on master help sign in
Improve the Show instance for LCase.
commitacd4c7eceeee6637f16bec071240f2f2c6483486 authorMatus Tejiscak <ziman@functor.sk> dateTue 25 Feb 2014, 13:24 (13 years ago) parent52ea5a0
1 file changed+2−2
src/IRTS/Lang.hs+2−2
src/IRTS/Lang.hs+2−2
@@ -228,8 +228,8 @@ instance Show LExp where
228228 show' (env ++ (map show args)) e
229229 show' env (LProj t i) = show t ++ "!" ++ show i
230230 show' env (LCon i n args) = show n ++ ")" ++ showSep ", " (map (show' env) args) ++ ")"
231− show' env (LCase e alts) = "case " ++ show' env e ++ " of {\n\t" ++
232− showSep "\n\t| " (map (showAlt env) alts)
231+ show' env (LCase e alts) = "case " ++ show' env e ++ " of \n" ++
232+ unlines (map (("\t | " ++) . showAlt env) alts)
233233 show' env (LConst c) = show c
234234 show' env (LForeign lang ty n args) = concat
235235 [ "foreign{ "