Project

General

Profile

Actions

Feature #16991

closed

Sets: add Set#join

Added by marcandre (Marc-Andre Lafortune) over 4 years ago. Updated almost 2 years ago.

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

Description

I'd like to add #join to Set:

# Now:
Set[1, 2, 3].join('x') # => NoMethodError
# After
Set[1, 2, 3].join('x') # => "1x2x3"

I'd make this join never recursive. (I've never wanted to use the recursivity of Array#join, but it may very well just be my particular experience)

Reminder: Why there is no Enumerable#join: https://bugs.ruby-lang.org/issues/1893


Related issues 1 (1 open0 closed)

Related to Ruby master - Feature #16989: Sets: need ♥️Assignedknu (Akinori MUSHA)Actions
Actions #1

Updated by marcandre (Marc-Andre Lafortune) over 4 years ago

Updated by zverok (Victor Shepelev) almost 2 years ago

  • Status changed from Open to Closed

Implemented in Ruby 3.0

Actions

Also available in: Atom PDF

Like0
Like0Like0