use of abs.frontend.ast.ParametricDataTypeDecl in project abstools by abstools.
the class PureExpressionBuilder method importType.
void importType(Decl decl) {
importModules.add(decl.getModuleDecl().getName());
if (decl instanceof TypeSynDecl) {
decl = resolveTypeSynonym((TypeSynDecl) decl);
importModules.add(decl.getModuleDecl().getName());
}
// import type parameters
if (decl instanceof ParametricDataTypeDecl) {
for (TypeParameterDecl t : ((ParametricDataTypeDecl) decl).getTypeParameters()) {
Decl type = getDecl(model, Decl.class, namePred(t.getName()));
if (type == null) {
// most likely a generic type
continue;
}
importType(type);
}
}
}
Aggregations