r233725 - [lex] Bitfieldize some booleans.

Benjamin Kramer benny.kra at googlemail.com
Tue Mar 31 11:47:06 PDT 2015


Author: d0k
Date: Tue Mar 31 13:47:05 2015
New Revision: 233725

URL: http://llvm.org/viewvc/llvm-project?rev=233725&view=rev
Log:
[lex] Bitfieldize some booleans.

Lets us fuse some branches into bit tests downstream. NFC.

Modified:
    cfe/trunk/include/clang/Lex/LiteralSupport.h

Modified: cfe/trunk/include/clang/Lex/LiteralSupport.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Lex/LiteralSupport.h?rev=233725&r1=233724&r2=233725&view=diff
==============================================================================
--- cfe/trunk/include/clang/Lex/LiteralSupport.h (original)
+++ cfe/trunk/include/clang/Lex/LiteralSupport.h Tue Mar 31 13:47:05 2015
@@ -57,13 +57,13 @@ public:
   NumericLiteralParser(StringRef TokSpelling,
                        SourceLocation TokLoc,
                        Preprocessor &PP);
-  bool hadError;
-  bool isUnsigned;
-  bool isLong;        // This is *not* set for long long.
-  bool isLongLong;
-  bool isFloat;       // 1.0f
-  bool isImaginary;   // 1.0i
-  uint8_t MicrosoftInteger;  // Microsoft suffix extension i8, i16, i32, or i64.
+  bool hadError : 1;
+  bool isUnsigned : 1;
+  bool isLong : 1;          // This is *not* set for long long.
+  bool isLongLong : 1;
+  bool isFloat : 1;         // 1.0f
+  bool isImaginary : 1;     // 1.0i
+  uint8_t MicrosoftInteger; // Microsoft suffix extension i8, i16, i32, or i64.
 
   bool isIntegerLiteral() const {
     return !saw_period && !saw_exponent;





More information about the cfe-commits mailing list