[Qt-interest] qobject_cast<> questions
Ross Bencina
rossb-lists at audiomulch.com
Sun May 31 13:28:04 CEST 2009
Thiago Macieira
>But I argue that we shouldn't need to document when things work exactly as
>expected. If qobject_cast is meant to work as a replacement for
>dynamic_cast, then it should work like it.
Ok, great, that is the most specific description of what qobject_cast is
supposed to be I have read. That is much clearer than the documentation,
which says:
"""
The qobject_cast() function behaves similarly to the standard C++
dynamic_cast()
"""
Note that it does not say "exactly" it says "similarly" -- it is vague, very
vague. When Qt docs say something vague like that I have _no_idea_ what to
expect. Perhaps the writer meant "the same as" but that's not what's
written.
I have filed the bug.
Thanks.
Ross.
More information about the Qt-interest-old
mailing list