]> granicus.if.org Git - clang/commitdiff
[AST] Tighten up some bitfields
authorDavid Majnemer <david.majnemer@gmail.com>
Sat, 9 Jul 2016 19:26:19 +0000 (19:26 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Sat, 9 Jul 2016 19:26:19 +0000 (19:26 +0000)
Optimize the bitfield types to conserve space for the MSVC ABI.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@274983 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/AST/DeclFriend.h
include/clang/AST/DeclObjC.h

index 27b0388007a1cd1d0243ae9922ffb307f4583e33..5b2e2d9915eb101b0a9e29be153020e1fd6d4be4 100644 (file)
@@ -57,7 +57,7 @@ private:
   /// True if this 'friend' declaration is unsupported.  Eventually we
   /// will support every possible friend declaration, but for now we
   /// silently ignore some and set this flag to authorize all access.
-  bool UnsupportedFriend : 1;
+  unsigned UnsupportedFriend : 1;
 
   // The number of "outer" template parameter lists in non-templatic
   // (currently unsupported) friend type declarations, such as
index 4e9682f3b32e409f96ce61b831c19ef1b4267741..ad9b5a26b7c867a2bb2741042f2c449f8031f7ba 100644 (file)
@@ -1124,15 +1124,15 @@ class ObjCInterfaceDecl : public ObjCContainerDecl
 
     /// \brief Indicates that the contents of this Objective-C class will be
     /// completed by the external AST source when required.
-    mutable bool ExternallyCompleted : 1;
+    mutable unsigned ExternallyCompleted : 1;
 
     /// \brief Indicates that the ivar cache does not yet include ivars
     /// declared in the implementation.
-    mutable bool IvarListMissingImplementation : 1;
+    mutable unsigned IvarListMissingImplementation : 1;
 
     /// Indicates that this interface decl contains at least one initializer
     /// marked with the 'objc_designated_initializer' attribute.
-    bool HasDesignatedInitializers : 1;
+    unsigned HasDesignatedInitializers : 1;
 
     enum InheritedDesignatedInitializersState {
       /// We didn't calculate whether the designated initializers should be