diff options
author | Chris Lattner <sabre@nondot.org> | 2010-10-14 00:24:10 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-10-14 00:24:10 +0000 |
commit | c637415a96c16abc7e28ef83c6c105716f7e8936 (patch) | |
tree | 64e61349d7991837a310ac48a396584ae8bb3db1 | |
parent | f9e7734edef861597473f31e85f6b46347348c3b (diff) |
allow I128 suffixes in msextensions mode just like i128 suffixes, patch
by Martin Vejnar!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116460 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Lex/LiteralSupport.cpp | 2 | ||||
-rw-r--r-- | test/Lexer/ms-extensions.c | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/lib/Lex/LiteralSupport.cpp b/lib/Lex/LiteralSupport.cpp index 3b739b3d0b..2eabd7edcd 100644 --- a/lib/Lex/LiteralSupport.cpp +++ b/lib/Lex/LiteralSupport.cpp @@ -431,6 +431,7 @@ NumericLiteralParser(const char *begin, const char *end, } continue; // Success. case 'i': + case 'I': if (PP.getLangOptions().Microsoft) { if (isFPConstant || isLong || isLongLong) break; @@ -467,7 +468,6 @@ NumericLiteralParser(const char *begin, const char *end, } } // fall through. - case 'I': case 'j': case 'J': if (isImaginary) break; // Cannot be repeated. diff --git a/test/Lexer/ms-extensions.c b/test/Lexer/ms-extensions.c index 8b7d2e1efc..9cd868e8f3 100644 --- a/test/Lexer/ms-extensions.c +++ b/test/Lexer/ms-extensions.c @@ -4,6 +4,7 @@ __int8 x1 = 3i8; __int16 x2 = 4i16; __int32 x3 = 5i32; __int64 x5 = 0x42i64; +__int64 x6 = 0x42I64; __int64 x4 = 70000000i128; __int64 y = 0x42i64u; // expected-error {{invalid suffix}} |