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

Version Path
typeprof-0.15.2 smoke/array15.rb
typeprof-0.15.1 smoke/array15.rb
typeprof-0.15.0 smoke/array15.rb
typeprof-0.14.1 smoke/array15.rb
typeprof-0.14.0 smoke/array15.rb
typeprof-0.13.0 smoke/array15.rb
typeprof-0.12.0 smoke/array15.rb
typeprof-0.11.0 smoke/array15.rb
typeprof-0.10.0 smoke/array15.rb