From 1e14fb7253d09eed094260dd28009b65540a11ed Mon Sep 17 00:00:00 2001 From: bolero-MURAKAMI Date: Sat, 22 Oct 2011 21:25:25 +0900 Subject: [PATCH] algorithm/* fix --- sprout/algorithm/fixed/merge.hpp | 7 ++++--- sprout/algorithm/fixed/set_difference.hpp | 7 ++++--- sprout/algorithm/fixed/set_intersection.hpp | 7 ++++--- sprout/algorithm/fixed/set_symmetric_difference.hpp | 7 ++++--- sprout/algorithm/fixed/set_union.hpp | 7 ++++--- sprout/algorithm/fixed/sort.hpp | 1 - 6 files changed, 20 insertions(+), 16 deletions(-) diff --git a/sprout/algorithm/fixed/merge.hpp b/sprout/algorithm/fixed/merge.hpp index c991785c..27ad86e7 100644 --- a/sprout/algorithm/fixed/merge.hpp +++ b/sprout/algorithm/fixed/merge.hpp @@ -1,11 +1,12 @@ #ifndef SPROUT_ALGORITHM_FIXED_MERGE_HPP #define SPROUT_ALGORITHM_FIXED_MERGE_HPP +#include #include #include #include #include -#include +#include #include #include HDR_FUNCTIONAL_SSCRISK_CEL_OR_SPROUT_DETAIL @@ -66,7 +67,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? first1 != last1 ? first2 != last2 ? comp(*first2, *first1) @@ -111,7 +112,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? merge_impl_1(first1, last1, first2, last2, result, comp, offset, args..., *sprout::next(sprout::fixed_begin(result), sizeof...(Args))) : merge_impl_2(first1, last1, first2, last2, result, comp, offset + sprout::size(result), args...) ; diff --git a/sprout/algorithm/fixed/set_difference.hpp b/sprout/algorithm/fixed/set_difference.hpp index 4c2c841d..095eae3e 100644 --- a/sprout/algorithm/fixed/set_difference.hpp +++ b/sprout/algorithm/fixed/set_difference.hpp @@ -1,11 +1,12 @@ #ifndef SPROUT_ALGORITHM_FIXED_SET_DIFFERENCE_HPP #define SPROUT_ALGORITHM_FIXED_SET_DIFFERENCE_HPP +#include #include #include #include #include -#include +#include #include #include HDR_FUNCTIONAL_SSCRISK_CEL_OR_SPROUT_DETAIL @@ -66,7 +67,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? first1 != last1 ? first2 != last2 ? comp(*first1, *first2) @@ -113,7 +114,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? set_difference_impl_1(first1, last1, first2, last2, result, comp, offset, args..., *sprout::next(sprout::fixed_begin(result), sizeof...(Args))) : set_difference_impl_2(first1, last1, first2, last2, result, comp, offset + sprout::size(result), args...) ; diff --git a/sprout/algorithm/fixed/set_intersection.hpp b/sprout/algorithm/fixed/set_intersection.hpp index 074ffdaa..3081cfe3 100644 --- a/sprout/algorithm/fixed/set_intersection.hpp +++ b/sprout/algorithm/fixed/set_intersection.hpp @@ -1,11 +1,12 @@ #ifndef SPROUT_ALGORITHM_FIXED_SET_INTERSECTION_HPP #define SPROUT_ALGORITHM_FIXED_SET_INTERSECTION_HPP +#include #include #include #include #include -#include +#include #include #include HDR_FUNCTIONAL_SSCRISK_CEL_OR_SPROUT_DETAIL @@ -66,7 +67,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? first1 != last1 ? first2 != last2 ? comp(*first1, *first2) @@ -113,7 +114,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? set_intersection_impl_1(first1, last1, first2, last2, result, comp, offset, args..., *sprout::next(sprout::fixed_begin(result), sizeof...(Args))) : set_intersection_impl_2(first1, last1, first2, last2, result, comp, offset + sprout::size(result), args...) ; diff --git a/sprout/algorithm/fixed/set_symmetric_difference.hpp b/sprout/algorithm/fixed/set_symmetric_difference.hpp index 814c1e9f..08c5fc6c 100644 --- a/sprout/algorithm/fixed/set_symmetric_difference.hpp +++ b/sprout/algorithm/fixed/set_symmetric_difference.hpp @@ -1,11 +1,12 @@ #ifndef SPROUT_ALGORITHM_FIXED_SET_SYMMETRIC_DIFFERENCE_HPP #define SPROUT_ALGORITHM_FIXED_SET_SYMMETRIC_DIFFERENCE_HPP +#include #include #include #include #include -#include +#include #include #include HDR_FUNCTIONAL_SSCRISK_CEL_OR_SPROUT_DETAIL @@ -66,7 +67,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? first1 != last1 ? first2 != last2 ? comp(*first1, *first2) @@ -113,7 +114,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? set_symmetric_difference_impl_1(first1, last1, first2, last2, result, comp, offset, args..., *sprout::next(sprout::fixed_begin(result), sizeof...(Args))) : set_symmetric_difference_impl_2(first1, last1, first2, last2, result, comp, offset + sprout::size(result), args...) ; diff --git a/sprout/algorithm/fixed/set_union.hpp b/sprout/algorithm/fixed/set_union.hpp index 03195be9..e87f3d6b 100644 --- a/sprout/algorithm/fixed/set_union.hpp +++ b/sprout/algorithm/fixed/set_union.hpp @@ -1,11 +1,12 @@ #ifndef SPROUT_ALGORITHM_FIXED_SET_UNION_HPP #define SPROUT_ALGORITHM_FIXED_SET_UNION_HPP +#include #include #include #include #include -#include +#include #include #include HDR_FUNCTIONAL_SSCRISK_CEL_OR_SPROUT_DETAIL @@ -66,7 +67,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? first1 != last1 ? first2 != last2 ? comp(*first1, *first2) @@ -113,7 +114,7 @@ namespace sprout { Args const&... args ) { - return sizeof...(Args) < offset + return sizeof...(Args) < static_cast(offset) ? set_union_impl_1(first1, last1, first2, last2, result, comp, offset, args..., *sprout::next(sprout::fixed_begin(result), sizeof...(Args))) : set_union_impl_2(first1, last1, first2, last2, result, comp, offset + sprout::size(result), args...) ; diff --git a/sprout/algorithm/fixed/sort.hpp b/sprout/algorithm/fixed/sort.hpp index bf3f44d7..60cf08ab 100644 --- a/sprout/algorithm/fixed/sort.hpp +++ b/sprout/algorithm/fixed/sort.hpp @@ -200,7 +200,6 @@ namespace sprout { } } // namespace detail // - // sort // template