diff --git a/C/cmppreds.c b/C/cmppreds.c index c37a83f40..757c64329 100644 --- a/C/cmppreds.c +++ b/C/cmppreds.c @@ -567,6 +567,8 @@ a_cmp(Term t1, Term t2) #ifdef USE_GMP } else if (IsBigIntTerm(t1)) { { + t2 = Yap_Eval(t2); + if (IsIntegerTerm(t2)) { return Yap_gmp_cmp_big_int(t1, IntegerOfTerm(t2)); } else if (IsFloatTerm(t2)) {