@@ -55,11 +55,12 @@ instance Pretty (Expr t v) where
5555 Var x -> variable x
5656 Range e1 e2 -> P.brackets (pretty e1 <> P.text ".." <> pretty e2)
5757 ExplicitList es -> P.brackets (commaCat (map pretty es))
58− Binop op e1 e2 -> P.sep [ prettyParens e1 <+> P.text op, prettyParens e2 ]
58+ Binop op e1 e2 -> P.sep [ prettyParens e1 <+> P.text op', prettyParens e2 ]
59+ where op' = if Help.isOp op then op else "`" ++ op ++ "`"
5960 Lambda p e -> let (ps,body) = collectLambdas (Location.none $ Lambda p e)
6061 in P.text "\\" <> P.sep ps <+> P.text "->" <+> pretty body
6162 App _ _ -> P.hang func 2 (P.sep args)
62− where func:args = map prettyParens (collectApps (Location.none expr))
63+ where func:args = map prettyParens (collectApps (Location.none expr))
6364 MultiIf branches -> P.text "if" $$ nest 3 (vcat $ map iff branches)
6465 where
6566 iff (b,e) = P.text "|" <+> P.hang (pretty b <+> P.text "->") 2 (pretty e)