Do not put `where` on newline when no export list
(even when lconfig_allowSingleLineExportList False)pull/136/head
parent
21ef8b296c
commit
8b67a028ea
|
@ -33,13 +33,16 @@ layoutModule lmod@(L _ mod') = case mod' of
|
||||||
<&> _conf_layout
|
<&> _conf_layout
|
||||||
.> _lconfig_allowSingleLineExportList
|
.> _lconfig_allowSingleLineExportList
|
||||||
.> confUnpack
|
.> confUnpack
|
||||||
|
-- the config should not prevent single-line layout when there is no
|
||||||
|
-- export list
|
||||||
|
let allowSingleLine = allowSingleLineExportList || Data.Maybe.isNothing les
|
||||||
docLines
|
docLines
|
||||||
$ docSeq
|
$ docSeq
|
||||||
[ docNodeAnnKW lmod Nothing docEmpty
|
[ docNodeAnnKW lmod Nothing docEmpty
|
||||||
-- A pseudo node that serves merely to force documentation
|
-- A pseudo node that serves merely to force documentation
|
||||||
-- before the node
|
-- before the node
|
||||||
, docNodeMoveToKWDP lmod AnnModule $ runFilteredAlternative $ do
|
, docNodeMoveToKWDP lmod AnnModule $ runFilteredAlternative $ do
|
||||||
addAlternativeCond allowSingleLineExportList $
|
addAlternativeCond allowSingleLine $
|
||||||
docForceSingleline
|
docForceSingleline
|
||||||
$ docSeq
|
$ docSeq
|
||||||
[ appSep $ docLit $ Text.pack "module"
|
[ appSep $ docLit $ Text.pack "module"
|
||||||
|
|
Loading…
Reference in New Issue