Class: Steep::TypeInference::Context::MethodContext
- Inherits:
-
Object
- Object
- Steep::TypeInference::Context::MethodContext
- Defined in:
- lib/steep/type_inference/context.rb
Instance Attribute Summary collapse
-
#constructor ⇒ Object
readonly
Returns the value of attribute constructor.
-
#method ⇒ Object
readonly
Returns the value of attribute method.
-
#method_type ⇒ Object
readonly
Returns the value of attribute method_type.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#return_type ⇒ Object
readonly
Returns the value of attribute return_type.
-
#super_method ⇒ Object
readonly
Returns the value of attribute super_method.
Instance Method Summary collapse
- #block_type ⇒ Object
-
#initialize(name:, method:, method_type:, return_type:, constructor:, super_method:) ⇒ MethodContext
constructor
A new instance of MethodContext.
Constructor Details
#initialize(name:, method:, method_type:, return_type:, constructor:, super_method:) ⇒ MethodContext
Returns a new instance of MethodContext.
12 13 14 15 16 17 18 19 |
# File 'lib/steep/type_inference/context.rb', line 12 def initialize(name:, method:, method_type:, return_type:, constructor:, super_method:) @name = name @method = method @return_type = return_type @method_type = method_type @constructor = constructor @super_method = super_method end |
Instance Attribute Details
#constructor ⇒ Object (readonly)
Returns the value of attribute constructor.
9 10 11 |
# File 'lib/steep/type_inference/context.rb', line 9 def constructor @constructor end |
#method ⇒ Object (readonly)
Returns the value of attribute method.
6 7 8 |
# File 'lib/steep/type_inference/context.rb', line 6 def method @method end |
#method_type ⇒ Object (readonly)
Returns the value of attribute method_type.
7 8 9 |
# File 'lib/steep/type_inference/context.rb', line 7 def method_type @method_type end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
5 6 7 |
# File 'lib/steep/type_inference/context.rb', line 5 def name @name end |
#return_type ⇒ Object (readonly)
Returns the value of attribute return_type.
8 9 10 |
# File 'lib/steep/type_inference/context.rb', line 8 def return_type @return_type end |
#super_method ⇒ Object (readonly)
Returns the value of attribute super_method.
10 11 12 |
# File 'lib/steep/type_inference/context.rb', line 10 def super_method @super_method end |
Instance Method Details
#block_type ⇒ Object
21 22 23 |
# File 'lib/steep/type_inference/context.rb', line 21 def block_type method_type&.block end |