E2506 Explicit specialization of 'specifier' is ambiguous: must specify template arguments (C++)

From RAD Studio
Jump to: navigation, search

Go Up to Compiler Errors And Warnings (C++) Index

In the following code, explicit template arguments are necessary:

template<class T> void foo(T);
template<class T> void foo(T *);
template<> void foo(int *); // error, must say 'foo<int>' or 'foo<int *>'