-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCplusplusNested.dot
121 lines (119 loc) · 6.22 KB
/
CplusplusNested.dot
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
digraph G {
#concentrate = true
"g0" [label="0: $start -> prog $end", shape = doubleoctagon, fontcolor=blue, color=blue ]
"g1" [label="1: prog -> /* empty */", shape = box, fontcolor=blue, color=blue ]
"g2" [label="2: prog -> prog decORexp_explorer stmt", shape = box, fontcolor=blue, color=blue ]
"g3" [label="3: stmt -> expr ';'", shape = box, fontcolor=blue, color=blue ]
"g4" [label="4: stmt -> decl", shape = box, fontcolor=blue, color=blue ]
"g5" [label="5: expr -> ID decORexp", shape = box, fontcolor=blue, color=blue ]
"g6" [label="6: expr -> NUM", shape = box, fontcolor=blue, color=blue ]
"g7" [label="7: expr -> INT '(' expr ')'", shape = box, fontcolor=blue, color=blue ]
"g8" [label="8: expr -> expr '+' expr", shape = box, fontcolor=blue, color=blue ]
"g9" [label="9: expr -> expr '=' expr", shape = box, fontcolor=blue, color=blue ]
"g10" [label="10: decl -> INT declarator ';'", shape = box, fontcolor=blue, color=blue ]
"g11" [label="11: decl -> INT declarator '=' expr ';'", shape = box, fontcolor=blue, color=blue ]
"g12" [label="12: declarator -> ID decORexp", shape = box, fontcolor=blue, color=blue ]
"g13" [label="13: declarator -> '(' declarator ')'", shape = box, fontcolor=blue, color=blue ]
"g14" [label="14: decORexp -> /* empty */", shape = box, fontcolor=blue, color=blue ]
"g15" [label="15: decORexp_explorer -> /* empty */", shape = box, fontcolor=blue, color=blue ]
g0 ->g1 [style=dotted];
g1 ->g2 [style=dotted];
g2 ->g3 [style=dotted];
g3 ->g4 [style=dotted];
g4 ->g5 [style=dotted];
g5 ->g6 [style=dotted];
g6 ->g7 [style=dotted];
g7 ->g8 [style=dotted];
g8 ->g9 [style=dotted];
g9 ->g10 [style=dotted];
g10 ->g11 [style=dotted];
g11 ->g12 [style=dotted];
g12 ->g13 [style=dotted];
g13 ->g14 [style=dotted];
g14 ->g15 [style=dotted];
28 [shape = diamond, fontcolor=red, color=red]
0 -> 1 [label = "prog", arrowhead = odot, color = "red", fontcolor = "red"]
0 -> "g1" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
1 -> 2 [label = "$end"]
1 -> 3 [label = "decORexp_explorer", arrowhead = odot, color = "red", fontcolor = "red"]
1 -> "g15" [label = "ID", arrowhead=dot, color = "blue", fontcolor = "blue"]
1 -> "g15" [label = "INT", arrowhead=dot, color = "blue", fontcolor = "blue"]
1 -> "g15" [label = "NUM", arrowhead=dot, color = "blue", fontcolor = "blue"]
2 [shape = doublecircle]
2 -> "g0" [arrowhead = dot, color = blue]
3 -> 5 [label = "ID"]
3 -> 9 [label = "INT"]
3 -> 4 [label = "NUM"]
3 -> 6 [label = "stmt", arrowhead = odot, color = "red", fontcolor = "red"]
3 -> 8 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
3 -> 7 [label = "decl", arrowhead = odot, color = "red", fontcolor = "red"]
4 -> "g6" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
5 -> 10 [label = "decORexp", arrowhead = odot, color = "red", fontcolor = "red"]
5 -> "g14" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
6 -> "g2" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
7 -> "g4" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
8 -> 11 [label = "'+'"]
8 -> 12 [label = "';'"]
8 -> 13 [label = "'='"]
9 -> 15 [label = "'('"]
9 -> 14 [label = "ID"]
9 -> 16 [label = "declarator", arrowhead = odot, color = "red", fontcolor = "red"]
10 -> "g5" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
11 -> 5 [label = "ID"]
11 -> 18 [label = "INT"]
11 -> 4 [label = "NUM"]
11 -> 17 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
12 -> "g3" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
13 -> 5 [label = "ID"]
13 -> 18 [label = "INT"]
13 -> 4 [label = "NUM"]
13 -> 19 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
14 -> 20 [label = "decORexp", arrowhead = odot, color = "red", fontcolor = "red"]
14 -> "g14" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
15 -> 22 [label = "'('"]
15 -> 21 [label = "ID"]
15 -> 18 [label = "INT"]
15 -> 4 [label = "NUM"]
15 -> 23 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
15 -> 24 [label = "declarator", arrowhead = odot, color = "red", fontcolor = "red"]
16 -> 25 [label = "';'"]
16 -> 26 [label = "'='"]
17 -> "g8" [label = "')'", arrowhead=dot, color = "blue", fontcolor = "blue"]
17 -> "g8" [label = "'+'", arrowhead=dot, color = "blue", fontcolor = "blue"]
17 -> "g8" [label = "';'", arrowhead=dot, color = "blue", fontcolor = "blue"]
17 -> "g8" [label = "'='", arrowhead=dot, color = "blue", fontcolor = "blue"]
18 -> 27 [label = "'('"]
19 -> 11 [label = "'+'"]
19 -> 13 [label = "'='"]
19 -> "g9" [label = "')'", arrowhead=dot, color = "blue", fontcolor = "blue"]
19 -> "g9" [label = "';'", arrowhead=dot, color = "blue", fontcolor = "blue"]
20 -> "g12" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
21 -> 28 [label = "decORexp", arrowhead = odot, color = "red", fontcolor = "red"]
21 -> "g14" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
22 -> 22 [label = "'('"]
22 -> 14 [label = "ID"]
22 -> 24 [label = "declarator", arrowhead = odot, color = "red", fontcolor = "red"]
23 -> 29 [label = "')'"]
23 -> 11 [label = "'+'"]
23 -> 13 [label = "'='"]
24 -> 30 [label = "')'"]
25 -> "g10" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
26 -> 5 [label = "ID"]
26 -> 18 [label = "INT"]
26 -> 4 [label = "NUM"]
26 -> 31 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
27 -> 5 [label = "ID"]
27 -> 18 [label = "INT"]
27 -> 4 [label = "NUM"]
27 -> 23 [label = "expr", arrowhead = odot, color = "red", fontcolor = "red"]
28 -> "g5" [label = "')'", arrowhead=dot, color = "blue", fontcolor = "blue"]
28 -> "g5" [label = "'+'", arrowhead=dot, color = "blue", fontcolor = "blue"]
28 -> "g5" [label = "'='", arrowhead=dot, color = "blue", fontcolor = "blue"]
28 -> "g12" [label = "')'", arrowhead=dot, style=dotted, color = "red", fontcolor = "red"]
29 -> "g7" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
30 -> "g13" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
31 -> 11 [label = "'+'"]
31 -> 32 [label = "';'"]
31 -> 13 [label = "'='"]
32 -> "g11" [label = "$default", arrowhead=dot, color = "blue", fontcolor = "blue"]
}