dart-sdk/tests/language_2/regress_33235_14_test.dart
Dmitry Stefantsov 7d6cd21706 CFE and member conflict rules
See https://github.com/dart-lang/sdk/issues/32613
and https://github.com/dart-lang/sdk/issues/33235#issue-326617285

Bug: #32613, #33235, #33237
Change-Id: I0d1432185b6811137e31135ac2c7f58c4de2de6c
Reviewed-on: https://dart-review.googlesource.com/64500
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Erik Ernst <eernst@google.com>
2018-07-16 14:09:01 +00:00

31 lines
756 B
Dart

// Copyright (c) 2018, the Dart project authors. Please see the AUTHORS file
// 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.
// Test for complience with tables at
// https://github.com/dart-lang/sdk/issues/33235#issue-326617285
// Files 01 to 16 should be compile time errors, files 17 to 21 should not.
class A {
void set n(int x) {}
}
class B extends A {
static void set n(int i) {} // //# 02: compile-time error
}
abstract class B2 implements A {
static void set n(int i) {} // //# 03: compile-time error
}
class C {
static void set n(int i) {} // //# 01: compile-time error
void set n(int x) {}
}
main() {
print(C);
print(B);
print(B2);
}