From 30e5e5d803a7245c0a5f7989d19810033a3e5147 Mon Sep 17 00:00:00 2001 From: Vitor Santos Costa Date: Mon, 25 Jan 2010 09:02:15 +0000 Subject: [PATCH] protect hooks within spy --- pl/debug.yap | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pl/debug.yap b/pl/debug.yap index 18c352791..c5cd88d35 100644 --- a/pl/debug.yap +++ b/pl/debug.yap @@ -123,21 +123,21 @@ recorded('$spy','$spy'(G,M),_), !. spy Spec :- - prolog:debug_action_hook(spy(Spec)), !. + '$notrace'(prolog:debug_action_hook(spy(Spec))), !. spy L :- '$current_module'(M), '$suspy'(L, spy, M), fail. spy _ :- debug. nospy Spec :- - prolog:debug_action_hook(nospy(Spec)), !. + '$notrace'(prolog:debug_action_hook(nospy(Spec))), !. nospy L :- '$current_module'(M), '$suspy'(L, nospy, M), fail. nospy _. nospyall :- - prolog:debug_action_hook(nospyall), !. + '$notrace'(prolog:debug_action_hook(nospyall)), !. nospyall :- recorded('$spy','$spy'(T,M),_), functor(T,F,N), '$suspy'(F/N,nospy,M), fail. nospyall.