git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Merge pull request #871 from purescript/870
ef20095Phil Freeman
examples/passing/UnknownInInstance.pursdeleted−8
@@ -1,8 +0,0 @@
1−module Main where
2−
3−data Proxy a = Proxy
4−
5−test :: forall a. (Show (Proxy a)) => String
6−test = show Proxy
7−
8−main = Debug.Trace.trace "Done"
src/Language/PureScript/TypeChecker/Entailment.hs−3
@@ -202,9 +202,6 @@ entails env moduleName context = solve (sortedNubBy canonicalizeDictionary (filt
202typeHeadsAreEqual :: ModuleName -> Environment -> Type -> Type -> Maybe [(String, Type)]
202typeHeadsAreEqual :: ModuleName -> Environment -> Type -> Type -> Maybe [(String, Type)]
203typeHeadsAreEqual _ _ (Skolem _ s1 _) (Skolem _ s2 _) | s1 == s2 = Just []
203typeHeadsAreEqual _ _ (Skolem _ s1 _) (Skolem _ s2 _) | s1 == s2 = Just []
204typeHeadsAreEqual _ _ t (TypeVar v) = Just [(v, t)]
204typeHeadsAreEqual _ _ t (TypeVar v) = Just [(v, t)]
205−-- In this case, we might want type information to flow back to the typechecker.
206−-- TODO: run this function in the UnifyT monad.
207−typeHeadsAreEqual _ _ (TUnknown _) _ = Just []
208typeHeadsAreEqual _ _ (TypeConstructor c1) (TypeConstructor c2) | c1 == c2 = Just []
205typeHeadsAreEqual _ _ (TypeConstructor c1) (TypeConstructor c2) | c1 == c2 = Just []
209typeHeadsAreEqual m e (TypeApp h1 t1) (TypeApp h2 t2) = (++) <$> typeHeadsAreEqual m e h1 h2
206typeHeadsAreEqual m e (TypeApp h1 t1) (TypeApp h2 t2) = (++) <$> typeHeadsAreEqual m e h1 h2
210 <*> typeHeadsAreEqual m e t1 t2
207 <*> typeHeadsAreEqual m e t1 t2