would be nice if -fno-code and --make worked together
|Reported by:||duncan||Owned by:|
|Type of failure:||None/Unknown||Test Case:|
|Related Tickets:||Differential Rev(s):|
We had a Cabal feature request to omit linking to make it quicker in the use case that we just want to check that a package typechecks ok.
Omitting liking is good but we could save more time by omitting code generation too. The -fno-code would seem to be what we want in this case but it looks like it only works with batch mode and not --make mode. What happens at the moment when one uses -fno-code --make is that ghc cannot find the dependent modules, though it is not clear that it is actually looking for .hi files in any particular location. This is with 6.8.2, I've not checked with 6.10 but I assume it is the same.
So if it looks like it would not be too hard to do, then letting -fno-code work with --make would be occasionally useful. The expected result would be to write out the .hi files for all the modules but not the corresponding .o files. When combined with -O0 we might hope it to be a bit quicker than normal builds.
Of course it would not work in the case of template Haskell, but Cabal would just avoid using -fno-code if the package uses TH.
Change History (10)
comment:3 Changed 6 years ago by igloo
- Milestone changed from 6.12.3 to 6.14.1
- Priority changed from normal to low
comment:7 Changed 4 years ago by igloo
- Milestone changed from 7.4.1 to 7.6.1
- Priority changed from low to lowest
comment:9 Changed 20 months ago by ezyang
- Resolution set to fixed
- Status changed from new to closed
- Type of failure set to None/Unknown