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

Side by Side Diff: tests/language/mixin_forwarding_constructor4_test.dart

Issue 707073002: Fix analyzer's treatment of mixin constructors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Improve error message. Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(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 }
OLDNEW
« no previous file with comments | « tests/language/mixin_forwarding_constructor3_test.dart ('k') | tests/language/mixin_super_constructor_named_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698