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

Unified Diff: dart/tests/language/crash_12118_test.dart

Issue 22300007: Compute the correct signature for default constructors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 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: dart/tests/language/crash_12118_test.dart
diff --git a/dart/samples/tests/samples/browser/hi_test.dart b/dart/tests/language/crash_12118_test.dart
similarity index 54%
copy from dart/samples/tests/samples/browser/hi_test.dart
copy to dart/tests/language/crash_12118_test.dart
index 111797989253b6d72139ba36035872e9c3e54338..fea6996b338a21202bfd9d7197d1ea354b44a12b 100644
--- a/dart/samples/tests/samples/browser/hi_test.dart
+++ b/dart/tests/language/crash_12118_test.dart
@@ -2,16 +2,19 @@
// 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.
-library hi_test;
+// Regression test for issue 12118 which caused a crash in dart2js.
-import '../../../hi/hi.dart' as hi;
+const X = 42;
-// @static-clean
+class A {
+ final x;
+ A({this.x: X});
+}
+
+class B extends A {}
-/**
- * This test exists to ensure that the hi sample compiles without errors.
- */
void main() {
-
+ if (new B().x != 42) {
+ throw 'Test failed';
+ }
}
-

Powered by Google App Engine
This is Rietveld 408576698