package jsont
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha512=507ab6b3d8718f322fb74999b3b82dbc1d36037042cb9067e5b8b63df80524a0602cc26e487b6e4ce061d65767162d6ffa00e173d9f51ce66cdd2a63482a350e
doc/CHANGES.html
v0.3.0 2026-08-14 Zagreb
- Add
Jsont.Json.remove_mem['] - Fix nested out-of-order case member decodes (#14)
Fix
Jsont.{int,int64}. The range in which numbers are codec by a JSON number is changed from[-2^53;2^53]to[-2^53+1;2^53-1]which is the correct range for reliable integer interchange.While
2^53is the maximal integer that can be represented exactly, it is ambiguous as it shares its representation with2^53+1. This means you could decode a JSON number2^53+1as2^53.jsontdid however encode2^53+1as a string so it was lossless on your own data.The new behaviour entails that both
-2^53and2^53values are now encoded as a string rather than a number. If you have encoded these numbers with the the previous version ofJsont.{int,int64}they will not parse back: they are now expected to be encoded by a string. You can useJsont.legacy_{int,int64}to migrate your data, the decoding works as before (and thus remains wrong if they hit externally produced JSON numbers-2^53-1and2^53+1) but the encoding uses the new range.Thanks to Thomas Gazagnaire for the report (#18).
v0.2.0 2025-07-25 Zagreb
- Fix
Jsont_bytesrw.{encode,encode'}. Do not write theeodslice ifeod:falseis specified. Thanks to Benjamin Nguyen-Van-Yen for the report and the fix (#8). - Fix
Jsont.zerofailing encodes rather than encodingnullas advertised. Thanks to Adrián Montesinos González for the report (#6). - Add
Jsont.Error.expectedto help format error messages. - Add
Jsont.with_docto update kind and doc strings of existing JSON types. - Add
Jsont.Object.Case.{tag,map_tag}to access a case and case map tags. - Fix
METAfile. Really export all requires and remove uneededbytesrwdependency fromjsontlibrary.
v0.1.1 2024-12-06 La Forclaz (VS)
Jsont.Object.Mems.mapmake encoding and decoding optional. Like in every other map.Jsont.Array.mapmake encoding and decoding optional. Like in every other map.Jsont_bytesrw.encodechange the default buffer size to match the one hinted by the writer rather thanBytesrw.Bytes.Slice.io_buffer_size.jsont.{bytesrw,brr}export all requires.jsonttool remove spurious dependency onb0.std(#2).
v0.1.0 2024-11-29 Zagreb
First release.
Supported by a grant from the OCaml Software Foundation.