[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-11-10 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. I wonder if we could come up with an overload or something for cases when we only have a `FieldDecl`. For example, in the Clang Static Analyzer, we have something similar at MemRegion.cpp#L784-L811

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. Thanks for the reviews! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/ https://reviews.llvm.org/D134791 ___ cfe-commits mailing list

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread serge via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3460a5d79572: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr (authored by serge-sans-paille). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. Assuming precommit CI comes back clean, this LGTM. Thanks for the cleanup! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/ https://reviews.llvm.org/D134791

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 465071. serge-sans-paille added a comment. Removed a diff that sneaked in. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/ https://reviews.llvm.org/D134791 Files: clang/include/clang/AST/Expr.h clang/lib/AST/Expr.cpp

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: bolt/lib/RuntimeLibs/RuntimeLibrary.cpp:31-36 + llvm::sys::path::append(LibPath, "lib64"); if (!llvm::sys::fs::exists(LibPath)) { // In some cases we install bolt binary into one level deeper in bin/, // we need to

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread serge via Phabricator via cfe-commits
serge-sans-paille added inline comments. Comment at: clang/include/clang/AST/Expr.h:531 + bool isFlexibleArrayMemberLike( + ASTContext , unsigned StrictFlexArraysLevel, + bool IgnoreTemplateOrMacroSubstitution = false) const; aaron.ballman wrote: > Do

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 465053. serge-sans-paille marked 3 inline comments as done. serge-sans-paille added a comment. Herald added a reviewer: rafauler. Herald added subscribers: yota9, ayermolo. Herald added a reviewer: Amir. Herald added a reviewer: maksfb. Address

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-04 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In general, this looks reasonable to me. Comment at: clang/include/clang/AST/Expr.h:529 + /// When IgnoreTemplateOrMacroSubstitution is set, it doesn't consider sizes + /// resulting from substitution of macro or template as special sizes. +

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-03 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. @aaron.ballman : gentle ping :-) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/ https://reviews.llvm.org/D134791 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-01 Thread serge via Phabricator via cfe-commits
serge-sans-paille marked an inline comment as done. serge-sans-paille added inline comments. Comment at: clang/lib/AST/Expr.cpp:225 + + } else if (!Context.getAsIncompleteArrayType(getType())) +return false; tschuett wrote: > Could this be an early exit? I

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-01 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 464494. serge-sans-paille added a comment. Add an early exit CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/ https://reviews.llvm.org/D134791 Files: clang/include/clang/AST/Expr.h clang/lib/AST/Expr.cpp

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-01 Thread Thorsten via Phabricator via cfe-commits
tschuett added inline comments. Comment at: clang/lib/AST/Expr.cpp:225 + + } else if (!Context.getAsIncompleteArrayType(getType())) +return false; Could this be an early exit? Comment at: clang/lib/AST/Expr.cpp:267 + +if

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-10-01 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 464485. serge-sans-paille edited the summary of this revision. serge-sans-paille added a comment. Add test case for ObjC interface with FAM, as hinted by @msebor CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134791/new/

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-09-30 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. In D134791#3827722 , @msebor wrote: > Thanks for the heads up! My only general comment is that unless this change > has no externally observable effect I'd suggest adding tests. (Otherwise, > noting it has no such

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-09-30 Thread Martin Sebor via Phabricator via cfe-commits
msebor added a comment. Thanks for the heads up! My only general comment is that unless this change has no externally observable effect I'd suggest adding tests. (Otherwise, noting it has no such effect would be helpful.) When I'm not familiar with the code (and often even what I am) I

[PATCH] D134791: [clang] Unify Sema and CodeGen implementation of isFlexibleArrayMemberExpr

2022-09-28 Thread serge via Phabricator via cfe-commits
serge-sans-paille created this revision. serge-sans-paille added reviewers: aaron.ballman, efriedma, jyknight, jrtc27, msebor. Herald added a subscriber: kristof.beyls. Herald added a project: All. serge-sans-paille requested review of this revision. Herald added a project: clang. Herald added a