mpz_{eq,lt,gt}_{ui,si}_p macros?

bodrato at mail.dm.unipi.it bodrato at mail.dm.unipi.it
Mon Feb 11 16:11:51 CET 2013


Ciao Niels,

Il Dom, 10 Febbraio 2013 10:02 pm, Niels ha scritto:
> I think this begs for yet another macro,
>
>   #define constantly_true_p(x) (__builtin_constant_p((x)) && (x))
>
> Not entirely sure if I should suggest this seriously or not...

It would be a useful shortcut. Very useful! Because it'd reduce the risk
of typos!

But gmp.h is not the right place for internal syntactic sugar, and I don't
know if there is a way to substitute macros in the gmp-h.in -> gmp.h 
transformation process.

Best regards,
m

-- 
http://bodrato.it/papers/



More information about the gmp-devel mailing list