str.format: Don't assume that '}' immediately follows '{', skip insides.

That at least makes stuff like "{:x}".format(1) to produce not completely
broken output.