-fno-code and Template Haskell are incompatible
Building the included project with
cabal configure && cabal build --ghc-options="-fforce-recomp -Wall -fno-code"
results in the following typechecker error:
ByteCodeLink.lookupCE
During interactive linking, GHCi couldn't find the following symbol:
supabugzm0zi1zi0_A_makeLenseszq_closure
This may be due to you not asking GHCi to load extra object files,
archives or DLLs needed by your current session. Restart GHCi, specifying
the missing library using the -L/path/to/object/dir and -lmissinglibname
flags, or simply by naming the relevant files on the GHCi command line.
Alternatively, this link failure might indicate a bug in GHCi.
If you suspect the latter, please send a bug report to:
glasgow-haskell-bugs@haskell.org
The problem here is that GHC goes looking for the code of modules needed for TemplateHaskell splices, which was not produced due to -fno-code
.