摘要:
error: using typedef-name `T' after `class'templateclass Factory{ friend class T;};class Foo{};int main(){ Factory f; return 0;}按照 http://stackoverflow.com/questions/6321191/using-friend-in-templates提供的解决方案是:使用间接方式:templateclass MakeFriend{public: typedef T Type; };templateclass Factory{... 阅读全文
posted @ 2013-04-15 00:38
Wilson-Loo
阅读(814)
评论(0)
推荐(0)

浙公网安备 33010602011771号