diff options
Diffstat (limited to 'neg.c')
-rw-r--r-- | neg.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -0,0 +1,13 @@ +#include "gmp.h" +#include "gmp-impl.h" +#include "mpfr.h" + +void mpfr_neg(mpfr_t a, mpfr_t b, unsigned char rnd_mode) +{ + CHANGE_SIGN(b); + if (a != b) { + mpfr_set(a, b, rnd_mode); + CHANGE_SIGN(b); + } + return; +} |