Class: AdLint::Ld::Typedef
- Inherits:
-
Object
- Object
- AdLint::Ld::Typedef
- Includes:
- AdLint::LocationHolder
- Defined in:
- lib/adlint/ld/typedef.rb
Instance Attribute Summary collapse
-
#location ⇒ Object
readonly
Returns the value of attribute location.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #eql?(rhs) ⇒ Boolean (also: #==)
- #hash ⇒ Object
-
#initialize(name, loc) ⇒ Typedef
constructor
A new instance of Typedef.
Methods included from AdLint::LocationHolder
Constructor Details
#initialize(name, loc) ⇒ Typedef
41 42 43 44 |
# File 'lib/adlint/ld/typedef.rb', line 41 def initialize(name, loc) @name = name @location = loc end |
Instance Attribute Details
#location ⇒ Object (readonly)
Returns the value of attribute location.
47 48 49 |
# File 'lib/adlint/ld/typedef.rb', line 47 def location @location end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
46 47 48 |
# File 'lib/adlint/ld/typedef.rb', line 46 def name @name end |
Instance Method Details
#eql?(rhs) ⇒ Boolean Also known as: ==
49 50 51 |
# File 'lib/adlint/ld/typedef.rb', line 49 def eql?(rhs) @name == rhs.name && @location == rhs.location end |
#hash ⇒ Object
55 56 57 |
# File 'lib/adlint/ld/typedef.rb', line 55 def hash "#{name} #{location}".hash end |