Sven Van Caekenberghe wrote:
Hi Peter,
Both cases will pass using this expression:
String streamContents: [ :out |
�� �� �� �� STON jsonWriter
�� �� �� �� �� �� �� �� referencePolicy: #ignore;
�� �� �� �� �� �� �� �� on: out;
�� �� �� �� �� �� �� �� nextPut: d ].
The problem is what to do with cycles.
Be faithful to what JSON.stringify does in JS. See attachment. :-)
Herby
Sven
On 27 Mar 2018, at 17:43, Peter Uhn��k<i.uhnak@gmail.com>�� wrote:
Hi,
I don't think this should throw an error when I am producing JSON.
```
d := {
�� �� �� �� 'a' ->�� #().
�� �� �� �� 'b' ->�� #().
} asDictionary.
STON toJsonString: d.
```
dtto this
```
a := {'hm'}.
d := {
�� �� �� �� 'a' ->�� a.
�� �� �� �� 'b' ->�� a.
} asDictionary.
STON toJsonString: d.
```
Maybe I should forgo using STON>>toJson* out of laziness (it is preinstalled) and always go for NeoJSON?
Peter