The user/caller decides what it expects from the input and how to deal with
exceptions.
For example, here is how to read multiple expression until EOF
Array streamContents: [ :out |
[ reader atEnd ] whileFalse: [ out nextPut: reader next ] ]
I think the current design is the both simple and f
Ok but how does the parser knows whether the input is multiexpression or an
error?
I mean it stops parsing in the middle of the string which seems really
weird to me.
Peter
On Sun, Jul 5, 2015 at 3:28 PM, Sven Van Caekenberghe wrote:
> Hi Peter,
>
> > On 05 Jul 2015, at 14:36, Peter Uhnák wrot
Hi Peter,
> On 05 Jul 2015, at 14:36, Peter Uhnák wrote:
>
> How come this passes?
>
> STON fromString: '{
> "a": "b"
> }wtf",
> "x": "y"
> '.
>
> The result is dictionary "a" -> "b".
>
> I would expect for it to die on parse error.
>
> Peter
The reason this does not fail is bec
How come this passes?
STON fromString: '{
"a": "b"
}wtf",
"x": "y"
'.
The result is dictionary "a" -> "b".
I would expect for it to die on parse error.
Peter