JuliaIO / JSON.jl

JSON parsing and printing
Other
311 stars 100 forks source link

Add eof check for streaming parser #321

Open wardlem opened 3 years ago

wardlem commented 3 years ago

Summary

Adds an end of file check to the streaming parser.

Motivation

# This works
JSON.parse("123")

# This also works
JSON.parse(IOBuffer("123\n"))

# This currently breaks
JSON.parse(IOBuffer("123"))

Fixes #314

pitipatw commented 1 year ago

Is this issue resolved? I also got an error that seems to be related to this one:

Unexpected end of input │ ...when parsing byte with value '0'