diff options
| author | fdumont <fdumont@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-08-01 19:54:46 +0000 |
|---|---|---|
| committer | fdumont <fdumont@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-08-01 19:54:46 +0000 |
| commit | 56c44694637f501b052658dec43f27fc99d8b391 (patch) | |
| tree | ed377bb0e83876a241613b80cb260f9f91684479 /libstdc++-v3/include/debug/list | |
| parent | 3f40d0f85be4aff6c2d322443e39dc32e9529bd0 (diff) | |
| download | ppe42-gcc-56c44694637f501b052658dec43f27fc99d8b391.tar.gz ppe42-gcc-56c44694637f501b052658dec43f27fc99d8b391.zip | |
2013-08-01 François Dumont <fdumont@gcc.gnu.org>
PR libstdc++/57779
* include/debug/formatter.h (_Debug_msg_id): Add
__msg_insert_itself_range entry.
* include/debug/functions.h (_Insert_range_from_self_is_safe<>):
New, indicate container types supporting self range insertion in
GNU implementation.
(__foreign_iterator): New, check if an iterator points to a given
sequence.
* include/debug/macros.h (__glibcxx_check_insert_range): Add check
using __foreign_iterator.
(__gibcxx_check_insert_range_after): Likewise.
* include/debug/string (_Insert_range_from_self_is_safe<>):
Partially specialized to mark __gnu_debug::basic_string<> as
supporting self range insert.
* include/debug/list (_Insert_range_from_self_is_safe<>):
Partially specialized to mark std::list as supporting self range
insert if _GLIBCXX_DEBUG_PEDANTIC is not defined.
* include/debug/forward_list (_Insert_range_from_self_is_safe<>):
Likewise.
* src/c++11/debug.cc (_S_debug_messages): Add
__msg_insert_itself_range_entry message.
(_Error_formatter::_Parameter::_M_print_description): Display
iterator sequence address rather than sequence address when the
parameter type is an iterator.
(_Error_formatter::_M_print_word): Enhance behavior when
displaying a word with an appended '\n'.
* testsuite/util/debug/checks.h (check_insert4<>): New.
* testsuite/23_containers/deque/debug/insert5_neg.cc: New.
* testsuite/23_containers/vector/debug/insert5_neg.cc: Likewise.
* testsuite/23_containers/vector/debug/insert6_neg.cc: Likewise.
* testsuite/23_containers/vector/debug/57779_neg.cc: Likewise.
* testsuite/23_containers/list/debug/insert5_neg.cc: Likewise.
* testsuite/23_containers/forward_list/debug/insert_after4_neg.cc:
Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@201416 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/debug/list')
| -rw-r--r-- | libstdc++-v3/include/debug/list | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libstdc++-v3/include/debug/list b/libstdc++-v3/include/debug/list index 1ae8507ca86..fd00b0148a9 100644 --- a/libstdc++-v3/include/debug/list +++ b/libstdc++-v3/include/debug/list @@ -791,4 +791,13 @@ namespace __debug } // namespace __debug } // namespace std +#ifndef _GLIBCXX_DEBUG_PEDANTIC +namespace __gnu_debug +{ + template<class _Tp, class _Alloc> + struct _Insert_range_from_self_is_safe<std::__debug::list<_Tp, _Alloc> > + { enum { __value = 1 }; }; +} +#endif + #endif |

