From 5f1c3d4deeb4832a1ff81b443338320064b1cd9c Mon Sep 17 00:00:00 2001 From: bolero-MURAKAMI Date: Wed, 2 Oct 2013 17:09:33 +0900 Subject: [PATCH] fix string: comparison of signed and unsigned integer --- sprout/string/string.hpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sprout/string/string.hpp b/sprout/string/string.hpp index e537738d..75f07ab0 100644 --- a/sprout/string/string.hpp +++ b/sprout/string/string.hpp @@ -38,7 +38,6 @@ # include #endif - namespace sprout { namespace detail { template @@ -154,7 +153,7 @@ namespace sprout { : value_type() )... } - , len(!(N < n) ? n + , len(!sprout::math::less(N, n) ? n : throw std::out_of_range("basic_string<>: index out of range") ) {} @@ -169,7 +168,7 @@ namespace sprout { : value_type() )... } - , len(!(N < n) ? n + , len(!sprout::math::less(N, n) ? n : throw std::out_of_range("basic_string<>: index out of range") ) {}