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

Unified Diff: tests/lib/mirrors/unnamed_mixin_application_test.dart

Issue 2519383002: Handle forwarding constructors of unnamed mixin applications for reflection (Closed)
Patch Set: Created 4 years, 1 month 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 | « pkg/compiler/lib/src/js_backend/mirrors_analysis.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/mirrors/unnamed_mixin_application_test.dart
diff --git a/tests/lib/mirrors/unnamed_mixin_application_test.dart b/tests/lib/mirrors/unnamed_mixin_application_test.dart
new file mode 100644
index 0000000000000000000000000000000000000000..782774b55b69c101bb5bcdace121d7ea464086f2
--- /dev/null
+++ b/tests/lib/mirrors/unnamed_mixin_application_test.dart
@@ -0,0 +1,24 @@
+// 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.
+
+/// Test that the forwarding constructors of unnamed mixin applications are
+/// included for reflection.
+
+import 'dart:mirrors';
+
+class S {
+ S();
+ S.anUnusedName();
+}
+class M {}
+class C extends S with M {
+ C();
+}
+
+main() {
+ // Use 'C#', 'S+M#' and 'S#' but not 'S#anUnusedName' nor 'S+M#anUnusedName'.
+ new C();
+ // Disable tree shaking making 'S+M#anUnusedName' live.
+ reflectClass(C);
+}
« no previous file with comments | « pkg/compiler/lib/src/js_backend/mirrors_analysis.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698