Via #haskell-stack, @chreekat just ran into a case where stack ghci --ghc-options ".." did not behave as expected. Namely, since this was run with the package-less global project, --ghc-options does not get applied to anything. We have a couple options for dealing with this:
- Apply CLI
--ghc-options even if there are no local package targets. This is the approach I prefer.
- Warn when
--ghc-options aren't getting applied to anything. This would actually be a good enhancement independently of ghci.
If both of these actions are taken, then we should make sure that stack ghci --ghc-options doesen't warn about --ghc-options not being applied.