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

Unified Diff: tests/compiler/dart2js/kernel/impact_test.dart

Issue 2683403002: Handle equivalence for generic mixins. (Closed)
Patch Set: Created 3 years, 10 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 | tests/compiler/dart2js/serialization/test_helper.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/kernel/impact_test.dart
diff --git a/tests/compiler/dart2js/kernel/impact_test.dart b/tests/compiler/dart2js/kernel/impact_test.dart
index 5fd2411e036e09f56319ec7d85920b5eb9c3db90..ccfce70f8ee8b2e7c933f0ebdaf6c46ef2c17b56 100644
--- a/tests/compiler/dart2js/kernel/impact_test.dart
+++ b/tests/compiler/dart2js/kernel/impact_test.dart
@@ -186,6 +186,8 @@ main() {
testNativeField(null);
testMixinInstantiation();
testNamedMixinInstantiation();
+ testGenericMixinInstantiation();
+ testGenericNamedMixinInstantiation();
}
testEmpty() {}
@@ -630,6 +632,8 @@ class NativeClass {
testNativeField(NativeClass c) => c.field;
testMixinInstantiation() => new Sub();
testNamedMixinInstantiation() => new NamedMixin();
+testGenericMixinInstantiation() => new GenericSub<int, String>();
+testGenericNamedMixinInstantiation() => new GenericNamedMixin<int, String>();
''',
'sdk/tests/compiler/dart2js_native/helper.dart': '''
import 'dart:_js_helper';
@@ -654,6 +658,14 @@ class Mixin2 {}
class Sub extends Super with Mixin1, Mixin2 {}
class NamedMixin = Super with Mixin1, Mixin2;
+class GenericSuper<X, Y> {}
+class GenericMixin1<X, Y> {}
+class GenericMixin2<X, Y> {}
+class GenericSub<X, Y> extends GenericSuper<X, Y>
Siggi Cherem (dart-lang) 2017/02/10 22:11:22 it might be interesting to test using different na
Johnni Winther 2017/02/12 09:46:43 Done.
+ with GenericMixin1<X, Y>, GenericMixin2<X, Y> {}
+class GenericNamedMixin<X, Y> = GenericSuper<X, Y>
+ with GenericMixin1<X, Y>, GenericMixin2<X, Y>;
+
const String _serializedScriptValue =
'num|String|bool|'
'JSExtendableArray|=Object';
« no previous file with comments | « no previous file | tests/compiler/dart2js/serialization/test_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698