共用方式為


編譯器錯誤 C2909

'identifier': 函式範本的明確具現化必須有傳回類型

函式樣板的明確具現化必須有其傳回類型的明確規格。 隱含傳回類型規格不適用。

下列範例會產生 C2909:

// C2909.cpp
// compile with: /c
template<class T> int f(T);
template f<int>(int);         // C2909
template int f<int>(int);   // OK