mirror of
https://gitee.com/TarsCloud/TarsCpp.git
synced 2024-12-22 22:16:38 +08:00
update protocol
This commit is contained in:
parent
6eb9ec0253
commit
34c6435833
@ -1 +1 @@
|
||||
Subproject commit b84624baa43088b77e7bb016bc833027a6d9f219
|
||||
Subproject commit 0c24c6a8ea0406c0c3dc6e8e56bc895996bb9cd6
|
@ -9,7 +9,7 @@
|
||||
#define FLEX_SCANNER
|
||||
#define YY_FLEX_MAJOR_VERSION 2
|
||||
#define YY_FLEX_MINOR_VERSION 5
|
||||
#define YY_FLEX_SUBMINOR_VERSION 35
|
||||
#define YY_FLEX_SUBMINOR_VERSION 37
|
||||
#if YY_FLEX_SUBMINOR_VERSION > 0
|
||||
#define FLEX_BETA
|
||||
#endif
|
||||
@ -47,7 +47,6 @@ typedef int16_t flex_int16_t;
|
||||
typedef uint16_t flex_uint16_t;
|
||||
typedef int32_t flex_int32_t;
|
||||
typedef uint32_t flex_uint32_t;
|
||||
typedef uint64_t flex_uint64_t;
|
||||
#else
|
||||
typedef signed char flex_int8_t;
|
||||
typedef short int flex_int16_t;
|
||||
@ -55,7 +54,6 @@ typedef int flex_int32_t;
|
||||
typedef unsigned char flex_uint8_t;
|
||||
typedef unsigned short int flex_uint16_t;
|
||||
typedef unsigned int flex_uint32_t;
|
||||
#endif /* ! C99 */
|
||||
|
||||
/* Limits of integral types. */
|
||||
#ifndef INT8_MIN
|
||||
@ -86,6 +84,8 @@ typedef unsigned int flex_uint32_t;
|
||||
#define UINT32_MAX (4294967295U)
|
||||
#endif
|
||||
|
||||
#endif /* ! C99 */
|
||||
|
||||
#endif /* ! FLEXINT_H */
|
||||
|
||||
#ifdef __cplusplus
|
||||
@ -176,7 +176,7 @@ extern FILE *yyin, *yyout;
|
||||
*/
|
||||
#define YY_LESS_LINENO(n) \
|
||||
do { \
|
||||
yy_size_t yyl;\
|
||||
int yyl;\
|
||||
for ( yyl = n; yyl < yyleng; ++yyl )\
|
||||
if ( yytext[yyl] == '\n' )\
|
||||
--yylineno;\
|
||||
@ -369,7 +369,7 @@ static void yy_fatal_error (yyconst char msg[] );
|
||||
*/
|
||||
#define YY_DO_BEFORE_ACTION \
|
||||
(yytext_ptr) = yy_bp; \
|
||||
yyleng = (yy_size_t) (yy_cp - yy_bp); \
|
||||
yyleng = (size_t) (yy_cp - yy_bp); \
|
||||
(yy_hold_char) = *yy_cp; \
|
||||
*yy_cp = '\0'; \
|
||||
(yy_c_buf_p) = yy_cp;
|
||||
@ -513,7 +513,7 @@ int yy_flex_debug = 0;
|
||||
#define YY_MORE_ADJ 0
|
||||
#define YY_RESTORE_YY_MORE_OFFSET
|
||||
char *yytext;
|
||||
#line 1 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 1 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
/**
|
||||
* Tencent is pleased to support the open source community by making Tars available.
|
||||
*
|
||||
@ -529,7 +529,7 @@ char *yytext;
|
||||
* CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations under the License.
|
||||
*/
|
||||
#line 20 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 20 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#include <map>
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
@ -649,7 +649,7 @@ static int input (void );
|
||||
/* This used to be an fputs(), but since the string might contain NUL's,
|
||||
* we now use fwrite().
|
||||
*/
|
||||
#define ECHO fwrite( yytext, yyleng, 1, yyout )
|
||||
#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
|
||||
#endif
|
||||
|
||||
/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
|
||||
@ -660,7 +660,7 @@ static int input (void );
|
||||
if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
|
||||
{ \
|
||||
int c = '*'; \
|
||||
yy_size_t n; \
|
||||
size_t n; \
|
||||
for ( n = 0; n < max_size && \
|
||||
(c = getc( yyin )) != EOF && c != '\n'; ++n ) \
|
||||
buf[n] = (char) c; \
|
||||
@ -742,7 +742,7 @@ YY_DECL
|
||||
register char *yy_cp, *yy_bp;
|
||||
register int yy_act;
|
||||
|
||||
#line 67 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 67 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
|
||||
|
||||
#line 749 "tars.lex.cpp"
|
||||
@ -840,12 +840,12 @@ do_action: /* This label is used only to access EOF actions. */
|
||||
|
||||
case 1:
|
||||
YY_RULE_SETUP
|
||||
#line 69 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 69 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{ BEGIN(INCL); }
|
||||
YY_BREAK
|
||||
case 2:
|
||||
YY_RULE_SETUP
|
||||
#line 71 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 71 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
if ( include_file_stack_ptr >= MAX_INCLUDE_DEPTH )
|
||||
{
|
||||
@ -878,7 +878,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case YY_STATE_EOF(INITIAL):
|
||||
case YY_STATE_EOF(INCL):
|
||||
#line 101 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 101 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
--include_file_stack_ptr;
|
||||
if ( include_file_stack_ptr < 0 )
|
||||
@ -897,14 +897,14 @@ case YY_STATE_EOF(INCL):
|
||||
YY_BREAK
|
||||
case 3:
|
||||
YY_RULE_SETUP
|
||||
#line 117 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 117 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
return TARS_SCOPE_DELIMITER;
|
||||
}
|
||||
YY_BREAK
|
||||
case 4:
|
||||
YY_RULE_SETUP
|
||||
#line 121 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 121 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
// C++ comment
|
||||
bool e = false;
|
||||
@ -925,7 +925,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 5:
|
||||
YY_RULE_SETUP
|
||||
#line 139 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 139 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
// C comment
|
||||
bool e = false;
|
||||
@ -976,7 +976,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 6:
|
||||
YY_RULE_SETUP
|
||||
#line 187 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 187 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
StringGrammarPtr ident = new StringGrammar;
|
||||
ident->v = yytext;
|
||||
@ -987,7 +987,7 @@ YY_RULE_SETUP
|
||||
case 7:
|
||||
/* rule 7 can match eol */
|
||||
YY_RULE_SETUP
|
||||
#line 194 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 194 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
StringGrammarPtr ident = new StringGrammar;
|
||||
ident->v = yytext;
|
||||
@ -1000,7 +1000,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 8:
|
||||
YY_RULE_SETUP
|
||||
#line 204 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 204 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
StringGrammarPtr str = new StringGrammar;
|
||||
bool e = false;
|
||||
@ -1115,7 +1115,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 9:
|
||||
YY_RULE_SETUP
|
||||
#line 316 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 316 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
errno = 0;
|
||||
IntergerGrammarPtr ptr = new IntergerGrammar;
|
||||
@ -1140,7 +1140,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 10:
|
||||
YY_RULE_SETUP
|
||||
#line 338 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 338 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
errno = 0;
|
||||
FloatGrammarPtr ptr = new FloatGrammar;
|
||||
@ -1175,7 +1175,7 @@ YY_RULE_SETUP
|
||||
case 11:
|
||||
/* rule 11 can match eol */
|
||||
YY_RULE_SETUP
|
||||
#line 369 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 369 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
if(yytext[0] == '\n')
|
||||
{
|
||||
@ -1185,7 +1185,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 12:
|
||||
YY_RULE_SETUP
|
||||
#line 376 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 376 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
{
|
||||
if(yytext[0] < 32 || yytext[0] > 126)
|
||||
{
|
||||
@ -1204,7 +1204,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 13:
|
||||
YY_RULE_SETUP
|
||||
#line 392 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 392 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
ECHO;
|
||||
YY_BREAK
|
||||
#line 1211 "tars.lex.cpp"
|
||||
@ -1398,7 +1398,7 @@ static int yy_get_next_buffer (void)
|
||||
{ /* Not enough room in the buffer - grow it. */
|
||||
|
||||
/* just a shorter name for the current buffer */
|
||||
YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
|
||||
YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
|
||||
|
||||
int yy_c_buf_p_offset =
|
||||
(int) ((yy_c_buf_p) - b->yy_ch_buf);
|
||||
@ -1531,7 +1531,7 @@ static int yy_get_next_buffer (void)
|
||||
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
|
||||
yy_is_jam = (yy_current_state == 51);
|
||||
|
||||
return yy_is_jam ? 0 : yy_current_state;
|
||||
return yy_is_jam ? 0 : yy_current_state;
|
||||
}
|
||||
|
||||
static void yyunput (int c, register char * yy_bp )
|
||||
@ -1623,7 +1623,7 @@ static int yy_get_next_buffer (void)
|
||||
case EOB_ACT_END_OF_FILE:
|
||||
{
|
||||
if ( yywrap( ) )
|
||||
return 0;
|
||||
return EOF;
|
||||
|
||||
if ( ! (yy_did_buffer_switch_on_eof) )
|
||||
YY_NEW_FILE;
|
||||
@ -1764,10 +1764,6 @@ static void yy_load_buffer_state (void)
|
||||
yyfree((void *) b );
|
||||
}
|
||||
|
||||
#ifndef __cplusplus
|
||||
extern int isatty (int );
|
||||
#endif /* __cplusplus */
|
||||
|
||||
/* Initializes or reinitializes a buffer.
|
||||
* This function is sometimes called more than once on the same buffer,
|
||||
* such as during a yyrestart() or at EOF.
|
||||
@ -1972,8 +1968,8 @@ YY_BUFFER_STATE yy_scan_string (yyconst char * yystr )
|
||||
|
||||
/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
|
||||
* scan from a @e copy of @a bytes.
|
||||
* @param bytes the byte buffer to scan
|
||||
* @param len the number of bytes in the buffer pointed to by @a bytes.
|
||||
* @param yybytes the byte buffer to scan
|
||||
* @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
|
||||
*
|
||||
* @return the newly allocated buffer state object.
|
||||
*/
|
||||
@ -1981,7 +1977,8 @@ YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len
|
||||
{
|
||||
YY_BUFFER_STATE b;
|
||||
char *buf;
|
||||
yy_size_t n, i;
|
||||
yy_size_t n;
|
||||
yy_size_t i;
|
||||
|
||||
/* Get memory for full buffer, including space for trailing EOB's. */
|
||||
n = _yybytes_len + 2;
|
||||
@ -2214,7 +2211,7 @@ void yyfree (void * ptr )
|
||||
|
||||
#define YYTABLES_NAME "yytables"
|
||||
|
||||
#line 392 "/Users/jarod/centos/TarsCloud/framework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
#line 392 "/home/tars/TarsFramework/tarscpp/tools/tarsgrammar/tars.l"
|
||||
|
||||
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,8 +1,8 @@
|
||||
/* A Bison parser, made by GNU Bison 3.2.2. */
|
||||
/* A Bison parser, made by GNU Bison 3.0.4. */
|
||||
|
||||
/* Bison interface for Yacc-like parsers in C
|
||||
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015, 2018 Free Software Foundation, Inc.
|
||||
Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc.
|
||||
|
||||
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
|
||||
@ -30,9 +30,6 @@
|
||||
This special exception was added by the Free Software Foundation in
|
||||
version 2.2 of Bison. */
|
||||
|
||||
/* Undocumented macros, especially those whose name start with YY_,
|
||||
are private implementation details. Do not rely on them. */
|
||||
|
||||
#ifndef YY_YY_TARS_TAB_HPP_INCLUDED
|
||||
# define YY_YY_TARS_TAB_HPP_INCLUDED
|
||||
/* Debug traces. */
|
||||
|
Loading…
Reference in New Issue
Block a user