Unbelievable in Xcode 4.6.
If I initialize a variable to something, it frees the memory. But what if this variable has a random value ?
class X
{
private:
NSThread* thr;
public:
X();
};
X :: X()
{
thr = 0; // BOOM !!!?
}
X* x = new X(); // Constructor crashes.
But if the constructor is inline, it doesn't!