Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Compiler Error C3539
Collapse the table of content
Expand the table of content

Compiler Error C3539

'type': a template-argument cannot be a type that contains 'auto'

The indicated template argument type cannot contain a usage of the auto keyword.

To correct this error

  •  Do not specify the template argument with the auto keyword.

The following example yields C3539.

// C3539.cpp
// Compile with /Zc:auto
template<class T> class C{};
int main()
   C<auto> c;   // C3539
   return 0;

Community Additions

© 2015 Microsoft