D26226: [KListOpenFilesJob] Use QString::splitRef()
David Faure
noreply at phabricator.kde.org
Thu Dec 26 14:29:32 GMT 2019
dfaure requested changes to this revision.
dfaure added inline comments.
This revision now requires changes to proceed.
INLINE COMMENTS
> klistopenfilesjob_unix.cpp:69
> const QString out(QString::fromLocal8Bit(lsofProcess.readAll()));
> - QStringList pidList = out.split(QRegularExpression(QStringLiteral("\\s+")), QString::SkipEmptyParts);
> - pidList.removeDuplicates();
> + QVector<QStringRef> pidList = out.splitRef(QRegularExpression(QStringLiteral("\\s+")), QString::SkipEmptyParts);
> for (const auto& pidStr : qAsConst(pidList)) {
Now you can make it `const` and remove the `qAsConst` on the next line.
REPOSITORY
R244 KCoreAddons
REVISION DETAIL
https://phabricator.kde.org/D26226
To: ahmadsamir, #frameworks, mpyne, dfaure, apol
Cc: kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20191226/70213793/attachment-0001.html>
More information about the Kde-frameworks-devel
mailing list