Repository navigation
Releases
Releases · peltonapp/rustyon-go
v1.1.0
Highlights
- Strict ron-rs compatibility. The parser is a port of ron-rs 0.12.3 value parsing and is checked in CI against ron-rs itself (about 1,300 corpus documents plus differential fuzzing).
- Faster decoding.
Unmarshaldecodes straight from the text without an intermediate tree: on par withencoding/json, andParseis about twice as fast asencoding/jsonintoany.Formatis faster too. - Comment preserving edits.
ParseEditablewithGet,Set,SetRON,Delete,InsertandAppendby path. - Field naming.
NamingStrategy(camelCase, PascalCase, ...),SetFieldNaming, and a per-structrename_all=option. - Pretty printing.
PrettyConfigandMarshalWithConfig, modelled on ron-rs'sPrettyConfig. - Raw values and generics.
rustyon.Raw,UnmarshalAs[T],DecodeAs[T]. - Enum representations. Internally tagged, adjacently tagged and untagged enums via
RegisterEnumWith, plus aflattentag option. - Options structs.
EncodeOptions/MarshalWithandDecodeOptions/UnmarshalWith. - Composite
Valuetypes print as compact RON withfmt.
Behaviour changes
These follow from matching ron-rs exactly:
- Nesting is limited like ron-rs: 64 nested collections, 128 nested
Some(. - Unsuffixed integers beyond 128 bits become floats instead of an error.
- Ranges (
1..2,1..=2,..) and#![type = "..."]/#![schema = "..."]attributes are accepted. isize/usizesuffixes,0X/0O/0Bprefixes and the\b,\f,\/escapes are rejected.( )is an empty tuple and()is unit.- On a decode error the target may be partially modified;
UnmarshalRON/UnmarshalTexthooks run at most once per value. - Decoding a non-comparable key into
map[any]Treturns an error instead of panicking.
CLI
The CLI is now its own module with its own tags; see the cmd/rustyon/v1.1.0 release for binaries:
go install github.com/peltonapp/rustyon-go/cmd/rustyon@latestv1.0.0
Changelog
- ec14b78 Add CI workflows with tests, lint, fuzz and DCO check
- 40912c4 Add Go module and gitignore
- c833ed8 Add GoReleaser release workflow and Dependabot
- 0df098d Add Marshal, Unmarshal and enum registry
- 98a62d5 Add README with logo and badges
- 154dde0 Add RON lexer, parser and value tree
- e32117e Add comment preserving formatter
- 7409df4 Add contributing guide, DCO, code of conduct and security policy
- 83f0d52 Add fuzz tests and benchmarks
- 1599fc8 Add performance summary to README
- 35bb5fe Add ronjson package for RON and JSON conversion
- b2d9188 Add rustyon CLI with fmt, validate and JSON conversion
- 50b4932 Bump GitHub Actions and exempt bots from the DCO check
- 2e3bb67 Fix gofmt alignment in fields test
- e69b9ff Fix lint findings and reduce formatter allocations
- 7afe1a6 Fix map key ordering, enforce 128-bit and explicit_struct_names limits, clarify errors
- 955b15d Initial commit
- c404922 Move lexer, formatter and struct reflection into internal packages
- 2373e1e Outline logo text so the SVG needs no web font
- b2332a2 Shrink formatter tokens and nodes to cut allocations by 70 percent
- 3ae3129 Speed up encoding and decoding with cached type checks and lock free enum lookups
- e29dd65 Switch license to BSD-3-Clause
- b090c0c Use errors.As in lexer error resolution
rustyon CLI v1.1.0
Full Changelog: v1.1.0...cmd/rustyon/v1.1.0