mirror of
https://github.com/NixOS/nix
synced 2025-06-27 16:51:15 +02:00
quit repl from step mode
This commit is contained in:
parent
e761bf0601
commit
c9bc3735f6
4 changed files with 26 additions and 7 deletions
|
@ -718,6 +718,15 @@ static RegisterPrimOp primop_break({
|
|||
auto &dt = state.debugTraces.front();
|
||||
debuggerHook(&error, dt.env, dt.expr);
|
||||
|
||||
if (state.debugQuit) {
|
||||
// if the user elects to quit the repl, throw an exception.
|
||||
throw Error(ErrorInfo{
|
||||
.level = lvlInfo,
|
||||
.msg = hintfmt("quit from debugger"),
|
||||
.errPos = pos,
|
||||
});
|
||||
}
|
||||
|
||||
// returning the value we were passed.
|
||||
v = *args[0];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue