Added some missing functionality to the dummy monomorphizer.

This commit is contained in:
Samuel Hammersberg 2023-03-24 10:57:21 +01:00
parent fc60112877
commit 30a79f34af
2 changed files with 18 additions and 2 deletions

View file

@ -40,3 +40,7 @@ data Lit
data Type = TLit Ident | TFun Type Type
deriving (Show, Ord, Eq)
flattenType :: Type -> [Type]
flattenType (TFun t1 t2) = t1 : flattenType t2
flattenType x = [x]