summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Text/Pandoc/Writers/Blaze.hs4
-rw-r--r--test/command/4639.md2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/Text/Pandoc/Writers/Blaze.hs b/src/Text/Pandoc/Writers/Blaze.hs
index 4bd21b789..8233043a3 100644
--- a/src/Text/Pandoc/Writers/Blaze.hs
+++ b/src/Text/Pandoc/Writers/Blaze.hs
@@ -113,8 +113,8 @@ toChunks :: Text -> [Doc Text]
toChunks = map toDoc . T.groupBy sameStatus
where
toDoc t
- | T.any (== ' ') t = space
- | T.any (== '\n') t = cr
+ | t == " " = space
+ | t == "\n" = cr
| otherwise = literal t
sameStatus c d =
(c == ' ' && d == ' ') ||
diff --git a/test/command/4639.md b/test/command/4639.md
index 31ac3a5d9..c35df1749 100644
--- a/test/command/4639.md
+++ b/test/command/4639.md
@@ -5,6 +5,6 @@
\end{equation}
^D
<p><span class="math display">\[\begin{equation}
-E=mc^2
+ E=mc^2
\end{equation}\]</span></p>
```