rclex.c

来自「基于4个mips核的noc设计」· C语言 代码 · 共 2,490 行 · 第 1/5 页

C
2,490
字号
       19,   19,   19,   28,   29,   30,   37,   30,   50,   41,       52,   55,   51,   42,   81,   38,   43,   56,   82,   63,       53,   39,   83,   40,   44,   95,   67,   64,   54,   96,       59,   45,   60,   65,  103,   46,   68,   66,   47,   34,       61,   62,   48,   49,   70,   73,   71,   74,   76,   72,       77,  104,   30,   78,   30,   84,   90,  108,   85,   91,       98,   99,  111,   75,   79,  113,  123,  109,  126,  129,      124,  131,  132,  114,  139,  468,  112,   84,  127,  130,       85,  205,  225,  467,  206,  241,  269,  269,  242,  270,      140,  226,  243,  295,  227,  228,  141,  229,  207,  273,      304,  466,  274,  269,  269,  305,  319,  465,  321,  296,      321,  322,   36,  321,  321,  464,  321,  322,   36,  321,      321,  463,  321,  322,   36,  321,   31,   31,  462,   31,       31,   33,   33,  461,   33,   33,   36,  460,  459,   36,       36,  320,  320,  458,  320,  320,  321,  321,  457,  456,      321,  455,  454,  453,  452,  451,  450,  449,  448,  447,      446,  445,  444,  443,  442,  441,  440,  439,  438,  437,      436,  435,  434,  433,  432,  431,  430,  429,  428,  427,      426,  425,  424,  423,  422,  421,  420,  419,  418,  417,      416,  415,  414,  413,  412,  411,  410,  409,  408,  407,      406,  405,  404,  403,  402,  401,  400,  399,  398,  364,      397,  396,  395,  394,  393,  392,  391,  390,  389,  388,      387,  386,  385,  384,  383,  382,  381,  380,  379,  378,      377,  376,  375,  374,  373,  372,  371,  370,  369,  368,      367,  366,  365,  364,  364,  363,  362,  361,  360,  359,      358,  357,  356,  355,  354,  353,  352,  351,  350,  349,      348,  347,  346,  345,  344,  343,  342,  341,  340,  339,      338,  337,  336,  335,  334,  333,  332,  331,  330,  329,      328,  327,  326,  325,  324,  323,  318,  317,  316,  315,      314,  313,  312,  311,  310,  309,  308,  307,  306,  303,      302,  301,  300,  299,  298,  297,  294,  293,  292,  291,      290,  289,  288,  287,  286,  285,  284,  283,  282,  281,      280,  279,  278,  277,  276,  275,  272,  271,  268,  267,      266,  265,  264,  263,  262,  261,  260,  259,  258,  257,      256,  255,  254,  253,  252,  251,  250,  249,  248,  247,      246,  245,  244,  240,  239,  238,  237,  236,  235,  234,      233,  232,  231,  230,  224,  223,  222,  221,  220,  219,      218,  217,  216,  215,  214,  213,  212,  211,  210,  209,      208,  204,  203,  202,  201,  200,  199,  198,  197,  196,      195,  194,  193,  192,  191,  190,  189,  188,  187,  186,      185,  184,  183,  182,  181,  180,  179,  178,  177,  176,      175,  174,  173,  172,  171,  170,  169,  168,  167,  166,      165,  164,  163,  162,  161,  160,  159,  158,  157,  156,      155,  154,  153,  152,  151,  150,  149,  148,  147,  146,       32,  145,  144,  143,  142,  138,  137,  136,  135,  134,      133,  128,  125,  122,  121,  120,  119,  118,  117,  116,      115,  110,  107,  106,  105,  102,  101,  100,   97,   94,       93,   92,   89,   88,   87,   86,   35,   32,   80,   69,       58,   57,   35,   32,  469,    3,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469    } ;static yyconst short int yy_chk[552] =    {   0,        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,        1,    1,    1,    1,    1,    5,   10,    5,   13,   11,       14,   15,   13,   11,   27,   10,   11,   15,   27,   20,       14,   10,   27,   10,   12,   45,   21,   20,   14,   45,       18,   12,   18,   20,   51,   12,   21,   20,   12,  472,       18,   18,   12,   12,   23,   24,   23,   24,   25,   23,       25,   51,   30,   25,   30,   32,   41,   55,   32,   41,       47,   47,   57,   24,   25,   58,   67,   55,   69,   71,       67,   72,   72,   58,   79,  465,   57,   84,   69,   71,       84,  148,  166,  464,  148,  181,  211,  211,  181,  211,       79,  166,  181,  241,  166,  166,   79,  166,  148,  214,      250,  463,  214,  269,  269,  250,  269,  460,  270,  241,      270,  270,  270,  270,  320,  459,  320,  320,  320,  320,      322,  458,  322,  322,  322,  322,  470,  470,  455,  470,      470,  471,  471,  454,  471,  471,  473,  453,  452,  473,      473,  474,  474,  446,  474,  474,  475,  475,  445,  444,      475,  441,  439,  438,  437,  436,  435,  434,  432,  431,      429,  428,  427,  425,  424,  423,  422,  421,  420,  419,      418,  416,  415,  414,  413,  410,  409,  408,  407,  405,      404,  403,  402,  401,  400,  399,  398,  397,  396,  395,      394,  393,  392,  391,  390,  389,  388,  387,  386,  383,      381,  380,  379,  375,  373,  372,  370,  368,  365,  364,      363,  362,  361,  360,  358,  357,  356,  355,  354,  353,      352,  350,  348,  347,  346,  345,  344,  343,  342,  340,      339,  338,  337,  336,  335,  334,  332,  331,  330,  329,      327,  325,  324,  321,  319,  318,  317,  316,  315,  314,      313,  312,  311,  309,  308,  306,  305,  304,  303,  302,      301,  300,  299,  298,  296,  295,  294,  293,  292,  291,      289,  287,  286,  285,  283,  282,  281,  280,  279,  278,      276,  275,  274,  273,  272,  271,  267,  266,  265,  264,      263,  262,  260,  258,  257,  255,  254,  252,  251,  249,      248,  246,  245,  244,  243,  242,  239,  238,  237,  236,      235,  232,  231,  229,  228,  227,  226,  225,  224,  223,      222,  221,  220,  219,  217,  216,  213,  212,  210,  207,      206,  205,  203,  202,  201,  200,  199,  198,  197,  196,      195,  194,  193,  192,  191,  190,  189,  187,  186,  185,      184,  183,  182,  180,  179,  178,  177,  176,  175,  174,      171,  170,  169,  167,  165,  164,  163,  162,  161,  160,      159,  158,  157,  156,  155,  154,  153,  152,  151,  150,      149,  147,  146,  145,  144,  143,  142,  141,  140,  139,      138,  137,  136,  135,  134,  133,  132,  131,  130,  129,      128,  126,  125,  124,  123,  122,  121,  120,  119,  118,      117,  116,  115,  114,  113,  112,  111,  110,  109,  108,      107,  105,  104,  103,  102,  101,  100,   99,   98,   97,       96,   95,   94,   93,   92,   91,   90,   89,   88,   86,       85,   83,   82,   81,   80,   78,   77,   76,   75,   74,       73,   70,   68,   66,   65,   64,   63,   62,   61,   60,       59,   56,   54,   53,   52,   50,   49,   48,   46,   44,       43,   42,   40,   39,   38,   37,   34,   31,   26,   22,       17,   16,    9,    7,    3,  469,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469,  469,  469,  469,  469,  469,  469,  469,  469,  469,      469    } ;static yy_state_type yy_last_accepting_state;static char *yy_last_accepting_cpos;/* The intent behind this definition is that it'll catch * any uses of REJECT which flex missed. */#define REJECT reject_used_but_not_detected#define yymore() yymore_used_but_not_detected#define YY_MORE_ADJ 0#define YY_RESTORE_YY_MORE_OFFSETchar *yytext;#line 1 "rclex.l"#define INITIAL 0#line 2 "rclex.l"/* Copyright 1997, 1998, 1999 Free Software Foundation, Inc.   Written by Ian Lance Taylor, Cygnus Support.   This file is part of GNU Binutils.   This program is free software; you can redistribute it and/or modify   it under the terms of the GNU General Public License as published by   the Free Software Foundation; either version 2 of the License, or   (at your option) any later version.   This program is distributed in the hope that it will be useful,   but WITHOUT ANY WARRANTY; without even the implied warranty of   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the   GNU General Public License for more details.   You should have received a copy of the GNU General Public License   along with this program; if not, write to the Free Software   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA   02111-1307, USA.  *//* This is a lex input file which generates a lexer used by the   Windows rc file parser.  It basically just recognized a bunch of   keywords.  */#include "bfd.h"#include "bucomm.h"#include "libiberty.h"#include "windres.h"#include "rcparse.h"#include <ctype.h>#include <assert.h>/* Whether we are in rcdata mode, in which we returns the lengths of   strings.  */static int rcdata_mode;/* Whether we are supressing lines from cpp (including windows.h or   headers from your C sources may bring in externs and typedefs).   When active, we return IGNORED_TOKEN, which lets us ignore these   outside of resource constructs.  Thus, it isn't required to protect   all the non-preprocessor lines in your header files with #ifdef   RC_INVOKED.  It also means your RC file can't include other RC   files if they're named "*.h".  Sorry.  Name them *.rch or whatever.  */static int suppress_cpp_data;#define MAYBE_RETURN(x) return suppress_cpp_data ? IGNORED_TOKEN : (x)/* The first filename we detect in the cpp output.  We use this to   tell included files from the original file.  */static char *initial_fn;/* List of allocated strings.  */struct alloc_string{  struct alloc_string *next;  char *s;};static struct alloc_string *strings;/* Local functions.  */static void cpp_line PARAMS ((const char *));static char *handle_quotes PARAMS ((const char *, unsigned long *));static char *get_string PARAMS ((int));#line 710 "lex.yy.c"/* Macros after this point can all be overridden by user definitions in * section 1. */#ifndef YY_SKIP_YYWRAP#ifdef __cplusplusextern "C" int yywrap YY_PROTO(( void ));#elseextern int yywrap YY_PROTO(( void ));#endif#endif#ifndef YY_NO_UNPUTstatic void yyunput YY_PROTO(( int c, char *buf_ptr ));#endif#ifndef yytext_ptrstatic void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));#endif#ifdef YY_NEED_STRLENstatic int yy_flex_strlen YY_PROTO(( yyconst char * ));#endif#ifndef YY_NO_INPUT#ifdef __cplusplusstatic int yyinput YY_PROTO(( void ));#elsestatic int input YY_PROTO(( void ));#endif#endif#if YY_STACK_USEDstatic int yy_start_stack_ptr = 0;static int yy_start_stack_depth = 0;static int *yy_start_stack = 0;#ifndef YY_NO_PUSH_STATEstatic void yy_push_state YY_PROTO(( int new_state ));#endif#ifndef YY_NO_POP_STATEstatic void yy_pop_state YY_PROTO(( void ));#endif#ifndef YY_NO_TOP_STATEstatic int yy_top_state YY_PROTO(( void ));#endif#else#define YY_NO_PUSH_STATE 1#define YY_NO_POP_STATE 1#define YY_NO_TOP_STATE 1#endif#ifdef YY_MALLOC_DECLYY_MALLOC_DECL#else#if __STDC__#ifndef __cplusplus#include <stdlib.h>#endif#else/* Just try to get by without declaring the routines.  This will fail * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int) * or sizeof(void*) != sizeof(int). */#endif#endif/* Amount of stuff to slurp up with each read. */#ifndef YY_READ_BUF_SIZE#define YY_READ_BUF_SIZE 8192#endif/* Copy whatever the last rule matched to the standard output. */#ifndef ECHO/* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )#endif/* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL, * is returned in "result". */#ifndef YY_INPUT#define YY_INPUT(buf,result,max_size) \	if ( yy_current_buffer->yy_is_interactive ) \		{ \		int c = '*', n; \		for ( n = 0; n < max_size && \			     (c = getc( yyin )) != EOF && c != '\n'; ++n ) \			buf[n] = (char) c; \		if ( c == '\n' ) \			buf[n++] = (char) c; \		if ( c == EOF && ferror( yyin ) ) \			YY_FATAL_ERROR( "input in flex scanner failed" ); \		result = n; \		} \	else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \		  && ferror( yyin ) ) \		YY_FATAL_ERROR( "input in flex scanner failed" );#endif/* No semi-colon after return; correct usage is to write "yyterminate();" - * we don't want an extra ';' after the "return" because that will cause * some compilers to complain about unreachable statements. */#ifndef yyterminate#define yyterminate() return YY_NULL#endif/* Number of entries by which start-condition stack grows. */#ifndef YY_START_STACK_INCR#define YY_START_STACK_INCR 25#endif/* Report a fatal error. */#ifndef YY_FATAL_ERROR#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )#endif/* Default declaration of generated scanner - a define so the user can * easily add parameters. */#ifndef YY_DECL#define YY_DECL int yylex YY_PROTO(( void ))#endif/* Code executed at the beginning of each rule, after yytext and yyleng * have been set up. */#ifndef YY_USER_ACTION#define YY_USER_ACTION#endif/* Code executed at the end of each rule. */#ifndef YY_BREAK#define YY_BREAK break;#endif#define YY_RULE_SETUP \	YY_USER_ACTIONYY_DECL	{	register yy_state_type yy_current_state;	register char *yy_cp, *yy_bp;	register int yy_act;#line 75 "rclex.l"#line 864 "lex.yy.c"	if ( yy_init )		{		yy_init = 0;#ifdef YY_USER_INIT		YY_USER_INIT;#endif		if ( ! yy_start )			yy_start = 1;	/* first start state */		if ( ! yyin )			yyin = stdin;		if ( ! yyout )			yyout = stdout;		if ( ! yy_current_buffer )			yy_current_buffer =				yy_create_buffer( yyin, YY_BUF_SIZE );		yy_load_buffer_state();		}	while ( 1 )		/* loops until end-of-file is reached */		{		yy_cp = yy_c_buf_p;		/* Support of yytext. */		*yy_cp = yy_hold_char;		/* yy_bp points to the position in yy_ch_buf of the start of		 * the current run.		 */		yy_bp = yy_cp;		yy_current_state = yy_start;yy_match:		do			{			register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];			if ( yy_accept[yy_current_state] )				{				yy_last_accepting_state = yy_current_state;				yy_last_accepting_cpos = yy_cp;				}			while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )				{				yy_current_state = (int) yy_def[yy_current_state];				if ( yy_current_state >= 470 )					yy_c = yy_meta[(unsigned int) yy_c];				}			yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];			++yy_cp;			}		while ( yy_base[yy_current_state] != 516 );yy_find_action:		yy_act = yy_accept[yy_current_state];		if ( yy_act == 0 )			{ /* have to back up */			yy_cp = yy_last_accepting_cpos;			yy_current_state = yy_last_accepting_state;			yy_act = yy_accept[yy_current_state];			}		YY_DO_BEFORE_ACTION;do_action:	/* This label is used only to access EOF actions. */		switch ( yy_act )	{ /* beginning of action switch */			case 0: /* must back up */			/* undo the effects of YY_DO_BEFORE_ACTION */			*yy_cp = yy_hold_char;			yy_cp = yy_last_accepting_cpos;			yy_current_state = yy_last_accepting_state;			goto yy_find_action;case 1:YY_RULE_SETUP#line 77 "rclex.l"{ MAYBE_RETURN (BEG); }	YY_BREAKcase 2:YY_RULE_SETUP#line 78 "rclex.l"{ MAYBE_RETURN (BEG); }	YY_BREAKcase 3:YY_RULE_SETUP#line 79 "rclex.l"{ MAYBE_RETURN (END); }	YY_BREAKcase 4:YY_RULE_SETUP#line 80 "rclex.l"{ MAYBE_RETURN (END); }	YY_BREAKcase 5:YY_RULE_SETUP#line 81 "rclex.l"{ MAYBE_RETURN (ACCELERATORS); }	YY_BREAKcase 6:YY_RULE_SETUP#line 82 "rclex.l"{ MAYBE_RETURN (VIRTKEY); }	YY_BREAKcase 7:YY_RULE_SETUP#line 83 "rclex.l"{ MAYBE_RETURN (ASCII); }	YY_BREAKcase 8:YY_RULE_SETUP#line 84 "rclex.l"{ MAYBE_RETURN (NOINVERT); }	YY_BREAKcase 9:YY_RULE_SETUP#line 85 "rclex.l"{ MAYBE_RETURN (SHIFT); }	YY_BREAKcase 10:YY_RULE_SETUP#line 86 "rclex.l"{ MAYBE_RETURN (CONTROL); }	YY_BREAKcase 11:

⌨️ 快捷键说明

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