summaryrefslogtreecommitdiffstats
path: root/src/script/bridge
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2010-03-05 12:12:24 (GMT)
committerKent Hansen <kent.hansen@nokia.com>2010-03-05 13:24:21 (GMT)
commit88e9515cc4300d841b16f17fe6b5c8c0d6de3562 (patch)
tree77bc7c0382a728a0b03b33b2a42cf09878810aab /src/script/bridge
parent12308db7663679e42c87aa72c564ec3f9f1a457f (diff)
downloadQt-88e9515cc4300d841b16f17fe6b5c8c0d6de3562.zip
Qt-88e9515cc4300d841b16f17fe6b5c8c0d6de3562.tar.gz
Qt-88e9515cc4300d841b16f17fe6b5c8c0d6de3562.tar.bz2
QMetaType::type(): return immediately if the typename is empty
No need to look up / lock data structures if we know that the comparisons will all fail. This was encountered because QMetaMethod::typeName() returns an empty string if the return type is void (even though there is a QMetaType::Void (value 0) with name "void"). This was causing the QtScript meta-object binding to spend a lot of its time looking up the type for an empty string when invoking slots that return void. Rather than having these checks in QtScript and who knows where else, it's better that QMetaType::type() does it itself. No regressions in the qmetatype benchmark. Reviewed-by: Olivier Goffart Reviewed-by: Harald Fernengel
Diffstat (limited to 'src/script/bridge')
0 files changed, 0 insertions, 0 deletions