another fix to new nb_getval.

This commit is contained in:
Vitor Santos Costa 2010-03-31 15:50:36 +01:00
parent 16a5e33267
commit 3d5878f651

View File

@ -524,14 +524,13 @@ make_add_to_proof(ID2,ProbEval,O) :-
O = fast_positive_add_to_proof(ID2,ProbEval). O = fast_positive_add_to_proof(ID2,ProbEval).
make_add_to_proof(ID2,ProbEval,add_to_proof(ID2,ProbEval)). make_add_to_proof(ID2,ProbEval,add_to_proof(ID2,ProbEval)).
:- nb_setval(probclause_counter,0).
% generate next global identifier % generate next global identifier
probclause_id(ID) :- probclause_id(ID) :-
nb_getval(probclause_counter,ID), !, nb_getval(probclause_counter,ID),
C1 is ID+1, C1 is ID+1,
nb_setval(probclause_counter,C1), !. nb_setval(probclause_counter,C1).
probclause_id(0) :-
nb_setval(probclause_counter,1).
non_ground_fact_grounding_id(Goal,ID) :- non_ground_fact_grounding_id(Goal,ID) :-
( (