blob: b82c6a01fa7dba800ec5f9d3eb5a658942fb5f20 [file] [log] [blame]
import org.checkerframework.framework.testchecker.testaccumulation.qual.*;
public class SimpleInference {
void build(@TestAccumulation({"a"}) SimpleInference this) {}
void doublebuild(@TestAccumulation({"a", "b"}) SimpleInference this) {}
void a() {}
void b() {}
static void doStuffCorrect() {
SimpleInference s = new SimpleInference();
s.a();
s.build();
}
static void doStuffCorrect2() {
SimpleInference s = new SimpleInference();
s.a();
s.b();
s.doublebuild();
}
static void doStuffWrong() {
SimpleInference s = new SimpleInference();
// :: error: method.invocation
s.build();
}
static void doStuffWrong2() {
SimpleInference s = new SimpleInference();
s.a();
// :: error: method.invocation
s.doublebuild();
}
}