diff options
author | Florian Klink <flokli@flokli.de> | 2024-01-16T13·35+0200 |
---|---|---|
committer | flokli <flokli@flokli.de> | 2024-01-18T14·24+0000 |
commit | 43b9e25025eef302369ff27074bfa5bbfb1c7115 (patch) | |
tree | 7bd8dd0c86ac8313edbbde9e4a702ba0d1cf17d9 /tvix/eval/tests/nix_oracle.rs | |
parent | ea03ff374b1d93985e2f77a13ad8bd9e070a5608 (diff) |
refactor(tvix/eval): move Evaluation::{default,new_pure}() again r/7409
Have a Evaluation::new() function that's used to set up the Evaluation struct initially - which is also used by both new_pure and new_impure internally. It's generic over the exact type of IO, making it easier to instantiate Evaluation with non-tvix-eval EvalIO implementations, that might not be in a Box. Change-Id: Ibf728da24aca59639c5b6df58d00ae98c99a63f5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10640 Reviewed-by: raitobezarius <tvl@lahfa.xyz> Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/eval/tests/nix_oracle.rs')
-rw-r--r-- | tvix/eval/tests/nix_oracle.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tvix/eval/tests/nix_oracle.rs b/tvix/eval/tests/nix_oracle.rs index 670926d9c8e4..6bab75cfd979 100644 --- a/tvix/eval/tests/nix_oracle.rs +++ b/tvix/eval/tests/nix_oracle.rs @@ -51,7 +51,7 @@ fn nix_eval(expr: &str, strictness: Strictness) -> String { #[track_caller] fn compare_eval(expr: &str, strictness: Strictness) { let nix_result = nix_eval(expr, strictness); - let mut eval = tvix_eval::Evaluation::default(); + let mut eval = tvix_eval::Evaluation::new_pure(); eval.strict = matches!(strictness, Strictness::Strict); eval.io_handle = Box::new(tvix_eval::StdIO); |