Boost logo

Boost-Commit :

From: john_at_[hidden]
Date: 2007-12-11 12:29:59


Author: johnmaddock
Date: 2007-12-11 12:29:58 EST (Tue, 11 Dec 2007)
New Revision: 41974
URL: http://svn.boost.org/trac/boost/changeset/41974

Log:
Merged fixes for #1471 (warning suppression).
Text files modified:
   branches/release/boost/regex/v4/cpp_regex_traits.hpp | 2 +-
   branches/release/boost/regex/v4/regex_workaround.hpp | 9 ++++++---
   2 files changed, 7 insertions(+), 4 deletions(-)

Modified: branches/release/boost/regex/v4/cpp_regex_traits.hpp
==============================================================================
--- branches/release/boost/regex/v4/cpp_regex_traits.hpp (original)
+++ branches/release/boost/regex/v4/cpp_regex_traits.hpp 2007-12-11 12:29:58 EST (Tue, 11 Dec 2007)
@@ -128,7 +128,7 @@
       break;
    case ::std::ios_base::cur:
    {
- std::ptrdiff_t newpos = pos + off;
+ std::ptrdiff_t newpos = static_cast<std::ptrdiff_t>(pos + off);
       if((newpos < 0) || (newpos > size))
          return pos_type(off_type(-1));
       else

Modified: branches/release/boost/regex/v4/regex_workaround.hpp
==============================================================================
--- branches/release/boost/regex/v4/regex_workaround.hpp (original)
+++ branches/release/boost/regex/v4/regex_workaround.hpp 2007-12-11 12:29:58 EST (Tue, 11 Dec 2007)
@@ -150,13 +150,16 @@
       return stdext::unchecked_equal(first, last, with);
    }
 
+#else
+ using std::copy;
+ using std::equal;
+#endif
+#if BOOST_WORKAROUND(BOOST_MSVC,>=1400) && defined(__STDC_WANT_SECURE_LIB__) && __STDC_WANT_SECURE_LIB__
+
    // use safe versions of strcpy etc:
    using ::strcpy_s;
    using ::strcat_s;
 #else
- using std::copy;
- using std::equal;
-
    inline std::size_t strcpy_s(
       char *strDestination,
       std::size_t sizeInBytes,


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk