Hi,
I know I posted many weird JSON problems lastly, but I use JSON a lot, so .. :D
I had a porblem in my application which I managed to replicate after a few hours, but I have to confess it still seems a little weird.
I create a some kind of linked list in cs:
$$innerobject = ^jsoncreate(object)
$$innerobject.id = inner
$$middleobject = ^jsoncreate(object)
$$middleobject.id = middle
$$middleobject.next = $$innerobject
$$outerobject = ^jsoncreate(object)
$$outerobject.id = outer
$$outerobject.next = $$middleobject
^jsonwrite($$innerobject)
So far everything works as expected, the inner object exists:
{ "id": "inner"}
Now if I cut the chain at the first possible point, the lastof the chain is destroyed:
$$outerobject.next = null
^jsonwrite($$innerobject)
{ }
So what can I do if a want to reset references to inner json objects without destroying them?