unused macro MPN_PTR_SWAP in mini-gmp.c

Hans Åberg haberg-1 at telia.com
Thu Mar 17 18:51:02 CET 2022

> On 9 Mar 2022, at 02:56, Paul Eggert <eggert at CS.UCLA.EDU> wrote:
> In libgmp 6.2.1, mini-gmp.c defines a macro without using it, causing the command "gcc -Wunused-macros -Werror" to fail with the following diagnostic:
> lib/mini-gmp.c:251: warning: macro "MPN_PTR_SWAP" is not used [-Wunused-macros]
>  251 | #define MPN_PTR_SWAP(xp,xs, yp,ys)         \
>      |

They might possibly be used in the C++ library, which uses swaps for the move operators, and if so, would break.

More information about the gmp-bugs mailing list