Method: FastRuby::Method#build

Defined in:
lib/fastruby/builder.rb

#build(signature, noreturn = false) ⇒ Object



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# File 'lib/fastruby/builder.rb', line 54

def build(signature, noreturn = false)
  return nil unless tree

  no_cache = false
  mname = FastRuby.make_str_signature(@method_name, signature)

  if @owner.respond_to? :method_hash
    method_hash = @owner.method_hash(@method_name.to_sym) || {}
    if (@owner.has_fastruby_function(method_hash,mname.to_s))
      FastRuby.logger.info "NOT Building #{@owner}::#{@method_name} for signature #{signature.inspect}, it's already done"
      return nil
    end
  end

  rebuild(signature, noreturn)
end