You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Cover all of CBOR and every JVM type, profile and option on Jolt (#40)
Jolt's boring.core now has the JVM's API over a portable codec that writes
the JVM's bytes and raises the JVM's error types:
- boring.plain mirrors Writer.java and Reader.java: every profile, the writer
options (text references, seq markers, metadata, float policy, shapes,
encode fallback), the decode budgets and policies, indefinite lengths, half
floats, simple values, unknown tags, and every type the JVM writes.
- core.jolt validates options through boring.options and adds encode-into!,
encode-buffered!, buffer, trim!, write-to-buffer!, write-indexed!,
write-seq! with its sealed offset index, seal-index!, build-index (the
ClojureScript byte walk), reader, decode-with, decode-at and
register-record-class.
- decode returns the first item, as on the JVM, and a count the input cannot
back is :boring/bad-count rather than :boring/truncated-input.
test-jolt/check.sh now also runs the 11 shared cljc suites on Jolt against
the built jar, and compares Jolt with the JVM on a corpus of every value type
under ten profile and option sets, 6000 hostile inputs through every read
path, and the API's argument handling. Shared tests take a :jolt branch only
where the Jolt runtime cannot express the JVM fixture.