on 52182bc help sign in
project-m36/src/lib/ProjectM36/TypeConstructorDef.hs
11 lines 372 B history raw
1module ProjectM36.TypeConstructorDef where
2import ProjectM36.Base
4name :: TypeConstructorDef -> TypeConstructorName
5name (ADTypeConstructorDef nam _) = nam
6name (PrimitiveTypeConstructorDef nam _) = nam
8typeVars :: TypeConstructorDef -> [TypeVarName]
9typeVars (PrimitiveTypeConstructorDef _ _) = []
10typeVars (ADTypeConstructorDef _ args) = args