git.iko.soy/typeable/pandoc
on master help sign in
RST: literal role should produce Code,

code role should have "code" class. http://docutils.sourceforge.net/docs/ref/rst/roles.html says that `text`:literal` is the same as ``text``. docutils outputs a <literal> element in both cases, whereas for the code role, it outputs a <literal> element with the "code" class.

commitdba066a33def2635567dc790f04387a06297e903 authorDaniel Bergey <bergey@alum.mit.edu> dateMon 8 Dec 2014, 16:41 (12 years ago) parent1581685
1 file changed+2−2
src/Text/Pandoc/Readers/RST.hs+2−2
src/Text/Pandoc/Readers/RST.hs+2−2
@@ -1006,12 +1006,12 @@ renderRole contents fmt role attr = case role of
10061006 "RFC" -> return $ rfcLink contents
10071007 "pep-reference" -> return $ pepLink contents
10081008 "PEP" -> return $ pepLink contents
1009− "literal" -> return $ B.str contents
1009+ "literal" -> return $ B.codeWith attr contents
10101010 "math" -> return $ B.math contents
10111011 "title-reference" -> titleRef contents
10121012 "title" -> titleRef contents
10131013 "t" -> titleRef contents
1014− "code" -> return $ B.codeWith attr contents
1014+ "code" -> return $ B.codeWith (union attr ["code"]) contents
10151015 "raw" -> return $ B.rawInline (fromMaybe "" fmt) contents
10161016 custom -> do
10171017 customRole <- stateRstCustomRoles <$> getState