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

Unified Diff: tests/language_strong/checked_covariant_overrides_test.dart

Issue 2641543003: Use "Object" as the reified type of covariant override parameters. (Closed)
Patch Set: Move getReifiedType() to MethodElement. Created 3 years, 11 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
Index: tests/language_strong/checked_covariant_overrides_test.dart
diff --git a/tests/language_strong/checked_covariant_overrides_test.dart b/tests/language_strong/checked_covariant_overrides_test.dart
deleted file mode 100644
index 6f538dcae3d064bc114b2f293d2d545ab903007e..0000000000000000000000000000000000000000
--- a/tests/language_strong/checked_covariant_overrides_test.dart
+++ /dev/null
@@ -1,36 +0,0 @@
-// Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-import "package:expect/expect.dart";
-import 'package:meta/meta.dart' show checked;
-
-// Test runtime behavior of @checked
-
-class View {
- addChild(View v) {}
- transform(View fn(View v)) {}
-}
-class MyView extends View {
- addChild(@checked MyView v) {}
- transform(@checked MyView fn(Object v)) {}
-}
-
-main() {
- dynamic mv = new MyView();
- dynamic v = new View();
-
- mv.addChild(mv);
- Expect.throws(() => mv.addChild(v));
-
- mv.transform((_) => new MyView());
-
- // TODO(jmesserly): these *should* be a cast failures, but DDC is currently
- // ignoring function type failures w/ a warning at the console...
-
- // * -> * not a subtype of Object -> MyView
- // Expect.throws(() => mv.transform((_) => mv));
-
- // View -> View not a subtype of Object -> MyView
- // Expect.throws(() => mv.transform((View x) => x));
-}

Powered by Google App Engine
This is Rietveld 408576698