diff options
author | Matthew Pickering <matthewtpickering@gmail.com> | 2021-08-10 11:46:13 +0100 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-08-18 17:57:42 -0400 |
commit | d9cf2ec8207e6c159815b22f1ed8dbdc08a2342d (patch) | |
tree | ae7f78335d021e8a5e67ddeb0589d5199204d607 | |
parent | 5f0d2dab9be5b0f89d61e9957bb728538b162230 (diff) | |
download | haskell-d9cf2ec8207e6c159815b22f1ed8dbdc08a2342d.tar.gz |
recomp: Check backend type rather than -fwrite-interface to decide whether we need any objects
This was a small oversight in the original patch which leads to spurious
recompilation when using `-fno-code` but not `-fwrite-interface`, which
you plausibly might do when using ghci.
Fixes #20216
-rw-r--r-- | compiler/GHC/Driver/Main.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/GHC/Driver/Main.hs b/compiler/GHC/Driver/Main.hs index d041d918bb..788c2bce1f 100644 --- a/compiler/GHC/Driver/Main.hs +++ b/compiler/GHC/Driver/Main.hs @@ -703,7 +703,7 @@ hscRecompStatus (recomp_obj_reqd, mb_linkable) <- case () of -- No need for a linkable, we're good to go - _ | writeInterfaceOnlyMode lcl_dflags -> return (UpToDate, Nothing) + _ | NoBackend <- backend lcl_dflags -> return (UpToDate, Nothing) -- Interpreter can use either already loaded bytecode or loaded object code | not (backendProducesObject (backend lcl_dflags)) -> do res <- liftIO $ checkByteCode old_linkable |