Releases: CertainLach/jrsonnet
v0.5.0-pre96-test
I'm running out of semver-compatible numbers, so v0.5.0 release is inevitable
What's Changed
- doc: correct a typo in features by @ebw44 in #114
- Allow '=' within the body of --tla-code by @expelledboy in #122
- feat: missing std features by @pawelbeza in #124
- feat: sync upstream stdlib changes by @CertainLach in #118
- Introduce experimental rowan parser and pretty-printer by @CertainLach in #132
- docs: asciidoc'ify all md's except for the generated one by @JarvisCraft in #131
- build(dep): update dependencies and share their versions by @JarvisCraft in #136
- fix: make
async_imports
compile again by @JarvisCraft in #137 - build: use now-stable async traits by @JarvisCraft in #138
- feat: add std regex builtins by @CertainLach in #119
- build(deps): bump zerocopy from 0.7.30 to 0.7.31 by @dependabot in #143
- Fix failing CI for tests and lints by @CertainLach in #146
- fix: lazy object comprehension by @CertainLach in #145
- Experimental jrsonnet-fmt formatting utility
- feat: allow negative indexes in std.slice by @CertainLach in #117
- Fix: field in super should not be interpreted with standalone-super concept. by @CertainLach in #154
- Implement
std.flattenDeepArray
andstd.prune
as builtins
New Contributors
- @ebw44 made their first contribution in #114
- @expelledboy made their first contribution in #122
- @pawelbeza made their first contribution in #124
- @dependabot made their first contribution in #143
Full Changelog: v0.5.0-pre9-test...v0.5.0-pre96-test
v0.5.0-pre9-test
What's Changed
- fix:
.so
build instructions out of date by @julienduchesne in #109 - fix: std.format freezes with '%g' % 0
- feat: make std.map accept strings
- feat: make std.sort/std.set/std.uniq work on arrays of arrays
- fix: do not write trailing newline in --multi for -S
- fix: restore --version argument
New Contributors
- @julienduchesne made their first contribution in #109
Full Changelog: v0.5.0-pre8-test...v0.5.0-pre9-test
v0.5.0-pre8-test
What's Changed
- Separate jrsonnet-evaluator and stdlib implementation #82 by @CertainLach in #84
- feat: add intrinsics for numeric parsing by @JarvisCraft in #89
- chore: remove int parsing functions from std.jsonnet by @JarvisCraft in #90
- feat: implement builtins for trivial numeric functions by @JarvisCraft in #91
- fix: use correct parameter names for intrinsics by @JarvisCraft in #92
- Fix: Use variable names from jsonnet stdlib for is_x builtins by @jackatbancast in #94
- Extended strings/other performance improvements by @CertainLach in #95
- feat: intrinsics for
xor
andsum
by @JarvisCraft in #100
New Contributors
- @jackatbancast made their first contribution in #94
Full Changelog: v0.5.0-pre5-test...v0.5.0-pre8-test
v0.5.0-pre5-test
Features
- Prettier empty strings display in errors
Release preparations
- Remove serde-yaml git dependency (replaced with forked and rebranded package), now jrsonnet can be published to crates.io
v0.5.0-pre4-test: build: switch to released gcmodule fork
Destructure improvements
- Support destructuring of function arguments:
local myFn({field}) = field;
myFn({field: 3}) == 3
- Object destructuring defaults
local {
a,
b = 20,
c = 30,
} = { a: 1, b: 2 };
a == 1 && b == 2 && c == 30
Release preparations
- Remove gcmodule git dependency (replaced with forked and rebranded package)
v0.5.0-pre3-test
- MacOS aarch64 build (Fixes #80)
- Throw infinite recursion error on imports, which finishes support for infinite recursion handling, as those errors are already handled in locals and objects
- Implement better object field ordering (exp-preserve-order feature)
v0.5.0-pre2-test
Destructuring support
When jrsonnet-evaluator is built with exp-destruct
(And in this pre-release - it is), syntax proposed here is supported (see last comment):
google/jsonnet#307
It was implemented as part of large optimization implementation, now locals in objects are cached not per field, but globally. I.e
{
local a = std.trace("get a", 1),
b: a,
c: a,
}
Earlier, manifestification of this object would print get a
2 times, but now it will be printed only once
v0.5.0-pre1-test
Ported new jsonnet standard library methods
std.get
, std.manifestJsonMinified
, others
importbin statement
Allows to import binary files as byte arrays
importbin 'some.bin' == [1, 2, 3, 4]
Object field order preservation
This feature was requested multiple times, both in this repo, and in other jsonnet implementations:
#76 #52
google/jsonnet#407
google/jsonnet#903
google/go-jsonnet#222
This feature is even implemented in scala jsonnet implementation, but doing this in same way will break backwards compatibility (Scala implementation has global flag for doing so)
databricks/sjsonnet#53
Implementation in jrsonnet
is opt-in, both at compile level (this feature is not built by default, as it is experimental, it is built in this prerelease though), and runtime level:
To configure CLI manifestification for this feature, you should pass --exp-preserve-order
flag:
jrsonnet --exp-preserve-order -e '{a: 1, b: 2, c: 3} + { d: 4, e: 5, a: 6 }'
For language usage there is optional argument added to manifestification functions:
std.manifestJsonEx({a: 1, b: 2, c: 3} + { d: 4, e: 5, a: 6 }, ' ', preserve_order = true)
And there is also new arguments on Rust api side to some functions
Both code snippets will yield
{ "b": 2, "c": 3, "d": 4, "e": 5, "a": 6 }
a
is last, because it was overriden later
Rust API improvements
Tons of interop api was implemented, i.e fancier builtin building stuff (this is already used for standard built-ins)
https://github.com/CertainLach/jrsonnet/blob/gcmodule/crates/jrsonnet-evaluator/src/builtin/mod.rs
And automatic generators for Rust<->Jsonnet structure translation
https://github.com/CertainLach/jrsonnet/blob/gcmodule/crates/jrsonnet-evaluator/tests/typed_obj.rs
Full Changelog: v0.5.0-gcmodule-test...v0.5.0-pre1-test
v0.5.0-gcmodule-test
Replaced rust-gc
with gcmodule
This prerelease isn't uploaded to crates.io, as it depends on git dependency (Fork of gcmodule with needed features)