Patchwork [v3] fix TODO in <bits/regex.h>

login
register
mail settings
Submitter Jonathan Wakely
Date Dec. 23, 2011, 1:49 a.m.
Message ID <CAH6eHdQvv5imOTVoRN8T2L1VWt09OMCeUREyvKm94DafVoQDCg@mail.gmail.com>
Download mbox | patch
Permalink /patch/132932/
State New
Headers show

Comments

Jonathan Wakely - Dec. 23, 2011, 1:49 a.m.
* include/bits/regex.h (match_results::size_type): Use
        allocator_traits.

Tested x86_64-linux, committed to trunk

Patch

Index: include/bits/regex.h
===================================================================
--- include/bits/regex.h	(revision 182644)
+++ include/bits/regex.h	(revision 182645)
@@ -1490,8 +1490,8 @@  _GLIBCXX_BEGIN_NAMESPACE_VERSION
       typedef const_iterator                                  iterator;
       typedef typename std::iterator_traits<_Bi_iter>::difference_type
                                                               difference_type;
-      /* TODO: needs allocator_traits */
-      typedef typename _Allocator::size_type                  size_type;
+      typedef typename allocator_traits<_Allocator>::size_type
+                                                              size_type;
       typedef _Allocator                                      allocator_type;
       typedef typename std::iterator_traits<_Bi_iter>::value_type
                                                               char_type;