remove collecting from the machine

use as stand alone module
This commit is contained in:
Torsten Ruger
2016-12-31 19:54:18 +02:00
parent 671512b96c
commit dccd097fef
6 changed files with 12 additions and 14 deletions

View File

@ -10,8 +10,8 @@ module Positioned
pos = Positioned.positions[self]
if pos == nil
str = "position accessed but not set, "
str += "#{Register.machine.objects.has_key?(self.object_id)}, at #{self.object_id.to_s(16)}\n"
raise str + "for #{self.class} byte_length #{byte_length} for #{self.inspect[0...100]}"
str += "#{self.object_id.to_s(16)}\n"
raise str + "for #{self.class} byte_length #{self.byte_length if self.respond_to?(:byte_length)} for #{self.inspect[0...100]}"
end
pos
end