You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes, there are no open or closed issues related to my issue
Describe the bug
Long lines that use BlockArguments cause an error when formatted using a column-limit that is less than the length of the line. I noticed this bug when formatting Hspec tests (e.g. it "foo" do).
A minimal example:
{-# LANGUAGE BlockArguments #-}
putThen::String->IOa->IOa
putThen s action =putStrLn s >> action
main::IO()
main =do
putThen "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789"doputStrLn""
Results in:
<stdin>
@@ -7,4 +7,5 @@
main :: IO ()
main = do
- putThen "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789" do
+ putThen
+ "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789" do
putStrLn ""
AST of input and AST of formatted code differ.
at <stdin>:(9,3)-(10,15)
Please, consider reporting the bug.
To format anyway, use --unsafe.
The text was updated successfully, but these errors were encountered:
Is your bug specific to Fourmolu?
Did you try it on the web app?
Did you search for existing issues?
Describe the bug
Long lines that use
BlockArguments
cause an error when formatted using acolumn-limit
that is less than the length of the line. I noticed this bug when formatting Hspec tests (e.g.it "foo" do
).A minimal example:
Results in:
The text was updated successfully, but these errors were encountered: