Reconstruct a stack variable?

1
2
3
4
5
6
7
8
MyClass mc (/*...*/);

//...

mc.~MyClass();
new (&mc) MyClass(/*...*/);

//... 
I know it is a design flaw to have to do this, but is it safe?
Yes, provided the constructor doesn't throw.
Topic archived. No new replies allowed.