From 4259b44a84f65d7a6ed0bfb901d889b16b5757de Mon Sep 17 00:00:00 2001 From: nikic Date: Fri, 7 Sep 2012 19:43:07 +0200 Subject: [PATCH] Add support for constant dereferencing (PHP 5.5) Examples: "foo"[2], [1, 2, 3][2] --- CHANGELOG.md | 3 + grammar/zend_language_parser.phpy | 17 +- lib/PHPParser/Parser.php | 1368 +++++++++-------- .../expr/fetchAndCall/constantDeref.test | 181 +++ 4 files changed, 894 insertions(+), 675 deletions(-) create mode 100644 test/code/parser/expr/fetchAndCall/constantDeref.test diff --git a/CHANGELOG.md b/CHANGELOG.md index b9194f8..0a4de43 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ Version 0.9.3-dev ----------------- +* [PHP 5.5] Add support for constant array / string dereferencing. + Examples: `"foo"[2]`, `[1, 2, 3][2]` + * [PHP 5.5] Add support for `yield` expressions. This adds a new `Yield` expression type, with subnodes `key` and `value`. diff --git a/grammar/zend_language_parser.phpy b/grammar/zend_language_parser.phpy index cbbee30..83383fd 100644 --- a/grammar/zend_language_parser.phpy +++ b/grammar/zend_language_parser.phpy @@ -582,8 +582,8 @@ expr: | T_EXIT exit_expr { $$ = Expr_Exit [$2]; } | '@' expr { $$ = Expr_ErrorSuppress[$2]; } | scalar { $$ = $1; } - | T_ARRAY '(' array_pair_list ')' { $$ = Expr_Array[$3]; } - | '[' array_pair_list ']' { $$ = Expr_Array[$2]; } + | array_expr { $$ = $1; } + | scalar_dereference { $$ = $1; } | '`' backticks_expr '`' { $$ = Expr_ShellExec[$2]; } | T_PRINT expr { $$ = Expr_Print[$2]; } | T_YIELD { $$ = Expr_Yield[null, null]; } @@ -603,6 +603,19 @@ yield_expr: | T_YIELD expr T_DOUBLE_ARROW expr { $$ = Expr_Yield[$2, $4]; } ; +array_expr: + T_ARRAY '(' array_pair_list ')' { $$ = Expr_Array[$3]; } + | '[' array_pair_list ']' { $$ = Expr_Array[$2]; } +; + +scalar_dereference: + array_expr '[' dim_offset ']' { $$ = Expr_ArrayDimFetch[$1, $3]; } + | T_CONSTANT_ENCAPSED_STRING '[' dim_offset ']' + { $$ = Expr_ArrayDimFetch[Scalar_String::create($1, $attributes), $3]; } + | scalar_dereference '[' dim_offset ']' { $$ = Expr_ArrayDimFetch[$1, $3]; } + /* alternative array syntax missing intentionally */ +; + new_expr: T_NEW class_name_reference ctor_arguments { $$ = Expr_New[$2, $3]; } ; diff --git a/lib/PHPParser/Parser.php b/lib/PHPParser/Parser.php index 101c694..ad02987 100644 --- a/lib/PHPParser/Parser.php +++ b/lib/PHPParser/Parser.php @@ -16,10 +16,10 @@ class PHPParser_Parser const TOKEN_MAP_SIZE = 386; - const YYLAST = 1006; - const YY2TBLSTATE = 313; - const YYGLAST = 406; - const YYNLSTATES = 525; + const YYLAST = 998; + const YY2TBLSTATE = 316; + const YYGLAST = 414; + const YYNLSTATES = 534; const YYUNEXPECTED = 32767; const YYDEFAULT = -32766; @@ -306,8 +306,8 @@ class PHPParser_Parser "'('", "')'", "'$'", - "']'", "'`'", + "']'", "'\"'" , "???" ); @@ -323,7 +323,7 @@ class PHPParser_Parser 36, 13, 38, 25, 60, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, - 151, 61, 151, 148, 30, 151, 149, 151, 151, 151, + 151, 61, 151, 149, 30, 151, 148, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 151, 143, 29, 144, 50, 151, 151, 151, @@ -356,217 +356,215 @@ class PHPParser_Parser ); protected static $yyaction = array( - 56, 57, 322, 58, 59,-32766,-32766,-32766, 624, 60, - 61,-32767,-32767,-32767,-32767, 94, 95, 96, 97, 98, - 54, 455,-32766, 294,-32766,-32766, 41, 102, 103, 104, - 105, 106, 107, 108, 109, 110, 111, 112, 264, 357, - 62, 63, 914, 488, 916, 915, 64, 529, 65, 216, - 217, 66, 67, 68, 69, 70, 71, 72, 73, 31, - 229, 74, 315, 323, 724, 726, 0, 826, 827, 359, - 348, 883, 337, 572, 500, 828, 46, 27, 324, 838, - 360, 242, 361, 321, 362, 39, 220, 325,-32766,-32766, - -32766, 36, 37, 363, 330, 277, 38, 364, 326, 418, - 75, 124, 118, 275, 276,-32766, 283,-32766, 35, 365, - 366, 367, 368, 369, 383, 340, 674, 327, 554, 596, - 370, 371, 372, 373, 625, 832, 833, 834, 835, 829, - 830, 236, 78, 79, 80, -344, 383, 836, 831, 327, - 578, 498, 343, 47, 224, 256, 555, 240, 244, 40, - 660, 81, 82, 83, 84, 85, 86, 87, 88, 89, - 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, - 100, 101, 782, 230, 669,-32766,-32766,-32766, 695, 696, - 697, 694, 693, 692, 911,-32766,-32766,-32766,-32766, 649, - 650, 211,-32766, 182,-32766,-32766,-32766,-32766,-32766,-32767, - -32767,-32767,-32767,-32766, 782, 319, 326, 316, 347, 22, - -117, 254, 190, 274,-32766,-32766,-32766, 365, 366, 877, - 687, 904, 792, 218, 213,-32766, 534, 596, 370, 371, - 538, 529, 341, 258, 529,-32766, 883, 372,-32766,-32766, - -32766, 569,-32766, 51,-32766, 319,-32766, 652, 260,-32766, - 53, 254, 595,-32766,-32766,-32766, 782,-32766,-32766,-32766, - 687, 119,-32766, 529, 345,-32766, 382,-32766, 212, 802, - -32766,-32766,-32766,-32766,-32766, 221,-32766, 570,-32766, 50, - 122,-32766, 96, 97, 98,-32766,-32766,-32766, 782, 883, - -32766,-32766, 594, 265,-32766, 848, 887,-32766, 382,-32766, - -32766, 383,-32766,-32766, 327,-32766, 319, 222, 331,-32766, - 256, 34, 254, 497, 904, 529, 99, 100, 101,-32766, - 230, 687,-32766,-32766,-32766, 115,-32766, 245,-32766, 342, - -32766, 223, 116,-32766,-32766,-32766, 122,-32766,-32766,-32766, - 782,-32766,-32766,-32766, 208, 235,-32766, 529, 126,-32766, - 382,-32766, 445, 593,-32766,-32766,-32766,-32766,-32766, 189, - -32766, 114,-32766, 256, 185,-32766, 183, -113, 123,-32766, - -32766,-32766, 849, 113,-32766,-32766, 350, 28,-32766, 354, - 462,-32766, 382, 184, 679, 838,-32766,-32766, 520,-32766, - 582, 782, 513,-32766, 127, 284, 471, 472, 514, 529, - 302, 535, 505,-32766, 522, 121,-32766,-32766,-32766, 510, - -32766, 503,-32766, 501,-32766, 125, 480,-32766,-32766,-32766, - 230,-32766,-32766,-32766, 591, 326,-32766,-32766, 673, 519, - -32766, 649, 650,-32766, 382, 52, 365, 366, 49, 684, - 524,-32766, 221, 55,-32766, 554, 596, 370, 371, 476, - 529, 841, 229, 339,-32766, 530, 207,-32766,-32766,-32766, - 467,-32766, 545,-32766, 263,-32766, 543, 529,-32766, 393, - -32766,-32766,-32766,-32766,-32766, 681,-32766,-32766,-32766, 496, - 485,-32766, 529, 408,-32766, 382,-32766, 336, 338,-32766, - -32766,-32766,-32766,-32766, 469,-32766, 782,-32766, 395, 407, - -32766, 396, 909, 394,-32766,-32766,-32766, 795, -161,-32766, - -32766, 473, 487,-32766, 226, 335,-32766, 382, 262, 326, - 316,-32766,-32766, 326,-32766, 904, 274, 450, 782, -158, - 365, 366, 409, 438, 365, 366, 465, 255, 252, 534, - 596, 370, 371, 554, 596, 370, 371, 356, 415,-32766, - 253, -287, 296,-32766,-32766, 529, 257, 651, 30,-32766, - 598, 260,-32766,-32766,-32766, 597,-32766, 536,-32766, -345, - -32766, 508, 243,-32766, -344, 241, 0,-32766,-32766,-32766, - 782,-32766,-32766,-32766, 42, 188,-32766, 529, 117,-32766, - 382,-32766, 837, -278,-32766,-32766,-32766,-32766,-32766, 45, - -32766, 493,-32766, -286, 248,-32766, 456, 247, 259,-32766, - -32766,-32766, 782, 401,-32766,-32766, 337, 334,-32766, 506, - 44,-32766, 382, 539, 677, 680,-32766,-32766, 571,-32766, - 507, 568, 581,-32766, 608, 610, 612, 559, 574, 529, - 627, 580, 618,-32766, 619, 567,-32766,-32766,-32766, 557, - -32766, 565,-32766, 563,-32766, 678, 573,-32766, 562,-32766, - 670,-32766,-32766,-32766, 504,-32766,-32766,-32766, 517, 521, - -32766, 529, 77,-32766, 382,-32766, 523, 516,-32766,-32766, - -32766,-32766,-32766, 511,-32766, 509,-32766, 120, 499,-32766, - 518, 234, 353,-32766,-32766,-32766, 878, 326,-32766,-32766, - 888, 910,-32766, 817, 880,-32766, 382, 912, 365, 366, - 566,-32766, 233,-32766, 913, 868,-32766, 554, 596, 370, - 371, 882, 529, 884, 616, 617,-32766, 662, 761,-32766, - -32766,-32766, 318,-32766, 232,-32766, 231,-32766, 219,-32766, - -32766, 314, 564,-32766,-32766,-32766,-32766, 215,-32766,-32766, - -32766, 214, 210,-32766, 529, 209,-32766, 382,-32766, 181, - 76,-32766,-32766,-32766,-32766,-32766, 48,-32766, 43,-32766, - 33, 32,-32766, 186, 187, 844,-32766,-32766,-32766, 653, - 778,-32766,-32766, 762, 786,-32766, 492, 466,-32766, 382, - 430, 355, 180,-32766,-32766, 351,-32766, 819, 326, 316, - 826, 827, 303, 285,-32766, 274, 439, 893, 828, 365, - 366,-32766,-32766,-32766, 790, 785, -113, 25, 534, 596, - 370, 371,-32766,-32766,-32766,-32766,-32766, 24,-32766, 780, - -32766,-32766,-32766,-32766,-32766, 23, -114, 0, 0,-32766, - 260,-32766,-32766,-32766,-32766, 474, 537, 862, 845, 908, - 0, 816, 879, 863, 867, 881, 435, 801, 832, 833, - 834, 835, 829, 830, 305, 779, 0, 0, 326, 0, - 836, 831, 326, 0, 0, 0,-32766, 0,-32766, 365, - 366, 0, 0, 365, 366, 326, 0, 0, 554, 596, - 370, 371, 554, 596, 370, 371, 365, 366, 0, 0, - 0, 326, 0, 0, 0, 554, 596, 370, 371, 0, - 0, 0, 365, 366, 326, 0, 592, 447, 326, 0, - 685, 554, 596, 370, 371, 365, 366, 0, 0, 365, - 366, 0, 326, 585, 554, 596, 370, 371, 554, 596, - 370, 371, 0, 365, 366, 495, 0, 0, 0, 784, - 0, 0, 554, 596, 370, 371, 0, 0, 326, 0, - 486, 0, 587, 0, 0, 0, 783, 0, 0, 365, - 366, 326, 0, 0, 0, 0, 0, 0, 554, 596, - 370, 371, 365, 366,-32766,-32766,-32766, 0, 0, 0, - 0, 554, 596, 370, 371, 0, 0, 0, 0, 0, - 0,-32766, 0,-32766,-32766,-32766 + 59, 60, 325, 61, 62,-32766,-32766,-32766, 351, 63, + 64,-32767,-32767,-32767,-32767, 97, 98, 99, 100, 101, + 57, 464,-32766, 297,-32766,-32766, 41, 105, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 267, 360, + 65, 66, 928, 497, 930, 929, 67, 538, 68, 219, + 220, 69, 70, 71, 72, 73, 74, 75, 76, 31, + 232, 77, 318, 326, 733, 735, 918, 840, 841, 362, + 324, 897, 340, 581, 509, 363, 46, 27, 327, 852, + 364, 245, 365, 456, 366, 39, 223, 328,-32766,-32766, + -32766, 36, 37, 367, 333, 280, 38, 368, 329, 425, + 78, 185, 121, 278, 279,-32766, 286,-32766, 35, 369, + 370, 371, 372, 373, 389, 343, 683, 330, 563, 605, + 374, 375, 376, 377, 863, 846, 847, 848, 849, 843, + 844, 239, 81, 82, 83, -349, 389, 850, 845, 330, + 587, 507, 346, 47, 227, 259, 243, 22, 247, 40, + 669, 84, 85, 86, 87, 88, 89, 90, 91, 92, + 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, + 103, 104, 791, 233, 678,-32766,-32766,-32766, 704, 705, + 706, 703, 702, 701, 633, 0,-32766,-32766,-32766, 658, + 659, 214,-32766, 122,-32766,-32766,-32766,-32766,-32766,-32767, + -32767,-32767,-32767,-32766, 791, 322, 329, 319, 350, 806, + -117, 257, 127, 277,-32766,-32766,-32766, 369, 370, 891, + 696, 261, 897, 221, 216,-32766, 543, 605, 374, 375, + 547, 538, 344, 215, 538,-32766, 897, 376,-32766,-32766, + -32766, 578,-32766, 54,-32766, 322,-32766, 661, 263,-32766, + 56, 257, 604,-32766,-32766,-32766, 791,-32766,-32766,-32766, + 696, 34,-32766, 538, 348,-32766, 388,-32766, 345, 816, + -32766,-32766,-32766,-32766,-32766, 224,-32766, 579,-32766, 53, + 125,-32766, 99, 100, 101,-32766,-32766,-32766, 791, 918, + -32766,-32766, 603, 268,-32766, 925, 259,-32766, 388, 226, + 634, 389,-32766,-32766, 330,-32766, 322, 225, 334,-32766, + 259, 238, 257, 901, 248, 538, 102, 103, 104,-32766, + 233, 696,-32766,-32766,-32766, 118,-32766, 506,-32766,-32766, + -32766, 187, 119,-32766,-32766,-32766, 125,-32766,-32766,-32766, + 791,-32766,-32766,-32766, 211, 188,-32766, 538, 129,-32766, + 388,-32766, 454, 602,-32766,-32766,-32766,-32766,-32766, 192, + -32766, 117,-32766, 862, 186,-32766, 116, -113, 193,-32766, + -32766,-32766, 852, 519,-32766,-32766,-32766,-32766,-32766, 353, + 28,-32766, 388, 357, 471, 126,-32766,-32766, 531,-32766, + 523, 791, 522,-32766, 130, 287, 480, 481, 688, 538, + 305, 544, 514,-32766, 529, 124,-32766,-32766,-32766, 512, + -32766, 591,-32766, 510,-32766, 128, 489,-32766,-32766,-32766, + 233,-32766,-32766,-32766, 600, 329,-32766,-32766, 682, 528, + -32766, 658, 659,-32766, 388, 52, 369, 370, 55, 693, + 533,-32766, 224, 51,-32766, 563, 605, 374, 375, 50, + 538, 58, 49, 496,-32766, 494, 232,-32766,-32766,-32766, + 485,-32766, 265,-32766, 210,-32766, 552, 414,-32766, 402, + -32766,-32766,-32766,-32766,-32766, 554,-32766,-32766,-32766, 855, + 539,-32766, 538, 538,-32766, 388,-32766, 505, 400,-32766, + -32766,-32766,-32766,-32766, 482,-32766, 791,-32766, 478, 339, + -32766, 341, 415, 690,-32766,-32766,-32766, 399, 923,-32766, + -32766, 809, 401,-32766, -161, 342,-32766, 388, 918, 329, + 319,-32766,-32766, 329,-32766, 266, 277, 476, 791, 338, + 369, 370, 416, 229, 369, 370, -158, 474, 447, 543, + 605, 374, 375, 563, 605, 374, 375, 459, 359,-32766, + 258, 606, 120,-32766,-32766, 538, 851, 660, 80,-32766, + 607, 263,-32766,-32766,-32766, 30,-32766, 545,-32766, 508, + -32766, 564, 256,-32766, 260, 255, 191,-32766,-32766,-32766, + 791,-32766,-32766,-32766, 244, -349,-32766, 538, 246,-32766, + 388,-32766, -350, 422,-32766,-32766,-32766,-32766,-32766, 42, + -32766, 465,-32766, 45, -292,-32766, 337, 789, 250,-32766, + -32766,-32766, 791, 407,-32766,-32766, -283, 502,-32766, 299, + 251,-32766, 388, -291, 513, 0,-32766,-32766, 340,-32766, + 590, 574, 572,-32766, 568, 582, 589, 583, 576, 538, + 636, 627, 628,-32766, 566, 689,-32766,-32766,-32766, 580, + -32766, 686,-32766, 548,-32766, 577, 687,-32766, 571,-32766, + 621,-32766,-32766,-32766, 44,-32766,-32766,-32766, 515, 619, + -32766, 538, 516,-32766, 388,-32766, 617, 679,-32766,-32766, + -32766,-32766,-32766, 518,-32766, 520,-32766, 525, 526,-32766, + 530, 532, 123,-32766,-32766,-32766, 527, 329,-32766,-32766, + 892, 902,-32766, 671, 831,-32766, 388, 894, 369, 370, + 575,-32766, 321,-32766, 882, 896,-32766, 563, 605, 374, + 375, 898, 538, 626, 926, 927,-32766, 625, 924,-32766, + -32766,-32766, 356,-32766,-32766,-32766, 317,-32766, 235, 234, + -32766, 222, 573,-32766,-32766,-32766,-32766, 236,-32766,-32766, + -32766, 218, 217,-32766, 538, 213,-32766, 388,-32766, 262, + 212,-32766,-32766,-32766,-32766,-32766, 237,-32766, 184,-32766, + 79, 48,-32766, 189, 190, 43,-32766,-32766,-32766, 33, + 32,-32766,-32766, -114, 858,-32766, 662, 798,-32766, 388, + 771, 795, 183,-32766,-32766, 501,-32766, 833, 329, 319, + 840, 841, 475, 439,-32766, 277, 358, 354, 842, 369, + 370,-32766,-32766,-32766, 306, 288, 25, 24, 543, 605, + 374, 375,-32766,-32766,-32766,-32766,-32766, 23,-32766, 483, + -32766,-32766,-32766,-32766,-32766, 794, 770, 448, 907,-32766, + 263,-32766,-32766,-32766,-32766, 804, 546, -113, 0, 876, + 0, 0, 859, 922, 830, 893, 444, 877, 846, 847, + 848, 849, 843, 844, 308, 881, 895, 815, 329, 802, + 850, 845, 329, 800, 801, 799,-32766, 0,-32766, 369, + 370, 0, 0, 369, 370, 329, 0, 0, 563, 605, + 374, 375, 563, 605, 374, 375, 369, 370, 0, 0, + 0, 329, 0, 0, 0, 563, 605, 374, 375, 0, + 0, 0, 369, 370, 329, 0, 517, 0, 329, 0, + 601, 563, 605, 374, 375, 369, 370, 0, 0, 369, + 370, 329, 0, 694, 563, 605, 374, 375, 563, 605, + 374, 375, 369, 370, 0, 0, 0, 504, 0, 594, + 0, 563, 605, 374, 375, 0,-32766,-32766,-32766, 0, + 329, 0, 793, 495, 0, 0, 596, 0, 0, 0, + 0, 369, 370,-32766, 329,-32766,-32766,-32766, 0, 792, + 563, 605, 374, 375, 0, 369, 370, 0, 0, 0, + 0, 0, 0, 0, 563, 605, 374, 375 ); protected static $yycheck = array( - 2, 3, 4, 5, 6, 8, 9, 10, 26, 11, + 2, 3, 4, 5, 6, 8, 9, 10, 7, 11, 12, 36, 37, 38, 39, 40, 41, 42, 43, 44, 61, 76, 25, 73, 27, 28, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 61, 7, 42, 43, 71, 71, 73, 74, 48, 71, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 51, 52, 0, 69, 70, 71, + 62, 63, 64, 65, 51, 52, 76, 69, 70, 71, 7, 73, 141, 75, 143, 77, 78, 79, 80, 134, - 82, 122, 84, 7, 86, 135, 136, 89, 8, 9, + 82, 122, 84, 81, 86, 135, 136, 89, 8, 9, 10, 93, 94, 95, 96, 7, 98, 99, 96, 122, - 102, 61, 143, 105, 106, 25, 7, 27, 7, 107, + 102, 7, 143, 105, 106, 25, 7, 27, 7, 107, 108, 113, 114, 115, 138, 26, 144, 141, 116, 117, - 118, 119, 124, 125, 142, 127, 128, 129, 130, 131, + 118, 119, 124, 125, 134, 127, 128, 129, 130, 131, 132, 133, 8, 9, 10, 122, 138, 139, 140, 141, - 142, 143, 7, 145, 31, 147, 144, 149, 150, 25, + 142, 143, 7, 145, 31, 147, 148, 146, 150, 25, 73, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 12, 49, 142, 8, 9, 10, 106, 107, - 108, 109, 110, 111, 144, 8, 8, 9, 10, 125, + 108, 109, 110, 111, 26, 0, 8, 9, 10, 125, 126, 31, 25, 7, 27, 28, 29, 30, 31, 32, 33, 34, 35, 25, 12, 97, 96, 97, 71, 146, - 146, 103, 13, 103, 8, 9, 10, 107, 108, 73, - 112, 76, 146, 31, 147, 65, 116, 117, 118, 119, + 146, 103, 61, 103, 8, 9, 10, 107, 108, 73, + 112, 7, 73, 31, 147, 65, 116, 117, 118, 119, 142, 71, 143, 7, 71, 75, 73, 124, 78, 79, 80, 142, 82, 61, 84, 97, 86, 146, 138, 89, 61, 103, 144, 93, 94, 95, 12, 65, 98, 99, 112, 7, 102, 71, 71, 105, 106, 75, 7, 106, 78, 79, 80, 113, 82, 31, 84, 142, 86, 61, - 143, 89, 42, 43, 44, 93, 94, 95, 12, 73, - 98, 99, 144, 147, 102, 150, 71, 105, 106, 8, - 9, 138, 142, 143, 141, 113, 97, 31, 145, 65, + 143, 89, 42, 43, 44, 93, 94, 95, 12, 76, + 98, 99, 144, 147, 102, 144, 147, 105, 106, 7, + 142, 138, 142, 143, 141, 113, 97, 31, 145, 65, 147, 7, 103, 71, 76, 71, 45, 46, 47, 75, - 49, 112, 78, 79, 80, 143, 82, 76, 84, 7, - 86, 7, 143, 89, 142, 143, 143, 93, 94, 95, - 12, 65, 98, 99, 123, 7, 102, 71, 143, 105, + 49, 112, 78, 79, 80, 143, 82, 71, 84, 8, + 86, 13, 143, 89, 142, 143, 143, 93, 94, 95, + 12, 65, 98, 99, 123, 13, 102, 71, 143, 105, 106, 75, 147, 144, 78, 79, 80, 113, 82, 13, - 84, 143, 86, 147, 13, 89, 13, 146, 143, 93, - 94, 95, 134, 13, 98, 99, 66, 67, 102, 66, - 67, 105, 106, 13, 142, 134, 142, 143, 26, 113, - 26, 12, 26, 65, 91, 92, 100, 101, 26, 71, + 84, 143, 86, 150, 13, 89, 13, 146, 13, 93, + 94, 95, 134, 26, 98, 99, 8, 9, 102, 66, + 67, 105, 106, 66, 67, 143, 142, 143, 26, 113, + 26, 12, 26, 65, 91, 92, 100, 101, 142, 71, 72, 142, 143, 75, 26, 26, 78, 79, 80, 26, 82, 26, 84, 26, 86, 26, 87, 89, 142, 143, 49, 93, 94, 95, 31, 96, 98, 99, 142, 143, 102, 125, 126, 105, 106, 61, 107, 108, 61, 142, - 143, 113, 31, 61, 65, 116, 117, 118, 119, 68, - 71, 71, 62, 80, 75, 71, 88, 78, 79, 80, - 103, 82, 71, 84, 76, 86, 71, 71, 89, 71, + 143, 113, 31, 61, 65, 116, 117, 118, 119, 61, + 71, 61, 61, 73, 75, 71, 62, 78, 79, 80, + 68, 82, 76, 84, 88, 86, 71, 71, 89, 71, 142, 143, 93, 94, 95, 71, 65, 98, 99, 71, 71, 102, 71, 71, 105, 106, 75, 71, 71, 78, 79, 80, 113, 82, 73, 84, 12, 86, 73, 71, - 89, 71, 71, 71, 93, 94, 95, 73, 73, 98, - 99, 73, 73, 102, 88, 96, 105, 106, 76, 96, - 97, 142, 143, 96, 113, 76, 103, 90, 12, 88, - 107, 108, 88, 88, 107, 108, 90, 104, 120, 116, - 117, 118, 119, 116, 117, 118, 119, 96, 124, 65, - 121, 137, 137, 142, 143, 71, 120, 146, 145, 75, - 117, 138, 78, 79, 80, 117, 82, 144, 84, 122, - 86, 144, 122, 89, 122, 122, -1, 93, 94, 95, - 12, 65, 98, 99, 123, 123, 102, 71, 123, 105, - 106, 75, 134, 137, 78, 79, 80, 113, 82, 142, - 84, 137, 86, 137, 137, 89, 137, 137, 145, 93, - 94, 95, 12, 141, 98, 99, 141, 141, 102, 142, - 142, 105, 106, 142, 142, 142, 142, 143, 142, 113, + 89, 71, 71, 71, 93, 94, 95, 71, 71, 98, + 99, 73, 73, 102, 73, 80, 105, 106, 76, 96, + 97, 142, 143, 96, 113, 76, 103, 103, 12, 96, + 107, 108, 88, 88, 107, 108, 88, 90, 88, 116, + 117, 118, 119, 116, 117, 118, 119, 90, 96, 65, + 104, 117, 123, 142, 143, 71, 134, 146, 143, 75, + 117, 138, 78, 79, 80, 145, 82, 144, 84, 143, + 86, 144, 121, 89, 120, 120, 123, 93, 94, 95, + 12, 65, 98, 99, 122, 122, 102, 71, 122, 105, + 106, 75, 122, 124, 78, 79, 80, 113, 82, 123, + 84, 137, 86, 142, 137, 89, 141, 148, 137, 93, + 94, 95, 12, 141, 98, 99, 137, 137, 102, 137, + 137, 105, 106, 137, 143, -1, 142, 143, 141, 113, 142, 142, 142, 65, 142, 142, 142, 142, 142, 71, 142, 142, 142, 75, 142, 142, 78, 79, 80, 142, 82, 142, 84, 142, 86, 142, 142, 89, 142, 143, - 142, 93, 94, 95, 143, 65, 98, 99, 143, 143, - 102, 71, 143, 105, 106, 75, 143, 143, 78, 79, + 142, 93, 94, 95, 142, 65, 98, 99, 142, 142, + 102, 71, 142, 105, 106, 75, 142, 142, 78, 79, 80, 113, 82, 143, 84, 143, 86, 143, 143, 89, - 143, 145, 144, 93, 94, 95, 144, 96, 98, 99, + 143, 143, 143, 93, 94, 95, 143, 96, 98, 99, 144, 144, 102, 144, 144, 105, 106, 144, 107, 108, 142, 143, 145, 113, 144, 144, 65, 116, 117, 118, - 119, 144, 71, 144, 144, 144, 75, 144, 146, 78, - 79, 80, 145, 82, 145, 84, 145, 86, 145, 145, + 119, 144, 71, 144, 144, 144, 75, 144, 144, 78, + 79, 80, 144, 82, 145, 84, 145, 86, 145, 145, 89, 145, 142, 143, 93, 94, 95, 145, 65, 98, 99, 145, 145, 102, 71, 145, 105, 106, 75, 145, 145, 78, 79, 80, 113, 82, 145, 84, 145, 86, - 145, 145, 89, 42, 43, 146, 93, 94, 95, 146, - 146, 98, 99, 146, 146, 102, 146, 146, 105, 106, + 145, 145, 89, 42, 43, 145, 93, 94, 95, 145, + 145, 98, 99, 146, 146, 102, 146, 146, 105, 106, 146, 146, 61, 142, 143, 146, 113, 146, 96, 97, 69, 70, 146, 146, 73, 103, 146, 146, 77, 107, 108, 8, 9, 10, 146, 146, 146, 146, 116, 117, 118, 119, 8, 9, 10, 142, 143, 146, 25, 149, - 27, 28, 29, 30, 31, 146, 146, -1, -1, 25, - 138, 27, 28, 29, 30, 148, 144, 148, 148, 148, - -1, 148, 148, 148, 148, 148, 125, 148, 127, 128, - 129, 130, 131, 132, 133, 148, -1, -1, 96, -1, - 139, 140, 96, -1, -1, -1, 145, -1, 147, 107, + 27, 28, 29, 30, 31, 146, 146, 146, 146, 25, + 138, 27, 28, 29, 30, 146, 144, 146, -1, 149, + -1, -1, 149, 149, 149, 149, 125, 149, 127, 128, + 129, 130, 131, 132, 133, 149, 149, 149, 96, 149, + 139, 140, 96, 149, 149, 149, 145, -1, 147, 107, 108, -1, -1, 107, 108, 96, -1, -1, 116, 117, 118, 119, 116, 117, 118, 119, 107, 108, -1, -1, -1, 96, -1, -1, -1, 116, 117, 118, 119, -1, - -1, -1, 107, 108, 96, -1, 144, 81, 96, -1, + -1, -1, 107, 108, 96, -1, 144, -1, 96, -1, 144, 116, 117, 118, 119, 107, 108, -1, -1, 107, - 108, -1, 96, 144, 116, 117, 118, 119, 116, 117, - 118, 119, -1, 107, 108, 83, -1, -1, -1, 144, - -1, -1, 116, 117, 118, 119, -1, -1, 96, -1, - 85, -1, 144, -1, -1, -1, 144, -1, -1, 107, - 108, 96, -1, -1, -1, -1, -1, -1, 116, 117, - 118, 119, 107, 108, 8, 9, 10, -1, -1, -1, - -1, 116, 117, 118, 119, -1, -1, -1, -1, -1, - -1, 25, -1, 27, 28, 29 + 108, 96, -1, 144, 116, 117, 118, 119, 116, 117, + 118, 119, 107, 108, -1, -1, -1, 83, -1, 144, + -1, 116, 117, 118, 119, -1, 8, 9, 10, -1, + 96, -1, 144, 85, -1, -1, 144, -1, -1, -1, + -1, 107, 108, 25, 96, 27, 28, 29, -1, 144, + 116, 117, 118, 119, -1, 107, 108, -1, -1, -1, + -1, -1, -1, -1, 116, 117, 118, 119 ); protected static $yybase = array( - 0, 702, 423, 110, 2, 427, 836, 329, 875, 772, - 822, 818, 805, 862, 789, 776, 601, 601, 601, 601, - 601, 385, 383, 372, 378, 372, 387, -2, -2, -2, + 0, 702, 423, 110, 427, 772, 2, 329, 878, 776, + 835, 822, 818, 864, 805, 789, 601, 601, 601, 601, + 601, 383, 347, 364, 362, 364, 387, -2, -2, -2, 411, 192, 192, 651, 192, 244, 516, 600, 568, 328, 379, 160, 276, 484, 484, 484, 484, 683, 683, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, @@ -576,50 +574,51 @@ class PHPParser_Parser 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, - 484, 484, 484, 484, 484, 484, 484, 484, -18, 514, - 465, 461, 511, 509, 503, 499, 669, 368, 557, 579, - 389, 577, 571, 560, 559, 583, 548, 556, 697, 552, - 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, - 177, 291, 206, 206, 206, 206, 206, 206, 206, 206, - 206, 206, 206, 206, 206, 206, 206, 178, 178, 80, - 731, 731, 731, 731, 731, 731, 731, 731, 731, 731, - 731, -3, 976, 814, 803, 167, 167, 167, 167, 13, - -25, -25, -25, -25, 108, 148, 209, 113, 113, 424, - 424, 390, 424, 544, 163, 163, 163, 163, 163, 163, - 163, 163, 163, 163, 163, 435, 408, 240, 240, 594, - 594, 64, 64, 64, 64, 306, 251, 238, 145, -28, - 442, 225, 225, 225, 388, 458, 449, 193, 137, 271, - 271, 271, -24, -24, -24, -24, 529, -24, -24, -24, - -69, 182, -50, -50, -29, 205, 437, 580, 446, 581, - 286, 414, -41, 259, 476, 77, 419, 476, 310, 313, - 296, 456, 89, 77, -18, 297, 189, 486, 412, 481, - 444, 88, 99, 135, -23, 218, 146, 63, 445, 660, - 582, 668, 40, 447, 101, -55, 218, 221, 661, 518, - 32, 76, 482, 242, 393, 625, 432, 413, 428, 432, - 438, 393, 621, 621, 621, 621, 393, 396, 413, 413, - 393, 390, 413, 304, 396, 393, 418, 396, 436, 621, - 477, 488, 432, 425, 429, 413, 413, 413, 428, 393, - 621, 357, 186, 413, 621, 357, 393, 438, 66, 364, - 623, 615, 587, 398, 545, 448, 443, 606, 602, 593, - 430, 416, 610, 626, 472, 489, 417, 360, 377, 470, - 374, 453, 419, 475, 371, 452, 467, 452, 717, 415, - 466, 450, 373, 490, 353, 370, 521, 472, 638, 656, - 680, 384, 591, 644, 452, 478, 254, 351, 589, 395, - 452, 567, 452, 637, 542, 607, 452, 634, 431, 570, - 472, 371, 371, 371, 633, 709, 707, 706, 705, 704, - 382, 703, 495, 649, 338, 614, 456, 469, 391, 496, - 226, 701, 452, 452, 540, 529, 452, 498, 457, 689, - 500, 641, 421, 462, 700, 458, 380, 645, 452, 451, - 699, 226, 366, 381, 690, 502, 534, 596, 525, 346, - 629, 463, 547, 199, 563, 362, 507, 681, 671, 670, - 494, 526, 409, 434, 439, 546, 493, 640, 441, 464, - 433, 426, 533, 404, 657, 492, 483, 513, 0, 0, + 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, + 484, 158, 493, 429, 476, 490, 489, 496, 494, 689, + 376, 584, 577, 389, 571, 570, 563, 560, 559, 588, + 557, 680, 556, 124, 124, 124, 124, 124, 124, 124, + 124, 124, 124, 321, 368, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 178, 178, 80, 731, 731, 731, 731, 731, 731, 731, + 731, 731, 731, 731, -3, 948, 814, 803, 167, 167, + 167, 167, 13, -25, -25, -25, -25, 108, 148, 209, + 113, 113, 469, 469, 394, 469, 549, 163, 163, 163, + 163, 163, 163, 163, 163, 163, 163, 163, 441, 416, + 240, 240, 589, 589, 64, 64, 64, 64, 306, 238, + -10, 213, -28, 386, 242, 242, 242, 449, 422, 442, + 193, 137, 271, 271, 271, -24, -24, -24, -24, 415, + -24, -24, -24, -69, 182, -50, -50, -29, 205, 457, + 583, 447, 579, 286, 467, -41, 259, 465, 77, 433, + 465, 313, 317, 296, 479, 89, 77, 158, 297, 189, + 507, 431, 511, 444, 88, 99, 135, -23, 218, 146, + 1, 450, 691, 690, 699, 151, 470, 101, -55, 218, + 221, 692, 535, 32, 63, 509, 256, 393, 634, 417, + 420, 396, 417, 421, 393, 626, 626, 626, 626, 393, + 412, 420, 420, 393, 394, 420, 254, 412, 393, 455, + 412, 454, 626, 526, 530, 417, 439, 451, 420, 420, + 420, 396, 393, 626, 424, 94, 420, 626, 424, 393, + 421, 185, 385, 391, 630, 625, 567, 436, 426, 434, + 443, 607, 606, 596, 398, 428, 615, 635, 472, 513, + 430, 353, 388, 382, 374, 471, 377, 462, 433, 487, + 371, 463, 483, 463, 726, 482, 486, 466, 435, 488, + 351, 318, 481, 472, 645, 668, 459, 409, 594, 657, + 463, 725, 522, 186, 332, 593, 395, 463, 602, 463, + 644, 540, 610, 463, 641, 437, 581, 472, 371, 371, + 371, 640, 724, 720, 718, 717, 716, 708, 706, 390, + 705, 492, 661, 304, 623, 479, 464, 404, 495, 214, + 704, 463, 463, 542, 415, 463, 498, 461, 681, 499, + 656, 425, 453, 703, 422, 408, 660, 463, 452, 700, + 214, 366, 392, 637, 500, 544, 591, 545, 346, 638, + 614, 553, 355, 580, 378, 502, 671, 670, 701, 518, + 547, 384, 438, 380, 621, 527, 649, 448, 480, 446, + 445, 548, 432, 669, 534, 503, 514, 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, 0, 0, 0, -2, -2, -2, -2, + 0, 0, 0, 0, 0, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, - -2, -2, 0, 0, 0, -2, -2, -2, -2, -2, + -2, 0, 0, 0, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, @@ -629,125 +628,127 @@ class PHPParser_Parser -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, - -2, -2, -2, 124, 124, 124, 124, 124, 124, 124, + -2, -2, -2, -2, -2, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, - 124, 124, 124, 124, 124, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 124, 124, 124, 124, 124, + 124, 124, 124, 124, 124, 124, 124, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, - 124, 124, 124, 124, 124, 163, 163, 163, 163, 163, - 163, 163, 163, 163, 163, 163, 124, 124, 124, 124, - 124, 124, 124, 124, 0, 271, 271, 271, 271, 72, - 72, 72, 163, 163, 163, 163, 163, 163, 163, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 72, 72, 271, 271, 163, 163, -24, -24, -24, -24, - -24, -50, -50, -50, -24, -50, 216, 216, 216, -50, - -50, -50, 146, 146, 0, 0, 0, 0, 0, 0, - 0, 216, 0, 0, 0, 396, 413, 0, 0, 0, - 216, 303, 303, 303, 303, 226, 218, 0, 472, 396, - 0, 425, 396, 0, 0, 0, 413, 0, 0, 0, - 0, 0, 254, 591, 322, 472, 0, 0, 0, 0, - 0, 0, 0, 472, 324, 324, 261, 0, 382, 0, - 0, 0, 0, 261, 322, 0, 0, 226 + 124, 124, 124, 124, 124, 124, 124, 163, 163, 163, + 163, 163, 163, 163, 163, 163, 163, 163, 124, 124, + 124, 124, 124, 124, 124, 124, 0, 271, 271, 271, + 271, 72, 72, 72, 163, 163, 163, 163, 163, 163, + 163, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 72, 72, 271, 271, 163, 163, -24, -24, + -24, -24, -24, -50, -50, -50, -24, -50, 149, 149, + 149, -50, -50, -50, 146, 146, 0, 0, 0, 0, + 0, 0, 0, 149, 0, 0, 0, 412, 420, 0, + 0, 0, 149, 303, 303, 303, 303, 214, 218, 0, + 472, 412, 0, 439, 412, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 186, 594, 261, 472, 0, 0, + 0, 0, 0, 0, 0, 472, 292, 292, 226, 0, + 390, 0, 0, 0, 0, 226, 261, 0, 0, 214 ); protected static $yydefault = array( 3,32767,32767, 1,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767, 106, 98, 112, 97, 108,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767, 370, 370,32767, 328,32767,32767,32767,32767,32767, - 32767,32767,32767, 179, 179, 179,32767,32767,32767, 360, - 360, 360, 360, 360, 360, 360,32767,32767,32767,32767, - 32767, 257,32767,32767,32767,32767,32767,32767,32767,32767, + 32767, 375, 375,32767, 333,32767,32767,32767,32767,32767, + 32767,32767,32767, 179, 179, 179,32767,32767,32767, 365, + 365, 365, 365, 365, 365, 365, 365, 365, 365,32767, + 32767,32767,32767,32767, 257,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 262, 375,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767, 262, 380,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 238, 239, 241, 242, 178, 131, 361, 263, 374, 177, - 205, 207, 256, 206, 183, 188, 189, 190, 191, 192, - 193, 194, 195, 196, 197, 198, 182, 235, 234, 203, - 325, 325, 328,32767,32767,32767,32767,32767,32767,32767, - 32767, 204, 208, 210, 209, 225, 226, 223, 224, 181, - 227, 228, 229, 230, 163, 163, 163,32767,32767, 369, - 369,32767, 369,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767, 164,32767, 217, 218, 288, - 288, 122, 122, 122, 122, 122,32767,32767,32767,32767, - 296,32767,32767,32767,32767,32767, 298,32767,32767, 212, - 213, 211,32767,32767,32767,32767,32767,32767,32767,32767, - 32767, 333, 297,32767,32767,32767,32767,32767,32767,32767, - 32767, 346, 284,32767,32767,32767, 277,32767, 109, 111, - 61, 314,32767,32767,32767,32767, 351,32767,32767,32767, - 17,32767,32767,32767, 382, 346,32767,32767, 19,32767, - 32767,32767,32767, 233,32767,32767, 350, 344,32767,32767, - 32767,32767,32767,32767, 65, 293,32767, 299,32767,32767, - 32767, 65,32767,32767,32767,32767, 65,32767, 349, 348, - 65,32767, 278, 327,32767, 65, 76,32767, 74,32767, - 95, 95,32767,32767, 78, 322, 339,32767,32767, 65, - 32767, 266, 327,32767,32767, 266, 65,32767,32767, 4, - 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 279,32767,32767,32767, 335,32767, - 336,32767, 277,32767, 221, 200,32767, 202,32767,32767, - 282, 285,32767,32767,32767, 140,32767, 280,32767, 186, - 32767,32767,32767,32767, 377,32767, 180,32767,32767,32767, - 136,32767, 63, 344,32767,32767, 367,32767,32767, 344, - 281, 214, 215, 216,32767,32767,32767,32767,32767,32767, - 345,32767,32767,32767, 116,32767, 314,32767,32767,32767, - 77,32767, 184, 132,32767,32767, 376,32767,32767,32767, - 32767,32767,32767, 332,32767,32767,32767,32767, 64,32767, - 32767, 79,32767,32767, 344,32767,32767,32767,32767, 120, - 32767,32767,32767, 175,32767,32767,32767,32767,32767, 344, - 32767,32767,32767,32767,32767,32767,32767,32767, 4,32767, - 157,32767,32767,32767,32767,32767,32767,32767, 25, 25, - 3, 25, 103, 25, 143, 3, 95, 95, 58, 143, - 25, 143, 25, 25, 25, 25, 25, 25, 25, 150, - 25, 25, 25, 25, 25 + 32767,32767,32767, 238, 239, 241, 242, 178, 366, 131, + 263, 379, 177, 205, 207, 256, 206, 183, 188, 189, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 182, + 235, 234, 203, 330, 330, 333,32767,32767,32767,32767, + 32767,32767,32767,32767, 204, 208, 210, 209, 225, 226, + 223, 224, 181, 227, 228, 229, 230, 163, 163, 163, + 32767,32767, 374, 374,32767, 374,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767, 164,32767, + 217, 218, 293, 293, 122, 122, 122, 122, 122,32767, + 32767,32767,32767, 301,32767,32767,32767,32767,32767, 303, + 32767,32767, 212, 213, 211,32767,32767,32767,32767,32767, + 32767,32767,32767,32767, 338, 302,32767,32767,32767,32767, + 32767,32767,32767,32767, 351, 289,32767,32767,32767, 282, + 32767, 109, 111, 61, 319,32767,32767,32767,32767, 356, + 32767,32767,32767, 17,32767,32767,32767, 387, 351,32767, + 32767, 19,32767,32767,32767,32767, 233,32767,32767, 355, + 349,32767,32767,32767,32767,32767,32767, 65, 298,32767, + 304,32767,32767,32767, 65,32767,32767,32767,32767, 65, + 32767, 354, 353, 65,32767, 283, 332,32767, 65, 76, + 32767, 74,32767, 95, 95,32767,32767, 78, 327, 344, + 32767,32767, 65,32767, 271, 332,32767,32767, 271, 65, + 32767,32767, 4, 308,32767,32767,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767, 284,32767, + 32767,32767, 253, 254, 340,32767, 341,32767, 282,32767, + 221, 200,32767, 202,32767,32767, 287, 290,32767,32767, + 32767, 140,32767, 285,32767, 186,32767,32767,32767,32767, + 382,32767,32767, 180,32767,32767,32767, 136,32767, 63, + 349,32767,32767, 372,32767,32767, 349, 286, 214, 215, + 216,32767,32767,32767,32767,32767,32767,32767,32767, 350, + 32767,32767,32767, 116,32767, 319,32767,32767,32767, 77, + 32767, 184, 132,32767,32767, 381,32767,32767,32767,32767, + 32767,32767, 337,32767,32767,32767,32767, 64,32767,32767, + 79,32767,32767, 349,32767,32767,32767,32767, 120,32767, + 32767,32767, 175,32767,32767,32767,32767,32767, 349,32767, + 32767,32767,32767,32767,32767,32767,32767, 4,32767, 157, + 32767,32767,32767,32767,32767,32767,32767, 25, 25, 3, + 25, 103, 25, 143, 3, 95, 95, 58, 143, 25, + 143, 25, 25, 25, 25, 25, 25, 25, 150, 25, + 25, 25, 25, 25 ); protected static $yygoto = array( - 155, 131, 131, 136, 131, 155, 132, 133, 134, 138, - 140, 164, 158, 154, 154, 154, 154, 136, 136, 156, - 156, 156, 156, 156, 156, 156, 150, 151, 152, 153, - 162, 130, 744, 745, 384, 747, 768, 769, 770, 771, - 772, 773, 774, 776, 712, 135, 137, 139, 160, 161, - 163, 179, 191, 192, 193, 194, 195, 196, 197, 198, - 200, 201, 202, 203, 227, 228, 249, 250, 251, 421, - 422, 423, 165, 166, 167, 168, 169, 170, 171, 172, - 173, 174, 175, 176, 141, 142, 143, 157, 144, 159, - 145, 177, 146, 147, 148, 178, 149, 128, 436, 436, - 436, 436, 436, 436, 436, 436, 436, 436, 436, 437, - 437, 437, 437, 437, 437, 437, 437, 437, 437, 437, - 576, 399, 532, 532, 532, 332, 332, 332, 332, 332, - 332, 332, 332, 332, 332, 332, 332, 332, 332, 332, - 332, 332, 332, 533, 533, 533, 417, 803, 803, 648, - 648, 648, 648, 648, 451, 457, 494, 489, 390, 390, - 548, 666, 615, 842, 843, 856, 646, 701, 448, 477, - 605, 605, 605, 605, 267, 600, 606, 484, 386, 386, - 386, 386, 386, 386, 386, 386, 386, 386, 386, 386, - 386, 386, 386, 386, 386, 386, 461, 270, 312, 897, - 389, 389, 307, 479, 416, 416, 442, 416, 410, 412, - 412, 385, 387, 404, 413, 419, 443, 446, 458, 464, - 5, 866, 16, 655, 6, 1, 531, 531, 531, 287, - 2, 7, 470, 17, 18, 8, 19, 9, 10, 11, - 854, 20, 12, 13, 14, 15, 626, 611, 609, 607, - 609, 502, 392, 635, 630, 840, 840, 840, 840, 840, - 840, 840, 840, 840, 840, 840, 308, 903, 903, 205, - 273, 206, 478, 820, 246, 906, 903, 825, 238, 890, - 765, 26, 21, 282, 290, 710, 540, 290, 799, 800, - 873, 873, 906, 906, 640, 640, 300, 432, 691, 313, - 874, 874, 889, 889, 889, 797, 865, 797, 29, 295, - 295, 295, 475, 798, 391, 391, 756, 872, 426, 427, - 428, 429, 431, 460, 295, 288, 815, 814, 424, 402, - 658, 398, 644, 306, 411, 309, 512, 397, 794, 268, - 269, 663, 614, 546, 298, 398, 398, 420, 452, 851, - 699, 481, 0, 0, 0, 482, 0, 0, 0, 0, + 159, 134, 134, 139, 134, 159, 135, 136, 137, 141, + 143, 167, 161, 157, 157, 157, 157, 139, 139, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 153, + 154, 155, 156, 165, 133, 753, 754, 390, 756, 777, + 778, 779, 780, 781, 782, 783, 785, 721, 138, 140, + 142, 163, 164, 166, 182, 194, 195, 196, 197, 198, + 199, 200, 201, 203, 204, 205, 206, 230, 231, 252, + 253, 254, 428, 429, 430, 168, 169, 170, 171, 172, + 173, 174, 175, 176, 177, 178, 179, 144, 145, 146, + 160, 147, 162, 148, 180, 149, 150, 151, 181, 152, + 131, 445, 445, 445, 445, 445, 445, 445, 445, 445, + 445, 445, 446, 446, 446, 446, 446, 446, 446, 446, + 446, 446, 446, 249, 585, 270, 405, 241, 335, 335, + 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, + 335, 335, 335, 335, 335, 335, 542, 542, 542, 424, + 817, 817, 657, 657, 657, 657, 657, 541, 541, 541, + 498, 396, 396, 432, 433, 434, 435, 436, 437, 438, + 440, 469, 1, 614, 614, 614, 614, 2, 609, 615, + 493, 392, 392, 392, 392, 392, 392, 392, 392, 392, + 392, 392, 392, 392, 392, 392, 392, 392, 392, 460, + 466, 503, 911, 395, 395, 310, 488, 423, 423, 451, + 423, 417, 419, 419, 391, 393, 410, 420, 426, 452, + 455, 467, 473, 5, 880, 16, 208, 6, 209, 540, + 540, 540, 457, 486, 7, 664, 17, 18, 8, 19, + 9, 10, 11, 290, 20, 12, 13, 14, 15, 635, + 620, 618, 616, 618, 511, 398, 644, 639, 854, 854, + 854, 854, 854, 854, 854, 854, 854, 854, 854, 917, + 917, 431, 479, 276, 404, 868, 834, 920, 917, 487, + 839, 649, 649, 774, 26, 21, 285, 293, 404, 404, + 293, 813, 814, 719, 920, 920, 271, 272, 700, 316, + 441, 470, 273, 315, 397, 397, 888, 888, 811, 879, + 811, 29, 829, 828, 311, 484, 812, 557, 675, 624, + 856, 857, 870, 655, 710, 887, 887, 298, 298, 298, + 904, 765, 291, 653, 303, 549, 408, 903, 903, 903, + 403, 418, 298, 667, 312, 521, 555, 301, 808, 623, + 427, 309, 886, 672, 865, 461, 708, 0, 0, 0, + 490, 0, 491, 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, 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, 403 + 0, 0, 0, 409 ); protected static $yygcheck = array( @@ -760,68 +761,69 @@ class PHPParser_Parser 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 24, 24, 24, 24, 24, 24, 24, 24, 38, 38, - 38, 38, 38, 38, 38, 38, 38, 38, 38, 91, - 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, - 31, 75, 6, 6, 6, 38, 38, 38, 38, 38, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 24, 38, 38, 38, 38, 38, 38, 38, 38, 38, + 38, 38, 93, 93, 93, 93, 93, 93, 93, 93, + 93, 93, 93, 99, 31, 48, 75, 99, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, - 38, 38, 38, 7, 7, 7, 79, 38, 38, 38, - 38, 38, 38, 38, 40, 40, 40, 38, 91, 91, - 12, 12, 12, 12, 12, 12, 12, 12, 21, 21, - 38, 38, 38, 38, 48, 38, 38, 38, 87, 87, - 87, 87, 87, 87, 87, 87, 87, 87, 87, 87, - 87, 87, 87, 87, 87, 87, 46, 46, 46, 109, - 87, 87, 32, 32, 32, 32, 32, 32, 32, 32, + 38, 38, 38, 38, 38, 38, 7, 7, 7, 83, + 38, 38, 38, 38, 38, 38, 38, 6, 6, 6, + 38, 93, 93, 84, 84, 84, 84, 84, 84, 84, + 84, 84, 2, 38, 38, 38, 38, 2, 38, 38, + 38, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 40, + 40, 40, 111, 90, 90, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, - 13, 57, 13, 59, 13, 2, 5, 5, 5, 28, - 2, 13, 99, 13, 13, 13, 13, 13, 13, 13, - 102, 13, 13, 13, 13, 13, 5, 5, 5, 5, - 5, 5, 5, 5, 5, 98, 98, 98, 98, 98, - 98, 98, 98, 98, 98, 98, 83, 110, 110, 44, - 4, 44, 30, 15, 97, 110, 110, 57, 97, 107, - 15, 15, 15, 15, 4, 75, 10, 4, 57, 57, - 89, 89, 110, 110, 53, 53, 29, 15, 72, 72, - 88, 88, 89, 89, 89, 57, 57, 57, 15, 95, - 95, 95, 15, 57, 94, 94, 76, 89, 90, 90, - 90, 90, 90, 90, 95, 39, 96, 96, 25, 39, - 60, 25, 55, 95, 39, 9, 50, 4, 85, 48, - 48, 61, 47, 11, 4, 25, 25, 4, 39, 101, - 74, 81, -1, -1, -1, 39, -1, -1, -1, -1, + 32, 32, 32, 13, 57, 13, 44, 13, 44, 5, + 5, 5, 21, 21, 13, 59, 13, 13, 13, 13, + 13, 13, 13, 28, 13, 13, 13, 13, 13, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 112, + 112, 25, 101, 4, 25, 104, 15, 112, 112, 30, + 57, 53, 53, 15, 15, 15, 15, 4, 25, 25, + 4, 57, 57, 75, 112, 112, 48, 48, 72, 72, + 15, 46, 46, 46, 96, 96, 91, 91, 57, 57, + 57, 15, 98, 98, 86, 15, 57, 12, 12, 12, + 12, 12, 12, 12, 12, 92, 92, 97, 97, 97, + 109, 76, 39, 55, 29, 10, 39, 92, 92, 92, + 4, 39, 97, 60, 9, 50, 11, 4, 88, 47, + 4, 97, 92, 61, 103, 39, 74, -1, -1, -1, + 82, -1, 39, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 75 + -1, -1, -1, 75 ); protected static $yygbase = array( - 0, 0, -275, 0, 10, 225, 121, 142, 0, 16, - 9, 1, -23, -279, 0, -42, 0, 0, 0, 0, - 0, 124, 0, 0, -30, 298, 0, 0, 183, 81, - 64, 95, -5, 0, 0, 0, 0, 0, -82, -1, - -78, 0, 0, 0, -240, 0, -57, -6, -167, 0, - 52, 0, 0, 87, 0, 97, 0, -40, 0, 188, - 47, -2, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 73, 0, -7, 74, 86, 0, 0, 114, - 0, -4, 0, 56, 0, 17, 0, -29, 71, 61, - 268, -71, 0, 0, 85, 68, 84, 34, 75, 51, - 0, -3, 58, 0, 0, 0, 0, 67, 0, 165, - 30, 0 + 0, 0, -337, 0, 10, 228, 156, 145, 0, 22, + 55, 1, 131, -285, 0, -42, 0, 0, 0, 0, + 0, 188, 0, 0, -30, 241, 0, 0, 197, 116, + 68, 99, -5, 0, 0, 0, 0, 0, -82, 3, + -36, 0, 0, 0, -292, 0, 45, -2, -219, 0, + 58, 0, 0, 71, 0, 95, 0, -40, 0, 200, + 57, 7, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 70, 0, -4, 79, 98, 0, 0, 0, + 0, 0, 2, 117, 113, 0, 101, 0, 24, 0, + -29, 74, 93, -71, 0, 0, 72, 83, 67, -120, + 75, 88, 0, -1, 90, 0, 0, 0, 0, 115, + 0, 168, 29, 0 ); protected static $yygdefault = array( - -32768, 358, 3, 527, 374, 551, 552, 553, 291, 289, - 541, 547, 453, 4, 549, 757, 278, 556, 279, 463, - 558, 405, 560, 561, 129, 375, 292, 293, 406, 299, - 449, 575, 199, 297, 577, 280, 579, 584, 281, 483, - 433, 376, 344, 444, 204, 414, 440, 613, 266, 621, - 515, 629, 632, 377, 434, 643, 349, 796, 304, 654, - 659, 664, 667, 320, 310, 459, 671, 672, 239, 676, - 490, 491, 690, 225, 698, 711, 317, 775, 777, 388, - 400, 468, 789, 301, 311, 793, 378, 379, 328, 329, - 425, 811, 808, 272, 859, 271, 346, 237, 846, 454, - 352, 896, 855, 261, 380, 381, 286, 891, 333, 898, - 905, 441 + -32768, 361, 3, 536, 378, 560, 561, 562, 294, 292, + 550, 556, 462, 4, 558, 766, 281, 565, 282, 472, + 567, 412, 569, 570, 132, 379, 295, 296, 413, 302, + 458, 584, 202, 300, 586, 283, 588, 593, 284, 492, + 442, 380, 347, 453, 207, 421, 449, 622, 269, 630, + 524, 638, 641, 381, 443, 652, 352, 810, 307, 663, + 668, 673, 676, 323, 313, 468, 680, 681, 242, 685, + 499, 500, 699, 228, 707, 720, 320, 784, 786, 382, + 383, 406, 477, 394, 411, 803, 304, 314, 807, 384, + 385, 331, 332, 825, 822, 275, 873, 274, 349, 240, + 860, 463, 355, 910, 869, 264, 386, 387, 289, 905, + 336, 912, 919, 450 ); protected static $yylhs = array( @@ -851,20 +853,20 @@ class PHPParser_Parser 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, - 15, 15, 25, 25, 75, 53, 81, 81, 84, 84, - 85, 86, 86, 86, 86, 86, 86, 91, 91, 38, - 38, 38, 76, 76, 92, 92, 87, 87, 93, 93, - 93, 93, 93, 77, 77, 77, 80, 80, 80, 82, - 82, 98, 98, 98, 98, 98, 98, 98, 98, 98, - 98, 98, 98, 98, 98, 12, 12, 12, 12, 12, - 12, 78, 78, 78, 78, 99, 99, 101, 101, 100, - 100, 102, 102, 32, 32, 32, 32, 104, 104, 103, - 103, 103, 103, 103, 105, 105, 89, 89, 94, 94, - 88, 88, 106, 106, 106, 106, 95, 95, 95, 95, - 90, 90, 96, 96, 96, 83, 83, 107, 107, 107, - 79, 79, 108, 108, 109, 109, 109, 109, 97, 97, - 97, 97, 110, 110, 110, 110, 110, 110, 110, 111, - 111, 111 + 15, 15, 25, 25, 79, 79, 80, 80, 80, 75, + 53, 82, 82, 87, 87, 88, 89, 89, 89, 89, + 89, 89, 93, 93, 38, 38, 38, 76, 76, 94, + 94, 90, 90, 95, 95, 95, 95, 95, 77, 77, + 77, 81, 81, 81, 85, 85, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 12, 12, 12, 12, 12, 12, 78, 78, 78, 78, + 101, 101, 103, 103, 102, 102, 104, 104, 32, 32, + 32, 32, 106, 106, 105, 105, 105, 105, 105, 107, + 107, 92, 92, 96, 96, 91, 91, 108, 108, 108, + 108, 97, 97, 97, 97, 84, 84, 98, 98, 98, + 86, 86, 109, 109, 109, 83, 83, 110, 110, 111, + 111, 111, 111, 99, 99, 99, 99, 112, 112, 112, + 112, 112, 112, 112, 113, 113, 113 ); protected static $yylen = array( @@ -893,21 +895,21 @@ class PHPParser_Parser 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 1, 3, 5, 4, 4, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 1, 4, 3, 3, 2, 1, 9, 10, - 3, 3, 2, 4, 3, 4, 0, 4, 1, 3, - 2, 2, 4, 6, 2, 2, 4, 1, 1, 1, - 2, 3, 1, 1, 1, 1, 1, 1, 0, 3, - 3, 4, 4, 0, 2, 1, 0, 1, 1, 0, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 3, 2, 1, 1, 3, 2, 2, 4, - 3, 1, 3, 3, 3, 0, 2, 0, 1, 3, - 1, 3, 1, 1, 1, 1, 1, 6, 4, 3, - 4, 2, 4, 4, 1, 3, 1, 2, 1, 1, - 4, 1, 3, 6, 4, 4, 4, 4, 1, 4, - 0, 1, 1, 3, 1, 3, 1, 1, 4, 0, - 0, 2, 3, 1, 3, 1, 4, 2, 2, 2, - 1, 2, 1, 4, 3, 3, 3, 6, 3, 1, - 1, 1 + 2, 2, 1, 1, 1, 3, 2, 1, 9, 10, + 3, 3, 2, 4, 4, 3, 4, 4, 4, 3, + 4, 0, 4, 1, 3, 2, 2, 4, 6, 2, + 2, 4, 1, 1, 1, 2, 3, 1, 1, 1, + 1, 1, 1, 0, 3, 3, 4, 4, 0, 2, + 1, 0, 1, 1, 0, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 3, 2, 1, + 1, 3, 2, 2, 4, 3, 1, 3, 3, 3, + 0, 2, 0, 1, 3, 1, 3, 1, 1, 1, + 1, 1, 6, 4, 3, 4, 2, 4, 4, 1, + 3, 1, 2, 1, 1, 4, 1, 3, 6, 4, + 4, 4, 4, 1, 4, 0, 1, 1, 3, 1, + 3, 1, 1, 4, 0, 0, 2, 3, 1, 3, + 1, 4, 2, 2, 2, 1, 2, 1, 4, 3, + 3, 3, 6, 3, 1, 1, 1 ); protected $yyval; @@ -2081,11 +2083,11 @@ class PHPParser_Parser } protected function yyn253($attributes) { - $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn254($attributes) { - $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(3-2)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn255($attributes) { @@ -2125,46 +2127,66 @@ class PHPParser_Parser } protected function yyn264($attributes) { - $this->yyval = new PHPParser_Node_Expr_New($this->yyastk[$this->stackPos-(3-2)], $this->yyastk[$this->stackPos-(3-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn265($attributes) { - $this->yyval = new PHPParser_Node_Expr_List($this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(3-2)], $attributes); } protected function yyn266($attributes) { - $this->yyval = array(); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn267($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(4-3)]; + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch(PHPParser_Node_Scalar_String::create($this->yyastk[$this->stackPos-(4-1)], $attributes), $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn268($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn269($attributes) { - $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + $this->yyval = new PHPParser_Node_Expr_New($this->yyastk[$this->stackPos-(3-2)], $this->yyastk[$this->stackPos-(3-3)], $attributes); } protected function yyn270($attributes) { - $this->yyval = new PHPParser_Node_Expr_ClosureUse(substr($this->yyastk[$this->stackPos-(2-2)], 1), $this->yyastk[$this->stackPos-(2-1)], $attributes); + $this->yyval = new PHPParser_Node_Expr_List($this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn271($attributes) { - $this->yyval = new PHPParser_Node_Expr_FuncCall($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)], $attributes); + $this->yyval = array(); } protected function yyn272($attributes) { - $this->yyval = new PHPParser_Node_Expr_StaticCall($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $this->yyastk[$this->stackPos-(4-4)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(4-3)]; } protected function yyn273($attributes) { - $this->yyval = new PHPParser_Node_Expr_StaticCall($this->yyastk[$this->stackPos-(6-1)], $this->yyastk[$this->stackPos-(6-4)], $this->yyastk[$this->stackPos-(6-6)], $attributes); + $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); } protected function yyn274($attributes) { + $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + } + + protected function yyn275($attributes) { + $this->yyval = new PHPParser_Node_Expr_ClosureUse(substr($this->yyastk[$this->stackPos-(2-2)], 1), $this->yyastk[$this->stackPos-(2-1)], $attributes); + } + + protected function yyn276($attributes) { + $this->yyval = new PHPParser_Node_Expr_FuncCall($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)], $attributes); + } + + protected function yyn277($attributes) { + $this->yyval = new PHPParser_Node_Expr_StaticCall($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $this->yyastk[$this->stackPos-(4-4)], $attributes); + } + + protected function yyn278($attributes) { + $this->yyval = new PHPParser_Node_Expr_StaticCall($this->yyastk[$this->stackPos-(6-1)], $this->yyastk[$this->stackPos-(6-4)], $this->yyastk[$this->stackPos-(6-6)], $attributes); + } + + protected function yyn279($attributes) { if ($this->yyastk[$this->stackPos-(2-1)] instanceof PHPParser_Node_Expr_StaticPropertyFetch) { $this->yyval = new PHPParser_Node_Expr_StaticCall($this->yyastk[$this->stackPos-(2-1)]->class, new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(2-1)]->name, $attributes), $this->yyastk[$this->stackPos-(2-2)], $attributes); @@ -2182,36 +2204,16 @@ class PHPParser_Parser } - protected function yyn275($attributes) { + protected function yyn280($attributes) { $this->yyval = new PHPParser_Node_Expr_FuncCall($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)], $attributes); } - protected function yyn276($attributes) { + protected function yyn281($attributes) { $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } - protected function yyn277($attributes) { - $this->yyval = new PHPParser_Node_Name('static', $attributes); - } - - protected function yyn278($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; - } - - protected function yyn279($attributes) { - $this->yyval = new PHPParser_Node_Name($this->yyastk[$this->stackPos-(1-1)], $attributes); - } - - protected function yyn280($attributes) { - $this->yyval = new PHPParser_Node_Name_FullyQualified($this->yyastk[$this->stackPos-(2-2)], $attributes); - } - - protected function yyn281($attributes) { - $this->yyval = new PHPParser_Node_Name_Relative($this->yyastk[$this->stackPos-(3-3)], $attributes); - } - protected function yyn282($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Name('static', $attributes); } protected function yyn283($attributes) { @@ -2219,67 +2221,67 @@ class PHPParser_Parser } protected function yyn284($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Name($this->yyastk[$this->stackPos-(1-1)], $attributes); } protected function yyn285($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Name_FullyQualified($this->yyastk[$this->stackPos-(2-2)], $attributes); } protected function yyn286($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Name_Relative($this->yyastk[$this->stackPos-(3-3)], $attributes); } protected function yyn287($attributes) { $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } - protected function yyn288() { - $this->yyval = $this->yyastk[$this->stackPos]; - } - - protected function yyn289($attributes) { - $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); - } - - protected function yyn290($attributes) { - $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); - } - - protected function yyn291($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); - } - - protected function yyn292($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); - } - - protected function yyn293($attributes) { - $this->yyval = null; - } - - protected function yyn294($attributes) { - $this->yyval = null; - } - - protected function yyn295($attributes) { + protected function yyn288($attributes) { $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } + protected function yyn289($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn290($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn291($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn292($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn293() { + $this->yyval = $this->yyastk[$this->stackPos]; + } + + protected function yyn294($attributes) { + $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); + } + + protected function yyn295($attributes) { + $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); + } + protected function yyn296($attributes) { - $this->yyval = array(); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn297($attributes) { - $this->yyval = array(PHPParser_Node_Scalar_String::parseEscapeSequences($this->yyastk[$this->stackPos-(1-1)], '`')); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn298($attributes) { - foreach ($this->yyastk[$this->stackPos-(1-1)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, '`'); } }; $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = null; } protected function yyn299($attributes) { - $this->yyval = array(); + $this->yyval = null; } protected function yyn300($attributes) { @@ -2287,171 +2289,171 @@ class PHPParser_Parser } protected function yyn301($attributes) { - $this->yyval = new PHPParser_Node_Scalar_LNumber(PHPParser_Node_Scalar_LNumber::parse($this->yyastk[$this->stackPos-(1-1)]), $attributes); - } - - protected function yyn302($attributes) { - $this->yyval = new PHPParser_Node_Scalar_DNumber(PHPParser_Node_Scalar_DNumber::parse($this->yyastk[$this->stackPos-(1-1)]), $attributes); - } - - protected function yyn303($attributes) { - $this->yyval = PHPParser_Node_Scalar_String::create($this->yyastk[$this->stackPos-(1-1)], $attributes); - } - - protected function yyn304($attributes) { - $this->yyval = new PHPParser_Node_Scalar_LineConst($attributes); - } - - protected function yyn305($attributes) { - $this->yyval = new PHPParser_Node_Scalar_FileConst($attributes); - } - - protected function yyn306($attributes) { - $this->yyval = new PHPParser_Node_Scalar_DirConst($attributes); - } - - protected function yyn307($attributes) { - $this->yyval = new PHPParser_Node_Scalar_ClassConst($attributes); - } - - protected function yyn308($attributes) { - $this->yyval = new PHPParser_Node_Scalar_TraitConst($attributes); - } - - protected function yyn309($attributes) { - $this->yyval = new PHPParser_Node_Scalar_MethodConst($attributes); - } - - protected function yyn310($attributes) { - $this->yyval = new PHPParser_Node_Scalar_FuncConst($attributes); - } - - protected function yyn311($attributes) { - $this->yyval = new PHPParser_Node_Scalar_NSConst($attributes); - } - - protected function yyn312($attributes) { - $this->yyval = new PHPParser_Node_Scalar_String(PHPParser_Node_Scalar_String::parseDocString($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-2)]), $attributes); - } - - protected function yyn313($attributes) { - $this->yyval = new PHPParser_Node_Scalar_String('', $attributes); - } - - protected function yyn314($attributes) { - $this->yyval = new PHPParser_Node_Expr_ConstFetch($this->yyastk[$this->stackPos-(1-1)], $attributes); - } - - protected function yyn315($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; - } - - protected function yyn316($attributes) { - $this->yyval = new PHPParser_Node_Expr_ClassConstFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); - } - - protected function yyn317($attributes) { - $this->yyval = new PHPParser_Node_Expr_UnaryPlus($this->yyastk[$this->stackPos-(2-2)], $attributes); - } - - protected function yyn318($attributes) { - $this->yyval = new PHPParser_Node_Expr_UnaryMinus($this->yyastk[$this->stackPos-(2-2)], $attributes); - } - - protected function yyn319($attributes) { - $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(4-3)], $attributes); - } - - protected function yyn320($attributes) { - $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(3-2)], $attributes); - } - - protected function yyn321($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; - } - - protected function yyn322($attributes) { - $this->yyval = new PHPParser_Node_Expr_ClassConstFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); - } - - protected function yyn323($attributes) { - foreach ($this->yyastk[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, '"'); } }; $this->yyval = new PHPParser_Node_Scalar_Encapsed($this->yyastk[$this->stackPos-(3-2)], $attributes); - } - - protected function yyn324($attributes) { - foreach ($this->yyastk[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, null); } } $s = preg_replace('~(\r\n|\n|\r)$~', '', $s); if ('' === $s) array_pop($this->yyastk[$this->stackPos-(3-2)]);; $this->yyval = new PHPParser_Node_Scalar_Encapsed($this->yyastk[$this->stackPos-(3-2)], $attributes); - } - - protected function yyn325($attributes) { $this->yyval = array(); } + protected function yyn302($attributes) { + $this->yyval = array(PHPParser_Node_Scalar_String::parseEscapeSequences($this->yyastk[$this->stackPos-(1-1)], '`')); + } + + protected function yyn303($attributes) { + foreach ($this->yyastk[$this->stackPos-(1-1)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, '`'); } }; $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn304($attributes) { + $this->yyval = array(); + } + + protected function yyn305($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn306($attributes) { + $this->yyval = new PHPParser_Node_Scalar_LNumber(PHPParser_Node_Scalar_LNumber::parse($this->yyastk[$this->stackPos-(1-1)]), $attributes); + } + + protected function yyn307($attributes) { + $this->yyval = new PHPParser_Node_Scalar_DNumber(PHPParser_Node_Scalar_DNumber::parse($this->yyastk[$this->stackPos-(1-1)]), $attributes); + } + + protected function yyn308($attributes) { + $this->yyval = PHPParser_Node_Scalar_String::create($this->yyastk[$this->stackPos-(1-1)], $attributes); + } + + protected function yyn309($attributes) { + $this->yyval = new PHPParser_Node_Scalar_LineConst($attributes); + } + + protected function yyn310($attributes) { + $this->yyval = new PHPParser_Node_Scalar_FileConst($attributes); + } + + protected function yyn311($attributes) { + $this->yyval = new PHPParser_Node_Scalar_DirConst($attributes); + } + + protected function yyn312($attributes) { + $this->yyval = new PHPParser_Node_Scalar_ClassConst($attributes); + } + + protected function yyn313($attributes) { + $this->yyval = new PHPParser_Node_Scalar_TraitConst($attributes); + } + + protected function yyn314($attributes) { + $this->yyval = new PHPParser_Node_Scalar_MethodConst($attributes); + } + + protected function yyn315($attributes) { + $this->yyval = new PHPParser_Node_Scalar_FuncConst($attributes); + } + + protected function yyn316($attributes) { + $this->yyval = new PHPParser_Node_Scalar_NSConst($attributes); + } + + protected function yyn317($attributes) { + $this->yyval = new PHPParser_Node_Scalar_String(PHPParser_Node_Scalar_String::parseDocString($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-2)]), $attributes); + } + + protected function yyn318($attributes) { + $this->yyval = new PHPParser_Node_Scalar_String('', $attributes); + } + + protected function yyn319($attributes) { + $this->yyval = new PHPParser_Node_Expr_ConstFetch($this->yyastk[$this->stackPos-(1-1)], $attributes); + } + + protected function yyn320($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn321($attributes) { + $this->yyval = new PHPParser_Node_Expr_ClassConstFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); + } + + protected function yyn322($attributes) { + $this->yyval = new PHPParser_Node_Expr_UnaryPlus($this->yyastk[$this->stackPos-(2-2)], $attributes); + } + + protected function yyn323($attributes) { + $this->yyval = new PHPParser_Node_Expr_UnaryMinus($this->yyastk[$this->stackPos-(2-2)], $attributes); + } + + protected function yyn324($attributes) { + $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(4-3)], $attributes); + } + + protected function yyn325($attributes) { + $this->yyval = new PHPParser_Node_Expr_Array($this->yyastk[$this->stackPos-(3-2)], $attributes); + } + protected function yyn326($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } - protected function yyn327() { - $this->yyval = $this->yyastk[$this->stackPos]; + protected function yyn327($attributes) { + $this->yyval = new PHPParser_Node_Expr_ClassConstFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); } - protected function yyn328() { - $this->yyval = $this->yyastk[$this->stackPos]; + protected function yyn328($attributes) { + foreach ($this->yyastk[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, '"'); } }; $this->yyval = new PHPParser_Node_Scalar_Encapsed($this->yyastk[$this->stackPos-(3-2)], $attributes); } protected function yyn329($attributes) { - $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + foreach ($this->yyastk[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = PHPParser_Node_Scalar_String::parseEscapeSequences($s, null); } } $s = preg_replace('~(\r\n|\n|\r)$~', '', $s); if ('' === $s) array_pop($this->yyastk[$this->stackPos-(3-2)]);; $this->yyval = new PHPParser_Node_Scalar_Encapsed($this->yyastk[$this->stackPos-(3-2)], $attributes); } protected function yyn330($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + $this->yyval = array(); } protected function yyn331($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(3-3)], $this->yyastk[$this->stackPos-(3-1)], false, $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; } - protected function yyn332($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(1-1)], null, false, $attributes); + protected function yyn332() { + $this->yyval = $this->yyastk[$this->stackPos]; } - protected function yyn333($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + protected function yyn333() { + $this->yyval = $this->yyastk[$this->stackPos]; } protected function yyn334($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; } protected function yyn335($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); } protected function yyn336($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(3-3)], $this->yyastk[$this->stackPos-(3-1)], false, $attributes); } protected function yyn337($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(6-2)], $this->yyastk[$this->stackPos-(6-5)], $attributes); + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(1-1)], null, false, $attributes); } protected function yyn338($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn339($attributes) { - $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn340($attributes) { - $this->yyval = new PHPParser_Node_Expr_MethodCall($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $this->yyastk[$this->stackPos-(4-4)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn341($attributes) { - $this->yyval = new PHPParser_Node_Expr_FuncCall($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn342($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(6-2)], $this->yyastk[$this->stackPos-(6-5)], $attributes); } protected function yyn343($attributes) { @@ -2459,23 +2461,23 @@ class PHPParser_Parser } protected function yyn344($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_PropertyFetch($this->yyastk[$this->stackPos-(3-1)], $this->yyastk[$this->stackPos-(3-3)], $attributes); } protected function yyn345($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(3-2)]; + $this->yyval = new PHPParser_Node_Expr_MethodCall($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $this->yyastk[$this->stackPos-(4-4)], $attributes); } protected function yyn346($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_FuncCall($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)], $attributes); } protected function yyn347($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(2-2)], $attributes); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn348($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn349($attributes) { @@ -2483,7 +2485,7 @@ class PHPParser_Parser } protected function yyn350($attributes) { - $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-4)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(3-2)]; } protected function yyn351($attributes) { @@ -2491,63 +2493,63 @@ class PHPParser_Parser } protected function yyn352($attributes) { - $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(3-1)], substr($this->yyastk[$this->stackPos-(3-3)], 1), $attributes); + $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(2-2)], $attributes); } protected function yyn353($attributes) { - $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(6-1)], $this->yyastk[$this->stackPos-(6-5)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn354($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn355($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-4)], $attributes); } protected function yyn356($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn357($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(3-1)], substr($this->yyastk[$this->stackPos-(3-3)], 1), $attributes); } protected function yyn358($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(1-1)], 1), $attributes); + $this->yyval = new PHPParser_Node_Expr_StaticPropertyFetch($this->yyastk[$this->stackPos-(6-1)], $this->yyastk[$this->stackPos-(6-5)], $attributes); } protected function yyn359($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(4-3)], $attributes); + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn360($attributes) { - $this->yyval = null; + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn361($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn362($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch($this->yyastk[$this->stackPos-(4-1)], $this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn363($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(3-2)]; + $this->yyval = new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(1-1)], 1), $attributes); } protected function yyn364($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(4-3)], $attributes); } protected function yyn365($attributes) { - $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + $this->yyval = null; } protected function yyn366($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; } protected function yyn367($attributes) { @@ -2555,98 +2557,118 @@ class PHPParser_Parser } protected function yyn368($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(4-3)]; - } - - protected function yyn369($attributes) { - $this->yyval = null; - } - - protected function yyn370($attributes) { - $this->yyval = array(); - } - - protected function yyn371($attributes) { - $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; - } - - protected function yyn372($attributes) { - $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; - } - - protected function yyn373($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); - } - - protected function yyn374($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(3-3)], $this->yyastk[$this->stackPos-(3-1)], false, $attributes); - } - - protected function yyn375($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(1-1)], null, false, $attributes); - } - - protected function yyn376($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(4-4)], $this->yyastk[$this->stackPos-(4-1)], true, $attributes); - } - - protected function yyn377($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(2-2)], null, true, $attributes); - } - - protected function yyn378($attributes) { - $this->yyastk[$this->stackPos-(2-1)][] = $this->yyastk[$this->stackPos-(2-2)]; $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; - } - - protected function yyn379($attributes) { - $this->yyastk[$this->stackPos-(2-1)][] = $this->yyastk[$this->stackPos-(2-2)]; $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; - } - - protected function yyn380($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); - } - - protected function yyn381($attributes) { - $this->yyval = array($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)]); - } - - protected function yyn382($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(1-1)], 1), $attributes); - } - - protected function yyn383($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch(new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(4-1)], 1), $attributes), $this->yyastk[$this->stackPos-(4-3)], $attributes); - } - - protected function yyn384($attributes) { - $this->yyval = new PHPParser_Node_Expr_PropertyFetch(new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(3-1)], 1), $attributes), $this->yyastk[$this->stackPos-(3-3)], $attributes); - } - - protected function yyn385($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(3-2)], $attributes); - } - - protected function yyn386($attributes) { - $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(3-2)], $attributes); - } - - protected function yyn387($attributes) { - $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch(new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(6-2)], $attributes), $this->yyastk[$this->stackPos-(6-4)], $attributes); - } - - protected function yyn388($attributes) { $this->yyval = $this->yyastk[$this->stackPos-(3-2)]; } + protected function yyn369($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn370($attributes) { + $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + } + + protected function yyn371($attributes) { + $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + } + + protected function yyn372($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(1-1)]; + } + + protected function yyn373($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(4-3)]; + } + + protected function yyn374($attributes) { + $this->yyval = null; + } + + protected function yyn375($attributes) { + $this->yyval = array(); + } + + protected function yyn376($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; + } + + protected function yyn377($attributes) { + $this->yyastk[$this->stackPos-(3-1)][] = $this->yyastk[$this->stackPos-(3-3)]; $this->yyval = $this->yyastk[$this->stackPos-(3-1)]; + } + + protected function yyn378($attributes) { + $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + } + + protected function yyn379($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(3-3)], $this->yyastk[$this->stackPos-(3-1)], false, $attributes); + } + + protected function yyn380($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(1-1)], null, false, $attributes); + } + + protected function yyn381($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(4-4)], $this->yyastk[$this->stackPos-(4-1)], true, $attributes); + } + + protected function yyn382($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayItem($this->yyastk[$this->stackPos-(2-2)], null, true, $attributes); + } + + protected function yyn383($attributes) { + $this->yyastk[$this->stackPos-(2-1)][] = $this->yyastk[$this->stackPos-(2-2)]; $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; + } + + protected function yyn384($attributes) { + $this->yyastk[$this->stackPos-(2-1)][] = $this->yyastk[$this->stackPos-(2-2)]; $this->yyval = $this->yyastk[$this->stackPos-(2-1)]; + } + + protected function yyn385($attributes) { + $this->yyval = array($this->yyastk[$this->stackPos-(1-1)]); + } + + protected function yyn386($attributes) { + $this->yyval = array($this->yyastk[$this->stackPos-(2-1)], $this->yyastk[$this->stackPos-(2-2)]); + } + + protected function yyn387($attributes) { + $this->yyval = new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(1-1)], 1), $attributes); + } + + protected function yyn388($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch(new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(4-1)], 1), $attributes), $this->yyastk[$this->stackPos-(4-3)], $attributes); + } + protected function yyn389($attributes) { - $this->yyval = new PHPParser_Node_Scalar_String($this->yyastk[$this->stackPos-(1-1)], $attributes); + $this->yyval = new PHPParser_Node_Expr_PropertyFetch(new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(3-1)], 1), $attributes), $this->yyastk[$this->stackPos-(3-3)], $attributes); } protected function yyn390($attributes) { - $this->yyval = new PHPParser_Node_Scalar_String($this->yyastk[$this->stackPos-(1-1)], $attributes); + $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(3-2)], $attributes); } protected function yyn391($attributes) { + $this->yyval = new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(3-2)], $attributes); + } + + protected function yyn392($attributes) { + $this->yyval = new PHPParser_Node_Expr_ArrayDimFetch(new PHPParser_Node_Expr_Variable($this->yyastk[$this->stackPos-(6-2)], $attributes), $this->yyastk[$this->stackPos-(6-4)], $attributes); + } + + protected function yyn393($attributes) { + $this->yyval = $this->yyastk[$this->stackPos-(3-2)]; + } + + protected function yyn394($attributes) { + $this->yyval = new PHPParser_Node_Scalar_String($this->yyastk[$this->stackPos-(1-1)], $attributes); + } + + protected function yyn395($attributes) { + $this->yyval = new PHPParser_Node_Scalar_String($this->yyastk[$this->stackPos-(1-1)], $attributes); + } + + protected function yyn396($attributes) { $this->yyval = new PHPParser_Node_Expr_Variable(substr($this->yyastk[$this->stackPos-(1-1)], 1), $attributes); } } diff --git a/test/code/parser/expr/fetchAndCall/constantDeref.test b/test/code/parser/expr/fetchAndCall/constantDeref.test new file mode 100644 index 0000000..fd5de56 --- /dev/null +++ b/test/code/parser/expr/fetchAndCall/constantDeref.test @@ -0,0 +1,181 @@ +Array/string dereferencing +----- +