On Sun, Jan 10, 2010 at 3:37 PM, Sean Hunt <[email protected]> wrote:
> Author: coppro
> Date: Sun Jan 10 17:37:56 2010
> New Revision: 93135
>
> URL: http://llvm.org/viewvc/llvm-project?rev=93135&view=rev
> Log:
> Do not parse hexadecimal floating point literals in C++0x mode because they
> are
> incompatible with user-defined literals, specifically with the following form:
>
> 0x1p+1
Wow, that is seriously nasty... we should see if it's possible to fix
the standard here.
> --- cfe/trunk/test/Lexer/hexfloat.cpp (added)
> +++ cfe/trunk/test/Lexer/hexfloat.cpp Sun Jan 10 17:37:56 2010
> @@ -0,0 +1,8 @@
> +//RUN: %clang_cc1 -fsyntax-only -verify
> +//RUN: %clang_cc1 -std=c++0x -fsyntax-only -verify
> +
> +#ifndef __GXX_EXPERIMENTAL_CXX0X__
> +float f = 0x1p+1; // expected-warning {{incompatible with C++0x}}
> +#else
> +float f = 0x1p+1; // expected-warning {{invalid suffix}}
> +#endif
Because you forgot to put %s in the runlines, this test doesn't actually run.
-Eli
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits