Fast incremental vi and emacs tags.

Latest on Hackage:1.4.2

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow to host generated Haddocks.

BSD3 licensed by Evan Laforge
Maintained by Evan Laforge

fast-tags - fast and robust tag generator for Haskell

Build Status

Supported GHC versions

Tested with GHC 7.8.4, 7.10.3, 8.0.2, 8.2.2, 8.4.1.


Build with either cabal or stack.


In order to generate tags for all Haskell files under current directory, issue

  fast-tags -R .

See vimrc for an example of how to keep the tags file up to date automatically, and for a way to use qualified names to disambiguate tags



  • add –src-prefix flag

Minor UI cleanups:

  • don’t read filenames from stdin on no arguments, use - for that

  • don’t automatically read contents of directories

  • don’t automatically recurse into any directories starting with dot

  • don’t follow symlinks by default when -R is given

Make qualified tags work better:

  • strip leading and trailing dots

  • make retry qualified tags without qualification


  • Ghc 8.4.1 compatibility.


  • Add, which is more clever about following qualified symbols, without modifying iskeyword. I also added –fully_qualified to support it. Now renamed imports such as import A.B.C as D should chase D.x to A.B.C.x. Thanks to JonnyRa in for the inspiration.


  • A tag will suppress any other tags with the same name within 2 lines. This should prevent multiple tag matches for things like data X = X. Currently the 2 is not configurable, but could be easily enough if someone wanted that.

  • Lock stderr when writing so warnings don’t get scrambled.

  • A –qualified flag which emits tags qualified by module name. There’s an example vimrc line that can use that without having to permanently modify iskeyword.

  • Tags should be always sorted now, instead of being inconsistently-but-mostly-sorted as they were before. I replaced complicated code trying to keep the output sorted with one sort at the end. It’s simpler and doesn’t seem to be measurably slower.


  • Minor updates to cabal file, comments, etc.



  • Implement --no-module-tags command line parameter to optionally avoid tagging modules.


  • fix ‘format’ output for vim


  • Decode UTF8 leniently, so non-UTF8 will no longer cause a crash. Removed the –ignore-encoding-errors flag, since that’s the default behaviour now.


  • Merged a whole bunch of patches from Sergey Vinokurov. Copy paste from

  • recognize more syntactic constructs (consider tests as specification of what’s handled)

  • add more tests

  • use tasty to organize tests

  • ability to produce emacs tags

  • handling of literate files

  • new mode to recursively traverse directory tree and search for haskell files

  • optionally ignore encoding errors during reading and skip offending files

  • ability to read \n-separated or \0-separated list of files from stdin and blazing-fast speed of tag generation is presevred


  • fix bug where class context in a class’s methods would be confused for the context of the class itself


  • Tags with the same name are sorted by their type: Function, Type, Constructor, Class, Module.


  • Fixed bug that prevented old tags from being filtered out.


  • Lots of speed ups, especially when given lots of files at once.

  • Support for type families and GADTs.

  • Support infix operators, multiple declarations per line, and fix various other bugs that missed or gave bad tags.

comments powered byDisqus