[clang-tools-extra] [clang-tidy] Ignore deleted ctor in `bugprone-forwarding-reference-overload` (PR #88138)

2024-04-13 Thread Mike Weller via cfe-commits
MikeWeller wrote: Sorry, didn't realize there are release notes I can updated in the change itself. Will do this Monday. https://github.com/llvm/llvm-project/pull/88138 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [Clang][Sema] Fix issue on requires expression with templated base class member function (PR #85198)

2024-04-13 Thread Qizhi Hu via cfe-commits
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn, NamedDecl *NDecl, } if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl)) -if (Method->isImplicitObjectMemberFunction()) +if (!isa(CurContext) && jcsxky wrote: And if only chec

[clang] [clang] Introduce `SemaCUDA` (PR #88559)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @fhahn Yeah, that's theoretically possible. I'll look into it today. https://github.com/llvm/llvm-project/pull/88559 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][DR1815] Support lifetime extension of temporary created by aggregate initialization using a default member initializer (PR #87933)

2024-04-13 Thread via cfe-commits
https://github.com/yronglin edited https://github.com/llvm/llvm-project/pull/87933 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix an issue where clang++ and clangd uses enormous amounts of memory (PR #88637)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: I'm not sure this is testable, but if you can think of a test, that would be nice. Can you also add a release note to `clang/ReleaseNotes.rst`? https://github.com/llvm/llvm-project/pull/88637 ___ cfe-commits mailing list cfe-commits@lis

[clang] [Clang][DR1815] Support lifetime extension of temporary created by aggregate initialization using a default member initializer (PR #87933)

2024-04-13 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/87933 >From 9fba6da7cb1ffbc7d46b69c6ac0cfd15a89c4b56 Mon Sep 17 00:00:00 2001 From: yronglin Date: Mon, 8 Apr 2024 01:38:23 +0800 Subject: [PATCH] [Clang] Support lifetime extension of temporary created by aggregate

[clang] [clang] Fix high memory consumption during pack deduction (PR #88637)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/88637 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix high memory consumption during pack deduction (PR #88637)

2024-04-13 Thread via cfe-commits
@@ -831,7 +831,7 @@ class PackDeductionScope { if (IsPartiallyExpanded) PackElements += NumPartialPackArgs; else if (IsExpanded) - PackElements += *FixedNumExpansions; + PackElements += FixedNumExpansions.value_or(1); Sirraide wrote: Th

[clang] [clang] Fix high memory consumption during pack deduction (PR #88637)

2024-04-13 Thread via cfe-commits
Sirraide wrote: > I can supply the exact code that causes this issue if needed, but I would > appreciate if you frends can point me to any tools that can generate an > obfuscated minimal reproducible example. There’s `creduce` and `cvise` from what I recall, but I’m not particularly good at u

[clang] [clang] Introduce `SemaOpenMP` (PR #88642)

2024-04-13 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-openmp Author: Vlad Serebrennikov (Endilll) Changes This patch moves OpenMP-related entities out of `Sema` to a newly created `SemaOpenMP` class. This is a part of the effort to split `Sema` up, and follows the recent example of CUDA, OpenACC, SYCL, HL

[clang] [clang] Introduce `SemaOpenMP` (PR #88642)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: I intentionally split formatting changes into a separate commit if reviewers want to look at changes without formatting noise. If, given the volume of changes here, there is an appetite to remove `OpenMP` and `OMP` from names inside `SemaOpenMP` right in this patch, I can do tha

[clang] [clang-format] Don't break between string literal operands of << (PR #69871)

2024-04-13 Thread Owen Pan via cfe-commits
owenca wrote: > I wish we'd made this removal an option rather than just removing it, what we > are seeing is reasonably formatted json or xml being streamed out is now > poorly written > > ```c++ > osjson << "{\n" ><<" \"name\": \"value\",\n" ><<" \"key\": \"abc\", \n" >

[clang] [Clang][CWG1815] Support lifetime extension of temporary created by aggregate initialization using a default member initializer (PR #87933)

2024-04-13 Thread via cfe-commits
https://github.com/yronglin edited https://github.com/llvm/llvm-project/pull/87933 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
https://github.com/Sirraide edited https://github.com/llvm/llvm-project/pull/88596 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
https://github.com/Sirraide requested changes to this pull request. Not too familiar w/ the overall context of this, so I can only comment on the implementation. This should also add some tests that actually use experimentally late-parsed attributes w/ the flag explicilty enabled/disabled. ht

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + Sirraide wrote: T

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -2101,9 +2179,20 @@ bool PragmaClangAttributeSupport::isAttributedSupported( return SpecifiedResult; // Opt-out rules: - // An attribute requires delayed parsing (LateParsed is on) - if (Attribute.getValueAsBit("LateParsed")) + + // An attribute requires delayed pa

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -2885,8 +2974,23 @@ static void emitAttributes(RecordKeeper &Records, raw_ostream &OS, return; } OS << "\n : " << SuperName << "(Ctx, CommonInfo, "; - OS << "attr::" << R.getName() << ", " - << (R.getValueAsBit("LateParsed") ? "true" : "fal

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -2885,8 +2974,23 @@ static void emitAttributes(RecordKeeper &Records, raw_ostream &OS, return; } OS << "\n : " << SuperName << "(Ctx, CommonInfo, "; - OS << "attr::" << R.getName() << ", " - << (R.getValueAsBit("LateParsed") ? "true" : "fal

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [clang] Introduce `SemaCUDA` (PR #88559)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: I think I exposed a name conflict with a system header on AIX by including `Cuda.h` in `Sema.h`. Given that this name conflict potentially affects both enum definition and its usage, how should we resolve this? https://github.com/llvm/llvm-project/pull/88559

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + delcypher wrote:

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + Sirraide wrote: I

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
@@ -2101,9 +2179,20 @@ bool PragmaClangAttributeSupport::isAttributedSupported( return SpecifiedResult; // Opt-out rules: - // An attribute requires delayed parsing (LateParsed is on) - if (Attribute.getValueAsBit("LateParsed")) + + // An attribute requires delayed pa

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
@@ -2101,9 +2179,20 @@ bool PragmaClangAttributeSupport::isAttributedSupported( return SpecifiedResult; // Opt-out rules: - // An attribute requires delayed parsing (LateParsed is on) - if (Attribute.getValueAsBit("LateParsed")) + + // An attribute requires delayed pa

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-13 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/88644 Fixes clang-ppc64-aix bot failure after #88559 (0a6f6df5b0c3d0f2a42f013bf5cafb9b5020dcac) https://lab.llvm.org/buildbot/#/builders/214/builds/11887 >From 9d46b1ed31d2acbb772f9bb4b139fa1ec36a65ab Mon Sep 17 00:0

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-13 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes Fixes clang-ppc64-aix bot failure after #88559 (0a6f6df5b0c3d0f2a42f013bf5cafb9b5020dcac) https://lab.llvm.org/buildbot/#/builders/214/builds/11887 --- Full diff: https://github.com/llvm/llvm-project/

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
delcypher wrote: @Sirraide Thanks for the feedback. > This should also add some tests that actually use experimentally late-parsed > attributes w/ the flag explicilty enabled/disabled. The intention is for the functionality being added to be used in a subsequent PR. This is currently sketch

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
https://github.com/delcypher updated https://github.com/llvm/llvm-project/pull/88596 >From 554287a724361a510389d7f34f9b57cf434b9657 Mon Sep 17 00:00:00 2001 From: Dan Liew Date: Fri, 12 Apr 2024 17:36:19 -0700 Subject: [PATCH 1/2] [Attributes] Support Attributes being declared as only supporti

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread Dan Liew via cfe-commits
@@ -1822,28 +1822,106 @@ void WriteSemanticSpellingSwitch(const std::string &VarName, OS << " }\n"; } +enum class LateAttrParseKind { + LateAttrParsingNever = 0, + LateAttrParsingAlways = 1, + LateAttrParsingExperimentalOnly = 2 +}; + +static LateAttrParseKind getLateAt

[clang] [Attributes] Support Attributes being declared as only supporting late parsing when passing an experimental feature flag (PR #88596)

2024-04-13 Thread via cfe-commits
Sirraide wrote: > Given that a subsequent patch will add the necessary test coverage and the > above problems I think it is reasonable for explicit tests for > `LateAttrParsingExperimentalOnly` to be omitted Yeah, if it’s not used anywhere or if both prs are merged at the same time, then that

[clang] [clang-repl] Set up executor implicitly to account for init PTUs (PR #84758)

2024-04-13 Thread Vassil Vassilev via cfe-commits
Stefan =?utf-8?q?Gränitz?= Message-ID: In-Reply-To: @@ -14,7 +14,7 @@ struct A { int a; A(int a) : a(a) {} virtual ~A(); }; // PartialTranslationUnit. inline A::~A() { printf("~A(%d)\n", a); } -// Create one instance with new and delete it. +// Create one instance with new

[clang] 09327ef - [clang][docs] fix whitespace in AttrDocs.td (#88631)

2024-04-13 Thread via cfe-commits
Author: Chris Copeland Date: 2024-04-14T08:37:58+02:00 New Revision: 09327efdf0f02c4f865a4536db96cac539bb1c01 URL: https://github.com/llvm/llvm-project/commit/09327efdf0f02c4f865a4536db96cac539bb1c01 DIFF: https://github.com/llvm/llvm-project/commit/09327efdf0f02c4f865a4536db96cac539bb1c01.diff

[clang] [clang][docs] fix whitespace in AttrDocs.td (PR #88631)

2024-04-13 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 closed https://github.com/llvm/llvm-project/pull/88631 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][docs] fix whitespace in AttrDocs.td (PR #88631)

2024-04-13 Thread via cfe-commits
github-actions[bot] wrote: @chrisnc Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a build,

[clang] [clang][Sema] Preserve the initializer of invalid VarDecls (PR #88645)

2024-04-13 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/88645 Fixes https://github.com/clangd/clangd/issues/1821 >From 42ee794d3de89241fae7314db2202cac32af469b Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 14 Apr 2024 02:41:48 -0400 Subject: [PATCH] [clang]

<    1   2