Helper functions for working with haskell-src-exts trees


Version on this page:0.2.4
LTS Haskell 21.13:0.2.5
Stackage Nightly 2023-09-27:0.2.5
Latest on Hackage:0.2.5

See all snapshots haskell-src-exts-util appears in

BSD-3-Clause licensed by Neil Mitchell, Jose Iborra
Maintained by pepeiborra@gmail.com
This version can be pinned in stack with:haskell-src-exts-util-0.2.4@sha256:fc941193b0b6f98d233fd5fa7daa08b338cd985775990d3e19cc64ecb136ff42,1427

Module documentation for 0.2.4

Hackage Stackage Nightly Travis Build Status haskell-src-exts-util

A small suite of helper functions for working with haskell-src-exts:

  • Free variables
  • Bound variables
  • Minimal (approximate) rebracketing of AST values such that prettyprint roundtrips.


This package extracts some the HSE functions in HLint and generalizes them. The original code was authored over the years by Neil Mitchell and the rest of HLint contributors.



  • Neil fixed the spotting of brackets inside a lambda.


  • isAtom is now more complete, thanks to Neil M.


  • Improved handling of OverloadedLabel syntax, thanks to Neil M.
  • Changed the treatment of multiple function composition in needParen. The new treatment is less keen to remove parentheses. Note that this is a change of behavior.
  • GHC 8.4 compatibility, courtesy of Ryan G. Scott