Quote Originally Posted by MarkZWEERS View Post
that's pretty annoying: I think a temporary should be allowed if it is not used out side its case...
It is, as long as you make it local scope - the problem is that in a
Code:
switch(xx)
{
...
}
the whole switch statement is one large scope - so if you declare a variable in the middle, it's the same as if you declared a variable on the other side of a goto as described above - it will not be constructed because you don't run the constructor code, and unconstructed objects aren't a particularly good idea.

--
Mats