Fixing ripples from previous

This commit is contained in:
2020-03-16 17:51:21 +02:00
parent 3ce6ed5263
commit 0ed5e74748
5 changed files with 10 additions and 10 deletions

View File

@ -8,7 +8,7 @@ module Risc
@right = RegisterValue.new(:right , :Integer)
end
def risc(i)
@left.op :- , @right
OperatorInstruction.new( "source" , :- , @left , @right )
end
def test_min
assert_operator 1 , :- , :left , :right , "op_-_"

View File

@ -12,7 +12,7 @@ module Risc
def test_chain
#show_main_ticks # get output of what is
check_main_chain [LoadConstant, SlotToReg, RegToSlot, LoadConstant, SlotToReg, #5
check_main_chain [LoadConstant, SlotToReg, RegToSlot, LoadConstant, SlotToReg, #5
RegToSlot, LoadConstant, SlotToReg, RegToSlot, SlotToReg, #10
FunctionCall, LoadConstant, LoadConstant, SlotToReg, OperatorInstruction, #15
IsNotZero, SlotToReg, RegToSlot, RegToSlot, SlotToReg, #20
@ -22,7 +22,7 @@ module Risc
RegToSlot, SlotToReg, SlotToReg, FunctionReturn, SlotToReg, #40
RegToSlot, Branch, SlotToReg, SlotToReg, RegToSlot, #45
SlotToReg, SlotToReg, FunctionReturn, Transfer, SlotToReg, #50
SlotToReg, Syscall, NilClass,] #55
SlotToReg, Transfer, Syscall, NilClass,] #55
assert_equal "Hello again" , @interpreter.stdout
assert_equal Integer , get_return.class
assert_equal 11 , get_return #bytes written