/* -*-c-*-
*
- * $Id: prim.c,v 1.2 2000/07/29 09:57:42 mdw Exp $
+ * $Id: prim.c,v 1.3 2000/10/08 12:11:22 mdw Exp $
*
* Finding primitive elements
*
/*----- Revision history --------------------------------------------------*
*
* $Log: prim.c,v $
+ * Revision 1.3 2000/10/08 12:11:22 mdw
+ * Use @MP_EQ@ instead of @MP_CMP@.
+ *
* Revision 1.2 2000/07/29 09:57:42 mdw
* Improve primitive-element testing a lot. Now much more sensible and
* orthogonal: you can find a generator for any given subgroup order by
x = mp_copy(ev->m);
else {
x = mpmont_exp(&c->mm, MP_NEW, ev->m, c->exp);
- if (MP_CMP(x, ==, MP_ONE))
+ if (MP_EQ(x, MP_ONE))
goto done;
}
if (c->n == 0)
mp *y = MP_NEW;
while (n) {
y = mpmont_exp(&c->mm, y, x, *f);
- if (MP_CMP(y, ==, MP_ONE)) {
+ if (MP_EQ(y, MP_ONE)) {
mp_drop(y);
goto done;
}