diff options
author | Roland McGrath <roland@gnu.org> | 1995-11-20 03:48:11 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1995-11-20 03:48:11 +0000 |
commit | 96aa2d94a2355cdc55c96e808d14a0e7f2ebe77d (patch) | |
tree | f7c87e6742af0707b858a1387ca85b679aa8d13e /stdio-common/printf_fp.c | |
parent | a5a81fecc7194d050066265a15b1ba8bc3abc627 (diff) | |
download | glibc-96aa2d94a2355cdc55c96e808d14a0e7f2ebe77d.tar.gz glibc-96aa2d94a2355cdc55c96e808d14a0e7f2ebe77d.tar.xz glibc-96aa2d94a2355cdc55c96e808d14a0e7f2ebe77d.zip |
Sat Nov 18 16:46:01 1995 Ulrich Drepper <drepper@gnu.ai.mit.edu>
* libio/Makefile, libio/cleanup.c, libio/clearerr.c, libio/feof.c, libio/ferror.c, libio/fgetc.c, libio/filedoalloc.c, libio/fileno.c, libio/fileops.c, libio/fputc.c, libio/freopen.c, libio/fseek.c, libio/genops.c, libio/getc.c, libio/getchar.c, libio/iofclose.c, libio/iofdopen.c, libio/iofflush.c, libio/iofgetpos.c, libio/iofgets.c, libio/iofopen.c, libio/iofprintf.c, libio/iofputs.c, libio/iofread.c, libio/iofscanf.c, libio/iofsetpos.c, libio/ioftell.c, libio/iofwrite.c, libio/iogetdelim.c, libio/iogetline.c, libio/iogets.c, libio/iolibio.h, libio/iopadn.c, libio/ioprims.c, libio/ioputs.c, libio/ioseekoff.c, libio/ioseekpos.c, libio/iosetbuffer.c, libio/iosetvbuf.c, libio/iosprintf.c, libio/ioungetc.c, libio/iovsprintf.c, libio/iovsscanf.c, libio/libio.h, libio/libioP.h, libio/putc.c, libio/putchar.c, libio/rewind.c, libio/setbuf.c, libio/setlinebuf.c, libio/stdfiles.c, libio/stdio.c, libio/stdio.h, libio/strfile.h, libio/strops.c, libio/vasprintf.c, libio/vscanf.c, libio/vsnprintf.c: New files. Slightly modified version from Linux libc. * libio/memstream.c, libio/vdprintf.c: New files for functions not (yet) part of GNU libio. * libio/iofopncook.c: Implementation of `fopencookie', mainly written by Per Bothner. * stdio-common/getline.c: Adapted to libio. * stdio-common/snprintf.c: Adapted to libio. * stdio-common/vfprintf.c: Adapted to libio. * stdio-common/vfscanf.c: Adapted to libio. * sysdeps/posix/tempname.c: Adapted to libio.
Diffstat (limited to 'stdio-common/printf_fp.c')
-rw-r--r-- | stdio-common/printf_fp.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/stdio-common/printf_fp.c b/stdio-common/printf_fp.c index 28d13d61b8..31c009e891 100644 --- a/stdio-common/printf_fp.c +++ b/stdio-common/printf_fp.c @@ -269,7 +269,7 @@ __printf_fp (fp, info, args) { fracsize = __mpn_extract_long_double (fp_input, (sizeof (fp_input) / - sizeof (fp_input[0])), + sizeof (fp_input[0])), &exponent, &is_neg, fpnum.ldbl); to_shift = 1 + fracsize * BITS_PER_MP_LIMB - LDBL_MANT_DIG; @@ -496,7 +496,7 @@ __printf_fp (fp, info, args) /* Now shift the input value to its right place. */ cy = __mpn_lshift (frac, fp_input, fracsize, to_shift); - frac[fracsize++] = cy; + frac[fracsize++] = cy; assert (cy == 1 || (frac[fracsize - 2] == 0 && frac[0] == 0)); expsign = 1; @@ -524,7 +524,7 @@ __printf_fp (fp, info, args) if (cy == 0) --tmpsize; - count_leading_zeros (cnt_h, tmp[tmpsize - 1]); + count_leading_zeros (cnt_h, tmp[tmpsize - 1]); incr = (tmpsize - fracsize) * BITS_PER_MP_LIMB + BITS_PER_MP_LIMB - 1 - cnt_h; @@ -559,7 +559,7 @@ __printf_fp (fp, info, args) && tmp[tmpsize - 2] < topval[0])))) { /* The factor is right. Adapt binary and decimal - exponents. */ + exponents. */ exponent -= incr; exp10 |= 1 << explog; @@ -639,7 +639,7 @@ __printf_fp (fp, info, args) /* Now shift the input value to its right place. */ cy = __mpn_lshift (frac, fp_input, fracsize, (exponent + to_shift)); - frac[fracsize++] = cy; + frac[fracsize++] = cy; exponent = 0; } @@ -714,7 +714,7 @@ __printf_fp (fp, info, args) it is possible that we need two more characters in front of all the other output. */ buffer = alloca (2 + chars_needed); - cp = startp = buffer + 2; /* Let room for rounding. */ + cp = startp = buffer + 2; /* Let room for rounding. */ /* Do the real work: put digits in allocated buffer. */ if (expsign == 0 || type != 'f') @@ -886,7 +886,7 @@ __printf_fp (fp, info, args) } /* Compute number of characters which must be filled with the padding - character. */ + character. */ if (is_neg || info->showsign || info->space) --width; width -= cp - startp; |