[clang] Implement [[msvc::no_unique_address]] (PR #65675)

Amy Huang via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 12 16:27:34 PDT 2023


================
@@ -4505,6 +4505,14 @@ bool FieldDecl::isZeroSize(const ASTContext &Ctx) const {
   if (!CXXRD->isEmpty())
     return false;
 
+  // MS ABI: nonzero if class type with class type fields
----------------
amykhuang wrote:

As far as I can tell the cases above still apply to MSVC so I think on 4489 it's correct to account for both spellings. Not sure what you mean about the comment? The existing comment above the `isEmpty` line describes what that checks for

https://github.com/llvm/llvm-project/pull/65675


More information about the cfe-commits mailing list