aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers
diff options
context:
space:
mode:
authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2007-01-24 08:14:43 +0000
committerfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2007-01-24 08:14:43 +0000
commit96919a6ac5c21a8b46fbc347a4d815f0c9c89b98 (patch)
treef9cf3dcd49e2d769a26738b7e5b5dcb5a7eeef97 /src/Text/Pandoc/Readers
parente6cc2aa3cf30cc5179b33974a894f5333167242b (diff)
downloadpandoc-96919a6ac5c21a8b46fbc347a4d815f0c9c89b98.tar.gz
More smart quote bug fixes:
+ LaTeX writer now handles consecutive quotes properly: for example, ``\,`hello'\,'' + LaTeX reader now parses '\,' as empty Str + normalizeSpaces function in Shared now removes empty Str elements + Modified tests accordingly git-svn-id: https://pandoc.googlecode.com/svn/trunk@506 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src/Text/Pandoc/Readers')
-rw-r--r--src/Text/Pandoc/Readers/LaTeX.hs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs
index 38777b003..c152cc336 100644
--- a/src/Text/Pandoc/Readers/LaTeX.hs
+++ b/src/Text/Pandoc/Readers/LaTeX.hs
@@ -381,7 +381,8 @@ comment = try (do
-- inline
--
-inline = choice [ strong, emph, ref, lab, code, linebreak, math, ellipses,
+inline = choice [ strong, emph, ref, lab, code, linebreak, spacer,
+ math, ellipses,
emDash, enDash, hyphen, quoted, apostrophe,
accentedChar, specialChar, specialInline, escapedChar,
unescapedChar, str, endline, whitespace ] <?> "inline"
@@ -579,6 +580,10 @@ linebreak = try (do
string "\\\\"
return LineBreak)
+spacer = try $ do
+ string "\\,"
+ return (Str "")
+
str = do
result <- many1 (noneOf specialChars)
return (Str result)