diff options
author | das <das@FreeBSD.org> | 2004-01-18 10:32:49 +0000 |
---|---|---|
committer | das <das@FreeBSD.org> | 2004-01-18 10:32:49 +0000 |
commit | 06e5503ed1af4178cf231245d64f40244b92b43d (patch) | |
tree | 647f93d3b15dfbb2900d0c437892779fc6eba06b /lib/libc/stdio/vfprintf.c | |
parent | ccef0e945a5de71ef6a89a30b82b2398649b403a (diff) | |
download | FreeBSD-src-06e5503ed1af4178cf231245d64f40244b92b43d.zip FreeBSD-src-06e5503ed1af4178cf231245d64f40244b92b43d.tar.gz |
Implement __hdtoa() and __hldtoa() and enable printf() support for %a
and %A, which print floating-point numbers in hexadecimal.
Diffstat (limited to 'lib/libc/stdio/vfprintf.c')
-rw-r--r-- | lib/libc/stdio/vfprintf.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/libc/stdio/vfprintf.c b/lib/libc/stdio/vfprintf.c index 8d048a3..138aa22 100644 --- a/lib/libc/stdio/vfprintf.c +++ b/lib/libc/stdio/vfprintf.c @@ -66,8 +66,9 @@ __FBSDID("$FreeBSD$"); #include "local.h" #include "fvwrite.h" -/* Define FLOATING_POINT to get floating point. */ +/* Define FLOATING_POINT to get floating point, HEXFLOAT to get %a. */ #define FLOATING_POINT +#define HEXFLOAT union arg { int intarg; @@ -844,10 +845,6 @@ reswitch: switch (ch) { prec++; if (dtoaresult != NULL) freedtoa(dtoaresult); - /* - * XXX We don't actually have a conversion - * XXX routine for this yet. - */ if (flags & LONGDBL) { fparg.ldbl = GETARG(long double); dtoaresult = cp = |