mirror of
https://github.com/ilyakooo0/ormolu.git
synced 2024-10-27 11:41:17 +03:00
Handle inline comments before let correctly
This commit is contained in:
parent
de1b33788d
commit
560c498688
@ -10,3 +10,9 @@ bar x =
|
|||||||
y = x
|
y = x
|
||||||
in z +
|
in z +
|
||||||
100
|
100
|
||||||
|
|
||||||
|
inlineComment :: Int -> Int
|
||||||
|
inlineComment =
|
||||||
|
let {- join -} go = case () of
|
||||||
|
() -> undefined
|
||||||
|
in go
|
||||||
|
@ -10,3 +10,9 @@ bar x =
|
|||||||
y = x
|
y = x
|
||||||
in z
|
in z
|
||||||
+ 100
|
+ 100
|
||||||
|
|
||||||
|
inlineComment :: Int -> Int
|
||||||
|
inlineComment =
|
||||||
|
let {- join -} go = case () of
|
||||||
|
() -> undefined
|
||||||
|
in go
|
||||||
|
@ -392,7 +392,7 @@ p_hsLocalBinds = \case
|
|||||||
(Left <$> bagToList bag) ++ (Right <$> lsigs)
|
(Left <$> bagToList bag) ++ (Right <$> lsigs)
|
||||||
p_item (Left x) = located x p_valDecl'
|
p_item (Left x) = located x p_valDecl'
|
||||||
p_item (Right x) = located x p_sigDecl'
|
p_item (Right x) = located x p_sigDecl'
|
||||||
newlineSep p_item (sortOn ssStart items)
|
newlineSep (sitcc . p_item) (sortOn ssStart items)
|
||||||
HsValBinds NoExt _ -> notImplemented "HsValBinds"
|
HsValBinds NoExt _ -> notImplemented "HsValBinds"
|
||||||
HsIPBinds NoExt _ -> notImplemented "HsIPBinds"
|
HsIPBinds NoExt _ -> notImplemented "HsIPBinds"
|
||||||
EmptyLocalBinds NoExt -> return ()
|
EmptyLocalBinds NoExt -> return ()
|
||||||
|
Loading…
Reference in New Issue
Block a user