What would be the best way (ideally with IronPython) to access an object using its memory address?
By address I mean the hex identifier which is often part of repr string.
import Rhino.Geometry as rg curve = rg.Circle(rg.Point3d(0,0,0), 10).ToNurbsCurve() print curve print hex(id(curve))
<Rhino.Geometry.NurbsCurve object at 0x0000000000000083 [Rhino.Geometry.NurbsCurve]>
I am aware that referencing objects this way would be bad practice, but assuming Rhino keeps the objects in the memory I imagine it could be really useful for debugging (ie. logging the identifiers and later inspecting the geometry that caused an exception).