-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Heuristic resolution does not find member of type referenced via alias template #1663
Comments
This is similar to #1657, except that the fix is in (With #1662 in place, the implementation of |
I wrote a fix for this (https://reviews.llvm.org/D152500), but I'm not satisfied with it. While my fix handles the above testcase specifically, it does not handle this modified testcase: template <typename T>
struct Waldo {
void find();
};
template <typename T>
struct MetaWaldo {
using Type = Waldo<T>;
};
template <typename T>
void foo(typename MetaWaldo<T>::Type w) {
w.find();
} even though clangd can resolve the use of I would like to find a solution that doesn't require manual handling for every kind of type sugar. |
I have updated my patch to take a more general approach. The example in the previous comment is still not handled; I mischaracterized it as being another example of type sugar when in fact it's not -- there is a heuristic resolution step involved, because class templates can be specialized while alias templates can't. I'll file a follow-up issue for this. |
The follow-up is #1671 |
In the following code:
go-to-definition on the use of
find()
does not produceWaldo::find()
.The text was updated successfully, but these errors were encountered: