How to force recompilation of preprocessed files (-F -pgmF ..)

Simon Hengel sol at
Thu May 17 10:58:02 CEST 2012

I'm experimenting with a preprocessor to automatically generate test
drivers[1].  The result depends on the existence of other files on the
disk.  When files are added or removed, the test driver has to be

Ideally ghc would just always recompile that single file (akin to make's
.PHONY), and it should work with ghci's :reload and with cabal.

I tried to touch the file within the preprocessor, but this does not
work.  It seems, that GHC checks the modification time only after

Any ideas how to tackle this?



More information about the Glasgow-haskell-users mailing list