Difference between revisions of "User:Shuming Lin"
Shuming Lin (talk | contribs) |
Shuming Lin (talk | contribs) |
||
Line 16: | Line 16: | ||
The format for declaring function templates with type parameters is: | The format for declaring function templates with type parameters is: | ||
− | template <class identifier> function_declaration; | + | <u>template <class identifier> function_declaration;</u> |
− | template <typename identifier> function_declaration; | + | |
+ | <u>template <typename identifier> function_declaration;</u> | ||
The only difference between both prototypes is the use of either the keyword class or the keyword typename. Its use is indistinct, since both expressions have exactly the same meaning and behave exactly the same way. | The only difference between both prototypes is the use of either the keyword class or the keyword typename. Its use is indistinct, since both expressions have exactly the same meaning and behave exactly the same way. |
Revision as of 23:29, 24 November 2012
OOP344 | Weekly Schedule | Student List | Teams | Project | Student Resources
Welcome to My Wiki Page
Owner: Shuming Lin
My Major
CPD
C++
templates The format for declaring function templates with type parameters is:
template <class identifier> function_declaration;
template <typename identifier> function_declaration;
The only difference between both prototypes is the use of either the keyword class or the keyword typename. Its use is indistinct, since both expressions have exactly the same meaning and behave exactly the same way.
more information see my blog
Contact Information
sln44@myseneca.ca
kevin.shuminglin@gmail.com