diff options
Diffstat (limited to 'src/Text/Pandoc/Readers/Markdown.hs')
-rw-r--r-- | src/Text/Pandoc/Readers/Markdown.hs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Readers/Markdown.hs b/src/Text/Pandoc/Readers/Markdown.hs index 9928500dc..2e95c518d 100644 --- a/src/Text/Pandoc/Readers/Markdown.hs +++ b/src/Text/Pandoc/Readers/Markdown.hs @@ -1482,6 +1482,7 @@ inline = choice [ whitespace , strongOrEmph , note , cite + , bracketedSpan , link , image , math @@ -1750,6 +1751,13 @@ link = try $ do setState $ st{ stateAllowLinks = True } regLink B.linkWith lab <|> referenceLink B.linkWith (lab,raw) +bracketedSpan :: MarkdownParser (F Inlines) +bracketedSpan = try $ do + guardEnabled Ext_bracketed_spans + (lab,_) <- reference + attr <- attributes + return $ B.spanWith attr <$> lab + regLink :: (Attr -> String -> String -> Inlines -> Inlines) -> F Inlines -> MarkdownParser (F Inlines) regLink constructor lab = try $ do |