[Development] Applications using -fno-rtti
Alberto Mardegan
mardy at users.sourceforge.net
Sat Jun 20 21:00:27 CEST 2020
On 20/06/20 21:42, Konstantin Tokarev wrote:
> Comparing metaObject() with staticMetaObject() is wrong because it would fail
> even for QProcess.
I didn't try, but why would it fail?
> OTOH, using qobject_cast would handle classes derived
> from QProcess correctly, unlike code with typeid().
But how would you use qobject_cast in this case? We don't know what
class to cast to; we only want to know if we are a subclass of QProcess.
Ciao,
Alberto
--
http://www.mardy.it - Geek in un lingua international
More information about the Development
mailing list