The example below compiles fine if the inner class is not a template
class. It also compiles perfectly on gcc. I think this is a bug in
CodeWarrior's C++ compiler.
class Foo
{
private:
void foo_func() { }
class BarPrivate
{
public:
virtual void execute() = 0;
};
public:
template<class QueryType>
class BarPublic : public BarPrivate
{
public:
void execute()
{
Foo * stub;
stub->foo_func();
}
};
};
class Reecha{ };
int main()
{
Foo::BarPublic<Reecha>* command = new Foo::BarPublic<Reecha>();
return 1;
}
Alexander Dymerets - 26 May 2005 08:20 GMT
Sailesh A wrote:
> The example below compiles fine if the inner class is not a template
This code should not compile at any case.