dart-sdk/pkg/front_end/testcases/no_such_method_forwarders/interface_with_concrete.dart
Johnni Winther 77e24a6736 [cfe] Migrate noSuchMethod forwarder tests to null-safety
Change-Id: I7fbfc06a864eaaf4052b736d756410be5d1ab531
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/275601
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2022-12-14 13:12:09 +00:00

22 lines
540 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.
// This method checks that the noSuchMethod forwarder is generated in cases when
// the class of the implemented interface has concrete methods.
class A {
dynamic noSuchMethod(Invocation i) {
return null;
}
}
class I {
// This method is concrete.
void foo() {}
}
class B extends A implements I {}
main() {}