aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorross <unknown>2005-01-13 14:43:41 +0000
committerross <unknown>2005-01-13 14:43:41 +0000
commit106e3cf0daeae469f969e669317c863a56b533b4 (patch)
tree8ff7b05bf8c02195e63b3db78a423cda970ea84c
parentb899a3812d89ac13c4accd774927301da79da500 (diff)
[haddock @ 2005-01-13 14:43:41 by ross]
also allow uppercase X in hexadecimal character references (like SGML)
-rw-r--r--src/HaddockLex.x2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/HaddockLex.x b/src/HaddockLex.x
index a9ecc99a..1044d64a 100644
--- a/src/HaddockLex.x
+++ b/src/HaddockLex.x
@@ -59,7 +59,7 @@ $ident = [$alphanum \'\_\.\!\#\$\%\&\*\+\/\<\=\>\?\@\\\\\^\|\-\~]
[\'\`] $ident+ [\'\`] { ident }
\\ . { strtoken (TokString . tail) }
"&#" $digit+ \; { strtoken $ \s -> TokString [chr (read (init (drop 2 s)))] }
- "&#x" $hexdigit+ \; { strtoken $ \s -> case readHex (init (drop 3 s)) of [(n,_)] -> TokString [chr n] }
+ "&#" [xX] $hexdigit+ \; { strtoken $ \s -> case readHex (init (drop 3 s)) of [(n,_)] -> TokString [chr n] }
-- allow special characters through if they don't fit one of the previous
-- patterns.
[\'\`\<\#\&\\] { strtoken TokString }