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

Unified Diff: tests/language/rewrite_implicit_this_test.dart

Issue 367263003: Fixed static type warning annotation in rewrite_implicit_this_test.dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/rewrite_implicit_this_test.dart
diff --git a/tests/language/rewrite_implicit_this_test.dart b/tests/language/rewrite_implicit_this_test.dart
index 76e5a1fad8620c8c33982202269f4e934e86ec98..5d8166965392efd1ba02eb6e2ca01dc96d017f57 100644
--- a/tests/language/rewrite_implicit_this_test.dart
+++ b/tests/language/rewrite_implicit_this_test.dart
@@ -10,30 +10,30 @@ class Foo {
String x = 'x';
easy(z) {
- return x + y + z;
+ return x + y + z; /// 01: static type warning
}
// Shadow the 'y' field in various ways
shadow_y_parameter(y) {
- return x + this.y + y;
+ return x + this.y + y; /// 01: continued
}
shadow_y_local(z) {
var y = z;
- return x + this.y + y;
+ return x + this.y + y; /// 01: continued
}
shadow_y_capturedLocal(z) {
var y = z;
foo() {
- return x + this.y + y;
+ return x + this.y + y; /// 01: continued
}
return foo();
}
shadow_y_closureParam(z) {
foo(y) {
- return x + this.y + y;
+ return x + this.y + y; /// 01: continued
}
return foo(z);
}
@@ -41,32 +41,32 @@ class Foo {
shadow_y_localInsideClosure(z) {
foo() {
var y = z;
- return x + this.y + y;
+ return x + this.y + y; /// 01: continued
}
return foo();
}
// Shadow the 'x' field in various ways
shadow_x_parameter(x) {
- return this.x + y + x;
+ return this.x + y + x; /// 01: continued
}
shadow_x_local(z) {
var x = z;
- return this.x + y + x;
+ return this.x + y + x; /// 01: continued
}
shadow_x_capturedLocal(z) {
var x = z;
foo() {
- return this.x + y + x;
+ return this.x + y + x; /// 01: continued
}
return foo();
}
shadow_x_closureParam(z) {
foo(x) {
- return this.x + y + x;
+ return this.x + y + x; /// 01: continued
}
return foo(z);
}
@@ -74,13 +74,13 @@ class Foo {
shadow_x_localInsideClosure(z) {
foo() {
var x = z;
- return this.x + y + x;
+ return this.x + y + x; /// 01: continued
}
return foo();
}
shadow_x_toplevel() {
- return x + this.y + toplevel + this.toplevel;
+ return x + this.y + toplevel + this.toplevel; /// 01: continued
}
}
@@ -91,17 +91,17 @@ class Sub extends Foo {
}
main() {
- Expect.equals('xyz', new Sub().easy('z'));
- Expect.equals('xyz', new Sub().shadow_y_parameter('z'));
- Expect.equals('xyz', new Sub().shadow_y_local('z'));
- Expect.equals('xyz', new Sub().shadow_y_capturedLocal('z'));
- Expect.equals('xyz', new Sub().shadow_y_closureParam('z'));
- Expect.equals('xyz', new Sub().shadow_y_localInsideClosure('z'));
- Expect.equals('xyz', new Sub().shadow_x_parameter('z'));
- Expect.equals('xyz', new Sub().shadow_x_local('z'));
- Expect.equals('xyz', new Sub().shadow_x_capturedLocal('z'));
- Expect.equals('xyz', new Sub().shadow_x_closureParam('z'));
- Expect.equals('xyz', new Sub().shadow_x_localInsideClosure('z'));
-
- Expect.equals('xyAB', new Sub().shadow_x_toplevel());
+ Expect.equals('xyz', new Sub().easy('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_y_parameter('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_y_local('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_y_capturedLocal('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_y_closureParam('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_y_localInsideClosure('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_x_parameter('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_x_local('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_x_capturedLocal('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_x_closureParam('z')); /// 01: continued
+ Expect.equals('xyz', new Sub().shadow_x_localInsideClosure('z')); /// 01: continued
+
+ Expect.equals('xyAB', new Sub().shadow_x_toplevel()); /// 01: continued
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698