Open superwills opened 3 years ago
v = v[p]; // advance deeper into the tree
In C++, when a reference is created, it is bound to a value. The binding can not be modified afterwards. The assignment above will write a new value to the original bound value. This is not quite related to RapidJSON per se.
I've cross posted this with stackoverflow
I'm having an issue where the rapidjson library appears to be inconsistent as to when it reports
IsObject()
astrue
.Sometimes when I call
value.IsObject()
after retrieving aValue
from aDocument
, it correctly reports it as anObject
. But sometimes it reports what I think should be anObject
as not anObject
.A toy program is below.
It seems I am unintentionally mutating the document somehow, as the 2nd lookup for
vegetables::celery
remarkably fails.