1--TEST-- 2Array destructuring (using unkeyed list()) 3--FILE-- 4<?php 5 6require __DIR__ . '/../util.php'; 7 8$code = <<<'PHP' 9<?php 10list($a, $b) = $x; 11list(, $b) = $x; 12PHP; 13 14echo ast_dump(ast\parse_code($code, $version=70)); 15 16?> 17--EXPECTF-- 18AST_STMT_LIST 19 0: AST_ASSIGN 20 var: AST_ARRAY 21 flags: ARRAY_SYNTAX_LIST (%d) 22 0: AST_ARRAY_ELEM 23 flags: 0 24 value: AST_VAR 25 name: "a" 26 key: null 27 1: AST_ARRAY_ELEM 28 flags: 0 29 value: AST_VAR 30 name: "b" 31 key: null 32 expr: AST_VAR 33 name: "x" 34 1: AST_ASSIGN 35 var: AST_ARRAY 36 flags: ARRAY_SYNTAX_LIST (%d) 37 0: null 38 1: AST_ARRAY_ELEM 39 flags: 0 40 value: AST_VAR 41 name: "b" 42 key: null 43 expr: AST_VAR 44 name: "x"