[PATCH] D106907: [clang] fix concepts crash on substitution failure during normalization

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/lib/Sema/SemaConcept.cpp:744 ArrayRef E) { - assert(E.size() != 0); - auto First = fromConstraintExpr(S, D, E[0]); rsmith wrote: > Might be useful to keep this assert;

[PATCH] D106907: [clang] fix concepts crash on substitution failure during normalization

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/lib/Sema/SemaConcept.cpp:751 + return None; +Conjunction.emplace(S.Context, std::move(*Conjunction), std::move(*Next), +CCK_Conjunction); mizvekov wrote: > rsmith wrote: > > Doesn'

[PATCH] D100733: [clang] NFC: change uses of `Expr->getValueKind` into `is?Value`

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4819b751bd87: [clang] NFC: change uses of `Expr->getValueKind` into `is?Value` (authored by mizvekov). Changed prior to commit: https://reviews.llvm.org/D100733?vs=351123&id=362254#toc Repository: rG

[PATCH] D100713: [clang] NFC: refactor multiple implementations of getDecltypeForParenthesizedExpr

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 362257. mizvekov added a comment. - rename to getReferenceQualifiedType. - Move the null expression special case out of the function, back to the original user. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D10

[PATCH] D100713: [clang] NFC: refactor multiple implementations of getDecltypeForParenthesizedExpr

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked 2 inline comments as done. mizvekov added inline comments. Comment at: clang/lib/Sema/SemaExprCXX.cpp:5845 + if (!To->isRValue()) { +QualType T = Self.Context.getDecltypeForParenthesizedExpr(To); InitializedEntity Entity = InitializedEntity::InitializeTe

[PATCH] D106907: [clang] fix concepts crash on substitution failure during normalization

2021-07-27 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 362268. mizvekov added a comment. - Restore assert. - Fix incorrekt use of emplace. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106907/new/ https://reviews.llvm.org/D106907 Files: clang/lib/Sema/SemaConce

[PATCH] D100713: [clang] NFC: refactor multiple implementations of getDecltypeForParenthesizedExpr

2021-07-28 Thread Matheus Izvekov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. mizvekov marked an inline comment as done. Closed by commit rG0c7cd4a87313: [clang] NFC: refactor multiple implementations of… (authored by mizvekov). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[PATCH] D106907: [clang] fix concepts crash on substitution failure during normalization

2021-07-28 Thread Matheus Izvekov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG87aa31827b29: [clang] fix concepts crash on substitution failure during normalization (authored by mizvekov). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 443731. mizvekov marked 2 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang/include

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:11551-11552 +if (Unqualified && !Ctx.hasSameType(X, Y)) { + assert(Ctx.hasSameUnqualifiedType(X, Y)); + auto XQuals = X.getCVRQualifiers(), YQuals = Y.getCVRQualifiers(); + X.addFastQualif

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 443734. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/Type.h clang/include/clang/Sema/Sema.

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 443749. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/Type.h clang/include/clang/Sema/Sema.

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 443769. Herald added subscribers: lldb-commits, Enna1. Herald added projects: LLDB, All. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.ll

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. Herald added a subscriber: JDevlieghere. In D111509#3168178 , @shafik wrote: > llvm-lit -sv lldb/test --filter TestScalarURem.py > > The change looks expected. Thanks for letting me know. Unfortunately that test is not suppor

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-11 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 443772. Herald added subscribers: usaxena95, kadircet, arphaman. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/Ext

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked 7 inline comments as done. mizvekov added a subscriber: sammccall. mizvekov added a comment. Herald added a subscriber: steakhal. Herald added a reviewer: NoQ. In D112374#3535949 , @rsmith wrote: > I've not looked at the test changes in an

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 443951. mizvekov marked 2 inline comments as done. Herald added a project: LLDB. Herald added a subscriber: lldb-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 444065. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/Type.h clang/include/clang/Sema/Sema.

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 444066. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/ExtractVariableTests.cpp clang-tools-extra/test/clang-tid

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 444067. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace.cpp clang-tools-extra/clang-include-fixer/f

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D111283#3646066 , @Mordante wrote: > The libc++ build failures are due a broken libc++ HEAD. The current HEAD > should work again. Thanks for letting me know! Pushed my patches again just to have a look at the result, haven

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked 2 inline comments as done. mizvekov added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:12225-12227 +#define NON_CANONICAL_TYPE(Class, Base) UNEXPECTED_TYPE(Class, "non-canonical") +#define TYPE(Class, Base) +#include "clang/AST/TypeNodes.inc"

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 444104. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace.cpp clang-tools-extra/clang-include-fixer/f

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-12 Thread Matheus Izvekov via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGbdc6974f9230: [clang] Implement ElaboratedType sugaring for types

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-13 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3647530 , @nikic wrote: > FYI this change had a noticeable compile-time impact > (http://llvm-compile-time-tracker.com/compare.php?from=ee88c0cf09969ba44307068797e12533b94768a6&to=bdc6974f92304f4ed542241b9b89ba58ba6b2

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-13 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3648624 , @JDevlieghere wrote: > This breaks all the LLDB tests that import the std module: > > Given that the bot has been red for 14 hours I went ahead and reverted this > change. Please keep an eye on this bot whe

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-14 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3650749 , @glandium wrote: > FWIW, this change also broke this check in Firefox's clang plugin: > https://searchfox.org/mozilla-central/rev/0d11f3660945ce35c49501bb44bc4f82bb2b503c/build/clang-plugin/NoPrincipalGetURI

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-14 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. @JDevlieghere I spent a lot of time trying to get this test running on my machine to no avail. I think lldb build and test setup is quite convoluted, fragile and antiquated. It uses many deprecated CMake features, It fails to properly link to system libraries it needs

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-14 Thread Matheus Izvekov via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG7c51f02effdb: [clang] Implement ElaboratedType sugaring for types written bare (authored by mizvekov). Changed prior to c

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-16 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov reopened this revision. mizvekov added a comment. In D112374#3653967 , @JDevlieghere wrote: > I'm sorry to hear you're having trouble building LLDB. The LLDB website has > quite an elaborate guide with instructions in how to build LLDB: > http

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-16 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3657472 , @kimgr wrote: > I'm coming at this from pretty far away, so there's very likely lots of > details that I'm overlooking. But it seems to me the mainline had only had an > `ElaboratedType` node if there was e

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-16 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3657472 , @kimgr wrote: > I can't say what the best solution is, but this patch generates quite a lot > of work for me, and I would really hope that catching up with the new AST > does not generate even more work dow

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-16 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. @kimgr One other general comment. The way this function is implemented is quite error prone: static const NamedDecl* TypeToDeclImpl(const Type* type, bool as_written) { // Get past all the 'class' and 'struct' prefixes, and namespaces. type = RemoveElaboration

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3658059 , @kimgr wrote: > Haha. Pun intended? :-) Yes :-) > As you noticed, it's not our tests that care about the AST, it's the tool > itself. IWYU has been around since 2010-11, so there's probably lots of code >

[PATCH] D129573: [Clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/test/Parser/while-loop-outside-function.c:3-4 + +while(1) {}; // expected-error {{expected identifier or '('}} \ + // expected-note {{while loop outside of functions}} + How about just making the error

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 445319. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked an inline comment as done. mizvekov added inline comments. Comment at: clang/lib/Sema/TypeLocBuilder.cpp:159 - assert(Capacity - Index == TypeLoc::getFullDataSizeForType(T) && + unsigned FDSz = TypeLoc::getFullDataSizeForType(T); + assert(Capacity - Index ==

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445358. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/Type.h clang/include/clang/Sema/Sema.

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445364. mizvekov marked 9 inline comments as done. Herald added subscribers: usaxena95, kadircet, arphaman. Herald added a project: clang-tools-extra. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ ht

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:11578 + default: +return X; + } rsmith wrote: > mizvekov wrote: > > rsmith wrote: > > > For `TemplateArgument::ArgKind::Declaration`, I think it'd make sense to > > > take the common

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445365. mizvekov marked 2 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/ExtractVariableTe

[PATCH] D129573: [Clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/test/Parser/while-loop-outside-function.c:3-4 + +while(1) {}; // expected-error {{expected identifier or '('}} \ + // expected-note {{while loop outside of functions}} + inclyc wrote: > mizvekov wrote:

[PATCH] D128113: Clang: fix AST representation of expanded template arguments.

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 445368. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128113/new/ https://reviews.llvm.org/D128113 Files: clang/include/clang/AST/ASTContext.h clang/include/cla

[PATCH] D128095: clang: fix checking parameter packs for expansion

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 445369. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128095/new/ https://reviews.llvm.org/D128095 Files: clang/include/clang/Sema/Sema.h clang/include/clang/Se

[PATCH] D128276: clang: perform deduction at the right depth on Sema::AddMethodTemplateCandidate

2022-07-17 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 445370. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128276/new/ https://reviews.llvm.org/D128276 Files: clang/lib/Sema/SemaOverload.cpp clang/test/CXX/temp/te

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked an inline comment as done. mizvekov added a comment. @JDevlieghere @teemperor ping. Sorry for the urgency here, but I have a lot of work built on top of this patch. And this patch fixes a bunch of bugs that other people are unaware and duplicating effort, see github issues. Re

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3659597 , @nikic wrote: > Given that LLVM 15 branches off in one week, maybe it would be better to wait > for that before relanding the change, as it seems to have significant impact > on plugins? I think it would m

[PATCH] D129573: [Clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D129573#3659404 , @inclyc wrote: > Now it only generates 1 error encountering token "while" Yes thank you, that is what I meant! But now we just gotta make sure this stays true for more complex test cases. ===

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445635. mizvekov marked an inline comment as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang-tools-extra/clangd/unittests/ASTTests.cpp clang-too

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445643. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/ExtractVariableTests.cpp clang-tools-extra/test/clang-tid

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445646. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace.cpp clang-tools-extra/clang-include-fixer/f

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445647. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang-tools-extra/clangd/unittests/ASTTests.cpp clang-tools-extra/clangd/unittests/HoverTests.cpp

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445648. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/ExtractVariableTests.cpp clang-tools-extra/test/clang-tid

[PATCH] D129573: [Clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/test/Parser/while-loop-outside-function.c:8 + +void some_fn(); + inclyc wrote: > mizvekov wrote: > > Can you add a few more test cases showing how error recovery is performing > > here? > > > > Have we parsed th

[PATCH] D129573: [clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-18 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/test/Parser/while-loop-outside-function.c:10-19 +// empty statement without semicolon +while(1) // expected-error {{while loop outside of a function}} +{ + +} + +// empty statement without semicolon, inline l_paren ---

[PATCH] D128113: Clang: fix AST representation of expanded template arguments.

2022-07-19 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 445993. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128113/new/ https://reviews.llvm.org/D128113 Files: clang/include/clang/AST/ASTContext.h clang/include/clang/AST/JSONNodeDumper.h clang/include/clang/

[PATCH] D128113: Clang: fix AST representation of expanded template arguments.

2022-07-19 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked an inline comment as done. mizvekov added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:1533 + *ReplacedOrErr, ToReplacementTypeOrErr->getCanonicalType(), + T->getPackIndex()); } shafik wrote: > I think we should have a tes

[PATCH] D128276: clang: perform deduction at the right depth on Sema::AddMethodTemplateCandidate

2022-07-19 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov planned changes to this revision. mizvekov added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:14176 + ParmVarDecl *Param = Method->getParamDecl(i); + if (!Param->hasDefaultArg()) { +IsError = true; shafik wrote: > Do we

[PATCH] D129573: [clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D129573#3664905 , @inclyc wrote: > Is the build error related to this patch? I don't think so, it's not even close to what you are changing. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129573/new/ https://reviews

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. @JDevlieghere @teemperor ping Can you please verify that everything works with LLDB, we just changed how those types are printed? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 446173. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace.cpp clang-tools-extra/clang-include-fixer/f

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3665249 , @sammccall wrote: > I've seen plenty of (useful) out-of-tree tidy checks written by people fuzzy > on the difference between a Type and a TypeLoc, or what sugar is. Clang makes > it (almost) easy to write t

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. It seems this change broke build on windows for me: clang-tools-extra\pseudo\lib\cxx\CXX.cpp(59): error C2838: 'noptr_declarator_0declarator_id': illegal qualified name in member declaration clang-tools-extra\pseudo\lib\cxx\CXX.cpp(59): error C2065: 'noptr_declarat

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. I confirm reverting just this patch fixes the build for me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129222/new/ https://reviews.llvm.org/D129222 ___ cfe-commits mailing li

[PATCH] D130089: update-test-checks: safely handle tests with #if's

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. This seems to have introduced a test which always fails on windows: $ ":" "RUN: at line 4" $ "cp" "clang\test\utils\update_cc_test_checks/Inputs/ifdef.c" "build\llvm\tools\clang\test\utils\update_cc_test_checks\Output\ifdef.test.tmp.c" $ "C:/Program Files (x86)/Mi

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. `Microsoft (R) C/C++ Optimizing Compiler Version 19.33.31627.1 for x64` As included in `Microsoft Visual Studio 2022` `Version 17.3.0 Preview 4.0` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129222/new/ https://reviews.

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. I un-reverted this locally to take a better look. It does not seem to me to be a compiler bug, because both cl.exe and intellisense are picking this error up, and I believe the MSVC intellisense is based on a completely different frontend (EDG). What I see is that `en

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. Running `clang-pseudo-gen --grammar ..\clang-tools-extra\pseudo\lib\cxx\cxx.bnf --emit-symbol-list` does seem to generate something that would work. But even if I delete `CXXSymbols.inc`, the cmake rule seems to be regenerating a wrong CXXSymbols.inc again, so I suspec

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. The clang-pseudo-gen that sits in `.\llvm\RelWithDebInfo\bin\clang-pseudo-gen` generates correct output, the one that sits in `.\llvm\NATIVE\Release\bin\clang-pseudo-gen.exe` doesn't, which seems to be the one cmake is picking up for this job. This could have somethin

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-20 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. Yeah, turning off `LLVM_OPTIMIZED_TABLEGEN` made cmake instantly generate the correct CXXSymbols.inc. So while I think there is a bug out there somewhere, it might not necessarily be in this patch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION htt

[PATCH] D130089: update-test-checks: safely handle tests with #if's

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D130089#3668022 , @nhaehnle wrote: > Aren't the before and after lines of the diff identical? Is this a Windows > new-lines issue? Yeah it looks like it from a glance, but I haven't had time to take a harder look at this ye

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D129222#3667638 , @hokein wrote: > Yeah, the native clang-pseudo-gen tool didn't rebuild somehow even its > source file changes, it is a bug in our cmake config. Should be fixed in > 2955192df8ac270515b5fa4aaa9e9380148e7f00

[PATCH] D130089: update-test-checks: safely handle tests with #if's

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D130089#3668061 , @nhaehnle wrote: > I've been staring at ifdef.test vs. basic-cplusplus.test for a while now and > don't see any relevant difference, including when I look at the line endings > in a hex editor (on Linux). S

[PATCH] D130089: update-test-checks: safely handle tests with #if's

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D130089#3668111 , @nhaehnle wrote: > My version of `diff` has a `--strip-trailing-cr` flag. But I don't really see > that being used in many places at all. What I see is that the sources are checked out with the expected win

[PATCH] D130089: update-test-checks: safely handle tests with #if's

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. I see what is going on here. The problem is not in this patch, but there is a problem in update_cc_test_checks.py. I had all the other files in `clang/test/utils/update_cc_test_checks` still checked out as unix line endings from before I had updated the config, and tha

[PATCH] D129222: [pseudo] Implement a guard to determine function declarator.

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D129222#3668158 , @sammccall wrote: > I think what's going on here: outer cmake invokes this opaque external > command (which just _happens_ to be cmake --build) to produce an exe. The > outer cmake has no special knowledge

[PATCH] D130308: WIP: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov created this revision. Herald added projects: clang, All. Herald added a subscriber: cfe-commits. mizvekov requested review of this revision. Depends on D128095 Signed-off-by: Matheus Izvekov Repository: rG LLVM Github Monorepo https://reviews.llv

[PATCH] D130308: WIP: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 446644. mizvekov planned changes to this revision. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130308/new/ https://reviews.llvm.org/D130308 Files: clang/include/clang/AST/ASTContext.h clang/lib/AST/ASTCon

[PATCH] D130308: WIP: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:12670 + return QualType(); +// FIXME: The modified types can be different as well. +// FIXME: It's inneficient to have to unify the modified types. rsmith wrote: > Should we bai

[PATCH] D129573: [clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-21 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added inline comments. Comment at: clang/test/Parser/while-loop-outside-function.c:4 +// basic +while(1) {}; // expected-error {{while loop outside of a function}} + What I meant is something like this, we test that the error caret would be placed on th

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D112374#3666531 , @kimgr wrote: > From a purely personal perspective, I'd prefer if this landed after the > branch for llvm-15. > > We try to co-release IWYU shortly after LLVM/Clang are released, to get a > public API-compa

[PATCH] D130308: WIP: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 447009. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130308/new/ https://reviews.llvm.org/D130308 Files: clang/include/clang/AST/ASTContext.h clang/lib/AST/ASTContext.cpp clang/lib/Sema/SemaTemplateDeduc

[PATCH] D130308: WIP: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov marked 3 inline comments as done. mizvekov added inline comments. Comment at: clang/lib/AST/ASTContext.cpp:12670 + return QualType(); +// FIXME: The modified types can be different as well. +// FIXME: It's inneficient to have to unify the modified types. ---

[PATCH] D129573: [clang] add a diagnostic note 'while loop outside functions' at global scope

2022-07-22 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov accepted this revision as: mizvekov. mizvekov added a comment. This revision is now accepted and ready to land. Thanks! The patch itself LGTM. Please update / fix up the commit message before merging. It still mentions `note` and has some minor English spelling issues. CHANGES SINCE L

[PATCH] D130419: Use `` with MSVC and C++

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D130419#3673877 , @fsb4000 wrote: > Why did x64 debian tests fail? openmp build is broken on linux pre-commit CI right now. Not related to your patch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION http

[PATCH] D112374: [clang] Implement ElaboratedType sugaring for types written bare

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov edited the summary of this revision. mizvekov updated this revision to Diff 447085. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112374/new/ https://reviews.llvm.org/D112374 Files: clang-tools-extra/clang-change-namespace/ChangeNamespace

[PATCH] D111283: [clang] template / auto deduction deduces common sugar

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 447086. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111283/new/ https://reviews.llvm.org/D111283 Files: clang-tools-extra/clangd/unittests/ASTTests.cpp clang-tools-extra/clangd/unittests/HoverTests.cpp

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 447087. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D111509/new/ https://reviews.llvm.org/D111509 Files: clang-tools-extra/clangd/unittests/tweaks/ExtractVariableTests.cpp clang-tools-extra/test/clang-tid

[PATCH] D111509: [clang] use getCommonSugar in an assortment of places

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D111509#3168178 , @shafik wrote: > Changing how types are printed can effect LLDB expression parsing tests. I > ran the LLDB test suite with this change: > > ninja check-lldb > > and it changes to the results for `TestScala

[PATCH] D130308: [clang] extend getCommonSugaredType to merge sugar nodes

2022-07-23 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 447091. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130308/new/ https://reviews.llvm.org/D130308 Files: clang/include/clang/AST/ASTContext.h clang/lib/AST/ASTContext.cpp clang/lib/Sema/SemaTemplateDeduc

[PATCH] D126308: cmake: use llvm dir variables for clang/utils/hmaptool

2022-05-24 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov created this revision. Herald added a subscriber: mgorny. Herald added a project: All. mizvekov published this revision for review. mizvekov added reviewers: bruno, mgorny, Ericson2314, sgraenitz, stephenneuendorffer. Herald added a project: clang. Herald added a subscriber: cfe-commits.

[PATCH] D100713: [clang] NFC: refactor usage of getDecltypeForParenthesizedExpr

2021-05-14 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D100713#2759637 , @aaronpuchert wrote: > Again, I'm not sure if it helps to use `getDecltypeForParenthesizedExpr` > where we don't actually have the `decltype` of a parenthesized expression. > > It's probably not entirely co

[PATCH] D100733: [clang] NFC: change uses of `Expr->getValueKind` into `is?Value`

2021-05-14 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D100733#2759592 , @aaronpuchert wrote: > Not sure how to feel about this, the value categories are already hard to > grasp for most C++ programmers. To solve the implicit move concerns with a > new value category seems like

[PATCH] D100733: [clang] NFC: change uses of `Expr->getValueKind` into `is?Value`

2021-05-14 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. In D100733#2761031 , @rsmith wrote: > What do we think about renaming `isRValue()` to `isPRValue()` and renaming > `VK_RValue` to `VK_PRValue`, adding a "real" `isRValue()`, and then > performing this cleanup? I think the curre

[PATCH] D95409: [clang] implicitly delete space ship operator with function pointers

2021-01-25 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov created this revision. Herald added a subscriber: yaxunl. mizvekov requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. See bug #48856 Definitions of classes with member function pointers and default spaceship operator were getting acc

[PATCH] D95409: [clang] implicitly delete space ship operator with function pointers

2021-01-26 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 319400. mizvekov added a comment. added tests adds test that will catch original bug also adds some tests on default equality/relational operators this last one would have caught the issue of not accepting equality operator for function pointers, had I not

[PATCH] D93095: Introduce -Wreserved-identifier

2021-02-03 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. There is a GNU extension where the linker provides symbols for section / start end, and using these with this patch would produce a warning. Example: ` [[gnu::section(foo)]] void bar() {} extern "C" void __start_foo(); extern "C" void __stop_foo(); CHANGES SIN

[PATCH] D95409: [clang] implicitly delete space ship operator with function pointers

2021-02-05 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. Ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95409/new/ https://reviews.llvm.org/D95409 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D109800: [clang] don't mark as Elidable CXXConstruct expressions used in NRVO

2021-09-15 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov added a comment. I can have a look on what is happening with that test case. At best if we figure out what is wrong, we could add some FIXMEs and circle back to it after we make this whole thing work again. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://rev

[PATCH] D109800: [clang] don't mark as Elidable CXXConstruct expressions used in NRVO

2021-09-15 Thread Matheus Izvekov via Phabricator via cfe-commits
mizvekov updated this revision to Diff 372845. mizvekov added a comment. Add a couple more test cases where we don't perform copy-elision on a returned prvalue in pre-C++17 modes, and the corresponding FIXMEs in the source code. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

<    1   2   3   4   5   6   7   8   9   10   >