Skip to content

.tix file generation broken with -fhpc and --make flags with lhs modules

Assume the project consisting of two files: Main.lhs and MyModule.hs. Main.lhs imports MyModule via standard import. Build the project with

ghc --make -fhpc -o main Main.lhs

The generated .tix file contains relevant information and hpc markup correctly shows the coverage for MyModule.

Now rename MyModule.hs to MyModule.lhs and enclose the code there in \begin{code} / \end{code}. Build again. The compilation still succeeds and the executable works fine. But main.tix now seems wrong and no hpc coverage information is available for MyModule

Edited by Thomas Miedema
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information