fix module_property, ignoring modules that are not actually implemented as files.

This commit is contained in:
Vítor Santos Costa
2016-03-05 23:18:57 +00:00
parent 23d18ac0fd
commit 79d99a7768
2 changed files with 28 additions and 30 deletions

View File

@@ -863,26 +863,13 @@ static Int cont_current_predicate(USES_REGS1) {
pp = firstModulePred(m->PredForME, task);
if (!pp) {
/* try Prolog Module */
if (task != TermUser) {
ModEntry *m = Yap_GetModuleEntry(TermProlog);
pp = firstModulePred(m->PredForME, task);
if (!pp) {
cut_fail();
}
}
cut_fail();
}
}
npp = firstModulePred(pp, task);
if (!npp) {
if (pp->ModuleOfPred != PROLOG_MODULE && task != TermUser) {
ModEntry *m = Yap_GetModuleEntry(TermProlog);
npp = firstModulePred(m->PredForME, task);
if (!npp)
will_cut = true;
} else {
will_cut = true;
}
will_cut = true;
}
// just try next one
else {