diff --git a/Cabal/Distribution/PackageDescription/PrettyPrint.hs b/Cabal/Distribution/PackageDescription/PrettyPrint.hs index 482f8dc64d5..6b39628192a 100644 --- a/Cabal/Distribution/PackageDescription/PrettyPrint.hs +++ b/Cabal/Distribution/PackageDescription/PrettyPrint.hs @@ -109,7 +109,7 @@ ppGenPackageFlags flds = vcat [ppFlag f | f <- flds] ppFlag :: Flag -> Doc ppFlag flag@(MkFlag name _ _ _) = - emptyLine $ text "flag" <+> ppFlagName name $+$ fields + emptyLine $ text "flag" <+> ppFlagName name $+$ nest indentWith fields where fields = ppFieldsFiltered flagDefaults flagFieldDescrs flag diff --git a/Cabal/Distribution/ParseUtils.hs b/Cabal/Distribution/ParseUtils.hs index 8f6d9ef1a29..e507a7a8661 100644 --- a/Cabal/Distribution/ParseUtils.hs +++ b/Cabal/Distribution/ParseUtils.hs @@ -284,6 +284,7 @@ ppField name fielddoc , "includes" , "install-includes" , "other-modules" + , "depends" ] showFields :: [FieldDescr a] -> a -> String @@ -733,7 +734,6 @@ showTestedWith (compiler, version) = text (show compiler) <+> disp version -- and with blank lines replaced by dots for correct re-parsing. showFreeText :: String -> Doc showFreeText "" = empty -showFreeText ('\n' :r) = text " " $+$ text "." $+$ showFreeText r showFreeText s = vcat [text (if null l then "." else l) | l <- lines_ s] -- | 'lines_' breaks a string up into a list of strings at newline