| author | |
| committer | |
| log | dede9ed9acffe9cd08a12b51a68b566120d7004d |
| tree | 1bc3f37ea23a0a8d208e9615c76b056f937e6994 |
| parent | 7a54d3cbd80ebdf78d6d7b16c86dfa81af42d1a4 |
1 files changed, 5 insertions(+), 0 deletions(-)
src/lib.zig+5| ... | ... | @@ -497,3 +497,8 @@ pub fn assertLog(ok: bool, message: string) void { |
| 497 | 497 | if (!ok) std.log.err("assertion failure: {s}", .{message}); |
| 498 | 498 | if (!ok) unreachable; // assertion failure |
| 499 | 499 | } |
| 500 | ||
| 501 | pub fn parse_json(alloc: std.mem.Allocator, input: string) !std.json.ValueTree { | |
| 502 | var p = std.json.Parser.init(alloc, .alloc_always); | |
| 503 | return try p.parse(input); | |
| 504 | } |