[Bug c++/101498] New: gcc accepts template code with 'auto' as subtype
fchelnokov at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sun Jul 18 11:34:37 GMT 2021
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101498
Bug ID: 101498
Summary: gcc accepts template code with 'auto' as subtype
Product: gcc
Version: 11.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: fchelnokov at gmail dot com
Target Milestone: ---
The code as follows:
```
template <typename T> struct S;
void foo(S<auto>);
```
is ill-formed and must be rejected, but gcc accepts it:
https://gcc.godbolt.org/z/bMof1xsEa
More information about the Gcc-bugs
mailing list