]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/libs/poly_collection/test/test_algorithm_impl.hpp
update sources to ceph Nautilus 14.2.1
[ceph.git] / ceph / src / boost / libs / poly_collection / test / test_algorithm_impl.hpp
index 4b0e2f34c9642de627e7b96dd82cb2241688067f..16c3499ff4b2da1b46c96950477ca12de19b1c7c 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright 2016-2017 Joaquin M Lopez Munoz.
+/* Copyright 2016-2018 Joaquin M Lopez Munoz.
  * Distributed under the Boost Software License, Version 1.0.
  * (See accompanying file LICENSE_1_0.txt or copy at
  * http://www.boost.org/LICENSE_1_0.txt)
@@ -213,15 +213,15 @@ struct std_is_permutation:std_cpp11_is_permutation<Ts...>
     ForwardIterator1 first1,ForwardIterator1 last1,
     ForwardIterator2 first2,Predicate pred)const
   {
+    using difference_type=
+      typename std::iterator_traits<ForwardIterator1>::difference_type;
+
     for(;first1!=last1;++first1,(void)++first2){
       if(!pred(*first1,*first2))goto not_done;
     }
     return true;
 
   not_done:
-    using difference_type=
-      typename std::iterator_traits<ForwardIterator1>::difference_type;
-
     difference_type l1=std::distance(first1,last1);
     if(l1==difference_type(1))return false;