use of com.rockwellcollins.atc.agree.agree.PatternStatement in project AGREE by loonwerks.
the class AgreeASTBuilder method getLemmaStatements.
private List<AgreeStatement> getLemmaStatements(EList<SpecStatement> specs) {
List<AgreeStatement> lemmas = new ArrayList<>();
for (SpecStatement spec : specs) {
if (spec instanceof LemmaStatement) {
LemmaStatement lemma = (LemmaStatement) spec;
if (lemma.getExpr() != null) {
lemmas.add(new AgreeStatement(lemma.getStr(), doSwitch(lemma.getExpr()), spec));
} else {
PatternStatement pattern = lemma.getPattern();
lemmas.add(new AgreePatternBuilder(lemma.getStr(), lemma, this).doSwitch(pattern));
}
}
}
return lemmas;
}
Aggregations