11#ifndef INCLUDED_BSLALG_ARRAYPRIMITIVES_CPP03
12#define INCLUDED_BSLALG_ARRAYPRIMITIVES_CPP03
63#ifdef COMPILING_BSLALG_ARRAYPRIMITIVES_H
65#if defined(BSLS_PLATFORM_CMP_IBM)
66# define BSLALG_ARRAYPRIMITIVES_CANNOT_REMOVE_POINTER_FROM_FUNCTION_POINTER 1
69# define BSLALG_ARRAYPRIMITIVES_NON_ZERO_NULL_VALUE_FOR_MEMBER_POINTERS 1
77struct ArrayPrimitives_Imp;
88struct ArrayPrimitives {
92 typedef ArrayPrimitives_Imp
Imp;
107 template <
class ALLOCATOR,
class FWD_ITER>
113 ALLOCATOR allocator);
114 template <
class ALLOCATOR,
class SOURCE_TYPE>
118 SOURCE_TYPE *fromBegin,
119 SOURCE_TYPE *fromEnd,
120 ALLOCATOR allocator);
133 template <
class TARGET_TYPE,
class FWD_ITER>
138 template <
class TARGET_TYPE,
class SOURCE_TYPE>
140 SOURCE_TYPE *fromBegin,
141 SOURCE_TYPE *fromEnd,
154 template <
class ALLOCATOR>
160 ALLOCATOR allocator);
172 template <
class TARGET_TYPE>
174 TARGET_TYPE *fromBegin,
175 TARGET_TYPE *fromEnd,
186 template <
class ALLOCATOR>
190 ALLOCATOR allocator);
203 template <
class TARGET_TYPE>
224 template <
class ALLOCATOR>
229 ALLOCATOR allocator);
243 template <
class TARGET_TYPE>
245 TARGET_TYPE *fromBegin,
246 TARGET_TYPE *fromEnd,
249#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
252#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
253#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
255#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A
256#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
259#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 0
260 template <
class ALLOCATOR>
267 ALLOCATOR allocator);
270#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 1
271 template <
class ALLOCATOR,
class ARGS_01>
282#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 2
283 template <
class ALLOCATOR,
class ARGS_01,
296#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 3
297 template <
class ALLOCATOR,
class ARGS_01,
312#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 4
313 template <
class ALLOCATOR,
class ARGS_01,
330#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 5
331 template <
class ALLOCATOR,
class ARGS_01,
350#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 6
351 template <
class ALLOCATOR,
class ARGS_01,
372#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 7
373 template <
class ALLOCATOR,
class ARGS_01,
396#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 8
397 template <
class ALLOCATOR,
class ARGS_01,
422#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 9
423 template <
class ALLOCATOR,
class ARGS_01,
450#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_A >= 10
451 template <
class ALLOCATOR,
class ARGS_01,
484 template <
class ALLOCATOR,
class... ARGS>
519 template <
class ALLOCATOR>
527 ALLOCATOR allocator);
551 template <
class TARGET_TYPE>
553 TARGET_TYPE **fromEndPtr,
554 TARGET_TYPE *fromBegin,
555 TARGET_TYPE *position,
556 TARGET_TYPE *fromEnd,
580 template <
class ALLOCATOR>
589 ALLOCATOR allocator);
607 template <
class TARGET_TYPE>
609 TARGET_TYPE **fromEndPtr,
610 TARGET_TYPE *fromBegin,
611 TARGET_TYPE *position,
612 TARGET_TYPE *fromEnd,
613 const TARGET_TYPE& value,
642 template <
class ALLOCATOR,
class FWD_ITER>
652 ALLOCATOR allocator);
673 template <
class TARGET_TYPE,
class FWD_ITER>
675 TARGET_TYPE **fromEndPtr,
676 TARGET_TYPE *fromBegin,
677 TARGET_TYPE *position,
678 TARGET_TYPE *fromEnd,
703 template <
class ALLOCATOR>
714 ALLOCATOR allocator);
737 template <
class TARGET_TYPE>
739 TARGET_TYPE **fromEndPtr,
740 TARGET_TYPE **lastPtr,
741 TARGET_TYPE *fromBegin,
742 TARGET_TYPE *position,
743 TARGET_TYPE *fromEnd,
749#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
752#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
753#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
755#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B
756#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
759#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 0
760 template <
class ALLOCATOR>
764 ALLOCATOR allocator);
767#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 1
768 template <
class ALLOCATOR,
class ARGS_01>
776#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 2
777 template <
class ALLOCATOR,
class ARGS_01,
787#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 3
788 template <
class ALLOCATOR,
class ARGS_01,
800#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 4
801 template <
class ALLOCATOR,
class ARGS_01,
815#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 5
816 template <
class ALLOCATOR,
class ARGS_01,
832#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 6
833 template <
class ALLOCATOR,
class ARGS_01,
851#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 7
852 template <
class ALLOCATOR,
class ARGS_01,
872#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 8
873 template <
class ALLOCATOR,
class ARGS_01,
895#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 9
896 template <
class ALLOCATOR,
class ARGS_01,
920#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 10
921 template <
class ALLOCATOR,
class ARGS_01,
948#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 0
949 template <
class TARGET_TYPE>
950 static void emplace(TARGET_TYPE *toBegin,
955#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 1
956 template <
class TARGET_TYPE,
class ARGS_01>
957 static void emplace(TARGET_TYPE *toBegin,
963#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 2
964 template <
class TARGET_TYPE,
class ARGS_01,
966 static void emplace(TARGET_TYPE *toBegin,
973#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 3
974 template <
class TARGET_TYPE,
class ARGS_01,
977 static void emplace(TARGET_TYPE *toBegin,
985#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 4
986 template <
class TARGET_TYPE,
class ARGS_01,
990 static void emplace(TARGET_TYPE *toBegin,
999#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 5
1000 template <
class TARGET_TYPE,
class ARGS_01,
1005 static void emplace(TARGET_TYPE *toBegin,
1015#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 6
1016 template <
class TARGET_TYPE,
class ARGS_01,
1022 static void emplace(TARGET_TYPE *toBegin,
1033#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 7
1034 template <
class TARGET_TYPE,
class ARGS_01,
1041 static void emplace(TARGET_TYPE *toBegin,
1053#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 8
1054 template <
class TARGET_TYPE,
class ARGS_01,
1062 static void emplace(TARGET_TYPE *toBegin,
1075#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 9
1076 template <
class TARGET_TYPE,
class ARGS_01,
1085 static void emplace(TARGET_TYPE *toBegin,
1099#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_B >= 10
1100 template <
class TARGET_TYPE,
class ARGS_01,
1110 static void emplace(TARGET_TYPE *toBegin,
1129 template <
class ALLOCATOR,
class... ARGS>
1133 ALLOCATOR allocator,
1136 template <
class TARGET_TYPE,
class... ARGS>
1137 static void emplace(TARGET_TYPE *toBegin,
1145#if defined(BSLS_PLATFORM_CMP_MSVC) && BSLS_PLATFORM_CMP_VERSION < 1900
1146 template <
class CLASS_TYPE,
class MEMBER_TYPE,
class... ARGS>
1147 static void emplace(MEMBER_TYPE CLASS_TYPE::* *toBegin,
1148 MEMBER_TYPE CLASS_TYPE::* *toEnd,
1149 bslma::Allocator *allocator)
1153 emplace(toBegin, toEnd, allocator,
nullptr);
1168 template <
class ALLOCATOR>
1173 ALLOCATOR allocator);
1184 template <
class TARGET_TYPE>
1185 static void erase(TARGET_TYPE *first,
1186 TARGET_TYPE *middle,
1200 template <
class ALLOCATOR>
1206 ALLOCATOR allocator);
1218 template <
class TARGET_TYPE>
1219 static void insert(TARGET_TYPE *toBegin,
1234 template <
class ALLOCATOR>
1241 ALLOCATOR allocator);
1254 template <
class TARGET_TYPE>
1255 static void insert(TARGET_TYPE *toBegin,
1257 const TARGET_TYPE& value,
1277 template <
class ALLOCATOR,
class FWD_ITER>
1284 ALLOCATOR allocator);
1285 template <
class ALLOCATOR,
class SOURCE_TYPE>
1289 SOURCE_TYPE *fromBegin,
1290 SOURCE_TYPE *fromEnd,
1292 ALLOCATOR allocator);
1310 template <
class TARGET_TYPE,
class FWD_ITER>
1311 static void insert(TARGET_TYPE *toBegin,
1317 template <
class TARGET_TYPE,
class SOURCE_TYPE>
1318 static void insert(TARGET_TYPE *toBegin,
1320 SOURCE_TYPE *fromBegin,
1321 SOURCE_TYPE *fromEnd,
1345 template <
class ALLOCATOR>
1353 ALLOCATOR allocator);
1374 template <
class TARGET_TYPE>
1377 TARGET_TYPE **fromEndPtr,
1378 TARGET_TYPE *fromBegin,
1379 TARGET_TYPE *fromEnd,
1393 template <
class TARGET_TYPE>
1394 static void rotate(TARGET_TYPE *first,
1395 TARGET_TYPE *middle,
1408 template <
class ALLOCATOR>
1413 ALLOCATOR allocator);
1428 template <
class TARGET_TYPE>
1431 const TARGET_TYPE& value,
1445struct ArrayPrimitives_Imp {
1455 template <
class TARGET_TYPE>
1456 static void assign(TARGET_TYPE *srcStart,
1457 TARGET_TYPE *srcEnd,
1458 TARGET_TYPE& value);
1469 template <
class TARGET_TYPE>
1470 static void reverseAssign(TARGET_TYPE *dest,
1471 TARGET_TYPE *srcStart,
1472 TARGET_TYPE *srcEnd);
1529 unsigned char *begin,
1530 unsigned char value,
1557 unsigned short *begin,
1558 unsigned short value,
1571 unsigned int *begin,
1585 unsigned long *begin,
1586 unsigned long value,
1641 volatile void **begin,
1642 volatile void *value,
1655 const volatile void **begin,
1656 const volatile void *value,
1661 template <
class TARGET_TYPE>
1663 TARGET_TYPE **begin,
1669 template <
class TARGET_TYPE>
1671 const TARGET_TYPE **begin,
1672 const TARGET_TYPE *value,
1677 template <
class TARGET_TYPE>
1679 volatile TARGET_TYPE **begin,
1680 volatile TARGET_TYPE *value,
1685 template <
class TARGET_TYPE>
1687 const volatile TARGET_TYPE **begin,
1688 const volatile TARGET_TYPE *value,
1693 template <
class TARGET_TYPE,
class ALLOCATOR>
1696 const TARGET_TYPE& value,
1698 ALLOCATOR *allocator,
1700 template <
class TARGET_TYPE,
class ALLOCATOR>
1703 const TARGET_TYPE& value,
1705 ALLOCATOR *allocator,
1718 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
1720 TARGET_TYPE *toBegin,
1723 ALLOCATOR allocator,
1725 template <
class TARGET_TYPE,
class ALLOCATOR>
1727 TARGET_TYPE *toBegin,
1728 const TARGET_TYPE *fromBegin,
1729 const TARGET_TYPE *fromEnd,
1730 ALLOCATOR allocator,
1732 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
1734 TARGET_TYPE *toBegin,
1737 ALLOCATOR allocator,
1739 template <
class FWD_ITER,
class ALLOCATOR>
1744 ALLOCATOR allocator,
1746 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
1748 TARGET_TYPE *toBegin,
1751 ALLOCATOR allocator,
1766 template <
class TARGET_TYPE,
class ALLOCATOR>
1768 TARGET_TYPE *toBegin,
1769 TARGET_TYPE *fromBegin,
1770 TARGET_TYPE *fromEnd,
1771 ALLOCATOR allocator,
1773 template <
class TARGET_TYPE,
class ALLOCATOR>
1775 TARGET_TYPE *toBegin,
1776 TARGET_TYPE *fromBegin,
1777 TARGET_TYPE *fromEnd,
1778 ALLOCATOR allocator,
1796 template <
class TARGET_TYPE,
class ALLOCATOR>
1798 TARGET_TYPE *toBegin,
1799 TARGET_TYPE *fromBegin,
1800 TARGET_TYPE *fromEnd,
1801 ALLOCATOR allocator,
1811 template <
class TARGET_TYPE,
class ALLOCATOR>
1815 ALLOCATOR allocator,
1817 template <
class TARGET_TYPE,
class ALLOCATOR>
1821 ALLOCATOR allocator,
1823 template <
class TARGET_TYPE,
class ALLOCATOR>
1827 ALLOCATOR allocator,
1836 template <
class TARGET_TYPE,
class ALLOCATOR>
1838 TARGET_TYPE *toBegin,
1839 TARGET_TYPE *fromBegin,
1840 TARGET_TYPE *fromEnd,
1841 ALLOCATOR allocator,
1843 template <
class TARGET_TYPE,
class ALLOCATOR>
1845 TARGET_TYPE *toBegin,
1846 TARGET_TYPE *fromBegin,
1847 TARGET_TYPE *fromEnd,
1848 ALLOCATOR allocator,
1851#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
1854#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
1855#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
1857#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C
1858#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
1860#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 0
1861 template <
class TARGET_TYPE,
class ALLOCATOR>
1863 TARGET_TYPE *toBegin,
1865 ALLOCATOR allocator,
1869#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 1
1870 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
1872 TARGET_TYPE *toBegin,
1874 ALLOCATOR allocator,
1879#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 2
1880 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1883 TARGET_TYPE *toBegin,
1885 ALLOCATOR allocator,
1891#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 3
1892 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1896 TARGET_TYPE *toBegin,
1898 ALLOCATOR allocator,
1905#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 4
1906 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1911 TARGET_TYPE *toBegin,
1913 ALLOCATOR allocator,
1921#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 5
1922 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1928 TARGET_TYPE *toBegin,
1930 ALLOCATOR allocator,
1939#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 6
1940 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1947 TARGET_TYPE *toBegin,
1949 ALLOCATOR allocator,
1959#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 7
1960 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1968 TARGET_TYPE *toBegin,
1970 ALLOCATOR allocator,
1981#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 8
1982 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
1991 TARGET_TYPE *toBegin,
1993 ALLOCATOR allocator,
2005#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 9
2006 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2016 TARGET_TYPE *toBegin,
2018 ALLOCATOR allocator,
2031#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 10
2032 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2043 TARGET_TYPE *toBegin,
2045 ALLOCATOR allocator,
2059#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 0
2060 template <
class TARGET_TYPE,
class ALLOCATOR>
2062 TARGET_TYPE *toBegin,
2064 ALLOCATOR allocator,
2068#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 1
2069 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
2071 TARGET_TYPE *toBegin,
2073 ALLOCATOR allocator,
2078#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 2
2079 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2082 TARGET_TYPE *toBegin,
2084 ALLOCATOR allocator,
2090#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 3
2091 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2095 TARGET_TYPE *toBegin,
2097 ALLOCATOR allocator,
2104#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 4
2105 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2110 TARGET_TYPE *toBegin,
2112 ALLOCATOR allocator,
2120#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 5
2121 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2127 TARGET_TYPE *toBegin,
2129 ALLOCATOR allocator,
2138#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 6
2139 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2146 TARGET_TYPE *toBegin,
2148 ALLOCATOR allocator,
2158#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 7
2159 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2167 TARGET_TYPE *toBegin,
2169 ALLOCATOR allocator,
2180#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 8
2181 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2190 TARGET_TYPE *toBegin,
2192 ALLOCATOR allocator,
2204#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 9
2205 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2215 TARGET_TYPE *toBegin,
2217 ALLOCATOR allocator,
2230#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 10
2231 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2242 TARGET_TYPE *toBegin,
2244 ALLOCATOR allocator,
2258#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 0
2259 template <
class TARGET_TYPE,
class ALLOCATOR>
2261 TARGET_TYPE *toBegin,
2263 ALLOCATOR allocator,
2267#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 1
2268 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
2270 TARGET_TYPE *toBegin,
2272 ALLOCATOR allocator,
2277#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 2
2278 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2281 TARGET_TYPE *toBegin,
2283 ALLOCATOR allocator,
2289#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 3
2290 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2294 TARGET_TYPE *toBegin,
2296 ALLOCATOR allocator,
2303#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 4
2304 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2309 TARGET_TYPE *toBegin,
2311 ALLOCATOR allocator,
2319#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 5
2320 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2326 TARGET_TYPE *toBegin,
2328 ALLOCATOR allocator,
2337#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 6
2338 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2345 TARGET_TYPE *toBegin,
2347 ALLOCATOR allocator,
2357#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 7
2358 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2366 TARGET_TYPE *toBegin,
2368 ALLOCATOR allocator,
2379#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 8
2380 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2389 TARGET_TYPE *toBegin,
2391 ALLOCATOR allocator,
2403#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 9
2404 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2414 TARGET_TYPE *toBegin,
2416 ALLOCATOR allocator,
2429#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_C >= 10
2430 template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
2441 TARGET_TYPE *toBegin,
2443 ALLOCATOR allocator,
2460 template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
2462 TARGET_TYPE *toBegin,
2464 ALLOCATOR allocator,
2467 template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
2469 TARGET_TYPE *toBegin,
2471 ALLOCATOR allocator,
2474 template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
2476 TARGET_TYPE *toBegin,
2478 ALLOCATOR allocator,
2490 template <
class TARGET_TYPE,
class ALLOCATOR>
2493 TARGET_TYPE *middle,
2495 ALLOCATOR allocator,
2497 template <
class TARGET_TYPE,
class ALLOCATOR>
2500 TARGET_TYPE *middle,
2502 ALLOCATOR allocator,
2512 template <
class TARGET_TYPE,
class ALLOCATOR>
2514 TARGET_TYPE *toBegin,
2516 const TARGET_TYPE& value,
2518 ALLOCATOR allocator,
2520 template <
class TARGET_TYPE,
class ALLOCATOR>
2522 TARGET_TYPE *toBegin,
2524 const TARGET_TYPE& value,
2526 ALLOCATOR allocator,
2528 template <
class TARGET_TYPE,
class ALLOCATOR>
2530 TARGET_TYPE *toBegin,
2532 const TARGET_TYPE& value,
2534 ALLOCATOR allocator,
2545 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
2547 TARGET_TYPE *toBegin,
2552 ALLOCATOR allocator,
2554 template <
class TARGET_TYPE,
class ALLOCATOR>
2556 TARGET_TYPE *toBegin,
2558 const TARGET_TYPE *fromBegin,
2559 const TARGET_TYPE *fromEnd,
2561 ALLOCATOR allocator,
2563 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
2565 TARGET_TYPE *toBegin,
2570 ALLOCATOR allocator,
2572 template <
class FWD_ITER,
class ALLOCATOR>
2579 ALLOCATOR allocator,
2581 template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
2583 TARGET_TYPE *toBegin,
2588 ALLOCATOR allocator,
2594 template <
class TARGET_TYPE,
class ALLOCATOR>
2596 TARGET_TYPE *toBegin,
2598 TARGET_TYPE **lastPtr,
2602 ALLOCATOR allocator,
2604 template <
class TARGET_TYPE,
class ALLOCATOR>
2606 TARGET_TYPE *toBegin,
2608 TARGET_TYPE **lastPtr,
2612 ALLOCATOR allocator,
2621 template <
class TARGET_TYPE>
2624 TARGET_TYPE *middle,
2627 template <
class TARGET_TYPE>
2630 TARGET_TYPE *middle,
2639 template <
class ALLOCATOR>
2645 ALLOCATOR allocator,
2647 template <
class ALLOCATOR>
2653 ALLOCATOR allocator,
2655 template <
class ALLOCATOR>
2661 ALLOCATOR allocator,
2668 static void bitwiseRotate(
char *begin,
char *middle,
char *end);
2707 template <
class FORWARD_ITERATOR>
2708 static bool isInvalidRange(FORWARD_ITERATOR begin, FORWARD_ITERATOR end);
2709 template <
class TARGET_TYPE>
2710 static bool isInvalidRange(TARGET_TYPE *begin, TARGET_TYPE *end);
2724template <
class FROM_TYPE,
class TO_TYPE>
2725struct ArrayPrimitives_CanBitwiseCopy
2728 typename bsl::remove_const<FROM_TYPE>::type,
2729 typename bsl::remove_const<TO_TYPE >::type>
2731 && bslmf::IsBitwiseCopyable<
2732 typename bsl::remove_const<TO_TYPE >::type>
2741template <
class ALLOCATOR>
2745 size_type numElements,
2747 ALLOCATOR allocator)
2765 k_IS_FUNDAMENTAL_OR_POINTER = k_IS_FUNDAMENTAL ||
2766 (k_IS_POINTER && !k_IS_FUNCTION_POINTER),
2772 : k_IS_BITWISECOPYABLE ?
Imp::e_BITWISE_COPYABLE_TRAITS
2783template <
class TARGET_TYPE>
2787 const TARGET_TYPE& value,
2790 uninitializedFillN<bsl::allocator<TARGET_TYPE> >(
begin,
2796template <
class ALLOCATOR,
class FWD_ITER>
2801 ALLOCATOR allocator)
2822 typedef typename FWD_ITER::value_type FwdTarget;
2833 k_VALUE = k_ITER_TO_FUNC_PTRS && k_TARGET_IS_VOID_PTR
2845template <
class TARGET_TYPE,
class FWD_ITER>
2852 copyConstruct<bsl::allocator<TARGET_TYPE> >(toBegin,
2858template <
class ALLOCATOR,
class SOURCE_TYPE>
2862 SOURCE_TYPE *fromBegin,
2863 SOURCE_TYPE *fromEnd,
2864 ALLOCATOR allocator)
2873 k_IS_BITWISECOPYABLE =
2887template <
class TARGET_TYPE,
class SOURCE_TYPE>
2890 SOURCE_TYPE *fromBegin,
2891 SOURCE_TYPE *fromEnd,
2894 copyConstruct<bsl::allocator<TARGET_TYPE> >(toBegin,
2900template <
class ALLOCATOR>
2905 ALLOCATOR allocator)
2916#if !defined(BSLALG_ARRAYPRIMITIVES_NON_ZERO_NULL_VALUE_FOR_MEMBER_POINTERS)
2932template <
class TARGET_TYPE>
2938 defaultConstruct<bsl::allocator<TARGET_TYPE> >(
begin,
2943template <
class ALLOCATOR>
2949 ALLOCATOR allocator)
2969template <
class TARGET_TYPE>
2972 TARGET_TYPE *fromBegin,
2973 TARGET_TYPE *fromEnd,
2976 destructiveMove<bsl::allocator<TARGET_TYPE> >(toBegin,
2982#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
2985#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
2986#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
2988#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D
2989#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
2991#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 0
2992template <
class ALLOCATOR>
2999 ALLOCATOR allocator)
3004 *fromEndPtr = fromEnd;
3007 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3013 TargetType *toPositionEnd = toPositionBegin + 1;
3015 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3025 *fromEndPtr = position;
3026 guard.moveEnd(fromEnd - position);
3034 *fromEndPtr = fromBegin;
3039#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 1
3040template <
class ALLOCATOR,
class ARGS_01>
3047 ALLOCATOR allocator,
3053 *fromEndPtr = fromEnd;
3056 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3063 TargetType *toPositionEnd = toPositionBegin + 1;
3065 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3075 *fromEndPtr = position;
3076 guard.moveEnd(fromEnd - position);
3084 *fromEndPtr = fromBegin;
3089#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 2
3090template <
class ALLOCATOR,
class ARGS_01,
3098 ALLOCATOR allocator,
3105 *fromEndPtr = fromEnd;
3108 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3116 TargetType *toPositionEnd = toPositionBegin + 1;
3118 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3128 *fromEndPtr = position;
3129 guard.moveEnd(fromEnd - position);
3137 *fromEndPtr = fromBegin;
3142#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 3
3143template <
class ALLOCATOR,
class ARGS_01,
3152 ALLOCATOR allocator,
3160 *fromEndPtr = fromEnd;
3163 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3172 TargetType *toPositionEnd = toPositionBegin + 1;
3174 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3184 *fromEndPtr = position;
3185 guard.moveEnd(fromEnd - position);
3193 *fromEndPtr = fromBegin;
3198#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 4
3199template <
class ALLOCATOR,
class ARGS_01,
3209 ALLOCATOR allocator,
3218 *fromEndPtr = fromEnd;
3221 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3231 TargetType *toPositionEnd = toPositionBegin + 1;
3233 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3243 *fromEndPtr = position;
3244 guard.moveEnd(fromEnd - position);
3252 *fromEndPtr = fromBegin;
3257#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 5
3258template <
class ALLOCATOR,
class ARGS_01,
3269 ALLOCATOR allocator,
3279 *fromEndPtr = fromEnd;
3282 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3293 TargetType *toPositionEnd = toPositionBegin + 1;
3295 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3305 *fromEndPtr = position;
3306 guard.moveEnd(fromEnd - position);
3314 *fromEndPtr = fromBegin;
3319#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 6
3320template <
class ALLOCATOR,
class ARGS_01,
3332 ALLOCATOR allocator,
3343 *fromEndPtr = fromEnd;
3346 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3358 TargetType *toPositionEnd = toPositionBegin + 1;
3360 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3370 *fromEndPtr = position;
3371 guard.moveEnd(fromEnd - position);
3379 *fromEndPtr = fromBegin;
3384#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 7
3385template <
class ALLOCATOR,
class ARGS_01,
3398 ALLOCATOR allocator,
3410 *fromEndPtr = fromEnd;
3413 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3426 TargetType *toPositionEnd = toPositionBegin + 1;
3428 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3438 *fromEndPtr = position;
3439 guard.moveEnd(fromEnd - position);
3447 *fromEndPtr = fromBegin;
3452#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 8
3453template <
class ALLOCATOR,
class ARGS_01,
3467 ALLOCATOR allocator,
3480 *fromEndPtr = fromEnd;
3483 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3497 TargetType *toPositionEnd = toPositionBegin + 1;
3499 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3509 *fromEndPtr = position;
3510 guard.moveEnd(fromEnd - position);
3518 *fromEndPtr = fromBegin;
3523#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 9
3524template <
class ALLOCATOR,
class ARGS_01,
3539 ALLOCATOR allocator,
3553 *fromEndPtr = fromEnd;
3556 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3571 TargetType *toPositionEnd = toPositionBegin + 1;
3573 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3583 *fromEndPtr = position;
3584 guard.moveEnd(fromEnd - position);
3592 *fromEndPtr = fromBegin;
3597#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_D >= 10
3598template <
class ALLOCATOR,
class ARGS_01,
3614 ALLOCATOR allocator,
3629 *fromEndPtr = fromEnd;
3632 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3648 TargetType *toPositionEnd = toPositionBegin + 1;
3650 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3660 *fromEndPtr = position;
3661 guard.moveEnd(fromEnd - position);
3669 *fromEndPtr = fromBegin;
3677template <
class ALLOCATOR,
class... ARGS>
3684 ALLOCATOR allocator,
3690 *fromEndPtr = fromEnd;
3693 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3700 TargetType *toPositionEnd = toPositionBegin + 1;
3702 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3712 *fromEndPtr = position;
3713 guard.moveEnd(fromEnd - position);
3721 *fromEndPtr = fromBegin;
3727template <
class ALLOCATOR>
3735 ALLOCATOR allocator)
3749 *fromEndPtr = fromEnd;
3757 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3760 TargetType *toPositionEnd = toPositionBegin + numElements;
3762 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3776 *fromEndPtr = position;
3777 guard.moveEnd(fromEnd - position);
3789 *fromEndPtr = fromBegin;
3793template <
class TARGET_TYPE>
3796 TARGET_TYPE *toBegin,
3797 TARGET_TYPE **fromEndPtr,
3798 TARGET_TYPE *fromBegin,
3799 TARGET_TYPE *position,
3800 TARGET_TYPE *fromEnd,
3804 destructiveMoveAndInsert<bsl::allocator<TARGET_TYPE> >(toBegin,
3813template <
class ALLOCATOR>
3822 ALLOCATOR allocator)
3836 *fromEndPtr = fromEnd;
3847 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3850 TargetType *toPositionEnd = toPositionBegin + numElements;
3852 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3866 *fromEndPtr = position;
3867 guard.moveEnd(fromEnd - position);
3879 *fromEndPtr = fromBegin;
3883template <
class TARGET_TYPE>
3885 TARGET_TYPE *toBegin,
3886 TARGET_TYPE **fromEndPtr,
3887 TARGET_TYPE *fromBegin,
3888 TARGET_TYPE *position,
3889 TARGET_TYPE *fromEnd,
3890 const TARGET_TYPE& value,
3894 destructiveMoveAndInsert<bsl::allocator<TARGET_TYPE> >(toBegin,
3904template <
class ALLOCATOR,
class FWD_ITER>
3914 ALLOCATOR allocator)
3928 *fromEndPtr = fromEnd;
3938 TargetType *toPositionBegin = toBegin + (position - fromBegin);
3941 TargetType *toPositionEnd = toPositionBegin + numElements;
3943 AutoArrayDestructor<TargetType, ALLOCATOR> guard(toPositionBegin,
3957 *fromEndPtr = position;
3958 guard.moveEnd(fromEnd - position);
3970 *fromEndPtr = fromBegin;
3974template <
class TARGET_TYPE,
class FWD_ITER>
3977 TARGET_TYPE *toBegin,
3978 TARGET_TYPE **fromEndPtr,
3979 TARGET_TYPE *fromBegin,
3980 TARGET_TYPE *position,
3981 TARGET_TYPE *fromEnd,
3987 destructiveMoveAndInsert<bsl::allocator<TARGET_TYPE> >(toBegin,
3998template <
class ALLOCATOR>
4009 ALLOCATOR allocator)
4024 *fromEndPtr = fromEnd;
4031 TargetType *toPositionBegin = toBegin + (position - fromBegin);
4032 TargetType *toPositionEnd = toPositionBegin + numElements;
4039 *fromEndPtr = position;
4041 AutoArrayDestructor<TargetType, ALLOCATOR>
4042 guard(toPositionEnd,
4043 toPositionEnd + (fromEnd - position),
4069 *fromEndPtr = fromBegin;
4073template <
class TARGET_TYPE>
4076 TARGET_TYPE *toBegin,
4077 TARGET_TYPE **fromEndPtr,
4078 TARGET_TYPE **lastPtr,
4079 TARGET_TYPE *fromBegin,
4080 TARGET_TYPE *position,
4081 TARGET_TYPE *fromEnd,
4087 destructiveMoveAndMoveInsert<bsl::allocator<TARGET_TYPE> >(toBegin,
4099#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
4102#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
4103#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
4105#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E
4106#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
4108#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 0
4109template <
class ALLOCATOR>
4114 ALLOCATOR allocator)
4138#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 1
4139template <
class ALLOCATOR,
class ARGS_01>
4144 ALLOCATOR allocator,
4170#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 2
4171template <
class ALLOCATOR,
class ARGS_01,
4177 ALLOCATOR allocator,
4205#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 3
4206template <
class ALLOCATOR,
class ARGS_01,
4213 ALLOCATOR allocator,
4243#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 4
4244template <
class ALLOCATOR,
class ARGS_01,
4252 ALLOCATOR allocator,
4284#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 5
4285template <
class ALLOCATOR,
class ARGS_01,
4294 ALLOCATOR allocator,
4328#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 6
4329template <
class ALLOCATOR,
class ARGS_01,
4339 ALLOCATOR allocator,
4375#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 7
4376template <
class ALLOCATOR,
class ARGS_01,
4387 ALLOCATOR allocator,
4425#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 8
4426template <
class ALLOCATOR,
class ARGS_01,
4438 ALLOCATOR allocator,
4478#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 9
4479template <
class ALLOCATOR,
class ARGS_01,
4492 ALLOCATOR allocator,
4534#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 10
4535template <
class ALLOCATOR,
class ARGS_01,
4549 ALLOCATOR allocator,
4594#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 0
4595template <
class TARGET_TYPE>
4601 emplace<bsl::allocator<TARGET_TYPE> >(
4608#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 1
4609template <
class TARGET_TYPE,
class ARGS_01>
4616 emplace<bsl::allocator<TARGET_TYPE> >(
4624#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 2
4625template <
class TARGET_TYPE,
class ARGS_01,
4634 emplace<bsl::allocator<TARGET_TYPE> >(
4643#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 3
4644template <
class TARGET_TYPE,
class ARGS_01,
4655 emplace<bsl::allocator<TARGET_TYPE> >(
4665#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 4
4666template <
class TARGET_TYPE,
class ARGS_01,
4679 emplace<bsl::allocator<TARGET_TYPE> >(
4690#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 5
4691template <
class TARGET_TYPE,
class ARGS_01,
4706 emplace<bsl::allocator<TARGET_TYPE> >(
4718#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 6
4719template <
class TARGET_TYPE,
class ARGS_01,
4736 emplace<bsl::allocator<TARGET_TYPE> >(
4749#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 7
4750template <
class TARGET_TYPE,
class ARGS_01,
4769 emplace<bsl::allocator<TARGET_TYPE> >(
4783#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 8
4784template <
class TARGET_TYPE,
class ARGS_01,
4805 emplace<bsl::allocator<TARGET_TYPE> >(
4820#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 9
4821template <
class TARGET_TYPE,
class ARGS_01,
4844 emplace<bsl::allocator<TARGET_TYPE> >(
4860#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_E >= 10
4861template <
class TARGET_TYPE,
class ARGS_01,
4886 emplace<bsl::allocator<TARGET_TYPE> >(
4906template <
class ALLOCATOR,
class... ARGS>
4911 ALLOCATOR allocator,
4936template <
class TARGET_TYPE,
class... ARGS>
4943 emplace<bsl::allocator<TARGET_TYPE> >(
4953template <
class ALLOCATOR>
4959 ALLOCATOR allocator)
4966 if (first == middle) {
4983template <
class TARGET_TYPE>
4986 TARGET_TYPE *middle,
4990 erase<bsl::allocator<TARGET_TYPE> >(first,
4996template <
class ALLOCATOR>
5003 ALLOCATOR allocator)
5010 if (toBegin != toEnd) {
5036template <
class TARGET_TYPE>
5043 insert<bsl::allocator<TARGET_TYPE> >(toBegin,
5049template <
class ALLOCATOR>
5055 ALLOCATOR allocator)
5062 if (0 == numElements) {
5081template <
class TARGET_TYPE>
5085 const TARGET_TYPE& value,
5089 insert<bsl::allocator<TARGET_TYPE> >(toBegin,
5096template <
class ALLOCATOR,
class FWD_ITER>
5103 ALLOCATOR allocator)
5105 if (0 == numElements) {
5127 typedef typename FWD_ITER::value_type FwdTarget;
5138 k_VALUE = k_ITER_TO_FUNC_PTRS && k_TARGET_IS_VOID_PTR
5151template <
class TARGET_TYPE,
class FWD_ITER>
5160 insert<bsl::allocator<TARGET_TYPE> >(toBegin,
5168template <
class ALLOCATOR,
class SOURCE_TYPE>
5172 SOURCE_TYPE *fromBegin,
5173 SOURCE_TYPE *fromEnd,
5175 ALLOCATOR allocator)
5177 if (0 == numElements) {
5187 k_IS_BITWISECOPYABLE =
5203template <
class TARGET_TYPE,
class SOURCE_TYPE>
5207 SOURCE_TYPE *fromBegin,
5208 SOURCE_TYPE *fromEnd,
5212 insert<bsl::allocator<TARGET_TYPE> >(toBegin,
5220template <
class ALLOCATOR>
5226 ALLOCATOR allocator)
5245template <
class TARGET_TYPE>
5248 TARGET_TYPE *fromBegin,
5249 TARGET_TYPE *fromEnd,
5252 moveConstruct<bsl::allocator<TARGET_TYPE> >(toBegin,
5258template <
class ALLOCATOR>
5267 ALLOCATOR allocator)
5286template <
class TARGET_TYPE>
5290 TARGET_TYPE **fromEndPtr,
5291 TARGET_TYPE *fromBegin,
5292 TARGET_TYPE *fromEnd,
5296 moveInsert<bsl::allocator<TARGET_TYPE> >(toBegin,
5305template <
class TARGET_TYPE>
5308 TARGET_TYPE *middle,
5332template <
class TARGET_TYPE>
5334void ArrayPrimitives_Imp::assign(TARGET_TYPE *srcStart,
5335 TARGET_TYPE *srcEnd,
5338 for ( ; srcStart != srcEnd; ++srcStart) {
5343template <
class FORWARD_ITERATOR>
5358template <
class TARGET_TYPE>
5366template <
class TARGET_TYPE>
5368void ArrayPrimitives_Imp::reverseAssign(TARGET_TYPE *dest,
5369 TARGET_TYPE *srcStart,
5370 TARGET_TYPE *srcEnd)
5372 TARGET_TYPE *destEnd = srcEnd - srcStart + dest;
5373 while (srcStart != srcEnd) {
5374 *--destEnd = *--srcEnd;
5394 std::memset(
reinterpret_cast<char *
>(begin),
5395 static_cast<char>(value),
5412 std::memset(begin, value, numElements);
5418 unsigned char *begin,
5419 unsigned char value,
5428 std::memset(begin, value, numElements);
5444 std::memset(begin, value, numElements);
5460 std::wmemset(begin, value, numElements);
5466 unsigned short *begin,
5467 unsigned short value,
5476 reinterpret_cast<short *
>(begin),
5477 static_cast<short>(value),
5485 unsigned int *begin,
5495 reinterpret_cast<int *
>(begin),
5496 static_cast<int>(value),
5513#if defined(BSLS_PLATFORM_CPU_64_BIT) && !defined(BSLS_PLATFORM_OS_WINDOWS)
5519 reinterpret_cast<int *
>(begin),
5520 static_cast<int>(value),
5529 unsigned long *begin,
5530 unsigned long value,
5538#if defined(BSLS_PLATFORM_CPU_64_BIT) && !defined(BSLS_PLATFORM_OS_WINDOWS)
5547 reinterpret_cast<int *
>(begin),
5548 static_cast<int>(value),
5574template <
class TARGET_TYPE>
5577 TARGET_TYPE **begin,
5594 reinterpret_cast<void **
>(begin),
5595 static_cast<void *
>(value),
5601template <
class TARGET_TYPE>
5604 const TARGET_TYPE **begin,
5605 const TARGET_TYPE *value,
5617 reinterpret_cast<const void **
>(begin),
5618 static_cast<const void *
>(value),
5624template <
class TARGET_TYPE>
5627 volatile TARGET_TYPE **begin,
5628 volatile TARGET_TYPE *value,
5640 reinterpret_cast<volatile void **
>(begin),
5641 static_cast<volatile void *
>(value),
5647template <
class TARGET_TYPE>
5650 const volatile TARGET_TYPE **begin,
5651 const volatile TARGET_TYPE *value,
5663 reinterpret_cast<const volatile void **
>(begin),
5664 static_cast<const volatile void *
>(value),
5670template <
class TARGET_TYPE,
class ALLOCATOR>
5673 const TARGET_TYPE& value,
5681 if (0 == numElements) {
5685 const char *valueBuffer =
5688 std::memcpy((
void *)begin, valueBuffer,
sizeof(TARGET_TYPE));
5689 bitwiseFillN(
reinterpret_cast<char *
>(begin),
5690 sizeof(TARGET_TYPE),
5691 sizeof(TARGET_TYPE) * numElements);
5694template <
class TARGET_TYPE,
class ALLOCATOR>
5697 const TARGET_TYPE& value,
5699 ALLOCATOR *allocator,
5706 if (0 == numElements) {
5709 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(begin,
5713 TARGET_TYPE *
end =
begin + numElements;
5716 begin = guard.moveEnd(1);
5717 }
while (begin != end);
5723template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
5726 TARGET_TYPE *toBegin,
5729 ALLOCATOR allocator,
5744#if defined(BSLALG_ARRAYPRIMITIVES_CANNOT_REMOVE_POINTER_FROM_FUNCTION_POINTER)
5747 (
void *
const *)fromBegin,
5748 (
void *
const *)fromEnd,
5753 reinterpret_cast<void * *
>(
const_cast<NcPtrType **
>(toBegin)),
5754 reinterpret_cast<void *
const *
>(
const_cast<NcIter *
const *
>(fromBegin)),
5755 reinterpret_cast<void *
const *
>(
const_cast<NcIter *
const *
>(fromEnd)),
5761template <
class FWD_ITER,
class ALLOCATOR>
5777 while (fromBegin != fromEnd) {
5781 *toBegin =
reinterpret_cast<void *
>(*fromBegin);
5787template <
class TARGET_TYPE,
class ALLOCATOR>
5790 TARGET_TYPE *toBegin,
5791 const TARGET_TYPE *fromBegin,
5792 const TARGET_TYPE *fromEnd,
5800 const size_type numBytes =
reinterpret_cast<const char*
>(fromEnd)
5801 -
reinterpret_cast<const char*
>(fromBegin);
5803 std::memcpy((
void *)toBegin, fromBegin, numBytes);
5807template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
5809 TARGET_TYPE *toBegin,
5812 ALLOCATOR allocator,
5819 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin, toBegin,
5822 while (fromBegin != fromEnd) {
5830 toBegin = guard.moveEnd(1);
5836template <
class TARGET_TYPE,
class ALLOCATOR>
5839 TARGET_TYPE *toBegin,
5840 TARGET_TYPE *fromBegin,
5841 TARGET_TYPE *fromEnd,
5849 const size_type numBytes =
reinterpret_cast<const char*
>(fromEnd)
5850 -
reinterpret_cast<const char*
>(fromBegin);
5852 std::memcpy((
void *)toBegin, fromBegin, numBytes);
5856template <
class TARGET_TYPE,
class ALLOCATOR>
5858 TARGET_TYPE *toBegin,
5859 TARGET_TYPE *fromBegin,
5860 TARGET_TYPE *fromEnd,
5861 ALLOCATOR allocator,
5868 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin, toBegin,
5871 while (fromBegin != fromEnd) {
5877 toBegin = guard.moveEnd(1);
5882template <
class TARGET_TYPE,
class ALLOCATOR>
5884 TARGET_TYPE *toBegin,
5885 TARGET_TYPE *fromBegin,
5886 TARGET_TYPE *fromEnd,
5887 ALLOCATOR allocator,
5894 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin, toBegin,
5897 while (fromBegin != fromEnd) {
5903 toBegin = guard.moveEnd(1);
5911template <
class TARGET_TYPE,
class ALLOCATOR>
5923 std::memset(
static_cast<void *
>(begin),
5925 sizeof(TARGET_TYPE) * numElements);
5929template <
class TARGET_TYPE,
class ALLOCATOR>
5934 ALLOCATOR allocator,
5940 if (0 < numElements) {
5942 bitwiseFillN(
reinterpret_cast<char *
>(begin),
5943 sizeof(TARGET_TYPE),
5944 numElements *
sizeof(TARGET_TYPE));
5948template <
class TARGET_TYPE,
class ALLOCATOR>
5952 ALLOCATOR allocator,
5958 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(begin, begin, allocator);
5960 const TARGET_TYPE *
end =
begin + numElements;
5961 while (begin != end) {
5963 begin = guard.moveEnd(1);
5970template <
class TARGET_TYPE,
class ALLOCATOR>
5973 TARGET_TYPE *toBegin,
5974 TARGET_TYPE *fromBegin,
5975 TARGET_TYPE *fromEnd,
5983 const size_type numBytes =
reinterpret_cast<const char*
>(fromEnd)
5984 -
reinterpret_cast<const char*
>(fromBegin);
5986 std::memcpy((
void *)toBegin, fromBegin, numBytes);
5990template <
class TARGET_TYPE,
class ALLOCATOR>
5993 TARGET_TYPE *toBegin,
5994 TARGET_TYPE *fromBegin,
5995 TARGET_TYPE *fromEnd,
5996 ALLOCATOR allocator,
6006 moveIfNoexcept(toBegin, fromBegin, fromEnd, allocator,
6013#if BSLS_COMPILERFEATURES_SIMULATE_VARIADIC_TEMPLATES
6016#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
6017#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT 10
6019#ifndef BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F
6020#define BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT
6022#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 0
6023template <
class TARGET_TYPE,
class ALLOCATOR>
6026 TARGET_TYPE *toBegin,
6028 ALLOCATOR allocator,
6040#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 1
6041template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
6044 TARGET_TYPE *toBegin,
6046 ALLOCATOR allocator,
6060#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 2
6061template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6065 TARGET_TYPE *toBegin,
6067 ALLOCATOR allocator,
6083#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 3
6084template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6089 TARGET_TYPE *toBegin,
6091 ALLOCATOR allocator,
6109#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 4
6110template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6116 TARGET_TYPE *toBegin,
6118 ALLOCATOR allocator,
6138#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 5
6139template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6146 TARGET_TYPE *toBegin,
6148 ALLOCATOR allocator,
6170#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 6
6171template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6179 TARGET_TYPE *toBegin,
6181 ALLOCATOR allocator,
6205#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 7
6206template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6215 TARGET_TYPE *toBegin,
6217 ALLOCATOR allocator,
6243#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 8
6244template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6254 TARGET_TYPE *toBegin,
6256 ALLOCATOR allocator,
6284#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 9
6285template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6296 TARGET_TYPE *toBegin,
6298 ALLOCATOR allocator,
6328#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 10
6329template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6341 TARGET_TYPE *toBegin,
6343 ALLOCATOR allocator,
6376#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 0
6377template <
class TARGET_TYPE,
class ALLOCATOR>
6379 TARGET_TYPE *toBegin,
6381 ALLOCATOR allocator,
6392 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6395 TARGET_TYPE *destBegin = toBegin + numElements;
6397 std::memmove((
void *)destBegin,
6399 tailLen *
sizeof(TARGET_TYPE));
6403 TARGET_TYPE *destEnd = toEnd + numElements;
6405 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6406 destEnd - numGuarded,
6407 destEnd - numGuarded,
6411 while (guard.middle() != guard.end()) {
6413 guard.destination());
6418 if (tailLen < numElements) {
6420 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6425 while (toEnd != destBegin) {
6429 endGuard.moveBegin(-1);
6436#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 1
6437template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
6439 TARGET_TYPE *toBegin,
6441 ALLOCATOR allocator,
6453 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6456 TARGET_TYPE *destBegin = toBegin + numElements;
6458 std::memmove((
void *)destBegin,
6460 tailLen *
sizeof(TARGET_TYPE));
6464 TARGET_TYPE *destEnd = toEnd + numElements;
6466 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6467 destEnd - numGuarded,
6468 destEnd - numGuarded,
6472 while (guard.middle() != guard.end()) {
6474 guard.destination(),
6480 if (tailLen < numElements) {
6482 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6487 while (toEnd != destBegin) {
6492 endGuard.moveBegin(-1);
6499#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 2
6500template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6503 TARGET_TYPE *toBegin,
6505 ALLOCATOR allocator,
6518 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6521 TARGET_TYPE *destBegin = toBegin + numElements;
6523 std::memmove((
void *)destBegin,
6525 tailLen *
sizeof(TARGET_TYPE));
6529 TARGET_TYPE *destEnd = toEnd + numElements;
6531 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6532 destEnd - numGuarded,
6533 destEnd - numGuarded,
6537 while (guard.middle() != guard.end()) {
6539 guard.destination(),
6546 if (tailLen < numElements) {
6548 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6553 while (toEnd != destBegin) {
6559 endGuard.moveBegin(-1);
6566#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 3
6567template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6571 TARGET_TYPE *toBegin,
6573 ALLOCATOR allocator,
6587 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6590 TARGET_TYPE *destBegin = toBegin + numElements;
6592 std::memmove((
void *)destBegin,
6594 tailLen *
sizeof(TARGET_TYPE));
6598 TARGET_TYPE *destEnd = toEnd + numElements;
6600 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6601 destEnd - numGuarded,
6602 destEnd - numGuarded,
6606 while (guard.middle() != guard.end()) {
6608 guard.destination(),
6616 if (tailLen < numElements) {
6618 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6623 while (toEnd != destBegin) {
6630 endGuard.moveBegin(-1);
6637#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 4
6638template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6643 TARGET_TYPE *toBegin,
6645 ALLOCATOR allocator,
6660 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6663 TARGET_TYPE *destBegin = toBegin + numElements;
6665 std::memmove((
void *)destBegin,
6667 tailLen *
sizeof(TARGET_TYPE));
6671 TARGET_TYPE *destEnd = toEnd + numElements;
6673 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6674 destEnd - numGuarded,
6675 destEnd - numGuarded,
6679 while (guard.middle() != guard.end()) {
6681 guard.destination(),
6690 if (tailLen < numElements) {
6692 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6697 while (toEnd != destBegin) {
6705 endGuard.moveBegin(-1);
6712#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 5
6713template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6719 TARGET_TYPE *toBegin,
6721 ALLOCATOR allocator,
6737 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6740 TARGET_TYPE *destBegin = toBegin + numElements;
6742 std::memmove((
void *)destBegin,
6744 tailLen *
sizeof(TARGET_TYPE));
6748 TARGET_TYPE *destEnd = toEnd + numElements;
6750 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6751 destEnd - numGuarded,
6752 destEnd - numGuarded,
6756 while (guard.middle() != guard.end()) {
6758 guard.destination(),
6768 if (tailLen < numElements) {
6770 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6775 while (toEnd != destBegin) {
6784 endGuard.moveBegin(-1);
6791#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 6
6792template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6799 TARGET_TYPE *toBegin,
6801 ALLOCATOR allocator,
6818 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6821 TARGET_TYPE *destBegin = toBegin + numElements;
6823 std::memmove((
void *)destBegin,
6825 tailLen *
sizeof(TARGET_TYPE));
6829 TARGET_TYPE *destEnd = toEnd + numElements;
6831 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6832 destEnd - numGuarded,
6833 destEnd - numGuarded,
6837 while (guard.middle() != guard.end()) {
6839 guard.destination(),
6850 if (tailLen < numElements) {
6852 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6857 while (toEnd != destBegin) {
6867 endGuard.moveBegin(-1);
6874#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 7
6875template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6883 TARGET_TYPE *toBegin,
6885 ALLOCATOR allocator,
6903 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6906 TARGET_TYPE *destBegin = toBegin + numElements;
6908 std::memmove((
void *)destBegin,
6910 tailLen *
sizeof(TARGET_TYPE));
6914 TARGET_TYPE *destEnd = toEnd + numElements;
6916 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
6917 destEnd - numGuarded,
6918 destEnd - numGuarded,
6922 while (guard.middle() != guard.end()) {
6924 guard.destination(),
6936 if (tailLen < numElements) {
6938 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
6943 while (toEnd != destBegin) {
6954 endGuard.moveBegin(-1);
6961#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 8
6962template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
6971 TARGET_TYPE *toBegin,
6973 ALLOCATOR allocator,
6992 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
6995 TARGET_TYPE *destBegin = toBegin + numElements;
6997 std::memmove((
void *)destBegin,
6999 tailLen *
sizeof(TARGET_TYPE));
7003 TARGET_TYPE *destEnd = toEnd + numElements;
7005 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
7006 destEnd - numGuarded,
7007 destEnd - numGuarded,
7011 while (guard.middle() != guard.end()) {
7013 guard.destination(),
7026 if (tailLen < numElements) {
7028 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
7033 while (toEnd != destBegin) {
7045 endGuard.moveBegin(-1);
7052#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 9
7053template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7063 TARGET_TYPE *toBegin,
7065 ALLOCATOR allocator,
7085 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
7088 TARGET_TYPE *destBegin = toBegin + numElements;
7090 std::memmove((
void *)destBegin,
7092 tailLen *
sizeof(TARGET_TYPE));
7096 TARGET_TYPE *destEnd = toEnd + numElements;
7098 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
7099 destEnd - numGuarded,
7100 destEnd - numGuarded,
7104 while (guard.middle() != guard.end()) {
7106 guard.destination(),
7120 if (tailLen < numElements) {
7122 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
7127 while (toEnd != destBegin) {
7140 endGuard.moveBegin(-1);
7147#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 10
7148template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7159 TARGET_TYPE *toBegin,
7161 ALLOCATOR allocator,
7182 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
7185 TARGET_TYPE *destBegin = toBegin + numElements;
7187 std::memmove((
void *)destBegin,
7189 tailLen *
sizeof(TARGET_TYPE));
7193 TARGET_TYPE *destEnd = toEnd + numElements;
7195 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
7196 destEnd - numGuarded,
7197 destEnd - numGuarded,
7201 while (guard.middle() != guard.end()) {
7203 guard.destination(),
7218 if (tailLen < numElements) {
7220 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
7225 while (toEnd != destBegin) {
7239 endGuard.moveBegin(-1);
7247#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 0
7248template <
class TARGET_TYPE,
class ALLOCATOR>
7250 TARGET_TYPE *toBegin,
7252 ALLOCATOR allocator,
7260 if (toEnd > toBegin) {
7275 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7280 TARGET_TYPE *destEnd = toEnd;
7281 TARGET_TYPE *srcEnd = toEnd - 1;
7282 while (toBegin != srcEnd) {
7299#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 1
7300template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01>
7302 TARGET_TYPE *toBegin,
7304 ALLOCATOR allocator,
7313 if (toEnd > toBegin) {
7329 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7334 TARGET_TYPE *destEnd = toEnd;
7335 TARGET_TYPE *srcEnd = toEnd - 1;
7336 while (toBegin != srcEnd) {
7353#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 2
7354template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7357 TARGET_TYPE *toBegin,
7359 ALLOCATOR allocator,
7369 if (toEnd > toBegin) {
7386 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7391 TARGET_TYPE *destEnd = toEnd;
7392 TARGET_TYPE *srcEnd = toEnd - 1;
7393 while (toBegin != srcEnd) {
7411#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 3
7412template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7416 TARGET_TYPE *toBegin,
7418 ALLOCATOR allocator,
7429 if (toEnd > toBegin) {
7447 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7452 TARGET_TYPE *destEnd = toEnd;
7453 TARGET_TYPE *srcEnd = toEnd - 1;
7454 while (toBegin != srcEnd) {
7473#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 4
7474template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7479 TARGET_TYPE *toBegin,
7481 ALLOCATOR allocator,
7493 if (toEnd > toBegin) {
7512 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7517 TARGET_TYPE *destEnd = toEnd;
7518 TARGET_TYPE *srcEnd = toEnd - 1;
7519 while (toBegin != srcEnd) {
7539#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 5
7540template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7546 TARGET_TYPE *toBegin,
7548 ALLOCATOR allocator,
7561 if (toEnd > toBegin) {
7581 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7586 TARGET_TYPE *destEnd = toEnd;
7587 TARGET_TYPE *srcEnd = toEnd - 1;
7588 while (toBegin != srcEnd) {
7609#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 6
7610template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7617 TARGET_TYPE *toBegin,
7619 ALLOCATOR allocator,
7633 if (toEnd > toBegin) {
7654 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7659 TARGET_TYPE *destEnd = toEnd;
7660 TARGET_TYPE *srcEnd = toEnd - 1;
7661 while (toBegin != srcEnd) {
7683#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 7
7684template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7692 TARGET_TYPE *toBegin,
7694 ALLOCATOR allocator,
7709 if (toEnd > toBegin) {
7731 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7736 TARGET_TYPE *destEnd = toEnd;
7737 TARGET_TYPE *srcEnd = toEnd - 1;
7738 while (toBegin != srcEnd) {
7761#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 8
7762template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7771 TARGET_TYPE *toBegin,
7773 ALLOCATOR allocator,
7789 if (toEnd > toBegin) {
7812 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7817 TARGET_TYPE *destEnd = toEnd;
7818 TARGET_TYPE *srcEnd = toEnd - 1;
7819 while (toBegin != srcEnd) {
7843#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 9
7844template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7854 TARGET_TYPE *toBegin,
7856 ALLOCATOR allocator,
7873 if (toEnd > toBegin) {
7897 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7902 TARGET_TYPE *destEnd = toEnd;
7903 TARGET_TYPE *srcEnd = toEnd - 1;
7904 while (toBegin != srcEnd) {
7929#if BSLALG_ARRAYPRIMITIVES_VARIADIC_LIMIT_F >= 10
7930template <
class TARGET_TYPE,
class ALLOCATOR,
class ARGS_01,
7941 TARGET_TYPE *toBegin,
7943 ALLOCATOR allocator,
7961 if (toEnd > toBegin) {
7986 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
7991 TARGET_TYPE *destEnd = toEnd;
7992 TARGET_TYPE *srcEnd = toEnd - 1;
7993 while (toBegin != srcEnd) {
8022template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
8025 TARGET_TYPE *toBegin,
8027 ALLOCATOR allocator,
8040template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
8042 TARGET_TYPE *toBegin,
8044 ALLOCATOR allocator,
8056 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
8059 TARGET_TYPE *destBegin = toBegin + numElements;
8061 std::memmove((
void *)destBegin,
8063 tailLen *
sizeof(TARGET_TYPE));
8067 TARGET_TYPE *destEnd = toEnd + numElements;
8069 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
8070 destEnd - numGuarded,
8071 destEnd - numGuarded,
8075 while (guard.middle() != guard.end()) {
8077 guard.destination(),
8083 if (tailLen < numElements) {
8085 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
8090 while (toEnd != destBegin) {
8095 endGuard.moveBegin(-1);
8101template <
class TARGET_TYPE,
class ALLOCATOR,
class... ARGS>
8103 TARGET_TYPE *toBegin,
8105 ALLOCATOR allocator,
8114 if (toEnd > toBegin) {
8130 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
8135 TARGET_TYPE *destEnd = toEnd;
8136 TARGET_TYPE *srcEnd = toEnd - 1;
8137 while (toBegin != srcEnd) {
8157template <
class TARGET_TYPE,
class ALLOCATOR>
8160 TARGET_TYPE *middle,
8162 ALLOCATOR allocator,
8183 size_type numBytes =
reinterpret_cast<const char *
>(last)
8184 -
reinterpret_cast<const char *
>(middle);
8186 std::memmove((
void *)first, middle, numBytes);
8190template <
class TARGET_TYPE,
class ALLOCATOR>
8193 TARGET_TYPE *middle,
8195 ALLOCATOR allocator,
8212 while (middle != last) {
8225template <
class TARGET_TYPE,
class ALLOCATOR>
8228 TARGET_TYPE *toBegin,
8230 const TARGET_TYPE& value,
8232 ALLOCATOR allocator,
8252 if (toBegin <= tempValuePtr && tempValuePtr < toEnd ) {
8255 tempValuePtr += numElements;
8262 const size_type numBytes =
reinterpret_cast<const char*
>(toEnd)
8263 -
reinterpret_cast<const char*
>(toBegin);
8265 std::memmove((
void *)(toBegin + numElements), toBegin, numBytes);
8283 bitwiseFillN(
reinterpret_cast<char *
>(toBegin),
8285 numElements *
sizeof value);
8288template <
class TARGET_TYPE,
class ALLOCATOR>
8290 TARGET_TYPE *toBegin,
8292 const TARGET_TYPE& value,
8294 ALLOCATOR allocator,
8311 if (toBegin <= tempValuePtr && tempValuePtr < toEnd + numElements) {
8314 tempValuePtr += numElements;
8318 size_type numGuarded = tailLen < numElements ? tailLen : numElements;
8324 TARGET_TYPE *destBegin = toBegin + numElements;
8326 std::memmove((
void *)destBegin,
8328 tailLen *
sizeof(TARGET_TYPE));
8335 TARGET_TYPE *destEnd = toEnd + numElements;
8337 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
8338 destEnd - numGuarded,
8339 destEnd - numGuarded,
8343 while (guard.middle() != guard.end()) {
8345 guard.destination(),
8353 if (tailLen < numElements) {
8359 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard(destBegin,
8367 while (toEnd != destBegin) {
8372 endGuard.moveBegin(-1);
8378template <
class TARGET_TYPE,
class ALLOCATOR>
8380 TARGET_TYPE *toBegin,
8382 const TARGET_TYPE& value,
8384 ALLOCATOR allocator,
8413 const size_type tailLen = toEnd - toBegin;
8414 if (tailLen >= numElements) {
8421 moveIfNoexcept(toEnd,
8422 toEnd - numElements,
8427 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
8428 toEnd + numElements,
8441 TARGET_TYPE *src = toEnd - numElements;
8442 TARGET_TYPE *dest = toEnd;
8443 while (toBegin != src) {
8451 for ( ; toBegin != dest; ++toBegin) {
8452 *toBegin = space.
object();
8474 moveIfNoexcept(toBegin + numElements,
8480 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd + remElements,
8481 toEnd + numElements,
8493 guard.moveBegin(-remElements);
8499 for ( ; toBegin != toEnd; ++toBegin) {
8500 *toBegin = space.
object();
8510template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
8513 TARGET_TYPE *toBegin,
8518 ALLOCATOR allocator,
8526#if defined(BSLALG_ARRAYPRIMITIVES_CANNOT_REMOVE_POINTER_FROM_FUNCTION_POINTER)
8528 insert((
void * *)toBegin,
8530 (
void *
const *)fromBegin,
8531 (
void *
const *)fromEnd,
8544 reinterpret_cast<void * *
>(
const_cast<NcPtrType **
>(toBegin)),
8545 reinterpret_cast<void * *
>(
const_cast<NcPtrType **
>(toEnd)),
8546 reinterpret_cast<void *
const *
>(
const_cast<NcIter *
const *
>(fromBegin)),
8547 reinterpret_cast<void *
const *
>(
const_cast<NcIter *
const *
>(fromEnd)),
8554template <
class TARGET_TYPE,
class ALLOCATOR>
8557 TARGET_TYPE *toBegin,
8559 const TARGET_TYPE *fromBegin,
8560 const TARGET_TYPE *fromEnd,
8589 const size_type numBytes =
reinterpret_cast<const char*
>(toEnd)
8590 -
reinterpret_cast<const char*
>(toBegin);
8592 std::memmove((
void *)(toBegin + numElements), toBegin, numBytes);
8600 std::memcpy((
void *)toBegin,
8602 numElements *
sizeof(TARGET_TYPE));
8606template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
8608 TARGET_TYPE *toBegin,
8613 ALLOCATOR allocator,
8620 if (0 == numElements) {
8642 const size_type tailLen = toEnd - toBegin;
8643 const size_type numGuarded = tailLen < numElements ? tailLen : numElements;
8649 TARGET_TYPE *destBegin = toBegin + numElements;
8651 std::memmove((
void *)destBegin,
8653 tailLen *
sizeof(TARGET_TYPE));
8660 TARGET_TYPE *destEnd = toEnd + numElements;
8662 AutoArrayMoveDestructor<TARGET_TYPE, ALLOCATOR> guard(toBegin,
8663 destEnd - numGuarded,
8664 destEnd - numGuarded,
8668 for (; guard.middle() != guard.end(); ++fromBegin) {
8670 guard.destination(),
8678 if (tailLen < numElements) {
8684 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard1(toEnd,
8687 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> endGuard2(destBegin,
8695 for (; toEnd != destBegin; ++fromBegin) {
8699 toEnd = endGuard1.moveEnd(1);
8701 endGuard1.release();
8702 endGuard2.release();
8706template <
class TARGET_TYPE,
class FWD_ITER,
class ALLOCATOR>
8708 TARGET_TYPE *toBegin,
8713 ALLOCATOR allocator,
8719 if (0 == numElements) {
8731 const size_type tailLen = toEnd - toBegin;
8732 if (tailLen > numElements) {
8739 moveIfNoexcept(toEnd,
8740 toEnd - numElements,
8745 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd,
8746 toEnd + numElements,
8753 TARGET_TYPE *src = toEnd - numElements;
8754 TARGET_TYPE *dest = toEnd;
8755 while (toBegin != src) {
8763 for (; toBegin != dest; ++toBegin, ++fromBegin) {
8764 *toBegin = *fromBegin;
8778 moveIfNoexcept(toBegin + numElements,
8784 AutoArrayDestructor<TARGET_TYPE, ALLOCATOR> guard(toEnd + remElements,
8785 toEnd + numElements,
8792 for (; toBegin != toEnd; ++fromBegin, ++toBegin) {
8793 *toBegin = *fromBegin;
8809template <
class FWD_ITER,
class ALLOCATOR>
8829 if (0 == numElements) {
8851 const size_type tailLen = toEnd - toBegin;
8857 void **destBegin = toBegin + numElements;
8860 std::memmove(destBegin, toBegin, tailLen *
sizeof(
void **));
8863 for (
size_type i = 0; i < numElements; ++i) {
8864 *toBegin =
reinterpret_cast<void *
>(*fromBegin);
8873template <
class TARGET_TYPE,
class ALLOCATOR>
8876 TARGET_TYPE *toBegin,
8878 TARGET_TYPE **lastPtr,
8882 ALLOCATOR allocator,
8894 insert(toBegin, toEnd, first, last, numElements, allocator,
8899template <
class TARGET_TYPE,
class ALLOCATOR>
8902 TARGET_TYPE *toBegin,
8904 TARGET_TYPE **lastPtr,
8908 ALLOCATOR allocator,
8921 insert(toBegin, toEnd, first, last, numElements, allocator,
8929template <
class TARGET_TYPE>
8933 TARGET_TYPE *middle,
8940 bitwiseRotate(
reinterpret_cast<char *
>(begin),
8941 reinterpret_cast<char *
>(middle),
8942 reinterpret_cast<char *
>(end));
8945template <
class TARGET_TYPE>
8948 TARGET_TYPE *middle,
8955 if (begin == middle || middle == end) {
8964 const std::size_t numElements = middle -
begin;
8965 const std::size_t remElements =
end - middle;
8967 if (numElements == remElements) {
8968 for (; middle !=
end; ++
begin, ++middle) {
8969 TARGET_TYPE tmp(*middle);
8981 std::size_t numCycles =
end -
begin;
8982 std::size_t remainder = numElements;
8983 while (remainder != 0) {
8984 std::size_t t = numCycles % remainder;
8985 numCycles = remainder;
8996 for (std::size_t i = 0; i < numCycles; ++i) {
9001 TARGET_TYPE *ptr =
begin;
9002 TARGET_TYPE tmp = *ptr;
9004 if (numElements < remElements) {
9022 std::size_t cycleSize = remElements / numCycles;
9024 for (std::size_t j = 0; j < cycleSize; ++j) {
9025 if (ptr > begin + remElements) {
9029 *ptr = *(ptr - remElements);
9033 *ptr = *(ptr + numElements);
9057 std::size_t cycleSize = numElements / numCycles - 1;
9059 for (std::size_t j = 0; j < cycleSize; ++j) {
9060 if (ptr < end - numElements) {
9061 *ptr = *(ptr + numElements);
9065 *ptr = *(ptr - remElements);
9084template <
class ALLOCATOR>
9091 ALLOCATOR allocator,
9102 ValueType *valuePtr =
9104 if (begin <= valuePtr && valuePtr < end) {
9108#if defined(BSLS_PLATFORM_PRAGMA_GCC_DIAGNOSTIC_GCC)
9110#pragma GCC diagnostic push
9111#pragma GCC diagnostic ignored "-Wclass-memaccess"
9115 std::memmove(begin + 1, begin, (end - begin) *
sizeof(ValueType));
9123#if defined(BSLS_PLATFORM_PRAGMA_GCC_DIAGNOSTIC_GCC)
9124#pragma GCC diagnostic pop
9128template <
class ALLOCATOR>
9135 ALLOCATOR allocator,
9146 ValueType *valuePtr =
9148 if (begin <= valuePtr && valuePtr < end) {
9153 size_t bytesNum = (
end -
begin) *
sizeof(ValueType);
9156#if defined(BSLS_PLATFORM_PRAGMA_GCC_DIAGNOSTIC_GCC)
9158#pragma GCC diagnostic push
9159#pragma GCC diagnostic ignored "-Wclass-memaccess"
9162 std::memmove(begin + 1, begin, bytesNum);
9168 class ElementsProctor {
9175 ElementsProctor(ValueType *p,
size_t n) : d_begin(p), d_bytesNum(n) {}
9178 if(d_bytesNum) std::memmove(d_begin, d_begin + 1, d_bytesNum);
9181 void release() { d_bytesNum = 0; }
9182 } proctor(begin, bytesNum);
9191#if defined(BSLS_PLATFORM_PRAGMA_GCC_DIAGNOSTIC_GCC)
9192#pragma GCC diagnostic pop
9196template <
class ALLOCATOR>
9203 ALLOCATOR allocator,
9214 ValueType *valuePtr =
9216 if (begin <= valuePtr && valuePtr < end) {
9239 end, end + 1, allocator);
9245 ValueType *dst =
end;
9246 ValueType *src =
end - 1;
9247 while (src != begin) {
9262#ifndef BDE_OPENSOURCE_PUBLICATION
9273#if defined(BSLALG_ARRAYPRIMITIVES_CANNOT_REMOVE_POINTER_FROM_FUNCTION_POINTER)
9274# undef BSLALG_ARRAYPRIMITIVES_CANNOT_REMOVE_POINTER_FROM_FUNCTION_POINTER
9278# error Not valid except when included from bslalg_arrayprimitives.h
Definition bslalg_autoarraydestructor.h:232
Definition bslma_allocator.h:457
Definition bslma_destructorproctor.h:259
Definition bslmf_movableref.h:751
bslalg::ArrayPrimitives bslalg_ArrayPrimitives
This alias is defined for backward compatibility.
Definition bslalg_arrayprimitives.h:4993
#define BSLMF_ASSERT(expr)
Definition bslmf_assert.h:229
static const bool value
Definition bslmf_integralconstant.h:258
#define BSLS_ASSERT_SAFE(X)
Definition bsls_assert.h:1762
#define BSLS_COMPILERFEATURES_FORWARD_REF(T)
Definition bsls_compilerfeatures.h:2012
#define BSLS_COMPILERFEATURES_FORWARD(T, V)
Definition bsls_compilerfeatures.h:2018
#define BSLS_UTIL_ADDRESSOF(OBJ)
Definition bsls_util.h:289
T::iterator begin(T &container)
Definition bslstl_iterator.h:1495
T::iterator end(T &container)
Definition bslstl_iterator.h:1523
Definition bdlc_flathashmap.h:1805
Definition balxml_encoderoptions.h:68
static void construct(ALLOCATOR_TYPE &basicAllocator, ELEMENT_TYPE *elementAddr, Args &&... arguments)
Definition bslma_allocatortraits.h:1472
BloombergLP::bslma::AllocatorTraits_PointerType< ALLOCATOR_TYPE >::type pointer
Definition bslma_allocatortraits.h:1149
ALLOCATOR_TYPE::value_type value_type
Definition bslma_allocatortraits.h:1145
Definition bslmf_integralconstant.h:244
Definition bslmf_isenum.h:270
Definition bslmf_isfundamental.h:329
Definition bslmf_ismemberpointer.h:143
Definition bslmf_ispointer.h:138
Definition bslmf_issame.h:146
Definition bslmf_istriviallydefaultconstructible.h:293
Definition bslmf_isvoid.h:138
Definition bslmf_removecv.h:118
Definition bslmf_removepointer.h:255
BloombergLP::bslmf::RemovePointer_Imp< t_TYPE >::Type type
Definition bslmf_removepointer.h:267
static void destroy(TARGET_TYPE *begin, TARGET_TYPE *end, ALLOCATOR allocator, bsl::true_type)
Definition bslalg_arraydestructionprimitives.h:232
static void emplace(TARGET_TYPE *toBegin, TARGET_TYPE *toEnd, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_COPYABLE_TRAITS >, ARGS &&... args)
TBD: document this.
Definition bslalg_arrayprimitives.h:3698
static void moveConstruct(TARGET_TYPE *toBegin, TARGET_TYPE *fromBegin, TARGET_TYPE *fromEnd, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_COPYABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:3520
static bool isInvalidRange(FORWARD_ITERATOR begin, FORWARD_ITERATOR end)
Definition bslalg_arrayprimitives.h:3027
static void bitwiseRotateBackward(char *begin, char *middle, char *end)
static void bitwiseRotate(char *begin, char *middle, char *end)
@ e_BITWISE_MOVEABLE_TRAITS
Definition bslalg_arrayprimitives.h:1260
@ e_HAS_TRIVIAL_DEFAULT_CTOR_TRAITS
Definition bslalg_arrayprimitives.h:1258
@ e_NIL_TRAITS
Definition bslalg_arrayprimitives.h:1261
@ e_BITWISE_COPYABLE_TRAITS
Definition bslalg_arrayprimitives.h:1259
@ e_IS_FUNDAMENTAL_OR_POINTER
Definition bslalg_arrayprimitives.h:1257
@ e_IS_ITERATOR_TO_FUNCTION_POINTER
Definition bslalg_arrayprimitives.h:1255
@ e_IS_POINTER_TO_POINTER
Definition bslalg_arrayprimitives.h:1256
static void shiftAndInsert(typename bsl::allocator_traits< ALLOCATOR >::pointer begin, typename bsl::allocator_traits< ALLOCATOR >::pointer end, bslmf::MovableRef< typename bsl::allocator_traits< ALLOCATOR >::value_type > value, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_COPYABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:4811
static void bitwiseFillN(char *begin, size_type numBytesInitialized, size_type numBytes)
static void bitwiseSwapRanges(char *begin, char *middle, char *end)
static void uninitializedFillN(bool *begin, bool value, size_type numElements, void *=0, bsl::integral_constant< int, e_IS_FUNDAMENTAL_OR_POINTER >=bsl::integral_constant< int, e_IS_FUNDAMENTAL_OR_POINTER >())
Definition bslalg_arrayprimitives.h:3064
static void moveInsert(TARGET_TYPE *toBegin, TARGET_TYPE *toEnd, TARGET_TYPE **lastPtr, TARGET_TYPE *first, TARGET_TYPE *last, size_type numElements, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_MOVEABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:4600
static void moveIfNoexcept(TARGET_TYPE *toBegin, TARGET_TYPE *fromBegin, TARGET_TYPE *fromEnd, ALLOCATOR allocator, bsl::integral_constant< int, e_NIL_TRAITS >)
Definition bslalg_arrayprimitives.h:3565
ArrayPrimitives::difference_type difference_type
Definition bslalg_arrayprimitives.h:1247
static void bitwiseRotateForward(char *begin, char *middle, char *end)
static void copyConstruct(TARGET_TYPE *toBegin, FWD_ITER fromBegin, FWD_ITER fromEnd, ALLOCATOR allocator, bsl::integral_constant< int, e_IS_POINTER_TO_POINTER >)
Definition bslalg_arrayprimitives.h:3407
ArrayPrimitives::size_type size_type
Definition bslalg_arrayprimitives.h:1246
static void destructiveMove(TARGET_TYPE *toBegin, TARGET_TYPE *fromBegin, TARGET_TYPE *fromEnd, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_MOVEABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:3654
@ k_INPLACE_BUFFER_SIZE
Definition bslalg_arrayprimitives.h:1268
static void erase(TARGET_TYPE *first, TARGET_TYPE *middle, TARGET_TYPE *last, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_MOVEABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:3883
static void rotate(TARGET_TYPE *begin, TARGET_TYPE *middle, TARGET_TYPE *end, bsl::integral_constant< int, e_BITWISE_MOVEABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:4656
static void insert(TARGET_TYPE *toBegin, TARGET_TYPE *toEnd, const TARGET_TYPE &value, size_type numElements, ALLOCATOR allocator, bsl::integral_constant< int, e_BITWISE_COPYABLE_TRAITS >)
Definition bslalg_arrayprimitives.h:3952
static void defaultConstruct(TARGET_TYPE *begin, size_type numElements, ALLOCATOR allocator, bsl::integral_constant< int, e_HAS_TRIVIAL_DEFAULT_CTOR_TRAITS >)
Definition bslalg_arrayprimitives.h:3595
Definition bslalg_arrayprimitives.h:418
static void destructiveMoveAndMoveInsert(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer *fromEndPtr, typename bsl::allocator_traits< ALLOCATOR >::pointer *lastPtr, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer position, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, typename bsl::allocator_traits< ALLOCATOR >::pointer first, typename bsl::allocator_traits< ALLOCATOR >::pointer last, size_type numElements, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2488
static void copyConstruct(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, FWD_ITER fromBegin, FWD_ITER fromEnd, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:1959
static void destructiveMoveAndEmplace(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer *fromEndPtr, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer position, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, ALLOCATOR allocator, ARGS &&... arguments)
Definition bslalg_arrayprimitives.h:2146
ArrayPrimitives_Imp Imp
Definition bslalg_arrayprimitives.h:422
static void insert(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer toEnd, bslmf::MovableRef< typename bsl::allocator_traits< ALLOCATOR >::value_type > value, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2680
static void destructiveMove(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2107
static void defaultConstruct(typename bsl::allocator_traits< ALLOCATOR >::pointer begin, size_type numElements, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2064
static void moveInsert(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer toEnd, typename bsl::allocator_traits< ALLOCATOR >::pointer *fromEndPtr, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, size_type numElements, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2942
static void emplace(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer toEnd, ALLOCATOR allocator, ARGS &&... arguments)
Definition bslalg_arrayprimitives.h:2591
static void moveConstruct(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2904
static void destructiveMoveAndInsert(typename bsl::allocator_traits< ALLOCATOR >::pointer toBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer *fromEndPtr, typename bsl::allocator_traits< ALLOCATOR >::pointer fromBegin, typename bsl::allocator_traits< ALLOCATOR >::pointer position, typename bsl::allocator_traits< ALLOCATOR >::pointer fromEnd, size_type numElements, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2217
std::ptrdiff_t difference_type
Definition bslalg_arrayprimitives.h:424
static void erase(typename bsl::allocator_traits< ALLOCATOR >::pointer first, typename bsl::allocator_traits< ALLOCATOR >::pointer middle, typename bsl::allocator_traits< ALLOCATOR >::pointer last, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:2637
static void uninitializedFillN(typename bsl::allocator_traits< ALLOCATOR >::pointer begin, size_type numElements, const typename bsl::allocator_traits< ALLOCATOR >::value_type &value, ALLOCATOR allocator)
Definition bslalg_arrayprimitives.h:1905
std::size_t size_type
Definition bslalg_arrayprimitives.h:423
static void rotate(TARGET_TYPE *first, TARGET_TYPE *middle, TARGET_TYPE *last)
Definition bslalg_arrayprimitives.h:2989
static void construct(TARGET_TYPE *address, const ALLOCATOR &allocator)
Definition bslma_constructionutil.h:1243
static Allocator * allocator(Allocator *basicAllocator=0)
Definition bslma_default.h:897
Definition bslmf_isbitwisecopyable.h:298
Definition bslmf_isbitwisemoveable.h:718
Definition bslmf_functionpointertraits.h:153
static MovableRef< t_TYPE > move(t_TYPE &reference) BSLS_KEYWORD_NOEXCEPT
Definition bslmf_movableref.h:1060
static t_TYPE & access(t_TYPE &ref) BSLS_KEYWORD_NOEXCEPT
Definition bslmf_movableref.h:1032
static bsl::enable_if<!bsl::is_nothrow_move_constructible< t_TYPE >::value &&bsl::is_copy_constructible< t_TYPE >::value, constt_TYPE & >::type move_if_noexcept(t_TYPE &lvalue) BSLS_KEYWORD_NOEXCEPT
Definition bslmf_movableref.h:915
@ BSLS_MAX_ALIGNMENT
Definition bsls_alignmentutil.h:275
unsigned long long Uint64
Definition bsls_types.h:137
long long Int64
Definition bsls_types.h:132
Definition bsls_objectbuffer.h:276
TYPE & object()
Definition bsls_objectbuffer.h:351