Please log in to watch this conference skillscast.
In this talk, I will describe the architecture and history of ghc-exactprint. ghc-exactprint is a library which enables programmers to easily specify refactoring operations by directly modifying the GHC AST. By leveraging the GHC parser and a suitable intermediate representation, we can refactor any haskell source file. I will also demonstrate two libraries which are already using ghc-exactprint to directly apply refactorings. HaRe has been rewritten to take advantage of this new machinery which has resulted in a significant reduction in complexity. Secondly, apply-refact automatically applies hlint suggestions. This program demonstrates one method in which the new foundation can be used in tandem with haskell-src-exts.
Join us at the Haskell eXchange in 2016!
Want to learn about the latest innovations in Haskell? Join 200+ Haskell and functional programmers to learn and share skills with some of the world's top Haskell experts at the Haskell eXchange 2016 in London. Find out all about Haskell's infrastructure roadmap, learn how Haskell is used in academia and enterprise and discover how Haskell is changing the way our industry tackles complex engineering problems. Early bird tickets already available!
YOU MAY ALSO LIKE:
A new foundation for refactoring - ghc-exactprint
Matthew is a PhD student at the University of Bristol and one of the core GHC contributors. His research interests are in program generation and multi-stage programming.