| title | Compiler Error C3539 | |
|---|---|---|
| ms.date | 11/04/2016 | |
| f1_keywords |
|
|
| helpviewer_keywords |
|
|
| ms.assetid | 34a33a0f-d1b6-498f-b312-ffad2d4799b3 |
'type': a template-argument cannot be a type that contains 'auto'
The indicated template argument type cannot contain a usage of the auto keyword.
- Do not specify the template argument with the
autokeyword.
The following example yields C3539.
// C3539.cpp
// Compile with /Zc:auto
template<class T> class C{};
int main()
{
C<auto> c; // C3539
return 0;
}