aboutsummaryrefslogtreecommitdiff
path: root/src/Haddock/Backends/Xhtml/Layout.hs
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2011-06-17 19:10:29 +0100
committerIan Lynagh <igloo@earth.li>2011-06-17 19:10:29 +0100
commit8739a6bd59f562bb550c915f1d2b2a327b748572 (patch)
tree6ce78264c2b2e1103209c70f3560b816f884937e /src/Haddock/Backends/Xhtml/Layout.hs
parentab24835eadb99059934d7a14f86564eea6449257 (diff)
Fix build
Diffstat (limited to 'src/Haddock/Backends/Xhtml/Layout.hs')
-rw-r--r--src/Haddock/Backends/Xhtml/Layout.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Haddock/Backends/Xhtml/Layout.hs b/src/Haddock/Backends/Xhtml/Layout.hs
index 91eac9c6..bdd5ac78 100644
--- a/src/Haddock/Backends/Xhtml/Layout.hs
+++ b/src/Haddock/Backends/Xhtml/Layout.hs
@@ -204,5 +204,7 @@ topDeclElem ((_,_,sourceMap), (_,_,maybe_wiki_url)) loc names html =
Documented n mdl = head names
-- FIXME: is it ok to simply take the first name?
- fname = unpackFS (srcSpanFile loc)
+ fname = case loc of
+ RealSrcSpan l -> unpackFS (srcSpanFile l)
+ UnhelpfulSpan _ -> error "topDeclElem UnhelpfulSpan"