libexpr: fix --debugger --ignore-try
a65e9e5828did not inform `tryEval` that (as far as it's concerned) `state.debug` moved to `state.errors.debug` and changed types. this resulted in the REPL erroneously coming up, that REPL having a non-debug state, and segfaulting after that REPL exited. it's probably good that `state.debug` isn't mutated by `--ignore-try` anymore. Change-Id: I1918e93edacd626452aa423fc2eb825080738835 Fixes:a65e9e5828("libexpr: extract eval error creation into new type") Signed-off-by: Dusk Banks <me@bb010g.com> (cherry picked from commit6a583136b7)
This commit is contained in:
committed by
eldritch horrors
parent
d2b1af70ee
commit
5fa27057b2
@@ -0,0 +1,8 @@
|
||||
@args --debugger --ignore-try
|
||||
|
||||
we don't enter a debug repl through tryEval
|
||||
nix-repl> (builtins.tryEval ((x: throw "foo") 1)).success
|
||||
false
|
||||
|
||||
no segfault either
|
||||
nix-repl> :quit
|
||||
@@ -187,5 +187,6 @@ REPL_TEST(stack_vars);
|
||||
REPL_TEST(errors);
|
||||
REPL_TEST(idempotent);
|
||||
REPL_TEST(debug_frames);
|
||||
REPL_TEST(debug_ignore_try);
|
||||
|
||||
}; // namespace nix
|
||||
|
||||
Reference in New Issue
Block a user