Skip to content

Commit 85561dd

Browse files
committed
[libc++] Fix bounded iterator hardening mode in C++03 mode
1 parent 8e3aa7e commit 85561dd

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

libcxx/include/string

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -827,8 +827,8 @@ public:
827827
// Users might provide custom allocators, and prior to C++20 we have no existing way to detect whether the allocator's
828828
// pointer type is contiguous (though it has to be by the Standard). Using the wrapper type ensures the iterator is
829829
// considered contiguous.
830-
typedef __bounded_iter<__wrap_iter<pointer>> iterator;
831-
typedef __bounded_iter<__wrap_iter<const_pointer>> const_iterator;
830+
typedef __bounded_iter<__wrap_iter<pointer> > iterator;
831+
typedef __bounded_iter<__wrap_iter<const_pointer> > const_iterator;
832832
#else
833833
typedef __wrap_iter<pointer> iterator;
834834
typedef __wrap_iter<const_pointer> const_iterator;

libcxx/include/vector

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -404,8 +404,8 @@ public:
404404
// Users might provide custom allocators, and prior to C++20 we have no existing way to detect whether the allocator's
405405
// pointer type is contiguous (though it has to be by the Standard). Using the wrapper type ensures the iterator is
406406
// considered contiguous.
407-
typedef __bounded_iter<__wrap_iter<pointer>> iterator;
408-
typedef __bounded_iter<__wrap_iter<const_pointer>> const_iterator;
407+
typedef __bounded_iter<__wrap_iter<pointer> > iterator;
408+
typedef __bounded_iter<__wrap_iter<const_pointer> > const_iterator;
409409
#else
410410
typedef __wrap_iter<pointer> iterator;
411411
typedef __wrap_iter<const_pointer> const_iterator;

0 commit comments

Comments
 (0)