Home | History | Annotate | Download | only in js

Lines Matching defs:invalid

41             testPassed('Invalid: "' + _a + '"');
46 testFailed('Invalid: "' + _a + '" should throw ' + errorType.name);
59 function invalid(_a, _type)
79 invalid("(a");
80 invalid("a[5");
81 invalid("a[5 + 6");
82 invalid("a.");
83 invalid("()");
84 invalid("a.'l'");
86 invalid("new -a");
91 invalid("a-- ++");
92 invalid("(a:) --b");
96 invalid("delete the void");
97 invalid("(a++");
101 invalid("1: null");
102 invalid("+-!~");
103 invalid("+-!~((");
104 invalid("a)");
105 invalid("a]");
106 invalid(".l");
107 invalid("1.l");
113 invalid("a + * b");
114 invalid("a ? b");
115 invalid("a ? b :");
116 invalid("%a");
117 invalid("a-");
122 invalid("a in instanceof b.l");
124 invalid("- false = 3");
127 invalid("a + typeof b += c in d");
128 invalid("typeof a &= typeof b");
138 invalid("a(");
139 invalid("a(5");
140 invalid("a(5,");
141 invalid("a(5,)");
142 invalid("a(5,6");
144 invalid("a(b[5)");
145 invalid("a(b.)");
147 invalid("a(*a)");
151 invalid("new a(5");
153 invalid("a(.length)");
159 invalid("function () {}");
160 invalid("function f(a b) {}");
161 invalid("function f(a,) {}");
162 invalid("function f(a,");
163 invalid("function f(a, 1) {}");
166 invalid("(function a{})");
167 invalid("(function this(){})");
170 invalid("function l() {");
171 invalid("function l++(){}");
177 invalid("[5,");
178 invalid("[,");
179 invalid("(a,)");
181 invalid("1 + {a");
182 invalid("1 + {a:");
183 invalid("1 + {get l(");
184 invalid(",a");
186 invalid("(,f)");
187 invalid("a,,b");
188 invalid("a ? b, c : d");
193 invalid("{ { }");
196 invalid("{ a: }");
201 invalid("{ if (a) }");
202 invalid("if a {}");
203 invalid("if (a");
204 invalid("if (a { }");
206 invalid("else {}");
208 invalid("if (a) {} else x; else");
209 invalid("if (a) { else }");
212 invalid("with a.b { }");
214 invalid("while a {}");
217 invalid("do g; while 4");
218 invalid("do g; while ((4)");
222 invalid("break ; break your_limits ; continue ; continue living ; debugger");
223 invalid("debugger X");
224 invalid("break 0.2");
225 invalid("continue a++");
226 invalid("continue (my_friend)");
229 invalid("do if (a) while (false) else debugger");
230 invalid("while if (a) ;");
233 invalid("if (a()) function f() { else function g() }");
234 invalid("if (a) if (b) ; else function f {}");
235 invalid("if (a) if (b) ; else function (){}");
238 invalid("throw");
244 invalid("var");
245 invalid("var = 7");
246 invalid("var c (6)");
248 invalid("var 5 = 6");
250 invalid("var a = if (b) { c }");
251 invalid("var a = var b");
253 invalid("var a %= b | 5");
254 invalid("var (a) = 5");
255 invalid("var a = (4, b = 6");
256 invalid("const 'l' = 3");
257 invalid("var var = 3");
261 invalid("var a = ?");
262 invalid("const a = *7");
263 invalid("var a = :)");
265 invalid("var a = b ? c, b");
266 invalid("const a = b : c");
277 invalid("for () { }");
278 invalid("for ( a ) { }");
279 invalid("for ( ; ) ;");
280 invalid("for a ; b ; c { }");
281 invalid("for (a ; { }");
282 invalid("for ( a ; ) ;");
283 invalid("for ( ; a ) break");
288 invalid("for ( ; var a ; ) break");
289 invalid("for (const a; ; ) break");
290 invalid("for ( %a ; ; ) { }");
294 invalid("for (new a in b in c in d) break");
295 invalid("for (new new new a in b) break");
296 invalid("for (delete new a() in b) break");
297 invalid("for (a * a in b) break");
298 invalid("for ((a * a) in b) break");
299 invalid("for (a++ in b) break");
300 invalid("for ((a++) in b) break");
301 invalid("for (++a in b) break");
302 invalid("for ((++a) in b) break");
303 invalid("for (a, b in c) break");
304 invalid("for (a,b in c ;;) break");
306 invalid("for ((a, b) in c) break");
307 invalid("for (a ? b : c in c) break");
308 invalid("for ((a ? b : c) in c) break");
311 invalid("for (var a += 5 in b) break");
312 invalid("for (var a = in b) break");
313 invalid("for (var a, b in b) break");
314 invalid("for (var a = -6, b in b) break");
315 invalid("for (var a, b = 8 in b) break");
317 invalid("for (var a = (b in c in d) break");
318 invalid("for (var (a) in b) { }");
323 invalid("try { break } catch(e) {}");
326 invalid("try {}");
327 invalid("catch(e) {}");
328 invalid("finally {}");
329 invalid("try a; catch(e) {}");
330 invalid("try {} catch(e) a()");
331 invalid("try {} finally a()");
332 invalid("try {} catch(e)");
333 invalid("try {} finally");
334 invalid("try {} finally {} catch(e) {}");
335 invalid("try {} catch (...) {}");
336 invalid("try {} catch {}");
339 invalid("if (a) try {} else b; catch (e) { }");
340 invalid("try { finally {}");
345 invalid("switch () {}");
346 invalid("case 5:");
347 invalid("default:");
348 invalid("switch (a) b;");
349 invalid("switch (a) case 3: b;");
351 invalid("switch (true) { default: case 6: default: }");
352 invalid("switch (l) { f(); }");
353 invalid("switch (l) { case 1: ; a: case 5: }");
355 invalid("switch (g) { case 1: a: }");
356 invalid("switch (g) { case 1: a: default: }");
357 invalid("switch g { case 1: l() }");
358 invalid("switch (g) { case 1:");
361 invalid("switch (l) { case b ? c : }");
363 invalid("switch (4 - ) { }");
364 invalid("switch (l) { default case: 5; }");
366 invalid("L: L: ;");
367 invalid("L: L1: L: ;");
368 invalid("L: L1: L2: L3: L4: L: ;");
370 invalid("for(var a,b 'this shouldn\'t be allowed' false ; ) ;");
371 invalid("for(var a,b '");
392 invalid("var a.b = c");
393 invalid("var a.b;");