Project

General

Profile

Actions

Feature #12333

closed

`String#concat`, `Array#concat`, `String#prepend` to take multiple arguments

Added by sawa (Tsuyoshi Sawada) almost 8 years ago. Updated over 7 years ago.

Status:
Closed
Assignee:
-
Target version:
-
[ruby-core:75264]

Description

I would like String#concat, Array#concat, String#prepend to take multiple arguments

s = ""
s.concat("a", "b", "c")
a.prepend("A", "B", "C")
s # => "ABCabc"

a = []
a.concat(["a"], ["b", "c"])
a # => ["a", "b", "c"]

Files

multi_concat_prepend.patch (2.94 KB) multi_concat_prepend.patch spinute (Satoru Horie), 05/03/2016 07:14 AM
fixed_multi_concat_prepend.patch (3.14 KB) fixed_multi_concat_prepend.patch spinute (Satoru Horie), 05/03/2016 08:03 AM
multi_concat_prepend.patch (7.19 KB) multi_concat_prepend.patch diff from: 0052ed9d806f3739df9200891a376a18dc8068f9 spinute (Satoru Horie), 06/20/2016 03:31 PM

Related issues 2 (1 open1 closed)

Related to Ruby master - Feature #12247: accept multiple arguments at Array#deleteOpenActions
Related to Ruby master - Bug #13268: [DOC] Restore docs for String#<<Closedstomar (Marcus Stollsteimer)Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0