This commit is contained in:
Vítor Santos Costa
2019-02-01 13:14:33 +00:00
parent ca2542c798
commit fa96ffa932
7 changed files with 710 additions and 938 deletions

View File

@@ -2854,12 +2854,12 @@ static Int undefp_handler(USES_REGS1) { /* '$undefp_handler'(P,Mod) */
pe = Yap_get_pred(Deref(ARG1), Deref(ARG2), "undefined/1");
PELOCK(59, pe);
if (EndOfPAEntr(pe)) {
UndefCode = FAILCODE;
UndefCode = Yap_get_pred(TermFail, MkIntTerm(0), "no def");
UNLOCKPE(59, pe);
return false;
}
if (pe->OpcodeOfPred == UNDEF_OPCODE) {
UndefCode = FAILCODE;
UndefCode = Yap_get_pred(TermFail, MkIntTerm(0), "no def");
UNLOCKPE(59, pe);
return false;
}