don't try to do module expansion if module borders are not crossed.

expand on-line depth_call and once.
improve write_x_loc


git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@752 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc
2003-01-30 16:27:45 +00:00
parent 1369dfa410
commit f5dad3ac1f
7 changed files with 88 additions and 36 deletions

View File

@@ -262,7 +262,7 @@ do_execute(Term t, SMALLUNSGN mod)
YENV[-EnvSizeInCells-2] = MkIntegerTerm((Int)PredPropByFunc(f,mod));
}
} else {
return CallMetaCall(mod);
return CallMetaCall(mod);
}
YENV[E_CP] = (CELL)P;
YENV[E_CB] = (CELL)B;
@@ -277,9 +277,10 @@ do_execute(Term t, SMALLUNSGN mod)
P = NEXTOP(COMMA_CODE,sla);
t = ArgOfTerm(1,t);
goto restart_exec;
}
} else if (mod != CurrentModule) {
return(CallMetaCall(mod));
}
}
/* now let us do what we wanted to do from the beginning !! */
/* I cannot use the standard macro here because
otherwise I would dereference the argument and
@@ -384,7 +385,8 @@ p_execute_within(void)
goto restart_exec;
}
}
return(CallMetaCallWithin(mod, B));
if (mod != CurrentModule)
return(CallMetaCallWithin(mod, B));
}
/* at this point check if we should enter creep mode */
if (yap_flags[SPY_CREEP_FLAG]) {
@@ -1733,7 +1735,7 @@ Yap_InitExecFs(void)
Yap_InitCPred("$call_with_args", 11, p_execute_9, 0);
Yap_InitCPred("$call_with_args", 12, p_execute_10, 0);
#ifdef DEPTH_LIMIT
Yap_InitCPred("$execute_under_depth_limit", 2, p_execute_depth_limit, 0);
Yap_InitCPred("depth_bound_call", 2, p_execute_depth_limit, 0);
#endif
Yap_InitCPred("$execute0", 2, p_execute0, 0);
Yap_InitCPred("$save_current_choice_point", 1, p_save_cp, 0);