friend10.c

来自「this is a gcc file, you can download it 」· C语言 代码 · 共 31 行

C
31
字号
// Build don't link:// Origin: Neil Booth, from PR #78namespace MySpace {   class Tag1 { };   class Tag2 { };   template<class Tag>   class Object   {   public:     friend void Forgotten(Object const & m) {}   };   typedef Object<Tag1> U1;   typedef Object<Tag2> U2;   void foo()   {     Forgotten(U1());     Forgotten(U2());   }   void bar()   {     Forgotten(U1());   } }

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?