[clang-tools-extra] [clangd] Document the cases in which Dex::Files and IdxContents are populated (PR #118906)

2024-12-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/118906 >From 45311dbceed8d438f2ac0db5019719a7fa32c0bf Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Thu, 5 Dec 2024 19:45:25 -0500 Subject: [PATCH] [clangd] Add clarifying comment about when Dex::IdxContents

[clang-tools-extra] [clangd] Add clarifying comment about when Dex::IdxContents is populated (PR #118906)

2024-12-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/118906 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add clarifying comment about when Dex::IdxContents is populated (PR #118906)

2024-12-07 Thread Nathan Ridge via cfe-commits
@@ -121,6 +121,8 @@ class Dex : public SymbolIndex { llvm::DenseMap, std::vector> Relations; std::shared_ptr KeepAlive; // poor man's move-only std::any // Set of files which were used during this index build. + // Files and IdxContents are only populated for dynamic an

[clang-tools-extra] [clangd] Handle DeducedTemplateSpecializationType in HeuristicResolver (PR #119107)

2024-12-09 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/119107 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-27 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Thank you @kleinesfilmroellchen for your contribution! https://github.com/llvm/llvm-project/pull/67749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-06 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > We can also create a new matcher for `dependentNameType` so we can use it > like `dependentNameType(hasDependentType(builtinType()))`, which is similar > to Complex and Array types. I don't think `DependentNameType` has a `Type` property that we could match in this way

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-05 Thread Nathan Ridge via cfe-commits
@@ -2235,6 +2235,24 @@ TEST_P(ASTMatchersTest, ArgumentCountIs_CXXConstructExpr) { Constructor1Arg)); } +TEST_P(ASTMatchersTest, HasDependentName_DependentScopeDeclRefExpr) { + if (!GetParam().isCXX() || GetParam().hasDelayedTemplateParsing()) { +// FIXM

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 approved this pull request. Thanks! The update looks good, I have one more minor suggestion for a change which I'll just go ahead and make before merging. https://github.com/llvm/llvm-project/pull/121656 ___ cfe-commi

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/121656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121656 >From 4cd48886384570e0e5bb0b712f4fd45f8decd27e Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 4 Jan 2025 17:36:05 +0100 Subject: [PATCH 1/4] [Clang][ASTMatcher] Add a matcher for the name of a De

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From d5403c8f7dcdf15409febf1851bd8dc19b2babab Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: In the latest update, matchers for the `DependentNameType` cases are revised to be more specific. Here, the approach I took was to match the context in which the types appear. @hokein I believe your comment about using more specific matchers should be fully addressed now

[clang] [Clang][ASTMatcher] Add `dependentTemplateSpecializationType` AST mat… (PR #121435)

2025-01-03 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentTemplateSpecializationType` AST mat… (PR #121435)

2025-01-02 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 approved this pull request. Thanks, LGTM! https://github.com/llvm/llvm-project/pull/121435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentTemplateSpecializationType` AST mat… (PR #121435)

2025-01-01 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 commented: Thanks! I agree with @AmrDeveloper's comments. Otherwise, this looks pretty good! https://github.com/llvm/llvm-project/pull/121435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.

[clang] [Clang][ASTMatcher] Add `dependentTemplateSpecializationType` AST mat… (PR #121435)

2025-01-01 Thread Nathan Ridge via cfe-commits
@@ -1926,6 +1926,21 @@ TEST_P(ASTMatchersTest, DependentNameType) { dependentNameType())); } +TEST_P(ASTMatchersTest, DependentTemplateSpecializationType) { + if (!GetParam().isCXX()) { +return; + } + + EXPECT_TRUE(matches( + R"( + template struct A; ---

[clang] [Clang][ASTMatcher] Add `dependentTemplateSpecializationType` AST mat… (PR #121435)

2025-01-01 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/121435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-01 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From 9bb43932c38558741f5b26a29b7cadd9958b9eb7 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-01 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From 052d67acf9d1f28ba487557d8bba6732fbab538f Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-01 Thread Nathan Ridge via cfe-commits
@@ -0,0 +1,521 @@ +//===-- HeuristicResolverTests.cpp --*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Remove clangd's HasValue GMock matcher (PR #121309)

2025-01-01 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121309 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-01 Thread Nathan Ridge via cfe-commits
@@ -0,0 +1,521 @@ +//===-- HeuristicResolverTests.cpp --*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-01 Thread Nathan Ridge via cfe-commits
@@ -0,0 +1,521 @@ +//===-- HeuristicResolverTests.cpp --*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From dfde3a11f9e90e75ba5118959b0ad101b6369734 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: (Rebased) https://github.com/llvm/llvm-project/pull/121313 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From 63d9512fb376ee9bb837bad3f3d107969e561371 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-05 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: In the latest update, I use the new `hasDependentName()` matcher added in https://github.com/llvm/llvm-project/issues/121610 to make the matchers using `dependentScopeDeclRefExpr()` more specific. https://github.com/llvm/llvm-project/pull/121313 __

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121313 >From c342743b01a643db8754446dbe5b014018bb4871 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-07 Thread Nathan Ridge via cfe-commits
@@ -0,0 +1,540 @@ +//===-- HeuristicResolverTests.cpp --*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2025-01-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/121313 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Extend `hasDependentName` to match DependentNameType name (PR #121975)

2025-01-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/121975 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Extend `hasDependentName` to match DependentNameType name (PR #121975)

2025-01-07 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 commented: Thanks! Nice to see we have a `POLYMORPHIC_MATCHER` utility that makes this straightforward to implement. https://github.com/llvm/llvm-project/pull/121975 ___ cfe-commits mailing list cfe-commits@lists.llvm

[clang] [Clang][ASTMatcher] Extend `hasDependentName` to match DependentNameType name (PR #121975)

2025-01-07 Thread Nathan Ridge via cfe-commits
@@ -2251,6 +2251,14 @@ TEST_P(ASTMatchersTest, HasDependentName_DependentScopeDeclRefExpr) { EXPECT_TRUE(matches("template struct S { static T foo(); };" "template void x() { S::foo(); }", dependentScopeDeclRefExpr(hasDependentNa

[clang] [Clang][ASTMatcher] Extend `hasDependentName` to match DependentNameType name (PR #121975)

2025-01-07 Thread Nathan Ridge via cfe-commits
@@ -2251,6 +2251,14 @@ TEST_P(ASTMatchersTest, HasDependentName_DependentScopeDeclRefExpr) { EXPECT_TRUE(matches("template struct S { static T foo(); };" "template void x() { S::foo(); }", dependentScopeDeclRefExpr(hasDependentNa

[clang-tools-extra] [clangd] Make EnableFunctionArgSnippets option string-typed (PR #121178)

2024-12-30 Thread Nathan Ridge via cfe-commits
@@ -242,13 +242,13 @@ opt FallbackStyle{ init(clang::format::DefaultFallbackStyle), }; -opt EnableFunctionArgSnippets{ +opt EnableFunctionArgSnippets{ HighCommander4 wrote: Thanks for the suggestion. I tried this briefly, but I think it makes the `--help

[clang-tools-extra] [clangd] Make EnableFunctionArgSnippets option string-typed (PR #121178)

2024-12-30 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > I think we need to add the new `ArgumentLists` config in the clangd config > doc https://clangd.llvm.org/config#completion. Definitely. I'll send out a patch documenting this and other options new in clangd 20 in the near future. (We have an entry about this on the [Rel

[clang-tools-extra] [clangd] Make EnableFunctionArgSnippets option string-typed (PR #121178)

2024-12-30 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121178 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/121313 Fixes https://github.com/clangd/clangd/issues/2154 >From 8238ad159c0b8123c03d953d18340147c72372e9 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-27 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: The rebased patch has green buildkite runs, so I will go ahead and merge it. https://github.com/llvm/llvm-project/pull/67749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/c

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-27 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/67749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentNameType` Matcher (PR #121263)

2024-12-28 Thread Nathan Ridge via cfe-commits
@@ -2536,6 +2536,15 @@ Node Matchers matches "decltype(i + j)" +MatcherStmt>dependentNameTypeMatcherDependentNameType>... HighCo

[clang] [Clang][ASTMatcher] Add `dependentNameType` Matcher (PR #121263)

2024-12-28 Thread Nathan Ridge via cfe-commits
@@ -1912,6 +1912,21 @@ TEST_P(ASTMatchersTest, DeducedTemplateSpecializationType) { deducedTemplateSpecializationType())); } +TEST_P(ASTMatchersTest, DependentNameType) { + if (!GetParam().isCXX()) { +// FIXME: Add a test for `dependentNameType()` that does

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-24 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/120996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-24 Thread Nathan Ridge via cfe-commits
@@ -556,6 +556,22 @@ TEST_P(ASTMatchersTest, DeclRefExpr) { Reference)); } +TEST_P(ASTMatchersTest, DependentScopeDeclRefExpr) { + if (!GetParam().isCXX() || GetParam().hasDelayedTemplateParsing()) { +// FIXME: Add a test for `dependentScopeDeclRe

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-24 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 commented: Thanks, this looks pretty good! https://github.com/llvm/llvm-project/pull/120996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-26 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > @kleinesfilmroellchen could you rebase the patch to a recent `main` please > (or merge `main` into it)? (I just realized there is an "Update branch" button which allows me to do this from the Github UI. Apologies, one year after the project's switch away from Phabricat

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-26 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/67749 >From 67971ca27ef5e2767aba5cfe2cec1021c4de5ec1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Thu, 25 Jan 2024 18:04:35 +0100 Subject: [PATCH] [clangd] Allow specifying what h

[clang-tools-extra] [clangd] Make EnableFunctionArgSnippets option string-typed (PR #121178)

2024-12-26 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/121178 Fixes https://github.com/clangd/clangd/issues/2232 >From 418a56b8e5bbdf479e427a1c3058022b5aacb74b Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Thu, 26 Dec 2024 23:23:00 -0500 Subject: [PATCH] [clang

[clang-tools-extra] [clangd] Make EnableFunctionArgSnippets option string-typed (PR #121178)

2024-12-26 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: The patch doesn't include a test because the only way I can think of testing this is a clangd lit test and it doesn't seem worth writing one for this, but I could write one if desired. https://github.com/llvm/llvm-project/pull/121178 __

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121313)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 ready_for_review https://github.com/llvm/llvm-project/pull/121313 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121246)

2024-12-29 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Resubmitted as https://github.com/llvm/llvm-project/pull/121313 in a user branch of this repo, so that I can stack dependent PRs on top of this. https://github.com/llvm/llvm-project/pull/121246 ___ cfe-commits mailing list cfe-co

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121246)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121246 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentNameType` Matcher (PR #121263)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/121263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentNameType` Matcher (PR #121263)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/121263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121246)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/121246 >From 8238ad159c0b8123c03d953d18340147c72372e9 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd] Add a unit test suite for HeuristicResolver Fixes

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121246)

2024-12-29 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Updated to take advantage of the new `dependentNameType()` matcher added in https://github.com/llvm/llvm-project/pull/121263. https://github.com/llvm/llvm-project/pull/121246 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[clang-tools-extra] [clangd] Remove clangd's HasValue GMock matcher (PR #121309)

2024-12-29 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/121309 An equivalent matcher under the name Optional has since been added upstream to GMock. Fixes https://github.com/llvm/llvm-project/issues/121308 >From 112d20354add8679fc62e66de4428c947b295e96 Mon Sep 17 0

[clang] [Clang][ASTMatcher] Add `dependentNameType` Matcher (PR #121263)

2024-12-29 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: @AmrDeveloper if you're not tired of these yet, I have one final one: https://github.com/llvm/llvm-project/issues/121307 https://github.com/llvm/llvm-project/pull/121263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org htt

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-27 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Went ahead and merged this. Thanks @AmrDeveloper! https://github.com/llvm/llvm-project/pull/120996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-27 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/120996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add a unit test suite for HeuristicResolver (PR #121246)

2024-12-27 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/121246 Fixes https://github.com/clangd/clangd/issues/2154 >From 3834e0c9b8018a662215a6eb6bd5878c67346215 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 6 Oct 2024 00:41:48 -0400 Subject: [PATCH] [clangd

[clang] [Clang][ASTMatcher] Add `dependentScopeDeclRefExpr` Matcher (PR #120996)

2024-12-27 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: By the way, in case you're interested in doing another one, I filed https://github.com/llvm/llvm-project/issues/121240 about another missing matcher I came across. https://github.com/llvm/llvm-project/pull/120996 ___ cfe-commits

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2025-01-31 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > Did this already land in 19.1.7? No, it will appear in clangd 20. https://github.com/llvm/llvm-project/pull/67749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[clang] [clang][Index] Use HeuristicResolver in libIndex (PR #125153)

2025-01-30 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/125153 None >From ddb04e547e312884c63739600829b58c242211b3 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Thu, 30 Jan 2025 21:31:12 -0500 Subject: [PATCH] [clang][Index] Use HeuristicResolver in libIndex --

[clang] [clang][HeuristicResolver] Track the expression whose type is being simplified after each step in simplifyType() (PR #126689)

2025-02-11 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/126689 >From 32b94e342ce6eb0d3703eb66586b393c0b4fd20c Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Tue, 11 Feb 2025 01:56:50 -0500 Subject: [PATCH] [clang][HeuristicResolver] Track the expression whose type

[clang] [clang][HeuristicResolver] Track the expression whose type is being simplified after each step in simplifyType() (PR #126689)

2025-02-11 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: (Rebased) https://github.com/llvm/llvm-project/pull/126689 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][HeuristicResolver] Track the expression whose type is being simplified after each step in simplifyType() (PR #126689)

2025-02-11 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/126689 >From 9a11851a8057f1d0e6efcfe9ddb9038fc8ca0a98 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Tue, 11 Feb 2025 01:56:50 -0500 Subject: [PATCH] [clang][HeuristicResolver] Track the expression whose type

[clang] [clang][HeuristicResolver] Track the expression whose type is being simplified after each step in simplifyType() (PR #126689)

2025-02-10 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/126689 Fixes https://github.com/llvm/llvm-project/issues/126536 >From e5a3d7aa5362357acd30ef5d1bafaa814ac2c89f Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Tue, 11 Feb 2025 01:56:50 -0500 Subject: [PATCH]

[clang] [clang][HeuristicResolver] Track the expression whose type is being simplified after each step in simplifyType() (PR #126689)

2025-02-10 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: The explanation in [this comment](https://github.com/llvm/llvm-project/issues/126536#issuecomment-2649966528) may provide useful context for reviewing this fix. https://github.com/llvm/llvm-project/pull/126689 ___ cfe-commits ma

[clang] [clang][HeuristicResolver] Only perform qualifier check for instance methods (PR #125166)

2025-01-30 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/125166 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][HeuristicResolver] Only perform qualifier check for instance methods (PR #125166)

2025-01-30 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Part of me wonders if there's ever a legitimate reason to call `CXXMethodDecl::getMethodQualifiers()` on a static method... https://github.com/llvm/llvm-project/pull/125166 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][HeuristicResolver] Only perform qualifier check for instance methods (PR #125166)

2025-01-30 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/125166 Fixes https://github.com/llvm/llvm-project/issues/125164 >From 5d7ae41e0b67dd3cebe94d2aea67f653acfe5ad1 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Thu, 30 Jan 2025 23:45:52 -0500 Subject: [PATCH]

[clang] [clang][CodeComplete] Use HeuristicResolver to resolve CXXDependentScopeMemberExpr (PR #124888)

2025-01-30 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/124888 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Do not show `aParam` parameter hint for argument spelled `param` (PR #119162)

2024-12-09 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > I have mixed feelings about this. The change is small, but it seems tied to a > particular coding style, and the implementation appears to be "optimized" > specifically for that style, which isn’t we do generally. Would you feel any differently if the implementation was

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
@@ -423,8 +427,6 @@ bool childExprIsStmt(const Stmt *Outer, const Expr *Inner) { if (!Outer || !Inner) return false; // Exclude the most common places where an expr can appear but be unused. - if (llvm::isa(Outer)) HighCommander4 wrote: We should revi

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
@@ -599,10 +607,22 @@ Expected ExtractVariable::apply(const Selection &Inputs) { // FIXME: get variable name from user or suggest based on type std::string VarName = "placeholder"; SourceRange Range = Target->getExtractionChars(); + + const SelectionTree::Node &OuterImp

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
@@ -599,10 +607,22 @@ Expected ExtractVariable::apply(const Selection &Inputs) { // FIXME: get variable name from user or suggest based on type std::string VarName = "placeholder"; SourceRange Range = Target->getExtractionChars(); + + const SelectionTree::Node &OuterImp

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 requested changes to this pull request. Ok, fair enough. https://github.com/llvm/llvm-project/pull/112525 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/112525 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Consider expression statements in ExtractVariable tweak (PR #112525)

2024-12-10 Thread Nathan Ridge via cfe-commits
@@ -152,7 +152,7 @@ TEST_F(ExtractVariableTest, Test) { a = [[b]]; a = [[xyz()]]; // statement expression - [[xyz()]]; + [[v()]]; HighCommander4 wrote: please update the comment above to "expression statement of type void" https://

[clang-tools-extra] [clangd] Index reserved symbols from `*intrin.h` system headers (PR #119735)

2024-12-14 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 approved this pull request. LGTM (I made a small tweak to the test name) https://github.com/llvm/llvm-project/pull/119735 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[clang-tools-extra] [clangd] Index reserved symbols from `*intrin.h` system headers (PR #119735)

2024-12-14 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Hmm, the test is failing for me locally. Is it passing for you? (I'm not quite sure from the Buildkite logs whether it ran this test or not.) https://github.com/llvm/llvm-project/pull/119735 ___ cfe-commits mailing list cfe-commi

[clang-tools-extra] [clangd] Index reserved symbols from `*intrin.h` system headers (PR #119735)

2024-12-14 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/119735 >From 04757e7d94ce5db11bb397accb0b1c0523d351ba Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Thu, 12 Dec 2024 12:15:32 -0600 Subject: [PATCH 1/3] [clangd] Index reserved symbols from `*intrin.h` syste

[clang-tools-extra] [clangd] Do not show `aParam` parameter hint for argument spelled `param` (PR #119162)

2024-12-15 Thread Nathan Ridge via cfe-commits
@@ -867,13 +867,28 @@ class InlayHintVisitor : public RecursiveASTVisitor { } } + static bool argumentMatchesParamName(StringRef ArgName, StringRef ParamName) { +// Exact match. +if (ParamName == ArgName) + return true; + +// Parameter name uses "a" p

[clang] [clang-tools-extra] FunctionDecl::getFunctionTypeLoc: ignore function type attributes (PR #118420)

2024-12-16 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Clangd changes LGTM https://github.com/llvm/llvm-project/pull/118420 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Augment code completion results with documentation from the index. (PR #120099)

2024-12-16 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > I'm not entirely sure how to add to the tests for clangd. Any advice? We have GTest unit tests for code completion in `CodeCompleteTests.cpp`. [This test](https://searchfox.org/llvm/rev/2df48fa78b496a2d276aa848598634bb2aad6857/clang-tools-extra/clangd/unittests/CodeCompl

[clang-tools-extra] [clangd] Augment code completion results with documentation from the index. (PR #120099)

2024-12-17 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Thanks. I haven't had a chance to look through the patch in detail yet, but the general shape seems reasonable. I also wanted to check, have you resolved the issue you described in [this comment](https://github.com/clangd/clangd/issues/2252#issuecomment-2545141457)? > no

[clang-tools-extra] [clangd] Re-land "support outgoing calls in call hierarchy" (PR #117673)

2024-12-17 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > Any chance this is backportable to the 19.x series? Or is it too dependent on > changes since then? > > Or even better 18.x? (since a lot of downstream tools are dependent on 18.x > and will be a while before they bump to 19) If you're asking about the change being bac

[clang-tools-extra] [clangd] Re-land "support outgoing calls in call hierarchy" (PR #117673)

2024-12-18 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > While I don't have direct experience with LLVM releases, I suppose the > Outgoing Calls feature will be part of version 20? Yep https://github.com/llvm/llvm-project/pull/117673 ___ cfe-commits mailing list cfe-commits@lists.ll

[clang-tools-extra] [clangd] Index reserved symbols from `*intrin.h` system headers (PR #119735)

2024-12-12 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 requested changes to this pull request. Thanks for the patch. I thought about whether it makes sense to have an additional check for the `*intrin.h` header being inside the resource directory specifically, but I don't see any headers with that name ending in an

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-19 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > I don't have any energy and the massive reachitecting requested would take me > tons of time. I certainly didn't intend to request a massive rearchitecting. Sam's comment gave me the impression that hooking up the preferences to include-cleaner would be fairly straight

[clang-tools-extra] [clangd] Check getFunctionTypeLoc() for validity in InlayHintVisitor (PR #117296)

2024-11-21 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/117296 Fixes https://github.com/clangd/clangd/issues/2223 >From ac19feac7e59e7fdcef89a091cbecaaf3d50b512 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Fri, 22 Nov 2024 01:51:06 -0500 Subject: [PATCH] [clang

[clang-tools-extra] [clangd] Re-land "support outgoing calls in call hierarchy" (PR #117673)

2024-12-03 Thread Nathan Ridge via cfe-commits
@@ -163,7 +163,7 @@ class Checker { unsigned ErrCount = 0; Checker(llvm::StringRef File, const ClangdLSPServer::Options &Opts) - : File(File), Opts(Opts) {} + : File(File), Opts(Opts), Index(/*SupportContainedRefs=*/false) {} HighCommander4 wrote

[clang-tools-extra] [clangd] Re-land "support outgoing calls in call hierarchy" (PR #117673)

2024-12-03 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Updated to remove the default arguments. Thanks for the reviews! https://github.com/llvm/llvm-project/pull/117673 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Compute accurate begin location for CallExpr with explicit object parameter (PR #117841)

2024-12-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/117841 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Document the cases in which Dex::Files and IdxContents are populated (PR #118906)

2024-12-05 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/118906 This is a follow-up to https://github.com/llvm/llvm-project/pull/118324 to document that the `Dex` fields `Files` and `IdxContents` are intentionally only used in some cases, and describe what those case

[clang] [clang-tools-extra] [clang] Compute accurate begin location for CallExpr with explicit object parameter (PR #117841)

2024-12-05 Thread Nathan Ridge via cfe-commits
@@ -1639,11 +1639,19 @@ SourceLocation CallExpr::getBeginLoc() const { if (const auto *OCE = dyn_cast(this)) return OCE->getBeginLoc(); + if (const auto *Method = + dyn_cast_if_present(getCalleeDecl()); HighCommander4 wrote: > heh I think ther

[clang-tools-extra] [NFC] Fix uninitialized scalar field in constructor. (PR #118324)

2024-12-05 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > Do you still want an issue to be opened? I sent out a follow-up PR at https://github.com/llvm/llvm-project/pull/118906 to add a comment describing the situations in which `IdxContents` is used, to avoid future confusion. https://github.com/llvm/llvm-project/pull/118324

[clang] [clang-tools-extra] [clang] [Sema] Preserve nested name specifier prefix in MemberPointerType (PR #118236)

2024-12-05 Thread Nathan Ridge via cfe-commits
@@ -5347,13 +5347,16 @@ static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, case NestedNameSpecifier::TypeSpec: case NestedNameSpecifier::TypeSpecWithTemplate: - ClsType = QualType(NNS->getAsType(), 0); + const Type *N

<    3   4   5   6   7   8   9   10   11   >