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

📄 lexyy.c

📁 这是linux下运行的mysql软件包,可用于linux 下安装 php + mysql + apach 的网络配置
💻 C
📖 第 1 页 / 共 5 页
字号:
        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,    1,    1,    1,    1,    1,        1,    1,    1,    1,    1,    1,    1,    1,    9,    9,       10,   10,   21,   28,   21,   24,   24,   29,   28,   30,       31,   29,  369,   30,   31,   32,   30,   32,   33,   30,       31,   35,   30,   36,   37,   33,   40,   29,   33,   35,       37,   33,   38,   36,   35,   40,   40,   41,   42,   43,       38,   43,   38,   45,   38,   42,   49,   38,   63,   41,       45,   49,   42,   41,   52,   52,   56,   41,   56,   68,       69,   69,   72,   93,   63,   68,   82,   97,   69,   93,       94,   72,   96,   99,  110,   97,  107,  125,   72,  110,      107,   82,   82,   96,   99,   94,  111,  128,  128,   94,      134,  111,  141,  125,  134,  142,  166,  166,  364,  363,      362,  361,  360,  359,  357,  142,  356,  141,  166,  367,      367,  367,  367,  368,  368,  368,  368,  370,  370,  355,      370,  371,  371,  371,  371,  372,  354,  372,  372,  353,      352,  351,  350,  349,  348,  346,  344,  341,  339,  338,      336,  335,  334,  333,  331,  329,  327,  326,  325,  324,      322,  320,  319,  316,  315,  313,  312,  309,  308,  307,      303,  302,  301,  300,  297,  296,  295,  293,  292,  290,      288,  286,  285,  283,  281,  279,  276,  275,  271,  270,      269,  268,  267,  266,  264,  263,  262,  261,  260,  259,      258,  257,  256,  255,  253,  252,  251,  249,  244,  243,      242,  241,  240,  239,  238,  236,  235,  234,  233,  231,      229,  227,  226,  225,  224,  223,  222,  221,  220,  218,      217,  216,  215,  214,  213,  212,  211,  210,  208,  207,      206,  203,  201,  199,  198,  197,  196,  194,  193,  192,      190,  189,  187,  186,  185,  184,  183,  182,  181,  180,      179,  178,  177,  175,  174,  173,  172,  171,  170,  169,      168,  167,  165,  164,  163,  161,  158,  157,  156,  155,      154,  153,  152,  151,  150,  148,  147,  146,  145,  144,      143,  140,  139,  137,  136,  133,  132,  131,  130,  129,      127,  126,  124,  123,  122,  121,  120,  119,  118,  115,      114,  108,  106,  105,  104,  103,  102,  101,  100,   98,       95,   92,   91,   90,   87,   86,   85,   84,   80,   79,       78,   77,   76,   75,   74,   73,   71,   70,   67,   65,       64,   62,   55,   51,   44,   39,   26,   22,   20,   19,        7,    6,    5,    4,    3,  366,  366,  366,  366,  366,      366,  366,  366,  366,  366,  366,  366,  366,  366,  366,      366,  366,  366,  366,  366,  366,  366,  366,  366,  366,      366,  366,  366,  366,  366,  366,  366,  366,  366,  366,      366,  366,  366,  366,  366,  366,  366,  366,  366,  366,      366,  366,  366,  366    } ;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 "pars0lex.l"#define INITIAL 0/******************************************************SQL parser lexical analyzer: input file for the GNU Flex lexer generator(c) 1997 Innobase OyCreated 12/14/1997 Heikki TuuriPublished under the GPL version 2The InnoDB parser is frozen because MySQL takes care of SQL parsing.Therefore we normally keep the InnoDB parser C files as they are, and donot automatically generate them from pars0grm.y and pars0lex.l.How to make the InnoDB parser and lexer C files:1. First do        bison -d pars0grm.y   That generates pars0grm.tab.c and pars0grm.tab.h.2. Rename pars0grm.tab.c to pars0grm.c and pars0grm.tab.h to pars0grm.h.3. Copy pars0grm.h also to /innobase/include4. Do        flex pars0lex.l   That generates lex.yy.c.5. Rename lex.yy.c to lexyy.c.6. Remove the #include of unistd.h from about line 2500 of lexyy.c7. Add '#include "univ.i"' before #include <stdio.h> in lexyy.c   (Needed for AIX)8. Add a type cast to int to the assignment below the comment   'need more input.'  (Removes a warning on Win64)These instructions seem to work at least with bison-1.28 and flex-2.5.4 onLinux.*******************************************************/#define YY_NEVER_INTERACTIVE 1#define YY_NO_INPUT 1#define YY_NO_UNPUT 1#define YY_NO_SCAN_BUFFER 1#define YY_NO_SCAN_BYTES 1#define YY_NO_SCAN_STRING 1#line 52 "pars0lex.l"#define YYSTYPE que_node_t*#include "univ.i"#include "pars0pars.h"#include "pars0grm.h"#include "pars0sym.h"#include "mem0mem.h"#include "os0proc.h"#define malloc(A)	ut_malloc(A)#define free(A)		ut_free(A)#define realloc(P, A)	ut_realloc(P, A)#define exit(A) 	ut_error#define YY_INPUT(buf, result, max_size) pars_get_lex_chars(buf, &result, max_size)/* String buffer for removing quotes */static ulint	stringbuf_len_alloc = 0; /* Allocated length */static ulint	stringbuf_len = 0; /* Current length */static char*	stringbuf; /* Start of buffer *//* Appends a string to the buffer. */staticvoidstring_append(/*==========*/	const char*	str,	/* in: string to be appended */	ulint		len)	/* in: length of the string */{	if (stringbuf == NULL) {		stringbuf = malloc(1);		stringbuf_len_alloc = 1;	}	if (stringbuf_len + len > stringbuf_len_alloc) {		while (stringbuf_len + len > stringbuf_len_alloc) {			stringbuf_len_alloc <<= 1;		}		stringbuf = realloc(stringbuf, stringbuf_len_alloc);	}	memcpy(stringbuf + stringbuf_len, str, len);	stringbuf_len += len;}#define comment 1#define quoted 2#line 676 "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 102 "pars0lex.l"#line 830 "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 >= 367 )					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] != 396 );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 104 "pars0lex.l"{			yylval = sym_tab_add_int_lit(pars_sym_tab_global,								atoi(yytext));			return(PARS_INT_LIT);}	YY_BREAKcase 2:YY_RULE_SETUP#line 110 "pars0lex.l"{			ut_error;	/* not implemented */			return(PARS_FLOAT_LIT);}	YY_BREAKcase 3:YY_RULE_SETUP#line 116 "pars0lex.l"{/* Quoted character string literals are handled in an explicitstart state 'quoted'.  This state is entered and the buffer forthe scanned string is emptied upon encountering a starting quote.In the state 'quoted', only two actions are possible (defined below). */			BEGIN(quoted);			stringbuf_len = 0;}	YY_BREAKcase 4:YY_RULE_SETUP#line 125 "pars0lex.l"{			/* Got a sequence of characters other than "'":			append to string buffer */			string_append(yytext, yyleng);}	YY_BREAKcase 5:YY_RULE_SETUP#line 130 "pars0lex.l"{			/* Got a sequence of "'" characters:			append half of them to string buffer,			as "''" represents a single "'".			We apply truncating division,			so that "'''" will result in "'". */			string_append(yytext, yyleng / 2);			/* If we got an odd number of quotes, then the			last quote we got is the terminating quote.			At the end of the string, we return to the			initial start state and report the scanned			string literal. */			if (yyleng % 2) {				BEGIN(INITIAL);				yylval = sym_tab_add_str_lit(					pars_sym_tab_global,					(byte*) stringbuf, stringbuf_len);				return(PARS_STR_LIT);			}}	YY_BREAKcase 6:YY_RULE_SETUP#line 154 "pars0lex.l"{			yylval = sym_tab_add_null_lit(pars_sym_tab_global);			return(PARS_NULL_LIT);}	YY_BREAKcase 7:YY_RULE_SETUP#line 160 "pars0lex.l"{			/* Implicit cursor name */			yylval = sym_tab_add_str_lit(pars_sym_tab_global,							(byte*) yytext, yyleng);			return(PARS_SQL_TOKEN);}	YY_BREAKcase 8:YY_RULE_SETUP#line 167 "pars0lex.l"{			return(PARS_AND_TOKEN);}	YY_BREAKcase 9:YY_RULE_SETUP#line 171 "pars0lex.l"{			return(PARS_OR_TOKEN);}	YY_BREAKcase 10:YY_RULE_SETUP#line 175 "pars0lex.l"{			return(PARS_NOT_TOKEN);}	YY_BREAKcase 11:YY_RULE_SETUP#line 179 "pars0lex.l"{			return(PARS_PROCEDURE_TOKEN);}	YY_BREAKcase 12:YY_RULE_SETUP#line 183 "pars0lex.l"{			return(PARS_IN_TOKEN);}	YY_BREAKcase 13:YY_RULE_SETUP#line 187 "pars0lex.l"{			return(PARS_OUT_TOKEN);

⌨️ 快捷键说明

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