greghendershott / markdown

Markdown parser written in Racket.
100 stars 28 forks source link

Backtick (a.k.a. quasiquote) in fenced code block #42

Closed greghendershott closed 10 years ago

greghendershott commented 10 years ago
(parse-markdown "```racket\n'(foo)\n```")
;; => '((pre ((class "brush: racket")) (code () "'(foo)"))) 
;; good

(parse-markdown "```racket\n`(foo)\n```")
;; => '((p () (code () "racket\n`(foo)")))
;; bad

First glance, I don't understand why. $verbatim/fenced is using $any-line which should not be affected by the ``. Somehow it is getting parsed as an inline$code`, instead.