Sha256: 8775b7b79a4a9fc847e69c4025caccd1a51a8332c90d154943223f09a97d6554
Contents?: true
Size: 303 Bytes
Versions: 9
Compression:
Stored size: 303 Bytes
Contents
class Foo def []=(*args) ary = [] val = args[-1] ary[*args[0..-2]] = val # TODO: there is room to improve array_aset ary # This should be Array[String] end end Foo.new[1] = "str" __END__ # Classes class Foo def []=: (*Integer | String args) -> Array[bot] end
Version data entries
9 entries across 9 versions & 1 rubygems