@@ -37,8 +37,8 @@ class IMAP
37
37
#
38
38
# SequenceSet.new may receive a single optional argument: a non-zero 32 bit
39
39
# unsigned integer, a range, a <tt>sequence-set</tt> formatted string,
40
- # another sequence set, a Set (containing only numbers), or an enumerable
41
- # containing any of these (which may be nested).
40
+ # another sequence set, a Set (containing only numbers), or an Array
41
+ # containing any of these (array inputs may be nested).
42
42
#
43
43
# set = Net::IMAP::SequenceSet.new(1)
44
44
# set.valid_string #=> "1"
@@ -290,8 +290,7 @@ class SequenceSet
290
290
private_constant :STAR_INT , :STARS
291
291
292
292
COERCIBLE = -> { _1 . respond_to? :to_sequence_set }
293
- ENUMABLE = -> { _1 . respond_to? ( :each ) && _1 . respond_to? ( :empty? ) }
294
- private_constant :COERCIBLE , :ENUMABLE
293
+ private_constant :COERCIBLE
295
294
296
295
class << self
297
296
@@ -1273,7 +1272,7 @@ def input_to_tuples(obj)
1273
1272
when String then str_to_tuples obj
1274
1273
when SequenceSet then obj . tuples
1275
1274
when Set then obj . map { to_tuple_int _1 }
1276
- when ENUMABLE then obj . flat_map { input_to_tuples _1 }
1275
+ when Array then obj . flat_map { input_to_tuples _1 }
1277
1276
when nil then [ ]
1278
1277
else
1279
1278
raise DataFormatError ,
0 commit comments