https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/146649
>From 7f8581f01c3c25363b77100635c6df7223badba3 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 2 Jul 2025 01:26:25 -0700
Subject: [PATCH 1/2] [clang][CodeComplete] skip explicit obj param in
Sign
@@ -1,14 +1,42 @@
struct A {
- void foo(this A self, int arg);
+ void foo(this auto&& self, int arg);
+ void bar(this A self, int arg);
};
-int main() {
+int func1() {
A a {};
a.
}
-// RUN: %clang_cc1 -cc1 -fsyntax-only -code-completion-at=%s:%(line-2):5
-std=c++23
MythreyaK wrote:
Seems to be working as expected. I'll add a test case for this as well.


https://github.com/llvm/
MythreyaK wrote:
The completion for `(&A::foo2)` is just `(A, int)`, not `foo(A, int)`. I tried
to add a test case, like in this [godbolt](https://godbolt.org/z/77zE7e3oE)
example,
```cpp
struct A {
void foo1(this A self, int arg) {}
template
void foo2(this T&& self, int arg, flo
MythreyaK wrote:
> How does completion handle things like this?
@cor3ntin Oh I totally forgot about this! Thanks! I'll check it in the evening.
https://github.com/llvm/llvm-project/pull/146649
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ht
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/146649
>From 7f8581f01c3c25363b77100635c6df7223badba3 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 2 Jul 2025 01:26:25 -0700
Subject: [PATCH] [clang][CodeComplete] skip explicit obj param in
Signatur
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/146649
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/146649
>From 816845b3402afc67acf641778dd7f937d9b1dc53 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 2 Jul 2025 01:26:25 -0700
Subject: [PATCH 1/3] [clang][CodeComplete] skip explicit obj param in
Sign
@@ -4368,11 +4409,14 @@ TEST(CompletionTest, SkipExplicitObjectParameter) {
Annotations Code(R"cpp(
struct A {
void foo(this auto&& self, int arg);
+ void bar(this A self, int arg);
};
int main() {
A a {};
- a.^
+ a.$c1^s
-
@@ -4368,11 +4409,14 @@ TEST(CompletionTest, SkipExplicitObjectParameter) {
Annotations Code(R"cpp(
struct A {
void foo(this auto&& self, int arg);
+ void bar(this A self, int arg);
};
int main() {
A a {};
- a.^
+ a.$c1^s
+ (&
@@ -4435,11 +,11 @@ TEST(CompletionTest, SkipExplicitObjectParameter) {
auto Result = codeComplete(testPath(TU.Filename), Code.point("c1"),
Preamble.get(), Inputs, Opts);
-EXPECT_THAT(Result.Completions,
-UnorderedElem
@@ -4386,12 +4430,24 @@ TEST(CompletionTest, SkipExplicitObjectParameter) {
MockFS FS;
auto Inputs = TU.inputs(FS);
- auto Result = codeComplete(testPath(TU.Filename), Code.point(),
- Preamble.get(), Inputs, Opts);
-
- EXPECT_THAT(Result.Compl
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/146649
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From f7e79ed934bcb05548b6a4d303d6ed6284648f35 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH] [libtooling] Insert headers in global module fragment
---
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From f7e79ed934bcb05548b6a4d303d6ed6284648f35 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH 1/2] [libtooling] Insert headers in global module fragment
MythreyaK wrote:
Should I combine all into the same test case, or are 3 separate ones okay?
I just realized the other tests seem to combine multiple checks into one gtest
test.
https://github.com/llvm/llvm-project/pull/151624
___
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
MythreyaK wrote:
@HighCommander4 @JVApen, I wasn't sure if the failures reported by the buildbot
are relevant or related to this PR. Thoughts?
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ht
MythreyaK wrote:
Thank you for checking!
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From f7e79ed934bcb05548b6a4d303d6ed6284648f35 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH 1/3] [libtooling] Insert headers in global module fragment
@@ -115,6 +134,7 @@ unsigned getOffsetAfterHeaderGuardsAndComments(StringRef
FileName,
return SM.getFileOffset(Tok.getLocation());
return 0;
}));
+ return std::max(HeaderAndPPOffset, ModuleDecl);
MythreyaK wrote:
Thanks, d
@@ -115,6 +134,7 @@ unsigned getOffsetAfterHeaderGuardsAndComments(StringRef
FileName,
return SM.getFileOffset(Tok.getLocation());
return 0;
}));
+ return std::max(HeaderAndPPOffset, ModuleDecl);
MythreyaK wrote:
This does
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From f7e79ed934bcb05548b6a4d303d6ed6284648f35 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH 1/4] [libtooling] Insert headers in global module fragment
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From f7e79ed934bcb05548b6a4d303d6ed6284648f35 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH 1/5] [libtooling] Insert headers in global module fragment
@@ -83,13 +83,13 @@ bool checkAndConsumeModuleDecl(const SourceManager &SM,
Lexer &Lex,
return Matched;
}
-// Returns the offset after header guard directives and any comments
-// before/after header guards (e.g. #ifndef/#define pair, #pragma once). If no
-// header guard i
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK ready_for_review
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK created
https://github.com/llvm/llvm-project/pull/151624
Currently a draft PR.
Change to insert headers only in the global module fragment after skipping
comments and any preprocessor directives.
>From 1c1f7cca259e4da191e4ce6113a955e891c71692 Mon Sep 17 00:00:
MythreyaK wrote:
Fixes clangd/clangd#2450
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/151624
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From 51db5932277a81581ba5076a7f79eb0b124c2b92 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Thu, 31 Jul 2025 19:14:22 -0700
Subject: [PATCH] [libtooling] Insert headers in global module fragment
--
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/151624
>From b4c0f290cf9b74813c015afc1167d016b78049cf Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 1 Aug 2025 01:19:18 -0700
Subject: [PATCH] [libtooling] Insert headers in global module fragment
---
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/146649
>From 816845b3402afc67acf641778dd7f937d9b1dc53 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 2 Jul 2025 01:26:25 -0700
Subject: [PATCH 1/4] [clang][CodeComplete] skip explicit obj param in
Sign
@@ -3294,18 +3294,27 @@ TEST(SignatureHelpTest, SkipExplicitObjectParameter) {
const auto Result = signatureHelp(testPath(TU.Filename), Code.point("c1"),
*Preamble, Inputs,
MarkupKind::PlainText);
-EXPECT_EQ(1, Result.signatures.s
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/146649
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
MythreyaK wrote:
> Hah, it's from the removal of the s at the end of a.$c1^s! I guess there was
> a reason for it 😆
You're right, nice catch! I thought the 's' was from me not `Ctrl+S` correctly
😆.
> I'm ok with either option.
I'm not sure what the changes might be, so I my thought is that
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/146649
>From 816845b3402afc67acf641778dd7f937d9b1dc53 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 2 Jul 2025 01:26:25 -0700
Subject: [PATCH 1/5] [clang][CodeComplete] skip explicit obj param in
Sign
@@ -6,9 +6,21 @@ int main() {
A a {};
a.
}
-// RUN: %clang_cc1 -cc1 -fsyntax-only -code-completion-at=%s:%(line-2):5
-std=c++23 %s | FileCheck %s
-// CHECK: COMPLETION: A : A::
-// CHECK-NEXT: COMPLETION: foo : [#void#]foo(<#int arg#>)
-// CHECK-NEXT: COMPLETION: operator=
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/152445
>From d66aaec0a298433af6a52ad5ebe87fc578a3e7bc Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 6 Aug 2025 22:49:28 -0700
Subject: [PATCH] [clang] CodeComplete fix for addr of deduced-this methods
@@ -42,7 +42,23 @@ int func3() {
int func4() {
// TODO (&A::foo)(
- (&A::bar)(
+ (&A::bar)()
}
MythreyaK wrote:
Renamed this file from `skip-explicit-object-parameter.cpp` to
`cpp23-explicit-object.cpp` and added the test here, instead of creating a new
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK created
https://github.com/llvm/llvm-project/pull/153760
Fixes #141291
Skip suggesting members when not using `self.` in explicit object methods.
[TODO: Need to add a semacodecomplete test too, will add it in a new commit]
>From 690ca3d679c2df1386a212533afecab3bc
https://github.com/MythreyaK created
https://github.com/llvm/llvm-project/pull/152445
Attempts to fix code complete for
```cpp
struct A {
void foo(this auto&& self, int arg);
void bar(this A self, int arg);
};
int main() {
A a {};
(&A::fo$c^;
}
```
This should return
```
signature
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/152445
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1312,6 +1312,11 @@ bool ResultBuilder::canCxxMethodBeCalled(const
CXXMethodDecl *Method,
(CurrentClassScope == Method->getParent() ||
CurrentClassScope->isDerivedFrom(Method->getParent()));
+ // if method is using C++23 "deducing this", then it is a call
+
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/152445
>From 1b2cb7c27b72d1a774aa7ac0652f3765defa1140 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Wed, 6 Aug 2025 22:49:28 -0700
Subject: [PATCH] [clang] CodeComplete fix for addr of deduced-this methods
https://github.com/MythreyaK created
https://github.com/llvm/llvm-project/pull/152671
Include `Signature` and `SnippetSuffix` in the output, when test fails
Before: Value of: Result.Completions
Expected: has 1 element that (named (Name: "bar")) and (signature (S: "(A self,
int arg)")) and (sn
@@ -1428,6 +1428,16 @@ void ResultBuilder::AddResult(Result R, DeclContext
*CurContext,
AdjustResultPriorityForDecl(R);
+ if (isa(R.Declaration)) {
+// If result is a member in the context of an explicit-object member
+// function, drop it because it must be acces
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 8df889319e8146db958d027d5dee8ed22d6c9d3c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH] [clang] Include explicit object methods in overload
sugg
@@ -1428,10 +1428,18 @@ void ResultBuilder::AddResult(Result R, DeclContext
*CurContext,
AdjustResultPriorityForDecl(R);
+ // Account for explicit object parameter
+ const auto getQualifiers = [&](const CXXMethodDecl *MethodDecl) {
+if (MethodDecl->isExplicitObjectMe
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 471fa8c60c27a99ce029b1168679a6c5b0271108 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/5] [clang] Include explicit object methods in overload
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 471fa8c60c27a99ce029b1168679a6c5b0271108 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/4] [clang] Include explicit object methods in overload
@@ -3410,9 +3418,36 @@ static void
AddQualifierToCompletionString(CodeCompletionBuilder &Result,
Result.AddTextChunk(Result.getAllocator().CopyString(PrintedNNS));
}
+// Sets the function qualifiers completion string by inspecting the explicit
+// object
+static void AddC
MythreyaK wrote:
Thanks for the review!
I have 2 remaining questions,
1. With this PR, these 2 show up as overloads, though not sure if they should
be considered overloads. It's convenient, but wanted to double-check.
```cpp
void foo2(int a);
void foo2(this const S& self, float a
@@ -1428,10 +1428,18 @@ void ResultBuilder::AddResult(Result R, DeclContext
*CurContext,
AdjustResultPriorityForDecl(R);
+ // Account for explicit object parameter
+ const auto getQualifiers = [&](const CXXMethodDecl *MethodDecl) {
MythreyaK wrote:
Wasn
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/155143
>From c1cdb3909c0bb55ce21d339f087c1e38616fec3f Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 23 Aug 2025 23:57:18 -0700
Subject: [PATCH 1/2] [clang] Heuristic resolution for explicit object
par
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/155143
>From c1cdb3909c0bb55ce21d339f087c1e38616fec3f Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 23 Aug 2025 23:57:18 -0700
Subject: [PATCH] [clang] Heuristic resolution for explicit object paramete
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/155143
>From c1cdb3909c0bb55ce21d339f087c1e38616fec3f Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 23 Aug 2025 23:57:18 -0700
Subject: [PATCH 1/3] [clang] Heuristic resolution for explicit object
par
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
https://github.com/MythreyaK created
https://github.com/llvm/llvm-project/pull/155143
Fixes clangd/clangd#2323.
Assumes `self` is of the record type in the declaration.
```cpp
struct Foo {
int [[memb^er]] {};
auto&& getter1(this auto&& self) { // assume `self` is is `Foo`
return self
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/155143
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK ready_for_review
https://github.com/llvm/llvm-project/pull/155143
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/155143
>From c1cdb3909c0bb55ce21d339f087c1e38616fec3f Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 23 Aug 2025 23:57:18 -0700
Subject: [PATCH 1/4] [clang] Heuristic resolution for explicit object
par
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
MythreyaK wrote
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/155143
>From c1cdb3909c0bb55ce21d339f087c1e38616fec3f Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 23 Aug 2025 23:57:18 -0700
Subject: [PATCH 1/5] [clang] Heuristic resolution for explicit object
par
@@ -301,9 +302,34 @@ std::vector
HeuristicResolverImpl::resolveMemberExpr(
return {};
}
+ // check if member expr is in the context of an explicit object method
+ // If so, it's safe to assume the templated arg is of type of the record
+ const auto ExplicitMemberHeur
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/152445
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/152445
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1428,6 +1428,16 @@ void ResultBuilder::AddResult(Result R, DeclContext
*CurContext,
AdjustResultPriorityForDecl(R);
+ if (isa(R.Declaration)) {
+// If result is a member in the context of an explicit-object member
+// function, drop it because it must be acces
@@ -197,6 +197,9 @@ class ResultBuilder {
/// Whether the \p ObjectTypeQualifiers field is active.
bool HasObjectTypeQualifiers;
+ // Whether the member function is using an explicit object parameter
+ bool IsExplicitObjectMemberFunction;
MythreyaK wrote
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/153760
>From cf4b9526cfa77fb0e289f0a5f3105b242202b4b7 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 15 Aug 2025 00:52:37 -0700
Subject: [PATCH 1/2] [clang] Skip unqualified members in explicit-member
@@ -42,7 +42,23 @@ int func3() {
int func4() {
// TODO (&A::foo)(
- (&A::bar)(
+ (&A::bar)()
}
MythreyaK wrote:
Had to add this paren, otherwise compilation fails
```
clang/test/CodeCompletion/cpp23-explicit-object.cpp:46:1: error: expected
expression
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/153760
>From d1007fc47f47c07688b0083216d2799bcb3ff406 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 15 Aug 2025 00:52:37 -0700
Subject: [PATCH 1/2] [clang] Skip unqualified members in explicit-member
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK ready_for_review
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/153760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1428,6 +1428,16 @@ void ResultBuilder::AddResult(Result R, DeclContext
*CurContext,
AdjustResultPriorityForDecl(R);
+ if (isa(R.Declaration)) {
+// If result is a member in the context of an explicit-object member
+// function, drop it because it must be acces
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/153760
>From 690f034b5854714abe6630de85fb0b7b5b947462 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 15 Aug 2025 00:52:37 -0700
Subject: [PATCH 1/3] [clang] Skip unqualified members in explicit-member
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/153760
>From 690f034b5854714abe6630de85fb0b7b5b947462 Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 15 Aug 2025 00:52:37 -0700
Subject: [PATCH 1/3] [clang] Skip unqualified members in explicit-member
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 8df889319e8146db958d027d5dee8ed22d6c9d3c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/2] [clang] Include explicit object methods in overload
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 8df889319e8146db958d027d5dee8ed22d6c9d3c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/2] [clang] Include explicit object methods in overload
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 8df889319e8146db958d027d5dee8ed22d6c9d3c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/2] [clang] Include explicit object methods in overload
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/154041
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/154041
>From 8df889319e8146db958d027d5dee8ed22d6c9d3c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Sat, 16 Aug 2025 15:48:02 -0700
Subject: [PATCH 1/2] [clang] Include explicit object methods in overload
https://github.com/MythreyaK updated
https://github.com/llvm/llvm-project/pull/153760
>From b279e4b718488a08d25fdc43edae965c0fec288c Mon Sep 17 00:00:00 2001
From: Mythreya Kuricheti
Date: Fri, 15 Aug 2025 00:52:37 -0700
Subject: [PATCH 1/3] [clang] Skip unqualified members in explicit-member
@@ -2288,7 +2288,10 @@ class CXXMethodDecl : public FunctionDecl {
const CXXRecordDecl *Decl);
Qualifiers getMethodQualifiers() const {
-return getType()->castAs()->getMethodQuals();
+if (isExplicitObjectMemberFunction())
+ return g
https://github.com/MythreyaK edited
https://github.com/llvm/llvm-project/pull/154041
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
1 - 100 of 135 matches
Mail list logo