summaryrefslogtreecommitdiff
path: root/libc/stdio/scanf.c
diff options
context:
space:
mode:
authorManuel Novoa III <mjn3@codepoet.org>2001-03-19 17:45:44 +0000
committerManuel Novoa III <mjn3@codepoet.org>2001-03-19 17:45:44 +0000
commit9ae054b3553801ed1e7b3532fe929abb36a0cf3d (patch)
treef5e5a639dc361882044cfdeb89d2ec43b202b72a /libc/stdio/scanf.c
parent3a1407ff3bb4e1fc448dfe5325caaeb891eb5411 (diff)
Since Erik apparently wants def/undef vs def 1/0...
Diffstat (limited to 'libc/stdio/scanf.c')
-rw-r--r--libc/stdio/scanf.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/libc/stdio/scanf.c b/libc/stdio/scanf.c
index 6fd802c73..0f1843a4d 100644
--- a/libc/stdio/scanf.c
+++ b/libc/stdio/scanf.c
@@ -143,7 +143,7 @@ struct scan_cookie {
int ungot_flag;
};
-#if __UCLIBC_HAS_LONG_LONG__
+#ifdef __UCLIBC_HAS_LONG_LONG__
static const char qual[] = "hl" /* "jtz" */ "Lq";
/* char = -2, short = -1, int = 0, long = 1, long long = 2 */
static const char qsz[] = { -1, 1, 2, 2 };
@@ -152,7 +152,7 @@ static const char qual[] = "hl" /* "jtz" */;
static const char qsz[] = { -1, 1, };
#endif
-#if __UCLIBC_HAS_FLOATS__
+#ifdef __UCLIBC_HAS_FLOATS__
static int __strtold(long double *ld, struct scan_cookie *sc);
/*01234567890123456 */
static const char spec[] = "%n[csoupxXidfeEgG";
@@ -225,7 +225,7 @@ FILE *fp;
const char *format;
va_list ap;
{
-#if __UCLIBC_HAS_LONG_LONG__
+#ifdef __UCLIBC_HAS_LONG_LONG__
#define STRTO_L_(s,e,b,u) _strto_ll(s,e,b,u)
#define MAX_DIGITS 64
#define UV_TYPE unsigned long long
@@ -236,7 +236,7 @@ va_list ap;
#define UV_TYPE unsigned long
#define V_TYPE long
#endif
-#if __UCLIBC_HAS_FLOATS__
+#ifdef __UCLIBC_HAS_FLOATS__
long double ld;
#endif
UV_TYPE uv;
@@ -426,7 +426,7 @@ va_list ap;
vp = va_arg(ap, void *);
switch (lval) {
case 2: /* If no long long, treat as long . */
-#if __UCLIBC_HAS_LONG_LONG__
+#ifdef __UCLIBC_HAS_LONG_LONG__
*((unsigned long long *)vp) = uv;
break;
#endif
@@ -434,7 +434,7 @@ va_list ap;
#if ULONG_MAX == UINT_MAX
case 0: /* int and long int are the same */
#endif
-#if __UCLIBC_HAS_LONG_LONG__
+#ifdef __UCLIBC_HAS_LONG_LONG__
if (usflag) {
if (uv > ULONG_MAX) {
uv = ULONG_MAX;
@@ -492,7 +492,7 @@ va_list ap;
}
goto nextfmt;
}
-#if __UCLIBC_HAS_FLOATS__
+#ifdef __UCLIBC_HAS_FLOATS__
else { /* floating point */
if (sc.width <= 0) {
goto done;
@@ -552,7 +552,7 @@ va_list ap;
}
/*****************************************************************************/
-#if __UCLIBC_HAS_FLOATS__
+#ifdef __UCLIBC_HAS_FLOATS__
#include <float.h>