diff options
| author | Daniel Dunbar <daniel@zuster.org> | 2008-07-25 18:41:57 +0000 |
|---|---|---|
| committer | Daniel Dunbar <daniel@zuster.org> | 2008-07-25 18:41:57 +0000 |
| commit | c481f72857ded28e7e4b06e0ecc6ea61d5a07aeb (patch) | |
| tree | 1f4441e11cddbb70864d904dbd401cd34d5fa153 /clang/test | |
| parent | c94ad4abcb928049ffb8010ae0b9215af77190b1 (diff) | |
| download | bcm5719-llvm-c481f72857ded28e7e4b06e0ecc6ea61d5a07aeb.tar.gz bcm5719-llvm-c481f72857ded28e7e4b06e0ecc6ea61d5a07aeb.zip | |
Add test case for hex floating point constants in < C99 mode
- For: rdar://6096838
llvm-svn: 54036
Diffstat (limited to 'clang/test')
| -rw-r--r-- | clang/test/Lexer/rdr-6096838.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/clang/test/Lexer/rdr-6096838.c b/clang/test/Lexer/rdr-6096838.c new file mode 100644 index 00000000000..1b56a910db7 --- /dev/null +++ b/clang/test/Lexer/rdr-6096838.c @@ -0,0 +1,14 @@ +/* RUN: clang -fsyntax-only -verify %s && + * RUN: clang -std=gnu89 -fsyntax-only -verify %s && + * RUN: clang -DPEDANTIC -pedantic -std=gnu89 -fsyntax-only -verify %s + */ + +#ifdef PEDANTIC + +long double d = 0x0.0000003ffffffff00000p-16357L; /* expected-warning {{ hexadecimal floating constants are a C99 feature }} */ + +#else + +long double d = 0x0.0000003ffffffff00000p-16357L; + +#endif |

