Skip to content

runghc should give an error when the path to ghc is invalid

runghc has a -f option which allows to specify the path to GHC. However, it uses rawSystem and if the path is incorrect, we only get a nonzero exit code. For example, attempting to use "ghc -fdefer-type-errors X.hs" gives absolutely no output.

Attached patch uses findExecutable and gives an error message if the executable is not found. This is not the ideal solution, but I think it's better than the current state.

Trac metadata
Trac field Value
Version 7.6.3
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component None
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information