git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Fix prettyprinting of dictionaries
commitd81ea934a23decdd53fa91fbf428a4bacbc26f24 authorGary Burgess <gary.burgess@gmail.com> dateSun 8 Mar 2015, 18:16 (12 years ago) parentedcefcb
1 file changed+2−2
src/Language/PureScript/Pretty/Values.hs+2−2
src/Language/PureScript/Pretty/Values.hs+2−2
@@ -29,7 +29,7 @@ import Control.Applicative
2929import Language.PureScript.AST
3030import Language.PureScript.Names
3131import Language.PureScript.Pretty.Common
32−import Language.PureScript.Pretty.Types (prettyPrintType)
32+import Language.PureScript.Pretty.Types (prettyPrintType, prettyPrintTypeAtom)
3333
3434literals :: Pattern PrinterState Expr String
3535literals = mkPattern' match
@@ -76,7 +76,7 @@ literals = mkPattern' match
7676 ]
7777 match (OperatorSection op (Right val)) = return $ "(" ++ prettyPrintValue op ++ " " ++ prettyPrintValue val ++ ")"
7878 match (OperatorSection op (Left val)) = return $ "(" ++ prettyPrintValue val ++ " " ++ prettyPrintValue op ++ ")"
79− match (TypeClassDictionary name _ _) = return $ "<<dict " ++ show name ++ ">>"
79+ match (TypeClassDictionary _ (name, tys) _) = return $ "<<dict " ++ show name ++ " " ++ unwords (map prettyPrintTypeAtom tys) ++ ">>"
8080 match (SuperClassDictionary name _) = return $ "<<superclass dict " ++ show name ++ ">>"
8181 match (TypedValue _ val _) = prettyPrintValue' val
8282 match (PositionedValue _ _ val) = prettyPrintValue' val