_decfloat_round_with_tail
Synopsis
#include <flint/decimal.h>int _decfloat_round_with_tail(decfloat_t res, const decfloat_t S, int tail_sign, slong tail_exp, slong prec, int rnd, gr_ctx_t ctx)sourceRound S + t to prec digits, where S is an exact nonzero finite decfloat and t a nonzero real number of sign tail_sign with |t| < 10^{\mathit{tail\_exp}}. Return 1 if tail_exp lies at least prec + 4e digits below the leading digit of S, so that t only acts as a sticky bit; 0 if this precondition fails, and -1 on an error (exponent limits). This implements the handling of tiny arguments of the elementary and special functions.
Cite this page
The FLINT team, “_decfloat_round_with_tail (decimal.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/decimal/_decfloat_round_with_tail.html (generated 2026-10-20).
@misc{flint-doc-decimal-decfloat-round-with-tail,
author = {{The FLINT team}},
title = {{\_decfloat\_round\_with\_tail (decimal.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/decimal/_decfloat_round_with_tail.html},
note = {Generated 2026-10-20}
}