Class: AdLint::Ld::FunctionDeclaration
- Inherits:
-
Object
- Object
- AdLint::Ld::FunctionDeclaration
- Includes:
- AdLint::LocationHolder
- Defined in:
- lib/adlint/ld/object.rb
Instance Method Summary collapse
- #eql?(rhs) ⇒ Boolean (also: #==)
- #explicit? ⇒ Boolean
- #extern? ⇒ Boolean
- #hash ⇒ Object
- #implicit? ⇒ Boolean
-
#initialize(fun_dcl_rec) ⇒ FunctionDeclaration
constructor
A new instance of FunctionDeclaration.
- #location ⇒ Object
- #name ⇒ Object
- #signature ⇒ Object
Methods included from AdLint::LocationHolder
Constructor Details
#initialize(fun_dcl_rec) ⇒ FunctionDeclaration
Returns a new instance of FunctionDeclaration.
227 228 229 |
# File 'lib/adlint/ld/object.rb', line 227 def initialize(fun_dcl_rec) @met_record = fun_dcl_rec end |
Instance Method Details
#eql?(rhs) ⇒ Boolean Also known as: ==
255 256 257 |
# File 'lib/adlint/ld/object.rb', line 255 def eql?(rhs) signature == rhs.signature && location == rhs.location end |
#explicit? ⇒ Boolean
247 248 249 |
# File 'lib/adlint/ld/object.rb', line 247 def explicit? @met_record.function_declaration_type == "E" end |
#extern? ⇒ Boolean
243 244 245 |
# File 'lib/adlint/ld/object.rb', line 243 def extern? @met_record.function_linkage_type == "X" end |
#hash ⇒ Object
261 262 263 |
# File 'lib/adlint/ld/object.rb', line 261 def hash "#{signature} #{location}".hash end |
#implicit? ⇒ Boolean
251 252 253 |
# File 'lib/adlint/ld/object.rb', line 251 def implicit? @met_record.function_declaration_type == "I" end |
#location ⇒ Object
231 232 233 |
# File 'lib/adlint/ld/object.rb', line 231 def location @met_record.location end |
#name ⇒ Object
239 240 241 |
# File 'lib/adlint/ld/object.rb', line 239 def name @met_record.function_id.name end |
#signature ⇒ Object
235 236 237 |
# File 'lib/adlint/ld/object.rb', line 235 def signature @met_record.function_id.signature end |