diff options
author | alexbiehl-gc <72160047+alexbiehl-gc@users.noreply.github.com> | 2021-02-07 18:39:59 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-07 18:39:59 +0100 |
commit | 786d3e69799398c3aac26fbd5017a127bc69cacc (patch) | |
tree | 883ee3f8c0e195299925b790cba6f88a537200f6 /haddock-api/src/Haddock/Backends/Hyperlinker.hs | |
parent | e90e79815960823a749287968fb1c6d09559a67f (diff) | |
parent | 0f7ff041fb824653a7930e1292b81f34df1e967d (diff) |
Merge branch 'ghc-head' into ghc-9.0
Diffstat (limited to 'haddock-api/src/Haddock/Backends/Hyperlinker.hs')
-rw-r--r-- | haddock-api/src/Haddock/Backends/Hyperlinker.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/haddock-api/src/Haddock/Backends/Hyperlinker.hs b/haddock-api/src/Haddock/Backends/Hyperlinker.hs index 03be8c22..d85a3970 100644 --- a/haddock-api/src/Haddock/Backends/Hyperlinker.hs +++ b/haddock-api/src/Haddock/Backends/Hyperlinker.hs @@ -70,10 +70,10 @@ ppHyperlinkedModuleSource verbosity srcdir pretty srcs iface = case ifaceHieFile -- Get the AST and tokens corresponding to the source file we want let fileFs = mkFastString file mast | M.size asts == 1 = snd <$> M.lookupMin asts - | otherwise = M.lookup fileFs asts + | otherwise = M.lookup (HiePath (mkFastString file)) asts + tokens = parse df file rawSrc ast = fromMaybe (emptyHieAst fileFs) mast fullAst = recoverFullIfaceTypes df types ast - tokens = parse df file rawSrc -- Warn if we didn't find an AST, but there were still ASTs if M.null asts |