Home | History | Annotate | Download | only in bits

Lines Matching refs:list

0 // List implementation -*- C++ -*-
70 /// Common part of a node in the %list.
93 /// An actual node in the %list.
108 * @brief A list::iterator.
178 // The only member points to the %list element.
183 * @brief A list::const_iterator.
258 // The only member points to the %list element.
358 // This is what actually destroys the list.
385 * This is a @e doubly @e linked %list. Traversal up and down the
386 * %list requires linear time, but adding and removing elements (or
393 * Also unlike the other standard containers, std::list provides
397 * A couple points on memory allocation for list<Tp>:
401 * that after elements from %list<X,Alloc1> are spliced into
402 * %list<X,Alloc2>, destroying the memory of the second %list is a
405 * Second, a %list conceptually represented as
409 * is actually circular; a link exists between A and D. The %list
410 * class holds (as its only data member) a private list::iterator
411 * pointing to @e D, not to @e A! To get to the head of the %list,
413 * iterator's next/previous pointers refer to itself, the %list is
417 class list : protected _List_base<_Tp, _Alloc>
499 list()
503 * @brief Creates a %list with no elements.
507 list(const allocator_type& __a)
511 * @brief Creates a %list with copies of an exemplar element.
516 * This constructor fills the %list with @a n copies of @a value.
519 list(size_type __n, const value_type& __value = value_type(),
525 * @brief %List copy constructor.
526 * @param x A %list of identical element and allocator types.
528 * The newly-created %list uses a copy of the allocation object used
531 list(const list& __x)
537 * @brief %List move constructor.
538 * @param x A %list of identical element and allocator types.
540 * The newly-created %list contains the exact contents of @a x.
541 * The contents of @a x are a valid, but unspecified %list.
543 list(list&& __x)
547 list from an initializer_list
551 * Create a %list consisting of copies of the elements in the
554 list(initializer_list<value_type> __l,
561 * @brief Builds a %list from a range.
566 * Create a %list consisting of copies of the elements from
571 list(_InputIterator __first, _InputIterator __last,
589 * @brief %List assignment operator.
590 * @param x A %list of identical element and allocator types.
595 list&
596 operator=(const list& __x);
600 * @brief %List move assignment operator.
601 * @param x A %list of identical element and allocator types.
603 * The contents of @a x are moved into this %list (without copying).
604 * @a x is a valid, but unspecified %list
606 list&
607 operator=(list&& __x)
616 * @brief %List initializer list assignment operator.
619 * Replace the contents of the %list with copies of the elements
622 list&
631 * @brief Assigns a given value to a %list.
635 * This function fills a %list with @a n copies of the given
636 * value. Note that the assignment completely changes the %list
637 * and that the resulting %list's size is the same as the number
645 * @brief Assigns a range to a %list.
649 * This function fills a %list with copies of the elements in the
652 * Note that the assignment completely changes the %list and
653 * that the resulting %list's size is the same as the number of
667 * @brief Assigns an initializer_list to a %list.
670 * Replace the contents of the %list with copies of the elements
686 * %list. Iteration is done in ordinary element order.
694 * first element in the %list. Iteration is done in ordinary
703 * element in the %list. Iteration is done in ordinary element
712 * the last element in the %list. Iteration is done in ordinary
721 * element in the %list. Iteration is done in reverse element
730 * the last element in the %list. Iteration is done in reverse
739 * before the first element in the %list. Iteration is done in
748 * before the first element in the %list. Iteration is done in reverse
758 * first element in the %list. Iteration is done in ordinary
767 * the last element in the %list. Iteration is done in ordinary
776 * the last element in the %list. Iteration is done in reverse
785 * before the first element in the %list. Iteration is done in reverse
795 * Returns true if the %list is empty. (Thus begin() would equal
802 /** Returns the number of elements in the %list. */
807 /** Returns the size() of the largest possible %list. */
813 * @brief Resizes the %list to the specified number of elements.
814 * @param new_size Number of elements the %list should contain.
817 * This function will %resize the %list to the specified number
818 * of elements. If the number is smaller than the %list's
819 * current size the %list is truncated, otherwise the %list is
828 * element of the %list.
836 * element of the %list.
844 * of the %list.
856 * element of the %list.
868 * @brief Add data to the front of the %list.
872 * element at the front of the %list and assigns the given data
873 * to it. Due to the nature of a %list this operation can be
895 * This is a typical stack operation. It shrinks the %list by
896 * one. Due to the nature of a %list this operation can be done
909 * @brief Add data to the end of the %list.
913 * element at the end of the %list and assigns the given data to
914 * it. Due to the nature of a %list this operation can be done
936 * This is a typical stack operation. It shrinks the %list by
937 * one. Due to the nature of a %list this operation can be done
950 * @brief Constructs object in %list before specified iterator.
951 * @param position A const_iterator into the %list.
957 * location. Due to the nature of a %list this operation can
967 * @brief Inserts given value into %list before specified iterator.
968 * @param position An iterator into the %list.
973 * the specified location. Due to the nature of a %list this
982 * @brief Inserts given rvalue into %list before specified iterator.
983 * @param position An iterator into the %list.
988 * the specified location. Due to the nature of a %list this
997 * @brief Inserts the contents of an initializer_list into %list
999 * @param p An iterator into the %list.
1003 * initializer_list @a l into the %list before the location
1015 * @brief Inserts a number of copies of given data into the %list.
1016 * @param position An iterator into the %list.
1029 list __tmp(__n, __x, _M_get_Node_allocator());
1034 * @brief Inserts a range into the %list.
1035 list.
1040 * first,@a last) into the %list before the location specified by
1051 list __tmp(__first, __last, _M_get_Node_allocator());
1061 * shorten the %list by one.
1063 * Due to the nature of a %list this operation can be done in
1082 * [first,last) and shorten the %list accordingly.
1100 * @brief Swaps data with another %list.
1101 * @param x A %list of the same element and allocator types.
1110 swap(list&& __x)
1112 swap(list& __x)
1136 // [23.2.2.4] list operations
1138 * @brief Insert contents of another %list.
1140 * @param x Source list.
1144 * list.
1150 splice(iterator __position, list&& __x)
1152 splice(iterator __position, list& __x)
1164 * @brief Insert element from another %list.
1166 * @param x Source list.
1169 * Removes the element in list @a x referenced by @a i and
1170 * inserts it into the current list before @a position.
1174 splice(iterator __position, list&& __x, iterator __i)
1176 splice(iterator __position, list& __x, iterator __i)
1191 * @brief Insert range from another %list.
1193 * @param x Source list.
1204 splice(iterator __position, list&& __x, iterator __first,
1207 splice(iterator __position, list& __x, iterator __first,
1224 * Removes every element in the list equal to @a value.
1225 * Remaining elements stay in list order. Note that this
1238 * Removes every element in the list for which the predicate
1239 * returns true. Remaining elements stay in list order. Note
1254 * list order. Note that this function only erases the
1269 * elements stay in list order. Note that this function only
1280 * @param x Sorted list to merge.
1282 * Assumes that both @a x and this list are sorted according to
1283 * operator<(). Merges elements of @a x into this list in
1285 * this list precede elements in @a x that are equal.
1289 merge(list&& __x);
1291 merge(list& __x);
1296 * @param x Sorted list to merge.
1300 * Assumes that both @a x and this list are sorted according to
1301 * StrictWeakOrdering. Merges elements of @a x into this list
1303 * in this list precede elements in @a x that are equivalent
1309 merge(list&&, _StrictWeakOrdering);
1311 merge(list&, _StrictWeakOrdering);
1315 * @brief Reverse the elements in list.
1317 * Reverse the order of elements in the list in linear time.
1326 * Sorts the elements of this list in NlogN time. Equivalent
1327 * elements remain in list order.
1335 * Sorts the elements of this list in NlogN time. Equivalent
1336 * elements remain in list order.
1364 // Called by list(n,v,a), and the range constructor when it turns out
1436 _M_check_equal_allocators(list& __x)
1440 __throw_runtime_error(__N("list::_M_check_equal_allocators"));
1445 * @brief List equality comparison.
1446 * @param x A %list.
1447 * @param y A %list of the same type as @a x.
1456 operator==(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1458 typedef typename list<_Tp, _Alloc>::const_iterator const_iterator;
1473 * @brief List ordering relation.
1474 * @param x A %list.
1475 * @param y A %list of the same type as @a x.
1485 operator<(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1492 operator!=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1498 operator>(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1504 operator<=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1510 operator>=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y)
1513 /// See std::list::swap().
1516 swap(list<_Tp, _Alloc>& __x, list<_Tp, _Alloc>& __y)
1522 swap(list<_Tp, _Alloc>&& __x, list<_Tp, _Alloc>& __y)
1527 swap(list<_Tp, _Alloc>& __x, list<_Tp, _Alloc>&& __y)