Class: RBI::Arg
Direct Known Subclasses
KwArg
Instance Attribute Summary collapse
Attributes inherited from Node
#loc, #parent_tree
Instance Method Summary
collapse
Methods inherited from Node
#compatible_with?, #detach, #merge_with, #parent_conflict_tree, #parent_scope, #print, #rbs_print, #rbs_string, #replace, #satisfies_version?, #string
Constructor Details
#initialize(value, loc: nil) ⇒ Arg
Returns a new instance of Arg.
983
984
985
986
|
# File 'lib/rbi/model.rb', line 983
def initialize(value, loc: nil)
super(loc: loc)
@value = value
end
|
Instance Attribute Details
#value ⇒ Object
980
981
982
|
# File 'lib/rbi/model.rb', line 980
def value
@value
end
|
Instance Method Details
#==(other) ⇒ Object
989
990
991
|
# File 'lib/rbi/model.rb', line 989
def ==(other)
Arg === other && value == other.value
end
|
#to_s ⇒ Object
994
995
996
|
# File 'lib/rbi/model.rb', line 994
def to_s
value
end
|