rename a bit
This commit is contained in:
@ -3,10 +3,10 @@ module Risc
|
||||
module Builtin
|
||||
module CompileHelper
|
||||
|
||||
def compiler_for( type , method_name , arguments , locals = {})
|
||||
def compiler_for( clazz_name , method_name , arguments , locals = {})
|
||||
frame = Parfait::NamedList.type_for( locals )
|
||||
args = Parfait::NamedList.type_for( arguments )
|
||||
Risc::MethodCompiler.create_method(type , method_name , args, frame )
|
||||
Risc::MethodCompiler.compiler_for_class(clazz_name , method_name , args, frame )
|
||||
end
|
||||
|
||||
end
|
||||
|
@ -41,11 +41,12 @@ module Risc
|
||||
emit_syscall( compiler.builder(true, compiler.method) , :exit )
|
||||
return compiler.method
|
||||
end
|
||||
|
||||
# this is the really really first place the machine starts (apart from the jump here)
|
||||
# it isn't really a function, ie it is jumped to (not called), exits and may not return
|
||||
# so it is responsible for initial setup
|
||||
def __init__ context
|
||||
compiler = Risc::MethodCompiler.create_method(:Object,:__init__ ,
|
||||
compiler = MethodCompiler.compiler_for_class(:Object,:__init__ ,
|
||||
Parfait::NamedList.type_for({}) , Parfait::NamedList.type_for({}))
|
||||
builder = compiler.builder(true, compiler.method)
|
||||
builder.build do
|
||||
|
Reference in New Issue
Block a user