Class: TypedRb::Model::TmSelf
Overview
booleans
Instance Attribute Summary
Attributes inherited from Expr
Instance Method Summary collapse
- #check_type(context) ⇒ Object
-
#initialize(node) ⇒ TmSelf
constructor
A new instance of TmSelf.
Constructor Details
#initialize(node) ⇒ TmSelf
Returns a new instance of TmSelf.
8 9 10 |
# File 'lib/typed/model/tm_self.rb', line 8 def initialize(node) super(node) end |
Instance Method Details
#check_type(context) ⇒ Object
12 13 14 15 16 17 18 19 |
# File 'lib/typed/model/tm_self.rb', line 12 def check_type(context) self_type = context.get_type_for(:self) if self_type.nil? fail TypeCheckError.new.new('Error type checking self reference: Cannot find self reference in typing context', node) else self_type end end |