Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: test/mjsunit/harmony/modules-html-comments.js

Issue 2009963002: [modules] Disable HTML-like comments Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Unify behavior for optimized and non-optimized executions Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/cctest/test-parsing.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 //
5 // Flags: --allow-natives-syntax
6 //
7 // MODULE
8
9 var x = 1;
10 x --> 0;
11 assertEquals(0, x, 'a');
12
13 var x = 0; x <!-- x
14 assertEquals(-1, x, 'b');
15
16 var x = 1; x <!--x
17 assertEquals(0, x, 'c');
18
19 var x = 2; x <!-- x; x = 42;
20 assertEquals(42, x, 'd');
21
22 var x = 1; x <! x--;
23 assertEquals(0, x, 'e');
24
25 var x = 1; x <!- x--;
26 assertEquals(0, x, 'f');
27
28 var b = true <! true;
29 assertFalse(b, 'g');
30
31 var b = true <!- true;
32 assertFalse(b, 'h');
33
34 function f() {
35 var x = 9;
36 x --> 0 && 0 <!-- x;
37 return x;
38 }
39
40 %DeoptimizeFunction(f);
41
42 assertEquals(f(), 7);
43
44 %OptimizeFunctionOnNextCall(f);
45
46 assertEquals(f(), 7);
OLDNEW
« no previous file with comments | « test/cctest/test-parsing.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698