blob: a30e4ee62bf437e934bfed7cb208a9d4f2eb7155 [file] [log] [blame]
// Copyright (c) 2015, 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.
// Regression test for
// Ensure that Mixin prototypes are initialized before first use.
// Mirrors is the only way to have a getter be equipped with metadata.
@MirrorsUsed(targets: 'M', override: '*')
import 'dart:mirrors';
import 'package:expect/expect.dart';
class M {
bool get foo => true;
class A extends Object with M {
bool get foo =>;
bool hide(bool x) => x;
main() {
Expect.isTrue((hide(true) ? new A() : new M()).foo);