> Solved it by surrounding code with more ticks than maximum number of consecutive ticks inside its text. This allows arbitrary nesting.
So, the same thing that Markdown does, as described in TFA?