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

Unified Diff: test/codegen/expect/cascade/cascade.js

Issue 949383003: use js_ast instead of strings to generate JS (Closed) Base URL: git@github.com:dart-lang/dart-dev-compiler.git@master
Patch Set: add redirecting ctor test Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/codegen/expect/async/async.js ('k') | test/codegen/expect/collection/collection.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/codegen/expect/cascade/cascade.js
diff --git a/test/codegen/expect/cascade/cascade.js b/test/codegen/expect/cascade/cascade.js
index 21d66d7c341cdfecc70161701abf3d800570dfe2..b2d7c4611326a16c05bbd314d5ca3ae5defc9cd4 100644
--- a/test/codegen/expect/cascade/cascade.js
+++ b/test/codegen/expect/cascade/cascade.js
@@ -1,12 +1,11 @@
var cascade;
-(function (cascade) {
+(function(cascade) {
'use strict';
class A extends dart.Object {
A() {
this.x = null;
}
}
-
// Function test_closure_with_mutate: () → void
function test_closure_with_mutate() {
let a = new A();
@@ -15,60 +14,54 @@ var cascade;
a = null;
};
((_) => {
- dart.dinvoke(_, "x");
- dart.dinvoke(_, "x");
+ dart.dinvoke(_, 'x');
+ dart.dinvoke(_, 'x');
})(a);
core.print(a);
}
-
// Function test_closure_without_mutate: () → void
function test_closure_without_mutate() {
let a = new A();
a.x = () => {
core.print(a);
};
- dart.dinvoke(a, "x");
- dart.dinvoke(a, "x");
+ dart.dinvoke(a, 'x');
+ dart.dinvoke(a, 'x');
core.print(a);
}
-
// Function test_mutate_inside_cascade: () → void
function test_mutate_inside_cascade() {
let a = null;
a = ((_) => {
- _.x = (a = null);
- _.x = (a = null);
+ _.x = a = null;
+ _.x = a = null;
return _;
})(new A());
core.print(a);
}
-
// Function test_mutate_outside_cascade: () → void
function test_mutate_outside_cascade() {
let a = null, b = null;
a = new A();
- dart.dput(a, "x", (b = null));
- dart.dput(a, "x", (b = null));
+ dart.dput(a, 'x', b = null);
+ dart.dput(a, 'x', b = null);
a = null;
core.print(a);
}
-
// Function test_VariableDeclaration_single: () → void
function test_VariableDeclaration_single() {
let a = new List.from([]);
- dart.dput(a, "length", 2);
+ dart.dput(a, 'length', 2);
a.add(42);
core.print(a);
}
-
// Function test_VariableDeclaration_last: () → void
function test_VariableDeclaration_last() {
let a = 42, b = new List.from([]);
- dart.dput(b, "length", 2);
+ dart.dput(b, 'length', 2);
b.add(a);
core.print(b);
}
-
// Function test_VariableDeclaration_first: () → void
function test_VariableDeclaration_first() {
let a = ((_) => {
@@ -78,7 +71,6 @@ var cascade;
})(new List.from([])), b = 2;
core.print(a);
}
-
// Exports:
cascade.A = A;
cascade.test_closure_with_mutate = test_closure_with_mutate;
« no previous file with comments | « test/codegen/expect/async/async.js ('k') | test/codegen/expect/collection/collection.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698