D13512: Return early - minimize if indentation
Tomaz Canabrava
noreply at phabricator.kde.org
Wed Jun 13 11:14:03 UTC 2018
tcanabrava created this revision.
Restricted Application added a project: Konsole.
Restricted Application added a subscriber: konsole-devel.
tcanabrava requested review of this revision.
REVISION SUMMARY
Use initializer list to create QSet
Don't check what doesn't needs to be checked.
the QBitArray knows how to deal with true / false
directly, so remove the if's. the speedgain of the
if's are probabely slower than just setting the values
to true / false again anyway as we are not suffering
from a possible branch-prediction, and plus, code is
cleaner.
No need to test for true / false to set true false
Just set it directly
REPOSITORY
R319 Konsole
BRANCH
incrementalSearchBarCodeModernization
REVISION DETAIL
https://phabricator.kde.org/D13512
AFFECTED FILES
src/IncrementalSearchBar.cpp
To: tcanabrava
Cc: konsole-devel, herrold, ngraham, maximilianocuria, hindenburg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/konsole-devel/attachments/20180613/f610ea1b/attachment.html>
More information about the konsole-devel
mailing list