Skip to content

Commit 7356bf4

Browse files
committed
JS: Update TRAP output
This input file contained a destructuring rest parameter
1 parent bec80a8 commit 7356bf4

1 file changed

Lines changed: 173 additions & 22 deletions

File tree

‎javascript/extractor/tests/es2015/output/trap/restparms2.js.trap‎

Lines changed: 173 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,27 +9,178 @@ hasLocation(#10000,#10002)
99
#20000=@"global_scope"
1010
scopes(#20000,0)
1111
#20001=@"script;{#10000},1,1"
12-
toplevels(#20001,0)
13-
#20002=@"loc,{#10000},1,1,1,1"
14-
locations_default(#20002,#10000,1,1,1,1)
15-
hasLocation(#20001,#20002)
16-
#20003=*
17-
js_parse_errors(#20003,#20001,"Error: Unexpected token","function f(x, ...[y, z]) {
18-
")
19-
#20004=@"loc,{#10000},1,18,1,18"
20-
locations_default(#20004,#10000,1,18,1,18)
21-
hasLocation(#20003,#20004)
22-
#20005=*
23-
lines(#20005,#20001,"function f(x, ...[y, z]) {","
12+
#20002=*
13+
lines(#20002,#20001,"function f(x, ...[y, z]) {","
2414
")
25-
#20006=@"loc,{#10000},1,1,1,26"
26-
locations_default(#20006,#10000,1,1,1,26)
27-
hasLocation(#20005,#20006)
28-
#20007=*
29-
lines(#20007,#20001,"}","")
30-
#20008=@"loc,{#10000},2,1,2,1"
31-
locations_default(#20008,#10000,2,1,2,1)
32-
hasLocation(#20007,#20008)
33-
numlines(#20001,2,0,0)
34-
numlines(#10000,2,0,0)
15+
#20003=@"loc,{#10000},1,1,1,26"
16+
locations_default(#20003,#10000,1,1,1,26)
17+
hasLocation(#20002,#20003)
18+
#20004=*
19+
lines(#20004,#20001,"}","")
20+
#20005=@"loc,{#10000},2,1,2,1"
21+
locations_default(#20005,#10000,2,1,2,1)
22+
hasLocation(#20004,#20005)
23+
numlines(#20001,2,2,0)
24+
#20006=*
25+
tokeninfo(#20006,7,#20001,0,"function")
26+
#20007=@"loc,{#10000},1,1,1,8"
27+
locations_default(#20007,#10000,1,1,1,8)
28+
hasLocation(#20006,#20007)
29+
#20008=*
30+
tokeninfo(#20008,6,#20001,1,"f")
31+
#20009=@"loc,{#10000},1,10,1,10"
32+
locations_default(#20009,#10000,1,10,1,10)
33+
hasLocation(#20008,#20009)
34+
#20010=*
35+
tokeninfo(#20010,8,#20001,2,"(")
36+
#20011=@"loc,{#10000},1,11,1,11"
37+
locations_default(#20011,#10000,1,11,1,11)
38+
hasLocation(#20010,#20011)
39+
#20012=*
40+
tokeninfo(#20012,6,#20001,3,"x")
41+
#20013=@"loc,{#10000},1,12,1,12"
42+
locations_default(#20013,#10000,1,12,1,12)
43+
hasLocation(#20012,#20013)
44+
#20014=*
45+
tokeninfo(#20014,8,#20001,4,",")
46+
#20015=@"loc,{#10000},1,13,1,13"
47+
locations_default(#20015,#10000,1,13,1,13)
48+
hasLocation(#20014,#20015)
49+
#20016=*
50+
tokeninfo(#20016,8,#20001,5,"...")
51+
#20017=@"loc,{#10000},1,15,1,17"
52+
locations_default(#20017,#10000,1,15,1,17)
53+
hasLocation(#20016,#20017)
54+
#20018=*
55+
tokeninfo(#20018,8,#20001,6,"[")
56+
#20019=@"loc,{#10000},1,18,1,18"
57+
locations_default(#20019,#10000,1,18,1,18)
58+
hasLocation(#20018,#20019)
59+
#20020=*
60+
tokeninfo(#20020,6,#20001,7,"y")
61+
#20021=@"loc,{#10000},1,19,1,19"
62+
locations_default(#20021,#10000,1,19,1,19)
63+
hasLocation(#20020,#20021)
64+
#20022=*
65+
tokeninfo(#20022,8,#20001,8,",")
66+
#20023=@"loc,{#10000},1,20,1,20"
67+
locations_default(#20023,#10000,1,20,1,20)
68+
hasLocation(#20022,#20023)
69+
#20024=*
70+
tokeninfo(#20024,6,#20001,9,"z")
71+
#20025=@"loc,{#10000},1,22,1,22"
72+
locations_default(#20025,#10000,1,22,1,22)
73+
hasLocation(#20024,#20025)
74+
#20026=*
75+
tokeninfo(#20026,8,#20001,10,"]")
76+
#20027=@"loc,{#10000},1,23,1,23"
77+
locations_default(#20027,#10000,1,23,1,23)
78+
hasLocation(#20026,#20027)
79+
#20028=*
80+
tokeninfo(#20028,8,#20001,11,")")
81+
#20029=@"loc,{#10000},1,24,1,24"
82+
locations_default(#20029,#10000,1,24,1,24)
83+
hasLocation(#20028,#20029)
84+
#20030=*
85+
tokeninfo(#20030,8,#20001,12,"{")
86+
#20031=@"loc,{#10000},1,26,1,26"
87+
locations_default(#20031,#10000,1,26,1,26)
88+
hasLocation(#20030,#20031)
89+
#20032=*
90+
tokeninfo(#20032,8,#20001,13,"}")
91+
hasLocation(#20032,#20005)
92+
#20033=*
93+
tokeninfo(#20033,0,#20001,14,"")
94+
#20034=@"loc,{#10000},2,2,2,1"
95+
locations_default(#20034,#10000,2,2,2,1)
96+
hasLocation(#20033,#20034)
97+
toplevels(#20001,0)
98+
#20035=@"loc,{#10000},1,1,2,1"
99+
locations_default(#20035,#10000,1,1,2,1)
100+
hasLocation(#20001,#20035)
101+
#20036=@"var;{f};{#20000}"
102+
variables(#20036,"f",#20000)
103+
#20037=@"var;{this};{#20000}"
104+
variables(#20037,"this",#20000)
105+
#20038=*
106+
stmts(#20038,17,#20001,0,"functio ... z]) {\n}")
107+
hasLocation(#20038,#20035)
108+
stmt_containers(#20038,#20001)
109+
#20039=*
110+
exprs(#20039,78,#20038,-1,"f")
111+
hasLocation(#20039,#20009)
112+
expr_containers(#20039,#20038)
113+
literals("f","f",#20039)
114+
decl(#20039,#20036)
115+
#20040=*
116+
scopes(#20040,1)
117+
scopenodes(#20038,#20040)
118+
scopenesting(#20040,#20000)
119+
#20041=@"var;{this};{#20040}"
120+
variables(#20041,"this",#20040)
121+
#20042=@"var;{x};{#20040}"
122+
variables(#20042,"x",#20040)
123+
#20043=*
124+
exprs(#20043,78,#20038,0,"x")
125+
hasLocation(#20043,#20013)
126+
expr_containers(#20043,#20038)
127+
literals("x","x",#20043)
128+
decl(#20043,#20042)
129+
#20044=@"var;{y};{#20040}"
130+
variables(#20044,"y",#20040)
131+
#20045=@"var;{z};{#20040}"
132+
variables(#20045,"z",#20040)
133+
#20046=*
134+
exprs(#20046,67,#20038,1,"[y, z]")
135+
#20047=@"loc,{#10000},1,18,1,23"
136+
locations_default(#20047,#10000,1,18,1,23)
137+
hasLocation(#20046,#20047)
138+
expr_containers(#20046,#20038)
139+
#20048=*
140+
exprs(#20048,78,#20046,0,"y")
141+
hasLocation(#20048,#20021)
142+
expr_containers(#20048,#20038)
143+
literals("y","y",#20048)
144+
decl(#20048,#20044)
145+
#20049=*
146+
exprs(#20049,78,#20046,1,"z")
147+
hasLocation(#20049,#20025)
148+
expr_containers(#20049,#20038)
149+
literals("z","z",#20049)
150+
decl(#20049,#20045)
151+
array_size(#20046,2)
152+
#20050=@"var;{arguments};{#20040}"
153+
variables(#20050,"arguments",#20040)
154+
is_arguments_object(#20050)
155+
has_rest_parameter(#20038)
156+
#20051=*
157+
stmts(#20051,1,#20038,-2,"{\n}")
158+
#20052=@"loc,{#10000},1,26,2,1"
159+
locations_default(#20052,#10000,1,26,2,1)
160+
hasLocation(#20051,#20052)
161+
stmt_containers(#20051,#20038)
162+
#20053=*
163+
entry_cfg_node(#20053,#20001)
164+
#20054=@"loc,{#10000},1,1,1,0"
165+
locations_default(#20054,#10000,1,1,1,0)
166+
hasLocation(#20053,#20054)
167+
#20055=*
168+
exit_cfg_node(#20055,#20001)
169+
hasLocation(#20055,#20034)
170+
successor(#20038,#20055)
171+
#20056=*
172+
entry_cfg_node(#20056,#20038)
173+
hasLocation(#20056,#20054)
174+
#20057=*
175+
exit_cfg_node(#20057,#20038)
176+
hasLocation(#20057,#20034)
177+
successor(#20051,#20057)
178+
successor(#20046,#20048)
179+
successor(#20049,#20051)
180+
successor(#20048,#20049)
181+
successor(#20043,#20046)
182+
successor(#20056,#20043)
183+
successor(#20039,#20038)
184+
successor(#20053,#20039)
185+
numlines(#10000,2,2,0)
35186
filetype(#10000,"javascript")

0 commit comments

Comments
 (0)