From ad76df9f7724dbeb50a8adf0a32494cd644fc1ad Mon Sep 17 00:00:00 2001 From: John Maddock Date: Mon, 10 Jun 2013 15:32:34 +0000 Subject: [PATCH] Change type of string index to std::string::difference_type. [SVN r84729] --- include/boost/multiprecision/cpp_int.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/boost/multiprecision/cpp_int.hpp b/include/boost/multiprecision/cpp_int.hpp index b4c432f8..ff518d6f 100644 --- a/include/boost/multiprecision/cpp_int.hpp +++ b/include/boost/multiprecision/cpp_int.hpp @@ -1456,7 +1456,7 @@ private: limb_type mask = static_cast((1u << shift) - 1); typename base_type::local_limb_type v = *this->limbs(); result.assign(Bits / shift + (Bits % shift ? 1 : 0), '0'); - int pos = result.size() - 1; + std::string::difference_type pos = result.size() - 1; for(unsigned i = 0; i < Bits / shift; ++i) { char c = '0' + static_cast(v & mask); @@ -1489,7 +1489,7 @@ private: else { result.assign(Bits / 3 + 1, '0'); - int pos = result.size() - 1; + std::string::difference_type pos = result.size() - 1; typename base_type::local_limb_type v(*this->limbs()); bool neg = false; if(this->sign()) @@ -1541,7 +1541,7 @@ private: limb_type mask = static_cast((1u << shift) - 1); cpp_int_backend t(*this); result.assign(Bits / shift + (Bits % shift ? 1 : 0), '0'); - int pos = result.size() - 1; + std::string::difference_type pos = result.size() - 1; for(unsigned i = 0; i < Bits / shift; ++i) { char c = '0' + static_cast(t.limbs()[0] & mask); @@ -1574,7 +1574,7 @@ private: else { result.assign(Bits / 3 + 1, '0'); - int pos = result.size() - 1; + std::string::difference_type pos = result.size() - 1; cpp_int_backend t(*this); cpp_int_backend r; bool neg = false;