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
Ormolu formats proc a -> x >- a to proc a -> a -< x, which has a different AST.
To Reproduce
$ cat test.hs
{-# LANGUAGE Arrows #-}
foo x = proc a -> x >- a
$ ormolu test.hs
test.hs
AST of input and AST of formatted code differ.
at test.hs:3:19-24
Please, consider reporting the bug.
$ ormolu --unsafe test.hs
{-# LANGUAGE Arrows #-}
foo x = proc a -> a -< x
Expected behavior
ormolu should not fail.
Probably, it shouldn't reformat the example at all, though I suppose an argument could be made for normalizing the direction. In that case, the ASTs should be considered equivalent.
Environment
current master on macos
The text was updated successfully, but these errors were encountered:
robx
added a commit
to robx/ormolu
that referenced
this issue
Aug 4, 2021
Describe the bug
Ormolu formats
proc a -> x >- a
toproc a -> a -< x
, which has a different AST.To Reproduce
Expected behavior
ormolu should not fail.
Probably, it shouldn't reformat the example at all, though I suppose an argument could be made for normalizing the direction. In that case, the ASTs should be considered equivalent.
Environment
current master on macos
The text was updated successfully, but these errors were encountered: