This revision was automatically updated to reflect the committed changes.
Closed by commit rGdad36245a5c2: [clang] Rework IsTailPaddedMemberArray into
isFlexibleArrayMemberExpr (authored by serge-sans-paille).
Changed prior to commit:
https://reviews.llvm.org/D133108?vs=460899=462140#toc
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM, though this should probably have a release note for it (we can augment
the release note when we make further changes in this area).
Comment at:
serge-sans-paille added inline comments.
Comment at: clang/test/Sema/unbounded-array-bounds.c:101
+ char tail[1]; // addr16-note {{declared here}} addr32-note {{declared here}}
+} fam1;
+
msebor wrote:
> msebor wrote:
> > There's a difference between the sizes
msebor added inline comments.
Comment at: clang/test/Sema/unbounded-array-bounds.c:101
+ char tail[1]; // addr16-note {{declared here}} addr32-note {{declared here}}
+} fam1;
+
msebor wrote:
> There's a difference between the sizes of `fam1` and `fam` that
msebor added inline comments.
Comment at: clang/test/Sema/unbounded-array-bounds.c:101
+ char tail[1]; // addr16-note {{declared here}} addr32-note {{declared here}}
+} fam1;
+
There's a difference between the sizes of `fam1` and `fam` that makes accesses
to
serge-sans-paille updated this revision to Diff 460899.
serge-sans-paille edited the summary of this revision.
serge-sans-paille added a comment.
Address minor nits, plus add a test case that showcases the extra (legitimate!)
warning we now get when accessing a "struct hack" field with an index
aaron.ballman added a comment.
Found a few more things while trying to convince myself this really is NFC, and
I don't think it is. If you agree, then I think we should have some additional
test coverage to show the behavioral changes.
Comment at:
serge-sans-paille updated this revision to Diff 460704.
serge-sans-paille added a comment.
Take reviews into account
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D133108/new/
https://reviews.llvm.org/D133108
Files:
clang/lib/Sema/SemaChecking.cpp
Index:
aaron.ballman added inline comments.
Comment at: clang/lib/Sema/SemaChecking.cpp:15881
+/// Check whether this array fits the idiom of a flexible array member,
+/// depending on -fstrict-flex-array value
///
depending on the value of -fstrict-flex-array
value.
msebor added inline comments.
Comment at: clang/lib/Sema/SemaChecking.cpp:15969
+ if (const MemberExpr *ME = dyn_cast(BaseExpr))
+ND = ME->getMemberDecl();
+
I'm not familiar with this code but I'm guessing that at most one of the `if`
conditionals is
serge-sans-paille created this revision.
serge-sans-paille added a reviewer: jyknight.
Herald added a project: All.
serge-sans-paille requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
This fixes a bunch of FIXME within
11 matches
Mail list logo