aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Haddock/GHC/Typecheck.hs8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Haddock/GHC/Typecheck.hs b/src/Haddock/GHC/Typecheck.hs
index f0626231..0df6fc29 100644
--- a/src/Haddock/GHC/Typecheck.hs
+++ b/src/Haddock/GHC/Typecheck.hs
@@ -80,6 +80,10 @@ mkGhcModule (mod, file, checkedMod) dynflags = GhcModule {
ghcInstances = modInfoInstances modInfo
}
where
- HsModule _ _ _ _ _ mbOpts _ _ = unLoc parsed
+#if __GLASGOW_HASKELL__ == 608 && __GHC_PATCHLEVEL__ == 2
+ HsModule _ _ _ _ _ mbOpts _ _ = unLoc parsed
+#else
+ mbOpts = haddockOptions dynflags
+#endif
(group, _, mbExports, mbDoc, info) = renamed
- (parsed, renamed, _, modInfo) = checkedMod
+ (parsed, renamed, _, modInfo) = checkedMod