D12578: fix some issues reported by clazy

Stefan BrĂ¼ns noreply at phabricator.kde.org
Sat Apr 28 16:07:36 UTC 2018


bruns added inline comments.

INLINE COMMENTS

> CMakeLists.txt:4
>  set(REQUIRED_QT_VERSION 5.8.0)
> -set(KF5_VERSION "5.45.0") # handled by release scripts
> -set(KF5_DEP_VERSION "5.45.0") # handled by release scripts
> +set(KF5_VERSION "5.44.0") # handled by release scripts
> +set(KF5_DEP_VERSION "5.44.0") # handled by release scripts

I don't think this belongs in here

> transaction.cpp:326
>  
> -    for (const EngineQuery& q : query.subQueries()) {
> +    const auto subQueries = query.subQueries();
> +    for (const EngineQuery& q : subQueries) {

Move this one up, before the `query.op() == EngineQuery::Phrase)`

> transaction.cpp:508
>              out << "\tFileNameTermsDB: ";
> -            for (const QByteArray& term : terms) {
> +            for (const QByteArray& term : fileNameTerms) {
>                  out << term << " ";

This is a functional change and should not be hidden between "cosmetical" changes

> searchstore.cpp:167
>  
> -        for (const Term& t : term.subTerms()) {
> +        for (const Term& t : subTerms) {
>              vec << constructQuery(tr, t);

No const here?

REPOSITORY
  R293 Baloo

REVISION DETAIL
  https://phabricator.kde.org/D12578

To: mgallien, #baloo, #frameworks
Cc: bruns, ashaposhnikov, michaelh, astippich, spoorun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180428/259a7782/attachment.html>


More information about the Kde-frameworks-devel mailing list