throw '' whenever an interrupt is made (#365, #366)

This commit is contained in:
Mark Thom
2020-04-19 12:58:44 -06:00
parent 3798dcb98d
commit 5d6ca7a88e
4 changed files with 26 additions and 4 deletions

View File

@@ -214,6 +214,9 @@ gather_goals([Var = Value | Pairs], VarList, Goals) :-
).
print_exception(E) :-
( E == error('$interrupt_thrown', repl) -> nl % print the exception on a newline to evade "^C".
; true
),
write_term('caught: ', [quoted(false), max_depth(20)]),
writeq(E),
nl.