⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cp_statement.c

📁 这是一个Linux下的集成开发环境
💻 C
📖 第 1 页 / 共 2 页
字号:
/*    case ':' : */   }}static Boolean_t case_statement( void ){   step( 1 );   f_constant_expression();   if( token( 0 ) == ':' )   {      step( 1 );   }   return True;}static Boolean_t default_statement( void ){   step( 1 );   if( token( 0 ) == ':' )   {      step( 1 );   }   return True;}static Boolean_t if_statement( void ){   niveau++;   step( 1 );   if( token( 0 ) == '(' )   {      step( 1 );   }   f_expression();   if( token( 0 ) == ')' )   {      step( 1 );   }   niveau--;   return True;}static Boolean_t else_statement( void ){   step( 1 );   return True;}static Boolean_t switch_statement( void ){   niveau++;   step( 1 );   if( token( 0 ) == '(' )   {      step( 1 );   }   f_expression();   if( token( 0 ) == ')' )   {      step( 1 );   }   niveau--;   return True;}static Boolean_t while_statement( void ){   niveau++;   step( 1 );   if( token( 0 ) == '(' )   {      step( 1 );   }   f_expression();   if( token( 0 ) == ')' )   {      step( 1 );   }   niveau--;   return True;}static Boolean_t do_statement( void ){   step( 1 );   return True;}static Boolean_t for_statement( void ){   niveau++;   step( 1 );   if( token( 0 ) == '(' )   {      step( 1 );   }   if( ! declaration_statement1())   {      expression_statement();   }   f_expression();   if( token( 0 ) == ';' )   {      step( 1 );   }   f_expression();   if( token( 0 ) == ')' )   {      step( 1 );   }   niveau--;   return True;}static Boolean_t break_statement( void ){   step( 1 );   if( token( 0 ) == ';' )   {      step( 1 );   }   return True;}static Boolean_t continue_statement( void ){   step( 1 );   if( token( 0 ) == ';' )   {      step( 1 );   }   return True;}static Boolean_t return_statement( void ){   step( 1 );   f_expression();   if( token( 0 ) == ';' )   {      step( 1 );   }   return True;}static Boolean_t throw_statement( void ){   step( 1 );   if( token( 0 ) != ';' )   {      f_assignment_expression();   }   if( token( 0 ) == ';' )   {      step( 1 );   }   return True;}static Boolean_t goto_statement( void ){   step( 1 );   if( token( 0 ) == SN_IDENTIFIER )   {      step( 1 );   }   if( token( 0 ) == ';' )   {      step( 1 );   }   return True;}static Boolean_t labeled_statement( void ){   Save();   step( 1 );   if( token( 0 ) == ':' )   {      step( 1 );      return True;   }   else   {      Restore();      return False;   }}static Boolean_t expression_statement( void ){   Save();   if( f_expression())   {      if( token( 0 ) == ';' )      {         step( 1 );      }      else      {#ifdef CORVEX         printf( "expected ';' at end of expression statement: %s:%d.%d\n"               , filename_g               , f_lineno( 0 )               , f_charno( 0 )               );#endif      }      return True;   }   Restore();   return False;}static Boolean_t declaration_statement1( void ){   Declaration_t Declaration;   int record;   Save();   xprintf( "declaration_statement1\n" );   if(( Declaration = f_Declaration( LEVEL_1 )))   {      xprintf( "declaration_statement1: OK: %s\n", ident( 0 ));      f_DeclarationProcess( Declaration, record = True );      f_DeclarationDestroy( Declaration );      return True;   }   else   {      xprintf( "declaration_statement1: 0\n" );      Restore();      return False;   }}static Boolean_t declaration_statement2( void ){   Declaration_t Declaration;   int record;   Save();   xprintf( "declaration_statement2\n" );   if(( Declaration = f_Declaration( LEVEL_2 )))   {      xprintf( "declaration_statement2: OK: %s\n", ident( 0 ));      f_DeclarationProcess( Declaration, record = True );      f_DeclarationDestroy( Declaration );      return True;   }   else   {      xprintf( "declaration_statement2: 0\n" );      Restore();      return False;   }}static Boolean_t try_statement( void ){   step( 1 );   compound_statement();   handler_list();   return True;}static Boolean_t handler_list( void ){   Save();   if( ! handler())   {      Restore();      return False;   }   while( handler())   {   }   return True;}static Boolean_t handler( void ){   if( token( 0 ) == SN_CATCH )   {      step( 1 );      if( token( 0 ) == '(' )      {         int i = 1;         step( 1 );         while( i > 0 )         {            switch( token( 0 ))            {            case '(': i++; break;            case ')': i--; break;            }            step( 1 );         }      }      compound_statement();      return True;   }   else   {      return False;   }}static void CompCreate( void ){   Comp_t Comp = (Comp_t) Malloc( sizeof( Comp[0] ));   niveauComp++;   Comp->CompParent = CompAct;   CompAct = Comp;}static void CompDestroy( void ){   Comp_t Comp = CompAct;   CompAct = Comp->CompParent;   niveauComp--;   SymtabNiveauDestroy( SymtabVariable, niveauComp );   SymtabNiveauDestroy( SymtabClass   , niveauComp );   ckfree( (char*)Comp );}/* az annyival okosabb. mint az strchr, hogy a <...> -on belul nem keres */static char *my_strchr( char *pc, char c ){   int in = 0;   while( True )   {      if( *pc == 0 ) return 0;      if( ! in && *pc == c ) return pc;      if( *pc == '<' ) in++;      if( *pc == '>' ) in--;      pc++;   }}

⌨️ 快捷键说明

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