Sha256: 47dc02257f708b4c3461eb2c4e5b284e2b383b97525b5370c33df17e6a398998

Contents?: true

Size: 453 Bytes

Versions: 5

Compression:

Stored size: 453 Bytes

Contents

class Foo
  def initialize
    @array = []
    @hash = {}
  end

  def set
    @array << 1
    @array << "str"
    @array << :sym
    @hash[:a] = 1
    @hash[:b] = "str"
    @hash[:c] = :sym
  end

  attr_reader :array, :hash
end

Foo.new.array
Foo.new.hash
Foo.new.set

__END__
# Classes
class Foo
  def initialize: -> void
  def set: -> :sym
  attr_reader array: Array[:sym | Integer | String]
  attr_reader hash: {a: Integer, b: String, c: :sym}
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
typeprof-0.20.0 smoke/ivar2.rb
typeprof-0.15.3 smoke/ivar2.rb
typeprof-0.15.2 smoke/ivar2.rb
typeprof-0.15.1 smoke/ivar2.rb
typeprof-0.15.0 smoke/ivar2.rb