Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
weakjson
The library is still under development. Please don't use it.
How to use it
There are only three functions that are provided by this library.
Decodes a json value from a string:
Shortcut function to decode a JSON &str
into an object:
Decodes a json value from an &mut io::Read
:
Comments:
Both inline (single-line) and block (multi-line) comments are allowed:
Object keys:
Object keys can be unquoted if they're valid identifiers or it's can be natural numbers:
Trailing commas:
Objects and arrays can have trailing commas:
Strings:
Strings can be single-quoted and contain unescaped control characters like '\n' or '\t'. Therefore, we can split string across multiple lines:
Weakjson ignore invalid escaping like \f
so that it will be simple f
.
Numbers:
Numbers can include Infinity
, -Infinity
, NaN
, and -NaN
,
begin with an explicit plus sign,
begin with leading zero digits,
begin or end with a (leading or trailing) decimal point,
be hexadecimal (base 16):