[PATCH] D102903: [clang] Fix Wnested-anon-types in ABIArgInfo

Raphael Isemann via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri May 21 02:19:15 PDT 2021


This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGebd25fde5e04: [clang] Fix Wnested-anon-types in ABIArgInfo (authored by teemperor).
Herald added a subscriber: cfe-commits.

Changed prior to commit:
  https://reviews.llvm.org/D102903?vs=346942&id=346960#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D102903/new/

https://reviews.llvm.org/D102903

Files:
  clang/include/clang/CodeGen/CGFunctionInfo.h


Index: clang/include/clang/CodeGen/CGFunctionInfo.h
===================================================================
--- clang/include/clang/CodeGen/CGFunctionInfo.h
+++ clang/include/clang/CodeGen/CGFunctionInfo.h
@@ -93,15 +93,17 @@
     llvm::Type *PaddingType; // canHavePaddingType()
     llvm::Type *UnpaddedCoerceAndExpandType; // isCoerceAndExpand()
   };
+  struct DirectAttrInfo {
+    unsigned Offset;
+    unsigned Align;
+  };
+  struct IndirectAttrInfo {
+    unsigned Align;
+    unsigned AddrSpace;
+  };
   union {
-    struct {
-      unsigned Offset;
-      unsigned Align;
-    } DirectAttr;              // isDirect() || isExtend()
-    struct {
-      unsigned Align;
-      unsigned AddrSpace;
-    } IndirectAttr;            // isIndirect()
+    DirectAttrInfo DirectAttr;     // isDirect() || isExtend()
+    IndirectAttrInfo IndirectAttr; // isIndirect()
     unsigned AllocaFieldIndex; // isInAlloca()
   };
   Kind TheKind;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D102903.346960.patch
Type: text/x-patch
Size: 955 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210521/9b1af1aa/attachment-0001.bin>


More information about the cfe-commits mailing list