By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,234 Members | 2,041 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,234 IT Pros & Developers. It's quick & easy.

Template member within a template

tekslave
P: 2
Does anyone know how to declare a template member inside of a template? The below example doesn't compile in Visual Studio 2005.

template< class M, int nSize >
class CQueue
{
private:
M m_list[ nSize ];
.
.
.
};

template< class T, int nSize >
class Foo
{
private:
CQueue<T, nSize> m_MyQueue;
.
.
.
};

Thanks!

<< TekSlave (A.K.A. Scott) >>
Feb 23 '07 #1
Share this Question
Share on Google+
2 Replies


tekslave
P: 2
Well I guess I should include the header that defined my queue template! All is well!

Sorry to take everyone's time.

<< Tekslave >>
Feb 23 '07 #2

Motoma
Expert 2.5K+
P: 3,235
Well I guess I should include the header that defined my queue template! All is well!

Sorry to take everyone's time.

<< Tekslave >>
Glad to see you've figured this out yourself. Welcome to theScripts!
Feb 23 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.