cleanup: typecast to yamop * instead of CODEADDR wherever possible.
Fix integer(233333833838383) fails bug (Roberto Bagnara). git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@733 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
@@ -401,12 +401,12 @@ Yap_NewPredPropByFunctor(FunctorEntry *fe, SMALLUNSGN cur_mod)
|
||||
INIT_RWLOCK(p->PRWLock);
|
||||
p->KindOfPE = PEProp;
|
||||
p->ArityOfPE = fe->ArityOfFE;
|
||||
p->FirstClause = p->LastClause = NIL;
|
||||
p->cs.p_code.FirstClause = p->cs.p_code.LastClause = NULL;
|
||||
p->PredFlags = 0L;
|
||||
p->StateOfPred = 0;
|
||||
p->OwnerFile = AtomNil;
|
||||
p->OpcodeOfPred = UNDEF_OPCODE;
|
||||
p->TrueCodeOfPred = p->CodeOfPred = (CODEADDR)(&(p->OpcodeOfPred));
|
||||
p->CodeOfPred = p->cs.p_code.TrueCodeOfPred = (yamop *)(&(p->OpcodeOfPred));
|
||||
p->ModuleOfPred = cur_mod;
|
||||
p->NextPredOfModule = ModulePred[cur_mod];
|
||||
ModulePred[cur_mod] = p;
|
||||
@@ -436,12 +436,12 @@ Yap_NewPredPropByAtom(AtomEntry *ae, SMALLUNSGN cur_mod)
|
||||
INIT_RWLOCK(p->PRWLock);
|
||||
p->KindOfPE = PEProp;
|
||||
p->ArityOfPE = 0;
|
||||
p->FirstClause = p->LastClause = NIL;
|
||||
p->cs.p_code.FirstClause = p->cs.p_code.LastClause = NULL;
|
||||
p->PredFlags = 0L;
|
||||
p->StateOfPred = 0;
|
||||
p->OwnerFile = AtomNil;
|
||||
p->OpcodeOfPred = UNDEF_OPCODE;
|
||||
p->TrueCodeOfPred = p->CodeOfPred = (CODEADDR)(&(p->OpcodeOfPred));
|
||||
p->CodeOfPred = p->cs.p_code.TrueCodeOfPred = (yamop *)(&(p->OpcodeOfPred));
|
||||
p->ModuleOfPred = cur_mod;
|
||||
p->NextPredOfModule = ModulePred[cur_mod];
|
||||
ModulePred[cur_mod] = p;
|
||||
|
Reference in New Issue
Block a user