mirror of
https://github.com/boostorg/regex.git
synced 2025-07-18 23:02:09 +02:00
Change detail namespace.
Big search and replace to change name of internal namepace so it's mangled with the Boost version number - the aim is to reduce the chances of mixing different header and library versions.
This commit is contained in:
@ -55,7 +55,7 @@ namespace boost{
|
||||
template <class BidiIterator, class Allocator = BOOST_DEDUCED_TYPENAME std::vector<sub_match<BidiIterator> >::allocator_type >
|
||||
class match_results;
|
||||
|
||||
namespace re_detail{
|
||||
namespace BOOST_REGEX_DETAIL_NS{
|
||||
|
||||
//
|
||||
// struct trivial_format_traits:
|
||||
@ -73,11 +73,11 @@ struct trivial_format_traits
|
||||
}
|
||||
static charT tolower(charT c)
|
||||
{
|
||||
return ::boost::re_detail::global_lower(c);
|
||||
return ::boost::BOOST_REGEX_DETAIL_NS::global_lower(c);
|
||||
}
|
||||
static charT toupper(charT c)
|
||||
{
|
||||
return ::boost::re_detail::global_upper(c);
|
||||
return ::boost::BOOST_REGEX_DETAIL_NS::global_upper(c);
|
||||
}
|
||||
static int value(const charT c, int radix)
|
||||
{
|
||||
@ -359,7 +359,7 @@ void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format
|
||||
default:
|
||||
// see if we have a number:
|
||||
{
|
||||
std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end);
|
||||
std::ptrdiff_t len = ::boost::BOOST_REGEX_DETAIL_NS::distance(m_position, m_end);
|
||||
//len = (std::min)(static_cast<std::ptrdiff_t>(2), len);
|
||||
int v = this->toi(m_position, m_position + len, 10);
|
||||
if((v < 0) || (have_brace && ((m_position == m_end) || (*m_position != '}'))))
|
||||
@ -570,7 +570,7 @@ void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format
|
||||
}
|
||||
else
|
||||
{
|
||||
std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end);
|
||||
std::ptrdiff_t len = ::boost::BOOST_REGEX_DETAIL_NS::distance(m_position, m_end);
|
||||
len = (std::min)(static_cast<std::ptrdiff_t>(2), len);
|
||||
int val = this->toi(m_position, m_position + len, 16);
|
||||
if(val < 0)
|
||||
@ -634,7 +634,7 @@ void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format
|
||||
break;
|
||||
}
|
||||
// see if we have a \n sed style backreference:
|
||||
std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end);
|
||||
std::ptrdiff_t len = ::boost::BOOST_REGEX_DETAIL_NS::distance(m_position, m_end);
|
||||
len = (std::min)(static_cast<std::ptrdiff_t>(1), len);
|
||||
int v = this->toi(m_position, m_position+len, 10);
|
||||
if((v > 0) || ((v == 0) && (m_flags & ::boost::regex_constants::format_sed)))
|
||||
@ -646,7 +646,7 @@ void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format
|
||||
{
|
||||
// octal ecape sequence:
|
||||
--m_position;
|
||||
len = ::boost::re_detail::distance(m_position, m_end);
|
||||
len = ::boost::BOOST_REGEX_DETAIL_NS::distance(m_position, m_end);
|
||||
len = (std::min)(static_cast<std::ptrdiff_t>(4), len);
|
||||
v = this->toi(m_position, m_position + len, 8);
|
||||
BOOST_ASSERT(v >= 0);
|
||||
@ -693,7 +693,7 @@ void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format
|
||||
}
|
||||
else
|
||||
{
|
||||
std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end);
|
||||
std::ptrdiff_t len = ::boost::BOOST_REGEX_DETAIL_NS::distance(m_position, m_end);
|
||||
len = (std::min)(static_cast<std::ptrdiff_t>(2), len);
|
||||
v = this->toi(m_position, m_position + len, 10);
|
||||
}
|
||||
@ -835,10 +835,10 @@ OutputIterator regex_format_imp(OutputIterator out,
|
||||
{
|
||||
if(flags & regex_constants::format_literal)
|
||||
{
|
||||
return re_detail::copy(p1, p2, out);
|
||||
return BOOST_REGEX_DETAIL_NS::copy(p1, p2, out);
|
||||
}
|
||||
|
||||
re_detail::basic_regex_formatter<
|
||||
BOOST_REGEX_DETAIL_NS::basic_regex_formatter<
|
||||
OutputIterator,
|
||||
match_results<Iterator, Alloc>,
|
||||
traits, ForwardIter> f(out, m, t);
|
||||
@ -1028,7 +1028,7 @@ struct format_functor1
|
||||
template <class S, class OutputIter>
|
||||
OutputIter do_format_string(const S& s, OutputIter i)
|
||||
{
|
||||
return re_detail::copy(s.begin(), s.end(), i);
|
||||
return BOOST_REGEX_DETAIL_NS::copy(s.begin(), s.end(), i);
|
||||
}
|
||||
template <class S, class OutputIter>
|
||||
inline OutputIter do_format_string(const S* s, OutputIter i)
|
||||
@ -1085,7 +1085,7 @@ struct format_functor_container
|
||||
OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits& t = Traits())
|
||||
{
|
||||
//typedef typename Match::char_type char_type;
|
||||
return re_detail::regex_format_imp(i, m, func.begin(), func.end(), f, t);
|
||||
return BOOST_REGEX_DETAIL_NS::regex_format_imp(i, m, func.begin(), func.end(), f, t);
|
||||
}
|
||||
private:
|
||||
const Container& func;
|
||||
@ -1093,7 +1093,7 @@ private:
|
||||
format_functor_container& operator=(const format_functor_container&);
|
||||
};
|
||||
|
||||
template <class Func, class Match, class OutputIterator, class Traits = re_detail::trivial_format_traits<typename Match::char_type> >
|
||||
template <class Func, class Match, class OutputIterator, class Traits = BOOST_REGEX_DETAIL_NS::trivial_format_traits<typename Match::char_type> >
|
||||
struct compute_functor_type
|
||||
{
|
||||
typedef typename format_traits<Func, Match, OutputIterator>::type tag;
|
||||
@ -1114,7 +1114,7 @@ struct compute_functor_type
|
||||
>::type type;
|
||||
};
|
||||
|
||||
} // namespace re_detail
|
||||
} // namespace BOOST_REGEX_DETAIL_NS
|
||||
|
||||
template <class OutputIterator, class Iterator, class Allocator, class Functor>
|
||||
inline OutputIterator regex_format(OutputIterator out,
|
||||
|
Reference in New Issue
Block a user