S
Srini
Hello all,
I was just wondering why there are no namespace templates in C++. For
instance, something like this...
template <typename TYPE>
namespace SOME
{
TYPE *pointer;
}
I cannot think of any use of this sort of a construct. But since a
class name itself becomes a namespace and when I'd have only static
data in a class, I could make it a namespace template.
Pardon me if this whole question is stupid - I just wanted to know if
it was a language design decision to not include it or no one thought
about it or its utterly useless.
Thanks is advance.
Regards,
Srini
I was just wondering why there are no namespace templates in C++. For
instance, something like this...
template <typename TYPE>
namespace SOME
{
TYPE *pointer;
}
I cannot think of any use of this sort of a construct. But since a
class name itself becomes a namespace and when I'd have only static
data in a class, I could make it a namespace template.
Pardon me if this whole question is stupid - I just wanted to know if
it was a language design decision to not include it or no one thought
about it or its utterly useless.
Thanks is advance.
Regards,
Srini