| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 import "package:expect/expect.dart"; | |
| 6 | |
| 7 // Test that hidden native class names are not used by generated code. | 5 // Test that hidden native class names are not used by generated code. |
| 8 | 6 |
| 9 class A native "*B" { | 7 class A native "*B" { |
| 10 get name => 'A'; | 8 get name => 'A'; |
| 11 static A create() => makeA(); | 9 static A create() => makeA(); |
| 12 } | 10 } |
| 13 | 11 |
| 14 class B native "*C" { | 12 class B native "*C" { |
| 15 get name => 'B'; | 13 get name => 'B'; |
| 16 static B create() => makeB(); | 14 static B create() => makeB(); |
| (...skipping 30 matching lines...) Expand all Loading... |
| 47 | 45 |
| 48 var things = [A.create(), B.create(), C.create()]; | 46 var things = [A.create(), B.create(), C.create()]; |
| 49 var a = things[inscrutable(0)]; | 47 var a = things[inscrutable(0)]; |
| 50 var b = things[inscrutable(1)]; | 48 var b = things[inscrutable(1)]; |
| 51 var c = things[inscrutable(2)]; | 49 var c = things[inscrutable(2)]; |
| 52 | 50 |
| 53 Expect.equals('A', a.name); | 51 Expect.equals('A', a.name); |
| 54 Expect.equals('B', b.name); | 52 Expect.equals('B', b.name); |
| 55 Expect.equals('C', c.name); | 53 Expect.equals('C', c.name); |
| 56 } | 54 } |
| OLD | NEW |