This isn't really a question, it's a built-in answer. This post applies to Confluence 3.5 and earlier.
I've been using the wiki for a long time, and can't be bothered with the menu system* when I already 'know' what to do. So I use the wiki markup editor and type things such as:
{code}Some code snippet here{code}
Which is fine unless there's a curly bracket { within the code snippet. The wiki tries to render the code, interprets the { as the beginning of a macro, and spoils the example.
I've learned that if you stop acting like a power user and
- click the macro button on the toolbar
- find the Code Block macro
- paste your code snippet into the dialog box
It's all perfectly fine and doesn't attempt to render it. I'm told there's probably an event handler built into the dialog box that evaluates the pasted text, that isn't there if you use ordinary paste.
Moral: just because you've used something a long time doesn't mean you know it.
... And as they say in NLP, "if what you're doing isn't working, try something else".
-----
* and also, it shows that Atlassian <rant:on> were on the path of forcing us down the path of "Use The Menus All The Time Because We Know What You REALLY Want" a long time ago. OK, I have used the 4x onward editor and it's no worse (and no better) than any other RTE editor, if that's what you want. But it will never replace the convenience and simplicity of wiki markup. </rant>