FLINT3.7.0-dev

FLINT_SGN, FLINT_SIGN_EXT

Synopsis#include <flint/flint.h>
FLINT_SGN(x)source
FLINT_SIGN_EXT(x)source

FLINT_SGN(x) is -1, 0 or 1 according to the sign of x interpreted as an slong. FLINT_SIGN_EXT(x) is the ulong with all bits equal to the sign bit of x: UWORD_MAX if x is negative and 0 otherwise.

Cite this page

The FLINT team, “FLINT_SGN, FLINT_SIGN_EXT (flint.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/flint/FLINT_SGN.html (generated 2026-10-20).