blob: c695fb330afa55bda93b6880ee63baf65505ac37 [file] [log] [blame]
// Copyright (c) 2011, 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 error for overriding getter with method.
class A {
get foo {
return 123;
}
}
class B extends A {
foo() {} // method cannot override getter.
}
class OverrideFieldMethod2NegativeTest {
static testMain() {
new B().foo();
}
}
main() {
OverrideFieldMethod2NegativeTest.testMain();
}