fromString for Fix

This commit is contained in:
crumbtoo
2024-02-26 14:59:37 -07:00
parent c8967572a6
commit 4bbf3a3afe

View File

@@ -88,6 +88,9 @@ type Expr b = Fix (ExprF b)
instance IsString (ExprF b a) where instance IsString (ExprF b a) where
fromString = VarF . fromString fromString = VarF . fromString
instance (IsString (f (Fix f))) => IsString (Fix f) where
fromString = Fix . fromString
data Type = TyFun data Type = TyFun
| TyVar Name | TyVar Name
| TyApp Type Type | TyApp Type Type