Class: RBS::Types::Literal
Relationships & Source Files | |
Super Chains via Extension / Inclusion / Inheritance | |
Instance Chain:
|
|
Inherits: | Object |
Defined in: | lib/rbs/types.rb |
Class Method Summary
- .new(literal:, location:) ⇒ Literal constructor
Instance Attribute Summary
Instance Method Summary
- #==(other) (also: #eql?)
- #eql?(other)
- #hash
- #to_json(state = _ = nil)
- #to_s(level = 0)
NoTypeName
- Included
EmptyEachType
- Included
NoSubst
- Included
NoFreeVariables
- Included
Constructor Details
.new(literal:, location:) ⇒ Literal
Instance Attribute Details
#literal (readonly)
[ GitHub ]# File 'lib/rbs/types.rb', line 1065
attr_reader :literal
#location (readonly)
[ GitHub ]# File 'lib/rbs/types.rb', line 1066
attr_reader :location
Instance Method Details
#==(other) Also known as: #eql?
[ GitHub ]#eql?(other)
[ GitHub ]# File 'lib/rbs/types.rb', line 1077
alias eql? ==
#hash
[ GitHub ]# File 'lib/rbs/types.rb', line 1079
def hash self.class.hash ^ literal.hash end
#to_json(state = _ = nil)
[ GitHub ]#to_s(level = 0)
[ GitHub ]# File 'lib/rbs/types.rb', line 1092
def to_s(level = 0) literal.inspect end