Index: test/codegen/lib/mirrors/array_tracing2_test.dart |
diff --git a/test/codegen/language/issue14242_test.dart b/test/codegen/lib/mirrors/array_tracing2_test.dart |
similarity index 54% |
copy from test/codegen/language/issue14242_test.dart |
copy to test/codegen/lib/mirrors/array_tracing2_test.dart |
index 1bd3fe694c2dd40d7f96307fc60df42f855b8f42..39411a10b77846901fde1642dc57c9151f13aad6 100644 |
--- a/test/codegen/language/issue14242_test.dart |
+++ b/test/codegen/lib/mirrors/array_tracing2_test.dart |
@@ -2,19 +2,18 @@ |
// 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. |
-// Regression test for dart2js that used to crash on type literals |
-// used in a cascade send. |
+import 'dart:mirrors'; |
class A { |
- var bar; |
- var foo = {}; |
+ var field; |
} |
main() { |
var a = new A(); |
- a..foo[Object] = 54 |
- ..bar = 42; |
- if (a.foo.keys.first is! Type) { |
- throw 'Test failed'; |
- } |
+ var mirror = reflect(a); |
+ var array = [42]; |
+ a.field = array; |
+ var field = mirror.getField(#field); |
+ field.invoke(#clear, []); |
+ if (array.length == 1) throw 'Test failed'; |
} |