diff options
author | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2009-11-29 20:37:55 +0000 |
---|---|---|
committer | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2009-11-29 20:37:55 +0000 |
commit | a84472e0542e0837d62cb637c2e446c2570d0230 (patch) | |
tree | 14125f69218349ff0147218109cbb1975d87fd97 /src | |
parent | 80a4a03df7cae09c73453322729653f9bffbdd75 (diff) | |
download | pandoc-a84472e0542e0837d62cb637c2e446c2570d0230.tar.gz |
Allow _ character in automatically generated identifiers.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@1635 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src')
-rw-r--r-- | src/Text/Pandoc/Shared.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Shared.hs b/src/Text/Pandoc/Shared.hs index 810911165..a0c45072d 100644 --- a/src/Text/Pandoc/Shared.hs +++ b/src/Text/Pandoc/Shared.hs @@ -891,7 +891,7 @@ inlineListToIdentifier' [] = "" inlineListToIdentifier' (x:xs) = xAsText ++ inlineListToIdentifier' xs where xAsText = case x of - Str s -> filter (\c -> c == '-' || not (isPunctuation c)) $ + Str s -> filter (\c -> c `elem` "_-" || not (isPunctuation c)) $ intercalate "-" $ words $ map toLower s Emph lst -> inlineListToIdentifier' lst Strikeout lst -> inlineListToIdentifier' lst |