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

Side by Side Diff: tests/language/parameter_initializer_test.dart

Issue 1021813002: Redo "Use an explicit 'this' parameter instead of 'This' nodes." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart ('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
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import "package:expect/expect.dart"; 5 import "package:expect/expect.dart";
6 6
7 class ParameterInitializerTest { 7 class ParameterInitializerTest {
8 8
9 static testMain() { 9 static testMain() {
10
10 var obj = new Foo.untyped(1); 11 var obj = new Foo.untyped(1);
11 Expect.equals(1, obj.x); 12 Expect.equals(1, obj.x);
12 13
13 obj = new Foo.supertype(9); 14 obj = new Foo.supertype(9);
14 Expect.equals(9, obj.x); 15 Expect.equals(9, obj.x);
15 16
16 obj = new Foo.subtype(7); 17 obj = new Foo.subtype(7);
17 Expect.equals(7, obj.x); 18 Expect.equals(7, obj.x);
18 19
19 obj = new Foo.optional(111); 20 obj = new Foo.optional(111);
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 Expect.equals(x_, 1); 77 Expect.equals(x_, 1);
77 78
78 // There is no way to get to the field in Foo. 79 // There is no way to get to the field in Foo.
79 Expect.equals(super.x, 1); 80 Expect.equals(super.x, 1);
80 } 81 }
81 } 82 }
82 83
83 main() { 84 main() {
84 ParameterInitializerTest.testMain(); 85 ParameterInitializerTest.testMain();
85 } 86 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698