undef should not fail immediately: it needs to test for exports first

This commit is contained in:
Vitor Santos Costa
2016-05-12 11:42:22 +01:00
parent e92062886b
commit c5323b2920
3 changed files with 10 additions and 8 deletions

View File

@@ -888,10 +888,7 @@ static int interrupt_dexecute(USES_REGS1) {
static void undef_goal(USES_REGS1) {
PredEntry *pe = PredFromDefCode(P);
if (Yap_UnknownFlag(CurrentModule) == TermFail) {
P = FAILCODE;
return;
}
BEGD(d0);
/* avoid trouble with undefined dynamic procedures */
/* I assume they were not locked beforehand */