[PATCH] D133711: [Sema] Reject array element types whose sizes aren't a multiple of their alignments

Reid Kleckner via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 14 14:45:21 PDT 2022


rnk added a comment.

This seems like a new error that will be pretty easy to run into, especially in the funky MSVC virtual base case. @aaron.ballman proposed some kind of new breaking change announcement mechanism. Can you add a release note and send an announcement following that process? I think it's just posting to Discourse announcements.

Overall this seems like the right thing to do.



================
Comment at: clang/test/Layout/ms-x86-misalignedarray.cpp:10
+#ifdef _ILP32
+// expected-error at -3 {{size of array element}}
+#endif
----------------
I think what I had in mind when I said let's not change record layout is, let's keep doing what we were doing if we are targeting MSVC. But, what you've done is principled, so if we can ship it, it would be for the best.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D133711



More information about the cfe-commits mailing list