>From: "Thorsten Ottosen" <[EMAIL PROTECTED]> > just want to show you something I discovered > (maybe you already know) which allows template functions to be specialized > for a class without including its header; it does require that classes are > changed internally, > but I assume it will make compilation mucho faster. (another problem is that > I can only > compile it with Comeau, neither GCC 3.2 or vc7 can eat it). > > Anyway, the example is quite straightforward: > > #include <iostream> > > using namespace std; > > template< typename C > > void foo( const C& c ) > { > foo_impl( c, C::tag() );
It appears typename is needed here: foo_impl( c, typename C::tag()); since "tag" is a dependent type. This makes it still work on EDG (I've tested it on Intel C++), and it works better on GCC 3.2, although now it reports that it can't disambiguate the two overloaded function templates. Regards, Terje _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost