blob: 2ac3d34f08d451d281a4088fbe684cfd1ba55f1a [file] [log] [blame]
library lib;
import "deferred_mirrors_metadata_test.dart";
@MirrorsUsed(
targets: const ["main", "main.A", "main.B", "main.C", "main.D", "lib.E"])
import "dart:mirrors";
class H {
const H();
}
class F {
@H()
final int f;
}
@C()
class E {
@D()
var f;
}
String foo() {
String c = reflectClass(E).metadata[0].invoke(#toString, []).reflectee;
String d = reflectClass(E)
.declarations[#f]
.metadata[0]
.invoke(#toString, []).reflectee;
InstanceMirror i = currentMirrorSystem().findLibrary(#main).metadata[0];
String a = i.invoke(#toString, []).reflectee;
String b = i.getField(#b).invoke(#toString, []).reflectee;
return a + b + c + d;
}