class TypedRb::Model::TmSuper
super keyword invocations
Attributes
args[R]
Public Class Methods
new(args, node)
click to toggle source
Calls superclass method
TypedRb::Model::Expr::new
# File lib/typed/model/tm_super.rb, line 8 def initialize(args, node) super(node) @args = args end
Public Instance Methods
check_type(context)
click to toggle source
# File lib/typed/model/tm_super.rb, line 13 def check_type(context) if Types::TypingContext.function_context self_type, message, args = Types::TypingContext.function_context parent_self_type = Types::TyObject.new(self_type.hierarchy.first, node) args = @args || args args = args.map { |arg| arg.check_type(context) } TmSend.new(parent_self_type, message, args, node).check_type(context) else fail TypeCheckError.new("Error type checking 'super' invocation without function context.", node) end end