module RBS::AST::Members::Var
Attributes
comment
[R]
Comment?
location
[R]
loc?
type
[R]
Types::t
Public Class Methods
(name: Symbol, type: Types::t, location: loc?, comment: Comment?) → void
Source
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/lib/rbs/ast/members.rb, line 127 def initialize(name:, type:, location:, comment:) @name = name @type = type @location = location @comment = comment end
Public Instance Methods
Source
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/lib/rbs/ast/members.rb, line 134 def ==(other) other.is_a?(self.class) && other.name == name && other.type == type end
Also aliased as: eql?
Source
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/lib/rbs/ast/members.rb, line 140 def hash name.hash ^ type.hash end