I discovered this while getting haskell-language-server set up. haskell/haskell-language-server#3020
Original file
$ cat foo.hlint.hs
foo :: [a] -> [a]
foo = foldl (\xs x -> x : xs) []
Refactored version:
$ hlint --refactor foo.hlint.hs
foo :: [a] -> [a]
foo = foldl (flip :) []
The expected code would be:
foo :: [a] -> [a]
foo = foldl (flip (:)) []
Using apply-refact-0.10.0.0 and The Glorious Glasgow Haskell Compilation System, version 9.2.3
I discovered this while getting haskell-language-server set up. haskell/haskell-language-server#3020
Original file
Refactored version:
The expected code would be:
Using
apply-refact-0.10.0.0andThe Glorious Glasgow Haskell Compilation System, version 9.2.3