Skip to content
Snippets Groups Projects
Commit 12c3490c authored by Daniel Trstenjak's avatar Daniel Trstenjak Committed by tibbe
Browse files

Remove 'condTreeConstraints' field from pretty printing

See #2323 for the details.

(cherry picked from commit 370f135a)
parent d3617da7
No related branches found
No related tags found
No related merge requests found
......@@ -215,9 +215,8 @@ ppFlagName :: FlagName -> Doc
ppFlagName (FlagName name) = text name
ppCondTree :: CondTree ConfVar [Dependency] a -> Maybe a -> (a -> Maybe a -> Doc) -> Doc
ppCondTree ct@(CondNode it deps ifs) mbIt ppIt =
let res = ppDeps deps
$+$ (vcat $ map ppIf ifs)
ppCondTree ct@(CondNode it _ ifs) mbIt ppIt =
let res = (vcat $ map ppIf ifs)
$+$ ppIt it mbIt
in if isJust mbIt && isEmpty res
then ppCondTree ct Nothing ppIt
......@@ -234,11 +233,6 @@ ppCondTree ct@(CondNode it deps ifs) mbIt ppIt =
$$ nest indentWith (ppCondTree (fromJust mElseTree)
(if simplifiedPrinting then (Just it) else Nothing) ppIt))
ppDeps :: [Dependency] -> Doc
ppDeps [] = empty
ppDeps deps =
text "build-depends:" $+$ nest indentWith (vcat (punctuate comma (map disp deps)))
emptyLine :: Doc -> Doc
emptyLine d = text "" $+$ d
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment