From 2a45b7c00f64ac30b29a8c0baf2e663a41faab70 Mon Sep 17 00:00:00 2001 From: David Waern Date: Wed, 7 Apr 2010 22:13:27 +0000 Subject: Fix #75 Add colons to the $ident character set. --- src/Haddock/Lex.x | 2 +- tests/tests/Ticket75.hs | 7 ++ tests/tests/Ticket75.html.ref | 174 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 182 insertions(+), 1 deletion(-) create mode 100644 tests/tests/Ticket75.hs create mode 100644 tests/tests/Ticket75.html.ref diff --git a/src/Haddock/Lex.x b/src/Haddock/Lex.x index 14843aa3..115646ca 100644 --- a/src/Haddock/Lex.x +++ b/src/Haddock/Lex.x @@ -40,7 +40,7 @@ $digit = [0-9] $hexdigit = [0-9a-fA-F] $special = [\"\@] $alphanum = [A-Za-z0-9] -$ident = [$alphanum \'\_\.\!\#\$\%\&\*\+\/\<\=\>\?\@\\\\\^\|\-\~] +$ident = [$alphanum \'\_\.\!\#\$\%\&\*\+\/\<\=\>\?\@\\\\\^\|\-\~\:] :- diff --git a/tests/tests/Ticket75.hs b/tests/tests/Ticket75.hs new file mode 100644 index 00000000..94a2f115 --- /dev/null +++ b/tests/tests/Ticket75.hs @@ -0,0 +1,7 @@ +module Ticket75 where + +data a :- b = Q + +-- | A reference to ':-' +f :: Int +f = undefined diff --git a/tests/tests/Ticket75.html.ref b/tests/tests/Ticket75.html.ref new file mode 100644 index 00000000..1490c1dc --- /dev/null +++ b/tests/tests/Ticket75.html.ref @@ -0,0 +1,174 @@ + + +Ticket75
 ContentsIndex
Ticket75
Synopsis
data a :- b = Q
f :: Int
Documentation
data a :- b
Constructors
Q
f :: Int
A reference to :- +
Produced by Haddock version 2.7.2
-- cgit v1.2.3