  import Text.Pandoc.Writers.Shared
  
  type Notes = [[Block]]
-@@ -250,11 +249,10 @@ inlineToHaddock _ (Code _ str) =
+@@ -97,6 +96,11 @@ escapeString :: String -> String
+ escapeString = escapeStringUsing haddockEscapes
+   where haddockEscapes = backslashEscapes "\\/'`\"@<"
+ 
++-- | Just escape backslashes
++escapeMathString :: String -> String
++escapeMathString = escapeStringUsing haddockMathEscapes
++  where haddockMathEscapes = backslashEscapes "\\"
++
+ -- | Convert Pandoc block element to haddock.
+ blockToHaddock :: PandocMonad m
+                => WriterOptions -- ^ Options
+@@ -250,11 +254,10 @@ inlineToHaddock _ (Code _ str) =
    return $ "@" <> text (escapeString str) <> "@"
  inlineToHaddock _ (Str str) =
    return $ text $ escapeString str

diff --git a/src/Text/Pandoc/Writers/Haddock.hs b/src/Text/Pandoc/Writers/Haddock.hs
index 75b8c78dc..128c2b866 100644
--- a/src/Text/Pandoc/Writers/Haddock.hs
+++ b/src/Text/Pandoc/Writers/Haddock.hs
@@ -45,7 +45,6 @@ import Text.Pandoc.Options

-  adjust <$> (lift (texMathToInlines mt str) >>= inlineListToHaddock opts)
+inlineToHaddock _ (Math mt str) =
+  return $ case mt of
+    DisplayMath -> cr <> "\\\\[" <> text (escapeMathString str) <> "\\\\]" <> cr
+    InlineMath  -> "\\(" <> text (escapeMathString str) <> "\\)"
 inlineToHaddock _ il@(RawInline f str)
   | f == "haddock" = return $ text str
   | otherwise = do
