<div dir="ltr"><div><div><div><div><div><div>I am please to announce an alpha release of the Haskell Refactorer making use of the GHC API.<br><br></div>It is a work in progress, but currently supports the following refactorings<br>

<br><br>       iftocase<br>           Convert an if expression to a case expression<br><br>       dupdef<br>           Duplicate a definition<br><br>       liftToTopLevel<br>           Lift a declaration to the top level<br>

<br>       liftOneLevel<br>           Lift a declaration one level<br><br>       demote<br>           Move a declaration down one level<br><br>       rename<br>           Rename an identifier<br><br></div>It offers emacs integration only at this point, based on the Wrangler elisp.<br>

<br></div>The underlying environment in terms of cabal file, sandbox, etc are managed by ghc-mod via the internals exposed in version 2.1.2<br><br></div>There are some known issues (and bound to be plenty of unknown ones too).<br>

<br></div>The most damaging of these is that layout is not adjusted after renaming an identifier if the new name is a different length. This affects layout-sensitive code.<br><br></div><div>Installation instructions can be found at <a href="https://github.com/alanz/HaRe/blob/master/README.markdown">https://github.com/alanz/HaRe/blob/master/README.markdown</a><br>

<br></div><div>Regards<br></div><div>  Alan<br></div><br><div><div><div><br></div></div></div></div>