From 8f29f69631075577d3a0ed6a9571102a82e9c94f Mon Sep 17 00:00:00 2001 From: simonmar Date: Mon, 6 May 2002 12:49:21 +0000 Subject: [haddock @ 2002-05-06 12:49:21 by simonmar] Fix silly bug in named documentation block lookup. --- src/Main.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/Main.hs b/src/Main.hs index 9873d2f8..08a70bde 100644 --- a/src/Main.hs +++ b/src/Main.hs @@ -591,8 +591,9 @@ findNamedDoc str decls = where search [] = Nothing search (HsDocCommentNamed str : rest) = case matchRegexAll docNameRE str of - Nothing -> search rest - Just (_, _, after, _, _) -> Just after + Just (_, _, after, _, name':_) + | name == name' -> Just after + _otherwise -> search rest search (_other_decl : rest) = search rest _other -> Nothing -- cgit v1.2.3