Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/AnonR/anonr.TX.../proc/self/root/usr/include
File: FlexLexer.h
// -*-C++-*-
[0] Fix | Delete
// FlexLexer.h -- define interfaces for lexical analyzer classes generated
[1] Fix | Delete
// by flex
[2] Fix | Delete
[3] Fix | Delete
// Copyright (c) 1993 The Regents of the University of California.
[4] Fix | Delete
// All rights reserved.
[5] Fix | Delete
//
[6] Fix | Delete
// This code is derived from software contributed to Berkeley by
[7] Fix | Delete
// Kent Williams and Tom Epperly.
[8] Fix | Delete
//
[9] Fix | Delete
// Redistribution and use in source and binary forms, with or without
[10] Fix | Delete
// modification, are permitted provided that the following conditions
[11] Fix | Delete
// are met:
[12] Fix | Delete
[13] Fix | Delete
// 1. Redistributions of source code must retain the above copyright
[14] Fix | Delete
// notice, this list of conditions and the following disclaimer.
[15] Fix | Delete
// 2. Redistributions in binary form must reproduce the above copyright
[16] Fix | Delete
// notice, this list of conditions and the following disclaimer in the
[17] Fix | Delete
// documentation and/or other materials provided with the distribution.
[18] Fix | Delete
[19] Fix | Delete
// Neither the name of the University nor the names of its contributors
[20] Fix | Delete
// may be used to endorse or promote products derived from this software
[21] Fix | Delete
// without specific prior written permission.
[22] Fix | Delete
[23] Fix | Delete
// THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
[24] Fix | Delete
// IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
[25] Fix | Delete
// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
[26] Fix | Delete
// PURPOSE.
[27] Fix | Delete
[28] Fix | Delete
// This file defines FlexLexer, an abstract class which specifies the
[29] Fix | Delete
// external interface provided to flex C++ lexer objects, and yyFlexLexer,
[30] Fix | Delete
// which defines a particular lexer class.
[31] Fix | Delete
//
[32] Fix | Delete
// If you want to create multiple lexer classes, you use the -P flag
[33] Fix | Delete
// to rename each yyFlexLexer to some other xxFlexLexer. You then
[34] Fix | Delete
// include <FlexLexer.h> in your other sources once per lexer class:
[35] Fix | Delete
//
[36] Fix | Delete
// #undef yyFlexLexer
[37] Fix | Delete
// #define yyFlexLexer xxFlexLexer
[38] Fix | Delete
// #include <FlexLexer.h>
[39] Fix | Delete
//
[40] Fix | Delete
// #undef yyFlexLexer
[41] Fix | Delete
// #define yyFlexLexer zzFlexLexer
[42] Fix | Delete
// #include <FlexLexer.h>
[43] Fix | Delete
// ...
[44] Fix | Delete
[45] Fix | Delete
#ifndef __FLEX_LEXER_H
[46] Fix | Delete
// Never included before - need to define base class.
[47] Fix | Delete
#define __FLEX_LEXER_H
[48] Fix | Delete
[49] Fix | Delete
#include <iostream>
[50] Fix | Delete
[51] Fix | Delete
extern "C++" {
[52] Fix | Delete
[53] Fix | Delete
struct yy_buffer_state;
[54] Fix | Delete
typedef int yy_state_type;
[55] Fix | Delete
[56] Fix | Delete
class FlexLexer
[57] Fix | Delete
{
[58] Fix | Delete
public:
[59] Fix | Delete
virtual ~FlexLexer() { }
[60] Fix | Delete
[61] Fix | Delete
const char* YYText() const { return yytext; }
[62] Fix | Delete
int YYLeng() const { return yyleng; }
[63] Fix | Delete
[64] Fix | Delete
virtual void
[65] Fix | Delete
yy_switch_to_buffer( yy_buffer_state* new_buffer ) = 0;
[66] Fix | Delete
virtual yy_buffer_state* yy_create_buffer( std::istream* s, int size ) = 0;
[67] Fix | Delete
virtual yy_buffer_state* yy_create_buffer( std::istream& s, int size ) = 0;
[68] Fix | Delete
virtual void yy_delete_buffer( yy_buffer_state* b ) = 0;
[69] Fix | Delete
virtual void yyrestart( std::istream* s ) = 0;
[70] Fix | Delete
virtual void yyrestart( std::istream& s ) = 0;
[71] Fix | Delete
[72] Fix | Delete
virtual int yylex() = 0;
[73] Fix | Delete
[74] Fix | Delete
// Call yylex with new input/output sources.
[75] Fix | Delete
int yylex( std::istream& new_in, std::ostream& new_out )
[76] Fix | Delete
{
[77] Fix | Delete
switch_streams( new_in, new_out );
[78] Fix | Delete
return yylex();
[79] Fix | Delete
}
[80] Fix | Delete
[81] Fix | Delete
int yylex( std::istream* new_in, std::ostream* new_out = 0)
[82] Fix | Delete
{
[83] Fix | Delete
switch_streams( new_in, new_out );
[84] Fix | Delete
return yylex();
[85] Fix | Delete
}
[86] Fix | Delete
[87] Fix | Delete
// Switch to new input/output streams. A nil stream pointer
[88] Fix | Delete
// indicates "keep the current one".
[89] Fix | Delete
virtual void switch_streams( std::istream* new_in,
[90] Fix | Delete
std::ostream* new_out ) = 0;
[91] Fix | Delete
virtual void switch_streams( std::istream& new_in,
[92] Fix | Delete
std::ostream& new_out ) = 0;
[93] Fix | Delete
[94] Fix | Delete
int lineno() const { return yylineno; }
[95] Fix | Delete
[96] Fix | Delete
int debug() const { return yy_flex_debug; }
[97] Fix | Delete
void set_debug( int flag ) { yy_flex_debug = flag; }
[98] Fix | Delete
[99] Fix | Delete
protected:
[100] Fix | Delete
char* yytext;
[101] Fix | Delete
int yyleng;
[102] Fix | Delete
int yylineno; // only maintained if you use %option yylineno
[103] Fix | Delete
int yy_flex_debug; // only has effect with -d or "%option debug"
[104] Fix | Delete
};
[105] Fix | Delete
[106] Fix | Delete
}
[107] Fix | Delete
#endif // FLEXLEXER_H
[108] Fix | Delete
[109] Fix | Delete
#if defined(yyFlexLexer) || ! defined(yyFlexLexerOnce)
[110] Fix | Delete
// Either this is the first time through (yyFlexLexerOnce not defined),
[111] Fix | Delete
// or this is a repeated include to define a different flavor of
[112] Fix | Delete
// yyFlexLexer, as discussed in the flex manual.
[113] Fix | Delete
# define yyFlexLexerOnce
[114] Fix | Delete
[115] Fix | Delete
extern "C++" {
[116] Fix | Delete
[117] Fix | Delete
class yyFlexLexer : public FlexLexer {
[118] Fix | Delete
public:
[119] Fix | Delete
// arg_yyin and arg_yyout default to the cin and cout, but we
[120] Fix | Delete
// only make that assignment when initializing in yylex().
[121] Fix | Delete
yyFlexLexer( std::istream& arg_yyin, std::ostream& arg_yyout );
[122] Fix | Delete
yyFlexLexer( std::istream* arg_yyin = 0, std::ostream* arg_yyout = 0 );
[123] Fix | Delete
private:
[124] Fix | Delete
void ctor_common();
[125] Fix | Delete
[126] Fix | Delete
public:
[127] Fix | Delete
[128] Fix | Delete
virtual ~yyFlexLexer();
[129] Fix | Delete
[130] Fix | Delete
void yy_switch_to_buffer( yy_buffer_state* new_buffer );
[131] Fix | Delete
yy_buffer_state* yy_create_buffer( std::istream* s, int size );
[132] Fix | Delete
yy_buffer_state* yy_create_buffer( std::istream& s, int size );
[133] Fix | Delete
void yy_delete_buffer( yy_buffer_state* b );
[134] Fix | Delete
void yyrestart( std::istream* s );
[135] Fix | Delete
void yyrestart( std::istream& s );
[136] Fix | Delete
[137] Fix | Delete
void yypush_buffer_state( yy_buffer_state* new_buffer );
[138] Fix | Delete
void yypop_buffer_state();
[139] Fix | Delete
[140] Fix | Delete
virtual int yylex();
[141] Fix | Delete
virtual void switch_streams( std::istream& new_in, std::ostream& new_out );
[142] Fix | Delete
virtual void switch_streams( std::istream* new_in = 0, std::ostream* new_out = 0 );
[143] Fix | Delete
virtual int yywrap();
[144] Fix | Delete
[145] Fix | Delete
protected:
[146] Fix | Delete
virtual int LexerInput( char* buf, int max_size );
[147] Fix | Delete
virtual void LexerOutput( const char* buf, int size );
[148] Fix | Delete
virtual void LexerError( const char* msg );
[149] Fix | Delete
[150] Fix | Delete
void yyunput( int c, char* buf_ptr );
[151] Fix | Delete
int yyinput();
[152] Fix | Delete
[153] Fix | Delete
void yy_load_buffer_state();
[154] Fix | Delete
void yy_init_buffer( yy_buffer_state* b, std::istream& s );
[155] Fix | Delete
void yy_flush_buffer( yy_buffer_state* b );
[156] Fix | Delete
[157] Fix | Delete
int yy_start_stack_ptr;
[158] Fix | Delete
int yy_start_stack_depth;
[159] Fix | Delete
int* yy_start_stack;
[160] Fix | Delete
[161] Fix | Delete
void yy_push_state( int new_state );
[162] Fix | Delete
void yy_pop_state();
[163] Fix | Delete
int yy_top_state();
[164] Fix | Delete
[165] Fix | Delete
yy_state_type yy_get_previous_state();
[166] Fix | Delete
yy_state_type yy_try_NUL_trans( yy_state_type current_state );
[167] Fix | Delete
int yy_get_next_buffer();
[168] Fix | Delete
[169] Fix | Delete
std::istream yyin; // input source for default LexerInput
[170] Fix | Delete
std::ostream yyout; // output sink for default LexerOutput
[171] Fix | Delete
[172] Fix | Delete
// yy_hold_char holds the character lost when yytext is formed.
[173] Fix | Delete
char yy_hold_char;
[174] Fix | Delete
[175] Fix | Delete
// Number of characters read into yy_ch_buf.
[176] Fix | Delete
int yy_n_chars;
[177] Fix | Delete
[178] Fix | Delete
// Points to current character in buffer.
[179] Fix | Delete
char* yy_c_buf_p;
[180] Fix | Delete
[181] Fix | Delete
int yy_init; // whether we need to initialize
[182] Fix | Delete
int yy_start; // start state number
[183] Fix | Delete
[184] Fix | Delete
// Flag which is used to allow yywrap()'s to do buffer switches
[185] Fix | Delete
// instead of setting up a fresh yyin. A bit of a hack ...
[186] Fix | Delete
int yy_did_buffer_switch_on_eof;
[187] Fix | Delete
[188] Fix | Delete
[189] Fix | Delete
size_t yy_buffer_stack_top; /**< index of top of stack. */
[190] Fix | Delete
size_t yy_buffer_stack_max; /**< capacity of stack. */
[191] Fix | Delete
yy_buffer_state ** yy_buffer_stack; /**< Stack as an array. */
[192] Fix | Delete
void yyensure_buffer_stack(void);
[193] Fix | Delete
[194] Fix | Delete
// The following are not always needed, but may be depending
[195] Fix | Delete
// on use of certain flex features (like REJECT or yymore()).
[196] Fix | Delete
[197] Fix | Delete
yy_state_type yy_last_accepting_state;
[198] Fix | Delete
char* yy_last_accepting_cpos;
[199] Fix | Delete
[200] Fix | Delete
yy_state_type* yy_state_buf;
[201] Fix | Delete
yy_state_type* yy_state_ptr;
[202] Fix | Delete
[203] Fix | Delete
char* yy_full_match;
[204] Fix | Delete
int* yy_full_state;
[205] Fix | Delete
int yy_full_lp;
[206] Fix | Delete
[207] Fix | Delete
int yy_lp;
[208] Fix | Delete
int yy_looking_for_trail_begin;
[209] Fix | Delete
[210] Fix | Delete
int yy_more_flag;
[211] Fix | Delete
int yy_more_len;
[212] Fix | Delete
int yy_more_offset;
[213] Fix | Delete
int yy_prev_more_offset;
[214] Fix | Delete
};
[215] Fix | Delete
[216] Fix | Delete
}
[217] Fix | Delete
[218] Fix | Delete
#endif // yyFlexLexer || ! yyFlexLexerOnce
[219] Fix | Delete
[220] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function