[kpeople] make it compile without foreach
ClosedPublic

Authored by mlaurent on Mar 22 2019, 8:02 AM.

Details

Summary

compile without foreach

Test Plan

autotest ok

Diff Detail

Repository
R307 KPeople
Branch
compile_without_foreach (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 10093
Build 10111: arc lint + arc unit
mlaurent created this revision.Mar 22 2019, 8:02 AM
Restricted Application added a project: Frameworks. · View Herald TranscriptMar 22 2019, 8:02 AM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
mlaurent requested review of this revision.Mar 22 2019, 8:02 AM
pino added a subscriber: pino.Mar 22 2019, 8:40 AM
pino added inline comments.
src/matchessolver.cpp
61–66

iterators, please

apol added a subscriber: apol.Mar 22 2019, 1:26 PM
apol added inline comments.
src/matchessolver.cpp
63

You are calling destinationResolver.keys(urlB) twice here.

mlaurent updated this revision to Diff 54563.Mar 22 2019, 2:28 PM

Remove duplicate call

dfaure requested changes to this revision.Mar 24 2019, 3:24 PM
dfaure added inline comments.
src/matchessolver.cpp
62–66

lst used to be called keys, there's no particular reason to rename it.

src/metacontact.cpp
51

(the qAsConst isn't technically needed since this method is const; but it doesn't hurt either)

src/widgets/plugins/mergecontactswidget.cpp
185

const & would be even better.

(It'll get lengthy, so this might be a reason to switch for const auto & here, although some might object that the type isn't visible in the code here)

This revision now requires changes to proceed.Mar 24 2019, 3:24 PM
mlaurent updated this revision to Diff 54749.Mar 25 2019, 5:59 AM

Fix error reported by david

dfaure accepted this revision.Mar 25 2019, 8:25 AM
This revision is now accepted and ready to land.Mar 25 2019, 8:25 AM
This revision was automatically updated to reflect the committed changes.