[wx-dev] Re: CVS: [ABX] wxWidgets/src/univ stdrend.cpp, 1.13,
1.14
Vadim Zeitlin
vadim at wxwindows.org
Mon Oct 2 05:38:03 PDT 2006
On Mon, 02 Oct 2006 14:35:00 +0200 ABX <abx at abx.art.pl> wrote:
A> Maybe. I just remember our own guidelines saying "The ternary operator ?:
A> shouldn't be used with objects"
That's because some broken compilers (Borland not to mention it by name)
failed to compile it when the 2 last arguments of this operator didn't have
exactly the same type (even though they could be converted to some common
type).
A> > I can't see anything wrong with the old code, why exactly did it crash?
A>
A> It's caused by:
A>
A> wxASSERT_MSG( m_refData->m_count > 0, _T("invalid ref data count") );
A>
A> in wxObject::UnRef(). I'll add longer investigation into my todo.
I strongly suspect there is some real problem elsewhere, this can't be
due to using ?:.
Regards,
VZ
More information about the wx-dev
mailing list