test/script/basic/parser/labelledStat.js.EXPECTED

Fri, 21 Mar 2014 20:24:01 +0530

author
sundar
date
Fri, 21 Mar 2014 20:24:01 +0530
changeset 772
c1f528e1d2f2
parent 0
b1a7da25b547
child 963
e2497b11a021
permissions
-rw-r--r--

8037562: Nashorn: JSON.parse comes up with nonexistent entries if there are gaps between the keys
Reviewed-by: jlaskey, hannesw

     1 {
     2     "type": "Program",
     3     "body": [
     4         {
     5             "type": "LabeledStatement",
     6             "label": {
     7                 "type": "Identifier",
     8                 "name": "begin"
     9             },
    10             "body": {
    11                 "type": "BlockStatement",
    12                 "body": [
    13                     {
    14                         "type": "ForStatement",
    15                         "init": null,
    16                         "test": null,
    17                         "update": null,
    18                         "body": {
    19                             "type": "BlockStatement",
    20                             "body": [
    21                                 {
    22                                     "type": "BreakStatement",
    23                                     "label": {
    24                                         "type": "Identifier",
    25                                         "name": "begin"
    26                                     }
    27                                 }
    28                             ]
    29                         }
    30                     }
    31                 ]
    32             }
    33         }
    34     ]
    35 }
    36 {
    37     "type": "Program",
    38     "body": [
    39         {
    40             "type": "LabeledStatement",
    41             "label": {
    42                 "type": "Identifier",
    43                 "name": "begin"
    44             },
    45             "body": {
    46                 "type": "BlockStatement",
    47                 "body": [
    48                     {
    49                         "type": "WhileStatement",
    50                         "test": {
    51                             "type": "Literal",
    52                             "value": true
    53                         },
    54                         "body": {
    55                             "type": "BlockStatement",
    56                             "body": [
    57                                 {
    58                                     "type": "BreakStatement",
    59                                     "label": {
    60                                         "type": "Identifier",
    61                                         "name": "begin"
    62                                     }
    63                                 }
    64                             ]
    65                         }
    66                     }
    67                 ]
    68             }
    69         }
    70     ]
    71 }

mercurial