[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-08 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa1e5430b6adf: [clang] Fix consteval operators in template contexts (authored by Fznamznon). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin accepted this revision. cor3ntin added a comment. This revision is now accepted and ready to land. I think this looks good! Thanks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 529244. Fznamznon added a comment. Remove dead code Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 Files: clang/docs/ReleaseNotes.rst

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:15216-15217 - if (Op == OO_Subscript) { -SourceLocation LBrace; -SourceLocation RBrace; - -if (DeclRefExpr *DRE = dyn_cast(Callee)) { - DeclarationNameLoc NameLoc =

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 529229. Fznamznon added a comment. Remove RequiresADL Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 Files: clang/docs/ReleaseNotes.rst

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:15216-15217 - if (Op == OO_Subscript) { -SourceLocation LBrace; -SourceLocation RBrace; - -if (DeclRefExpr *DRE = dyn_cast(Callee)) { - DeclarationNameLoc NameLoc =

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:11988 - return getDerived().RebuildCXXOperatorCallExpr(E->getOperator(), - E->getOperatorLoc(), -

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-07 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 529220. Fznamznon added a comment. Use 1-element UnresolvedSet, rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 Files: clang/docs/ReleaseNotes.rst

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-06 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:12002 + + UnresolvedSet<16> Functions; + if (ImplicitCastExpr *ICE = dyn_cast(Callee)) cor3ntin wrote: > Can `Functions` ever held more than one element here? Good catch! I don't think

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-06 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:12002 + + UnresolvedSet<16> Functions; + if (ImplicitCastExpr *ICE = dyn_cast(Callee)) Can `Functions` ever held more than one element here? Repository: rG LLVM Github Monorepo

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-06 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added a comment. libcxx CI seems to be failing for other patches as well. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 ___ cfe-commits mailing

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-06 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 528769. Fznamznon added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 Files: clang/docs/ReleaseNotes.rst clang/lib/Sema/TreeTransform.h

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-02 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 527808. Fznamznon added a comment. Transform the callee, add a test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151553/new/ https://reviews.llvm.org/D151553 Files: clang/docs/ReleaseNotes.rst

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-06-01 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:11940-11943 - ExprResult Callee = getDerived().TransformExpr(E->getCallee()); - if (Callee.isInvalid()) -return ExprError(); - rsmith wrote: > Fznamznon wrote: > > cor3ntin wrote:

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-31 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:11940-11943 - ExprResult Callee = getDerived().TransformExpr(E->getCallee()); - if (Callee.isInvalid()) -return ExprError(); - Fznamznon wrote: > cor3ntin wrote: > > I don't

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-31 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added a comment. In D151553#4380667 , @erichkeane wrote: > Like @cor3ntin I'm concerned about removing the transform call. I'm just as > concerned that it caused no regressions... > > If we have to transform the arguments, then this can be a

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-30 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Like @cor3ntin I'm concerned about removing the transform call. I'm just as concerned that it caused no regressions... If we have to transform the arguments, then this can be a dependent thing, which means the callee should be possible to be dependent, right? Thus

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-26 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:11940-11943 - ExprResult Callee = getDerived().TransformExpr(E->getCallee()); - if (Callee.isInvalid()) -return ExprError(); - cor3ntin wrote: > I don't understand why we would not

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-26 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Sema/TreeTransform.h:11940-11943 - ExprResult Callee = getDerived().TransformExpr(E->getCallee()); - if (Callee.isInvalid()) -return ExprError(); - I don't understand why we would not need to transform

[PATCH] D151553: [clang] Fix consteval operators in template contexts

2023-05-26 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon created this revision. Herald added a project: All. Fznamznon requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Clang used to reject consteval operators if they're used inside a template due to TreeTransform putting two different