diff options
author | Tobias Markmann <tm@ayena.de> | 2014-10-19 20:22:58 (GMT) |
---|---|---|
committer | Tobias Markmann <tm@ayena.de> | 2014-10-20 13:49:33 (GMT) |
commit | 6b22dfcf59474dd016a0355a3102a1dd3692d92c (patch) | |
tree | 2b1fd33be433a91e81fee84fdc2bf1b52575d934 /3rdParty/Boost/src/boost/format/parsing.hpp | |
parent | 38b0cb785fea8eae5e48fae56440695fdfd10ee1 (diff) | |
download | swift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.zip swift-contrib-6b22dfcf59474dd016a0355a3102a1dd3692d92c.tar.bz2 |
Update Boost in 3rdParty to version 1.56.0.
This updates Boost in our 3rdParty directory to version 1.56.0.
Updated our update.sh script to stop on error.
Changed error reporting in SwiftTools/CrashReporter.cpp to SWIFT_LOG due to
missing include of <iostream> with newer Boost.
Change-Id: I4b35c77de951333979a524097f35f5f83d325edc
Diffstat (limited to '3rdParty/Boost/src/boost/format/parsing.hpp')
-rw-r--r-- | 3rdParty/Boost/src/boost/format/parsing.hpp | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/3rdParty/Boost/src/boost/format/parsing.hpp b/3rdParty/Boost/src/boost/format/parsing.hpp index b14ca82..3ff1828 100644 --- a/3rdParty/Boost/src/boost/format/parsing.hpp +++ b/3rdParty/Boost/src/boost/format/parsing.hpp @@ -358,75 +358,71 @@ namespace detail { const typename String::value_type arg_mark, const Facet& fac, unsigned char exceptions) { // quick-parsing of the format-string to count arguments mark (arg_mark, '%') // returns : upper bound on the number of format items in the format strings using namespace boost::io; typename String::size_type i1=0; int num_items=0; while( (i1=buf.find(arg_mark,i1)) != String::npos ) { if( i1+1 >= buf.size() ) { if(exceptions & bad_format_string_bit) boost::throw_exception(bad_format_string(i1, buf.size() )); // must not end in ".. %" else { ++num_items; break; } } if(buf[i1+1] == buf[i1] ) {// escaped "%%" i1+=2; continue; } ++i1; // in case of %N% directives, dont count it double (wastes allocations..) : i1 = detail::wrap_scan_notdigit(fac, buf.begin()+i1, buf.end()) - buf.begin(); if( i1 < buf.size() && buf[i1] == arg_mark ) ++i1; ++num_items; } return num_items; } template<class String> inline void append_string(String& dst, const String& src, const typename String::size_type beg, const typename String::size_type end) { -#if !defined(BOOST_NO_STRING_APPEND) dst.append(src.begin()+beg, src.begin()+end); -#else - dst += src.substr(beg, end-beg); -#endif } } // detail namespace } // io namespace // ----------------------------------------------- // format :: parse(..) template<class Ch, class Tr, class Alloc> basic_format<Ch, Tr, Alloc>& basic_format<Ch, Tr, Alloc>:: parse (const string_type& buf) { // parse the format-string using namespace std; #if !defined(BOOST_NO_STD_LOCALE) const std::ctype<Ch> & fac = BOOST_USE_FACET( std::ctype<Ch>, getloc()); #else io::basic_oaltstringstream<Ch, Tr, Alloc> fac; //has widen and narrow even on compilers without locale #endif const Ch arg_mark = io::detail::const_or_not(fac).widen( '%'); bool ordered_args=true; int max_argN=-1; // A: find upper_bound on num_items and allocates arrays int num_items = io::detail::upper_bound_from_fstring(buf, arg_mark, fac, exceptions()); make_or_reuse_data(num_items); // B: Now the real parsing of the format string : num_items=0; typename string_type::size_type i0=0, i1=0; typename string_type::const_iterator it; bool special_things=false; |