ghc - Dead code and/or how to generate a cross reference from Haskell source -


i've got unused functionality in codebase, it's hard identify. code has evolved on last year explore problem space , possible solutions. i'm needing find unused code can rid of it. i'm happy if deals problem on exportable name basis.ghc has warnings deal non-exported unused code. tools specific task of interest.

however, i'm curious comprehensive cross referencing tool. can find unused code such tool. years ago when working in c , assembler, found xref pretty handy tool, useful many different purposes.

i'm getting googling. apparently in haskell dominant meaning of cross-reference within literate programming. though maybe there useful.

i don’t know of such tool, in past have done bit of hack instead.

if have comprehensive test suite, can run ghc’s code coverage tracing enabled. compile -fhpc , use hpc markup generate annotated source. gives union of unused code , untested code, both of address anyway.

sourcegraph can give a bunch of information may find useful.


Comments

Popular posts from this blog

java - Run a .jar on Heroku -

java - Jtable duplicate Rows -

validation - How to pass paramaters like unix into windows batch file -