2014-11-13 23:30 GMT+01:00 Tim Shen <[email protected]>:
> On Thu, Nov 13, 2014 at 2:11 PM, Daniel Krügler
> <[email protected]> wrote:
>> + typedef typename sub_match<_Bi_iter>::string_type string_type;
>
> Use _String_type instead of string_type? I'm not 100% sure of this.
I thought about this first, but withdraw that for two reasons: The
name string_type is not protected (it is an official typedef of
sub_match) and we use exactly the same approach elsewhere, e.g. see
around line 1318, 1346, 1398, 1426:
template<typename _Bi_iter>
inline bool
operator==(typename iterator_traits<_Bi_iter>::value_type const& __lhs,
const sub_match<_Bi_iter>& __rhs)
{
typedef typename sub_match<_Bi_iter>::string_type string_type;
return __rhs.compare(string_type(1, __lhs)) == 0;
}
So I followed for consistency reasons.
- Daniel