]>
Commit | Line | Data |
---|---|---|
eb39fafa DC |
1 | /*expected |
2 | initial->s1_1->s1_3->s1_2->s1_4->s1_6->s1_5->s1_7->s1_8->s1_9->s1_10->s1_11->s1_12->s1_13->s1_5; | |
3 | s1_3->s1_15; | |
4 | s1_6->s1_14->s1_2; | |
5 | s1_7->s1_10; | |
6 | s1_8->s1_15; | |
7 | s1_10->s1_13; | |
8 | s1_11->s1_14; | |
9 | s1_13->s1_14->s1_15->final; | |
10 | */ | |
11 | A: for (var a of [0]) { | |
12 | B: for (var b of [1]) { | |
13 | if (c) { | |
14 | break A; | |
15 | } | |
16 | if (d) { | |
17 | break B; | |
18 | } | |
19 | foo(); | |
20 | } | |
21 | } | |
22 | ||
23 | /*DOT | |
24 | digraph { | |
25 | node[shape=box,style="rounded,filled",fillcolor=white]; | |
26 | initial[label="",shape=circle,style=filled,fillcolor=black,width=0.25,height=0.25]; | |
27 | final[label="",shape=doublecircle,style=filled,fillcolor=black,width=0.25,height=0.25]; | |
28 | s1_1[label="Program\nLabeledStatement\nIdentifier (A)\nForInStatement"]; | |
29 | s1_3[label="ArrayExpression\nLiteral (0)"]; | |
30 | s1_2[label="VariableDeclaration\nVariableDeclarator\nIdentifier (a)"]; | |
31 | s1_4[label="BlockStatement\nLabeledStatement\nIdentifier (B)\nForInStatement"]; | |
32 | s1_6[label="ArrayExpression\nLiteral (1)"]; | |
33 | s1_5[label="VariableDeclaration\nVariableDeclarator\nIdentifier (b)"]; | |
34 | s1_7[label="BlockStatement\nIfStatement\nIdentifier (c)"]; | |
35 | s1_8[label="BlockStatement\nBreakStatement\nIdentifier (A)"]; | |
36 | s1_9[style="rounded,dashed,filled",fillcolor="#FF9800",label="<<unreachable>>\nBlockStatement:exit"]; | |
37 | s1_10[label="IfStatement\nIdentifier (d)"]; | |
38 | s1_11[label="BlockStatement\nBreakStatement\nIdentifier (B)"]; | |
39 | s1_12[style="rounded,dashed,filled",fillcolor="#FF9800",label="<<unreachable>>\nBlockStatement:exit"]; | |
40 | s1_13[label="ExpressionStatement\nCallExpression\nIdentifier (foo)"]; | |
41 | s1_15[label="ForInStatement:exit\nLabeledStatement:exit\nProgram:exit"]; | |
42 | s1_14[label="ForInStatement:exit\nLabeledStatement:exit\nBlockStatement:exit"]; | |
43 | initial->s1_1->s1_3->s1_2->s1_4->s1_6->s1_5->s1_7->s1_8->s1_9->s1_10->s1_11->s1_12->s1_13->s1_5; | |
44 | s1_3->s1_15; | |
45 | s1_6->s1_14->s1_2; | |
46 | s1_7->s1_10; | |
47 | s1_8->s1_15; | |
48 | s1_10->s1_13; | |
49 | s1_11->s1_14; | |
50 | s1_13->s1_14->s1_15->final; | |
51 | } | |
52 | */ |