fntemp16.c

来自「开放源码的编译器open watcom 1.6.0版的源代码」· C语言 代码 · 共 34 行

C
34
字号
#include "fail.h"

/*
//  This regression test is linked to Bugzilla item numer 218
//  After a syncToRestart whilst in external linkage OR a namespace body
//  the parser could not reduce when the next token was a right brace.
//  a fix to the grammar to allow an empty token to satisfy the parser 
//  allowed the reduce.
*/
extern "C"{
   template < class t_Data > class t_Vector
   {
   public:  t_Data Do_Something(t_Data);
   };
   template < class t_Data >t_Data t_Vector< t_Data >::Do_Something(t_Data x){
      return(++x);
   }
}

namespace t_temp{
   template < class t_Data > class t_Vector2
   {
   public:  t_Data Do_Something(t_Data);
   };
   template < class t_Data >t_Data t_Vector2< t_Data >::Do_Something(t_Data x){
      return(++x);
   }
}

int main()
{
    _PASS;
}

⌨️ 快捷键说明

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