<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/62519>62519</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[Standard compliant issue] Base class that is the current instantiation is not recognised.
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
SainoNamkho
</td>
</tr>
</table>
<pre>
Compiling the example from https://eel.is/c++draft/temp.dep.type#example-2 with `clang++`
```c++
template<class T>
struct A
{
typedef int M;
struct B
{
typedef void M;
struct C;
};
};
template<class T>
struct A<T>::B::C : A<T>
{
M m; // OK,A<T>::M
};
int main()
{
}
```
leads to error
```
error: field has incomplete type 'A::B::M' (aka 'void')
M m; // OK,A<T>::M
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJycVM1y8jgQfJrxZSouI2GDDz4YCJctdg_ZFxisMdZGlihJJJu335JNAmxy-OqrotBPT7dmNGpTCPpkmRsoN1DuMrrEwfnmhbR1f9L4Orjs6NRHs3XjWRttTxgHRv6XxrNh7L0bcYjxHEC2IPYg9swm1wHEvgOxAbFRnvoIYh95POeKz3n8ODMIeZV4Eviu44BQFZ0he5pJUBVQ7KBo02T6XdXm3aRlKDLIbWcoBPwb5PMMhegvXcT2Sl9dGYiI6WDFPWob8QDyE7kFXLl3lAf-vcab0-pnkTuh7Q2ftHZf6_s5_npNcjttyhZku5mHLYJsb9D3qg84gtzg3Bz86w943sNmC-vto9zhe2Lzf7qtkbQFsQZR_--AFP7Yp3lpmFTA6JC9d_7HkBmRLfaajcKBAmrbufQmIk_3jCBW7UOxBxArBLGmV0pgagKI1Vdav1HuZ06ZaqSqZU0ZN4tqLReLolrX2dAUZX9cMPFS1L3qVXnsqTxKUSpVl31R1ZluRCFkURZyUSyXyzqnUlC1qCtaqXXBYgXLgkfSJjfmbcydP2U6hAs3lSgXdWboyCZM7hPC8jtOIAiRzOibxHk6Xk4BloXRIYabStTRTLZ9iWQVeYXT7Wmy8SpS7nBDgXF-T3GgBEz-7S7ec4qzIZKNmqJ2NoHWRfTcuZPVgVWeXbxpHv190nG4HPPOjSD2KZnr8HT27h_uktWn09MnYCrxvwAAAP__l-w66Q">