This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v2 3/9] Remove duplicated code from __printf_fp_l, __printf_fphex, and __printf_size
On Fri, 2 Jun 2017, Gabriel F. T. Gomes wrote:
> +#define PRINTF_FP_FETCH(FLOAT, VAR, SUFFIX, MANT_DIG) \
> + { \
> + VAR = *(const FLOAT *) args[0]; \
Good practice would be to use (VAR) here, as a macro argument that might
not just be a single identifier.
> +#define PRINTF_FPHEX_FETCH(FLOAT, VAR) \
> + { \
> + VAR = *(const FLOAT *) args[0]; \
Likewise.
> +#define PRINTF_SIZE_FETCH(FLOAT, VAR) \
> + { \
> + VAR = *(const FLOAT *) args[0]; \
Likewise.
> + while (VAR >= divisor && tag[1] != '\0') \
Likewise.
> + { \
> + VAR /= divisor; \
Likewise.
OK with those changes.
--
Joseph S. Myers
joseph@codesourcery.com