aboutsummaryrefslogtreecommitdiff
path: root/lib/std/json.zig
AgeCommit message (Collapse)Author
2020-07-11run zig fmt on std lib and self hostedVexu
2020-07-05Merge pull request #5786 from ziglang/std-hash-mapAndrew Kelley
reimplement std.HashMap
2020-07-05update std lib to new hash map APIAndrew Kelley
2020-07-04std.mem.dupe is deprecated, move all references in stdjoachimschmidt557
Replaced all occurences of std.mem.dupe in stdlib with Allocator.dupe/std.mem.dupeZ -> Allocator.dupeZ
2020-06-22`try` allocation of pointer type when parsing (#5665)prime31
* `try` allocation of pointer type when parsing * fixes pointer destroy compile error
2020-06-20zig fmtAndrew Kelley
2020-06-15std: remove std.debug.getStderrStreamdaurnimator
Rather than migrate to new 'writer' interface, just remove it
2020-05-28Support stringify for vectors (#5441)Dmitry Atamanov
* use array's pointer
2020-05-18json: properly stringify error setsAndrew Kelley
I did this wrong originally in feade9ef0010b1b47d7216e786ed964d09612c2b
2020-05-17std.json: support stringify for anyerrorAndrew Kelley
2020-05-12Fix comment typo RFC8529 -> RFC8259Jason Merrill
Ref: https://tools.ietf.org/html/rfc8259
2020-05-12Merge pull request #5118 from xackus/fix-json-writestreamVexu
fix json.WriteStream.emitJson
2020-05-12std.json properly handle comptime int/floatVexu
2020-05-08publicize member functions affected by #4909Josh Junon
2020-04-27Fix issue with std.json incorrectly replacing forward slashes with a ↵Auguste Rame
backslash (#5167) * fix breaking typo in json.zig * add tests
2020-04-24Add mips support to standard libraryTimon Kruiper
2020-04-18update std lib to decls being disallowed between fieldsVexu
2020-04-11ArrayList: remove old (before span) APIxackus
2020-04-07fix broken testsVexu
2020-04-02new ArrayList API: fix everything elsexackus
2020-04-01std: add support to std.json.stringify for null literalsdaurnimator
2020-04-01std: allow picking between serialising []u8 as string or arraydaurnimator
2020-04-01std: add options to std.json.stringfy to control escapingdaurnimator
2020-04-01std: use stringify from Value.dump; remove other dump helpersdaurnimator
2020-04-01std: add jsonStringify trait to json Value objectsdaurnimator
2020-03-31std: add whitespace control to json.stringifydaurnimator
2020-03-31std: have json tests take options parameterdaurnimator
2020-03-30std lib API deprecations for the upcoming 0.6.0 releaseAndrew Kelley
See #3811
2020-03-29enable now-passing test casesAndrew Kelley
These can now be enabled thanks to bug fixes that landed in LLVM 10.
2020-03-25Carry-over stream error to JSON.stringifyBenjamin Feng
2020-03-19std lib fixups for new semanticsAndrew Kelley
std lib tests are passing now
2020-03-12Replace fmt with new fmtstreamBenjamin Feng
2020-03-12Convert JSON to fmtstreamBenjamin Feng
2020-03-10update standard library to new I/O streams APIAndrew Kelley
2020-03-10(breaking) improve and simplify fixed buffer streams APIAndrew Kelley
2020-02-19std: tagged unions are broken on arm64daurnimator
2020-02-19std: add json.parse to automatically decode json into a structdaurnimator
2020-02-19std: add json.stringify to encode arbitrary values to JSONdaurnimator
2020-02-16std: Remove now-superflous hackLemonBoy
2020-02-14std: use testing.allocator in testsdaurnimator
2020-02-12Convert a lot of json tests to use testing.allocatorBenjamin Feng
2020-01-07Merge pull request #4091 from xackus/json_copy_stringsAndrew Kelley
json: implement copy_strings=false
2020-01-07json tests: don't use debug allocatorxackus
2020-01-07json: disallow overlong and out-of-range UTF-8hryx
Fixes #2379 = Overlong (non-shortest) sequences UTF-8's unique encoding scheme allows for some Unicode codepoints to be represented in multiple ways. For any of these characters, the spec forbids all but the shortest form. These disallowed longer sequences are called "overlong". As an interesting side effect of this rule, the bytes C0 and C1 never appear in valid UTF-8. = Codepoint range UTF-8 disallows representation of codepoints beyond U+10FFFF, which is the highest character which can be encoded in UTF-16. Because a 4-byte sequence is capable of resulting in such characters, they must be explicitly rejected. This rule also has an interesting side effect, which is that bytes F5 to FF never appear. = References Detecting an overlong version of a codepoint could get gnarly, but luckily The Unicode Consortium did the hard work by creating this handy table of valid byte sequences: https://unicode.org/versions/corrigendum1.html I thought this mapped nicely to the parser's state machine, so I rearranged the relevant states to make use of it.
2020-01-06json: implement copy_strings=falsexackus
2019-12-31std: fix typo in commentdaurnimator
2019-12-31std: json.unescapeString doesn't need to take an allocatordaurnimator
2019-12-31std: track decoded string length in std.json tokenizerdaurnimator
2019-12-30std: use enum literals in std.jsondaurnimator
2019-12-30std: use a union(enum) for std.json.Tokendaurnimator