|
|
@ -138,7 +138,6 @@ module DFHack
|
|
|
|
@@inspecting = {} # avoid infinite recursion on mutually-referenced objects
|
|
|
|
@@inspecting = {} # avoid infinite recursion on mutually-referenced objects
|
|
|
|
def inspect
|
|
|
|
def inspect
|
|
|
|
cn = self.class.name.sub(/^DFHack::/, '')
|
|
|
|
cn = self.class.name.sub(/^DFHack::/, '')
|
|
|
|
cn << ' @' << ('0x%X' % _memaddr) if cn != ''
|
|
|
|
|
|
|
|
out = "#<#{cn}"
|
|
|
|
out = "#<#{cn}"
|
|
|
|
return out << ' ...>' if @@inspecting[_memaddr]
|
|
|
|
return out << ' ...>' if @@inspecting[_memaddr]
|
|
|
|
@@inspecting[_memaddr] = true
|
|
|
|
@@inspecting[_memaddr] = true
|
|
|
@ -655,6 +654,13 @@ module DFHack
|
|
|
|
DFHack.memory_bitarray_set(@_memaddr, idx, v)
|
|
|
|
DFHack.memory_bitarray_set(@_memaddr, idx, v)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
def inspect
|
|
|
|
|
|
|
|
out = "#<DfFlagarray"
|
|
|
|
|
|
|
|
each_with_index { |e, idx|
|
|
|
|
|
|
|
|
out << " #{_indexenum.sym(idx)}" if e
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
out << '>'
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
include Enumerable
|
|
|
|
include Enumerable
|
|
|
|
end
|
|
|
|
end
|
|
|
|