From c002727edffc1626ce2cd0badcc73f0cadeaa06b Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Wed, 25 Sep 2013 14:10:26 +0200 Subject: [PATCH] config: Remove the "abstract" keyword. --- lib/config/config_lexer.cc | 334 +++++++++++----------- lib/config/config_lexer.ll | 1 - lib/config/config_parser.cc | 552 +++++++++++++++++------------------- lib/config/config_parser.h | 28 +- lib/config/config_parser.yy | 13 +- 5 files changed, 439 insertions(+), 489 deletions(-) diff --git a/lib/config/config_lexer.cc b/lib/config/config_lexer.cc index 2910fa1ac..c0ece5583 100644 --- a/lib/config/config_lexer.cc +++ b/lib/config/config_lexer.cc @@ -370,8 +370,8 @@ static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner ); *yy_cp = '\0'; \ yyg->yy_c_buf_p = yy_cp; -#define YY_NUM_RULES 59 -#define YY_END_OF_BUFFER 60 +#define YY_NUM_RULES 58 +#define YY_END_OF_BUFFER 59 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -379,30 +379,28 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[195] = +static yyconst flex_int16_t yy_accept[188] = { 0, - 0, 0, 0, 0, 0, 0, 0, 0, 60, 58, - 21, 21, 1, 58, 58, 58, 58, 58, 52, 58, - 53, 58, 46, 46, 46, 46, 46, 46, 46, 46, - 46, 46, 46, 58, 18, 19, 12, 3, 2, 59, - 15, 15, 0, 0, 0, 56, 54, 52, 55, 16, - 20, 57, 0, 49, 50, 51, 0, 44, 47, 45, - 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, - 46, 46, 46, 46, 46, 46, 46, 46, 0, 17, - 12, 11, 4, 5, 9, 10, 6, 8, 7, 0, - 0, 0, 0, 20, 52, 48, 46, 28, 46, 46, - - 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, - 43, 46, 46, 46, 46, 13, 4, 5, 14, 0, - 0, 0, 46, 46, 46, 46, 46, 46, 46, 29, - 39, 46, 46, 46, 46, 46, 46, 41, 22, 4, - 0, 0, 0, 46, 24, 46, 42, 46, 46, 46, - 46, 46, 46, 46, 46, 46, 0, 0, 0, 46, - 46, 46, 46, 46, 25, 34, 46, 27, 26, 46, - 0, 0, 0, 46, 46, 36, 46, 37, 40, 46, - 0, 31, 0, 33, 46, 38, 35, 0, 0, 46, - 32, 30, 23, 0 - + 0, 0, 0, 0, 0, 0, 0, 0, 59, 57, + 21, 21, 1, 57, 57, 57, 57, 57, 51, 57, + 52, 57, 45, 45, 45, 45, 45, 45, 45, 45, + 45, 45, 45, 57, 18, 19, 12, 3, 2, 58, + 15, 15, 0, 0, 0, 55, 53, 51, 54, 16, + 20, 56, 0, 48, 49, 50, 0, 43, 46, 44, + 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, + 45, 45, 45, 45, 45, 45, 45, 0, 17, 12, + 11, 4, 5, 9, 10, 6, 8, 7, 0, 0, + 0, 0, 20, 51, 47, 28, 45, 45, 45, 45, + + 45, 45, 45, 45, 45, 45, 45, 45, 42, 45, + 45, 45, 45, 13, 4, 5, 14, 0, 0, 0, + 45, 45, 45, 45, 45, 45, 29, 38, 45, 45, + 45, 45, 45, 45, 40, 22, 4, 0, 0, 0, + 24, 45, 41, 45, 45, 45, 45, 45, 45, 45, + 45, 45, 0, 0, 0, 45, 45, 45, 45, 25, + 33, 45, 27, 26, 45, 0, 0, 0, 45, 35, + 45, 36, 39, 45, 0, 31, 0, 45, 37, 34, + 0, 0, 45, 32, 30, 23, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -446,61 +444,59 @@ static yyconst flex_int32_t yy_meta[43] = 1, 1 } ; -static yyconst flex_int16_t yy_base[203] = +static yyconst flex_int16_t yy_base[196] = { 0, - 0, 0, 243, 242, 40, 42, 205, 204, 245, 250, - 250, 250, 250, 28, 229, 228, 37, 44, 44, 48, - 250, 226, 0, 37, 214, 221, 208, 211, 46, 217, - 217, 48, 38, 194, 250, 224, 0, 250, 250, 75, - 250, 191, 195, 208, 211, 250, 250, 79, 250, 250, - 0, 250, 64, 250, 193, 250, 212, 211, 250, 250, - 0, 190, 185, 189, 202, 193, 56, 201, 190, 63, - 191, 183, 198, 179, 180, 184, 175, 179, 170, 250, - 0, 250, 85, 89, 250, 250, 250, 250, 250, 168, - 172, 174, 178, 0, 91, 250, 169, 0, 186, 167, - - 167, 173, 178, 165, 176, 169, 177, 173, 158, 165, - 0, 166, 159, 168, 167, 250, 96, 102, 250, 154, - 150, 160, 151, 145, 157, 160, 144, 146, 161, 0, - 0, 156, 157, 150, 157, 144, 145, 0, 0, 107, - 146, 145, 149, 151, 0, 137, 0, 146, 140, 131, - 130, 127, 144, 127, 136, 141, 139, 123, 138, 135, - 122, 123, 108, 86, 0, 0, 96, 0, 0, 87, - 85, 99, 83, 79, 92, 0, 68, 0, 0, 75, - 57, 250, 57, 0, 48, 0, 0, 58, 44, 26, - 250, 250, 0, 250, 127, 131, 135, 139, 47, 143, - - 147, 151 + 0, 0, 236, 235, 40, 42, 198, 197, 238, 243, + 243, 243, 243, 28, 222, 221, 37, 44, 44, 48, + 243, 219, 0, 26, 207, 214, 201, 204, 46, 210, + 210, 45, 46, 187, 243, 217, 0, 243, 243, 76, + 243, 184, 188, 201, 204, 243, 243, 67, 243, 243, + 0, 243, 60, 243, 186, 243, 205, 204, 243, 243, + 0, 179, 183, 196, 187, 64, 195, 184, 62, 185, + 177, 192, 173, 174, 178, 169, 173, 164, 243, 0, + 243, 83, 87, 243, 243, 243, 243, 243, 162, 166, + 168, 172, 0, 90, 243, 0, 181, 162, 162, 168, + + 173, 160, 171, 164, 172, 168, 153, 160, 0, 161, + 154, 163, 162, 243, 93, 97, 243, 149, 145, 155, + 141, 153, 156, 140, 142, 157, 0, 0, 152, 153, + 146, 153, 140, 141, 0, 0, 103, 142, 141, 145, + 0, 134, 0, 143, 137, 128, 127, 124, 141, 124, + 133, 138, 136, 120, 133, 114, 121, 88, 84, 0, + 0, 94, 0, 0, 85, 83, 96, 81, 98, 0, + 76, 0, 0, 87, 69, 243, 57, 48, 0, 0, + 54, 40, 33, 243, 243, 0, 243, 126, 130, 134, + 138, 47, 142, 146, 150 + } ; -static yyconst flex_int16_t yy_def[203] = +static yyconst flex_int16_t yy_def[196] = { 0, - 194, 1, 195, 195, 196, 196, 197, 197, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 198, - 194, 194, 199, 199, 199, 199, 199, 199, 199, 199, - 199, 199, 199, 194, 194, 194, 200, 194, 194, 201, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 202, 194, 194, 194, 194, 194, 198, 198, 194, 194, - 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, - 199, 199, 199, 199, 199, 199, 199, 199, 194, 194, - 200, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 202, 194, 194, 199, 199, 199, 199, - - 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, - 199, 199, 199, 199, 199, 194, 194, 194, 194, 194, - 194, 194, 199, 199, 199, 199, 199, 199, 199, 199, - 199, 199, 199, 199, 199, 199, 199, 199, 199, 194, - 194, 194, 194, 199, 199, 199, 199, 199, 199, 199, - 199, 199, 199, 199, 199, 199, 194, 194, 194, 199, - 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, - 194, 194, 194, 199, 199, 199, 199, 199, 199, 199, - 194, 194, 194, 199, 199, 199, 199, 194, 194, 199, - 194, 194, 199, 0, 194, 194, 194, 194, 194, 194, - - 194, 194 + 187, 1, 188, 188, 189, 189, 190, 190, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 191, + 187, 187, 192, 192, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 187, 187, 187, 193, 187, 187, 194, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 195, 187, 187, 187, 187, 187, 191, 191, 187, 187, + 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 192, 192, 192, 192, 187, 187, 193, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 195, 187, 187, 192, 192, 192, 192, 192, + + 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 187, 187, 187, 187, 187, 187, 187, + 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 192, 192, 192, 187, 187, 187, 187, + 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, + 192, 192, 187, 187, 187, 192, 192, 192, 192, 192, + 192, 192, 192, 192, 192, 187, 187, 187, 192, 192, + 192, 192, 192, 192, 187, 187, 187, 192, 192, 192, + 187, 187, 192, 187, 187, 192, 0, 187, 187, 187, + 187, 187, 187, 187, 187 + } ; -static yyconst flex_int16_t yy_nxt[293] = +static yyconst flex_int16_t yy_nxt[286] = { 0, 10, 11, 12, 13, 14, 15, 16, 17, 10, 18, 19, 19, 10, 20, 21, 22, 23, 10, 24, 23, @@ -508,79 +504,74 @@ static yyconst flex_int16_t yy_nxt[293] = 29, 30, 31, 23, 23, 32, 33, 23, 23, 23, 34, 10, 38, 39, 38, 39, 43, 48, 48, 50, 61, 49, 53, 51, 48, 48, 62, 40, 52, 40, - 76, 58, 44, 59, 69, 193, 45, 63, 73, 54, - 74, 64, 77, 55, 95, 95, 102, 78, 192, 56, - 191, 103, 190, 70, 75, 83, 84, 53, 189, 48, - 48, 106, 107, 188, 85, 117, 118, 187, 86, 118, - - 118, 95, 95, 186, 54, 87, 140, 118, 55, 88, - 185, 89, 118, 118, 56, 184, 54, 118, 118, 183, - 55, 182, 181, 180, 179, 178, 56, 35, 35, 35, - 35, 37, 37, 37, 37, 41, 41, 41, 41, 57, - 57, 57, 57, 81, 177, 176, 81, 82, 82, 82, - 82, 94, 175, 94, 94, 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, 145, 144, 143, 142, 141, 139, - 138, 137, 136, 135, 134, 133, 132, 131, 130, 129, - - 128, 127, 126, 125, 124, 123, 122, 121, 120, 119, - 116, 115, 114, 113, 112, 111, 110, 109, 108, 105, - 104, 101, 100, 99, 98, 97, 59, 59, 96, 93, - 92, 91, 90, 80, 79, 72, 71, 68, 67, 66, - 65, 60, 47, 46, 194, 42, 42, 36, 36, 9, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194 - + 63, 58, 44, 59, 68, 72, 45, 73, 75, 54, + 94, 94, 186, 55, 185, 53, 184, 48, 48, 56, + 76, 74, 183, 69, 100, 77, 82, 83, 182, 101, + 104, 105, 54, 115, 116, 84, 55, 116, 116, 85, + + 94, 94, 56, 137, 116, 181, 86, 116, 116, 180, + 87, 179, 88, 116, 116, 54, 178, 177, 176, 55, + 175, 174, 173, 172, 171, 56, 35, 35, 35, 35, + 37, 37, 37, 37, 41, 41, 41, 41, 57, 57, + 57, 57, 80, 170, 169, 80, 81, 81, 81, 81, + 93, 168, 93, 93, 167, 166, 165, 164, 163, 162, + 161, 160, 159, 158, 157, 156, 155, 154, 153, 152, + 151, 150, 149, 148, 147, 146, 145, 144, 143, 142, + 141, 140, 139, 138, 136, 135, 134, 133, 132, 131, + 130, 129, 128, 127, 126, 125, 124, 123, 122, 121, + + 120, 119, 118, 117, 114, 113, 112, 111, 110, 109, + 108, 107, 106, 103, 102, 99, 98, 97, 96, 59, + 59, 95, 92, 91, 90, 89, 79, 78, 71, 70, + 67, 66, 65, 64, 60, 47, 46, 187, 42, 42, + 36, 36, 9, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187 } ; -static yyconst flex_int16_t yy_chk[293] = +static yyconst flex_int16_t yy_chk[286] = { 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, 1, 1, 1, 1, 1, 1, 1, 5, 5, 6, 6, 14, 17, 17, 18, - 199, 17, 19, 18, 19, 19, 24, 5, 18, 6, - 33, 20, 14, 20, 29, 190, 14, 24, 32, 19, - 32, 24, 33, 19, 53, 53, 67, 33, 189, 19, - 188, 67, 185, 29, 32, 40, 40, 48, 183, 48, - 48, 70, 70, 181, 40, 83, 83, 180, 40, 84, - - 84, 95, 95, 177, 48, 40, 117, 117, 48, 40, - 175, 40, 118, 118, 48, 174, 95, 140, 140, 173, - 95, 172, 171, 170, 167, 164, 95, 195, 195, 195, - 195, 196, 196, 196, 196, 197, 197, 197, 197, 198, - 198, 198, 198, 200, 163, 162, 200, 201, 201, 201, - 201, 202, 161, 202, 202, 160, 159, 158, 157, 156, - 155, 154, 153, 152, 151, 150, 149, 148, 146, 144, - 143, 142, 141, 137, 136, 135, 134, 133, 132, 129, - 128, 127, 126, 125, 124, 123, 122, 121, 120, 115, - 114, 113, 112, 110, 109, 108, 107, 106, 105, 104, - - 103, 102, 101, 100, 99, 97, 93, 92, 91, 90, - 79, 78, 77, 76, 75, 74, 73, 72, 71, 69, - 68, 66, 65, 64, 63, 62, 58, 57, 55, 45, - 44, 43, 42, 36, 34, 31, 30, 28, 27, 26, - 25, 22, 16, 15, 9, 8, 7, 4, 3, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, - 194, 194 - + 192, 17, 19, 18, 19, 19, 24, 5, 18, 6, + 24, 20, 14, 20, 29, 32, 14, 32, 33, 19, + 53, 53, 183, 19, 182, 48, 181, 48, 48, 19, + 33, 32, 178, 29, 66, 33, 40, 40, 177, 66, + 69, 69, 48, 82, 82, 40, 48, 83, 83, 40, + + 94, 94, 48, 115, 115, 175, 40, 116, 116, 174, + 40, 171, 40, 137, 137, 94, 169, 168, 167, 94, + 166, 165, 162, 159, 158, 94, 188, 188, 188, 188, + 189, 189, 189, 189, 190, 190, 190, 190, 191, 191, + 191, 191, 193, 157, 156, 193, 194, 194, 194, 194, + 195, 155, 195, 195, 154, 153, 152, 151, 150, 149, + 148, 147, 146, 145, 144, 142, 140, 139, 138, 134, + 133, 132, 131, 130, 129, 126, 125, 124, 123, 122, + 121, 120, 119, 118, 113, 112, 111, 110, 108, 107, + 106, 105, 104, 103, 102, 101, 100, 99, 98, 97, + + 92, 91, 90, 89, 78, 77, 76, 75, 74, 73, + 72, 71, 70, 68, 67, 65, 64, 63, 62, 58, + 57, 55, 45, 44, 43, 42, 36, 34, 31, 30, + 28, 27, 26, 25, 22, 16, 15, 9, 8, 7, + 4, 3, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, + 187, 187, 187, 187, 187 } ; /* Table of booleans, true if rule could match eol. */ -static yyconst flex_int32_t yy_rule_can_match_eol[60] = +static yyconst flex_int32_t yy_rule_can_match_eol[59] = { 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - }; + 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, }; /* The intent behind this definition is that it'll catch * any uses of REJECT which flex missed. @@ -684,7 +675,7 @@ static char *lb_steal(lex_buf *lb) -#line 688 "../../../lib/config/config_lexer.cc" +#line 679 "../../../lib/config/config_lexer.cc" #define INITIAL 0 #define C_COMMENT 1 @@ -941,7 +932,7 @@ YY_DECL lex_buf string_buf; -#line 945 "../../../lib/config/config_lexer.cc" +#line 936 "../../../lib/config/config_lexer.cc" yylval = yylval_param; @@ -998,13 +989,13 @@ yy_match: 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 >= 195 ) + if ( yy_current_state >= 188 ) 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_current_state != 194 ); + while ( yy_current_state != 187 ); yy_cp = yyg->yy_last_accepting_cpos; yy_current_state = yyg->yy_last_accepting_state; @@ -1256,93 +1247,93 @@ YY_RULE_SETUP case 33: YY_RULE_SETUP #line 201 "config_lexer.ll" -return T_ABSTRACT; +return T_OBJECT; YY_BREAK case 34: YY_RULE_SETUP #line 202 "config_lexer.ll" -return T_OBJECT; +return T_TEMPLATE; YY_BREAK case 35: YY_RULE_SETUP #line 203 "config_lexer.ll" -return T_TEMPLATE; +return T_INCLUDE; YY_BREAK case 36: YY_RULE_SETUP #line 204 "config_lexer.ll" -return T_INCLUDE; +return T_LIBRARY; YY_BREAK case 37: YY_RULE_SETUP #line 205 "config_lexer.ll" -return T_LIBRARY; +return T_INHERITS; YY_BREAK case 38: YY_RULE_SETUP #line 206 "config_lexer.ll" -return T_INHERITS; +return T_NULL; YY_BREAK case 39: YY_RULE_SETUP #line 207 "config_lexer.ll" -return T_NULL; +return T_PARTIAL; YY_BREAK case 40: YY_RULE_SETUP #line 208 "config_lexer.ll" -return T_PARTIAL; +{ yylval->num = 1; return T_NUMBER; } YY_BREAK case 41: YY_RULE_SETUP #line 209 "config_lexer.ll" -{ yylval->num = 1; return T_NUMBER; } +{ yylval->num = 0; return T_NUMBER; } YY_BREAK case 42: YY_RULE_SETUP #line 210 "config_lexer.ll" -{ yylval->num = 0; return T_NUMBER; } +return T_SET; YY_BREAK case 43: YY_RULE_SETUP #line 211 "config_lexer.ll" -return T_SET; +return T_SHIFT_LEFT; YY_BREAK case 44: YY_RULE_SETUP #line 212 "config_lexer.ll" -return T_SHIFT_LEFT; +return T_SHIFT_RIGHT; YY_BREAK case 45: YY_RULE_SETUP #line 213 "config_lexer.ll" -return T_SHIFT_RIGHT; +{ yylval->text = strdup(yytext); return T_IDENTIFIER; } YY_BREAK case 46: +/* rule 46 can match eol */ YY_RULE_SETUP #line 214 "config_lexer.ll" -{ yylval->text = strdup(yytext); return T_IDENTIFIER; } +{ yytext[yyleng-1] = '\0'; yylval->text = strdup(yytext + 1); return T_STRING_ANGLE; } YY_BREAK case 47: -/* rule 47 can match eol */ YY_RULE_SETUP #line 215 "config_lexer.ll" -{ yytext[yyleng-1] = '\0'; yylval->text = strdup(yytext + 1); return T_STRING_ANGLE; } +{ yylval->num = strtod(yytext, NULL) / 1000; return T_NUMBER; } YY_BREAK case 48: YY_RULE_SETUP #line 216 "config_lexer.ll" -{ yylval->num = strtod(yytext, NULL) / 1000; return T_NUMBER; } +{ yylval->num = strtod(yytext, NULL) * 60 * 60; return T_NUMBER; } YY_BREAK case 49: YY_RULE_SETUP #line 217 "config_lexer.ll" -{ yylval->num = strtod(yytext, NULL) * 60 * 60; return T_NUMBER; } +{ yylval->num = strtod(yytext, NULL) * 60; return T_NUMBER; } YY_BREAK case 50: YY_RULE_SETUP #line 218 "config_lexer.ll" -{ yylval->num = strtod(yytext, NULL) * 60; return T_NUMBER; } +{ yylval->num = strtod(yytext, NULL); return T_NUMBER; } YY_BREAK case 51: YY_RULE_SETUP @@ -1352,45 +1343,40 @@ YY_RULE_SETUP case 52: YY_RULE_SETUP #line 220 "config_lexer.ll" -{ yylval->num = strtod(yytext, NULL); return T_NUMBER; } +{ yylval->op = OperatorSet; return T_EQUAL; } YY_BREAK case 53: YY_RULE_SETUP #line 221 "config_lexer.ll" -{ yylval->op = OperatorSet; return T_EQUAL; } +{ yylval->op = OperatorPlus; return T_PLUS_EQUAL; } YY_BREAK case 54: YY_RULE_SETUP #line 222 "config_lexer.ll" -{ yylval->op = OperatorPlus; return T_PLUS_EQUAL; } +{ yylval->op = OperatorMinus; return T_MINUS_EQUAL; } YY_BREAK case 55: YY_RULE_SETUP #line 223 "config_lexer.ll" -{ yylval->op = OperatorMinus; return T_MINUS_EQUAL; } +{ yylval->op = OperatorMultiply; return T_MULTIPLY_EQUAL; } YY_BREAK case 56: YY_RULE_SETUP #line 224 "config_lexer.ll" -{ yylval->op = OperatorMultiply; return T_MULTIPLY_EQUAL; } - YY_BREAK -case 57: -YY_RULE_SETUP -#line 225 "config_lexer.ll" { yylval->op = OperatorDivide; return T_DIVIDE_EQUAL; } YY_BREAK -case 58: +case 57: YY_RULE_SETUP -#line 228 "config_lexer.ll" +#line 227 "config_lexer.ll" return yytext[0]; YY_BREAK -case 59: +case 58: YY_RULE_SETUP -#line 230 "config_lexer.ll" +#line 229 "config_lexer.ll" ECHO; YY_BREAK -#line 1394 "../../../lib/config/config_lexer.cc" +#line 1380 "../../../lib/config/config_lexer.cc" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(C_COMMENT): case YY_STATE_EOF(STRING): @@ -1688,7 +1674,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner) 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 >= 195 ) + if ( yy_current_state >= 188 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1717,11 +1703,11 @@ static int yy_get_next_buffer (yyscan_t yyscanner) 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 >= 195 ) + if ( yy_current_state >= 188 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; - yy_is_jam = (yy_current_state == 194); + yy_is_jam = (yy_current_state == 187); return yy_is_jam ? 0 : yy_current_state; } @@ -2580,7 +2566,7 @@ void yyfree (void * ptr , yyscan_t yyscanner) #define YYTABLES_NAME "yytables" -#line 230 "config_lexer.ll" +#line 229 "config_lexer.ll" diff --git a/lib/config/config_lexer.ll b/lib/config/config_lexer.ll index a7a10bd7b..f7e2ad42f 100644 --- a/lib/config/config_lexer.ll +++ b/lib/config/config_lexer.ll @@ -198,7 +198,6 @@ name { yylval->type = TypeName; return T_TYPE_NAME; } %validator { return T_VALIDATOR; } %require { return T_REQUIRE; } %attribute { return T_ATTRIBUTE; } -abstract return T_ABSTRACT; object return T_OBJECT; template return T_TEMPLATE; include return T_INCLUDE; diff --git a/lib/config/config_parser.cc b/lib/config/config_parser.cc index 4b48164a9..e2ed635e8 100644 --- a/lib/config/config_parser.cc +++ b/lib/config/config_parser.cc @@ -169,13 +169,12 @@ using namespace icinga; T_REQUIRE = 279, T_ATTRIBUTE = 280, T_TYPE = 281, - T_ABSTRACT = 282, - T_OBJECT = 283, - T_TEMPLATE = 284, - T_INCLUDE = 285, - T_LIBRARY = 286, - T_INHERITS = 287, - T_PARTIAL = 288 + T_OBJECT = 282, + T_TEMPLATE = 283, + T_INCLUDE = 284, + T_LIBRARY = 285, + T_INHERITS = 286, + T_PARTIAL = 287 }; #endif /* Tokens. */ @@ -203,13 +202,12 @@ using namespace icinga; #define T_REQUIRE 279 #define T_ATTRIBUTE 280 #define T_TYPE 281 -#define T_ABSTRACT 282 -#define T_OBJECT 283 -#define T_TEMPLATE 284 -#define T_INCLUDE 285 -#define T_LIBRARY 286 -#define T_INHERITS 287 -#define T_PARTIAL 288 +#define T_OBJECT 282 +#define T_TEMPLATE 283 +#define T_INCLUDE 284 +#define T_LIBRARY 285 +#define T_INHERITS 286 +#define T_PARTIAL 287 @@ -234,7 +232,7 @@ typedef union YYSTYPE /* Line 293 of yacc.c */ -#line 238 "../../../lib/config/config_parser.cc" +#line 236 "../../../lib/config/config_parser.cc" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -258,7 +256,7 @@ typedef struct YYLTYPE /* Copy the second part of user declarations. */ /* Line 343 of yacc.c */ -#line 119 "config_parser.yy" +#line 118 "config_parser.yy" int yylex(YYSTYPE *lvalp, YYLTYPE *llocp, void *scanner); @@ -292,7 +290,7 @@ void ConfigCompiler::Compile(void) /* Line 343 of yacc.c */ -#line 296 "../../../lib/config/config_parser.cc" +#line 294 "../../../lib/config/config_parser.cc" #ifdef short # undef short @@ -513,20 +511,20 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 2 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 152 +#define YYLAST 147 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 47 +#define YYNTOKENS 46 /* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 35 +#define YYNNTS 33 /* YYNRULES -- Number of rules. */ -#define YYNRULES 90 +#define YYNRULES 87 /* YYNRULES -- Number of states. */ -#define YYNSTATES 132 +#define YYNSTATES 129 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 288 +#define YYMAXUTOK 287 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -537,16 +535,16 @@ static const yytype_uint8 yytranslate[] = 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 38, 2, - 43, 44, 36, 34, 42, 35, 2, 37, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 37, 2, + 42, 43, 35, 33, 41, 34, 2, 36, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 45, 2, 46, 2, 2, 2, 2, 2, 2, + 2, 44, 2, 45, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 40, 39, 41, 2, 2, 2, 2, + 2, 2, 2, 39, 38, 40, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, @@ -562,7 +560,7 @@ static const yytype_uint8 yytranslate[] = 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 32, 33 + 25, 26, 27, 28, 29, 30, 31, 32 }; #if YYDEBUG @@ -574,57 +572,54 @@ static const yytype_uint8 yyprhs[] = 20, 23, 26, 31, 33, 35, 36, 43, 44, 46, 47, 52, 54, 57, 58, 60, 64, 67, 70, 74, 81, 86, 87, 90, 92, 94, 96, 98, 100, 102, - 104, 105, 112, 115, 117, 118, 121, 123, 124, 126, - 130, 131, 134, 138, 140, 143, 144, 146, 150, 154, - 161, 163, 165, 167, 169, 171, 175, 177, 180, 181, - 183, 187, 189, 191, 193, 195, 199, 201, 203, 205, - 209, 213, 217, 221, 225, 229, 233, 237, 241, 243, - 245 + 104, 105, 112, 114, 116, 117, 119, 123, 124, 127, + 131, 133, 136, 137, 139, 143, 147, 154, 156, 158, + 160, 162, 164, 168, 170, 173, 174, 176, 180, 182, + 184, 186, 188, 192, 194, 196, 198, 202, 206, 210, + 214, 218, 222, 226, 230, 234, 236, 238 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int8 yyrhs[] = { - 48, 0, -1, -1, 48, 49, -1, 63, -1, 54, - -1, 50, -1, 51, -1, 52, -1, 30, 81, -1, - 30, 4, -1, 31, 3, -1, 13, 53, 8, 81, - -1, 7, -1, 3, -1, -1, 56, 26, 53, 55, - 62, 57, -1, -1, 33, -1, -1, 40, 58, 59, - 41, -1, 60, -1, 60, 42, -1, -1, 61, -1, - 60, 42, 61, -1, 24, 3, -1, 23, 3, -1, - 25, 54, 3, -1, 25, 22, 43, 53, 44, 3, - -1, 25, 54, 3, 57, -1, -1, 32, 53, -1, + 47, 0, -1, -1, 47, 48, -1, 62, -1, 53, + -1, 49, -1, 50, -1, 51, -1, 29, 78, -1, + 29, 4, -1, 30, 3, -1, 13, 52, 8, 78, + -1, 7, -1, 3, -1, -1, 55, 26, 52, 54, + 61, 56, -1, -1, 32, -1, -1, 39, 57, 58, + 40, -1, 59, -1, 59, 41, -1, -1, 60, -1, + 59, 41, 60, -1, 24, 3, -1, 23, 3, -1, + 25, 53, 3, -1, 25, 22, 42, 52, 43, 3, + -1, 25, 53, 3, 56, -1, -1, 31, 52, -1, 16, -1, 17, -1, 18, -1, 19, -1, 20, -1, - 21, -1, 22, -1, -1, 64, 65, 53, 3, 69, - 70, -1, 66, 28, -1, 29, -1, -1, 66, 67, - -1, 27, -1, -1, 3, -1, 68, 42, 3, -1, - -1, 32, 68, -1, 40, 71, 41, -1, 72, -1, - 72, 42, -1, -1, 73, -1, 72, 42, 73, -1, - 53, 74, 81, -1, 53, 45, 3, 46, 74, 81, - -1, 8, -1, 9, -1, 10, -1, 11, -1, 12, - -1, 45, 76, 46, -1, 77, -1, 77, 42, -1, - -1, 81, -1, 77, 42, 81, -1, 3, -1, 5, - -1, 6, -1, 75, -1, 43, 80, 44, -1, 3, - -1, 5, -1, 7, -1, 80, 34, 80, -1, 80, - 35, 80, -1, 80, 36, 80, -1, 80, 37, 80, - -1, 80, 38, 80, -1, 80, 39, 80, -1, 80, - 14, 80, -1, 80, 15, 80, -1, 43, 80, 44, - -1, 78, -1, 70, -1, 79, -1 + 21, -1, 22, -1, -1, 63, 64, 52, 3, 66, + 67, -1, 27, -1, 28, -1, -1, 3, -1, 65, + 41, 3, -1, -1, 31, 65, -1, 39, 68, 40, + -1, 69, -1, 69, 41, -1, -1, 70, -1, 69, + 41, 70, -1, 52, 71, 78, -1, 52, 44, 3, + 45, 71, 78, -1, 8, -1, 9, -1, 10, -1, + 11, -1, 12, -1, 44, 73, 45, -1, 74, -1, + 74, 41, -1, -1, 78, -1, 74, 41, 78, -1, + 3, -1, 5, -1, 6, -1, 72, -1, 42, 77, + 43, -1, 3, -1, 5, -1, 7, -1, 77, 33, + 77, -1, 77, 34, 77, -1, 77, 35, 77, -1, + 77, 36, 77, -1, 77, 37, 77, -1, 77, 38, + 77, -1, 77, 14, 77, -1, 77, 15, 77, -1, + 42, 77, 43, -1, 75, -1, 67, -1, 76, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 152, 152, 153, 156, 156, 156, 156, 156, 159, - 164, 170, 176, 192, 193, 200, 199, 229, 232, 239, - 238, 250, 251, 253, 254, 255, 258, 263, 268, 275, - 283, 292, 293, 300, 301, 302, 303, 304, 305, 306, - 313, 313, 354, 355, 360, 361, 364, 371, 374, 380, - 393, 396, 402, 411, 415, 421, 424, 430, 442, 448, - 462, 463, 464, 465, 466, 472, 478, 482, 488, 491, - 506, 526, 531, 535, 539, 549, 554, 559, 563, 568, - 578, 585, 592, 599, 606, 613, 620, 627, 633, 634, - 639 + 0, 151, 151, 152, 155, 155, 155, 155, 155, 158, + 163, 169, 175, 191, 192, 199, 198, 228, 231, 238, + 237, 249, 250, 252, 253, 254, 257, 262, 267, 274, + 282, 291, 292, 299, 300, 301, 302, 303, 304, 305, + 312, 312, 353, 354, 360, 363, 369, 382, 385, 391, + 400, 404, 410, 413, 419, 431, 437, 451, 452, 453, + 454, 455, 461, 467, 471, 477, 480, 495, 515, 520, + 524, 528, 538, 543, 548, 552, 557, 567, 574, 581, + 588, 595, 602, 609, 616, 622, 623, 628 }; #endif @@ -643,15 +638,14 @@ static const char *const yytname[] = "\"any (T_TYPE_ANY)\"", "\"name (T_TYPE_NAME)\"", "\"%validator (T_VALIDATOR)\"", "\"%require (T_REQUIRE)\"", "\"%attribute (T_ATTRIBUTE)\"", "\"type (T_TYPE)\"", - "\"abstract (T_ABSTRACT)\"", "\"object (T_OBJECT)\"", - "\"template (T_TEMPLATE)\"", "\"include (T_INCLUDE)\"", - "\"library (T_LIBRARY)\"", "\"inherits (T_INHERITS)\"", - "\"partial (T_PARTIAL)\"", "'+'", "'-'", "'*'", "'/'", "'&'", "'|'", - "'{'", "'}'", "','", "'('", "')'", "'['", "']'", "$accept", "statements", - "statement", "include", "library", "variable", "identifier", "type", - "$@1", "partial_specifier", "typerulelist", "$@2", "typerules", - "typerules_inner", "typerule", "type_inherits_specifier", "object", - "$@3", "object_declaration", "attributes", "attribute", + "\"object (T_OBJECT)\"", "\"template (T_TEMPLATE)\"", + "\"include (T_INCLUDE)\"", "\"library (T_LIBRARY)\"", + "\"inherits (T_INHERITS)\"", "\"partial (T_PARTIAL)\"", "'+'", "'-'", + "'*'", "'/'", "'&'", "'|'", "'{'", "'}'", "','", "'('", "')'", "'['", + "']'", "$accept", "statements", "statement", "include", "library", + "variable", "identifier", "type", "$@1", "partial_specifier", + "typerulelist", "$@2", "typerules", "typerules_inner", "typerule", + "type_inherits_specifier", "object", "$@3", "object_declaration", "object_inherits_list", "object_inherits_specifier", "expressionlist", "expressions", "expressions_inner", "expression", "operator", "array", "array_items", "array_items_inner", "simplevalue", "constterm", @@ -667,24 +661,23 @@ static const yytype_uint16 yytoknum[] = 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, - 285, 286, 287, 288, 43, 45, 42, 47, 38, 124, - 123, 125, 44, 40, 41, 91, 93 + 285, 286, 287, 43, 45, 42, 47, 38, 124, 123, + 125, 44, 40, 41, 91, 93 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 47, 48, 48, 49, 49, 49, 49, 49, 50, - 50, 51, 52, 53, 53, 55, 54, 56, 56, 58, - 57, 59, 59, 60, 60, 60, 61, 61, 61, 61, - 61, 62, 62, 54, 54, 54, 54, 54, 54, 54, - 64, 63, 65, 65, 66, 66, 67, 68, 68, 68, - 69, 69, 70, 71, 71, 72, 72, 72, 73, 73, - 74, 74, 74, 74, 74, 75, 76, 76, 77, 77, - 77, 78, 78, 78, 78, 79, 80, 80, 80, 80, - 80, 80, 80, 80, 80, 80, 80, 80, 81, 81, - 81 + 0, 46, 47, 47, 48, 48, 48, 48, 48, 49, + 49, 50, 51, 52, 52, 54, 53, 55, 55, 57, + 56, 58, 58, 59, 59, 59, 60, 60, 60, 60, + 60, 61, 61, 53, 53, 53, 53, 53, 53, 53, + 63, 62, 64, 64, 65, 65, 65, 66, 66, 67, + 68, 68, 69, 69, 69, 70, 70, 71, 71, 71, + 71, 71, 72, 73, 73, 74, 74, 74, 75, 75, + 75, 75, 76, 77, 77, 77, 77, 77, 77, 77, + 77, 77, 77, 77, 77, 78, 78, 78 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -694,12 +687,11 @@ static const yytype_uint8 yyr2[] = 2, 2, 4, 1, 1, 0, 6, 0, 1, 0, 4, 1, 2, 0, 1, 3, 2, 2, 3, 6, 4, 0, 2, 1, 1, 1, 1, 1, 1, 1, - 0, 6, 2, 1, 0, 2, 1, 0, 1, 3, - 0, 2, 3, 1, 2, 0, 1, 3, 3, 6, - 1, 1, 1, 1, 1, 3, 1, 2, 0, 1, - 3, 1, 1, 1, 1, 3, 1, 1, 1, 3, - 3, 3, 3, 3, 3, 3, 3, 3, 1, 1, - 1 + 0, 6, 1, 1, 0, 1, 3, 0, 2, 3, + 1, 2, 0, 1, 3, 3, 6, 1, 1, 1, + 1, 1, 3, 1, 2, 0, 1, 3, 1, 1, + 1, 1, 3, 1, 1, 1, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 1, 1, 1 }; /* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. @@ -709,57 +701,55 @@ static const yytype_uint8 yydefact[] = { 2, 40, 1, 0, 33, 34, 35, 36, 37, 38, 39, 0, 0, 18, 3, 6, 7, 8, 5, 0, - 4, 44, 14, 13, 0, 71, 10, 72, 73, 55, - 0, 68, 89, 74, 88, 90, 9, 11, 0, 43, - 0, 0, 0, 0, 0, 53, 56, 76, 77, 78, - 0, 0, 0, 66, 69, 15, 0, 46, 42, 45, - 12, 60, 61, 62, 63, 64, 0, 0, 52, 54, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 75, - 65, 67, 31, 50, 0, 58, 57, 87, 85, 86, - 79, 80, 81, 82, 83, 84, 70, 0, 0, 47, - 0, 0, 32, 19, 16, 48, 51, 41, 0, 23, - 0, 59, 0, 0, 17, 0, 21, 24, 49, 27, - 26, 39, 0, 20, 22, 0, 28, 25, 0, 30, - 0, 29 + 4, 0, 14, 13, 0, 68, 10, 69, 70, 52, + 0, 65, 86, 71, 85, 87, 9, 11, 0, 42, + 43, 0, 0, 0, 0, 50, 53, 73, 74, 75, + 0, 0, 0, 63, 66, 15, 0, 12, 57, 58, + 59, 60, 61, 0, 0, 49, 51, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 72, 62, 64, 31, + 47, 0, 55, 54, 84, 82, 83, 76, 77, 78, + 79, 80, 81, 67, 0, 0, 44, 0, 0, 32, + 19, 16, 45, 48, 41, 0, 23, 0, 56, 0, + 0, 17, 0, 21, 24, 46, 27, 26, 39, 0, + 20, 22, 0, 28, 25, 0, 30, 0, 29 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int8 yydefgoto[] = { - -1, 1, 14, 15, 16, 17, 43, 18, 82, 19, - 104, 109, 115, 116, 117, 98, 20, 21, 40, 41, - 59, 106, 100, 32, 44, 45, 46, 67, 33, 52, - 53, 34, 35, 51, 36 + -1, 1, 14, 15, 16, 17, 43, 18, 79, 19, + 101, 106, 112, 113, 114, 95, 20, 21, 41, 103, + 97, 32, 44, 45, 46, 64, 33, 52, 53, 34, + 35, 51, 36 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -30 +#define YYPACT_NINF -31 static const yytype_int8 yypact[] = { - -30, 42, -30, 5, -30, -30, -30, -30, -30, -30, - -30, 0, -2, -30, -30, -30, -30, -30, -30, -15, - -30, -14, -30, -30, 9, -30, -30, -30, -30, 5, - 11, 4, -30, -30, -30, -30, -30, -30, 5, -30, - 5, 23, 4, 12, -22, -6, -30, -30, -30, -30, - 11, 51, -7, -1, -30, -30, 43, -30, -30, -30, - -30, -30, -30, -30, -30, -30, 45, 4, -30, 5, - 62, 11, 11, 11, 11, 11, 11, 11, 11, -30, - -30, 4, 24, 35, 25, -30, -30, -30, 89, 89, - 93, 93, 95, 95, 14, 55, -30, 5, 34, 75, - 40, 22, -30, -30, -30, -30, 39, -30, 4, 2, - 79, -30, 80, 81, 119, 52, 50, -30, -30, -30, - -30, 59, 102, -30, 2, 5, 34, -30, 67, -30, - 117, -30 + -31, 51, -31, 34, -31, -31, -31, -31, -31, -31, + -31, 0, -1, -31, -31, -31, -31, -31, -31, -10, + -31, 18, -31, -31, 10, -31, -31, -31, -31, 34, + 12, 8, -31, -31, -31, -31, -31, -31, 34, -31, + -31, 34, 8, 13, -20, 2, -31, -31, -31, -31, + 12, -7, 4, 22, -31, -31, 50, -31, -31, -31, + -31, -31, -31, 62, 8, -31, 34, 64, 12, 12, + 12, 12, 12, 12, 12, 12, -31, -31, 8, 9, + 35, 29, -31, -31, -31, 89, 89, 102, 102, -5, + -5, 44, 41, -31, 34, 53, 73, 54, 76, -31, + -31, -31, -31, 48, -31, 8, 37, 91, -31, 92, + 93, 112, 65, 77, -31, -31, -31, -31, 78, 103, + -31, 37, 34, 53, -31, 98, -31, 118, -31 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int8 yypgoto[] = { - -30, -30, -30, -30, -30, -30, -3, 7, -30, -30, - 16, -30, -30, -30, 19, -30, -30, -30, -30, -30, - -30, -30, -30, 44, -30, -30, 76, 46, -30, -30, - -30, -30, -30, 41, -29 + -31, -31, -31, -31, -31, -31, -3, 24, -31, -31, + 19, -31, -31, -31, 15, -31, -31, -31, -31, -31, + -31, 46, -31, -31, 79, 49, -31, -31, -31, -31, + -31, 40, -30 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If @@ -768,68 +758,65 @@ static const yytype_int8 yypgoto[] = #define YYTABLE_NINF -18 static const yytype_int16 yytable[] = { - 24, 37, 54, 25, 26, 27, 28, 25, 22, 27, - 28, 38, 23, 60, 47, 39, 48, 42, 49, 68, - 61, 62, 63, 64, 65, 112, 113, 114, 71, 72, - 61, 62, 63, 64, 65, 55, 69, 56, 85, 80, - 29, 81, 2, 30, 29, 31, 83, 30, 84, 31, - 57, 58, 96, 78, 50, 3, 97, 66, 4, 5, - 6, 7, 8, 9, 10, 71, 72, 99, -17, 71, - 72, 101, 11, 12, 103, 13, 71, 72, 105, 111, - 29, 110, 118, 119, 120, 73, 74, 75, 76, 77, - 78, 70, 124, 123, 102, 79, 73, 74, 75, 76, - 77, 78, 125, 71, 72, 126, 87, 71, 72, 71, - 72, 130, 88, 89, 90, 91, 92, 93, 94, 95, - 131, 122, 128, 73, 74, 75, 76, 77, 78, 75, - 76, 77, 78, 77, 78, 4, 5, 6, 7, 8, - 9, 121, 129, 127, 107, 86, 0, 108, 0, 0, - 0, 0, 13 + 24, 54, 37, 25, 26, 27, 28, 68, 69, 68, + 69, 25, 57, 27, 28, 47, 38, 48, 42, 49, + 65, 58, 59, 60, 61, 62, 70, 71, 72, 73, + 74, 75, 74, 75, 82, 55, 76, 22, 56, 29, + 94, 23, 30, 66, 31, 39, 40, 29, 93, 77, + 30, 2, 31, 80, 50, 68, 69, 63, 68, 69, + 109, 110, 111, 78, 3, 81, 96, 4, 5, 6, + 7, 8, 9, 10, 98, 108, 102, -17, 68, 69, + 11, 12, 75, 13, 58, 59, 60, 61, 62, 107, + 67, 99, 100, 29, 115, 116, 117, 70, 71, 72, + 73, 74, 75, 68, 69, 120, 123, 84, 85, 86, + 87, 88, 89, 90, 91, 92, 68, 69, 121, 125, + 122, 128, 70, 71, 72, 73, 74, 75, 4, 5, + 6, 7, 8, 9, 118, 119, 124, 72, 73, 74, + 75, 127, 126, 104, 13, 83, 0, 105 }; #define yypact_value_is_default(yystate) \ - ((yystate) == (-30)) + ((yystate) == (-31)) #define yytable_value_is_error(yytable_value) \ YYID (0) static const yytype_int8 yycheck[] = { - 3, 3, 31, 3, 4, 5, 6, 3, 3, 5, - 6, 26, 7, 42, 3, 29, 5, 8, 7, 41, - 8, 9, 10, 11, 12, 23, 24, 25, 14, 15, - 8, 9, 10, 11, 12, 38, 42, 40, 67, 46, - 40, 42, 0, 43, 40, 45, 3, 43, 3, 45, - 27, 28, 81, 39, 43, 13, 32, 45, 16, 17, - 18, 19, 20, 21, 22, 14, 15, 32, 26, 14, - 15, 46, 30, 31, 40, 33, 14, 15, 3, 108, - 40, 42, 3, 3, 3, 34, 35, 36, 37, 38, - 39, 50, 42, 41, 97, 44, 34, 35, 36, 37, - 38, 39, 43, 14, 15, 3, 44, 14, 15, 14, - 15, 44, 71, 72, 73, 74, 75, 76, 77, 78, - 3, 114, 125, 34, 35, 36, 37, 38, 39, 36, - 37, 38, 39, 38, 39, 16, 17, 18, 19, 20, - 21, 22, 126, 124, 100, 69, -1, 101, -1, -1, - -1, -1, 33 + 3, 31, 3, 3, 4, 5, 6, 14, 15, 14, + 15, 3, 42, 5, 6, 3, 26, 5, 8, 7, + 40, 8, 9, 10, 11, 12, 33, 34, 35, 36, + 37, 38, 37, 38, 64, 38, 43, 3, 41, 39, + 31, 7, 42, 41, 44, 27, 28, 39, 78, 45, + 42, 0, 44, 3, 42, 14, 15, 44, 14, 15, + 23, 24, 25, 41, 13, 3, 31, 16, 17, 18, + 19, 20, 21, 22, 45, 105, 3, 26, 14, 15, + 29, 30, 38, 32, 8, 9, 10, 11, 12, 41, + 50, 94, 39, 39, 3, 3, 3, 33, 34, 35, + 36, 37, 38, 14, 15, 40, 3, 43, 68, 69, + 70, 71, 72, 73, 74, 75, 14, 15, 41, 122, + 42, 3, 33, 34, 35, 36, 37, 38, 16, 17, + 18, 19, 20, 21, 22, 111, 121, 35, 36, 37, + 38, 43, 123, 97, 32, 66, -1, 98 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing symbol of state STATE-NUM. */ static const yytype_uint8 yystos[] = { - 0, 48, 0, 13, 16, 17, 18, 19, 20, 21, - 22, 30, 31, 33, 49, 50, 51, 52, 54, 56, - 63, 64, 3, 7, 53, 3, 4, 5, 6, 40, - 43, 45, 70, 75, 78, 79, 81, 3, 26, 29, - 65, 66, 8, 53, 71, 72, 73, 3, 5, 7, - 43, 80, 76, 77, 81, 53, 53, 27, 28, 67, - 81, 8, 9, 10, 11, 12, 45, 74, 41, 42, - 80, 14, 15, 34, 35, 36, 37, 38, 39, 44, - 46, 42, 55, 3, 3, 81, 73, 44, 80, 80, - 80, 80, 80, 80, 80, 80, 81, 32, 62, 32, - 69, 46, 53, 40, 57, 3, 68, 70, 74, 58, - 42, 81, 23, 24, 25, 59, 60, 61, 3, 3, - 3, 22, 54, 41, 42, 43, 3, 61, 53, 57, - 44, 3 + 0, 47, 0, 13, 16, 17, 18, 19, 20, 21, + 22, 29, 30, 32, 48, 49, 50, 51, 53, 55, + 62, 63, 3, 7, 52, 3, 4, 5, 6, 39, + 42, 44, 67, 72, 75, 76, 78, 3, 26, 27, + 28, 64, 8, 52, 68, 69, 70, 3, 5, 7, + 42, 77, 73, 74, 78, 52, 52, 78, 8, 9, + 10, 11, 12, 44, 71, 40, 41, 77, 14, 15, + 33, 34, 35, 36, 37, 38, 43, 45, 41, 54, + 3, 3, 78, 70, 43, 77, 77, 77, 77, 77, + 77, 77, 77, 78, 31, 61, 31, 66, 45, 52, + 39, 56, 3, 65, 67, 71, 57, 41, 78, 23, + 24, 25, 58, 59, 60, 3, 3, 3, 22, 53, + 40, 41, 42, 3, 60, 52, 56, 43, 3 }; #define yyerrok (yyerrstatus = 0) @@ -1715,7 +1702,7 @@ yyreduce: case 9: /* Line 1806 of yacc.c */ -#line 160 "config_parser.yy" +#line 159 "config_parser.yy" { context->HandleInclude(*(yyvsp[(2) - (2)].variant), false, yylloc); delete (yyvsp[(2) - (2)].variant); @@ -1725,7 +1712,7 @@ yyreduce: case 10: /* Line 1806 of yacc.c */ -#line 165 "config_parser.yy" +#line 164 "config_parser.yy" { context->HandleInclude((yyvsp[(2) - (2)].text), true, yylloc); free((yyvsp[(2) - (2)].text)); @@ -1735,7 +1722,7 @@ yyreduce: case 11: /* Line 1806 of yacc.c */ -#line 171 "config_parser.yy" +#line 170 "config_parser.yy" { context->HandleLibrary((yyvsp[(2) - (2)].text)); free((yyvsp[(2) - (2)].text)); @@ -1745,7 +1732,7 @@ yyreduce: case 12: /* Line 1806 of yacc.c */ -#line 177 "config_parser.yy" +#line 176 "config_parser.yy" { Value *value = (yyvsp[(4) - (4)].variant); if (value->IsObjectType()) { @@ -1765,7 +1752,7 @@ yyreduce: case 14: /* Line 1806 of yacc.c */ -#line 194 "config_parser.yy" +#line 193 "config_parser.yy" { (yyval.text) = (yyvsp[(1) - (1)].text); } @@ -1774,7 +1761,7 @@ yyreduce: case 15: /* Line 1806 of yacc.c */ -#line 200 "config_parser.yy" +#line 199 "config_parser.yy" { String name = String((yyvsp[(3) - (3)].text)); free((yyvsp[(3) - (3)].text)); @@ -1794,7 +1781,7 @@ yyreduce: case 16: /* Line 1806 of yacc.c */ -#line 215 "config_parser.yy" +#line 214 "config_parser.yy" { TypeRuleList::Ptr ruleList = *(yyvsp[(6) - (6)].variant); m_Type->GetRuleList()->AddRules(ruleList); @@ -1811,7 +1798,7 @@ yyreduce: case 17: /* Line 1806 of yacc.c */ -#line 229 "config_parser.yy" +#line 228 "config_parser.yy" { (yyval.num) = 0; } @@ -1820,7 +1807,7 @@ yyreduce: case 18: /* Line 1806 of yacc.c */ -#line 233 "config_parser.yy" +#line 232 "config_parser.yy" { (yyval.num) = 1; } @@ -1829,7 +1816,7 @@ yyreduce: case 19: /* Line 1806 of yacc.c */ -#line 239 "config_parser.yy" +#line 238 "config_parser.yy" { m_RuleLists.push(boost::make_shared()); } @@ -1838,7 +1825,7 @@ yyreduce: case 20: /* Line 1806 of yacc.c */ -#line 244 "config_parser.yy" +#line 243 "config_parser.yy" { (yyval.variant) = new Value(m_RuleLists.top()); m_RuleLists.pop(); @@ -1848,7 +1835,7 @@ yyreduce: case 26: /* Line 1806 of yacc.c */ -#line 259 "config_parser.yy" +#line 258 "config_parser.yy" { m_RuleLists.top()->AddRequire((yyvsp[(2) - (2)].text)); free((yyvsp[(2) - (2)].text)); @@ -1858,7 +1845,7 @@ yyreduce: case 27: /* Line 1806 of yacc.c */ -#line 264 "config_parser.yy" +#line 263 "config_parser.yy" { m_RuleLists.top()->SetValidator((yyvsp[(2) - (2)].text)); free((yyvsp[(2) - (2)].text)); @@ -1868,7 +1855,7 @@ yyreduce: case 28: /* Line 1806 of yacc.c */ -#line 269 "config_parser.yy" +#line 268 "config_parser.yy" { TypeRule rule((yyvsp[(2) - (3)].type), String(), (yyvsp[(3) - (3)].text), TypeRuleList::Ptr(), yylloc); free((yyvsp[(3) - (3)].text)); @@ -1880,7 +1867,7 @@ yyreduce: case 29: /* Line 1806 of yacc.c */ -#line 276 "config_parser.yy" +#line 275 "config_parser.yy" { TypeRule rule((yyvsp[(2) - (6)].type), (yyvsp[(4) - (6)].text), (yyvsp[(6) - (6)].text), TypeRuleList::Ptr(), yylloc); free((yyvsp[(4) - (6)].text)); @@ -1893,7 +1880,7 @@ yyreduce: case 30: /* Line 1806 of yacc.c */ -#line 284 "config_parser.yy" +#line 283 "config_parser.yy" { TypeRule rule((yyvsp[(2) - (4)].type), String(), (yyvsp[(3) - (4)].text), *(yyvsp[(4) - (4)].variant), yylloc); free((yyvsp[(3) - (4)].text)); @@ -1905,7 +1892,7 @@ yyreduce: case 32: /* Line 1806 of yacc.c */ -#line 294 "config_parser.yy" +#line 293 "config_parser.yy" { m_Type->SetParent((yyvsp[(2) - (2)].text)); free((yyvsp[(2) - (2)].text)); @@ -1915,7 +1902,7 @@ yyreduce: case 39: /* Line 1806 of yacc.c */ -#line 307 "config_parser.yy" +#line 306 "config_parser.yy" { (yyval.type) = (yyvsp[(1) - (1)].type); } @@ -1924,7 +1911,7 @@ yyreduce: case 40: /* Line 1806 of yacc.c */ -#line 313 "config_parser.yy" +#line 312 "config_parser.yy" { m_Abstract = false; } @@ -1933,7 +1920,7 @@ yyreduce: case 41: /* Line 1806 of yacc.c */ -#line 317 "config_parser.yy" +#line 316 "config_parser.yy" { ConfigItemBuilder::Ptr item = boost::make_shared(yylloc); @@ -1974,34 +1961,25 @@ yyreduce: case 43: /* Line 1806 of yacc.c */ -#line 356 "config_parser.yy" +#line 355 "config_parser.yy" { m_Abstract = true; } break; - case 46: - -/* Line 1806 of yacc.c */ -#line 365 "config_parser.yy" - { - m_Abstract = true; - } - break; - - case 47: + case 44: /* Line 1806 of yacc.c */ -#line 371 "config_parser.yy" +#line 360 "config_parser.yy" { (yyval.slist) = NULL; } break; - case 48: + case 45: /* Line 1806 of yacc.c */ -#line 375 "config_parser.yy" +#line 364 "config_parser.yy" { (yyval.slist) = new std::vector(); (yyval.slist)->push_back((yyvsp[(1) - (1)].text)); @@ -2009,10 +1987,10 @@ yyreduce: } break; - case 49: + case 46: /* Line 1806 of yacc.c */ -#line 381 "config_parser.yy" +#line 370 "config_parser.yy" { if ((yyvsp[(1) - (3)].slist)) (yyval.slist) = (yyvsp[(1) - (3)].slist); @@ -2024,28 +2002,28 @@ yyreduce: } break; - case 50: + case 47: /* Line 1806 of yacc.c */ -#line 393 "config_parser.yy" +#line 382 "config_parser.yy" { (yyval.slist) = NULL; } break; - case 51: + case 48: /* Line 1806 of yacc.c */ -#line 397 "config_parser.yy" +#line 386 "config_parser.yy" { (yyval.slist) = (yyvsp[(2) - (2)].slist); } break; - case 52: + case 49: /* Line 1806 of yacc.c */ -#line 403 "config_parser.yy" +#line 392 "config_parser.yy" { if ((yyvsp[(2) - (3)].exprl)) (yyval.exprl) = (yyvsp[(2) - (3)].exprl); @@ -2054,37 +2032,37 @@ yyreduce: } break; - case 53: + case 50: /* Line 1806 of yacc.c */ -#line 412 "config_parser.yy" +#line 401 "config_parser.yy" { (yyval.exprl) = (yyvsp[(1) - (1)].exprl); } break; - case 54: + case 51: /* Line 1806 of yacc.c */ -#line 416 "config_parser.yy" +#line 405 "config_parser.yy" { (yyval.exprl) = (yyvsp[(1) - (2)].exprl); } break; - case 55: + case 52: /* Line 1806 of yacc.c */ -#line 421 "config_parser.yy" +#line 410 "config_parser.yy" { (yyval.exprl) = NULL; } break; - case 56: + case 53: /* Line 1806 of yacc.c */ -#line 425 "config_parser.yy" +#line 414 "config_parser.yy" { (yyval.exprl) = new ExpressionList(); (yyval.exprl)->AddExpression(*(yyvsp[(1) - (1)].expr)); @@ -2092,10 +2070,10 @@ yyreduce: } break; - case 57: + case 54: /* Line 1806 of yacc.c */ -#line 431 "config_parser.yy" +#line 420 "config_parser.yy" { if ((yyvsp[(1) - (3)].exprl)) (yyval.exprl) = (yyvsp[(1) - (3)].exprl); @@ -2107,10 +2085,10 @@ yyreduce: } break; - case 58: + case 55: /* Line 1806 of yacc.c */ -#line 443 "config_parser.yy" +#line 432 "config_parser.yy" { (yyval.expr) = new Expression((yyvsp[(1) - (3)].text), (yyvsp[(2) - (3)].op), *(yyvsp[(3) - (3)].variant), yylloc); free((yyvsp[(1) - (3)].text)); @@ -2118,10 +2096,10 @@ yyreduce: } break; - case 59: + case 56: /* Line 1806 of yacc.c */ -#line 449 "config_parser.yy" +#line 438 "config_parser.yy" { Expression subexpr((yyvsp[(3) - (6)].text), (yyvsp[(5) - (6)].op), *(yyvsp[(6) - (6)].variant), yylloc); free((yyvsp[(3) - (6)].text)); @@ -2135,55 +2113,55 @@ yyreduce: } break; - case 64: + case 61: /* Line 1806 of yacc.c */ -#line 467 "config_parser.yy" +#line 456 "config_parser.yy" { (yyval.op) = (yyvsp[(1) - (1)].op); } break; - case 65: + case 62: /* Line 1806 of yacc.c */ -#line 473 "config_parser.yy" +#line 462 "config_parser.yy" { (yyval.array) = (yyvsp[(2) - (3)].array); } break; - case 66: + case 63: /* Line 1806 of yacc.c */ -#line 479 "config_parser.yy" +#line 468 "config_parser.yy" { (yyval.array) = (yyvsp[(1) - (1)].array); } break; - case 67: + case 64: /* Line 1806 of yacc.c */ -#line 483 "config_parser.yy" +#line 472 "config_parser.yy" { (yyval.array) = (yyvsp[(1) - (2)].array); } break; - case 68: + case 65: /* Line 1806 of yacc.c */ -#line 488 "config_parser.yy" +#line 477 "config_parser.yy" { (yyval.array) = NULL; } break; - case 69: + case 66: /* Line 1806 of yacc.c */ -#line 492 "config_parser.yy" +#line 481 "config_parser.yy" { (yyval.array) = new Array(); @@ -2200,10 +2178,10 @@ yyreduce: } break; - case 70: + case 67: /* Line 1806 of yacc.c */ -#line 507 "config_parser.yy" +#line 496 "config_parser.yy" { if ((yyvsp[(1) - (3)].array)) (yyval.array) = (yyvsp[(1) - (3)].array); @@ -2223,38 +2201,38 @@ yyreduce: } break; - case 71: + case 68: /* Line 1806 of yacc.c */ -#line 527 "config_parser.yy" +#line 516 "config_parser.yy" { (yyval.variant) = new Value((yyvsp[(1) - (1)].text)); free((yyvsp[(1) - (1)].text)); } break; - case 72: + case 69: /* Line 1806 of yacc.c */ -#line 532 "config_parser.yy" +#line 521 "config_parser.yy" { (yyval.variant) = new Value((yyvsp[(1) - (1)].num)); } break; - case 73: + case 70: /* Line 1806 of yacc.c */ -#line 536 "config_parser.yy" +#line 525 "config_parser.yy" { (yyval.variant) = new Value(); } break; - case 74: + case 71: /* Line 1806 of yacc.c */ -#line 540 "config_parser.yy" +#line 529 "config_parser.yy" { if ((yyvsp[(1) - (1)].array) == NULL) (yyvsp[(1) - (1)].array) = new Array(); @@ -2264,48 +2242,48 @@ yyreduce: } break; - case 75: + case 72: /* Line 1806 of yacc.c */ -#line 550 "config_parser.yy" +#line 539 "config_parser.yy" { (yyval.variant) = (yyvsp[(2) - (3)].variant); } break; - case 76: + case 73: /* Line 1806 of yacc.c */ -#line 555 "config_parser.yy" +#line 544 "config_parser.yy" { (yyval.variant) = new Value((yyvsp[(1) - (1)].text)); free((yyvsp[(1) - (1)].text)); } break; - case 77: + case 74: /* Line 1806 of yacc.c */ -#line 560 "config_parser.yy" +#line 549 "config_parser.yy" { (yyval.variant) = new Value((yyvsp[(1) - (1)].num)); } break; - case 78: + case 75: /* Line 1806 of yacc.c */ -#line 564 "config_parser.yy" +#line 553 "config_parser.yy" { (yyval.variant) = new Value(ScriptVariable::Get((yyvsp[(1) - (1)].text))); free((yyvsp[(1) - (1)].text)); } break; - case 79: + case 76: /* Line 1806 of yacc.c */ -#line 569 "config_parser.yy" +#line 558 "config_parser.yy" { if ((yyvsp[(1) - (3)].variant)->GetType() == ValueString || (yyvsp[(3) - (3)].variant)->GetType() == ValueString) (yyval.variant) = new Value((String)*(yyvsp[(1) - (3)].variant) + (String)*(yyvsp[(3) - (3)].variant)); @@ -2317,10 +2295,10 @@ yyreduce: } break; - case 80: + case 77: /* Line 1806 of yacc.c */ -#line 579 "config_parser.yy" +#line 568 "config_parser.yy" { (yyval.variant) = new Value((double)*(yyvsp[(1) - (3)].variant) - (double)*(yyvsp[(3) - (3)].variant)); @@ -2329,10 +2307,10 @@ yyreduce: } break; - case 81: + case 78: /* Line 1806 of yacc.c */ -#line 586 "config_parser.yy" +#line 575 "config_parser.yy" { (yyval.variant) = new Value((double)*(yyvsp[(1) - (3)].variant) * (double)*(yyvsp[(3) - (3)].variant)); @@ -2341,10 +2319,10 @@ yyreduce: } break; - case 82: + case 79: /* Line 1806 of yacc.c */ -#line 593 "config_parser.yy" +#line 582 "config_parser.yy" { (yyval.variant) = new Value((double)*(yyvsp[(1) - (3)].variant) / (double)*(yyvsp[(3) - (3)].variant)); @@ -2353,10 +2331,10 @@ yyreduce: } break; - case 83: + case 80: /* Line 1806 of yacc.c */ -#line 600 "config_parser.yy" +#line 589 "config_parser.yy" { (yyval.variant) = new Value((long)*(yyvsp[(1) - (3)].variant) & (long)*(yyvsp[(3) - (3)].variant)); @@ -2365,10 +2343,10 @@ yyreduce: } break; - case 84: + case 81: /* Line 1806 of yacc.c */ -#line 607 "config_parser.yy" +#line 596 "config_parser.yy" { (yyval.variant) = new Value((long)*(yyvsp[(1) - (3)].variant) | (long)*(yyvsp[(3) - (3)].variant)); @@ -2377,10 +2355,10 @@ yyreduce: } break; - case 85: + case 82: /* Line 1806 of yacc.c */ -#line 614 "config_parser.yy" +#line 603 "config_parser.yy" { (yyval.variant) = new Value((long)*(yyvsp[(1) - (3)].variant) << (long)*(yyvsp[(3) - (3)].variant)); @@ -2389,10 +2367,10 @@ yyreduce: } break; - case 86: + case 83: /* Line 1806 of yacc.c */ -#line 621 "config_parser.yy" +#line 610 "config_parser.yy" { (yyval.variant) = new Value((long)*(yyvsp[(1) - (3)].variant) >> (long)*(yyvsp[(3) - (3)].variant)); @@ -2401,29 +2379,29 @@ yyreduce: } break; - case 87: + case 84: /* Line 1806 of yacc.c */ -#line 628 "config_parser.yy" +#line 617 "config_parser.yy" { (yyval.variant) = (yyvsp[(2) - (3)].variant); } break; - case 89: + case 86: /* Line 1806 of yacc.c */ -#line 635 "config_parser.yy" +#line 624 "config_parser.yy" { ExpressionList::Ptr exprl = ExpressionList::Ptr((yyvsp[(1) - (1)].exprl)); (yyval.variant) = new Value(exprl); } break; - case 90: + case 87: /* Line 1806 of yacc.c */ -#line 640 "config_parser.yy" +#line 629 "config_parser.yy" { (yyval.variant) = (yyvsp[(1) - (1)].variant); } @@ -2432,7 +2410,7 @@ yyreduce: /* Line 1806 of yacc.c */ -#line 2436 "../../../lib/config/config_parser.cc" +#line 2414 "../../../lib/config/config_parser.cc" default: break; } /* User semantic actions sometimes alter yychar, and that requires @@ -2670,6 +2648,6 @@ yyreturn: /* Line 2067 of yacc.c */ -#line 644 "config_parser.yy" +#line 633 "config_parser.yy" diff --git a/lib/config/config_parser.h b/lib/config/config_parser.h index fcc8faf60..92be1fece 100644 --- a/lib/config/config_parser.h +++ b/lib/config/config_parser.h @@ -112,13 +112,12 @@ using namespace icinga; T_REQUIRE = 279, T_ATTRIBUTE = 280, T_TYPE = 281, - T_ABSTRACT = 282, - T_OBJECT = 283, - T_TEMPLATE = 284, - T_INCLUDE = 285, - T_LIBRARY = 286, - T_INHERITS = 287, - T_PARTIAL = 288 + T_OBJECT = 282, + T_TEMPLATE = 283, + T_INCLUDE = 284, + T_LIBRARY = 285, + T_INHERITS = 286, + T_PARTIAL = 287 }; #endif /* Tokens. */ @@ -146,13 +145,12 @@ using namespace icinga; #define T_REQUIRE 279 #define T_ATTRIBUTE 280 #define T_TYPE 281 -#define T_ABSTRACT 282 -#define T_OBJECT 283 -#define T_TEMPLATE 284 -#define T_INCLUDE 285 -#define T_LIBRARY 286 -#define T_INHERITS 287 -#define T_PARTIAL 288 +#define T_OBJECT 282 +#define T_TEMPLATE 283 +#define T_INCLUDE 284 +#define T_LIBRARY 285 +#define T_INHERITS 286 +#define T_PARTIAL 287 @@ -177,7 +175,7 @@ typedef union YYSTYPE /* Line 2068 of yacc.c */ -#line 181 "../../../lib/config/config_parser.h" +#line 179 "../../../lib/config/config_parser.h" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ diff --git a/lib/config/config_parser.yy b/lib/config/config_parser.yy index db2c3b3b2..672a91de1 100644 --- a/lib/config/config_parser.yy +++ b/lib/config/config_parser.yy @@ -87,7 +87,6 @@ using namespace icinga; %token T_REQUIRE "%require (T_REQUIRE)" %token T_ATTRIBUTE "%attribute (T_ATTRIBUTE)" %token T_TYPE "type (T_TYPE)" -%token T_ABSTRACT "abstract (T_ABSTRACT)" %token T_OBJECT "object (T_OBJECT)" %token T_TEMPLATE "template (T_TEMPLATE)" %token T_INCLUDE "include (T_INCLUDE)" @@ -351,22 +350,12 @@ object_declaration identifier T_STRING object_inherits_specifier expressionlist } ; -object_declaration: attributes T_OBJECT +object_declaration: T_OBJECT | T_TEMPLATE { m_Abstract = true; } -attributes: /* empty */ - | attributes attribute - ; - -attribute: T_ABSTRACT - { - m_Abstract = true; - } - ; - object_inherits_list: { $$ = NULL; -- 2.50.0