OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
| 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. |
| 4 |
| 5 // Verify that when no constructors are forwarded from the base class |
| 6 // through a mixin, it is always an error; the mixin does not acquire an |
| 7 // implicit default constructor. |
| 8 |
| 9 abstract class Mixin {} |
| 10 |
| 11 class Base { |
| 12 Base( |
| 13 {x} /// 01: compile-time error |
| 14 {x} /// 02: compile-time error |
| 15 {x} /// 03: compile-time error |
| 16 ); |
| 17 } |
| 18 |
| 19 class C extends Base with Mixin { |
| 20 C(); /// 02: continued |
| 21 C() : super(); /// 03: continued |
| 22 } |
| 23 |
| 24 main() { |
| 25 new C(); |
| 26 } |
OLD | NEW |