Skip to content
This repository was archived by the owner on Apr 1, 2025. It is now read-only.

Commit 7763028

Browse files
committed
🔥 MFree.
1 parent a9894d0 commit 7763028

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

semantic-core/src/Analysis/Typecheck.hs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ data Monotype a
4141
| MUnit
4242
| MString
4343
| MMeta a
44-
| MFree Gensym
4544
| MArr (Monotype a) (Monotype a)
4645
| MRecord (Map.Map User (Monotype a))
4746
deriving (Eq, Functor, Ord, Show)
@@ -86,7 +85,6 @@ generalize ty = namespace "generalize" $ do
8685
MBool -> PBool
8786
MString -> PString
8887
MMeta i -> PFree (Gensym root i)
89-
MFree n -> PFree n
9088
MArr a b -> PArr (fold root a) (fold root b)
9189
MRecord fs -> PRecord (fold root <$> fs)
9290

@@ -209,7 +207,6 @@ instance FreeVariables (Monotype Meta) where
209207
mvs MString = mempty
210208
mvs (MArr a b) = mvs a <> mvs b
211209
mvs (MMeta m) = IntSet.singleton m
212-
mvs (MFree _) = mempty
213210
mvs (MRecord fs) = foldMap mvs fs
214211

215212
instance FreeVariables Constraint where
@@ -228,7 +225,6 @@ instance Substitutable (Monotype Meta) where
228225
| m := t <- s
229226
, m == m' -> t
230227
| otherwise -> MMeta m'
231-
MFree n -> MFree n
232228
MRecord fs -> MRecord (subst s <$> fs)
233229

234230
instance Substitutable Constraint where

0 commit comments

Comments
 (0)