tvl-depot/tvix/eval/src
Vincent Ambo 939cebd0f1 fix(tvix/eval): implement cppnix JSON-serialisation semantics
This drops the usage of serde::Serialize, as the trait can not be used
to implement the correct semantics (function colouring!).

Instead, a manual JSON serialisation function is written which
correctly handles toString, outPath and other similar weirdnesses.

Unexpectedly, the eval-okay-tojson test from the C++ Nix test suite
now passes, too.

This fixes an issue where serialising data structures containing
derivations to JSON would fail.

Change-Id: I5c39e3d8356ee93a07eda481410f88610f6dd9f8
Reviewed-on: https://cl.tvl.fyi/c/depot/+/8209
Reviewed-by: raitobezarius <tvl@lahfa.xyz>
Tested-by: BuildkiteCI
2023-03-13 20:30:59 +00:00
..
builtins fix(tvix/eval): implement cppnix JSON-serialisation semantics 2023-03-13 20:30:59 +00:00
compiler fix(tvix/eval): correctly thunk deferred formals access 2023-03-13 20:30:59 +00:00
tests fix(tvix/eval): implement cppnix JSON-serialisation semantics 2023-03-13 20:30:59 +00:00
value fix(tvix/eval): implement cppnix JSON-serialisation semantics 2023-03-13 20:30:59 +00:00
vm fix(tvix/eval): implement cppnix JSON-serialisation semantics 2023-03-13 20:30:59 +00:00
chunk.rs refactor(tvix/eval): enhance debug output for bytecode dumps 2023-03-03 10:52:48 +00:00
errors.rs fix(tvix/eval): implement cppnix JSON-serialisation semantics 2023-03-13 20:30:59 +00:00
io.rs chore(tvix/eval): only use Rc with impure feature 2023-02-03 18:58:17 +00:00
lib.rs refactor(tvix/eval): flatten call stack of VM using generators 2023-03-13 20:30:59 +00:00
nix_search_path.rs fix(tvix/eval): fix current clippy warnings 2022-12-25 18:25:06 +00:00
observer.rs feat(tvix/eval): give generators human-readable names 2023-03-13 20:30:59 +00:00
opcode.rs refactor(tvix/eval): flatten call stack of VM using generators 2023-03-13 20:30:59 +00:00
pretty_ast.rs fix(tvix/eval): fix current clippy warnings 2022-12-25 18:25:06 +00:00
properties.rs refactor(tvix/eval): Don't (ab)use PartialEq for Nix equality 2022-09-18 22:03:41 +00:00
source.rs chore(tvix/eval): implement std::error::Error for tvix_eval::Error 2023-01-02 22:24:43 +00:00
spans.rs refactor(tvix/eval): implement From<Span> for LightSpan 2023-03-04 15:18:37 +00:00
systems.rs fix(tvix/eval): fix current clippy warnings 2022-12-25 18:25:06 +00:00
test_utils.rs test(tvix/eval): Add proof-of-concept test for Chunk 2022-09-18 17:55:06 +00:00
upvalues.rs fix(tvix/eval): remove impl PartialEq for Value 2022-11-04 00:30:13 +00:00
warnings.rs chore(tvix/eval): delete "useless parenthesis" warning/optimisation 2023-01-23 17:59:06 +00:00