class TypeProf::Core::AST::BranchNode::LoopNode::BreakNode::NextNode::CaseNode::CaseMatchNode::AndNode::OrNode::ReturnNode

Attributes

arg[R]

Public Class Methods

new(raw_node, lenv) click to toggle source
Calls superclass method TypeProf::Core::AST::Node::new
# File typeprof-0.30.1/lib/typeprof/core/ast/control.rb, line 336
def initialize(raw_node, lenv)
  super(raw_node, lenv)
  @arg = AST.parse_return_arguments(raw_node, lenv, code_range)
end

Public Instance Methods

install0(genv) click to toggle source
# File typeprof-0.30.1/lib/typeprof/core/ast/control.rb, line 345
def install0(genv)
  @arg.install(genv)
  e_ret = @lenv.locals[:"*expected_method_ret"]
  @lenv.add_return_box(@changes.add_escape_box(genv, @arg.ret, e_ret)) if e_ret
  Source.new(Type::Bot.new(genv))
end
subnodes(= { arg: }) click to toggle source
# File typeprof-0.30.1/lib/typeprof/core/ast/control.rb, line 343
  def subnodes = { arg: }

  def install0(genv)
    @arg.install(genv)
    e_ret = @lenv.locals[:"*expected_method_ret"]
    @lenv.add_return_box(@changes.add_escape_box(genv, @arg.ret, e_ret)) if e_ret
    Source.new(Type::Bot.new(genv))
  end
end