Some C++ compilers accept this code and others not.Code:template <class T> class b { T v; ... // code here }; int main() { b<b<int>> *C; ... }
Can somebody give me an alternative to my code or some sugestions ?
Some C++ compilers accept this code and others not.Code:template <class T> class b { T v; ... // code here }; int main() { b<b<int>> *C; ... }
Can somebody give me an alternative to my code or some sugestions ?
In the current C++ standard, that ">>" should be seen as a right-shift operator, not as two ">"s. I believe in the next standard, that will be valid syntax, but right now, you should have to use "> >".Code:b<b<int>> *C;
dwk
Seek and ye shall find. quaere et invenies.
"Simplicity does not precede complexity, but follows it." -- Alan Perlis
"Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
"The only real mistake is the one from which we learn nothing." -- John Powell
Other boards: DaniWeb, TPS
Unofficial Wiki FAQ: cpwiki.sf.net
My website: http://dwks.theprogrammingsite.com/
Projects: codeform, xuni, atlantis, nort, etc.