fix util namespace

and instruction move ripples
This commit is contained in:
Torsten Ruger
2018-03-26 20:05:30 +03:00
parent c5b3c3f106
commit 4cc1d8455e
7 changed files with 45 additions and 53 deletions

View File

@ -38,9 +38,15 @@ module Risc
def assemble io
end
def total_byte_length
ret = 0
self.each{|ins| ret += ins.byte_length}
ret
end
# labels have the same position as their next
def set_position( position )
super(position)
Positioned.set_position(self,position)
self.next.set_position(position) if self.next
end