From 8700307cf574e4dc31bade7a45b5694e289e96d7 Mon Sep 17 00:00:00 2001 From: John Maddock Date: Thu, 9 Nov 2000 13:03:41 +0000 Subject: [PATCH] regex fixes for updated Dinkum library [SVN r8161] --- include/boost/re_detail/regex_compile.hpp | 3 ++- include/boost/re_detail/regex_config.hpp | 11 +++++++---- include/boost/re_detail/regex_split.hpp | 1 + 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/include/boost/re_detail/regex_compile.hpp b/include/boost/re_detail/regex_compile.hpp index 6b1b1f5e..ba559bee 100644 --- a/include/boost/re_detail/regex_compile.hpp +++ b/include/boost/re_detail/regex_compile.hpp @@ -1240,7 +1240,8 @@ unsigned int BOOST_RE_CALL reg_expression::set_express register traits_size_type c; register re_detail::re_syntax_base* dat; - unsigned rep_min, rep_max; + unsigned rep_min = 0; + unsigned rep_max = 0; // // set up header: diff --git a/include/boost/re_detail/regex_config.hpp b/include/boost/re_detail/regex_config.hpp index 77f31cf7..a943db80 100644 --- a/include/boost/re_detail/regex_config.hpp +++ b/include/boost/re_detail/regex_config.hpp @@ -618,10 +618,13 @@ typedef unsigned long jm_uintfast32_t; #define BOOST_RE_NEED_ALLOC #define BOOST_RE_STL_DONE - - #define BOOST_RE_USE_FACET(l, type) std::use_facet(l, (type*)0, true) - #define BOOST_RE_HAS_FACET(l, type) std::has_facet(l, (type*)0) - + #ifndef _CPPLIB_VER + #define BOOST_RE_USE_FACET(l, type) std::use_facet(l, (type*)0, true) + #define BOOST_RE_HAS_FACET(l, type) std::has_facet(l, (type*)0) + #else + #define BOOST_RE_USE_FACET(l, type) std::use_facet(l, (type*)0) + #define BOOST_RE_HAS_FACET(l, type) std::has_facet(l, (type*)0) + #endif #else diff --git a/include/boost/re_detail/regex_split.hpp b/include/boost/re_detail/regex_split.hpp index 2273bc08..321c5820 100644 --- a/include/boost/re_detail/regex_split.hpp +++ b/include/boost/re_detail/regex_split.hpp @@ -118,6 +118,7 @@ std::size_t regex_split(OutputIterator out, *out = std::basic_string((ci_t)last, (ci_t)s.end()); ++out; last = s.end(); + --max_split; } // // delete from the string everything that has been processed so far: