Open
Description
See:
https://godbolt.org/z/b99E59WxT
template<typename T>
struct S {
template<typename U = T>
void getsTypoCorrection(){}
void baz() {
getsTypoCorrectoin();
}
};
Diagnoses as:
<source>:10:9: error: use of undeclared identifier 'getsTypoCorrectoin'; did you mean 'getsTypoCorrection'?
10 | getsTypoCorrectoin();
| ^~~~~~~~~~~~~~~~~~
| getsTypoCorrection
<source>:7:10: note: 'getsTypoCorrection' declared here
7 | void getsTypoCorrection(){}
| ^
<source>:10:9: error: cannot refer to member 'getsTypoCorrection' in 'S<T>' with '->'
10 | getsTypoCorrectoin();
| ^
<source>:7:10: note: member 'getsTypoCorrection' declared here
7 | void getsTypoCorrection(){}
The first diagnostic is correct, but the 2nd is super weird/awkward. I'm guessing we're not doing a good job checking to make sure the this
isn't implicit? Or not setting it right?