Skip to content

Ugly but valid comment breaks AST #518

@fisx

Description

@fisx
module A where

a =
  b
    [ f
 {-,


                                    -}
    ]
$ ormolu A.hs 
AST of input and AST of formatted code differ.
  in A.hs
Please, consider reporting the bug.
$ ormolu --version
ormolu 0.0.3.1 UNKNOWN UNKNOWN
using ghc-lib-parser 8.8.2.20200205

If I remove one empty line from the comment, the problem goes away.

Thanks, and enjoy! :)

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions