Well, I found a workaround, but it's ugly as hell.
1) define a new role:
.. role:: raw-html(raw)
:format: html
2) use that role for generating required html code:
:raw-html:`<tt class="docutils literal"><span class="pre">x = 3 + (4 * 5
</span></tt>`
Still hoping someone can suggest something better!
On Saturday, August 18, 2012 7:30:31 PM UTC+3, Aivar Annamaa wrote:
>
> Hi!
>
> I'm trying to write an inline code sample with a syntax error in it: ``x
> = 3 + (4 * 5 ``, but I get error "Inline literal start-string without
> end-string". If I close the parens, then the error goes away.
>
> I also tried :literal:`x = 4 + (3 * 5 `, but got similar error.
>
> Any ideas for a workaround?
>
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/sphinx-dev/-/mIkLNpTWPaoJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.