consult of dynamic predicates was working as reconsult
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@166 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
parent
2eb822797e
commit
c3aa27e76b
@ -16,6 +16,8 @@
|
|||||||
|
|
||||||
<h2>Yap-4.3.20:</h2>
|
<h2>Yap-4.3.20:</h2>
|
||||||
<ul>
|
<ul>
|
||||||
|
<li>FIXED: consult should not erase dynamic clauses (report
|
||||||
|
from James Cussens).</li>
|
||||||
<li>FIXED: check if we still can do garbage collection (MBIT
|
<li>FIXED: check if we still can do garbage collection (MBIT
|
||||||
and RBIT ok) (report from James Cussens).</li>
|
and RBIT ok) (report from James Cussens).</li>
|
||||||
<li>FIXED: always release stack after InitBigNum (report from
|
<li>FIXED: always release stack after InitBigNum (report from
|
||||||
|
@ -300,7 +300,7 @@ repeat :- '$repeat'.
|
|||||||
'$go_compile_clause'(G,V,5),
|
'$go_compile_clause'(G,V,5),
|
||||||
fail.
|
fail.
|
||||||
'$continue_with_command'(consult,V,G) :-
|
'$continue_with_command'(consult,V,G) :-
|
||||||
'$go_compile_clause'(G,V,5),
|
'$go_compile_clause'(G,V,13),
|
||||||
fail.
|
fail.
|
||||||
'$continue_with_command'(top,V,G) :-
|
'$continue_with_command'(top,V,G) :-
|
||||||
'$query'(G,V).
|
'$query'(G,V).
|
||||||
@ -328,7 +328,7 @@ repeat :- '$repeat'.
|
|||||||
'$check_term'(G,V) ; true ),
|
'$check_term'(G,V) ; true ),
|
||||||
'$precompile_term'(G, G0, G1).
|
'$precompile_term'(G, G0, G1).
|
||||||
|
|
||||||
% proccess an input clause
|
% process an input clause
|
||||||
'$$compile'(G,G0,L) :-
|
'$$compile'(G,G0,L) :-
|
||||||
'$head_and_body'(G,H,_),
|
'$head_and_body'(G,H,_),
|
||||||
'$inform_of_clause'(H,L),
|
'$inform_of_clause'(H,L),
|
||||||
|
@ -174,13 +174,16 @@ assertz_static(C) :-
|
|||||||
'$assertz_dynamic'(X,C,C0) :- (X/\4)=:=0, !,
|
'$assertz_dynamic'(X,C,C0) :- (X/\4)=:=0, !,
|
||||||
'$head_and_body'(C,H,B),
|
'$head_and_body'(C,H,B),
|
||||||
'$assertat_d'(last,H,B,C0,_).
|
'$assertat_d'(last,H,B,C0,_).
|
||||||
'$assertz_dynamic'(_,C,C0) :-
|
'$assertz_dynamic'(X,C,C0) :-
|
||||||
'$head_and_body'(C,H,B), functor(H,N,A),
|
'$head_and_body'(C,H,B), functor(H,N,A),
|
||||||
( '$check_if_reconsulted'(N,A) ->
|
('$check_if_reconsulted'(N,A) ->
|
||||||
true
|
true
|
||||||
;
|
;
|
||||||
|
(X/\8)=:=0 ->
|
||||||
'$inform_as_reconsulted'(N,A),
|
'$inform_as_reconsulted'(N,A),
|
||||||
'$remove_all_d_clauses'(H)
|
'$remove_all_d_clauses'(H)
|
||||||
|
;
|
||||||
|
true
|
||||||
),
|
),
|
||||||
'$assertat_d'(last,H,B,C0,_).
|
'$assertat_d'(last,H,B,C0,_).
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user