Class: Steep::TypeInference::MethodCall::MethodDecl
- Defined in:
- lib/steep/type_inference/method_call.rb
Instance Attribute Summary collapse
-
#method_def ⇒ Object
readonly
Returns the value of attribute method_def.
-
#method_name ⇒ Object
readonly
Returns the value of attribute method_name.
Instance Method Summary collapse
- #==(other) ⇒ Object (also: #eql?)
- #hash ⇒ Object
-
#initialize(method_name:, method_def:) ⇒ MethodDecl
constructor
A new instance of MethodDecl.
- #method_type ⇒ Object
Constructor Details
#initialize(method_name:, method_def:) ⇒ MethodDecl
Returns a new instance of MethodDecl.
8 9 10 11 |
# File 'lib/steep/type_inference/method_call.rb', line 8 def initialize(method_name:, method_def:) @method_name = method_name @method_def = method_def end |
Instance Attribute Details
#method_def ⇒ Object (readonly)
Returns the value of attribute method_def.
6 7 8 |
# File 'lib/steep/type_inference/method_call.rb', line 6 def method_def @method_def end |
#method_name ⇒ Object (readonly)
Returns the value of attribute method_name.
5 6 7 |
# File 'lib/steep/type_inference/method_call.rb', line 5 def method_name @method_name end |
Instance Method Details
#==(other) ⇒ Object Also known as: eql?
17 18 19 |
# File 'lib/steep/type_inference/method_call.rb', line 17 def ==(other) other.is_a?(MethodDecl) && other.method_name == method_name && other.method_def == method_def end |
#hash ⇒ Object
13 14 15 |
# File 'lib/steep/type_inference/method_call.rb', line 13 def hash method_name.hash end |
#method_type ⇒ Object
23 24 25 |
# File 'lib/steep/type_inference/method_call.rb', line 23 def method_type method_def.type end |