dart-sdk/tests/language_2/conflicting_generic_interfaces_simple_test.dart
Paul Berry 2993476129 Report an error if a class inconsistently implements a generic interface.
This is not allowed in Dart 2.0.

Change-Id: I6861ce298e5d5a5cf3f26a010990868b5ba9bda2
Reviewed-on: https://dart-review.googlesource.com/39601
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-03-05 12:13:12 +00:00

17 lines
435 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.
// Dart test program to test arithmetic operations.
class I<T> {}
class A implements I<int> {}
class B implements I<String> {}
/*@compile-error=unspecified*/ class C extends A implements B {}
main() {
new C();
}