From 9719b0c74c8266a63b40dfacfe83f03de9c1d62a Mon Sep 17 00:00:00 2001
From: John MacFarlane <jgm@berkeley.edu>
Date: Fri, 2 Nov 2018 22:58:25 -0700
Subject: Roff reader: Handle 'H' modifier after '.TS'.

---
 src/Text/Pandoc/Readers/Roff.hs | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

(limited to 'src/Text/Pandoc')

diff --git a/src/Text/Pandoc/Readers/Roff.hs b/src/Text/Pandoc/Readers/Roff.hs
index 2bf2d070e..8121bedfe 100644
--- a/src/Text/Pandoc/Readers/Roff.hs
+++ b/src/Text/Pandoc/Readers/Roff.hs
@@ -376,7 +376,6 @@ lexMacro = do
     "ie"  -> lexConditional "ie"
     "if"  -> lexConditional "if"
     "el"  -> lexConditional "el"
-    "TS"  -> lexTable pos
 
     _ -> do
        args <- lexArgs
@@ -384,6 +383,7 @@ lexMacro = do
          ""     -> return mempty
          "\\\"" -> return mempty
          "\\#"  -> return mempty
+         "TS"   -> lexTable pos
          "de"   -> lexMacroDef args
          "de1"  -> lexMacroDef args
          "ds"   -> lexStringDef args
@@ -458,8 +458,7 @@ tableOption = do
          char '('
          manyTill anyChar (char ')')
   skipMany spacetab
-  optional (char ',')
-  skipMany spacetab
+  optional (char ',' >> skipMany spacetab)
   return (k,v)
 
 tableFormatSpec :: PandocMonad m => RoffLexer m [[CellFormat]]
-- 
cgit v1.2.3