make sure $pred_exists does not create new pred prop.
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@908 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
parent
77bb5fed93
commit
614bdd981f
@ -460,7 +460,9 @@ Yap_NewPredPropByFunctor(FunctorEntry *fe, SMALLUNSGN cur_mod)
|
||||
Prop p0;
|
||||
PredEntry *p = (PredEntry *) Yap_AllocAtomSpace(sizeof(*p));
|
||||
|
||||
/* printf("entering %s:%s/%d\n", RepAtom(AtomOfTerm(ModuleName[cur_mod]))->StrOfAE, RepAtom(fe->NameOfFE)->StrOfAE, fe->ArityOfFE); */
|
||||
extern long long int vsc_count;
|
||||
if (p == 0x9183b68) printf("%lld entering %s:%s/%d\n", vsc_count,
|
||||
RepAtom(AtomOfTerm(ModuleName[cur_mod]))->StrOfAE, RepAtom(fe->NameOfFE)->StrOfAE, fe->ArityOfFE);
|
||||
|
||||
INIT_RWLOCK(p->PRWLock);
|
||||
p->KindOfPE = PEProp;
|
||||
|
@ -1885,10 +1885,10 @@ p_pred_exists(void)
|
||||
return (FALSE);
|
||||
} else if (IsAtomTerm(t)) {
|
||||
Atom at = AtomOfTerm(t);
|
||||
pe = RepPredProp(PredPropByAtom(at, mod));
|
||||
pe = RepPredProp(Yap_GetPredPropByAtom(at, mod));
|
||||
} else if (IsApplTerm(t)) {
|
||||
Functor fun = FunctorOfTerm(t);
|
||||
pe = RepPredProp(PredPropByFunc(fun, mod));
|
||||
pe = RepPredProp(Yap_GetPredPropByFunc(fun, mod));
|
||||
} else
|
||||
return (FALSE);
|
||||
if (pe == NIL)
|
||||
|
Reference in New Issue
Block a user