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

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

Issue 1093143004: fixes #52, fields shadowing getters/setters or other fields (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 8 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/cascade.js ('k') | test/codegen/expect/fields.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/codegen/expect/constructors.js
diff --git a/test/codegen/expect/constructors.js b/test/codegen/expect/constructors.js
index 4fb06b7c78bdcf4b32eb76d6eb90753fddf2edc8..5bfee7fbf9c0c3e23ce4715dede231bd15e584f3 100644
--- a/test/codegen/expect/constructors.js
+++ b/test/codegen/expect/constructors.js
@@ -26,7 +26,7 @@ var constructors;
dart.defineNamedConstructor(D, 'named');
class E extends core.Object {
E(name) {
- this.name = name;
+ dart.initField(E, this, 'name', name);
}
}
class F extends E {
@@ -47,31 +47,31 @@ var constructors;
}
class I extends core.Object {
I() {
- this.name = 'default';
+ dart.initField(I, this, 'name', 'default');
}
named(name) {
- this.name = name;
+ dart.initField(I, this, 'name', name);
}
}
dart.defineNamedConstructor(I, 'named');
class J extends core.Object {
J() {
- this.initialized = true;
- this.nonInitialized = null;
+ dart.initField(J, this, 'initialized', true);
+ dart.initField(J, this, 'nonInitialized', null);
}
}
class K extends core.Object {
K() {
- this.s = 'a';
+ dart.initField(K, this, 's', 'a');
}
withS(s) {
- this.s = s;
+ dart.initField(K, this, 's', s);
}
}
dart.defineNamedConstructor(K, 'withS');
class L extends core.Object {
L(foo) {
- this.foo = foo;
+ dart.initField(L, this, 'foo', foo);
}
}
class M extends L {
« no previous file with comments | « test/codegen/expect/cascade.js ('k') | test/codegen/expect/fields.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698