diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-01-07 10:44:59 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-01-07 10:44:59 +0000 |
commit | 173550d4c70e5af356b669f66161bc8a6c08f1ca (patch) | |
tree | 09e466d179dd9978c2d5c6df6799a5862c668fec /gcc/testsuite/gcc.dg/format/c90-scanf-2.c | |
parent | 89e8d34f7eddb60e298cce0fd0fb870e584c606d (diff) | |
download | gcc-173550d4c70e5af356b669f66161bc8a6c08f1ca.tar.gz |
* gcc.dg/format/format.h: New file.
* gcc.dg/format/array-1.c, gcc.dg/format/attr-1.c,
gcc.dg/format/branch-1.c, gcc.dg/format/c90-printf-1.c,
gcc.dg/format/c90-printf-2.c, gcc.dg/format/c90-printf-3.c,
gcc.dg/format/c90-scanf-1.c, gcc.dg/format/c90-scanf-2.c,
gcc.dg/format/c90-scanf-3.c, gcc.dg/format/c90-scanf-4.c,
gcc.dg/format/c90-strftime-1.c, gcc.dg/format/c90-strftime-2.c,
gcc.dg/format/c94-printf-1.c, gcc.dg/format/c94-scanf-1.c,
gcc.dg/format/c99-printf-1.c, gcc.dg/format/c99-printf-2.c,
gcc.dg/format/c99-printf-3.c, gcc.dg/format/c99-scanf-1.c,
gcc.dg/format/c99-scanf-2.c, gcc.dg/format/c99-scanf-3.c,
gcc.dg/format/c99-strftime-1.c, gcc.dg/format/c99-strftime-2.c,
gcc.dg/format/diag-1.c, gcc.dg/format/errmk-1.c,
gcc.dg/format/ext-1.c, gcc.dg/format/ext-2.c,
gcc.dg/format/ext-3.c, gcc.dg/format/ext-4.c,
gcc.dg/format/ext-5.c, gcc.dg/format/miss-1.c,
gcc.dg/format/miss-2.c, gcc.dg/format/no-exargs-1.c,
gcc.dg/format/no-y2k-1.c, gcc.dg/format/nonlit-1.c,
gcc.dg/format/nonlit-2.c, gcc.dg/format/nonlit-3.c,
gcc.dg/format/sec-1.c, gcc.dg/format/strfmon-1.c,
gcc.dg/format/va-1.c, gcc.dg/format/warnll-1.c,
gcc.dg/format/xopen-1.c, gcc.dg/format/z-1.c: Include "format.h"
instead of declaring standard types, macros and functions in each
test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@38767 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/format/c90-scanf-2.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/format/c90-scanf-2.c | 28 |
1 files changed, 1 insertions, 27 deletions
diff --git a/gcc/testsuite/gcc.dg/format/c90-scanf-2.c b/gcc/testsuite/gcc.dg/format/c90-scanf-2.c index 786acdde379..52c08921ef9 100644 --- a/gcc/testsuite/gcc.dg/format/c90-scanf-2.c +++ b/gcc/testsuite/gcc.dg/format/c90-scanf-2.c @@ -5,33 +5,7 @@ /* { dg-do compile } */ /* { dg-options "-std=iso9899:1990 -pedantic -Wformat" } */ -typedef __SIZE_TYPE__ size_t; -typedef __PTRDIFF_TYPE__ ptrdiff_t; - -__extension__ typedef long long int llong; - -/* This next definition is a kludge. When GCC has a <stdint.h> it - should be used. -*/ -/* (T *) if E is zero, (void *) otherwise. */ -#define type_if_not(T, E) __typeof__(0 ? (T *)0 : (void *)(E)) - -/* (T *) if E is nonzero, (void *) otherwise. */ -#define type_if(T, E) type_if_not(T, !(E)) - -/* Combine pointer types, all but one (void *). */ -#define type_comb2(T1, T2) __typeof__(0 ? (T1)0 : (T2)0) -#define type_comb3(T1, T2, T3) type_comb2(T1, type_comb2(T2, T3)) - -#define maybe_int_ptr type_if(int, sizeof(int) == sizeof(llong)) -#define maybe_long_ptr type_if(long, sizeof(long) == sizeof(llong) && sizeof(long) > sizeof(int)) -#define maybe_long_long_ptr type_if(llong, sizeof(llong) > sizeof(long)) - -#define intmax_type_ptr type_comb3(maybe_int_ptr, maybe_long_ptr, maybe_long_long_ptr) - -typedef __typeof__(*((intmax_type_ptr)0)) intmax_t; - -extern int scanf (const char *, ...); +#include "format.h" void foo (signed char *hhp, float *fp, llong *llp, intmax_t *jp, |