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

Unified Diff: pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart

Issue 3010613003: Simplify annotations in runtime check tests. (Closed)
Patch Set: Address code review comment Created 3 years, 4 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: pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart
diff --git a/pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart b/pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart
index 2febace9c66fe7a335ed054faa9af61b98d09612..f9251d161799318401b2dba94a361b621c3e0eb7 100644
--- a/pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart
+++ b/pkg/front_end/testcases/runtime_checks/covariant_generic_parameter_complex.dart
@@ -7,28 +7,31 @@ library test;
class C<T> {
// List<T> is covariant in T so it needs checking
- void f1(List<T> /*@checkFormal=semiSafe*/ x) {}
+ void f1(List<T> /*@checkFormal=semiSafe*/ /*@checkInterface=semiTyped*/ x) {}
// () -> T is covariant in T so it needs checking
- void f2(T /*@checkFormal=semiSafe*/ callback()) {}
+ void f2(
+ T /*@checkFormal=semiSafe*/ /*@checkInterface=semiTyped*/ callback()) {}
// (T) -> T is partially covariant in T so it needs checking
- void f3(T /*@checkFormal=semiSafe*/ callback(T x)) {}
+ void f3(
+ T /*@checkFormal=semiSafe*/ /*@checkInterface=semiTyped*/ callback(
+ T x)) {}
// (T) -> void is contravariant in T so it doesn't need checking
void f4(void callback(T x)) {}
}
void g1(C<num> c, List<num> l) {
- c.f1 /*@checkCall=interface(semiTyped:0)*/ (l);
+ c.f1(l);
}
void g2(C<num> c, num callback()) {
- c.f2 /*@checkCall=interface(semiTyped:0)*/ (callback);
+ c.f2(callback);
}
void g3(C<num> c, num callback(num x)) {
- c.f3 /*@checkCall=interface(semiTyped:0)*/ (callback);
+ c.f3(callback);
}
void g4(C<num> c, void callback(num x)) {

Powered by Google App Engine
This is Rietveld 408576698