From d6cfd266b30066a5452514b26e50b740104a982b Mon Sep 17 00:00:00 2001 From: Ɓukasz Hanuszczak Date: Mon, 29 Jun 2015 23:00:54 +0200 Subject: Add support for hyperlinking constructor names in patters. --- haddock-api/src/Haddock/Backends/Hyperlinker/Ast.hs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/haddock-api/src/Haddock/Backends/Hyperlinker/Ast.hs b/haddock-api/src/Haddock/Backends/Hyperlinker/Ast.hs index 5efcd2ed..fd3f2f1e 100644 --- a/haddock-api/src/Haddock/Backends/Hyperlinker/Ast.hs +++ b/haddock-api/src/Haddock/Backends/Hyperlinker/Ast.hs @@ -102,6 +102,8 @@ binds = pat term = case cast term of (Just (GHC.L sspan (GHC.VarPat name))) -> pure (sspan, RtkBind name) + (Just (GHC.L _ (GHC.ConPatIn (GHC.L sspan name) _))) -> + pure (sspan, RtkVar name) _ -> empty -- | Obtain details map for top-level declarations. -- cgit v1.2.3