- getGhcMode `thenM` \ ghc_mode ->
- if (ghc_mode == Interactive || ghc_mode == JustTypecheck)
- && not source_unchanged then
- returnM (outOfDate, maybe_iface)
- else
-
- case maybe_iface of {
- Just old_iface -> do -- Use the one we already have
- recomp <- checkVersions hsc_env source_unchanged old_iface
- return (recomp, Just old_iface)
-
- ; Nothing ->
+ ; ghc_mode <- getGhcMode
+ ; if (ghc_mode == Interactive || ghc_mode == JustTypecheck)
+ && not source_unchanged then
+ return (outOfDate, maybe_iface)
+ else
+ case maybe_iface of {
+ Just old_iface -> do -- Use the one we already have
+ { traceIf (text "We already have the old interface for" <+> ppr (ms_mod mod_summary))
+ ; recomp <- checkVersions hsc_env source_unchanged old_iface
+ ; return (recomp, Just old_iface) }
+
+ ; Nothing -> do