rubyx/lib/asm/data_object.rb
2014-04-22 23:55:47 +03:00

21 lines
320 B
Ruby

module Asm
class DataObject
def initialize(data)
@data = data
end
def position
throw "Not set" unless @address
@address
end
def at address
@address = address
end
def length
@data.length
end
def assemble(io, as)
io << @data
end
end
end