prevent failure in listing X

This commit is contained in:
Vítor Santos Costa 2012-11-26 09:23:25 +00:00
parent 57ac65c83b
commit 095cd68cac

View File

@ -35,7 +35,7 @@ listing(V) :-
'$listing'(V,Mod,Stream) :- var(V), !,
'$current_predicate_no_modules'(Mod,_,Pred),
'$list_clauses'(Stream,Mod,Pred).
( '$list_clauses'(Stream,Mod,Pred) ; true ).
'$listing'(M:V,_,Stream) :- !,
'$listing'(V,M,Stream).
'$listing'([],_,_) :- !.