Skip to main content

Module json

Module json 

Source
Expand description

A small JSON reader that remembers the line of every value, so .yblock and .yitem errors point at file:line (serde_json only knows where a syntax error is).

Structs§

J
A JSON value and the 1-based line it starts on.

Enums§

V

Functions§

num_value
A number as JSON: integral values without a fraction (16, not 16.0).
parse
Parses text. Errors are line N: message. Duplicate keys are an error.
to_pretty
Pretty JSON, keys in order, two-space indent; arrays of numbers and small objects of scalars stay on one line ("uv": [0, 0, 16, 16]).