---
name: "__gnu_debug::def_deque"
section: "3"
platform: "linux"
package: "libstdc++6-doc"
version: "3.4.6-5"
release: "Debian 4.0 (Etch)"
platforms: ["linux"]
url: "https://new.carta.tech/__gnu_debug::def_deque"
---

# \_\_gnu\_debug::def\_deque(3)

## NAME

\_\_gnu\_debug\_def::deque -

## SYNOPSIS

Inherits **std::deque\< Type, Allocator \>**, and **\_\_gnu\_debug::Safe\_sequence\< Sequence \>\< \_\_gnu\_debug\_def::deque\< Type, Allocator \> \>**.

### Public Types

typedef Allocator::reference **reference**\
 typedef Allocator::const\_reference **const\_reference**\
 typedef **\_\_gnu\_debug::Safe\_iterator**\< typename **Base::iterator**, **deque** \> **iterator**\
 typedef **\_\_gnu\_debug::Safe\_iterator**\< typename **Base::const\_iterator**, **deque** \> **const\_iterator**\
 typedef **Base::size\_type** **size\_type**\
 typedef **Base::difference\_type** **difference\_type**\
 typedef Type **value\_type**\
 typedef Allocator **allocator\_type**\
 typedef Allocator::pointer **pointer**\
 typedef Allocator::const\_pointer **const\_pointer**\
 typedef **std::reverse\_iterator**\< **iterator** \> **reverse\_iterator**\
 typedef **std::reverse\_iterator**\< **const\_iterator** \> **const\_reverse\_iterator**\

### Public Member Functions

**deque** (const Allocator &a=Allocator())\
 **deque** (**size\_type** n, const Type &value=Type(), const Allocator &a=Allocator())\
 template\<class InputIterator\> **deque** (InputIterator first, InputIterator last, const Allocator &a=Allocator())\
 **deque** (const **deque**\< Type, Allocator \> &x)\
 **deque** (const **Base** &x)\
 **~deque** ()\
 **deque**\< Type, Allocator \> & **operator=** (const **deque**\< Type, Allocator \> &x)\
 template\<class InputIterator\> void **assign** (InputIterator first, InputIterator last)\
 *Assigns a range to a deque.*  void **assign** (**size\_type** n, const Type &\_\_t)\
 *Assigns a given value to a deque.*  **iterator** **begin** ()\
 **const\_iterator** **begin** () const\
 **iterator** **end** ()\
 **const\_iterator** **end** () const\
 **reverse\_iterator** **rbegin** ()\
 **const\_reverse\_iterator** **rbegin** () const\
 **reverse\_iterator** **rend** ()\
 **const\_reverse\_iterator** **rend** () const\
 void **resize** (**size\_type** sz, Type c=Type())\
 **reference** **operator\[\]** (**size\_type** n)\
 *Subscript access to the data contained in the deque.*  **const\_reference** **operator\[\]** (**size\_type** n) const \
 *Subscript access to the data contained in the deque.*  **reference** **front** ()\
 **const\_reference** **front** () const\
 **reference** **back** ()\
 **const\_reference** **back** () const\
 void **push\_front** (const Type &x)\
 *Add data to the front of the deque.*  void **push\_back** (const Type &x)\
 *Add data to the end of the deque.*  **iterator** **insert** (**iterator** position, const Type &x)\
 void **insert** (**iterator** position, **size\_type** n, const Type &x)\
 template\<class InputIterator\> void **insert** (**iterator** position, InputIterator first, InputIterator last)\
 void **pop\_front** ()\
 *Removes first element.*  void **pop\_back** ()\
 *Removes last element.*  **iterator** **erase** (**iterator** position)\
 **iterator** **erase** (**iterator** first, **iterator** last)\
 void **swap** (**deque**\< Type, Allocator \> &x)\
 void **clear** ()\
 **Base** & **M\_base** ()\
 const **Base** & **M\_base** () const\
 **allocator\_type** **get\_allocator** () const\
 *Get a copy of the memory allocation object.*  **size\_type** **size** () const\
 **size\_type** **max\_size** () const\
 void **resize** (**size\_type** new\_size, const **value\_type** &x)\
 *Resizes the deque to the specified number of elements.*  void **resize** (**size\_type** new\_size)\
 *Resizes the deque to the specified number of elements.*  bool **empty** () const\
 **reference** **at** (**size\_type** n)\
 *Provides access to the data contained in the deque.*  **const\_reference** **at** (**size\_type** n) const \
 *Provides access to the data contained in the deque.*  **iterator** **insert** (**iterator** position, const **value\_type** &x)\
 *Inserts given value into deque before specified iterator.*  void **insert** (**iterator** position, **size\_type** n, const **value\_type** &x)\
 *Inserts a number of copies of given data into the deque.*  void **insert** (**iterator** position, InputIterator first, InputIterator last)\
 *Inserts a range into the deque.*  **iterator** **erase** (**iterator** position)\
 *Remove element at given position.*  **iterator** **erase** (**iterator** first, **iterator** last)\
 *Remove a range of elements.*  void **swap** (**deque** &x)\
 *Swaps data with another deque.*  template\<typename Predicate\> void **M\_invalidate\_if** (Predicate pred)\
 template\<typename Iterator\> void **M\_transfer\_iter** (const Safe\_iterator\< Iterator, Sequence \> &x)\
 void **M\_invalidate\_all** () const\

### Public Attributes

Safe\_iterator\_base \* **M\_iterators**\
 *The list of mutable iterators that reference this container.*  Safe\_iterator\_base \* **M\_const\_iterators**\
 *The list of constant iterators that reference this container.*  unsigned int **M\_version**\
 *The container version number. This number may never be 0.*

### Protected Types

typedef **pointer** \* **Map\_pointer**\
 enum \
 typedef Allocator::template rebind\< Type \* \>::other **Map\_alloc\_type**\

### Protected Member Functions

void **M\_range\_check** (**size\_type** n) const \
 void **M\_initialize\_dispatch** (Integer n, Integer x, **\_\_true\_type**)\
 void **M\_initialize\_dispatch** (InputIterator first, InputIterator last, **\_\_false\_type**)\
 void **M\_assign\_dispatch** (Integer n, Integer \_\_val, **\_\_true\_type**)\
 void **M\_assign\_dispatch** (InputIterator first, InputIterator last, **\_\_false\_type**)\
 void **M\_assign\_aux** (ForwardIterator first, ForwardIterator last, forward\_iterator\_tag)\
 void **M\_fill\_assign** (**size\_type** n, const **value\_type** &\_\_val)\
 void **M\_insert\_dispatch** (**iterator** position, Integer n, Integer x, **\_\_true\_type**)\
 void **M\_insert\_dispatch** (**iterator** position, InputIterator first, InputIterator last, **\_\_false\_type**)\
 **iterator** **M\_reserve\_elements\_at\_front** (**size\_type** n)\
 **iterator** **M\_reserve\_elements\_at\_back** (**size\_type** n)\
 void **M\_reserve\_map\_at\_back** (**size\_type** nodes\_to\_add=1)\
 void **M\_reserve\_map\_at\_front** (**size\_type** nodes\_to\_add=1)\
 **Map\_alloc\_type** **M\_get\_map\_allocator** () const\
 Type \* **M\_allocate\_node** ()\
 void **M\_deallocate\_node** (Type \*\_\_p)\
 Type \*\* **M\_allocate\_map** (size\_t n)\
 void **M\_deallocate\_map** (Type \*\*\_\_p, size\_t n)\
 void **M\_detach\_all** ()\
 void **M\_detach\_singular** ()\
 void **M\_revalidate\_singular** ()\
 void **M\_swap** (Safe\_sequence\_base &x)\

### Static Protected Member Functions

static size\_t **S\_buffer\_size** ()\

### Protected Attributes

Deque\_impl **M\_impl**\

### Private Types

typedef **std::deque**\< Type, Allocator \> **Base**\
 typedef **\_\_gnu\_debug::Safe\_sequence**\< **deque** \> **Safe\_base**\

## Detailed Description

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> class \_\_gnu\_debug\_def::deque\< Type, Allocator \>

Definition at line 41 of file debug/deque.

## Constructor & Destructor Documentation

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> \_\_gnu\_debug\_def::deque\< Type, Allocator \>::~deque ()` [inline]`

The dtor only erases the elements, and note that if the elements themselves are pointers, the pointed-to memory is not touched in any way. Managing the pointer is the user's responsibilty.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 85 of file debug/deque.

## Member Function Documentation

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> template\<class InputIterator\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::assign (InputIterator first, InputIterator last)` [inline]`

Assigns a range to a deque.

**Parameters:**

*first* An input iterator. \
 *last* An input iterator.

This function fills a deque with copies of the elements in the range \[first,last).

Note that the assignment completely changes the deque and that the resulting deque's size is the same as the number of elements assigned. Old data may be lost.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 97 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::assign (size\_type n, const Type & \_\_t)` [inline]`

Assigns a given value to a deque.

**Parameters:**

*n* Number of elements to be assigned. \
 *val* Value to be assigned.

This function fills a deque with *n* copies of the given value. Note that the assignment completely changes the deque and that the resulting deque's size is the same as the number of elements assigned. Old data may be lost.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 105 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::begin ()` [inline]`

Returns a read/write iterator that points to the first element in the deque. Iteration is done in ordinary element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 115 of file debug/deque.

Referenced by \_\_gnu\_debug\_def::deque\< Type, Allocator \>::erase(), \_\_gnu\_debug\_def::deque\< Type, Allocator \>::pop\_front(), \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rend(), and \_\_gnu\_debug\_def::deque\< Type, Allocator \>::resize().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::begin () const` [inline]`

Returns a read-only (constant) iterator that points to the first element in the deque. Iteration is done in ordinary element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 119 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::end ()` [inline]`

Returns a read/write iterator that points one past the last element in the deque. Iteration is done in ordinary element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 123 of file debug/deque.

Referenced by \_\_gnu\_debug\_def::deque\< Type, Allocator \>::erase(), \_\_gnu\_debug\_def::deque\< Type, Allocator \>::pop\_back(), and \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rbegin().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::end () const` [inline]`

Returns a read-only (constant) iterator that points one past the last element in the deque. Iteration is done in ordinary element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 127 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> reverse\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rbegin ()` [inline]`

Returns a read/write reverse iterator that points to the last element in the deque. Iteration is done in reverse element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 131 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::end().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_reverse\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rbegin () const` [inline]`

Returns a read-only (constant) reverse iterator that points to the last element in the deque. Iteration is done in reverse element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 135 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::end().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> reverse\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rend ()` [inline]`

Returns a read/write reverse iterator that points to one before the first element in the deque. Iteration is done in reverse element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 139 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::begin().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_reverse\_iterator \_\_gnu\_debug\_def::deque\< Type, Allocator \>::rend () const` [inline]`

Returns a read-only (constant) reverse iterator that points to one before the first element in the deque. Iteration is done in reverse element order.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 143 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::begin().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::operator\[\] (size\_type n)` [inline]`

Subscript access to the data contained in the deque.

**Parameters:**

*n* The index of the element for which data should be accessed.

**Returns:**

Read/write reference to data.

This operator allows for easy, array-style, data access. Note that data access with this operator is unchecked and out\_of\_range lookups are not defined. (For checked lookups see **at()**.)

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 170 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::operator\[\] (size\_type n) const` [inline]`

Subscript access to the data contained in the deque.

**Parameters:**

*n* The index of the element for which data should be accessed.

**Returns:**

Read-only (constant) reference to data.

This operator allows for easy, array-style, data access. Note that data access with this operator is unchecked and out\_of\_range lookups are not defined. (For checked lookups see **at()**.)

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 177 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::front ()` [inline]`

Returns a read/write reference to the data at the first element of the deque.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 186 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::front () const` [inline]`

Returns a read-only (constant) reference to the data at the first element of the deque.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 193 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::back ()` [inline]`

Returns a read/write reference to the data at the last element of the deque.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 200 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> const\_reference \_\_gnu\_debug\_def::deque\< Type, Allocator \>::back () const` [inline]`

Returns a read-only (constant) reference to the data at the last element of the deque.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 207 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::push\_front (const Type & x)` [inline]`

Add data to the front of the deque.

**Parameters:**

*x* Data to be added.

This is a typical stack operation. The function creates an element at the front of the deque and assigns the given data to it. Due to the nature of a deque this operation can be done in constant time.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 215 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::push\_back (const Type & x)` [inline]`

Add data to the end of the deque.

**Parameters:**

*x* Data to be added.

This is a typical stack operation. The function creates an element at the end of the deque and assigns the given data to it. Due to the nature of a deque this operation can be done in constant time.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 222 of file debug/deque.

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::pop\_front ()` [inline]`

Removes first element.

This is a typical stack operation. It shrinks the deque by one.

Note that no data is returned, and if the first element's data is needed, it should be retrieved before **pop\_front()** is called.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 256 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::begin().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::pop\_back ()` [inline]`

Removes last element.

This is a typical stack operation. It shrinks the deque by one.

Note that no data is returned, and if the last element's data is needed, it should be retrieved before **pop\_back()** is called.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 265 of file debug/deque.

References \_\_gnu\_debug\_def::deque\< Type, Allocator \>::end().

### template\<typename Type, typename Allocator = std::allocator\<Type\>\> void \_\_gnu\_debug\_def::deque\< Type, Allocator \>::clear ()` [inline]`

Erases all the elements. Note that this function only erases the elements, and that if the elements themselves are pointers, the pointed-to memory is not touched in any way. Managing the pointer is the user's responsibilty.

Reimplemented from **std::deque\< Type, Allocator \>**.

Definition at line 333 of file debug/deque.

### allocator\_type std::deque\< Type , Allocator \>::get\_allocator () const` [inline, inherited]`

Get a copy of the memory allocation object.

Reimplemented from **std::Deque\_base\< Type, Allocator \>**.

Definition at line 751 of file stl\_deque.h.

### size\_type std::deque\< Type , Allocator \>::size () const` [inline, inherited]`

Returns the number of elements in the deque.

Definition at line 824 of file stl\_deque.h.

Referenced by \_\_gnu\_debug\_def::deque\< Type, Allocator \>::resize().

### size\_type std::deque\< Type , Allocator \>::max\_size (void) const` [inline, inherited]`

Returns the **size()** of the largest possible deque.

Definition at line 829 of file stl\_deque.h.

### void std::deque\< Type , Allocator \>::resize (size\_type new\_size, const value\_type & x)` [inline, inherited]`

Resizes the deque to the specified number of elements.

**Parameters:**

*new\_size* Number of elements the deque should contain. \
 *x* Data with which new elements should be populated.

This function will resize the deque to the specified number of elements. If the number is smaller than the deque's current size the deque is truncated, otherwise the deque is extended and new elements are populated with given data.

Definition at line 843 of file stl\_deque.h.

References std::deque\< Type, Alloc \>::erase(), std::deque\< Type, Alloc \>::insert(), and std::deque\< Type, Alloc \>::size().

### void std::deque\< Type , Allocator \>::resize (size\_type new\_size)` [inline, inherited]`

Resizes the deque to the specified number of elements.

**Parameters:**

*new\_size* Number of elements the deque should contain.

This function will resize the deque to the specified number of elements. If the number is smaller than the deque's current size the deque is truncated, otherwise the deque is extended and new elements are default-constructed.

Definition at line 862 of file stl\_deque.h.

References std::deque\< Type, Alloc \>::resize().

### bool std::deque\< Type , Allocator \>::empty () const` [inline, inherited]`

Returns true if the deque is empty. (Thus **begin()** would equal **end()**.)

Definition at line 869 of file stl\_deque.h.

### reference std::deque\< Type , Allocator \>::at (size\_type n)` [inline, inherited]`

Provides access to the data contained in the deque.

**Parameters:**

*n* The index of the element for which data should be accessed.

**Returns:**

Read/write reference to data.

**Exceptions:**

**std::out\_of\_range If** *n* **is an invalid index.**

**This function provides for safer data access. The parameter is first checked that it is in the range of the deque. The function throws out\_of\_range if the check fails.**

**Definition at line 920 of file stl\_deque.h.**

### const\_reference std::deque\< Type , Allocator \>::at (size\_type n) const` [inline, inherited]`

**Provides access to the data contained in the deque.**

**Parameters:**

*n* **The index of the element for which data should be accessed.**

**Returns:**

**Read-only (constant) reference to data.**

**Exceptions:**

**std::out\_of\_range If** *n* **is an invalid index.**

**This function provides for safer data access. The parameter is first checked that it is in the range of the deque. The function throws out\_of\_range if the check fails.**

**Definition at line 934 of file stl\_deque.h.**

### iterator std::deque\< Type , Allocator \>::insert (iterator position, const value\_type & x)` [inherited]`

**Inserts given value into deque before specified iterator.**

**Parameters:**

*position* **An iterator into the deque.** \
 *x* **Data to be inserted.**

**Returns:**

**An iterator that points to the inserted data.**

**This function will insert a copy of the given value before the specified location.**

### void std::deque\< Type , Allocator \>::insert (iterator position, size\_type n, const value\_type & x)` [inline, inherited]`

**Inserts a number of copies of given data into the deque.**

**Parameters:**

*position* **An iterator into the deque.** \
 *n* **Number of elements to be inserted.** \
 *x* **Data to be inserted.**

**This function will insert a specified number of copies of the given data before the location specified by** *position***.**

**Definition at line 1083 of file stl\_deque.h.**

### void std::deque\< Type , Allocator \>::insert (iterator position, InputIterator first, InputIterator last)` [inline, inherited]`

**Inserts a range into the deque.**

**Parameters:**

*position* **An iterator into the deque.** \
 *first* **An input iterator.** \
 *last* **An input iterator.**

**This function will insert copies of the data in the range \[first,last) into the deque before the location specified by** *pos***. This is known as 'range insert.'**

**Definition at line 1098 of file stl\_deque.h.**

### iterator std::deque\< Type , Allocator \>::erase (iterator position)` [inherited]`

**Remove element at given position.**

**Parameters:**

*position* **Iterator pointing to element to be erased.**

**Returns:**

**An iterator pointing to the next element (or end()).**

**This function will erase the element at the given position and thus shorten the deque by one.**

**The user is cautioned that this function only erases the element, and that if the element is itself a pointer, the pointed-to memory is not touched in any way. Managing the pointer is the user's responsibilty.**

### iterator std::deque\< Type , Allocator \>::erase (iterator first, iterator last)` [inherited]`

**Remove a range of elements.**

**Parameters:**

*first* **Iterator pointing to the first element to be erased.** \
 *last* **Iterator pointing to one past the last element to be erased.**

**Returns:**

**An iterator pointing to the element pointed to by** *last* **prior to erasing (or end()).**

**This function will erase the elements in the range \[first,last) and shorten the deque accordingly.**

**The user is cautioned that this function only erases the elements, and that if the elements themselves are pointers, the pointed-to memory is not touched in any way. Managing the pointer is the user's responsibilty.**

### void std::deque\< Type , Allocator \>::swap (deque\< Type, Allocator \> & x)` [inline, inherited]`

**Swaps data with another deque.**

**Parameters:**

*x* **A deque of the same element and allocator types.**

**This exchanges the elements between two deques in constant time. (Four pointers, so it should be quite fast.) Note that the global std::swap() function is specialized such that std::swap(d1,d2) will feed to this function.**

**Definition at line 1151 of file stl\_deque.h.**

**References std::swap().**

### template\<typename Sequence\> template\<typename Predicate\> void \_\_gnu\_debug::Safe\_sequence\< Sequence \>::M\_invalidate\_if (Predicate pred)` [inherited]`

**Invalidates all iterators** `x` **that reference this sequence, are not singular, and for which** `pred(x)` **returns** `true`**. The user of this routine should be careful not to make copies of the iterators passed to** `pred`**, as the copies may interfere with the invalidation.**

**Definition at line 120 of file safe\_sequence.h.**

### template\<typename Sequence\> template\<typename Iterator\> void \_\_gnu\_debug::Safe\_sequence\< Sequence \>::M\_transfer\_iter (const Safe\_iterator\< Iterator, Sequence \> & x)` [inherited]`

**Transfers all iterators that reference this memory location to this sequence from whatever sequence they are attached to.**

**Definition at line 152 of file safe\_sequence.h.**

### void \_\_gnu\_debug::Safe\_sequence\_base::M\_detach\_all ()` [protected, inherited]`

**Detach all iterators, leaving them singular.**

**Definition at line 114 of file debug.cc.**

### void \_\_gnu\_debug::Safe\_sequence\_base::M\_detach\_singular ()` [protected, inherited]`

**Detach all singular iterators.**

**Postcondition:**

**for all iterators i attached to this sequence, i-\>M\_version == M\_version.**

**Definition at line 133 of file debug.cc.**

### void \_\_gnu\_debug::Safe\_sequence\_base::M\_revalidate\_singular ()` [protected, inherited]`

**Revalidates all attached singular iterators. This method may be used to validate iterators that were invalidated before (but for some reasion, such as an exception, need to become valid again).**

**Definition at line 154 of file debug.cc.**

### void \_\_gnu\_debug::Safe\_sequence\_base::M\_swap (Safe\_sequence\_base & x)` [protected, inherited]`

**Swap this sequence with the given sequence. This operation also swaps ownership of the iterators, so that when the operation is complete all iterators that originally referenced one container now reference the other container.**

**Definition at line 172 of file debug.cc.**

**References \_\_gnu\_debug::swap().**

### void \_\_gnu\_debug::Safe\_sequence\_base::M\_invalidate\_all () const` [inline, inherited]`

**Invalidates all iterators.**

**Definition at line 202 of file safe\_base.h.**

## Member Data Documentation

### Safe\_iterator\_base\* \_\_gnu\_debug::Safe\_sequence\_base::M\_iterators` [inherited]`

**The list of mutable iterators that reference this container.**

**Definition at line 153 of file safe\_base.h.**

### Safe\_iterator\_base\* \_\_gnu\_debug::Safe\_sequence\_base::M\_const\_iterators` [inherited]`

**The list of constant iterators that reference this container.**

**Definition at line 156 of file safe\_base.h.**

### unsigned int \_\_gnu\_debug::Safe\_sequence\_base::M\_version` [mutable, inherited]`

**The container version number. This number may never be 0.**

**Definition at line 159 of file safe\_base.h.**

## Author

**Generated automatically by Doxygen for libstdc++-v3 Source from the source code.**
