opaques are not integers
This commit is contained in:
parent
5b6a3bffc1
commit
72fe7e84c0
40
C/absmi.c
40
C/absmi.c
@ -9050,8 +9050,14 @@ Yap_absmi(int inp)
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
case (CELL)FunctorLongInt:
|
|
||||||
case (CELL)FunctorBigInt:
|
case (CELL)FunctorBigInt:
|
||||||
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
PREG = PREG->u.xl.F;
|
||||||
|
GONext();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case (CELL)FunctorLongInt:
|
||||||
PREG = NEXTOP(PREG, xl);
|
PREG = NEXTOP(PREG, xl);
|
||||||
GONext();
|
GONext();
|
||||||
default:
|
default:
|
||||||
@ -9087,10 +9093,14 @@ Yap_absmi(int inp)
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
case (CELL)FunctorLongInt:
|
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
case (CELL)FunctorBigInt:
|
||||||
#endif
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
PREG = PREG->u.yl.F;
|
||||||
|
GONext();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case (CELL)FunctorLongInt:
|
||||||
PREG = NEXTOP(PREG, yl);
|
PREG = NEXTOP(PREG, yl);
|
||||||
GONext();
|
GONext();
|
||||||
default:
|
default:
|
||||||
@ -9156,11 +9166,15 @@ Yap_absmi(int inp)
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
|
case (CELL)FunctorBigInt:
|
||||||
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
PREG = PREG->u.xl.F;
|
||||||
|
GONext();
|
||||||
|
}
|
||||||
|
}
|
||||||
case (CELL)FunctorLongInt:
|
case (CELL)FunctorLongInt:
|
||||||
case (CELL)FunctorDouble:
|
case (CELL)FunctorDouble:
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
|
||||||
#endif
|
|
||||||
PREG = NEXTOP(PREG, xl);
|
PREG = NEXTOP(PREG, xl);
|
||||||
GONext();
|
GONext();
|
||||||
default:
|
default:
|
||||||
@ -9197,11 +9211,15 @@ Yap_absmi(int inp)
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
|
case (CELL)FunctorBigInt:
|
||||||
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
PREG = PREG->u.yl.F;
|
||||||
|
GONext();
|
||||||
|
}
|
||||||
|
}
|
||||||
case (CELL)FunctorLongInt:
|
case (CELL)FunctorLongInt:
|
||||||
case (CELL)FunctorDouble:
|
case (CELL)FunctorDouble:
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
|
||||||
#endif
|
|
||||||
PREG = NEXTOP(PREG, yl);
|
PREG = NEXTOP(PREG, yl);
|
||||||
GONext();
|
GONext();
|
||||||
default:
|
default:
|
||||||
@ -9210,7 +9228,7 @@ Yap_absmi(int inp)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
PREG = PREG->u.xl.F;
|
PREG = PREG->u.yl.F;
|
||||||
GONext();
|
GONext();
|
||||||
|
|
||||||
derefa_body(d0, pt0, number_y_unk, number_y_nvar);
|
derefa_body(d0, pt0, number_y_unk, number_y_nvar);
|
||||||
|
18
C/inlines.c
18
C/inlines.c
@ -96,10 +96,13 @@ p_integer( USES_REGS1 )
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
case (CELL)FunctorLongInt:
|
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
case (CELL)FunctorBigInt:
|
||||||
#endif
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case (CELL)FunctorLongInt:
|
||||||
return(TRUE);
|
return(TRUE);
|
||||||
default:
|
default:
|
||||||
return(FALSE);
|
return(FALSE);
|
||||||
@ -131,11 +134,14 @@ p_number( USES_REGS1 )
|
|||||||
Functor f0 = FunctorOfTerm(d0);
|
Functor f0 = FunctorOfTerm(d0);
|
||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
|
case (CELL)FunctorBigInt:
|
||||||
|
{ CELL *pt = RepAppl(d0);
|
||||||
|
if ( pt[1] != BIG_RATIONAL || pt[1] != BIG_INT ) {
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
}
|
||||||
case (CELL)FunctorLongInt:
|
case (CELL)FunctorLongInt:
|
||||||
case (CELL)FunctorDouble:
|
case (CELL)FunctorDouble:
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
|
||||||
#endif
|
|
||||||
return(TRUE);
|
return(TRUE);
|
||||||
default:
|
default:
|
||||||
return(FALSE);
|
return(FALSE);
|
||||||
|
Reference in New Issue
Block a user