last fixes for cc
seems like setup had just worked by chance and change broke that.
This commit is contained in:
@ -28,6 +28,12 @@ module Mom
|
||||
end
|
||||
end
|
||||
|
||||
# Only for init, as init has no return
|
||||
def _reset_for_init
|
||||
@mom_instructions = Label.new(source_name, source_name)
|
||||
@current = @mom_instructions
|
||||
end
|
||||
|
||||
# add a constant (which get created during compilation and need to be linked)
|
||||
def add_constant(const)
|
||||
raise "Must be Parfait #{const}" unless const.is_a?(Parfait::Object)
|
||||
@ -64,8 +70,8 @@ module Mom
|
||||
while( instruction )
|
||||
raise "whats this a #{instruction}" unless instruction.is_a?(Mom::Instruction)
|
||||
#puts "adding mom #{instruction.to_s}:#{instruction.next.to_s}"
|
||||
instruction.to_risc( risc_compiler )
|
||||
risc_compiler.reset_regs
|
||||
instruction.to_risc( risc_compiler )
|
||||
#puts "adding risc #{risc.to_s}:#{risc.next.to_s}"
|
||||
instruction = instruction.next
|
||||
end
|
||||
|
Reference in New Issue
Block a user