[ruby-core:69745] [Ruby trunk - Bug #11310] [Open] CSV::Table#to_csv should use concat not +

From: zach.dennis@...
Date: 2015-06-26 15:16:15 UTC
List: ruby-core #69745
Issue #11310 has been reported by Zach Dennis.

----------------------------------------
Bug #11310: CSV::Table#to_csv should use concat not +
https://bugs.ruby-lang.org/issues/11310

* Author: Zach Dennis
* Status: Open
* Priority: Normal
* Assignee: 
* ruby -v: ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux-gnu]
* Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN
----------------------------------------
The current implementation of CSV::Table#to_a method uses Array#+ to which is really bad on performance. It seems like it should use Array#concat.

Relevant Github PR: https://github.com/ruby/ruby/pull/946



-- 
https://bugs.ruby-lang.org/

In This Thread

Prev Next