File: arrayEmptyElemens.test

package info (click to toggle)
php-parser 5.6.1-1
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 4,532 kB
  • sloc: php: 23,585; yacc: 1,272; makefile: 39; sh: 8
file content (70 lines) | stat: -rw-r--r-- 1,975 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
Array with empty elements
-----
<?php

[1, , 2];
array(1, , 2);
-----
!!positions
Cannot use empty array elements in arrays from 3:5 to 3:5
Cannot use empty array elements in arrays from 4:10 to 4:10
array(
    0: Stmt_Expression[3:1 - 3:9](
        expr: Expr_Array[3:1 - 3:8](
            items: array(
                0: ArrayItem[3:2 - 3:2](
                    key: null
                    value: Scalar_Int[3:2 - 3:2](
                        value: 1
                    )
                    byRef: false
                    unpack: false
                )
                1: ArrayItem[3:5 - 3:5](
                    key: null
                    value: Expr_Error[3:5 - 3:5](
                    )
                    byRef: false
                    unpack: false
                )
                2: ArrayItem[3:7 - 3:7](
                    key: null
                    value: Scalar_Int[3:7 - 3:7](
                        value: 2
                    )
                    byRef: false
                    unpack: false
                )
            )
        )
    )
    1: Stmt_Expression[4:1 - 4:14](
        expr: Expr_Array[4:1 - 4:13](
            items: array(
                0: ArrayItem[4:7 - 4:7](
                    key: null
                    value: Scalar_Int[4:7 - 4:7](
                        value: 1
                    )
                    byRef: false
                    unpack: false
                )
                1: ArrayItem[4:10 - 4:10](
                    key: null
                    value: Expr_Error[4:10 - 4:10](
                    )
                    byRef: false
                    unpack: false
                )
                2: ArrayItem[4:12 - 4:12](
                    key: null
                    value: Scalar_Int[4:12 - 4:12](
                        value: 2
                    )
                    byRef: false
                    unpack: false
                )
            )
        )
    )
)