D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-29 Thread Friedrich W. H. Kossebau
kossebau added a comment. Also compared binary size? ;) You still want to use QLatin1Char with single characters, that is less undisputed agreed upon as better choice :) REPOSITORY R237 KConfig REVISION DETAIL https://phabricator.kde.org/D26868 To: tcanabrava, ervin, dfaure Cc: kossebau

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-29 Thread Tomaz Canabrava
tcanabrava updated this revision to Diff 74600. tcanabrava added a comment. - Fix code style REPOSITORY R237 KConfig CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D26868?vs=74234&id=74600 BRANCH simplify_newEntry REVISION DETAIL https://phabricator.kde.org/D26868 AFFECTED F

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-29 Thread Tomaz Canabrava
tcanabrava added a comment. In D26868#602162 , @kossebau wrote: > In D26868#602150 , @dfaure wrote: > > > There is indeed a QString overload for concatenating QLatin1String, but it will have to be co

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-28 Thread Friedrich W. H. Kossebau
kossebau added a comment. In D26868#602150 , @dfaure wrote: > There is indeed a QString overload for concatenating QLatin1String, but it will have to be converted char-by-char (from 8 bits to 16 bits), so isn't it faster to concatenate QStringLi

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-28 Thread David Faure
dfaure added a comment. There is indeed a QString overload for concatenating QLatin1String, but it will have to be converted char-by-char (from 8 bits to 16 bits), so isn't it faster to concatenate QStringLiterals? REPOSITORY R237 KConfig REVISION DETAIL https://phabricator.kde.org/D268

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-28 Thread Friedrich W. H. Kossebau
kossebau added a comment. And more while at it: for latin1 strings used in concatenation it is recommended to use QLatin1String and for single chars QLatin1Char. QStringLiteral is more expensive here, and QStringBuilder & QString has proper overloads for the concatenations. So you want to ke

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-28 Thread Kevin Ottens
ervin added inline comments. INLINE COMMENTS > KConfigSourceGenerator.cpp:659 > + > +QString KConfigSourceGenerator::newItem(const CfgEntry* entry, const QString > &key, const QString& defaultValue, const QString ¶m) > +{ Since we're here, what about fixing the coding style? (same thing for the

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-24 Thread Tomaz Canabrava
tcanabrava added reviewers: ervin, dfaure. REPOSITORY R237 KConfig REVISION DETAIL https://phabricator.kde.org/D26868 To: tcanabrava, ervin, dfaure Cc: kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns

D26868: Move newItem to private method in KConfigSourceGenerator

2020-01-23 Thread Tomaz Canabrava
tcanabrava created this revision. Herald added a project: Frameworks. Herald added a subscriber: kde-frameworks-devel. tcanabrava requested review of this revision. REVISION SUMMARY This is only used here, should only be exposed here. TEST PLAN Run unittests REPOSITORY R237 KConfig BRANCH