class member types
From: nospam (johnnynoname_1_at_hotmail.com)
Date: 03/31/04
- Next message: Frosted Flake: "Re: Generating Compiler Warnings"
- Previous message: Leor Zolman: "Re: using-directive question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 31 Mar 2004 08:13:52 -0800
If i have some code like this:
template<typename T>
class eg
{
public:
typedef T size_type;
...
void somefunc(size_type);
};
What would be the correct way to define this
member function outside of the class definition?
template<typename T>
void eg<T>::somefunc(size_type)
{}
The above code compiles, but is it correct?
Or do i need to do something like:
template<typename T>
void eg<T>::somefunc(typename eg<T>::size_type)
{}
Thanks
- Next message: Frosted Flake: "Re: Generating Compiler Warnings"
- Previous message: Leor Zolman: "Re: using-directive question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|