llvm-project/clang/lib/Lex
Leonard Chan e5597ad9f3 [Fixed Point Arithmetic] Fix for bug where integer literals could be treated as fixed point literals
This addresses a bug brought up in https://bugs.llvm.org/show_bug.cgi?id=38161 where integer literals could be treated as fixed point types and throw errors related to fixed point types when the 'k' or 'r' suffix used. The fix also addresses the second issue brought up with the assertion by not treating integers as fixed point types in the first place.

Integers that have suffixes 'k' and 'r' now throw the error `invalid suffix 'k/r' on integer constant`.

A few more tests were also added to ensure that fixed point types, and any errors/warnings related to them, are limited to C for now.

Prior discussion also at https://reviews.llvm.org/D46915.

Differential Revision: https://reviews.llvm.org/D49327

llvm-svn: 337289
2018-07-17 14:58:49 +00:00
..
CMakeLists.txt
HeaderMap.cpp Use StringRef for MemoryBuffer identifier API (NFC) 2016-10-01 16:38:28 +00:00
HeaderSearch.cpp Revert "[modules] Fix 37878; Autoload subdirectory modulemaps with specific LangOpts" 2018-07-12 17:38:48 +00:00
Lexer.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
LiteralSupport.cpp [Fixed Point Arithmetic] Fix for bug where integer literals could be treated as fixed point literals 2018-07-17 14:58:49 +00:00
MacroArgs.cpp Fix typos in clang 2018-04-06 15:14:32 +00:00
MacroInfo.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
ModuleMap.cpp [Modules] Improve .Private fix-its to handle 'explicit' and 'framework' 2018-06-15 20:13:28 +00:00
PPCaching.cpp [Lex] Fix crash on code completion in comment in included file. 2018-01-19 23:41:47 +00:00
PPCallbacks.cpp
PPConditionalDirectiveRecord.cpp Switch PPCallbacks to take the new MacroDefinition instead of MacroDirective*, in order to preserve full information on module macro expansion. 2015-05-04 03:15:40 +00:00
PPDirectives.cpp [clang-cl, PCH] Implement support for MS-style PCH through headers 2018-07-05 17:22:13 +00:00
PPExpressions.cpp Implement P0482R2, support for char8_t type. 2018-05-01 05:02:45 +00:00
PPLexerChange.cpp [clang-cl, PCH] Implement support for MS-style PCH through headers 2018-07-05 17:22:13 +00:00
PPMacroExpansion.cpp Add a new driver mode to dump compiler feature and extension options. 2018-05-31 13:57:09 +00:00
PTHLexer.cpp Fix typos in clang 2018-04-06 15:14:32 +00:00
Pragma.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
PreprocessingRecord.cpp Reland '[clang] Adding CharacteristicKind to PPCallbacks::InclusionDirective' 2018-05-10 19:05:36 +00:00
Preprocessor.cpp [clang-cl, PCH] Implement support for MS-style PCH through headers 2018-07-05 17:22:13 +00:00
PreprocessorLexer.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
ScratchBuffer.cpp [Lex] Use WritableMemoryBuffer in ScratchBuffer.cpp 2018-01-11 10:43:45 +00:00
TokenConcatenation.cpp Now that C++17 is official (https://www.iso.org/standard/68564.html), start changing the C++1z terminology over to C++17. NFC intended, these are all mechanical changes. 2017-12-04 20:27:34 +00:00
TokenLexer.cpp Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
UnicodeCharSets.h