remove >>, consistent use of <<

makes code easier to read, like assignments
does remind of Passengers
This commit is contained in:
Torsten Ruger
2018-04-06 22:40:58 +03:00
parent c042dd9faa
commit 22409c93ee
5 changed files with 40 additions and 49 deletions

View File

@ -38,14 +38,14 @@ module Risc
assert_equal @r0 , message.register
end
def test_slot_to_reg
instr = @r1[:first_message] >> @r0
instr = @r0 << @r1[:first_message]
assert_equal SlotToReg , instr.class
assert_equal @r1 , instr.array
assert_equal @r0 , instr.register
assert_equal 4 , instr.index
end
def test_reg_to_slot
instr = @r0 >> @r1[:first_message]
instr = @r1[:first_message] << @r0
assert_equal RegToSlot , instr.class
assert_equal @r1 , instr.array
assert_equal @r0 , instr.register