function test, slow but steady
This commit is contained in:
@ -48,7 +48,7 @@ module Ast
|
||||
clazz = ::Virtual::Object.space.get_or_create_class name
|
||||
raise "uups #{clazz}.#{name}" unless clazz
|
||||
#class qualifier, means call from metaclass
|
||||
clazz = clazz.meta_class
|
||||
#clazz = clazz.meta_class
|
||||
clazz
|
||||
end
|
||||
end
|
||||
|
@ -2,7 +2,9 @@ module Ast
|
||||
class FunctionExpression < Expression
|
||||
# attr_reader :name, :params, :body , :receiver
|
||||
def compile frame , method
|
||||
method = Virtual::Method.new(name , params )
|
||||
args = params.collect{ |p| p.compile(frame , method )}
|
||||
r = receiver ? receiver.compile(frame,method) : Virtual::SelfReference.new
|
||||
method = Virtual::Method.new(name , params , r )
|
||||
end
|
||||
def scratch
|
||||
args = []
|
||||
|
Reference in New Issue
Block a user