From: Thomas Markwalder Date: Thu, 26 Jan 2017 14:03:15 +0000 (-0500) Subject: [5110] Adding bison parsing for forward-ddns and reverser-ddns to D2 X-Git-Tag: trac1205_base^2~13 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e93455bd5c3ff2788dc0833a73049c105e5348db;p=thirdparty%2Fkea.git [5110] Adding bison parsing for forward-ddns and reverser-ddns to D2 src/bin/d2/d2_lexer.ll Added regexp for ddns-domians, key-name, dns-servers, hostname src/bin/d2/d2_parser.yy Added tokens and rules for ddns-domains, key-name, dns-servers, hostname src/bin/d2/parser_context.h src/bin/d2/parser_context.cc Added contexts FORWARD_DDNS, REVERSE_DDNS, DDNS_DOMAINS, DNS_SERVERS, src/bin/d2/tests/testdata/d2_cfg_tests.json Changed logic-errors to syntax-errors --- diff --git a/src/bin/d2/d2_lexer.cc b/src/bin/d2/d2_lexer.cc index 4c910b495b..a05a38cadf 100644 --- a/src/bin/d2/d2_lexer.cc +++ b/src/bin/d2/d2_lexer.cc @@ -524,8 +524,8 @@ static void yynoreturn yy_fatal_error ( const char* msg ); /* %% [3.0] code to copy yytext_ptr to d2_parser_text[] goes here, if %array \ */\ (yy_c_buf_p) = yy_cp; /* %% [4.0] data tables for the DFA and the user's section 1 definitions go here */ -#define YY_NUM_RULES 54 -#define YY_END_OF_BUFFER 55 +#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 @@ -533,42 +533,45 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static const flex_int16_t yy_accept[304] = +static const flex_int16_t yy_accept[336] = { 0, - 47, 47, 0, 0, 0, 0, 0, 0, 0, 0, - 55, 53, 10, 11, 53, 1, 47, 44, 47, 47, - 53, 46, 45, 53, 53, 53, 53, 53, 40, 41, - 53, 53, 53, 42, 43, 5, 5, 5, 53, 53, - 53, 10, 11, 0, 0, 36, 0, 0, 0, 0, + 51, 51, 0, 0, 0, 0, 0, 0, 0, 0, + 59, 57, 10, 11, 57, 1, 51, 48, 51, 51, + 57, 50, 49, 57, 57, 57, 57, 57, 44, 45, + 57, 57, 57, 46, 47, 5, 5, 5, 57, 57, + 57, 10, 11, 0, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 1, 47, 47, 0, 46, 47, 3, - 2, 6, 0, 47, 0, 0, 0, 0, 0, 0, - 4, 0, 0, 9, 0, 37, 0, 0, 0, 0, - 0, 0, 0, 39, 0, 0, 0, 0, 0, 0, - - 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, - 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, - 0, 0, 0, 0, 0, 38, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 51, 51, 0, 50, + 51, 3, 2, 6, 0, 51, 0, 0, 0, 0, + 0, 0, 4, 0, 0, 9, 0, 41, 0, 0, + 0, 0, 0, 0, 0, 43, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, + 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 52, 50, 0, 49, 48, 0, 0, - 0, 0, 0, 19, 18, 0, 0, 0, 0, 0, + 0, 56, 54, 0, 53, 52, 0, 0, 0, 0, + 0, 19, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 51, 48, 0, 0, 0, 0, 0, 20, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 31, 0, - 0, 0, 14, 0, 0, 0, 0, 0, 0, 34, - - 35, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, - 0, 0, 26, 0, 0, 0, 27, 0, 0, 0, - 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, - 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 33, 0, 24, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 23, 32, 0, 0, 0, 13, 17, - 0, 0, 0, 25, 0, 0, 0, 0, 0, 0, - 21, 16, 0, 22, 0, 0, 0, 29, 0, 0, - - 0, 15, 0 + 0, 0, 55, 52, 0, 0, 0, 0, 0, 20, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 35, 0, 0, 0, 14, 0, 0, 0, + 0, 0, 0, 38, 39, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 34, + 0, 0, 30, 0, 0, 0, 31, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, + 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, + 26, 0, 24, 0, 0, 0, 0, 37, 0, 28, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + + 27, 0, 36, 0, 0, 0, 0, 13, 17, 0, + 0, 0, 0, 29, 0, 25, 0, 0, 0, 0, + 23, 0, 21, 16, 0, 22, 0, 0, 0, 33, + 0, 0, 0, 15, 0 } ; static const YY_CHAR yy_ec[256] = @@ -614,85 +617,91 @@ static const YY_CHAR yy_meta[65] = 3, 3, 3, 3 } ; -static const flex_int16_t yy_base[316] = +static const flex_int16_t yy_base[348] = { 0, 0, 0, 63, 66, 69, 0, 67, 71, 52, 68, - 311, 1963, 87, 307, 133, 0, 96, 1963, 130, 133, - 84, 150, 1963, 288, 109, 69, 67, 72, 1963, 1963, - 110, 71, 97, 1963, 1963, 1963, 97, 283, 242, 0, - 273, 139, 281, 132, 194, 1963, 200, 206, 212, 218, - 224, 227, 250, 256, 268, 275, 288, 296, 312, 318, - 325, 338, 344, 0, 343, 349, 369, 380, 374, 1963, - 0, 1963, 220, 230, 128, 165, 124, 171, 177, 145, - 1963, 233, 248, 1963, 148, 1963, 385, 405, 426, 411, - 433, 448, 232, 459, 490, 471, 481, 491, 518, 537, - - 465, 543, 550, 557, 563, 570, 580, 595, 602, 0, - 246, 214, 127, 249, 222, 173, 181, 1963, 0, 608, - 617, 627, 641, 650, 217, 1963, 674, 656, 665, 702, - 674, 719, 725, 731, 739, 747, 758, 768, 784, 790, - 796, 805, 185, 1963, 1963, 263, 1963, 1963, 152, 0, - 828, 813, 835, 1963, 1963, 870, 852, 860, 867, 897, - 915, 924, 934, 940, 947, 956, 962, 973, 979, 985, - 994, 1963, 1963, 129, 0, 1005, 1011, 1018, 1963, 1031, - 1071, 1043, 1037, 1061, 1098, 1069, 1120, 1127, 1963, 1135, - 1142, 1148, 1963, 1159, 1165, 1172, 1185, 119, 0, 1963, - - 1963, 1191, 1202, 1209, 1224, 1239, 1250, 1256, 1263, 1271, - 1277, 1283, 1295, 1301, 1289, 1309, 1315, 1963, 1321, 1338, - 1347, 1354, 1360, 1367, 1379, 1386, 1397, 1404, 1416, 1963, - 1423, 1434, 1963, 1441, 1448, 1456, 1963, 1462, 1478, 1486, - 1494, 1503, 1510, 1963, 1518, 1524, 1542, 1548, 1562, 1568, - 1963, 1574, 1580, 1586, 1592, 1600, 1612, 1618, 1633, 1644, - 1650, 1963, 1657, 1963, 1671, 1677, 1689, 1683, 1695, 1703, - 1709, 1716, 1722, 1963, 1963, 1736, 1742, 1748, 1963, 1963, - 1755, 1764, 1775, 1963, 1785, 1792, 1801, 1807, 1813, 1822, - 1963, 1963, 1833, 1963, 1839, 1845, 1851, 1963, 1860, 1866, - - 1878, 1963, 1963, 1924, 1929, 1934, 1939, 1944, 1949, 1954, - 1957, 146, 132, 91, 88 + 296, 2262, 87, 289, 133, 0, 96, 2262, 130, 133, + 84, 150, 2262, 268, 109, 69, 67, 72, 2262, 2262, + 110, 71, 97, 2262, 2262, 2262, 97, 271, 229, 0, + 235, 139, 247, 132, 194, 2262, 200, 206, 212, 218, + 224, 227, 250, 256, 268, 275, 288, 305, 313, 329, + 335, 345, 351, 359, 374, 0, 375, 390, 312, 398, + 393, 2262, 0, 2262, 220, 230, 128, 165, 163, 177, + 214, 164, 2262, 196, 226, 2262, 148, 2262, 380, 426, + 442, 448, 455, 464, 211, 472, 506, 487, 481, 501, + + 534, 551, 557, 563, 572, 584, 590, 596, 604, 613, + 622, 628, 637, 650, 0, 240, 247, 127, 246, 267, + 185, 160, 2262, 0, 666, 679, 688, 698, 704, 198, + 2262, 728, 711, 721, 727, 754, 773, 760, 779, 786, + 793, 799, 805, 811, 826, 832, 838, 849, 855, 864, + 295, 2262, 2262, 315, 2262, 2262, 113, 0, 882, 870, + 910, 2262, 2262, 945, 919, 925, 936, 942, 975, 990, + 999, 1005, 1012, 1018, 1032, 1038, 1044, 1055, 1065, 1071, + 1083, 1093, 2262, 2262, 120, 0, 1104, 1110, 1116, 2262, + 1123, 1163, 1132, 1155, 1162, 1194, 1209, 1217, 1223, 1231, + + 1238, 1255, 2262, 1263, 1278, 1284, 2262, 1292, 1300, 1306, + 1322, 115, 0, 2262, 2262, 1329, 1338, 1344, 1350, 1359, + 1368, 1387, 1405, 1412, 1419, 1425, 1431, 1444, 1452, 1464, + 1470, 1481, 1489, 1496, 2262, 1507, 1514, 1521, 1528, 1535, + 1547, 1553, 1560, 1572, 1580, 1590, 1598, 1604, 1617, 2262, + 1627, 1636, 2262, 1642, 1649, 1656, 2262, 1664, 1681, 1688, + 1694, 1704, 1721, 1732, 1743, 1749, 2262, 1759, 1765, 1771, + 1781, 1788, 1803, 2262, 1809, 1826, 1832, 1841, 1847, 1853, + 2262, 1864, 2262, 1870, 1885, 1879, 1892, 2262, 1903, 2262, + 1909, 1917, 1930, 1941, 1947, 1954, 1962, 1968, 1979, 1987, + + 2262, 2000, 2262, 2006, 2012, 2027, 2044, 2262, 2262, 2052, + 2059, 2065, 2071, 2262, 2077, 2262, 2084, 2091, 2103, 2109, + 2262, 2117, 2262, 2262, 2128, 2262, 2135, 2141, 2147, 2262, + 2156, 2165, 2174, 2262, 2262, 2223, 2228, 2233, 2238, 2243, + 2248, 2253, 2256, 146, 132, 91, 88 } ; -static const flex_int16_t yy_def[316] = +static const flex_int16_t yy_def[348] = { 0, - 303, 1, 304, 304, 1, 5, 5, 5, 5, 5, - 303, 303, 303, 303, 305, 306, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 307, - 303, 303, 303, 308, 305, 303, 305, 305, 305, 305, - 305, 309, 305, 305, 305, 305, 305, 305, 305, 305, - 305, 305, 305, 306, 303, 303, 303, 303, 303, 303, - 310, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 307, 303, 308, 303, 303, 305, 305, 305, - 305, 305, 311, 305, 309, 305, 305, 305, 305, 305, - - 305, 305, 305, 305, 305, 305, 305, 305, 305, 310, - 303, 303, 303, 303, 303, 303, 303, 303, 312, 305, - 305, 305, 305, 305, 311, 303, 309, 305, 305, 305, - 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, - 305, 305, 303, 303, 303, 303, 303, 303, 303, 313, - 305, 305, 305, 303, 303, 309, 305, 305, 305, 305, - 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, - 305, 303, 303, 303, 314, 305, 305, 305, 303, 305, - 309, 305, 305, 305, 305, 305, 305, 305, 303, 305, - 305, 305, 303, 305, 305, 305, 305, 303, 315, 303, - - 303, 305, 305, 305, 305, 305, 305, 305, 305, 305, - 305, 305, 305, 305, 305, 305, 305, 303, 305, 305, - 305, 305, 305, 305, 305, 305, 305, 305, 305, 303, - 305, 305, 303, 305, 305, 305, 303, 305, 305, 305, - 305, 305, 305, 303, 305, 305, 305, 305, 305, 305, - 303, 305, 305, 305, 305, 305, 305, 305, 305, 305, - 305, 303, 305, 303, 305, 305, 305, 305, 305, 305, - 305, 305, 305, 303, 303, 305, 305, 305, 303, 303, - 305, 305, 305, 303, 305, 305, 305, 305, 305, 305, - 303, 303, 305, 303, 305, 305, 305, 303, 305, 305, - - 305, 303, 0, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303 + 335, 1, 336, 336, 1, 5, 5, 5, 5, 5, + 335, 335, 335, 335, 337, 338, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 339, + 335, 335, 335, 340, 337, 335, 337, 337, 337, 337, + 337, 341, 337, 337, 337, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 337, 338, 335, 335, 335, 335, + 335, 335, 342, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 339, 335, 340, 335, 335, 337, + 337, 337, 337, 337, 343, 337, 341, 337, 337, 337, + + 337, 337, 337, 337, 337, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 342, 335, 335, 335, 335, 335, + 335, 335, 335, 344, 337, 337, 337, 337, 337, 343, + 335, 341, 337, 337, 337, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 337, 337, 337, 337, 337, 337, + 335, 335, 335, 335, 335, 335, 335, 345, 337, 337, + 337, 335, 335, 341, 337, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 337, 337, 337, 337, 337, 337, + 337, 337, 335, 335, 335, 346, 337, 337, 337, 335, + 337, 341, 337, 337, 337, 337, 337, 337, 337, 337, + + 337, 337, 335, 337, 337, 337, 335, 337, 337, 337, + 337, 335, 347, 335, 335, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 337, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 335, 337, 337, 337, 337, 337, + 337, 337, 337, 337, 337, 337, 337, 337, 337, 335, + 337, 337, 335, 337, 337, 337, 335, 337, 337, 337, + 337, 337, 337, 337, 337, 337, 335, 337, 337, 337, + 337, 337, 337, 335, 337, 337, 337, 337, 337, 337, + 335, 337, 335, 337, 337, 337, 337, 335, 337, 335, + 337, 337, 337, 337, 337, 337, 337, 337, 337, 337, + + 335, 337, 335, 337, 337, 337, 337, 335, 335, 337, + 337, 337, 337, 335, 337, 335, 337, 337, 337, 337, + 335, 337, 335, 335, 337, 335, 337, 337, 337, 335, + 337, 337, 337, 335, 0, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335 } ; -static const flex_int16_t yy_nxt[2028] = +static const flex_int16_t yy_nxt[2327] = { 0, 12, 13, 14, 13, 12, 15, 16, 12, 17, 18, 19, 20, 21, 22, 22, 22, 23, 24, 12, 12, @@ -702,224 +711,257 @@ static const flex_int16_t yy_nxt[2028] = 12, 12, 32, 12, 12, 12, 12, 33, 12, 12, 12, 12, 34, 35, 37, 14, 37, 37, 14, 37, 38, 41, 40, 38, 12, 12, 40, 12, 12, 12, - 12, 12, 12, 12, 12, 12, 12, 41, 42, 75, - 42, 70, 85, 12, 12, 199, 71, 12, 42, 12, - - 42, 76, 12, 77, 12, 76, 12, 65, 75, 66, - 66, 66, 12, 12, 12, 12, 39, 73, 12, 73, - 67, 12, 74, 74, 74, 76, 12, 77, 77, 79, - 75, 12, 12, 44, 44, 44, 175, 86, 46, 67, - 42, 65, 42, 68, 68, 68, 69, 69, 69, 78, - 150, 145, 80, 86, 67, 111, 47, 67, 113, 48, - 49, 65, 218, 68, 68, 68, 50, 51, 87, 52, - 145, 198, 53, 67, 67, 54, 67, 55, 111, 113, - 56, 48, 113, 57, 87, 58, 59, 60, 61, 62, - 63, 51, 112, 67, 44, 44, 44, 145, 111, 46, - - 44, 44, 44, 116, 112, 46, 44, 44, 44, 172, - 174, 46, 44, 44, 44, 112, 148, 46, 44, 44, - 44, 114, 126, 46, 44, 44, 44, 115, 172, 46, - 52, 149, 94, 74, 74, 74, 52, 126, 89, 45, - 91, 144, 52, 74, 74, 74, 88, 92, 52, 144, - 44, 44, 44, 118, 52, 46, 44, 44, 44, 91, - 52, 46, 89, 45, 144, 90, 92, 45, 44, 44, - 44, 45, 147, 46, 117, 44, 44, 44, 143, 45, - 46, 143, 45, 43, 45, 95, 52, 172, 44, 44, - 44, 84, 52, 46, 82, 81, 44, 44, 44, 97, - - 96, 46, 143, 98, 52, 146, 173, 72, 99, 43, - 303, 52, 44, 44, 44, 303, 303, 46, 44, 44, - 44, 100, 303, 46, 52, 44, 44, 44, 303, 101, - 46, 303, 52, 303, 303, 103, 303, 104, 44, 44, - 44, 102, 303, 46, 44, 44, 44, 303, 52, 46, - 303, 303, 303, 303, 52, 303, 69, 69, 69, 303, - 65, 52, 66, 66, 66, 303, 91, 67, 107, 303, - 105, 106, 303, 67, 52, 303, 303, 73, 303, 73, - 52, 108, 74, 74, 74, 91, 67, 69, 69, 69, - 85, 65, 67, 68, 68, 68, 303, 85, 67, 303, - - 109, 303, 303, 303, 67, 44, 44, 44, 303, 303, - 46, 44, 44, 44, 303, 303, 46, 67, 303, 303, - 303, 85, 303, 67, 303, 85, 44, 44, 44, 85, - 303, 46, 303, 44, 44, 44, 303, 85, 46, 303, - 85, 52, 85, 119, 303, 303, 120, 52, 44, 44, - 44, 303, 303, 46, 303, 121, 122, 303, 303, 44, - 44, 44, 52, 123, 46, 44, 44, 44, 303, 52, - 46, 44, 44, 44, 303, 133, 46, 303, 124, 121, - 303, 44, 44, 44, 52, 303, 46, 123, 303, 303, - 303, 44, 44, 44, 303, 52, 46, 303, 303, 303, - - 303, 52, 124, 127, 127, 127, 303, 52, 303, 303, - 127, 127, 127, 127, 127, 127, 128, 52, 44, 44, - 44, 129, 303, 46, 303, 303, 303, 52, 303, 127, - 127, 127, 127, 127, 127, 303, 130, 44, 44, 44, - 303, 303, 46, 44, 44, 44, 303, 303, 46, 303, - 44, 44, 44, 303, 52, 46, 303, 44, 44, 44, - 303, 303, 46, 44, 44, 44, 303, 303, 46, 303, - 44, 44, 44, 52, 131, 46, 303, 303, 303, 52, - 44, 44, 44, 303, 303, 46, 52, 303, 134, 303, - 303, 303, 132, 52, 303, 44, 44, 44, 303, 52, - - 46, 135, 44, 44, 44, 303, 52, 46, 44, 44, - 44, 303, 136, 46, 303, 303, 52, 44, 44, 44, - 137, 303, 46, 303, 303, 138, 303, 44, 44, 44, - 303, 52, 46, 303, 303, 303, 140, 303, 52, 139, - 303, 44, 44, 44, 52, 152, 154, 303, 303, 142, - 44, 44, 44, 52, 141, 155, 44, 44, 44, 303, - 303, 46, 151, 52, 303, 44, 44, 44, 303, 152, - 46, 303, 153, 303, 44, 44, 44, 52, 303, 46, - 303, 303, 303, 303, 160, 303, 52, 156, 156, 156, - 303, 303, 52, 303, 156, 156, 156, 156, 156, 156, - - 303, 52, 44, 44, 44, 303, 303, 46, 303, 157, - 52, 303, 303, 156, 156, 156, 156, 156, 156, 44, - 44, 44, 303, 158, 46, 44, 44, 44, 303, 303, - 46, 44, 44, 44, 303, 303, 46, 303, 52, 44, - 44, 44, 303, 303, 46, 159, 303, 44, 44, 44, - 303, 303, 46, 303, 303, 52, 303, 165, 44, 44, - 44, 52, 303, 46, 162, 303, 303, 52, 44, 44, - 44, 303, 303, 46, 303, 52, 163, 303, 303, 161, - 303, 303, 164, 52, 44, 44, 44, 303, 303, 46, - 44, 44, 44, 303, 52, 46, 44, 44, 44, 303, - - 303, 46, 303, 303, 52, 44, 44, 44, 303, 303, - 46, 303, 166, 44, 44, 44, 303, 303, 179, 303, - 52, 303, 303, 303, 303, 167, 52, 168, 44, 44, - 44, 303, 52, 46, 303, 44, 44, 44, 303, 170, - 46, 52, 176, 177, 303, 169, 303, 303, 303, 52, - 171, 178, 44, 44, 44, 303, 303, 46, 303, 303, - 44, 44, 44, 303, 52, 46, 303, 44, 44, 44, - 303, 52, 46, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 180, 181, 181, 181, 303, 303, 52, 303, - 181, 181, 181, 181, 181, 181, 52, 44, 44, 44, - - 303, 303, 46, 52, 303, 183, 303, 182, 303, 181, - 181, 181, 181, 181, 181, 44, 44, 44, 303, 303, - 46, 303, 303, 184, 44, 44, 44, 303, 303, 46, - 303, 303, 303, 52, 44, 44, 44, 303, 303, 46, - 44, 44, 44, 303, 303, 189, 303, 44, 44, 44, - 303, 52, 46, 185, 186, 303, 44, 44, 44, 303, - 52, 46, 44, 44, 44, 303, 187, 193, 303, 303, - 52, 303, 303, 44, 44, 44, 52, 188, 46, 44, - 44, 44, 303, 52, 46, 44, 44, 44, 303, 303, - 46, 190, 52, 303, 44, 44, 44, 303, 52, 46, - - 303, 191, 303, 303, 197, 44, 44, 44, 303, 52, - 200, 44, 44, 44, 192, 52, 201, 303, 44, 44, - 44, 52, 195, 46, 303, 303, 303, 303, 194, 303, - 52, 44, 44, 44, 303, 303, 46, 44, 44, 44, - 196, 52, 46, 44, 44, 44, 303, 52, 46, 303, - 303, 303, 303, 303, 52, 303, 303, 303, 303, 303, - 202, 44, 44, 44, 303, 303, 46, 52, 303, 44, - 44, 44, 303, 52, 46, 303, 303, 303, 303, 52, - 303, 303, 303, 203, 45, 45, 45, 205, 303, 303, - 204, 45, 45, 45, 45, 45, 45, 52, 44, 44, - - 44, 303, 303, 46, 303, 52, 303, 303, 303, 303, - 45, 45, 45, 45, 45, 45, 303, 303, 206, 303, - 44, 44, 44, 303, 208, 46, 303, 44, 44, 44, - 303, 303, 46, 303, 52, 44, 44, 44, 303, 303, - 46, 207, 44, 44, 44, 303, 303, 46, 44, 44, - 44, 303, 303, 46, 303, 303, 52, 303, 303, 44, - 44, 44, 209, 52, 46, 44, 44, 44, 303, 303, - 46, 52, 44, 44, 44, 303, 303, 46, 52, 303, - 303, 303, 210, 303, 52, 44, 44, 44, 211, 303, - 46, 44, 44, 44, 303, 52, 46, 212, 303, 303, - - 303, 52, 44, 44, 44, 213, 303, 46, 52, 44, - 44, 44, 303, 303, 46, 214, 303, 303, 303, 216, - 303, 52, 215, 303, 44, 44, 44, 52, 303, 46, - 303, 303, 303, 303, 217, 303, 303, 303, 52, 44, - 44, 44, 303, 219, 46, 52, 303, 220, 303, 223, - 44, 44, 44, 303, 303, 46, 44, 44, 44, 303, - 52, 46, 303, 44, 44, 44, 221, 222, 46, 303, - 303, 44, 44, 44, 303, 52, 46, 44, 44, 44, - 303, 303, 46, 44, 44, 44, 52, 303, 46, 44, - 44, 44, 52, 303, 233, 44, 44, 44, 225, 52, - - 230, 44, 44, 44, 303, 224, 46, 52, 303, 44, - 44, 44, 303, 52, 46, 44, 44, 44, 226, 52, - 46, 44, 44, 44, 303, 52, 46, 227, 303, 303, - 303, 52, 228, 231, 303, 303, 229, 52, 44, 44, - 44, 303, 303, 237, 232, 52, 303, 44, 44, 44, - 303, 52, 46, 303, 44, 44, 44, 52, 235, 46, - 44, 44, 44, 303, 303, 46, 234, 44, 44, 44, - 303, 303, 46, 303, 52, 303, 303, 236, 303, 44, - 44, 44, 303, 52, 46, 303, 44, 44, 44, 242, - 52, 46, 303, 238, 303, 303, 52, 44, 44, 44, - - 240, 303, 244, 52, 44, 44, 44, 303, 303, 46, - 303, 303, 303, 239, 303, 52, 44, 44, 44, 303, - 303, 46, 52, 44, 44, 44, 241, 303, 46, 243, - 303, 303, 303, 52, 44, 44, 44, 303, 303, 46, - 52, 44, 44, 44, 248, 303, 46, 303, 44, 44, - 44, 303, 52, 46, 303, 245, 44, 44, 44, 52, - 303, 251, 44, 44, 44, 303, 303, 46, 303, 303, - 52, 303, 303, 246, 303, 303, 247, 52, 44, 44, - 44, 303, 303, 46, 52, 303, 44, 44, 44, 303, - 303, 46, 52, 303, 44, 44, 44, 303, 52, 46, - - 303, 303, 249, 44, 44, 44, 303, 303, 46, 250, - 44, 44, 44, 252, 52, 46, 303, 303, 44, 44, - 44, 253, 52, 46, 44, 44, 44, 303, 303, 46, - 52, 303, 303, 254, 303, 303, 303, 255, 303, 52, - 303, 303, 44, 44, 44, 256, 52, 46, 44, 44, - 44, 303, 303, 46, 52, 303, 303, 258, 303, 303, - 52, 303, 44, 44, 44, 303, 257, 262, 44, 44, - 44, 303, 303, 46, 44, 44, 44, 259, 52, 264, - 44, 44, 44, 303, 52, 46, 44, 44, 44, 303, - 261, 46, 44, 44, 44, 303, 260, 46, 52, 303, - - 44, 44, 44, 303, 52, 46, 303, 303, 303, 303, - 52, 303, 44, 44, 44, 303, 52, 46, 44, 44, - 44, 303, 52, 46, 263, 303, 303, 303, 52, 303, - 265, 303, 303, 44, 44, 44, 52, 303, 46, 303, - 303, 303, 268, 266, 44, 44, 44, 267, 52, 46, - 44, 44, 44, 303, 52, 46, 303, 44, 44, 44, - 303, 303, 274, 303, 303, 303, 303, 303, 269, 52, - 303, 44, 44, 44, 271, 270, 275, 44, 44, 44, - 52, 303, 46, 44, 44, 44, 52, 303, 46, 44, - 44, 44, 273, 52, 46, 44, 44, 44, 303, 277, - - 279, 272, 303, 44, 44, 44, 303, 52, 280, 44, - 44, 44, 303, 52, 46, 303, 44, 44, 44, 52, - 303, 46, 44, 44, 44, 52, 303, 46, 303, 303, - 303, 52, 303, 276, 303, 278, 44, 44, 44, 52, - 303, 284, 44, 44, 44, 52, 303, 46, 44, 44, - 44, 303, 52, 46, 303, 44, 44, 44, 52, 303, - 46, 303, 281, 282, 44, 44, 44, 303, 303, 46, - 303, 303, 52, 303, 283, 44, 44, 44, 52, 303, - 46, 303, 303, 303, 52, 44, 44, 44, 303, 303, - 46, 52, 44, 44, 44, 303, 303, 291, 303, 285, - - 52, 44, 44, 44, 286, 287, 292, 44, 44, 44, - 303, 52, 46, 44, 44, 44, 303, 288, 294, 303, - 303, 52, 44, 44, 44, 303, 303, 46, 52, 303, - 303, 289, 290, 44, 44, 44, 303, 52, 46, 44, - 44, 44, 303, 52, 46, 44, 44, 44, 303, 52, - 298, 44, 44, 44, 303, 303, 46, 303, 52, 293, - 44, 44, 44, 303, 303, 46, 44, 44, 44, 52, - 303, 46, 303, 295, 303, 52, 303, 303, 44, 44, - 44, 52, 297, 302, 303, 303, 303, 52, 303, 296, - 303, 303, 303, 303, 303, 303, 52, 303, 303, 303, - - 303, 303, 52, 303, 299, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 52, 303, 303, 303, 300, 303, - 303, 303, 303, 301, 36, 36, 36, 36, 36, 45, - 45, 45, 45, 45, 64, 303, 64, 64, 64, 83, - 303, 83, 303, 83, 85, 85, 85, 85, 85, 93, - 93, 93, 93, 93, 110, 303, 110, 110, 110, 125, - 125, 125, 11, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303 + 12, 12, 12, 12, 12, 12, 12, 41, 42, 77, + 42, 72, 87, 12, 12, 213, 73, 12, 42, 12, + + 42, 78, 12, 79, 12, 78, 12, 67, 77, 68, + 68, 68, 12, 12, 12, 12, 39, 75, 12, 75, + 69, 12, 76, 76, 76, 78, 12, 79, 79, 81, + 77, 12, 12, 44, 44, 44, 186, 88, 46, 69, + 42, 67, 42, 70, 70, 70, 71, 71, 71, 80, + 158, 153, 82, 88, 69, 116, 47, 69, 235, 48, + 49, 67, 212, 70, 70, 70, 50, 51, 89, 52, + 153, 185, 53, 69, 69, 54, 69, 55, 116, 56, + 57, 48, 58, 59, 89, 60, 61, 62, 63, 64, + 65, 51, 117, 69, 44, 44, 44, 118, 118, 46, + + 44, 44, 44, 131, 116, 46, 44, 44, 44, 153, + 157, 46, 44, 44, 44, 117, 131, 46, 44, 44, + 44, 118, 121, 46, 44, 44, 44, 119, 156, 46, + 52, 123, 96, 76, 76, 76, 52, 122, 91, 45, + 93, 117, 52, 76, 76, 76, 90, 94, 52, 43, + 44, 44, 44, 86, 52, 46, 44, 44, 44, 93, + 52, 46, 91, 45, 120, 92, 94, 45, 44, 44, + 44, 45, 151, 46, 152, 44, 44, 44, 151, 45, + 46, 84, 45, 83, 45, 97, 52, 74, 44, 44, + 44, 43, 52, 46, 152, 335, 151, 152, 99, 100, + + 98, 335, 154, 101, 52, 44, 44, 44, 102, 335, + 46, 52, 335, 44, 44, 44, 335, 155, 46, 183, + 75, 103, 75, 335, 52, 76, 76, 76, 104, 44, + 44, 44, 335, 335, 46, 44, 44, 44, 183, 183, + 46, 52, 105, 335, 335, 44, 44, 44, 106, 52, + 46, 44, 44, 44, 335, 335, 46, 335, 184, 44, + 44, 44, 335, 335, 46, 52, 107, 335, 108, 335, + 109, 52, 335, 335, 44, 44, 44, 335, 335, 46, + 335, 52, 335, 335, 335, 87, 335, 52, 71, 71, + 71, 335, 87, 110, 112, 52, 93, 335, 111, 69, + + 335, 67, 113, 68, 68, 68, 71, 71, 71, 67, + 52, 70, 70, 70, 69, 93, 87, 69, 69, 335, + 87, 335, 69, 335, 87, 335, 44, 44, 44, 335, + 114, 46, 87, 69, 335, 87, 69, 87, 124, 335, + 335, 69, 44, 44, 44, 335, 335, 46, 44, 44, + 44, 335, 335, 46, 335, 44, 44, 44, 335, 335, + 46, 335, 52, 335, 44, 44, 44, 125, 335, 46, + 335, 126, 44, 44, 44, 335, 335, 46, 52, 335, + 335, 44, 44, 44, 52, 128, 46, 44, 44, 44, + 335, 52, 46, 127, 129, 126, 335, 335, 335, 335, + + 52, 44, 44, 44, 335, 335, 46, 335, 52, 128, + 335, 335, 335, 335, 335, 335, 335, 52, 129, 132, + 132, 132, 335, 52, 335, 335, 132, 132, 132, 132, + 132, 132, 133, 134, 44, 44, 44, 52, 335, 46, + 335, 135, 335, 335, 335, 132, 132, 132, 132, 132, + 132, 44, 44, 44, 335, 335, 46, 44, 44, 44, + 335, 335, 46, 44, 44, 44, 335, 335, 46, 335, + 52, 335, 44, 44, 44, 335, 335, 46, 335, 136, + 335, 335, 140, 335, 44, 44, 44, 52, 335, 46, + 44, 44, 44, 52, 335, 46, 44, 44, 44, 52, + + 335, 46, 335, 335, 44, 44, 44, 137, 52, 46, + 335, 335, 138, 44, 44, 44, 335, 335, 46, 139, + 52, 335, 44, 44, 44, 335, 52, 46, 44, 44, + 44, 335, 52, 46, 335, 142, 335, 44, 44, 44, + 52, 335, 46, 335, 335, 141, 335, 143, 335, 52, + 44, 44, 44, 335, 335, 46, 335, 335, 52, 144, + 335, 335, 335, 335, 52, 335, 44, 44, 44, 335, + 145, 46, 335, 52, 335, 335, 335, 146, 148, 44, + 44, 44, 335, 335, 46, 335, 52, 147, 44, 44, + 44, 335, 335, 46, 335, 335, 149, 150, 44, 44, + + 44, 335, 52, 162, 44, 44, 44, 160, 335, 163, + 335, 44, 44, 44, 335, 52, 46, 335, 335, 335, + 159, 44, 44, 44, 52, 335, 46, 44, 44, 44, + 335, 160, 46, 161, 52, 335, 335, 335, 335, 335, + 52, 164, 164, 164, 335, 335, 335, 52, 164, 164, + 164, 164, 164, 164, 44, 44, 44, 52, 335, 46, + 44, 44, 44, 52, 165, 46, 335, 164, 164, 164, + 164, 164, 164, 44, 44, 44, 335, 166, 46, 44, + 44, 44, 335, 169, 46, 167, 44, 44, 44, 335, + 52, 46, 335, 44, 44, 44, 52, 168, 46, 44, + + 44, 44, 335, 173, 46, 44, 44, 44, 335, 52, + 46, 44, 44, 44, 335, 52, 46, 335, 335, 335, + 170, 176, 52, 335, 335, 172, 44, 44, 44, 52, + 335, 46, 44, 44, 44, 52, 171, 46, 44, 44, + 44, 52, 335, 46, 174, 335, 335, 52, 175, 44, + 44, 44, 335, 335, 46, 44, 44, 44, 335, 335, + 46, 335, 52, 335, 44, 44, 44, 335, 52, 46, + 44, 44, 44, 335, 52, 190, 335, 335, 335, 335, + 177, 179, 44, 44, 44, 52, 335, 46, 335, 178, + 335, 52, 335, 335, 335, 335, 187, 188, 181, 335, + + 52, 335, 335, 335, 180, 189, 52, 335, 335, 182, + 44, 44, 44, 335, 335, 46, 335, 335, 52, 44, + 44, 44, 335, 335, 46, 44, 44, 44, 335, 335, + 46, 335, 335, 335, 335, 194, 44, 44, 44, 335, + 335, 46, 44, 44, 44, 335, 52, 46, 335, 335, + 335, 335, 335, 335, 335, 52, 335, 191, 192, 192, + 192, 52, 335, 335, 335, 192, 192, 192, 192, 192, + 192, 335, 52, 335, 193, 44, 44, 44, 52, 335, + 46, 195, 335, 335, 192, 192, 192, 192, 192, 192, + 44, 44, 44, 335, 335, 46, 335, 335, 196, 44, + + 44, 44, 335, 335, 46, 44, 44, 44, 335, 335, + 46, 52, 44, 44, 44, 335, 335, 46, 44, 44, + 44, 335, 335, 46, 335, 335, 52, 335, 335, 198, + 335, 197, 44, 44, 44, 52, 335, 203, 44, 44, + 44, 52, 335, 46, 44, 44, 44, 200, 52, 46, + 335, 199, 335, 335, 52, 44, 44, 44, 335, 335, + 207, 202, 335, 335, 201, 44, 44, 44, 52, 335, + 46, 44, 44, 44, 52, 335, 46, 335, 335, 335, + 52, 335, 204, 44, 44, 44, 335, 335, 46, 335, + 335, 52, 205, 44, 44, 44, 335, 335, 46, 335, + + 335, 52, 206, 211, 44, 44, 44, 52, 335, 214, + 44, 44, 44, 335, 209, 215, 44, 44, 44, 52, + 208, 46, 335, 44, 44, 44, 335, 335, 46, 52, + 335, 335, 44, 44, 44, 335, 335, 46, 210, 335, + 52, 335, 335, 335, 335, 335, 52, 335, 335, 335, + 335, 335, 52, 335, 335, 44, 44, 44, 216, 52, + 46, 335, 44, 44, 44, 335, 335, 46, 52, 335, + 335, 335, 335, 335, 335, 217, 45, 45, 45, 218, + 335, 335, 335, 45, 45, 45, 45, 45, 45, 335, + 335, 52, 335, 335, 44, 44, 44, 219, 52, 46, + + 335, 335, 45, 45, 45, 45, 45, 45, 335, 44, + 44, 44, 220, 335, 46, 335, 335, 44, 44, 44, + 335, 335, 46, 44, 44, 44, 335, 335, 46, 335, + 52, 44, 44, 44, 335, 335, 46, 335, 44, 44, + 44, 335, 335, 46, 335, 52, 335, 335, 335, 335, + 335, 221, 222, 52, 335, 44, 44, 44, 335, 52, + 46, 335, 224, 44, 44, 44, 335, 52, 46, 335, + 335, 335, 223, 225, 52, 335, 335, 226, 44, 44, + 44, 335, 335, 46, 44, 44, 44, 335, 335, 46, + 335, 52, 44, 44, 44, 335, 335, 46, 335, 52, + + 44, 44, 44, 335, 335, 46, 44, 44, 44, 335, + 227, 46, 335, 335, 52, 335, 228, 335, 335, 335, + 52, 335, 44, 44, 44, 335, 335, 46, 52, 44, + 44, 44, 335, 229, 46, 335, 52, 335, 44, 44, + 44, 230, 52, 46, 44, 44, 44, 335, 231, 46, + 44, 44, 44, 233, 335, 46, 335, 232, 52, 44, + 44, 44, 335, 335, 46, 52, 335, 335, 44, 44, + 44, 234, 335, 46, 52, 335, 335, 335, 241, 335, + 52, 236, 335, 237, 335, 335, 52, 44, 44, 44, + 335, 335, 46, 335, 335, 52, 335, 335, 335, 335, + + 335, 238, 240, 239, 52, 44, 44, 44, 335, 335, + 46, 335, 44, 44, 44, 335, 335, 46, 335, 44, + 44, 44, 335, 52, 46, 44, 44, 44, 335, 335, + 46, 44, 44, 44, 335, 335, 46, 335, 335, 335, + 335, 52, 242, 335, 44, 44, 44, 243, 52, 46, + 335, 335, 44, 44, 44, 52, 335, 46, 335, 335, + 335, 52, 335, 244, 44, 44, 44, 52, 335, 250, + 44, 44, 44, 335, 245, 46, 246, 335, 335, 335, + 52, 44, 44, 44, 335, 335, 253, 247, 52, 44, + 44, 44, 335, 335, 46, 335, 44, 44, 44, 248, + + 52, 46, 251, 335, 335, 249, 52, 44, 44, 44, + 335, 335, 46, 252, 44, 44, 44, 52, 335, 257, + 335, 44, 44, 44, 335, 52, 46, 335, 44, 44, + 44, 335, 52, 46, 335, 44, 44, 44, 335, 255, + 46, 335, 335, 52, 335, 335, 254, 44, 44, 44, + 52, 335, 46, 44, 44, 44, 335, 52, 46, 335, + 44, 44, 44, 256, 52, 46, 335, 258, 335, 335, + 263, 52, 44, 44, 44, 335, 335, 46, 335, 259, + 44, 44, 44, 52, 335, 46, 335, 261, 335, 52, + 44, 44, 44, 335, 260, 46, 52, 335, 44, 44, + + 44, 335, 335, 267, 44, 44, 44, 335, 52, 46, + 335, 335, 262, 335, 335, 264, 52, 44, 44, 44, + 335, 335, 46, 265, 335, 335, 52, 44, 44, 44, + 335, 335, 46, 266, 52, 335, 44, 44, 44, 335, + 52, 46, 44, 44, 44, 335, 271, 46, 335, 44, + 44, 44, 335, 52, 46, 268, 44, 44, 44, 335, + 335, 274, 335, 52, 44, 44, 44, 335, 335, 46, + 335, 335, 52, 335, 269, 335, 335, 335, 52, 335, + 270, 44, 44, 44, 335, 52, 46, 335, 44, 44, + 44, 335, 52, 46, 44, 44, 44, 335, 335, 46, + + 52, 335, 335, 272, 44, 44, 44, 335, 335, 46, + 273, 335, 335, 335, 335, 275, 335, 52, 335, 335, + 276, 44, 44, 44, 52, 335, 46, 335, 335, 335, + 52, 277, 44, 44, 44, 335, 335, 281, 335, 335, + 52, 278, 335, 44, 44, 44, 335, 279, 46, 44, + 44, 44, 335, 335, 283, 335, 335, 52, 335, 44, + 44, 44, 335, 280, 46, 44, 44, 44, 52, 335, + 46, 44, 44, 44, 335, 335, 46, 335, 335, 52, + 335, 44, 44, 44, 335, 52, 46, 335, 44, 44, + 44, 335, 335, 288, 335, 52, 335, 335, 284, 282, + + 335, 52, 335, 44, 44, 44, 335, 52, 46, 44, + 44, 44, 335, 335, 290, 335, 335, 52, 285, 335, + 335, 335, 335, 287, 52, 286, 44, 44, 44, 335, + 335, 46, 44, 44, 44, 335, 335, 46, 335, 52, + 335, 44, 44, 44, 335, 52, 46, 44, 44, 44, + 335, 335, 46, 44, 44, 44, 335, 335, 46, 289, + 335, 335, 52, 335, 44, 44, 44, 335, 52, 46, + 44, 44, 44, 291, 335, 46, 335, 52, 335, 44, + 44, 44, 292, 52, 46, 44, 44, 44, 335, 52, + 46, 335, 44, 44, 44, 295, 335, 46, 293, 335, + + 52, 335, 294, 44, 44, 44, 52, 335, 301, 44, + 44, 44, 335, 335, 46, 52, 335, 44, 44, 44, + 296, 52, 303, 335, 335, 335, 298, 297, 52, 335, + 44, 44, 44, 335, 300, 46, 299, 335, 335, 52, + 335, 44, 44, 44, 335, 52, 46, 44, 44, 44, + 335, 305, 46, 52, 44, 44, 44, 335, 335, 308, + 335, 302, 44, 44, 44, 335, 52, 309, 44, 44, + 44, 335, 335, 46, 335, 335, 335, 52, 335, 44, + 44, 44, 335, 52, 46, 335, 304, 44, 44, 44, + 52, 335, 46, 335, 335, 335, 335, 306, 52, 307, + + 44, 44, 44, 335, 52, 46, 44, 44, 44, 335, + 335, 314, 44, 44, 44, 52, 335, 46, 335, 335, + 335, 310, 335, 52, 335, 335, 311, 44, 44, 44, + 335, 335, 316, 335, 335, 335, 52, 335, 335, 312, + 335, 335, 52, 335, 44, 44, 44, 335, 52, 46, + 335, 335, 44, 44, 44, 335, 313, 46, 335, 44, + 44, 44, 335, 52, 46, 44, 44, 44, 335, 315, + 46, 44, 44, 44, 335, 335, 321, 44, 44, 44, + 52, 335, 46, 335, 44, 44, 44, 335, 52, 323, + 335, 44, 44, 44, 335, 52, 324, 335, 335, 335, + + 317, 52, 318, 44, 44, 44, 335, 52, 46, 44, + 44, 44, 319, 52, 326, 335, 335, 44, 44, 44, + 52, 320, 46, 335, 322, 335, 335, 52, 44, 44, + 44, 335, 335, 46, 335, 44, 44, 44, 335, 52, + 46, 44, 44, 44, 335, 52, 330, 44, 44, 44, + 335, 335, 46, 52, 335, 325, 44, 44, 44, 335, + 335, 46, 335, 335, 52, 44, 44, 44, 327, 335, + 46, 52, 335, 335, 44, 44, 44, 52, 329, 334, + 335, 335, 335, 52, 328, 335, 335, 335, 335, 335, + 335, 335, 52, 335, 335, 335, 335, 335, 335, 335, + + 331, 52, 335, 335, 335, 335, 335, 335, 335, 335, + 52, 335, 335, 335, 332, 335, 335, 335, 335, 335, + 335, 335, 333, 36, 36, 36, 36, 36, 45, 45, + 45, 45, 45, 66, 335, 66, 66, 66, 85, 335, + 85, 335, 85, 87, 87, 87, 87, 87, 95, 95, + 95, 95, 95, 115, 335, 115, 115, 115, 130, 130, + 130, 11, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335 } ; -static const flex_int16_t yy_chk[2028] = +static const flex_int16_t yy_chk[2327] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -930,220 +972,253 @@ static const flex_int16_t yy_chk[2028] = 1, 1, 1, 1, 3, 3, 3, 4, 4, 4, 3, 9, 7, 4, 5, 5, 8, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 10, 13, 26, - 13, 21, 315, 5, 5, 314, 21, 5, 37, 9, + 13, 21, 347, 5, 5, 346, 21, 5, 37, 9, 37, 27, 5, 28, 5, 32, 5, 17, 26, 17, 17, 17, 5, 5, 7, 10, 5, 25, 8, 25, 17, 5, 25, 25, 25, 27, 5, 28, 33, 32, - 31, 5, 5, 15, 15, 15, 313, 44, 15, 17, + 31, 5, 5, 15, 15, 15, 345, 44, 15, 17, 42, 19, 42, 19, 19, 19, 20, 20, 20, 31, - 312, 113, 33, 85, 19, 75, 15, 20, 77, 15, - 15, 22, 198, 22, 22, 22, 15, 15, 44, 15, - 113, 174, 15, 19, 22, 15, 20, 15, 75, 80, - 15, 15, 77, 15, 85, 15, 15, 15, 15, 15, - 15, 15, 76, 22, 45, 45, 45, 116, 78, 45, - - 47, 47, 47, 80, 79, 47, 48, 48, 48, 143, - 149, 48, 49, 49, 49, 76, 116, 49, 50, 50, - 50, 78, 125, 50, 51, 51, 51, 79, 143, 51, - 45, 117, 52, 73, 73, 73, 47, 93, 48, 52, - 50, 112, 48, 74, 74, 74, 47, 51, 49, 115, - 53, 53, 53, 83, 50, 53, 54, 54, 54, 50, - 51, 54, 48, 52, 112, 49, 51, 52, 55, 55, - 55, 52, 115, 55, 82, 56, 56, 56, 111, 52, - 56, 114, 52, 43, 52, 52, 53, 146, 57, 57, - 57, 41, 54, 57, 39, 38, 58, 58, 58, 54, - - 53, 58, 111, 54, 55, 114, 146, 24, 54, 14, - 11, 56, 59, 59, 59, 0, 0, 59, 60, 60, - 60, 55, 0, 60, 57, 61, 61, 61, 0, 56, - 61, 0, 58, 0, 0, 58, 0, 58, 62, 62, - 62, 57, 0, 62, 63, 63, 63, 0, 59, 63, - 0, 0, 0, 0, 60, 0, 65, 65, 65, 0, - 66, 61, 66, 66, 66, 0, 63, 65, 61, 0, - 59, 60, 0, 66, 62, 0, 0, 67, 0, 67, - 63, 62, 67, 67, 67, 63, 65, 69, 69, 69, - 87, 68, 66, 68, 68, 68, 0, 87, 69, 0, - - 63, 0, 0, 0, 68, 88, 88, 88, 0, 0, - 88, 90, 90, 90, 0, 0, 90, 69, 0, 0, - 0, 87, 0, 68, 0, 87, 89, 89, 89, 87, - 0, 89, 0, 91, 91, 91, 0, 87, 91, 0, - 87, 88, 87, 87, 0, 0, 88, 90, 92, 92, - 92, 0, 0, 92, 0, 89, 90, 0, 0, 94, - 94, 94, 89, 91, 94, 101, 101, 101, 0, 91, - 101, 96, 96, 96, 0, 101, 96, 0, 92, 89, - 0, 97, 97, 97, 92, 0, 97, 91, 0, 0, - 0, 98, 98, 98, 0, 94, 98, 0, 0, 0, - - 0, 101, 92, 95, 95, 95, 0, 96, 0, 0, - 95, 95, 95, 95, 95, 95, 96, 97, 99, 99, - 99, 97, 0, 99, 0, 0, 0, 98, 0, 95, - 95, 95, 95, 95, 95, 0, 98, 100, 100, 100, - 0, 0, 100, 102, 102, 102, 0, 0, 102, 0, - 103, 103, 103, 0, 99, 103, 0, 104, 104, 104, - 0, 0, 104, 105, 105, 105, 0, 0, 105, 0, - 106, 106, 106, 100, 99, 106, 0, 0, 0, 102, - 107, 107, 107, 0, 0, 107, 103, 0, 102, 0, - 0, 0, 100, 104, 0, 108, 108, 108, 0, 105, - - 108, 103, 109, 109, 109, 0, 106, 109, 120, 120, - 120, 0, 104, 120, 0, 0, 107, 121, 121, 121, - 105, 0, 121, 0, 0, 106, 0, 122, 122, 122, - 0, 108, 122, 0, 0, 0, 108, 0, 109, 107, - 0, 123, 123, 123, 120, 121, 123, 0, 0, 109, - 124, 124, 124, 121, 108, 124, 128, 128, 128, 0, - 0, 128, 120, 122, 0, 129, 129, 129, 0, 121, - 129, 0, 122, 0, 131, 131, 131, 123, 0, 131, - 0, 0, 0, 0, 131, 0, 124, 127, 127, 127, - 0, 0, 128, 0, 127, 127, 127, 127, 127, 127, - - 0, 129, 130, 130, 130, 0, 0, 130, 0, 128, - 131, 0, 0, 127, 127, 127, 127, 127, 127, 132, - 132, 132, 0, 129, 132, 133, 133, 133, 0, 0, - 133, 134, 134, 134, 0, 0, 134, 0, 130, 135, - 135, 135, 0, 0, 135, 130, 0, 136, 136, 136, - 0, 0, 136, 0, 0, 132, 0, 136, 137, 137, - 137, 133, 0, 137, 133, 0, 0, 134, 138, 138, - 138, 0, 0, 138, 0, 135, 134, 0, 0, 132, - 0, 0, 135, 136, 139, 139, 139, 0, 0, 139, - 140, 140, 140, 0, 137, 140, 141, 141, 141, 0, - - 0, 141, 0, 0, 138, 142, 142, 142, 0, 0, - 142, 0, 137, 152, 152, 152, 0, 0, 152, 0, - 139, 0, 0, 0, 0, 138, 140, 139, 151, 151, - 151, 0, 141, 151, 0, 153, 153, 153, 0, 141, - 153, 142, 151, 151, 0, 140, 0, 0, 0, 152, - 142, 151, 157, 157, 157, 0, 0, 157, 0, 0, - 158, 158, 158, 0, 151, 158, 0, 159, 159, 159, - 0, 153, 159, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 153, 156, 156, 156, 0, 0, 157, 0, - 156, 156, 156, 156, 156, 156, 158, 160, 160, 160, - - 0, 0, 160, 159, 0, 158, 0, 157, 0, 156, - 156, 156, 156, 156, 156, 161, 161, 161, 0, 0, - 161, 0, 0, 159, 162, 162, 162, 0, 0, 162, - 0, 0, 0, 160, 163, 163, 163, 0, 0, 163, - 164, 164, 164, 0, 0, 164, 0, 165, 165, 165, - 0, 161, 165, 160, 161, 0, 166, 166, 166, 0, - 162, 166, 167, 167, 167, 0, 162, 167, 0, 0, - 163, 0, 0, 168, 168, 168, 164, 163, 168, 169, - 169, 169, 0, 165, 169, 170, 170, 170, 0, 0, - 170, 165, 166, 0, 171, 171, 171, 0, 167, 171, - - 0, 165, 0, 0, 171, 176, 176, 176, 0, 168, - 176, 177, 177, 177, 166, 169, 177, 0, 178, 178, - 178, 170, 169, 178, 0, 0, 0, 0, 168, 0, - 171, 180, 180, 180, 0, 0, 180, 183, 183, 183, - 170, 176, 183, 182, 182, 182, 0, 177, 182, 0, - 0, 0, 0, 0, 178, 0, 0, 0, 0, 0, - 178, 184, 184, 184, 0, 0, 184, 180, 0, 186, - 186, 186, 0, 183, 186, 0, 0, 0, 0, 182, - 0, 0, 0, 180, 181, 181, 181, 183, 0, 0, - 182, 181, 181, 181, 181, 181, 181, 184, 185, 185, - - 185, 0, 0, 185, 0, 186, 0, 0, 0, 0, - 181, 181, 181, 181, 181, 181, 0, 0, 184, 0, - 187, 187, 187, 0, 186, 187, 0, 188, 188, 188, - 0, 0, 188, 0, 185, 190, 190, 190, 0, 0, - 190, 185, 191, 191, 191, 0, 0, 191, 192, 192, - 192, 0, 0, 192, 0, 0, 187, 0, 0, 194, - 194, 194, 187, 188, 194, 195, 195, 195, 0, 0, - 195, 190, 196, 196, 196, 0, 0, 196, 191, 0, - 0, 0, 188, 0, 192, 197, 197, 197, 190, 0, - 197, 202, 202, 202, 0, 194, 202, 191, 0, 0, - - 0, 195, 203, 203, 203, 192, 0, 203, 196, 204, - 204, 204, 0, 0, 204, 194, 0, 0, 0, 196, - 0, 197, 195, 0, 205, 205, 205, 202, 0, 205, - 0, 0, 0, 0, 197, 0, 0, 0, 203, 206, - 206, 206, 0, 202, 206, 204, 0, 203, 0, 206, - 207, 207, 207, 0, 0, 207, 208, 208, 208, 0, - 205, 208, 0, 209, 209, 209, 204, 205, 209, 0, - 0, 210, 210, 210, 0, 206, 210, 211, 211, 211, - 0, 0, 211, 212, 212, 212, 207, 0, 212, 215, - 215, 215, 208, 0, 215, 213, 213, 213, 208, 209, - - 213, 214, 214, 214, 0, 207, 214, 210, 0, 216, - 216, 216, 0, 211, 216, 217, 217, 217, 209, 212, - 217, 219, 219, 219, 0, 215, 219, 210, 0, 0, - 0, 213, 211, 213, 0, 0, 212, 214, 220, 220, - 220, 0, 0, 220, 214, 216, 0, 221, 221, 221, - 0, 217, 221, 0, 222, 222, 222, 219, 217, 222, - 223, 223, 223, 0, 0, 223, 216, 224, 224, 224, - 0, 0, 224, 0, 220, 0, 0, 219, 0, 225, - 225, 225, 0, 221, 225, 0, 226, 226, 226, 225, - 222, 226, 0, 221, 0, 0, 223, 227, 227, 227, - - 223, 0, 227, 224, 228, 228, 228, 0, 0, 228, - 0, 0, 0, 222, 0, 225, 229, 229, 229, 0, - 0, 229, 226, 231, 231, 231, 224, 0, 231, 226, - 0, 0, 0, 227, 232, 232, 232, 0, 0, 232, - 228, 234, 234, 234, 232, 0, 234, 0, 235, 235, - 235, 0, 229, 235, 0, 228, 236, 236, 236, 231, - 0, 236, 238, 238, 238, 0, 0, 238, 0, 0, - 232, 0, 0, 229, 0, 0, 231, 234, 239, 239, - 239, 0, 0, 239, 235, 0, 240, 240, 240, 0, - 0, 240, 236, 0, 241, 241, 241, 0, 238, 241, - - 0, 0, 234, 242, 242, 242, 0, 0, 242, 235, - 243, 243, 243, 238, 239, 243, 0, 0, 245, 245, - 245, 239, 240, 245, 246, 246, 246, 0, 0, 246, - 241, 0, 0, 240, 0, 0, 0, 241, 0, 242, - 0, 0, 247, 247, 247, 242, 243, 247, 248, 248, - 248, 0, 0, 248, 245, 0, 0, 245, 0, 0, - 246, 0, 249, 249, 249, 0, 243, 249, 250, 250, - 250, 0, 0, 250, 252, 252, 252, 246, 247, 252, - 253, 253, 253, 0, 248, 253, 254, 254, 254, 0, - 248, 254, 255, 255, 255, 0, 247, 255, 249, 0, - - 256, 256, 256, 0, 250, 256, 0, 0, 0, 0, - 252, 0, 257, 257, 257, 0, 253, 257, 258, 258, - 258, 0, 254, 258, 250, 0, 0, 0, 255, 0, - 253, 0, 0, 259, 259, 259, 256, 0, 259, 0, - 0, 0, 256, 254, 260, 260, 260, 255, 257, 260, - 261, 261, 261, 0, 258, 261, 0, 263, 263, 263, - 0, 0, 263, 0, 0, 0, 0, 0, 257, 259, - 0, 265, 265, 265, 259, 258, 265, 266, 266, 266, - 260, 0, 266, 268, 268, 268, 261, 0, 268, 267, - 267, 267, 261, 263, 267, 269, 269, 269, 0, 267, - - 269, 260, 0, 270, 270, 270, 0, 265, 270, 271, - 271, 271, 0, 266, 271, 0, 272, 272, 272, 268, - 0, 272, 273, 273, 273, 267, 0, 273, 0, 0, - 0, 269, 0, 266, 0, 268, 276, 276, 276, 270, - 0, 276, 277, 277, 277, 271, 0, 277, 278, 278, - 278, 0, 272, 278, 0, 281, 281, 281, 273, 0, - 281, 0, 271, 272, 282, 282, 282, 0, 0, 282, - 0, 0, 276, 0, 273, 283, 283, 283, 277, 0, - 283, 0, 0, 0, 278, 285, 285, 285, 0, 0, - 285, 281, 286, 286, 286, 0, 0, 286, 0, 277, - - 282, 287, 287, 287, 278, 281, 287, 288, 288, 288, - 0, 283, 288, 289, 289, 289, 0, 282, 289, 0, - 0, 285, 290, 290, 290, 0, 0, 290, 286, 0, - 0, 283, 285, 293, 293, 293, 0, 287, 293, 295, - 295, 295, 0, 288, 295, 296, 296, 296, 0, 289, - 296, 297, 297, 297, 0, 0, 297, 0, 290, 288, - 299, 299, 299, 0, 0, 299, 300, 300, 300, 293, - 0, 300, 0, 290, 0, 295, 0, 0, 301, 301, - 301, 296, 295, 301, 0, 0, 0, 297, 0, 293, - 0, 0, 0, 0, 0, 0, 299, 0, 0, 0, - - 0, 0, 300, 0, 297, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 301, 0, 0, 0, 299, 0, - 0, 0, 0, 300, 304, 304, 304, 304, 304, 305, - 305, 305, 305, 305, 306, 0, 306, 306, 306, 307, - 0, 307, 0, 307, 308, 308, 308, 308, 308, 309, - 309, 309, 309, 309, 310, 0, 310, 310, 310, 311, - 311, 311, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, - 303, 303, 303, 303, 303, 303, 303 + 344, 118, 33, 87, 19, 77, 15, 20, 212, 15, + 15, 22, 185, 22, 22, 22, 15, 15, 44, 15, + 118, 157, 15, 19, 22, 15, 20, 15, 77, 15, + 15, 15, 15, 15, 87, 15, 15, 15, 15, 15, + 15, 15, 78, 22, 45, 45, 45, 79, 82, 45, + + 47, 47, 47, 130, 80, 47, 48, 48, 48, 121, + 122, 48, 49, 49, 49, 78, 95, 49, 50, 50, + 50, 79, 82, 50, 51, 51, 51, 80, 121, 51, + 45, 85, 52, 75, 75, 75, 47, 84, 48, 52, + 50, 81, 48, 76, 76, 76, 47, 51, 49, 43, + 53, 53, 53, 41, 50, 53, 54, 54, 54, 50, + 51, 54, 48, 52, 81, 49, 51, 52, 55, 55, + 55, 52, 116, 55, 117, 56, 56, 56, 119, 52, + 56, 39, 52, 38, 52, 52, 53, 24, 57, 57, + 57, 14, 54, 57, 120, 11, 116, 117, 54, 54, + + 53, 0, 119, 54, 55, 58, 58, 58, 54, 0, + 58, 56, 0, 59, 59, 59, 0, 120, 59, 151, + 69, 55, 69, 0, 57, 69, 69, 69, 56, 60, + 60, 60, 0, 0, 60, 61, 61, 61, 151, 154, + 61, 58, 57, 0, 0, 62, 62, 62, 58, 59, + 62, 63, 63, 63, 0, 0, 63, 0, 154, 64, + 64, 64, 0, 0, 64, 60, 59, 0, 60, 0, + 60, 61, 0, 0, 65, 65, 65, 0, 0, 65, + 0, 62, 0, 0, 0, 89, 0, 63, 67, 67, + 67, 0, 89, 61, 63, 64, 65, 0, 62, 67, + + 0, 68, 64, 68, 68, 68, 71, 71, 71, 70, + 65, 70, 70, 70, 68, 65, 89, 71, 67, 0, + 89, 0, 70, 0, 89, 0, 90, 90, 90, 0, + 65, 90, 89, 68, 0, 89, 71, 89, 89, 0, + 0, 70, 91, 91, 91, 0, 0, 91, 92, 92, + 92, 0, 0, 92, 0, 93, 93, 93, 0, 0, + 93, 0, 90, 0, 94, 94, 94, 90, 0, 94, + 0, 91, 96, 96, 96, 0, 0, 96, 91, 0, + 0, 99, 99, 99, 92, 93, 99, 98, 98, 98, + 0, 93, 98, 92, 94, 91, 0, 0, 0, 0, + + 94, 100, 100, 100, 0, 0, 100, 0, 96, 93, + 0, 0, 0, 0, 0, 0, 0, 99, 94, 97, + 97, 97, 0, 98, 0, 0, 97, 97, 97, 97, + 97, 97, 98, 99, 101, 101, 101, 100, 0, 101, + 0, 100, 0, 0, 0, 97, 97, 97, 97, 97, + 97, 102, 102, 102, 0, 0, 102, 103, 103, 103, + 0, 0, 103, 104, 104, 104, 0, 0, 104, 0, + 101, 0, 105, 105, 105, 0, 0, 105, 0, 101, + 0, 0, 105, 0, 106, 106, 106, 102, 0, 106, + 107, 107, 107, 103, 0, 107, 108, 108, 108, 104, + + 0, 108, 0, 0, 109, 109, 109, 102, 105, 109, + 0, 0, 103, 110, 110, 110, 0, 0, 110, 104, + 106, 0, 111, 111, 111, 0, 107, 111, 112, 112, + 112, 0, 108, 112, 0, 107, 0, 113, 113, 113, + 109, 0, 113, 0, 0, 106, 0, 108, 0, 110, + 114, 114, 114, 0, 0, 114, 0, 0, 111, 109, + 0, 0, 0, 0, 112, 0, 125, 125, 125, 0, + 110, 125, 0, 113, 0, 0, 0, 111, 113, 126, + 126, 126, 0, 0, 126, 0, 114, 112, 127, 127, + 127, 0, 0, 127, 0, 0, 113, 114, 128, 128, + + 128, 0, 125, 128, 129, 129, 129, 126, 0, 129, + 0, 133, 133, 133, 0, 126, 133, 0, 0, 0, + 125, 134, 134, 134, 127, 0, 134, 135, 135, 135, + 0, 126, 135, 127, 128, 0, 0, 0, 0, 0, + 129, 132, 132, 132, 0, 0, 0, 133, 132, 132, + 132, 132, 132, 132, 136, 136, 136, 134, 0, 136, + 138, 138, 138, 135, 133, 138, 0, 132, 132, 132, + 132, 132, 132, 137, 137, 137, 0, 134, 137, 139, + 139, 139, 0, 137, 139, 135, 140, 140, 140, 0, + 136, 140, 0, 141, 141, 141, 138, 136, 141, 142, + + 142, 142, 0, 141, 142, 143, 143, 143, 0, 137, + 143, 144, 144, 144, 0, 139, 144, 0, 0, 0, + 138, 144, 140, 0, 0, 140, 145, 145, 145, 141, + 0, 145, 146, 146, 146, 142, 139, 146, 147, 147, + 147, 143, 0, 147, 142, 0, 0, 144, 143, 148, + 148, 148, 0, 0, 148, 149, 149, 149, 0, 0, + 149, 0, 145, 0, 150, 150, 150, 0, 146, 150, + 160, 160, 160, 0, 147, 160, 0, 0, 0, 0, + 145, 147, 159, 159, 159, 148, 0, 159, 0, 146, + 0, 149, 0, 0, 0, 0, 159, 159, 149, 0, + + 150, 0, 0, 0, 148, 159, 160, 0, 0, 150, + 161, 161, 161, 0, 0, 161, 0, 0, 159, 165, + 165, 165, 0, 0, 165, 166, 166, 166, 0, 0, + 166, 0, 0, 0, 0, 166, 167, 167, 167, 0, + 0, 167, 168, 168, 168, 0, 161, 168, 0, 0, + 0, 0, 0, 0, 0, 165, 0, 161, 164, 164, + 164, 166, 0, 0, 0, 164, 164, 164, 164, 164, + 164, 0, 167, 0, 165, 169, 169, 169, 168, 0, + 169, 167, 0, 0, 164, 164, 164, 164, 164, 164, + 170, 170, 170, 0, 0, 170, 0, 0, 168, 171, + + 171, 171, 0, 0, 171, 172, 172, 172, 0, 0, + 172, 169, 173, 173, 173, 0, 0, 173, 174, 174, + 174, 0, 0, 174, 0, 0, 170, 0, 0, 170, + 0, 169, 175, 175, 175, 171, 0, 175, 176, 176, + 176, 172, 0, 176, 177, 177, 177, 172, 173, 177, + 0, 171, 0, 0, 174, 178, 178, 178, 0, 0, + 178, 174, 0, 0, 173, 179, 179, 179, 175, 0, + 179, 180, 180, 180, 176, 0, 180, 0, 0, 0, + 177, 0, 176, 181, 181, 181, 0, 0, 181, 0, + 0, 178, 176, 182, 182, 182, 0, 0, 182, 0, + + 0, 179, 177, 182, 187, 187, 187, 180, 0, 187, + 188, 188, 188, 0, 180, 188, 189, 189, 189, 181, + 179, 189, 0, 191, 191, 191, 0, 0, 191, 182, + 0, 0, 193, 193, 193, 0, 0, 193, 181, 0, + 187, 0, 0, 0, 0, 0, 188, 0, 0, 0, + 0, 0, 189, 0, 0, 194, 194, 194, 189, 191, + 194, 0, 195, 195, 195, 0, 0, 195, 193, 0, + 0, 0, 0, 0, 0, 191, 192, 192, 192, 193, + 0, 0, 0, 192, 192, 192, 192, 192, 192, 0, + 0, 194, 0, 0, 196, 196, 196, 194, 195, 196, + + 0, 0, 192, 192, 192, 192, 192, 192, 0, 197, + 197, 197, 195, 0, 197, 0, 0, 198, 198, 198, + 0, 0, 198, 199, 199, 199, 0, 0, 199, 0, + 196, 200, 200, 200, 0, 0, 200, 0, 201, 201, + 201, 0, 0, 201, 0, 197, 0, 0, 0, 0, + 0, 196, 197, 198, 0, 202, 202, 202, 0, 199, + 202, 0, 199, 204, 204, 204, 0, 200, 204, 0, + 0, 0, 198, 200, 201, 0, 0, 201, 205, 205, + 205, 0, 0, 205, 206, 206, 206, 0, 0, 206, + 0, 202, 208, 208, 208, 0, 0, 208, 0, 204, + + 209, 209, 209, 0, 0, 209, 210, 210, 210, 0, + 202, 210, 0, 0, 205, 0, 204, 0, 0, 0, + 206, 0, 211, 211, 211, 0, 0, 211, 208, 216, + 216, 216, 0, 205, 216, 0, 209, 0, 217, 217, + 217, 206, 210, 217, 218, 218, 218, 0, 208, 218, + 219, 219, 219, 210, 0, 219, 0, 209, 211, 220, + 220, 220, 0, 0, 220, 216, 0, 0, 221, 221, + 221, 211, 0, 221, 217, 0, 0, 0, 221, 0, + 218, 216, 0, 217, 0, 0, 219, 222, 222, 222, + 0, 0, 222, 0, 0, 220, 0, 0, 0, 0, + + 0, 218, 220, 219, 221, 223, 223, 223, 0, 0, + 223, 0, 224, 224, 224, 0, 0, 224, 0, 225, + 225, 225, 0, 222, 225, 226, 226, 226, 0, 0, + 226, 227, 227, 227, 0, 0, 227, 0, 0, 0, + 0, 223, 222, 0, 228, 228, 228, 223, 224, 228, + 0, 0, 229, 229, 229, 225, 0, 229, 0, 0, + 0, 226, 0, 224, 230, 230, 230, 227, 0, 230, + 231, 231, 231, 0, 225, 231, 226, 0, 0, 0, + 228, 232, 232, 232, 0, 0, 232, 227, 229, 233, + 233, 233, 0, 0, 233, 0, 234, 234, 234, 228, + + 230, 234, 230, 0, 0, 229, 231, 236, 236, 236, + 0, 0, 236, 231, 237, 237, 237, 232, 0, 237, + 0, 238, 238, 238, 0, 233, 238, 0, 239, 239, + 239, 0, 234, 239, 0, 240, 240, 240, 0, 234, + 240, 0, 0, 236, 0, 0, 233, 241, 241, 241, + 237, 0, 241, 242, 242, 242, 0, 238, 242, 0, + 243, 243, 243, 236, 239, 243, 0, 238, 0, 0, + 243, 240, 244, 244, 244, 0, 0, 244, 0, 239, + 245, 245, 245, 241, 0, 245, 0, 241, 0, 242, + 246, 246, 246, 0, 240, 246, 243, 0, 247, 247, + + 247, 0, 0, 247, 248, 248, 248, 0, 244, 248, + 0, 0, 242, 0, 0, 244, 245, 249, 249, 249, + 0, 0, 249, 245, 0, 0, 246, 251, 251, 251, + 0, 0, 251, 246, 247, 0, 252, 252, 252, 0, + 248, 252, 254, 254, 254, 0, 252, 254, 0, 255, + 255, 255, 0, 249, 255, 248, 256, 256, 256, 0, + 0, 256, 0, 251, 258, 258, 258, 0, 0, 258, + 0, 0, 252, 0, 249, 0, 0, 0, 254, 0, + 251, 259, 259, 259, 0, 255, 259, 0, 260, 260, + 260, 0, 256, 260, 261, 261, 261, 0, 0, 261, + + 258, 0, 0, 254, 262, 262, 262, 0, 0, 262, + 255, 0, 0, 0, 0, 258, 0, 259, 0, 0, + 259, 263, 263, 263, 260, 0, 263, 0, 0, 0, + 261, 260, 264, 264, 264, 0, 0, 264, 0, 0, + 262, 261, 0, 265, 265, 265, 0, 262, 265, 266, + 266, 266, 0, 0, 266, 0, 0, 263, 0, 268, + 268, 268, 0, 263, 268, 269, 269, 269, 264, 0, + 269, 270, 270, 270, 0, 0, 270, 0, 0, 265, + 0, 271, 271, 271, 0, 266, 271, 0, 272, 272, + 272, 0, 0, 272, 0, 268, 0, 0, 268, 265, + + 0, 269, 0, 273, 273, 273, 0, 270, 273, 275, + 275, 275, 0, 0, 275, 0, 0, 271, 269, 0, + 0, 0, 0, 271, 272, 270, 276, 276, 276, 0, + 0, 276, 277, 277, 277, 0, 0, 277, 0, 273, + 0, 278, 278, 278, 0, 275, 278, 279, 279, 279, + 0, 0, 279, 280, 280, 280, 0, 0, 280, 273, + 0, 0, 276, 0, 282, 282, 282, 0, 277, 282, + 284, 284, 284, 276, 0, 284, 0, 278, 0, 286, + 286, 286, 277, 279, 286, 285, 285, 285, 0, 280, + 285, 0, 287, 287, 287, 280, 0, 287, 278, 0, + + 282, 0, 279, 289, 289, 289, 284, 0, 289, 291, + 291, 291, 0, 0, 291, 286, 0, 292, 292, 292, + 282, 285, 292, 0, 0, 0, 285, 284, 287, 0, + 293, 293, 293, 0, 287, 293, 286, 0, 0, 289, + 0, 294, 294, 294, 0, 291, 294, 295, 295, 295, + 0, 294, 295, 292, 296, 296, 296, 0, 0, 296, + 0, 291, 297, 297, 297, 0, 293, 297, 298, 298, + 298, 0, 0, 298, 0, 0, 0, 294, 0, 299, + 299, 299, 0, 295, 299, 0, 293, 300, 300, 300, + 296, 0, 300, 0, 0, 0, 0, 294, 297, 295, + + 302, 302, 302, 0, 298, 302, 304, 304, 304, 0, + 0, 304, 305, 305, 305, 299, 0, 305, 0, 0, + 0, 298, 0, 300, 0, 0, 299, 306, 306, 306, + 0, 0, 306, 0, 0, 0, 302, 0, 0, 300, + 0, 0, 304, 0, 307, 307, 307, 0, 305, 307, + 0, 0, 310, 310, 310, 0, 302, 310, 0, 311, + 311, 311, 0, 306, 311, 312, 312, 312, 0, 305, + 312, 313, 313, 313, 0, 0, 313, 315, 315, 315, + 307, 0, 315, 0, 317, 317, 317, 0, 310, 317, + 0, 318, 318, 318, 0, 311, 318, 0, 0, 0, + + 307, 312, 310, 319, 319, 319, 0, 313, 319, 320, + 320, 320, 311, 315, 320, 0, 0, 322, 322, 322, + 317, 312, 322, 0, 315, 0, 0, 318, 325, 325, + 325, 0, 0, 325, 0, 327, 327, 327, 0, 319, + 327, 328, 328, 328, 0, 320, 328, 329, 329, 329, + 0, 0, 329, 322, 0, 319, 331, 331, 331, 0, + 0, 331, 0, 0, 325, 332, 332, 332, 322, 0, + 332, 327, 0, 0, 333, 333, 333, 328, 327, 333, + 0, 0, 0, 329, 325, 0, 0, 0, 0, 0, + 0, 0, 331, 0, 0, 0, 0, 0, 0, 0, + + 329, 332, 0, 0, 0, 0, 0, 0, 0, 0, + 333, 0, 0, 0, 331, 0, 0, 0, 0, 0, + 0, 0, 332, 336, 336, 336, 336, 336, 337, 337, + 337, 337, 337, 338, 0, 338, 338, 338, 339, 0, + 339, 0, 339, 340, 340, 340, 340, 340, 341, 341, + 341, 341, 341, 342, 0, 342, 342, 342, 343, 343, + 343, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335 } ; static yy_state_type yy_last_accepting_state; @@ -1152,14 +1227,14 @@ static char *yy_last_accepting_cpos; extern int d2_parser__flex_debug; int d2_parser__flex_debug = 1; -static const flex_int16_t yy_rule_linenum[54] = +static const flex_int16_t yy_rule_linenum[58] = { 0, 117, 119, 121, 126, 127, 132, 133, 134, 146, 149, - 154, 160, 169, 178, 187, 196, 205, 214, 224, 234, - 244, 253, 262, 271, 280, 289, 299, 308, 317, 326, - 335, 345, 354, 363, 372, 382, 480, 485, 490, 495, - 496, 497, 498, 499, 500, 502, 520, 533, 538, 542, - 544, 546, 548 + 154, 160, 169, 179, 189, 198, 207, 216, 226, 236, + 246, 255, 264, 274, 283, 292, 302, 311, 320, 329, + 339, 348, 357, 366, 375, 386, 395, 404, 413, 423, + 521, 526, 531, 536, 537, 538, 539, 540, 541, 543, + 561, 574, 579, 583, 585, 587, 589 } ; /* The intent behind this definition is that it'll catch @@ -1204,7 +1279,7 @@ unsigned int comment_start_line = 0; // To avoid the call to exit... oops! #define YY_FATAL_ERROR(msg) isc::d2::D2ParserContext::fatal(msg) -#line 1207 "d2_lexer.cc" +#line 1282 "d2_lexer.cc" /* noyywrap disables automatic rewinding for the next file to parse. Since we always parse only a single string, there's no need to do any wraps. And using yywrap requires linking with -lfl, which provides the default yywrap @@ -1230,8 +1305,8 @@ unsigned int comment_start_line = 0; // by moving it ahead by yyleng bytes. yyleng specifies the length of the // currently matched token. #define YY_USER_ACTION driver.loc_.columns(yyleng); -#line 1233 "d2_lexer.cc" -#line 1234 "d2_lexer.cc" +#line 1308 "d2_lexer.cc" +#line 1309 "d2_lexer.cc" #define INITIAL 0 #define COMMENT 1 @@ -1539,7 +1614,7 @@ YY_DECL } -#line 1542 "d2_lexer.cc" +#line 1617 "d2_lexer.cc" while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */ { @@ -1568,13 +1643,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 >= 304 ) + if ( yy_current_state >= 336 ) yy_c = yy_meta[yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; ++yy_cp; } - while ( yy_current_state != 303 ); + while ( yy_current_state != 335 ); yy_cp = (yy_last_accepting_cpos); yy_current_state = (yy_last_accepting_state); @@ -1593,13 +1668,13 @@ do_action: /* This label is used only to access EOF actions. */ { if ( yy_act == 0 ) fprintf( stderr, "--scanner backing up\n" ); - else if ( yy_act < 54 ) + else if ( yy_act < 58 ) fprintf( stderr, "--accepting rule at line %ld (\"%s\")\n", (long)yy_rule_linenum[yy_act], d2_parser_text ); - else if ( yy_act == 54 ) + else if ( yy_act == 58 ) fprintf( stderr, "--accepting default rule (\"%s\")\n", d2_parser_text ); - else if ( yy_act == 55 ) + else if ( yy_act == 59 ) fprintf( stderr, "--(end of buffer or a NUL)\n" ); else fprintf( stderr, "--EOF (start condition %d)\n", YY_START ); @@ -1721,6 +1796,7 @@ YY_RULE_SETUP { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: + case isc::d2::D2ParserContext::DNS_SERVERS: return isc::d2::D2Parser::make_IP_ADDRESS(driver.loc_); default: return isc::d2::D2Parser::make_STRING("ip-address", driver.loc_); @@ -1729,10 +1805,11 @@ YY_RULE_SETUP YY_BREAK case 14: YY_RULE_SETUP -#line 178 "d2_lexer.ll" +#line 179 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: + case isc::d2::D2ParserContext::DNS_SERVERS: return isc::d2::D2Parser::make_PORT(driver.loc_); default: return isc::d2::D2Parser::make_STRING("port", driver.loc_); @@ -1741,7 +1818,7 @@ YY_RULE_SETUP YY_BREAK case 15: YY_RULE_SETUP -#line 187 "d2_lexer.ll" +#line 189 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1753,7 +1830,7 @@ YY_RULE_SETUP YY_BREAK case 16: YY_RULE_SETUP -#line 196 "d2_lexer.ll" +#line 198 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1765,7 +1842,7 @@ YY_RULE_SETUP YY_BREAK case 17: YY_RULE_SETUP -#line 205 "d2_lexer.ll" +#line 207 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1777,7 +1854,7 @@ YY_RULE_SETUP YY_BREAK case 18: YY_RULE_SETUP -#line 214 "d2_lexer.ll" +#line 216 "d2_lexer.ll" { /* dhcp-ddns value keywords are case insensitive */ if (driver.ctx_ == isc::d2::D2ParserContext::NCR_PROTOCOL) { @@ -1790,7 +1867,7 @@ YY_RULE_SETUP YY_BREAK case 19: YY_RULE_SETUP -#line 224 "d2_lexer.ll" +#line 226 "d2_lexer.ll" { /* dhcp-ddns value keywords are case insensitive */ if (driver.ctx_ == isc::d2::D2ParserContext::NCR_PROTOCOL) { @@ -1803,7 +1880,7 @@ YY_RULE_SETUP YY_BREAK case 20: YY_RULE_SETUP -#line 234 "d2_lexer.ll" +#line 236 "d2_lexer.ll" { /* dhcp-ddns value keywords are case insensitive */ if (driver.ctx_ == isc::d2::D2ParserContext::NCR_FORMAT) { @@ -1816,7 +1893,7 @@ YY_RULE_SETUP YY_BREAK case 21: YY_RULE_SETUP -#line 244 "d2_lexer.ll" +#line 246 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1828,7 +1905,7 @@ YY_RULE_SETUP YY_BREAK case 22: YY_RULE_SETUP -#line 253 "d2_lexer.ll" +#line 255 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1840,7 +1917,56 @@ YY_RULE_SETUP YY_BREAK case 23: YY_RULE_SETUP -#line 262 "d2_lexer.ll" +#line 264 "d2_lexer.ll" +{ + switch(driver.ctx_) { + case isc::d2::D2ParserContext::FORWARD_DDNS: + case isc::d2::D2ParserContext::REVERSE_DDNS: + return isc::d2::D2Parser::make_DDNS_DOMAINS(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("ddns-domains", driver.loc_); + } +} + YY_BREAK +case 24: +YY_RULE_SETUP +#line 274 "d2_lexer.ll" +{ + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DDNS_DOMAINS: + return isc::d2::D2Parser::make_KEY_NAME(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("key-name", driver.loc_); + } +} + YY_BREAK +case 25: +YY_RULE_SETUP +#line 283 "d2_lexer.ll" +{ + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DDNS_DOMAINS: + return isc::d2::D2Parser::make_DNS_SERVERS(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("dns-servers", driver.loc_); + } +} + YY_BREAK +case 26: +YY_RULE_SETUP +#line 292 "d2_lexer.ll" +{ + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DNS_SERVERS: + return isc::d2::D2Parser::make_HOSTNAME(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("hostname", driver.loc_); + } +} + YY_BREAK +case 27: +YY_RULE_SETUP +#line 302 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -1850,9 +1976,9 @@ YY_RULE_SETUP } } YY_BREAK -case 24: +case 28: YY_RULE_SETUP -#line 271 "d2_lexer.ll" +#line 311 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::TSIG_KEYS: @@ -1862,9 +1988,9 @@ YY_RULE_SETUP } } YY_BREAK -case 25: +case 29: YY_RULE_SETUP -#line 280 "d2_lexer.ll" +#line 320 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::TSIG_KEYS: @@ -1874,9 +2000,9 @@ YY_RULE_SETUP } } YY_BREAK -case 26: +case 30: YY_RULE_SETUP -#line 289 "d2_lexer.ll" +#line 329 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::TSIG_KEYS: @@ -1886,9 +2012,9 @@ YY_RULE_SETUP } } YY_BREAK -case 27: +case 31: YY_RULE_SETUP -#line 299 "d2_lexer.ll" +#line 339 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::CONFIG: @@ -1898,9 +2024,9 @@ YY_RULE_SETUP } } YY_BREAK -case 28: +case 32: YY_RULE_SETUP -#line 308 "d2_lexer.ll" +#line 348 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGING: @@ -1910,9 +2036,9 @@ YY_RULE_SETUP } } YY_BREAK -case 29: +case 33: YY_RULE_SETUP -#line 317 "d2_lexer.ll" +#line 357 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGERS: @@ -1922,9 +2048,9 @@ YY_RULE_SETUP } } YY_BREAK -case 30: +case 34: YY_RULE_SETUP -#line 326 "d2_lexer.ll" +#line 366 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::OUTPUT_OPTIONS: @@ -1934,22 +2060,23 @@ YY_RULE_SETUP } } YY_BREAK -case 31: +case 35: YY_RULE_SETUP -#line 335 "d2_lexer.ll" +#line 375 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGERS: case isc::d2::D2ParserContext::TSIG_KEYS: + case isc::d2::D2ParserContext::DDNS_DOMAINS: return isc::d2::D2Parser::make_NAME(driver.loc_); default: return isc::d2::D2Parser::make_STRING("name", driver.loc_); } } YY_BREAK -case 32: +case 36: YY_RULE_SETUP -#line 345 "d2_lexer.ll" +#line 386 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGERS: @@ -1959,9 +2086,9 @@ YY_RULE_SETUP } } YY_BREAK -case 33: +case 37: YY_RULE_SETUP -#line 354 "d2_lexer.ll" +#line 395 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGERS: @@ -1971,9 +2098,9 @@ YY_RULE_SETUP } } YY_BREAK -case 34: +case 38: YY_RULE_SETUP -#line 363 "d2_lexer.ll" +#line 404 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::CONFIG: @@ -1983,9 +2110,9 @@ YY_RULE_SETUP } } YY_BREAK -case 35: +case 39: YY_RULE_SETUP -#line 372 "d2_lexer.ll" +#line 413 "d2_lexer.ll" { switch(driver.ctx_) { case isc::d2::D2ParserContext::CONFIG: @@ -1995,9 +2122,9 @@ YY_RULE_SETUP } } YY_BREAK -case 36: +case 40: YY_RULE_SETUP -#line 382 "d2_lexer.ll" +#line 423 "d2_lexer.ll" { // A string has been matched. It contains the actual string and single quotes. // We need to get those quotes out of the way and just use its content, e.g. @@ -2096,65 +2223,65 @@ YY_RULE_SETUP return isc::d2::D2Parser::make_STRING(decoded, driver.loc_); } YY_BREAK -case 37: -/* rule 37 can match eol */ +case 41: +/* rule 41 can match eol */ YY_RULE_SETUP -#line 480 "d2_lexer.ll" +#line 521 "d2_lexer.ll" { // Bad string with a forbidden control character inside driver.error(driver.loc_, "Invalid control in " + std::string(yytext)); } YY_BREAK -case 38: -/* rule 38 can match eol */ +case 42: +/* rule 42 can match eol */ YY_RULE_SETUP -#line 485 "d2_lexer.ll" +#line 526 "d2_lexer.ll" { // Bad string with a bad escape inside driver.error(driver.loc_, "Bad escape in " + std::string(yytext)); } YY_BREAK -case 39: +case 43: YY_RULE_SETUP -#line 490 "d2_lexer.ll" +#line 531 "d2_lexer.ll" { // Bad string with an open escape at the end driver.error(driver.loc_, "Overflow escape in " + std::string(yytext)); } YY_BREAK -case 40: +case 44: YY_RULE_SETUP -#line 495 "d2_lexer.ll" +#line 536 "d2_lexer.ll" { return isc::d2::D2Parser::make_LSQUARE_BRACKET(driver.loc_); } YY_BREAK -case 41: +case 45: YY_RULE_SETUP -#line 496 "d2_lexer.ll" +#line 537 "d2_lexer.ll" { return isc::d2::D2Parser::make_RSQUARE_BRACKET(driver.loc_); } YY_BREAK -case 42: +case 46: YY_RULE_SETUP -#line 497 "d2_lexer.ll" +#line 538 "d2_lexer.ll" { return isc::d2::D2Parser::make_LCURLY_BRACKET(driver.loc_); } YY_BREAK -case 43: +case 47: YY_RULE_SETUP -#line 498 "d2_lexer.ll" +#line 539 "d2_lexer.ll" { return isc::d2::D2Parser::make_RCURLY_BRACKET(driver.loc_); } YY_BREAK -case 44: +case 48: YY_RULE_SETUP -#line 499 "d2_lexer.ll" +#line 540 "d2_lexer.ll" { return isc::d2::D2Parser::make_COMMA(driver.loc_); } YY_BREAK -case 45: +case 49: YY_RULE_SETUP -#line 500 "d2_lexer.ll" +#line 541 "d2_lexer.ll" { return isc::d2::D2Parser::make_COLON(driver.loc_); } YY_BREAK -case 46: +case 50: YY_RULE_SETUP -#line 502 "d2_lexer.ll" +#line 543 "d2_lexer.ll" { // An integer was found. std::string tmp(yytext); @@ -2173,9 +2300,9 @@ YY_RULE_SETUP return isc::d2::D2Parser::make_INTEGER(integer, driver.loc_); } YY_BREAK -case 47: +case 51: YY_RULE_SETUP -#line 520 "d2_lexer.ll" +#line 561 "d2_lexer.ll" { // A floating point was found. std::string tmp(yytext); @@ -2189,43 +2316,43 @@ YY_RULE_SETUP return isc::d2::D2Parser::make_FLOAT(fp, driver.loc_); } YY_BREAK -case 48: +case 52: YY_RULE_SETUP -#line 533 "d2_lexer.ll" +#line 574 "d2_lexer.ll" { string tmp(yytext); return isc::d2::D2Parser::make_BOOLEAN(tmp == "true", driver.loc_); } YY_BREAK -case 49: +case 53: YY_RULE_SETUP -#line 538 "d2_lexer.ll" +#line 579 "d2_lexer.ll" { return isc::d2::D2Parser::make_NULL_TYPE(driver.loc_); } YY_BREAK -case 50: +case 54: YY_RULE_SETUP -#line 542 "d2_lexer.ll" +#line 583 "d2_lexer.ll" driver.error (driver.loc_, "JSON true reserved keyword is lower case only"); YY_BREAK -case 51: +case 55: YY_RULE_SETUP -#line 544 "d2_lexer.ll" +#line 585 "d2_lexer.ll" driver.error (driver.loc_, "JSON false reserved keyword is lower case only"); YY_BREAK -case 52: +case 56: YY_RULE_SETUP -#line 546 "d2_lexer.ll" +#line 587 "d2_lexer.ll" driver.error (driver.loc_, "JSON null reserved keyword is lower case only"); YY_BREAK -case 53: +case 57: YY_RULE_SETUP -#line 548 "d2_lexer.ll" +#line 589 "d2_lexer.ll" driver.error (driver.loc_, "Invalid character: " + std::string(yytext)); YY_BREAK case YY_STATE_EOF(INITIAL): -#line 550 "d2_lexer.ll" +#line 591 "d2_lexer.ll" { if (driver.states_.empty()) { return isc::d2::D2Parser::make_END(driver.loc_); @@ -2249,12 +2376,12 @@ case YY_STATE_EOF(INITIAL): BEGIN(DIR_EXIT); } YY_BREAK -case 54: +case 58: YY_RULE_SETUP -#line 573 "d2_lexer.ll" +#line 614 "d2_lexer.ll" ECHO; YY_BREAK -#line 2257 "d2_lexer.cc" +#line 2384 "d2_lexer.cc" case YY_END_OF_BUFFER: { @@ -2569,7 +2696,7 @@ static int yy_get_next_buffer (void) 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 >= 304 ) + if ( yy_current_state >= 336 ) yy_c = yy_meta[yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; @@ -2602,11 +2729,11 @@ static int yy_get_next_buffer (void) 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 >= 304 ) + if ( yy_current_state >= 336 ) yy_c = yy_meta[yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; - yy_is_jam = (yy_current_state == 303); + yy_is_jam = (yy_current_state == 335); return yy_is_jam ? 0 : yy_current_state; } @@ -3355,7 +3482,7 @@ void d2_parser_free (void * ptr ) /* %ok-for-header */ -#line 573 "d2_lexer.ll" +#line 614 "d2_lexer.ll" using namespace isc::dhcp; diff --git a/src/bin/d2/d2_lexer.ll b/src/bin/d2/d2_lexer.ll index f932ed2252..f68b7b7359 100644 --- a/src/bin/d2/d2_lexer.ll +++ b/src/bin/d2/d2_lexer.ll @@ -168,6 +168,7 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence} \"ip-address\" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: + case isc::d2::D2ParserContext::DNS_SERVERS: return isc::d2::D2Parser::make_IP_ADDRESS(driver.loc_); default: return isc::d2::D2Parser::make_STRING("ip-address", driver.loc_); @@ -177,6 +178,7 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence} \"port\" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: + case isc::d2::D2ParserContext::DNS_SERVERS: return isc::d2::D2Parser::make_PORT(driver.loc_); default: return isc::d2::D2Parser::make_STRING("port", driver.loc_); @@ -258,6 +260,44 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence} } } +\"ddns-domains\" { + switch(driver.ctx_) { + case isc::d2::D2ParserContext::FORWARD_DDNS: + case isc::d2::D2ParserContext::REVERSE_DDNS: + return isc::d2::D2Parser::make_DDNS_DOMAINS(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("ddns-domains", driver.loc_); + } +} + +\"key-name\" { + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DDNS_DOMAINS: + return isc::d2::D2Parser::make_KEY_NAME(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("key-name", driver.loc_); + } +} + +\"dns-servers\" { + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DDNS_DOMAINS: + return isc::d2::D2Parser::make_DNS_SERVERS(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("dns-servers", driver.loc_); + } +} + +\"hostname\" { + switch(driver.ctx_) { + case isc::d2::D2ParserContext::DNS_SERVERS: + return isc::d2::D2Parser::make_HOSTNAME(driver.loc_); + default: + return isc::d2::D2Parser::make_STRING("hostname", driver.loc_); + } +} + + \"tsig-keys\" { switch(driver.ctx_) { case isc::d2::D2ParserContext::DHCPDDNS: @@ -335,6 +375,7 @@ ControlCharacterFill [^"\\]|\\{JSONEscapeSequence} switch(driver.ctx_) { case isc::d2::D2ParserContext::LOGGERS: case isc::d2::D2ParserContext::TSIG_KEYS: + case isc::d2::D2ParserContext::DDNS_DOMAINS: return isc::d2::D2Parser::make_NAME(driver.loc_); default: return isc::d2::D2Parser::make_STRING("name", driver.loc_); diff --git a/src/bin/d2/d2_parser.cc b/src/bin/d2/d2_parser.cc index 3fd3917121..ad15ae214f 100644 --- a/src/bin/d2/d2_parser.cc +++ b/src/bin/d2/d2_parser.cc @@ -253,24 +253,24 @@ namespace isc { namespace d2 { { switch (that.type_get ()) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.move< ElementPtr > (that.value); break; - case 40: // "boolean" + case 44: // "boolean" value.move< bool > (that.value); break; - case 39: // "floating point" + case 43: // "floating point" value.move< double > (that.value); break; - case 38: // "integer" + case 42: // "integer" value.move< int64_t > (that.value); break; - case 37: // "constant string" + case 41: // "constant string" value.move< std::string > (that.value); break; @@ -289,24 +289,24 @@ namespace isc { namespace d2 { state = that.state; switch (that.type_get ()) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.copy< ElementPtr > (that.value); break; - case 40: // "boolean" + case 44: // "boolean" value.copy< bool > (that.value); break; - case 39: // "floating point" + case 43: // "floating point" value.copy< double > (that.value); break; - case 38: // "integer" + case 42: // "integer" value.copy< int64_t > (that.value); break; - case 37: // "constant string" + case 41: // "constant string" value.copy< std::string > (that.value); break; @@ -346,44 +346,44 @@ namespace isc { namespace d2 { << yysym.location << ": "; switch (yytype) { - case 37: // "constant string" + case 41: // "constant string" -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< std::string > (); } #line 354 "d2_parser.cc" // lalr1.cc:636 break; - case 38: // "integer" + case 42: // "integer" -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< int64_t > (); } #line 361 "d2_parser.cc" // lalr1.cc:636 break; - case 39: // "floating point" + case 43: // "floating point" -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< double > (); } #line 368 "d2_parser.cc" // lalr1.cc:636 break; - case 40: // "boolean" + case 44: // "boolean" -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< bool > (); } #line 375 "d2_parser.cc" // lalr1.cc:636 break; - case 46: // value + case 50: // value -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< ElementPtr > (); } #line 382 "d2_parser.cc" // lalr1.cc:636 break; - case 73: // ncr_protocol_value + case 77: // ncr_protocol_value -#line 94 "d2_parser.yy" // lalr1.cc:636 +#line 98 "d2_parser.yy" // lalr1.cc:636 { yyoutput << yysym.value.template as< ElementPtr > (); } #line 389 "d2_parser.cc" // lalr1.cc:636 break; @@ -585,24 +585,24 @@ namespace isc { namespace d2 { when using variants. */ switch (yyr1_[yyn]) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value yylhs.value.build< ElementPtr > (); break; - case 40: // "boolean" + case 44: // "boolean" yylhs.value.build< bool > (); break; - case 39: // "floating point" + case 43: // "floating point" yylhs.value.build< double > (); break; - case 38: // "integer" + case 42: // "integer" yylhs.value.build< int64_t > (); break; - case 37: // "constant string" + case 41: // "constant string" yylhs.value.build< std::string > (); break; @@ -624,67 +624,67 @@ namespace isc { namespace d2 { switch (yyn) { case 2: -#line 103 "d2_parser.yy" // lalr1.cc:859 +#line 107 "d2_parser.yy" // lalr1.cc:859 { ctx.ctx_ = ctx.NO_KEYWORD; } #line 630 "d2_parser.cc" // lalr1.cc:859 break; case 4: -#line 104 "d2_parser.yy" // lalr1.cc:859 +#line 108 "d2_parser.yy" // lalr1.cc:859 { ctx.ctx_ = ctx.CONFIG; } #line 636 "d2_parser.cc" // lalr1.cc:859 break; case 6: -#line 105 "d2_parser.yy" // lalr1.cc:859 +#line 109 "d2_parser.yy" // lalr1.cc:859 { ctx.ctx_ = ctx.DHCPDDNS; } #line 642 "d2_parser.cc" // lalr1.cc:859 break; case 8: -#line 113 "d2_parser.yy" // lalr1.cc:859 +#line 117 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); } #line 648 "d2_parser.cc" // lalr1.cc:859 break; case 9: -#line 114 "d2_parser.yy" // lalr1.cc:859 +#line 118 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); } #line 654 "d2_parser.cc" // lalr1.cc:859 break; case 10: -#line 115 "d2_parser.yy" // lalr1.cc:859 +#line 119 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); } #line 660 "d2_parser.cc" // lalr1.cc:859 break; case 11: -#line 116 "d2_parser.yy" // lalr1.cc:859 +#line 120 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); } #line 666 "d2_parser.cc" // lalr1.cc:859 break; case 12: -#line 117 "d2_parser.yy" // lalr1.cc:859 +#line 121 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); } #line 672 "d2_parser.cc" // lalr1.cc:859 break; case 13: -#line 118 "d2_parser.yy" // lalr1.cc:859 +#line 122 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); } #line 678 "d2_parser.cc" // lalr1.cc:859 break; case 14: -#line 119 "d2_parser.yy" // lalr1.cc:859 +#line 123 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); } #line 684 "d2_parser.cc" // lalr1.cc:859 break; case 15: -#line 122 "d2_parser.yy" // lalr1.cc:859 +#line 126 "d2_parser.yy" // lalr1.cc:859 { // Push back the JSON value on the stack ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ()); @@ -693,7 +693,7 @@ namespace isc { namespace d2 { break; case 16: -#line 127 "d2_parser.yy" // lalr1.cc:859 +#line 131 "d2_parser.yy" // lalr1.cc:859 { // This code is executed when we're about to start parsing // the content of the map @@ -704,7 +704,7 @@ namespace isc { namespace d2 { break; case 17: -#line 132 "d2_parser.yy" // lalr1.cc:859 +#line 136 "d2_parser.yy" // lalr1.cc:859 { // map parsing completed. If we ever want to do any wrap up // (maybe some sanity checking), this would be the best place @@ -714,7 +714,7 @@ namespace isc { namespace d2 { break; case 20: -#line 143 "d2_parser.yy" // lalr1.cc:859 +#line 147 "d2_parser.yy" // lalr1.cc:859 { // map containing a single entry ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ()); @@ -723,7 +723,7 @@ namespace isc { namespace d2 { break; case 21: -#line 147 "d2_parser.yy" // lalr1.cc:859 +#line 151 "d2_parser.yy" // lalr1.cc:859 { // map consisting of a shorter map followed by // comma and string:value @@ -733,7 +733,7 @@ namespace isc { namespace d2 { break; case 22: -#line 154 "d2_parser.yy" // lalr1.cc:859 +#line 158 "d2_parser.yy" // lalr1.cc:859 { ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.push_back(l); @@ -742,7 +742,7 @@ namespace isc { namespace d2 { break; case 23: -#line 157 "d2_parser.yy" // lalr1.cc:859 +#line 161 "d2_parser.yy" // lalr1.cc:859 { // list parsing complete. Put any sanity checking here } @@ -750,7 +750,7 @@ namespace isc { namespace d2 { break; case 26: -#line 173 "d2_parser.yy" // lalr1.cc:859 +#line 169 "d2_parser.yy" // lalr1.cc:859 { // List consisting of a single element. ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ()); @@ -759,7 +759,7 @@ namespace isc { namespace d2 { break; case 27: -#line 177 "d2_parser.yy" // lalr1.cc:859 +#line 173 "d2_parser.yy" // lalr1.cc:859 { // List ending with , and a value. ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ()); @@ -768,7 +768,7 @@ namespace isc { namespace d2 { break; case 28: -#line 188 "d2_parser.yy" // lalr1.cc:859 +#line 184 "d2_parser.yy" // lalr1.cc:859 { const std::string& where = ctx.contextName(); const std::string& keyword = yystack_[1].value.as< std::string > (); @@ -779,7 +779,7 @@ namespace isc { namespace d2 { break; case 29: -#line 198 "d2_parser.yy" // lalr1.cc:859 +#line 194 "d2_parser.yy" // lalr1.cc:859 { // This code is executed when we're about to start parsing // the content of the map @@ -790,7 +790,7 @@ namespace isc { namespace d2 { break; case 30: -#line 203 "d2_parser.yy" // lalr1.cc:859 +#line 199 "d2_parser.yy" // lalr1.cc:859 { // map parsing completed. If we ever want to do any wrap up // (maybe some sanity checking), this would be the best place @@ -800,7 +800,7 @@ namespace isc { namespace d2 { break; case 38: -#line 224 "d2_parser.yy" // lalr1.cc:859 +#line 220 "d2_parser.yy" // lalr1.cc:859 { ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("DhcpDdns", m); @@ -811,7 +811,7 @@ namespace isc { namespace d2 { break; case 39: -#line 229 "d2_parser.yy" // lalr1.cc:859 +#line 225 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); ctx.leave(); @@ -820,7 +820,7 @@ namespace isc { namespace d2 { break; case 40: -#line 234 "d2_parser.yy" // lalr1.cc:859 +#line 230 "d2_parser.yy" // lalr1.cc:859 { // Parse the dhcpddns map ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); @@ -830,7 +830,7 @@ namespace isc { namespace d2 { break; case 41: -#line 238 "d2_parser.yy" // lalr1.cc:859 +#line 234 "d2_parser.yy" // lalr1.cc:859 { // parsing completed } @@ -838,7 +838,7 @@ namespace isc { namespace d2 { break; case 53: -#line 257 "d2_parser.yy" // lalr1.cc:859 +#line 253 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } @@ -846,7 +846,7 @@ namespace isc { namespace d2 { break; case 54: -#line 259 "d2_parser.yy" // lalr1.cc:859 +#line 255 "d2_parser.yy" // lalr1.cc:859 { ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("ip-address", s); @@ -856,7 +856,7 @@ namespace isc { namespace d2 { break; case 55: -#line 265 "d2_parser.yy" // lalr1.cc:859 +#line 261 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< int64_t > () <= 0) { error(yystack_[0].location, "port must be greater than zero"); @@ -868,7 +868,7 @@ namespace isc { namespace d2 { break; case 56: -#line 273 "d2_parser.yy" // lalr1.cc:859 +#line 269 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< int64_t > () <= 0) { error(yystack_[0].location, "dns-server-timeout must be greater than zero"); @@ -881,7 +881,7 @@ namespace isc { namespace d2 { break; case 57: -#line 282 "d2_parser.yy" // lalr1.cc:859 +#line 278 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NCR_PROTOCOL); } @@ -889,7 +889,7 @@ namespace isc { namespace d2 { break; case 58: -#line 284 "d2_parser.yy" // lalr1.cc:859 +#line 280 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.back()->set("ncr-protocol", yystack_[0].value.as< ElementPtr > ()); ctx.leave(); @@ -898,19 +898,19 @@ namespace isc { namespace d2 { break; case 59: -#line 290 "d2_parser.yy" // lalr1.cc:859 +#line 286 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("UDP", ctx.loc2pos(yystack_[0].location))); } #line 904 "d2_parser.cc" // lalr1.cc:859 break; case 60: -#line 291 "d2_parser.yy" // lalr1.cc:859 +#line 287 "d2_parser.yy" // lalr1.cc:859 { yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("TCP", ctx.loc2pos(yystack_[0].location))); } #line 910 "d2_parser.cc" // lalr1.cc:859 break; case 61: -#line 294 "d2_parser.yy" // lalr1.cc:859 +#line 290 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NCR_FORMAT); } @@ -918,7 +918,7 @@ namespace isc { namespace d2 { break; case 62: -#line 296 "d2_parser.yy" // lalr1.cc:859 +#line 292 "d2_parser.yy" // lalr1.cc:859 { ElementPtr json(new StringElement("JSON", ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("ncr-format", json); @@ -928,87 +928,265 @@ namespace isc { namespace d2 { break; case 63: -#line 302 "d2_parser.yy" // lalr1.cc:859 +#line 298 "d2_parser.yy" // lalr1.cc:859 { - ctx.enter(ctx.NO_KEYWORD); + ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("forward-ddns", m); + ctx.stack_.push_back(m); + ctx.enter(ctx.FORWARD_DDNS); } -#line 936 "d2_parser.cc" // lalr1.cc:859 +#line 939 "d2_parser.cc" // lalr1.cc:859 break; case 64: -#line 304 "d2_parser.yy" // lalr1.cc:859 +#line 303 "d2_parser.yy" // lalr1.cc:859 { - ctx.stack_.back()->set("forward-ddns", yystack_[0].value.as< ElementPtr > ()); + ctx.stack_.pop_back(); ctx.leave(); } -#line 945 "d2_parser.cc" // lalr1.cc:859 +#line 948 "d2_parser.cc" // lalr1.cc:859 break; case 65: -#line 309 "d2_parser.yy" // lalr1.cc:859 +#line 308 "d2_parser.yy" // lalr1.cc:859 { - ctx.enter(ctx.NO_KEYWORD); + ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("reverse-ddns", m); + ctx.stack_.push_back(m); + ctx.enter(ctx.REVERSE_DDNS); } -#line 953 "d2_parser.cc" // lalr1.cc:859 +#line 959 "d2_parser.cc" // lalr1.cc:859 break; case 66: -#line 311 "d2_parser.yy" // lalr1.cc:859 +#line 313 "d2_parser.yy" // lalr1.cc:859 { - ctx.stack_.back()->set("reverse-ddns", yystack_[0].value.as< ElementPtr > ()); + ctx.stack_.pop_back(); ctx.leave(); } -#line 962 "d2_parser.cc" // lalr1.cc:859 +#line 968 "d2_parser.cc" // lalr1.cc:859 break; - case 67: -#line 318 "d2_parser.yy" // lalr1.cc:859 + case 73: +#line 333 "d2_parser.yy" // lalr1.cc:859 + { + ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("ddns-domains", l); + ctx.stack_.push_back(l); + ctx.enter(ctx.DDNS_DOMAINS); +} +#line 979 "d2_parser.cc" // lalr1.cc:859 + break; + + case 74: +#line 338 "d2_parser.yy" // lalr1.cc:859 + { + ctx.stack_.pop_back(); + ctx.leave(); +} +#line 988 "d2_parser.cc" // lalr1.cc:859 + break; + + case 79: +#line 351 "d2_parser.yy" // lalr1.cc:859 + { + ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->add(m); + ctx.stack_.push_back(m); +} +#line 998 "d2_parser.cc" // lalr1.cc:859 + break; + + case 80: +#line 355 "d2_parser.yy" // lalr1.cc:859 + { + ctx.stack_.pop_back(); +} +#line 1006 "d2_parser.cc" // lalr1.cc:859 + break; + + case 87: +#line 370 "d2_parser.yy" // lalr1.cc:859 + { + ctx.enter(ctx.NO_KEYWORD); +} +#line 1014 "d2_parser.cc" // lalr1.cc:859 + break; + + case 88: +#line 372 "d2_parser.yy" // lalr1.cc:859 + { + if (yystack_[0].value.as< std::string > () == "") { + error(yystack_[1].location, "name cannot be blank"); + } + ElementPtr elem(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("name", name); + ctx.leave(); +} +#line 1028 "d2_parser.cc" // lalr1.cc:859 + break; + + case 89: +#line 382 "d2_parser.yy" // lalr1.cc:859 + { + ctx.enter(ctx.NO_KEYWORD); +} +#line 1036 "d2_parser.cc" // lalr1.cc:859 + break; + + case 90: +#line 384 "d2_parser.yy" // lalr1.cc:859 + { + if (yystack_[0].value.as< std::string > () == "") { + error(yystack_[1].location, "key-name cannot be blank"); + } + ElementPtr elem(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("key-name", name); + ctx.leave(); +} +#line 1050 "d2_parser.cc" // lalr1.cc:859 + break; + + case 91: +#line 397 "d2_parser.yy" // lalr1.cc:859 + { + ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("dns-servers", l); + ctx.stack_.push_back(l); + ctx.enter(ctx.DNS_SERVERS); +} +#line 1061 "d2_parser.cc" // lalr1.cc:859 + break; + + case 92: +#line 402 "d2_parser.yy" // lalr1.cc:859 + { + ctx.stack_.pop_back(); + ctx.leave(); +} +#line 1070 "d2_parser.cc" // lalr1.cc:859 + break; + + case 97: +#line 415 "d2_parser.yy" // lalr1.cc:859 + { + ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->add(m); + ctx.stack_.push_back(m); +} +#line 1080 "d2_parser.cc" // lalr1.cc:859 + break; + + case 98: +#line 419 "d2_parser.yy" // lalr1.cc:859 + { + ctx.stack_.pop_back(); +} +#line 1088 "d2_parser.cc" // lalr1.cc:859 + break; + + case 105: +#line 433 "d2_parser.yy" // lalr1.cc:859 + { + ctx.enter(ctx.NO_KEYWORD); +} +#line 1096 "d2_parser.cc" // lalr1.cc:859 + break; + + case 106: +#line 435 "d2_parser.yy" // lalr1.cc:859 + { + if (yystack_[0].value.as< std::string > () == "") { + error(yystack_[1].location, "hostname cannot be blank"); + } + ElementPtr elem(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("hostname", name); + ctx.leave(); +} +#line 1110 "d2_parser.cc" // lalr1.cc:859 + break; + + case 107: +#line 445 "d2_parser.yy" // lalr1.cc:859 + { + ctx.enter(ctx.NO_KEYWORD); +} +#line 1118 "d2_parser.cc" // lalr1.cc:859 + break; + + case 108: +#line 447 "d2_parser.yy" // lalr1.cc:859 + { + ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("ip-address", s); + ctx.leave(); +} +#line 1128 "d2_parser.cc" // lalr1.cc:859 + break; + + case 109: +#line 453 "d2_parser.yy" // lalr1.cc:859 + { + if (yystack_[0].value.as< int64_t > () <= 0) { + error(yystack_[0].location, "port must be greater than zero"); + } + ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); + ctx.stack_.back()->set("port", i); +} +#line 1140 "d2_parser.cc" // lalr1.cc:859 + break; + + case 110: +#line 467 "d2_parser.yy" // lalr1.cc:859 { ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("tsig-keys", l); ctx.stack_.push_back(l); ctx.enter(ctx.TSIG_KEYS); } -#line 973 "d2_parser.cc" // lalr1.cc:859 +#line 1151 "d2_parser.cc" // lalr1.cc:859 break; - case 68: -#line 323 "d2_parser.yy" // lalr1.cc:859 + case 111: +#line 472 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); ctx.leave(); } -#line 982 "d2_parser.cc" // lalr1.cc:859 +#line 1160 "d2_parser.cc" // lalr1.cc:859 break; - case 73: -#line 336 "d2_parser.yy" // lalr1.cc:859 + case 116: +#line 485 "d2_parser.yy" // lalr1.cc:859 { ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->add(m); ctx.stack_.push_back(m); } -#line 992 "d2_parser.cc" // lalr1.cc:859 +#line 1170 "d2_parser.cc" // lalr1.cc:859 break; - case 74: -#line 340 "d2_parser.yy" // lalr1.cc:859 + case 117: +#line 489 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); } -#line 1000 "d2_parser.cc" // lalr1.cc:859 +#line 1178 "d2_parser.cc" // lalr1.cc:859 break; - case 82: -#line 355 "d2_parser.yy" // lalr1.cc:859 + case 125: +#line 504 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1008 "d2_parser.cc" // lalr1.cc:859 +#line 1186 "d2_parser.cc" // lalr1.cc:859 break; - case 83: -#line 357 "d2_parser.yy" // lalr1.cc:859 + case 126: +#line 506 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< std::string > () == "") { error(yystack_[1].location, "name cannot be blank"); @@ -1018,19 +1196,19 @@ namespace isc { namespace d2 { ctx.stack_.back()->set("name", name); ctx.leave(); } -#line 1022 "d2_parser.cc" // lalr1.cc:859 +#line 1200 "d2_parser.cc" // lalr1.cc:859 break; - case 84: -#line 367 "d2_parser.yy" // lalr1.cc:859 + case 127: +#line 516 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1030 "d2_parser.cc" // lalr1.cc:859 +#line 1208 "d2_parser.cc" // lalr1.cc:859 break; - case 85: -#line 369 "d2_parser.yy" // lalr1.cc:859 + case 128: +#line 518 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< std::string > () == "") { error(yystack_[1].location, "algorithm cannot be blank"); @@ -1039,11 +1217,11 @@ namespace isc { namespace d2 { ctx.stack_.back()->set("algorithm", elem); ctx.leave(); } -#line 1043 "d2_parser.cc" // lalr1.cc:859 +#line 1221 "d2_parser.cc" // lalr1.cc:859 break; - case 86: -#line 378 "d2_parser.yy" // lalr1.cc:859 + case 129: +#line 527 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< int64_t > () < 0 || (yystack_[0].value.as< int64_t > () > 0 && (yystack_[0].value.as< int64_t > () % 8 != 0))) { error(yystack_[0].location, "digest-bits must either be zero or a positive, multiple of eight"); @@ -1051,19 +1229,19 @@ namespace isc { namespace d2 { ElementPtr elem(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("digest-bits", elem); } -#line 1055 "d2_parser.cc" // lalr1.cc:859 +#line 1233 "d2_parser.cc" // lalr1.cc:859 break; - case 87: -#line 386 "d2_parser.yy" // lalr1.cc:859 + case 130: +#line 535 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1063 "d2_parser.cc" // lalr1.cc:859 +#line 1241 "d2_parser.cc" // lalr1.cc:859 break; - case 88: -#line 388 "d2_parser.yy" // lalr1.cc:859 + case 131: +#line 537 "d2_parser.yy" // lalr1.cc:859 { if (yystack_[0].value.as< std::string > () == "") { error(yystack_[1].location, "secret cannot be blank"); @@ -1072,204 +1250,204 @@ namespace isc { namespace d2 { ctx.stack_.back()->set("secret", elem); ctx.leave(); } -#line 1076 "d2_parser.cc" // lalr1.cc:859 +#line 1254 "d2_parser.cc" // lalr1.cc:859 break; - case 89: -#line 401 "d2_parser.yy" // lalr1.cc:859 + case 132: +#line 550 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1084 "d2_parser.cc" // lalr1.cc:859 +#line 1262 "d2_parser.cc" // lalr1.cc:859 break; - case 90: -#line 403 "d2_parser.yy" // lalr1.cc:859 + case 133: +#line 552 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.back()->set("Dhcp6", yystack_[0].value.as< ElementPtr > ()); ctx.leave(); } -#line 1093 "d2_parser.cc" // lalr1.cc:859 +#line 1271 "d2_parser.cc" // lalr1.cc:859 break; - case 91: -#line 408 "d2_parser.yy" // lalr1.cc:859 + case 134: +#line 557 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1101 "d2_parser.cc" // lalr1.cc:859 +#line 1279 "d2_parser.cc" // lalr1.cc:859 break; - case 92: -#line 410 "d2_parser.yy" // lalr1.cc:859 + case 135: +#line 559 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.back()->set("Dhcp4", yystack_[0].value.as< ElementPtr > ()); ctx.leave(); } -#line 1110 "d2_parser.cc" // lalr1.cc:859 +#line 1288 "d2_parser.cc" // lalr1.cc:859 break; - case 93: -#line 420 "d2_parser.yy" // lalr1.cc:859 + case 136: +#line 569 "d2_parser.yy" // lalr1.cc:859 { ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("Logging", m); ctx.stack_.push_back(m); ctx.enter(ctx.LOGGING); } -#line 1121 "d2_parser.cc" // lalr1.cc:859 +#line 1299 "d2_parser.cc" // lalr1.cc:859 break; - case 94: -#line 425 "d2_parser.yy" // lalr1.cc:859 + case 137: +#line 574 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); ctx.leave(); } -#line 1130 "d2_parser.cc" // lalr1.cc:859 +#line 1308 "d2_parser.cc" // lalr1.cc:859 break; - case 98: -#line 442 "d2_parser.yy" // lalr1.cc:859 + case 141: +#line 591 "d2_parser.yy" // lalr1.cc:859 { ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("loggers", l); ctx.stack_.push_back(l); ctx.enter(ctx.LOGGERS); } -#line 1141 "d2_parser.cc" // lalr1.cc:859 +#line 1319 "d2_parser.cc" // lalr1.cc:859 break; - case 99: -#line 447 "d2_parser.yy" // lalr1.cc:859 + case 142: +#line 596 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); ctx.leave(); } -#line 1150 "d2_parser.cc" // lalr1.cc:859 +#line 1328 "d2_parser.cc" // lalr1.cc:859 break; - case 102: -#line 459 "d2_parser.yy" // lalr1.cc:859 + case 145: +#line 608 "d2_parser.yy" // lalr1.cc:859 { ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->add(l); ctx.stack_.push_back(l); } -#line 1160 "d2_parser.cc" // lalr1.cc:859 +#line 1338 "d2_parser.cc" // lalr1.cc:859 break; - case 103: -#line 463 "d2_parser.yy" // lalr1.cc:859 + case 146: +#line 612 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); } -#line 1168 "d2_parser.cc" // lalr1.cc:859 +#line 1346 "d2_parser.cc" // lalr1.cc:859 break; - case 111: -#line 478 "d2_parser.yy" // lalr1.cc:859 + case 154: +#line 627 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1176 "d2_parser.cc" // lalr1.cc:859 +#line 1354 "d2_parser.cc" // lalr1.cc:859 break; - case 112: -#line 480 "d2_parser.yy" // lalr1.cc:859 + case 155: +#line 629 "d2_parser.yy" // lalr1.cc:859 { ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("name", name); ctx.leave(); } -#line 1186 "d2_parser.cc" // lalr1.cc:859 +#line 1364 "d2_parser.cc" // lalr1.cc:859 break; - case 113: -#line 486 "d2_parser.yy" // lalr1.cc:859 + case 156: +#line 635 "d2_parser.yy" // lalr1.cc:859 { ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("debuglevel", dl); } -#line 1195 "d2_parser.cc" // lalr1.cc:859 +#line 1373 "d2_parser.cc" // lalr1.cc:859 break; - case 114: -#line 490 "d2_parser.yy" // lalr1.cc:859 + case 157: +#line 639 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1203 "d2_parser.cc" // lalr1.cc:859 +#line 1381 "d2_parser.cc" // lalr1.cc:859 break; - case 115: -#line 492 "d2_parser.yy" // lalr1.cc:859 + case 158: +#line 641 "d2_parser.yy" // lalr1.cc:859 { ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("severity", sev); ctx.leave(); } -#line 1213 "d2_parser.cc" // lalr1.cc:859 +#line 1391 "d2_parser.cc" // lalr1.cc:859 break; - case 116: -#line 498 "d2_parser.yy" // lalr1.cc:859 + case 159: +#line 647 "d2_parser.yy" // lalr1.cc:859 { ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("output_options", l); ctx.stack_.push_back(l); ctx.enter(ctx.OUTPUT_OPTIONS); } -#line 1224 "d2_parser.cc" // lalr1.cc:859 +#line 1402 "d2_parser.cc" // lalr1.cc:859 break; - case 117: -#line 503 "d2_parser.yy" // lalr1.cc:859 + case 160: +#line 652 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); ctx.leave(); } -#line 1233 "d2_parser.cc" // lalr1.cc:859 +#line 1411 "d2_parser.cc" // lalr1.cc:859 break; - case 120: -#line 512 "d2_parser.yy" // lalr1.cc:859 + case 163: +#line 661 "d2_parser.yy" // lalr1.cc:859 { ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->add(m); ctx.stack_.push_back(m); } -#line 1243 "d2_parser.cc" // lalr1.cc:859 +#line 1421 "d2_parser.cc" // lalr1.cc:859 break; - case 121: -#line 516 "d2_parser.yy" // lalr1.cc:859 + case 164: +#line 665 "d2_parser.yy" // lalr1.cc:859 { ctx.stack_.pop_back(); } -#line 1251 "d2_parser.cc" // lalr1.cc:859 +#line 1429 "d2_parser.cc" // lalr1.cc:859 break; - case 124: -#line 524 "d2_parser.yy" // lalr1.cc:859 + case 167: +#line 673 "d2_parser.yy" // lalr1.cc:859 { ctx.enter(ctx.NO_KEYWORD); } -#line 1259 "d2_parser.cc" // lalr1.cc:859 +#line 1437 "d2_parser.cc" // lalr1.cc:859 break; - case 125: -#line 526 "d2_parser.yy" // lalr1.cc:859 + case 168: +#line 675 "d2_parser.yy" // lalr1.cc:859 { ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); ctx.stack_.back()->set("output", sev); ctx.leave(); } -#line 1269 "d2_parser.cc" // lalr1.cc:859 +#line 1447 "d2_parser.cc" // lalr1.cc:859 break; -#line 1273 "d2_parser.cc" // lalr1.cc:859 +#line 1451 "d2_parser.cc" // lalr1.cc:859 default: break; } @@ -1524,35 +1702,42 @@ namespace isc { namespace d2 { } - const signed char D2Parser::yypact_ninf_ = -78; + const signed char D2Parser::yypact_ninf_ = -104; const signed char D2Parser::yytable_ninf_ = -1; - const signed char + const short int D2Parser::yypact_[] = { - 28, -78, -78, -78, 5, -3, 12, 13, -78, -78, - -78, -78, -78, -78, -78, -78, -78, -78, -78, -78, - -78, -78, -78, -78, -3, -7, 1, 2, -78, 27, - 43, 54, 52, 66, -78, -78, -78, -78, 67, -78, - 0, -78, -78, -78, -78, -78, -78, 68, 69, -78, - -78, -78, -78, -78, -78, 6, -78, -78, -78, -78, - -78, -78, -78, -78, -78, -78, -3, -3, -78, 33, - 70, 71, 72, 75, -78, 1, -78, 76, 44, 45, - 80, 81, 82, 83, 84, 2, -78, -78, -78, 85, - -3, -3, 86, 87, -78, 55, -78, -78, 48, 77, - -3, -3, 90, -78, -3, -78, -78, 2, 62, -78, - -78, -78, -78, -78, -78, -78, 89, -78, 19, -78, - 23, -78, -78, -78, 92, 88, -78, -78, 95, 62, - -78, 16, -78, 89, 96, -78, -78, 98, -78, -78, - -78, 49, -78, -78, -78, -78, -78, -78, 93, 99, - 73, 100, 102, 16, -78, -78, 4, -78, 78, -78, - 79, 91, -78, 18, 93, -78, -78, -78, -78, -78, - -78, 103, -78, -78, 51, -78, -78, -78, -78, -78, - -78, 104, 105, 74, 106, 18, -78, 94, 108, -78, - 97, -78, -78, 107, -78, -78, 26, -78, 101, 107, - -78, -78, 53, -78, -78, 113, 101, -78, 109, -78, - -78 + -24, -104, -104, -104, 3, -3, -2, 0, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -3, -8, 1, 4, -104, 42, + 47, 58, 68, 79, -104, -104, -104, -104, 83, -104, + 19, -104, -104, -104, -104, -104, -104, 88, 89, -104, + -104, -104, -104, -104, -104, 21, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -3, -3, -104, 53, + 91, 92, 93, 94, -104, 1, -104, 95, 59, 60, + 96, 99, 100, 101, 102, 4, -104, -104, -104, 103, + -3, -3, 104, 105, -104, 74, -104, -104, 73, 90, + 107, 110, 113, -104, -3, -104, -104, 4, 87, -104, + -104, -104, -104, -104, -13, -13, 114, -104, 27, -104, + 51, -104, -104, -104, -104, 63, -104, -104, -104, 66, + -104, 116, 106, -104, -104, 119, 87, -104, 120, -13, + -104, -104, 23, -104, 114, 115, -104, 121, -104, -104, + 123, -104, -104, -104, 67, -104, -104, -104, -104, -104, + -104, 118, 122, 124, 97, 126, 127, 23, -104, -104, + 31, -104, -104, 128, 129, -104, 108, -104, 109, 111, + -104, 24, 118, -104, 22, -104, 122, -104, -104, -104, + -104, -104, 131, -104, -104, 69, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, 70, -104, -104, -104, + -104, -104, 132, 133, 98, 134, 24, -104, 138, 139, + 140, 22, -104, 112, 141, -104, 125, -104, 130, 142, + 135, -104, -104, 144, -104, -104, 147, -104, -104, 80, + -104, -104, 150, 145, -104, 137, 144, -104, -5, -104, + 147, -104, 76, -104, -104, -104, 153, -104, -104, 77, + -104, -104, -104, -104, -104, 155, 137, -104, 156, 136, + 157, -5, -104, 143, -104, 146, -104, 148, -104, -104, + -104, -104 }; const unsigned char @@ -1561,39 +1746,48 @@ namespace isc { namespace d2 { 0, 2, 4, 6, 0, 0, 0, 0, 1, 22, 16, 12, 11, 8, 9, 10, 15, 3, 13, 14, 29, 5, 40, 7, 24, 18, 0, 0, 26, 0, - 25, 0, 0, 19, 89, 91, 38, 93, 0, 37, + 25, 0, 0, 19, 132, 134, 38, 136, 0, 37, 0, 31, 36, 33, 35, 34, 53, 0, 0, 57, - 61, 63, 65, 67, 52, 0, 42, 44, 45, 46, + 61, 63, 65, 110, 52, 0, 42, 44, 45, 46, 47, 48, 49, 50, 51, 23, 0, 0, 17, 0, 0, 0, 0, 0, 28, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 41, 27, 20, 0, 0, 0, 0, 0, 32, 0, 55, 56, 0, 0, - 0, 0, 0, 43, 0, 90, 92, 0, 0, 54, - 59, 60, 58, 62, 64, 66, 69, 21, 0, 98, - 0, 95, 97, 73, 0, 70, 71, 39, 0, 0, - 94, 0, 68, 0, 0, 96, 84, 0, 87, 82, - 81, 0, 75, 77, 78, 79, 80, 72, 0, 0, - 0, 0, 0, 0, 74, 102, 0, 100, 0, 86, - 0, 0, 76, 0, 0, 99, 85, 88, 83, 111, - 116, 0, 114, 110, 0, 104, 106, 108, 109, 107, - 101, 0, 0, 0, 0, 0, 103, 0, 0, 113, - 0, 105, 112, 0, 115, 120, 0, 118, 0, 0, - 117, 124, 0, 122, 119, 0, 0, 121, 0, 123, - 125 + 0, 0, 0, 43, 0, 133, 135, 0, 0, 54, + 59, 60, 58, 62, 67, 67, 112, 21, 0, 141, + 0, 138, 140, 73, 72, 0, 68, 69, 71, 0, + 116, 0, 113, 114, 39, 0, 0, 137, 0, 0, + 64, 66, 0, 111, 0, 0, 139, 0, 70, 127, + 0, 130, 125, 124, 0, 118, 120, 121, 122, 123, + 115, 0, 75, 0, 0, 0, 0, 0, 117, 145, + 0, 143, 79, 0, 76, 77, 0, 129, 0, 0, + 119, 0, 0, 142, 0, 74, 0, 128, 131, 126, + 154, 159, 0, 157, 153, 0, 147, 149, 151, 152, + 150, 144, 89, 91, 87, 86, 0, 81, 83, 84, + 85, 78, 0, 0, 0, 0, 0, 146, 0, 0, + 0, 0, 80, 0, 0, 156, 0, 148, 0, 0, + 0, 82, 155, 0, 158, 90, 93, 88, 163, 0, + 161, 97, 0, 94, 95, 0, 0, 160, 0, 92, + 0, 167, 0, 165, 162, 107, 0, 105, 104, 0, + 99, 101, 102, 103, 96, 0, 0, 164, 0, 0, + 0, 0, 98, 0, 166, 0, 109, 0, 100, 168, + 108, 106 }; const signed char D2Parser::yypgoto_[] = { - -78, -78, -78, -78, -78, -23, -78, -78, -78, -78, - -78, -78, -78, -78, -78, -26, -78, -78, -78, 46, - -78, -78, -78, -78, 11, 34, -78, -78, -78, -78, - -78, -78, -78, -78, -78, -78, -78, -78, -78, -78, - -78, -78, -78, -13, -78, -78, -31, -78, -78, -78, - -78, -78, -78, -78, -78, -78, -78, -78, -78, -78, - -78, -6, -78, -78, -78, -40, -78, -78, -60, -78, - -78, -78, -78, -78, -78, -78, -78, -73, -78, -78, - -77, -78 + -104, -104, -104, -104, -104, -23, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -26, -104, -104, -104, 33, + -104, -104, -104, -104, 26, 78, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, 30, + -104, 25, -104, -104, -104, -104, -21, -104, -104, -59, + -104, -104, -104, -104, -104, -104, -104, -104, -83, -104, + -104, -103, -104, -104, -104, -104, -104, -104, -104, -104, + -104, 29, -104, -104, 2, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, 34, + -104, -104, -104, -7, -104, -104, -42, -104, -104, -104, + -104, -104, -104, -104, -104, -69, -104, -104, -87, -104 }; const short int @@ -1602,99 +1796,130 @@ namespace isc { namespace d2 { -1, 4, 5, 6, 7, 16, 17, 18, 25, 32, 33, 19, 24, 29, 30, 54, 21, 26, 40, 41, 42, 72, 23, 27, 55, 56, 57, 77, 58, 59, - 60, 80, 112, 61, 81, 62, 82, 63, 83, 64, - 84, 124, 125, 126, 131, 141, 142, 143, 152, 144, - 149, 145, 146, 151, 43, 70, 44, 71, 45, 73, - 120, 121, 122, 128, 156, 157, 163, 174, 175, 176, - 181, 177, 178, 184, 179, 182, 196, 197, 198, 202, - 203, 205 + 60, 80, 112, 61, 81, 62, 82, 63, 83, 125, + 126, 127, 128, 138, 173, 174, 175, 184, 206, 207, + 208, 220, 209, 218, 210, 219, 242, 243, 244, 248, + 259, 260, 261, 270, 262, 268, 263, 64, 84, 131, + 132, 133, 142, 154, 155, 156, 166, 157, 163, 158, + 159, 165, 43, 70, 44, 71, 45, 73, 120, 121, + 122, 135, 170, 171, 181, 195, 196, 197, 212, 198, + 199, 215, 200, 213, 239, 240, 245, 252, 253, 265 }; - const unsigned char + const unsigned short int D2Parser::yytable_[] = { - 39, 28, 9, 75, 10, 8, 11, 164, 76, 85, - 165, 34, 35, 36, 86, 46, 47, 48, 49, 20, - 22, 50, 85, 51, 52, 53, 129, 127, 37, 199, - 31, 130, 200, 65, 12, 13, 14, 15, 38, 38, - 136, 137, 138, 87, 88, 139, 66, 169, 170, 39, - 171, 172, 153, 38, 185, 38, 206, 154, 67, 186, - 68, 207, 1, 2, 3, 110, 111, 105, 106, 69, - 89, 74, 78, 79, 90, 91, 92, 114, 115, 93, - 95, 117, 96, 97, 98, 99, 100, 101, 102, 104, - 119, 133, 109, 107, 108, 116, 123, 113, 132, 134, - 155, 148, 150, 158, 160, 140, 161, 183, 187, 188, - 190, 159, 189, 193, 195, 166, 167, 208, 118, 103, - 147, 94, 162, 135, 180, 191, 204, 140, 168, 209, - 0, 192, 201, 0, 194, 0, 0, 173, 0, 0, - 0, 0, 0, 0, 0, 0, 210, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 173 + 39, 28, 9, 8, 10, 20, 11, 22, 255, 256, + 123, 34, 35, 36, 1, 2, 3, 46, 47, 48, + 49, 257, 75, 50, 85, 51, 52, 76, 38, 86, + 85, 53, 37, 31, 182, 134, 38, 183, 12, 13, + 14, 15, 38, 87, 88, 38, 202, 203, 65, 39, + 66, 149, 150, 151, 136, 204, 152, 190, 191, 137, + 192, 193, 67, 38, 38, 38, 139, 105, 106, 139, + 167, 140, 216, 221, 141, 168, 68, 217, 222, 266, + 271, 117, 69, 246, 267, 272, 247, 74, 124, 124, + 110, 111, 78, 79, 89, 90, 91, 92, 93, 95, + 98, 96, 97, 99, 100, 101, 102, 104, 94, 144, + 113, 107, 108, 124, 114, 109, 153, 115, 116, 119, + 161, 130, 143, 145, 147, 169, 162, 164, 176, 172, + 178, 179, 186, 118, 185, 214, 223, 224, 226, 177, + 225, 153, 228, 229, 230, 129, 233, 236, 250, 187, + 188, 238, 189, 232, 241, 194, 249, 269, 205, 273, + 275, 277, 231, 103, 148, 211, 234, 264, 278, 180, + 146, 235, 251, 160, 227, 201, 237, 254, 276, 274, + 0, 0, 0, 0, 279, 0, 0, 280, 0, 281, + 194, 0, 0, 0, 0, 205, 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, 0, 258, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 258 }; const short int D2Parser::yycheck_[] = { - 26, 24, 5, 3, 7, 0, 9, 3, 8, 3, - 6, 10, 11, 12, 8, 13, 14, 15, 16, 7, - 7, 19, 3, 21, 22, 23, 3, 8, 27, 3, - 37, 8, 6, 6, 37, 38, 39, 40, 37, 37, - 24, 25, 26, 66, 67, 29, 3, 29, 30, 75, - 32, 33, 3, 37, 3, 37, 3, 8, 4, 8, - 8, 8, 34, 35, 36, 17, 18, 90, 91, 3, - 37, 4, 4, 4, 4, 4, 4, 100, 101, 4, - 4, 104, 38, 38, 4, 4, 4, 4, 4, 4, - 28, 3, 37, 7, 7, 5, 7, 20, 6, 4, - 7, 5, 4, 4, 4, 131, 4, 4, 4, 4, - 4, 38, 38, 5, 7, 37, 37, 4, 107, 85, - 133, 75, 153, 129, 164, 185, 199, 153, 37, 206, - -1, 37, 31, -1, 37, -1, -1, 163, -1, -1, - -1, -1, -1, -1, -1, -1, 37, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 185 + 26, 24, 5, 0, 7, 7, 9, 7, 13, 14, + 23, 10, 11, 12, 38, 39, 40, 13, 14, 15, + 16, 26, 3, 19, 3, 21, 22, 8, 41, 8, + 3, 27, 31, 41, 3, 8, 41, 6, 41, 42, + 43, 44, 41, 66, 67, 41, 24, 25, 6, 75, + 3, 28, 29, 30, 3, 33, 33, 33, 34, 8, + 36, 37, 4, 41, 41, 41, 3, 90, 91, 3, + 3, 8, 3, 3, 8, 8, 8, 8, 8, 3, + 3, 104, 3, 3, 8, 8, 6, 4, 114, 115, + 17, 18, 4, 4, 41, 4, 4, 4, 4, 4, + 4, 42, 42, 4, 4, 4, 4, 4, 75, 3, + 20, 7, 7, 139, 7, 41, 142, 7, 5, 32, + 5, 7, 6, 4, 4, 7, 5, 4, 4, 7, + 4, 4, 3, 107, 6, 4, 4, 4, 4, 42, + 42, 167, 4, 4, 4, 115, 5, 5, 3, 41, + 41, 7, 41, 41, 7, 181, 6, 4, 184, 4, + 4, 4, 221, 85, 139, 186, 41, 250, 271, 167, + 136, 41, 35, 144, 216, 182, 41, 246, 42, 266, + -1, -1, -1, -1, 41, -1, -1, 41, -1, 41, + 216, -1, -1, -1, -1, 221, -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, 248, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 271 }; const unsigned char D2Parser::yystos_[] = { - 0, 34, 35, 36, 42, 43, 44, 45, 0, 5, - 7, 9, 37, 38, 39, 40, 46, 47, 48, 52, - 7, 57, 7, 63, 53, 49, 58, 64, 46, 54, - 55, 37, 50, 51, 10, 11, 12, 27, 37, 56, - 59, 60, 61, 95, 97, 99, 13, 14, 15, 16, - 19, 21, 22, 23, 56, 65, 66, 67, 69, 70, - 71, 74, 76, 78, 80, 6, 3, 4, 8, 3, - 96, 98, 62, 100, 4, 3, 8, 68, 4, 4, - 72, 75, 77, 79, 81, 3, 8, 46, 46, 37, - 4, 4, 4, 4, 60, 4, 38, 38, 4, 4, - 4, 4, 4, 66, 4, 46, 46, 7, 7, 37, - 17, 18, 73, 20, 46, 46, 5, 46, 65, 28, - 101, 102, 103, 7, 82, 83, 84, 8, 104, 3, - 8, 85, 6, 3, 4, 102, 24, 25, 26, 29, - 56, 86, 87, 88, 90, 92, 93, 84, 5, 91, - 4, 94, 89, 3, 8, 7, 105, 106, 4, 38, - 4, 4, 87, 107, 3, 6, 37, 37, 37, 29, - 30, 32, 33, 56, 108, 109, 110, 112, 113, 115, - 106, 111, 116, 4, 114, 3, 8, 4, 4, 38, - 4, 109, 37, 5, 37, 7, 117, 118, 119, 3, - 6, 31, 120, 121, 118, 122, 3, 8, 4, 121, - 37 + 0, 38, 39, 40, 46, 47, 48, 49, 0, 5, + 7, 9, 41, 42, 43, 44, 50, 51, 52, 56, + 7, 61, 7, 67, 57, 53, 62, 68, 50, 58, + 59, 41, 54, 55, 10, 11, 12, 31, 41, 60, + 63, 64, 65, 127, 129, 131, 13, 14, 15, 16, + 19, 21, 22, 27, 60, 69, 70, 71, 73, 74, + 75, 78, 80, 82, 112, 6, 3, 4, 8, 3, + 128, 130, 66, 132, 4, 3, 8, 72, 4, 4, + 76, 79, 81, 83, 113, 3, 8, 50, 50, 41, + 4, 4, 4, 4, 64, 4, 42, 42, 4, 4, + 4, 4, 4, 70, 4, 50, 50, 7, 7, 41, + 17, 18, 77, 20, 7, 7, 5, 50, 69, 32, + 133, 134, 135, 23, 60, 84, 85, 86, 87, 84, + 7, 114, 115, 116, 8, 136, 3, 8, 88, 3, + 8, 8, 117, 6, 3, 4, 134, 4, 86, 28, + 29, 30, 33, 60, 118, 119, 120, 122, 124, 125, + 116, 5, 5, 123, 4, 126, 121, 3, 8, 7, + 137, 138, 7, 89, 90, 91, 4, 42, 4, 4, + 119, 139, 3, 6, 92, 6, 3, 41, 41, 41, + 33, 34, 36, 37, 60, 140, 141, 142, 144, 145, + 147, 138, 24, 25, 33, 60, 93, 94, 95, 97, + 99, 91, 143, 148, 4, 146, 3, 8, 98, 100, + 96, 3, 8, 4, 4, 42, 4, 141, 4, 4, + 4, 94, 41, 5, 41, 41, 5, 41, 7, 149, + 150, 7, 101, 102, 103, 151, 3, 6, 104, 6, + 3, 35, 152, 153, 150, 13, 14, 26, 60, 105, + 106, 107, 109, 111, 103, 154, 3, 8, 110, 4, + 108, 3, 8, 4, 153, 4, 42, 4, 106, 41, + 41, 41 }; const unsigned char D2Parser::yyr1_[] = { - 0, 41, 43, 42, 44, 42, 45, 42, 46, 46, - 46, 46, 46, 46, 46, 47, 49, 48, 50, 50, - 51, 51, 53, 52, 54, 54, 55, 55, 56, 58, - 57, 59, 59, 60, 60, 60, 60, 60, 62, 61, - 64, 63, 65, 65, 66, 66, 66, 66, 66, 66, - 66, 66, 66, 68, 67, 69, 70, 72, 71, 73, - 73, 75, 74, 77, 76, 79, 78, 81, 80, 82, - 82, 83, 83, 85, 84, 86, 86, 87, 87, 87, - 87, 87, 89, 88, 91, 90, 92, 94, 93, 96, - 95, 98, 97, 100, 99, 101, 101, 102, 104, 103, - 105, 105, 107, 106, 108, 108, 109, 109, 109, 109, - 109, 111, 110, 112, 114, 113, 116, 115, 117, 117, - 119, 118, 120, 120, 122, 121 + 0, 45, 47, 46, 48, 46, 49, 46, 50, 50, + 50, 50, 50, 50, 50, 51, 53, 52, 54, 54, + 55, 55, 57, 56, 58, 58, 59, 59, 60, 62, + 61, 63, 63, 64, 64, 64, 64, 64, 66, 65, + 68, 67, 69, 69, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 72, 71, 73, 74, 76, 75, 77, + 77, 79, 78, 81, 80, 83, 82, 84, 84, 85, + 85, 86, 86, 88, 87, 89, 89, 90, 90, 92, + 91, 93, 93, 94, 94, 94, 94, 96, 95, 98, + 97, 100, 99, 101, 101, 102, 102, 104, 103, 105, + 105, 106, 106, 106, 106, 108, 107, 110, 109, 111, + 113, 112, 114, 114, 115, 115, 117, 116, 118, 118, + 119, 119, 119, 119, 119, 121, 120, 123, 122, 124, + 126, 125, 128, 127, 130, 129, 132, 131, 133, 133, + 134, 136, 135, 137, 137, 139, 138, 140, 140, 141, + 141, 141, 141, 141, 143, 142, 144, 146, 145, 148, + 147, 149, 149, 151, 150, 152, 152, 154, 153 }; const unsigned char @@ -1706,13 +1931,17 @@ namespace isc { namespace d2 { 4, 1, 3, 1, 1, 1, 1, 1, 0, 6, 0, 4, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 4, 3, 3, 0, 4, 1, - 1, 0, 4, 0, 4, 0, 4, 0, 6, 0, - 1, 1, 3, 0, 4, 1, 3, 1, 1, 1, - 1, 1, 0, 4, 0, 4, 3, 0, 4, 0, - 4, 0, 4, 0, 6, 1, 3, 1, 0, 6, - 1, 3, 0, 4, 1, 3, 1, 1, 1, 1, - 1, 0, 4, 3, 0, 4, 0, 6, 1, 3, - 0, 4, 1, 3, 0, 4 + 1, 0, 4, 0, 6, 0, 6, 0, 1, 1, + 3, 1, 1, 0, 6, 0, 1, 1, 3, 0, + 4, 1, 3, 1, 1, 1, 1, 0, 4, 0, + 4, 0, 6, 0, 1, 1, 3, 0, 4, 1, + 3, 1, 1, 1, 1, 0, 4, 0, 4, 3, + 0, 6, 0, 1, 1, 3, 0, 4, 1, 3, + 1, 1, 1, 1, 1, 0, 4, 0, 4, 3, + 0, 4, 0, 4, 0, 4, 0, 6, 1, 3, + 1, 0, 6, 1, 3, 0, 4, 1, 3, 1, + 1, 1, 1, 1, 0, 4, 3, 0, 4, 0, + 6, 1, 3, 0, 4, 1, 3, 0, 4 }; @@ -1726,48 +1955,60 @@ namespace isc { namespace d2 { "\"]\"", "\"{\"", "\"}\"", "\"null\"", "\"Dhcp6\"", "\"Dhcp4\"", "\"DhcpDdns\"", "\"ip-address\"", "\"port\"", "\"dns-server-timeout\"", "\"ncr-protocol\"", "\"UDP\"", "\"TCP\"", "\"ncr-format\"", "\"JSON\"", - "\"forward-ddns\"", "\"reverse-ddns\"", "\"tsig-keys\"", "\"algorithm\"", - "\"digest-bits\"", "\"secret\"", "\"Logging\"", "\"loggers\"", - "\"name\"", "\"output_options\"", "\"output\"", "\"debuglevel\"", - "\"severity\"", "TOPLEVEL_JSON", "TOPLEVEL_DHCPDDNS", "SUB_DHCPDDNS", - "\"constant string\"", "\"integer\"", "\"floating point\"", - "\"boolean\"", "$accept", "start", "$@1", "$@2", "$@3", "value", - "sub_json", "map2", "$@4", "map_content", "not_empty_map", - "list_generic", "$@5", "list_content", "not_empty_list", + "\"forward-ddns\"", "\"reverse-ddns\"", "\"ddns-domains\"", + "\"key-name\"", "\"dns-servers\"", "\"hostname\"", "\"tsig-keys\"", + "\"algorithm\"", "\"digest-bits\"", "\"secret\"", "\"Logging\"", + "\"loggers\"", "\"name\"", "\"output_options\"", "\"output\"", + "\"debuglevel\"", "\"severity\"", "TOPLEVEL_JSON", "TOPLEVEL_DHCPDDNS", + "SUB_DHCPDDNS", "\"constant string\"", "\"integer\"", + "\"floating point\"", "\"boolean\"", "$accept", "start", "$@1", "$@2", + "$@3", "value", "sub_json", "map2", "$@4", "map_content", + "not_empty_map", "list_generic", "$@5", "list_content", "not_empty_list", "unknown_map_entry", "syntax_map", "$@6", "global_objects", "global_object", "dhcpddns_object", "$@7", "sub_dhcpddns", "$@8", "dhcpddns_params", "dhcpddns_param", "ip_address", "$@9", "port", "dns_server_timeout", "ncr_protocol", "$@10", "ncr_protocol_value", "ncr_format", "$@11", "forward_ddns", "$@12", "reverse_ddns", "$@13", - "tsig_keys", "$@14", "tsig_keys_list", "not_empty_tsig_keys_list", - "tsig_key", "$@15", "tsig_key_params", "tsig_key_param", "tsig_key_name", - "$@16", "tsig_key_algorithm", "$@17", "tsig_key_digest_bits", - "tsig_key_secret", "$@18", "dhcp6_json_object", "$@19", - "dhcp4_json_object", "$@20", "logging_object", "$@21", "logging_params", - "logging_param", "loggers", "$@22", "loggers_entries", "logger_entry", - "$@23", "logger_params", "logger_param", "name", "$@24", "debuglevel", - "severity", "$@25", "output_options_list", "$@26", - "output_options_list_content", "output_entry", "$@27", "output_params", - "output_param", "$@28", YY_NULLPTR + "ddns_mgr_params", "not_empty_ddns_mgr_params", "ddns_mgr_param", + "ddns_domains", "$@14", "ddns_domain_list", "not_empty_ddns_domain_list", + "ddns_domain", "$@15", "ddns_domain_params", "ddns_domain_param", + "ddns_domain_name", "$@16", "ddns_domain_key_name", "$@17", + "dns_servers", "$@18", "dns_server_list", "not_empty_dns_server_list", + "dns_server", "$@19", "dns_server_params", "dns_server_param", + "dns_server_hostname", "$@20", "dns_server_ip_address", "$@21", + "dns_server_port", "tsig_keys", "$@22", "tsig_keys_list", + "not_empty_tsig_keys_list", "tsig_key", "$@23", "tsig_key_params", + "tsig_key_param", "tsig_key_name", "$@24", "tsig_key_algorithm", "$@25", + "tsig_key_digest_bits", "tsig_key_secret", "$@26", "dhcp6_json_object", + "$@27", "dhcp4_json_object", "$@28", "logging_object", "$@29", + "logging_params", "logging_param", "loggers", "$@30", "loggers_entries", + "logger_entry", "$@31", "logger_params", "logger_param", "name", "$@32", + "debuglevel", "severity", "$@33", "output_options_list", "$@34", + "output_options_list_content", "output_entry", "$@35", "output_params", + "output_param", "$@36", YY_NULLPTR }; #if D2_PARSER_DEBUG const unsigned short int D2Parser::yyrline_[] = { - 0, 103, 103, 103, 104, 104, 105, 105, 113, 114, - 115, 116, 117, 118, 119, 122, 127, 127, 139, 140, - 143, 147, 154, 154, 169, 170, 173, 177, 188, 198, - 198, 210, 211, 215, 216, 217, 218, 219, 224, 224, - 234, 234, 242, 243, 246, 247, 248, 249, 250, 251, - 252, 253, 254, 257, 257, 265, 273, 282, 282, 290, - 291, 294, 294, 302, 302, 309, 309, 318, 318, 328, - 329, 332, 333, 336, 336, 344, 345, 348, 349, 350, - 351, 352, 355, 355, 367, 367, 378, 386, 386, 401, - 401, 408, 408, 420, 420, 433, 434, 438, 442, 442, - 454, 455, 459, 459, 467, 468, 471, 472, 473, 474, - 475, 478, 478, 486, 490, 490, 498, 498, 508, 509, - 512, 512, 520, 521, 524, 524 + 0, 107, 107, 107, 108, 108, 109, 109, 117, 118, + 119, 120, 121, 122, 123, 126, 131, 131, 143, 144, + 147, 151, 158, 158, 165, 166, 169, 173, 184, 194, + 194, 206, 207, 211, 212, 213, 214, 215, 220, 220, + 230, 230, 238, 239, 242, 243, 244, 245, 246, 247, + 248, 249, 250, 253, 253, 261, 269, 278, 278, 286, + 287, 290, 290, 298, 298, 308, 308, 318, 319, 322, + 323, 326, 327, 333, 333, 343, 344, 347, 348, 351, + 351, 359, 360, 363, 364, 365, 366, 370, 370, 382, + 382, 397, 397, 407, 408, 411, 412, 415, 415, 423, + 424, 427, 428, 429, 430, 433, 433, 445, 445, 453, + 467, 467, 477, 478, 481, 482, 485, 485, 493, 494, + 497, 498, 499, 500, 501, 504, 504, 516, 516, 527, + 535, 535, 550, 550, 557, 557, 569, 569, 582, 583, + 587, 591, 591, 603, 604, 608, 608, 616, 617, 620, + 621, 622, 623, 624, 627, 627, 635, 639, 639, 647, + 647, 657, 658, 661, 661, 669, 670, 673, 673 }; // Print the state stack on the debug stream. @@ -1802,8 +2043,8 @@ namespace isc { namespace d2 { #line 14 "d2_parser.yy" // lalr1.cc:1167 } } // isc::d2 -#line 1806 "d2_parser.cc" // lalr1.cc:1167 -#line 532 "d2_parser.yy" // lalr1.cc:1168 +#line 2047 "d2_parser.cc" // lalr1.cc:1167 +#line 681 "d2_parser.yy" // lalr1.cc:1168 void diff --git a/src/bin/d2/d2_parser.h b/src/bin/d2/d2_parser.h index 267c352ee1..11a29c190f 100644 --- a/src/bin/d2/d2_parser.h +++ b/src/bin/d2/d2_parser.h @@ -362,24 +362,28 @@ namespace isc { namespace d2 { TOKEN_JSON = 275, TOKEN_FORWARD_DDNS = 276, TOKEN_REVERSE_DDNS = 277, - TOKEN_TSIG_KEYS = 278, - TOKEN_ALGORITHM = 279, - TOKEN_DIGEST_BITS = 280, - TOKEN_SECRET = 281, - TOKEN_LOGGING = 282, - TOKEN_LOGGERS = 283, - TOKEN_NAME = 284, - TOKEN_OUTPUT_OPTIONS = 285, - TOKEN_OUTPUT = 286, - TOKEN_DEBUGLEVEL = 287, - TOKEN_SEVERITY = 288, - TOKEN_TOPLEVEL_JSON = 289, - TOKEN_TOPLEVEL_DHCPDDNS = 290, - TOKEN_SUB_DHCPDDNS = 291, - TOKEN_STRING = 292, - TOKEN_INTEGER = 293, - TOKEN_FLOAT = 294, - TOKEN_BOOLEAN = 295 + TOKEN_DDNS_DOMAINS = 278, + TOKEN_KEY_NAME = 279, + TOKEN_DNS_SERVERS = 280, + TOKEN_HOSTNAME = 281, + TOKEN_TSIG_KEYS = 282, + TOKEN_ALGORITHM = 283, + TOKEN_DIGEST_BITS = 284, + TOKEN_SECRET = 285, + TOKEN_LOGGING = 286, + TOKEN_LOGGERS = 287, + TOKEN_NAME = 288, + TOKEN_OUTPUT_OPTIONS = 289, + TOKEN_OUTPUT = 290, + TOKEN_DEBUGLEVEL = 291, + TOKEN_SEVERITY = 292, + TOKEN_TOPLEVEL_JSON = 293, + TOKEN_TOPLEVEL_DHCPDDNS = 294, + TOKEN_SUB_DHCPDDNS = 295, + TOKEN_STRING = 296, + TOKEN_INTEGER = 297, + TOKEN_FLOAT = 298, + TOKEN_BOOLEAN = 299 }; }; @@ -578,6 +582,22 @@ namespace isc { namespace d2 { symbol_type make_REVERSE_DDNS (const location_type& l); + static inline + symbol_type + make_DDNS_DOMAINS (const location_type& l); + + static inline + symbol_type + make_KEY_NAME (const location_type& l); + + static inline + symbol_type + make_DNS_SERVERS (const location_type& l); + + static inline + symbol_type + make_HOSTNAME (const location_type& l); + static inline symbol_type make_TSIG_KEYS (const location_type& l); @@ -717,7 +737,7 @@ namespace isc { namespace d2 { // Tables. // YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing // STATE-NUM. - static const signed char yypact_[]; + static const short int yypact_[]; // YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. // Performed when YYTABLE does not specify something else to do. Zero @@ -733,7 +753,7 @@ namespace isc { namespace d2 { // YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If // positive, shift that token. If negative, reduce the rule whose // number is the opposite. If YYTABLE_NINF, syntax error. - static const unsigned char yytable_[]; + static const unsigned short int yytable_[]; static const short int yycheck_[]; @@ -855,12 +875,12 @@ namespace isc { namespace d2 { enum { yyeof_ = 0, - yylast_ = 159, ///< Last index in yytable_. - yynnts_ = 82, ///< Number of nonterminal symbols. + yylast_ = 245, ///< Last index in yytable_. + yynnts_ = 110, ///< Number of nonterminal symbols. yyfinal_ = 8, ///< Termination state number. yyterror_ = 1, yyerrcode_ = 256, - yyntokens_ = 41 ///< Number of tokens. + yyntokens_ = 45 ///< Number of tokens. }; @@ -906,9 +926,9 @@ namespace isc { namespace d2 { 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, 34, - 35, 36, 37, 38, 39, 40 + 35, 36, 37, 38, 39, 40, 41, 42, 43, 44 }; - const unsigned int user_token_number_max_ = 295; + const unsigned int user_token_number_max_ = 299; const token_number_type undef_token_ = 2; if (static_cast(t) <= yyeof_) @@ -941,24 +961,24 @@ namespace isc { namespace d2 { { switch (other.type_get ()) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.copy< ElementPtr > (other.value); break; - case 40: // "boolean" + case 44: // "boolean" value.copy< bool > (other.value); break; - case 39: // "floating point" + case 43: // "floating point" value.copy< double > (other.value); break; - case 38: // "integer" + case 42: // "integer" value.copy< int64_t > (other.value); break; - case 37: // "constant string" + case 41: // "constant string" value.copy< std::string > (other.value); break; @@ -979,24 +999,24 @@ namespace isc { namespace d2 { (void) v; switch (this->type_get ()) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.copy< ElementPtr > (v); break; - case 40: // "boolean" + case 44: // "boolean" value.copy< bool > (v); break; - case 39: // "floating point" + case 43: // "floating point" value.copy< double > (v); break; - case 38: // "integer" + case 42: // "integer" value.copy< int64_t > (v); break; - case 37: // "constant string" + case 41: // "constant string" value.copy< std::string > (v); break; @@ -1076,24 +1096,24 @@ namespace isc { namespace d2 { // Type destructor. switch (yytype) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.template destroy< ElementPtr > (); break; - case 40: // "boolean" + case 44: // "boolean" value.template destroy< bool > (); break; - case 39: // "floating point" + case 43: // "floating point" value.template destroy< double > (); break; - case 38: // "integer" + case 42: // "integer" value.template destroy< int64_t > (); break; - case 37: // "constant string" + case 41: // "constant string" value.template destroy< std::string > (); break; @@ -1120,24 +1140,24 @@ namespace isc { namespace d2 { super_type::move(s); switch (this->type_get ()) { - case 46: // value - case 73: // ncr_protocol_value + case 50: // value + case 77: // ncr_protocol_value value.move< ElementPtr > (s.value); break; - case 40: // "boolean" + case 44: // "boolean" value.move< bool > (s.value); break; - case 39: // "floating point" + case 43: // "floating point" value.move< double > (s.value); break; - case 38: // "integer" + case 42: // "integer" value.move< int64_t > (s.value); break; - case 37: // "constant string" + case 41: // "constant string" value.move< std::string > (s.value); break; @@ -1200,7 +1220,7 @@ namespace isc { namespace d2 { 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, - 295 + 295, 296, 297, 298, 299 }; return static_cast (yytoken_number_[type]); } @@ -1331,6 +1351,30 @@ namespace isc { namespace d2 { return symbol_type (token::TOKEN_REVERSE_DDNS, l); } + D2Parser::symbol_type + D2Parser::make_DDNS_DOMAINS (const location_type& l) + { + return symbol_type (token::TOKEN_DDNS_DOMAINS, l); + } + + D2Parser::symbol_type + D2Parser::make_KEY_NAME (const location_type& l) + { + return symbol_type (token::TOKEN_KEY_NAME, l); + } + + D2Parser::symbol_type + D2Parser::make_DNS_SERVERS (const location_type& l) + { + return symbol_type (token::TOKEN_DNS_SERVERS, l); + } + + D2Parser::symbol_type + D2Parser::make_HOSTNAME (const location_type& l) + { + return symbol_type (token::TOKEN_HOSTNAME, l); + } + D2Parser::symbol_type D2Parser::make_TSIG_KEYS (const location_type& l) { @@ -1442,7 +1486,7 @@ namespace isc { namespace d2 { #line 14 "d2_parser.yy" // lalr1.cc:392 } } // isc::d2 -#line 1446 "d2_parser.h" // lalr1.cc:392 +#line 1490 "d2_parser.h" // lalr1.cc:392 diff --git a/src/bin/d2/d2_parser.yy b/src/bin/d2/d2_parser.yy index eddc47ccfa..5000a75042 100644 --- a/src/bin/d2/d2_parser.yy +++ b/src/bin/d2/d2_parser.yy @@ -63,6 +63,10 @@ using namespace std; JSON "JSON" FORWARD_DDNS "forward-ddns" REVERSE_DDNS "reverse-ddns" + DDNS_DOMAINS "ddns-domains" + KEY_NAME "key-name" + DNS_SERVERS "dns-servers" + HOSTNAME "hostname" TSIG_KEYS "tsig-keys" ALGORITHM "algorithm" DIGEST_BITS "digest-bits" @@ -158,14 +162,6 @@ list_generic: LSQUARE_BRACKET { // list parsing complete. Put any sanity checking here }; -//// This one is used in syntax parser. -//list2: LSQUARE_BRACKET { -// // List parsing about to start -//} list_content RSQUARE_BRACKET { -// // list parsing complete. Put any sanity checking here -// //ctx.stack_.pop_back(); -//}; - list_content: %empty // Empty list | not_empty_list ; @@ -300,19 +296,172 @@ ncr_format: NCR_FORMAT { }; forward_ddns : FORWARD_DDNS { - ctx.enter(ctx.NO_KEYWORD); -} COLON value { - ctx.stack_.back()->set("forward-ddns", $4); + ElementPtr m(new MapElement(ctx.loc2pos(@1))); + ctx.stack_.back()->set("forward-ddns", m); + ctx.stack_.push_back(m); + ctx.enter(ctx.FORWARD_DDNS); +} COLON LCURLY_BRACKET ddns_mgr_params RCURLY_BRACKET { + ctx.stack_.pop_back(); ctx.leave(); }; reverse_ddns : REVERSE_DDNS { + ElementPtr m(new MapElement(ctx.loc2pos(@1))); + ctx.stack_.back()->set("reverse-ddns", m); + ctx.stack_.push_back(m); + ctx.enter(ctx.REVERSE_DDNS); +} COLON LCURLY_BRACKET ddns_mgr_params RCURLY_BRACKET { + ctx.stack_.pop_back(); + ctx.leave(); +}; + +ddns_mgr_params: %empty + | not_empty_ddns_mgr_params + ; + +not_empty_ddns_mgr_params: ddns_mgr_param + | ddns_mgr_params COMMA ddns_mgr_param + ; + +ddns_mgr_param: ddns_domains + | unknown_map_entry + ; + + +// --- ddns-domains ---------------------------------------- + +ddns_domains: DDNS_DOMAINS { + ElementPtr l(new ListElement(ctx.loc2pos(@1))); + ctx.stack_.back()->set("ddns-domains", l); + ctx.stack_.push_back(l); + ctx.enter(ctx.DDNS_DOMAINS); +} COLON LSQUARE_BRACKET ddns_domain_list RSQUARE_BRACKET { + ctx.stack_.pop_back(); + ctx.leave(); +}; + +ddns_domain_list: %empty + | not_empty_ddns_domain_list + ; + +not_empty_ddns_domain_list: ddns_domain + | not_empty_ddns_domain_list COMMA ddns_domain + ; + +ddns_domain: LCURLY_BRACKET { + ElementPtr m(new MapElement(ctx.loc2pos(@1))); + ctx.stack_.back()->add(m); + ctx.stack_.push_back(m); +} ddns_domain_params RCURLY_BRACKET { + ctx.stack_.pop_back(); +}; + +ddns_domain_params: ddns_domain_param + | ddns_domain_params COMMA ddns_domain_param + ; + +ddns_domain_param: ddns_domain_name + | ddns_domain_key_name + | dns_servers + | unknown_map_entry + ; + +// @todo NAME needs to be an FQDN sort of thing +ddns_domain_name: NAME { ctx.enter(ctx.NO_KEYWORD); -} COLON value { - ctx.stack_.back()->set("reverse-ddns", $4); +} COLON STRING { + if ($4 == "") { + error(@3, "name cannot be blank"); + } + ElementPtr elem(new StringElement($4, ctx.loc2pos(@4))); + ElementPtr name(new StringElement($4, ctx.loc2pos(@4))); + ctx.stack_.back()->set("name", name); ctx.leave(); }; +ddns_domain_key_name: KEY_NAME { + ctx.enter(ctx.NO_KEYWORD); +} COLON STRING { + if ($4 == "") { + error(@3, "key-name cannot be blank"); + } + ElementPtr elem(new StringElement($4, ctx.loc2pos(@4))); + ElementPtr name(new StringElement($4, ctx.loc2pos(@4))); + ctx.stack_.back()->set("key-name", name); + ctx.leave(); +}; + +// --- end ddns-domains ---------------------------------------- + +// --- dns-servers ---------------------------------------- +dns_servers: DNS_SERVERS { + ElementPtr l(new ListElement(ctx.loc2pos(@1))); + ctx.stack_.back()->set("dns-servers", l); + ctx.stack_.push_back(l); + ctx.enter(ctx.DNS_SERVERS); +} COLON LSQUARE_BRACKET dns_server_list RSQUARE_BRACKET { + ctx.stack_.pop_back(); + ctx.leave(); +}; + +dns_server_list: %empty + | not_empty_dns_server_list + ; + +not_empty_dns_server_list: dns_server + | not_empty_dns_server_list COMMA dns_server + ; + +dns_server: LCURLY_BRACKET { + ElementPtr m(new MapElement(ctx.loc2pos(@1))); + ctx.stack_.back()->add(m); + ctx.stack_.push_back(m); +} dns_server_params RCURLY_BRACKET { + ctx.stack_.pop_back(); +}; + +dns_server_params: dns_server_param + | dns_server_params COMMA dns_server_param + ; + +dns_server_param: dns_server_hostname + | dns_server_ip_address + | dns_server_port + | unknown_map_entry + ; + +dns_server_hostname: HOSTNAME { + ctx.enter(ctx.NO_KEYWORD); +} COLON STRING { + if ($4 == "") { + error(@3, "hostname cannot be blank"); + } + ElementPtr elem(new StringElement($4, ctx.loc2pos(@4))); + ElementPtr name(new StringElement($4, ctx.loc2pos(@4))); + ctx.stack_.back()->set("hostname", name); + ctx.leave(); +}; + +dns_server_ip_address: IP_ADDRESS { + ctx.enter(ctx.NO_KEYWORD); +} COLON STRING { + ElementPtr s(new StringElement($4, ctx.loc2pos(@4))); + ctx.stack_.back()->set("ip-address", s); + ctx.leave(); +}; + +dns_server_port: PORT COLON INTEGER { + if ($3 <= 0) { + error(@3, "port must be greater than zero"); + } + ElementPtr i(new IntElement($3, ctx.loc2pos(@3))); + ctx.stack_.back()->set("port", i); +}; + +// --- end of dns-servers --------------------------------- + + + // --- tsig-keys ---------------------------------------- // "tsig-keys" : [ ... ] tsig_keys: TSIG_KEYS { diff --git a/src/bin/d2/parser_context.cc b/src/bin/d2/parser_context.cc index 9d0faf0bc4..200617d2c6 100644 --- a/src/bin/d2/parser_context.cc +++ b/src/bin/d2/parser_context.cc @@ -125,6 +125,20 @@ D2ParserContext::contextName() return ("DhcpDdns"); case TSIG_KEYS: return ("tsig-keys"); + case ALGORITHM: + return("algorithm"); + case DIGEST_BITS: + return("digest-bits"); + case SECRET: + return("secret"); + case FORWARD_DDNS: + return("forward-ddns"); + case REVERSE_DDNS: + return("reverse-ddns"); + case DDNS_DOMAINS: + return("ddns-domains"); + case DNS_SERVERS: + return("dns-servers"); case LOGGING: return ("Logging"); case LOGGERS: diff --git a/src/bin/d2/parser_context.h b/src/bin/d2/parser_context.h index dbb720b385..ede65d84c3 100644 --- a/src/bin/d2/parser_context.h +++ b/src/bin/d2/parser_context.h @@ -168,6 +168,18 @@ public: ///< Used while parsing content of DhcpDdns/tsig-keys/secret SECRET, + ///< Used while parsing content of DhcpDdns/forward-ddns + FORWARD_DDNS, + + ///< Used while parsing content of DhcpDdns/reverse-ddns + REVERSE_DDNS, + + ///< Used while parsing content of DhcpDdns/-ddns/ddns-domains + DDNS_DOMAINS, + + ///< Used while parsing content of DhcpDdns/-ddns/ddns-domains/dns-servers + DNS_SERVERS, + ///< Used while parsing content of Logging LOGGING, diff --git a/src/bin/d2/tests/d2_cfg_mgr_unittests.cc b/src/bin/d2/tests/d2_cfg_mgr_unittests.cc index e100e9e92c..b9fe89d487 100644 --- a/src/bin/d2/tests/d2_cfg_mgr_unittests.cc +++ b/src/bin/d2/tests/d2_cfg_mgr_unittests.cc @@ -1773,9 +1773,10 @@ TEST_F(D2CfgMgrTest, configPermutations) { EXPECT_EQ(expected_syntax_error, ex.what()) << description << ", syntax error mismatch"; - // Expected or not, skip logic testing on syntax errors. - continue; - } + } + + // Expected or not, skip logic testing on syntax errors. + continue; } // Attempt to Element parse the configuration. We verify that we get the diff --git a/src/bin/d2/tests/testdata/d2_cfg_tests.json b/src/bin/d2/tests/testdata/d2_cfg_tests.json index 4cc5077ba1..924af245cd 100644 --- a/src/bin/d2/tests/testdata/d2_cfg_tests.json +++ b/src/bin/d2/tests/testdata/d2_cfg_tests.json @@ -736,7 +736,7 @@ #------ ,{ "description" : "D2.forward-ddns, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.21-27: got unexpected keyword \"bogus\" in forward-ddns map.", "data" : { "forward-ddns" : @@ -820,7 +820,7 @@ #----- D2.forward-ddns.dhcp-ddns tests ,{ "description" : "D2.forward-ddns.dhcp-ddns, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.41-47: got unexpected keyword \"bogus\" in ddns-domains map.", "data" : { "forward-ddns" : @@ -839,8 +839,8 @@ #----- D2.forward-ddns.dhcp-ddns.name tests ,{ -"description" : "D2.forward-ddns.dhcp-ddns, no name", -"logic-error" : true, +"description" : "D2.forward-ddns.dhcp-ddns, empty domain", +"syntax-error" : ":1.42: syntax error, unexpected }, expecting key-name or dns-servers or name or constant string", "data" : { "forward-ddns" : @@ -859,7 +859,7 @@ #----- ,{ "description" : "D2.forward-ddns.dhcp-ddns, blank name", -"logic-error" : true, +"syntax-error" : ":1.47: name cannot be blank", "data" : { "forward-ddns" : @@ -934,7 +934,7 @@ #----- D2.forward-ddns.dhcp-ddns.dns-servers tests ,{ "description" : "D2.forward-ddns.dhcp-ddns.dns-servers, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.60-66: got unexpected keyword \"bogus\" in dns-servers map.", "data" : { "forward-ddns" : @@ -1089,7 +1089,7 @@ #----- ,{ "description" : "D2.forward-ddns.dhcp-ddns.dns-servers.port cannot be 0 ", -"logic-error" : true, +"syntax-error" : ":1.97: port must be greater than zero", "data" : { "forward-ddns" : @@ -1130,7 +1130,7 @@ #------ ,{ "description" : "D2.reverse-ddns, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.43-49: got unexpected keyword \"bogus\" in reverse-ddns map.", "data" : { "forward-ddns" : {}, @@ -1214,7 +1214,7 @@ #----- D2.reverse-ddns.dhcp-ddns tests ,{ "description" : "D2.reverse-ddns.dhcp-ddns, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.63-69: got unexpected keyword \"bogus\" in ddns-domains map.", "data" : { "forward-ddns" : {}, @@ -1234,7 +1234,7 @@ #----- D2.reverse-ddns.dhcp-ddns.name tests ,{ "description" : "D2.reverse-ddns.dhcp-ddns, no name", -"logic-error" : true, +"syntax-error" : ":1.64: syntax error, unexpected }, expecting key-name or dns-servers or name or constant string", "data" : { "forward-ddns" : {}, @@ -1253,7 +1253,7 @@ #----- ,{ "description" : "D2.reverse-ddns.dhcp-ddns, blank name", -"logic-error" : true, +"syntax-error" : ":1.69: name cannot be blank", "data" : { "forward-ddns" : {}, @@ -1328,7 +1328,7 @@ #----- D2.reverse-ddns.dhcp-ddns.dns-servers tests ,{ "description" : "D2.reverse-ddns.dhcp-ddns.dns-servers, unknown parameter", -"logic-error" : true, +"syntax-error" : ":1.82-88: got unexpected keyword \"bogus\" in dns-servers map.", "data" : { "forward-ddns" : {}, @@ -1482,7 +1482,7 @@ #----- ,{ "description" : "D2.reverse-ddns.dhcp-ddns.dns-servers.port cannot be 0 ", -"logic-error" : true, +"syntax-error" : ":1.119: port must be greater than zero", "data" : { "forward-ddns" : {},