chart2/source/tools/DataSeriesHelper.cxx |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

New commits:
commit d90293e7ec42eab0ca09f730371599adc466e349
Author: Jochen Nitschke <j.nitschke+loger...@ok.de>
Date:   Sun Jul 9 15:28:19 2017 +0200

    C++11 replace std::remove_copy_if with std::copy_if
    
    remove_copy_if copies entries for which predicate returns false.
    since C++11 there is copy_if which copies entries for which
    predicate returns true.
    
    Change-Id: I3ade82f13d27364e2cd35f4286b18128f52f8a5b
    Reviewed-on: https://gerrit.libreoffice.org/39727
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Jochen Nitschke <j.nitschke+loger...@ok.de>

diff --git a/chart2/source/tools/DataSeriesHelper.cxx 
b/chart2/source/tools/DataSeriesHelper.cxx
index 34fd73540e64..f292948cef37 100644
--- a/chart2/source/tools/DataSeriesHelper.cxx
+++ b/chart2/source/tools/DataSeriesHelper.cxx
@@ -230,11 +230,9 @@ std::vector< Reference< chart2::data::XLabeledDataSequence 
> >
                                const OUString& aRole, bool bMatchPrefix /* = 
false */ )
 {
     std::vector< Reference< chart2::data::XLabeledDataSequence > > aResultVec;
-    std::remove_copy_if( aDataSequences.begin(), aDataSequences.end(),
+    std::copy_if( aDataSequences.begin(), aDataSequences.end(),
                            std::back_inserter( aResultVec ),
-                           [&aRole, bMatchPrefix](const Reference< 
chart2::data::XLabeledDataSequence > & xSeq)
-                           {return !(lcl_MatchesRole(aRole, 
bMatchPrefix).operator()(xSeq));});
-                            //TODO replace lambda with 
std::not_fn(lcl_MatchesRole(aRole, bMatchPrefix) in C++17
+                           lcl_MatchesRole(aRole, bMatchPrefix) );
     return aResultVec;
 }
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to