fix unsafe test

This commit is contained in:
U-WIN-8E8REQR3Q7E\Vítor Santos Costa 2010-05-09 00:43:13 +01:00
parent 85e401bc30
commit e85d0a3939

2
C/heapgc.c Normal file → Executable file
View File

@ -1655,7 +1655,7 @@ mark_trail(tr_fr_ptr trail_ptr, tr_fr_ptr trail_base, CELL *gc_H, choiceptr gc_B
nondeterministically, I know that after backtracking it will be back to be an unbound variable.
The ideal solution would be to unbind all variables. The current solution is to
remark it as an attributed variable */
if (IsAttVar(hp) && !UNMARKED_MARK(hp-1,Yap_bp)) {
if (IN_BETWEEN(Yap_GlobalBase,hp,H) && IsAttVar(hp) && !UNMARKED_MARK(hp-1,Yap_bp)) {
total_marked++;
PUSH_POINTER(hp-1);
if (hp-1 < HGEN) {