diff --git a/C/compiler.c b/C/compiler.c index f1e2ee611..c0438667a 100644 --- a/C/compiler.c +++ b/C/compiler.c @@ -905,7 +905,7 @@ static void c_test(Int Op, Term t1, compiler_struct *cglobs) { Term t = Deref(t1); - if (!IsVarTerm(t)) { + if (!IsVarTerm(t) || IsNewVar(t)) { Term tn = MkVarTerm(); c_eq(t, tn, cglobs); t = tn;