This commit is contained in:
Torsten Ruger 2015-10-15 10:27:06 +03:00
parent 398ec513f4
commit 0179638f0e
3 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@ module Phisol
raise "no class" unless for_class raise "no class" unless for_class
index = for_class.object_layout.variable_index(name) index = for_class.object_layout.variable_index(name)
#raise "class field already defined:#{name} for class #{for_class.name}" if index #raise "class field already defined:#{name} for class #{for_class.name}" if index
puts "Define field #{name} on class #{for_class.name}" #puts "Define field #{name} on class #{for_class.name}"
index = for_class.object_layout.add_instance_variable( name ) #TODO need typing index = for_class.object_layout.add_instance_variable( name ) #TODO need typing
if value if value

View File

@ -6,7 +6,7 @@ module Phisol
name , derives , statements = *statement name , derives , statements = *statement
raise "classes dont yet play babushka, get coding #{name}" if @clazz raise "classes dont yet play babushka, get coding #{name}" if @clazz
@clazz = Parfait::Space.object_space.get_class_by_name! name @clazz = Parfait::Space.object_space.get_class_by_name! name
puts "Compiling class #{@clazz.name.inspect}" #puts "Compiling class #{@clazz.name.inspect}"
statement_value = process_all(statements).last statement_value = process_all(statements).last
@clazz = nil @clazz = nil
return statement_value return statement_value

View File

@ -38,7 +38,7 @@ module Phisol
@method.for_class.add_instance_method @method @method.for_class.add_instance_method @method
end end
@method.source.receiver = r @method.source.receiver = r
puts "compile method #{@method.name}" #puts "compile method #{@method.name}"
kids.to_a.each do |ex| kids.to_a.each do |ex|
ret = process(ex) ret = process(ex)