From 392e4fbdd9b152efff4c051286f6b2c21270c902 Mon Sep 17 00:00:00 2001 From: Bill Wendling Date: Wed, 18 Apr 2012 21:39:23 +0000 Subject: [PATCH] Creating release_31 branch llvm-svn: 155059 llvm-svn: 155053 llvm-svn: 155051 --- debuginfo-tests/README.txt | 19 - debuginfo-tests/aggregate-indirect-arg.cpp | 32 - debuginfo-tests/block_var.m | 32 - debuginfo-tests/blocks.m | 43 - debuginfo-tests/ctor.cpp | 25 - debuginfo-tests/dbg-arg.ll | 126 - debuginfo-tests/dbg-declare.ll | 263 - debuginfo-tests/dbg-declare2.ll | 264 - debuginfo-tests/foreach.m | 31 - debuginfo-tests/forward-declare-class.cpp | 24 - debuginfo-tests/local-var.ll | 109 - debuginfo-tests/local-var2.ll | 109 - debuginfo-tests/nested-struct.cpp | 21 - debuginfo-tests/sret.cpp | 71 - debuginfo-tests/unused-boolean-arg.ll | 84 - libclc/CREDITS.TXT | 2 - libclc/LICENSE.TXT | 64 - libclc/README.TXT | 37 - libclc/build/metabuild.py | 91 - libclc/build/ninja_syntax.py | 110 - libclc/compile-test.sh | 3 - libclc/configure.py | 133 - libclc/generic/include/clc/as_type.h | 53 - libclc/generic/include/clc/clc.h | 57 - libclc/generic/include/clc/clcfunc.h | 4 - libclc/generic/include/clc/clcmacro.h | 42 - libclc/generic/include/clc/clctypes.h | 74 - libclc/generic/include/clc/gentype.inc | 51 - libclc/generic/include/clc/geometric/cross.h | 2 - .../generic/include/clc/geometric/distance.h | 2 - libclc/generic/include/clc/geometric/dot.h | 2 - .../generic/include/clc/geometric/floatn.inc | 35 - libclc/generic/include/clc/geometric/length.h | 2 - .../generic/include/clc/geometric/length.inc | 1 - .../generic/include/clc/geometric/normalize.h | 2 - .../include/clc/geometric/normalize.inc | 1 - libclc/generic/include/clc/integer/abs.h | 2 - libclc/generic/include/clc/integer/abs.inc | 1 - libclc/generic/include/clc/integer/abs_diff.h | 2 - .../generic/include/clc/integer/abs_diff.inc | 1 - libclc/generic/include/clc/integer/add_sat.h | 2 - .../generic/include/clc/integer/add_sat.inc | 1 - .../generic/include/clc/integer/gentype.inc | 385 - libclc/generic/include/clc/math/cos.h | 6 - libclc/generic/include/clc/math/native_cos.h | 1 - .../generic/include/clc/math/native_divide.h | 1 - libclc/generic/include/clc/math/native_sin.h | 1 - libclc/generic/include/clc/math/native_sqrt.h | 1 - libclc/generic/include/clc/math/sin.h | 6 - libclc/generic/include/clc/math/sqrt.h | 6 - .../generic/include/clc/math/unary_decl.inc | 1 - .../generic/include/clc/math/unary_intrin.inc | 18 - .../generic/include/clc/relational/select.h | 1 - .../clc/synchronization/cl_mem_fence_flags.h | 4 - libclc/generic/lib/SOURCES | 8 - libclc/generic/lib/geometric/cross.cl | 11 - libclc/generic/lib/geometric/dot.cl | 17 - libclc/generic/lib/geometric/length.cl | 4 - libclc/generic/lib/geometric/length.inc | 3 - libclc/generic/lib/geometric/normalize.cl | 4 - libclc/generic/lib/geometric/normalize.inc | 3 - libclc/generic/lib/integer/abs.cl | 4 - libclc/generic/lib/integer/abs.inc | 3 - libclc/generic/lib/integer/abs_diff.cl | 4 - libclc/generic/lib/integer/abs_diff.inc | 3 - libclc/generic/lib/integer/add_sat.cl | 52 - libclc/generic/lib/integer/add_sat.ll | 55 - libclc/generic/lib/integer/add_sat_impl.ll | 83 - .../include/clc/synchronization/barrier.h | 6 - .../include/clc/workitem/get_global_id.h | 8 - .../include/clc/workitem/get_global_size.h | 8 - .../include/clc/workitem/get_group_id.h | 8 - .../include/clc/workitem/get_local_id.h | 8 - .../include/clc/workitem/get_local_size.h | 8 - .../include/clc/workitem/get_num_groups.h | 8 - libclc/ptx-nvidiacl/lib/SOURCES | 0 libclc/ptx/lib/SOURCES | 1 - libclc/ptx/lib/integer/add_sat.ll | 55 - libclc/test/cos.cl | 3 - libclc/test/cross.cl | 3 - libclc/test/get_group_id.cl | 3 - libclc/utils/prepare-builtins.cpp | 81 - libclc/www/index.html | 55 - libcxx/CMakeLists.txt | 159 - libcxx/CREDITS.TXT | 49 - libcxx/LICENSE.TXT | 76 - libcxx/Makefile | 55 - libcxx/cmake/Modules/GetTriple.cmake | 53 - .../Modules/MacroEnsureOutOfSourceBuild.cmake | 18 - libcxx/cmake/config-ix.cmake | 38 - libcxx/include/__bit_reference | 1248 - libcxx/include/__config | 445 - libcxx/include/__debug | 191 - libcxx/include/__functional_03 | 2130 -- libcxx/include/__functional_base | 437 - libcxx/include/__functional_base_03 | 1087 - libcxx/include/__hash_table | 1920 - libcxx/include/__locale | 1426 - libcxx/include/__mutex_base | 439 - libcxx/include/__split_buffer | 654 - libcxx/include/__sso_allocator | 77 - libcxx/include/__std_stream | 317 - libcxx/include/__tree | 2293 -- libcxx/include/__tuple | 296 - libcxx/include/__tuple_03 | 27 - libcxx/include/__undef_min_max | 19 - libcxx/include/algorithm | 5401 --- libcxx/include/array | 338 - libcxx/include/atomic | 1515 - libcxx/include/bitset | 1050 - libcxx/include/cassert | 25 - libcxx/include/ccomplex | 29 - libcxx/include/cctype | 164 - libcxx/include/cerrno | 393 - libcxx/include/cfenv | 82 - libcxx/include/cfloat | 78 - libcxx/include/chrono | 875 - libcxx/include/cinttypes | 259 - libcxx/include/ciso646 | 25 - libcxx/include/climits | 48 - libcxx/include/clocale | 53 - libcxx/include/cmath | 1668 - libcxx/include/codecvt | 547 - libcxx/include/complex | 1520 - libcxx/include/complex.h | 35 - libcxx/include/condition_variable | 256 - libcxx/include/csetjmp | 52 - libcxx/include/csignal | 58 - libcxx/include/cstdarg | 48 - libcxx/include/cstdbool | 32 - libcxx/include/cstddef | 103 - libcxx/include/cstdint | 191 - libcxx/include/cstdio | 163 - libcxx/include/cstdlib | 150 - libcxx/include/cstring | 112 - libcxx/include/ctgmath | 29 - libcxx/include/ctime | 72 - libcxx/include/cwchar | 204 - libcxx/include/cwctype | 213 - libcxx/include/deque | 2844 -- libcxx/include/exception | 250 - libcxx/include/ext/__hash | 46 - libcxx/include/ext/hash_map | 1003 - libcxx/include/ext/hash_set | 657 - libcxx/include/forward_list | 1636 - libcxx/include/fstream | 1398 - libcxx/include/functional | 2020 -- libcxx/include/future | 2501 -- libcxx/include/initializer_list | 105 - libcxx/include/iomanip | 504 - libcxx/include/ios | 986 - libcxx/include/iosfwd | 194 - libcxx/include/iostream | 60 - libcxx/include/istream | 1712 - libcxx/include/iterator | 1805 - libcxx/include/limits | 621 - libcxx/include/list | 2275 -- libcxx/include/locale | 4524 --- libcxx/include/map | 1935 - libcxx/include/memory | 5294 --- libcxx/include/mutex | 564 - libcxx/include/new | 117 - libcxx/include/numeric | 197 - libcxx/include/ostream | 1295 - libcxx/include/queue | 715 - libcxx/include/random | 6625 ---- libcxx/include/ratio | 487 - libcxx/include/regex | 6414 ---- libcxx/include/scoped_allocator | 578 - libcxx/include/set | 1025 - libcxx/include/sstream | 888 - libcxx/include/stack | 290 - libcxx/include/stdexcept | 162 - libcxx/include/streambuf | 564 - libcxx/include/string | 3984 --- libcxx/include/strstream | 400 - .../include/support/solaris/floatingpoint.h | 5 - libcxx/include/support/solaris/wchar.h | 38 - libcxx/include/support/solaris/xlocale.h | 146 - libcxx/include/support/win32/limits_win32.h | 79 - libcxx/include/support/win32/locale_win32.h | 116 - libcxx/include/support/win32/math_win32.h | 113 - libcxx/include/support/win32/support.h | 115 - libcxx/include/system_error | 636 - libcxx/include/tgmath.h | 29 - libcxx/include/thread | 447 - libcxx/include/tuple | 1054 - libcxx/include/type_traits | 3121 -- libcxx/include/typeindex | 103 - libcxx/include/typeinfo | 124 - libcxx/include/unordered_map | 1847 - libcxx/include/unordered_set | 1144 - libcxx/include/utility | 587 - libcxx/include/valarray | 4775 --- libcxx/include/vector | 3171 -- libcxx/lib/CMakeLists.txt | 66 - libcxx/lib/buildit | 125 - libcxx/lib/libc++abi.exp | 159 - libcxx/lib/libc++abi2.exp | 310 - libcxx/lib/libc++sjlj-abi.exp | 159 - libcxx/lib/libc++unexp.exp | 19 - libcxx/lib/notweak.exp | 5 - libcxx/lib/weak.exp | 16 - libcxx/src/algorithm.cpp | 83 - libcxx/src/bind.cpp | 30 - libcxx/src/chrono.cpp | 128 - libcxx/src/condition_variable.cpp | 69 - libcxx/src/debug.cpp | 484 - libcxx/src/exception.cpp | 221 - libcxx/src/future.cpp | 285 - libcxx/src/hash.cpp | 560 - libcxx/src/ios.cpp | 455 - libcxx/src/iostream.cpp | 66 - libcxx/src/locale.cpp | 6017 ---- libcxx/src/memory.cpp | 165 - libcxx/src/mutex.cpp | 249 - libcxx/src/new.cpp | 196 - libcxx/src/random.cpp | 48 - libcxx/src/regex.cpp | 325 - libcxx/src/stdexcept.cpp | 187 - libcxx/src/string.cpp | 679 - libcxx/src/strstream.cpp | 327 - libcxx/src/support/solaris/README | 4 - libcxx/src/support/solaris/mbsnrtowcs.inc | 76 - libcxx/src/support/solaris/wcsnrtombs.inc | 93 - libcxx/src/support/solaris/xlocale.c | 245 - libcxx/src/support/win32/locale_win32.cpp | 94 - libcxx/src/support/win32/support.cpp | 70 - libcxx/src/system_error.cpp | 201 - libcxx/src/thread.cpp | 183 - libcxx/src/typeinfo.cpp | 53 - libcxx/src/utility.cpp | 17 - libcxx/src/valarray.cpp | 54 - libcxx/test/CMakeLists.txt | 44 - .../alg.c.library/tested_elsewhere.pass.cpp | 12 - .../alg.copy/copy.pass.cpp | 73 - .../alg.copy/copy_backward.pass.cpp | 51 - .../alg.copy/copy_if.pass.cpp | 80 - .../alg.copy/copy_n.pass.cpp | 73 - .../alg.fill/fill.pass.cpp | 59 - .../alg.fill/fill_n.pass.cpp | 59 - .../alg.generate/generate.pass.cpp | 47 - .../alg.generate/generate_n.pass.cpp | 47 - .../alg.move/move.pass.cpp | 134 - .../alg.move/move_backward.pass.cpp | 88 - .../alg.partitions/is_partitioned.pass.cpp | 58 - .../alg.partitions/partition.pass.cpp | 104 - .../alg.partitions/partition_copy.pass.cpp | 50 - .../alg.partitions/partition_point.pass.cpp | 76 - .../alg.partitions/stable_partition.pass.cpp | 314 - .../random_shuffle.pass.cpp | 30 - .../random_shuffle_rand.pass.cpp | 37 - .../random_shuffle_urng.pass.cpp | 31 - .../alg.remove/remove.pass.cpp | 83 - .../alg.remove/remove_copy.pass.cpp | 70 - .../alg.remove/remove_copy_if.pass.cpp | 73 - .../alg.remove/remove_if.pass.cpp | 92 - .../alg.replace/replace.pass.cpp | 44 - .../alg.replace/replace_copy.pass.cpp | 72 - .../alg.replace/replace_copy_if.pass.cpp | 74 - .../alg.replace/replace_if.pass.cpp | 45 - .../alg.reverse/reverse.pass.cpp | 60 - .../alg.reverse/reverse_copy.pass.cpp | 81 - .../alg.rotate/rotate.pass.cpp | 439 - .../alg.rotate/rotate_copy.pass.cpp | 134 - .../alg.swap/iter_swap.pass.cpp | 27 - .../alg.swap/swap_ranges.pass.cpp | 110 - .../alg.transform/binary_transform.pass.cpp | 217 - .../alg.transform/unary_transform.pass.cpp | 77 - .../alg.unique/unique.pass.cpp | 189 - .../alg.unique/unique_copy.pass.cpp | 125 - .../alg.unique/unique_copy_pred.pass.cpp | 152 - .../alg.unique/unique_pred.pass.cpp | 231 - .../nothing_to_do.pass.cpp | 12 - .../alg.adjacent.find/adjacent_find.pass.cpp | 35 - .../adjacent_find_pred.pass.cpp | 39 - .../alg.all_of/all_of.pass.cpp | 47 - .../alg.any_of/any_of.pass.cpp | 55 - .../alg.nonmodifying/alg.count/count.pass.cpp | 32 - .../alg.count/count_if.pass.cpp | 36 - .../alg.nonmodifying/alg.equal/equal.pass.cpp | 33 - .../alg.equal/equal_pred.pass.cpp | 37 - .../alg.find.end/find_end.pass.cpp | 57 - .../alg.find.end/find_end_pred.pass.cpp | 86 - .../alg.find.first.of/find_first_of.pass.cpp | 49 - .../find_first_of_pred.pass.cpp | 55 - .../alg.nonmodifying/alg.find/find.pass.cpp | 31 - .../alg.find/find_if.pass.cpp | 35 - .../alg.find/find_if_not.pass.cpp | 35 - .../alg.foreach/test.pass.cpp | 39 - .../is_permutation.pass.cpp | 325 - .../is_permutation_pred.pass.cpp | 364 - .../alg.none_of/none_of.pass.cpp | 55 - .../alg.search/search.pass.cpp | 72 - .../alg.search/search_pred.pass.cpp | 111 - .../mismatch/mismatch.pass.cpp | 34 - .../mismatch/mismatch_pred.pass.cpp | 39 - .../alg.nonmodifying/nothing_to_do.pass.cpp | 12 - .../binary.search/binary_search.pass.cpp | 63 - .../binary.search/binary_search_comp.pass.cpp | 64 - .../equal.range/equal_range.pass.cpp | 69 - .../equal.range/equal_range_comp.pass.cpp | 70 - .../lower.bound/lower_bound.pass.cpp | 64 - .../lower.bound/lower_bound_comp.pass.cpp | 65 - .../alg.binary.search/nothing_to_do.pass.cpp | 12 - .../upper.bound/upper_bound.pass.cpp | 64 - .../upper.bound/upper_bound_comp.pass.cpp | 65 - .../is.heap/is_heap.pass.cpp | 521 - .../is.heap/is_heap_comp.pass.cpp | 522 - .../is.heap/is_heap_until.pass.cpp | 521 - .../is.heap/is_heap_until_comp.pass.cpp | 522 - .../make.heap/make_heap.pass.cpp | 39 - .../make.heap/make_heap_comp.pass.cpp | 64 - .../nothing_to_do.pass.cpp | 12 - .../pop.heap/pop_heap.pass.cpp | 39 - .../pop.heap/pop_heap_comp.pass.cpp | 68 - .../push.heap/push_heap.pass.cpp | 38 - .../push.heap/push_heap_comp.pass.cpp | 66 - .../sort.heap/sort_heap.pass.cpp | 40 - .../sort.heap/sort_heap_comp.pass.cpp | 66 - .../lexicographical_compare.pass.cpp | 69 - .../lexicographical_compare_comp.pass.cpp | 73 - .../alg.merge/inplace_merge.pass.cpp | 79 - .../alg.merge/inplace_merge_comp.pass.cpp | 112 - .../alg.sorting/alg.merge/merge.pass.cpp | 222 - .../alg.sorting/alg.merge/merge_comp.pass.cpp | 227 - .../alg.sorting/alg.min.max/max.pass.cpp | 46 - .../alg.sorting/alg.min.max/max_comp.pass.cpp | 48 - .../alg.min.max/max_element.pass.cpp | 66 - .../alg.min.max/max_element_comp.pass.cpp | 67 - .../alg.min.max/max_init_list.pass.cpp | 35 - .../alg.min.max/max_init_list_comp.pass.cpp | 36 - .../alg.sorting/alg.min.max/min.pass.cpp | 46 - .../alg.sorting/alg.min.max/min_comp.pass.cpp | 48 - .../alg.min.max/min_element.pass.cpp | 66 - .../alg.min.max/min_element_comp.pass.cpp | 67 - .../alg.min.max/min_init_list.pass.cpp | 35 - .../alg.min.max/min_init_list_comp.pass.cpp | 36 - .../alg.sorting/alg.min.max/minmax.pass.cpp | 48 - .../alg.min.max/minmax_comp.pass.cpp | 50 - .../alg.min.max/minmax_element.pass.cpp | 83 - .../alg.min.max/minmax_element_comp.pass.cpp | 88 - .../alg.min.max/minmax_init_list.pass.cpp | 29 - .../minmax_init_list_comp.pass.cpp | 30 - .../alg.nth.element/nth_element.pass.cpp | 62 - .../alg.nth.element/nth_element_comp.pass.cpp | 85 - .../next_permutation.pass.cpp | 66 - .../next_permutation_comp.pass.cpp | 68 - .../prev_permutation.pass.cpp | 66 - .../prev_permutation_comp.pass.cpp | 68 - .../includes/includes.pass.cpp | 84 - .../includes/includes_comp.pass.cpp | 85 - .../alg.set.operations/nothing_to_do.pass.cpp | 12 - .../set.difference/set_difference.pass.cpp | 200 - .../set_difference_comp.pass.cpp | 202 - .../set_intersection.pass.cpp | 198 - .../set_intersection_comp.pass.cpp | 200 - .../set_symmetric_difference.pass.cpp | 199 - .../set_symmetric_difference_comp.pass.cpp | 203 - .../set.union/set_union.pass.cpp | 198 - .../set.union/set_union_comp.pass.cpp | 200 - .../alg.sort/is.sorted/is_sorted.pass.cpp | 183 - .../is.sorted/is_sorted_comp.pass.cpp | 184 - .../is.sorted/is_sorted_until.pass.cpp | 183 - .../is.sorted/is_sorted_until_comp.pass.cpp | 184 - .../alg.sort/nothing_to_do.pass.cpp | 12 - .../partial_sort_copy.pass.cpp | 86 - .../partial_sort_copy_comp.pass.cpp | 90 - .../partial.sort/partial_sort.pass.cpp | 63 - .../partial.sort/partial_sort_comp.pass.cpp | 87 - .../alg.sorting/alg.sort/sort/sort.pass.cpp | 150 - .../alg.sort/sort/sort_comp.pass.cpp | 57 - .../alg.sort/stable.sort/stable_sort.pass.cpp | 150 - .../stable.sort/stable_sort_comp.pass.cpp | 83 - .../alg.sorting/nothing_to_do.pass.cpp | 12 - .../algorithms.general/nothing_to_do.pass.cpp | 12 - libcxx/test/algorithms/iterators.h | 314 - libcxx/test/algorithms/version.pass.cpp | 20 - .../atomic_signal_fence.pass.cpp | 19 - .../atomic_thread_fence.pass.cpp | 19 - .../atomics.flag/atomic_flag_clear.pass.cpp | 34 - .../atomic_flag_clear_explicit.pass.cpp | 58 - .../atomic_flag_test_and_set.pass.cpp | 34 - ...atomic_flag_test_and_set_explicit.pass.cpp | 94 - .../test/atomics/atomics.flag/clear.pass.cpp | 70 - .../atomics/atomics.flag/copy_assign.fail.cpp | 24 - .../atomics/atomics.flag/copy_ctor.fail.cpp | 23 - .../copy_volatile_assign.fail.cpp | 24 - .../atomics/atomics.flag/default.pass.cpp | 22 - .../test/atomics/atomics.flag/init.pass.cpp | 23 - .../atomics.flag/test_and_set.pass.cpp | 106 - .../atomics.general/nothing_to_do.pass.cpp | 13 - .../atomics.lockfree/lockfree.pass.cpp | 50 - .../atomics.order/kill_dependency.pass.cpp | 21 - .../atomics.order/memory_order.pass.cpp | 31 - .../atomics.syn/nothing_to_do.pass.cpp | 13 - .../atomics.types.generic/address.pass.cpp | 126 - .../atomics.types.generic/bool.pass.cpp | 165 - .../cstdint_typedefs.pass.cpp | 66 - .../atomics.types.generic/integral.pass.cpp | 191 - .../integral_typedefs.pass.cpp | 48 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../atomic_compare_exchange_strong.pass.cpp | 84 - ..._compare_exchange_strong_explicit.pass.cpp | 91 - .../atomic_compare_exchange_weak.pass.cpp | 84 - ...ic_compare_exchange_weak_explicit.pass.cpp | 91 - .../atomic_exchange.pass.cpp | 69 - .../atomic_exchange_explicit.pass.cpp | 71 - .../atomic_fetch_add.pass.cpp | 107 - .../atomic_fetch_add_explicit.pass.cpp | 111 - .../atomic_fetch_and.pass.cpp | 61 - .../atomic_fetch_and_explicit.pass.cpp | 63 - .../atomic_fetch_or.pass.cpp | 61 - .../atomic_fetch_or_explicit.pass.cpp | 63 - .../atomic_fetch_sub.pass.cpp | 107 - .../atomic_fetch_sub_explicit.pass.cpp | 112 - .../atomic_fetch_xor.pass.cpp | 61 - .../atomic_fetch_xor_explicit.pass.cpp | 63 - .../atomic_init.pass.cpp | 67 - .../atomic_is_lock_free.pass.cpp | 59 - .../atomic_load.pass.cpp | 67 - .../atomic_load_explicit.pass.cpp | 67 - .../atomic_store.pass.cpp | 67 - .../atomic_store_explicit.pass.cpp | 67 - .../atomic_var_init.pass.cpp | 21 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - libcxx/test/atomics/version.pass.cpp | 20 - libcxx/test/containers/Copyable.h | 9 - libcxx/test/containers/DefaultOnly.h | 26 - libcxx/test/containers/Emplaceable.h | 45 - libcxx/test/containers/MoveOnly.h | 41 - libcxx/test/containers/NotConstructible.h | 30 - .../associative/map/map.access/at.pass.cpp | 86 - .../associative/map/map.access/empty.pass.cpp | 28 - .../map/map.access/index_key.pass.cpp | 44 - .../map/map.access/index_rv_key.pass.cpp | 38 - .../map/map.access/iterator.pass.cpp | 120 - .../map/map.access/max_size.pass.cpp | 24 - .../associative/map/map.access/size.pass.cpp | 36 - .../associative/map/map.cons/alloc.pass.cpp | 29 - .../map.cons/assign_initializer_list.pass.cpp | 45 - .../associative/map/map.cons/compare.pass.cpp | 28 - .../map/map.cons/compare_alloc.pass.cpp | 31 - .../associative/map/map.cons/copy.pass.cpp | 94 - .../map/map.cons/copy_alloc.pass.cpp | 56 - .../map/map.cons/copy_assign.pass.cpp | 94 - .../associative/map/map.cons/default.pass.cpp | 24 - .../map/map.cons/default_noexcept.pass.cpp | 53 - .../map/map.cons/default_recursive.pass.cpp | 25 - .../map/map.cons/dtor_noexcept.pass.cpp | 51 - .../map/map.cons/initializer_list.pass.cpp | 41 - .../initializer_list_compare.pass.cpp | 43 - .../initializer_list_compare_alloc.pass.cpp | 46 - .../map/map.cons/iter_iter.pass.cpp | 41 - .../map/map.cons/iter_iter_comp.pass.cpp | 45 - .../map.cons/iter_iter_comp_alloc.pass.cpp | 49 - .../associative/map/map.cons/move.pass.cpp | 72 - .../map/map.cons/move_alloc.pass.cpp | 144 - .../map/map.cons/move_assign.pass.cpp | 147 - .../map.cons/move_assign_noexcept.pass.cpp | 53 - .../map/map.cons/move_noexcept.pass.cpp | 51 - .../map/map.modifiers/clear.pass.cpp | 40 - .../map/map.modifiers/emplace.pass.cpp | 89 - .../map/map.modifiers/emplace_hint.pass.cpp | 82 - .../map/map.modifiers/erase_iter.pass.cpp | 127 - .../map.modifiers/erase_iter_iter.pass.cpp | 87 - .../map/map.modifiers/erase_key.pass.cpp | 146 - .../map/map.modifiers/insert_cv.pass.cpp | 53 - .../insert_initializer_list.pass.cpp | 43 - .../map/map.modifiers/insert_iter_cv.pass.cpp | 49 - .../map.modifiers/insert_iter_iter.pass.cpp | 49 - .../map/map.modifiers/insert_iter_rv.pass.cpp | 55 - .../map/map.modifiers/insert_rv.pass.cpp | 58 - .../associative/map/map.ops/count.pass.cpp | 56 - .../map/map.ops/equal_range.pass.cpp | 156 - .../associative/map/map.ops/find.pass.cpp | 90 - .../map/map.ops/lower_bound.pass.cpp | 122 - .../map/map.ops/upper_bound.pass.cpp | 122 - .../map/map.special/member_swap.pass.cpp | 107 - .../map/map.special/non_member_swap.pass.cpp | 179 - .../map/map.special/swap_noexcept.pass.cpp | 60 - .../containers/associative/map/types.pass.cpp | 48 - .../associative/map/version.pass.cpp | 20 - .../associative/multimap/empty.pass.cpp | 28 - .../associative/multimap/iterator.pass.cpp | 122 - .../associative/multimap/max_size.pass.cpp | 24 - .../multimap/multimap.cons/alloc.pass.cpp | 29 - .../assign_initializer_list.pass.cpp | 50 - .../multimap/multimap.cons/compare.pass.cpp | 28 - .../multimap.cons/compare_alloc.pass.cpp | 31 - .../multimap/multimap.cons/copy.pass.cpp | 76 - .../multimap.cons/copy_alloc.pass.cpp | 47 - .../multimap.cons/copy_assign.pass.cpp | 76 - .../multimap/multimap.cons/default.pass.cpp | 24 - .../multimap.cons/default_noexcept.pass.cpp | 53 - .../multimap.cons/dtor_noexcept.pass.cpp | 51 - .../multimap.cons/initializer_list.pass.cpp | 49 - .../initializer_list_compare.pass.cpp | 54 - .../initializer_list_compare_alloc.pass.cpp | 57 - .../multimap/multimap.cons/iter_iter.pass.cpp | 47 - .../multimap.cons/iter_iter_comp.pass.cpp | 52 - .../iter_iter_comp_alloc.pass.cpp | 55 - .../multimap/multimap.cons/move.pass.cpp | 78 - .../multimap.cons/move_alloc.pass.cpp | 144 - .../multimap.cons/move_assign.pass.cpp | 147 - .../move_assign_noexcept.pass.cpp | 53 - .../multimap.cons/move_noexcept.pass.cpp | 51 - .../multimap.modifiers/clear.pass.cpp | 40 - .../multimap.modifiers/emplace.pass.cpp | 82 - .../multimap.modifiers/emplace_hint.pass.cpp | 82 - .../multimap.modifiers/erase_iter.pass.cpp | 148 - .../erase_iter_iter.pass.cpp | 87 - .../multimap.modifiers/erase_key.pass.cpp | 84 - .../multimap.modifiers/insert_cv.pass.cpp | 49 - .../insert_initializer_list.pass.cpp | 53 - .../insert_iter_cv.pass.cpp | 49 - .../insert_iter_iter.pass.cpp | 61 - .../insert_iter_rv.pass.cpp | 55 - .../multimap.modifiers/insert_rv.pass.cpp | 54 - .../multimap/multimap.ops/count.pass.cpp | 53 - .../multimap.ops/equal_range.pass.cpp | 98 - .../multimap/multimap.ops/find.pass.cpp | 80 - .../multimap.ops/lower_bound.pass.cpp | 84 - .../multimap.ops/upper_bound.pass.cpp | 84 - .../multimap.special/member_swap.pass.cpp | 107 - .../multimap.special/non_member_swap.pass.cpp | 179 - .../multimap.special/swap_noexcept.pass.cpp | 60 - .../associative/multimap/size.pass.cpp | 36 - .../associative/multimap/types.pass.cpp | 48 - .../associative/multiset/clear.pass.cpp | 40 - .../associative/multiset/count.pass.cpp | 53 - .../associative/multiset/emplace.pass.cpp | 71 - .../multiset/emplace_hint.pass.cpp | 71 - .../associative/multiset/empty.pass.cpp | 28 - .../associative/multiset/equal_range.pass.cpp | 98 - .../associative/multiset/erase_iter.pass.cpp | 99 - .../multiset/erase_iter_iter.pass.cpp | 79 - .../associative/multiset/erase_key.pass.cpp | 73 - .../associative/multiset/find.pass.cpp | 90 - .../associative/multiset/insert_cv.pass.cpp | 45 - .../multiset/insert_initializer_list.pass.cpp | 38 - .../multiset/insert_iter_cv.pass.cpp | 45 - .../multiset/insert_iter_iter.pass.cpp | 53 - .../multiset/insert_iter_rv.pass.cpp | 49 - .../associative/multiset/insert_rv.pass.cpp | 49 - .../associative/multiset/iterator.pass.cpp | 114 - .../associative/multiset/lower_bound.pass.cpp | 84 - .../associative/multiset/max_size.pass.cpp | 24 - .../multiset/multiset.cons/alloc.pass.cpp | 29 - .../assign_initializer_list.pass.cpp | 36 - .../multiset/multiset.cons/compare.pass.cpp | 28 - .../multiset.cons/compare_alloc.pass.cpp | 31 - .../multiset/multiset.cons/copy.pass.cpp | 118 - .../multiset.cons/copy_alloc.pass.cpp | 68 - .../multiset.cons/copy_assign.pass.cpp | 118 - .../multiset/multiset.cons/default.pass.cpp | 24 - .../multiset.cons/default_noexcept.pass.cpp | 53 - .../multiset.cons/dtor_noexcept.pass.cpp | 51 - .../multiset.cons/initializer_list.pass.cpp | 35 - .../initializer_list_compare.pass.cpp | 38 - .../initializer_list_compare_alloc.pass.cpp | 41 - .../multiset/multiset.cons/iter_iter.pass.cpp | 50 - .../multiset.cons/iter_iter_alloc.pass.cpp | 58 - .../multiset.cons/iter_iter_comp.pass.cpp | 53 - .../multiset/multiset.cons/move.pass.cpp | 79 - .../multiset.cons/move_alloc.pass.cpp | 141 - .../multiset.cons/move_assign.pass.cpp | 144 - .../move_assign_noexcept.pass.cpp | 53 - .../multiset.cons/move_noexcept.pass.cpp | 51 - .../multiset.special/member_swap.pass.cpp | 107 - .../multiset.special/non_member_swap.pass.cpp | 177 - .../multiset.special/swap_noexcept.pass.cpp | 60 - .../associative/multiset/size.pass.cpp | 36 - .../associative/multiset/types.pass.cpp | 48 - .../associative/multiset/upper_bound.pass.cpp | 84 - .../containers/associative/set/clear.pass.cpp | 40 - .../containers/associative/set/count.pass.cpp | 56 - .../associative/set/emplace.pass.cpp | 77 - .../associative/set/emplace_hint.pass.cpp | 71 - .../containers/associative/set/empty.pass.cpp | 28 - .../associative/set/equal_range.pass.cpp | 156 - .../associative/set/erase_iter.pass.cpp | 99 - .../associative/set/erase_iter_iter.pass.cpp | 79 - .../associative/set/erase_key.pass.cpp | 110 - .../containers/associative/set/find.pass.cpp | 90 - .../associative/set/insert_cv.pass.cpp | 49 - .../set/insert_initializer_list.pass.cpp | 38 - .../associative/set/insert_iter_cv.pass.cpp | 45 - .../associative/set/insert_iter_iter.pass.cpp | 47 - .../associative/set/insert_iter_rv.pass.cpp | 49 - .../associative/set/insert_rv.pass.cpp | 53 - .../associative/set/iterator.pass.cpp | 112 - .../associative/set/lower_bound.pass.cpp | 122 - .../associative/set/max_size.pass.cpp | 24 - .../associative/set/set.cons/alloc.pass.cpp | 29 - .../set.cons/assign_initializer_list.pass.cpp | 36 - .../associative/set/set.cons/compare.pass.cpp | 28 - .../set/set.cons/compare_alloc.pass.cpp | 31 - .../associative/set/set.cons/copy.pass.cpp | 94 - .../set/set.cons/copy_alloc.pass.cpp | 56 - .../set/set.cons/copy_assign.pass.cpp | 94 - .../associative/set/set.cons/default.pass.cpp | 24 - .../set/set.cons/default_noexcept.pass.cpp | 53 - .../set/set.cons/dtor_noexcept.pass.cpp | 51 - .../set/set.cons/initializer_list.pass.cpp | 35 - .../initializer_list_compare.pass.cpp | 38 - .../initializer_list_compare_alloc.pass.cpp | 41 - .../set/set.cons/iter_iter.pass.cpp | 44 - .../set/set.cons/iter_iter_alloc.pass.cpp | 52 - .../set/set.cons/iter_iter_comp.pass.cpp | 47 - .../associative/set/set.cons/move.pass.cpp | 73 - .../set/set.cons/move_alloc.pass.cpp | 141 - .../set/set.cons/move_assign.pass.cpp | 144 - .../set.cons/move_assign_noexcept.pass.cpp | 53 - .../set/set.cons/move_noexcept.pass.cpp | 51 - .../set/set.special/member_swap.pass.cpp | 107 - .../set/set.special/non_member_swap.pass.cpp | 177 - .../set/set.special/swap_noexcept.pass.cpp | 60 - .../containers/associative/set/size.pass.cpp | 36 - .../containers/associative/set/types.pass.cpp | 48 - .../associative/set/upper_bound.pass.cpp | 122 - .../associative/set/version.pass.cpp | 20 - .../tree_balance_after_insert.pass.cpp | 1616 - .../associative/tree_left_rotate.pass.cpp | 98 - .../associative/tree_remove.pass.cpp | 1648 - .../associative/tree_right_rotate.pass.cpp | 98 - .../container.adaptors/nothing_to_do.pass.cpp | 12 - .../priqueue.cons.alloc/ctor_alloc.pass.cpp | 48 - .../ctor_comp_alloc.pass.cpp | 48 - .../ctor_comp_cont_alloc.pass.cpp | 62 - .../ctor_comp_rcont_alloc.pass.cpp | 61 - .../ctor_copy_alloc.pass.cpp | 58 - .../ctor_move_alloc.pass.cpp | 68 - .../priqueue.cons/assign_copy.pass.cpp | 35 - .../priqueue.cons/assign_move.pass.cpp | 42 - .../priqueue.cons/ctor_comp.pass.cpp | 27 - .../ctor_comp_container.pass.cpp | 33 - .../ctor_comp_rcontainer.pass.cpp | 40 - .../priqueue.cons/ctor_copy.pass.cpp | 34 - .../priqueue.cons/ctor_default.pass.cpp | 27 - .../priqueue.cons/ctor_iter_iter.pass.cpp | 25 - .../ctor_iter_iter_comp.pass.cpp | 26 - .../ctor_iter_iter_comp_cont.pass.cpp | 27 - .../ctor_iter_iter_comp_rcont.pass.cpp | 32 - .../priqueue.cons/ctor_move.pass.cpp | 41 - .../priqueue.cons/default_noexcept.pass.cpp | 31 - .../priqueue.cons/dtor_noexcept.pass.cpp | 27 - .../move_assign_noexcept.pass.cpp | 31 - .../priqueue.cons/move_noexcept.pass.cpp | 31 - .../priqueue.members/emplace.pass.cpp | 32 - .../priqueue.members/empty.pass.cpp | 27 - .../priqueue.members/pop.pass.cpp | 34 - .../priqueue.members/push.pass.cpp | 28 - .../priqueue.members/push_rvalue.pass.cpp | 32 - .../priqueue.members/size.pass.cpp | 27 - .../priqueue.members/swap.pass.cpp | 30 - .../priqueue.members/top.pass.cpp | 28 - .../priqueue.special/swap.pass.cpp | 32 - .../priqueue.special/swap_noexcept.pass.cpp | 32 - .../priority.queue/types.pass.cpp | 60 - .../queue.cons.alloc/ctor_alloc.pass.cpp | 38 - .../ctor_container_alloc.pass.cpp | 57 - .../ctor_queue_alloc.pass.cpp | 52 - .../ctor_rcontainer_alloc.pass.cpp | 59 - .../ctor_rqueue_alloc.pass.cpp | 60 - .../queue/queue.cons/ctor_container.pass.cpp | 37 - .../queue/queue.cons/ctor_copy.pass.cpp | 32 - .../queue/queue.cons/ctor_default.pass.cpp | 28 - .../queue/queue.cons/ctor_move.pass.cpp | 41 - .../queue/queue.cons/ctor_rcontainer.pass.cpp | 39 - .../queue.cons/default_noexcept.pass.cpp | 30 - .../queue/queue.cons/dtor_noexcept.pass.cpp | 27 - .../queue.cons/move_assign_noexcept.pass.cpp | 30 - .../queue/queue.cons/move_noexcept.pass.cpp | 30 - .../queue/queue.defn/assign_copy.pass.cpp | 33 - .../queue/queue.defn/assign_move.pass.cpp | 42 - .../queue/queue.defn/back.pass.cpp | 26 - .../queue/queue.defn/back_const.pass.cpp | 27 - .../queue/queue.defn/emplace.pass.cpp | 30 - .../queue/queue.defn/empty.pass.cpp | 25 - .../queue/queue.defn/front.pass.cpp | 26 - .../queue/queue.defn/front_const.pass.cpp | 27 - .../queue/queue.defn/pop.pass.cpp | 37 - .../queue/queue.defn/push.pass.cpp | 32 - .../queue/queue.defn/push_rv.pass.cpp | 36 - .../queue/queue.defn/size.pass.cpp | 23 - .../queue/queue.defn/swap.pass.cpp | 36 - .../queue/queue.defn/types.pass.cpp | 58 - .../queue/queue.ops/eq.pass.cpp | 40 - .../queue/queue.ops/lt.pass.cpp | 45 - .../queue/queue.special/swap.pass.cpp | 37 - .../queue.special/swap_noexcept.pass.cpp | 31 - .../container.adaptors/queue/version.pass.cpp | 20 - .../stack.cons.alloc/ctor_alloc.pass.cpp | 38 - .../ctor_container_alloc.pass.cpp | 57 - .../stack.cons.alloc/ctor_copy_alloc.pass.cpp | 52 - .../ctor_rcontainer_alloc.pass.cpp | 59 - .../ctor_rqueue_alloc.pass.cpp | 60 - .../stack/stack.cons/ctor_container.pass.cpp | 37 - .../stack/stack.cons/ctor_copy.pass.cpp | 32 - .../stack/stack.cons/ctor_default.pass.cpp | 28 - .../stack/stack.cons/ctor_move.pass.cpp | 41 - .../stack/stack.cons/ctor_rcontainer.pass.cpp | 39 - .../stack.cons/default_noexcept.pass.cpp | 30 - .../stack/stack.cons/dtor_noexcept.pass.cpp | 27 - .../stack.cons/move_assign_noexcept.pass.cpp | 30 - .../stack/stack.cons/move_noexcept.pass.cpp | 30 - .../stack/stack.defn/assign_copy.pass.cpp | 33 - .../stack/stack.defn/assign_move.pass.cpp | 42 - .../stack/stack.defn/emplace.pass.cpp | 29 - .../stack/stack.defn/empty.pass.cpp | 25 - .../stack/stack.defn/pop.pass.cpp | 34 - .../stack/stack.defn/push.pass.cpp | 29 - .../stack/stack.defn/push_rv.pass.cpp | 33 - .../stack/stack.defn/size.pass.cpp | 23 - .../stack/stack.defn/swap.pass.cpp | 36 - .../stack/stack.defn/top.pass.cpp | 26 - .../stack/stack.defn/top_const.pass.cpp | 27 - .../stack/stack.defn/types.pass.cpp | 59 - .../stack/stack.ops/eq.pass.cpp | 40 - .../stack/stack.ops/lt.pass.cpp | 45 - .../stack/stack.special/swap.pass.cpp | 37 - .../stack.special/swap_noexcept.pass.cpp | 31 - .../container.adaptors/stack/version.pass.cpp | 20 - .../nothing_to_do.pass.cpp | 12 - .../associative.reqmts/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../sequence.reqmts/nothing_to_do.pass.cpp | 12 - .../unord.req/nothing_to_do.pass.cpp | 12 - .../unord.req.except/nothing_to_do.pass.cpp | 12 - .../containers.general/nothing_to_do.pass.cpp | 12 - libcxx/test/containers/iterators.h | 251 - libcxx/test/containers/nothing_to_do.pass.cpp | 12 - .../array/array.cons/default.pass.cpp | 31 - .../array.cons/initializer_list.pass.cpp | 34 - .../sequences/array/array.data/data.pass.cpp | 34 - .../array/array.data/data_const.pass.cpp | 34 - .../sequences/array/array.fill/fill.pass.cpp | 36 - .../sequences/array/array.size/size.pass.cpp | 31 - .../array/array.special/swap.pass.cpp | 43 - .../sequences/array/array.swap/swap.pass.cpp | 43 - .../sequences/array/array.tuple/get.pass.cpp | 28 - .../array/array.tuple/get_const.pass.cpp | 27 - .../array/array.tuple/get_rv.pass.cpp | 29 - .../array/array.tuple/tuple_element.pass.cpp | 33 - .../array/array.tuple/tuple_size.pass.cpp | 28 - .../array.zero/tested_elsewhere.pass.cpp | 18 - .../containers/sequences/array/begin.pass.cpp | 32 - .../containers/sequences/array/types.pass.cpp | 62 - .../sequences/array/version.pass.cpp | 20 - .../deque/deque.capacity/access.pass.cpp | 68 - .../deque/deque.capacity/resize_size.pass.cpp | 71 - .../deque.capacity/resize_size_value.pass.cpp | 71 - .../deque.capacity/shrink_to_fit.pass.cpp | 62 - .../sequences/deque/deque.cons/alloc.pass.cpp | 33 - .../assign_initializer_list.pass.cpp | 28 - .../deque.cons/assign_iter_iter.pass.cpp | 93 - .../deque.cons/assign_size_value.pass.cpp | 71 - .../sequences/deque/deque.cons/copy.pass.cpp | 47 - .../deque/deque.cons/copy_alloc.pass.cpp | 42 - .../deque/deque.cons/default.pass.cpp | 32 - .../deque.cons/default_noexcept.pass.cpp | 50 - .../deque/deque.cons/dtor_noexcept.pass.cpp | 52 - .../deque.cons/initializer_list.pass.cpp | 27 - .../initializer_list_alloc.pass.cpp | 30 - .../deque/deque.cons/iter_iter.pass.cpp | 58 - .../deque/deque.cons/iter_iter_alloc.pass.cpp | 44 - .../sequences/deque/deque.cons/move.pass.cpp | 54 - .../deque/deque.cons/move_alloc.pass.cpp | 69 - .../deque/deque.cons/move_assign.pass.cpp | 72 - .../deque.cons/move_assign_noexcept.pass.cpp | 52 - .../deque/deque.cons/move_noexcept.pass.cpp | 50 - .../deque/deque.cons/op_equal.pass.cpp | 48 - .../op_equal_initializer_list.pass.cpp | 28 - .../sequences/deque/deque.cons/size.pass.cpp | 55 - .../deque/deque.cons/size_value.pass.cpp | 47 - .../deque.cons/size_value_alloc.pass.cpp | 46 - .../deque/deque.modifiers/emplace.pass.cpp | 99 - .../deque.modifiers/emplace_back.pass.cpp | 74 - .../deque.modifiers/emplace_front.pass.cpp | 74 - .../deque/deque.modifiers/erase_iter.pass.cpp | 76 - .../deque.modifiers/erase_iter_iter.pass.cpp | 80 - .../insert_iter_initializer_list.pass.cpp | 39 - .../deque.modifiers/insert_iter_iter.pass.cpp | 235 - .../deque.modifiers/insert_rvalue.pass.cpp | 105 - .../insert_size_value.pass.cpp | 141 - .../deque.modifiers/insert_value.pass.cpp | 124 - .../deque/deque.modifiers/pop_back.pass.cpp | 70 - .../deque/deque.modifiers/pop_front.pass.cpp | 70 - .../deque/deque.modifiers/push_back.pass.cpp | 59 - .../deque.modifiers/push_back_rvalue.pass.cpp | 67 - .../deque/deque.modifiers/push_front.pass.cpp | 69 - .../push_front_rvalue.pass.cpp | 77 - .../deque/deque.special/copy.pass.cpp | 75 - .../deque.special/copy_backward.pass.cpp | 74 - .../deque/deque.special/move.pass.cpp | 74 - .../deque.special/move_backward.pass.cpp | 74 - .../deque/deque.special/swap.pass.cpp | 86 - .../deque.special/swap_noexcept.pass.cpp | 60 - .../sequences/deque/iterators.pass.cpp | 32 - .../containers/sequences/deque/types.pass.cpp | 75 - .../sequences/deque/version.pass.cpp | 20 - .../forwardlist.access/front.pass.cpp | 39 - .../forwardlist.cons/alloc.fail.cpp | 30 - .../forwardlist.cons/alloc.pass.cpp | 30 - .../forwardlist.cons/assign_copy.pass.cpp | 119 - .../forwardlist.cons/assign_init.pass.cpp | 44 - .../forwardlist.cons/assign_move.pass.cpp | 162 - .../forwardlist.cons/assign_op_init.pass.cpp | 44 - .../forwardlist.cons/assign_range.pass.cpp | 49 - .../assign_size_value.pass.cpp | 42 - .../forwardlist.cons/copy.pass.cpp | 52 - .../forwardlist.cons/copy_alloc.pass.cpp | 50 - .../forwardlist.cons/default.pass.cpp | 25 - .../default_noexcept.pass.cpp | 50 - .../forwardlist.cons/dtor_noexcept.pass.cpp | 52 - .../forwardlist.cons/init.pass.cpp | 30 - .../forwardlist.cons/init_alloc.pass.cpp | 34 - .../forwardlist.cons/move.pass.cpp | 55 - .../forwardlist.cons/move_alloc.pass.cpp | 55 - .../move_assign_noexcept.pass.cpp | 52 - .../forwardlist.cons/move_noexcept.pass.cpp | 50 - .../forwardlist.cons/range.pass.cpp | 34 - .../forwardlist.cons/range_alloc.pass.cpp | 38 - .../forwardlist.cons/size.fail.cpp | 35 - .../forwardlist.cons/size.pass.cpp | 35 - .../forwardlist.cons/size_value.pass.cpp | 30 - .../size_value_alloc.pass.cpp | 34 - .../forwardlist.iter/before_begin.pass.cpp | 61 - .../forwardlist.iter/iterators.pass.cpp | 72 - .../forwardlist.modifiers/clear.pass.cpp | 40 - .../emplace_after.pass.cpp | 55 - .../emplace_front.pass.cpp | 35 - .../erase_after_many.pass.cpp | 85 - .../erase_after_one.pass.cpp | 56 - .../insert_after_const.pass.cpp | 51 - .../insert_after_init.pass.cpp | 46 - .../insert_after_range.pass.cpp | 50 - .../insert_after_rv.pass.cpp | 55 - .../insert_after_size_value.pass.cpp | 44 - .../forwardlist.modifiers/pop_front.pass.cpp | 48 - .../push_front_const.pass.cpp | 31 - .../push_front_rv.pass.cpp | 35 - .../resize_size.pass.cpp | 66 - .../resize_size_value.pass.cpp | 51 - .../forwardlist.ops/merge.pass.cpp | 32 - .../forwardlist.ops/merge_pred.pass.cpp | 33 - .../forwardlist.ops/remove.pass.cpp | 67 - .../forwardlist.ops/remove_if.pass.cpp | 72 - .../forwardlist.ops/reverse.pass.cpp | 37 - .../forwardlist/forwardlist.ops/sort.pass.cpp | 41 - .../forwardlist.ops/sort_pred.pass.cpp | 42 - .../splice_after_flist.pass.cpp | 53 - .../forwardlist.ops/splice_after_one.pass.cpp | 103 - .../splice_after_range.pass.cpp | 118 - .../forwardlist.ops/unique.pass.cpp | 68 - .../forwardlist.ops/unique_pred.pass.cpp | 73 - .../forwardlist.spec/equal.pass.cpp | 53 - .../forwardlist.spec/member_swap.pass.cpp | 178 - .../forwardlist.spec/non_member_swap.pass.cpp | 179 - .../forwardlist.spec/relational.pass.cpp | 58 - .../forwardlist.spec/swap_noexcept.pass.cpp | 60 - .../sequences/forwardlist/max_size.pass.cpp | 25 - .../sequences/forwardlist/types.pass.cpp | 41 - .../sequences/forwardlist/version.pass.cpp | 20 - .../sequences/list/iterators.pass.cpp | 72 - .../list/list.capacity/resize_size.pass.cpp | 49 - .../list.capacity/resize_size_value.pass.cpp | 35 - .../list/list.cons/assign_copy.pass.cpp | 34 - .../assign_initializer_list.pass.cpp | 29 - .../list/list.cons/assign_move.pass.cpp | 65 - .../sequences/list/list.cons/copy.pass.cpp | 40 - .../list/list.cons/copy_alloc.pass.cpp | 33 - .../sequences/list/list.cons/default.pass.cpp | 35 - .../list/list.cons/default_noexcept.pass.cpp | 50 - .../list.cons/default_stack_alloc.pass.cpp | 37 - .../list/list.cons/dtor_noexcept.pass.cpp | 52 - .../list/list.cons/initializer_list.pass.cpp | 28 - .../list.cons/initializer_list_alloc.pass.cpp | 31 - .../list/list.cons/input_iterator.pass.cpp | 53 - .../sequences/list/list.cons/move.pass.cpp | 49 - .../list/list.cons/move_alloc.pass.cpp | 62 - .../list.cons/move_assign_noexcept.pass.cpp | 52 - .../list/list.cons/move_noexcept.pass.cpp | 50 - .../op_equal_initializer_list.pass.cpp | 29 - .../list/list.cons/size_type.pass.cpp | 50 - .../list/list.cons/size_value_alloc.pass.cpp | 54 - .../list/list.modifiers/clear.pass.cpp | 23 - .../list/list.modifiers/emplace.pass.cpp | 47 - .../list/list.modifiers/emplace_back.pass.cpp | 47 - .../list.modifiers/emplace_front.pass.cpp | 47 - .../list/list.modifiers/erase_iter.pass.cpp | 38 - .../list.modifiers/erase_iter_iter.pass.cpp | 50 - .../insert_iter_initializer_list.pass.cpp | 40 - .../insert_iter_iter_iter.pass.cpp | 93 - .../insert_iter_rvalue.pass.cpp | 31 - .../insert_iter_size_value.pass.cpp | 57 - .../list.modifiers/insert_iter_value.pass.cpp | 59 - .../list/list.modifiers/pop_back.pass.cpp | 27 - .../list/list.modifiers/pop_front.pass.cpp | 27 - .../list/list.modifiers/push_back.pass.cpp | 24 - .../list.modifiers/push_back_rvalue.pass.cpp | 31 - .../list/list.modifiers/push_front.pass.cpp | 24 - .../list.modifiers/push_front_rvalue.pass.cpp | 31 - .../sequences/list/list.ops/merge.pass.cpp | 26 - .../list/list.ops/merge_comp.pass.cpp | 27 - .../sequences/list/list.ops/remove.pass.cpp | 24 - .../list/list.ops/remove_if.pass.cpp | 30 - .../sequences/list/list.ops/reverse.pass.cpp | 24 - .../sequences/list/list.ops/sort.pass.cpp | 24 - .../list/list.ops/sort_comp.pass.cpp | 25 - .../list/list.ops/splice_pos_list.pass.cpp | 400 - .../list.ops/splice_pos_list_iter.pass.cpp | 177 - .../splice_pos_list_iter_iter.pass.cpp | 117 - .../sequences/list/list.ops/unique.pass.cpp | 24 - .../list/list.ops/unique_pred.pass.cpp | 29 - .../sequences/list/list.special/swap.pass.cpp | 88 - .../list/list.special/swap_noexcept.pass.cpp | 60 - .../containers/sequences/list/types.pass.cpp | 36 - .../sequences/list/version.pass.cpp | 20 - .../sequences/nothing_to_do.pass.cpp | 12 - .../vector.bool/assign_copy.pass.cpp | 34 - .../assign_initializer_list.pass.cpp | 28 - .../vector.bool/assign_move.pass.cpp | 64 - .../sequences/vector.bool/capacity.pass.cpp | 30 - .../vector.bool/construct_default.pass.cpp | 46 - .../vector.bool/construct_iter_iter.pass.cpp | 40 - .../construct_iter_iter_alloc.pass.cpp | 42 - .../vector.bool/construct_size.pass.cpp | 33 - .../vector.bool/construct_size_value.pass.cpp | 32 - .../construct_size_value_alloc.pass.cpp | 34 - .../sequences/vector.bool/copy.pass.cpp | 51 - .../sequences/vector.bool/copy_alloc.pass.cpp | 48 - .../vector.bool/default_noexcept.pass.cpp | 49 - .../vector.bool/dtor_noexcept.pass.cpp | 51 - .../sequences/vector.bool/erase_iter.pass.cpp | 39 - .../vector.bool/erase_iter_iter.pass.cpp | 51 - .../vector.bool/initializer_list.pass.cpp | 27 - .../initializer_list_alloc.pass.cpp | 30 - .../insert_iter_initializer_list.pass.cpp | 39 - .../insert_iter_iter_iter.pass.cpp | 54 - .../insert_iter_size_value.pass.cpp | 33 - .../vector.bool/insert_iter_value.pass.cpp | 32 - .../sequences/vector.bool/iterators.pass.cpp | 59 - .../sequences/vector.bool/move.pass.cpp | 48 - .../sequences/vector.bool/move_alloc.pass.cpp | 61 - .../vector.bool/move_assign_noexcept.pass.cpp | 51 - .../vector.bool/move_noexcept.pass.cpp | 49 - .../op_equal_initializer_list.pass.cpp | 28 - .../sequences/vector.bool/push_back.pass.cpp | 32 - .../sequences/vector.bool/reserve.pass.cpp | 35 - .../vector.bool/resize_size.pass.cpp | 29 - .../vector.bool/resize_size_value.pass.cpp | 34 - .../vector.bool/shrink_to_fit.pass.cpp | 27 - .../sequences/vector.bool/swap.pass.cpp | 54 - .../vector.bool/swap_noexcept.pass.cpp | 59 - .../sequences/vector.bool/types.pass.cpp | 68 - .../vector.bool/vector_bool.pass.cpp | 35 - .../sequences/vector/iterators.pass.cpp | 72 - .../sequences/vector/types.pass.cpp | 75 - .../vector/vector.capacity/capacity.pass.cpp | 29 - .../vector/vector.capacity/reserve.pass.cpp | 45 - .../vector.capacity/resize_size.pass.cpp | 60 - .../resize_size_value.pass.cpp | 43 - .../vector.capacity/shrink_to_fit.pass.cpp | 41 - .../vector/vector.capacity/swap.pass.cpp | 28 - .../vector/vector.cons/assign_copy.pass.cpp | 34 - .../assign_initializer_list.pass.cpp | 28 - .../vector/vector.cons/assign_move.pass.cpp | 65 - .../vector.cons/construct_default.pass.cpp | 54 - .../vector.cons/construct_iter_iter.pass.cpp | 46 - .../construct_iter_iter_alloc.pass.cpp | 42 - .../vector.cons/construct_size.pass.cpp | 38 - .../vector.cons/construct_size_value.pass.cpp | 34 - .../construct_size_value_alloc.pass.cpp | 33 - .../vector/vector.cons/copy.pass.cpp | 50 - .../vector/vector.cons/copy_alloc.pass.cpp | 48 - .../vector.cons/default_noexcept.pass.cpp | 50 - .../vector/vector.cons/dtor_noexcept.pass.cpp | 52 - .../vector.cons/initializer_list.pass.cpp | 27 - .../initializer_list_alloc.pass.cpp | 30 - .../vector/vector.cons/move.pass.cpp | 49 - .../vector/vector.cons/move_alloc.pass.cpp | 62 - .../vector.cons/move_assign_noexcept.pass.cpp | 52 - .../vector/vector.cons/move_noexcept.pass.cpp | 50 - .../op_equal_initializer_list.pass.cpp | 28 - .../vector/vector.data/data.pass.cpp | 27 - .../vector/vector.data/data_const.pass.cpp | 27 - .../vector/vector.modifiers/emplace.pass.cpp | 106 - .../vector.modifiers/emplace_back.pass.cpp | 84 - .../vector.modifiers/erase_iter.pass.cpp | 38 - .../vector.modifiers/erase_iter_iter.pass.cpp | 50 - .../insert_iter_initializer_list.pass.cpp | 39 - .../insert_iter_iter_iter.pass.cpp | 86 - .../insert_iter_rvalue.pass.cpp | 47 - .../insert_iter_size_value.pass.cpp | 46 - .../insert_iter_value.pass.cpp | 44 - .../vector.modifiers/push_back.pass.cpp | 66 - .../push_back_rvalue.pass.cpp | 69 - .../vector/vector.special/swap.pass.cpp | 88 - .../vector.special/swap_noexcept.pass.cpp | 60 - .../sequences/vector/version.pass.cpp | 20 - libcxx/test/containers/stack_allocator.h | 52 - libcxx/test/containers/test_allocator.h | 112 - libcxx/test/containers/test_compare.h | 27 - libcxx/test/containers/test_hash.h | 23 - .../test/containers/unord/next_prime.pass.cpp | 49 - .../unord/unord.map/bucket.pass.cpp | 42 - .../unord/unord.map/bucket_count.pass.cpp | 49 - .../unord/unord.map/bucket_size.pass.cpp | 44 - .../containers/unord/unord.map/count.pass.cpp | 42 - .../containers/unord/unord.map/eq.pass.cpp | 92 - .../unord.map/equal_range_const.pass.cpp | 47 - .../unord.map/equal_range_non_const.pass.cpp | 47 - .../unord/unord.map/find_const.pass.cpp | 45 - .../unord/unord.map/find_non_const.pass.cpp | 45 - .../unord/unord.map/iterators.pass.cpp | 67 - .../unord/unord.map/load_factor.pass.cpp | 48 - .../unord/unord.map/local_iterators.pass.cpp | 221 - .../unord/unord.map/max_bucket_count.pass.cpp | 31 - .../unord/unord.map/max_load_factor.pass.cpp | 39 - .../unord/unord.map/max_size.pass.cpp | 27 - .../unord/unord.map/rehash.pass.cpp | 59 - .../unord/unord.map/reserve.pass.cpp | 59 - .../unord/unord.map/swap_member.pass.cpp | 389 - .../containers/unord/unord.map/types.pass.cpp | 51 - .../unord.map.cnstr/allocator.pass.cpp | 47 - .../unord.map.cnstr/assign_copy.pass.cpp | 119 - .../unord.map.cnstr/assign_init.pass.cpp | 62 - .../unord.map.cnstr/assign_move.pass.cpp | 168 - .../unord.map/unord.map.cnstr/copy.pass.cpp | 109 - .../unord.map.cnstr/copy_alloc.pass.cpp | 68 - .../unord.map.cnstr/default.pass.cpp | 47 - .../unord.map.cnstr/default_noexcept.pass.cpp | 70 - .../unord.map.cnstr/dtor_noexcept.pass.cpp | 67 - .../unord.map/unord.map.cnstr/init.pass.cpp | 62 - .../unord.map.cnstr/init_size.pass.cpp | 64 - .../unord.map.cnstr/init_size_hash.pass.cpp | 65 - .../init_size_hash_equal.pass.cpp | 67 - .../init_size_hash_equal_allocator.pass.cpp | 68 - .../unord.map/unord.map.cnstr/move.pass.cpp | 108 - .../unord.map.cnstr/move_alloc.pass.cpp | 113 - .../move_assign_noexcept.pass.cpp | 69 - .../unord.map.cnstr/move_noexcept.pass.cpp | 66 - .../unord.map/unord.map.cnstr/range.pass.cpp | 65 - .../unord.map.cnstr/range_size.pass.cpp | 67 - .../unord.map.cnstr/range_size_hash.pass.cpp | 69 - .../range_size_hash_equal.pass.cpp | 70 - .../range_size_hash_equal_allocator.pass.cpp | 72 - .../unord.map/unord.map.cnstr/size.fail.cpp | 47 - .../unord.map/unord.map.cnstr/size.pass.cpp | 47 - .../unord.map.cnstr/size_hash.pass.cpp | 49 - .../unord.map.cnstr/size_hash_equal.pass.cpp | 50 - .../size_hash_equal_allocator.pass.cpp | 51 - .../unord.map/unord.map.elem/at.pass.cpp | 78 - .../unord.map/unord.map.elem/index.pass.cpp | 68 - .../unord.map.swap/swap_noexcept.pass.cpp | 73 - .../unord.map.swap/swap_non_member.pass.cpp | 389 - .../unorder.map.modifiers/clear.pass.cpp | 40 - .../unorder.map.modifiers/emplace.pass.cpp | 50 - .../emplace_hint.pass.cpp | 48 - .../erase_const_iter.pass.cpp | 44 - .../unorder.map.modifiers/erase_key.pass.cpp | 80 - .../erase_range.pass.cpp | 59 - .../insert_const_lvalue.pass.cpp | 52 - .../insert_hint_const_lvalue.pass.cpp | 49 - .../insert_hint_rvalue.pass.cpp | 81 - .../insert_init.pass.cpp | 48 - .../insert_range.pass.cpp | 47 - .../insert_rvalue.pass.cpp | 87 - .../unord/unord.map/version.pass.cpp | 20 - .../unord/unord.multimap/bucket.pass.cpp | 42 - .../unord.multimap/bucket_count.pass.cpp | 49 - .../unord/unord.multimap/bucket_size.pass.cpp | 46 - .../unord/unord.multimap/count.pass.cpp | 45 - .../unord/unord.multimap/eq.pass.cpp | 101 - .../unord.multimap/equal_range_const.pass.cpp | 58 - .../equal_range_non_const.pass.cpp | 58 - .../unord/unord.multimap/find_const.pass.cpp | 45 - .../unord.multimap/find_non_const.pass.cpp | 45 - .../unord/unord.multimap/iterators.fail.cpp | 69 - .../unord/unord.multimap/iterators.pass.cpp | 70 - .../unord/unord.multimap/load_factor.pass.cpp | 48 - .../unord.multimap/local_iterators.fail.cpp | 286 - .../unord.multimap/local_iterators.pass.cpp | 285 - .../unord.multimap/max_bucket_count.pass.cpp | 31 - .../unord.multimap/max_load_factor.pass.cpp | 39 - .../unord/unord.multimap/max_size.pass.cpp | 27 - .../unord/unord.multimap/rehash.pass.cpp | 88 - .../unord/unord.multimap/reserve.pass.cpp | 61 - .../unord/unord.multimap/swap_member.pass.cpp | 397 - .../unord/unord.multimap/types.pass.cpp | 51 - .../unord.multimap.cnstr/allocator.pass.cpp | 47 - .../unord.multimap.cnstr/assign_copy.pass.cpp | 147 - .../unord.multimap.cnstr/assign_init.pass.cpp | 87 - .../unord.multimap.cnstr/assign_move.pass.cpp | 226 - .../unord.multimap.cnstr/copy.pass.cpp | 137 - .../unord.multimap.cnstr/copy_alloc.pass.cpp | 82 - .../unord.multimap.cnstr/default.pass.cpp | 47 - .../default_noexcept.pass.cpp | 70 - .../dtor_noexcept.pass.cpp | 67 - .../unord.multimap.cnstr/init.pass.cpp | 84 - .../unord.multimap.cnstr/init_size.pass.cpp | 86 - .../init_size_hash.pass.cpp | 87 - .../init_size_hash_equal.pass.cpp | 89 - .../init_size_hash_equal_allocator.pass.cpp | 90 - .../unord.multimap.cnstr/move.pass.cpp | 130 - .../unord.multimap.cnstr/move_alloc.pass.cpp | 161 - .../move_assign_noexcept.pass.cpp | 69 - .../move_noexcept.pass.cpp | 66 - .../unord.multimap.cnstr/range.pass.cpp | 87 - .../unord.multimap.cnstr/range_size.pass.cpp | 89 - .../range_size_hash.pass.cpp | 91 - .../range_size_hash_equal.pass.cpp | 92 - .../range_size_hash_equal_allocator.pass.cpp | 94 - .../unord.multimap.cnstr/size.fail.cpp | 47 - .../unord.multimap.cnstr/size.pass.cpp | 47 - .../unord.multimap.cnstr/size_hash.pass.cpp | 49 - .../size_hash_equal.pass.cpp | 50 - .../size_hash_equal_allocator.pass.cpp | 51 - .../unord.multimap.modifiers/clear.pass.cpp | 40 - .../unord.multimap.modifiers/emplace.pass.cpp | 47 - .../emplace_hint.pass.cpp | 56 - .../erase_const_iter.pass.cpp | 68 - .../erase_key.pass.cpp | 185 - .../erase_range.pass.cpp | 99 - .../insert_const_lvalue.pass.cpp | 48 - .../insert_hint_const_lvalue.pass.cpp | 49 - .../insert_hint_rvalue.pass.cpp | 81 - .../insert_init.pass.cpp | 73 - .../insert_range.pass.cpp | 72 - .../insert_rvalue.pass.cpp | 79 - .../swap_noexcept.pass.cpp | 73 - .../swap_non_member.pass.cpp | 397 - .../unord/unord.multiset/bucket.pass.cpp | 41 - .../unord.multiset/bucket_count.pass.cpp | 48 - .../unord/unord.multiset/bucket_size.pass.cpp | 45 - .../unord/unord.multiset/clear.pass.cpp | 39 - .../unord/unord.multiset/count.pass.cpp | 44 - .../unord/unord.multiset/emplace.pass.cpp | 44 - .../unord.multiset/emplace_hint.pass.cpp | 45 - .../unord/unord.multiset/eq.pass.cpp | 100 - .../unord.multiset/equal_range_const.pass.cpp | 54 - .../equal_range_non_const.pass.cpp | 54 - .../unord.multiset/erase_const_iter.pass.cpp | 44 - .../unord/unord.multiset/erase_key.pass.cpp | 80 - .../unord/unord.multiset/erase_range.pass.cpp | 56 - .../unord/unord.multiset/find_const.pass.cpp | 43 - .../unord.multiset/find_non_const.pass.cpp | 43 - .../insert_const_lvalue.pass.cpp | 44 - .../insert_hint_const_lvalue.pass.cpp | 45 - .../insert_hint_rvalue.pass.cpp | 71 - .../unord/unord.multiset/insert_init.pass.cpp | 47 - .../unord.multiset/insert_range.pass.cpp | 46 - .../unord.multiset/insert_rvalue.pass.cpp | 69 - .../unord/unord.multiset/iterators.fail.cpp | 67 - .../unord/unord.multiset/iterators.pass.cpp | 66 - .../unord/unord.multiset/load_factor.pass.cpp | 47 - .../unord.multiset/local_iterators.fail.cpp | 261 - .../unord.multiset/local_iterators.pass.cpp | 260 - .../unord.multiset/max_bucket_count.pass.cpp | 28 - .../unord.multiset/max_load_factor.pass.cpp | 38 - .../unord/unord.multiset/max_size.pass.cpp | 27 - .../unord/unord.multiset/rehash.pass.cpp | 58 - .../unord/unord.multiset/reserve.pass.cpp | 58 - .../unord/unord.multiset/swap_member.pass.cpp | 388 - .../unord/unord.multiset/types.pass.cpp | 49 - .../unord.multiset.cnstr/allocator.pass.cpp | 45 - .../unord.multiset.cnstr/assign_copy.pass.cpp | 134 - .../unord.multiset.cnstr/assign_init.pass.cpp | 62 - .../unord.multiset.cnstr/assign_move.pass.cpp | 173 - .../unord.multiset.cnstr/copy.pass.cpp | 122 - .../unord.multiset.cnstr/copy_alloc.pass.cpp | 74 - .../unord.multiset.cnstr/default.pass.cpp | 45 - .../default_noexcept.pass.cpp | 70 - .../dtor_noexcept.pass.cpp | 67 - .../unord.multiset.cnstr/init.pass.cpp | 60 - .../unord.multiset.cnstr/init_size.pass.cpp | 62 - .../init_size_hash.pass.cpp | 64 - .../init_size_hash_equal.pass.cpp | 65 - .../init_size_hash_equal_allocator.pass.cpp | 66 - .../unord.multiset.cnstr/move.pass.cpp | 105 - .../unord.multiset.cnstr/move_alloc.pass.cpp | 120 - .../move_assign_noexcept.pass.cpp | 69 - .../move_noexcept.pass.cpp | 66 - .../unord.multiset.cnstr/range.pass.cpp | 62 - .../unord.multiset.cnstr/range_size.pass.cpp | 64 - .../range_size_hash.pass.cpp | 66 - .../range_size_hash_equal.pass.cpp | 67 - .../range_size_hash_equal_allocator.pass.cpp | 69 - .../unord.multiset.cnstr/size.fail.cpp | 45 - .../unord.multiset.cnstr/size.pass.cpp | 45 - .../unord.multiset.cnstr/size_hash.pass.cpp | 47 - .../size_hash_equal.pass.cpp | 48 - .../size_hash_equal_allocator.pass.cpp | 49 - .../swap_noexcept.pass.cpp | 73 - .../swap_non_member.pass.cpp | 388 - .../unord/unord.set/bucket.pass.cpp | 41 - .../unord/unord.set/bucket_count.pass.cpp | 48 - .../unord/unord.set/bucket_size.pass.cpp | 43 - .../containers/unord/unord.set/clear.pass.cpp | 39 - .../containers/unord/unord.set/count.pass.cpp | 44 - .../unord/unord.set/emplace.pass.cpp | 47 - .../unord/unord.set/emplace_hint.pass.cpp | 45 - .../containers/unord/unord.set/eq.pass.cpp | 91 - .../unord.set/equal_range_const.pass.cpp | 50 - .../unord.set/equal_range_non_const.pass.cpp | 50 - .../unord/unord.set/erase_const_iter.pass.cpp | 43 - .../unord/unord.set/erase_key.pass.cpp | 80 - .../unord/unord.set/erase_range.pass.cpp | 56 - .../unord/unord.set/find_const.pass.cpp | 43 - .../unord/unord.set/find_non_const.pass.cpp | 43 - .../unord.set/insert_const_lvalue.pass.cpp | 48 - .../insert_hint_const_lvalue.pass.cpp | 45 - .../unord.set/insert_hint_rvalue.pass.cpp | 71 - .../unord/unord.set/insert_init.pass.cpp | 47 - .../unord/unord.set/insert_range.pass.cpp | 46 - .../unord/unord.set/insert_rvalue.pass.cpp | 77 - .../unord/unord.set/iterators.fail.cpp | 67 - .../unord/unord.set/iterators.pass.cpp | 66 - .../unord/unord.set/load_factor.pass.cpp | 47 - .../unord/unord.set/local_iterators.fail.cpp | 261 - .../unord/unord.set/local_iterators.pass.cpp | 204 - .../unord/unord.set/max_bucket_count.pass.cpp | 28 - .../unord/unord.set/max_load_factor.pass.cpp | 38 - .../unord/unord.set/max_size.pass.cpp | 27 - .../unord/unord.set/rehash.pass.cpp | 58 - .../unord/unord.set/reserve.pass.cpp | 58 - .../unord/unord.set/swap_member.pass.cpp | 388 - .../containers/unord/unord.set/types.pass.cpp | 49 - .../unord.set.cnstr/allocator.pass.cpp | 45 - .../unord.set.cnstr/assign_copy.pass.cpp | 118 - .../unord.set.cnstr/assign_init.pass.cpp | 62 - .../unord.set.cnstr/assign_move.pass.cpp | 165 - .../unord.set/unord.set.cnstr/copy.pass.cpp | 106 - .../unord.set.cnstr/copy_alloc.pass.cpp | 66 - .../unord.set.cnstr/default.pass.cpp | 45 - .../unord.set.cnstr/default_noexcept.pass.cpp | 70 - .../unord.set.cnstr/dtor_noexcept.pass.cpp | 67 - .../unord.set/unord.set.cnstr/init.pass.cpp | 60 - .../unord.set.cnstr/init_size.pass.cpp | 62 - .../unord.set.cnstr/init_size_hash.pass.cpp | 64 - .../init_size_hash_equal.pass.cpp | 65 - .../init_size_hash_equal_allocator.pass.cpp | 66 - .../unord.set/unord.set.cnstr/move.pass.cpp | 105 - .../unord.set.cnstr/move_alloc.pass.cpp | 112 - .../move_assign_noexcept.pass.cpp | 69 - .../unord.set.cnstr/move_noexcept.pass.cpp | 66 - .../unord.set/unord.set.cnstr/range.pass.cpp | 62 - .../unord.set.cnstr/range_size.pass.cpp | 64 - .../unord.set.cnstr/range_size_hash.pass.cpp | 66 - .../range_size_hash_equal.pass.cpp | 67 - .../range_size_hash_equal_allocator.pass.cpp | 69 - .../unord.set/unord.set.cnstr/size.fail.cpp | 45 - .../unord.set/unord.set.cnstr/size.pass.cpp | 45 - .../unord.set.cnstr/size_hash.pass.cpp | 47 - .../unord.set.cnstr/size_hash_equal.pass.cpp | 48 - .../size_hash_equal_allocator.pass.cpp | 49 - .../unord.set.swap/swap_noexcept.pass.cpp | 73 - .../unord.set.swap/swap_non_member.pass.cpp | 388 - .../unord/unord.set/version.pass.cpp | 20 - libcxx/test/depr/depr.auto.ptr/auto.ptr/A.h | 30 - libcxx/test/depr/depr.auto.ptr/auto.ptr/AB.h | 41 - .../auto.ptr.cons/assignment.fail.cpp | 44 - .../auto.ptr.cons/assignment.pass.cpp | 44 - .../auto.ptr/auto.ptr.cons/convert.fail.cpp | 40 - .../auto.ptr/auto.ptr.cons/convert.pass.cpp | 40 - .../auto.ptr.cons/convert_assignment.fail.cpp | 47 - .../auto.ptr.cons/convert_assignment.pass.cpp | 47 - .../auto.ptr/auto.ptr.cons/copy.fail.cpp | 38 - .../auto.ptr/auto.ptr.cons/copy.pass.cpp | 38 - .../auto.ptr/auto.ptr.cons/explicit.fail.cpp | 40 - .../auto.ptr/auto.ptr.cons/pointer.pass.cpp | 40 - .../assign_from_auto_ptr_ref.pass.cpp | 40 - .../convert_from_auto_ptr_ref.pass.cpp | 39 - .../convert_to_auto_ptr.pass.cpp | 36 - .../convert_to_auto_ptr_ref.pass.cpp | 33 - .../auto.ptr/auto.ptr.members/arrow.pass.cpp | 37 - .../auto.ptr/auto.ptr.members/deref.pass.cpp | 37 - .../auto.ptr.members/release.pass.cpp | 38 - .../auto.ptr/auto.ptr.members/reset.pass.cpp | 54 - .../auto.ptr/element_type.pass.cpp | 36 - .../depr/depr.auto.ptr/nothing_to_do.pass.cpp | 12 - .../depr/depr.c.headers/assert_h.pass.cpp | 20 - .../test/depr/depr.c.headers/ciso646.pass.cpp | 20 - .../depr/depr.c.headers/complex.h.pass.cpp | 21 - .../test/depr/depr.c.headers/ctype_h.pass.cpp | 103 - .../test/depr/depr.c.headers/errno_h.pass.cpp | 33 - .../test/depr/depr.c.headers/fenv_h.pass.cpp | 74 - .../test/depr/depr.c.headers/float_h.pass.cpp | 140 - .../depr/depr.c.headers/inttypes_h.pass.cpp | 643 - .../depr/depr.c.headers/iso646_h.pass.cpp | 17 - .../depr/depr.c.headers/limits_h.pass.cpp | 92 - .../depr/depr.c.headers/locale_h.pass.cpp | 48 - .../test/depr/depr.c.headers/math_h.pass.cpp | 681 - .../depr/depr.c.headers/setjmp_h.pass.cpp | 20 - .../depr/depr.c.headers/signal_h.pass.cpp | 57 - .../depr/depr.c.headers/stdarg_h.pass.cpp | 33 - .../depr/depr.c.headers/stdbool_h.pass.cpp | 32 - .../depr/depr.c.headers/stddef_h.pass.cpp | 37 - .../depr/depr.c.headers/stdint_h.pass.cpp | 290 - .../test/depr/depr.c.headers/stdio_h.pass.cpp | 136 - .../depr/depr.c.headers/stdlib_h.pass.cpp | 82 - .../depr/depr.c.headers/string_h.pass.cpp | 48 - .../depr/depr.c.headers/tgmath_h.pass.cpp | 22 - .../test/depr/depr.c.headers/time_h.pass.cpp | 40 - .../test/depr/depr.c.headers/uchar_h.pass.cpp | 16 - .../test/depr/depr.c.headers/wchar_h.pass.cpp | 104 - .../depr/depr.c.headers/wctype_h.pass.cpp | 114 - .../pointer_to_binary_function.pass.cpp | 26 - .../pointer_to_unary_function.pass.cpp | 26 - .../ptr_fun1.pass.cpp | 25 - .../ptr_fun2.pass.cpp | 25 - .../const_mem_fun.pass.cpp | 31 - .../const_mem_fun1.pass.cpp | 31 - .../const_mem_fun1_ref_t.pass.cpp | 33 - .../const_mem_fun1_t.pass.cpp | 33 - .../const_mem_fun_ref.pass.cpp | 31 - .../const_mem_fun_ref1.pass.cpp | 31 - .../const_mem_fun_ref_t.pass.cpp | 33 - .../const_mem_fun_t.pass.cpp | 33 - .../mem_fun.pass.cpp | 31 - .../mem_fun1.pass.cpp | 31 - .../mem_fun1_ref_t.pass.cpp | 33 - .../mem_fun1_t.pass.cpp | 33 - .../mem_fun_ref.pass.cpp | 31 - .../mem_fun_ref1.pass.cpp | 31 - .../mem_fun_ref_t.pass.cpp | 33 - .../mem_fun_t.pass.cpp | 33 - .../depr.adaptors/nothing_to_do.pass.cpp | 12 - .../depr.base/binary_function.pass.cpp | 28 - .../depr.base/unary_function.pass.cpp | 26 - .../nothing_to_do.pass.cpp | 12 - .../depr/depr.ios.members/io_state.pass.cpp | 25 - .../depr/depr.ios.members/open_mode.pass.cpp | 25 - .../depr/depr.ios.members/seek_dir.pass.cpp | 25 - .../depr/depr.ios.members/streamoff.pass.cpp | 25 - .../depr/depr.ios.members/streampos.pass.cpp | 24 - .../depr.lib.bind.1st/bind1st.pass.cpp | 24 - .../depr.lib.bind.2nd/bind2nd.pass.cpp | 24 - .../depr.lib.binder.1st/binder1st.pass.cpp | 58 - .../depr.lib.binder.2nd/binder2nd.pass.cpp | 58 - .../depr.lib.binders/nothing_to_do.pass.cpp | 12 - libcxx/test/depr/depr.lib.binders/test_func.h | 33 - .../depr.istrstream.cons/ccp.pass.cpp | 43 - .../depr.istrstream.cons/ccp_size.pass.cpp | 43 - .../depr.istrstream.cons/cp.pass.cpp | 43 - .../depr.istrstream.cons/cp_size.pass.cpp | 43 - .../depr.istrstream.members/rdbuf.pass.cpp | 27 - .../depr.istrstream.members/str.pass.cpp | 26 - .../depr.istrstream/types.pass.cpp | 23 - .../cp_size_mode.pass.cpp | 41 - .../depr.ostrstream.cons/default.pass.cpp | 27 - .../depr.ostrstream.members/freeze.pass.cpp | 33 - .../depr.ostrstream.members/pcount.pass.cpp | 27 - .../depr.ostrstream.members/rdbuf.pass.cpp | 28 - .../depr.ostrstream.members/str.pass.cpp | 26 - .../depr.ostrstream/types.pass.cpp | 23 - .../depr.strstream.cons/cp_size_mode.pass.cpp | 59 - .../depr.strstream.cons/default.pass.cpp | 34 - .../depr.strstream.dest/rdbuf.pass.cpp | 28 - .../depr.strstream.oper/freeze.pass.cpp | 33 - .../depr.strstream.oper/pcount.pass.cpp | 27 - .../depr.strstream.oper/str.pass.cpp | 26 - .../depr.strstream/types.pass.cpp | 32 - .../depr.strstreambuf.cons/ccp_size.pass.cpp | 40 - .../cp_size_cp.pass.cpp | 96 - .../depr.strstreambuf.cons/cscp_size.pass.cpp | 40 - .../depr.strstreambuf.cons/cucp_size.pass.cpp | 40 - .../custom_alloc.pass.cpp | 51 - .../depr.strstreambuf.cons/default.pass.cpp | 31 - .../scp_size_scp.pass.cpp | 96 - .../ucp_size_ucp.pass.cpp | 96 - .../depr.strstreambuf.members/freeze.pass.cpp | 28 - .../depr.strstreambuf.members/pcount.pass.cpp | 31 - .../depr.strstreambuf.members/str.pass.cpp | 27 - .../overflow.pass.cpp | 47 - .../pbackfail.pass.cpp | 62 - .../seekoff.pass.cpp | 57 - .../seekpos.pass.cpp | 39 - .../setbuf.pass.cpp | 27 - .../underflow.pass.cpp | 51 - .../depr.strstreambuf/types.pass.cpp | 21 - .../depr/depr.str.strstreams/version.pass.cpp | 20 - .../nothing_to_do.pass.cpp | 12 - .../set.unexpected/get_unexpected.pass.cpp | 39 - .../set.unexpected/set_unexpected.pass.cpp | 35 - .../unexpected_handler.pass.cpp | 19 - .../unexpected/unexpected.pass.cpp | 26 - libcxx/test/depr/nothing_to_do.pass.cpp | 12 - .../diagnostics/assertions/cassert.pass.cpp | 24 - .../nothing_to_do.pass.cpp | 12 - libcxx/test/diagnostics/errno/cerrno.pass.cpp | 349 - .../test/diagnostics/nothing_to_do.pass.cpp | 12 - .../domain.error/domain_error.pass.cpp | 42 - .../invalid_argument.pass.cpp | 42 - .../length.error/length_error.pass.cpp | 42 - .../logic.error/logic_error.pass.cpp | 42 - .../out.of.range/out_of_range.pass.cpp | 42 - .../overflow.error/overflow_error.pass.cpp | 42 - .../range.error/range_error.pass.cpp | 42 - .../runtime.error/runtime_error.pass.cpp | 42 - .../underflow.error/underflow_error.pass.cpp | 42 - .../std.exceptions/version.pass.cpp | 20 - libcxx/test/diagnostics/syserr/errc.pass.cpp | 104 - .../eq_error_code_error_code.pass.cpp | 106 - .../syserr.errcat/nothing_to_do.pass.cpp | 12 - .../syserr.errcat.derived/message.pass.cpp | 34 - .../syserr.errcat.nonvirtuals/eq.pass.cpp | 26 - .../syserr.errcat.nonvirtuals/lt.pass.cpp | 26 - .../syserr.errcat.nonvirtuals/neq.pass.cpp | 26 - .../generic_category.pass.cpp | 25 - .../system_category.pass.cpp | 29 - .../error_category.pass.cpp | 19 - .../default_error_condition.pass.cpp | 25 - .../equivalent_error_code_int.pass.cpp | 24 - .../equivalent_int_error_condition.pass.cpp | 25 - .../syserr.errcode/nothing_to_do.pass.cpp | 12 - .../ErrorCodeEnum.pass.cpp | 44 - .../default.pass.cpp | 24 - .../int_error_category.pass.cpp | 31 - .../ErrorCodeEnum.pass.cpp | 45 - .../syserr.errcode.modifiers/assign.pass.cpp | 33 - .../syserr.errcode.modifiers/clear.pass.cpp | 30 - .../syserr.errcode.nonmembers/lt.pass.cpp | 27 - .../make_error_code.pass.cpp | 26 - .../stream_inserter.pass.cpp | 27 - .../syserr.errcode.observers/bool.pass.cpp | 30 - .../category.pass.cpp | 23 - .../default_error_condition.pass.cpp | 31 - .../syserr.errcode.observers/message.pass.cpp | 24 - .../syserr.errcode.observers/value.pass.cpp | 23 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../ErrorConditionEnum.pass.cpp | 26 - .../default.pass.cpp | 24 - .../int_error_category.pass.cpp | 31 - .../ErrorConditionEnum.pass.cpp | 27 - .../assign.pass.cpp | 33 - .../clear.pass.cpp | 30 - .../lt.pass.cpp | 27 - .../make_error_condition.pass.cpp | 26 - .../bool.pass.cpp | 30 - .../category.pass.cpp | 23 - .../message.pass.cpp | 24 - .../value.pass.cpp | 23 - .../nothing_to_do.pass.cpp | 12 - .../syserr/syserr.hash/error_code.pass.cpp | 42 - .../syserr.syserr/nothing_to_do.pass.cpp | 12 - .../ctor_error_code.pass.cpp | 29 - ...tor_error_code_const_char_pointer.pass.cpp | 30 - .../ctor_error_code_string.pass.cpp | 30 - .../ctor_int_error_category.pass.cpp | 29 - ...error_category_const_char_pointer.pass.cpp | 31 - .../ctor_int_error_category_string.pass.cpp | 31 - .../nothing_to_do.pass.cpp | 12 - .../test/diagnostics/syserr/version.pass.cpp | 20 - libcxx/test/hexfloat.h | 38 - .../file.streams/c.files/cinttypes.pass.cpp | 929 - .../file.streams/c.files/cstdio.pass.cpp | 134 - .../c.files/version_ccstdio.pass.cpp | 20 - .../c.files/version_cinttypes.pass.cpp | 20 - .../filebuf.assign/member_swap.pass.cpp | 54 - .../filebuf.assign/move_assign.pass.cpp | 56 - .../filebuf.assign/nonmember_swap.pass.cpp | 56 - .../fstreams/filebuf.cons/default.pass.cpp | 30 - .../fstreams/filebuf.cons/move.pass.cpp | 54 - .../filebuf.members/open_pointer.pass.cpp | 51 - .../filebuf.virtuals/overflow.pass.cpp | 142 - .../filebuf.virtuals/pbackfail.pass.cpp | 56 - .../filebuf.virtuals/seekoff.pass.cpp | 83 - .../fstreams/filebuf.virtuals/underflow.dat | 1 - .../filebuf.virtuals/underflow.pass.cpp | 121 - .../filebuf.virtuals/underflow_utf8.dat | 1 - .../fstreams/filebuf/types.pass.cpp | 34 - .../fstream.assign/member_swap.pass.cpp | 71 - .../fstream.assign/move_assign.pass.cpp | 50 - .../fstream.assign/nonmember_swap.pass.cpp | 72 - .../fstreams/fstream.cons/default.pass.cpp | 28 - .../fstreams/fstream.cons/move.pass.cpp | 48 - .../fstreams/fstream.cons/pointer.pass.cpp | 44 - .../fstreams/fstream.cons/string.pass.cpp | 46 - .../fstreams/fstream.members/close.pass.cpp | 42 - .../fstream.members/open_pointer.pass.cpp | 50 - .../fstream.members/open_string.pass.cpp | 50 - .../fstreams/fstream.members/rdbuf.pass.cpp | 30 - .../fstreams/fstream/types.pass.cpp | 34 - .../ifstream.assign/member_swap.pass.cpp | 42 - .../ifstream.assign/move_assign.pass.cpp | 40 - .../ifstream.assign/nonmember_swap.pass.cpp | 43 - .../fstreams/ifstream.assign/test.dat | 1 - .../fstreams/ifstream.assign/test2.dat | 1 - .../fstreams/ifstream.cons/default.pass.cpp | 28 - .../fstreams/ifstream.cons/move.pass.cpp | 38 - .../fstreams/ifstream.cons/pointer.pass.cpp | 46 - .../fstreams/ifstream.cons/string.pass.cpp | 46 - .../fstreams/ifstream.cons/test.dat | 1 - .../fstreams/ifstream.members/close.pass.cpp | 38 - .../ifstream.members/open_pointer.pass.cpp | 46 - .../ifstream.members/open_string.pass.cpp | 46 - .../fstreams/ifstream.members/rdbuf.pass.cpp | 32 - .../fstreams/ifstream.members/test.dat | 1 - .../fstreams/ifstream/types.pass.cpp | 34 - .../ofstream.assign/member_swap.pass.cpp | 79 - .../ofstream.assign/move_assign.pass.cpp | 52 - .../ofstream.assign/nonmember_swap.pass.cpp | 80 - .../fstreams/ofstream.cons/default.pass.cpp | 28 - .../fstreams/ofstream.cons/move.pass.cpp | 50 - .../fstreams/ofstream.cons/pointer.pass.cpp | 46 - .../fstreams/ofstream.cons/string.pass.cpp | 46 - .../fstreams/ofstream.members/close.pass.cpp | 42 - .../ofstream.members/open_pointer.pass.cpp | 58 - .../ofstream.members/open_string.pass.cpp | 58 - .../fstreams/ofstream.members/rdbuf.pass.cpp | 36 - .../fstreams/ofstream/types.pass.cpp | 34 - .../file.streams/fstreams/version.pass.cpp | 20 - .../file.streams/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../ext.manip/get_money.pass.cpp | 73 - .../ext.manip/get_time.pass.cpp | 73 - .../ext.manip/put_money.pass.cpp | 89 - .../ext.manip/put_time.pass.cpp | 83 - .../iostream.assign/member_swap.pass.cpp | 85 - .../iostream.assign/move_assign.pass.cpp | 92 - .../iostreamclass/iostream.cons/move.pass.cpp | 78 - .../iostream.cons/streambuf.pass.cpp | 55 - .../iostream.dest/nothing_to_do.pass.cpp | 12 - .../iostreamclass/types.pass.cpp | 37 - .../bool.pass.cpp | 79 - .../double.pass.cpp | 79 - .../float.pass.cpp | 79 - .../istream.formatted.arithmetic/int.pass.cpp | 79 - .../long.pass.cpp | 79 - .../long_double.pass.cpp | 79 - .../long_long.pass.cpp | 79 - .../pointer.pass.cpp | 79 - .../short.pass.cpp | 79 - .../unsigned_int.pass.cpp | 79 - .../unsigned_long.pass.cpp | 79 - .../unsigned_long_long.pass.cpp | 79 - .../unsigned_short.pass.cpp | 79 - .../tested_elsewhere.pass.cpp | 12 - .../istream_extractors/basic_ios.pass.cpp | 38 - .../istream_extractors/chart.pass.cpp | 87 - .../istream_extractors/ios_base.pass.cpp | 36 - .../istream_extractors/istream.pass.cpp | 38 - .../istream_extractors/signed_char.pass.cpp | 70 - .../signed_char_pointer.pass.cpp | 85 - .../istream_extractors/streambuf.pass.cpp | 69 - .../istream_extractors/unsigned_char.pass.cpp | 70 - .../unsigned_char_pointer.pass.cpp | 85 - .../wchar_t_pointer.pass.cpp | 85 - .../istream.formatted/nothing_to_do.pass.cpp | 12 - .../input.streams/istream.manip/ws.pass.cpp | 59 - .../istream.rvalue/rvalue.pass.cpp | 63 - .../istream.unformatted/get.pass.cpp | 100 - .../istream.unformatted/get_chart.pass.cpp | 103 - .../get_pointer_size.pass.cpp | 99 - .../get_pointer_size_chart.pass.cpp | 99 - .../get_streambuf.pass.cpp | 88 - .../get_streambuf_chart.pass.cpp | 89 - .../getline_pointer_size.pass.cpp | 83 - .../getline_pointer_size_chart.pass.cpp | 83 - .../istream.unformatted/ignore.pass.cpp | 76 - .../istream.unformatted/peek.pass.cpp | 69 - .../istream.unformatted/putback.pass.cpp | 89 - .../istream.unformatted/read.pass.cpp | 81 - .../istream.unformatted/readsome.pass.cpp | 83 - .../istream.unformatted/seekg.pass.cpp | 66 - .../istream.unformatted/seekg_off.pass.cpp | 68 - .../istream.unformatted/sync.pass.cpp | 64 - .../istream.unformatted/tellg.pass.cpp | 63 - .../istream.unformatted/unget.pass.cpp | 81 - .../istream.assign/member_swap.pass.cpp | 85 - .../istream.assign/move_assign.pass.cpp | 92 - .../istream/istream.cons/move.pass.cpp | 78 - .../istream/istream.cons/streambuf.pass.cpp | 55 - .../istream/istream_sentry/ctor.pass.cpp | 128 - .../input.streams/istream/types.pass.cpp | 35 - .../input.streams/version.pass.cpp | 20 - .../iostream.format/nothing_to_do.pass.cpp | 12 - .../ostream.assign/member_swap.pass.cpp | 85 - .../ostream.assign/move_assign.pass.cpp | 92 - .../output.streams/ostream.cons/move.pass.cpp | 74 - .../ostream.cons/streambuf.pass.cpp | 53 - .../ostream.formatted/nothing_to_do.pass.cpp | 12 - .../tested_elsewhere.pass.cpp | 12 - .../bool.pass.cpp | 91 - .../double.pass.cpp | 83 - .../float.pass.cpp | 83 - .../ostream.inserters.arithmetic/int.pass.cpp | 83 - .../long.pass.cpp | 83 - .../long_double.pass.cpp | 83 - .../long_long.pass.cpp | 83 - .../pointer.pass.cpp | 76 - .../short.pass.cpp | 83 - .../unsigned_int.pass.cpp | 83 - .../unsigned_long.pass.cpp | 83 - .../unsigned_long_long.pass.cpp | 83 - .../unsigned_short.pass.cpp | 83 - .../CharT.pass.cpp | 88 - .../CharT_pointer.pass.cpp | 88 - .../ostream.inserters.character/char.pass.cpp | 88 - .../char_pointer.pass.cpp | 88 - .../char_to_wide.pass.cpp | 88 - .../char_to_wide_pointer.pass.cpp | 88 - .../signed_char.pass.cpp | 88 - .../signed_char_pointer.pass.cpp | 88 - .../unsigned_char.pass.cpp | 88 - .../unsigned_char_pointer.pass.cpp | 88 - .../ostream.inserters/basic_ios.pass.cpp | 70 - .../ostream.inserters/ios_base.pass.cpp | 61 - .../ostream.inserters/ostream.pass.cpp | 69 - .../ostream.inserters/streambuf.pass.cpp | 69 - .../ostream.manip/endl.pass.cpp | 80 - .../ostream.manip/ends.pass.cpp | 71 - .../ostream.manip/flush.pass.cpp | 58 - .../ostream.rvalue/CharT_pointer.pass.cpp | 72 - .../ostream.seeks/seekp.pass.cpp | 57 - .../ostream.seeks/seekp2.pass.cpp | 59 - .../ostream.seeks/tellp.pass.cpp | 54 - .../ostream.unformatted/flush.pass.cpp | 54 - .../ostream.unformatted/put.pass.cpp | 76 - .../ostream.unformatted/write.pass.cpp | 76 - .../output.streams/ostream/types.pass.cpp | 35 - .../ostream_sentry/construct.pass.cpp | 61 - .../ostream_sentry/destruct.pass.cpp | 75 - .../output.streams/version.pass.cpp | 20 - .../std.manip/resetiosflags.pass.cpp | 54 - .../std.manip/setbase.pass.cpp | 74 - .../std.manip/setfill.pass.cpp | 38 - .../std.manip/setiosflags.pass.cpp | 54 - .../std.manip/setprecision.pass.cpp | 50 - .../iostream.format/std.manip/setw.pass.cpp | 50 - .../std.manip/version.pass.cpp | 20 - .../iostream.forward/iosfwd.pass.cpp | 142 - .../iostream.forward/version.pass.cpp | 20 - .../narrow.stream.objects/cerr.pass.cpp | 25 - .../narrow.stream.objects/cin.pass.cpp | 28 - .../narrow.stream.objects/clog.pass.cpp | 23 - .../narrow.stream.objects/cout.pass.cpp | 27 - .../iostream.objects/version.pass.cpp | 20 - .../wide.stream.objects/wcerr.pass.cpp | 25 - .../wide.stream.objects/wcin.pass.cpp | 28 - .../wide.stream.objects/wclog.pass.cpp | 23 - .../wide.stream.objects/wcout.pass.cpp | 23 - .../fpos/fpos.members/state.pass.cpp | 24 - .../fpos/fpos.operations/addition.pass.cpp | 28 - .../fpos/fpos.operations/ctor_int.pass.cpp | 24 - .../fpos/fpos.operations/difference.pass.cpp | 26 - .../fpos/fpos.operations/eq_int.pass.cpp | 26 - .../fpos/fpos.operations/offset.pass.cpp | 25 - .../fpos/fpos.operations/streamsize.pass.cpp | 24 - .../fpos/fpos.operations/subtraction.pass.cpp | 28 - .../fpos/nothing_to_do.pass.cpp | 12 - .../ios.base/fmtflags.state/flags.pass.cpp | 33 - .../fmtflags.state/flags_fmtflags.pass.cpp | 36 - .../fmtflags.state/precision.pass.cpp | 33 - .../precision_streamsize.pass.cpp | 36 - .../fmtflags.state/setf_fmtflags.pass.cpp | 36 - .../setf_fmtflags_mask.pass.cpp | 36 - .../fmtflags.state/unsetf_mask.pass.cpp | 35 - .../ios.base/fmtflags.state/width.pass.cpp | 33 - .../fmtflags.state/width_streamsize.pass.cpp | 36 - .../register_callback.pass.cpp | 54 - .../ios.base/ios.base.cons/dtor.pass.cpp | 86 - .../ios.base/ios.base.locales/getloc.pass.cpp | 34 - .../ios.base/ios.base.locales/imbue.pass.cpp | 89 - .../ios.base/ios.base.storage/iword.pass.cpp | 42 - .../ios.base/ios.base.storage/pword.pass.cpp | 42 - .../ios.base/ios.base.storage/xalloc.pass.cpp | 26 - .../sync_with_stdio.pass.cpp | 27 - .../ios_Init/tested_elsewhere.pass.cpp | 12 - .../ctor_char_pointer_error_code.pass.cpp | 39 - .../ctor_string_error_code.pass.cpp | 39 - .../ios.types/ios_fmtflags/fmtflags.pass.cpp | 81 - .../ios.types/ios_iostate/iostate.pass.cpp | 36 - .../ios.types/ios_openmode/openmode.pass.cpp | 42 - .../ios.types/ios_seekdir/seekdir.pass.cpp | 26 - .../ios.base/ios.types/nothing_to_do.pass.cpp | 12 - .../ios.base/nothing_to_do.pass.cpp | 16 - .../basic.ios.cons/ctor_streambuf.pass.cpp | 48 - .../ios/basic.ios.members/copyfmt.pass.cpp | 187 - .../ios/basic.ios.members/fill.pass.cpp | 23 - .../basic.ios.members/fill_char_type.pass.cpp | 26 - .../ios/basic.ios.members/imbue.pass.cpp | 101 - .../ios/basic.ios.members/move.pass.cpp | 138 - .../ios/basic.ios.members/narow.pass.cpp | 24 - .../ios/basic.ios.members/rdbuf.pass.cpp | 31 - .../rdbuf_streambuf.pass.cpp | 34 - .../ios/basic.ios.members/set_rdbuf.pass.cpp | 57 - .../ios/basic.ios.members/swap.pass.cpp | 165 - .../ios/basic.ios.members/tie.pass.cpp | 23 - .../basic.ios.members/tie_ostream.pass.cpp | 26 - .../ios/basic.ios.members/widen.pass.cpp | 23 - .../ios/iostate.flags/bad.pass.cpp | 41 - .../ios/iostate.flags/bool.pass.cpp | 25 - .../ios/iostate.flags/clear.pass.cpp | 65 - .../ios/iostate.flags/eof.pass.cpp | 37 - .../ios/iostate.flags/exceptions.pass.cpp | 33 - .../iostate.flags/exceptions_iostate.pass.cpp | 48 - .../ios/iostate.flags/fail.pass.cpp | 41 - .../ios/iostate.flags/good.pass.cpp | 35 - .../ios/iostate.flags/not.pass.cpp | 25 - .../ios/iostate.flags/rdstate.pass.cpp | 25 - .../ios/iostate.flags/setstate.pass.cpp | 64 - .../iostreams.base/ios/types.pass.cpp | 33 - .../adjustfield.manip/internal.pass.cpp | 29 - .../adjustfield.manip/left.pass.cpp | 29 - .../adjustfield.manip/right.pass.cpp | 29 - .../basefield.manip/dec.pass.cpp | 29 - .../basefield.manip/hex.pass.cpp | 29 - .../basefield.manip/oct.pass.cpp | 29 - .../iostream_category.pass.cpp | 23 - .../error.reporting/make_error_code.pass.cpp | 24 - .../make_error_condition.pass.cpp | 24 - .../floatfield.manip/defaultfloat.pass.cpp | 30 - .../floatfield.manip/fixed.pass.cpp | 29 - .../floatfield.manip/hexfloat.pass.cpp | 30 - .../floatfield.manip/scientific.pass.cpp | 29 - .../fmtflags.manip/boolalpha.pass.cpp | 29 - .../fmtflags.manip/noboolalpha.pass.cpp | 30 - .../fmtflags.manip/noshowbase.pass.cpp | 30 - .../fmtflags.manip/noshowpoint.pass.cpp | 30 - .../fmtflags.manip/noshowpos.pass.cpp | 30 - .../fmtflags.manip/noskipws.pass.cpp | 30 - .../fmtflags.manip/nounitbuf.pass.cpp | 30 - .../fmtflags.manip/nouppercase.pass.cpp | 30 - .../fmtflags.manip/showbase.pass.cpp | 29 - .../fmtflags.manip/showpoint.pass.cpp | 29 - .../fmtflags.manip/showpos.pass.cpp | 29 - .../fmtflags.manip/skipws.pass.cpp | 29 - .../fmtflags.manip/unitbuf.pass.cpp | 29 - .../fmtflags.manip/uppercase.pass.cpp | 29 - .../std.ios.manip/nothing_to_do.pass.cpp | 12 - .../stream.types/streamoff.pass.cpp | 21 - .../stream.types/streamsize.pass.cpp | 21 - .../iostreams.base/version.pass.cpp | 20 - .../tested_elsewhere.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../test/input.output/nothing_to_do.pass.cpp | 12 - .../streambuf.reqts/tested_elsewhere.pass.cpp | 12 - .../streambuf/streambuf.cons/copy.fail.cpp | 25 - .../streambuf/streambuf.cons/copy.pass.cpp | 84 - .../streambuf/streambuf.cons/default.fail.cpp | 22 - .../streambuf/streambuf.cons/default.pass.cpp | 56 - .../streambuf.members/nothing_to_do.pass.cpp | 12 - .../streambuf.buffer/pubseekoff.pass.cpp | 35 - .../streambuf.buffer/pubseekpos.pass.cpp | 34 - .../streambuf.buffer/pubsetbuf.pass.cpp | 33 - .../streambuf.buffer/pubsync.pass.cpp | 33 - .../streambuf.locales/locales.pass.cpp | 48 - .../streambuf.pub.get/in_avail.pass.cpp | 52 - .../streambuf.pub.get/sbumpc.pass.cpp | 56 - .../streambuf.pub.get/sgetc.pass.cpp | 56 - .../streambuf.pub.get/sgetn.pass.cpp | 41 - .../streambuf.pub.get/snextc.pass.cpp | 56 - .../streambuf.pub.pback/sputbackc.pass.cpp | 56 - .../streambuf.pub.pback/sungetc.pass.cpp | 56 - .../streambuf.pub.put/sputc.pass.cpp | 63 - .../streambuf.pub.put/sputn.pass.cpp | 41 - .../nothing_to_do.pass.cpp | 12 - .../streambuf.assign/assign.pass.cpp | 91 - .../streambuf.assign/swap.pass.cpp | 101 - .../streambuf.get.area/gbump.pass.cpp | 59 - .../streambuf.get.area/setg.pass.cpp | 49 - .../streambuf.put.area/pbump.pass.cpp | 61 - .../streambuf.put.area/setp.pass.cpp | 49 - .../streambuf.virtuals/nothing_to_do.pass.cpp | 12 - .../tested_elsewhere.pass.cpp | 12 - .../streambuf.virt.get/showmanyc.pass.cpp | 33 - .../streambuf.virt.get/uflow.pass.cpp | 33 - .../streambuf.virt.get/underflow.pass.cpp | 30 - .../streambuf.virt.get/xsgetn.pass.cpp | 41 - .../nothing_to_do.pass.cpp | 12 - .../streambuf.virt.pback/pbackfail.pass.cpp | 32 - .../streambuf.virt.put/overflow.pass.cpp | 30 - .../streambuf.virt.put/xsputn.pass.cpp | 44 - .../stream.buffers/streambuf/types.pass.cpp | 39 - .../stream.buffers/version.pass.cpp | 20 - .../istringstream.assign/member_swap.pass.cpp | 56 - .../istringstream.assign/move.pass.cpp | 50 - .../nonmember_swap.pass.cpp | 59 - .../istringstream.cons/default.pass.cpp | 46 - .../istringstream.cons/move.pass.cpp | 48 - .../istringstream.cons/string.pass.cpp | 67 - .../istringstream.members/str.pass.cpp | 56 - .../istringstream/types.pass.cpp | 36 - .../ostringstream.assign/member_swap.pass.cpp | 48 - .../ostringstream.assign/move.pass.cpp | 46 - .../nonmember_swap.pass.cpp | 48 - .../ostringstream.cons/default.pass.cpp | 46 - .../ostringstream.cons/move.pass.cpp | 44 - .../ostringstream.cons/string.pass.cpp | 59 - .../ostringstream.members/str.pass.cpp | 52 - .../ostringstream/types.pass.cpp | 36 - .../stringbuf.assign/member_swap.pass.cpp | 64 - .../stringbuf/stringbuf.assign/move.pass.cpp | 58 - .../stringbuf.assign/nonmember_swap.pass.cpp | 66 - .../stringbuf/stringbuf.cons/default.pass.cpp | 30 - .../stringbuf/stringbuf.cons/move.pass.cpp | 52 - .../stringbuf/stringbuf.cons/string.pass.cpp | 47 - .../stringbuf/stringbuf.members/str.pass.cpp | 34 - .../stringbuf.virtuals/overflow.pass.cpp | 97 - .../stringbuf.virtuals/pbackfail.pass.cpp | 92 - .../stringbuf.virtuals/seekoff.pass.cpp | 143 - .../stringbuf.virtuals/seekpos.pass.cpp | 77 - .../stringbuf.virtuals/setbuf.pass.cpp | 32 - .../stringbuf.virtuals/underflow.pass.cpp | 70 - .../string.streams/stringbuf/types.pass.cpp | 36 - .../stringstream.cons/default.pass.cpp | 46 - .../stringstream.cons/move.pass.cpp | 52 - .../stringstream.cons/string.pass.cpp | 49 - .../stringstream.assign/member_swap.pass.cpp | 56 - .../stringstream.assign/move.pass.cpp | 54 - .../nonmember_swap.pass.cpp | 59 - .../stringstream.members/str.pass.cpp | 62 - .../stringstream/types.pass.cpp | 36 - .../string.streams/version.pass.cpp | 20 - .../iterator.basic/iterator.pass.cpp | 82 - .../iterator.operations/advance.pass.cpp | 45 - .../iterator.operations/distance.pass.cpp | 40 - .../iterator.operations/next.pass.cpp | 46 - .../iterator.operations/prev.pass.cpp | 44 - .../iterator.traits/const_pointer.pass.cpp | 35 - .../iterator.traits/empty.pass.cpp | 26 - .../iterator.traits/iterator.pass.cpp | 43 - .../iterator.traits/pointer.pass.cpp | 35 - .../nothing_to_do.pass.cpp | 12 - .../bidirectional_iterator_tag.pass.cpp | 24 - .../forward_iterator_tag.pass.cpp | 24 - .../input_iterator_tag.pass.cpp | 22 - .../output_iterator_tag.pass.cpp | 22 - .../random_access_iterator_tag.pass.cpp | 24 - .../nothing_to_do.pass.cpp | 12 - .../forward.iterators/nothing_to_do.pass.cpp | 12 - .../input.iterators/nothing_to_do.pass.cpp | 12 - .../iterator.iterators/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../output.iterators/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../iterator.synopsis/nothing_to_do.pass.cpp | 12 - .../iterators.general/nothing_to_do.pass.cpp | 12 - libcxx/test/iterators/iterators.h | 251 - .../back.insert.iter.cons/container.fail.cpp | 24 - .../back.insert.iter.cons/container.pass.cpp | 29 - .../back.insert.iter.op++/post.pass.cpp | 34 - .../back.insert.iter.op++/pre.pass.cpp | 32 - .../back.insert.iter.op=/lv_value.pass.cpp | 46 - .../back.insert.iter.op=/rv_value.pass.cpp | 42 - .../back.insert.iter.op_astrk/test.pass.cpp | 32 - .../back.inserter/test.pass.cpp | 33 - .../nothing_to_do.pass.cpp | 12 - .../back.insert.iterator/types.pass.cpp | 59 - .../front.insert.iter.cons/container.fail.cpp | 24 - .../front.insert.iter.cons/container.pass.cpp | 29 - .../front.insert.iter.op++/post.pass.cpp | 34 - .../front.insert.iter.op++/pre.pass.cpp | 32 - .../front.insert.iter.op=/lv_value.pass.cpp | 45 - .../front.insert.iter.op=/rv_value.pass.cpp | 41 - .../front.insert.iter.op_astrk/test.pass.cpp | 32 - .../front.inserter/test.pass.cpp | 33 - .../nothing_to_do.pass.cpp | 12 - .../front.insert.iterator/types.pass.cpp | 60 - .../insert.iter.cons/test.pass.cpp | 29 - .../insert.iter.op++/post.pass.cpp | 34 - .../insert.iter.op++/pre.pass.cpp | 32 - .../insert.iter.op=/lv_value.pass.cpp | 64 - .../insert.iter.op=/rv_value.pass.cpp | 95 - .../insert.iter.op_astrk/test.pass.cpp | 32 - .../insert.iter.ops/inserter/test.pass.cpp | 33 - .../insert.iter.ops/nothing_to_do.pass.cpp | 12 - .../insert.iterator/types.pass.cpp | 64 - .../insert.iterators/nothing_to_do.pass.cpp | 12 - .../make_move_iterator.pass.cpp | 39 - .../move.iter.nonmember/minus.pass.cpp | 39 - .../move.iter.nonmember/plus.pass.cpp | 37 - .../move.iter.op.+/difference_type.pass.cpp | 36 - .../move.iter.op.+=/difference_type.pass.cpp | 37 - .../move.iter.op.-/difference_type.pass.cpp | 36 - .../move.iter.op.-=/difference_type.pass.cpp | 37 - .../move.iter.op.comp/op_eq.pass.cpp | 46 - .../move.iter.op.comp/op_gt.pass.cpp | 42 - .../move.iter.op.comp/op_gte.pass.cpp | 42 - .../move.iter.op.comp/op_lt.pass.cpp | 42 - .../move.iter.op.comp/op_lte.pass.cpp | 42 - .../move.iter.op.comp/op_neq.pass.cpp | 46 - .../move.iter.op.const/convert.fail.cpp | 38 - .../move.iter.op.const/convert.pass.cpp | 44 - .../move.iter.op.const/default.pass.cpp | 34 - .../move.iter.op.const/iter.fail.cpp | 31 - .../move.iter.op.const/iter.pass.cpp | 37 - .../tested_elsewhere.pass.cpp | 12 - .../move.iter.op.decr/post.pass.cpp | 37 - .../move.iter.op.decr/pre.pass.cpp | 37 - .../move.iter.op.incr/post.pass.cpp | 39 - .../move.iter.op.incr/pre.pass.cpp | 39 - .../difference_type.pass.cpp | 58 - .../move.iter.op.ref/op_arrow.pass.cpp | 31 - .../move.iter.op.star/op_star.pass.cpp | 61 - .../move.iter.op=/move_iterator.fail.cpp | 39 - .../move.iter.op=/move_iterator.pass.cpp | 47 - .../move.iter.ops/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../move.iterator/types.pass.cpp | 56 - .../move.iterators/nothing_to_do.pass.cpp | 12 - .../predef.iterators/nothing_to_do.pass.cpp | 12 - .../reverse.iterators/nothing_to_do.pass.cpp | 12 - .../reverse.iter.ops/nothing_to_do.pass.cpp | 12 - .../reverse.iter.cons/default.pass.cpp | 33 - .../reverse.iter.cons/iter.fail.cpp | 31 - .../reverse.iter.cons/iter.pass.cpp | 35 - .../reverse_iterator.fail.cpp | 38 - .../reverse_iterator.pass.cpp | 42 - .../tested_elsewhere.pass.cpp | 12 - .../reverse.iter.op!=/test.pass.cpp | 42 - .../reverse.iter.op++/post.pass.cpp | 37 - .../reverse.iter.op++/pre.pass.cpp | 37 - .../reverse.iter.op+/difference_type.pass.cpp | 36 - .../difference_type.pass.cpp | 37 - .../reverse.iter.op--/post.pass.cpp | 37 - .../reverse.iter.op--/pre.pass.cpp | 37 - .../reverse.iter.op-/difference_type.pass.cpp | 36 - .../difference_type.pass.cpp | 37 - .../reverse.iter.op.star/op_star.pass.cpp | 66 - .../reverse_iterator.fail.cpp | 39 - .../reverse_iterator.pass.cpp | 45 - .../reverse.iter.op==/test.pass.cpp | 42 - .../reverse.iter.opdiff/test.pass.cpp | 43 - .../reverse.iter.opgt/test.pass.cpp | 42 - .../reverse.iter.opgt=/test.pass.cpp | 42 - .../difference_type.pass.cpp | 38 - .../reverse.iter.oplt/test.pass.cpp | 42 - .../reverse.iter.oplt=/test.pass.cpp | 42 - .../reverse.iter.opref/op_arrow.pass.cpp | 69 - .../difference_type.pass.cpp | 37 - .../nothing_to_do.pass.cpp | 12 - .../reverse.iterator/types.pass.cpp | 61 - .../istream.iterator.cons/copy.pass.cpp | 36 - .../istream.iterator.cons/default.pass.cpp | 23 - .../istream.iterator.cons/istream.pass.cpp | 30 - .../istream.iterator.ops/arrow.pass.cpp | 37 - .../istream.iterator.ops/dereference.pass.cpp | 34 - .../istream.iterator.ops/equal.pass.cpp | 52 - .../post_increment.pass.cpp | 32 - .../pre_increment.pass.cpp | 29 - .../istream.iterator/types.pass.cpp | 42 - .../istreambuf.iterator.cons/default.pass.cpp | 30 - .../istreambuf.iterator.cons/istream.pass.cpp | 42 - .../istreambuf.iterator.cons/proxy.pass.cpp | 36 - .../streambuf.pass.cpp | 50 - .../istreambuf.iterator_equal/equal.pass.cpp | 78 - .../not_equal.pass.cpp | 80 - .../dereference.pass.cpp | 40 - .../istreambuf.iterator_op==/equal.pass.cpp | 80 - .../arrow.pass.cpp | 28 - .../post_increment.pass.cpp | 38 - .../pre_increment.pass.cpp | 39 - .../istreambuf.iterator_proxy/proxy.pass.cpp | 44 - .../istreambuf.iterator/types.pass.cpp | 51 - .../iterator.range/begin_array.pass.cpp | 24 - .../iterator.range/begin_const.pass.cpp | 23 - .../iterator.range/begin_non_const.pass.cpp | 25 - .../iterator.range/end_array.pass.cpp | 24 - .../iterator.range/end_const.pass.cpp | 23 - .../iterator.range/end_non_const.pass.cpp | 23 - .../stream.iterators/nothing_to_do.pass.cpp | 12 - .../ostream.iterator.cons.des/copy.pass.cpp | 26 - .../ostream.pass.cpp | 25 - .../ostream_delem.pass.cpp | 32 - .../ostream.iterator.ops/assign_t.pass.cpp | 46 - .../ostream.iterator.ops/dereference.pass.cpp | 26 - .../ostream.iterator.ops/increment.pass.cpp | 29 - .../ostream.iterator/types.pass.cpp | 40 - .../ostreambuf.iter.cons/ostream.pass.cpp | 32 - .../ostreambuf.iter.cons/streambuf.pass.cpp | 32 - .../ostreambuf.iter.ops/assign_c.pass.cpp | 39 - .../ostreambuf.iter.ops/deref.pass.cpp | 34 - .../ostreambuf.iter.ops/failed.pass.cpp | 30 - .../ostreambuf.iter.ops/increment.pass.cpp | 39 - .../ostreambuf.iterator/types.pass.cpp | 44 - libcxx/test/iterators/version.pass.cpp | 20 - .../cstdint/cstdint.syn/cstdint.pass.cpp | 290 - .../language.support/cstdint/version.pass.cpp | 20 - .../language.support/nothing_to_do.pass.cpp | 12 - .../alloc.errors/bad.alloc/bad_alloc.pass.cpp | 27 - .../bad_array_new_length.pass.cpp | 27 - .../new.handler/new_handler.pass.cpp | 19 - .../alloc.errors/nothing_to_do.pass.cpp | 12 - .../set.new.handler/get_new_handler.pass.cpp | 25 - .../set.new.handler/set_new_handler.pass.cpp | 22 - .../new.delete.array/new_array.pass.cpp | 54 - .../new_array_nothrow.pass.cpp | 51 - .../new_array_nothrow_replace.pass.cpp | 49 - .../new_array_replace.pass.cpp | 49 - .../not_testable.pass.cpp | 12 - .../new.delete.placement/new.pass.cpp | 30 - .../new.delete.placement/new_array.pass.cpp | 30 - .../new.delete/new.delete.single/new.pass.cpp | 54 - .../new.delete.single/new_nothrow.pass.cpp | 51 - .../new_nothrow_replace.pass.cpp | 49 - .../new.delete.single/new_replace.pass.cpp | 49 - .../new.delete/nothing_to_do.pass.cpp | 12 - .../support.dynamic/version.pass.cpp | 20 - .../bad.exception/bad_exception.pass.cpp | 27 - .../except.nested/assign.pass.cpp | 59 - .../except.nested/ctor_copy.pass.cpp | 57 - .../except.nested/ctor_default.pass.cpp | 55 - .../except.nested/rethrow_if_nested.pass.cpp | 89 - .../except.nested/rethrow_nested.pass.cpp | 70 - .../except.nested/throw_with_nested.pass.cpp | 103 - .../nothing_to_do.pass.cpp | 12 - .../set.terminate/get_terminate.pass.cpp | 25 - .../set.terminate/set_terminate.pass.cpp | 23 - .../terminate_handler.pass.cpp | 19 - .../terminate/terminate.pass.cpp | 26 - .../exception/exception.pass.cpp | 25 - .../propagation/current_exception.pass.cpp | 269 - .../propagation/exception_ptr.pass.cpp | 34 - .../propagation/make_exception_ptr.pass.cpp | 49 - .../propagation/rethrow_exception.pass.cpp | 57 - .../uncaught/uncaught_exception.pass.cpp | 45 - .../support.exception/version.pass.cpp | 20 - .../support.general/nothing_to_do.pass.cpp | 12 - .../support.initlist.access/access.pass.cpp | 42 - .../support.initlist.cons/default.pass.cpp | 25 - .../support.initlist.range/begin_end.pass.cpp | 40 - .../support.initlist/types.pass.cpp | 37 - .../support.initlist/version.pass.cpp | 20 - .../support.limits/c.limits/cfloat.pass.cpp | 140 - .../support.limits/c.limits/climits.pass.cpp | 92 - .../c.limits/version_cfloat.pass.cpp | 20 - .../c.limits/version_climits.pass.cpp | 20 - .../limits/denorm.style/check_values.pass.cpp | 38 - .../limits/is_specialized.pass.cpp | 67 - .../denorm_min.pass.cpp | 49 - .../numeric.limits.members/digits.pass.cpp | 49 - .../numeric.limits.members/digits10.pass.cpp | 53 - .../numeric.limits.members/epsilon.pass.cpp | 50 - .../has_denorm.pass.cpp | 48 - .../has_denorm_loss.pass.cpp | 48 - .../has_infinity.pass.cpp | 48 - .../has_quiet_NaN.pass.cpp | 48 - .../has_signaling_NaN.pass.cpp | 48 - .../numeric.limits.members/infinity.pass.cpp | 54 - .../is_bounded.pass.cpp | 48 - .../numeric.limits.members/is_exact.pass.cpp | 48 - .../numeric.limits.members/is_iec559.pass.cpp | 48 - .../is_integer.pass.cpp | 48 - .../numeric.limits.members/is_modulo.pass.cpp | 48 - .../numeric.limits.members/is_signed.pass.cpp | 48 - .../numeric.limits.members/lowest.pass.cpp | 56 - .../numeric.limits.members/max.pass.cpp | 56 - .../max_digits10.pass.cpp | 49 - .../max_exponent.pass.cpp | 49 - .../max_exponent10.pass.cpp | 49 - .../numeric.limits.members/min.pass.cpp | 56 - .../min_exponent.pass.cpp | 49 - .../min_exponent10.pass.cpp | 49 - .../numeric.limits.members/quiet_NaN.pass.cpp | 69 - .../numeric.limits.members/radix.pass.cpp | 49 - .../round_error.pass.cpp | 50 - .../round_style.pass.cpp | 48 - .../signaling_NaN.pass.cpp | 69 - .../tinyness_before.pass.cpp | 48 - .../numeric.limits.members/traps.pass.cpp | 48 - .../limits/numeric.limits/default.pass.cpp | 83 - .../numeric.special/nothing_to_do.pass.cpp | 12 - .../limits/round.style/check_values.pass.cpp | 34 - .../support.limits/limits/version.pass.cpp | 20 - .../support.limits/nothing_to_do.pass.cpp | 12 - .../support.rtti/bad.cast/bad_cast.pass.cpp | 27 - .../bad.typeid/bad_typeid.pass.cpp | 27 - .../support.rtti/type.info/type_info.pass.cpp | 26 - .../type.info/type_info_hash.pass.cpp | 23 - .../support.rtti/version.pass.cpp | 20 - .../support.runtime/csetjmp.pass.cpp | 24 - .../support.runtime/csignal.pass.cpp | 57 - .../support.runtime/cstdarg.pass.cpp | 33 - .../support.runtime/cstdbool.pass.cpp | 32 - .../support.runtime/cstdlib.pass.cpp | 86 - .../support.runtime/ctime.pass.cpp | 40 - .../support.runtime/version_csetjmp.pass.cpp | 20 - .../support.runtime/version_csignal.pass.cpp | 20 - .../support.runtime/version_cstdarg.pass.cpp | 20 - .../support.runtime/version_cstdbool.pass.cpp | 20 - .../support.runtime/version_cstdlib.pass.cpp | 20 - .../support.runtime/version_ctime.pass.cpp | 20 - .../support.start.term/quick_exit.pass.cpp | 21 - .../support.types/max_align_t.pass.cpp | 34 - .../support.types/null.pass.cpp | 18 - .../support.types/nullptr_t.pass.cpp | 59 - .../support.types/offsetof.pass.cpp | 18 - .../support.types/ptrdiff_t.pass.cpp | 27 - .../support.types/size_t.pass.cpp | 27 - .../support.types/version.pass.cpp | 20 - libcxx/test/lit.cfg | 154 - libcxx/test/lit.site.cfg.in | 10 - .../localization/c.locales/clocale.pass.cpp | 48 - .../localization/c.locales/version.pass.cpp | 20 - .../locale.categories/__scan_keyword.pass.cpp | 118 - .../locale.collate.byname/compare.pass.cpp | 82 - .../locale.collate.byname/hash.pass.cpp | 41 - .../locale.collate.byname/transform.pass.cpp | 67 - .../locale.collate.byname/types.pass.cpp | 45 - .../locale.collate/ctor.pass.cpp | 67 - .../locale.collate.members/compare.pass.cpp | 49 - .../locale.collate.members/hash.pass.cpp | 39 - .../locale.collate.members/transform.pass.cpp | 33 - .../tested_elsewhere.pass.cpp | 12 - .../locale.collate/types.pass.cpp | 49 - .../category.collate/nothing_to_do.pass.cpp | 12 - .../category.ctype/ctype_base.pass.cpp | 57 - .../facet.ctype.char.dtor/dtor.pass.cpp | 50 - .../facet.ctype.char.members/ctor.pass.cpp | 50 - .../facet.ctype.char.members/is_1.pass.cpp | 59 - .../facet.ctype.char.members/is_many.pass.cpp | 118 - .../narrow_1.pass.cpp | 33 - .../narrow_many.pass.cpp | 38 - .../facet.ctype.char.members/scan_is.pass.cpp | 44 - .../scan_not.pass.cpp | 44 - .../facet.ctype.char.members/table.pass.cpp | 33 - .../tolower_1.pass.cpp | 33 - .../tolower_many.pass.cpp | 36 - .../toupper_1.pass.cpp | 33 - .../toupper_many.pass.cpp | 36 - .../facet.ctype.char.members/widen_1.pass.cpp | 33 - .../widen_many.pass.cpp | 38 - .../classic_table.pass.cpp | 23 - .../tested_elsewhere.pass.cpp | 12 - .../facet.ctype.special/types.pass.cpp | 38 - .../locale.codecvt.byname/ctor_char.pass.cpp | 70 - .../ctor_char16_t.pass.cpp | 70 - .../ctor_char32_t.pass.cpp | 70 - .../ctor_wchar_t.pass.cpp | 72 - .../locale.codecvt/codecvt_base.pass.cpp | 27 - .../locale.codecvt/ctor_char.pass.cpp | 52 - .../locale.codecvt/ctor_char16_t.pass.cpp | 58 - .../locale.codecvt/ctor_char32_t.pass.cpp | 58 - .../locale.codecvt/ctor_wchar_t.pass.cpp | 52 - .../char16_t_always_noconv.pass.cpp | 26 - .../char16_t_encoding.pass.cpp | 26 - .../char16_t_in.pass.cpp | 40 - .../char16_t_length.pass.cpp | 32 - .../char16_t_max_length.pass.cpp | 26 - .../char16_t_out.pass.cpp | 45 - .../char16_t_unshift.pass.cpp | 33 - .../char32_t_always_noconv.pass.cpp | 26 - .../char32_t_encoding.pass.cpp | 26 - .../char32_t_in.pass.cpp | 40 - .../char32_t_length.pass.cpp | 32 - .../char32_t_max_length.pass.cpp | 26 - .../char32_t_out.pass.cpp | 45 - .../char32_t_unshift.pass.cpp | 33 - .../char_always_noconv.pass.cpp | 26 - .../char_encoding.pass.cpp | 26 - .../locale.codecvt.members/char_in.pass.cpp | 38 - .../char_length.pass.cpp | 32 - .../char_max_length.pass.cpp | 26 - .../locale.codecvt.members/char_out.pass.cpp | 38 - .../char_unshift.pass.cpp | 33 - .../utf_sanity_check.pass.cpp | 127 - .../wchar_t_always_noconv.pass.cpp | 26 - .../wchar_t_encoding.pass.cpp | 26 - .../wchar_t_in.pass.cpp | 42 - .../wchar_t_length.pass.cpp | 32 - .../wchar_t_max_length.pass.cpp | 26 - .../wchar_t_out.pass.cpp | 69 - .../wchar_t_unshift.pass.cpp | 35 - .../tested_elsewhere.pass.cpp | 12 - .../locale.codecvt/types_char.pass.cpp | 40 - .../locale.codecvt/types_char16_t.pass.cpp | 42 - .../locale.codecvt/types_char32_t.pass.cpp | 42 - .../locale.codecvt/types_wchar_t.pass.cpp | 40 - .../locale.ctype.byname/is_1.pass.cpp | 110 - .../locale.ctype.byname/is_many.pass.cpp | 245 - .../locale.ctype.byname/narrow_1.pass.cpp | 53 - .../locale.ctype.byname/narrow_many.pass.cpp | 61 - .../locale.ctype.byname/scan_is.pass.cpp | 69 - .../locale.ctype.byname/scan_not.pass.cpp | 69 - .../locale.ctype.byname/tolower_1.pass.cpp | 87 - .../locale.ctype.byname/tolower_many.pass.cpp | 92 - .../locale.ctype.byname/toupper_1.pass.cpp | 87 - .../locale.ctype.byname/toupper_many.pass.cpp | 92 - .../locale.ctype.byname/types.pass.cpp | 71 - .../locale.ctype.byname/widen_1.pass.cpp | 56 - .../locale.ctype.byname/widen_many.pass.cpp | 63 - .../category.ctype/locale.ctype/ctor.pass.cpp | 51 - .../locale.ctype.members/is_1.pass.cpp | 59 - .../locale.ctype.members/is_many.pass.cpp | 118 - .../locale.ctype.members/narrow_1.pass.cpp | 33 - .../locale.ctype.members/narrow_many.pass.cpp | 38 - .../locale.ctype.members/scan_is.pass.cpp | 44 - .../locale.ctype.members/scan_not.pass.cpp | 44 - .../locale.ctype.members/tolower_1.pass.cpp | 33 - .../tolower_many.pass.cpp | 36 - .../locale.ctype.members/toupper_1.pass.cpp | 33 - .../toupper_many.pass.cpp | 36 - .../locale.ctype.members/widen_1.pass.cpp | 33 - .../locale.ctype.members/widen_many.pass.cpp | 38 - .../tested_elsewhere.pass.cpp | 12 - .../locale.ctype/types.pass.cpp | 38 - .../nothing_to_do.pass.cpp | 12 - .../locale.messages/ctor.pass.cpp | 52 - .../not_testable.pass.cpp | 34 - .../tested_elsewhere.pass.cpp | 12 - .../locale.messages/messages_base.pass.cpp | 24 - .../locale.messages/types.pass.cpp | 34 - .../category.messages/nothing_to_do.pass.cpp | 12 - .../locale.money.get/ctor.pass.cpp | 52 - .../get_long_double_en_US.pass.cpp | 721 - .../get_long_double_fr_FR.pass.cpp | 722 - .../get_long_double_ru_RU.pass.cpp | 725 - .../get_long_double_zh_CN.pass.cpp | 721 - .../get_string_en_US.pass.cpp | 729 - .../locale.money.get.members/iterators.h | 55 - .../tested_elsewhere.pass.cpp | 12 - .../locale.money.get/types.pass.cpp | 34 - .../locale.money.put/ctor.pass.cpp | 52 - .../locale.money.put.members/iterators.h | 33 - .../put_long_double_en_US.pass.cpp | 492 - .../put_long_double_fr_FR.pass.cpp | 491 - .../put_long_double_ru_RU.pass.cpp | 491 - .../put_long_double_zh_CN.pass.cpp | 491 - .../put_string_en_US.pass.cpp | 492 - .../tested_elsewhere.pass.cpp | 12 - .../locale.money.put/types.pass.cpp | 34 - .../curr_symbol.pass.cpp | 140 - .../decimal_point.pass.cpp | 140 - .../frac_digits.pass.cpp | 140 - .../grouping.pass.cpp | 143 - .../neg_format.pass.cpp | 220 - .../negative_sign.pass.cpp | 140 - .../pos_format.pass.cpp | 220 - .../positive_sign.pass.cpp | 140 - .../thousands_sep.pass.cpp | 140 - .../locale.moneypunct/ctor.pass.cpp | 52 - .../curr_symbol.pass.cpp | 75 - .../decimal_point.pass.cpp | 75 - .../frac_digits.pass.cpp | 75 - .../grouping.pass.cpp | 75 - .../neg_format.pass.cpp | 88 - .../negative_sign.pass.cpp | 76 - .../pos_format.pass.cpp | 88 - .../positive_sign.pass.cpp | 75 - .../thousands_sep.pass.cpp | 75 - .../tested_elsewhere.pass.cpp | 12 - .../locale.moneypunct/money_base.pass.cpp | 33 - .../locale.moneypunct/types.pass.cpp | 34 - .../category.monetary/nothing_to_do.pass.cpp | 12 - .../locale.nm.put/ctor.pass.cpp | 52 - .../facet.num.put.members/iterators.h | 33 - .../facet.num.put.members/put_bool.pass.cpp | 100 - .../facet.num.put.members/put_double.pass.cpp | 17887 ---------- .../facet.num.put.members/put_long.pass.cpp | 371 - .../put_long_double.pass.cpp | 26245 -------------- .../put_long_long.pass.cpp | 344 - .../put_pointer.pass.cpp | 43 - .../put_unsigned_long.pass.cpp | 374 - .../put_unsigned_long_long.pass.cpp | 344 - .../tested_elsewhere.pass.cpp | 12 - .../locale.nm.put/types.pass.cpp | 32 - .../locale.num.get/ctor.pass.cpp | 52 - .../facet.num.get.members/get_bool.pass.cpp | 230 - .../facet.num.get.members/get_double.pass.cpp | 241 - .../facet.num.get.members/get_float.pass.cpp | 171 - .../facet.num.get.members/get_long.pass.cpp | 519 - .../get_long_double.pass.cpp | 171 - .../get_long_long.pass.cpp | 105 - .../get_pointer.pass.cpp | 61 - .../get_unsigned_int.pass.cpp | 83 - .../get_unsigned_long.pass.cpp | 83 - .../get_unsigned_long_long.pass.cpp | 83 - .../get_unsigned_short.pass.cpp | 83 - .../facet.num.get.members/iterators.h | 251 - .../test_min_max.pass.cpp | 53 - .../tested_elsewhere.pass.cpp | 12 - .../locale.num.get/types.pass.cpp | 32 - .../category.numeric/nothing_to_do.pass.cpp | 12 - .../date_order.pass.cpp | 50 - .../date_order_wide.pass.cpp | 50 - .../locale.time.get.byname/get_date.pass.cpp | 89 - .../get_date_wide.pass.cpp | 89 - .../get_monthname.pass.cpp | 81 - .../get_monthname_wide.pass.cpp | 90 - .../locale.time.get.byname/get_one.pass.cpp | 160 - .../get_one_wide.pass.cpp | 162 - .../locale.time.get.byname/get_time.pass.cpp | 89 - .../get_time_wide.pass.cpp | 89 - .../get_weekday.pass.cpp | 83 - .../get_weekday_wide.pass.cpp | 81 - .../locale.time.get.byname/get_year.pass.cpp | 80 - .../get_year_wide.pass.cpp | 80 - .../locale.time.get.byname/iterators.h | 55 - .../locale.time.get/ctor.pass.cpp | 52 - .../date_order.pass.cpp | 34 - .../locale.time.get.members/get_date.pass.cpp | 51 - .../get_date_wide.pass.cpp | 51 - .../locale.time.get.members/get_many.pass.cpp | 68 - .../get_monthname.pass.cpp | 265 - .../get_monthname_wide.pass.cpp | 265 - .../locale.time.get.members/get_one.pass.cpp | 305 - .../locale.time.get.members/get_time.pass.cpp | 117 - .../get_time_wide.pass.cpp | 117 - .../get_weekday.pass.cpp | 220 - .../get_weekday_wide.pass.cpp | 220 - .../locale.time.get.members/get_year.pass.cpp | 138 - .../locale.time.get.members/iterators.h | 55 - .../tested_elsewhere.pass.cpp | 12 - .../locale.time.get/time_base.pass.cpp | 29 - .../locale.time.get/types.pass.cpp | 41 - .../locale.time.put.byname/iterators.h | 33 - .../locale.time.put.byname/put1.pass.cpp | 72 - .../locale.time.put/ctor.pass.cpp | 52 - .../locale.time.put.members/iterators.h | 33 - .../locale.time.put.members/put1.pass.cpp | 61 - .../locale.time.put.members/put2.pass.cpp | 367 - .../tested_elsewhere.pass.cpp | 12 - .../locale.time.put/types.pass.cpp | 32 - .../category.time/nothing_to_do.pass.cpp | 12 - .../decimal_point.pass.cpp | 62 - .../locale.numpunct.byname/grouping.pass.cpp | 62 - .../thousands_sep.pass.cpp | 62 - .../locale.numpunct/ctor.pass.cpp | 66 - .../decimal_point.pass.cpp | 32 - .../facet.numpunct.members/falsename.pass.cpp | 32 - .../facet.numpunct.members/grouping.pass.cpp | 32 - .../thousands_sep.pass.cpp | 32 - .../facet.numpunct.members/truename.pass.cpp | 32 - .../tested_elsewhere.pass.cpp | 12 - .../locale.numpunct/types.pass.cpp | 48 - .../facet.numpunct/nothing_to_do.pass.cpp | 12 - .../facets.examples/nothing_to_do.pass.cpp | 12 - .../locale.stdcvt/codecvt_mode.pass.cpp | 29 - .../locale.stdcvt/codecvt_utf16.pass.cpp | 56 - .../codecvt_utf16_always_noconv.pass.cpp | 45 - .../codecvt_utf16_encoding.pass.cpp | 45 - .../locale.stdcvt/codecvt_utf16_in.pass.cpp | 739 - .../codecvt_utf16_length.pass.cpp | 449 - .../codecvt_utf16_max_length.pass.cpp | 63 - .../locale.stdcvt/codecvt_utf16_out.pass.cpp | 331 - .../codecvt_utf16_unshift.pass.cpp | 56 - .../locale.stdcvt/codecvt_utf8.pass.cpp | 56 - .../codecvt_utf8_always_noconv.pass.cpp | 45 - .../codecvt_utf8_encoding.pass.cpp | 45 - .../locale.stdcvt/codecvt_utf8_in.pass.cpp | 360 - .../codecvt_utf8_length.pass.cpp | 244 - .../codecvt_utf8_max_length.pass.cpp | 63 - .../locale.stdcvt/codecvt_utf8_out.pass.cpp | 456 - .../codecvt_utf8_unshift.pass.cpp | 56 - .../codecvt_utf8_utf16_always_noconv.pass.cpp | 45 - .../codecvt_utf8_utf16_encoding.pass.cpp | 45 - .../codecvt_utf8_utf16_in.pass.cpp | 372 - .../codecvt_utf8_utf16_length.pass.cpp | 235 - .../codecvt_utf8_utf16_max_length.pass.cpp | 63 - .../codecvt_utf8_utf16_out.pass.cpp | 415 - .../codecvt_utf8_utf16_unshift.pass.cpp | 56 - .../locale.stdcvt/version.pass.cpp | 20 - .../locale.syn/nothing_to_do.pass.cpp | 12 - .../classification/isalnum.pass.cpp | 31 - .../classification/isalpha.pass.cpp | 31 - .../classification/iscntrl.pass.cpp | 31 - .../classification/isdigit.pass.cpp | 31 - .../classification/isgraph.pass.cpp | 31 - .../classification/islower.pass.cpp | 31 - .../classification/isprint.pass.cpp | 31 - .../classification/ispunct.pass.cpp | 31 - .../classification/isspace.pass.cpp | 31 - .../classification/isupper.pass.cpp | 31 - .../classification/isxdigit.pass.cpp | 31 - .../conversions.buffer/ctor.pass.cpp | 67 - .../conversions.buffer/overflow.pass.cpp | 100 - .../conversions.buffer/pbackfail.pass.cpp | 59 - .../conversions.buffer/rdbuf.pass.cpp | 31 - .../conversions.buffer/seekoff.pass.cpp | 58 - .../conversions.buffer/state.pass.cpp | 28 - .../conversions.buffer/test.pass.cpp | 36 - .../conversions.buffer/underflow.dat | 1 - .../conversions.buffer/underflow.pass.cpp | 84 - .../conversions.buffer/underflow_utf8.dat | 1 - .../conversions.character/tolower.pass.cpp | 31 - .../conversions.character/toupper.pass.cpp | 31 - .../conversions.string/converted.pass.cpp | 32 - .../conversions.string/ctor_codecvt.pass.cpp | 34 - .../ctor_codecvt_state.pass.cpp | 28 - .../ctor_err_string.pass.cpp | 64 - .../conversions.string/from_bytes.pass.cpp | 37 - .../conversions.string/state.pass.cpp | 25 - .../conversions.string/to_bytes.pass.cpp | 37 - .../conversions.string/types.pass.cpp | 35 - .../conversions/nothing_to_do.pass.cpp | 12 - .../locale.convenience/nothing_to_do.pass.cpp | 12 - .../has_facet.pass.cpp | 32 - .../use_facet.pass.cpp | 52 - .../locale/locale.cons/assign.pass.cpp | 80 - .../locale/locale.cons/char_pointer.pass.cpp | 100 - .../locales/locale/locale.cons/copy.pass.cpp | 79 - .../locale/locale.cons/default.pass.cpp | 89 - .../locale_char_pointer_cat.pass.cpp | 78 - .../locale.cons/locale_facetptr.pass.cpp | 103 - .../locale.cons/locale_locale_cat.pass.cpp | 78 - .../locale.cons/locale_string_cat.pass.cpp | 78 - .../locale/locale.cons/string.pass.cpp | 83 - .../locale/locale.members/combine.pass.cpp | 107 - .../locale/locale.members/name.pass.cpp | 29 - .../locale/locale.operators/compare.pass.cpp | 34 - .../locale/locale.operators/eq.pass.cpp | 84 - .../locale/locale.statics/classic.pass.cpp | 59 - .../locale/locale.statics/global.pass.cpp | 63 - .../locale.category/category.pass.cpp | 41 - .../locale.types/locale.facet/facet.pass.cpp | 53 - .../locale/locale.types/locale.id/id.pass.cpp | 50 - .../locale.types/nothing_to_do.pass.cpp | 12 - .../locales/locale/nothing_to_do.pass.cpp | 12 - .../locales/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - libcxx/test/localization/version.pass.cpp | 20 - libcxx/test/nothing_to_do.pass.cpp | 13 - libcxx/test/numerics/c.math/cmath.pass.cpp | 1339 - libcxx/test/numerics/c.math/ctgmath.pass.cpp | 22 - libcxx/test/numerics/c.math/tgmath_h.pass.cpp | 20 - .../numerics/c.math/version_cmath.pass.cpp | 20 - .../numerics/cfenv/cfenv.syn/cfenv.pass.cpp | 74 - libcxx/test/numerics/cfenv/version.pass.cpp | 20 - libcxx/test/numerics/complex.number/cases.h | 230 - .../complex.number/ccmplx/ccomplex.pass.cpp | 21 - .../complex.number/cmplx.over/arg.pass.cpp | 55 - .../complex.number/cmplx.over/conj.pass.cpp | 66 - .../complex.number/cmplx.over/imag.pass.cpp | 55 - .../complex.number/cmplx.over/norm.pass.cpp | 55 - .../complex.number/cmplx.over/pow.pass.cpp | 104 - .../complex.number/cmplx.over/proj.pass.cpp | 66 - .../complex.number/cmplx.over/real.pass.cpp | 55 - .../assignment_complex.pass.cpp | 48 - .../assignment_scalar.pass.cpp | 37 - .../divide_equal_complex.pass.cpp | 38 - .../divide_equal_scalar.pass.cpp | 44 - .../minus_equal_complex.pass.cpp | 38 - .../minus_equal_scalar.pass.cpp | 40 - .../plus_equal_complex.pass.cpp | 38 - .../plus_equal_scalar.pass.cpp | 40 - .../times_equal_complex.pass.cpp | 38 - .../times_equal_scalar.pass.cpp | 44 - .../complex.members/construct.pass.cpp | 48 - .../complex.members/real_imag.pass.cpp | 44 - .../complex_divide_complex.pass.cpp | 159 - .../complex_divide_scalar.pass.cpp | 41 - .../complex_equals_complex.pass.cpp | 47 - .../complex_equals_scalar.pass.cpp | 57 - .../complex_minus_complex.pass.cpp | 49 - .../complex.ops/complex_minus_scalar.pass.cpp | 49 - .../complex_not_equals_complex.pass.cpp | 47 - .../complex_not_equals_scalar.pass.cpp | 57 - .../complex.ops/complex_plus_complex.pass.cpp | 49 - .../complex.ops/complex_plus_scalar.pass.cpp | 49 - .../complex_times_complex.pass.cpp | 161 - .../complex.ops/complex_times_scalar.pass.cpp | 41 - .../scalar_divide_complex.pass.cpp | 41 - .../scalar_equals_complex.pass.cpp | 57 - .../complex.ops/scalar_minus_complex.pass.cpp | 49 - .../scalar_not_equals_complex.pass.cpp | 57 - .../complex.ops/scalar_plus_complex.pass.cpp | 49 - .../complex.ops/scalar_times_complex.pass.cpp | 41 - .../complex.ops/stream_input.pass.cpp | 99 - .../complex.ops/stream_output.pass.cpp | 26 - .../complex.ops/unary_minus.pass.cpp | 36 - .../complex.ops/unary_plus.pass.cpp | 36 - .../double_float_explicit.pass.cpp | 27 - .../double_float_implicit.pass.cpp | 27 - .../double_long_double_explicit.pass.cpp | 27 - .../double_long_double_implicit.fail.cpp | 27 - .../float_double_explicit.pass.cpp | 27 - .../float_double_implicit.fail.cpp | 27 - .../float_long_double_explicit.pass.cpp | 27 - .../float_long_double_implicit.fail.cpp | 27 - .../long_double_double_explicit.pass.cpp | 27 - .../long_double_double_implicit.pass.cpp | 27 - .../long_double_float_explicit.pass.cpp | 27 - .../long_double_float_implicit.pass.cpp | 27 - .../complex.synopsis/nothing_to_do.pass.cpp | 12 - .../complex.transcendentals/acos.pass.cpp | 140 - .../complex.transcendentals/acosh.pass.cpp | 142 - .../complex.transcendentals/asin.pass.cpp | 120 - .../complex.transcendentals/asinh.pass.cpp | 119 - .../complex.transcendentals/atan.pass.cpp | 68 - .../complex.transcendentals/atanh.pass.cpp | 132 - .../complex.transcendentals/cos.pass.cpp | 68 - .../complex.transcendentals/cosh.pass.cpp | 118 - .../complex.transcendentals/exp.pass.cpp | 114 - .../complex.transcendentals/log.pass.cpp | 131 - .../complex.transcendentals/log10.pass.cpp | 66 - .../pow_complex_complex.pass.cpp | 71 - .../pow_complex_scalar.pass.cpp | 69 - .../pow_scalar_complex.pass.cpp | 69 - .../complex.transcendentals/sin.pass.cpp | 69 - .../complex.transcendentals/sinh.pass.cpp | 119 - .../complex.transcendentals/sqrt.pass.cpp | 109 - .../complex.transcendentals/tan.pass.cpp | 69 - .../complex.transcendentals/tanh.pass.cpp | 101 - .../complex.value.ops/abs.pass.cpp | 63 - .../complex.value.ops/arg.pass.cpp | 135 - .../complex.value.ops/conj.pass.cpp | 41 - .../complex.value.ops/imag.pass.cpp | 32 - .../complex.value.ops/norm.pass.cpp | 63 - .../complex.value.ops/polar.pass.cpp | 112 - .../complex.value.ops/proj.pass.cpp | 71 - .../complex.value.ops/real.pass.cpp | 32 - .../complex.number/complex/types.pass.cpp | 36 - .../numerics/complex.number/layout.pass.cpp | 36 - .../numerics/complex.number/version.pass.cpp | 20 - libcxx/test/numerics/nothing_to_do.pass.cpp | 12 - .../gslice.access/tested_elsewhere.pass.cpp | 12 - .../class.gslice/gslice.cons/default.pass.cpp | 25 - .../gslice.cons/start_size_stride.pass.cpp | 38 - .../class.gslice/nothing_to_do.pass.cpp | 12 - .../class.slice/cons.slice/default.pass.cpp | 25 - .../cons.slice/start_size_stride.pass.cpp | 25 - .../class.slice/nothing_to_do.pass.cpp | 12 - .../slice.access/tested_elsewhere.pass.cpp | 12 - .../template.gslice.array/default.fail.cpp | 22 - .../gslice.array.assign/gslice_array.pass.cpp | 81 - .../gslice.array.assign/valarray.pass.cpp | 77 - .../addition.pass.cpp | 77 - .../gslice.array.comp.assign/and.pass.cpp | 77 - .../gslice.array.comp.assign/divide.pass.cpp | 77 - .../gslice.array.comp.assign/modulo.pass.cpp | 77 - .../multiply.pass.cpp | 77 - .../gslice.array.comp.assign/or.pass.cpp | 77 - .../shift_left.pass.cpp | 77 - .../shift_right.pass.cpp | 77 - .../subtraction.pass.cpp | 77 - .../gslice.array.comp.assign/xor.pass.cpp | 77 - .../gslice.array.fill/assign_value.pass.cpp | 74 - .../template.gslice.array/types.pass.cpp | 24 - .../template.indirect.array/default.fail.cpp | 22 - .../indirect_array.pass.cpp | 80 - .../indirect.array.assign/valarray.pass.cpp | 77 - .../addition.pass.cpp | 77 - .../indirect.array.comp.assign/and.pass.cpp | 77 - .../divide.pass.cpp | 77 - .../modulo.pass.cpp | 77 - .../multiply.pass.cpp | 77 - .../indirect.array.comp.assign/or.pass.cpp | 77 - .../shift_left.pass.cpp | 77 - .../shift_right.pass.cpp | 77 - .../subtraction.pass.cpp | 77 - .../indirect.array.comp.assign/xor.pass.cpp | 77 - .../indirect.array.fill/assign_value.pass.cpp | 74 - .../template.indirect.array/types.pass.cpp | 24 - .../template.mask.array/default.fail.cpp | 22 - .../mask.array.assign/mask_array.pass.cpp | 51 - .../mask.array.assign/valarray.pass.cpp | 49 - .../mask.array.comp.assign/addition.pass.cpp | 49 - .../mask.array.comp.assign/and.pass.cpp | 49 - .../mask.array.comp.assign/divide.pass.cpp | 49 - .../mask.array.comp.assign/modulo.pass.cpp | 49 - .../mask.array.comp.assign/multiply.pass.cpp | 49 - .../mask.array.comp.assign/or.pass.cpp | 49 - .../shift_left.pass.cpp | 49 - .../shift_right.pass.cpp | 49 - .../subtraction.pass.cpp | 49 - .../mask.array.comp.assign/xor.pass.cpp | 49 - .../mask.array.fill/assign_value.pass.cpp | 45 - .../template.mask.array/types.pass.cpp | 24 - .../template.slice.array/default.fail.cpp | 22 - .../slice.arr.assign/slice_array.pass.cpp | 43 - .../slice.arr.assign/valarray.pass.cpp | 43 - .../slice.arr.comp.assign/addition.pass.cpp | 43 - .../slice.arr.comp.assign/and.pass.cpp | 43 - .../slice.arr.comp.assign/divide.pass.cpp | 43 - .../slice.arr.comp.assign/modulo.pass.cpp | 43 - .../slice.arr.comp.assign/multiply.pass.cpp | 43 - .../slice.arr.comp.assign/or.pass.cpp | 43 - .../slice.arr.comp.assign/shift_left.pass.cpp | 43 - .../shift_right.pass.cpp | 43 - .../subtraction.pass.cpp | 43 - .../slice.arr.comp.assign/xor.pass.cpp | 43 - .../slice.arr.fill/assign_value.pass.cpp | 41 - .../template.slice.array/types.pass.cpp | 24 - .../numarray/template.valarray/types.pass.cpp | 26 - .../valarray.access/access.pass.cpp | 33 - .../valarray.access/const_access.pass.cpp | 31 - .../valarray.assign/copy_assign.pass.cpp | 58 - .../gslice_array_assign.pass.cpp | 58 - .../indirect_array_assign.pass.cpp | 58 - .../initializer_list_assign.pass.cpp | 57 - .../mask_array_assign.pass.cpp | 35 - .../valarray.assign/move_assign.pass.cpp | 63 - .../slice_array_assign.pass.cpp | 31 - .../valarray.assign/value_assign.pass.cpp | 31 - .../valarray.cassign/and_valarray.pass.cpp | 36 - .../valarray.cassign/and_value.pass.cpp | 33 - .../valarray.cassign/divide_valarray.pass.cpp | 36 - .../valarray.cassign/divide_value.pass.cpp | 33 - .../valarray.cassign/minus_valarray.pass.cpp | 36 - .../valarray.cassign/minus_value.pass.cpp | 33 - .../valarray.cassign/modulo_valarray.pass.cpp | 36 - .../valarray.cassign/modulo_value.pass.cpp | 33 - .../valarray.cassign/or_valarray.pass.cpp | 36 - .../valarray.cassign/or_value.pass.cpp | 33 - .../valarray.cassign/plus_valarray.pass.cpp | 36 - .../valarray.cassign/plus_value.pass.cpp | 33 - .../shift_left_valarray.pass.cpp | 36 - .../shift_left_value.pass.cpp | 33 - .../shift_right_valarray.pass.cpp | 36 - .../shift_right_value.pass.cpp | 33 - .../valarray.cassign/times_valarray.pass.cpp | 36 - .../valarray.cassign/times_value.pass.cpp | 33 - .../valarray.cassign/xor_valarray.pass.cpp | 36 - .../valarray.cassign/xor_value.pass.cpp | 33 - .../valarray.cons/copy.pass.cpp | 55 - .../valarray.cons/default.pass.cpp | 37 - .../valarray.cons/gslice_array.pass.cpp | 57 - .../valarray.cons/indirect_array.pass.cpp | 57 - .../valarray.cons/initializer_list.pass.cpp | 41 - .../valarray.cons/mask_array.pass.cpp | 34 - .../valarray.cons/move.pass.cpp | 61 - .../valarray.cons/pointer_size.pass.cpp | 52 - .../valarray.cons/size.pass.cpp | 39 - .../valarray.cons/slice_array.pass.cpp | 30 - .../valarray.cons/value_size.pass.cpp | 39 - .../valarray.members/apply_cref.pass.cpp | 51 - .../valarray.members/apply_value.pass.cpp | 51 - .../valarray.members/cshift.pass.cpp | 127 - .../valarray.members/max.pass.cpp | 40 - .../valarray.members/min.pass.cpp | 40 - .../valarray.members/resize.pass.cpp | 41 - .../valarray.members/shift.pass.cpp | 127 - .../valarray.members/size.pass.cpp | 41 - .../valarray.members/sum.pass.cpp | 28 - .../valarray.members/swap.pass.cpp | 89 - .../valarray.sub/gslice_const.pass.cpp | 77 - .../valarray.sub/gslice_non_const.pass.cpp | 57 - .../indirect_array_const.pass.cpp | 57 - .../indirect_array_non_const.pass.cpp | 58 - .../valarray.sub/slice_const.pass.cpp | 30 - .../valarray.sub/slice_non_const.pass.cpp | 43 - .../valarray.sub/valarray_bool_const.pass.cpp | 34 - .../valarray_bool_non_const.pass.cpp | 35 - .../valarray.unary/bit_not.pass.cpp | 55 - .../valarray.unary/negate.pass.cpp | 65 - .../valarray.unary/not.pass.cpp | 41 - .../valarray.unary/plus.pass.cpp | 65 - .../nothing_to_do.pass.cpp | 12 - .../and_valarray_valarray.pass.cpp | 35 - .../and_valarray_value.pass.cpp | 32 - .../and_value_valarray.pass.cpp | 32 - .../divide_valarray_valarray.pass.cpp | 35 - .../divide_valarray_value.pass.cpp | 32 - .../divide_value_valarray.pass.cpp | 32 - .../minus_valarray_valarray.pass.cpp | 35 - .../minus_valarray_value.pass.cpp | 32 - .../minus_value_valarray.pass.cpp | 32 - .../modulo_valarray_valarray.pass.cpp | 35 - .../modulo_valarray_value.pass.cpp | 32 - .../modulo_value_valarray.pass.cpp | 32 - .../or_valarray_valarray.pass.cpp | 35 - .../or_valarray_value.pass.cpp | 32 - .../or_value_valarray.pass.cpp | 32 - .../plus_valarray_valarray.pass.cpp | 35 - .../plus_valarray_value.pass.cpp | 32 - .../plus_value_valarray.pass.cpp | 32 - .../shift_left_valarray_valarray.pass.cpp | 35 - .../shift_left_valarray_value.pass.cpp | 32 - .../shift_left_value_valarray.pass.cpp | 32 - .../shift_right_valarray_valarray.pass.cpp | 35 - .../shift_right_valarray_value.pass.cpp | 32 - .../shift_right_value_valarray.pass.cpp | 32 - .../times_valarray_valarray.pass.cpp | 35 - .../times_valarray_value.pass.cpp | 32 - .../times_value_valarray.pass.cpp | 32 - .../xor_valarray_valarray.pass.cpp | 35 - .../xor_valarray_value.pass.cpp | 32 - .../xor_value_valarray.pass.cpp | 32 - .../and_valarray_valarray.pass.cpp | 37 - .../and_valarray_value.pass.cpp | 45 - .../and_value_valarray.pass.cpp | 45 - .../equal_valarray_valarray.pass.cpp | 37 - .../equal_valarray_value.pass.cpp | 34 - .../equal_value_valarray.pass.cpp | 34 - .../greater_equal_valarray_valarray.pass.cpp | 37 - .../greater_equal_valarray_value.pass.cpp | 34 - .../greater_equal_value_valarray.pass.cpp | 34 - .../greater_valarray_valarray.pass.cpp | 37 - .../greater_valarray_value.pass.cpp | 34 - .../greater_value_valarray.pass.cpp | 34 - .../less_equal_valarray_valarray.pass.cpp | 37 - .../less_equal_valarray_value.pass.cpp | 34 - .../less_equal_value_valarray.pass.cpp | 34 - .../less_valarray_valarray.pass.cpp | 37 - .../less_valarray_value.pass.cpp | 34 - .../less_value_valarray.pass.cpp | 34 - .../not_equal_valarray_valarray.pass.cpp | 37 - .../not_equal_valarray_value.pass.cpp | 34 - .../not_equal_value_valarray.pass.cpp | 34 - .../or_valarray_valarray.pass.cpp | 37 - .../or_valarray_value.pass.cpp | 45 - .../or_value_valarray.pass.cpp | 45 - .../valarray.special/swap.pass.cpp | 91 - .../valarray.transcend/abs_valarray.pass.cpp | 34 - .../valarray.transcend/acos_valarray.pass.cpp | 51 - .../valarray.transcend/asin_valarray.pass.cpp | 51 - .../atan2_valarray_valarray.pass.cpp | 53 - .../atan2_valarray_value.pass.cpp | 51 - .../atan2_value_valarray.pass.cpp | 51 - .../valarray.transcend/atan_valarray.pass.cpp | 51 - .../valarray.transcend/cos_valarray.pass.cpp | 51 - .../valarray.transcend/cosh_valarray.pass.cpp | 51 - .../valarray.transcend/exp_valarray.pass.cpp | 51 - .../log10_valarray.pass.cpp | 51 - .../valarray.transcend/log_valarray.pass.cpp | 51 - .../pow_valarray_valarray.pass.cpp | 53 - .../pow_valarray_value.pass.cpp | 51 - .../pow_value_valarray.pass.cpp | 51 - .../valarray.transcend/sin_valarray.pass.cpp | 51 - .../valarray.transcend/sinh_valarray.pass.cpp | 51 - .../valarray.transcend/sqrt_valarray.pass.cpp | 51 - .../valarray.transcend/tan_valarray.pass.cpp | 51 - .../valarray.transcend/tanh_valarray.pass.cpp | 51 - .../valarray.range/begin_const.pass.cpp | 30 - .../valarray.range/begin_non_const.pass.cpp | 31 - .../valarray.range/end_const.pass.cpp | 31 - .../valarray.range/end_non_const.pass.cpp | 32 - .../valarray.syn/nothing_to_do.pass.cpp | 12 - .../test/numerics/numarray/version.pass.cpp | 20 - .../accumulate/accumulate.pass.cpp | 53 - .../accumulate/accumulate_op.pass.cpp | 55 - .../adjacent_difference.pass.cpp | 72 - .../adjacent_difference_op.pass.cpp | 74 - .../inner.product/inner_product.pass.cpp | 82 - .../inner.product/inner_product_comp.pass.cpp | 85 - libcxx/test/numerics/numeric.ops/iterators.h | 314 - .../numeric.ops/numeric.iota/iota.pass.cpp | 38 - .../partial.sum/partial_sum.pass.cpp | 70 - .../partial.sum/partial_sum_op.pass.cpp | 72 - .../numerics/numeric.ops/version.pass.cpp | 20 - .../nothing_to_do.pass.cpp | 12 - .../numerics.general/nothing_to_do.pass.cpp | 12 - .../test/numerics/rand/nothing_to_do.pass.cpp | 12 - .../rand/rand.adapt/nothing_to_do.pass.cpp | 12 - .../rand.adapt.disc/assign.pass.cpp | 56 - .../rand.adapt/rand.adapt.disc/copy.pass.cpp | 54 - .../rand.adapt.disc/ctor_engine_copy.pass.cpp | 29 - .../rand.adapt.disc/ctor_engine_move.pass.cpp | 30 - .../rand.adapt.disc/ctor_result_type.pass.cpp | 51 - .../rand.adapt.disc/ctor_sseq.pass.cpp | 55 - .../rand.adapt.disc/default.pass.cpp | 42 - .../rand.adapt.disc/discard.pass.cpp | 52 - .../rand.adapt/rand.adapt.disc/eval.pass.cpp | 42 - .../rand.adapt/rand.adapt.disc/io.pass.cpp | 63 - .../rand.adapt.disc/result_type.pass.cpp | 42 - .../rand.adapt.disc/seed_result_type.pass.cpp | 50 - .../rand.adapt.disc/seed_sseq.pass.cpp | 48 - .../rand.adapt.disc/values.pass.cpp | 53 - .../rand.adapt.ibits/assign.pass.cpp | 56 - .../rand.adapt/rand.adapt.ibits/copy.pass.cpp | 54 - .../ctor_engine_copy.pass.cpp | 29 - .../ctor_engine_move.pass.cpp | 30 - .../ctor_result_type.pass.cpp | 51 - .../rand.adapt.ibits/ctor_sseq.pass.cpp | 55 - .../rand.adapt.ibits/default.pass.cpp | 42 - .../rand.adapt.ibits/discard.pass.cpp | 52 - .../rand.adapt/rand.adapt.ibits/eval.pass.cpp | 141 - .../rand.adapt/rand.adapt.ibits/io.pass.cpp | 63 - .../rand.adapt.ibits/result_type.pass.cpp | 83 - .../seed_result_type.pass.cpp | 50 - .../rand.adapt.ibits/seed_sseq.pass.cpp | 48 - .../rand.adapt.ibits/values.pass.cpp | 47 - .../rand.adapt.shuf/assign.pass.cpp | 39 - .../rand.adapt/rand.adapt.shuf/copy.pass.cpp | 38 - .../rand.adapt.shuf/ctor_engine_copy.pass.cpp | 31 - .../rand.adapt.shuf/ctor_engine_move.pass.cpp | 32 - .../rand.adapt.shuf/ctor_result_type.pass.cpp | 76 - .../rand.adapt.shuf/ctor_sseq.pass.cpp | 79 - .../rand.adapt.shuf/default.pass.cpp | 32 - .../rand.adapt.shuf/discard.pass.cpp | 37 - .../rand.adapt/rand.adapt.shuf/eval.pass.cpp | 93 - .../rand.adapt/rand.adapt.shuf/io.pass.cpp | 48 - .../rand.adapt.shuf/result_type.pass.cpp | 83 - .../rand.adapt.shuf/seed_result_type.pass.cpp | 36 - .../rand.adapt.shuf/seed_sseq.pass.cpp | 35 - .../rand.adapt.shuf/values.pass.cpp | 40 - .../numerics/rand/rand.device/ctor.pass.cpp | 38 - .../rand/rand.device/entropy.pass.cpp | 23 - .../numerics/rand/rand.device/eval.pass.cpp | 23 - .../rand/rand.dis/nothing_to_do.pass.cpp | 12 - .../rand.dist.bern/nothing_to_do.pass.cpp | 12 - .../rand.dist.bern.bernoulli/assign.pass.cpp | 33 - .../rand.dist.bern.bernoulli/copy.pass.cpp | 31 - .../ctor_double.pass.cpp | 36 - .../ctor_param.pass.cpp | 28 - .../rand.dist.bern.bernoulli/eq.pass.cpp | 36 - .../rand.dist.bern.bernoulli/eval.pass.cpp | 103 - .../eval_param.pass.cpp | 107 - .../get_param.pass.cpp | 28 - .../rand.dist.bern.bernoulli/io.pass.cpp | 40 - .../rand.dist.bern.bernoulli/max.pass.cpp | 26 - .../rand.dist.bern.bernoulli/min.pass.cpp | 26 - .../param_assign.pass.cpp | 30 - .../param_copy.pass.cpp | 29 - .../param_ctor.pass.cpp | 34 - .../param_eq.pass.cpp | 36 - .../param_types.pass.cpp | 27 - .../set_param.pass.cpp | 29 - .../rand.dist.bern.bernoulli/types.pass.cpp | 26 - .../rand.dist.bern.bin/assign.pass.cpp | 34 - .../rand.dist.bern.bin/copy.pass.cpp | 32 - .../ctor_int_double.pass.cpp | 40 - .../rand.dist.bern.bin/ctor_param.pass.cpp | 30 - .../rand.dist.bern.bin/eq.pass.cpp | 43 - .../rand.dist.bern.bin/eval.pass.cpp | 422 - .../rand.dist.bern.bin/eval_param.pass.cpp | 158 - .../rand.dist.bern.bin/get_param.pass.cpp | 29 - .../rand.dist.bern.bin/io.pass.cpp | 41 - .../rand.dist.bern.bin/max.pass.cpp | 27 - .../rand.dist.bern.bin/min.pass.cpp | 27 - .../rand.dist.bern.bin/param_assign.pass.cpp | 32 - .../rand.dist.bern.bin/param_copy.pass.cpp | 31 - .../rand.dist.bern.bin/param_ctor.pass.cpp | 44 - .../rand.dist.bern.bin/param_eq.pass.cpp | 37 - .../rand.dist.bern.bin/param_types.pass.cpp | 28 - .../rand.dist.bern.bin/set_param.pass.cpp | 30 - .../rand.dist.bern.bin/types.pass.cpp | 32 - .../rand.dist.bern.geo/assign.pass.cpp | 34 - .../rand.dist.bern.geo/copy.pass.cpp | 32 - .../rand.dist.bern.geo/ctor_double.pass.cpp | 32 - .../rand.dist.bern.geo/ctor_param.pass.cpp | 29 - .../rand.dist.bern.geo/eq.pass.cpp | 37 - .../rand.dist.bern.geo/eval.pass.cpp | 272 - .../rand.dist.bern.geo/eval_param.pass.cpp | 158 - .../rand.dist.bern.geo/get_param.pass.cpp | 29 - .../rand.dist.bern.geo/io.pass.cpp | 41 - .../rand.dist.bern.geo/max.pass.cpp | 27 - .../rand.dist.bern.geo/min.pass.cpp | 27 - .../rand.dist.bern.geo/param_assign.pass.cpp | 31 - .../rand.dist.bern.geo/param_copy.pass.cpp | 30 - .../rand.dist.bern.geo/param_ctor.pass.cpp | 35 - .../rand.dist.bern.geo/param_eq.pass.cpp | 37 - .../rand.dist.bern.geo/param_types.pass.cpp | 28 - .../rand.dist.bern.geo/set_param.pass.cpp | 30 - .../rand.dist.bern.geo/types.pass.cpp | 32 - .../rand.dist.bern.negbin/assign.pass.cpp | 34 - .../rand.dist.bern.negbin/copy.pass.cpp | 32 - .../ctor_int_double.pass.cpp | 40 - .../rand.dist.bern.negbin/ctor_param.pass.cpp | 30 - .../rand.dist.bern.negbin/eq.pass.cpp | 43 - .../rand.dist.bern.negbin/eval.pass.cpp | 270 - .../rand.dist.bern.negbin/eval_param.pass.cpp | 158 - .../rand.dist.bern.negbin/get_param.pass.cpp | 29 - .../rand.dist.bern.negbin/io.pass.cpp | 41 - .../rand.dist.bern.negbin/max.pass.cpp | 27 - .../rand.dist.bern.negbin/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../rand.dist.bern.negbin/param_copy.pass.cpp | 31 - .../rand.dist.bern.negbin/param_ctor.pass.cpp | 44 - .../rand.dist.bern.negbin/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.bern.negbin/set_param.pass.cpp | 30 - .../rand.dist.bern.negbin/types.pass.cpp | 32 - .../rand.dist.norm/nothing_to_do.pass.cpp | 12 - .../rand.dist.norm.cauchy/assign.pass.cpp | 34 - .../rand.dist.norm.cauchy/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../rand.dist.norm.cauchy/ctor_param.pass.cpp | 30 - .../rand.dist.norm.cauchy/eq.pass.cpp | 37 - .../rand.dist.norm.cauchy/eval.pass.cpp | 78 - .../rand.dist.norm.cauchy/eval_param.pass.cpp | 81 - .../rand.dist.norm.cauchy/get_param.pass.cpp | 29 - .../rand.dist.norm.cauchy/io.pass.cpp | 41 - .../rand.dist.norm.cauchy/max.pass.cpp | 28 - .../rand.dist.norm.cauchy/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../rand.dist.norm.cauchy/param_copy.pass.cpp | 31 - .../rand.dist.norm.cauchy/param_ctor.pass.cpp | 44 - .../rand.dist.norm.cauchy/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.norm.cauchy/set_param.pass.cpp | 30 - .../rand.dist.norm.cauchy/types.pass.cpp | 34 - .../rand.dist.norm.chisq/assign.pass.cpp | 34 - .../rand.dist.norm.chisq/copy.pass.cpp | 32 - .../rand.dist.norm.chisq/ctor_double.pass.cpp | 32 - .../rand.dist.norm.chisq/ctor_param.pass.cpp | 29 - .../rand.dist.norm.chisq/eq.pass.cpp | 37 - .../rand.dist.norm.chisq/eval.pass.cpp | 152 - .../rand.dist.norm.chisq/eval_param.pass.cpp | 155 - .../rand.dist.norm.chisq/get_param.pass.cpp | 29 - .../rand.dist.norm.chisq/io.pass.cpp | 41 - .../rand.dist.norm.chisq/max.pass.cpp | 28 - .../rand.dist.norm.chisq/min.pass.cpp | 27 - .../param_assign.pass.cpp | 31 - .../rand.dist.norm.chisq/param_copy.pass.cpp | 30 - .../rand.dist.norm.chisq/param_ctor.pass.cpp | 35 - .../rand.dist.norm.chisq/param_eq.pass.cpp | 37 - .../rand.dist.norm.chisq/param_types.pass.cpp | 28 - .../rand.dist.norm.chisq/set_param.pass.cpp | 30 - .../rand.dist.norm.chisq/types.pass.cpp | 34 - .../rand.dist.norm.f/assign.pass.cpp | 34 - .../rand.dist.norm.f/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../rand.dist.norm.f/ctor_param.pass.cpp | 30 - .../rand.dist.norm.f/eq.pass.cpp | 37 - .../rand.dist.norm.f/eval.pass.cpp | 104 - .../rand.dist.norm.f/eval_param.pass.cpp | 107 - .../rand.dist.norm.f/get_param.pass.cpp | 29 - .../rand.dist.norm.f/io.pass.cpp | 41 - .../rand.dist.norm.f/max.pass.cpp | 28 - .../rand.dist.norm.f/min.pass.cpp | 27 - .../rand.dist.norm.f/param_assign.pass.cpp | 32 - .../rand.dist.norm.f/param_copy.pass.cpp | 31 - .../rand.dist.norm.f/param_ctor.pass.cpp | 44 - .../rand.dist.norm.f/param_eq.pass.cpp | 37 - .../rand.dist.norm.f/param_types.pass.cpp | 28 - .../rand.dist.norm.f/set_param.pass.cpp | 30 - .../rand.dist.norm.f/types.pass.cpp | 34 - .../rand.dist.norm.lognormal/assign.pass.cpp | 34 - .../rand.dist.norm.lognormal/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../ctor_param.pass.cpp | 30 - .../rand.dist.norm.lognormal/eq.pass.cpp | 37 - .../rand.dist.norm.lognormal/eval.pass.cpp | 242 - .../eval_param.pass.cpp | 248 - .../get_param.pass.cpp | 29 - .../rand.dist.norm.lognormal/io.pass.cpp | 41 - .../rand.dist.norm.lognormal/max.pass.cpp | 28 - .../rand.dist.norm.lognormal/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../param_copy.pass.cpp | 31 - .../param_ctor.pass.cpp | 44 - .../param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../set_param.pass.cpp | 30 - .../rand.dist.norm.lognormal/types.pass.cpp | 34 - .../rand.dist.norm.normal/assign.pass.cpp | 34 - .../rand.dist.norm.normal/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../rand.dist.norm.normal/ctor_param.pass.cpp | 30 - .../rand.dist.norm.normal/eq.pass.cpp | 37 - .../rand.dist.norm.normal/eval.pass.cpp | 68 - .../rand.dist.norm.normal/eval_param.pass.cpp | 69 - .../rand.dist.norm.normal/get_param.pass.cpp | 29 - .../rand.dist.norm.normal/io.pass.cpp | 41 - .../rand.dist.norm.normal/max.pass.cpp | 28 - .../rand.dist.norm.normal/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../rand.dist.norm.normal/param_copy.pass.cpp | 31 - .../rand.dist.norm.normal/param_ctor.pass.cpp | 44 - .../rand.dist.norm.normal/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.norm.normal/set_param.pass.cpp | 30 - .../rand.dist.norm.normal/types.pass.cpp | 34 - .../rand.dist.norm.t/assign.pass.cpp | 34 - .../rand.dist.norm.t/copy.pass.cpp | 32 - .../rand.dist.norm.t/ctor_double.pass.cpp | 32 - .../rand.dist.norm.t/ctor_param.pass.cpp | 29 - .../rand.dist.norm.t/eq.pass.cpp | 37 - .../rand.dist.norm.t/eval.pass.cpp | 140 - .../rand.dist.norm.t/eval_param.pass.cpp | 143 - .../rand.dist.norm.t/get_param.pass.cpp | 29 - .../rand.dist.norm.t/io.pass.cpp | 41 - .../rand.dist.norm.t/max.pass.cpp | 28 - .../rand.dist.norm.t/min.pass.cpp | 27 - .../rand.dist.norm.t/param_assign.pass.cpp | 31 - .../rand.dist.norm.t/param_copy.pass.cpp | 30 - .../rand.dist.norm.t/param_ctor.pass.cpp | 35 - .../rand.dist.norm.t/param_eq.pass.cpp | 37 - .../rand.dist.norm.t/param_types.pass.cpp | 28 - .../rand.dist.norm.t/set_param.pass.cpp | 30 - .../rand.dist.norm.t/types.pass.cpp | 34 - .../rand.dist.pois/nothing_to_do.pass.cpp | 12 - .../rand.dist.pois.exp/assign.pass.cpp | 34 - .../rand.dist.pois.exp/copy.pass.cpp | 32 - .../rand.dist.pois.exp/ctor_double.pass.cpp | 32 - .../rand.dist.pois.exp/ctor_param.pass.cpp | 29 - .../rand.dist.pois.exp/eq.pass.cpp | 37 - .../rand.dist.pois.exp/eval.pass.cpp | 152 - .../rand.dist.pois.exp/eval_param.pass.cpp | 73 - .../rand.dist.pois.exp/get_param.pass.cpp | 29 - .../rand.dist.pois.exp/io.pass.cpp | 41 - .../rand.dist.pois.exp/max.pass.cpp | 28 - .../rand.dist.pois.exp/min.pass.cpp | 27 - .../rand.dist.pois.exp/param_assign.pass.cpp | 31 - .../rand.dist.pois.exp/param_copy.pass.cpp | 30 - .../rand.dist.pois.exp/param_ctor.pass.cpp | 35 - .../rand.dist.pois.exp/param_eq.pass.cpp | 37 - .../rand.dist.pois.exp/param_types.pass.cpp | 28 - .../rand.dist.pois.exp/set_param.pass.cpp | 30 - .../rand.dist.pois.exp/types.pass.cpp | 34 - .../rand.dist.pois.extreme/assign.pass.cpp | 34 - .../rand.dist.pois.extreme/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../ctor_param.pass.cpp | 30 - .../rand.dist.pois.extreme/eq.pass.cpp | 37 - .../rand.dist.pois.extreme/eval.pass.cpp | 188 - .../eval_param.pass.cpp | 192 - .../rand.dist.pois.extreme/get_param.pass.cpp | 29 - .../rand.dist.pois.extreme/io.pass.cpp | 41 - .../rand.dist.pois.extreme/max.pass.cpp | 28 - .../rand.dist.pois.extreme/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../param_copy.pass.cpp | 31 - .../param_ctor.pass.cpp | 44 - .../rand.dist.pois.extreme/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.pois.extreme/set_param.pass.cpp | 30 - .../rand.dist.pois.extreme/types.pass.cpp | 34 - .../rand.dist.pois.gamma/assign.pass.cpp | 34 - .../rand.dist.pois.gamma/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../rand.dist.pois.gamma/ctor_param.pass.cpp | 30 - .../rand.dist.pois.gamma/eq.pass.cpp | 37 - .../rand.dist.pois.gamma/eval.pass.cpp | 152 - .../rand.dist.pois.gamma/eval_param.pass.cpp | 155 - .../rand.dist.pois.gamma/get_param.pass.cpp | 29 - .../rand.dist.pois.gamma/io.pass.cpp | 41 - .../rand.dist.pois.gamma/max.pass.cpp | 28 - .../rand.dist.pois.gamma/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../rand.dist.pois.gamma/param_copy.pass.cpp | 31 - .../rand.dist.pois.gamma/param_ctor.pass.cpp | 44 - .../rand.dist.pois.gamma/param_eq.pass.cpp | 37 - .../rand.dist.pois.gamma/param_types.pass.cpp | 28 - .../rand.dist.pois.gamma/set_param.pass.cpp | 30 - .../rand.dist.pois.gamma/types.pass.cpp | 34 - .../rand.dist.pois.poisson/assign.pass.cpp | 34 - .../rand.dist.pois.poisson/copy.pass.cpp | 32 - .../ctor_double.pass.cpp | 32 - .../ctor_param.pass.cpp | 29 - .../rand.dist.pois.poisson/eq.pass.cpp | 37 - .../rand.dist.pois.poisson/eval.pass.cpp | 149 - .../eval_param.pass.cpp | 155 - .../rand.dist.pois.poisson/get_param.pass.cpp | 29 - .../rand.dist.pois.poisson/io.pass.cpp | 41 - .../rand.dist.pois.poisson/max.pass.cpp | 28 - .../rand.dist.pois.poisson/min.pass.cpp | 27 - .../param_assign.pass.cpp | 31 - .../param_copy.pass.cpp | 30 - .../param_ctor.pass.cpp | 35 - .../rand.dist.pois.poisson/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.pois.poisson/set_param.pass.cpp | 30 - .../rand.dist.pois.poisson/types.pass.cpp | 34 - .../rand.dist.pois.weibull/assign.pass.cpp | 34 - .../rand.dist.pois.weibull/copy.pass.cpp | 32 - .../ctor_double_double.pass.cpp | 40 - .../ctor_param.pass.cpp | 30 - .../rand.dist.pois.weibull/eq.pass.cpp | 37 - .../rand.dist.pois.weibull/eval.pass.cpp | 164 - .../eval_param.pass.cpp | 167 - .../rand.dist.pois.weibull/get_param.pass.cpp | 29 - .../rand.dist.pois.weibull/io.pass.cpp | 41 - .../rand.dist.pois.weibull/max.pass.cpp | 28 - .../rand.dist.pois.weibull/min.pass.cpp | 27 - .../param_assign.pass.cpp | 32 - .../param_copy.pass.cpp | 31 - .../param_ctor.pass.cpp | 44 - .../rand.dist.pois.weibull/param_eq.pass.cpp | 37 - .../param_types.pass.cpp | 28 - .../rand.dist.pois.weibull/set_param.pass.cpp | 30 - .../rand.dist.pois.weibull/types.pass.cpp | 34 - .../rand.dist.samp/nothing_to_do.pass.cpp | 12 - .../rand.dist.samp.discrete/assign.pass.cpp | 35 - .../rand.dist.samp.discrete/copy.pass.cpp | 33 - .../ctor_default.pass.cpp | 29 - .../ctor_func.pass.cpp | 60 - .../ctor_init.pass.cpp | 81 - .../ctor_iterator.pass.cpp | 87 - .../ctor_param.pass.cpp | 33 - .../rand.dist.samp.discrete/eq.pass.cpp | 45 - .../rand.dist.samp.discrete/eval.pass.cpp | 277 - .../eval_param.pass.cpp | 43 - .../get_param.pass.cpp | 30 - .../rand.dist.samp.discrete/io.pass.cpp | 42 - .../rand.dist.samp.discrete/max.pass.cpp | 34 - .../rand.dist.samp.discrete/min.pass.cpp | 28 - .../param_assign.pass.cpp | 32 - .../param_copy.pass.cpp | 31 - .../param_ctor_default.pass.cpp | 32 - .../param_ctor_func.pass.cpp | 64 - .../param_ctor_init.pass.cpp | 88 - .../param_ctor_iterator.pass.cpp | 94 - .../rand.dist.samp.discrete/param_eq.pass.cpp | 39 - .../param_types.pass.cpp | 28 - .../set_param.pass.cpp | 31 - .../rand.dist.samp.discrete/types.pass.cpp | 32 - .../rand.dist.samp.pconst/assign.pass.cpp | 36 - .../rand.dist.samp.pconst/copy.pass.cpp | 34 - .../ctor_default.pass.cpp | 35 - .../rand.dist.samp.pconst/ctor_func.pass.cpp | 64 - .../ctor_init_func.pass.cpp | 78 - .../ctor_iterator.pass.cpp | 96 - .../rand.dist.samp.pconst/ctor_param.pass.cpp | 41 - .../rand.dist.samp.pconst/eq.pass.cpp | 47 - .../rand.dist.samp.pconst/eval.pass.cpp | 693 - .../rand.dist.samp.pconst/eval_param.pass.cpp | 95 - .../rand.dist.samp.pconst/get_param.pass.cpp | 32 - .../rand.dist.samp.pconst/io.pass.cpp | 44 - .../rand.dist.samp.pconst/max.pass.cpp | 30 - .../rand.dist.samp.pconst/min.pass.cpp | 30 - .../param_assign.pass.cpp | 34 - .../rand.dist.samp.pconst/param_copy.pass.cpp | 33 - .../param_ctor_default.pass.cpp | 34 - .../param_ctor_func.pass.cpp | 67 - .../param_ctor_init_func.pass.cpp | 79 - .../param_ctor_iterator.pass.cpp | 100 - .../rand.dist.samp.pconst/param_eq.pass.cpp | 41 - .../param_types.pass.cpp | 28 - .../rand.dist.samp.pconst/set_param.pass.cpp | 32 - .../rand.dist.samp.pconst/types.pass.cpp | 32 - .../rand.dist.samp.plinear/assign.pass.cpp | 36 - .../rand.dist.samp.plinear/copy.pass.cpp | 34 - .../ctor_default.pass.cpp | 36 - .../rand.dist.samp.plinear/ctor_func.pass.cpp | 69 - .../ctor_init_func.pass.cpp | 82 - .../ctor_iterator.pass.cpp | 101 - .../ctor_param.pass.cpp | 42 - .../rand.dist.samp.plinear/eq.pass.cpp | 47 - .../rand.dist.samp.plinear/eval.pass.cpp | 341 - .../eval_param.pass.cpp | 90 - .../rand.dist.samp.plinear/get_param.pass.cpp | 32 - .../rand.dist.samp.plinear/io.pass.cpp | 44 - .../rand.dist.samp.plinear/max.pass.cpp | 30 - .../rand.dist.samp.plinear/min.pass.cpp | 30 - .../param_assign.pass.cpp | 34 - .../param_copy.pass.cpp | 33 - .../param_ctor_default.pass.cpp | 35 - .../param_ctor_func.pass.cpp | 70 - .../param_ctor_init_func.pass.cpp | 83 - .../param_ctor_iterator.pass.cpp | 105 - .../rand.dist.samp.plinear/param_eq.pass.cpp | 41 - .../param_types.pass.cpp | 28 - .../rand.dist.samp.plinear/set_param.pass.cpp | 32 - .../rand.dist.samp.plinear/types.pass.cpp | 32 - .../rand.dist.uni/nothing_to_do.pass.cpp | 12 - .../rand.dist.uni.int/assign.pass.cpp | 34 - .../rand.dist.uni.int/copy.pass.cpp | 32 - .../rand.dist.uni.int/ctor_int_int.pass.cpp | 41 - .../rand.dist.uni.int/ctor_param.pass.cpp | 30 - .../rand.dist.uni.int/eq.pass.cpp | 37 - .../rand.dist.uni.int/eval.pass.cpp | 453 - .../rand.dist.uni.int/eval_param.pass.cpp | 75 - .../rand.dist.uni.int/get_param.pass.cpp | 29 - .../rand.dist.uni.int/io.pass.cpp | 41 - .../rand.dist.uni.int/max.pass.cpp | 27 - .../rand.dist.uni.int/min.pass.cpp | 27 - .../rand.dist.uni.int/param_assign.pass.cpp | 32 - .../rand.dist.uni.int/param_copy.pass.cpp | 31 - .../rand.dist.uni.int/param_ctor.pass.cpp | 44 - .../rand.dist.uni.int/param_eq.pass.cpp | 37 - .../rand.dist.uni.int/param_types.pass.cpp | 28 - .../rand.dist.uni.int/set_param.pass.cpp | 30 - .../rand.dist.uni.int/types.pass.cpp | 27 - .../rand.dist.uni.real/assign.pass.cpp | 34 - .../rand.dist.uni.real/copy.pass.cpp | 32 - .../rand.dist.uni.real/ctor_int_int.pass.cpp | 41 - .../rand.dist.uni.real/ctor_param.pass.cpp | 30 - .../rand.dist.uni.real/eq.pass.cpp | 37 - .../rand.dist.uni.real/eval.pass.cpp | 472 - .../rand.dist.uni.real/eval_param.pass.cpp | 74 - .../rand.dist.uni.real/get_param.pass.cpp | 29 - .../rand.dist.uni.real/io.pass.cpp | 41 - .../rand.dist.uni.real/max.pass.cpp | 27 - .../rand.dist.uni.real/min.pass.cpp | 27 - .../rand.dist.uni.real/param_assign.pass.cpp | 32 - .../rand.dist.uni.real/param_copy.pass.cpp | 31 - .../rand.dist.uni.real/param_ctor.pass.cpp | 44 - .../rand.dist.uni.real/param_eq.pass.cpp | 37 - .../rand.dist.uni.real/param_types.pass.cpp | 28 - .../rand.dist.uni.real/set_param.pass.cpp | 30 - .../rand.dist.uni.real/types.pass.cpp | 27 - .../rand/rand.eng/nothing_to_do.pass.cpp | 12 - .../rand.eng/rand.eng.lcong/assign.pass.cpp | 58 - .../rand.eng/rand.eng.lcong/copy.pass.cpp | 58 - .../rand.eng.lcong/ctor_result_type.pass.cpp | 154 - .../rand.eng.lcong/ctor_sseq.pass.cpp | 29 - .../rand.eng/rand.eng.lcong/default.pass.cpp | 57 - .../rand.eng/rand.eng.lcong/discard.pass.cpp | 73 - .../rand.eng/rand.eng.lcong/eval.pass.cpp | 87 - .../rand/rand.eng/rand.eng.lcong/io.pass.cpp | 44 - .../rand.eng.lcong/result_type.pass.cpp | 37 - .../rand.eng.lcong/seed_result_type.pass.cpp | 40 - .../rand.eng.lcong/seed_sseq.pass.cpp | 31 - .../rand.eng/rand.eng.lcong/values.pass.cpp | 67 - .../rand.eng/rand.eng.mers/assign.pass.cpp | 58 - .../rand/rand.eng/rand.eng.mers/copy.pass.cpp | 56 - .../rand.eng.mers/ctor_result_type.pass.cpp | 245 - .../rand.eng/rand.eng.mers/ctor_sseq.pass.cpp | 309 - .../rand.eng/rand.eng.mers/default.pass.cpp | 45 - .../rand.eng/rand.eng.mers/discard.pass.cpp | 55 - .../rand/rand.eng/rand.eng.mers/eval.pass.cpp | 45 - .../rand/rand.eng/rand.eng.mers/io.pass.cpp | 69 - .../rand.eng.mers/result_type.pass.cpp | 44 - .../rand.eng.mers/seed_result_type.pass.cpp | 52 - .../rand.eng/rand.eng.mers/seed_sseq.pass.cpp | 50 - .../rand.eng/rand.eng.mers/values.pass.cpp | 91 - .../rand.eng/rand.eng.sub/assign.pass.cpp | 56 - .../rand/rand.eng/rand.eng.sub/copy.pass.cpp | 54 - .../rand.eng.sub/ctor_result_type.pass.cpp | 51 - .../rand.eng/rand.eng.sub/ctor_sseq.pass.cpp | 55 - .../rand.eng/rand.eng.sub/default.pass.cpp | 42 - .../rand.eng/rand.eng.sub/discard.pass.cpp | 52 - .../rand/rand.eng/rand.eng.sub/eval.pass.cpp | 42 - .../rand/rand.eng/rand.eng.sub/io.pass.cpp | 63 - .../rand.eng.sub/result_type.pass.cpp | 42 - .../rand.eng.sub/seed_result_type.pass.cpp | 50 - .../rand.eng/rand.eng.sub/seed_sseq.pass.cpp | 48 - .../rand.eng/rand.eng.sub/values.pass.cpp | 59 - .../default_random_engine.pass.cpp | 22 - .../rand/rand.predef/knuth_b.pass.cpp | 22 - .../rand/rand.predef/minstd_rand.pass.cpp | 23 - .../rand/rand.predef/minstd_rand0.pass.cpp | 23 - .../rand/rand.predef/mt19937.pass.cpp | 27 - .../rand/rand.predef/mt19937_64.pass.cpp | 27 - .../rand/rand.predef/ranlux24.pass.cpp | 22 - .../rand/rand.predef/ranlux24_base.pass.cpp | 22 - .../rand/rand.predef/ranlux48.pass.cpp | 22 - .../rand/rand.predef/ranlux48_base.pass.cpp | 22 - .../rand/rand.req/nothing_to_do.pass.cpp | 12 - .../rand.req.adapt/nothing_to_do.pass.cpp | 12 - .../rand.req.dst/nothing_to_do.pass.cpp | 12 - .../rand.req.eng/nothing_to_do.pass.cpp | 12 - .../rand.req.genl/nothing_to_do.pass.cpp | 12 - .../rand.req.seedseq/nothing_to_do.pass.cpp | 12 - .../rand.req.urng/nothing_to_do.pass.cpp | 12 - .../rand/rand.synopsis/version.pass.cpp | 20 - .../rand/rand.util/nothing_to_do.pass.cpp | 12 - .../generate_canonical.pass.cpp | 100 - .../rand.util.seedseq/assign.fail.cpp | 23 - .../rand.util/rand.util.seedseq/copy.fail.cpp | 22 - .../rand.util.seedseq/default.pass.cpp | 23 - .../rand.util.seedseq/generate.pass.cpp | 805 - .../initializer_list.pass.cpp | 33 - .../rand.util.seedseq/iterator.pass.cpp | 32 - .../rand.util.seedseq/types.pass.cpp | 24 - libcxx/test/platform_support.h | 37 - libcxx/test/re/iterators.h | 277 - libcxx/test/re/nothing_to_do.pass.cpp | 12 - libcxx/test/re/re.alg/nothing_to_do.pass.cpp | 12 - .../test/re/re.alg/re.alg.match/awk.pass.cpp | 1389 - .../re/re.alg/re.alg.match/basic.pass.cpp | 1361 - .../test/re/re.alg/re.alg.match/ecma.pass.cpp | 1331 - .../re/re.alg/re.alg.match/egrep.pass.cpp | 81 - .../re/re.alg/re.alg.match/extended.pass.cpp | 1357 - .../test/re/re.alg/re.alg.match/grep.pass.cpp | 49 - .../re/re.alg/re.alg.replace/test1.pass.cpp | 107 - .../re/re.alg/re.alg.replace/test2.pass.cpp | 107 - .../re/re.alg/re.alg.replace/test3.pass.cpp | 73 - .../re/re.alg/re.alg.replace/test4.pass.cpp | 72 - .../re/re.alg/re.alg.replace/test5.pass.cpp | 73 - .../re/re.alg/re.alg.replace/test6.pass.cpp | 73 - .../test/re/re.alg/re.alg.search/awk.pass.cpp | 1568 - .../re/re.alg/re.alg.search/basic.pass.cpp | 1541 - .../re/re.alg/re.alg.search/ecma.pass.cpp | 1583 - .../re/re.alg/re.alg.search/egrep.pass.cpp | 90 - .../re/re.alg/re.alg.search/extended.pass.cpp | 1537 - .../re/re.alg/re.alg.search/grep.pass.cpp | 58 - .../re.alg/re.except/nothing_to_do.pass.cpp | 12 - libcxx/test/re/re.badexp/regex_error.pass.cpp | 96 - .../test/re/re.const/nothing_to_do.pass.cpp | 13 - .../re/re.const/re.err/error_type.pass.cpp | 143 - .../re.matchflag/match_flag_type.pass.cpp | 128 - .../re.synopt/syntax_option_type.pass.cpp | 114 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - .../nothing_to_do.pass.cpp | 13 - libcxx/test/re/re.def/nothing_to_do.pass.cpp | 13 - .../test/re/re.general/nothing_to_do.pass.cpp | 13 - .../test/re/re.grammar/nothing_to_do.pass.cpp | 12 - libcxx/test/re/re.iter/nothing_to_do.pass.cpp | 12 - .../re.regiter.cnstr/cnstr.pass.cpp | 44 - .../re.regiter.cnstr/default.pass.cpp | 32 - .../re.regiter.comp/tested_elsewhere.pass.cpp | 19 - .../re.regiter.deref/deref.pass.cpp | 42 - .../re.regiter/re.regiter.incr/post.pass.cpp | 42 - .../test/re/re.iter/re.regiter/types.pass.cpp | 45 - .../re.tokiter.cnstr/array.pass.cpp | 64 - .../re.tokiter.cnstr/default.pass.cpp | 32 - .../re.tokiter/re.tokiter.cnstr/init.pass.cpp | 64 - .../re.tokiter/re.tokiter.cnstr/int.pass.cpp | 75 - .../re.tokiter.cnstr/vector.pass.cpp | 128 - .../re.tokiter/re.tokiter.comp/equal.pass.cpp | 36 - .../re.tokiter.deref/deref.pass.cpp | 72 - .../re.tokiter/re.tokiter.incr/post.pass.cpp | 72 - .../test/re/re.iter/re.tokiter/types.pass.cpp | 45 - .../re.regex.assign/assign.il.pass.cpp | 33 - .../re.regex/re.regex.assign/assign.pass.cpp | 26 - .../assign_iter_iter_flag.pass.cpp | 46 - .../re.regex.assign/assign_ptr_flag.pass.cpp | 29 - .../assign_ptr_size_flag.pass.cpp | 25 - .../assign_string_flag.pass.cpp | 31 - .../re/re.regex/re.regex.assign/copy.pass.cpp | 26 - .../re/re.regex/re.regex.assign/il.pass.cpp | 27 - .../re/re.regex/re.regex.assign/ptr.pass.cpp | 25 - .../re.regex/re.regex.assign/string.pass.cpp | 26 - .../re.regex.const/constants.pass.cpp | 52 - .../re.regex/re.regex.construct/copy.pass.cpp | 25 - .../re.regex.construct/default.pass.cpp | 32 - .../re.regex.construct/il_flg.pass.cpp | 70 - .../re.regex.construct/iter_iter.pass.cpp | 43 - .../re.regex.construct/iter_iter_flg.pass.cpp | 69 - .../re.regex/re.regex.construct/ptr.pass.cpp | 34 - .../re.regex.construct/ptr_flg.pass.cpp | 59 - .../re.regex.construct/ptr_size_flg.pass.cpp | 60 - .../re.regex.construct/string.pass.cpp | 35 - .../re.regex.construct/string_flg.pass.cpp | 61 - .../re.regex/re.regex.locale/imbue.pass.cpp | 31 - .../re.regex.nonmemb/nothing_to_do.pass.cpp | 12 - .../re.regex.nmswap/swap.pass.cpp | 29 - .../tested_elsewhere.pass.cpp | 12 - .../re/re.regex/re.regex.swap/swap.pass.cpp | 28 - libcxx/test/re/re.regex/types.pass.cpp | 35 - libcxx/test/re/re.req/nothing_to_do.pass.cpp | 13 - .../re.results.acc/begin_end.pass.cpp | 38 - .../re.results.acc/cbegin_cend.pass.cpp | 38 - .../re.results/re.results.acc/index.pass.cpp | 50 - .../re.results/re.results.acc/length.pass.cpp | 36 - .../re.results.acc/position.pass.cpp | 36 - .../re.results/re.results.acc/prefix.pass.cpp | 34 - .../re/re.results/re.results.acc/str.pass.cpp | 36 - .../re.results/re.results.acc/suffix.pass.cpp | 34 - .../re.results.all/get_allocator.pass.cpp | 35 - .../re.results.const/allocator.pass.cpp | 35 - .../re.results.const/default.pass.cpp | 33 - .../re.results/re.results.form/form1.pass.cpp | 103 - .../re.results/re.results.form/form2.pass.cpp | 102 - .../re.results/re.results.form/form3.pass.cpp | 85 - .../re.results/re.results.form/form4.pass.cpp | 80 - .../re.results.nonmember/equal.pass.cpp | 46 - .../re.results/re.results.size/empty.pass.cpp | 36 - .../re.results.size/max_size.pass.cpp | 31 - .../re.results.state/ready.pass.cpp | 43 - .../re.results.swap/member_swap.pass.cpp | 39 - .../re.results.swap/non_member_swap.pass.cpp | 41 - libcxx/test/re/re.results/types.pass.cpp | 51 - .../compare_string_type.pass.cpp | 49 - .../compare_sub_match.pass.cpp | 53 - .../compare_value_type_ptr.pass.cpp | 47 - .../re.submatch.members/default.pass.cpp | 33 - .../re.submatch.members/length.pass.cpp | 43 - .../operator_string.pass.cpp | 47 - .../re.submatch.members/str.pass.cpp | 47 - .../re.submatch.op/compare.pass.cpp | 283 - .../re.submatch.op/stream.pass.cpp | 42 - libcxx/test/re/re.submatch/types.pass.cpp | 64 - libcxx/test/re/re.syn/cmatch.pass.cpp | 20 - .../test/re/re.syn/cregex_iterator.pass.cpp | 20 - .../re/re.syn/cregex_token_iterator.pass.cpp | 20 - libcxx/test/re/re.syn/csub_match.pass.cpp | 20 - libcxx/test/re/re.syn/regex.pass.cpp | 20 - libcxx/test/re/re.syn/smatch.pass.cpp | 20 - .../test/re/re.syn/sregex_iterator.pass.cpp | 20 - .../re/re.syn/sregex_token_iterator.pass.cpp | 20 - libcxx/test/re/re.syn/ssub_match.pass.cpp | 20 - libcxx/test/re/re.syn/wcmatch.pass.cpp | 20 - .../test/re/re.syn/wcregex_iterator.pass.cpp | 20 - .../re/re.syn/wcregex_token_iterator.pass.cpp | 20 - libcxx/test/re/re.syn/wcsub_match.pass.cpp | 20 - libcxx/test/re/re.syn/wregex.pass.cpp | 20 - libcxx/test/re/re.syn/wsmatch.pass.cpp | 20 - .../test/re/re.syn/wsregex_iterator.pass.cpp | 20 - .../re/re.syn/wsregex_token_iterator.pass.cpp | 20 - libcxx/test/re/re.syn/wssub_match.pass.cpp | 20 - libcxx/test/re/re.traits/default.pass.cpp | 37 - libcxx/test/re/re.traits/getloc.pass.cpp | 36 - libcxx/test/re/re.traits/imbue.pass.cpp | 30 - libcxx/test/re/re.traits/isctype.pass.cpp | 279 - libcxx/test/re/re.traits/iterators.h | 251 - libcxx/test/re/re.traits/length.pass.cpp | 31 - .../re/re.traits/lookup_classname.pass.cpp | 209 - .../re/re.traits/lookup_collatename.pass.cpp | 185 - libcxx/test/re/re.traits/transform.pass.cpp | 42 - .../re/re.traits/transform_primary.pass.cpp | 47 - libcxx/test/re/re.traits/translate.pass.cpp | 34 - .../re/re.traits/translate_nocase.pass.cpp | 64 - libcxx/test/re/re.traits/types.pass.cpp | 32 - libcxx/test/re/re.traits/value.pass.cpp | 125 - libcxx/test/re/test_allocator.h | 112 - .../basic.string.hash/strings.pass.cpp | 48 - .../strings/basic.string/input_iterator.h | 32 - .../basic.string/string.access/at.pass.cpp | 44 - .../basic.string/string.access/back.pass.cpp | 34 - .../basic.string/string.access/front.pass.cpp | 34 - .../basic.string/string.access/index.pass.cpp | 31 - .../string.capacity/capacity.pass.cpp | 48 - .../string.capacity/clear.pass.cpp | 38 - .../string.capacity/empty.pass.cpp | 30 - .../string.capacity/length.pass.cpp | 30 - .../string.capacity/max_size.pass.cpp | 30 - .../string.capacity/reserve.pass.cpp | 81 - .../string.capacity/resize_size.pass.cpp | 54 - .../string.capacity/resize_size_char.pass.cpp | 54 - .../string.capacity/shrink_to_fit.pass.cpp | 43 - .../string.capacity/size.pass.cpp | 30 - .../basic.string/string.cons/alloc.pass.cpp | 44 - .../string.cons/char_assignment.pass.cpp | 36 - .../basic.string/string.cons/copy.pass.cpp | 37 - .../string.cons/copy_alloc.pass.cpp | 37 - .../string.cons/copy_assignment.pass.cpp | 46 - .../string.cons/default_noexcept.pass.cpp | 45 - .../string.cons/dtor_noexcept.pass.cpp | 47 - .../string.cons/initializer_list.pass.cpp | 32 - .../initializer_list_assignment.pass.cpp | 26 - .../string.cons/iter_alloc.pass.cpp | 87 - .../basic.string/string.cons/move.pass.cpp | 45 - .../string.cons/move_alloc.pass.cpp | 45 - .../string.cons/move_assign_noexcept.pass.cpp | 47 - .../string.cons/move_assignment.pass.cpp | 56 - .../string.cons/move_noexcept.pass.cpp | 45 - .../string.cons/pointer_alloc.pass.cpp | 69 - .../string.cons/pointer_assignment.pass.cpp | 48 - .../string.cons/pointer_size_alloc.pass.cpp | 67 - .../string.cons/size_char_alloc.pass.cpp | 106 - .../basic.string/string.cons/substr.pass.cpp | 130 - .../string.iterators/begin.pass.cpp | 37 - .../string.iterators/cbegin.pass.cpp | 34 - .../string.iterators/cend.pass.cpp | 30 - .../string.iterators/crbegin.pass.cpp | 34 - .../string.iterators/crend.pass.cpp | 30 - .../string.iterators/end.pass.cpp | 39 - .../string.iterators/rbegin.pass.cpp | 37 - .../string.iterators/rend.pass.cpp | 39 - .../string.modifiers/nothing_to_do.pass.cpp | 12 - .../string_append/initializer_list.pass.cpp | 26 - .../string_append/iterator.pass.cpp | 87 - .../string_append/pointer.pass.cpp | 42 - .../string_append/pointer_size.pass.cpp | 47 - .../string_append/push_back.pass.cpp | 32 - .../string_append/size_char.pass.cpp | 42 - .../string_append/string.pass.cpp | 50 - .../string_append/string_size_size.pass.cpp | 60 - .../string_assign/initializer_list.pass.cpp | 26 - .../string_assign/iterator.pass.cpp | 87 - .../string_assign/pointer.pass.cpp | 42 - .../string_assign/pointer_size.pass.cpp | 47 - .../string_assign/rv_string.pass.cpp | 50 - .../string_assign/size_char.pass.cpp | 42 - .../string_assign/string.pass.cpp | 50 - .../string_assign/string_size_size.pass.cpp | 60 - .../string_copy/copy.pass.cpp | 102 - .../string_erase/iter.pass.cpp | 43 - .../string_erase/iter_iter.pass.cpp | 86 - .../string_erase/pop_back.pass.cpp | 32 - .../string_erase/size_size.pass.cpp | 171 - .../string_insert/iter_char.pass.cpp | 51 - .../iter_initializer_list.pass.cpp | 27 - .../string_insert/iter_iter_iter.pass.cpp | 76 - .../string_insert/iter_size_char.pass.cpp | 96 - .../string_insert/size_pointer.pass.cpp | 122 - .../string_insert/size_pointer_size.pass.cpp | 363 - .../string_insert/size_size_char.pass.cpp | 123 - .../string_insert/size_string.pass.cpp | 122 - .../size_string_size_size.pass.cpp | 1674 - .../string_op_plus_equal/char.pass.cpp | 33 - .../initializer_list.pass.cpp | 26 - .../string_op_plus_equal/pointer.pass.cpp | 49 - .../string_op_plus_equal/string.pass.cpp | 50 - .../iter_iter_initializer_list.pass.cpp | 26 - .../iter_iter_iter_iter.pass.cpp | 952 - .../string_replace/iter_iter_pointer.pass.cpp | 270 - .../iter_iter_pointer_size.pass.cpp | 949 - .../iter_iter_size_char.pass.cpp | 271 - .../string_replace/iter_iter_string.pass.cpp | 270 - .../string_replace/size_size_pointer.pass.cpp | 360 - .../size_size_pointer_size.pass.cpp | 1294 - .../size_size_size_char.pass.cpp | 359 - .../string_replace/size_size_string.pass.cpp | 359 - .../size_size_string_size_size.pass.cpp | 5802 --- .../string_swap/swap.pass.cpp | 51 - .../string.nonmembers/nothing_to_do.pass.cpp | 12 - .../string.io/get_line.pass.cpp | 49 - .../string.io/get_line_delim.pass.cpp | 55 - .../string.io/get_line_delim_rv.pass.cpp | 35 - .../string.io/get_line_rv.pass.cpp | 35 - .../string.io/stream_extract.pass.cpp | 67 - .../string.io/stream_insert.pass.cpp | 53 - .../string.special/swap.pass.cpp | 53 - .../string.special/swap_noexcept.pass.cpp | 54 - .../string_op!=/pointer_string.pass.cpp | 45 - .../string_op!=/string_pointer.pass.cpp | 45 - .../string_op!=/string_string.pass.cpp | 46 - .../string_op+/char_string.pass.cpp | 58 - .../string_op+/pointer_string.pass.cpp | 82 - .../string_op+/string_char.pass.cpp | 58 - .../string_op+/string_pointer.pass.cpp | 82 - .../string_op+/string_string.pass.cpp | 142 - .../string_operator==/pointer_string.pass.cpp | 45 - .../string_operator==/string_pointer.pass.cpp | 45 - .../string_operator==/string_string.pass.cpp | 46 - .../string_opgt/pointer_string.pass.cpp | 45 - .../string_opgt/string_pointer.pass.cpp | 45 - .../string_opgt/string_string.pass.cpp | 46 - .../string_opgt=/pointer_string.pass.cpp | 45 - .../string_opgt=/string_pointer.pass.cpp | 45 - .../string_opgt=/string_string.pass.cpp | 46 - .../string_oplt/pointer_string.pass.cpp | 45 - .../string_oplt/string_pointer.pass.cpp | 45 - .../string_oplt/string_string.pass.cpp | 46 - .../string_oplt=/pointer_string.pass.cpp | 45 - .../string_oplt=/string_pointer.pass.cpp | 45 - .../string_oplt=/string_string.pass.cpp | 46 - .../string.ops/nothing_to_do.pass.cpp | 12 - .../string.accessors/c_str.pass.cpp | 39 - .../string.ops/string.accessors/data.pass.cpp | 39 - .../string.accessors/get_allocator.pass.cpp | 34 - .../string_compare/pointer.pass.cpp | 53 - .../string_compare/size_size_pointer.pass.cpp | 358 - .../size_size_pointer_size.pass.cpp | 1291 - .../string_compare/size_size_string.pass.cpp | 358 - .../size_size_string_size_size.pass.cpp | 5800 --- .../string.ops/string_compare/string.pass.cpp | 53 - .../char_size.pass.cpp | 65 - .../pointer_size.pass.cpp | 146 - .../pointer_size_size.pass.cpp | 371 - .../string_size.pass.cpp | 145 - .../string_find.first.of/char_size.pass.cpp | 65 - .../pointer_size.pass.cpp | 146 - .../pointer_size_size.pass.cpp | 371 - .../string_find.first.of/string_size.pass.cpp | 145 - .../char_size.pass.cpp | 65 - .../pointer_size.pass.cpp | 146 - .../pointer_size_size.pass.cpp | 371 - .../string_size.pass.cpp | 145 - .../string_find.last.of/char_size.pass.cpp | 65 - .../string_find.last.of/pointer_size.pass.cpp | 146 - .../pointer_size_size.pass.cpp | 371 - .../string_find.last.of/string_size.pass.cpp | 145 - .../string.ops/string_find/char_size.pass.cpp | 65 - .../string_find/pointer_size.pass.cpp | 152 - .../string_find/pointer_size_size.pass.cpp | 371 - .../string_find/string_size.pass.cpp | 145 - .../string_rfind/char_size.pass.cpp | 65 - .../string_rfind/pointer_size.pass.cpp | 153 - .../string_rfind/pointer_size_size.pass.cpp | 371 - .../string_rfind/string_size.pass.cpp | 145 - .../string.ops/string_substr/substr.pass.cpp | 100 - .../string.require/nothing_to_do.pass.cpp | 12 - .../strings/basic.string/test_allocator.h | 70 - .../test/strings/basic.string/test_traits.h | 10 - .../test/strings/basic.string/types.pass.cpp | 81 - libcxx/test/strings/c.strings/cctype.pass.cpp | 103 - .../test/strings/c.strings/cstring.pass.cpp | 53 - libcxx/test/strings/c.strings/cuchar.pass.cpp | 16 - libcxx/test/strings/c.strings/cwchar.pass.cpp | 109 - .../test/strings/c.strings/cwctype.pass.cpp | 114 - .../strings/c.strings/version_cctype.pass.cpp | 20 - .../c.strings/version_cstring.pass.cpp | 20 - .../strings/c.strings/version_cuchar.pass.cpp | 20 - .../strings/c.strings/version_cwchar.pass.cpp | 20 - .../c.strings/version_cwctype.pass.cpp | 20 - .../nothing_to_do.pass.cpp | 12 - .../assign2.pass.cpp | 24 - .../assign3.pass.cpp | 27 - .../compare.pass.cpp | 40 - .../copy.pass.cpp | 27 - .../eof.pass.cpp | 22 - .../eq.pass.cpp | 24 - .../eq_int_type.pass.cpp | 26 - .../find.pass.cpp | 27 - .../length.pass.cpp | 26 - .../lt.pass.cpp | 28 - .../move.pass.cpp | 31 - .../not_eof.pass.cpp | 26 - .../to_char_type.pass.cpp | 24 - .../to_int_type.pass.cpp | 24 - .../types.pass.cpp | 30 - .../assign2.pass.cpp | 26 - .../assign3.pass.cpp | 29 - .../compare.pass.cpp | 42 - .../copy.pass.cpp | 29 - .../eof.pass.cpp | 24 - .../eq.pass.cpp | 26 - .../eq_int_type.pass.cpp | 28 - .../find.pass.cpp | 29 - .../length.pass.cpp | 28 - .../lt.pass.cpp | 26 - .../move.pass.cpp | 33 - .../not_eof.pass.cpp | 28 - .../to_char_type.pass.cpp | 26 - .../to_int_type.pass.cpp | 26 - .../types.pass.cpp | 33 - .../assign2.pass.cpp | 26 - .../assign3.pass.cpp | 29 - .../compare.pass.cpp | 42 - .../copy.pass.cpp | 29 - .../eof.pass.cpp | 24 - .../eq.pass.cpp | 26 - .../eq_int_type.pass.cpp | 28 - .../find.pass.cpp | 29 - .../length.pass.cpp | 28 - .../lt.pass.cpp | 26 - .../move.pass.cpp | 33 - .../not_eof.pass.cpp | 28 - .../to_char_type.pass.cpp | 26 - .../to_int_type.pass.cpp | 26 - .../types.pass.cpp | 33 - .../assign2.pass.cpp | 24 - .../assign3.pass.cpp | 27 - .../compare.pass.cpp | 40 - .../copy.pass.cpp | 27 - .../eof.pass.cpp | 22 - .../eq.pass.cpp | 24 - .../eq_int_type.pass.cpp | 26 - .../find.pass.cpp | 27 - .../length.pass.cpp | 26 - .../lt.pass.cpp | 24 - .../move.pass.cpp | 31 - .../not_eof.pass.cpp | 26 - .../to_char_type.pass.cpp | 24 - .../to_int_type.pass.cpp | 24 - .../types.pass.cpp | 30 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../char.traits/nothing_to_do.pass.cpp | 12 - .../strings/string.classes/typedefs.pass.cpp | 30 - .../strings/string.conversions/stod.pass.cpp | 166 - .../strings/string.conversions/stof.pass.cpp | 166 - .../strings/string.conversions/stoi.pass.cpp | 108 - .../strings/string.conversions/stol.pass.cpp | 89 - .../strings/string.conversions/stold.pass.cpp | 168 - .../strings/string.conversions/stoll.pass.cpp | 89 - .../strings/string.conversions/stoul.pass.cpp | 87 - .../string.conversions/stoull.pass.cpp | 88 - .../string.conversions/to_string.pass.cpp | 126 - .../string.conversions/to_wstring.pass.cpp | 126 - .../strings.general/nothing_to_do.pass.cpp | 13 - libcxx/test/strings/version.pass.cpp | 20 - libcxx/test/testit | 134 - .../futures/futures.async/async.pass.cpp | 177 - .../default_error_condition.pass.cpp | 25 - .../equivalent_error_code_int.pass.cpp | 24 - .../equivalent_int_error_condition.pass.cpp | 25 - .../futures.errors/future_category.pass.cpp | 22 - .../futures.errors/make_error_code.pass.cpp | 26 - .../make_error_condition.pass.cpp | 28 - .../futures.future_error/code.pass.cpp | 41 - .../futures.future_error/types.pass.cpp | 21 - .../futures.future_error/what.pass.cpp | 41 - .../futures.overview/future_errc.pass.cpp | 28 - .../futures.overview/future_status.pass.cpp | 26 - .../is_error_code_enum_future_errc.pass.cpp | 19 - .../futures/futures.overview/launch.pass.cpp | 27 - .../futures.promise/alloc_ctor.pass.cpp | 49 - .../futures.promise/copy_assign.fail.cpp | 87 - .../futures.promise/copy_ctor.fail.cpp | 81 - .../futures/futures.promise/default.pass.cpp | 36 - .../futures/futures.promise/dtor.pass.cpp | 106 - .../futures.promise/get_future.pass.cpp | 53 - .../futures.promise/move_assign.pass.cpp | 89 - .../futures.promise/move_ctor.pass.cpp | 83 - .../futures.promise/set_exception.pass.cpp | 45 - .../set_exception_at_thread_exit.pass.cpp | 42 - .../futures.promise/set_lvalue.pass.cpp | 41 - .../set_lvalue_at_thread_exit.pass.cpp | 36 - .../futures.promise/set_rvalue.pass.cpp | 67 - .../set_rvalue_at_thread_exit.pass.cpp | 39 - .../set_value_at_thread_exit_const.pass.cpp | 33 - .../set_value_at_thread_exit_void.pass.cpp | 37 - .../futures.promise/set_value_const.pass.cpp | 61 - .../futures.promise/set_value_void.pass.cpp | 37 - .../futures/futures.promise/swap.pass.cpp | 82 - .../futures.promise/uses_allocator.pass.cpp | 26 - .../copy_assign.pass.cpp | 74 - .../futures.shared_future/copy_ctor.pass.cpp | 66 - .../ctor_future.pass.cpp | 66 - .../futures.shared_future/default.pass.cpp | 33 - .../futures.shared_future/dtor.pass.cpp | 66 - .../futures.shared_future/get.pass.cpp | 143 - .../move_assign.pass.cpp | 74 - .../futures.shared_future/move_ctor.pass.cpp | 66 - .../futures.shared_future/wait.pass.cpp | 86 - .../futures.shared_future/wait_for.pass.cpp | 95 - .../futures.shared_future/wait_until.pass.cpp | 95 - .../futures.state/nothing_to_do.pass.cpp | 13 - .../futures.task.members/assign_copy.fail.cpp | 48 - .../futures.task.members/assign_move.pass.cpp | 48 - .../futures.task.members/ctor_copy.fail.cpp | 46 - .../ctor_default.pass.cpp | 25 - .../futures.task.members/ctor_func.pass.cpp | 61 - .../ctor_func_alloc.pass.cpp | 69 - .../futures.task.members/ctor_move.pass.cpp | 46 - .../futures.task.members/dtor.pass.cpp | 60 - .../futures.task.members/get_future.pass.cpp | 62 - .../make_ready_at_thread_exit.pass.cpp | 104 - .../futures.task.members/operator.pass.cpp | 105 - .../futures.task.members/reset.pass.cpp | 58 - .../futures.task.members/swap.pass.cpp | 48 - .../futures.task.nonmembers/swap.pass.cpp | 50 - .../uses_allocator.pass.cpp | 24 - .../thread/futures/futures.tas/types.pass.cpp | 26 - .../copy_assign.fail.cpp | 74 - .../futures.unique_future/copy_ctor.fail.cpp | 66 - .../futures.unique_future/default.pass.cpp | 33 - .../futures.unique_future/dtor.pass.cpp | 66 - .../futures.unique_future/get.pass.cpp | 143 - .../move_assign.pass.cpp | 74 - .../futures.unique_future/move_ctor.pass.cpp | 68 - .../futures.unique_future/share.pass.cpp | 66 - .../futures.unique_future/wait.pass.cpp | 86 - .../futures.unique_future/wait_for.pass.cpp | 95 - .../futures.unique_future/wait_until.pass.cpp | 95 - libcxx/test/thread/futures/test_allocator.h | 143 - libcxx/test/thread/futures/version.pass.cpp | 20 - libcxx/test/thread/macro.pass.cpp | 21 - .../thread.condition/cv_status.pass.cpp | 21 - .../notify_all_at_thread_exit.pass.cpp | 42 - .../thread.condition.condvar/assign.fail.cpp | 24 - .../thread.condition.condvar/copy.fail.cpp | 23 - .../thread.condition.condvar/default.pass.cpp | 22 - .../destructor.pass.cpp | 56 - .../native_handle.pass.cpp | 27 - .../notify_all.pass.cpp | 67 - .../notify_one.pass.cpp | 92 - .../thread.condition.condvar/wait.pass.cpp | 50 - .../wait_for.pass.cpp | 85 - .../wait_for_pred.pass.cpp | 93 - .../wait_pred.pass.cpp | 60 - .../wait_until.pass.cpp | 100 - .../wait_until_pred.pass.cpp | 111 - .../assign.fail.cpp | 24 - .../thread.condition.condvarany/copy.fail.cpp | 23 - .../default.pass.cpp | 22 - .../destructor.pass.cpp | 57 - .../notify_all.pass.cpp | 71 - .../notify_one.pass.cpp | 96 - .../thread.condition.condvarany/wait.pass.cpp | 55 - .../wait_for.pass.cpp | 88 - .../wait_for_pred.pass.cpp | 96 - .../wait_pred.pass.cpp | 64 - .../wait_until.pass.cpp | 103 - .../wait_until_pred.pass.cpp | 115 - .../thread/thread.condition/version.pass.cpp | 20 - .../thread.general/nothing_to_do.pass.cpp | 12 - .../thread.lock.algorithm/lock.pass.cpp | 505 - .../thread.lock.algorithm/try_lock.pass.cpp | 514 - .../thread.lock.guard/adopt_lock.pass.cpp | 49 - .../thread.lock.guard/assign.fail.cpp | 25 - .../thread.lock.guard/copy.fail.cpp | 23 - .../thread.lock.guard/mutex.fail.cpp | 48 - .../thread.lock.guard/mutex.pass.cpp | 48 - .../thread.lock.guard/types.pass.cpp | 27 - .../copy_assign.fail.cpp | 31 - .../copy_ctor.fail.cpp | 29 - .../thread.lock.unique.cons/default.pass.cpp | 24 - .../move_assign.pass.cpp | 33 - .../move_ctor.pass.cpp | 31 - .../thread.lock.unique.cons/mutex.pass.cpp | 48 - .../mutex_adopt_lock.pass.cpp | 26 - .../mutex_defer_lock.pass.cpp | 25 - .../mutex_duration.pass.cpp | 66 - .../mutex_time_point.pass.cpp | 66 - .../mutex_try_to_lock.pass.cpp | 63 - .../thread.lock.unique.locking/lock.pass.cpp | 67 - .../try_lock.pass.cpp | 62 - .../try_lock_for.pass.cpp | 67 - .../try_lock_until.pass.cpp | 67 - .../unlock.pass.cpp | 54 - .../member_swap.pass.cpp | 36 - .../nonmember_swap.pass.cpp | 37 - .../thread.lock.unique.mod/release.pass.cpp | 44 - .../thread.lock.unique.obs/mutex.pass.cpp | 29 - .../thread.lock.unique.obs/op_bool.pass.cpp | 29 - .../thread.lock.unique.obs/owns_lock.pass.cpp | 29 - .../thread.lock.unique/types.pass.cpp | 27 - .../thread.mutex/thread.lock/types.pass.cpp | 32 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../thread.mutex.class/assign.fail.cpp | 23 - .../thread.mutex.class/copy.fail.cpp | 22 - .../thread.mutex.class/default.pass.cpp | 21 - .../thread.mutex.class/lock.pass.cpp | 48 - .../thread.mutex.class/native_handle.pass.cpp | 25 - .../thread.mutex.class/try_lock.pass.cpp | 50 - .../thread.mutex.recursive/assign.fail.cpp | 23 - .../thread.mutex.recursive/copy.fail.cpp | 22 - .../thread.mutex.recursive/default.pass.cpp | 21 - .../thread.mutex.recursive/lock.pass.cpp | 50 - .../native_handle.pass.cpp | 25 - .../thread.mutex.recursive/try_lock.pass.cpp | 52 - .../nothing_to_do.pass.cpp | 12 - .../thread.timedmutex.class/assign.fail.cpp | 23 - .../thread.timedmutex.class/copy.fail.cpp | 22 - .../thread.timedmutex.class/default.pass.cpp | 21 - .../thread.timedmutex.class/lock.pass.cpp | 48 - .../thread.timedmutex.class/try_lock.pass.cpp | 50 - .../try_lock_for.pass.cpp | 65 - .../try_lock_until.pass.cpp | 65 - .../assign.fail.cpp | 23 - .../thread.timedmutex.recursive/copy.fail.cpp | 22 - .../default.pass.cpp | 21 - .../thread.timedmutex.recursive/lock.pass.cpp | 50 - .../try_lock.pass.cpp | 52 - .../try_lock_for.pass.cpp | 67 - .../try_lock_until.pass.cpp | 67 - .../thread.once/nothing_to_do.pass.cpp | 12 - .../thread.once.callonce/call_once.pass.cpp | 198 - .../thread.once.onceflag/assign.fail.cpp | 23 - .../thread.once.onceflag/copy.fail.cpp | 22 - .../thread.once.onceflag/default.pass.cpp | 21 - .../test/thread/thread.mutex/version.pass.cpp | 20 - .../thread/thread.req/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../thread.req.native/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../thread.req.timing/nothing_to_do.pass.cpp | 12 - .../thread.thread.algorithm/swap.pass.cpp | 55 - .../thread.thread.assign/copy.fail.cpp | 51 - .../thread.thread.assign/move.pass.cpp | 82 - .../thread.thread.constr/F.pass.cpp | 150 - .../thread.thread.constr/copy.fail.cpp | 66 - .../thread.thread.constr/default.pass.cpp | 23 - .../thread.thread.constr/move.pass.cpp | 68 - .../thread.thread.destr/dtor.pass.cpp | 58 - .../thread.thread.id/assign.pass.cpp | 27 - .../thread.thread.id/copy.pass.cpp | 24 - .../thread.thread.id/default.pass.cpp | 23 - .../thread.thread.id/eq.pass.cpp | 30 - .../thread.thread.id/lt.pass.cpp | 35 - .../thread.thread.id/stream.pass.cpp | 27 - .../thread.thread.id/thread_id.pass.cpp | 31 - .../thread.thread.member/detach.pass.cpp | 54 - .../thread.thread.member/get_id.pass.cpp | 54 - .../thread.thread.member/join.pass.cpp | 51 - .../thread.thread.member/joinable.pass.cpp | 51 - .../native_handle.pass.cpp | 51 - .../thread.thread.member/swap.pass.cpp | 55 - .../hardware_concurrency.pass.cpp | 22 - .../thread.thread.class/types.pass.cpp | 25 - .../thread.thread.this/get_id.pass.cpp | 21 - .../thread.thread.this/sleep_for.pass.cpp | 32 - .../thread.thread.this/sleep_until.pass.cpp | 32 - .../thread.thread.this/yield.pass.cpp | 20 - .../thread/thread.threads/version.pass.cpp | 20 - .../allocator.adaptor.cnstr/allocs.pass.cpp | 112 - .../converting_copy.pass.cpp | 69 - .../converting_move.pass.cpp | 75 - .../allocator.adaptor.cnstr/copy.pass.cpp | 70 - .../allocator.adaptor.cnstr/default.pass.cpp | 58 - .../allocate_size.pass.cpp | 49 - .../allocate_size_hint.pass.cpp | 70 - .../construct.pass.cpp | 193 - .../deallocate.pass.cpp | 46 - .../destroy.pass.cpp | 70 - .../inner_allocator.pass.cpp | 45 - .../max_size.pass.cpp | 43 - .../outer_allocator.pass.cpp | 44 - ...ct_on_container_copy_construction.pass.cpp | 55 - .../inner_allocator_type.pass.cpp | 39 - ...gate_on_container_copy_assignment.pass.cpp | 39 - ...gate_on_container_move_assignment.pass.cpp | 39 - .../propagate_on_container_swap.pass.cpp | 39 - .../utilities/allocator.adaptor/allocators.h | 174 - .../scoped.adaptor.operators/eq.pass.cpp | 64 - .../allocator.adaptor/types.pass.cpp | 102 - .../date.time/tested_elsewhere.pass.cpp | 37 - .../arithmetic.operations/divides.pass.cpp | 24 - .../arithmetic.operations/minus.pass.cpp | 24 - .../arithmetic.operations/modulus.pass.cpp | 24 - .../arithmetic.operations/multiplies.pass.cpp | 24 - .../arithmetic.operations/negate.pass.cpp | 24 - .../arithmetic.operations/plus.pass.cpp | 24 - .../func.bind.bind/invoke_int_0.pass.cpp | 53 - .../func.bind.bind/invoke_lvalue.pass.cpp | 268 - .../func.bind.bind/invoke_rvalue.pass.cpp | 266 - .../func.bind.bind/invoke_void_0.pass.cpp | 59 - .../is_bind_expression.pass.cpp | 32 - .../func.bind.isbind/is_placeholder.pass.cpp | 41 - .../func.bind.place/placeholders.pass.cpp | 36 - .../bind/func.bind/nothing_to_do.pass.cpp | 12 - .../bind/nothing_to_do.pass.cpp | 12 - .../bitwise.operations/bit_and.pass.cpp | 28 - .../bitwise.operations/bit_or.pass.cpp | 28 - .../bitwise.operations/bit_xor.pass.cpp | 28 - .../comparisons/equal_to.pass.cpp | 25 - .../comparisons/greater.pass.cpp | 26 - .../comparisons/greater_equal.pass.cpp | 26 - .../comparisons/less.pass.cpp | 26 - .../comparisons/less_equal.pass.cpp | 26 - .../comparisons/not_equal_to.pass.cpp | 25 - .../func.def/nothing_to_do.pass.cpp | 12 - .../func.memfn/member_data.fail.cpp | 42 - .../func.memfn/member_data.pass.cpp | 41 - .../func.memfn/member_function.pass.cpp | 66 - .../func.memfn/member_function_const.pass.cpp | 72 - .../member_function_const_volatile.pass.cpp | 72 - .../member_function_volatile.pass.cpp | 72 - .../func.require/binary_function.pass.cpp | 23 - .../func.require/unary_function.pass.cpp | 22 - .../bad_function_call.pass.cpp | 26 - .../bad_function_call_ctor.pass.cpp | 20 - .../func.wrap.func.alg/swap.pass.cpp | 135 - .../func.wrap.func.cap/operator_bool.pass.cpp | 29 - .../func.wrap.func.con/F.pass.cpp | 98 - .../func.wrap.func.con/F_assign.pass.cpp | 105 - .../func.wrap.func.con/alloc.pass.cpp | 25 - .../func.wrap.func.con/alloc_F.pass.cpp | 80 - .../alloc_function.pass.cpp | 104 - .../func.wrap.func.con/alloc_nullptr.pass.cpp | 25 - .../alloc_rfunction.pass.cpp | 81 - .../func.wrap.func.con/copy.pass.cpp | 119 - .../func.wrap.func.con/copy_assign.pass.cpp | 123 - .../func.wrap.func.con/default.pass.cpp | 23 - .../func.wrap.func.con/nullptr_t.pass.cpp | 23 - .../nullptr_t_assign.pass.cpp | 86 - .../func.wrap.func.inv/invoke.fail.cpp | 46 - .../func.wrap.func.inv/invoke.pass.cpp | 335 - .../func.wrap.func.inv/invoke_int_0.pass.cpp | 58 - .../func.wrap.func.inv/invoke_void_0.pass.cpp | 67 - .../assign_F_alloc.pass.cpp | 60 - .../func.wrap.func.mod/swap.pass.cpp | 134 - .../operator_==.pass.cpp | 41 - .../func.wrap.func.targ/target.pass.cpp | 89 - .../func.wrap.func.targ/target_type.pass.cpp | 61 - .../func.wrap/func.wrap.func/test_allocator.h | 112 - .../func.wrap/func.wrap.func/types.pass.cpp | 49 - .../func.wrap/nothing_to_do.pass.cpp | 12 - .../logical.operations/logical_and.pass.cpp | 27 - .../logical.operations/logical_not.pass.cpp | 25 - .../logical.operations/logical_or.pass.cpp | 27 - .../negators/binary_negate.pass.cpp | 27 - .../function.objects/negators/not1.pass.cpp | 22 - .../function.objects/negators/not2.pass.cpp | 24 - .../negators/unary_negate.pass.cpp | 25 - .../function.objects/refwrap/binary.pass.cpp | 80 - .../refwrap.access/conversion.pass.cpp | 46 - .../refwrap.assign/copy_assign.pass.cpp | 58 - .../refwrap/refwrap.const/copy_ctor.pass.cpp | 46 - .../refwrap/refwrap.const/type_ctor.fail.cpp | 22 - .../refwrap/refwrap.const/type_ctor.pass.cpp | 45 - .../refwrap/refwrap.helpers/cref_1.pass.cpp | 24 - .../refwrap/refwrap.helpers/cref_2.pass.cpp | 25 - .../refwrap/refwrap.helpers/ref_1.fail.cpp | 27 - .../refwrap/refwrap.helpers/ref_1.pass.cpp | 24 - .../refwrap/refwrap.helpers/ref_2.pass.cpp | 25 - .../refwrap/refwrap.invoke/invoke.fail.cpp | 52 - .../refwrap/refwrap.invoke/invoke.pass.cpp | 329 - .../refwrap.invoke/invoke_int_0.pass.cpp | 76 - .../refwrap.invoke/invoke_void_0.pass.cpp | 68 - .../function.objects/refwrap/type.pass.cpp | 37 - .../function.objects/refwrap/unary.pass.cpp | 78 - .../refwrap/weak_result.pass.cpp | 82 - .../unord.hash/floating.pass.cpp | 68 - .../unord.hash/integral.pass.cpp | 58 - .../unord.hash/pointer.pass.cpp | 42 - .../function.objects/version.pass.cpp | 20 - .../allocator.tag/allocator_arg.pass.cpp | 22 - .../allocate.pass.cpp | 38 - .../allocate_hint.pass.cpp | 60 - .../construct.pass.cpp | 143 - .../deallocate.pass.cpp | 42 - .../allocator.traits.members/destroy.pass.cpp | 80 - .../max_size.pass.cpp | 64 - ...ct_on_container_copy_construction.pass.cpp | 68 - .../const_pointer.pass.cpp | 55 - .../const_void_pointer.pass.cpp | 55 - .../difference_type.pass.cpp | 62 - .../allocator.traits.types/pointer.pass.cpp | 42 - ...gate_on_container_copy_assignment.pass.cpp | 40 - ...gate_on_container_move_assignment.pass.cpp | 40 - .../propagate_on_container_swap.pass.cpp | 40 - .../rebind_alloc.pass.cpp | 79 - .../allocator.traits.types/size_type.pass.cpp | 63 - .../void_pointer.pass.cpp | 55 - .../allocator.traits/allocator_type.pass.cpp | 31 - .../allocator.traits/rebind_traits.pass.cpp | 79 - .../allocator.traits/value_type.pass.cpp | 31 - .../tested_elsewhere.pass.cpp | 12 - .../uses_allocator.pass.cpp | 33 - .../allocator.uses/nothing_to_do.pass.cpp | 12 - .../memory/c.malloc/nothing_to_do.pass.cpp | 14 - .../allocator.globals/eq.pass.cpp | 31 - .../allocator.members/address.pass.cpp | 39 - .../allocator.members/allocate.pass.cpp | 63 - .../allocator.members/construct.pass.cpp | 153 - .../allocator.members/max_size.pass.cpp | 27 - .../allocator_types.pass.cpp | 49 - .../default.allocator/allocator_void.pass.cpp | 36 - .../pointer.traits/difference_type.pass.cpp | 25 - .../pointer.traits/element_type.pass.cpp | 25 - .../memory/pointer.traits/pointer.pass.cpp | 32 - .../pointer_to.pass.cpp | 48 - .../difference_type.pass.cpp | 48 - .../element_type.pass.cpp | 49 - .../pointer.traits.types/rebind.pass.cpp | 69 - .../memory/pointer.traits/pointer_to.pass.cpp | 32 - .../memory/pointer.traits/rebind.pass.cpp | 29 - .../utilities/memory/ptr.align/align.pass.cpp | 85 - .../nothing_to_do.pass.cpp | 12 - .../specialized.addressof/addressof.pass.cpp | 33 - .../uninitialized_copy.pass.cpp | 51 - .../uninitialized_copy_n.pass.cpp | 51 - .../uninitialized_fill_n.pass.cpp | 50 - .../uninitialized_fill.pass.cpp | 50 - .../raw_storag_iterator.pass.cpp | 44 - .../temporary_buffer.pass.cpp | 29 - .../utilities/memory/unique.ptr/deleter.h | 181 - .../memory/unique.ptr/nothing_to_do.pass.cpp | 12 - .../unique.ptr.dltr/nothing_to_do.pass.cpp | 12 - .../convert_ctor.pass.cpp | 48 - .../unique.ptr.dltr.dflt/default.pass.cpp | 34 - .../unique.ptr.dltr.dflt/incomplete.fail.cpp | 26 - .../convert_ctor.fail.cpp | 32 - .../unique.ptr.dltr.dflt1/default.pass.cpp | 36 - .../unique.ptr.dltr.dflt1/incomplete.fail.cpp | 26 - .../nothing_to_do.pass.cpp | 12 - .../unique.ptr.runtime/move01.fail.cpp | 38 - .../unique.ptr.runtime/move01.pass.cpp | 78 - .../unique.ptr.runtime/move02.fail.cpp | 38 - .../unique.ptr.runtime/move03.fail.cpp | 56 - .../unique.ptr.runtime/move04.fail.cpp | 56 - .../move_convert01.fail.cpp | 56 - .../move_convert02.fail.cpp | 60 - .../move_convert03.fail.cpp | 61 - .../move_convert04.fail.cpp | 56 - .../move_convert05.fail.cpp | 60 - .../move_convert06.fail.cpp | 61 - .../move_convert07.fail.cpp | 55 - .../move_convert08.fail.cpp | 59 - .../move_convert09.fail.cpp | 61 - .../unique.ptr.runtime/null_asgn.pass.cpp | 41 - .../unique.ptr.runtime/null_ctor.pass.cpp | 44 - .../unique.ptr.runtime/nullptr_asgn.pass.cpp | 41 - .../unique.ptr.runtime/pointer_type.pass.cpp | 34 - .../default01.fail.cpp | 36 - .../default01.pass.cpp | 47 - .../default02.fail.cpp | 30 - .../default02.pass.cpp | 87 - .../default03.fail.cpp | 23 - .../unique.ptr.runtime.ctor/move01.fail.cpp | 42 - .../unique.ptr.runtime.ctor/move01.pass.cpp | 85 - .../unique.ptr.runtime.ctor/move02.fail.cpp | 42 - .../unique.ptr.runtime.ctor/move02.pass.cpp | 87 - .../unique.ptr.runtime.ctor/move03.fail.cpp | 55 - .../unique.ptr.runtime.ctor/move04.fail.cpp | 55 - .../move_convert01.fail.cpp | 57 - .../move_convert02.fail.cpp | 61 - .../move_convert03.fail.cpp | 78 - .../move_convert04.fail.cpp | 57 - .../move_convert05.fail.cpp | 61 - .../move_convert06.fail.cpp | 78 - .../move_convert07.fail.cpp | 57 - .../move_convert08.fail.cpp | 61 - .../move_convert09.fail.cpp | 78 - .../move_convert10.fail.cpp | 57 - .../move_convert11.fail.cpp | 61 - .../move_convert12.fail.cpp | 78 - .../move_convert13.fail.cpp | 57 - .../move_convert14.fail.cpp | 61 - .../move_convert15.fail.cpp | 78 - .../move_convert16.fail.cpp | 57 - .../move_convert17.fail.cpp | 61 - .../move_convert18.fail.cpp | 78 - .../unique.ptr.runtime.ctor/nullptr.pass.cpp | 46 - .../pointer01.fail.cpp | 36 - .../pointer01.pass.cpp | 63 - .../pointer02.fail.cpp | 29 - .../pointer02.pass.cpp | 95 - .../pointer03.fail.cpp | 23 - .../pointer04.fail.cpp | 67 - .../pointer_deleter01.pass.cpp | 43 - .../pointer_deleter02.pass.cpp | 58 - .../pointer_deleter03.pass.cpp | 60 - .../pointer_deleter04.fail.cpp | 55 - .../pointer_deleter04.pass.cpp | 58 - .../pointer_deleter05.fail.cpp | 58 - .../release.pass.cpp | 27 - .../reset1.pass.cpp | 48 - .../reset2.fail.cpp | 64 - .../swap.pass.cpp | 56 - .../dereference.fail.cpp | 23 - .../explicit_bool.pass.cpp | 39 - .../unique.ptr.runtime.observers/get.pass.cpp | 24 - .../get_deleter.pass.cpp | 37 - .../index.pass.cpp | 47 - .../op_arrow.fail.cpp | 30 - .../unique.ptr.single/pointer_type.pass.cpp | 34 - .../unique.ptr.single.asgn/move01.fail.cpp | 38 - .../unique.ptr.single.asgn/move01.pass.cpp | 74 - .../unique.ptr.single.asgn/move02.fail.cpp | 38 - .../unique.ptr.single.asgn/move03.fail.cpp | 56 - .../unique.ptr.single.asgn/move04.fail.cpp | 56 - .../move_convert01.fail.cpp | 56 - .../move_convert01.pass.cpp | 55 - .../move_convert02.fail.cpp | 60 - .../move_convert02.pass.cpp | 59 - .../move_convert03.fail.cpp | 61 - .../move_convert03.pass.cpp | 62 - .../move_convert04.fail.cpp | 56 - .../move_convert05.fail.cpp | 60 - .../move_convert06.fail.cpp | 61 - .../move_convert13.fail.cpp | 35 - .../unique.ptr.single.asgn/null.pass.cpp | 41 - .../unique.ptr.single.asgn/nullptr.pass.cpp | 41 - .../auto_pointer.pass.cpp | 67 - .../auto_pointer01.fail.cpp | 67 - .../auto_pointer02.fail.cpp | 61 - .../unique.ptr.single.ctor/default01.fail.cpp | 35 - .../unique.ptr.single.ctor/default01.pass.cpp | 46 - .../unique.ptr.single.ctor/default02.fail.cpp | 29 - .../unique.ptr.single.ctor/default02.pass.cpp | 84 - .../unique.ptr.single.ctor/default03.fail.cpp | 23 - .../unique.ptr.single.ctor/move01.fail.cpp | 42 - .../unique.ptr.single.ctor/move01.pass.cpp | 141 - .../unique.ptr.single.ctor/move02.fail.cpp | 42 - .../unique.ptr.single.ctor/move02.pass.cpp | 143 - .../unique.ptr.single.ctor/move03.fail.cpp | 55 - .../unique.ptr.single.ctor/move04.fail.cpp | 55 - .../move_convert01.fail.cpp | 55 - .../move_convert01.pass.cpp | 57 - .../move_convert02.fail.cpp | 61 - .../move_convert02.pass.cpp | 61 - .../move_convert03.fail.cpp | 78 - .../move_convert03.pass.cpp | 78 - .../move_convert04.fail.cpp | 57 - .../move_convert04.pass.cpp | 57 - .../move_convert05.fail.cpp | 50 - .../move_convert05.pass.cpp | 61 - .../move_convert06.fail.cpp | 78 - .../move_convert06.pass.cpp | 78 - .../move_convert07.fail.cpp | 57 - .../move_convert07.pass.cpp | 62 - .../move_convert08.fail.cpp | 117 - .../move_convert09.fail.cpp | 78 - .../move_convert10.fail.cpp | 57 - .../move_convert11.fail.cpp | 117 - .../move_convert12.fail.cpp | 78 - .../move_convert13.fail.cpp | 34 - .../unique.ptr.single.ctor/nullptr.pass.cpp | 46 - .../unique.ptr.single.ctor/pointer01.fail.cpp | 35 - .../unique.ptr.single.ctor/pointer01.pass.cpp | 63 - .../unique.ptr.single.ctor/pointer02.fail.cpp | 29 - .../unique.ptr.single.ctor/pointer02.pass.cpp | 95 - .../unique.ptr.single.ctor/pointer03.fail.cpp | 23 - .../unique.ptr.single.ctor/pointer03.pass.cpp | 78 - .../pointer_deleter01.pass.cpp | 99 - .../pointer_deleter02.pass.cpp | 58 - .../pointer_deleter03.pass.cpp | 60 - .../pointer_deleter04.fail.cpp | 55 - .../pointer_deleter04.pass.cpp | 58 - .../pointer_deleter05.pass.cpp | 66 - .../pointer_deleter06.pass.cpp | 39 - .../unique.ptr.single.dtor/null.pass.cpp | 44 - .../release.pass.cpp | 27 - .../reset1.pass.cpp | 48 - .../reset2.pass.cpp | 64 - .../reset_self.pass.cpp | 29 - .../unique.ptr.single.modifiers/swap.pass.cpp | 59 - .../dereference.pass.cpp | 23 - .../explicit_bool.pass.cpp | 39 - .../unique.ptr.single.observers/get.pass.cpp | 24 - .../get_deleter.pass.cpp | 37 - .../index.fail.cpp | 47 - .../op_arrow.pass.cpp | 30 - .../unique.ptr.special/cmp_nullptr.pass.cpp | 71 - .../unique.ptr/unique.ptr.special/eq.pass.cpp | 86 - .../unique.ptr.special/rel.pass.cpp | 100 - .../unique.ptr.special/swap.pass.cpp | 77 - .../declare_no_pointers.pass.cpp | 23 - .../declare_reachable.pass.cpp | 24 - .../get_pointer_safety.pass.cpp | 23 - .../util.smartptr/nothing_to_do.pass.cpp | 12 - .../enable_shared_from_this.pass.cpp | 49 - .../hash_shared_ptr.pass.cpp | 30 - .../hash_unique_ptr.pass.cpp | 30 - .../util.smartptr.shared/test_allocator.h | 77 - .../util.smartptr.shared/test_deleter.h | 60 - .../util.smartptr.shared/types.pass.cpp | 26 - .../get_deleter.pass.cpp | 67 - .../auto_ptr_Y.pass.cpp | 113 - .../shared_ptr.pass.cpp | 121 - .../shared_ptr_Y.pass.cpp | 121 - .../shared_ptr_Y_rv.pass.cpp | 123 - .../shared_ptr_rv.pass.cpp | 123 - .../unique_ptr_Y.pass.cpp | 113 - .../const_pointer_cast.pass.cpp | 57 - .../dynamic_pointer_cast.pass.cpp | 57 - .../static_pointer_cast.pass.cpp | 69 - .../cmp_nullptr.pass.cpp | 71 - .../util.smartptr.shared.cmp/eq.pass.cpp | 31 - .../util.smartptr.shared.cmp/lt.pass.cpp | 30 - .../auto_ptr.pass.cpp | 102 - .../default.pass.cpp | 22 - .../nullptr_t.pass.cpp | 22 - .../nullptr_t_deleter.pass.cpp | 47 - .../nullptr_t_deleter_allocator.pass.cpp | 50 - ...nullptr_t_deleter_allocator_throw.pass.cpp | 46 - .../nullptr_t_deleter_throw.pass.cpp | 61 - .../pointer.pass.cpp | 46 - .../pointer_deleter.pass.cpp | 48 - .../pointer_deleter_allocator.pass.cpp | 51 - .../pointer_deleter_allocator_throw.pass.cpp | 47 - .../pointer_deleter_throw.pass.cpp | 62 - .../pointer_throw.pass.cpp | 60 - .../shared_ptr.pass.cpp | 62 - .../shared_ptr_Y.pass.cpp | 97 - .../shared_ptr_Y_rv.pass.cpp | 109 - .../shared_ptr_pointer.pass.cpp | 61 - .../shared_ptr_rv.pass.cpp | 73 - .../unique_ptr.pass.cpp | 92 - .../weak_ptr.pass.cpp | 79 - .../allocate_shared.pass.cpp | 57 - .../make_shared.pass.cpp | 77 - .../tested_elsewhere.pass.cpp | 12 - .../util.smartptr.shared.io/io.pass.cpp | 29 - .../util.smartptr.shared.mod/reset.pass.cpp | 62 - .../reset_pointer.pass.cpp | 64 - .../reset_pointer_deleter.pass.cpp | 79 - .../reset_pointer_deleter_allocator.pass.cpp | 88 - .../util.smartptr.shared.mod/swap.pass.cpp | 104 - .../util.smartptr.shared.obs/arrow.pass.cpp | 29 - .../dereference.pass.cpp | 25 - .../util.smartptr.shared.obs/op_bool.pass.cpp | 29 - .../owner_before_shared_ptr.pass.cpp | 28 - .../owner_before_weak_ptr.pass.cpp | 31 - .../util.smartptr.shared.obs/unique.pass.cpp | 28 - .../util.smartptr.shared.spec/swap.pass.cpp | 104 - .../util.smartptr.weak/types.pass.cpp | 26 - .../owner_less.pass.cpp | 74 - .../shared_ptr_Y.pass.cpp | 61 - .../weak_ptr.pass.cpp | 62 - .../weak_ptr_Y.pass.cpp | 62 - .../util.smartptr.weak.const/default.pass.cpp | 25 - .../shared_ptr_Y.pass.cpp | 95 - .../weak_ptr.pass.cpp | 93 - .../weak_ptr_Y.pass.cpp | 95 - .../tested_elsewhere.pass.cpp | 12 - .../util.smartptr.weak.mod/reset.pass.cpp | 41 - .../util.smartptr.weak.mod/swap.pass.cpp | 49 - .../util.smartptr.weak.obs/expired.pass.cpp | 46 - .../util.smartptr.weak.obs/lock.pass.cpp | 58 - .../not_less_than.fail.cpp | 27 - .../owner_before_shared_ptr.pass.cpp | 31 - .../owner_before_weak_ptr.pass.cpp | 31 - .../util.smartptr.weak.spec/swap.pass.cpp | 49 - .../bad_weak_ptr.pass.cpp | 31 - libcxx/test/utilities/memory/version.pass.cpp | 20 - .../meta/meta.hel/integral_constant.pass.cpp | 42 - .../meta/meta.rel/is_base_of.pass.cpp | 49 - .../meta/meta.rel/is_convertible.pass.cpp | 382 - .../utilities/meta/meta.rel/is_same.pass.cpp | 59 - .../meta/meta.rqmts/nothing_to_do.pass.cpp | 12 - .../remove_all_extents.pass.cpp | 32 - .../meta.trans.arr/remove_extent.pass.cpp | 32 - .../meta.trans.cv/add_const.pass.cpp | 40 - .../meta.trans/meta.trans.cv/add_cv.pass.cpp | 40 - .../meta.trans.cv/add_volatile.pass.cpp | 40 - .../meta.trans.cv/remove_const.pass.cpp | 40 - .../meta.trans.cv/remove_cv.pass.cpp | 40 - .../meta.trans.cv/remove_volatile.pass.cpp | 40 - .../meta.trans.other/aligned_storage.pass.cpp | 123 - .../meta.trans.other/common_type.pass.cpp | 26 - .../meta.trans.other/conditional.pass.cpp | 20 - .../meta.trans.other/decay.pass.cpp | 31 - .../meta.trans.other/enable_if.fail.cpp | 19 - .../meta.trans.other/enable_if.pass.cpp | 20 - .../meta.trans.other/result_of.pass.cpp | 43 - .../meta.trans.other/underlying_type.pass.cpp | 33 - .../meta.trans.ptr/add_pointer.pass.cpp | 31 - .../meta.trans.ptr/remove_pointer.pass.cpp | 40 - .../meta.trans.ref/add_lvalue_ref.pass.cpp | 31 - .../meta.trans.ref/add_rvalue_ref.pass.cpp | 37 - .../meta.trans.ref/remove_ref.pass.cpp | 43 - .../meta.trans.sign/make_signed.pass.cpp | 42 - .../meta.trans.sign/make_unsigned.pass.cpp | 42 - .../meta/meta.trans/nothing_to_do.pass.cpp | 12 - .../meta.type.synop/nothing_to_do.pass.cpp | 12 - .../alignment_of.pass.cpp | 42 - .../meta.unary.prop.query/extent.pass.cpp | 60 - .../meta/meta.unary.prop.query/rank.pass.cpp | 46 - .../meta.unary/meta.unary.cat/array.pass.cpp | 52 - .../meta.unary/meta.unary.cat/class.pass.cpp | 52 - .../meta.unary/meta.unary.cat/enum.pass.cpp | 48 - .../meta.unary.cat/floating_point.pass.cpp | 48 - .../meta.unary.cat/function.pass.cpp | 49 - .../meta.unary.cat/integral.pass.cpp | 58 - .../meta.unary.cat/lvalue_ref.pass.cpp | 38 - .../member_function_pointer.pass.cpp | 52 - .../member_object_pointer.pass.cpp | 50 - .../meta.unary.cat/pointer.pass.cpp | 49 - .../meta.unary.cat/rvalue_ref.pass.cpp | 40 - .../meta.unary/meta.unary.cat/union.pass.cpp | 52 - .../meta.unary/meta.unary.cat/void.pass.cpp | 46 - .../meta.unary/meta.unary.comp/array.pass.cpp | 46 - .../meta.unary/meta.unary.comp/class.pass.cpp | 46 - .../meta.unary/meta.unary.comp/enum.pass.cpp | 42 - .../meta.unary.comp/floating_point.pass.cpp | 42 - .../meta.unary.comp/function.pass.cpp | 43 - .../meta.unary.comp/integral.pass.cpp | 52 - .../meta.unary.comp/lvalue_ref.pass.cpp | 32 - .../member_function_pointer.pass.cpp | 46 - .../member_object_pointer.pass.cpp | 44 - .../meta.unary.comp/pointer.pass.cpp | 43 - .../meta.unary.comp/rvalue_ref.pass.cpp | 34 - .../meta.unary/meta.unary.comp/union.pass.cpp | 46 - .../meta.unary/meta.unary.comp/void.pass.cpp | 40 - .../has_virtual_destructor.pass.cpp | 77 - .../meta.unary.prop/is_abstract.pass.cpp | 71 - .../meta.unary.prop/is_assignable.pass.cpp | 38 - .../meta.unary.prop/is_const.pass.cpp | 37 - .../meta.unary.prop/is_constructible.pass.cpp | 37 - .../is_copy_assignable.pass.cpp | 57 - .../is_copy_constructible.pass.cpp | 73 - .../is_default_constructible.pass.cpp | 76 - .../meta.unary.prop/is_destructible.pass.cpp | 66 - .../meta.unary.prop/is_empty.pass.cpp | 65 - .../meta.unary.prop/is_literal_type.pass.cpp | 33 - .../is_move_assignable.pass.cpp | 51 - .../is_move_constructible.pass.cpp | 73 - .../is_nothrow_assignable.pass.cpp | 34 - .../is_nothrow_constructible.pass.cpp | 52 - .../is_nothrow_copy_assignable.pass.cpp | 58 - .../is_nothrow_copy_constructible.pass.cpp | 61 - .../is_nothrow_default_constructible.pass.cpp | 64 - .../is_nothrow_destructible.pass.cpp | 77 - .../is_nothrow_move_assignable.pass.cpp | 57 - .../is_nothrow_move_constructible.pass.cpp | 61 - .../meta.unary.prop/is_pod.pass.cpp | 52 - .../meta.unary.prop/is_polymorphic.pass.cpp | 71 - .../meta.unary.prop/is_signed.pass.cpp | 54 - .../is_standard_layout.pass.cpp | 30 - .../meta.unary.prop/is_trivial.pass.cpp | 31 - .../is_trivialially_copyable.pass.cpp | 44 - .../is_trivially_assignable.pass.cpp | 34 - .../is_trivially_constructible.pass.cpp | 30 - .../is_trivially_copy_assignable.pass.cpp | 64 - .../is_trivially_copy_constructible.pass.cpp | 73 - ...s_trivially_default_constructible.pass.cpp | 76 - .../is_trivially_destructible.pass.cpp | 77 - .../is_trivially_move_assignable.pass.cpp | 64 - .../is_trivially_move_constructible.pass.cpp | 89 - .../meta.unary.prop/is_unsigned.pass.cpp | 54 - .../meta.unary.prop/is_volatile.pass.cpp | 37 - .../meta/meta.unary/nothing_to_do.pass.cpp | 12 - libcxx/test/utilities/meta/version.pass.cpp | 20 - libcxx/test/utilities/nothing_to_do.pass.cpp | 12 - .../ratio/ratio.arithmetic/ratio_add.fail.cpp | 19 - .../ratio/ratio.arithmetic/ratio_add.pass.cpp | 76 - .../ratio.arithmetic/ratio_divide.fail.cpp | 19 - .../ratio.arithmetic/ratio_divide.pass.cpp | 58 - .../ratio.arithmetic/ratio_multiply.fail.cpp | 19 - .../ratio.arithmetic/ratio_multiply.pass.cpp | 58 - .../ratio.arithmetic/ratio_subtract.fail.cpp | 19 - .../ratio.arithmetic/ratio_subtract.pass.cpp | 76 - .../ratio.comparison/ratio_equal.pass.cpp | 56 - .../ratio.comparison/ratio_greater.pass.cpp | 56 - .../ratio_greater_equal.pass.cpp | 56 - .../ratio.comparison/ratio_less.pass.cpp | 86 - .../ratio_less_equal.pass.cpp | 56 - .../ratio.comparison/ratio_not_equal.pass.cpp | 56 - .../ratio/ratio.ratio/ratio.pass.cpp | 44 - .../ratio/ratio.ratio/ratio1.fail.cpp | 18 - .../ratio/ratio.ratio/ratio2.fail.cpp | 19 - .../ratio/ratio.ratio/ratio3.fail.cpp | 19 - .../ratio/ratio.si/nothing_to_do.pass.cpp | 12 - libcxx/test/utilities/ratio/typedefs.pass.cpp | 32 - libcxx/test/utilities/ratio/version.pass.cpp | 20 - .../bitset.cons/char_ptr_ctor.pass.cpp | 56 - .../bitset.cons/default.pass.cpp | 39 - .../bitset.cons/string_ctor.pass.cpp | 88 - .../bitset.cons/ull_ctor.pass.cpp | 42 - .../bitset.hash/bitset.pass.cpp | 44 - .../bitset.members/all.pass.cpp | 41 - .../bitset.members/any.pass.cpp | 44 - .../bitset.members/count.pass.cpp | 51 - .../bitset.members/flip_all.pass.cpp | 49 - .../bitset.members/flip_one.pass.cpp | 60 - .../bitset.members/index.pass.cpp | 67 - .../bitset.members/index_const.pass.cpp | 49 - .../bitset.members/left_shift.pass.cpp | 50 - .../bitset.members/left_shift_eq.pass.cpp | 55 - .../bitset.members/none.pass.cpp | 44 - .../bitset.members/not_all.pass.cpp | 48 - .../bitset.members/op_and_eq.pass.cpp | 50 - .../bitset.members/op_eq_eq.pass.cpp | 55 - .../bitset.members/op_or_eq.pass.cpp | 50 - .../bitset.members/op_xor_eq.pass.cpp | 50 - .../bitset.members/reset_all.pass.cpp | 38 - .../bitset.members/reset_one.pass.cpp | 47 - .../bitset.members/right_shift.pass.cpp | 50 - .../bitset.members/right_shift_eq.pass.cpp | 55 - .../bitset.members/set_all.pass.cpp | 37 - .../bitset.members/set_one.pass.cpp | 52 - .../bitset.members/size.pass.cpp | 33 - .../bitset.members/test.pass.cpp | 55 - .../bitset.members/to_string.pass.cpp | 162 - .../bitset.members/to_ullong.pass.cpp | 50 - .../bitset.members/to_ulong.pass.cpp | 50 - .../bitset.operators/op_and.pass.cpp | 48 - .../bitset.operators/op_not.pass.cpp | 48 - .../bitset.operators/op_or.pass.cpp | 48 - .../bitset.operators/stream_in.pass.cpp | 26 - .../bitset.operators/stream_out.pass.cpp | 26 - .../template.bitset/includes.pass.cpp | 32 - .../template.bitset/version.pass.cpp | 20 - libcxx/test/utilities/time/clock.h | 17 - libcxx/test/utilities/time/hours.pass.cpp | 27 - .../test/utilities/time/microseconds.pass.cpp | 27 - .../test/utilities/time/milliseconds.pass.cpp | 27 - libcxx/test/utilities/time/minutes.pass.cpp | 27 - .../test/utilities/time/nanoseconds.pass.cpp | 27 - libcxx/test/utilities/time/rep.h | 18 - libcxx/test/utilities/time/seconds.pass.cpp | 27 - .../time.clock.req/nothing_to_do.pass.cpp | 12 - .../time/time.clock/nothing_to_do.pass.cpp | 12 - .../time.clock.hires/consistency.pass.cpp | 25 - .../time.clock/time.clock.hires/now.pass.cpp | 22 - .../time.clock.steady/consistency.pass.cpp | 25 - .../time.clock/time.clock.steady/now.pass.cpp | 25 - .../time.clock.system/consistency.pass.cpp | 26 - .../time.clock.system/from_time_t.pass.cpp | 23 - .../time.clock/time.clock.system/now.pass.cpp | 22 - .../time.clock.system/rep_signed.pass.cpp | 23 - .../time.clock.system/to_time_t.pass.cpp | 23 - .../time/time.duration/default_ratio.pass.cpp | 26 - .../time/time.duration/duration.fail.cpp | 23 - .../time/time.duration/positive_num.fail.cpp | 22 - .../time/time.duration/ratio.fail.cpp | 30 - .../time.duration.arithmetic/op_++.pass.cpp | 25 - .../op_++int.pass.cpp | 25 - .../time.duration.arithmetic/op_+.pass.cpp | 24 - .../time.duration.arithmetic/op_+=.pass.cpp | 26 - .../time.duration.arithmetic/op_--.pass.cpp | 25 - .../op_--int.pass.cpp | 25 - .../time.duration.arithmetic/op_-.pass.cpp | 24 - .../time.duration.arithmetic/op_-=.pass.cpp | 26 - .../op_divide=.pass.cpp | 24 - .../op_mod=duration.pass.cpp | 27 - .../op_mod=rep.pass.cpp | 24 - .../op_times=.pass.cpp | 24 - .../time.duration.cast/duration_cast.pass.cpp | 43 - .../time.duration.cast/toduration.fail.cpp | 25 - .../op_equal.pass.cpp | 69 - .../op_less.pass.cpp | 91 - .../time.duration.cons/convert_exact.pass.cpp | 27 - .../convert_float_to_int.fail.cpp | 25 - .../convert_inexact.fail.cpp | 25 - .../convert_inexact.pass.cpp | 27 - .../convert_int_to_float.pass.cpp | 27 - .../time.duration.cons/default.pass.cpp | 34 - .../time.duration.cons/rep.pass.cpp | 36 - .../time.duration.cons/rep01.fail.cpp | 26 - .../time.duration.cons/rep02.fail.cpp | 26 - .../time.duration.cons/rep02.pass.cpp | 26 - .../time.duration.cons/rep03.fail.cpp | 24 - .../time.duration.nonmember/op_+.pass.cpp | 47 - .../time.duration.nonmember/op_-.pass.cpp | 47 - .../op_divide_duration.pass.cpp | 43 - .../op_divide_rep.fail.cpp | 26 - .../op_divide_rep.pass.cpp | 26 - .../op_mod_duration.pass.cpp | 41 - .../op_mod_rep.fail.cpp | 26 - .../op_mod_rep.pass.cpp | 26 - .../op_times_rep.pass.cpp | 32 - .../op_times_rep1.fail.cpp | 30 - .../op_times_rep2.fail.cpp | 30 - .../tested_elsewhere.pass.cpp | 12 - .../time.duration.special/max.pass.cpp | 34 - .../time.duration.special/min.pass.cpp | 34 - .../time.duration.special/zero.pass.cpp | 33 - .../time/time.duration/types.pass.cpp | 27 - .../time/time.point/default_duration.pass.cpp | 26 - .../time/time.point/duration.fail.cpp | 22 - .../time.point.arithmetic/op_+=.pass.cpp | 26 - .../time.point.arithmetic/op_-=.pass.cpp | 26 - .../time.point.cast/time_point_cast.pass.cpp | 48 - .../time.point.cast/toduration.fail.cpp | 28 - .../time.point.comparisons/op_equal.fail.cpp | 40 - .../time.point.comparisons/op_equal.pass.cpp | 57 - .../time.point.comparisons/op_less.fail.cpp | 48 - .../time.point.comparisons/op_less.pass.cpp | 73 - .../time.point.cons/convert.fail.cpp | 30 - .../time.point.cons/convert.pass.cpp | 30 - .../time.point.cons/default.pass.cpp | 27 - .../time.point.cons/duration.fail.cpp | 25 - .../time.point.cons/duration.pass.cpp | 31 - .../time.point.nonmember/op_+.pass.cpp | 35 - .../op_-duration.pass.cpp | 29 - .../op_-time_point.pass.cpp | 29 - .../tested_elsewhere.pass.cpp | 12 - .../time.point.special/max.pass.cpp | 25 - .../time.point.special/min.pass.cpp | 25 - .../time/time.traits/nothing_to_do.pass.cpp | 12 - .../time.traits.duration_values/max.pass.cpp | 28 - .../time.traits.duration_values/min.pass.cpp | 28 - .../time.traits.duration_values/zero.pass.cpp | 23 - .../treat_as_floating_point.pass.cpp | 37 - .../duration.pass.cpp | 42 - .../time_point.pass.cpp | 46 - libcxx/test/utilities/time/version.pass.cpp | 20 - .../tuple.general/nothing_to_do.pass.cpp | 12 - .../utilities/tuple/tuple.tuple/DefaultOnly.h | 26 - .../utilities/tuple/tuple.tuple/MoveOnly.h | 41 - .../utilities/tuple/tuple.tuple/alloc_first.h | 49 - .../utilities/tuple/tuple.tuple/alloc_last.h | 49 - .../utilities/tuple/tuple.tuple/allocators.h | 174 - .../tuple/tuple.tuple/empty_member.pass.cpp | 44 - .../tuple.assign/const_pair.pass.cpp | 32 - .../tuple.assign/convert_copy.pass.cpp | 75 - .../tuple.assign/convert_move.pass.cpp | 88 - .../tuple.tuple/tuple.assign/copy.fail.cpp | 29 - .../tuple.tuple/tuple.assign/copy.pass.cpp | 52 - .../tuple.tuple/tuple.assign/move.pass.cpp | 53 - .../tuple.assign/move_pair.pass.cpp | 48 - .../tuple.tuple/tuple.cnstr/UTypes.fail.cpp | 49 - .../tuple.tuple/tuple.cnstr/UTypes.pass.cpp | 55 - .../tuple.tuple/tuple.cnstr/alloc.pass.cpp | 79 - .../tuple.cnstr/alloc_UTypes.pass.cpp | 71 - .../tuple.cnstr/alloc_const_Types.pass.cpp | 74 - .../tuple.cnstr/alloc_const_pair.pass.cpp | 57 - .../tuple.cnstr/alloc_convert_copy.pass.cpp | 67 - .../tuple.cnstr/alloc_convert_move.pass.cpp | 82 - .../tuple.cnstr/alloc_copy.pass.cpp | 76 - .../tuple.cnstr/alloc_move.pass.cpp | 75 - .../tuple.cnstr/alloc_move_pair.pass.cpp | 53 - .../tuple.cnstr/const_Types.fail.cpp | 25 - .../tuple.cnstr/const_Types.pass.cpp | 62 - .../tuple.cnstr/const_Types2.fail.cpp | 25 - .../tuple.cnstr/const_pair.pass.cpp | 30 - .../tuple.cnstr/convert_copy.pass.cpp | 70 - .../tuple.cnstr/convert_move.pass.cpp | 82 - .../tuple.tuple/tuple.cnstr/copy.fail.cpp | 28 - .../tuple.tuple/tuple.cnstr/copy.pass.cpp | 48 - .../tuple.tuple/tuple.cnstr/default.pass.cpp | 49 - .../tuple.tuple/tuple.cnstr/move.pass.cpp | 49 - .../tuple.cnstr/move_pair.pass.cpp | 46 - .../tuple.creation/forward_as_tuple.pass.cpp | 71 - .../tuple.creation/make_tuple.pass.cpp | 41 - .../tuple.tuple/tuple.creation/tie.pass.cpp | 30 - .../tuple.creation/tuple_cat.pass.cpp | 190 - .../tuple.tuple/tuple.elem/get_const.fail.cpp | 39 - .../tuple.tuple/tuple.elem/get_const.pass.cpp | 48 - .../tuple.elem/get_non_const.pass.cpp | 56 - .../tuple.tuple/tuple.elem/get_rv.pass.cpp | 30 - .../tuple.helper/tuple_element.pass.cpp | 40 - .../tuple.helper/tuple_size.pass.cpp | 40 - .../tuple/tuple.tuple/tuple.rel/eq.pass.cpp | 144 - .../tuple/tuple.tuple/tuple.rel/lt.pass.cpp | 196 - .../tuple.special/non_member_swap.pass.cpp | 60 - .../tuple.swap/member_swap.pass.cpp | 59 - .../tuple.traits/uses_allocator.pass.cpp | 44 - libcxx/test/utilities/tuple/version.pass.cpp | 20 - .../type.index/type.index.hash/hash.pass.cpp | 28 - .../type.index.members/ctor.pass.cpp | 22 - .../type.index/type.index.members/eq.pass.cpp | 27 - .../type.index.members/hash_code.pass.cpp | 24 - .../type.index/type.index.members/lt.pass.cpp | 45 - .../type.index.members/name.pass.cpp | 25 - .../type.index.overview/copy_assign.pass.cpp | 26 - .../type.index.overview/copy_ctor.pass.cpp | 24 - .../hash_type_index.pass.cpp | 25 - .../utilities/type.index/version.pass.cpp | 20 - .../utilities.general/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../hash.requirements/nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../nothing_to_do.pass.cpp | 12 - .../utility/declval/declval.pass.cpp | 30 - .../utility/forward/forward.pass.cpp | 73 - .../utility/forward/forward1.fail.cpp | 24 - .../utility/forward/forward2.fail.cpp | 25 - .../utility/forward/forward3.fail.cpp | 24 - .../utility/forward/forward4.fail.cpp | 25 - .../utility/forward/forward5.fail.cpp | 25 - .../utility/forward/forward6.fail.cpp | 22 - .../utility/forward/move_copy.pass.cpp | 71 - .../utility/forward/move_if_noexcept.pass.cpp | 63 - .../utility/forward/move_only.pass.cpp | 49 - .../utility/forward/move_only1.fail.cpp | 52 - .../utility/forward/move_only2.fail.cpp | 52 - .../utility/forward/move_only3.fail.cpp | 49 - .../utility/forward/move_only4.fail.cpp | 52 - .../utility/operators/rel_ops.pass.cpp | 49 - .../utility/pairs/nothing_to_do.pass.cpp | 12 - .../pairs/pair.astuple/get_const.fail.cpp | 30 - .../pairs/pair.astuple/get_const.pass.cpp | 29 - .../pairs/pair.astuple/get_non_const.pass.cpp | 33 - .../pairs/pair.astuple/get_rv.pass.cpp | 32 - .../pairs/pair.astuple/tuple_element.pass.cpp | 30 - .../pairs/pair.astuple/tuple_size.pass.cpp | 24 - .../piecewise_construct.pass.cpp | 55 - .../pairs.general/nothing_to_do.pass.cpp | 12 - .../utility/pairs/pairs.pair/U_V.pass.cpp | 30 - .../pairs.pair/assign_const_pair_U_V.pass.cpp | 30 - .../pairs/pairs.pair/assign_rv_pair.pass.cpp | 32 - .../pairs.pair/assign_rv_pair_U_V.pass.cpp | 43 - .../const_first_const_second.pass.cpp | 42 - .../pairs/pairs.pair/const_pair_U_V.pass.cpp | 29 - .../pairs/pairs.pair/copy_ctor.pass.cpp | 28 - .../utility/pairs/pairs.pair/default.pass.cpp | 25 - .../pairs/pairs.pair/piecewise.pass.cpp | 35 - .../pairs/pairs.pair/rv_pair_U_V.pass.cpp | 42 - .../utility/pairs/pairs.pair/swap.pass.cpp | 31 - .../utility/pairs/pairs.pair/types.pass.cpp | 26 - .../pairs/pairs.spec/comparison.pass.cpp | 81 - .../pairs/pairs.spec/make_pair.pass.cpp | 40 - .../pairs/pairs.spec/non_member_swap.pass.cpp | 31 - .../utility/utility.swap/swap.pass.cpp | 53 - .../utility/utility.swap/swap_array.pass.cpp | 65 - .../test/utilities/utility/version.pass.cpp | 20 - libcxx/www/atomic_design.html | 92 - libcxx/www/atomic_design_a.html | 309 - libcxx/www/atomic_design_b.html | 250 - libcxx/www/atomic_design_c.html | 458 - libcxx/www/content.css | 27 - libcxx/www/index.html | 225 - libcxx/www/libcxx_by_chapter.pdf | Bin 36793 -> 0 bytes libcxx/www/menu.css | 39 - libcxx/www/results.Windows.html | 670 - libcxx/www/type_traits_design.html | 286 - libcxxabi/CREDITS.TXT | 22 - libcxxabi/LICENSE.TXT | 76 - libcxxabi/include/cxa_demangle.h | 167 - libcxxabi/include/cxxabi.h | 175 - libcxxabi/lib/buildit | 99 - libcxxabi/src/abort_message.cpp | 50 - libcxxabi/src/abort_message.h | 33 - libcxxabi/src/cxa_aux_runtime.cpp | 34 - libcxxabi/src/cxa_default_handlers.cpp | 124 - libcxxabi/src/cxa_demangle.cpp | 10878 ------ libcxxabi/src/cxa_exception.cpp | 622 - libcxxabi/src/cxa_exception.hpp | 123 - libcxxabi/src/cxa_exception_storage.cpp | 91 - libcxxabi/src/cxa_guard.cpp | 231 - libcxxabi/src/cxa_handlers.cpp | 125 - libcxxabi/src/cxa_handlers.hpp | 54 - libcxxabi/src/cxa_new_delete.cpp | 231 - libcxxabi/src/cxa_personality.cpp | 1051 - libcxxabi/src/cxa_unexpected.cpp | 27 - libcxxabi/src/cxa_vector.cpp | 367 - libcxxabi/src/cxa_virtual.cpp | 31 - libcxxabi/src/exception.cpp | 41 - libcxxabi/src/fallback_malloc.ipp | 174 - libcxxabi/src/private_typeinfo.cpp | 1052 - libcxxabi/src/private_typeinfo.h | 248 - libcxxabi/src/stdexcept.cpp | 122 - libcxxabi/src/typeinfo.cpp | 53 - libcxxabi/test/catch_array_01.cpp | 30 - libcxxabi/test/catch_array_02.cpp | 30 - libcxxabi/test/catch_class_01.cpp | 58 - libcxxabi/test/catch_class_02.cpp | 83 - libcxxabi/test/catch_class_03.cpp | 190 - libcxxabi/test/catch_class_04.cpp | 213 - .../test/catch_const_pointer_nullptr.cpp | 133 - libcxxabi/test/catch_function_01.cpp | 31 - libcxxabi/test/catch_function_02.cpp | 31 - .../test/catch_member_data_pointer_01.cpp | 57 - .../test/catch_member_function_pointer_01.cpp | 57 - .../test/catch_member_pointer_nullptr.cpp | 71 - libcxxabi/test/catch_pointer_nullptr.cpp | 64 - libcxxabi/test/catch_ptr.cpp | 181 - libcxxabi/test/catch_ptr_02.cpp | 86 - libcxxabi/test/dynamic_cast14.cpp | 2189 -- libcxxabi/test/dynamic_cast3.cpp | 2461 -- libcxxabi/test/dynamic_cast5.cpp | 1321 - libcxxabi/test/dynamic_cast_stress.cpp | 81 - libcxxabi/test/test_aux_runtime.cpp | 64 - libcxxabi/test/test_demangle.cpp | 29643 ---------------- libcxxabi/test/test_exception_storage.cpp | 74 - libcxxabi/test/test_fallback_malloc.cpp | 189 - libcxxabi/test/test_guard.cpp | 134 - libcxxabi/test/test_vector1.cpp | 262 - libcxxabi/test/test_vector2.cpp | 83 - libcxxabi/test/test_vector3.cpp | 57 - libcxxabi/test/testit | 127 - libcxxabi/test/unwind_01.cpp | 96 - libcxxabi/test/unwind_02.cpp | 96 - libcxxabi/test/unwind_03.cpp | 102 - libcxxabi/test/unwind_04.cpp | 108 - libcxxabi/test/unwind_05.cpp | 112 - libcxxabi/www/content.css | 27 - libcxxabi/www/index.html | 87 - libcxxabi/www/menu.css | 39 - libcxxabi/www/spec.html | 1016 - lld/.gitignore | 22 - lld/CMakeLists.txt | 131 - lld/LICENSE.TXT | 62 - lld/README.md | 10 - lld/docs/Makefile | 155 - lld/docs/README.txt | 7 - lld/docs/_static/favicon.ico | Bin 1150 -> 0 bytes lld/docs/_templates/indexsidebar.html | 4 - lld/docs/_templates/layout.html | 12 - lld/docs/conf.py | 251 - lld/docs/design.rst | 405 - lld/docs/development.rst | 13 - lld/docs/hello.png | Bin 27616 -> 0 bytes lld/docs/index.rst | 79 - lld/docs/llvm-theme/layout.html | 22 - lld/docs/llvm-theme/static/contents.png | Bin 202 -> 0 bytes lld/docs/llvm-theme/static/llvm.css | 345 - lld/docs/llvm-theme/static/logo.png | Bin 9864 -> 0 bytes lld/docs/llvm-theme/static/navigation.png | Bin 218 -> 0 bytes lld/docs/llvm-theme/theme.conf | 4 - lld/docs/make.bat | 190 - lld/docs/open_projects.rst | 13 - lld/docs/sphinx_intro.rst | 147 - lld/include/lld/Core/AbsoluteAtom.h | 35 - lld/include/lld/Core/AliasAtom.h | 56 - lld/include/lld/Core/Atom.h | 73 - lld/include/lld/Core/DefinedAtom.h | 315 - lld/include/lld/Core/Error.h | 76 - lld/include/lld/Core/File.h | 185 - lld/include/lld/Core/InputFiles.h | 51 - lld/include/lld/Core/LLVM.h | 75 - lld/include/lld/Core/NativeReader.h | 40 - lld/include/lld/Core/NativeWriter.h | 34 - lld/include/lld/Core/Pass.h | 79 - lld/include/lld/Core/Platform.h | 174 - lld/include/lld/Core/Reference.h | 78 - lld/include/lld/Core/Resolver.h | 131 - lld/include/lld/Core/SharedLibraryAtom.h | 46 - lld/include/lld/Core/SymbolTable.h | 103 - lld/include/lld/Core/TODO.txt | 17 - lld/include/lld/Core/UndefinedAtom.h | 66 - lld/include/lld/Core/YamlReader.h | 48 - lld/include/lld/Core/YamlWriter.h | 31 - lld/lib/CMakeLists.txt | 3 - lld/lib/Core/CMakeLists.txt | 14 - lld/lib/Core/Error.cpp | 92 - lld/lib/Core/File.cpp | 25 - lld/lib/Core/NativeFileFormat.h | 243 - lld/lib/Core/NativeReader.cpp | 839 - lld/lib/Core/NativeWriter.cpp | 555 - lld/lib/Core/Platform.cpp | 19 - lld/lib/Core/Resolver.cpp | 407 - lld/lib/Core/SymbolTable.cpp | 306 - lld/lib/Core/TODO.txt | 26 - lld/lib/Core/YamlKeyValues.cpp | 435 - lld/lib/Core/YamlKeyValues.h | 99 - lld/lib/Core/YamlReader.cpp | 1010 - lld/lib/Core/YamlWriter.cpp | 489 - lld/lib/Passes/CMakeLists.txt | 4 - lld/lib/Passes/GOTPass.cpp | 112 - lld/lib/Passes/StubsPass.cpp | 71 - lld/lib/Platforms/CMakeLists.txt | 1 - lld/lib/Platforms/Darwin/CMakeLists.txt | 5 - lld/lib/Platforms/Darwin/DarwinPlatform.cpp | 264 - lld/lib/Platforms/Darwin/DarwinPlatform.h | 87 - .../Platforms/Darwin/DarwinReferenceKinds.cpp | 89 - .../Platforms/Darwin/DarwinReferenceKinds.h | 54 - lld/lib/Platforms/Darwin/ExecutableWriter.cpp | 1436 - lld/lib/Platforms/Darwin/ExecutableWriter.h | 35 - lld/lib/Platforms/Darwin/MachOFormat.hpp | 346 - lld/lib/Platforms/Darwin/StubAtoms.hpp | 372 - lld/test/CMakeLists.txt | 55 - lld/test/absolute-basic.objtxt | 25 - lld/test/auto-hide-coalesce.objtxt | 68 - lld/test/cstring-coalesce.objtxt | 37 - lld/test/custom-section.objtxt | 34 - lld/test/darwin/hello-world.objtxt | 35 - lld/test/dead-strip-attributes.objtxt | 29 - lld/test/empty.objtxt | 11 - lld/test/fixups-addend.objtxt | 50 - lld/test/fixups-dup-named.objtxt | 31 - lld/test/fixups-named.objtxt | 35 - lld/test/fixups-unnamed.objtxt | 40 - lld/test/inline-coalesce.objtxt | 34 - lld/test/lit.cfg | 110 - lld/test/lit.site.cfg.in | 21 - lld/test/multiple-def-error.objtxt | 21 - lld/test/pass-got-basic.objtxt | 81 - lld/test/pass-stubs-basic.objtxt | 50 - lld/test/shared-library-basic.objtxt | 34 - lld/test/shared-library-coalesce.objtxt | 110 - lld/test/tent-merge.objtxt | 27 - lld/test/undef-coalesce.objtxt | 46 - lld/test/undef-weak-coalesce.objtxt | 117 - lld/test/weak-coalesce.objtxt | 33 - lld/tools/CMakeLists.txt | 2 - lld/tools/lld-core/CMakeLists.txt | 16 - lld/tools/lld-core/lld-core.cpp | 604 - lld/tools/lld/CMakeLists.txt | 6 - lld/tools/lld/TODO.txt | 14 - lld/tools/lld/lld.cpp | 17 - lld/utils/astyle-options | 7 - lldb/.gitignore | 6 - lldb/INSTALL.txt | 9 - lldb/LICENSE.TXT | 38 - lldb/Makefile | 105 - lldb/docs/building-with-debug-llvm.txt | 50 - lldb/docs/code-signing.txt | 53 - lldb/docs/lldb-for-gdb-users.txt | 488 - lldb/docs/lldb-gdb-remote.txt | 736 - ...gsCommandTestCase.test_set_output_path.log | 43 - .../docs/testsuite/a-detailed-walkthrough.txt | 309 - lldb/docs/testsuite/best-practices.txt | 93 - lldb/docs/try.me | 0 .../customization/bin-utils/.lldbinit | 5 - lldb/examples/customization/bin-utils/README | 36 - .../customization/bin-utils/binutils.py | 122 - .../customization/import-python/README | 40 - .../customization/import-python/importcmd.py | 31 - .../customization/pwd-cd-and-system/.lldbinit | 7 - .../customization/pwd-cd-and-system/README | 41 - .../customization/pwd-cd-and-system/utils.py | 49 - lldb/examples/darwin/heap_find/Makefile | 7 - lldb/examples/darwin/heap_find/heap.py | 221 - lldb/examples/darwin/heap_find/heap_find.cpp | 329 - .../darwin/fd_interposing/FDInterposing.cpp | 1152 - .../darwin/fd_interposing/Makefile | 7 - lldb/examples/lookup/Makefile | 13 - lldb/examples/lookup/main.cpp | 122 - lldb/examples/python/cmdtemplate.py | 50 - lldb/examples/python/crashlog.py | 473 - lldb/examples/python/delta.py | 115 - lldb/examples/python/disasm-stress-test.py | 168 - lldb/examples/python/disasm.py | 119 - lldb/examples/python/gdbremote.py | 197 - lldb/examples/python/sbvalue.py | 255 - lldb/examples/python/symbolication.py | 524 - lldb/examples/scripting/dictionary.c | 200 - lldb/examples/scripting/tree_utils.py | 118 - lldb/examples/summaries/cocoa/CFArray.py | 203 - lldb/examples/summaries/cocoa/CFBag.py | 145 - lldb/examples/summaries/cocoa/CFBinaryHeap.py | 141 - lldb/examples/summaries/cocoa/CFBitVector.py | 175 - lldb/examples/summaries/cocoa/CFDictionary.py | 233 - lldb/examples/summaries/cocoa/CFString.py | 320 - lldb/examples/summaries/cocoa/Class.py | 21 - lldb/examples/summaries/cocoa/Logger.py | 122 - lldb/examples/summaries/cocoa/NSBundle.py | 126 - lldb/examples/summaries/cocoa/NSData.py | 162 - lldb/examples/summaries/cocoa/NSDate.py | 264 - lldb/examples/summaries/cocoa/NSException.py | 114 - lldb/examples/summaries/cocoa/NSIndexSet.py | 142 - lldb/examples/summaries/cocoa/NSMachPort.py | 122 - .../summaries/cocoa/NSNotification.py | 109 - lldb/examples/summaries/cocoa/NSNumber.py | 232 - lldb/examples/summaries/cocoa/NSSet.py | 263 - lldb/examples/summaries/cocoa/NSURL.py | 134 - lldb/examples/summaries/cocoa/Selector.py | 14 - .../summaries/cocoa/attrib_fromdict.py | 38 - lldb/examples/summaries/cocoa/cache.py | 35 - lldb/examples/summaries/cocoa/metrics.py | 73 - lldb/examples/summaries/cocoa/objc_lldb.py | 133 - lldb/examples/summaries/cocoa/objc_runtime.py | 777 - lldb/examples/summaries/essentials | 5 - lldb/examples/summaries/lldb | 15 - lldb/examples/summaries/objc.py | 9 - lldb/examples/synthetic/bitfield/example.py | 94 - lldb/examples/synthetic/bitfield/program.cpp | 74 - lldb/examples/synthetic/gnu_libstdcpp.py | 414 - lldb/examples/synthetic/libcxx.py | 577 - lldb/examples/test/.lldb-pre-post-flight | 12 - lldb/examples/test/.lldb-pre-post-flight.bad | 8 - lldb/examples/test/.lldbtest-config | 6 - lldb/examples/test/.lldbtest-config2 | 19 - lldb/examples/test/lldbtest-stderr | 39 - lldb/examples/test/lldbtest-stdout | 0 lldb/examples/test/usage-config | 10 - lldb/examples/test/usage-pre-post-flight | 65 - lldb/include/Makefile | 13 - lldb/include/lldb/API/LLDB.h | 52 - lldb/include/lldb/API/SBAddress.h | 150 - lldb/include/lldb/API/SBBlock.h | 123 - lldb/include/lldb/API/SBBreakpoint.h | 163 - lldb/include/lldb/API/SBBreakpointLocation.h | 107 - lldb/include/lldb/API/SBBroadcaster.h | 97 - lldb/include/lldb/API/SBCommandInterpreter.h | 126 - lldb/include/lldb/API/SBCommandReturnObject.h | 114 - lldb/include/lldb/API/SBCommunication.h | 99 - lldb/include/lldb/API/SBCompileUnit.h | 98 - lldb/include/lldb/API/SBData.h | 180 - lldb/include/lldb/API/SBDebugger.h | 317 - lldb/include/lldb/API/SBDefines.h | 77 - lldb/include/lldb/API/SBError.h | 106 - lldb/include/lldb/API/SBEvent.h | 100 - lldb/include/lldb/API/SBFileSpec.h | 92 - lldb/include/lldb/API/SBFileSpecList.h | 72 - lldb/include/lldb/API/SBFrame.h | 231 - lldb/include/lldb/API/SBFunction.h | 90 - lldb/include/lldb/API/SBHostOS.h | 54 - lldb/include/lldb/API/SBInputReader.h | 97 - lldb/include/lldb/API/SBInstruction.h | 94 - lldb/include/lldb/API/SBInstructionList.h | 71 - lldb/include/lldb/API/SBLineEntry.h | 99 - lldb/include/lldb/API/SBListener.h | 135 - lldb/include/lldb/API/SBModule.h | 242 - lldb/include/lldb/API/SBProcess.h | 221 - lldb/include/lldb/API/SBSection.h | 97 - lldb/include/lldb/API/SBSourceManager.h | 53 - lldb/include/lldb/API/SBStream.h | 108 - lldb/include/lldb/API/SBStringList.h | 70 - lldb/include/lldb/API/SBSymbol.h | 106 - lldb/include/lldb/API/SBSymbolContext.h | 94 - lldb/include/lldb/API/SBSymbolContextList.h | 69 - lldb/include/lldb/API/SBTarget.h | 767 - lldb/include/lldb/API/SBThread.h | 181 - lldb/include/lldb/API/SBType.h | 220 - lldb/include/lldb/API/SBTypeCategory.h | 168 - lldb/include/lldb/API/SBTypeFilter.h | 92 - lldb/include/lldb/API/SBTypeFormat.h | 84 - lldb/include/lldb/API/SBTypeNameSpecifier.h | 76 - lldb/include/lldb/API/SBTypeSummary.h | 115 - lldb/include/lldb/API/SBTypeSynthetic.h | 102 - lldb/include/lldb/API/SBValue.h | 389 - lldb/include/lldb/API/SBValueList.h | 86 - lldb/include/lldb/API/SBWatchpoint.h | 95 - lldb/include/lldb/Breakpoint/Breakpoint.h | 580 - lldb/include/lldb/Breakpoint/BreakpointID.h | 117 - .../lldb/Breakpoint/BreakpointIDList.h | 82 - lldb/include/lldb/Breakpoint/BreakpointList.h | 190 - .../lldb/Breakpoint/BreakpointLocation.h | 404 - .../Breakpoint/BreakpointLocationCollection.h | 201 - .../lldb/Breakpoint/BreakpointLocationList.h | 269 - .../lldb/Breakpoint/BreakpointOptions.h | 268 - .../lldb/Breakpoint/BreakpointResolver.h | 148 - .../Breakpoint/BreakpointResolverAddress.h | 74 - .../Breakpoint/BreakpointResolverFileLine.h | 72 - .../Breakpoint/BreakpointResolverFileRegex.h | 68 - .../lldb/Breakpoint/BreakpointResolverName.h | 102 - lldb/include/lldb/Breakpoint/BreakpointSite.h | 276 - .../lldb/Breakpoint/BreakpointSiteList.h | 237 - lldb/include/lldb/Breakpoint/Stoppoint.h | 63 - .../Breakpoint/StoppointCallbackContext.h | 58 - .../lldb/Breakpoint/StoppointLocation.h | 146 - lldb/include/lldb/Breakpoint/Watchpoint.h | 129 - lldb/include/lldb/Breakpoint/WatchpointList.h | 276 - lldb/include/lldb/Core/Address.h | 573 - lldb/include/lldb/Core/AddressRange.h | 284 - lldb/include/lldb/Core/AddressResolver.h | 89 - .../lldb/Core/AddressResolverFileLine.h | 59 - lldb/include/lldb/Core/AddressResolverName.h | 68 - lldb/include/lldb/Core/ArchSpec.h | 403 - lldb/include/lldb/Core/Baton.h | 62 - lldb/include/lldb/Core/Broadcaster.h | 468 - lldb/include/lldb/Core/ClangForward.h | 136 - lldb/include/lldb/Core/Communication.h | 413 - lldb/include/lldb/Core/Connection.h | 162 - .../lldb/Core/ConnectionFileDescriptor.h | 128 - lldb/include/lldb/Core/ConnectionMachPort.h | 92 - .../lldb/Core/ConnectionSharedMemory.h | 70 - lldb/include/lldb/Core/ConstString.h | 502 - lldb/include/lldb/Core/DataBuffer.h | 94 - lldb/include/lldb/Core/DataBufferHeap.h | 136 - lldb/include/lldb/Core/DataBufferMemoryMap.h | 160 - lldb/include/lldb/Core/DataEncoder.h | 447 - lldb/include/lldb/Core/DataExtractor.h | 1239 - lldb/include/lldb/Core/DataVisualization.h | 156 - lldb/include/lldb/Core/Debugger.h | 547 - lldb/include/lldb/Core/Disassembler.h | 388 - lldb/include/lldb/Core/EmulateInstruction.h | 642 - lldb/include/lldb/Core/Error.h | 299 - lldb/include/lldb/Core/Event.h | 217 - lldb/include/lldb/Core/FileLineResolver.h | 80 - lldb/include/lldb/Core/FileSpecList.h | 199 - lldb/include/lldb/Core/Flags.h | 256 - lldb/include/lldb/Core/FormatClasses.h | 1437 - lldb/include/lldb/Core/FormatManager.h | 708 - lldb/include/lldb/Core/FormatNavigator.h | 631 - lldb/include/lldb/Core/History.h | 177 - lldb/include/lldb/Core/IOStreamMacros.h | 38 - lldb/include/lldb/Core/InputReader.h | 274 - lldb/include/lldb/Core/InputReaderEZ.h | 87 - lldb/include/lldb/Core/InputReaderStack.h | 58 - lldb/include/lldb/Core/Language.h | 117 - lldb/include/lldb/Core/Listener.h | 195 - lldb/include/lldb/Core/Log.h | 229 - lldb/include/lldb/Core/Mangled.h | 532 - lldb/include/lldb/Core/MappedHash.h | 527 - lldb/include/lldb/Core/Module.h | 1192 - lldb/include/lldb/Core/ModuleChild.h | 94 - lldb/include/lldb/Core/ModuleList.h | 439 - lldb/include/lldb/Core/Opcode.h | 251 - lldb/include/lldb/Core/PluginInterface.h | 40 - lldb/include/lldb/Core/PluginManager.h | 302 - lldb/include/lldb/Core/RangeMap.h | 952 - lldb/include/lldb/Core/RegisterValue.h | 404 - lldb/include/lldb/Core/RegularExpression.h | 189 - lldb/include/lldb/Core/STLUtils.h | 94 - lldb/include/lldb/Core/Scalar.h | 321 - lldb/include/lldb/Core/SearchFilter.h | 480 - lldb/include/lldb/Core/Section.h | 303 - lldb/include/lldb/Core/SourceManager.h | 195 - lldb/include/lldb/Core/State.h | 78 - lldb/include/lldb/Core/Stream.h | 609 - lldb/include/lldb/Core/StreamAsynchronousIO.h | 42 - lldb/include/lldb/Core/StreamBuffer.h | 83 - lldb/include/lldb/Core/StreamCallback.h | 47 - lldb/include/lldb/Core/StreamFile.h | 75 - lldb/include/lldb/Core/StreamString.h | 58 - lldb/include/lldb/Core/StreamTee.h | 173 - lldb/include/lldb/Core/StringList.h | 89 - lldb/include/lldb/Core/ThreadSafeSTLMap.h | 184 - lldb/include/lldb/Core/ThreadSafeValue.h | 96 - lldb/include/lldb/Core/Timer.h | 97 - lldb/include/lldb/Core/UUID.h | 79 - lldb/include/lldb/Core/UniqueCStringMap.h | 307 - lldb/include/lldb/Core/UserID.h | 131 - .../lldb/Core/UserSettingsController.h | 462 - lldb/include/lldb/Core/VMRange.h | 181 - lldb/include/lldb/Core/Value.h | 186 - lldb/include/lldb/Core/ValueObject.h | 1276 - lldb/include/lldb/Core/ValueObjectChild.h | 130 - .../lldb/Core/ValueObjectConstResult.h | 202 - .../lldb/Core/ValueObjectConstResultChild.h | 78 - .../lldb/Core/ValueObjectConstResultImpl.h | 96 - .../lldb/Core/ValueObjectDynamicValue.h | 190 - lldb/include/lldb/Core/ValueObjectList.h | 90 - lldb/include/lldb/Core/ValueObjectMemory.h | 94 - lldb/include/lldb/Core/ValueObjectRegister.h | 198 - .../lldb/Core/ValueObjectSyntheticFilter.h | 137 - lldb/include/lldb/Core/ValueObjectVariable.h | 83 - lldb/include/lldb/Core/dwarf.h | 65 - lldb/include/lldb/Expression/ASTDumper.h | 42 - .../lldb/Expression/ASTResultSynthesizer.h | 184 - .../lldb/Expression/ASTStructExtractor.h | 156 - lldb/include/lldb/Expression/ClangASTSource.h | 512 - .../include/lldb/Expression/ClangExpression.h | 178 - .../lldb/Expression/ClangExpressionDeclMap.h | 1154 - .../lldb/Expression/ClangExpressionParser.h | 197 - .../lldb/Expression/ClangExpressionVariable.h | 426 - lldb/include/lldb/Expression/ClangFunction.h | 631 - .../Expression/ClangPersistentVariables.h | 75 - .../lldb/Expression/ClangUserExpression.h | 417 - .../lldb/Expression/ClangUtilityFunction.h | 181 - .../include/lldb/Expression/DWARFExpression.h | 401 - .../lldb/Expression/ExpressionSourceCode.h | 76 - .../include/lldb/Expression/IRDynamicChecks.h | 169 - lldb/include/lldb/Expression/IRForTarget.h | 706 - lldb/include/lldb/Expression/IRInterpreter.h | 113 - lldb/include/lldb/Expression/IRToDWARF.h | 111 - .../lldb/Expression/ProcessDataAllocator.h | 72 - .../lldb/Expression/RecordingMemoryManager.h | 401 - lldb/include/lldb/Host/Condition.h | 123 - lldb/include/lldb/Host/Config.h | 35 - lldb/include/lldb/Host/Endian.h | 33 - lldb/include/lldb/Host/File.h | 486 - lldb/include/lldb/Host/FileSpec.h | 615 - lldb/include/lldb/Host/Host.h | 464 - lldb/include/lldb/Host/Mutex.h | 245 - lldb/include/lldb/Host/Predicate.h | 446 - lldb/include/lldb/Host/ReadWriteLock.h | 234 - lldb/include/lldb/Host/SocketAddress.h | 256 - lldb/include/lldb/Host/Symbols.h | 37 - lldb/include/lldb/Host/Terminal.h | 251 - lldb/include/lldb/Host/TimeValue.h | 107 - lldb/include/lldb/Host/freebsd/Config.h | 30 - lldb/include/lldb/Host/linux/Config.h | 30 - lldb/include/lldb/Host/macosx/Config.h | 30 - lldb/include/lldb/Host/mingw/Config.h | 30 - lldb/include/lldb/Interpreter/Args.h | 432 - .../lldb/Interpreter/CommandCompletions.h | 295 - .../lldb/Interpreter/CommandInterpreter.h | 486 - lldb/include/lldb/Interpreter/CommandObject.h | 407 - .../lldb/Interpreter/CommandObjectCrossref.h | 59 - .../lldb/Interpreter/CommandObjectMultiword.h | 75 - .../Interpreter/CommandObjectRegexCommand.h | 79 - .../lldb/Interpreter/CommandReturnObject.h | 180 - .../lldb/Interpreter/NamedOptionValue.h | 1230 - .../Interpreter/OptionGroupArchitecture.h | 73 - .../lldb/Interpreter/OptionGroupBoolean.h | 82 - .../lldb/Interpreter/OptionGroupFile.h | 141 - .../lldb/Interpreter/OptionGroupFormat.h | 121 - .../lldb/Interpreter/OptionGroupOutputFile.h | 75 - .../lldb/Interpreter/OptionGroupPlatform.h | 119 - .../lldb/Interpreter/OptionGroupUInt64.h | 82 - .../lldb/Interpreter/OptionGroupUUID.h | 61 - .../OptionGroupValueObjectDisplay.h | 79 - .../lldb/Interpreter/OptionGroupVariable.h | 63 - .../lldb/Interpreter/OptionGroupWatchpoint.h | 68 - lldb/include/lldb/Interpreter/Options.h | 478 - .../lldb/Interpreter/ScriptInterpreter.h | 297 - .../lldb/Interpreter/ScriptInterpreterNone.h | 35 - .../Interpreter/ScriptInterpreterPython.h | 287 - lldb/include/lldb/Makefile | 31 - lldb/include/lldb/Symbol/Block.h | 481 - lldb/include/lldb/Symbol/ClangASTContext.h | 987 - lldb/include/lldb/Symbol/ClangASTImporter.h | 282 - lldb/include/lldb/Symbol/ClangASTType.h | 341 - .../Symbol/ClangExternalASTSourceCallbacks.h | 172 - .../Symbol/ClangExternalASTSourceCommon.h | 63 - lldb/include/lldb/Symbol/ClangNamespaceDecl.h | 103 - lldb/include/lldb/Symbol/CompileUnit.h | 412 - lldb/include/lldb/Symbol/DWARFCallFrameInfo.h | 141 - lldb/include/lldb/Symbol/Declaration.h | 278 - lldb/include/lldb/Symbol/FuncUnwinders.h | 102 - lldb/include/lldb/Symbol/Function.h | 648 - lldb/include/lldb/Symbol/LineEntry.h | 174 - lldb/include/lldb/Symbol/LineTable.h | 354 - lldb/include/lldb/Symbol/ObjectContainer.h | 235 - lldb/include/lldb/Symbol/ObjectFile.h | 601 - lldb/include/lldb/Symbol/Symbol.h | 294 - lldb/include/lldb/Symbol/SymbolContext.h | 450 - lldb/include/lldb/Symbol/SymbolContextScope.h | 137 - lldb/include/lldb/Symbol/SymbolFile.h | 162 - lldb/include/lldb/Symbol/SymbolVendor.h | 202 - lldb/include/lldb/Symbol/Symtab.h | 156 - lldb/include/lldb/Symbol/TaggedASTType.h | 47 - lldb/include/lldb/Symbol/Type.h | 520 - .../lldb/Symbol/TypeHierarchyNavigator.h | 75 - lldb/include/lldb/Symbol/TypeList.h | 77 - lldb/include/lldb/Symbol/UnwindPlan.h | 466 - lldb/include/lldb/Symbol/UnwindTable.h | 60 - lldb/include/lldb/Symbol/Variable.h | 178 - lldb/include/lldb/Symbol/VariableList.h | 90 - lldb/include/lldb/Symbol/VerifyDecl.h | 20 - lldb/include/lldb/Target/ABI.h | 115 - lldb/include/lldb/Target/CPPLanguageRuntime.h | 74 - lldb/include/lldb/Target/DynamicLoader.h | 227 - lldb/include/lldb/Target/ExecutionContext.h | 792 - .../lldb/Target/ExecutionContextScope.h | 74 - lldb/include/lldb/Target/LanguageRuntime.h | 145 - lldb/include/lldb/Target/Memory.h | 196 - .../include/lldb/Target/ObjCLanguageRuntime.h | 282 - lldb/include/lldb/Target/OperatingSystem.h | 90 - lldb/include/lldb/Target/PathMappingList.h | 155 - lldb/include/lldb/Target/Platform.h | 660 - lldb/include/lldb/Target/Process.h | 3407 -- lldb/include/lldb/Target/RegisterContext.h | 203 - lldb/include/lldb/Target/SectionLoadList.h | 86 - lldb/include/lldb/Target/StackFrame.h | 211 - lldb/include/lldb/Target/StackFrameList.h | 133 - lldb/include/lldb/Target/StackID.h | 149 - lldb/include/lldb/Target/StopInfo.h | 164 - lldb/include/lldb/Target/Target.h | 1184 - lldb/include/lldb/Target/TargetList.h | 236 - lldb/include/lldb/Target/Thread.h | 864 - lldb/include/lldb/Target/ThreadList.h | 134 - lldb/include/lldb/Target/ThreadPlan.h | 502 - lldb/include/lldb/Target/ThreadPlanBase.h | 70 - .../lldb/Target/ThreadPlanCallFunction.h | 179 - .../Target/ThreadPlanCallUserExpression.h | 64 - .../lldb/Target/ThreadPlanRunToAddress.h | 85 - .../lldb/Target/ThreadPlanShouldStopHere.h | 94 - .../lldb/Target/ThreadPlanStepInRange.h | 85 - .../lldb/Target/ThreadPlanStepInstruction.h | 61 - lldb/include/lldb/Target/ThreadPlanStepOut.h | 89 - .../Target/ThreadPlanStepOverBreakpoint.h | 54 - .../lldb/Target/ThreadPlanStepOverRange.h | 57 - .../include/lldb/Target/ThreadPlanStepRange.h | 93 - .../lldb/Target/ThreadPlanStepThrough.h | 66 - .../include/lldb/Target/ThreadPlanStepUntil.h | 79 - .../lldb/Target/ThreadPlanTestCondition.h | 65 - lldb/include/lldb/Target/ThreadPlanTracer.h | 131 - lldb/include/lldb/Target/ThreadSpec.h | 155 - lldb/include/lldb/Target/UnixSignals.h | 144 - lldb/include/lldb/Target/Unwind.h | 120 - lldb/include/lldb/Target/UnwindAssembly.h | 58 - lldb/include/lldb/Utility/AnsiTerminal.h | 86 - lldb/include/lldb/Utility/CleanUp.h | 322 - .../lldb/Utility/PriorityPointerPair.h | 150 - lldb/include/lldb/Utility/PseudoTerminal.h | 266 - lldb/include/lldb/Utility/PythonPointer.h | 78 - lldb/include/lldb/Utility/RefCounter.h | 56 - lldb/include/lldb/Utility/SharedCluster.h | 108 - lldb/include/lldb/Utility/SharingPtr.h | 816 - lldb/include/lldb/Utility/Utils.h | 20 - lldb/include/lldb/lldb-defines.h | 120 - lldb/include/lldb/lldb-enumerations.h | 653 - lldb/include/lldb/lldb-forward.h | 346 - lldb/include/lldb/lldb-private-enumerations.h | 232 - lldb/include/lldb/lldb-private-interfaces.h | 44 - lldb/include/lldb/lldb-private-log.h | 85 - lldb/include/lldb/lldb-private-types.h | 74 - lldb/include/lldb/lldb-private.h | 84 - lldb/include/lldb/lldb-public.h | 18 - lldb/include/lldb/lldb-types.h | 83 - lldb/lib/Makefile | 143 - lldb/lldb.xcodeproj/project.pbxproj | 5206 --- .../contents.xcworkspacedata | 7 - .../xcshareddata/xcschemes/LLDB.xcscheme | 102 - .../xcschemes/darwin-debug.xcscheme | 102 - .../xcschemes/launcherRootXPCService.xcscheme | 58 - .../xcschemes/launcherXPCService.xcscheme | 62 - .../xcshareddata/xcschemes/lldb-tool.xcscheme | 209 - .../lldb.xcworkspace/contents.xcworkspacedata | 10 - lldb/resources/LLDB-Info.plist | 24 - lldb/resources/lldb-framework-exports | 3 - lldb/scripts/Python/build-swig-Python.sh | 310 - .../Python/edit-swig-python-wrapper-file.py | 53 - .../scripts/Python/finish-swig-Python-LLDB.sh | 556 - lldb/scripts/Python/interface/SBAddress.i | 200 - lldb/scripts/Python/interface/SBBlock.i | 175 - lldb/scripts/Python/interface/SBBreakpoint.i | 199 - .../Python/interface/SBBreakpointLocation.i | 104 - lldb/scripts/Python/interface/SBBroadcaster.i | 62 - .../Python/interface/SBCommandInterpreter.i | 122 - .../Python/interface/SBCommandReturnObject.i | 82 - .../Python/interface/SBCommunication.i | 82 - lldb/scripts/Python/interface/SBCompileUnit.i | 101 - lldb/scripts/Python/interface/SBData.i | 300 - lldb/scripts/Python/interface/SBDebugger.i | 363 - lldb/scripts/Python/interface/SBError.i | 126 - lldb/scripts/Python/interface/SBEvent.i | 153 - lldb/scripts/Python/interface/SBFileSpec.i | 97 - .../scripts/Python/interface/SBFileSpecList.i | 45 - lldb/scripts/Python/interface/SBFrame.i | 343 - lldb/scripts/Python/interface/SBFunction.i | 117 - lldb/scripts/Python/interface/SBHostOS.i | 41 - lldb/scripts/Python/interface/SBInputReader.i | 53 - lldb/scripts/Python/interface/SBInstruction.i | 103 - .../Python/interface/SBInstructionList.i | 91 - lldb/scripts/Python/interface/SBLineEntry.i | 100 - lldb/scripts/Python/interface/SBListener.i | 99 - lldb/scripts/Python/interface/SBModule.i | 400 - lldb/scripts/Python/interface/SBProcess.i | 386 - lldb/scripts/Python/interface/SBSection.i | 125 - .../Python/interface/SBSourceManager.i | 54 - lldb/scripts/Python/interface/SBStream.i | 94 - lldb/scripts/Python/interface/SBStringList.i | 44 - lldb/scripts/Python/interface/SBSymbol.i | 98 - .../Python/interface/SBSymbolContext.i | 112 - .../Python/interface/SBSymbolContextList.i | 140 - lldb/scripts/Python/interface/SBTarget.i | 778 - lldb/scripts/Python/interface/SBThread.i | 240 - lldb/scripts/Python/interface/SBType.i | 303 - .../scripts/Python/interface/SBTypeCategory.i | 140 - lldb/scripts/Python/interface/SBTypeFilter.i | 69 - lldb/scripts/Python/interface/SBTypeFormat.i | 64 - .../Python/interface/SBTypeNameSpecifier.i | 62 - lldb/scripts/Python/interface/SBTypeSummary.i | 93 - .../Python/interface/SBTypeSynthetic.i | 74 - lldb/scripts/Python/interface/SBValue.i | 474 - lldb/scripts/Python/interface/SBValueList.i | 138 - lldb/scripts/Python/interface/SBWatchpoint.i | 89 - lldb/scripts/Python/modify-python-lldb.py | 437 - lldb/scripts/Python/python-extensions.swig | 680 - lldb/scripts/Python/python-typemaps.swig | 332 - lldb/scripts/Python/python-wrapper.swig | 748 - lldb/scripts/build-lldb-llvm-clang | 74 - lldb/scripts/build-llvm.pl | 440 - lldb/scripts/build-swig-wrapper-classes.sh | 126 - lldb/scripts/buildbot.py | 152 - lldb/scripts/checkpoint-llvm.pl | 126 - ...ang.check-definition-for-superclasses.diff | 15 - .../clang.complete-type-getObjCLayout.diff | 13 - .../clang.decl-printer-reference-type.diff | 13 - .../scripts/clang.template-keyword-fixes.diff | 13 - lldb/scripts/disasm-gdb-remote.pl | 2198 -- lldb/scripts/finish-swig-wrapper-classes.sh | 85 - lldb/scripts/generate-vers.pl | 46 - lldb/scripts/install-lldb.sh | 59 - lldb/scripts/lldb.swig | 155 - lldb/scripts/llvm.fix-target-amalgamated.diff | 191 - lldb/scripts/llvm.full-i386-relocations.diff | 841 - lldb/scripts/llvm.info-leak.diff | 60 - lldb/scripts/llvm.template-keyword-fixes.diff | 35 - lldb/scripts/sed-sources | 251 - lldb/source/API/Makefile | 14 - lldb/source/API/SBAddress.cpp | 323 - lldb/source/API/SBBlock.cpp | 368 - lldb/source/API/SBBreakpoint.cpp | 601 - lldb/source/API/SBBreakpointLocation.cpp | 308 - lldb/source/API/SBBroadcaster.cpp | 196 - lldb/source/API/SBCommandInterpreter.cpp | 360 - lldb/source/API/SBCommandReturnObject.cpp | 287 - lldb/source/API/SBCommunication.cpp | 279 - lldb/source/API/SBCompileUnit.cpp | 248 - lldb/source/API/SBData.cpp | 785 - lldb/source/API/SBDebugger.cpp | 1244 - lldb/source/API/SBError.cpp | 233 - lldb/source/API/SBEvent.cpp | 243 - lldb/source/API/SBFileSpec.cpp | 215 - lldb/source/API/SBFileSpecList.cpp | 142 - lldb/source/API/SBFrame.cpp | 1171 - lldb/source/API/SBFunction.cpp | 218 - lldb/source/API/SBHostOS.cpp | 73 - lldb/source/API/SBInputReader.cpp | 216 - lldb/source/API/SBInstruction.cpp | 247 - lldb/source/API/SBInstructionList.cpp | 132 - lldb/source/API/SBLineEntry.cpp | 250 - lldb/source/API/SBListener.cpp | 443 - lldb/source/API/SBModule.cpp | 555 - lldb/source/API/SBProcess.cpp | 1050 - lldb/source/API/SBSection.cpp | 259 - lldb/source/API/SBSourceManager.cpp | 134 - lldb/source/API/SBStream.cpp | 187 - lldb/source/API/SBStringList.cpp | 136 - lldb/source/API/SBSymbol.cpp | 218 - lldb/source/API/SBSymbolContext.cpp | 285 - lldb/source/API/SBSymbolContextList.cpp | 117 - lldb/source/API/SBTarget.cpp | 2221 -- lldb/source/API/SBThread.cpp | 1132 - lldb/source/API/SBType.cpp | 685 - lldb/source/API/SBTypeCategory.cpp | 574 - lldb/source/API/SBTypeFilter.cpp | 197 - lldb/source/API/SBTypeFormat.cpp | 153 - lldb/source/API/SBTypeNameSpecifier.cpp | 146 - lldb/source/API/SBTypeSummary.cpp | 302 - lldb/source/API/SBTypeSynthetic.cpp | 207 - lldb/source/API/SBValue.cpp | 1720 - lldb/source/API/SBValueList.cpp | 217 - lldb/source/API/SBWatchpoint.cpp | 276 - lldb/source/Breakpoint/Breakpoint.cpp | 694 - lldb/source/Breakpoint/BreakpointID.cpp | 120 - lldb/source/Breakpoint/BreakpointIDList.cpp | 399 - lldb/source/Breakpoint/BreakpointList.cpp | 227 - lldb/source/Breakpoint/BreakpointLocation.cpp | 527 - .../BreakpointLocationCollection.cpp | 179 - .../Breakpoint/BreakpointLocationList.cpp | 287 - lldb/source/Breakpoint/BreakpointOptions.cpp | 360 - lldb/source/Breakpoint/BreakpointResolver.cpp | 61 - .../Breakpoint/BreakpointResolverAddress.cpp | 111 - .../Breakpoint/BreakpointResolverFileLine.cpp | 198 - .../BreakpointResolverFileRegex.cpp | 133 - .../Breakpoint/BreakpointResolverName.cpp | 361 - lldb/source/Breakpoint/BreakpointSite.cpp | 229 - lldb/source/Breakpoint/BreakpointSiteList.cpp | 275 - lldb/source/Breakpoint/Makefile | 14 - lldb/source/Breakpoint/Stoppoint.cpp | 46 - .../Breakpoint/StoppointCallbackContext.cpp | 39 - lldb/source/Breakpoint/StoppointLocation.cpp | 48 - lldb/source/Breakpoint/Watchpoint.cpp | 237 - lldb/source/Breakpoint/WatchpointList.cpp | 277 - lldb/source/Commands/CommandCompletions.cpp | 710 - lldb/source/Commands/CommandObjectApropos.cpp | 131 - lldb/source/Commands/CommandObjectApropos.h | 43 - lldb/source/Commands/CommandObjectArgs.cpp | 274 - lldb/source/Commands/CommandObjectArgs.h | 74 - .../Commands/CommandObjectBreakpoint.cpp | 1636 - .../source/Commands/CommandObjectBreakpoint.h | 365 - .../CommandObjectBreakpointCommand.cpp | 866 - .../Commands/CommandObjectBreakpointCommand.h | 174 - .../source/Commands/CommandObjectCommands.cpp | 1923 - lldb/source/Commands/CommandObjectCommands.h | 40 - .../source/Commands/CommandObjectCrossref.cpp | 92 - .../Commands/CommandObjectDisassemble.cpp | 482 - .../Commands/CommandObjectDisassemble.h | 99 - .../Commands/CommandObjectExpression.cpp | 511 - .../source/Commands/CommandObjectExpression.h | 105 - lldb/source/Commands/CommandObjectFrame.cpp | 644 - lldb/source/Commands/CommandObjectFrame.h | 40 - lldb/source/Commands/CommandObjectHelp.cpp | 295 - lldb/source/Commands/CommandObjectHelp.h | 117 - lldb/source/Commands/CommandObjectLog.cpp | 491 - lldb/source/Commands/CommandObjectLog.h | 48 - lldb/source/Commands/CommandObjectMemory.cpp | 1228 - lldb/source/Commands/CommandObjectMemory.h | 33 - .../Commands/CommandObjectMultiword.cpp | 312 - .../source/Commands/CommandObjectPlatform.cpp | 966 - lldb/source/Commands/CommandObjectPlatform.h | 40 - lldb/source/Commands/CommandObjectProcess.cpp | 1643 - lldb/source/Commands/CommandObjectProcess.h | 37 - lldb/source/Commands/CommandObjectQuit.cpp | 46 - lldb/source/Commands/CommandObjectQuit.h | 42 - .../source/Commands/CommandObjectRegister.cpp | 483 - lldb/source/Commands/CommandObjectRegister.h | 45 - .../source/Commands/CommandObjectSettings.cpp | 1301 - lldb/source/Commands/CommandObjectSettings.h | 396 - lldb/source/Commands/CommandObjectSource.cpp | 653 - lldb/source/Commands/CommandObjectSource.h | 40 - lldb/source/Commands/CommandObjectSyntax.cpp | 117 - lldb/source/Commands/CommandObjectSyntax.h | 43 - lldb/source/Commands/CommandObjectTarget.cpp | 4350 --- lldb/source/Commands/CommandObjectTarget.h | 41 - lldb/source/Commands/CommandObjectThread.cpp | 1287 - lldb/source/Commands/CommandObjectThread.h | 34 - lldb/source/Commands/CommandObjectType.cpp | 3991 --- lldb/source/Commands/CommandObjectType.h | 37 - lldb/source/Commands/CommandObjectVersion.cpp | 47 - lldb/source/Commands/CommandObjectVersion.h | 42 - .../Commands/CommandObjectWatchpoint.cpp | 1213 - .../source/Commands/CommandObjectWatchpoint.h | 318 - lldb/source/Commands/Makefile | 14 - lldb/source/Core/Address.cpp | 1029 - lldb/source/Core/AddressRange.cpp | 208 - lldb/source/Core/AddressResolver.cpp | 67 - lldb/source/Core/AddressResolverFileLine.cpp | 100 - lldb/source/Core/AddressResolverName.cpp | 251 - lldb/source/Core/ArchSpec.cpp | 737 - lldb/source/Core/Baton.cpp | 24 - lldb/source/Core/Broadcaster.cpp | 499 - lldb/source/Core/Communication.cpp | 434 - lldb/source/Core/Connection.cpp | 24 - lldb/source/Core/ConnectionFileDescriptor.cpp | 1055 - lldb/source/Core/ConnectionMachPort.cpp | 323 - lldb/source/Core/ConnectionSharedMemory.cpp | 131 - lldb/source/Core/ConstString.cpp | 296 - lldb/source/Core/DataBufferHeap.cpp | 105 - lldb/source/Core/DataBufferMemoryMap.cpp | 224 - lldb/source/Core/DataEncoder.cpp | 361 - lldb/source/Core/DataExtractor.cpp | 2048 -- lldb/source/Core/DataVisualization.cpp | 247 - lldb/source/Core/Debugger.cpp | 2845 -- lldb/source/Core/Disassembler.cpp | 1147 - lldb/source/Core/DynamicLoader.cpp | 75 - lldb/source/Core/EmulateInstruction.cpp | 673 - lldb/source/Core/Error.cpp | 389 - lldb/source/Core/Event.cpp | 207 - lldb/source/Core/FileLineResolver.cpp | 118 - lldb/source/Core/FileSpecList.cpp | 235 - lldb/source/Core/FormatClasses.cpp | 357 - lldb/source/Core/FormatManager.cpp | 1048 - lldb/source/Core/History.cpp | 25 - lldb/source/Core/InputReader.cpp | 385 - lldb/source/Core/InputReaderEZ.cpp | 91 - lldb/source/Core/InputReaderStack.cpp | 80 - lldb/source/Core/Language.cpp | 151 - lldb/source/Core/Listener.cpp | 526 - lldb/source/Core/Log.cpp | 524 - lldb/source/Core/Makefile | 14 - lldb/source/Core/Mangled.cpp | 744 - lldb/source/Core/Module.cpp | 1194 - lldb/source/Core/ModuleChild.cpp | 46 - lldb/source/Core/ModuleList.cpp | 820 - lldb/source/Core/Opcode.cpp | 116 - lldb/source/Core/PluginManager.cpp | 1804 - lldb/source/Core/RegisterValue.cpp | 1205 - lldb/source/Core/RegularExpression.cpp | 223 - lldb/source/Core/Scalar.cpp | 2262 -- lldb/source/Core/SearchFilter.cpp | 846 - lldb/source/Core/Section.cpp | 633 - lldb/source/Core/SourceManager.cpp | 597 - lldb/source/Core/State.cpp | 117 - lldb/source/Core/Stream.cpp | 784 - lldb/source/Core/StreamAsynchronousIO.cpp | 52 - lldb/source/Core/StreamCallback.cpp | 64 - lldb/source/Core/StreamFile.cpp | 72 - lldb/source/Core/StreamString.cpp | 73 - lldb/source/Core/StringList.cpp | 239 - lldb/source/Core/Timer.cpp | 252 - lldb/source/Core/UUID.cpp | 214 - lldb/source/Core/UserID.cpp | 25 - lldb/source/Core/UserSettingsController.cpp | 2501 -- lldb/source/Core/VMRange.cpp | 112 - lldb/source/Core/Value.cpp | 714 - lldb/source/Core/ValueObject.cpp | 3961 --- lldb/source/Core/ValueObjectChild.cpp | 234 - lldb/source/Core/ValueObjectConstResult.cpp | 377 - .../Core/ValueObjectConstResultChild.cpp | 82 - .../Core/ValueObjectConstResultImpl.cpp | 242 - lldb/source/Core/ValueObjectDynamicValue.cpp | 361 - lldb/source/Core/ValueObjectList.cpp | 166 - lldb/source/Core/ValueObjectMemory.cpp | 281 - lldb/source/Core/ValueObjectRegister.cpp | 433 - .../Core/ValueObjectSyntheticFilter.cpp | 176 - lldb/source/Core/ValueObjectVariable.cpp | 314 - lldb/source/Expression/ASTDumper.cpp | 125 - .../Expression/ASTResultSynthesizer.cpp | 503 - lldb/source/Expression/ASTStructExtractor.cpp | 191 - lldb/source/Expression/ClangASTSource.cpp | 1552 - .../Expression/ClangExpressionDeclMap.cpp | 3306 -- .../Expression/ClangExpressionParser.cpp | 802 - .../Expression/ClangExpressionVariable.cpp | 147 - lldb/source/Expression/ClangFunction.cpp | 570 - .../Expression/ClangPersistentVariables.cpp | 89 - .../source/Expression/ClangUserExpression.cpp | 780 - .../Expression/ClangUtilityFunction.cpp | 181 - lldb/source/Expression/DWARFExpression.cpp | 3186 -- .../Expression/ExpressionSourceCode.cpp | 109 - lldb/source/Expression/IRDynamicChecks.cpp | 655 - lldb/source/Expression/IRForTarget.cpp | 2820 -- lldb/source/Expression/IRInterpreter.cpp | 1724 - lldb/source/Expression/Makefile | 14 - .../Expression/ProcessDataAllocator.cpp | 43 - .../Expression/RecordingMemoryManager.cpp | 340 - lldb/source/Host/Makefile | 28 - lldb/source/Host/common/Condition.cpp | 106 - lldb/source/Host/common/File.cpp | 665 - lldb/source/Host/common/FileSpec.cpp | 952 - lldb/source/Host/common/Host.cpp | 1423 - lldb/source/Host/common/Makefile | 14 - lldb/source/Host/common/Mutex.cpp | 380 - lldb/source/Host/common/SocketAddress.cpp | 260 - lldb/source/Host/common/Symbols.cpp | 31 - lldb/source/Host/common/Terminal.cpp | 299 - lldb/source/Host/common/TimeValue.cpp | 210 - lldb/source/Host/freebsd/Host.cpp | 328 - lldb/source/Host/freebsd/Makefile | 16 - lldb/source/Host/linux/Host.cpp | 98 - lldb/source/Host/linux/Makefile | 14 - lldb/source/Host/macosx/Host.mm | 1845 - lldb/source/Host/macosx/Makefile | 26 - lldb/source/Host/macosx/Symbols.cpp | 576 - lldb/source/Host/macosx/cfcpp/CFCBundle.cpp | 99 - lldb/source/Host/macosx/cfcpp/CFCBundle.h | 50 - lldb/source/Host/macosx/cfcpp/CFCData.cpp | 82 - lldb/source/Host/macosx/cfcpp/CFCData.h | 35 - .../Host/macosx/cfcpp/CFCMutableArray.cpp | 166 - .../Host/macosx/cfcpp/CFCMutableArray.h | 39 - .../macosx/cfcpp/CFCMutableDictionary.cpp | 491 - .../Host/macosx/cfcpp/CFCMutableDictionary.h | 77 - .../Host/macosx/cfcpp/CFCMutableSet.cpp | 114 - lldb/source/Host/macosx/cfcpp/CFCMutableSet.h | 53 - lldb/source/Host/macosx/cfcpp/CFCReleaser.h | 158 - lldb/source/Host/macosx/cfcpp/CFCString.cpp | 195 - lldb/source/Host/macosx/cfcpp/CFCString.h | 41 - .../Host/macosx/cfcpp/CoreFoundationCPP.h | 30 - .../LauncherRootXPCService-Info.plist | 44 - .../LauncherRootXPCService.mm | 42 - .../LauncherXPCService-Info.plist | 44 - .../LauncherXPCService.entitlements | 8 - .../launcherXPCService/LauncherXPCService.h | 16 - .../launcherXPCService/LauncherXPCService.mm | 17 - .../Host/macosx/launcherXPCService/main.mm | 193 - lldb/source/Interpreter/Args.cpp | 1465 - .../source/Interpreter/CommandInterpreter.cpp | 2672 -- lldb/source/Interpreter/CommandObject.cpp | 934 - .../Interpreter/CommandObjectRegexCommand.cpp | 119 - .../Interpreter/CommandObjectScript.cpp | 94 - lldb/source/Interpreter/CommandObjectScript.h | 51 - .../Interpreter/CommandReturnObject.cpp | 221 - lldb/source/Interpreter/Makefile | 75 - lldb/source/Interpreter/NamedOptionValue.cpp | 503 - .../Interpreter/OptionGroupArchitecture.cpp | 86 - .../source/Interpreter/OptionGroupBoolean.cpp | 58 - lldb/source/Interpreter/OptionGroupFile.cpp | 97 - lldb/source/Interpreter/OptionGroupFormat.cpp | 233 - .../Interpreter/OptionGroupOutputFile.cpp | 81 - .../Interpreter/OptionGroupPlatform.cpp | 132 - lldb/source/Interpreter/OptionGroupUInt64.cpp | 58 - lldb/source/Interpreter/OptionGroupUUID.cpp | 76 - .../OptionGroupValueObjectDisplay.cpp | 147 - .../Interpreter/OptionGroupVariable.cpp | 115 - .../Interpreter/OptionGroupWatchpoint.cpp | 103 - lldb/source/Interpreter/Options.cpp | 1044 - lldb/source/Interpreter/ScriptInterpreter.cpp | 86 - .../Interpreter/ScriptInterpreterNone.cpp | 41 - .../Interpreter/ScriptInterpreterPython.cpp | 1993 -- .../Interpreter/embedded_interpreter.py | 103 - lldb/source/Makefile | 20 - .../Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp | 735 - .../Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.h | 129 - lldb/source/Plugins/ABI/MacOSX-arm/Makefile | 14 - .../ABI/MacOSX-i386/ABIMacOSX_i386.cpp | 948 - .../Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.h | 130 - lldb/source/Plugins/ABI/MacOSX-i386/Makefile | 14 - .../ABI/SysV-x86_64/ABISysV_x86_64.cpp | 1133 - .../Plugins/ABI/SysV-x86_64/ABISysV_x86_64.h | 128 - lldb/source/Plugins/ABI/SysV-x86_64/Makefile | 14 - .../Disassembler/llvm/DisassemblerLLVM.cpp | 799 - .../Disassembler/llvm/DisassemblerLLVM.h | 113 - .../Disassembler/llvm/DisassemblerLLVMC.cpp | 693 - .../Disassembler/llvm/DisassemblerLLVMC.h | 126 - .../source/Plugins/Disassembler/llvm/Makefile | 14 - .../DynamicLoaderDarwinKernel.cpp | 819 - .../Darwin-Kernel/DynamicLoaderDarwinKernel.h | 351 - .../DynamicLoader/Darwin-Kernel/Makefile | 14 - .../MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp | 1764 - .../MacOSX-DYLD/DynamicLoaderMacOSXDYLD.h | 434 - .../DynamicLoader/MacOSX-DYLD/Makefile | 14 - .../DynamicLoader/POSIX-DYLD/AuxVector.cpp | 153 - .../DynamicLoader/POSIX-DYLD/AuxVector.h | 97 - .../POSIX-DYLD/DYLDRendezvous.cpp | 330 - .../DynamicLoader/POSIX-DYLD/DYLDRendezvous.h | 230 - .../POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp | 426 - .../POSIX-DYLD/DynamicLoaderPOSIXDYLD.h | 165 - .../Plugins/DynamicLoader/POSIX-DYLD/Makefile | 14 - .../Static/DynamicLoaderStatic.cpp | 208 - .../Static/DynamicLoaderStatic.h | 91 - .../Plugins/DynamicLoader/Static/Makefile | 14 - .../Instruction/ARM/EmulateInstructionARM.cpp | 13585 ------- .../Instruction/ARM/EmulateInstructionARM.h | 999 - .../Instruction/ARM/EmulationStateARM.cpp | 404 - .../Instruction/ARM/EmulationStateARM.h | 101 - lldb/source/Plugins/Instruction/ARM/Makefile | 14 - .../ItaniumABI/ItaniumABILanguageRuntime.cpp | 429 - .../ItaniumABI/ItaniumABILanguageRuntime.h | 91 - .../CPlusPlus/ItaniumABI/Makefile | 14 - .../AppleObjCRuntime/AppleObjCRuntime.cpp | 360 - .../ObjC/AppleObjCRuntime/AppleObjCRuntime.h | 136 - .../AppleObjCRuntime/AppleObjCRuntimeV1.cpp | 154 - .../AppleObjCRuntime/AppleObjCRuntimeV1.h | 105 - .../AppleObjCRuntime/AppleObjCRuntimeV2.cpp | 780 - .../AppleObjCRuntime/AppleObjCRuntimeV2.h | 136 - .../AppleObjCSymbolVendor.cpp | 76 - .../AppleObjCRuntime/AppleObjCSymbolVendor.h | 47 - .../AppleObjCTrampolineHandler.cpp | 997 - .../AppleObjCTrampolineHandler.h | 212 - ...pleThreadPlanStepThroughObjCTrampoline.cpp | 221 - ...AppleThreadPlanStepThroughObjCTrampoline.h | 102 - .../ObjC/AppleObjCRuntime/Makefile | 14 - lldb/source/Plugins/Makefile | 42 - .../ObjectContainer/BSD-Archive/Makefile | 14 - .../BSD-Archive/ObjectContainerBSDArchive.cpp | 428 - .../BSD-Archive/ObjectContainerBSDArchive.h | 190 - .../ObjectContainer/Universal-Mach-O/Makefile | 14 - .../ObjectContainerUniversalMachO.cpp | 246 - .../ObjectContainerUniversalMachO.h | 91 - .../Plugins/ObjectFile/ELF/ELFHeader.cpp | 373 - .../source/Plugins/ObjectFile/ELF/ELFHeader.h | 417 - lldb/source/Plugins/ObjectFile/ELF/Makefile | 14 - .../Plugins/ObjectFile/ELF/ObjectFileELF.cpp | 1520 - .../Plugins/ObjectFile/ELF/ObjectFileELF.h | 302 - .../source/Plugins/ObjectFile/Mach-O/Makefile | 14 - .../ObjectFile/Mach-O/ObjectFileMachO.cpp | 2800 -- .../ObjectFile/Mach-O/ObjectFileMachO.h | 171 - .../source/Plugins/ObjectFile/PECOFF/Makefile | 14 - .../ObjectFile/PECOFF/ObjectFilePECOFF.cpp | 945 - .../ObjectFile/PECOFF/ObjectFilePECOFF.h | 238 - .../OperatingSystem/Darwin-Kernel/Makefile | 14 - .../OperatingSystemDarwinKernel.cpp | 306 - .../OperatingSystemDarwinKernel.h | 90 - lldb/source/Plugins/Platform/FreeBSD/Makefile | 14 - .../Platform/FreeBSD/PlatformFreeBSD.cpp | 618 - .../Platform/FreeBSD/PlatformFreeBSD.h | 171 - lldb/source/Plugins/Platform/Linux/Makefile | 14 - .../Plugins/Platform/Linux/PlatformLinux.cpp | 397 - .../Plugins/Platform/Linux/PlatformLinux.h | 123 - lldb/source/Plugins/Platform/MacOSX/Makefile | 15 - .../Platform/MacOSX/PlatformDarwin.cpp | 785 - .../Plugins/Platform/MacOSX/PlatformDarwin.h | 117 - .../Platform/MacOSX/PlatformMacOSX.cpp | 152 - .../Plugins/Platform/MacOSX/PlatformMacOSX.h | 93 - .../Platform/MacOSX/PlatformRemoteiOS.cpp | 604 - .../Platform/MacOSX/PlatformRemoteiOS.h | 160 - .../Platform/MacOSX/PlatformiOSSimulator.cpp | 395 - .../Platform/MacOSX/PlatformiOSSimulator.h | 128 - lldb/source/Plugins/Platform/Makefile | 28 - .../Plugins/Platform/gdb-server/Makefile | 14 - .../gdb-server/PlatformRemoteGDBServer.cpp | 408 - .../gdb-server/PlatformRemoteGDBServer.h | 153 - lldb/source/Plugins/Process/FreeBSD/Makefile | 17 - .../Process/FreeBSD/ProcessFreeBSD.cpp | 137 - .../Plugins/Process/FreeBSD/ProcessFreeBSD.h | 85 - .../Process/FreeBSD/ProcessMonitor.cpp | 1560 - .../Plugins/Process/FreeBSD/ProcessMonitor.h | 292 - .../FreeBSD/RegisterContextFreeBSD_x86_64.h | 43 - .../Plugins/Process/Linux/LinuxSignals.cpp | 67 - .../Plugins/Process/Linux/LinuxSignals.h | 31 - lldb/source/Plugins/Process/Linux/Makefile | 17 - .../Plugins/Process/Linux/ProcessLinux.cpp | 157 - .../Plugins/Process/Linux/ProcessLinux.h | 88 - .../Plugins/Process/Linux/ProcessMonitor.cpp | 1722 - .../Plugins/Process/Linux/ProcessMonitor.h | 294 - .../Linux/RegisterContextLinux_x86_64.h | 44 - .../MacOSX-Kernel/CommunicationKDP.cpp | 1103 - .../Process/MacOSX-Kernel/CommunicationKDP.h | 326 - .../Plugins/Process/MacOSX-Kernel/Makefile | 14 - .../Process/MacOSX-Kernel/ProcessKDP.cpp | 821 - .../Process/MacOSX-Kernel/ProcessKDP.h | 277 - .../Process/MacOSX-Kernel/ProcessKDPLog.cpp | 181 - .../Process/MacOSX-Kernel/ProcessKDPLog.h | 54 - .../MacOSX-Kernel/RegisterContextKDP_arm.cpp | 121 - .../MacOSX-Kernel/RegisterContextKDP_arm.h | 61 - .../MacOSX-Kernel/RegisterContextKDP_i386.cpp | 99 - .../MacOSX-Kernel/RegisterContextKDP_i386.h | 53 - .../RegisterContextKDP_x86_64.cpp | 67 - .../MacOSX-Kernel/RegisterContextKDP_x86_64.h | 54 - .../Process/MacOSX-Kernel/ThreadKDP.cpp | 216 - .../Plugins/Process/MacOSX-Kernel/ThreadKDP.h | 103 - lldb/source/Plugins/Process/POSIX/Makefile | 28 - .../Plugins/Process/POSIX/POSIXStopInfo.cpp | 60 - .../Plugins/Process/POSIX/POSIXStopInfo.h | 92 - .../Plugins/Process/POSIX/POSIXThread.cpp | 355 - .../Plugins/Process/POSIX/POSIXThread.h | 106 - .../Plugins/Process/POSIX/ProcessMessage.cpp | 245 - .../Plugins/Process/POSIX/ProcessMessage.h | 171 - .../Plugins/Process/POSIX/ProcessPOSIX.cpp | 598 - .../Plugins/Process/POSIX/ProcessPOSIX.h | 180 - .../Plugins/Process/POSIX/ProcessPOSIXLog.cpp | 188 - .../Plugins/Process/POSIX/ProcessPOSIXLog.h | 106 - .../Process/POSIX/RegisterContextPOSIX.h | 40 - .../Process/POSIX/RegisterContext_i386.cpp | 644 - .../Process/POSIX/RegisterContext_i386.h | 169 - .../Process/POSIX/RegisterContext_x86_64.cpp | 758 - .../Process/POSIX/RegisterContext_x86_64.h | 143 - .../Plugins/Process/Utility/ARMDefines.h | 110 - .../source/Plugins/Process/Utility/ARMUtils.h | 390 - .../Process/Utility/DynamicRegisterInfo.cpp | 142 - .../Process/Utility/DynamicRegisterInfo.h | 82 - .../Process/Utility/InferiorCallPOSIX.cpp | 190 - .../Process/Utility/InferiorCallPOSIX.h | 41 - .../Process/Utility/InstructionUtils.h | 136 - lldb/source/Plugins/Process/Utility/Makefile | 14 - .../Utility/RegisterContextDarwin_arm.cpp | 1226 - .../Utility/RegisterContextDarwin_arm.h | 348 - .../Utility/RegisterContextDarwin_i386.cpp | 980 - .../Utility/RegisterContextDarwin_i386.h | 287 - .../Utility/RegisterContextDarwin_x86_64.cpp | 1066 - .../Utility/RegisterContextDarwin_x86_64.h | 292 - .../Process/Utility/RegisterContextLLDB.cpp | 1497 - .../Process/Utility/RegisterContextLLDB.h | 208 - .../RegisterContextMacOSXFrameBackchain.cpp | 206 - .../RegisterContextMacOSXFrameBackchain.h | 77 - .../Utility/RegisterContextMach_arm.cpp | 87 - .../Process/Utility/RegisterContextMach_arm.h | 56 - .../Utility/RegisterContextMach_i386.cpp | 72 - .../Utility/RegisterContextMach_i386.h | 49 - .../Utility/RegisterContextMach_x86_64.cpp | 72 - .../Utility/RegisterContextMach_x86_64.h | 49 - .../Process/Utility/RegisterContextMemory.cpp | 166 - .../Process/Utility/RegisterContextMemory.h | 100 - .../Process/Utility/StopInfoMachException.cpp | 400 - .../Process/Utility/StopInfoMachException.h | 75 - .../Plugins/Process/Utility/ThreadMemory.cpp | 121 - .../Plugins/Process/Utility/ThreadMemory.h | 64 - .../Plugins/Process/Utility/UnwindLLDB.cpp | 277 - .../Plugins/Process/Utility/UnwindLLDB.h | 118 - .../Utility/UnwindMacOSXFrameBackchain.cpp | 272 - .../Utility/UnwindMacOSXFrameBackchain.h | 74 - .../gdb-remote/GDBRemoteCommunication.cpp | 641 - .../gdb-remote/GDBRemoteCommunication.h | 264 - .../GDBRemoteCommunicationClient.cpp | 1897 - .../gdb-remote/GDBRemoteCommunicationClient.h | 402 - .../GDBRemoteCommunicationServer.cpp | 834 - .../gdb-remote/GDBRemoteCommunicationServer.h | 147 - .../gdb-remote/GDBRemoteRegisterContext.cpp | 865 - .../gdb-remote/GDBRemoteRegisterContext.h | 262 - .../Plugins/Process/gdb-remote/Makefile | 14 - .../Process/gdb-remote/ProcessGDBRemote.cpp | 2732 -- .../Process/gdb-remote/ProcessGDBRemote.h | 382 - .../gdb-remote/ProcessGDBRemoteLog.cpp | 190 - .../Process/gdb-remote/ProcessGDBRemoteLog.h | 57 - .../Process/gdb-remote/ThreadGDBRemote.cpp | 243 - .../Process/gdb-remote/ThreadGDBRemote.h | 110 - .../source/Plugins/Process/mach-core/Makefile | 14 - .../Process/mach-core/ProcessMachCore.cpp | 455 - .../Process/mach-core/ProcessMachCore.h | 147 - .../Process/mach-core/ThreadMachCore.cpp | 159 - .../Process/mach-core/ThreadMachCore.h | 92 - .../DWARF/DWARFAbbreviationDeclaration.cpp | 211 - .../DWARF/DWARFAbbreviationDeclaration.h | 81 - .../Plugins/SymbolFile/DWARF/DWARFAttribute.h | 45 - .../SymbolFile/DWARF/DWARFCompileUnit.cpp | 927 - .../SymbolFile/DWARF/DWARFCompileUnit.h | 193 - .../SymbolFile/DWARF/DWARFDIECollection.cpp | 62 - .../SymbolFile/DWARF/DWARFDIECollection.h | 51 - .../SymbolFile/DWARF/DWARFDebugAbbrev.cpp | 202 - .../SymbolFile/DWARF/DWARFDebugAbbrev.h | 74 - .../SymbolFile/DWARF/DWARFDebugArangeSet.cpp | 274 - .../SymbolFile/DWARF/DWARFDebugArangeSet.h | 76 - .../SymbolFile/DWARF/DWARFDebugAranges.cpp | 174 - .../SymbolFile/DWARF/DWARFDebugAranges.h | 94 - .../SymbolFile/DWARF/DWARFDebugInfo.cpp | 780 - .../Plugins/SymbolFile/DWARF/DWARFDebugInfo.h | 88 - .../SymbolFile/DWARF/DWARFDebugInfoEntry.cpp | 2141 -- .../SymbolFile/DWARF/DWARFDebugInfoEntry.h | 433 - .../SymbolFile/DWARF/DWARFDebugLine.cpp | 1436 - .../Plugins/SymbolFile/DWARF/DWARFDebugLine.h | 225 - .../SymbolFile/DWARF/DWARFDebugMacinfo.cpp | 48 - .../SymbolFile/DWARF/DWARFDebugMacinfo.h | 29 - .../DWARF/DWARFDebugMacinfoEntry.cpp | 132 - .../SymbolFile/DWARF/DWARFDebugMacinfoEntry.h | 57 - .../SymbolFile/DWARF/DWARFDebugPubnames.cpp | 298 - .../SymbolFile/DWARF/DWARFDebugPubnames.h | 38 - .../DWARF/DWARFDebugPubnamesSet.cpp | 166 - .../SymbolFile/DWARF/DWARFDebugPubnamesSet.h | 91 - .../SymbolFile/DWARF/DWARFDebugRanges.cpp | 243 - .../SymbolFile/DWARF/DWARFDebugRanges.h | 46 - .../Plugins/SymbolFile/DWARF/DWARFDefines.cpp | 497 - .../Plugins/SymbolFile/DWARF/DWARFDefines.h | 116 - .../SymbolFile/DWARF/DWARFFormValue.cpp | 585 - .../Plugins/SymbolFile/DWARF/DWARFFormValue.h | 78 - .../DWARF/DWARFLocationDescription.cpp | 172 - .../DWARF/DWARFLocationDescription.h | 24 - .../SymbolFile/DWARF/DWARFLocationList.cpp | 93 - .../SymbolFile/DWARF/DWARFLocationList.h | 34 - .../SymbolFile/DWARF/HashedNameToDIE.h | 850 - .../SymbolFile/DWARF/LogChannelDWARF.cpp | 233 - .../SymbolFile/DWARF/LogChannelDWARF.h | 92 - lldb/source/Plugins/SymbolFile/DWARF/Makefile | 14 - .../Plugins/SymbolFile/DWARF/NameToDIE.cpp | 75 - .../Plugins/SymbolFile/DWARF/NameToDIE.h | 59 - .../SymbolFile/DWARF/SymbolFileDWARF.cpp | 6787 ---- .../SymbolFile/DWARF/SymbolFileDWARF.h | 579 - .../DWARF/SymbolFileDWARFDebugMap.cpp | 1211 - .../DWARF/SymbolFileDWARFDebugMap.h | 259 - .../SymbolFile/DWARF/UniqueDWARFASTType.cpp | 94 - .../SymbolFile/DWARF/UniqueDWARFASTType.h | 175 - .../source/Plugins/SymbolFile/Symtab/Makefile | 14 - .../SymbolFile/Symtab/SymbolFileSymtab.cpp | 462 - .../SymbolFile/Symtab/SymbolFileSymtab.h | 140 - .../Plugins/SymbolVendor/MacOSX/Makefile | 14 - .../MacOSX/SymbolVendorMacOSX.cpp | 210 - .../SymbolVendor/MacOSX/SymbolVendorMacOSX.h | 61 - .../UnwindAssembly/InstEmulation/Makefile | 14 - .../UnwindAssemblyInstEmulation.cpp | 521 - .../UnwindAssemblyInstEmulation.h | 174 - .../Plugins/UnwindAssembly/x86/Makefile | 14 - .../UnwindAssembly/x86/UnwindAssembly-x86.cpp | 936 - .../UnwindAssembly/x86/UnwindAssembly-x86.h | 73 - lldb/source/Symbol/Block.cpp | 624 - lldb/source/Symbol/ClangASTContext.cpp | 6325 ---- lldb/source/Symbol/ClangASTImporter.cpp | 550 - lldb/source/Symbol/ClangASTType.cpp | 1771 - .../ClangExternalASTSourceCallbacks.cpp | 157 - .../Symbol/ClangExternalASTSourceCommon.cpp | 52 - lldb/source/Symbol/ClangNamespaceDecl.cpp | 25 - lldb/source/Symbol/CompileUnit.cpp | 415 - lldb/source/Symbol/DWARFCallFrameInfo.cpp | 754 - lldb/source/Symbol/Declaration.cpp | 117 - lldb/source/Symbol/FuncUnwinders.cpp | 238 - lldb/source/Symbol/Function.cpp | 576 - lldb/source/Symbol/LineEntry.cpp | 246 - lldb/source/Symbol/LineTable.cpp | 452 - lldb/source/Symbol/Makefile | 14 - lldb/source/Symbol/ObjectFile.cpp | 457 - lldb/source/Symbol/Symbol.cpp | 414 - lldb/source/Symbol/SymbolContext.cpp | 1062 - lldb/source/Symbol/SymbolFile.cpp | 72 - lldb/source/Symbol/SymbolVendor.cpp | 437 - lldb/source/Symbol/Symtab.cpp | 952 - lldb/source/Symbol/Type.cpp | 894 - lldb/source/Symbol/TypeHierarchyNavigator.cpp | 121 - lldb/source/Symbol/TypeList.cpp | 333 - lldb/source/Symbol/UnwindPlan.cpp | 448 - lldb/source/Symbol/UnwindTable.cpp | 128 - lldb/source/Symbol/Variable.cpp | 519 - lldb/source/Symbol/VariableList.cpp | 178 - lldb/source/Symbol/VerifyDecl.cpp | 16 - lldb/source/Target/ABI.cpp | 174 - lldb/source/Target/CPPLanguageRuntime.cpp | 269 - lldb/source/Target/ExecutionContext.cpp | 745 - lldb/source/Target/LanguageRuntime.cpp | 210 - lldb/source/Target/Makefile | 14 - lldb/source/Target/Memory.cpp | 459 - lldb/source/Target/ObjCLanguageRuntime.cpp | 262 - lldb/source/Target/OperatingSystem.cpp | 56 - lldb/source/Target/PathMappingList.cpp | 318 - lldb/source/Target/Platform.cpp | 666 - lldb/source/Target/Process.cpp | 4827 --- lldb/source/Target/RegisterContext.cpp | 559 - lldb/source/Target/SectionLoadList.cpp | 255 - lldb/source/Target/StackFrame.cpp | 1369 - lldb/source/Target/StackFrameList.cpp | 627 - lldb/source/Target/StackID.cpp | 110 - lldb/source/Target/StopInfo.cpp | 801 - lldb/source/Target/Target.cpp | 2887 -- lldb/source/Target/TargetList.cpp | 436 - lldb/source/Target/Thread.cpp | 1591 - lldb/source/Target/ThreadList.cpp | 608 - lldb/source/Target/ThreadPlan.cpp | 188 - lldb/source/Target/ThreadPlanBase.cpp | 212 - lldb/source/Target/ThreadPlanCallFunction.cpp | 509 - .../Target/ThreadPlanCallUserExpression.cpp | 74 - lldb/source/Target/ThreadPlanRunToAddress.cpp | 267 - .../Target/ThreadPlanShouldStopHere.cpp | 74 - lldb/source/Target/ThreadPlanStepInRange.cpp | 297 - .../Target/ThreadPlanStepInstruction.cpp | 194 - lldb/source/Target/ThreadPlanStepOut.cpp | 470 - .../Target/ThreadPlanStepOverBreakpoint.cpp | 142 - .../source/Target/ThreadPlanStepOverRange.cpp | 172 - lldb/source/Target/ThreadPlanStepRange.cpp | 438 - lldb/source/Target/ThreadPlanStepThrough.cpp | 276 - lldb/source/Target/ThreadPlanStepUntil.cpp | 416 - .../source/Target/ThreadPlanTestCondition.cpp | 194 - lldb/source/Target/ThreadPlanTracer.cpp | 280 - lldb/source/Target/ThreadSpec.cpp | 158 - lldb/source/Target/UnixSignals.cpp | 293 - lldb/source/Target/UnwindAssembly.cpp | 41 - lldb/source/Utility/ARM_DWARF_Registers.cpp | 391 - lldb/source/Utility/ARM_DWARF_Registers.h | 217 - lldb/source/Utility/ARM_GCC_Registers.h | 146 - lldb/source/Utility/Makefile | 14 - lldb/source/Utility/PseudoTerminal.cpp | 339 - lldb/source/Utility/RefCounter.cpp | 25 - lldb/source/Utility/SharingPtr.cpp | 158 - lldb/source/Utility/StringExtractor.cpp | 387 - lldb/source/Utility/StringExtractor.h | 141 - .../Utility/StringExtractorGDBRemote.cpp | 182 - .../source/Utility/StringExtractorGDBRemote.h | 103 - lldb/source/lldb-log.cpp | 247 - lldb/source/lldb.cpp | 323 - lldb/test/Makefile | 37 - lldb/test/README-TestSuite | 135 - .../api/check_public_api_headers/Makefile | 16 - .../TestPublicAPIHeaders.py | 102 - .../main.cpp.template | 24 - lldb/test/arm_emulation/TestEmulations.py | 57 - .../new-test-files/test-add-1-arm.dat | 111 - .../new-test-files/test-add-1-thumb.dat | 111 - .../new-test-files/test-add-10-thumb.dat | 111 - .../new-test-files/test-add-11-thumb.dat | 111 - .../new-test-files/test-add-12-thumb.dat | 111 - .../new-test-files/test-add-2-arm.dat | 111 - .../new-test-files/test-add-2-thumb.dat | 111 - .../new-test-files/test-add-3-arm.dat | 111 - .../new-test-files/test-add-3-thumb.dat | 111 - .../new-test-files/test-add-4-arm.dat | 111 - .../new-test-files/test-add-4-thumb.dat | 111 - .../new-test-files/test-add-5-arm.dat | 111 - .../new-test-files/test-add-5-thumb.dat | 111 - .../new-test-files/test-add-6-arm.dat | 111 - .../new-test-files/test-add-6-thumb.dat | 111 - .../new-test-files/test-add-7-arm.dat | 111 - .../new-test-files/test-add-7-thumb.dat | 111 - .../new-test-files/test-add-8-arm.dat | 111 - .../new-test-files/test-add-8-thumb.dat | 111 - .../new-test-files/test-add-9-thumb.dat | 111 - .../new-test-files/test-bic-1-arm.dat | 111 - .../new-test-files/test-bic-1-thumb.dat | 111 - .../new-test-files/test-ldmia-1-arm.dat | 119 - .../new-test-files/test-ldmia-1-thumb.dat | 119 - .../new-test-files/test-ldmia-2-arm.dat | 123 - .../new-test-files/test-ldmia-2-thumb.dat | 123 - .../new-test-files/test-ldmia-3-arm.dat | 119 - .../new-test-files/test-ldmia-3-thumb.dat | 119 - .../new-test-files/test-ldr-1-arm.dat | 118 - .../new-test-files/test-ldr-1-thumb.dat | 118 - .../new-test-files/test-ldr-10-thumb.dat | 118 - .../new-test-files/test-ldr-11-thumb.dat | 118 - .../new-test-files/test-ldr-12-thumb.dat | 118 - .../new-test-files/test-ldr-2-arm.dat | 118 - .../new-test-files/test-ldr-2-thumb.dat | 118 - .../new-test-files/test-ldr-3-arm.dat | 118 - .../new-test-files/test-ldr-3-thumb.dat | 118 - .../new-test-files/test-ldr-4-arm.dat | 118 - .../new-test-files/test-ldr-4-thumb.dat | 118 - .../new-test-files/test-ldr-5-arm.dat | 118 - .../new-test-files/test-ldr-5-thumb.dat | 118 - .../new-test-files/test-ldr-6-arm.dat | 118 - .../new-test-files/test-ldr-6-thumb.dat | 118 - .../new-test-files/test-ldr-7-arm.dat | 118 - .../new-test-files/test-ldr-7-thumb.dat | 118 - .../new-test-files/test-ldr-8-arm.dat | 118 - .../new-test-files/test-ldr-8-thumb.dat | 118 - .../new-test-files/test-ldr-9-thumb.dat | 118 - .../new-test-files/test-ldrd-1-arm.dat | 119 - .../new-test-files/test-ldrd-1-thumb.dat | 119 - .../new-test-files/test-ldrd-2-thumb.dat | 119 - .../new-test-files/test-ldrh-1-thumb.dat | 118 - .../new-test-files/test-ldrsh-1-arm.dat | 118 - .../new-test-files/test-ldrsh-2-arm.dat | 118 - .../new-test-files/test-mov-1-arm.dat | 111 - .../new-test-files/test-mov-1-thumb.dat | 111 - .../new-test-files/test-mov-10-thumb.dat | 111 - .../new-test-files/test-mov-11-thumb.dat | 111 - .../new-test-files/test-mov-12-thumb.dat | 111 - .../new-test-files/test-mov-13-thumb.dat | 111 - .../new-test-files/test-mov-14-thumb.dat | 111 - .../new-test-files/test-mov-15-thumb.dat | 111 - .../new-test-files/test-mov-16-thumb.dat | 111 - .../new-test-files/test-mov-17-thumb.dat | 111 - .../new-test-files/test-mov-18-thumb.dat | 111 - .../new-test-files/test-mov-19-thumb.dat | 111 - .../new-test-files/test-mov-2-arm.dat | 111 - .../new-test-files/test-mov-2-thumb.dat | 111 - .../new-test-files/test-mov-20-thumb.dat | 111 - .../new-test-files/test-mov-21-thumb.dat | 111 - .../new-test-files/test-mov-22-thumb.dat | 111 - .../new-test-files/test-mov-23-thumb.dat | 111 - .../new-test-files/test-mov-24-thumb.dat | 111 - .../new-test-files/test-mov-25-thumb.dat | 111 - .../new-test-files/test-mov-26-thumb.dat | 111 - .../new-test-files/test-mov-27-thumb.dat | 111 - .../new-test-files/test-mov-28-thumb.dat | 111 - .../new-test-files/test-mov-29-thumb.dat | 111 - .../new-test-files/test-mov-3-arm.dat | 111 - .../new-test-files/test-mov-3-thumb.dat | 111 - .../new-test-files/test-mov-30-thumb.dat | 111 - .../new-test-files/test-mov-31-thumb.dat | 111 - .../new-test-files/test-mov-4-arm.dat | 111 - .../new-test-files/test-mov-4-thumb.dat | 111 - .../new-test-files/test-mov-5-arm.dat | 111 - .../new-test-files/test-mov-5-thumb.dat | 111 - .../new-test-files/test-mov-6-arm.dat | 111 - .../new-test-files/test-mov-6-thumb.dat | 111 - .../new-test-files/test-mov-7-thumb.dat | 111 - .../new-test-files/test-mov-8-thumb.dat | 111 - .../new-test-files/test-mov-9-thumb.dat | 111 - .../new-test-files/test-moveq-1-arm.dat | 111 - .../new-test-files/test-movs-1-arm.dat | 111 - .../new-test-files/test-mvn-1-arm.dat | 111 - .../new-test-files/test-mvn-1-thumb.dat | 111 - .../new-test-files/test-mvn-2-arm.dat | 111 - .../new-test-files/test-mvn-2-thumb.dat | 111 - .../new-test-files/test-mvn-3-arm.dat | 111 - .../new-test-files/test-mvn-3-thumb.dat | 111 - .../new-test-files/test-mvn-4-arm.dat | 111 - .../new-test-files/test-mvn-4-thumb.dat | 111 - .../new-test-files/test-pop-1-arm.dat | 121 - .../new-test-files/test-pop-1-thumb.dat | 121 - .../new-test-files/test-pop-2-arm.dat | 118 - .../new-test-files/test-pop-2-thumb.dat | 118 - .../new-test-files/test-pop-3-thumb.dat | 118 - .../new-test-files/test-push-1-arm.dat | 111 - .../new-test-files/test-push-1-thumb.dat | 111 - .../new-test-files/test-push-2-arm.dat | 111 - .../new-test-files/test-push-2-thumb.dat | 111 - .../new-test-files/test-push-3-arm.dat | 111 - .../new-test-files/test-push-3-thumb.dat | 111 - .../new-test-files/test-str-1-arm.dat | 111 - .../new-test-files/test-str-1-thumb.dat | 111 - .../new-test-files/test-str-2-arm.dat | 111 - .../new-test-files/test-str-2-thumb.dat | 111 - .../new-test-files/test-str-3-arm.dat | 111 - .../new-test-files/test-str-3-thumb.dat | 111 - .../new-test-files/test-str-4-arm.dat | 111 - .../new-test-files/test-str-4-thumb.dat | 111 - .../new-test-files/test-str-5-arm.dat | 111 - .../new-test-files/test-strb-1-arm.dat | 111 - .../new-test-files/test-strb-2-arm.dat | 111 - .../new-test-files/test-strbt-1-arm.dat | 111 - .../new-test-files/test-strd-1-thumb.dat | 111 - .../new-test-files/test-strt-1-arm.dat | 111 - .../new-test-files/test-sub-1-arm.dat | 111 - .../new-test-files/test-sub-1-thumb.dat | 111 - .../new-test-files/test-sub-10-arm.dat | 111 - .../new-test-files/test-sub-2-arm.dat | 111 - .../new-test-files/test-sub-2-thumb.dat | 111 - .../new-test-files/test-sub-3-arm.dat | 111 - .../new-test-files/test-sub-3-thumb.dat | 111 - .../new-test-files/test-sub-4-arm.dat | 111 - .../new-test-files/test-sub-4-thumb.dat | 111 - .../new-test-files/test-sub-5-arm.dat | 111 - .../new-test-files/test-sub-5-thumb.dat | 111 - .../new-test-files/test-sub-6-arm.dat | 111 - .../new-test-files/test-sub-6-thumb.dat | 111 - .../new-test-files/test-sub-8-arm.dat | 111 - .../new-test-files/test-sub-9-arm.dat | 111 - .../new-test-files/test-subs-1-arm.dat | 111 - .../new-test-files/test-subs-1-thumb.dat | 111 - .../new-test-files/test-subs-10-thumb.dat | 111 - .../new-test-files/test-subs-2-thumb.dat | 111 - .../new-test-files/test-subs-3-thumb.dat | 111 - .../new-test-files/test-subs-4-thumb.dat | 111 - .../new-test-files/test-subs-5-thumb.dat | 111 - .../new-test-files/test-subs-6-thumb.dat | 111 - .../new-test-files/test-subs-8-thumb.dat | 111 - .../new-test-files/test-subs-9-thumb.dat | 111 - .../new-test-files/test-vpop-1-thumb.dat | 125 - .../new-test-files/test-vpop-2-thumb.dat | 118 - .../new-test-files/test-vpop-3-thumb.dat | 121 - .../new-test-files/test-vpush-1-thumb.dat | 111 - .../new-test-files/test-vpush-2-thumb.dat | 111 - .../new-test-files/test-vpush-3-thumb.dat | 111 - lldb/test/attic/dotest.pl | 44 - lldb/test/attic/tester.py | 109 - lldb/test/bench-history | 206 - lldb/test/bench.py | 71 - .../benchmarks/disassembly/TestDisassembly.py | 155 - .../TestDoAttachThenDisassembly.py | 75 - .../TestFlintVsSlateGDBDisassembly.py | 95 - lldb/test/benchmarks/expression/Makefile | 5 - .../expression/TestExpressionCmd.py | 76 - .../expression/TestRepeatedExprs.py | 133 - lldb/test/benchmarks/expression/main.cpp | 51 - .../TestFrameVariableResponse.py | 79 - .../benchmarks/startup/TestStartupDelays.py | 89 - .../stepping/TestRunHooksThenSteppings.py | 66 - .../benchmarks/stepping/TestSteppingSpeed.py | 78 - .../TestCompileRunToBreakpointTurnaround.py | 122 - lldb/test/blacklist.py | 18 - lldb/test/dosep.ty | 51 - lldb/test/dotest.py | 1357 - lldb/test/example/TestSequenceFunctions.py | 34 - .../expression_command/call-function/Makefile | 5 - .../TestCallStdStringFunction.py | 61 - .../expression_command/call-function/main.cpp | 15 - .../expression_command/formatters/Makefile | 5 - .../formatters/TestFormatters.py | 177 - .../expression_command/formatters/foosynth.py | 29 - .../formatters/formatters.py | 17 - .../expression_command/formatters/main.cpp | 48 - .../expression_command/issue_11588/Makefile | 5 - .../issue_11588/Test11588.py | 76 - .../expression_command/issue_11588/main.cpp | 54 - .../expression_command/issue_11588/s11588.py | 26 - .../persistent_types/Makefile | 5 - .../persistent_types/TestPersistentTypes.py | 41 - .../persistent_types/main.c | 13 - .../persistent_variables/Makefile | 5 - .../TestPersistentVariables.py | 49 - .../persistent_variables/main.c | 13 - .../expression_command/radar_8638051/Makefile | 5 - .../radar_8638051/Test8638051.py | 43 - .../expression_command/radar_8638051/main.c | 54 - .../expression_command/radar_9531204/Makefile | 5 - .../radar_9531204/TestPrintfAfterUp.py | 46 - .../expression_command/radar_9531204/main.c | 25 - .../expression_command/radar_9673664/Makefile | 5 - .../radar_9673664/TestExprHelpExamples.py | 47 - .../expression_command/radar_9673664/main.c | 16 - lldb/test/expression_command/test/Makefile | 5 - .../test/expression_command/test/TestExprs.py | 221 - .../expression_command/test/TestExprs2.py | 66 - lldb/test/expression_command/test/main.cpp | 33 - .../expression_command/two-files/Makefile | 7 - .../TestObjCTypeQueryFromOtherCompileUnit.py | 56 - lldb/test/expression_command/two-files/foo.m | 28 - lldb/test/expression_command/two-files/main.m | 22 - .../functionalities/abbreviation/Makefile | 5 - .../abbreviation/TestAbbreviations.py | 169 - .../abbreviation/TestCommonShortSpellings.py | 65 - .../abbreviation/change_prompt.lldb | 2 - .../functionalities/abbreviation/main.cpp | 62 - lldb/test/functionalities/alias/Makefile | 5 - .../test/functionalities/alias/TestAliases.py | 148 - lldb/test/functionalities/alias/main.cpp | 62 - lldb/test/functionalities/archives/Makefile | 9 - lldb/test/functionalities/archives/README | 62 - .../archives/TestBSDArchives.py | 65 - lldb/test/functionalities/archives/a.c | 19 - lldb/test/functionalities/archives/b.c | 19 - lldb/test/functionalities/archives/main.c | 17 - .../backticks/TestBackticksWithoutATarget.py | 23 - .../breakpoint/breakpoint_command/Makefile | 5 - .../TestBreakpointCommand.py | 222 - .../breakpoint/breakpoint_command/a.c | 9 - .../breakpoint/breakpoint_command/b.c | 9 - .../breakpoint/breakpoint_command/bktptcmd.py | 4 - .../breakpoint/breakpoint_command/main.c | 13 - .../breakpoint/breakpoint_conditions/Makefile | 5 - .../TestBreakpointConditions.py | 168 - .../breakpoint/breakpoint_conditions/main.c | 51 - .../breakpoint/breakpoint_ids/Makefile | 5 - .../breakpoint_ids/TestBreakpointIDs.py | 63 - .../breakpoint/breakpoint_ids/main.cpp | 65 - .../breakpoint_ignore_count/Makefile | 5 - .../TestBreakpointIgnoreCount.py | 135 - .../breakpoint/breakpoint_ignore_count/main.c | 52 - .../breakpoint/breakpoint_locations/Makefile | 5 - .../TestBreakpointLocations.py | 100 - .../breakpoint/breakpoint_locations/main.c | 43 - .../breakpoint/inlined_breakpoints/Makefile | 5 - .../TestInlinedBreakpoints.py | 59 - .../inlined_breakpoints/basic_type.cpp | 178 - .../breakpoint/inlined_breakpoints/int.cpp | 9 - .../command_regex/TestCommandRegex.py | 44 - .../functionalities/command_script/Makefile | 5 - .../command_script/TestCommandScript.py | 132 - .../command_script/bug11569.py | 7 - .../command_script/import/Makefile | 6 - .../command_script/import/TestImport.py | 72 - .../command_script/import/bar/bar.py | 10 - .../command_script/import/bar/barutil.py | 2 - .../command_script/import/dummymodule.py | 2 - .../command_script/import/foo/bar/foobar.py | 3 - .../command_script/import/foo/foo.py | 3 - .../command_script/import/foo/foo2.py | 7 - .../command_script/import/main.c | 15 - .../functionalities/command_script/main.cpp | 69 - .../functionalities/command_script/mysto.py | 21 - .../functionalities/command_script/py_import | 11 - .../functionalities/command_script/welcome.py | 34 - .../test/functionalities/command_source/.lldb | 1 - .../command_source/TestCommandSource.py | 46 - .../test/functionalities/command_source/my.py | 4 - .../completion/TestCompletion.py | 192 - .../functionalities/conditional_break/.lldb | 7 - .../conditional_break/Makefile | 5 - .../conditional_break/TestConditionalBreak.py | 145 - .../conditional_break/conditional_break.py | 37 - .../functionalities/conditional_break/main.c | 54 - .../connect_remote/EchoServer.py | 23 - .../connect_remote/TestConnectRemote.py | 41 - .../data-formatter-advanced/Makefile | 5 - .../TestDataFormatterAdv.py | 290 - .../data-formatter-advanced/main.cpp | 171 - .../data-formatter-categories/Makefile | 5 - .../TestDataFormatterCategories.py | 341 - .../data-formatter-categories/main.cpp | 46 - .../data-formatter-cpp/Makefile | 5 - .../TestDataFormatterCpp.py | 281 - .../data-formatter-cpp/main.cpp | 118 - .../data-formatter-globals/Makefile | 5 - .../TestDataFormatterGlobals.py | 85 - .../data-formatter-globals/main.cpp | 27 - .../data-formatter-named-summaries/Makefile | 5 - .../TestDataFormatterNamedSummaries.py | 139 - .../data-formatter-named-summaries/main.cpp | 59 - .../data-formatter-objc/Makefile | 9 - .../TestDataFormatterObjC.py | 552 - .../data-formatter/data-formatter-objc/main.m | 658 - .../data-formatter-python-synth/Makefile | 5 - .../TestDataFormatterPythonSynth.py | 278 - .../fooSynthProvider.py | 23 - .../data-formatter-python-synth/ftsp.py | 32 - .../data-formatter-python-synth/main.cpp | 67 - .../data-formatter-script/Makefile | 5 - .../TestDataFormatterScript.py | 184 - .../data-formatter-script/main.cpp | 53 - .../data-formatter-skip-summary/Makefile | 5 - .../TestDataFormatterSkipSummary.py | 187 - .../data-formatter-skip-summary/main.cpp | 57 - .../data-formatter-smart-array/Makefile | 5 - .../TestDataFormatterSmartArray.py | 363 - .../data-formatter-smart-array/main.cpp | 65 - .../data-formatter-stl/libcxx/list/Makefile | 8 - .../list/TestDataFormatterLibcxxList.py | 177 - .../data-formatter-stl/libcxx/list/main.cpp | 38 - .../data-formatter-stl/libcxx/map/Makefile | 8 - .../libcxx/map/TestDataFormatterLibccMap.py | 318 - .../data-formatter-stl/libcxx/map/main.cpp | 59 - .../data-formatter-stl/libcxx/vector/Makefile | 8 - .../vector/TestDataFormatterLibcxxVector.py | 206 - .../data-formatter-stl/libcxx/vector/main.cpp | 35 - .../libstdcpp/list/Makefile | 5 - .../list/TestDataFormatterStdList.py | 190 - .../libstdcpp/list/main.cpp | 33 - .../data-formatter-stl/libstdcpp/map/Makefile | 5 - .../libstdcpp/map/TestDataFormatterStdMap.py | 328 - .../data-formatter-stl/libstdcpp/map/main.cpp | 55 - .../libstdcpp/vector/Makefile | 5 - .../vector/TestDataFormatterStdVector.py | 218 - .../libstdcpp/vector/main.cpp | 31 - .../data-formatter-synth/Makefile | 5 - .../TestDataFormatterSynth.py | 217 - .../data-formatter-synth/main.cpp | 83 - .../data-formatter/rdar-10642615/Makefile | 7 - .../rdar-10642615/Test-rdar-10642615.py | 78 - .../data-formatter/rdar-10642615/main.cpp | 27 - .../data-formatter/rdar-10887661/Makefile | 5 - .../rdar-10887661/TestRdar10887661.py | 96 - .../rdar-10887661/fooSynthProvider.py | 21 - .../data-formatter/rdar-10887661/main.cpp | 62 - .../data-formatter/rdar-3534688/Makefile | 9 - .../TestFormattersOneIsSingular.py | 109 - .../data-formatter/rdar-3534688/main.m | 42 - .../data-formatter/rdar-9973865/Makefile | 5 - .../rdar-9973865/Test-rdar-9973865.py | 78 - .../data-formatter/rdar-9973865/main.cpp | 30 - .../data-formatter/rdar-9973992/Makefile | 5 - .../rdar-9973992/Test-rdar-9973992.py | 92 - .../data-formatter/rdar-9973992/main.cpp | 41 - .../data-formatter/rdar-9974002/Makefile | 5 - .../rdar-9974002/Test-rdar-9974002.py | 148 - .../data-formatter/rdar-9974002/main.cpp | 30 - lldb/test/functionalities/dead-strip/Makefile | 7 - .../dead-strip/TestDeadStrip.py | 73 - lldb/test/functionalities/dead-strip/cmds.txt | 4 - lldb/test/functionalities/dead-strip/main.c | 53 - .../embedded_interpreter/Makefile | 5 - .../TestConvenienceVariables.py | 89 - .../embedded_interpreter/main.c | 6 - .../expr-doesnt-deadlock/Makefile | 5 - .../TestExprDoesntBlock.py | 69 - .../expr-doesnt-deadlock/locking.c | 80 - .../functionalities/inferior-changed/Makefile | 5 - .../inferior-changed/TestInferiorChanged.py | 90 - .../functionalities/inferior-changed/main.c | 16 - .../functionalities/inferior-changed/main2.c | 18 - .../inferior-crashing/Makefile | 5 - .../inferior-crashing/TestInferiorCrashing.py | 80 - .../functionalities/inferior-crashing/main.c | 16 - .../test/functionalities/load_unload/Makefile | 48 - .../load_unload/TestLoadUnload.py | 230 - lldb/test/functionalities/load_unload/a.c | 15 - lldb/test/functionalities/load_unload/b.c | 13 - lldb/test/functionalities/load_unload/c.c | 13 - .../test/functionalities/load_unload/cmds.txt | 2 - lldb/test/functionalities/load_unload/d.c | 13 - lldb/test/functionalities/load_unload/main.c | 75 - .../test/functionalities/memory/read/Makefile | 5 - .../memory/read/TestMemoryRead.py | 108 - .../test/functionalities/memory/read/main.cpp | 18 - .../non-overlapping-index-variable-i/Makefile | 5 - .../TestIndexVariable.py | 52 - .../non-overlapping-index-variable-i/main.cpp | 51 - .../platform/TestPlatformCommand.py | 39 - .../functionalities/process_launch/Makefile | 7 - .../process_launch/TestProcessLaunch.py | 185 - .../process_launch/input-file.txt | 2 - .../functionalities/process_launch/main.cpp | 17 - .../process_launch/print_cwd.cpp | 13 - lldb/test/functionalities/register/Makefile | 5 - .../functionalities/register/TestRegisters.py | 55 - lldb/test/functionalities/register/main.cpp | 18 - .../functionalities/return-value/Makefile | 5 - .../return-value/TestReturnValue.py | 219 - .../functionalities/return-value/call-func.c | 356 - lldb/test/functionalities/signal/Makefile | 5 - .../functionalities/signal/TestSendSignal.py | 88 - lldb/test/functionalities/signal/main.c | 27 - lldb/test/functionalities/stop-hook/Makefile | 5 - .../stop-hook/TestStopHookCmd.py | 86 - .../stop-hook/TestStopHookMechanism.py | 96 - lldb/test/functionalities/stop-hook/main.cpp | 54 - .../stop-hook/multiple_threads/Makefile | 5 - .../TestStopHookMultipleThreads.py | 76 - .../stop-hook/multiple_threads/main.cpp | 88 - .../functionalities/target_command/Makefile | 8 - .../target_command/TestTargetCommand.py | 208 - lldb/test/functionalities/target_command/a.c | 16 - lldb/test/functionalities/target_command/b.c | 13 - lldb/test/functionalities/target_command/c.c | 29 - .../functionalities/target_command/globals.c | 25 - .../functionalities/type_completion/Makefile | 5 - .../type_completion/TestTypeCompletion.py | 141 - .../functionalities/type_completion/main.cpp | 52 - .../watchpoint/hello_watchlocation/Makefile | 5 - .../hello_watchlocation/TestWatchLocation.py | 115 - .../watchpoint/hello_watchlocation/main.cpp | 100 - .../watchpoint/hello_watchpoint/Makefile | 5 - .../hello_watchpoint/TestMyFirstWatchpoint.py | 95 - .../watchpoint/hello_watchpoint/main.c | 30 - .../watchpoint/multiple_threads/Makefile | 5 - .../TestWatchpointMultipleThreads.py | 104 - .../watchpoint/multiple_threads/main.cpp | 92 - .../watchpoint/watchpoint_commands/Makefile | 5 - .../TestWatchpointCommands.py | 377 - .../watchpoint_commands/condition/Makefile | 5 - .../condition/TestWatchpointConditionCmd.py | 93 - .../watchpoint_commands/condition/main.cpp | 28 - .../watchpoint/watchpoint_commands/main.c | 24 - .../watchpoint_set_command/Makefile | 5 - .../TestWatchLocationWithWatchSet.py | 104 - .../TestWatchpointSetErrorCases.py | 77 - .../watchpoint_set_command/main.cpp | 109 - lldb/test/help/TestHelp.py | 137 - lldb/test/lang/c/anonymous/Makefile | 5 - lldb/test/lang/c/anonymous/TestAnonymous.py | 61 - lldb/test/lang/c/anonymous/main.c | 28 - lldb/test/lang/c/array_types/Makefile | 5 - .../test/lang/c/array_types/TestArrayTypes.py | 221 - lldb/test/lang/c/array_types/cmds.txt | 3 - lldb/test/lang/c/array_types/main.c | 51 - lldb/test/lang/c/bitfields/Makefile | 5 - lldb/test/lang/c/bitfields/TestBitfields.py | 159 - lldb/test/lang/c/bitfields/main.c | 47 - lldb/test/lang/c/blocks/Makefile | 5 - lldb/test/lang/c/blocks/TestBlocks.py | 76 - lldb/test/lang/c/blocks/main.c | 21 - lldb/test/lang/c/enum_types/Makefile | 5 - lldb/test/lang/c/enum_types/TestEnumTypes.py | 74 - lldb/test/lang/c/enum_types/main.c | 29 - lldb/test/lang/c/forward/Makefile | 5 - lldb/test/lang/c/forward/README.txt | 5 - .../lang/c/forward/TestForwardDeclaration.py | 67 - lldb/test/lang/c/forward/foo.c | 8 - lldb/test/lang/c/forward/foo.h | 4 - lldb/test/lang/c/forward/main.c | 18 - lldb/test/lang/c/function_types/Makefile | 5 - .../c/function_types/TestFunctionTypes.py | 106 - lldb/test/lang/c/function_types/main.c | 22 - lldb/test/lang/c/global_variables/Makefile | 8 - .../c/global_variables/TestGlobalVariables.py | 85 - lldb/test/lang/c/global_variables/a.c | 15 - lldb/test/lang/c/global_variables/cmds.txt | 3 - lldb/test/lang/c/global_variables/main.c | 23 - lldb/test/lang/c/inlines/Makefile | 5 - lldb/test/lang/c/inlines/inlines.c | 53 - lldb/test/lang/c/inlines/inlines.h | 4 - lldb/test/lang/c/recurse/Makefile | 5 - lldb/test/lang/c/recurse/main.c | 28 - lldb/test/lang/c/set_values/Makefile | 5 - lldb/test/lang/c/set_values/TestSetValues.py | 142 - lldb/test/lang/c/set_values/main.c | 116 - lldb/test/lang/c/shared_lib/Makefile | 7 - lldb/test/lang/c/shared_lib/TestSharedLib.py | 83 - lldb/test/lang/c/shared_lib/foo.c | 22 - lldb/test/lang/c/shared_lib/foo.h | 12 - lldb/test/lang/c/shared_lib/main.c | 13 - lldb/test/lang/c/stepping/Makefile | 5 - .../lang/c/stepping/TestThreadStepping.py | 97 - lldb/test/lang/c/stepping/main.c | 48 - lldb/test/lang/c/strings/Makefile | 5 - lldb/test/lang/c/strings/TestCStrings.py | 68 - lldb/test/lang/c/strings/main.c | 18 - lldb/test/lang/c/struct_types/Makefile | 5 - .../lang/c/struct_types/TestStructTypes.py | 65 - lldb/test/lang/c/struct_types/cmds.txt | 3 - lldb/test/lang/c/struct_types/main.c | 23 - lldb/test/lang/cpp/breakpoints/Makefile | 5 - .../cpp/breakpoints/TestCPPBreakpoints.py | 104 - lldb/test/lang/cpp/breakpoints/nested.cpp | 76 - lldb/test/lang/cpp/class_static/Makefile | 5 - .../cpp/class_static/TestStaticVariables.py | 150 - lldb/test/lang/cpp/class_static/main.cpp | 53 - lldb/test/lang/cpp/class_types/Makefile | 5 - .../lang/cpp/class_types/TestClassTypes.py | 216 - .../class_types/TestClassTypesDisassembly.py | 122 - lldb/test/lang/cpp/class_types/cmds.txt | 3 - lldb/test/lang/cpp/class_types/main.cpp | 126 - lldb/test/lang/cpp/dynamic-value/Makefile | 5 - .../cpp/dynamic-value/TestCppValueCast.py | 154 - .../cpp/dynamic-value/TestDynamicValue.py | 234 - .../lang/cpp/dynamic-value/pass-to-base.cpp | 68 - .../lang/cpp/dynamic-value/sbvalue-cast.cpp | 80 - lldb/test/lang/cpp/exceptions/Makefile | 5 - .../exceptions/TestCPPExceptionBreakpoints.py | 81 - lldb/test/lang/cpp/exceptions/exceptions.cpp | 42 - lldb/test/lang/cpp/namespace/Makefile | 5 - lldb/test/lang/cpp/namespace/TestNamespace.py | 115 - lldb/test/lang/cpp/namespace/cmds.txt | 3 - lldb/test/lang/cpp/namespace/main.cpp | 72 - lldb/test/lang/cpp/signed_types/Makefile | 5 - .../lang/cpp/signed_types/TestSignedTypes.py | 71 - lldb/test/lang/cpp/signed_types/main.cpp | 31 - lldb/test/lang/cpp/static_methods/Makefile | 5 - .../static_methods/TestCPPStaticMethods.py | 53 - lldb/test/lang/cpp/static_methods/main.cpp | 38 - lldb/test/lang/cpp/stl/Makefile | 6 - lldb/test/lang/cpp/stl/TestSTL.py | 149 - .../lang/cpp/stl/TestStdCXXDisassembly.py | 114 - lldb/test/lang/cpp/stl/cmds.txt | 3 - lldb/test/lang/cpp/stl/main.cpp | 29 - lldb/test/lang/cpp/this/Makefile | 5 - lldb/test/lang/cpp/this/TestCPPThis.py | 73 - lldb/test/lang/cpp/this/main.cpp | 53 - lldb/test/lang/cpp/unique-types/Makefile | 5 - .../lang/cpp/unique-types/TestUniqueTypes.py | 89 - lldb/test/lang/cpp/unique-types/main.cpp | 24 - lldb/test/lang/cpp/unsigned_types/Makefile | 5 - .../cpp/unsigned_types/TestUnsignedTypes.py | 69 - lldb/test/lang/cpp/unsigned_types/main.cpp | 22 - lldb/test/lang/cpp/virtual/Makefile | 5 - lldb/test/lang/cpp/virtual/TestVirtual.py | 86 - lldb/test/lang/cpp/virtual/main.cpp | 112 - lldb/test/lang/objc/forward-decl/Container.h | 13 - lldb/test/lang/objc/forward-decl/Container.m | 27 - lldb/test/lang/objc/forward-decl/Makefile | 9 - .../lang/objc/forward-decl/TestForwardDecl.py | 60 - lldb/test/lang/objc/forward-decl/main.m | 14 - lldb/test/lang/objc/foundation/Makefile | 8 - .../lang/objc/foundation/TestConstStrings.py | 70 - .../foundation/TestFoundationDisassembly.py | 135 - .../lang/objc/foundation/TestObjCMethods.py | 263 - .../lang/objc/foundation/TestObjCMethods2.py | 251 - .../foundation/TestObjectDescriptionAPI.py | 89 - .../lang/objc/foundation/TestSymbolTable.py | 84 - .../test/lang/objc/foundation/const-strings.m | 24 - lldb/test/lang/objc/foundation/main.m | 141 - lldb/test/lang/objc/foundation/my-base.h | 8 - lldb/test/lang/objc/foundation/my-base.m | 10 - .../lang/objc/hidden-ivars/InternalDefiner.h | 10 - .../lang/objc/hidden-ivars/InternalDefiner.m | 18 - lldb/test/lang/objc/hidden-ivars/Makefile | 9 - .../lang/objc/hidden-ivars/TestHiddenIvars.py | 93 - lldb/test/lang/objc/hidden-ivars/main.m | 33 - .../lang/objc/objc-builtin-types/Makefile | 5 - .../TestObjCBuiltinTypes.py | 71 - .../lang/objc/objc-builtin-types/main.cpp | 9 - lldb/test/lang/objc/objc-checker/Makefile | 6 - .../objc/objc-checker/TestObjCCheckers.py | 87 - lldb/test/lang/objc/objc-checker/main.m | 30 - .../test/lang/objc/objc-class-method/Makefile | 6 - .../objc-class-method/TestObjCClassMethod.py | 71 - lldb/test/lang/objc/objc-class-method/class.m | 24 - .../lang/objc/objc-dynamic-value/Makefile | 6 - .../TestObjCDynamicValue.py | 191 - .../objc/objc-dynamic-value/dynamic-value.m | 147 - .../test/lang/objc/objc-ivar-offsets/Makefile | 6 - .../objc-ivar-offsets/TestObjCIvarOffsets.py | 89 - lldb/test/lang/objc/objc-ivar-offsets/main.m | 15 - .../objc-ivar-offsets/objc-ivar-offsets.h | 27 - .../objc-ivar-offsets/objc-ivar-offsets.m | 19 - lldb/test/lang/objc/objc-new-syntax/Makefile | 7 - .../objc/objc-new-syntax/TestObjCNewSyntax.py | 124 - lldb/test/lang/objc/objc-new-syntax/main.m | 19 - lldb/test/lang/objc/objc-optimized/Makefile | 8 - .../objc/objc-optimized/TestObjcOptimized.py | 65 - lldb/test/lang/objc/objc-optimized/main.m | 44 - lldb/test/lang/objc/objc-property/Makefile | 6 - .../objc/objc-property/TestObjCProperty.py | 131 - lldb/test/lang/objc/objc-property/main.m | 91 - .../lang/objc/objc-static-method/Makefile | 6 - .../TestObjCStaticMethod.py | 78 - .../lang/objc/objc-static-method/static.m | 29 - lldb/test/lang/objc/objc-stepping/Makefile | 6 - .../objc/objc-stepping/TestObjCStepping.py | 163 - .../lang/objc/objc-stepping/stepping-tests.m | 133 - lldb/test/lang/objc/print-obj/Makefile | 6 - lldb/test/lang/objc/print-obj/TestPrintObj.py | 104 - lldb/test/lang/objc/print-obj/blocked.m | 73 - lldb/test/lang/objc/radar-9691614/Makefile | 7 - .../TestObjCMethodReturningBOOL.py | 63 - lldb/test/lang/objc/radar-9691614/main.m | 67 - lldb/test/lang/objc/rdar-10967107/Makefile | 7 - .../objc/rdar-10967107/TestRdar10967107.py | 61 - lldb/test/lang/objc/rdar-10967107/main.m | 13 - lldb/test/lang/objc/real-definition/Bar.h | 12 - lldb/test/lang/objc/real-definition/Bar.m | 43 - lldb/test/lang/objc/real-definition/Foo.h | 11 - lldb/test/lang/objc/real-definition/Foo.m | 25 - lldb/test/lang/objc/real-definition/Makefile | 6 - .../real-definition/TestRealDefinition.py | 118 - lldb/test/lang/objc/real-definition/main.m | 13 - lldb/test/lang/objc/sample/Makefile | 6 - lldb/test/lang/objc/sample/main.m | 70 - lldb/test/lang/objc/self/Makefile | 6 - lldb/test/lang/objc/self/TestObjCSelf.py | 57 - lldb/test/lang/objc/self/main.m | 54 - lldb/test/lldbbench.py | 112 - lldb/test/lldbtest.py | 1289 - lldb/test/lldbutil.py | 657 - lldb/test/logging/Makefile | 5 - lldb/test/logging/TestLogging.py | 98 - lldb/test/logging/main.cpp | 62 - .../macosx/debug-info/apple_types/Makefile | 6 - .../apple_types/TestAppleTypesIsProduced.py | 87 - .../test/macosx/debug-info/apple_types/main.c | 27 - lldb/test/macosx/order/Makefile | 7 - lldb/test/macosx/order/TestOrderFile.py | 52 - lldb/test/macosx/order/cmds.txt | 3 - lldb/test/macosx/order/main.c | 54 - lldb/test/macosx/order/order-file | 4 - lldb/test/macosx/universal/Makefile | 19 - lldb/test/macosx/universal/TestUniversal.py | 114 - lldb/test/macosx/universal/main.c | 7 - lldb/test/make/Makefile.rules | 310 - lldb/test/pexpect-2.4/ANSI.py | 334 - lldb/test/pexpect-2.4/FSM.py | 331 - lldb/test/pexpect-2.4/INSTALL | 31 - lldb/test/pexpect-2.4/LICENSE | 21 - lldb/test/pexpect-2.4/PKG-INFO | 10 - lldb/test/pexpect-2.4/README | 45 - lldb/test/pexpect-2.4/doc/clean.css | 103 - lldb/test/pexpect-2.4/doc/email.png | Bin 322 -> 0 bytes lldb/test/pexpect-2.4/doc/examples.html | 135 - lldb/test/pexpect-2.4/doc/index.html | 868 - lldb/test/pexpect-2.4/doc/index.template.html | 868 - lldb/test/pexpect-2.4/examples/README | 72 - lldb/test/pexpect-2.4/examples/astat.py | 74 - lldb/test/pexpect-2.4/examples/bd_client.py | 38 - lldb/test/pexpect-2.4/examples/bd_serv.py | 316 - lldb/test/pexpect-2.4/examples/cgishell.cgi | 762 - lldb/test/pexpect-2.4/examples/chess.py | 131 - lldb/test/pexpect-2.4/examples/chess2.py | 131 - lldb/test/pexpect-2.4/examples/chess3.py | 138 - lldb/test/pexpect-2.4/examples/df.py | 34 - .../pexpect-2.4/examples/fix_cvs_files.py | 95 - lldb/test/pexpect-2.4/examples/ftp.py | 47 - lldb/test/pexpect-2.4/examples/hive.py | 437 - lldb/test/pexpect-2.4/examples/monitor.py | 208 - lldb/test/pexpect-2.4/examples/passmass.py | 90 - lldb/test/pexpect-2.4/examples/python.py | 22 - lldb/test/pexpect-2.4/examples/rippy.py | 993 - lldb/test/pexpect-2.4/examples/script.py | 103 - lldb/test/pexpect-2.4/examples/ssh_session.py | 94 - lldb/test/pexpect-2.4/examples/ssh_tunnel.py | 72 - lldb/test/pexpect-2.4/examples/sshls.py | 56 - .../test/pexpect-2.4/examples/table_test.html | 106 - lldb/test/pexpect-2.4/examples/topip.py | 267 - lldb/test/pexpect-2.4/examples/uptime.py | 57 - lldb/test/pexpect-2.4/fdpexpect.py | 82 - lldb/test/pexpect-2.4/pexpect.py | 1850 - lldb/test/pexpect-2.4/pxssh.py | 311 - lldb/test/pexpect-2.4/screen.py | 380 - lldb/test/pexpect-2.4/setup.py | 39 - lldb/test/plugins/builder_base.py | 109 - lldb/test/plugins/builder_darwin.py | 25 - lldb/test/plugins/builder_linux2.py | 4 - .../python_api/debugger/TestDebuggerAPI.py | 38 - .../TestDefaultConstructorForAPIObjects.py | 373 - .../default-constructor/sb_address.py | 22 - .../default-constructor/sb_block.py | 17 - .../default-constructor/sb_breakpoint.py | 35 - .../sb_breakpointlocation.py | 28 - .../default-constructor/sb_broadcaster.py | 20 - .../default-constructor/sb_communication.py | 28 - .../default-constructor/sb_compileunit.py | 15 - .../default-constructor/sb_debugger.py | 56 - .../default-constructor/sb_error.py | 22 - .../default-constructor/sb_event.py | 17 - .../default-constructor/sb_filespec.py | 14 - .../default-constructor/sb_frame.py | 37 - .../default-constructor/sb_function.py | 19 - .../default-constructor/sb_inputreader.py | 13 - .../default-constructor/sb_instruction.py | 16 - .../default-constructor/sb_instructionlist.py | 17 - .../default-constructor/sb_lineentry.py | 14 - .../default-constructor/sb_listener.py | 23 - .../default-constructor/sb_module.py | 29 - .../default-constructor/sb_process.py | 48 - .../default-constructor/sb_section.py | 22 - .../default-constructor/sb_stringlist.py | 17 - .../default-constructor/sb_symbol.py | 16 - .../default-constructor/sb_symbolcontext.py | 15 - .../default-constructor/sb_target.py | 64 - .../default-constructor/sb_thread.py | 37 - .../python_api/default-constructor/sb_type.py | 22 - .../default-constructor/sb_value.py | 66 - .../default-constructor/sb_valuelist.py | 14 - .../default-constructor/sb_watchpoint.py | 22 - .../TestDisassembleRawData.py | 45 - .../TestDisassemble_VST1_64.py | 64 - lldb/test/python_api/event/Makefile | 5 - lldb/test/python_api/event/TestEvents.py | 306 - lldb/test/python_api/event/main.c | 49 - lldb/test/python_api/formatters/Makefile | 5 - .../formatters/TestFormattersSBAPI.py | 359 - lldb/test/python_api/formatters/jas_synth.py | 24 - lldb/test/python_api/formatters/main.cpp | 40 - lldb/test/python_api/frame/Makefile | 5 - lldb/test/python_api/frame/TestFrames.py | 224 - lldb/test/python_api/frame/inlines/Makefile | 5 - .../frame/inlines/TestInlinedFrame.py | 95 - lldb/test/python_api/frame/inlines/inlines.c | 53 - lldb/test/python_api/frame/inlines/inlines.h | 4 - lldb/test/python_api/frame/main.c | 58 - lldb/test/python_api/function_symbol/Makefile | 5 - .../function_symbol/TestDisasmAPI.py | 127 - .../function_symbol/TestSymbolAPI.py | 96 - lldb/test/python_api/function_symbol/main.c | 60 - lldb/test/python_api/hello_world/Makefile | 7 - .../python_api/hello_world/TestHelloWorld.py | 198 - lldb/test/python_api/hello_world/main.c | 15 - lldb/test/python_api/interpreter/Makefile | 5 - .../interpreter/TestCommandInterpreterAPI.py | 91 - lldb/test/python_api/interpreter/main.c | 6 - lldb/test/python_api/lldbutil/frame/Makefile | 6 - .../lldbutil/frame/TestFrameUtils.py | 66 - lldb/test/python_api/lldbutil/frame/main.c | 47 - lldb/test/python_api/lldbutil/iter/Makefile | 6 - .../lldbutil/iter/TestLLDBIterator.py | 134 - .../lldbutil/iter/TestRegistersIterator.py | 92 - lldb/test/python_api/lldbutil/iter/main.cpp | 128 - .../test/python_api/lldbutil/process/Makefile | 6 - .../lldbutil/process/TestPrintStackTraces.py | 58 - .../test/python_api/lldbutil/process/main.cpp | 128 - lldb/test/python_api/module_section/Makefile | 6 - .../module_section/TestModuleAndSection.py | 139 - lldb/test/python_api/module_section/b.cpp | 3 - lldb/test/python_api/module_section/c.cpp | 3 - lldb/test/python_api/module_section/main.cpp | 128 - lldb/test/python_api/process/Makefile | 5 - .../test/python_api/process/TestProcessAPI.py | 318 - lldb/test/python_api/process/io/Makefile | 6 - .../python_api/process/io/TestProcessIO.py | 68 - lldb/test/python_api/process/io/main.c | 14 - lldb/test/python_api/process/main.cpp | 31 - lldb/test/python_api/sbdata/Makefile | 5 - lldb/test/python_api/sbdata/TestSBData.py | 317 - lldb/test/python_api/sbdata/main.cpp | 43 - lldb/test/python_api/symbol-context/Makefile | 5 - .../symbol-context/TestSymbolContext.py | 104 - lldb/test/python_api/symbol-context/main.c | 51 - lldb/test/python_api/target/Makefile | 5 - lldb/test/python_api/target/TestTargetAPI.py | 314 - lldb/test/python_api/target/main.c | 59 - lldb/test/python_api/thread/Makefile | 5 - lldb/test/python_api/thread/TestThreadAPI.py | 293 - lldb/test/python_api/thread/main.cpp | 26 - lldb/test/python_api/thread/main2.cpp | 54 - lldb/test/python_api/type/Makefile | 5 - lldb/test/python_api/type/TestTypeList.py | 123 - lldb/test/python_api/type/main.cpp | 49 - lldb/test/python_api/value/Makefile | 5 - lldb/test/python_api/value/TestValueAPI.py | 145 - .../python_api/value/change_values/Makefile | 5 - .../value/change_values/TestChangeValueAPI.py | 151 - .../python_api/value/change_values/main.c | 29 - .../python_api/value/linked_list/Makefile | 5 - .../linked_list/TestValueAPILinkedList.py | 150 - .../python_api/value/linked_list/main.cpp | 56 - lldb/test/python_api/value/main.c | 42 - lldb/test/python_api/watchpoint/Makefile | 5 - .../watchpoint/TestSetWatchpoint.py | 106 - .../watchpoint/TestWatchpointIgnoreCount.py | 102 - .../watchpoint/TestWatchpointIter.py | 127 - .../python_api/watchpoint/condition/Makefile | 5 - .../condition/TestWatchpointConditionAPI.py | 103 - .../python_api/watchpoint/condition/main.cpp | 28 - lldb/test/python_api/watchpoint/main.c | 24 - .../watchpoint/watchlocation/Makefile | 5 - .../watchlocation/TestSetWatchlocation.py | 103 - .../watchlocation/TestTargetWatchAddress.py | 103 - .../watchpoint/watchlocation/main.cpp | 98 - lldb/test/redo.py | 164 - lldb/test/settings/Makefile | 5 - lldb/test/settings/TestSettings.py | 331 - lldb/test/settings/main.cpp | 70 - lldb/test/source-manager/Makefile | 5 - lldb/test/source-manager/TestSourceManager.py | 191 - lldb/test/source-manager/main.c | 6 - lldb/test/terminal/TestSTTYBeforeAndAfter.py | 124 - lldb/test/types/AbstractBase.py | 242 - lldb/test/types/HideTestFailures.py | 143 - lldb/test/types/Makefile | 7 - lldb/test/types/TestFloatTypes.py | 54 - lldb/test/types/TestFloatTypesExpr.py | 57 - lldb/test/types/TestIntegerTypes.py | 193 - lldb/test/types/TestIntegerTypesExpr.py | 193 - lldb/test/types/basic_type.cpp | 211 - lldb/test/types/char.cpp | 9 - lldb/test/types/double.cpp | 9 - lldb/test/types/float.cpp | 9 - lldb/test/types/int.cpp | 9 - lldb/test/types/long.cpp | 18 - lldb/test/types/long_long.cpp | 18 - lldb/test/types/short.cpp | 9 - lldb/test/types/unsigned_char.cpp | 9 - lldb/test/types/unsigned_int.cpp | 9 - lldb/test/types/unsigned_long.cpp | 18 - lldb/test/types/unsigned_long_long.cpp | 18 - lldb/test/types/unsigned_short.cpp | 9 - lldb/test/unittest2/__init__.py | 68 - lldb/test/unittest2/__main__.py | 10 - lldb/test/unittest2/case.py | 1084 - lldb/test/unittest2/collector.py | 9 - lldb/test/unittest2/compatibility.py | 64 - lldb/test/unittest2/loader.py | 322 - lldb/test/unittest2/main.py | 241 - lldb/test/unittest2/result.py | 183 - lldb/test/unittest2/runner.py | 206 - lldb/test/unittest2/signals.py | 57 - lldb/test/unittest2/suite.py | 287 - lldb/test/unittest2/test/__init__.py | 1 - lldb/test/unittest2/test/dummy.py | 0 lldb/test/unittest2/test/support.py | 177 - lldb/test/unittest2/test/test_assertions.py | 254 - lldb/test/unittest2/test/test_break.py | 260 - lldb/test/unittest2/test/test_case.py | 1065 - lldb/test/unittest2/test/test_discovery.py | 371 - .../unittest2/test/test_functiontestcase.py | 149 - lldb/test/unittest2/test/test_loader.py | 1286 - lldb/test/unittest2/test/test_new_tests.py | 46 - lldb/test/unittest2/test/test_program.py | 239 - lldb/test/unittest2/test/test_result.py | 416 - lldb/test/unittest2/test/test_runner.py | 129 - lldb/test/unittest2/test/test_setups.py | 502 - lldb/test/unittest2/test/test_skipping.py | 143 - lldb/test/unittest2/test/test_suite.py | 341 - .../unittest2/test/test_unittest2_with.py | 143 - lldb/test/unittest2/util.py | 99 - lldb/test/warnings/uuid/Makefile | 5 - .../warnings/uuid/TestUUIDMismatchWanring.py | 113 - lldb/test/warnings/uuid/main.cpp.template | 19 - lldb/tools/Makefile | 13 - lldb/tools/darwin-debug/darwin-debug.cpp | 322 - lldb/tools/darwin-threads/examine-threads.c | 426 - lldb/tools/debugserver/debugnub-exports | 2 - .../debugserver.xcodeproj/project.pbxproj | 736 - .../contents.xcworkspacedata | 7 - .../xcschemes/debugserver.xcscheme | 111 - .../resources/lldb-debugserver-Info.plist | 21 - .../debugserver/scripts/dbgnub-config.pl | 71 - .../debugserver/source/ARM_DWARF_Registers.h | 190 - .../debugserver/source/ARM_GCC_Registers.h | 35 - lldb/tools/debugserver/source/ChangeLog | 1515 - lldb/tools/debugserver/source/DNB.cpp | 2104 -- lldb/tools/debugserver/source/DNB.h | 162 - lldb/tools/debugserver/source/DNBArch.cpp | 99 - lldb/tools/debugserver/source/DNBArch.h | 93 - .../debugserver/source/DNBBreakpoint.cpp | 303 - lldb/tools/debugserver/source/DNBBreakpoint.h | 159 - lldb/tools/debugserver/source/DNBDataRef.cpp | 485 - lldb/tools/debugserver/source/DNBDataRef.h | 111 - lldb/tools/debugserver/source/DNBDefs.h | 362 - lldb/tools/debugserver/source/DNBError.cpp | 108 - lldb/tools/debugserver/source/DNBError.h | 96 - lldb/tools/debugserver/source/DNBLog.cpp | 354 - lldb/tools/debugserver/source/DNBLog.h | 97 - .../debugserver/source/DNBRegisterInfo.cpp | 220 - .../debugserver/source/DNBRegisterInfo.h | 31 - .../debugserver/source/DNBRuntimeAction.h | 25 - .../source/DNBThreadResumeActions.cpp | 116 - .../source/DNBThreadResumeActions.h | 102 - lldb/tools/debugserver/source/DNBTimer.h | 162 - .../debugserver/source/FunctionProfiler.cpp | 288 - .../debugserver/source/FunctionProfiler.h | 70 - .../debugserver/source/MacOSX/CFBundle.cpp | 87 - .../debugserver/source/MacOSX/CFBundle.h | 37 - .../debugserver/source/MacOSX/CFData.cpp | 85 - lldb/tools/debugserver/source/MacOSX/CFData.h | 39 - .../debugserver/source/MacOSX/CFString.cpp | 201 - .../debugserver/source/MacOSX/CFString.h | 43 - .../tools/debugserver/source/MacOSX/CFUtils.h | 81 - lldb/tools/debugserver/source/MacOSX/HasAVX.h | 27 - lldb/tools/debugserver/source/MacOSX/HasAVX.s | 50 - .../debugserver/source/MacOSX/MachDYLD.cpp | 679 - .../debugserver/source/MacOSX/MachDYLD.h | 145 - .../source/MacOSX/MachException.cpp | 566 - .../debugserver/source/MacOSX/MachException.h | 134 - .../debugserver/source/MacOSX/MachProcess.cpp | 2148 -- .../debugserver/source/MacOSX/MachProcess.h | 286 - .../debugserver/source/MacOSX/MachTask.cpp | 805 - .../debugserver/source/MacOSX/MachTask.h | 130 - .../debugserver/source/MacOSX/MachThread.cpp | 745 - .../debugserver/source/MacOSX/MachThread.h | 141 - .../source/MacOSX/MachThreadList.cpp | 524 - .../source/MacOSX/MachThreadList.h | 71 - .../source/MacOSX/MachVMMemory.cpp | 223 - .../debugserver/source/MacOSX/MachVMMemory.h | 41 - .../source/MacOSX/MachVMRegion.cpp | 202 - .../debugserver/source/MacOSX/MachVMRegion.h | 77 - .../source/MacOSX/arm/DNBArchImpl.cpp | 3292 -- .../source/MacOSX/arm/DNBArchImpl.h | 274 - .../debugserver/source/MacOSX/dbgnub-mig.defs | 16 - .../source/MacOSX/i386/DNBArchImplI386.cpp | 1572 - .../source/MacOSX/i386/DNBArchImplI386.h | 239 - .../MacOSX/i386/MachRegisterStatesI386.h | 180 - .../source/MacOSX/ppc/DNBArchImpl.cpp | 569 - .../source/MacOSX/ppc/DNBArchImpl.h | 179 - .../debugserver/source/MacOSX/stack_logging.h | 122 - .../MacOSX/x86_64/DNBArchImplX86_64.cpp | 1891 - .../source/MacOSX/x86_64/DNBArchImplX86_64.h | 246 - .../MacOSX/x86_64/MachRegisterStatesX86_64.h | 210 - .../debugserver/source/PThreadCondition.h | 53 - .../tools/debugserver/source/PThreadEvent.cpp | 227 - lldb/tools/debugserver/source/PThreadEvent.h | 59 - .../tools/debugserver/source/PThreadMutex.cpp | 84 - lldb/tools/debugserver/source/PThreadMutex.h | 148 - .../debugserver/source/ProfileObjectiveC.cpp | 393 - .../debugserver/source/ProfileObjectiveC.h | 82 - .../debugserver/source/PseudoTerminal.cpp | 227 - .../tools/debugserver/source/PseudoTerminal.h | 94 - lldb/tools/debugserver/source/RNBContext.cpp | 251 - lldb/tools/debugserver/source/RNBContext.h | 147 - lldb/tools/debugserver/source/RNBDefs.h | 76 - lldb/tools/debugserver/source/RNBRemote.cpp | 3580 -- lldb/tools/debugserver/source/RNBRemote.h | 363 - lldb/tools/debugserver/source/RNBServices.cpp | 146 - lldb/tools/debugserver/source/RNBServices.h | 29 - lldb/tools/debugserver/source/RNBSocket.cpp | 328 - lldb/tools/debugserver/source/RNBSocket.h | 76 - lldb/tools/debugserver/source/SysSignal.cpp | 66 - lldb/tools/debugserver/source/SysSignal.h | 23 - lldb/tools/debugserver/source/TTYState.cpp | 122 - lldb/tools/debugserver/source/TTYState.h | 61 - .../source/com.apple.debugserver-secure.plist | 15 - .../com.apple.debugserver.applist.plist | 16 - .../source/com.apple.debugserver.plist | 15 - .../source/debugserver-entitlements.plist | 14 - lldb/tools/debugserver/source/debugserver.cpp | 1464 - lldb/tools/driver/Driver.cpp | 1546 - lldb/tools/driver/Driver.h | 192 - lldb/tools/driver/IOChannel.cpp | 598 - lldb/tools/driver/IOChannel.h | 156 - lldb/tools/driver/Makefile | 30 - lldb/tools/driver/lldb-Info.plist | 21 - lldb/tools/install-headers/Makefile | 17 - lldb/tools/lldb-platform/Makefile | 23 - lldb/tools/lldb-platform/lldb-platform.cpp | 229 - lldb/utils/git-svn/convert.py | 65 - lldb/utils/misc/grep-svn-log.py | 85 - lldb/utils/test/README-disasm | 406 - lldb/utils/test/README-lldb-disasm | 94 - lldb/utils/test/README-run-until-faulted | 18 - lldb/utils/test/disasm.py | 198 - lldb/utils/test/lldb-disasm.py | 243 - lldb/utils/test/llvm-mc-shell.py | 100 - lldb/utils/test/main.c | 14 - lldb/utils/test/ras.py | 176 - lldb/utils/test/run-dis.py | 125 - lldb/utils/test/run-until-faulted.py | 111 - lldb/www/architecture.html | 264 - lldb/www/build.html | 132 - lldb/www/customization.html | 33 - lldb/www/docs.html | 33 - lldb/www/download.html | 47 - lldb/www/faq.html | 30 - lldb/www/features.html | 60 - lldb/www/formats.html | 258 - lldb/www/goals.html | 63 - lldb/www/index.html | 126 - lldb/www/lldb-gdb.html | 884 - lldb/www/python-reference.html | 478 - lldb/www/scripting.html | 586 - lldb/www/sidebar.incl | 51 - lldb/www/status.html | 61 - lldb/www/style.css | 161 - lldb/www/tutorial.html | 715 - lldb/www/varformats.html | 1290 - polly/CMakeLists.txt | 179 - polly/CREDITS.txt | 30 - polly/LICENSE.txt | 61 - polly/Makefile | 17 - polly/Makefile.common.in | 34 - polly/Makefile.config.in | 42 - polly/README | 10 - polly/autoconf/AutoRegen.sh | 33 - polly/autoconf/LICENSE.TXT | 24 - polly/autoconf/aclocal.m4 | 75 - polly/autoconf/config.guess | 1388 - polly/autoconf/config.sub | 1489 - polly/autoconf/configure.ac | 114 - polly/autoconf/configure.bak | 65 - polly/autoconf/m4/find_lib_and_headers.m4 | 46 - polly/cmake/FindCloog.cmake | 19 - polly/cmake/FindGmp.cmake | 19 - polly/cmake/FindIsl.cmake | 19 - polly/cmake/FindOpenScop.cmake | 19 - polly/cmake/FindSCoPLib.cmake | 19 - polly/configure | 4088 --- polly/docs/index.html | 6 - polly/docs/polly.png | Bin 15526 -> 0 bytes polly/docs/polly.svg | 149 - polly/include/CMakeLists.txt | 1 - polly/include/polly/CMakeLists.txt | 9 - polly/include/polly/Cloog.h | 69 - polly/include/polly/CodeGeneration.h | 20 - polly/include/polly/Config/config.h.cmake | 19 - polly/include/polly/Config/config.h.in | 28 - polly/include/polly/Dependences.h | 131 - polly/include/polly/LinkAllPasses.h | 130 - polly/include/polly/LoopGenerators.h | 108 - polly/include/polly/MayAliasSet.h | 157 - polly/include/polly/RegisterPasses.h | 27 - polly/include/polly/ScheduleOptimizer.h | 19 - polly/include/polly/ScopDetection.h | 279 - polly/include/polly/ScopInfo.h | 634 - polly/include/polly/ScopLib.h | 72 - polly/include/polly/ScopPass.h | 64 - polly/include/polly/Support/GICHelper.h | 50 - polly/include/polly/Support/SCEVValidator.h | 36 - polly/include/polly/Support/ScopHelper.h | 85 - polly/include/polly/TempScopInfo.h | 298 - polly/lib/Analysis/CMakeLists.txt | 8 - polly/lib/Analysis/Dependences.cpp | 277 - polly/lib/Analysis/Makefile | 17 - polly/lib/Analysis/ScopDetection.cpp | 612 - polly/lib/Analysis/ScopGraphPrinter.cpp | 216 - polly/lib/Analysis/ScopInfo.cpp | 1020 - polly/lib/Analysis/ScopPass.cpp | 42 - polly/lib/Analysis/TempScopInfo.cpp | 319 - polly/lib/CMakeLists.txt | 47 - polly/lib/Cloog.cpp | 335 - polly/lib/CodeGen/CMakeLists.txt | 4 - polly/lib/CodeGen/CodeGeneration.cpp | 1768 - polly/lib/CodeGen/LoopGenerators.cpp | 335 - polly/lib/CodeGen/Makefile | 16 - polly/lib/CodePreparation.cpp | 174 - polly/lib/DeadCodeElimination.cpp | 75 - polly/lib/Exchange/CMakeLists.txt | 18 - polly/lib/Exchange/JSONExporter.cpp | 341 - polly/lib/Exchange/Makefile | 16 - polly/lib/Exchange/OpenScopExporter.cpp | 587 - polly/lib/Exchange/OpenScopImporter.cpp | 252 - polly/lib/Exchange/ScopLib.cpp | 756 - polly/lib/Exchange/ScopLibExporter.cpp | 99 - polly/lib/Exchange/ScopLibImporter.cpp | 120 - polly/lib/IndVarSimplify.cpp | 2003 -- polly/lib/IndependentBlocks.cpp | 556 - polly/lib/JSON/CMakeLists.txt | 6 - polly/lib/JSON/LICENSE.txt | 1 - polly/lib/JSON/Makefile | 16 - polly/lib/JSON/include/json/autolink.h | 19 - polly/lib/JSON/include/json/config.h | 43 - polly/lib/JSON/include/json/features.h | 42 - polly/lib/JSON/include/json/forwards.h | 39 - polly/lib/JSON/include/json/json.h | 10 - polly/lib/JSON/include/json/reader.h | 196 - polly/lib/JSON/include/json/value.h | 1069 - polly/lib/JSON/include/json/writer.h | 174 - polly/lib/JSON/json_batchallocator.h | 125 - polly/lib/JSON/json_internalarray.inl | 448 - polly/lib/JSON/json_internalmap.inl | 607 - polly/lib/JSON/json_reader.cpp | 890 - polly/lib/JSON/json_value.cpp | 1727 - polly/lib/JSON/json_valueiterator.inl | 292 - polly/lib/JSON/json_writer.cpp | 829 - polly/lib/JSON/sconscript | 8 - polly/lib/Makefile | 95 - polly/lib/MayAliasSet.cpp | 47 - polly/lib/Pocc.cpp | 282 - polly/lib/RegionSimplify.cpp | 222 - polly/lib/RegisterPasses.cpp | 269 - polly/lib/ScheduleOptimizer.cpp | 567 - polly/lib/Support/CMakeLists.txt | 5 - polly/lib/Support/GICHelper.cpp | 112 - polly/lib/Support/Makefile | 16 - polly/lib/Support/SCEVValidator.cpp | 332 - polly/lib/Support/ScopHelper.cpp | 247 - polly/test/CMakeLists.txt | 72 - polly/test/Cloog/ambigous_schedule.ll | 118 - ...us_schedule___%for.cond---%for.end30.jscop | 28 - polly/test/CodeGen/20100617.ll | 20 - polly/test/CodeGen/20100622.ll | 44 - polly/test/CodeGen/20100707.ll | 28 - polly/test/CodeGen/20100707_2.ll | 116 - polly/test/CodeGen/20100708.ll | 19 - polly/test/CodeGen/20100708_2.ll | 29 - polly/test/CodeGen/20100713.ll | 35 - polly/test/CodeGen/20100713_2.ll | 35 - polly/test/CodeGen/20100717.ll | 40 - polly/test/CodeGen/20100718-DomInfo-2.ll | 36 - polly/test/CodeGen/20100718-DomInfo.ll | 29 - .../CodeGen/20100720-MultipleConditions.c | 23 - .../CodeGen/20100720-MultipleConditions.ll | 73 - .../test/CodeGen/20100809-IndependentBlock.ll | 31 - ...0100811-ScalarDependencyBetweenBrAndCnd.ll | 30 - polly/test/CodeGen/20101030-Overflow.ll | 22 - polly/test/CodeGen/20101103-Overflow3.ll | 24 - polly/test/CodeGen/20101103-signmissmatch.ll | 38 - .../test/CodeGen/20110226-Ignore-Dead-Code.ll | 60 - .../test/CodeGen/20110226-PHI-Node-removed.ll | 30 - .../CodeGen/20110312-Fail-without-basicaa.ll | 28 - polly/test/CodeGen/20120316-InvalidCast.ll | 20 - .../CodeGen/20120403-RHS-type-mismatch.ll | 27 - .../MemAccess/codegen_constant_offset.c | 8 - .../MemAccess/codegen_constant_offset.ll | 34 - ...nstant_offset___%for.cond---%for.end.jscop | 25 - ...t___%for.cond---%for.end.jscop.transformed | 25 - polly/test/CodeGen/MemAccess/codegen_simple.c | 8 - .../test/CodeGen/MemAccess/codegen_simple.ll | 34 - ...odegen_simple___%for.cond---%for.end.jscop | 25 - ...e___%for.cond---%for.end.jscop.transformed | 25 - .../CodeGen/MemAccess/codegen_simple_md.c | 9 - .../CodeGen/MemAccess/codegen_simple_md.ll | 64 - ...en_simple_md___%for.cond---%for.end6.jscop | 17 - ...nd---%for.end6.jscop.transformed+withconst | 17 - ...--%for.end6.jscop.transformed+withoutconst | 17 - polly/test/CodeGen/MemAccess/simple.c | 17 - polly/test/CodeGen/MemAccess/simple.ll | 47 - .../simple___%for.cond---%for.end.jscop | 17 - ...e___%for.cond---%for.end.jscop.transformed | 17 - .../simple___%for.cond4---%for.end14.jscop | 17 - ..._%for.cond4---%for.end14.jscop.transformed | 17 - .../test/CodeGen/MemAccess/simple_analyze.ll | 48 - .../CodeGen/OpenMP/20120330-argument-use.c | 28 - .../CodeGen/OpenMP/20120330-argument-use.ll | 41 - polly/test/CodeGen/OpenMP/add_memref.c | 10 - polly/test/CodeGen/OpenMP/add_memref.ll | 29 - polly/test/CodeGen/OpenMP/extract_memref.c | 17 - polly/test/CodeGen/OpenMP/extract_memref.ll | 39 - .../CodeGen/OpenMP/invalidate_subfn_scops.c | 11 - .../CodeGen/OpenMP/invalidate_subfn_scops.ll | 38 - polly/test/CodeGen/OpenMP/parallel_loop.c | 21 - polly/test/CodeGen/OpenMP/parallel_loop.ll | 186 - .../parallel_loop___%bb18---%bb50.jscop | 42 - .../parallel_loop___%bb18---%bb50.jscop.tiled | 42 - .../CodeGen/OpenMP/parallel_loop_simple.c | 15 - .../CodeGen/OpenMP/parallel_loop_simple.ll | 56 - .../CodeGen/OpenMP/parallel_loop_simple2.c | 15 - .../CodeGen/OpenMP/parallel_loop_simple2.ll | 64 - .../test/CodeGen/OpenMP/simple_nested_loop.c | 22 - .../test/CodeGen/OpenMP/simple_nested_loop.ll | 67 - polly/test/CodeGen/OpenMP/structnames.c | 26 - polly/test/CodeGen/OpenMP/structnames.ll | 77 - polly/test/CodeGen/OpenMP/two_loop.c | 24 - polly/test/CodeGen/OpenMP/two_loop.ll | 56 - polly/test/CodeGen/PHIInExit.ll | 77 - polly/test/CodeGen/constant_condition.c | 23 - polly/test/CodeGen/constant_condition.ll | 32 - polly/test/CodeGen/do_pluto_matmult.c | 74 - polly/test/CodeGen/do_pluto_matmult.ll | 229 - polly/test/CodeGen/do_pluto_matmult.ll.result | 36 - ...pluto_matmult___%do.body---%do.end45.jscop | 25 - ...%do.body---%do.end45.jscop.invalid_reverse | 25 - ...__%do.body---%do.end45.jscop.valid_reverse | 25 - polly/test/CodeGen/loop_with_condition.c | 39 - polly/test/CodeGen/loop_with_condition.ll | 140 - polly/test/CodeGen/loop_with_condition_2.ll | 141 - polly/test/CodeGen/loop_with_condition_ineq.c | 39 - .../test/CodeGen/loop_with_condition_ineq.ll | 141 - .../test/CodeGen/loop_with_condition_nested.c | 45 - .../CodeGen/loop_with_condition_nested.ll | 172 - polly/test/CodeGen/matmul_vec.c | 46 - polly/test/CodeGen/matmul_vec.ll | 92 - .../test/CodeGen/matmul_vec___%1---%17.jscop | 25 - polly/test/CodeGen/pluto_matmult.c | 36 - polly/test/CodeGen/pluto_matmult.ll | 111 - ...uto_matmult___%for.cond---%for.end47.jscop | 25 - polly/test/CodeGen/reduction.c | 27 - polly/test/CodeGen/reduction.ll | 63 - polly/test/CodeGen/reduction_2.c | 23 - polly/test/CodeGen/reduction_2.ll | 71 - polly/test/CodeGen/scev.ll | 23 - polly/test/CodeGen/sequential_loops.c | 31 - polly/test/CodeGen/sequential_loops.ll | 108 - polly/test/CodeGen/simple_nonaffine_loop.c | 15 - polly/test/CodeGen/simple_nonaffine_loop.ll | 43 - polly/test/CodeGen/simple_vec_assign_scalar.c | 15 - .../test/CodeGen/simple_vec_assign_scalar.ll | 43 - .../test/CodeGen/simple_vec_assign_scalar_2.c | 15 - .../CodeGen/simple_vec_assign_scalar_2.ll | 49 - polly/test/CodeGen/simple_vec_call.ll | 43 - polly/test/CodeGen/simple_vec_call_2.ll | 45 - polly/test/CodeGen/simple_vec_cast.ll | 33 - polly/test/CodeGen/simple_vec_const.c | 15 - polly/test/CodeGen/simple_vec_const.ll | 43 - polly/test/CodeGen/simple_vec_impossible.ll | 38 - polly/test/CodeGen/simple_vec_large_width.ll | 41 - polly/test/CodeGen/simple_vec_stride_one.c | 15 - polly/test/CodeGen/simple_vec_stride_one.ll | 71 - .../simple_vec_stride_one___%1---%5.jscop | 17 - polly/test/CodeGen/simple_vec_stride_x.c | 15 - polly/test/CodeGen/simple_vec_stride_x.ll | 59 - polly/test/CodeGen/simple_vec_two_stmts.ll | 52 - .../single_do_loop_int_max_iterations.c | 34 - .../single_do_loop_int_max_iterations.ll | 59 - ..._max_iterations___%do.body---%do.end.jscop | 13 - .../single_do_loop_int_param_iterations.c | 25 - .../single_do_loop_int_param_iterations.ll | 51 - .../single_do_loop_ll_max_iterations.c | 25 - .../single_do_loop_ll_max_iterations.ll | 43 - .../CodeGen/single_do_loop_one_iteration.c | 25 - .../CodeGen/single_do_loop_one_iteration.ll | 45 - .../CodeGen/single_do_loop_scev_replace.c | 32 - .../CodeGen/single_do_loop_scev_replace.ll | 64 - polly/test/CodeGen/single_loop.c | 20 - polly/test/CodeGen/single_loop.ll | 66 - .../CodeGen/single_loop_int_max_iterations.c | 21 - .../CodeGen/single_loop_int_max_iterations.ll | 51 - .../CodeGen/single_loop_ll_max_iterations.c | 21 - .../CodeGen/single_loop_ll_max_iterations.ll | 51 - .../test/CodeGen/single_loop_one_iteration.c | 20 - .../test/CodeGen/single_loop_one_iteration.ll | 49 - polly/test/CodeGen/single_loop_param.ll | 76 - .../CodeGen/single_loop_uint_max_iterations.c | 21 - .../single_loop_uint_max_iterations.ll | 50 - .../CodeGen/single_loop_ull_max_iterations.c | 21 - .../CodeGen/single_loop_ull_max_iterations.ll | 50 - .../CodeGen/single_loop_zero_iterations.c | 20 - .../CodeGen/single_loop_zero_iterations.ll | 50 - polly/test/CodeGen/split_edges.ll | 34 - polly/test/CodeGen/split_edges_2.ll | 33 - polly/test/CodeGen/test.c | 19 - polly/test/CodeGen/test.ll | 48 - polly/test/Makefile | 61 - polly/test/README | 1 - .../2011-08-25-crash_in_vectorizer.ll | 44 - .../2012-03-16-Empty-Domain.ll | 17 - ...2012-04-16-Trivially-vectorizable-loops.ll | 205 - .../ScopDetection/single_function_only.ll | 122 - .../20111108-Parameter-not-detected.ll | 56 - ...03-16-Crash-because-of-unsigned-in-scev.ll | 32 - polly/test/ScopInfo/Alias-0.ll | 35 - polly/test/ScopInfo/Alias-1.ll | 36 - polly/test/ScopInfo/Alias-2.ll | 33 - polly/test/ScopInfo/Alias-3.ll | 27 - polly/test/ScopInfo/Alias-4.ll | 27 - polly/test/ScopInfo/bad_loop_0.ll | 45 - polly/test/ScopInfo/bug_2010_10_22.ll | 47 - polly/test/ScopInfo/bug_2011_1_5.ll | 61 - .../test/ScopInfo/bug_scev_not_fully_eval.ll | 36 - polly/test/ScopInfo/cond_in_loop.ll | 48 - polly/test/ScopInfo/indvar_out_of_loop.ll | 41 - polly/test/ScopInfo/indvar_out_of_loop_1.ll | 47 - polly/test/ScopInfo/indvar_out_of_loop_2.ll | 45 - polly/test/ScopInfo/loop_affine_bound_0.ll | 56 - polly/test/ScopInfo/loop_affine_bound_1.ll | 54 - polly/test/ScopInfo/loop_affine_bound_2.ll | 65 - polly/test/ScopInfo/loop_carry.ll | 81 - polly/test/ScopInfo/loop_complex_parameter.ll | 57 - polly/test/ScopInfo/loop_depth_0.ll | 56 - polly/test/ScopInfo/loop_multi_exits.ll | 101 - polly/test/ScopInfo/out_of_loop_0.ll | 35 - polly/test/ScopInfo/phi_not_grouped_at_top.ll | 30 - polly/test/ScopInfo/phi_with_invoke_edge.ll | 27 - polly/test/ScopInfo/simple_loop_1.ll | 30 - polly/test/ScopInfo/simple_nonaffine_loop.ll | 41 - .../ScopInfo/simple_nonaffine_loop_not.ll | 41 - polly/test/ScopInfo/undef_in_cond.ll | 24 - polly/test/TempScop/not-a-reduction.c | 13 - polly/test/TempScop/not-a-reduction.ll | 37 - polly/test/create_ll.sh | 11 - polly/test/lit.cfg | 97 - polly/test/lit.site.cfg.in | 34 - polly/test/polly.ll | 12 - polly/test/polybench/README | 87 - .../datamining/correlation/correlation.c | 165 - .../correlation/correlation_with_param.ll | 169 - .../correlation/correlation_without_param.ll | 117 - .../datamining/covariance/covariance.c | 138 - .../covariance/covariance_with_param.ll | 203 - .../covariance/covariance_without_param.ll | 135 - .../linear-algebra/kernels/2mm/2mm.c | 168 - .../kernels/2mm/2mm_with_param.ll | 164 - .../kernels/2mm/2mm_without_param.ll | 101 - .../linear-algebra/kernels/2mm/compiler.opts | 1 - .../linear-algebra/kernels/3mm/3mm.c | 217 - .../kernels/3mm/3mm_with_param.ll | 213 - .../kernels/3mm/3mm_without_param.ll | 137 - .../linear-algebra/kernels/3mm/compiler.opts | 1 - .../linear-algebra/kernels/atax/atax.c | 119 - .../kernels/atax/atax_with_param.ll | 91 - .../kernels/atax/atax_without_param.ll | 77 - .../linear-algebra/kernels/bicg/bicg.c | 126 - .../kernels/bicg/bicg_with_param.ll | 101 - .../kernels/bicg/bicg_without_param.ll | 69 - .../linear-algebra/kernels/doitgen/doitgen.c | 141 - .../kernels/doitgen/doitgen_with_param.ll | 104 - .../kernels/doitgen/doitgen_without_param.ll | 79 - .../linear-algebra/kernels/gemm/compiler.opts | 1 - .../linear-algebra/kernels/gemm/gemm.c | 139 - .../kernels/gemm/gemm_with_param.ll | 98 - .../kernels/gemm/gemm_without_param.ll | 64 - .../linear-algebra/kernels/gemver/gemver.c | 146 - .../kernels/gemver/gemver_with_param.ll | 154 - .../kernels/gemver/gemver_without_param.ll | 138 - .../linear-algebra/kernels/gesummv/gesummv.c | 127 - .../kernels/gesummv/gesummv_with_param.ll | 73 - .../kernels/gesummv/gesummv_without_param.ll | 66 - .../solvers/gramschmidt/gramschmidt.c | 133 - .../gramschmidt/gramschmidt_with_param.ll | 175 - .../gramschmidt/gramschmidt_without_param.ll | 162 - .../polybench/linear-algebra/solvers/lu/lu.c | 110 - .../solvers/lu/lu_with_param.ll | 97 - .../solvers/lu/lu_without_param.ll | 89 - .../linear-algebra/solvers/ludcmp/ludcmp.c | 145 - .../solvers/ludcmp/ludcmp_with_param.ll | 301 - .../solvers/ludcmp/ludcmp_without_param.ll | 249 - polly/test/polybench/scripts/compile.sh | 14 - polly/test/polybench/scripts/runall.sh | 40 - polly/test/polybench/stencils/adi/adi.c | 147 - .../polybench/stencils/adi/adi_with_param.ll | 251 - .../stencils/adi/adi_without_param.ll | 200 - .../jacobi-2d-imper/jacobi-2d-imper.c | 123 - .../jacobi-2d-imper_with_param.ll | 109 - .../jacobi-2d-imper_without_param.ll | 93 - polly/test/polybench/stencils/seidel/seidel.c | 112 - .../stencils/seidel/seidel_with_param.ll | 96 - .../stencils/seidel/seidel_without_param.ll | 81 - polly/test/polybench/utilities/instrument.c | 87 - polly/test/polybench/utilities/instrument.h | 25 - .../utilities/template-for-new-benchmark.c | 99 - polly/tools/CMakeLists.txt | 1 - polly/tools/Makefile | 13 - polly/utils/argparse.py | 2353 -- polly/utils/checkout_cloog.sh | 92 - polly/utils/jscop2cloog.py | 68 - polly/utils/pyscop/isl.py | 578 - polly/utils/pyscop/jscop2iscc.py | 68 - polly/utils/pyscop/pyscop.py | 68 - polly/www/.htaccess | 1 - polly/www/bugs.html | 35 - polly/www/content.css | 39 - polly/www/contributors.html | 58 - polly/www/documentation.html | 47 - polly/www/documentation/architecture.html | 21 - polly/www/documentation/memaccess.html | 126 - polly/www/documentation/passes.html | 68 - polly/www/example_load_Polly_into_clang.html | 131 - polly/www/example_manual_matmul.html | 454 - polly/www/examples.html | 22 - polly/www/experiments/matmul/.htaccess | 1 - .../matmul/init_array___%1---%19.jscop | 21 - .../experiments/matmul/main___%1---%17.jscop | 40 - .../matmul/main___%1---%17.jscop.interchanged | 40 - .../main___%1---%17.jscop.interchanged+tiled | 40 - ...__%1---%17.jscop.interchanged+tiled+vector | 40 - polly/www/experiments/matmul/matmul.c | 52 - .../experiments/matmul/matmul.normalopt.exe | Bin 8644 -> 0 bytes .../experiments/matmul/matmul.normalopt.ll | Bin 1744 -> 0 bytes .../www/experiments/matmul/matmul.normalopt.s | 203 - ...polly.interchanged+tiled+vector+openmp.exe | Bin 13208 -> 0 bytes ....polly.interchanged+tiled+vector+openmp.ll | Bin 4784 -> 0 bytes ...l.polly.interchanged+tiled+vector+openmp.s | 628 - ...matmul.polly.interchanged+tiled+vector.exe | Bin 8718 -> 0 bytes .../matmul.polly.interchanged+tiled+vector.ll | Bin 2820 -> 0 bytes .../matmul.polly.interchanged+tiled+vector.s | 318 - .../matmul.polly.interchanged+tiled.exe | Bin 8711 -> 0 bytes .../matmul/matmul.polly.interchanged+tiled.ll | Bin 2748 -> 0 bytes .../matmul/matmul.polly.interchanged+tiled.s | 323 - .../matmul/matmul.polly.interchanged.exe | Bin 8705 -> 0 bytes .../matmul/matmul.polly.interchanged.ll | Bin 2308 -> 0 bytes .../matmul/matmul.polly.interchanged.s | 217 - polly/www/experiments/matmul/matmul.preopt.ll | 180 - polly/www/experiments/matmul/matmul.s | 255 - polly/www/experiments/matmul/runall.sh | 94 - .../experiments/matmul/scops.init_array.dot | 47 - .../matmul/scops.init_array.dot.png | Bin 144639 -> 0 bytes polly/www/experiments/matmul/scops.main.dot | 65 - .../www/experiments/matmul/scops.main.dot.png | Bin 175453 -> 0 bytes .../experiments/matmul/scops.print_array.dot | 60 - .../matmul/scops.print_array.dot.png | Bin 181300 -> 0 bytes .../matmul/scopsonly.init_array.dot | 47 - .../matmul/scopsonly.init_array.dot.png | Bin 24332 -> 0 bytes .../www/experiments/matmul/scopsonly.main.dot | 65 - .../experiments/matmul/scopsonly.main.dot.png | Bin 35645 -> 0 bytes .../matmul/scopsonly.print_array.dot | 60 - .../matmul/scopsonly.print_array.dot.png | Bin 30645 -> 0 bytes polly/www/get_started.html | 187 - polly/www/images/architecture.png | Bin 30298 -> 0 bytes polly/www/images/iit-madras.png | Bin 10864 -> 0 bytes polly/www/images/osu.png | Bin 6673 -> 0 bytes .../www/images/performance/parallel-large.png | Bin 43113 -> 0 bytes .../www/images/performance/parallel-small.png | Bin 43404 -> 0 bytes .../images/performance/sequential-large.png | Bin 43852 -> 0 bytes .../images/performance/sequential-small.png | Bin 41102 -> 0 bytes polly/www/images/sys-uni.png | Bin 7919 -> 0 bytes polly/www/images/uni-passau.png | Bin 6780 -> 0 bytes polly/www/images/video-summit-2011.png | Bin 46922 -> 0 bytes polly/www/index.html | 244 - polly/www/menu.css | 40 - polly/www/menu.html.incl | 30 - polly/www/performance.html | 66 - polly/www/phonecall.html | 46 - polly/www/polly.sh | 50 - polly/www/publications.html | 154 - .../publications/grosser-diploma-thesis.pdf | Bin 886366 -> 0 bytes .../grosser-impact-2011-slides.pdf | Bin 734304 -> 0 bytes .../www/publications/grosser-impact-2011.pdf | Bin 323334 -> 0 bytes .../publications/raghesh-a-masters-thesis.pdf | Bin 509037 -> 0 bytes polly/www/todo.html | 419 - polly/www/video-js/video-js.css | 242 - polly/www/video-js/video.js | 1758 - 7270 files changed, 1069968 deletions(-) delete mode 100644 debuginfo-tests/README.txt delete mode 100644 debuginfo-tests/aggregate-indirect-arg.cpp delete mode 100644 debuginfo-tests/block_var.m delete mode 100644 debuginfo-tests/blocks.m delete mode 100644 debuginfo-tests/ctor.cpp delete mode 100644 debuginfo-tests/dbg-arg.ll delete mode 100644 debuginfo-tests/dbg-declare.ll delete mode 100644 debuginfo-tests/dbg-declare2.ll delete mode 100644 debuginfo-tests/foreach.m delete mode 100644 debuginfo-tests/forward-declare-class.cpp delete mode 100644 debuginfo-tests/local-var.ll delete mode 100644 debuginfo-tests/local-var2.ll delete mode 100644 debuginfo-tests/nested-struct.cpp delete mode 100644 debuginfo-tests/sret.cpp delete mode 100644 debuginfo-tests/unused-boolean-arg.ll delete mode 100644 libclc/CREDITS.TXT delete mode 100644 libclc/LICENSE.TXT delete mode 100644 libclc/README.TXT delete mode 100644 libclc/build/metabuild.py delete mode 100644 libclc/build/ninja_syntax.py delete mode 100755 libclc/compile-test.sh delete mode 100755 libclc/configure.py delete mode 100644 libclc/generic/include/clc/as_type.h delete mode 100644 libclc/generic/include/clc/clc.h delete mode 100644 libclc/generic/include/clc/clcfunc.h delete mode 100644 libclc/generic/include/clc/clcmacro.h delete mode 100644 libclc/generic/include/clc/clctypes.h delete mode 100644 libclc/generic/include/clc/gentype.inc delete mode 100644 libclc/generic/include/clc/geometric/cross.h delete mode 100644 libclc/generic/include/clc/geometric/distance.h delete mode 100644 libclc/generic/include/clc/geometric/dot.h delete mode 100644 libclc/generic/include/clc/geometric/floatn.inc delete mode 100644 libclc/generic/include/clc/geometric/length.h delete mode 100644 libclc/generic/include/clc/geometric/length.inc delete mode 100644 libclc/generic/include/clc/geometric/normalize.h delete mode 100644 libclc/generic/include/clc/geometric/normalize.inc delete mode 100644 libclc/generic/include/clc/integer/abs.h delete mode 100644 libclc/generic/include/clc/integer/abs.inc delete mode 100644 libclc/generic/include/clc/integer/abs_diff.h delete mode 100644 libclc/generic/include/clc/integer/abs_diff.inc delete mode 100644 libclc/generic/include/clc/integer/add_sat.h delete mode 100644 libclc/generic/include/clc/integer/add_sat.inc delete mode 100644 libclc/generic/include/clc/integer/gentype.inc delete mode 100644 libclc/generic/include/clc/math/cos.h delete mode 100644 libclc/generic/include/clc/math/native_cos.h delete mode 100644 libclc/generic/include/clc/math/native_divide.h delete mode 100644 libclc/generic/include/clc/math/native_sin.h delete mode 100644 libclc/generic/include/clc/math/native_sqrt.h delete mode 100644 libclc/generic/include/clc/math/sin.h delete mode 100644 libclc/generic/include/clc/math/sqrt.h delete mode 100644 libclc/generic/include/clc/math/unary_decl.inc delete mode 100644 libclc/generic/include/clc/math/unary_intrin.inc delete mode 100644 libclc/generic/include/clc/relational/select.h delete mode 100644 libclc/generic/include/clc/synchronization/cl_mem_fence_flags.h delete mode 100644 libclc/generic/lib/SOURCES delete mode 100644 libclc/generic/lib/geometric/cross.cl delete mode 100644 libclc/generic/lib/geometric/dot.cl delete mode 100644 libclc/generic/lib/geometric/length.cl delete mode 100644 libclc/generic/lib/geometric/length.inc delete mode 100644 libclc/generic/lib/geometric/normalize.cl delete mode 100644 libclc/generic/lib/geometric/normalize.inc delete mode 100644 libclc/generic/lib/integer/abs.cl delete mode 100644 libclc/generic/lib/integer/abs.inc delete mode 100644 libclc/generic/lib/integer/abs_diff.cl delete mode 100644 libclc/generic/lib/integer/abs_diff.inc delete mode 100644 libclc/generic/lib/integer/add_sat.cl delete mode 100644 libclc/generic/lib/integer/add_sat.ll delete mode 100644 libclc/generic/lib/integer/add_sat_impl.ll delete mode 100644 libclc/ptx-nvidiacl/include/clc/synchronization/barrier.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_global_id.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_global_size.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_group_id.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_local_id.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_local_size.h delete mode 100644 libclc/ptx-nvidiacl/include/clc/workitem/get_num_groups.h delete mode 100644 libclc/ptx-nvidiacl/lib/SOURCES delete mode 100644 libclc/ptx/lib/SOURCES delete mode 100644 libclc/ptx/lib/integer/add_sat.ll delete mode 100644 libclc/test/cos.cl delete mode 100644 libclc/test/cross.cl delete mode 100644 libclc/test/get_group_id.cl delete mode 100644 libclc/utils/prepare-builtins.cpp delete mode 100644 libclc/www/index.html delete mode 100644 libcxx/CMakeLists.txt delete mode 100644 libcxx/CREDITS.TXT delete mode 100644 libcxx/LICENSE.TXT delete mode 100644 libcxx/Makefile delete mode 100644 libcxx/cmake/Modules/GetTriple.cmake delete mode 100644 libcxx/cmake/Modules/MacroEnsureOutOfSourceBuild.cmake delete mode 100644 libcxx/cmake/config-ix.cmake delete mode 100644 libcxx/include/__bit_reference delete mode 100644 libcxx/include/__config delete mode 100644 libcxx/include/__debug delete mode 100644 libcxx/include/__functional_03 delete mode 100644 libcxx/include/__functional_base delete mode 100644 libcxx/include/__functional_base_03 delete mode 100644 libcxx/include/__hash_table delete mode 100644 libcxx/include/__locale delete mode 100644 libcxx/include/__mutex_base delete mode 100644 libcxx/include/__split_buffer delete mode 100644 libcxx/include/__sso_allocator delete mode 100644 libcxx/include/__std_stream delete mode 100644 libcxx/include/__tree delete mode 100644 libcxx/include/__tuple delete mode 100644 libcxx/include/__tuple_03 delete mode 100644 libcxx/include/__undef_min_max delete mode 100644 libcxx/include/algorithm delete mode 100644 libcxx/include/array delete mode 100644 libcxx/include/atomic delete mode 100644 libcxx/include/bitset delete mode 100644 libcxx/include/cassert delete mode 100644 libcxx/include/ccomplex delete mode 100644 libcxx/include/cctype delete mode 100644 libcxx/include/cerrno delete mode 100644 libcxx/include/cfenv delete mode 100644 libcxx/include/cfloat delete mode 100644 libcxx/include/chrono delete mode 100644 libcxx/include/cinttypes delete mode 100644 libcxx/include/ciso646 delete mode 100644 libcxx/include/climits delete mode 100644 libcxx/include/clocale delete mode 100644 libcxx/include/cmath delete mode 100644 libcxx/include/codecvt delete mode 100644 libcxx/include/complex delete mode 100644 libcxx/include/complex.h delete mode 100644 libcxx/include/condition_variable delete mode 100644 libcxx/include/csetjmp delete mode 100644 libcxx/include/csignal delete mode 100644 libcxx/include/cstdarg delete mode 100644 libcxx/include/cstdbool delete mode 100644 libcxx/include/cstddef delete mode 100644 libcxx/include/cstdint delete mode 100644 libcxx/include/cstdio delete mode 100644 libcxx/include/cstdlib delete mode 100644 libcxx/include/cstring delete mode 100644 libcxx/include/ctgmath delete mode 100644 libcxx/include/ctime delete mode 100644 libcxx/include/cwchar delete mode 100644 libcxx/include/cwctype delete mode 100644 libcxx/include/deque delete mode 100644 libcxx/include/exception delete mode 100644 libcxx/include/ext/__hash delete mode 100644 libcxx/include/ext/hash_map delete mode 100644 libcxx/include/ext/hash_set delete mode 100644 libcxx/include/forward_list delete mode 100644 libcxx/include/fstream delete mode 100644 libcxx/include/functional delete mode 100644 libcxx/include/future delete mode 100644 libcxx/include/initializer_list delete mode 100644 libcxx/include/iomanip delete mode 100644 libcxx/include/ios delete mode 100644 libcxx/include/iosfwd delete mode 100644 libcxx/include/iostream delete mode 100644 libcxx/include/istream delete mode 100644 libcxx/include/iterator delete mode 100644 libcxx/include/limits delete mode 100644 libcxx/include/list delete mode 100644 libcxx/include/locale delete mode 100644 libcxx/include/map delete mode 100644 libcxx/include/memory delete mode 100644 libcxx/include/mutex delete mode 100644 libcxx/include/new delete mode 100644 libcxx/include/numeric delete mode 100644 libcxx/include/ostream delete mode 100644 libcxx/include/queue delete mode 100644 libcxx/include/random delete mode 100644 libcxx/include/ratio delete mode 100644 libcxx/include/regex delete mode 100644 libcxx/include/scoped_allocator delete mode 100644 libcxx/include/set delete mode 100644 libcxx/include/sstream delete mode 100644 libcxx/include/stack delete mode 100644 libcxx/include/stdexcept delete mode 100644 libcxx/include/streambuf delete mode 100644 libcxx/include/string delete mode 100644 libcxx/include/strstream delete mode 100644 libcxx/include/support/solaris/floatingpoint.h delete mode 100644 libcxx/include/support/solaris/wchar.h delete mode 100644 libcxx/include/support/solaris/xlocale.h delete mode 100644 libcxx/include/support/win32/limits_win32.h delete mode 100644 libcxx/include/support/win32/locale_win32.h delete mode 100644 libcxx/include/support/win32/math_win32.h delete mode 100644 libcxx/include/support/win32/support.h delete mode 100644 libcxx/include/system_error delete mode 100644 libcxx/include/tgmath.h delete mode 100644 libcxx/include/thread delete mode 100644 libcxx/include/tuple delete mode 100644 libcxx/include/type_traits delete mode 100644 libcxx/include/typeindex delete mode 100644 libcxx/include/typeinfo delete mode 100644 libcxx/include/unordered_map delete mode 100644 libcxx/include/unordered_set delete mode 100644 libcxx/include/utility delete mode 100644 libcxx/include/valarray delete mode 100644 libcxx/include/vector delete mode 100644 libcxx/lib/CMakeLists.txt delete mode 100755 libcxx/lib/buildit delete mode 100644 libcxx/lib/libc++abi.exp delete mode 100644 libcxx/lib/libc++abi2.exp delete mode 100644 libcxx/lib/libc++sjlj-abi.exp delete mode 100644 libcxx/lib/libc++unexp.exp delete mode 100644 libcxx/lib/notweak.exp delete mode 100644 libcxx/lib/weak.exp delete mode 100644 libcxx/src/algorithm.cpp delete mode 100644 libcxx/src/bind.cpp delete mode 100644 libcxx/src/chrono.cpp delete mode 100644 libcxx/src/condition_variable.cpp delete mode 100644 libcxx/src/debug.cpp delete mode 100644 libcxx/src/exception.cpp delete mode 100644 libcxx/src/future.cpp delete mode 100644 libcxx/src/hash.cpp delete mode 100644 libcxx/src/ios.cpp delete mode 100644 libcxx/src/iostream.cpp delete mode 100644 libcxx/src/locale.cpp delete mode 100644 libcxx/src/memory.cpp delete mode 100644 libcxx/src/mutex.cpp delete mode 100644 libcxx/src/new.cpp delete mode 100644 libcxx/src/random.cpp delete mode 100644 libcxx/src/regex.cpp delete mode 100644 libcxx/src/stdexcept.cpp delete mode 100644 libcxx/src/string.cpp delete mode 100644 libcxx/src/strstream.cpp delete mode 100644 libcxx/src/support/solaris/README delete mode 100644 libcxx/src/support/solaris/mbsnrtowcs.inc delete mode 100644 libcxx/src/support/solaris/wcsnrtombs.inc delete mode 100644 libcxx/src/support/solaris/xlocale.c delete mode 100644 libcxx/src/support/win32/locale_win32.cpp delete mode 100644 libcxx/src/support/win32/support.cpp delete mode 100644 libcxx/src/system_error.cpp delete mode 100644 libcxx/src/thread.cpp delete mode 100644 libcxx/src/typeinfo.cpp delete mode 100644 libcxx/src/utility.cpp delete mode 100644 libcxx/src/valarray.cpp delete mode 100644 libcxx/test/CMakeLists.txt delete mode 100644 libcxx/test/algorithms/alg.c.library/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.copy/copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.copy/copy_backward.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.copy/copy_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.copy/copy_n.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.fill/fill_n.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.generate/generate.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.generate/generate_n.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.move/move.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.move/move_backward.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.partitions/partition.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.partitions/partition_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.partitions/stable_partition.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.random.shuffle/random_shuffle.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.random.shuffle/random_shuffle_rand.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.random.shuffle/random_shuffle_urng.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.remove/remove.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.remove/remove_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.remove/remove_copy_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.remove/remove_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.replace/replace.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.replace/replace_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.replace/replace_copy_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.replace/replace_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.reverse/reverse.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.reverse/reverse_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.rotate/rotate.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.rotate/rotate_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.swap/iter_swap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.swap/swap_ranges.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.transform/binary_transform.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.transform/unary_transform.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.unique/unique.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.unique/unique_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.unique/unique_copy_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/alg.unique/unique_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.modifying.operations/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.adjacent.find/adjacent_find.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.adjacent.find/adjacent_find_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.count/count.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.count/count_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.equal/equal.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.equal/equal_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find.end/find_end.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find.end/find_end_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find.first.of/find_first_of.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find.first.of/find_first_of_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find/find.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find/find_if.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.find/find_if_not.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.foreach/test.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.search/search.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/alg.search/search_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/mismatch/mismatch.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/mismatch/mismatch_pred.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.nonmodifying/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/binary.search/binary_search.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/binary.search/binary_search_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/equal.range/equal_range.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/equal.range/equal_range_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/lower.bound/lower_bound.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/lower.bound/lower_bound_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/upper.bound/upper_bound.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.binary.search/upper.bound/upper_bound_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/make.heap/make_heap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/make.heap/make_heap_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/pop.heap/pop_heap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/pop.heap/pop_heap_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/push.heap/push_heap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/push.heap/push_heap_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/sort.heap/sort_heap.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.heap.operations/sort.heap/sort_heap_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.lex.comparison/lexicographical_compare.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.lex.comparison/lexicographical_compare_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.merge/inplace_merge.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.merge/inplace_merge_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.merge/merge.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.merge/merge_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max_element.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max_element_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max_init_list.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/max_init_list_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min_element.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min_element_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min_init_list.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/min_init_list_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax_element.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax_element_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax_init_list.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.min.max/minmax_init_list_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.nth.element/nth_element.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.nth.element/nth_element_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.permutation.generators/next_permutation.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.permutation.generators/next_permutation_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.permutation.generators/prev_permutation.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.permutation.generators/prev_permutation_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/includes/includes.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/includes/includes_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.difference/set_difference.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.difference/set_difference_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.intersection/set_intersection.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.intersection/set_intersection_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.symmetric.difference/set_symmetric_difference.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.symmetric.difference/set_symmetric_difference_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.union/set_union.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.set.operations/set.union/set_union_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/partial.sort.copy/partial_sort_copy.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/partial.sort.copy/partial_sort_copy_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/sort/sort.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/sort/sort_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/stable.sort/stable_sort.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/alg.sort/stable.sort/stable_sort_comp.pass.cpp delete mode 100644 libcxx/test/algorithms/alg.sorting/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/algorithms.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/algorithms/iterators.h delete mode 100644 libcxx/test/algorithms/version.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.fences/atomic_signal_fence.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.fences/atomic_thread_fence.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/atomic_flag_clear.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/atomic_flag_clear_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/atomic_flag_test_and_set.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/atomic_flag_test_and_set_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/clear.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/copy_assign.fail.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/copy_ctor.fail.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/copy_volatile_assign.fail.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/default.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/init.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.flag/test_and_set.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.lockfree/lockfree.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.order/kill_dependency.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.order/memory_order.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.syn/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.generic/address.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.generic/bool.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.generic/cstdint_typedefs.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.generic/integral.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.generic/integral_typedefs.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.arith/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.pointer/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_compare_exchange_strong.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_compare_exchange_strong_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_compare_exchange_weak.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_compare_exchange_weak_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_exchange.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_exchange_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_and.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_and_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_or.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_or_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_xor.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_xor_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_init.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_is_lock_free.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_load.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_load_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_store.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_store_explicit.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.req/atomic_var_init.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/atomics.types.operations.templ/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/atomics.types.operations/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/atomics/version.pass.cpp delete mode 100644 libcxx/test/containers/Copyable.h delete mode 100644 libcxx/test/containers/DefaultOnly.h delete mode 100644 libcxx/test/containers/Emplaceable.h delete mode 100644 libcxx/test/containers/MoveOnly.h delete mode 100644 libcxx/test/containers/NotConstructible.h delete mode 100644 libcxx/test/containers/associative/map/map.access/at.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/empty.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/index_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/index_rv_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/iterator.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/max_size.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.access/size.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/copy_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/default_recursive.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/initializer_list_compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/initializer_list_compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/iter_iter_comp.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/iter_iter_comp_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_iter_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_iter_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.modifiers/insert_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.ops/count.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.ops/equal_range.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.ops/find.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.ops/lower_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.ops/upper_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.special/member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.special/non_member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/map.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/types.pass.cpp delete mode 100644 libcxx/test/containers/associative/map/version.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/empty.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/iterator.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/max_size.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/copy_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/initializer_list_compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/initializer_list_compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/iter_iter_comp.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/iter_iter_comp_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_iter_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_iter_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.modifiers/insert_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.ops/count.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.ops/equal_range.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.ops/find.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.ops/lower_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.ops/upper_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.special/member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/multimap.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/size.pass.cpp delete mode 100644 libcxx/test/containers/associative/multimap/types.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/clear.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/count.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/emplace.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/empty.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/equal_range.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/find.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_iter_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_iter_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/insert_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/iterator.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/lower_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/max_size.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/copy_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/initializer_list_compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/initializer_list_compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/iter_iter_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/iter_iter_comp.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.special/member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/multiset.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/size.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/types.pass.cpp delete mode 100644 libcxx/test/containers/associative/multiset/upper_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/clear.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/count.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/emplace.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/empty.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/equal_range.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/find.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_iter_cv.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_iter_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/insert_rv.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/iterator.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/lower_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/max_size.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/copy_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/initializer_list_compare.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/initializer_list_compare_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/iter_iter_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/iter_iter_comp.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.special/member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.special/non_member_swap.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/set.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/size.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/types.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/upper_bound.pass.cpp delete mode 100644 libcxx/test/containers/associative/set/version.pass.cpp delete mode 100644 libcxx/test/containers/associative/tree_balance_after_insert.pass.cpp delete mode 100644 libcxx/test/containers/associative/tree_left_rotate.pass.cpp delete mode 100644 libcxx/test/containers/associative/tree_remove.pass.cpp delete mode 100644 libcxx/test/containers/associative/tree_right_rotate.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_comp_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_comp_cont_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_comp_rcont_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ctor_move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_comp.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_comp_container.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_comp_rcontainer.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_default.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_iter_comp.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_iter_comp_cont.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_iter_comp_rcont.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/ctor_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/emplace.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/empty.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/pop.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/push.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/push_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/size.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.members/top.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/priqueue.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/priority.queue/types.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons.alloc/ctor_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons.alloc/ctor_container_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons.alloc/ctor_queue_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons.alloc/ctor_rcontainer_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons.alloc/ctor_rqueue_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/ctor_container.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/ctor_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/ctor_default.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/ctor_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/ctor_rcontainer.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/back.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/back_const.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/emplace.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/empty.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/front.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/front_const.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/pop.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/push.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/push_rv.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/size.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.defn/types.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.ops/eq.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.ops/lt.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/queue.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/queue/version.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons.alloc/ctor_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons.alloc/ctor_container_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons.alloc/ctor_copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons.alloc/ctor_rcontainer_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons.alloc/ctor_rqueue_alloc.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/ctor_container.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/ctor_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/ctor_default.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/ctor_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/ctor_rcontainer.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/emplace.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/empty.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/pop.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/push.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/push_rv.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/size.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/top.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/top_const.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.defn/types.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.ops/eq.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.ops/lt.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/stack.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/container.adaptors/stack/version.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/associative.reqmts/associative.reqmts.except/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/associative.reqmts/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/container.requirements.dataraces/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/container.requirements.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/sequence.reqmts/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/unord.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/container.requirements/unord.req/unord.req.except/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/containers.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/iterators.h delete mode 100644 libcxx/test/containers/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.data/data.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.data/data_const.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.fill/fill.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.size/size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.swap/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.tuple/get.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.tuple/get_const.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.tuple/get_rv.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.tuple/tuple_element.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.tuple/tuple_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/array.zero/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/begin.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/array/version.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.capacity/access.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.capacity/resize_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.capacity/resize_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.capacity/shrink_to_fit.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/assign_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/assign_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/initializer_list_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/iter_iter_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/op_equal.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/op_equal_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.cons/size_value_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/emplace_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/emplace_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/insert_iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/insert_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/insert_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/insert_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/insert_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/pop_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/pop_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/push_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/push_back_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/push_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.modifiers/push_front_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/copy_backward.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/move_backward.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/deque.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/iterators.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/deque/version.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.access/front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/alloc.fail.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_init.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_op_init.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_range.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/assign_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/init.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/init_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/range.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/range_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/size.fail.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.cons/size_value_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.iter/before_begin.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.iter/iterators.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/emplace_after.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/emplace_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/erase_after_many.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/erase_after_one.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/insert_after_const.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/insert_after_init.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/insert_after_range.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/insert_after_rv.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/insert_after_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/pop_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/push_front_const.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/push_front_rv.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/resize_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.modifiers/resize_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/merge.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/merge_pred.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/remove.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/remove_if.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/reverse.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/sort.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/sort_pred.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/splice_after_flist.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/splice_after_range.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/unique.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.ops/unique_pred.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.spec/member_swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.spec/non_member_swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/forwardlist.spec/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/max_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/forwardlist/version.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/iterators.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.capacity/resize_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.capacity/resize_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/default_stack_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/initializer_list_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/input_iterator.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/op_equal_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/size_type.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.cons/size_value_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/emplace_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/emplace_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/insert_iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/insert_iter_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/insert_iter_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/insert_iter_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/insert_iter_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/pop_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/pop_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/push_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/push_back_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/push_front.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.modifiers/push_front_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/merge.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/merge_comp.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/remove.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/remove_if.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/reverse.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/sort.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/sort_comp.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/splice_pos_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/splice_pos_list_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/splice_pos_list_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/unique.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.ops/unique_pred.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/list.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/list/version.pass.cpp delete mode 100644 libcxx/test/containers/sequences/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/capacity.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_iter_iter_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/construct_size_value_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/initializer_list_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/insert_iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/insert_iter_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/insert_iter_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/insert_iter_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/iterators.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/op_equal_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/push_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/reserve.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/resize_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/resize_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/shrink_to_fit.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector.bool/vector_bool.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/iterators.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/types.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/capacity.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/reserve.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/resize_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/resize_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/shrink_to_fit.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.capacity/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/assign_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_default.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_iter_iter_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_size.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/construct_size_value_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/copy.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/initializer_list_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/move.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.cons/op_equal_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.data/data.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.data/data_const.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/emplace_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/erase_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/erase_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/insert_iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/insert_iter_iter_iter.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/insert_iter_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/insert_iter_size_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/insert_iter_value.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/push_back.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.modifiers/push_back_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.special/swap.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/vector.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/sequences/vector/version.pass.cpp delete mode 100644 libcxx/test/containers/stack_allocator.h delete mode 100644 libcxx/test/containers/test_allocator.h delete mode 100644 libcxx/test/containers/test_compare.h delete mode 100644 libcxx/test/containers/test_hash.h delete mode 100644 libcxx/test/containers/unord/next_prime.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/bucket.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/bucket_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/eq.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/equal_range_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/equal_range_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/find_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/find_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/local_iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/max_bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/max_load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/max_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/rehash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/reserve.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/swap_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/types.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/assign_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/default.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/init_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/init_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/init_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/init_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/range_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/range_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/range_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/range_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/size.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.cnstr/size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.elem/at.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.elem/index.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.swap/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unord.map.swap/swap_non_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/erase_const_iter.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/erase_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_hint_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_hint_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/unorder.map.modifiers/insert_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.map/version.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/bucket.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/bucket_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/eq.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/equal_range_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/equal_range_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/find_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/find_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/local_iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/local_iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/max_bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/max_load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/max_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/rehash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/reserve.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/swap_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/types.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/assign_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/default.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/init_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/init_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/init_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/init_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/range_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/range_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/range_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/range_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/size.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.cnstr/size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/emplace.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/erase_const_iter.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/erase_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_hint_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_hint_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.modifiers/insert_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.swap/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multimap/unord.multimap.swap/swap_non_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/bucket.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/bucket_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/clear.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/emplace.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/eq.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/equal_range_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/equal_range_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/erase_const_iter.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/erase_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/find_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/find_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_hint_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_hint_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/insert_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/local_iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/local_iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/max_bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/max_load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/max_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/rehash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/reserve.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/swap_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/types.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/assign_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/default.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/init_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/init_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/init_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/init_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/range_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/range_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/range_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/range_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/size.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.cnstr/size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.swap/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.multiset/unord.multiset.swap/swap_non_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/bucket.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/bucket_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/clear.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/emplace.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/emplace_hint.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/eq.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/equal_range_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/equal_range_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/erase_const_iter.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/erase_key.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/erase_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/find_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/find_non_const.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_hint_const_lvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_hint_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/insert_rvalue.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/local_iterators.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/local_iterators.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/max_bucket_count.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/max_load_factor.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/max_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/rehash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/reserve.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/swap_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/types.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/assign_copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/assign_init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/assign_move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/copy_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/default.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/default_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/init.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/init_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/init_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/init_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/init_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/move.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/move_alloc.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/move_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/range.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/range_size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/range_size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/range_size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/range_size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/size.fail.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/size.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/size_hash.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/size_hash_equal.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.cnstr/size_hash_equal_allocator.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.swap/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/unord.set.swap/swap_non_member.pass.cpp delete mode 100644 libcxx/test/containers/unord/unord.set/version.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/A.h delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/AB.h delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/assignment.fail.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/assignment.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/convert.fail.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/convert.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/convert_assignment.fail.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/convert_assignment.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/copy.fail.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/copy.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/explicit.fail.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.cons/pointer.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.conv/assign_from_auto_ptr_ref.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.conv/convert_from_auto_ptr_ref.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.conv/convert_to_auto_ptr.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.conv/convert_to_auto_ptr_ref.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.members/arrow.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.members/deref.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.members/release.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/auto.ptr.members/reset.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/auto.ptr/element_type.pass.cpp delete mode 100644 libcxx/test/depr/depr.auto.ptr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/assert_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/ciso646.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/complex.h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/ctype_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/errno_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/fenv_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/float_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/inttypes_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/iso646_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/limits_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/locale_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/math_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/setjmp_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/signal_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stdarg_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stdbool_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stddef_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stdint_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stdio_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/stdlib_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/string_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/tgmath_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/time_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/uchar_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/wchar_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.c.headers/wctype_h.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.function.pointer.adaptors/pointer_to_binary_function.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.function.pointer.adaptors/pointer_to_unary_function.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.function.pointer.adaptors/ptr_fun1.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.function.pointer.adaptors/ptr_fun2.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun1.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun1_ref_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun1_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun_ref.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun_ref1.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun_ref_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/const_mem_fun_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun1.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun1_ref_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun1_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun_ref.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun_ref1.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun_ref_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun_t.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.adaptors/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.base/binary_function.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/depr.base/unary_function.pass.cpp delete mode 100644 libcxx/test/depr/depr.function.objects/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/depr/depr.ios.members/io_state.pass.cpp delete mode 100644 libcxx/test/depr/depr.ios.members/open_mode.pass.cpp delete mode 100644 libcxx/test/depr/depr.ios.members/seek_dir.pass.cpp delete mode 100644 libcxx/test/depr/depr.ios.members/streamoff.pass.cpp delete mode 100644 libcxx/test/depr/depr.ios.members/streampos.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/depr.lib.bind.1st/bind1st.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/depr.lib.bind.2nd/bind2nd.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/depr.lib.binder.1st/binder1st.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/depr.lib.binder.2nd/binder2nd.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/depr/depr.lib.binders/test_func.h delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.cons/ccp.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.cons/ccp_size.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.cons/cp.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.cons/cp_size.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/depr.istrstream.members/str.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.istrstream/types.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.cons/cp_size_mode.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.cons/default.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.members/freeze.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.members/pcount.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/depr.ostrstream.members/str.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.ostrstream/types.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.cons/cp_size_mode.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.cons/default.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.dest/rdbuf.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.oper/freeze.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.oper/pcount.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/depr.strstream.oper/str.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstream/types.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/ccp_size.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/cp_size_cp.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/cscp_size.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/cucp_size.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/custom_alloc.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/default.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/scp_size_scp.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.cons/ucp_size_ucp.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.members/freeze.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.members/pcount.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.members/str.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/overflow.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/pbackfail.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/seekoff.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/seekpos.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/setbuf.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/depr.strstreambuf.virtuals/underflow.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/depr.strstreambuf/types.pass.cpp delete mode 100644 libcxx/test/depr/depr.str.strstreams/version.pass.cpp delete mode 100644 libcxx/test/depr/exception.unexpected/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/depr/exception.unexpected/set.unexpected/get_unexpected.pass.cpp delete mode 100644 libcxx/test/depr/exception.unexpected/set.unexpected/set_unexpected.pass.cpp delete mode 100644 libcxx/test/depr/exception.unexpected/unexpected.handler/unexpected_handler.pass.cpp delete mode 100644 libcxx/test/depr/exception.unexpected/unexpected/unexpected.pass.cpp delete mode 100644 libcxx/test/depr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/assertions/cassert.pass.cpp delete mode 100644 libcxx/test/diagnostics/diagnostics.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/errno/cerrno.pass.cpp delete mode 100644 libcxx/test/diagnostics/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/domain.error/domain_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/invalid.argument/invalid_argument.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/length.error/length_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/logic.error/logic_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/out.of.range/out_of_range.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/overflow.error/overflow_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/range.error/range_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/runtime.error/runtime_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/underflow.error/underflow_error.pass.cpp delete mode 100644 libcxx/test/diagnostics/std.exceptions/version.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/errc.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.compare/eq_error_code_error_code.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.derived/message.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/eq.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/lt.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/neq.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/generic_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/system_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.overview/error_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.virtuals/default_error_condition.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.virtuals/equivalent_error_code_int.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcat/syserr.errcat.virtuals/equivalent_int_error_condition.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.constructors/ErrorCodeEnum.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.constructors/default.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.constructors/int_error_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.modifiers/ErrorCodeEnum.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.modifiers/assign.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.nonmembers/lt.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.nonmembers/make_error_code.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.nonmembers/stream_inserter.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.observers/bool.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.observers/category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.observers/default_error_condition.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.observers/message.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.observers/value.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcode/syserr.errcode.overview/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.constructors/ErrorConditionEnum.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.constructors/default.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.constructors/int_error_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.modifiers/ErrorConditionEnum.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.modifiers/assign.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.modifiers/clear.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.nonmembers/lt.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.nonmembers/make_error_condition.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.observers/bool.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.observers/category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.observers/message.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.observers/value.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.errcondition/syserr.errcondition.overview/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.hash/error_code.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code_const_char_pointer.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code_string.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category_const_char_pointer.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category_string.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/syserr.syserr/syserr.syserr.overview/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/diagnostics/syserr/version.pass.cpp delete mode 100644 libcxx/test/hexfloat.h delete mode 100644 libcxx/test/input.output/file.streams/c.files/cinttypes.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/c.files/cstdio.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/c.files/version_ccstdio.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/c.files/version_cinttypes.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.members/open_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/overflow.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/pbackfail.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/seekoff.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/underflow.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/underflow.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf.virtuals/underflow_utf8.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/filebuf/types.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.cons/pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.members/close.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.members/open_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.members/open_string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/fstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.assign/test.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.assign/test2.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.cons/pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.cons/test.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.members/close.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.members/open_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.members/open_string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream.members/test.dat delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ifstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.cons/pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.members/close.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.members/open_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.members/open_string.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/ofstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/fstreams/version.pass.cpp delete mode 100644 libcxx/test/input.output/file.streams/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/input.output.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/ext.manip/get_money.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/ext.manip/get_time.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/ext.manip/put_money.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/ext.manip/put_time.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/iostream.dest/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/iostreamclass/types.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/bool.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/double.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/float.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/int.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/long_double.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/long_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/short.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/unsigned_int.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/unsigned_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/unsigned_long_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.arithmetic/unsigned_short.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream.formatted.reqmts/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/basic_ios.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/chart.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/ios_base.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/istream.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/signed_char.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/signed_char_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/unsigned_char.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/unsigned_char_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/istream_extractors/wchar_t_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.formatted/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.manip/ws.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.rvalue/rvalue.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get_chart.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get_pointer_size.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get_pointer_size_chart.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get_streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/get_streambuf_chart.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/getline_pointer_size.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/getline_pointer_size_chart.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/ignore.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/peek.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/putback.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/read.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/readsome.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/seekg.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/seekg_off.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/sync.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/tellg.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream.unformatted/unget.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/istream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/istream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/istream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/istream.cons/streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/istream_sentry/ctor.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/istream/types.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/input.streams/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.cons/streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.formatted.reqmts/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/bool.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/double.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/float.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/int.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/long_double.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/long_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/short.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/unsigned_int.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/unsigned_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/unsigned_long_long.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.arithmetic/unsigned_short.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/CharT.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/CharT_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/char.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/char_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/char_to_wide.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/char_to_wide_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/signed_char.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/signed_char_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/unsigned_char.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters.character/unsigned_char_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters/basic_ios.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters/ios_base.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters/ostream.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.formatted/ostream.inserters/streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.manip/endl.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.manip/ends.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.manip/flush.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.rvalue/CharT_pointer.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.seeks/seekp.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.seeks/seekp2.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.seeks/tellp.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.unformatted/flush.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.unformatted/put.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream.unformatted/write.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream/types.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream_sentry/construct.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/ostream_sentry/destruct.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/output.streams/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/resetiosflags.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/setbase.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/setfill.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/setiosflags.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/setprecision.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/setw.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.format/std.manip/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.forward/iosfwd.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.forward/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/narrow.stream.objects/cerr.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/narrow.stream.objects/cin.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/narrow.stream.objects/clog.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/narrow.stream.objects/cout.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/wide.stream.objects/wcerr.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/wide.stream.objects/wcin.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/wide.stream.objects/wclog.pass.cpp delete mode 100644 libcxx/test/input.output/iostream.objects/wide.stream.objects/wcout.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.members/state.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/addition.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/ctor_int.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/difference.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/eq_int.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/offset.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/streamsize.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/fpos.operations/subtraction.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/fpos/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/flags.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/flags_fmtflags.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/precision.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/precision_streamsize.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/setf_fmtflags.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/setf_fmtflags_mask.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/unsetf_mask.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/width.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/fmtflags.state/width_streamsize.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.callback/register_callback.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.cons/dtor.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.locales/getloc.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.locales/imbue.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.storage/iword.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.storage/pword.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.base.storage/xalloc.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.members.static/sync_with_stdio.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_Init/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_failure/ctor_char_pointer_error_code.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_failure/ctor_string_error_code.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_fmtflags/fmtflags.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_iostate/iostate.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_openmode/openmode.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/ios_seekdir/seekdir.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/ios.types/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios.base/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.cons/ctor_streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/copyfmt.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/fill.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/fill_char_type.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/imbue.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/move.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/narow.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/rdbuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/rdbuf_streambuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/set_rdbuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/swap.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/tie.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/tie_ostream.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/basic.ios.members/widen.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/bad.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/bool.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/clear.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/eof.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/exceptions.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/exceptions_iostate.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/fail.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/good.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/not.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/rdstate.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/iostate.flags/setstate.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/ios/types.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/adjustfield.manip/internal.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/adjustfield.manip/left.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/adjustfield.manip/right.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/basefield.manip/dec.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/basefield.manip/hex.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/basefield.manip/oct.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/error.reporting/iostream_category.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/error.reporting/make_error_code.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/error.reporting/make_error_condition.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/floatfield.manip/defaultfloat.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/floatfield.manip/fixed.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/floatfield.manip/hexfloat.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/floatfield.manip/scientific.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/boolalpha.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/noboolalpha.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/noshowbase.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/noshowpoint.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/noshowpos.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/noskipws.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/nounitbuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/nouppercase.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/showbase.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/showpoint.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/showpos.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/skipws.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/unitbuf.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/fmtflags.manip/uppercase.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/std.ios.manip/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/stream.types/streamoff.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/stream.types/streamsize.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.base/version.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.requirements/iostream.limits.imbue/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.requirements/iostreams.limits.pos/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.requirements/iostreams.threadsafety/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/iostreams.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf.reqts/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.cons/copy.fail.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.cons/copy.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.cons/default.fail.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.buffer/pubseekoff.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.buffer/pubseekpos.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.buffer/pubsetbuf.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.buffer/pubsync.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.locales/locales.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.get/in_avail.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.get/sbumpc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.get/sgetc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.get/sgetn.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.get/snextc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.pback/sputbackc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.pback/sungetc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.put/sputc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.members/streambuf.pub.put/sputn.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.assign/assign.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.assign/swap.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.get.area/gbump.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.get.area/setg.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.put.area/pbump.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.protected/streambuf.put.area/setp.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.buffer/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.get/showmanyc.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.get/uflow.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.get/underflow.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.get/xsgetn.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.locales/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.pback/pbackfail.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.put/overflow.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/streambuf.virtuals/streambuf.virt.put/xsputn.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/streambuf/types.pass.cpp delete mode 100644 libcxx/test/input.output/stream.buffers/version.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.assign/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/istringstream.members/str.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/istringstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.assign/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/ostringstream.members/str.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/ostringstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.assign/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.members/str.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/overflow.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/pbackfail.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/seekoff.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/seekpos.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/setbuf.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/stringbuf.virtuals/underflow.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringbuf/types.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/default.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/string.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/stringstream.assign/member_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/stringstream.assign/move.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.cons/stringstream.assign/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream.members/str.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/stringstream/types.pass.cpp delete mode 100644 libcxx/test/input.output/string.streams/version.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.basic/iterator.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.operations/advance.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.operations/distance.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.operations/next.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.operations/prev.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.traits/const_pointer.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.traits/empty.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.traits/iterator.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/iterator.traits/pointer.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/std.iterator.tags/bidirectional_iterator_tag.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/std.iterator.tags/forward_iterator_tag.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/std.iterator.tags/input_iterator_tag.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/std.iterator.tags/output_iterator_tag.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.primitives/std.iterator.tags/random_access_iterator_tag.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/bidirectional.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/forward.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/input.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/iterator.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/iterator.requirements.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/output.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.requirements/random.access.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterator.synopsis/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterators.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/iterators.h delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.cons/container.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.cons/container.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.op++/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.op++/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.op=/lv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.op=/rv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.insert.iter.op_astrk/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/back.inserter/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iter.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/back.insert.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.cons/container.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.cons/container.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.op++/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.op++/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.op=/lv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.op=/rv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.insert.iter.op_astrk/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/front.inserter/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iter.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/front.insert.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.cons/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.op++/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.op++/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.op=/lv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.op=/rv_value.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/insert.iter.op_astrk/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/inserter/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iter.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/insert.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/insert.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.nonmember/make_move_iterator.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.nonmember/minus.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.nonmember/plus.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.+/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.+=/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.-/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.-=/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_eq.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_gt.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_gte.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_lt.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_lte.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.comp/op_neq.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.const/convert.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.const/convert.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.const/default.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.const/iter.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.const/iter.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.conv/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.decr/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.decr/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.incr/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.incr/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.index/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.ref/op_arrow.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.star/op_star.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op=/move_iterator.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op=/move_iterator.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iter.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/move.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/move.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.cons/default.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.cons/iter.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.cons/iter.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.cons/reverse_iterator.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.cons/reverse_iterator.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.conv/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op!=/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op++/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op++/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op+/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op+=/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op--/post.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op--/pre.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op-/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op-=/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op.star/op_star.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op=/reverse_iterator.fail.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op=/reverse_iterator.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.op==/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opdiff/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opgt/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opgt=/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opindex/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.oplt/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.oplt=/test.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opref/op_arrow.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.ops/reverse.iter.opsum/difference_type.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iter.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.cons/copy.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.cons/default.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.cons/istream.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.ops/arrow.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.ops/dereference.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.ops/equal.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.ops/post_increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/istream.iterator.ops/pre_increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istream.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator.cons/default.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator.cons/istream.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator.cons/proxy.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator.cons/streambuf.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_equal/equal.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op!=/not_equal.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op++/dereference.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op==/equal.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op_astrk/arrow.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op_astrk/post_increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_op_astrk/pre_increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/istreambuf.iterator_proxy/proxy.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/istreambuf.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/begin_array.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/begin_const.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/begin_non_const.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/end_array.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/end_const.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/iterator.range/end_non_const.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.cons.des/copy.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.cons.des/ostream.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.cons.des/ostream_delem.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.ops/assign_t.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.ops/dereference.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/ostream.iterator.ops/increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostream.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.cons/ostream.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.cons/streambuf.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.ops/assign_c.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.ops/deref.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.ops/failed.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/ostreambuf.iter.ops/increment.pass.cpp delete mode 100644 libcxx/test/iterators/stream.iterators/ostreambuf.iterator/types.pass.cpp delete mode 100644 libcxx/test/iterators/version.pass.cpp delete mode 100644 libcxx/test/language.support/cstdint/cstdint.syn/cstdint.pass.cpp delete mode 100644 libcxx/test/language.support/cstdint/version.pass.cpp delete mode 100644 libcxx/test/language.support/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/bad.alloc/bad_alloc.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/new.badlength/bad_array_new_length.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/new.handler/new_handler.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/set.new.handler/get_new_handler.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/alloc.errors/set.new.handler/set_new_handler.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.array/new_array.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.dataraces/not_testable.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.placement/new.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.placement/new_array.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/new.delete.single/new_replace.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/new.delete/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.dynamic/version.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/bad.exception/bad_exception.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/assign.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/ctor_copy.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/ctor_default.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/rethrow_nested.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/except.nested/throw_with_nested.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception.terminate/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception.terminate/set.terminate/get_terminate.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception.terminate/set.terminate/set_terminate.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception.terminate/terminate.handler/terminate_handler.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception.terminate/terminate/terminate.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/exception/exception.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/propagation/current_exception.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/propagation/exception_ptr.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/propagation/make_exception_ptr.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/propagation/rethrow_exception.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/uncaught/uncaught_exception.pass.cpp delete mode 100644 libcxx/test/language.support/support.exception/version.pass.cpp delete mode 100644 libcxx/test/language.support/support.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.initlist/support.initlist.access/access.pass.cpp delete mode 100644 libcxx/test/language.support/support.initlist/support.initlist.cons/default.pass.cpp delete mode 100644 libcxx/test/language.support/support.initlist/support.initlist.range/begin_end.pass.cpp delete mode 100644 libcxx/test/language.support/support.initlist/types.pass.cpp delete mode 100644 libcxx/test/language.support/support.initlist/version.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/c.limits/cfloat.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/c.limits/climits.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/c.limits/version_cfloat.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/c.limits/version_climits.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/denorm.style/check_values.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/is_specialized.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/denorm_min.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/digits.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/digits10.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/epsilon.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/has_denorm.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/has_denorm_loss.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/has_infinity.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/has_quiet_NaN.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/has_signaling_NaN.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/infinity.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_bounded.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_exact.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_iec559.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_integer.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_modulo.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/is_signed.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/lowest.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/max.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/max_digits10.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/max_exponent.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/max_exponent10.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/min.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/min_exponent.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/min_exponent10.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/quiet_NaN.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/radix.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/round_error.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/round_style.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/signaling_NaN.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/tinyness_before.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits.members/traps.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.limits/default.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/numeric.special/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/round.style/check_values.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/limits/version.pass.cpp delete mode 100644 libcxx/test/language.support/support.limits/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/language.support/support.rtti/bad.cast/bad_cast.pass.cpp delete mode 100644 libcxx/test/language.support/support.rtti/bad.typeid/bad_typeid.pass.cpp delete mode 100644 libcxx/test/language.support/support.rtti/type.info/type_info.pass.cpp delete mode 100644 libcxx/test/language.support/support.rtti/type.info/type_info_hash.pass.cpp delete mode 100644 libcxx/test/language.support/support.rtti/version.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/csetjmp.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/csignal.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/cstdarg.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/cstdbool.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/cstdlib.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/ctime.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_csetjmp.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_csignal.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_cstdarg.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_cstdbool.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_cstdlib.pass.cpp delete mode 100644 libcxx/test/language.support/support.runtime/version_ctime.pass.cpp delete mode 100644 libcxx/test/language.support/support.start.term/quick_exit.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/max_align_t.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/null.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/nullptr_t.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/offsetof.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/ptrdiff_t.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/size_t.pass.cpp delete mode 100644 libcxx/test/language.support/support.types/version.pass.cpp delete mode 100644 libcxx/test/lit.cfg delete mode 100644 libcxx/test/lit.site.cfg.in delete mode 100644 libcxx/test/localization/c.locales/clocale.pass.cpp delete mode 100644 libcxx/test/localization/c.locales/version.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/__scan_keyword.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate.byname/compare.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate.byname/hash.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate.byname/transform.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate.byname/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/locale.collate.members/compare.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/locale.collate.members/hash.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/locale.collate.members/transform.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/locale.collate.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/locale.collate/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.collate/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/ctype_base.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.dtor/dtor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/is_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/is_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/narrow_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/narrow_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/scan_is.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/scan_not.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/table.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/tolower_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/tolower_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/toupper_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/toupper_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/widen_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.members/widen_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.statics/classic_table.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/facet.ctype.char.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/facet.ctype.special/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt.byname/ctor_char.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt.byname/ctor_char16_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt.byname/ctor_char32_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt.byname/ctor_wchar_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/codecvt_base.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/ctor_char.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/ctor_char16_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/ctor_char32_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/ctor_wchar_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char16_t_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char32_t_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/char_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/wchar_t_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/types_char.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/types_char16_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/types_char32_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.codecvt/types_wchar_t.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/is_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/is_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/narrow_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/narrow_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/scan_is.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/scan_not.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/widen_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype.byname/widen_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/is_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/is_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/narrow_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/narrow_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/scan_is.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/scan_not.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/tolower_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/tolower_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/toupper_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/toupper_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/widen_1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.members/widen_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/locale.ctype.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.ctype/locale.ctype/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages.byname/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages/locale.messages.members/not_testable.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages/locale.messages.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages/messages_base.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/locale.messages/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.messages/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/get_long_double_en_US.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/get_long_double_fr_FR.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/get_long_double_ru_RU.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/get_long_double_zh_CN.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/get_string_en_US.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/locale.money.get.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.get/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/put_long_double_en_US.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/put_long_double_fr_FR.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/put_long_double_ru_RU.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/put_long_double_zh_CN.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.members/put_string_en_US.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/locale.money.put.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.money.put/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/curr_symbol.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/decimal_point.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/frac_digits.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/grouping.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/neg_format.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/negative_sign.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/pos_format.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/positive_sign.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct.byname/thousands_sep.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/curr_symbol.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/decimal_point.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/frac_digits.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/grouping.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/neg_format.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/negative_sign.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/pos_format.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/positive_sign.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.members/thousands_sep.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/locale.moneypunct.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/money_base.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/locale.moneypunct/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.monetary/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_bool.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_pointer.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_unsigned_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_unsigned_long_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.nm.put/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_bool.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_double.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_float.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_long_double.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_long_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_pointer.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_unsigned_int.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_unsigned_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_unsigned_long_long.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/get_unsigned_short.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.members/test_min_max.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/facet.num.get.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/locale.num.get/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.numeric/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/date_order.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/date_order_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_date.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_date_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_monthname.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_monthname_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_one.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_one_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_time.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_time_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_weekday.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_weekday_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_year.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/get_year_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get.byname/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/date_order.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_date.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_date_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_many.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_monthname.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_monthname_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_one.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_time.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_time_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_weekday.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_weekday_wide.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/get_year.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/locale.time.get.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/time_base.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.get/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put.byname/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put.byname/put1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/locale.time.put.members/iterators.h delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/locale.time.put.members/put1.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/locale.time.put.members/put2.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/locale.time.put.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/locale.time.put/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/category.time/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct.byname/decimal_point.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct.byname/grouping.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct.byname/thousands_sep.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.members/decimal_point.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.members/falsename.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.members/grouping.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.members/thousands_sep.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.members/truename.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/facet.numpunct.virtuals/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/locale.numpunct/types.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facet.numpunct/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.categories/facets.examples/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_mode.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf16_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_always_noconv.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_encoding.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_in.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_max_length.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_out.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/codecvt_utf8_utf16_unshift.pass.cpp delete mode 100644 libcxx/test/localization/locale.stdcvt/version.pass.cpp delete mode 100644 libcxx/test/localization/locale.syn/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isalnum.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isalpha.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/iscntrl.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isdigit.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isgraph.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/islower.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isprint.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/ispunct.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isspace.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isupper.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/classification/isxdigit.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/ctor.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/overflow.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/pbackfail.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/rdbuf.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/seekoff.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/state.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/test.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/underflow.dat delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/underflow.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.buffer/underflow_utf8.dat delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.character/tolower.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.character/toupper.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/converted.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/ctor_codecvt.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/ctor_codecvt_state.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/ctor_err_string.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/from_bytes.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/state.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/to_bytes.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/conversions.string/types.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/conversions/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.convenience/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.global.templates/has_facet.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale.global.templates/use_facet.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/assign.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/char_pointer.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/copy.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/default.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/locale_char_pointer_cat.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/locale_facetptr.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/locale_locale_cat.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/locale_string_cat.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.cons/string.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.members/combine.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.members/name.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.operators/compare.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.operators/eq.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.statics/classic.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.statics/global.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.types/locale.category/category.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.types/locale.facet/facet.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.types/locale.id/id.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/locale.types/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locales/locale/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/locales/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/localization.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/localization/version.pass.cpp delete mode 100644 libcxx/test/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/c.math/cmath.pass.cpp delete mode 100644 libcxx/test/numerics/c.math/ctgmath.pass.cpp delete mode 100644 libcxx/test/numerics/c.math/tgmath_h.pass.cpp delete mode 100644 libcxx/test/numerics/c.math/version_cmath.pass.cpp delete mode 100644 libcxx/test/numerics/cfenv/cfenv.syn/cfenv.pass.cpp delete mode 100644 libcxx/test/numerics/cfenv/version.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cases.h delete mode 100644 libcxx/test/numerics/complex.number/ccmplx/ccomplex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/arg.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/conj.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/imag.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/norm.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/pow.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/proj.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/cmplx.over/real.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/assignment_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/assignment_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/divide_equal_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/divide_equal_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/minus_equal_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/minus_equal_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/plus_equal_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/plus_equal_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/times_equal_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.member.ops/times_equal_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.members/construct.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.members/real_imag.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_divide_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_divide_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_equals_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_equals_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_minus_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_minus_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_not_equals_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_not_equals_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_plus_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_plus_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_times_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/complex_times_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_divide_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_equals_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_minus_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_not_equals_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_plus_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/scalar_times_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/stream_input.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/stream_output.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/unary_minus.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.ops/unary_plus.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/double_float_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/double_float_implicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/double_long_double_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/double_long_double_implicit.fail.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/float_double_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/float_double_implicit.fail.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/float_long_double_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/float_long_double_implicit.fail.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/long_double_double_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/long_double_double_implicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/long_double_float_explicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.special/long_double_float_implicit.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.synopsis/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/acos.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/acosh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/asin.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/asinh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/atan.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/atanh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/cos.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/cosh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/exp.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/log.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/log10.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/pow_complex_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/pow_complex_scalar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/pow_scalar_complex.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/sin.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/sinh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/sqrt.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/tan.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.transcendentals/tanh.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/abs.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/arg.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/conj.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/imag.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/norm.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/polar.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/proj.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex.value.ops/real.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/complex/types.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/layout.pass.cpp delete mode 100644 libcxx/test/numerics/complex.number/version.pass.cpp delete mode 100644 libcxx/test/numerics/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.gslice/gslice.access/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.gslice/gslice.cons/default.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.gslice/gslice.cons/start_size_stride.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.gslice/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.slice/cons.slice/default.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.slice/cons.slice/start_size_stride.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.slice/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/class.slice/slice.access/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/default.fail.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.assign/gslice_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.assign/valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/addition.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/and.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/divide.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/modulo.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/multiply.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/or.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/shift_left.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/shift_right.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/subtraction.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.comp.assign/xor.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/gslice.array.fill/assign_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.gslice.array/types.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/default.fail.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.assign/indirect_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.assign/valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/addition.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/and.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/divide.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/modulo.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/multiply.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/or.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/shift_left.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/shift_right.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/subtraction.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.comp.assign/xor.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/indirect.array.fill/assign_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.indirect.array/types.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/default.fail.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.assign/mask_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.assign/valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/addition.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/and.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/divide.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/modulo.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/multiply.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/or.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/shift_left.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/shift_right.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/subtraction.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.comp.assign/xor.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/mask.array.fill/assign_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.mask.array/types.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/default.fail.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.assign/slice_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.assign/valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/addition.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/and.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/divide.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/modulo.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/multiply.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/or.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/shift_left.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/shift_right.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/subtraction.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.comp.assign/xor.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/slice.arr.fill/assign_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.slice.array/types.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/types.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.access/access.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.access/const_access.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/copy_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/gslice_array_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/indirect_array_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/initializer_list_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/mask_array_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/move_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/slice_array_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.assign/value_assign.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/and_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/and_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/divide_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/divide_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/minus_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/minus_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/modulo_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/modulo_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/or_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/or_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/plus_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/plus_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/shift_left_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/shift_left_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/shift_right_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/shift_right_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/times_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/times_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/xor_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cassign/xor_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/copy.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/default.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/gslice_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/indirect_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/mask_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/move.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/pointer_size.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/size.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/slice_array.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.cons/value_size.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/apply_cref.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/apply_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/cshift.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/max.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/min.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/resize.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/shift.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/size.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/sum.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.members/swap.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/gslice_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/gslice_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/indirect_array_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/indirect_array_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/slice_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/slice_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/valarray_bool_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.sub/valarray_bool_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.unary/bit_not.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.unary/negate.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.unary/not.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/template.valarray/valarray.unary/plus.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/and_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/and_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/and_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/divide_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/divide_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/divide_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/minus_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/minus_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/minus_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/modulo_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/modulo_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/modulo_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/or_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/or_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/or_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/plus_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/plus_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/plus_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_left_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_left_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_left_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_right_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_right_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/shift_right_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/times_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/times_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/times_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/xor_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/xor_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.binary/xor_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/and_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/and_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/and_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/equal_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/equal_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/equal_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_equal_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_equal_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_equal_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/greater_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_equal_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_equal_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_equal_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/less_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/not_equal_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/not_equal_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/not_equal_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/or_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/or_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.comparison/or_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.special/swap.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/abs_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/acos_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/asin_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/atan2_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/atan2_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/atan2_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/atan_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/cos_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/cosh_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/exp_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/log10_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/log_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/pow_valarray_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/pow_valarray_value.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/pow_value_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/sin_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/sinh_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/sqrt_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/tan_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.nonmembers/valarray.transcend/tanh_valarray.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.range/begin_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.range/begin_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.range/end_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.range/end_non_const.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/valarray.syn/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numarray/version.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/accumulate/accumulate.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/accumulate/accumulate_op.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/adjacent.difference/adjacent_difference.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/adjacent.difference/adjacent_difference_op.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/inner.product/inner_product.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/inner.product/inner_product_comp.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/iterators.h delete mode 100644 libcxx/test/numerics/numeric.ops/numeric.iota/iota.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/partial.sum/partial_sum.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/partial.sum/partial_sum_op.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.ops/version.pass.cpp delete mode 100644 libcxx/test/numerics/numeric.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/numerics.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/ctor_engine_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/ctor_engine_move.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.disc/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/ctor_engine_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/ctor_engine_move.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.ibits/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/ctor_engine_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/ctor_engine_move.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.adapt/rand.adapt.shuf/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.device/ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.device/entropy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.device/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bernoulli/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/ctor_int_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.bin/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.geo/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/ctor_int_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.bern/rand.dist.bern.negbin/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.cauchy/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.chisq/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.f/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.lognormal/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.normal/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.norm/rand.dist.norm.t/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.exp/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.extreme/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.gamma/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/ctor_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.poisson/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/ctor_double_double.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.pois/rand.dist.pois.weibull/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/ctor_init.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_ctor_init.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.discrete/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/ctor_init_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_ctor_init_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.pconst/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/ctor_init_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_ctor_default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_ctor_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_ctor_init_func.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_ctor_iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/ctor_int_int.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.int/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/ctor_int_int.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/ctor_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/eval_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/get_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/max.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/min.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/param_assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/param_copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/param_ctor.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/param_eq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/param_types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/set_param.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.dis/rand.dist.uni/rand.dist.uni.real/types.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.lcong/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.mers/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/assign.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/copy.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/ctor_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/ctor_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/discard.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/eval.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/io.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/seed_result_type.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/seed_sseq.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.eng/rand.eng.sub/values.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/default_random_engine.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/knuth_b.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/minstd_rand.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/minstd_rand0.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/mt19937.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/mt19937_64.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/ranlux24.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/ranlux24_base.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/ranlux48.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.predef/ranlux48_base.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.adapt/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.dst/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.eng/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.genl/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.seedseq/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.req/rand.req.urng/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.synopsis/version.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.canonical/generate_canonical.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/assign.fail.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/copy.fail.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/default.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/generate.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/initializer_list.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/iterator.pass.cpp delete mode 100644 libcxx/test/numerics/rand/rand.util/rand.util.seedseq/types.pass.cpp delete mode 100644 libcxx/test/platform_support.h delete mode 100644 libcxx/test/re/iterators.h delete mode 100644 libcxx/test/re/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.alg/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/awk.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/basic.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/ecma.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/egrep.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/extended.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.match/grep.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test1.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test2.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test3.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test4.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test5.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.replace/test6.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/awk.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/basic.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/ecma.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/egrep.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/extended.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.alg.search/grep.pass.cpp delete mode 100644 libcxx/test/re/re.alg/re.except/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.badexp/regex_error.pass.cpp delete mode 100644 libcxx/test/re/re.const/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.const/re.err/error_type.pass.cpp delete mode 100644 libcxx/test/re/re.const/re.matchflag/match_flag_type.pass.cpp delete mode 100644 libcxx/test/re/re.const/re.synopt/syntax_option_type.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.collating.element/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.finite.state.machine/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.format.specifier/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.matched/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.primary.equivalence.class/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.regular.expression/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/defns.regex.subexpression/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.def/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.grammar/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.iter/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/re.regiter.cnstr/cnstr.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/re.regiter.cnstr/default.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/re.regiter.comp/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/re.regiter.deref/deref.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/re.regiter.incr/post.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.regiter/types.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.cnstr/array.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.cnstr/default.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.cnstr/init.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.cnstr/int.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.cnstr/vector.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.comp/equal.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.deref/deref.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/re.tokiter.incr/post.pass.cpp delete mode 100644 libcxx/test/re/re.iter/re.tokiter/types.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign.il.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign_iter_iter_flag.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign_ptr_flag.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign_ptr_size_flag.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/assign_string_flag.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/copy.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/il.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/ptr.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.assign/string.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.const/constants.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/copy.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/default.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/il_flg.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/iter_iter.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/ptr.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/ptr_flg.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/string.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.construct/string_flg.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.locale/imbue.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.nonmemb/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.nonmemb/re.regex.nmswap/swap.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.operations/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/re/re.regex/re.regex.swap/swap.pass.cpp delete mode 100644 libcxx/test/re/re.regex/types.pass.cpp delete mode 100644 libcxx/test/re/re.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/begin_end.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/cbegin_cend.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/index.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/length.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/position.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/prefix.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/str.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.acc/suffix.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.all/get_allocator.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.const/allocator.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.const/default.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.form/form1.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.form/form2.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.form/form3.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.form/form4.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.nonmember/equal.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.size/empty.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.size/max_size.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.state/ready.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.swap/member_swap.pass.cpp delete mode 100644 libcxx/test/re/re.results/re.results.swap/non_member_swap.pass.cpp delete mode 100644 libcxx/test/re/re.results/types.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/compare_string_type.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/compare_sub_match.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/compare_value_type_ptr.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/default.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/length.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/operator_string.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.members/str.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.op/compare.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/re.submatch.op/stream.pass.cpp delete mode 100644 libcxx/test/re/re.submatch/types.pass.cpp delete mode 100644 libcxx/test/re/re.syn/cmatch.pass.cpp delete mode 100644 libcxx/test/re/re.syn/cregex_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/cregex_token_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/csub_match.pass.cpp delete mode 100644 libcxx/test/re/re.syn/regex.pass.cpp delete mode 100644 libcxx/test/re/re.syn/smatch.pass.cpp delete mode 100644 libcxx/test/re/re.syn/sregex_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/sregex_token_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/ssub_match.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wcmatch.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wcregex_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wcregex_token_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wcsub_match.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wregex.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wsmatch.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wsregex_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wsregex_token_iterator.pass.cpp delete mode 100644 libcxx/test/re/re.syn/wssub_match.pass.cpp delete mode 100644 libcxx/test/re/re.traits/default.pass.cpp delete mode 100644 libcxx/test/re/re.traits/getloc.pass.cpp delete mode 100644 libcxx/test/re/re.traits/imbue.pass.cpp delete mode 100644 libcxx/test/re/re.traits/isctype.pass.cpp delete mode 100644 libcxx/test/re/re.traits/iterators.h delete mode 100644 libcxx/test/re/re.traits/length.pass.cpp delete mode 100644 libcxx/test/re/re.traits/lookup_classname.pass.cpp delete mode 100644 libcxx/test/re/re.traits/lookup_collatename.pass.cpp delete mode 100644 libcxx/test/re/re.traits/transform.pass.cpp delete mode 100644 libcxx/test/re/re.traits/transform_primary.pass.cpp delete mode 100644 libcxx/test/re/re.traits/translate.pass.cpp delete mode 100644 libcxx/test/re/re.traits/translate_nocase.pass.cpp delete mode 100644 libcxx/test/re/re.traits/types.pass.cpp delete mode 100644 libcxx/test/re/re.traits/value.pass.cpp delete mode 100644 libcxx/test/re/test_allocator.h delete mode 100644 libcxx/test/strings/basic.string.hash/strings.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/input_iterator.h delete mode 100644 libcxx/test/strings/basic.string/string.access/at.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.access/back.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.access/front.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.access/index.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/capacity.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/clear.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/empty.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/length.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/max_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/reserve.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/resize_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/resize_size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/shrink_to_fit.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.capacity/size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/char_assignment.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/copy.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/copy_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/copy_assignment.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/default_noexcept.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/dtor_noexcept.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/initializer_list_assignment.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/iter_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/move.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/move_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/move_assign_noexcept.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/move_assignment.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/move_noexcept.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/pointer_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/pointer_assignment.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/pointer_size_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/size_char_alloc.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.cons/substr.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/begin.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/cbegin.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/cend.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/crbegin.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/crend.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/end.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/rbegin.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.iterators/rend.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/iterator.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/push_back.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_append/string_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/iterator.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/rv_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_assign/string_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_copy/copy.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_erase/iter.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_erase/iter_iter.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_erase/pop_back.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_erase/size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/iter_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/iter_iter_iter.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/iter_size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/size_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/size_pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/size_size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/size_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_insert/size_string_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_op_plus_equal/char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_op_plus_equal/initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_op_plus_equal/pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_op_plus_equal/string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_initializer_list.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_iter_iter.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/iter_iter_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/size_size_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/size_size_pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/size_size_size_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/size_size_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_replace/size_size_string_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.modifiers/string_swap/swap.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/get_line.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/get_line_delim.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/get_line_delim_rv.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/get_line_rv.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/stream_extract.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.io/stream_insert.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.special/swap.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string.special/swap_noexcept.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op!=/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op!=/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op!=/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op+/char_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op+/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op+/string_char.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op+/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_op+/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_operator==/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_operator==/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_operator==/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt=/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt=/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_opgt=/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt=/pointer_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt=/string_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.nonmembers/string_oplt=/string_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string.accessors/c_str.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string.accessors/data.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string.accessors/get_allocator.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/size_size_pointer.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/size_size_pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/size_size_string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/size_size_string_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_compare/string.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.not.of/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.not.of/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.not.of/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.not.of/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.of/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.of/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.of/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.first.of/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.not.of/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.not.of/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.not.of/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.not.of/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.of/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.of/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.of/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find.last.of/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_find/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_rfind/char_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_rfind/pointer_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_rfind/pointer_size_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_rfind/string_size.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.ops/string_substr/substr.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/string.require/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/basic.string/test_allocator.h delete mode 100644 libcxx/test/strings/basic.string/test_traits.h delete mode 100644 libcxx/test/strings/basic.string/types.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/cctype.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/cstring.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/cuchar.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/cwchar.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/cwctype.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/version_cctype.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/version_cstring.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/version_cuchar.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/version_cwchar.pass.cpp delete mode 100644 libcxx/test/strings/c.strings/version_cwctype.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.require/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/assign2.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/assign3.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/compare.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/copy.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/eq.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/eq_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/find.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/length.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/lt.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/move.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/not_eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/to_char_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/to_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char/types.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/assign2.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/assign3.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/compare.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/copy.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/eq.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/eq_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/find.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/length.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/lt.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/move.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/not_eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/to_char_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/to_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char16_t/types.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/assign2.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/assign3.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/compare.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/copy.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/eq.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/eq_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/find.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/length.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/lt.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/move.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/not_eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/to_char_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/to_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.char32_t/types.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/assign2.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/assign3.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/compare.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/copy.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/eq.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/eq_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/find.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/length.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/lt.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/move.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/not_eof.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/to_char_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/to_int_type.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/char.traits.specializations.wchar.t/types.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.specializations/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/char.traits.typedefs/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/char.traits/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/string.classes/typedefs.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stod.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stof.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stoi.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stol.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stold.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stoll.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stoul.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/stoull.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/to_string.pass.cpp delete mode 100644 libcxx/test/strings/string.conversions/to_wstring.pass.cpp delete mode 100644 libcxx/test/strings/strings.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/strings/version.pass.cpp delete mode 100755 libcxx/test/testit delete mode 100644 libcxx/test/thread/futures/futures.async/async.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/default_error_condition.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/equivalent_error_code_int.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/equivalent_int_error_condition.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/future_category.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/make_error_code.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.errors/make_error_condition.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.future_error/code.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.future_error/types.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.future_error/what.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.overview/future_errc.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.overview/future_status.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.overview/is_error_code_enum_future_errc.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.overview/launch.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/alloc_ctor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/copy_assign.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/copy_ctor.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/default.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/dtor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/get_future.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/move_assign.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/move_ctor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_exception.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_exception_at_thread_exit.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_lvalue.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_lvalue_at_thread_exit.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_rvalue.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_rvalue_at_thread_exit.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_value_at_thread_exit_const.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_value_at_thread_exit_void.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_value_const.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/set_value_void.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/swap.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.promise/uses_allocator.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/copy_assign.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/copy_ctor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/ctor_future.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/default.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/dtor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/get.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/move_assign.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/move_ctor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/wait.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/wait_for.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.shared_future/wait_until.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.state/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/assign_copy.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/assign_move.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/ctor_copy.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/ctor_default.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/ctor_func.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/ctor_func_alloc.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/ctor_move.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/dtor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/get_future.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/make_ready_at_thread_exit.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/operator.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/reset.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.members/swap.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.nonmembers/swap.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/futures.task.nonmembers/uses_allocator.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.tas/types.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/copy_assign.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/copy_ctor.fail.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/default.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/dtor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/get.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/move_assign.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/move_ctor.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/share.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/wait.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/wait_for.pass.cpp delete mode 100644 libcxx/test/thread/futures/futures.unique_future/wait_until.pass.cpp delete mode 100644 libcxx/test/thread/futures/test_allocator.h delete mode 100644 libcxx/test/thread/futures/version.pass.cpp delete mode 100644 libcxx/test/thread/macro.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/cv_status.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/notify_all_at_thread_exit.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/destructor.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/native_handle.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/notify_all.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/notify_one.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait_for_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvar/wait_until_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/destructor.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/notify_all.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/notify_one.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_for_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_until_pred.pass.cpp delete mode 100644 libcxx/test/thread/thread.condition/version.pass.cpp delete mode 100644 libcxx/test/thread/thread.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock.algorithm/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock.algorithm/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/adopt_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/mutex.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/mutex.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.guard/types.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/copy_assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/copy_ctor.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/move_assign.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/move_ctor.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex_adopt_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex_defer_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex_duration.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex_time_point.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.cons/mutex_try_to_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.locking/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.locking/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.locking/try_lock_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.locking/try_lock_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.locking/unlock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.mod/member_swap.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.mod/nonmember_swap.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.mod/release.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.obs/mutex.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.obs/op_bool.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/thread.lock.unique.obs/owns_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/thread.lock.unique/types.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.lock/types.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/native_handle.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/native_handle.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/try_lock_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.class/try_lock_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/try_lock.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/try_lock_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/try_lock_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.once/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.once/thread.once.callonce/call_once.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.once/thread.once.onceflag/assign.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.once/thread.once.onceflag/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.mutex/thread.once/thread.once.onceflag/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.mutex/version.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.exception/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.lockable/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.lockable/thread.req.lockable.basic/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.lockable/thread.req.lockable.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.lockable/thread.req.lockable.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.lockable/thread.req.lockable.timed/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.native/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.paramname/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.req/thread.req.timing/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.algorithm/swap.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.assign/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.assign/move.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.constr/F.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.constr/copy.fail.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.constr/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.constr/move.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.destr/dtor.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/assign.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/copy.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/default.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/eq.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/stream.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.id/thread_id.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/detach.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/get_id.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/join.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/joinable.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/native_handle.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.member/swap.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/thread.thread.static/hardware_concurrency.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.class/types.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.this/get_id.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.this/sleep_for.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.this/sleep_until.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/thread.thread.this/yield.pass.cpp delete mode 100644 libcxx/test/thread/thread.threads/version.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.cnstr/allocs.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.cnstr/converting_copy.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.cnstr/converting_move.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.cnstr/default.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/allocate_size.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/allocate_size_hint.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/construct.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/deallocate.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/destroy.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/inner_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/max_size.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/outer_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.members/select_on_container_copy_construction.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.types/inner_allocator_type.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.types/propagate_on_container_copy_assignment.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.types/propagate_on_container_move_assignment.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocator.adaptor.types/propagate_on_container_swap.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/allocators.h delete mode 100644 libcxx/test/utilities/allocator.adaptor/scoped.adaptor.operators/eq.pass.cpp delete mode 100644 libcxx/test/utilities/allocator.adaptor/types.pass.cpp delete mode 100644 libcxx/test/utilities/date.time/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/divides.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/minus.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/modulus.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/multiplies.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/negate.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/arithmetic.operations/plus.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.bind/invoke_int_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.bind/invoke_lvalue.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.bind/invoke_rvalue.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.bind/invoke_void_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.isbind/is_bind_expression.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.isbind/is_placeholder.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/func.bind.place/placeholders.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/func.bind/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bind/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bitwise.operations/bit_and.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bitwise.operations/bit_or.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/bitwise.operations/bit_xor.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/equal_to.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/greater.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/greater_equal.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/less.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/less_equal.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/comparisons/not_equal_to.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.def/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_data.fail.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_data.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_function.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_function_const.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_function_const_volatile.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.memfn/member_function_volatile.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.require/binary_function.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.require/unary_function.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.badcall/bad_function_call.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.badcall/func.wrap.badcall.const/bad_function_call_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.alg/swap.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.cap/operator_bool.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/F.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/F_assign.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_F.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_function.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_rfunction.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_assign.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/default.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/nullptr_t.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/nullptr_t_assign.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke.fail.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke_int_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke_void_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.mod/assign_F_alloc.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.mod/swap.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.nullptr/operator_==.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.targ/target.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.targ/target_type.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/test_allocator.h delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/func.wrap.func/types.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/func.wrap/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/logical.operations/logical_and.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/logical.operations/logical_not.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/logical.operations/logical_or.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/negators/binary_negate.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/negators/not1.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/negators/not2.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/negators/unary_negate.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/binary.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.access/conversion.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.assign/copy_assign.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.const/copy_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.const/type_ctor.fail.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.const/type_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.helpers/cref_1.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.helpers/cref_2.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.helpers/ref_1.fail.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.helpers/ref_1.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.helpers/ref_2.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.invoke/invoke.fail.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.invoke/invoke.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.invoke/invoke_int_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/refwrap.invoke/invoke_void_0.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/type.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/unary.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/refwrap/weak_result.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/unord.hash/floating.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/unord.hash/integral.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/unord.hash/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/function.objects/version.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.tag/allocator_arg.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/allocate.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/allocate_hint.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/construct.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/deallocate.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/destroy.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/max_size.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.members/select_on_container_copy_construction.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/const_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/const_void_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/difference_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/propagate_on_container_copy_assignment.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/propagate_on_container_move_assignment.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/propagate_on_container_swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/rebind_alloc.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/size_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator.traits.types/void_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/allocator_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/rebind_traits.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.traits/value_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.uses/allocator.uses.construction/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.uses/allocator.uses.trait/uses_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/memory/allocator.uses/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/c.malloc/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator.globals/eq.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator.members/address.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator.members/allocate.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator.members/construct.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator.members/max_size.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator_types.pass.cpp delete mode 100644 libcxx/test/utilities/memory/default.allocator/allocator_void.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/difference_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/element_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer.traits.functions/pointer_to.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer.traits.types/difference_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer.traits.types/element_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer.traits.types/rebind.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/pointer_to.pass.cpp delete mode 100644 libcxx/test/utilities/memory/pointer.traits/rebind.pass.cpp delete mode 100644 libcxx/test/utilities/memory/ptr.align/align.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/specialized.addressof/addressof.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/uninitialized.copy/uninitialized_copy.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/uninitialized.copy/uninitialized_copy_n.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/uninitialized.fill.n/uninitialized_fill_n.pass.cpp delete mode 100644 libcxx/test/utilities/memory/specialized.algorithms/uninitialized.fill/uninitialized_fill.pass.cpp delete mode 100644 libcxx/test/utilities/memory/storage.iterator/raw_storag_iterator.pass.cpp delete mode 100644 libcxx/test/utilities/memory/temporary.buffer/temporary_buffer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/deleter.h delete mode 100644 libcxx/test/utilities/memory/unique.ptr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt/convert_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt/default.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt/incomplete.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt1/convert_ctor.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt1/default.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.dflt1/incomplete.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.dltr/unique.ptr.dltr.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert05.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert06.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert07.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert08.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/move_convert09.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/null_asgn.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/null_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/nullptr_asgn.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/pointer_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/default01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/default01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/default02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/default02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/default03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert05.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert06.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert07.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert08.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert09.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert10.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert11.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert12.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert13.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert14.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert15.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert16.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert17.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/move_convert18.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter03.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter04.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/pointer_deleter05.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.modifiers/release.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.modifiers/reset1.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.modifiers/reset2.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.modifiers/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/dereference.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/explicit_bool.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/get.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/get_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/index.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.observers/op_arrow.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/pointer_type.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert03.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert05.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert06.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/move_convert13.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/null.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/auto_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/auto_pointer01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/auto_pointer02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/default01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/default01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/default02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/default02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/default03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert03.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert04.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert05.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert05.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert06.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert06.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert07.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert07.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert08.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert09.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert10.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert11.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert12.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/move_convert13.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer01.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer02.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer03.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer03.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter01.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter02.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter03.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter04.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter04.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter05.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.ctor/pointer_deleter06.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.dtor/null.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/release.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/reset1.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/reset2.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/reset_self.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/dereference.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/explicit_bool.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/get.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/get_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/index.fail.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.observers/op_arrow.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.special/cmp_nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.special/eq.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.special/rel.pass.cpp delete mode 100644 libcxx/test/utilities/memory/unique.ptr/unique.ptr.special/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.dynamic.safety/declare_no_pointers.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.dynamic.safety/declare_reachable.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.dynamic.safety/get_pointer_safety.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.enab/enable_shared_from_this.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.hash/hash_shared_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.hash/hash_unique_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/test_allocator.h delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/test_deleter.h delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/types.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.getdeleter/get_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/auto_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_Y_rv.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_rv.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/unique_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cast/const_pointer_cast.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cast/dynamic_pointer_cast.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cast/static_pointer_cast.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cmp/cmp_nullptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cmp/eq.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cmp/lt.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/auto_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/default.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/nullptr_t.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/nullptr_t_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/nullptr_t_deleter_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/nullptr_t_deleter_allocator_throw.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/nullptr_t_deleter_throw.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer_deleter_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer_deleter_allocator_throw.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer_deleter_throw.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/pointer_throw.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/shared_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/shared_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/shared_ptr_Y_rv.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/shared_ptr_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/shared_ptr_rv.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/unique_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/make_shared.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.dest/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.io/io.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/reset.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/reset_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/reset_pointer_deleter.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/reset_pointer_deleter_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/arrow.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/dereference.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/op_bool.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/owner_before_shared_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/owner_before_weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.obs/unique.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.spec/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/types.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.ownerless/owner_less.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.assign/shared_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.assign/weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.assign/weak_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/default.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/shared_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/weak_ptr_Y.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.dest/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.mod/reset.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.mod/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.obs/expired.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.obs/lock.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.obs/not_less_than.fail.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.obs/owner_before_shared_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.obs/owner_before_weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.spec/swap.pass.cpp delete mode 100644 libcxx/test/utilities/memory/util.smartptr/util.smartptr.weakptr/bad_weak_ptr.pass.cpp delete mode 100644 libcxx/test/utilities/memory/version.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.hel/integral_constant.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.rel/is_base_of.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.rel/is_convertible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.rel/is_same.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.rqmts/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.arr/remove_all_extents.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.arr/remove_extent.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/add_const.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/add_cv.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/add_volatile.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/remove_const.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/remove_cv.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.cv/remove_volatile.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/aligned_storage.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/common_type.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/conditional.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/decay.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/enable_if.fail.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/enable_if.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/result_of.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.other/underlying_type.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.ptr/add_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.ptr/remove_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.ref/add_lvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.ref/add_rvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.ref/remove_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.sign/make_signed.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/meta.trans.sign/make_unsigned.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.trans/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.type.synop/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary.prop.query/alignment_of.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary.prop.query/extent.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary.prop.query/rank.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/array.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/class.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/enum.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/floating_point.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/function.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/integral.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/lvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/member_function_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/member_object_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/rvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/union.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.cat/void.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/array.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/class.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/enum.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/floating_point.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/function.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/integral.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/lvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/member_function_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/member_object_pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/pointer.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/rvalue_ref.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/union.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.comp/void.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/has_virtual_destructor.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_abstract.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_const.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_copy_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_copy_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_default_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_destructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_empty.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_literal_type.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_move_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_move_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_copy_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_copy_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_default_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_destructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_move_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_move_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_pod.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_polymorphic.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_signed.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_standard_layout.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivial.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivialially_copyable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_copy_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_copy_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_default_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_destructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_move_assignable.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_trivially_move_constructible.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_unsigned.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/meta.unary.prop/is_volatile.pass.cpp delete mode 100644 libcxx/test/utilities/meta/meta.unary/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/meta/version.pass.cpp delete mode 100644 libcxx/test/utilities/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_add.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_add.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_divide.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_divide.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_multiply.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_multiply.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_subtract.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.arithmetic/ratio_subtract.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_equal.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_greater.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_greater_equal.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_less.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_less_equal.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.comparison/ratio_not_equal.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.ratio/ratio.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.ratio/ratio1.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.ratio/ratio2.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.ratio/ratio3.fail.cpp delete mode 100644 libcxx/test/utilities/ratio/ratio.si/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/typedefs.pass.cpp delete mode 100644 libcxx/test/utilities/ratio/version.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.cons/char_ptr_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.cons/default.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.cons/string_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.cons/ull_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.hash/bitset.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/all.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/any.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/count.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/flip_all.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/flip_one.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/index.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/index_const.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/left_shift.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/left_shift_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/none.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/not_all.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/op_and_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/op_eq_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/op_or_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/op_xor_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/reset_all.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/reset_one.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/right_shift.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/right_shift_eq.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/set_all.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/set_one.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/size.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/test.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/to_string.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/to_ullong.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.members/to_ulong.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.operators/op_and.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.operators/op_not.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.operators/op_or.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.operators/stream_in.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/bitset.operators/stream_out.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/includes.pass.cpp delete mode 100644 libcxx/test/utilities/template.bitset/version.pass.cpp delete mode 100644 libcxx/test/utilities/time/clock.h delete mode 100644 libcxx/test/utilities/time/hours.pass.cpp delete mode 100644 libcxx/test/utilities/time/microseconds.pass.cpp delete mode 100644 libcxx/test/utilities/time/milliseconds.pass.cpp delete mode 100644 libcxx/test/utilities/time/minutes.pass.cpp delete mode 100644 libcxx/test/utilities/time/nanoseconds.pass.cpp delete mode 100644 libcxx/test/utilities/time/rep.h delete mode 100644 libcxx/test/utilities/time/seconds.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock.req/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.hires/consistency.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.hires/now.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.steady/consistency.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.steady/now.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.system/consistency.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.system/from_time_t.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.system/now.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.system/rep_signed.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.clock/time.clock.system/to_time_t.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/default_ratio.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/duration.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/positive_num.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/ratio.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_++.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_++int.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_+.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_+=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_--.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_--int.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_-.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_-=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_divide=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_mod=duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_mod=rep.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.arithmetic/op_times=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cast/duration_cast.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cast/toduration.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.comparisons/op_equal.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.comparisons/op_less.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/convert_exact.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/convert_float_to_int.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/convert_inexact.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/convert_inexact.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/convert_int_to_float.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/default.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/rep.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/rep01.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/rep02.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/rep02.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.cons/rep03.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_+.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_-.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_divide_duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_divide_rep.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_divide_rep.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_mod_duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_mod_rep.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_mod_rep.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_times_rep.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_times_rep1.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.nonmember/op_times_rep2.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.observer/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.special/max.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.special/min.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/time.duration.special/zero.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.duration/types.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/default_duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/duration.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.arithmetic/op_+=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.arithmetic/op_-=.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cast/time_point_cast.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cast/toduration.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.comparisons/op_equal.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.comparisons/op_equal.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.comparisons/op_less.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.comparisons/op_less.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cons/convert.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cons/convert.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cons/default.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cons/duration.fail.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.cons/duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.nonmember/op_+.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.nonmember/op_-duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.nonmember/op_-time_point.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.observer/tested_elsewhere.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.special/max.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.point/time.point.special/min.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.duration_values/max.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.duration_values/min.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.duration_values/zero.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.is_fp/treat_as_floating_point.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.specializations/duration.pass.cpp delete mode 100644 libcxx/test/utilities/time/time.traits/time.traits.specializations/time_point.pass.cpp delete mode 100644 libcxx/test/utilities/time/version.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/DefaultOnly.h delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/MoveOnly.h delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/alloc_first.h delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/alloc_last.h delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/allocators.h delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/empty_member.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/const_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/convert_copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/convert_move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/copy.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.assign/move_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/UTypes.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/UTypes.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_UTypes.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_const_Types.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_const_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_convert_copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_convert_move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/alloc_move_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/const_Types.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/const_Types.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/const_Types2.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/const_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/convert_copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/convert_move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/copy.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/copy.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/default.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/move.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.cnstr/move_pair.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.creation/forward_as_tuple.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.creation/make_tuple.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.creation/tie.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.creation/tuple_cat.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.elem/get_const.fail.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.elem/get_const.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.elem/get_non_const.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.elem/get_rv.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.helper/tuple_element.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.helper/tuple_size.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.rel/eq.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.rel/lt.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.special/non_member_swap.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.swap/member_swap.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/tuple.tuple/tuple.traits/uses_allocator.pass.cpp delete mode 100644 libcxx/test/utilities/tuple/version.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.hash/hash.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.members/ctor.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.members/eq.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.members/hash_code.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.members/lt.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.members/name.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.overview/copy_assign.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.overview/copy_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/type.index.synopsis/hash_type_index.pass.cpp delete mode 100644 libcxx/test/utilities/type.index/version.pass.cpp delete mode 100644 libcxx/test/utilities/utilities.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/allocator.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/hash.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/nullablepointer.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/swappable.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility.requirements/utility.arg.requirements/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility/declval/declval.pass.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward.pass.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward1.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward2.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward3.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward4.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward5.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/forward6.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_copy.pass.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_if_noexcept.pass.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_only.pass.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_only1.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_only2.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_only3.fail.cpp delete mode 100644 libcxx/test/utilities/utility/forward/move_only4.fail.cpp delete mode 100644 libcxx/test/utilities/utility/operators/rel_ops.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/get_const.fail.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/get_const.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/get_non_const.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/get_rv.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/tuple_element.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.astuple/tuple_size.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pair.piecewise/piecewise_construct.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.general/nothing_to_do.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/U_V.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/assign_const_pair_U_V.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/assign_rv_pair.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/assign_rv_pair_U_V.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/const_first_const_second.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/const_pair_U_V.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/copy_ctor.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/default.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/piecewise.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/rv_pair_U_V.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/swap.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.pair/types.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.spec/comparison.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.spec/make_pair.pass.cpp delete mode 100644 libcxx/test/utilities/utility/pairs/pairs.spec/non_member_swap.pass.cpp delete mode 100644 libcxx/test/utilities/utility/utility.swap/swap.pass.cpp delete mode 100644 libcxx/test/utilities/utility/utility.swap/swap_array.pass.cpp delete mode 100644 libcxx/test/utilities/utility/version.pass.cpp delete mode 100644 libcxx/www/atomic_design.html delete mode 100644 libcxx/www/atomic_design_a.html delete mode 100644 libcxx/www/atomic_design_b.html delete mode 100644 libcxx/www/atomic_design_c.html delete mode 100644 libcxx/www/content.css delete mode 100644 libcxx/www/index.html delete mode 100644 libcxx/www/libcxx_by_chapter.pdf delete mode 100644 libcxx/www/menu.css delete mode 100644 libcxx/www/results.Windows.html delete mode 100644 libcxx/www/type_traits_design.html delete mode 100644 libcxxabi/CREDITS.TXT delete mode 100644 libcxxabi/LICENSE.TXT delete mode 100644 libcxxabi/include/cxa_demangle.h delete mode 100644 libcxxabi/include/cxxabi.h delete mode 100755 libcxxabi/lib/buildit delete mode 100644 libcxxabi/src/abort_message.cpp delete mode 100644 libcxxabi/src/abort_message.h delete mode 100644 libcxxabi/src/cxa_aux_runtime.cpp delete mode 100644 libcxxabi/src/cxa_default_handlers.cpp delete mode 100644 libcxxabi/src/cxa_demangle.cpp delete mode 100644 libcxxabi/src/cxa_exception.cpp delete mode 100644 libcxxabi/src/cxa_exception.hpp delete mode 100644 libcxxabi/src/cxa_exception_storage.cpp delete mode 100644 libcxxabi/src/cxa_guard.cpp delete mode 100644 libcxxabi/src/cxa_handlers.cpp delete mode 100644 libcxxabi/src/cxa_handlers.hpp delete mode 100644 libcxxabi/src/cxa_new_delete.cpp delete mode 100644 libcxxabi/src/cxa_personality.cpp delete mode 100644 libcxxabi/src/cxa_unexpected.cpp delete mode 100644 libcxxabi/src/cxa_vector.cpp delete mode 100644 libcxxabi/src/cxa_virtual.cpp delete mode 100644 libcxxabi/src/exception.cpp delete mode 100644 libcxxabi/src/fallback_malloc.ipp delete mode 100644 libcxxabi/src/private_typeinfo.cpp delete mode 100644 libcxxabi/src/private_typeinfo.h delete mode 100644 libcxxabi/src/stdexcept.cpp delete mode 100644 libcxxabi/src/typeinfo.cpp delete mode 100644 libcxxabi/test/catch_array_01.cpp delete mode 100644 libcxxabi/test/catch_array_02.cpp delete mode 100644 libcxxabi/test/catch_class_01.cpp delete mode 100644 libcxxabi/test/catch_class_02.cpp delete mode 100644 libcxxabi/test/catch_class_03.cpp delete mode 100644 libcxxabi/test/catch_class_04.cpp delete mode 100644 libcxxabi/test/catch_const_pointer_nullptr.cpp delete mode 100644 libcxxabi/test/catch_function_01.cpp delete mode 100644 libcxxabi/test/catch_function_02.cpp delete mode 100644 libcxxabi/test/catch_member_data_pointer_01.cpp delete mode 100644 libcxxabi/test/catch_member_function_pointer_01.cpp delete mode 100644 libcxxabi/test/catch_member_pointer_nullptr.cpp delete mode 100644 libcxxabi/test/catch_pointer_nullptr.cpp delete mode 100644 libcxxabi/test/catch_ptr.cpp delete mode 100644 libcxxabi/test/catch_ptr_02.cpp delete mode 100644 libcxxabi/test/dynamic_cast14.cpp delete mode 100644 libcxxabi/test/dynamic_cast3.cpp delete mode 100644 libcxxabi/test/dynamic_cast5.cpp delete mode 100644 libcxxabi/test/dynamic_cast_stress.cpp delete mode 100644 libcxxabi/test/test_aux_runtime.cpp delete mode 100644 libcxxabi/test/test_demangle.cpp delete mode 100644 libcxxabi/test/test_exception_storage.cpp delete mode 100644 libcxxabi/test/test_fallback_malloc.cpp delete mode 100644 libcxxabi/test/test_guard.cpp delete mode 100644 libcxxabi/test/test_vector1.cpp delete mode 100644 libcxxabi/test/test_vector2.cpp delete mode 100644 libcxxabi/test/test_vector3.cpp delete mode 100755 libcxxabi/test/testit delete mode 100644 libcxxabi/test/unwind_01.cpp delete mode 100644 libcxxabi/test/unwind_02.cpp delete mode 100644 libcxxabi/test/unwind_03.cpp delete mode 100644 libcxxabi/test/unwind_04.cpp delete mode 100644 libcxxabi/test/unwind_05.cpp delete mode 100644 libcxxabi/www/content.css delete mode 100644 libcxxabi/www/index.html delete mode 100644 libcxxabi/www/menu.css delete mode 100644 libcxxabi/www/spec.html delete mode 100644 lld/.gitignore delete mode 100644 lld/CMakeLists.txt delete mode 100644 lld/LICENSE.TXT delete mode 100644 lld/README.md delete mode 100644 lld/docs/Makefile delete mode 100644 lld/docs/README.txt delete mode 100644 lld/docs/_static/favicon.ico delete mode 100644 lld/docs/_templates/indexsidebar.html delete mode 100644 lld/docs/_templates/layout.html delete mode 100644 lld/docs/conf.py delete mode 100644 lld/docs/design.rst delete mode 100644 lld/docs/development.rst delete mode 100644 lld/docs/hello.png delete mode 100644 lld/docs/index.rst delete mode 100644 lld/docs/llvm-theme/layout.html delete mode 100644 lld/docs/llvm-theme/static/contents.png delete mode 100644 lld/docs/llvm-theme/static/llvm.css delete mode 100644 lld/docs/llvm-theme/static/logo.png delete mode 100644 lld/docs/llvm-theme/static/navigation.png delete mode 100644 lld/docs/llvm-theme/theme.conf delete mode 100644 lld/docs/make.bat delete mode 100644 lld/docs/open_projects.rst delete mode 100644 lld/docs/sphinx_intro.rst delete mode 100644 lld/include/lld/Core/AbsoluteAtom.h delete mode 100644 lld/include/lld/Core/AliasAtom.h delete mode 100644 lld/include/lld/Core/Atom.h delete mode 100644 lld/include/lld/Core/DefinedAtom.h delete mode 100644 lld/include/lld/Core/Error.h delete mode 100644 lld/include/lld/Core/File.h delete mode 100644 lld/include/lld/Core/InputFiles.h delete mode 100644 lld/include/lld/Core/LLVM.h delete mode 100644 lld/include/lld/Core/NativeReader.h delete mode 100644 lld/include/lld/Core/NativeWriter.h delete mode 100644 lld/include/lld/Core/Pass.h delete mode 100644 lld/include/lld/Core/Platform.h delete mode 100644 lld/include/lld/Core/Reference.h delete mode 100644 lld/include/lld/Core/Resolver.h delete mode 100644 lld/include/lld/Core/SharedLibraryAtom.h delete mode 100644 lld/include/lld/Core/SymbolTable.h delete mode 100644 lld/include/lld/Core/TODO.txt delete mode 100644 lld/include/lld/Core/UndefinedAtom.h delete mode 100644 lld/include/lld/Core/YamlReader.h delete mode 100644 lld/include/lld/Core/YamlWriter.h delete mode 100644 lld/lib/CMakeLists.txt delete mode 100644 lld/lib/Core/CMakeLists.txt delete mode 100644 lld/lib/Core/Error.cpp delete mode 100644 lld/lib/Core/File.cpp delete mode 100644 lld/lib/Core/NativeFileFormat.h delete mode 100644 lld/lib/Core/NativeReader.cpp delete mode 100644 lld/lib/Core/NativeWriter.cpp delete mode 100644 lld/lib/Core/Platform.cpp delete mode 100644 lld/lib/Core/Resolver.cpp delete mode 100644 lld/lib/Core/SymbolTable.cpp delete mode 100644 lld/lib/Core/TODO.txt delete mode 100644 lld/lib/Core/YamlKeyValues.cpp delete mode 100644 lld/lib/Core/YamlKeyValues.h delete mode 100644 lld/lib/Core/YamlReader.cpp delete mode 100644 lld/lib/Core/YamlWriter.cpp delete mode 100644 lld/lib/Passes/CMakeLists.txt delete mode 100644 lld/lib/Passes/GOTPass.cpp delete mode 100644 lld/lib/Passes/StubsPass.cpp delete mode 100644 lld/lib/Platforms/CMakeLists.txt delete mode 100644 lld/lib/Platforms/Darwin/CMakeLists.txt delete mode 100644 lld/lib/Platforms/Darwin/DarwinPlatform.cpp delete mode 100644 lld/lib/Platforms/Darwin/DarwinPlatform.h delete mode 100644 lld/lib/Platforms/Darwin/DarwinReferenceKinds.cpp delete mode 100644 lld/lib/Platforms/Darwin/DarwinReferenceKinds.h delete mode 100644 lld/lib/Platforms/Darwin/ExecutableWriter.cpp delete mode 100644 lld/lib/Platforms/Darwin/ExecutableWriter.h delete mode 100644 lld/lib/Platforms/Darwin/MachOFormat.hpp delete mode 100644 lld/lib/Platforms/Darwin/StubAtoms.hpp delete mode 100644 lld/test/CMakeLists.txt delete mode 100644 lld/test/absolute-basic.objtxt delete mode 100644 lld/test/auto-hide-coalesce.objtxt delete mode 100644 lld/test/cstring-coalesce.objtxt delete mode 100644 lld/test/custom-section.objtxt delete mode 100644 lld/test/darwin/hello-world.objtxt delete mode 100644 lld/test/dead-strip-attributes.objtxt delete mode 100644 lld/test/empty.objtxt delete mode 100644 lld/test/fixups-addend.objtxt delete mode 100644 lld/test/fixups-dup-named.objtxt delete mode 100644 lld/test/fixups-named.objtxt delete mode 100644 lld/test/fixups-unnamed.objtxt delete mode 100644 lld/test/inline-coalesce.objtxt delete mode 100644 lld/test/lit.cfg delete mode 100644 lld/test/lit.site.cfg.in delete mode 100644 lld/test/multiple-def-error.objtxt delete mode 100644 lld/test/pass-got-basic.objtxt delete mode 100644 lld/test/pass-stubs-basic.objtxt delete mode 100644 lld/test/shared-library-basic.objtxt delete mode 100644 lld/test/shared-library-coalesce.objtxt delete mode 100644 lld/test/tent-merge.objtxt delete mode 100644 lld/test/undef-coalesce.objtxt delete mode 100644 lld/test/undef-weak-coalesce.objtxt delete mode 100644 lld/test/weak-coalesce.objtxt delete mode 100644 lld/tools/CMakeLists.txt delete mode 100644 lld/tools/lld-core/CMakeLists.txt delete mode 100644 lld/tools/lld-core/lld-core.cpp delete mode 100644 lld/tools/lld/CMakeLists.txt delete mode 100644 lld/tools/lld/TODO.txt delete mode 100644 lld/tools/lld/lld.cpp delete mode 100644 lld/utils/astyle-options delete mode 100644 lldb/.gitignore delete mode 100644 lldb/INSTALL.txt delete mode 100644 lldb/LICENSE.TXT delete mode 100644 lldb/Makefile delete mode 100644 lldb/docs/building-with-debug-llvm.txt delete mode 100644 lldb/docs/code-signing.txt delete mode 100644 lldb/docs/lldb-for-gdb-users.txt delete mode 100644 lldb/docs/lldb-gdb-remote.txt delete mode 100644 lldb/docs/testsuite/2010-10-19-14_10_49.059609/TestSettings.SettingsCommandTestCase.test_set_output_path.log delete mode 100644 lldb/docs/testsuite/a-detailed-walkthrough.txt delete mode 100644 lldb/docs/testsuite/best-practices.txt delete mode 100644 lldb/docs/try.me delete mode 100644 lldb/examples/customization/bin-utils/.lldbinit delete mode 100644 lldb/examples/customization/bin-utils/README delete mode 100644 lldb/examples/customization/bin-utils/binutils.py delete mode 100644 lldb/examples/customization/import-python/README delete mode 100644 lldb/examples/customization/import-python/importcmd.py delete mode 100644 lldb/examples/customization/pwd-cd-and-system/.lldbinit delete mode 100644 lldb/examples/customization/pwd-cd-and-system/README delete mode 100644 lldb/examples/customization/pwd-cd-and-system/utils.py delete mode 100644 lldb/examples/darwin/heap_find/Makefile delete mode 100644 lldb/examples/darwin/heap_find/heap.py delete mode 100644 lldb/examples/darwin/heap_find/heap_find.cpp delete mode 100644 lldb/examples/interposing/darwin/fd_interposing/FDInterposing.cpp delete mode 100644 lldb/examples/interposing/darwin/fd_interposing/Makefile delete mode 100644 lldb/examples/lookup/Makefile delete mode 100644 lldb/examples/lookup/main.cpp delete mode 100644 lldb/examples/python/cmdtemplate.py delete mode 100755 lldb/examples/python/crashlog.py delete mode 100755 lldb/examples/python/delta.py delete mode 100755 lldb/examples/python/disasm-stress-test.py delete mode 100755 lldb/examples/python/disasm.py delete mode 100755 lldb/examples/python/gdbremote.py delete mode 100755 lldb/examples/python/sbvalue.py delete mode 100755 lldb/examples/python/symbolication.py delete mode 100644 lldb/examples/scripting/dictionary.c delete mode 100755 lldb/examples/scripting/tree_utils.py delete mode 100644 lldb/examples/summaries/cocoa/CFArray.py delete mode 100644 lldb/examples/summaries/cocoa/CFBag.py delete mode 100644 lldb/examples/summaries/cocoa/CFBinaryHeap.py delete mode 100644 lldb/examples/summaries/cocoa/CFBitVector.py delete mode 100644 lldb/examples/summaries/cocoa/CFDictionary.py delete mode 100644 lldb/examples/summaries/cocoa/CFString.py delete mode 100644 lldb/examples/summaries/cocoa/Class.py delete mode 100644 lldb/examples/summaries/cocoa/Logger.py delete mode 100644 lldb/examples/summaries/cocoa/NSBundle.py delete mode 100644 lldb/examples/summaries/cocoa/NSData.py delete mode 100644 lldb/examples/summaries/cocoa/NSDate.py delete mode 100644 lldb/examples/summaries/cocoa/NSException.py delete mode 100644 lldb/examples/summaries/cocoa/NSIndexSet.py delete mode 100644 lldb/examples/summaries/cocoa/NSMachPort.py delete mode 100644 lldb/examples/summaries/cocoa/NSNotification.py delete mode 100644 lldb/examples/summaries/cocoa/NSNumber.py delete mode 100644 lldb/examples/summaries/cocoa/NSSet.py delete mode 100644 lldb/examples/summaries/cocoa/NSURL.py delete mode 100644 lldb/examples/summaries/cocoa/Selector.py delete mode 100644 lldb/examples/summaries/cocoa/attrib_fromdict.py delete mode 100644 lldb/examples/summaries/cocoa/cache.py delete mode 100644 lldb/examples/summaries/cocoa/metrics.py delete mode 100644 lldb/examples/summaries/cocoa/objc_lldb.py delete mode 100644 lldb/examples/summaries/cocoa/objc_runtime.py delete mode 100644 lldb/examples/summaries/essentials delete mode 100644 lldb/examples/summaries/lldb delete mode 100644 lldb/examples/summaries/objc.py delete mode 100644 lldb/examples/synthetic/bitfield/example.py delete mode 100644 lldb/examples/synthetic/bitfield/program.cpp delete mode 100644 lldb/examples/synthetic/gnu_libstdcpp.py delete mode 100644 lldb/examples/synthetic/libcxx.py delete mode 100644 lldb/examples/test/.lldb-pre-post-flight delete mode 100644 lldb/examples/test/.lldb-pre-post-flight.bad delete mode 100644 lldb/examples/test/.lldbtest-config delete mode 100644 lldb/examples/test/.lldbtest-config2 delete mode 100644 lldb/examples/test/lldbtest-stderr delete mode 100644 lldb/examples/test/lldbtest-stdout delete mode 100644 lldb/examples/test/usage-config delete mode 100644 lldb/examples/test/usage-pre-post-flight delete mode 100644 lldb/include/Makefile delete mode 100644 lldb/include/lldb/API/LLDB.h delete mode 100644 lldb/include/lldb/API/SBAddress.h delete mode 100644 lldb/include/lldb/API/SBBlock.h delete mode 100644 lldb/include/lldb/API/SBBreakpoint.h delete mode 100644 lldb/include/lldb/API/SBBreakpointLocation.h delete mode 100644 lldb/include/lldb/API/SBBroadcaster.h delete mode 100644 lldb/include/lldb/API/SBCommandInterpreter.h delete mode 100644 lldb/include/lldb/API/SBCommandReturnObject.h delete mode 100644 lldb/include/lldb/API/SBCommunication.h delete mode 100644 lldb/include/lldb/API/SBCompileUnit.h delete mode 100644 lldb/include/lldb/API/SBData.h delete mode 100644 lldb/include/lldb/API/SBDebugger.h delete mode 100644 lldb/include/lldb/API/SBDefines.h delete mode 100644 lldb/include/lldb/API/SBError.h delete mode 100644 lldb/include/lldb/API/SBEvent.h delete mode 100644 lldb/include/lldb/API/SBFileSpec.h delete mode 100644 lldb/include/lldb/API/SBFileSpecList.h delete mode 100644 lldb/include/lldb/API/SBFrame.h delete mode 100644 lldb/include/lldb/API/SBFunction.h delete mode 100644 lldb/include/lldb/API/SBHostOS.h delete mode 100644 lldb/include/lldb/API/SBInputReader.h delete mode 100644 lldb/include/lldb/API/SBInstruction.h delete mode 100644 lldb/include/lldb/API/SBInstructionList.h delete mode 100644 lldb/include/lldb/API/SBLineEntry.h delete mode 100644 lldb/include/lldb/API/SBListener.h delete mode 100644 lldb/include/lldb/API/SBModule.h delete mode 100644 lldb/include/lldb/API/SBProcess.h delete mode 100644 lldb/include/lldb/API/SBSection.h delete mode 100644 lldb/include/lldb/API/SBSourceManager.h delete mode 100644 lldb/include/lldb/API/SBStream.h delete mode 100644 lldb/include/lldb/API/SBStringList.h delete mode 100644 lldb/include/lldb/API/SBSymbol.h delete mode 100644 lldb/include/lldb/API/SBSymbolContext.h delete mode 100644 lldb/include/lldb/API/SBSymbolContextList.h delete mode 100644 lldb/include/lldb/API/SBTarget.h delete mode 100644 lldb/include/lldb/API/SBThread.h delete mode 100644 lldb/include/lldb/API/SBType.h delete mode 100644 lldb/include/lldb/API/SBTypeCategory.h delete mode 100644 lldb/include/lldb/API/SBTypeFilter.h delete mode 100644 lldb/include/lldb/API/SBTypeFormat.h delete mode 100644 lldb/include/lldb/API/SBTypeNameSpecifier.h delete mode 100644 lldb/include/lldb/API/SBTypeSummary.h delete mode 100644 lldb/include/lldb/API/SBTypeSynthetic.h delete mode 100644 lldb/include/lldb/API/SBValue.h delete mode 100644 lldb/include/lldb/API/SBValueList.h delete mode 100644 lldb/include/lldb/API/SBWatchpoint.h delete mode 100644 lldb/include/lldb/Breakpoint/Breakpoint.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointID.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointIDList.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointList.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointLocation.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointLocationCollection.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointLocationList.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointOptions.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointResolver.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointResolverAddress.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointResolverFileLine.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointResolverFileRegex.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointResolverName.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointSite.h delete mode 100644 lldb/include/lldb/Breakpoint/BreakpointSiteList.h delete mode 100644 lldb/include/lldb/Breakpoint/Stoppoint.h delete mode 100644 lldb/include/lldb/Breakpoint/StoppointCallbackContext.h delete mode 100644 lldb/include/lldb/Breakpoint/StoppointLocation.h delete mode 100644 lldb/include/lldb/Breakpoint/Watchpoint.h delete mode 100644 lldb/include/lldb/Breakpoint/WatchpointList.h delete mode 100644 lldb/include/lldb/Core/Address.h delete mode 100644 lldb/include/lldb/Core/AddressRange.h delete mode 100644 lldb/include/lldb/Core/AddressResolver.h delete mode 100644 lldb/include/lldb/Core/AddressResolverFileLine.h delete mode 100644 lldb/include/lldb/Core/AddressResolverName.h delete mode 100644 lldb/include/lldb/Core/ArchSpec.h delete mode 100644 lldb/include/lldb/Core/Baton.h delete mode 100644 lldb/include/lldb/Core/Broadcaster.h delete mode 100644 lldb/include/lldb/Core/ClangForward.h delete mode 100644 lldb/include/lldb/Core/Communication.h delete mode 100644 lldb/include/lldb/Core/Connection.h delete mode 100644 lldb/include/lldb/Core/ConnectionFileDescriptor.h delete mode 100644 lldb/include/lldb/Core/ConnectionMachPort.h delete mode 100644 lldb/include/lldb/Core/ConnectionSharedMemory.h delete mode 100644 lldb/include/lldb/Core/ConstString.h delete mode 100644 lldb/include/lldb/Core/DataBuffer.h delete mode 100644 lldb/include/lldb/Core/DataBufferHeap.h delete mode 100644 lldb/include/lldb/Core/DataBufferMemoryMap.h delete mode 100644 lldb/include/lldb/Core/DataEncoder.h delete mode 100644 lldb/include/lldb/Core/DataExtractor.h delete mode 100644 lldb/include/lldb/Core/DataVisualization.h delete mode 100644 lldb/include/lldb/Core/Debugger.h delete mode 100644 lldb/include/lldb/Core/Disassembler.h delete mode 100644 lldb/include/lldb/Core/EmulateInstruction.h delete mode 100644 lldb/include/lldb/Core/Error.h delete mode 100644 lldb/include/lldb/Core/Event.h delete mode 100644 lldb/include/lldb/Core/FileLineResolver.h delete mode 100644 lldb/include/lldb/Core/FileSpecList.h delete mode 100644 lldb/include/lldb/Core/Flags.h delete mode 100644 lldb/include/lldb/Core/FormatClasses.h delete mode 100644 lldb/include/lldb/Core/FormatManager.h delete mode 100644 lldb/include/lldb/Core/FormatNavigator.h delete mode 100644 lldb/include/lldb/Core/History.h delete mode 100644 lldb/include/lldb/Core/IOStreamMacros.h delete mode 100644 lldb/include/lldb/Core/InputReader.h delete mode 100644 lldb/include/lldb/Core/InputReaderEZ.h delete mode 100644 lldb/include/lldb/Core/InputReaderStack.h delete mode 100644 lldb/include/lldb/Core/Language.h delete mode 100644 lldb/include/lldb/Core/Listener.h delete mode 100644 lldb/include/lldb/Core/Log.h delete mode 100644 lldb/include/lldb/Core/Mangled.h delete mode 100644 lldb/include/lldb/Core/MappedHash.h delete mode 100644 lldb/include/lldb/Core/Module.h delete mode 100644 lldb/include/lldb/Core/ModuleChild.h delete mode 100644 lldb/include/lldb/Core/ModuleList.h delete mode 100644 lldb/include/lldb/Core/Opcode.h delete mode 100644 lldb/include/lldb/Core/PluginInterface.h delete mode 100644 lldb/include/lldb/Core/PluginManager.h delete mode 100644 lldb/include/lldb/Core/RangeMap.h delete mode 100644 lldb/include/lldb/Core/RegisterValue.h delete mode 100644 lldb/include/lldb/Core/RegularExpression.h delete mode 100644 lldb/include/lldb/Core/STLUtils.h delete mode 100644 lldb/include/lldb/Core/Scalar.h delete mode 100644 lldb/include/lldb/Core/SearchFilter.h delete mode 100644 lldb/include/lldb/Core/Section.h delete mode 100644 lldb/include/lldb/Core/SourceManager.h delete mode 100644 lldb/include/lldb/Core/State.h delete mode 100644 lldb/include/lldb/Core/Stream.h delete mode 100644 lldb/include/lldb/Core/StreamAsynchronousIO.h delete mode 100644 lldb/include/lldb/Core/StreamBuffer.h delete mode 100644 lldb/include/lldb/Core/StreamCallback.h delete mode 100644 lldb/include/lldb/Core/StreamFile.h delete mode 100644 lldb/include/lldb/Core/StreamString.h delete mode 100644 lldb/include/lldb/Core/StreamTee.h delete mode 100644 lldb/include/lldb/Core/StringList.h delete mode 100644 lldb/include/lldb/Core/ThreadSafeSTLMap.h delete mode 100644 lldb/include/lldb/Core/ThreadSafeValue.h delete mode 100644 lldb/include/lldb/Core/Timer.h delete mode 100644 lldb/include/lldb/Core/UUID.h delete mode 100644 lldb/include/lldb/Core/UniqueCStringMap.h delete mode 100644 lldb/include/lldb/Core/UserID.h delete mode 100644 lldb/include/lldb/Core/UserSettingsController.h delete mode 100644 lldb/include/lldb/Core/VMRange.h delete mode 100644 lldb/include/lldb/Core/Value.h delete mode 100644 lldb/include/lldb/Core/ValueObject.h delete mode 100644 lldb/include/lldb/Core/ValueObjectChild.h delete mode 100644 lldb/include/lldb/Core/ValueObjectConstResult.h delete mode 100644 lldb/include/lldb/Core/ValueObjectConstResultChild.h delete mode 100644 lldb/include/lldb/Core/ValueObjectConstResultImpl.h delete mode 100644 lldb/include/lldb/Core/ValueObjectDynamicValue.h delete mode 100644 lldb/include/lldb/Core/ValueObjectList.h delete mode 100644 lldb/include/lldb/Core/ValueObjectMemory.h delete mode 100644 lldb/include/lldb/Core/ValueObjectRegister.h delete mode 100644 lldb/include/lldb/Core/ValueObjectSyntheticFilter.h delete mode 100644 lldb/include/lldb/Core/ValueObjectVariable.h delete mode 100644 lldb/include/lldb/Core/dwarf.h delete mode 100644 lldb/include/lldb/Expression/ASTDumper.h delete mode 100644 lldb/include/lldb/Expression/ASTResultSynthesizer.h delete mode 100644 lldb/include/lldb/Expression/ASTStructExtractor.h delete mode 100644 lldb/include/lldb/Expression/ClangASTSource.h delete mode 100644 lldb/include/lldb/Expression/ClangExpression.h delete mode 100644 lldb/include/lldb/Expression/ClangExpressionDeclMap.h delete mode 100644 lldb/include/lldb/Expression/ClangExpressionParser.h delete mode 100644 lldb/include/lldb/Expression/ClangExpressionVariable.h delete mode 100644 lldb/include/lldb/Expression/ClangFunction.h delete mode 100644 lldb/include/lldb/Expression/ClangPersistentVariables.h delete mode 100644 lldb/include/lldb/Expression/ClangUserExpression.h delete mode 100644 lldb/include/lldb/Expression/ClangUtilityFunction.h delete mode 100644 lldb/include/lldb/Expression/DWARFExpression.h delete mode 100644 lldb/include/lldb/Expression/ExpressionSourceCode.h delete mode 100644 lldb/include/lldb/Expression/IRDynamicChecks.h delete mode 100644 lldb/include/lldb/Expression/IRForTarget.h delete mode 100644 lldb/include/lldb/Expression/IRInterpreter.h delete mode 100644 lldb/include/lldb/Expression/IRToDWARF.h delete mode 100644 lldb/include/lldb/Expression/ProcessDataAllocator.h delete mode 100644 lldb/include/lldb/Expression/RecordingMemoryManager.h delete mode 100644 lldb/include/lldb/Host/Condition.h delete mode 100644 lldb/include/lldb/Host/Config.h delete mode 100644 lldb/include/lldb/Host/Endian.h delete mode 100644 lldb/include/lldb/Host/File.h delete mode 100644 lldb/include/lldb/Host/FileSpec.h delete mode 100644 lldb/include/lldb/Host/Host.h delete mode 100644 lldb/include/lldb/Host/Mutex.h delete mode 100644 lldb/include/lldb/Host/Predicate.h delete mode 100644 lldb/include/lldb/Host/ReadWriteLock.h delete mode 100644 lldb/include/lldb/Host/SocketAddress.h delete mode 100644 lldb/include/lldb/Host/Symbols.h delete mode 100644 lldb/include/lldb/Host/Terminal.h delete mode 100644 lldb/include/lldb/Host/TimeValue.h delete mode 100644 lldb/include/lldb/Host/freebsd/Config.h delete mode 100644 lldb/include/lldb/Host/linux/Config.h delete mode 100644 lldb/include/lldb/Host/macosx/Config.h delete mode 100644 lldb/include/lldb/Host/mingw/Config.h delete mode 100644 lldb/include/lldb/Interpreter/Args.h delete mode 100644 lldb/include/lldb/Interpreter/CommandCompletions.h delete mode 100644 lldb/include/lldb/Interpreter/CommandInterpreter.h delete mode 100644 lldb/include/lldb/Interpreter/CommandObject.h delete mode 100644 lldb/include/lldb/Interpreter/CommandObjectCrossref.h delete mode 100644 lldb/include/lldb/Interpreter/CommandObjectMultiword.h delete mode 100644 lldb/include/lldb/Interpreter/CommandObjectRegexCommand.h delete mode 100644 lldb/include/lldb/Interpreter/CommandReturnObject.h delete mode 100644 lldb/include/lldb/Interpreter/NamedOptionValue.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupArchitecture.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupBoolean.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupFile.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupFormat.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupOutputFile.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupPlatform.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupUInt64.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupUUID.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupVariable.h delete mode 100644 lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h delete mode 100644 lldb/include/lldb/Interpreter/Options.h delete mode 100644 lldb/include/lldb/Interpreter/ScriptInterpreter.h delete mode 100644 lldb/include/lldb/Interpreter/ScriptInterpreterNone.h delete mode 100644 lldb/include/lldb/Interpreter/ScriptInterpreterPython.h delete mode 100644 lldb/include/lldb/Makefile delete mode 100644 lldb/include/lldb/Symbol/Block.h delete mode 100644 lldb/include/lldb/Symbol/ClangASTContext.h delete mode 100644 lldb/include/lldb/Symbol/ClangASTImporter.h delete mode 100644 lldb/include/lldb/Symbol/ClangASTType.h delete mode 100644 lldb/include/lldb/Symbol/ClangExternalASTSourceCallbacks.h delete mode 100644 lldb/include/lldb/Symbol/ClangExternalASTSourceCommon.h delete mode 100644 lldb/include/lldb/Symbol/ClangNamespaceDecl.h delete mode 100644 lldb/include/lldb/Symbol/CompileUnit.h delete mode 100644 lldb/include/lldb/Symbol/DWARFCallFrameInfo.h delete mode 100644 lldb/include/lldb/Symbol/Declaration.h delete mode 100644 lldb/include/lldb/Symbol/FuncUnwinders.h delete mode 100644 lldb/include/lldb/Symbol/Function.h delete mode 100644 lldb/include/lldb/Symbol/LineEntry.h delete mode 100644 lldb/include/lldb/Symbol/LineTable.h delete mode 100644 lldb/include/lldb/Symbol/ObjectContainer.h delete mode 100644 lldb/include/lldb/Symbol/ObjectFile.h delete mode 100644 lldb/include/lldb/Symbol/Symbol.h delete mode 100644 lldb/include/lldb/Symbol/SymbolContext.h delete mode 100644 lldb/include/lldb/Symbol/SymbolContextScope.h delete mode 100644 lldb/include/lldb/Symbol/SymbolFile.h delete mode 100644 lldb/include/lldb/Symbol/SymbolVendor.h delete mode 100644 lldb/include/lldb/Symbol/Symtab.h delete mode 100644 lldb/include/lldb/Symbol/TaggedASTType.h delete mode 100644 lldb/include/lldb/Symbol/Type.h delete mode 100644 lldb/include/lldb/Symbol/TypeHierarchyNavigator.h delete mode 100644 lldb/include/lldb/Symbol/TypeList.h delete mode 100644 lldb/include/lldb/Symbol/UnwindPlan.h delete mode 100644 lldb/include/lldb/Symbol/UnwindTable.h delete mode 100644 lldb/include/lldb/Symbol/Variable.h delete mode 100644 lldb/include/lldb/Symbol/VariableList.h delete mode 100644 lldb/include/lldb/Symbol/VerifyDecl.h delete mode 100644 lldb/include/lldb/Target/ABI.h delete mode 100644 lldb/include/lldb/Target/CPPLanguageRuntime.h delete mode 100644 lldb/include/lldb/Target/DynamicLoader.h delete mode 100644 lldb/include/lldb/Target/ExecutionContext.h delete mode 100644 lldb/include/lldb/Target/ExecutionContextScope.h delete mode 100644 lldb/include/lldb/Target/LanguageRuntime.h delete mode 100644 lldb/include/lldb/Target/Memory.h delete mode 100644 lldb/include/lldb/Target/ObjCLanguageRuntime.h delete mode 100644 lldb/include/lldb/Target/OperatingSystem.h delete mode 100644 lldb/include/lldb/Target/PathMappingList.h delete mode 100644 lldb/include/lldb/Target/Platform.h delete mode 100644 lldb/include/lldb/Target/Process.h delete mode 100644 lldb/include/lldb/Target/RegisterContext.h delete mode 100644 lldb/include/lldb/Target/SectionLoadList.h delete mode 100644 lldb/include/lldb/Target/StackFrame.h delete mode 100644 lldb/include/lldb/Target/StackFrameList.h delete mode 100644 lldb/include/lldb/Target/StackID.h delete mode 100644 lldb/include/lldb/Target/StopInfo.h delete mode 100644 lldb/include/lldb/Target/Target.h delete mode 100644 lldb/include/lldb/Target/TargetList.h delete mode 100644 lldb/include/lldb/Target/Thread.h delete mode 100644 lldb/include/lldb/Target/ThreadList.h delete mode 100644 lldb/include/lldb/Target/ThreadPlan.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanBase.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanCallFunction.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanCallUserExpression.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanRunToAddress.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanShouldStopHere.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepInRange.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepInstruction.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepOut.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepOverBreakpoint.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepOverRange.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepRange.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepThrough.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanStepUntil.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanTestCondition.h delete mode 100644 lldb/include/lldb/Target/ThreadPlanTracer.h delete mode 100644 lldb/include/lldb/Target/ThreadSpec.h delete mode 100644 lldb/include/lldb/Target/UnixSignals.h delete mode 100644 lldb/include/lldb/Target/Unwind.h delete mode 100644 lldb/include/lldb/Target/UnwindAssembly.h delete mode 100644 lldb/include/lldb/Utility/AnsiTerminal.h delete mode 100644 lldb/include/lldb/Utility/CleanUp.h delete mode 100644 lldb/include/lldb/Utility/PriorityPointerPair.h delete mode 100644 lldb/include/lldb/Utility/PseudoTerminal.h delete mode 100644 lldb/include/lldb/Utility/PythonPointer.h delete mode 100644 lldb/include/lldb/Utility/RefCounter.h delete mode 100644 lldb/include/lldb/Utility/SharedCluster.h delete mode 100644 lldb/include/lldb/Utility/SharingPtr.h delete mode 100644 lldb/include/lldb/Utility/Utils.h delete mode 100644 lldb/include/lldb/lldb-defines.h delete mode 100644 lldb/include/lldb/lldb-enumerations.h delete mode 100644 lldb/include/lldb/lldb-forward.h delete mode 100644 lldb/include/lldb/lldb-private-enumerations.h delete mode 100644 lldb/include/lldb/lldb-private-interfaces.h delete mode 100644 lldb/include/lldb/lldb-private-log.h delete mode 100644 lldb/include/lldb/lldb-private-types.h delete mode 100644 lldb/include/lldb/lldb-private.h delete mode 100644 lldb/include/lldb/lldb-public.h delete mode 100644 lldb/include/lldb/lldb-types.h delete mode 100644 lldb/lib/Makefile delete mode 100644 lldb/lldb.xcodeproj/project.pbxproj delete mode 100644 lldb/lldb.xcodeproj/project.xcworkspace/contents.xcworkspacedata delete mode 100644 lldb/lldb.xcodeproj/xcshareddata/xcschemes/LLDB.xcscheme delete mode 100644 lldb/lldb.xcodeproj/xcshareddata/xcschemes/darwin-debug.xcscheme delete mode 100644 lldb/lldb.xcodeproj/xcshareddata/xcschemes/launcherRootXPCService.xcscheme delete mode 100644 lldb/lldb.xcodeproj/xcshareddata/xcschemes/launcherXPCService.xcscheme delete mode 100644 lldb/lldb.xcodeproj/xcshareddata/xcschemes/lldb-tool.xcscheme delete mode 100644 lldb/lldb.xcworkspace/contents.xcworkspacedata delete mode 100644 lldb/resources/LLDB-Info.plist delete mode 100644 lldb/resources/lldb-framework-exports delete mode 100755 lldb/scripts/Python/build-swig-Python.sh delete mode 100644 lldb/scripts/Python/edit-swig-python-wrapper-file.py delete mode 100755 lldb/scripts/Python/finish-swig-Python-LLDB.sh delete mode 100644 lldb/scripts/Python/interface/SBAddress.i delete mode 100644 lldb/scripts/Python/interface/SBBlock.i delete mode 100644 lldb/scripts/Python/interface/SBBreakpoint.i delete mode 100644 lldb/scripts/Python/interface/SBBreakpointLocation.i delete mode 100644 lldb/scripts/Python/interface/SBBroadcaster.i delete mode 100644 lldb/scripts/Python/interface/SBCommandInterpreter.i delete mode 100644 lldb/scripts/Python/interface/SBCommandReturnObject.i delete mode 100644 lldb/scripts/Python/interface/SBCommunication.i delete mode 100644 lldb/scripts/Python/interface/SBCompileUnit.i delete mode 100644 lldb/scripts/Python/interface/SBData.i delete mode 100644 lldb/scripts/Python/interface/SBDebugger.i delete mode 100644 lldb/scripts/Python/interface/SBError.i delete mode 100644 lldb/scripts/Python/interface/SBEvent.i delete mode 100644 lldb/scripts/Python/interface/SBFileSpec.i delete mode 100644 lldb/scripts/Python/interface/SBFileSpecList.i delete mode 100644 lldb/scripts/Python/interface/SBFrame.i delete mode 100644 lldb/scripts/Python/interface/SBFunction.i delete mode 100644 lldb/scripts/Python/interface/SBHostOS.i delete mode 100644 lldb/scripts/Python/interface/SBInputReader.i delete mode 100644 lldb/scripts/Python/interface/SBInstruction.i delete mode 100644 lldb/scripts/Python/interface/SBInstructionList.i delete mode 100644 lldb/scripts/Python/interface/SBLineEntry.i delete mode 100644 lldb/scripts/Python/interface/SBListener.i delete mode 100644 lldb/scripts/Python/interface/SBModule.i delete mode 100644 lldb/scripts/Python/interface/SBProcess.i delete mode 100644 lldb/scripts/Python/interface/SBSection.i delete mode 100644 lldb/scripts/Python/interface/SBSourceManager.i delete mode 100644 lldb/scripts/Python/interface/SBStream.i delete mode 100644 lldb/scripts/Python/interface/SBStringList.i delete mode 100644 lldb/scripts/Python/interface/SBSymbol.i delete mode 100644 lldb/scripts/Python/interface/SBSymbolContext.i delete mode 100644 lldb/scripts/Python/interface/SBSymbolContextList.i delete mode 100644 lldb/scripts/Python/interface/SBTarget.i delete mode 100644 lldb/scripts/Python/interface/SBThread.i delete mode 100644 lldb/scripts/Python/interface/SBType.i delete mode 100644 lldb/scripts/Python/interface/SBTypeCategory.i delete mode 100644 lldb/scripts/Python/interface/SBTypeFilter.i delete mode 100644 lldb/scripts/Python/interface/SBTypeFormat.i delete mode 100644 lldb/scripts/Python/interface/SBTypeNameSpecifier.i delete mode 100644 lldb/scripts/Python/interface/SBTypeSummary.i delete mode 100644 lldb/scripts/Python/interface/SBTypeSynthetic.i delete mode 100644 lldb/scripts/Python/interface/SBValue.i delete mode 100644 lldb/scripts/Python/interface/SBValueList.i delete mode 100644 lldb/scripts/Python/interface/SBWatchpoint.i delete mode 100644 lldb/scripts/Python/modify-python-lldb.py delete mode 100644 lldb/scripts/Python/python-extensions.swig delete mode 100644 lldb/scripts/Python/python-typemaps.swig delete mode 100644 lldb/scripts/Python/python-wrapper.swig delete mode 100755 lldb/scripts/build-lldb-llvm-clang delete mode 100644 lldb/scripts/build-llvm.pl delete mode 100755 lldb/scripts/build-swig-wrapper-classes.sh delete mode 100755 lldb/scripts/buildbot.py delete mode 100755 lldb/scripts/checkpoint-llvm.pl delete mode 100644 lldb/scripts/clang.check-definition-for-superclasses.diff delete mode 100644 lldb/scripts/clang.complete-type-getObjCLayout.diff delete mode 100644 lldb/scripts/clang.decl-printer-reference-type.diff delete mode 100644 lldb/scripts/clang.template-keyword-fixes.diff delete mode 100755 lldb/scripts/disasm-gdb-remote.pl delete mode 100755 lldb/scripts/finish-swig-wrapper-classes.sh delete mode 100755 lldb/scripts/generate-vers.pl delete mode 100755 lldb/scripts/install-lldb.sh delete mode 100644 lldb/scripts/lldb.swig delete mode 100644 lldb/scripts/llvm.fix-target-amalgamated.diff delete mode 100644 lldb/scripts/llvm.full-i386-relocations.diff delete mode 100644 lldb/scripts/llvm.info-leak.diff delete mode 100644 lldb/scripts/llvm.template-keyword-fixes.diff delete mode 100755 lldb/scripts/sed-sources delete mode 100644 lldb/source/API/Makefile delete mode 100644 lldb/source/API/SBAddress.cpp delete mode 100644 lldb/source/API/SBBlock.cpp delete mode 100644 lldb/source/API/SBBreakpoint.cpp delete mode 100644 lldb/source/API/SBBreakpointLocation.cpp delete mode 100644 lldb/source/API/SBBroadcaster.cpp delete mode 100644 lldb/source/API/SBCommandInterpreter.cpp delete mode 100644 lldb/source/API/SBCommandReturnObject.cpp delete mode 100644 lldb/source/API/SBCommunication.cpp delete mode 100644 lldb/source/API/SBCompileUnit.cpp delete mode 100644 lldb/source/API/SBData.cpp delete mode 100644 lldb/source/API/SBDebugger.cpp delete mode 100644 lldb/source/API/SBError.cpp delete mode 100644 lldb/source/API/SBEvent.cpp delete mode 100644 lldb/source/API/SBFileSpec.cpp delete mode 100644 lldb/source/API/SBFileSpecList.cpp delete mode 100644 lldb/source/API/SBFrame.cpp delete mode 100644 lldb/source/API/SBFunction.cpp delete mode 100644 lldb/source/API/SBHostOS.cpp delete mode 100644 lldb/source/API/SBInputReader.cpp delete mode 100644 lldb/source/API/SBInstruction.cpp delete mode 100644 lldb/source/API/SBInstructionList.cpp delete mode 100644 lldb/source/API/SBLineEntry.cpp delete mode 100644 lldb/source/API/SBListener.cpp delete mode 100644 lldb/source/API/SBModule.cpp delete mode 100644 lldb/source/API/SBProcess.cpp delete mode 100644 lldb/source/API/SBSection.cpp delete mode 100644 lldb/source/API/SBSourceManager.cpp delete mode 100644 lldb/source/API/SBStream.cpp delete mode 100644 lldb/source/API/SBStringList.cpp delete mode 100644 lldb/source/API/SBSymbol.cpp delete mode 100644 lldb/source/API/SBSymbolContext.cpp delete mode 100644 lldb/source/API/SBSymbolContextList.cpp delete mode 100644 lldb/source/API/SBTarget.cpp delete mode 100644 lldb/source/API/SBThread.cpp delete mode 100644 lldb/source/API/SBType.cpp delete mode 100644 lldb/source/API/SBTypeCategory.cpp delete mode 100644 lldb/source/API/SBTypeFilter.cpp delete mode 100644 lldb/source/API/SBTypeFormat.cpp delete mode 100644 lldb/source/API/SBTypeNameSpecifier.cpp delete mode 100644 lldb/source/API/SBTypeSummary.cpp delete mode 100644 lldb/source/API/SBTypeSynthetic.cpp delete mode 100644 lldb/source/API/SBValue.cpp delete mode 100644 lldb/source/API/SBValueList.cpp delete mode 100644 lldb/source/API/SBWatchpoint.cpp delete mode 100644 lldb/source/Breakpoint/Breakpoint.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointID.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointIDList.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointList.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointLocation.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointLocationCollection.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointLocationList.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointOptions.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointResolver.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointResolverAddress.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointResolverFileLine.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointResolverFileRegex.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointResolverName.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointSite.cpp delete mode 100644 lldb/source/Breakpoint/BreakpointSiteList.cpp delete mode 100644 lldb/source/Breakpoint/Makefile delete mode 100644 lldb/source/Breakpoint/Stoppoint.cpp delete mode 100644 lldb/source/Breakpoint/StoppointCallbackContext.cpp delete mode 100644 lldb/source/Breakpoint/StoppointLocation.cpp delete mode 100644 lldb/source/Breakpoint/Watchpoint.cpp delete mode 100644 lldb/source/Breakpoint/WatchpointList.cpp delete mode 100644 lldb/source/Commands/CommandCompletions.cpp delete mode 100644 lldb/source/Commands/CommandObjectApropos.cpp delete mode 100644 lldb/source/Commands/CommandObjectApropos.h delete mode 100644 lldb/source/Commands/CommandObjectArgs.cpp delete mode 100644 lldb/source/Commands/CommandObjectArgs.h delete mode 100644 lldb/source/Commands/CommandObjectBreakpoint.cpp delete mode 100644 lldb/source/Commands/CommandObjectBreakpoint.h delete mode 100644 lldb/source/Commands/CommandObjectBreakpointCommand.cpp delete mode 100644 lldb/source/Commands/CommandObjectBreakpointCommand.h delete mode 100644 lldb/source/Commands/CommandObjectCommands.cpp delete mode 100644 lldb/source/Commands/CommandObjectCommands.h delete mode 100644 lldb/source/Commands/CommandObjectCrossref.cpp delete mode 100644 lldb/source/Commands/CommandObjectDisassemble.cpp delete mode 100644 lldb/source/Commands/CommandObjectDisassemble.h delete mode 100644 lldb/source/Commands/CommandObjectExpression.cpp delete mode 100644 lldb/source/Commands/CommandObjectExpression.h delete mode 100644 lldb/source/Commands/CommandObjectFrame.cpp delete mode 100644 lldb/source/Commands/CommandObjectFrame.h delete mode 100644 lldb/source/Commands/CommandObjectHelp.cpp delete mode 100644 lldb/source/Commands/CommandObjectHelp.h delete mode 100644 lldb/source/Commands/CommandObjectLog.cpp delete mode 100644 lldb/source/Commands/CommandObjectLog.h delete mode 100644 lldb/source/Commands/CommandObjectMemory.cpp delete mode 100644 lldb/source/Commands/CommandObjectMemory.h delete mode 100644 lldb/source/Commands/CommandObjectMultiword.cpp delete mode 100644 lldb/source/Commands/CommandObjectPlatform.cpp delete mode 100644 lldb/source/Commands/CommandObjectPlatform.h delete mode 100644 lldb/source/Commands/CommandObjectProcess.cpp delete mode 100644 lldb/source/Commands/CommandObjectProcess.h delete mode 100644 lldb/source/Commands/CommandObjectQuit.cpp delete mode 100644 lldb/source/Commands/CommandObjectQuit.h delete mode 100644 lldb/source/Commands/CommandObjectRegister.cpp delete mode 100644 lldb/source/Commands/CommandObjectRegister.h delete mode 100644 lldb/source/Commands/CommandObjectSettings.cpp delete mode 100644 lldb/source/Commands/CommandObjectSettings.h delete mode 100644 lldb/source/Commands/CommandObjectSource.cpp delete mode 100644 lldb/source/Commands/CommandObjectSource.h delete mode 100644 lldb/source/Commands/CommandObjectSyntax.cpp delete mode 100644 lldb/source/Commands/CommandObjectSyntax.h delete mode 100644 lldb/source/Commands/CommandObjectTarget.cpp delete mode 100644 lldb/source/Commands/CommandObjectTarget.h delete mode 100644 lldb/source/Commands/CommandObjectThread.cpp delete mode 100644 lldb/source/Commands/CommandObjectThread.h delete mode 100644 lldb/source/Commands/CommandObjectType.cpp delete mode 100644 lldb/source/Commands/CommandObjectType.h delete mode 100644 lldb/source/Commands/CommandObjectVersion.cpp delete mode 100644 lldb/source/Commands/CommandObjectVersion.h delete mode 100644 lldb/source/Commands/CommandObjectWatchpoint.cpp delete mode 100644 lldb/source/Commands/CommandObjectWatchpoint.h delete mode 100644 lldb/source/Commands/Makefile delete mode 100644 lldb/source/Core/Address.cpp delete mode 100644 lldb/source/Core/AddressRange.cpp delete mode 100644 lldb/source/Core/AddressResolver.cpp delete mode 100644 lldb/source/Core/AddressResolverFileLine.cpp delete mode 100644 lldb/source/Core/AddressResolverName.cpp delete mode 100644 lldb/source/Core/ArchSpec.cpp delete mode 100644 lldb/source/Core/Baton.cpp delete mode 100644 lldb/source/Core/Broadcaster.cpp delete mode 100644 lldb/source/Core/Communication.cpp delete mode 100644 lldb/source/Core/Connection.cpp delete mode 100644 lldb/source/Core/ConnectionFileDescriptor.cpp delete mode 100644 lldb/source/Core/ConnectionMachPort.cpp delete mode 100644 lldb/source/Core/ConnectionSharedMemory.cpp delete mode 100644 lldb/source/Core/ConstString.cpp delete mode 100644 lldb/source/Core/DataBufferHeap.cpp delete mode 100644 lldb/source/Core/DataBufferMemoryMap.cpp delete mode 100644 lldb/source/Core/DataEncoder.cpp delete mode 100644 lldb/source/Core/DataExtractor.cpp delete mode 100644 lldb/source/Core/DataVisualization.cpp delete mode 100644 lldb/source/Core/Debugger.cpp delete mode 100644 lldb/source/Core/Disassembler.cpp delete mode 100644 lldb/source/Core/DynamicLoader.cpp delete mode 100644 lldb/source/Core/EmulateInstruction.cpp delete mode 100644 lldb/source/Core/Error.cpp delete mode 100644 lldb/source/Core/Event.cpp delete mode 100644 lldb/source/Core/FileLineResolver.cpp delete mode 100644 lldb/source/Core/FileSpecList.cpp delete mode 100644 lldb/source/Core/FormatClasses.cpp delete mode 100644 lldb/source/Core/FormatManager.cpp delete mode 100644 lldb/source/Core/History.cpp delete mode 100644 lldb/source/Core/InputReader.cpp delete mode 100644 lldb/source/Core/InputReaderEZ.cpp delete mode 100644 lldb/source/Core/InputReaderStack.cpp delete mode 100644 lldb/source/Core/Language.cpp delete mode 100644 lldb/source/Core/Listener.cpp delete mode 100644 lldb/source/Core/Log.cpp delete mode 100644 lldb/source/Core/Makefile delete mode 100644 lldb/source/Core/Mangled.cpp delete mode 100644 lldb/source/Core/Module.cpp delete mode 100644 lldb/source/Core/ModuleChild.cpp delete mode 100644 lldb/source/Core/ModuleList.cpp delete mode 100644 lldb/source/Core/Opcode.cpp delete mode 100644 lldb/source/Core/PluginManager.cpp delete mode 100644 lldb/source/Core/RegisterValue.cpp delete mode 100644 lldb/source/Core/RegularExpression.cpp delete mode 100644 lldb/source/Core/Scalar.cpp delete mode 100644 lldb/source/Core/SearchFilter.cpp delete mode 100644 lldb/source/Core/Section.cpp delete mode 100644 lldb/source/Core/SourceManager.cpp delete mode 100644 lldb/source/Core/State.cpp delete mode 100644 lldb/source/Core/Stream.cpp delete mode 100644 lldb/source/Core/StreamAsynchronousIO.cpp delete mode 100644 lldb/source/Core/StreamCallback.cpp delete mode 100644 lldb/source/Core/StreamFile.cpp delete mode 100644 lldb/source/Core/StreamString.cpp delete mode 100644 lldb/source/Core/StringList.cpp delete mode 100644 lldb/source/Core/Timer.cpp delete mode 100644 lldb/source/Core/UUID.cpp delete mode 100644 lldb/source/Core/UserID.cpp delete mode 100644 lldb/source/Core/UserSettingsController.cpp delete mode 100644 lldb/source/Core/VMRange.cpp delete mode 100644 lldb/source/Core/Value.cpp delete mode 100644 lldb/source/Core/ValueObject.cpp delete mode 100644 lldb/source/Core/ValueObjectChild.cpp delete mode 100644 lldb/source/Core/ValueObjectConstResult.cpp delete mode 100644 lldb/source/Core/ValueObjectConstResultChild.cpp delete mode 100644 lldb/source/Core/ValueObjectConstResultImpl.cpp delete mode 100644 lldb/source/Core/ValueObjectDynamicValue.cpp delete mode 100644 lldb/source/Core/ValueObjectList.cpp delete mode 100644 lldb/source/Core/ValueObjectMemory.cpp delete mode 100644 lldb/source/Core/ValueObjectRegister.cpp delete mode 100644 lldb/source/Core/ValueObjectSyntheticFilter.cpp delete mode 100644 lldb/source/Core/ValueObjectVariable.cpp delete mode 100644 lldb/source/Expression/ASTDumper.cpp delete mode 100644 lldb/source/Expression/ASTResultSynthesizer.cpp delete mode 100644 lldb/source/Expression/ASTStructExtractor.cpp delete mode 100644 lldb/source/Expression/ClangASTSource.cpp delete mode 100644 lldb/source/Expression/ClangExpressionDeclMap.cpp delete mode 100644 lldb/source/Expression/ClangExpressionParser.cpp delete mode 100644 lldb/source/Expression/ClangExpressionVariable.cpp delete mode 100644 lldb/source/Expression/ClangFunction.cpp delete mode 100644 lldb/source/Expression/ClangPersistentVariables.cpp delete mode 100644 lldb/source/Expression/ClangUserExpression.cpp delete mode 100644 lldb/source/Expression/ClangUtilityFunction.cpp delete mode 100644 lldb/source/Expression/DWARFExpression.cpp delete mode 100644 lldb/source/Expression/ExpressionSourceCode.cpp delete mode 100644 lldb/source/Expression/IRDynamicChecks.cpp delete mode 100644 lldb/source/Expression/IRForTarget.cpp delete mode 100644 lldb/source/Expression/IRInterpreter.cpp delete mode 100644 lldb/source/Expression/Makefile delete mode 100644 lldb/source/Expression/ProcessDataAllocator.cpp delete mode 100644 lldb/source/Expression/RecordingMemoryManager.cpp delete mode 100644 lldb/source/Host/Makefile delete mode 100644 lldb/source/Host/common/Condition.cpp delete mode 100644 lldb/source/Host/common/File.cpp delete mode 100644 lldb/source/Host/common/FileSpec.cpp delete mode 100644 lldb/source/Host/common/Host.cpp delete mode 100644 lldb/source/Host/common/Makefile delete mode 100644 lldb/source/Host/common/Mutex.cpp delete mode 100644 lldb/source/Host/common/SocketAddress.cpp delete mode 100644 lldb/source/Host/common/Symbols.cpp delete mode 100644 lldb/source/Host/common/Terminal.cpp delete mode 100644 lldb/source/Host/common/TimeValue.cpp delete mode 100644 lldb/source/Host/freebsd/Host.cpp delete mode 100644 lldb/source/Host/freebsd/Makefile delete mode 100644 lldb/source/Host/linux/Host.cpp delete mode 100644 lldb/source/Host/linux/Makefile delete mode 100644 lldb/source/Host/macosx/Host.mm delete mode 100644 lldb/source/Host/macosx/Makefile delete mode 100644 lldb/source/Host/macosx/Symbols.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCBundle.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCBundle.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCData.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCData.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableArray.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableArray.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableSet.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCMutableSet.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCReleaser.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCString.cpp delete mode 100644 lldb/source/Host/macosx/cfcpp/CFCString.h delete mode 100644 lldb/source/Host/macosx/cfcpp/CoreFoundationCPP.h delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherRootXPCService-Info.plist delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherRootXPCService.mm delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherXPCService-Info.plist delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherXPCService.entitlements delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherXPCService.h delete mode 100644 lldb/source/Host/macosx/launcherXPCService/LauncherXPCService.mm delete mode 100644 lldb/source/Host/macosx/launcherXPCService/main.mm delete mode 100644 lldb/source/Interpreter/Args.cpp delete mode 100644 lldb/source/Interpreter/CommandInterpreter.cpp delete mode 100644 lldb/source/Interpreter/CommandObject.cpp delete mode 100644 lldb/source/Interpreter/CommandObjectRegexCommand.cpp delete mode 100644 lldb/source/Interpreter/CommandObjectScript.cpp delete mode 100644 lldb/source/Interpreter/CommandObjectScript.h delete mode 100644 lldb/source/Interpreter/CommandReturnObject.cpp delete mode 100644 lldb/source/Interpreter/Makefile delete mode 100644 lldb/source/Interpreter/NamedOptionValue.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupArchitecture.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupBoolean.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupFile.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupFormat.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupOutputFile.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupPlatform.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupUInt64.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupUUID.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupVariable.cpp delete mode 100644 lldb/source/Interpreter/OptionGroupWatchpoint.cpp delete mode 100644 lldb/source/Interpreter/Options.cpp delete mode 100644 lldb/source/Interpreter/ScriptInterpreter.cpp delete mode 100644 lldb/source/Interpreter/ScriptInterpreterNone.cpp delete mode 100644 lldb/source/Interpreter/ScriptInterpreterPython.cpp delete mode 100644 lldb/source/Interpreter/embedded_interpreter.py delete mode 100644 lldb/source/Makefile delete mode 100644 lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp delete mode 100644 lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.h delete mode 100644 lldb/source/Plugins/ABI/MacOSX-arm/Makefile delete mode 100644 lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp delete mode 100644 lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.h delete mode 100644 lldb/source/Plugins/ABI/MacOSX-i386/Makefile delete mode 100644 lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp delete mode 100644 lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.h delete mode 100644 lldb/source/Plugins/ABI/SysV-x86_64/Makefile delete mode 100644 lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVM.cpp delete mode 100644 lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVM.h delete mode 100644 lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.cpp delete mode 100644 lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.h delete mode 100644 lldb/source/Plugins/Disassembler/llvm/Makefile delete mode 100644 lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.h delete mode 100644 lldb/source/Plugins/DynamicLoader/Darwin-Kernel/Makefile delete mode 100644 lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.h delete mode 100644 lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/Makefile delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.h delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.h delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.h delete mode 100644 lldb/source/Plugins/DynamicLoader/POSIX-DYLD/Makefile delete mode 100644 lldb/source/Plugins/DynamicLoader/Static/DynamicLoaderStatic.cpp delete mode 100644 lldb/source/Plugins/DynamicLoader/Static/DynamicLoaderStatic.h delete mode 100644 lldb/source/Plugins/DynamicLoader/Static/Makefile delete mode 100644 lldb/source/Plugins/Instruction/ARM/EmulateInstructionARM.cpp delete mode 100644 lldb/source/Plugins/Instruction/ARM/EmulateInstructionARM.h delete mode 100644 lldb/source/Plugins/Instruction/ARM/EmulationStateARM.cpp delete mode 100644 lldb/source/Plugins/Instruction/ARM/EmulationStateARM.h delete mode 100644 lldb/source/Plugins/Instruction/ARM/Makefile delete mode 100644 lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/Makefile delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV1.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV1.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCSymbolVendor.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCSymbolVendor.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.cpp delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.h delete mode 100644 lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/Makefile delete mode 100644 lldb/source/Plugins/Makefile delete mode 100644 lldb/source/Plugins/ObjectContainer/BSD-Archive/Makefile delete mode 100644 lldb/source/Plugins/ObjectContainer/BSD-Archive/ObjectContainerBSDArchive.cpp delete mode 100644 lldb/source/Plugins/ObjectContainer/BSD-Archive/ObjectContainerBSDArchive.h delete mode 100644 lldb/source/Plugins/ObjectContainer/Universal-Mach-O/Makefile delete mode 100644 lldb/source/Plugins/ObjectContainer/Universal-Mach-O/ObjectContainerUniversalMachO.cpp delete mode 100644 lldb/source/Plugins/ObjectContainer/Universal-Mach-O/ObjectContainerUniversalMachO.h delete mode 100644 lldb/source/Plugins/ObjectFile/ELF/ELFHeader.cpp delete mode 100644 lldb/source/Plugins/ObjectFile/ELF/ELFHeader.h delete mode 100644 lldb/source/Plugins/ObjectFile/ELF/Makefile delete mode 100644 lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp delete mode 100644 lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.h delete mode 100644 lldb/source/Plugins/ObjectFile/Mach-O/Makefile delete mode 100644 lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp delete mode 100644 lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.h delete mode 100644 lldb/source/Plugins/ObjectFile/PECOFF/Makefile delete mode 100644 lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.cpp delete mode 100644 lldb/source/Plugins/ObjectFile/PECOFF/ObjectFilePECOFF.h delete mode 100644 lldb/source/Plugins/OperatingSystem/Darwin-Kernel/Makefile delete mode 100644 lldb/source/Plugins/OperatingSystem/Darwin-Kernel/OperatingSystemDarwinKernel.cpp delete mode 100644 lldb/source/Plugins/OperatingSystem/Darwin-Kernel/OperatingSystemDarwinKernel.h delete mode 100644 lldb/source/Plugins/Platform/FreeBSD/Makefile delete mode 100644 lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp delete mode 100644 lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h delete mode 100644 lldb/source/Plugins/Platform/Linux/Makefile delete mode 100644 lldb/source/Plugins/Platform/Linux/PlatformLinux.cpp delete mode 100644 lldb/source/Plugins/Platform/Linux/PlatformLinux.h delete mode 100644 lldb/source/Plugins/Platform/MacOSX/Makefile delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformDarwin.h delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformRemoteiOS.cpp delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformRemoteiOS.h delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformiOSSimulator.cpp delete mode 100644 lldb/source/Plugins/Platform/MacOSX/PlatformiOSSimulator.h delete mode 100644 lldb/source/Plugins/Platform/Makefile delete mode 100644 lldb/source/Plugins/Platform/gdb-server/Makefile delete mode 100644 lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp delete mode 100644 lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h delete mode 100644 lldb/source/Plugins/Process/FreeBSD/Makefile delete mode 100644 lldb/source/Plugins/Process/FreeBSD/ProcessFreeBSD.cpp delete mode 100644 lldb/source/Plugins/Process/FreeBSD/ProcessFreeBSD.h delete mode 100644 lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp delete mode 100644 lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.h delete mode 100644 lldb/source/Plugins/Process/FreeBSD/RegisterContextFreeBSD_x86_64.h delete mode 100644 lldb/source/Plugins/Process/Linux/LinuxSignals.cpp delete mode 100644 lldb/source/Plugins/Process/Linux/LinuxSignals.h delete mode 100644 lldb/source/Plugins/Process/Linux/Makefile delete mode 100644 lldb/source/Plugins/Process/Linux/ProcessLinux.cpp delete mode 100644 lldb/source/Plugins/Process/Linux/ProcessLinux.h delete mode 100644 lldb/source/Plugins/Process/Linux/ProcessMonitor.cpp delete mode 100644 lldb/source/Plugins/Process/Linux/ProcessMonitor.h delete mode 100644 lldb/source/Plugins/Process/Linux/RegisterContextLinux_x86_64.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/CommunicationKDP.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/CommunicationKDP.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/Makefile delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDPLog.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDPLog.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_arm.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_arm.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_i386.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_i386.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_x86_64.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/RegisterContextKDP_x86_64.h delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ThreadKDP.cpp delete mode 100644 lldb/source/Plugins/Process/MacOSX-Kernel/ThreadKDP.h delete mode 100644 lldb/source/Plugins/Process/POSIX/Makefile delete mode 100644 lldb/source/Plugins/Process/POSIX/POSIXStopInfo.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/POSIXStopInfo.h delete mode 100644 lldb/source/Plugins/Process/POSIX/POSIXThread.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/POSIXThread.h delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessMessage.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessMessage.h delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessPOSIX.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessPOSIX.h delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessPOSIXLog.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/ProcessPOSIXLog.h delete mode 100644 lldb/source/Plugins/Process/POSIX/RegisterContextPOSIX.h delete mode 100644 lldb/source/Plugins/Process/POSIX/RegisterContext_i386.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/RegisterContext_i386.h delete mode 100644 lldb/source/Plugins/Process/POSIX/RegisterContext_x86_64.cpp delete mode 100644 lldb/source/Plugins/Process/POSIX/RegisterContext_x86_64.h delete mode 100644 lldb/source/Plugins/Process/Utility/ARMDefines.h delete mode 100644 lldb/source/Plugins/Process/Utility/ARMUtils.h delete mode 100644 lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.h delete mode 100644 lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.h delete mode 100644 lldb/source/Plugins/Process/Utility/InstructionUtils.h delete mode 100644 lldb/source/Plugins/Process/Utility/Makefile delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_i386.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_i386.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_x86_64.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextDarwin_x86_64.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextLLDB.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextLLDB.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMacOSXFrameBackchain.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMacOSXFrameBackchain.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_arm.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_arm.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_i386.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_i386.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_x86_64.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMach_x86_64.h delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMemory.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/RegisterContextMemory.h delete mode 100644 lldb/source/Plugins/Process/Utility/StopInfoMachException.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/StopInfoMachException.h delete mode 100644 lldb/source/Plugins/Process/Utility/ThreadMemory.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/ThreadMemory.h delete mode 100644 lldb/source/Plugins/Process/Utility/UnwindLLDB.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/UnwindLLDB.h delete mode 100644 lldb/source/Plugins/Process/Utility/UnwindMacOSXFrameBackchain.cpp delete mode 100644 lldb/source/Plugins/Process/Utility/UnwindMacOSXFrameBackchain.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/Makefile delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemoteLog.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemoteLog.h delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp delete mode 100644 lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.h delete mode 100644 lldb/source/Plugins/Process/mach-core/Makefile delete mode 100644 lldb/source/Plugins/Process/mach-core/ProcessMachCore.cpp delete mode 100644 lldb/source/Plugins/Process/mach-core/ProcessMachCore.h delete mode 100644 lldb/source/Plugins/Process/mach-core/ThreadMachCore.cpp delete mode 100644 lldb/source/Plugins/Process/mach-core/ThreadMachCore.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFAttribute.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDIECollection.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDIECollection.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAbbrev.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAbbrev.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugArangeSet.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugArangeSet.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAranges.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAranges.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugLine.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugLine.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugMacinfo.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugMacinfo.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugMacinfoEntry.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugMacinfoEntry.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugPubnames.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugPubnames.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugPubnamesSet.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugPubnamesSet.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugRanges.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugRanges.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDefines.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFDefines.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationDescription.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationDescription.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/DWARFLocationList.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/HashedNameToDIE.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/LogChannelDWARF.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/LogChannelDWARF.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/Makefile delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/NameToDIE.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/NameToDIE.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/UniqueDWARFASTType.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/DWARF/UniqueDWARFASTType.h delete mode 100644 lldb/source/Plugins/SymbolFile/Symtab/Makefile delete mode 100644 lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp delete mode 100644 lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h delete mode 100644 lldb/source/Plugins/SymbolVendor/MacOSX/Makefile delete mode 100644 lldb/source/Plugins/SymbolVendor/MacOSX/SymbolVendorMacOSX.cpp delete mode 100644 lldb/source/Plugins/SymbolVendor/MacOSX/SymbolVendorMacOSX.h delete mode 100644 lldb/source/Plugins/UnwindAssembly/InstEmulation/Makefile delete mode 100644 lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp delete mode 100644 lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.h delete mode 100644 lldb/source/Plugins/UnwindAssembly/x86/Makefile delete mode 100644 lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp delete mode 100644 lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.h delete mode 100644 lldb/source/Symbol/Block.cpp delete mode 100644 lldb/source/Symbol/ClangASTContext.cpp delete mode 100644 lldb/source/Symbol/ClangASTImporter.cpp delete mode 100644 lldb/source/Symbol/ClangASTType.cpp delete mode 100644 lldb/source/Symbol/ClangExternalASTSourceCallbacks.cpp delete mode 100644 lldb/source/Symbol/ClangExternalASTSourceCommon.cpp delete mode 100644 lldb/source/Symbol/ClangNamespaceDecl.cpp delete mode 100644 lldb/source/Symbol/CompileUnit.cpp delete mode 100644 lldb/source/Symbol/DWARFCallFrameInfo.cpp delete mode 100644 lldb/source/Symbol/Declaration.cpp delete mode 100644 lldb/source/Symbol/FuncUnwinders.cpp delete mode 100644 lldb/source/Symbol/Function.cpp delete mode 100644 lldb/source/Symbol/LineEntry.cpp delete mode 100644 lldb/source/Symbol/LineTable.cpp delete mode 100644 lldb/source/Symbol/Makefile delete mode 100644 lldb/source/Symbol/ObjectFile.cpp delete mode 100644 lldb/source/Symbol/Symbol.cpp delete mode 100644 lldb/source/Symbol/SymbolContext.cpp delete mode 100644 lldb/source/Symbol/SymbolFile.cpp delete mode 100644 lldb/source/Symbol/SymbolVendor.cpp delete mode 100644 lldb/source/Symbol/Symtab.cpp delete mode 100644 lldb/source/Symbol/Type.cpp delete mode 100644 lldb/source/Symbol/TypeHierarchyNavigator.cpp delete mode 100644 lldb/source/Symbol/TypeList.cpp delete mode 100644 lldb/source/Symbol/UnwindPlan.cpp delete mode 100644 lldb/source/Symbol/UnwindTable.cpp delete mode 100644 lldb/source/Symbol/Variable.cpp delete mode 100644 lldb/source/Symbol/VariableList.cpp delete mode 100644 lldb/source/Symbol/VerifyDecl.cpp delete mode 100644 lldb/source/Target/ABI.cpp delete mode 100644 lldb/source/Target/CPPLanguageRuntime.cpp delete mode 100644 lldb/source/Target/ExecutionContext.cpp delete mode 100644 lldb/source/Target/LanguageRuntime.cpp delete mode 100644 lldb/source/Target/Makefile delete mode 100644 lldb/source/Target/Memory.cpp delete mode 100644 lldb/source/Target/ObjCLanguageRuntime.cpp delete mode 100644 lldb/source/Target/OperatingSystem.cpp delete mode 100644 lldb/source/Target/PathMappingList.cpp delete mode 100644 lldb/source/Target/Platform.cpp delete mode 100644 lldb/source/Target/Process.cpp delete mode 100644 lldb/source/Target/RegisterContext.cpp delete mode 100644 lldb/source/Target/SectionLoadList.cpp delete mode 100644 lldb/source/Target/StackFrame.cpp delete mode 100644 lldb/source/Target/StackFrameList.cpp delete mode 100644 lldb/source/Target/StackID.cpp delete mode 100644 lldb/source/Target/StopInfo.cpp delete mode 100644 lldb/source/Target/Target.cpp delete mode 100644 lldb/source/Target/TargetList.cpp delete mode 100644 lldb/source/Target/Thread.cpp delete mode 100644 lldb/source/Target/ThreadList.cpp delete mode 100644 lldb/source/Target/ThreadPlan.cpp delete mode 100644 lldb/source/Target/ThreadPlanBase.cpp delete mode 100644 lldb/source/Target/ThreadPlanCallFunction.cpp delete mode 100644 lldb/source/Target/ThreadPlanCallUserExpression.cpp delete mode 100644 lldb/source/Target/ThreadPlanRunToAddress.cpp delete mode 100644 lldb/source/Target/ThreadPlanShouldStopHere.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepInRange.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepInstruction.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepOut.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepOverBreakpoint.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepOverRange.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepRange.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepThrough.cpp delete mode 100644 lldb/source/Target/ThreadPlanStepUntil.cpp delete mode 100644 lldb/source/Target/ThreadPlanTestCondition.cpp delete mode 100644 lldb/source/Target/ThreadPlanTracer.cpp delete mode 100644 lldb/source/Target/ThreadSpec.cpp delete mode 100644 lldb/source/Target/UnixSignals.cpp delete mode 100644 lldb/source/Target/UnwindAssembly.cpp delete mode 100644 lldb/source/Utility/ARM_DWARF_Registers.cpp delete mode 100644 lldb/source/Utility/ARM_DWARF_Registers.h delete mode 100644 lldb/source/Utility/ARM_GCC_Registers.h delete mode 100644 lldb/source/Utility/Makefile delete mode 100644 lldb/source/Utility/PseudoTerminal.cpp delete mode 100644 lldb/source/Utility/RefCounter.cpp delete mode 100644 lldb/source/Utility/SharingPtr.cpp delete mode 100644 lldb/source/Utility/StringExtractor.cpp delete mode 100644 lldb/source/Utility/StringExtractor.h delete mode 100644 lldb/source/Utility/StringExtractorGDBRemote.cpp delete mode 100644 lldb/source/Utility/StringExtractorGDBRemote.h delete mode 100644 lldb/source/lldb-log.cpp delete mode 100644 lldb/source/lldb.cpp delete mode 100644 lldb/test/Makefile delete mode 100644 lldb/test/README-TestSuite delete mode 100644 lldb/test/api/check_public_api_headers/Makefile delete mode 100644 lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py delete mode 100644 lldb/test/api/check_public_api_headers/main.cpp.template delete mode 100644 lldb/test/arm_emulation/TestEmulations.py delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-10-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-11-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-12-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-5-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-5-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-6-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-6-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-7-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-7-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-8-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-8-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-add-9-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-bic-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-bic-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldmia-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-10-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-11-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-12-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-5-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-5-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-6-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-6-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-7-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-7-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-8-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-8-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldr-9-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrd-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrd-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrd-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrh-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrsh-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-ldrsh-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-10-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-11-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-12-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-13-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-14-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-15-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-16-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-17-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-18-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-19-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-20-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-21-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-22-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-23-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-24-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-25-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-26-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-27-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-28-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-29-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-30-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-31-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-5-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-5-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-6-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-6-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-7-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-8-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mov-9-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-moveq-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-movs-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-mvn-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-pop-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-pop-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-pop-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-pop-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-pop-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-push-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-str-5-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-strb-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-strb-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-strbt-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-strd-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-strt-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-10-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-2-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-3-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-4-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-5-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-5-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-6-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-6-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-8-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-sub-9-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-1-arm.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-10-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-4-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-5-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-6-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-8-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-subs-9-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpop-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpop-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpop-3-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpush-1-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpush-2-thumb.dat delete mode 100644 lldb/test/arm_emulation/new-test-files/test-vpush-3-thumb.dat delete mode 100755 lldb/test/attic/dotest.pl delete mode 100755 lldb/test/attic/tester.py delete mode 100644 lldb/test/bench-history delete mode 100755 lldb/test/bench.py delete mode 100644 lldb/test/benchmarks/disassembly/TestDisassembly.py delete mode 100644 lldb/test/benchmarks/disassembly/TestDoAttachThenDisassembly.py delete mode 100644 lldb/test/benchmarks/disassembly/TestFlintVsSlateGDBDisassembly.py delete mode 100644 lldb/test/benchmarks/expression/Makefile delete mode 100644 lldb/test/benchmarks/expression/TestExpressionCmd.py delete mode 100644 lldb/test/benchmarks/expression/TestRepeatedExprs.py delete mode 100644 lldb/test/benchmarks/expression/main.cpp delete mode 100644 lldb/test/benchmarks/frame_variable/TestFrameVariableResponse.py delete mode 100644 lldb/test/benchmarks/startup/TestStartupDelays.py delete mode 100644 lldb/test/benchmarks/stepping/TestRunHooksThenSteppings.py delete mode 100644 lldb/test/benchmarks/stepping/TestSteppingSpeed.py delete mode 100644 lldb/test/benchmarks/turnaround/TestCompileRunToBreakpointTurnaround.py delete mode 100644 lldb/test/blacklist.py delete mode 100755 lldb/test/dosep.ty delete mode 100755 lldb/test/dotest.py delete mode 100644 lldb/test/example/TestSequenceFunctions.py delete mode 100644 lldb/test/expression_command/call-function/Makefile delete mode 100644 lldb/test/expression_command/call-function/TestCallStdStringFunction.py delete mode 100644 lldb/test/expression_command/call-function/main.cpp delete mode 100644 lldb/test/expression_command/formatters/Makefile delete mode 100644 lldb/test/expression_command/formatters/TestFormatters.py delete mode 100644 lldb/test/expression_command/formatters/foosynth.py delete mode 100644 lldb/test/expression_command/formatters/formatters.py delete mode 100644 lldb/test/expression_command/formatters/main.cpp delete mode 100644 lldb/test/expression_command/issue_11588/Makefile delete mode 100644 lldb/test/expression_command/issue_11588/Test11588.py delete mode 100644 lldb/test/expression_command/issue_11588/main.cpp delete mode 100644 lldb/test/expression_command/issue_11588/s11588.py delete mode 100644 lldb/test/expression_command/persistent_types/Makefile delete mode 100644 lldb/test/expression_command/persistent_types/TestPersistentTypes.py delete mode 100644 lldb/test/expression_command/persistent_types/main.c delete mode 100644 lldb/test/expression_command/persistent_variables/Makefile delete mode 100644 lldb/test/expression_command/persistent_variables/TestPersistentVariables.py delete mode 100644 lldb/test/expression_command/persistent_variables/main.c delete mode 100644 lldb/test/expression_command/radar_8638051/Makefile delete mode 100644 lldb/test/expression_command/radar_8638051/Test8638051.py delete mode 100644 lldb/test/expression_command/radar_8638051/main.c delete mode 100644 lldb/test/expression_command/radar_9531204/Makefile delete mode 100644 lldb/test/expression_command/radar_9531204/TestPrintfAfterUp.py delete mode 100644 lldb/test/expression_command/radar_9531204/main.c delete mode 100644 lldb/test/expression_command/radar_9673664/Makefile delete mode 100644 lldb/test/expression_command/radar_9673664/TestExprHelpExamples.py delete mode 100644 lldb/test/expression_command/radar_9673664/main.c delete mode 100644 lldb/test/expression_command/test/Makefile delete mode 100644 lldb/test/expression_command/test/TestExprs.py delete mode 100644 lldb/test/expression_command/test/TestExprs2.py delete mode 100644 lldb/test/expression_command/test/main.cpp delete mode 100644 lldb/test/expression_command/two-files/Makefile delete mode 100644 lldb/test/expression_command/two-files/TestObjCTypeQueryFromOtherCompileUnit.py delete mode 100644 lldb/test/expression_command/two-files/foo.m delete mode 100644 lldb/test/expression_command/two-files/main.m delete mode 100644 lldb/test/functionalities/abbreviation/Makefile delete mode 100644 lldb/test/functionalities/abbreviation/TestAbbreviations.py delete mode 100644 lldb/test/functionalities/abbreviation/TestCommonShortSpellings.py delete mode 100644 lldb/test/functionalities/abbreviation/change_prompt.lldb delete mode 100644 lldb/test/functionalities/abbreviation/main.cpp delete mode 100644 lldb/test/functionalities/alias/Makefile delete mode 100644 lldb/test/functionalities/alias/TestAliases.py delete mode 100644 lldb/test/functionalities/alias/main.cpp delete mode 100644 lldb/test/functionalities/archives/Makefile delete mode 100644 lldb/test/functionalities/archives/README delete mode 100644 lldb/test/functionalities/archives/TestBSDArchives.py delete mode 100644 lldb/test/functionalities/archives/a.c delete mode 100644 lldb/test/functionalities/archives/b.c delete mode 100644 lldb/test/functionalities/archives/main.c delete mode 100644 lldb/test/functionalities/backticks/TestBackticksWithoutATarget.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/a.c delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/b.c delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/bktptcmd.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_command/main.c delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_conditions/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_conditions/TestBreakpointConditions.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_conditions/main.c delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ids/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ids/TestBreakpointIDs.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ids/main.cpp delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ignore_count/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ignore_count/TestBreakpointIgnoreCount.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_ignore_count/main.c delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_locations/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_locations/TestBreakpointLocations.py delete mode 100644 lldb/test/functionalities/breakpoint/breakpoint_locations/main.c delete mode 100644 lldb/test/functionalities/breakpoint/inlined_breakpoints/Makefile delete mode 100644 lldb/test/functionalities/breakpoint/inlined_breakpoints/TestInlinedBreakpoints.py delete mode 100644 lldb/test/functionalities/breakpoint/inlined_breakpoints/basic_type.cpp delete mode 100644 lldb/test/functionalities/breakpoint/inlined_breakpoints/int.cpp delete mode 100644 lldb/test/functionalities/command_regex/TestCommandRegex.py delete mode 100644 lldb/test/functionalities/command_script/Makefile delete mode 100644 lldb/test/functionalities/command_script/TestCommandScript.py delete mode 100644 lldb/test/functionalities/command_script/bug11569.py delete mode 100644 lldb/test/functionalities/command_script/import/Makefile delete mode 100644 lldb/test/functionalities/command_script/import/TestImport.py delete mode 100644 lldb/test/functionalities/command_script/import/bar/bar.py delete mode 100644 lldb/test/functionalities/command_script/import/bar/barutil.py delete mode 100644 lldb/test/functionalities/command_script/import/dummymodule.py delete mode 100644 lldb/test/functionalities/command_script/import/foo/bar/foobar.py delete mode 100644 lldb/test/functionalities/command_script/import/foo/foo.py delete mode 100644 lldb/test/functionalities/command_script/import/foo/foo2.py delete mode 100644 lldb/test/functionalities/command_script/import/main.c delete mode 100644 lldb/test/functionalities/command_script/main.cpp delete mode 100644 lldb/test/functionalities/command_script/mysto.py delete mode 100644 lldb/test/functionalities/command_script/py_import delete mode 100644 lldb/test/functionalities/command_script/welcome.py delete mode 100644 lldb/test/functionalities/command_source/.lldb delete mode 100644 lldb/test/functionalities/command_source/TestCommandSource.py delete mode 100644 lldb/test/functionalities/command_source/my.py delete mode 100644 lldb/test/functionalities/completion/TestCompletion.py delete mode 100644 lldb/test/functionalities/conditional_break/.lldb delete mode 100644 lldb/test/functionalities/conditional_break/Makefile delete mode 100644 lldb/test/functionalities/conditional_break/TestConditionalBreak.py delete mode 100644 lldb/test/functionalities/conditional_break/conditional_break.py delete mode 100644 lldb/test/functionalities/conditional_break/main.c delete mode 100755 lldb/test/functionalities/connect_remote/EchoServer.py delete mode 100644 lldb/test/functionalities/connect_remote/TestConnectRemote.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-advanced/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-advanced/TestDataFormatterAdv.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-advanced/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-categories/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-categories/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-cpp/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-cpp/TestDataFormatterCpp.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-cpp/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-globals/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-globals/TestDataFormatterGlobals.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-globals/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-named-summaries/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-named-summaries/TestDataFormatterNamedSummaries.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-named-summaries/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-objc/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-objc/main.m delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-python-synth/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-python-synth/TestDataFormatterPythonSynth.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-python-synth/fooSynthProvider.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-python-synth/ftsp.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-python-synth/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-script/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-script/TestDataFormatterScript.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-script/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-skip-summary/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-skip-summary/TestDataFormatterSkipSummary.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-skip-summary/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-smart-array/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-smart-array/TestDataFormatterSmartArray.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-smart-array/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/list/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/list/TestDataFormatterLibcxxList.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/list/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/map/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/map/TestDataFormatterLibccMap.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/map/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/vector/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/vector/TestDataFormatterLibcxxVector.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libcxx/vector/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/list/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/list/TestDataFormatterStdList.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/list/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/TestDataFormatterStdMap.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/map/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/TestDataFormatterStdVector.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vector/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-synth/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-synth/TestDataFormatterSynth.py delete mode 100644 lldb/test/functionalities/data-formatter/data-formatter-synth/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10642615/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10642615/Test-rdar-10642615.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10642615/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10887661/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10887661/TestRdar10887661.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10887661/fooSynthProvider.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-10887661/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/rdar-3534688/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-3534688/TestFormattersOneIsSingular.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-3534688/main.m delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973865/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973865/Test-rdar-9973865.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973865/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973992/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973992/Test-rdar-9973992.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9973992/main.cpp delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9974002/Makefile delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9974002/Test-rdar-9974002.py delete mode 100644 lldb/test/functionalities/data-formatter/rdar-9974002/main.cpp delete mode 100644 lldb/test/functionalities/dead-strip/Makefile delete mode 100644 lldb/test/functionalities/dead-strip/TestDeadStrip.py delete mode 100644 lldb/test/functionalities/dead-strip/cmds.txt delete mode 100644 lldb/test/functionalities/dead-strip/main.c delete mode 100644 lldb/test/functionalities/embedded_interpreter/Makefile delete mode 100644 lldb/test/functionalities/embedded_interpreter/TestConvenienceVariables.py delete mode 100644 lldb/test/functionalities/embedded_interpreter/main.c delete mode 100644 lldb/test/functionalities/expr-doesnt-deadlock/Makefile delete mode 100644 lldb/test/functionalities/expr-doesnt-deadlock/TestExprDoesntBlock.py delete mode 100644 lldb/test/functionalities/expr-doesnt-deadlock/locking.c delete mode 100644 lldb/test/functionalities/inferior-changed/Makefile delete mode 100644 lldb/test/functionalities/inferior-changed/TestInferiorChanged.py delete mode 100644 lldb/test/functionalities/inferior-changed/main.c delete mode 100644 lldb/test/functionalities/inferior-changed/main2.c delete mode 100644 lldb/test/functionalities/inferior-crashing/Makefile delete mode 100644 lldb/test/functionalities/inferior-crashing/TestInferiorCrashing.py delete mode 100644 lldb/test/functionalities/inferior-crashing/main.c delete mode 100644 lldb/test/functionalities/load_unload/Makefile delete mode 100644 lldb/test/functionalities/load_unload/TestLoadUnload.py delete mode 100644 lldb/test/functionalities/load_unload/a.c delete mode 100644 lldb/test/functionalities/load_unload/b.c delete mode 100644 lldb/test/functionalities/load_unload/c.c delete mode 100644 lldb/test/functionalities/load_unload/cmds.txt delete mode 100644 lldb/test/functionalities/load_unload/d.c delete mode 100644 lldb/test/functionalities/load_unload/main.c delete mode 100644 lldb/test/functionalities/memory/read/Makefile delete mode 100644 lldb/test/functionalities/memory/read/TestMemoryRead.py delete mode 100644 lldb/test/functionalities/memory/read/main.cpp delete mode 100644 lldb/test/functionalities/non-overlapping-index-variable-i/Makefile delete mode 100644 lldb/test/functionalities/non-overlapping-index-variable-i/TestIndexVariable.py delete mode 100644 lldb/test/functionalities/non-overlapping-index-variable-i/main.cpp delete mode 100644 lldb/test/functionalities/platform/TestPlatformCommand.py delete mode 100644 lldb/test/functionalities/process_launch/Makefile delete mode 100644 lldb/test/functionalities/process_launch/TestProcessLaunch.py delete mode 100644 lldb/test/functionalities/process_launch/input-file.txt delete mode 100644 lldb/test/functionalities/process_launch/main.cpp delete mode 100644 lldb/test/functionalities/process_launch/print_cwd.cpp delete mode 100644 lldb/test/functionalities/register/Makefile delete mode 100644 lldb/test/functionalities/register/TestRegisters.py delete mode 100644 lldb/test/functionalities/register/main.cpp delete mode 100644 lldb/test/functionalities/return-value/Makefile delete mode 100644 lldb/test/functionalities/return-value/TestReturnValue.py delete mode 100644 lldb/test/functionalities/return-value/call-func.c delete mode 100644 lldb/test/functionalities/signal/Makefile delete mode 100644 lldb/test/functionalities/signal/TestSendSignal.py delete mode 100644 lldb/test/functionalities/signal/main.c delete mode 100644 lldb/test/functionalities/stop-hook/Makefile delete mode 100644 lldb/test/functionalities/stop-hook/TestStopHookCmd.py delete mode 100644 lldb/test/functionalities/stop-hook/TestStopHookMechanism.py delete mode 100644 lldb/test/functionalities/stop-hook/main.cpp delete mode 100644 lldb/test/functionalities/stop-hook/multiple_threads/Makefile delete mode 100644 lldb/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py delete mode 100644 lldb/test/functionalities/stop-hook/multiple_threads/main.cpp delete mode 100644 lldb/test/functionalities/target_command/Makefile delete mode 100644 lldb/test/functionalities/target_command/TestTargetCommand.py delete mode 100644 lldb/test/functionalities/target_command/a.c delete mode 100644 lldb/test/functionalities/target_command/b.c delete mode 100644 lldb/test/functionalities/target_command/c.c delete mode 100644 lldb/test/functionalities/target_command/globals.c delete mode 100644 lldb/test/functionalities/type_completion/Makefile delete mode 100644 lldb/test/functionalities/type_completion/TestTypeCompletion.py delete mode 100644 lldb/test/functionalities/type_completion/main.cpp delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchlocation/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchlocation/TestWatchLocation.py delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchlocation/main.cpp delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchpoint/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchpoint/TestMyFirstWatchpoint.py delete mode 100644 lldb/test/functionalities/watchpoint/hello_watchpoint/main.c delete mode 100644 lldb/test/functionalities/watchpoint/multiple_threads/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/multiple_threads/TestWatchpointMultipleThreads.py delete mode 100644 lldb/test/functionalities/watchpoint/multiple_threads/main.cpp delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/TestWatchpointCommands.py delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/condition/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/condition/TestWatchpointConditionCmd.py delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/condition/main.cpp delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_commands/main.c delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_set_command/Makefile delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_set_command/TestWatchLocationWithWatchSet.py delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_set_command/TestWatchpointSetErrorCases.py delete mode 100644 lldb/test/functionalities/watchpoint/watchpoint_set_command/main.cpp delete mode 100644 lldb/test/help/TestHelp.py delete mode 100644 lldb/test/lang/c/anonymous/Makefile delete mode 100644 lldb/test/lang/c/anonymous/TestAnonymous.py delete mode 100644 lldb/test/lang/c/anonymous/main.c delete mode 100644 lldb/test/lang/c/array_types/Makefile delete mode 100644 lldb/test/lang/c/array_types/TestArrayTypes.py delete mode 100644 lldb/test/lang/c/array_types/cmds.txt delete mode 100644 lldb/test/lang/c/array_types/main.c delete mode 100644 lldb/test/lang/c/bitfields/Makefile delete mode 100644 lldb/test/lang/c/bitfields/TestBitfields.py delete mode 100644 lldb/test/lang/c/bitfields/main.c delete mode 100644 lldb/test/lang/c/blocks/Makefile delete mode 100644 lldb/test/lang/c/blocks/TestBlocks.py delete mode 100644 lldb/test/lang/c/blocks/main.c delete mode 100644 lldb/test/lang/c/enum_types/Makefile delete mode 100644 lldb/test/lang/c/enum_types/TestEnumTypes.py delete mode 100644 lldb/test/lang/c/enum_types/main.c delete mode 100644 lldb/test/lang/c/forward/Makefile delete mode 100644 lldb/test/lang/c/forward/README.txt delete mode 100644 lldb/test/lang/c/forward/TestForwardDeclaration.py delete mode 100644 lldb/test/lang/c/forward/foo.c delete mode 100644 lldb/test/lang/c/forward/foo.h delete mode 100644 lldb/test/lang/c/forward/main.c delete mode 100644 lldb/test/lang/c/function_types/Makefile delete mode 100644 lldb/test/lang/c/function_types/TestFunctionTypes.py delete mode 100644 lldb/test/lang/c/function_types/main.c delete mode 100644 lldb/test/lang/c/global_variables/Makefile delete mode 100644 lldb/test/lang/c/global_variables/TestGlobalVariables.py delete mode 100644 lldb/test/lang/c/global_variables/a.c delete mode 100644 lldb/test/lang/c/global_variables/cmds.txt delete mode 100644 lldb/test/lang/c/global_variables/main.c delete mode 100644 lldb/test/lang/c/inlines/Makefile delete mode 100644 lldb/test/lang/c/inlines/inlines.c delete mode 100644 lldb/test/lang/c/inlines/inlines.h delete mode 100644 lldb/test/lang/c/recurse/Makefile delete mode 100644 lldb/test/lang/c/recurse/main.c delete mode 100644 lldb/test/lang/c/set_values/Makefile delete mode 100644 lldb/test/lang/c/set_values/TestSetValues.py delete mode 100644 lldb/test/lang/c/set_values/main.c delete mode 100644 lldb/test/lang/c/shared_lib/Makefile delete mode 100644 lldb/test/lang/c/shared_lib/TestSharedLib.py delete mode 100644 lldb/test/lang/c/shared_lib/foo.c delete mode 100644 lldb/test/lang/c/shared_lib/foo.h delete mode 100644 lldb/test/lang/c/shared_lib/main.c delete mode 100644 lldb/test/lang/c/stepping/Makefile delete mode 100644 lldb/test/lang/c/stepping/TestThreadStepping.py delete mode 100644 lldb/test/lang/c/stepping/main.c delete mode 100644 lldb/test/lang/c/strings/Makefile delete mode 100644 lldb/test/lang/c/strings/TestCStrings.py delete mode 100644 lldb/test/lang/c/strings/main.c delete mode 100644 lldb/test/lang/c/struct_types/Makefile delete mode 100644 lldb/test/lang/c/struct_types/TestStructTypes.py delete mode 100644 lldb/test/lang/c/struct_types/cmds.txt delete mode 100644 lldb/test/lang/c/struct_types/main.c delete mode 100644 lldb/test/lang/cpp/breakpoints/Makefile delete mode 100644 lldb/test/lang/cpp/breakpoints/TestCPPBreakpoints.py delete mode 100644 lldb/test/lang/cpp/breakpoints/nested.cpp delete mode 100644 lldb/test/lang/cpp/class_static/Makefile delete mode 100644 lldb/test/lang/cpp/class_static/TestStaticVariables.py delete mode 100644 lldb/test/lang/cpp/class_static/main.cpp delete mode 100644 lldb/test/lang/cpp/class_types/Makefile delete mode 100644 lldb/test/lang/cpp/class_types/TestClassTypes.py delete mode 100644 lldb/test/lang/cpp/class_types/TestClassTypesDisassembly.py delete mode 100644 lldb/test/lang/cpp/class_types/cmds.txt delete mode 100644 lldb/test/lang/cpp/class_types/main.cpp delete mode 100644 lldb/test/lang/cpp/dynamic-value/Makefile delete mode 100644 lldb/test/lang/cpp/dynamic-value/TestCppValueCast.py delete mode 100644 lldb/test/lang/cpp/dynamic-value/TestDynamicValue.py delete mode 100644 lldb/test/lang/cpp/dynamic-value/pass-to-base.cpp delete mode 100644 lldb/test/lang/cpp/dynamic-value/sbvalue-cast.cpp delete mode 100644 lldb/test/lang/cpp/exceptions/Makefile delete mode 100644 lldb/test/lang/cpp/exceptions/TestCPPExceptionBreakpoints.py delete mode 100644 lldb/test/lang/cpp/exceptions/exceptions.cpp delete mode 100644 lldb/test/lang/cpp/namespace/Makefile delete mode 100644 lldb/test/lang/cpp/namespace/TestNamespace.py delete mode 100644 lldb/test/lang/cpp/namespace/cmds.txt delete mode 100644 lldb/test/lang/cpp/namespace/main.cpp delete mode 100644 lldb/test/lang/cpp/signed_types/Makefile delete mode 100644 lldb/test/lang/cpp/signed_types/TestSignedTypes.py delete mode 100644 lldb/test/lang/cpp/signed_types/main.cpp delete mode 100644 lldb/test/lang/cpp/static_methods/Makefile delete mode 100644 lldb/test/lang/cpp/static_methods/TestCPPStaticMethods.py delete mode 100644 lldb/test/lang/cpp/static_methods/main.cpp delete mode 100644 lldb/test/lang/cpp/stl/Makefile delete mode 100644 lldb/test/lang/cpp/stl/TestSTL.py delete mode 100644 lldb/test/lang/cpp/stl/TestStdCXXDisassembly.py delete mode 100644 lldb/test/lang/cpp/stl/cmds.txt delete mode 100644 lldb/test/lang/cpp/stl/main.cpp delete mode 100644 lldb/test/lang/cpp/this/Makefile delete mode 100644 lldb/test/lang/cpp/this/TestCPPThis.py delete mode 100644 lldb/test/lang/cpp/this/main.cpp delete mode 100644 lldb/test/lang/cpp/unique-types/Makefile delete mode 100644 lldb/test/lang/cpp/unique-types/TestUniqueTypes.py delete mode 100644 lldb/test/lang/cpp/unique-types/main.cpp delete mode 100644 lldb/test/lang/cpp/unsigned_types/Makefile delete mode 100644 lldb/test/lang/cpp/unsigned_types/TestUnsignedTypes.py delete mode 100644 lldb/test/lang/cpp/unsigned_types/main.cpp delete mode 100644 lldb/test/lang/cpp/virtual/Makefile delete mode 100644 lldb/test/lang/cpp/virtual/TestVirtual.py delete mode 100644 lldb/test/lang/cpp/virtual/main.cpp delete mode 100644 lldb/test/lang/objc/forward-decl/Container.h delete mode 100644 lldb/test/lang/objc/forward-decl/Container.m delete mode 100644 lldb/test/lang/objc/forward-decl/Makefile delete mode 100644 lldb/test/lang/objc/forward-decl/TestForwardDecl.py delete mode 100644 lldb/test/lang/objc/forward-decl/main.m delete mode 100644 lldb/test/lang/objc/foundation/Makefile delete mode 100644 lldb/test/lang/objc/foundation/TestConstStrings.py delete mode 100644 lldb/test/lang/objc/foundation/TestFoundationDisassembly.py delete mode 100644 lldb/test/lang/objc/foundation/TestObjCMethods.py delete mode 100644 lldb/test/lang/objc/foundation/TestObjCMethods2.py delete mode 100644 lldb/test/lang/objc/foundation/TestObjectDescriptionAPI.py delete mode 100644 lldb/test/lang/objc/foundation/TestSymbolTable.py delete mode 100644 lldb/test/lang/objc/foundation/const-strings.m delete mode 100644 lldb/test/lang/objc/foundation/main.m delete mode 100644 lldb/test/lang/objc/foundation/my-base.h delete mode 100644 lldb/test/lang/objc/foundation/my-base.m delete mode 100644 lldb/test/lang/objc/hidden-ivars/InternalDefiner.h delete mode 100644 lldb/test/lang/objc/hidden-ivars/InternalDefiner.m delete mode 100644 lldb/test/lang/objc/hidden-ivars/Makefile delete mode 100644 lldb/test/lang/objc/hidden-ivars/TestHiddenIvars.py delete mode 100644 lldb/test/lang/objc/hidden-ivars/main.m delete mode 100644 lldb/test/lang/objc/objc-builtin-types/Makefile delete mode 100644 lldb/test/lang/objc/objc-builtin-types/TestObjCBuiltinTypes.py delete mode 100644 lldb/test/lang/objc/objc-builtin-types/main.cpp delete mode 100644 lldb/test/lang/objc/objc-checker/Makefile delete mode 100644 lldb/test/lang/objc/objc-checker/TestObjCCheckers.py delete mode 100644 lldb/test/lang/objc/objc-checker/main.m delete mode 100644 lldb/test/lang/objc/objc-class-method/Makefile delete mode 100644 lldb/test/lang/objc/objc-class-method/TestObjCClassMethod.py delete mode 100644 lldb/test/lang/objc/objc-class-method/class.m delete mode 100644 lldb/test/lang/objc/objc-dynamic-value/Makefile delete mode 100644 lldb/test/lang/objc/objc-dynamic-value/TestObjCDynamicValue.py delete mode 100644 lldb/test/lang/objc/objc-dynamic-value/dynamic-value.m delete mode 100644 lldb/test/lang/objc/objc-ivar-offsets/Makefile delete mode 100644 lldb/test/lang/objc/objc-ivar-offsets/TestObjCIvarOffsets.py delete mode 100644 lldb/test/lang/objc/objc-ivar-offsets/main.m delete mode 100644 lldb/test/lang/objc/objc-ivar-offsets/objc-ivar-offsets.h delete mode 100644 lldb/test/lang/objc/objc-ivar-offsets/objc-ivar-offsets.m delete mode 100644 lldb/test/lang/objc/objc-new-syntax/Makefile delete mode 100644 lldb/test/lang/objc/objc-new-syntax/TestObjCNewSyntax.py delete mode 100644 lldb/test/lang/objc/objc-new-syntax/main.m delete mode 100644 lldb/test/lang/objc/objc-optimized/Makefile delete mode 100644 lldb/test/lang/objc/objc-optimized/TestObjcOptimized.py delete mode 100644 lldb/test/lang/objc/objc-optimized/main.m delete mode 100644 lldb/test/lang/objc/objc-property/Makefile delete mode 100644 lldb/test/lang/objc/objc-property/TestObjCProperty.py delete mode 100644 lldb/test/lang/objc/objc-property/main.m delete mode 100644 lldb/test/lang/objc/objc-static-method/Makefile delete mode 100644 lldb/test/lang/objc/objc-static-method/TestObjCStaticMethod.py delete mode 100644 lldb/test/lang/objc/objc-static-method/static.m delete mode 100644 lldb/test/lang/objc/objc-stepping/Makefile delete mode 100644 lldb/test/lang/objc/objc-stepping/TestObjCStepping.py delete mode 100644 lldb/test/lang/objc/objc-stepping/stepping-tests.m delete mode 100644 lldb/test/lang/objc/print-obj/Makefile delete mode 100644 lldb/test/lang/objc/print-obj/TestPrintObj.py delete mode 100644 lldb/test/lang/objc/print-obj/blocked.m delete mode 100644 lldb/test/lang/objc/radar-9691614/Makefile delete mode 100644 lldb/test/lang/objc/radar-9691614/TestObjCMethodReturningBOOL.py delete mode 100644 lldb/test/lang/objc/radar-9691614/main.m delete mode 100644 lldb/test/lang/objc/rdar-10967107/Makefile delete mode 100644 lldb/test/lang/objc/rdar-10967107/TestRdar10967107.py delete mode 100644 lldb/test/lang/objc/rdar-10967107/main.m delete mode 100644 lldb/test/lang/objc/real-definition/Bar.h delete mode 100644 lldb/test/lang/objc/real-definition/Bar.m delete mode 100644 lldb/test/lang/objc/real-definition/Foo.h delete mode 100644 lldb/test/lang/objc/real-definition/Foo.m delete mode 100644 lldb/test/lang/objc/real-definition/Makefile delete mode 100644 lldb/test/lang/objc/real-definition/TestRealDefinition.py delete mode 100644 lldb/test/lang/objc/real-definition/main.m delete mode 100644 lldb/test/lang/objc/sample/Makefile delete mode 100644 lldb/test/lang/objc/sample/main.m delete mode 100644 lldb/test/lang/objc/self/Makefile delete mode 100644 lldb/test/lang/objc/self/TestObjCSelf.py delete mode 100644 lldb/test/lang/objc/self/main.m delete mode 100644 lldb/test/lldbbench.py delete mode 100644 lldb/test/lldbtest.py delete mode 100644 lldb/test/lldbutil.py delete mode 100644 lldb/test/logging/Makefile delete mode 100644 lldb/test/logging/TestLogging.py delete mode 100644 lldb/test/logging/main.cpp delete mode 100644 lldb/test/macosx/debug-info/apple_types/Makefile delete mode 100644 lldb/test/macosx/debug-info/apple_types/TestAppleTypesIsProduced.py delete mode 100644 lldb/test/macosx/debug-info/apple_types/main.c delete mode 100644 lldb/test/macosx/order/Makefile delete mode 100644 lldb/test/macosx/order/TestOrderFile.py delete mode 100644 lldb/test/macosx/order/cmds.txt delete mode 100644 lldb/test/macosx/order/main.c delete mode 100644 lldb/test/macosx/order/order-file delete mode 100644 lldb/test/macosx/universal/Makefile delete mode 100644 lldb/test/macosx/universal/TestUniversal.py delete mode 100644 lldb/test/macosx/universal/main.c delete mode 100644 lldb/test/make/Makefile.rules delete mode 100644 lldb/test/pexpect-2.4/ANSI.py delete mode 100644 lldb/test/pexpect-2.4/FSM.py delete mode 100644 lldb/test/pexpect-2.4/INSTALL delete mode 100644 lldb/test/pexpect-2.4/LICENSE delete mode 100644 lldb/test/pexpect-2.4/PKG-INFO delete mode 100644 lldb/test/pexpect-2.4/README delete mode 100644 lldb/test/pexpect-2.4/doc/clean.css delete mode 100644 lldb/test/pexpect-2.4/doc/email.png delete mode 100644 lldb/test/pexpect-2.4/doc/examples.html delete mode 100644 lldb/test/pexpect-2.4/doc/index.html delete mode 100644 lldb/test/pexpect-2.4/doc/index.template.html delete mode 100644 lldb/test/pexpect-2.4/examples/README delete mode 100755 lldb/test/pexpect-2.4/examples/astat.py delete mode 100755 lldb/test/pexpect-2.4/examples/bd_client.py delete mode 100755 lldb/test/pexpect-2.4/examples/bd_serv.py delete mode 100755 lldb/test/pexpect-2.4/examples/cgishell.cgi delete mode 100755 lldb/test/pexpect-2.4/examples/chess.py delete mode 100755 lldb/test/pexpect-2.4/examples/chess2.py delete mode 100755 lldb/test/pexpect-2.4/examples/chess3.py delete mode 100755 lldb/test/pexpect-2.4/examples/df.py delete mode 100755 lldb/test/pexpect-2.4/examples/fix_cvs_files.py delete mode 100755 lldb/test/pexpect-2.4/examples/ftp.py delete mode 100755 lldb/test/pexpect-2.4/examples/hive.py delete mode 100755 lldb/test/pexpect-2.4/examples/monitor.py delete mode 100755 lldb/test/pexpect-2.4/examples/passmass.py delete mode 100755 lldb/test/pexpect-2.4/examples/python.py delete mode 100755 lldb/test/pexpect-2.4/examples/rippy.py delete mode 100755 lldb/test/pexpect-2.4/examples/script.py delete mode 100755 lldb/test/pexpect-2.4/examples/ssh_session.py delete mode 100755 lldb/test/pexpect-2.4/examples/ssh_tunnel.py delete mode 100755 lldb/test/pexpect-2.4/examples/sshls.py delete mode 100644 lldb/test/pexpect-2.4/examples/table_test.html delete mode 100755 lldb/test/pexpect-2.4/examples/topip.py delete mode 100755 lldb/test/pexpect-2.4/examples/uptime.py delete mode 100644 lldb/test/pexpect-2.4/fdpexpect.py delete mode 100644 lldb/test/pexpect-2.4/pexpect.py delete mode 100644 lldb/test/pexpect-2.4/pxssh.py delete mode 100644 lldb/test/pexpect-2.4/screen.py delete mode 100755 lldb/test/pexpect-2.4/setup.py delete mode 100644 lldb/test/plugins/builder_base.py delete mode 100644 lldb/test/plugins/builder_darwin.py delete mode 100644 lldb/test/plugins/builder_linux2.py delete mode 100644 lldb/test/python_api/debugger/TestDebuggerAPI.py delete mode 100644 lldb/test/python_api/default-constructor/TestDefaultConstructorForAPIObjects.py delete mode 100644 lldb/test/python_api/default-constructor/sb_address.py delete mode 100644 lldb/test/python_api/default-constructor/sb_block.py delete mode 100644 lldb/test/python_api/default-constructor/sb_breakpoint.py delete mode 100644 lldb/test/python_api/default-constructor/sb_breakpointlocation.py delete mode 100644 lldb/test/python_api/default-constructor/sb_broadcaster.py delete mode 100644 lldb/test/python_api/default-constructor/sb_communication.py delete mode 100644 lldb/test/python_api/default-constructor/sb_compileunit.py delete mode 100644 lldb/test/python_api/default-constructor/sb_debugger.py delete mode 100644 lldb/test/python_api/default-constructor/sb_error.py delete mode 100644 lldb/test/python_api/default-constructor/sb_event.py delete mode 100644 lldb/test/python_api/default-constructor/sb_filespec.py delete mode 100644 lldb/test/python_api/default-constructor/sb_frame.py delete mode 100644 lldb/test/python_api/default-constructor/sb_function.py delete mode 100644 lldb/test/python_api/default-constructor/sb_inputreader.py delete mode 100644 lldb/test/python_api/default-constructor/sb_instruction.py delete mode 100644 lldb/test/python_api/default-constructor/sb_instructionlist.py delete mode 100644 lldb/test/python_api/default-constructor/sb_lineentry.py delete mode 100644 lldb/test/python_api/default-constructor/sb_listener.py delete mode 100644 lldb/test/python_api/default-constructor/sb_module.py delete mode 100644 lldb/test/python_api/default-constructor/sb_process.py delete mode 100644 lldb/test/python_api/default-constructor/sb_section.py delete mode 100644 lldb/test/python_api/default-constructor/sb_stringlist.py delete mode 100644 lldb/test/python_api/default-constructor/sb_symbol.py delete mode 100644 lldb/test/python_api/default-constructor/sb_symbolcontext.py delete mode 100644 lldb/test/python_api/default-constructor/sb_target.py delete mode 100644 lldb/test/python_api/default-constructor/sb_thread.py delete mode 100644 lldb/test/python_api/default-constructor/sb_type.py delete mode 100644 lldb/test/python_api/default-constructor/sb_value.py delete mode 100644 lldb/test/python_api/default-constructor/sb_valuelist.py delete mode 100644 lldb/test/python_api/default-constructor/sb_watchpoint.py delete mode 100644 lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py delete mode 100644 lldb/test/python_api/disassemble-raw-data/TestDisassemble_VST1_64.py delete mode 100644 lldb/test/python_api/event/Makefile delete mode 100644 lldb/test/python_api/event/TestEvents.py delete mode 100644 lldb/test/python_api/event/main.c delete mode 100644 lldb/test/python_api/formatters/Makefile delete mode 100644 lldb/test/python_api/formatters/TestFormattersSBAPI.py delete mode 100644 lldb/test/python_api/formatters/jas_synth.py delete mode 100644 lldb/test/python_api/formatters/main.cpp delete mode 100644 lldb/test/python_api/frame/Makefile delete mode 100644 lldb/test/python_api/frame/TestFrames.py delete mode 100644 lldb/test/python_api/frame/inlines/Makefile delete mode 100644 lldb/test/python_api/frame/inlines/TestInlinedFrame.py delete mode 100644 lldb/test/python_api/frame/inlines/inlines.c delete mode 100644 lldb/test/python_api/frame/inlines/inlines.h delete mode 100644 lldb/test/python_api/frame/main.c delete mode 100644 lldb/test/python_api/function_symbol/Makefile delete mode 100644 lldb/test/python_api/function_symbol/TestDisasmAPI.py delete mode 100644 lldb/test/python_api/function_symbol/TestSymbolAPI.py delete mode 100644 lldb/test/python_api/function_symbol/main.c delete mode 100644 lldb/test/python_api/hello_world/Makefile delete mode 100644 lldb/test/python_api/hello_world/TestHelloWorld.py delete mode 100644 lldb/test/python_api/hello_world/main.c delete mode 100644 lldb/test/python_api/interpreter/Makefile delete mode 100644 lldb/test/python_api/interpreter/TestCommandInterpreterAPI.py delete mode 100644 lldb/test/python_api/interpreter/main.c delete mode 100644 lldb/test/python_api/lldbutil/frame/Makefile delete mode 100644 lldb/test/python_api/lldbutil/frame/TestFrameUtils.py delete mode 100644 lldb/test/python_api/lldbutil/frame/main.c delete mode 100644 lldb/test/python_api/lldbutil/iter/Makefile delete mode 100644 lldb/test/python_api/lldbutil/iter/TestLLDBIterator.py delete mode 100644 lldb/test/python_api/lldbutil/iter/TestRegistersIterator.py delete mode 100644 lldb/test/python_api/lldbutil/iter/main.cpp delete mode 100644 lldb/test/python_api/lldbutil/process/Makefile delete mode 100644 lldb/test/python_api/lldbutil/process/TestPrintStackTraces.py delete mode 100644 lldb/test/python_api/lldbutil/process/main.cpp delete mode 100644 lldb/test/python_api/module_section/Makefile delete mode 100644 lldb/test/python_api/module_section/TestModuleAndSection.py delete mode 100644 lldb/test/python_api/module_section/b.cpp delete mode 100644 lldb/test/python_api/module_section/c.cpp delete mode 100644 lldb/test/python_api/module_section/main.cpp delete mode 100644 lldb/test/python_api/process/Makefile delete mode 100644 lldb/test/python_api/process/TestProcessAPI.py delete mode 100644 lldb/test/python_api/process/io/Makefile delete mode 100644 lldb/test/python_api/process/io/TestProcessIO.py delete mode 100644 lldb/test/python_api/process/io/main.c delete mode 100644 lldb/test/python_api/process/main.cpp delete mode 100644 lldb/test/python_api/sbdata/Makefile delete mode 100644 lldb/test/python_api/sbdata/TestSBData.py delete mode 100644 lldb/test/python_api/sbdata/main.cpp delete mode 100644 lldb/test/python_api/symbol-context/Makefile delete mode 100644 lldb/test/python_api/symbol-context/TestSymbolContext.py delete mode 100644 lldb/test/python_api/symbol-context/main.c delete mode 100644 lldb/test/python_api/target/Makefile delete mode 100644 lldb/test/python_api/target/TestTargetAPI.py delete mode 100644 lldb/test/python_api/target/main.c delete mode 100644 lldb/test/python_api/thread/Makefile delete mode 100644 lldb/test/python_api/thread/TestThreadAPI.py delete mode 100644 lldb/test/python_api/thread/main.cpp delete mode 100644 lldb/test/python_api/thread/main2.cpp delete mode 100644 lldb/test/python_api/type/Makefile delete mode 100644 lldb/test/python_api/type/TestTypeList.py delete mode 100644 lldb/test/python_api/type/main.cpp delete mode 100644 lldb/test/python_api/value/Makefile delete mode 100644 lldb/test/python_api/value/TestValueAPI.py delete mode 100644 lldb/test/python_api/value/change_values/Makefile delete mode 100644 lldb/test/python_api/value/change_values/TestChangeValueAPI.py delete mode 100644 lldb/test/python_api/value/change_values/main.c delete mode 100644 lldb/test/python_api/value/linked_list/Makefile delete mode 100644 lldb/test/python_api/value/linked_list/TestValueAPILinkedList.py delete mode 100644 lldb/test/python_api/value/linked_list/main.cpp delete mode 100644 lldb/test/python_api/value/main.c delete mode 100644 lldb/test/python_api/watchpoint/Makefile delete mode 100644 lldb/test/python_api/watchpoint/TestSetWatchpoint.py delete mode 100644 lldb/test/python_api/watchpoint/TestWatchpointIgnoreCount.py delete mode 100644 lldb/test/python_api/watchpoint/TestWatchpointIter.py delete mode 100644 lldb/test/python_api/watchpoint/condition/Makefile delete mode 100644 lldb/test/python_api/watchpoint/condition/TestWatchpointConditionAPI.py delete mode 100644 lldb/test/python_api/watchpoint/condition/main.cpp delete mode 100644 lldb/test/python_api/watchpoint/main.c delete mode 100644 lldb/test/python_api/watchpoint/watchlocation/Makefile delete mode 100644 lldb/test/python_api/watchpoint/watchlocation/TestSetWatchlocation.py delete mode 100644 lldb/test/python_api/watchpoint/watchlocation/TestTargetWatchAddress.py delete mode 100644 lldb/test/python_api/watchpoint/watchlocation/main.cpp delete mode 100755 lldb/test/redo.py delete mode 100644 lldb/test/settings/Makefile delete mode 100644 lldb/test/settings/TestSettings.py delete mode 100644 lldb/test/settings/main.cpp delete mode 100644 lldb/test/source-manager/Makefile delete mode 100644 lldb/test/source-manager/TestSourceManager.py delete mode 100644 lldb/test/source-manager/main.c delete mode 100644 lldb/test/terminal/TestSTTYBeforeAndAfter.py delete mode 100644 lldb/test/types/AbstractBase.py delete mode 100644 lldb/test/types/HideTestFailures.py delete mode 100644 lldb/test/types/Makefile delete mode 100644 lldb/test/types/TestFloatTypes.py delete mode 100644 lldb/test/types/TestFloatTypesExpr.py delete mode 100644 lldb/test/types/TestIntegerTypes.py delete mode 100644 lldb/test/types/TestIntegerTypesExpr.py delete mode 100644 lldb/test/types/basic_type.cpp delete mode 100644 lldb/test/types/char.cpp delete mode 100644 lldb/test/types/double.cpp delete mode 100644 lldb/test/types/float.cpp delete mode 100644 lldb/test/types/int.cpp delete mode 100644 lldb/test/types/long.cpp delete mode 100644 lldb/test/types/long_long.cpp delete mode 100644 lldb/test/types/short.cpp delete mode 100644 lldb/test/types/unsigned_char.cpp delete mode 100644 lldb/test/types/unsigned_int.cpp delete mode 100644 lldb/test/types/unsigned_long.cpp delete mode 100644 lldb/test/types/unsigned_long_long.cpp delete mode 100644 lldb/test/types/unsigned_short.cpp delete mode 100644 lldb/test/unittest2/__init__.py delete mode 100644 lldb/test/unittest2/__main__.py delete mode 100644 lldb/test/unittest2/case.py delete mode 100644 lldb/test/unittest2/collector.py delete mode 100644 lldb/test/unittest2/compatibility.py delete mode 100644 lldb/test/unittest2/loader.py delete mode 100644 lldb/test/unittest2/main.py delete mode 100644 lldb/test/unittest2/result.py delete mode 100644 lldb/test/unittest2/runner.py delete mode 100644 lldb/test/unittest2/signals.py delete mode 100644 lldb/test/unittest2/suite.py delete mode 100644 lldb/test/unittest2/test/__init__.py delete mode 100644 lldb/test/unittest2/test/dummy.py delete mode 100644 lldb/test/unittest2/test/support.py delete mode 100644 lldb/test/unittest2/test/test_assertions.py delete mode 100644 lldb/test/unittest2/test/test_break.py delete mode 100644 lldb/test/unittest2/test/test_case.py delete mode 100644 lldb/test/unittest2/test/test_discovery.py delete mode 100644 lldb/test/unittest2/test/test_functiontestcase.py delete mode 100644 lldb/test/unittest2/test/test_loader.py delete mode 100644 lldb/test/unittest2/test/test_new_tests.py delete mode 100644 lldb/test/unittest2/test/test_program.py delete mode 100644 lldb/test/unittest2/test/test_result.py delete mode 100644 lldb/test/unittest2/test/test_runner.py delete mode 100644 lldb/test/unittest2/test/test_setups.py delete mode 100644 lldb/test/unittest2/test/test_skipping.py delete mode 100644 lldb/test/unittest2/test/test_suite.py delete mode 100644 lldb/test/unittest2/test/test_unittest2_with.py delete mode 100644 lldb/test/unittest2/util.py delete mode 100644 lldb/test/warnings/uuid/Makefile delete mode 100644 lldb/test/warnings/uuid/TestUUIDMismatchWanring.py delete mode 100644 lldb/test/warnings/uuid/main.cpp.template delete mode 100644 lldb/tools/Makefile delete mode 100644 lldb/tools/darwin-debug/darwin-debug.cpp delete mode 100644 lldb/tools/darwin-threads/examine-threads.c delete mode 100644 lldb/tools/debugserver/debugnub-exports delete mode 100644 lldb/tools/debugserver/debugserver.xcodeproj/project.pbxproj delete mode 100644 lldb/tools/debugserver/debugserver.xcodeproj/project.xcworkspace/contents.xcworkspacedata delete mode 100644 lldb/tools/debugserver/debugserver.xcodeproj/xcshareddata/xcschemes/debugserver.xcscheme delete mode 100644 lldb/tools/debugserver/resources/lldb-debugserver-Info.plist delete mode 100644 lldb/tools/debugserver/scripts/dbgnub-config.pl delete mode 100644 lldb/tools/debugserver/source/ARM_DWARF_Registers.h delete mode 100644 lldb/tools/debugserver/source/ARM_GCC_Registers.h delete mode 100644 lldb/tools/debugserver/source/ChangeLog delete mode 100644 lldb/tools/debugserver/source/DNB.cpp delete mode 100644 lldb/tools/debugserver/source/DNB.h delete mode 100644 lldb/tools/debugserver/source/DNBArch.cpp delete mode 100644 lldb/tools/debugserver/source/DNBArch.h delete mode 100644 lldb/tools/debugserver/source/DNBBreakpoint.cpp delete mode 100644 lldb/tools/debugserver/source/DNBBreakpoint.h delete mode 100644 lldb/tools/debugserver/source/DNBDataRef.cpp delete mode 100644 lldb/tools/debugserver/source/DNBDataRef.h delete mode 100644 lldb/tools/debugserver/source/DNBDefs.h delete mode 100644 lldb/tools/debugserver/source/DNBError.cpp delete mode 100644 lldb/tools/debugserver/source/DNBError.h delete mode 100644 lldb/tools/debugserver/source/DNBLog.cpp delete mode 100644 lldb/tools/debugserver/source/DNBLog.h delete mode 100644 lldb/tools/debugserver/source/DNBRegisterInfo.cpp delete mode 100644 lldb/tools/debugserver/source/DNBRegisterInfo.h delete mode 100644 lldb/tools/debugserver/source/DNBRuntimeAction.h delete mode 100644 lldb/tools/debugserver/source/DNBThreadResumeActions.cpp delete mode 100644 lldb/tools/debugserver/source/DNBThreadResumeActions.h delete mode 100644 lldb/tools/debugserver/source/DNBTimer.h delete mode 100644 lldb/tools/debugserver/source/FunctionProfiler.cpp delete mode 100644 lldb/tools/debugserver/source/FunctionProfiler.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFBundle.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFBundle.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFData.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFData.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFString.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFString.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/CFUtils.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/HasAVX.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/HasAVX.s delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachDYLD.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachDYLD.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachException.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachException.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachProcess.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachProcess.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachTask.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachTask.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachThread.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachThread.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachThreadList.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachVMMemory.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachVMRegion.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/MachVMRegion.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/arm/DNBArchImpl.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/dbgnub-mig.defs delete mode 100644 lldb/tools/debugserver/source/MacOSX/i386/DNBArchImplI386.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/i386/DNBArchImplI386.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/i386/MachRegisterStatesI386.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/ppc/DNBArchImpl.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/ppc/DNBArchImpl.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/stack_logging.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.cpp delete mode 100644 lldb/tools/debugserver/source/MacOSX/x86_64/DNBArchImplX86_64.h delete mode 100644 lldb/tools/debugserver/source/MacOSX/x86_64/MachRegisterStatesX86_64.h delete mode 100644 lldb/tools/debugserver/source/PThreadCondition.h delete mode 100644 lldb/tools/debugserver/source/PThreadEvent.cpp delete mode 100644 lldb/tools/debugserver/source/PThreadEvent.h delete mode 100644 lldb/tools/debugserver/source/PThreadMutex.cpp delete mode 100644 lldb/tools/debugserver/source/PThreadMutex.h delete mode 100644 lldb/tools/debugserver/source/ProfileObjectiveC.cpp delete mode 100644 lldb/tools/debugserver/source/ProfileObjectiveC.h delete mode 100644 lldb/tools/debugserver/source/PseudoTerminal.cpp delete mode 100644 lldb/tools/debugserver/source/PseudoTerminal.h delete mode 100644 lldb/tools/debugserver/source/RNBContext.cpp delete mode 100644 lldb/tools/debugserver/source/RNBContext.h delete mode 100644 lldb/tools/debugserver/source/RNBDefs.h delete mode 100644 lldb/tools/debugserver/source/RNBRemote.cpp delete mode 100644 lldb/tools/debugserver/source/RNBRemote.h delete mode 100644 lldb/tools/debugserver/source/RNBServices.cpp delete mode 100644 lldb/tools/debugserver/source/RNBServices.h delete mode 100644 lldb/tools/debugserver/source/RNBSocket.cpp delete mode 100644 lldb/tools/debugserver/source/RNBSocket.h delete mode 100644 lldb/tools/debugserver/source/SysSignal.cpp delete mode 100644 lldb/tools/debugserver/source/SysSignal.h delete mode 100644 lldb/tools/debugserver/source/TTYState.cpp delete mode 100644 lldb/tools/debugserver/source/TTYState.h delete mode 100644 lldb/tools/debugserver/source/com.apple.debugserver-secure.plist delete mode 100644 lldb/tools/debugserver/source/com.apple.debugserver.applist.plist delete mode 100644 lldb/tools/debugserver/source/com.apple.debugserver.plist delete mode 100644 lldb/tools/debugserver/source/debugserver-entitlements.plist delete mode 100644 lldb/tools/debugserver/source/debugserver.cpp delete mode 100644 lldb/tools/driver/Driver.cpp delete mode 100644 lldb/tools/driver/Driver.h delete mode 100644 lldb/tools/driver/IOChannel.cpp delete mode 100644 lldb/tools/driver/IOChannel.h delete mode 100644 lldb/tools/driver/Makefile delete mode 100644 lldb/tools/driver/lldb-Info.plist delete mode 100644 lldb/tools/install-headers/Makefile delete mode 100644 lldb/tools/lldb-platform/Makefile delete mode 100644 lldb/tools/lldb-platform/lldb-platform.cpp delete mode 100755 lldb/utils/git-svn/convert.py delete mode 100755 lldb/utils/misc/grep-svn-log.py delete mode 100644 lldb/utils/test/README-disasm delete mode 100644 lldb/utils/test/README-lldb-disasm delete mode 100644 lldb/utils/test/README-run-until-faulted delete mode 100755 lldb/utils/test/disasm.py delete mode 100755 lldb/utils/test/lldb-disasm.py delete mode 100755 lldb/utils/test/llvm-mc-shell.py delete mode 100644 lldb/utils/test/main.c delete mode 100755 lldb/utils/test/ras.py delete mode 100755 lldb/utils/test/run-dis.py delete mode 100755 lldb/utils/test/run-until-faulted.py delete mode 100755 lldb/www/architecture.html delete mode 100755 lldb/www/build.html delete mode 100755 lldb/www/customization.html delete mode 100755 lldb/www/docs.html delete mode 100755 lldb/www/download.html delete mode 100755 lldb/www/faq.html delete mode 100755 lldb/www/features.html delete mode 100755 lldb/www/formats.html delete mode 100755 lldb/www/goals.html delete mode 100755 lldb/www/index.html delete mode 100755 lldb/www/lldb-gdb.html delete mode 100755 lldb/www/python-reference.html delete mode 100755 lldb/www/scripting.html delete mode 100644 lldb/www/sidebar.incl delete mode 100755 lldb/www/status.html delete mode 100755 lldb/www/style.css delete mode 100755 lldb/www/tutorial.html delete mode 100755 lldb/www/varformats.html delete mode 100644 polly/CMakeLists.txt delete mode 100644 polly/CREDITS.txt delete mode 100644 polly/LICENSE.txt delete mode 100644 polly/Makefile delete mode 100755 polly/Makefile.common.in delete mode 100755 polly/Makefile.config.in delete mode 100644 polly/README delete mode 100755 polly/autoconf/AutoRegen.sh delete mode 100644 polly/autoconf/LICENSE.TXT delete mode 100644 polly/autoconf/aclocal.m4 delete mode 100644 polly/autoconf/config.guess delete mode 100644 polly/autoconf/config.sub delete mode 100644 polly/autoconf/configure.ac delete mode 100644 polly/autoconf/configure.bak delete mode 100755 polly/autoconf/m4/find_lib_and_headers.m4 delete mode 100644 polly/cmake/FindCloog.cmake delete mode 100644 polly/cmake/FindGmp.cmake delete mode 100644 polly/cmake/FindIsl.cmake delete mode 100644 polly/cmake/FindOpenScop.cmake delete mode 100644 polly/cmake/FindSCoPLib.cmake delete mode 100755 polly/configure delete mode 100644 polly/docs/index.html delete mode 100644 polly/docs/polly.png delete mode 100644 polly/docs/polly.svg delete mode 100644 polly/include/CMakeLists.txt delete mode 100644 polly/include/polly/CMakeLists.txt delete mode 100644 polly/include/polly/Cloog.h delete mode 100644 polly/include/polly/CodeGeneration.h delete mode 100755 polly/include/polly/Config/config.h.cmake delete mode 100644 polly/include/polly/Config/config.h.in delete mode 100755 polly/include/polly/Dependences.h delete mode 100644 polly/include/polly/LinkAllPasses.h delete mode 100644 polly/include/polly/LoopGenerators.h delete mode 100755 polly/include/polly/MayAliasSet.h delete mode 100644 polly/include/polly/RegisterPasses.h delete mode 100644 polly/include/polly/ScheduleOptimizer.h delete mode 100755 polly/include/polly/ScopDetection.h delete mode 100755 polly/include/polly/ScopInfo.h delete mode 100644 polly/include/polly/ScopLib.h delete mode 100755 polly/include/polly/ScopPass.h delete mode 100755 polly/include/polly/Support/GICHelper.h delete mode 100755 polly/include/polly/Support/SCEVValidator.h delete mode 100755 polly/include/polly/Support/ScopHelper.h delete mode 100755 polly/include/polly/TempScopInfo.h delete mode 100644 polly/lib/Analysis/CMakeLists.txt delete mode 100644 polly/lib/Analysis/Dependences.cpp delete mode 100755 polly/lib/Analysis/Makefile delete mode 100644 polly/lib/Analysis/ScopDetection.cpp delete mode 100644 polly/lib/Analysis/ScopGraphPrinter.cpp delete mode 100644 polly/lib/Analysis/ScopInfo.cpp delete mode 100755 polly/lib/Analysis/ScopPass.cpp delete mode 100644 polly/lib/Analysis/TempScopInfo.cpp delete mode 100755 polly/lib/CMakeLists.txt delete mode 100644 polly/lib/Cloog.cpp delete mode 100755 polly/lib/CodeGen/CMakeLists.txt delete mode 100644 polly/lib/CodeGen/CodeGeneration.cpp delete mode 100644 polly/lib/CodeGen/LoopGenerators.cpp delete mode 100755 polly/lib/CodeGen/Makefile delete mode 100644 polly/lib/CodePreparation.cpp delete mode 100644 polly/lib/DeadCodeElimination.cpp delete mode 100644 polly/lib/Exchange/CMakeLists.txt delete mode 100755 polly/lib/Exchange/JSONExporter.cpp delete mode 100755 polly/lib/Exchange/Makefile delete mode 100755 polly/lib/Exchange/OpenScopExporter.cpp delete mode 100755 polly/lib/Exchange/OpenScopImporter.cpp delete mode 100644 polly/lib/Exchange/ScopLib.cpp delete mode 100755 polly/lib/Exchange/ScopLibExporter.cpp delete mode 100755 polly/lib/Exchange/ScopLibImporter.cpp delete mode 100644 polly/lib/IndVarSimplify.cpp delete mode 100644 polly/lib/IndependentBlocks.cpp delete mode 100755 polly/lib/JSON/CMakeLists.txt delete mode 100644 polly/lib/JSON/LICENSE.txt delete mode 100755 polly/lib/JSON/Makefile delete mode 100644 polly/lib/JSON/include/json/autolink.h delete mode 100644 polly/lib/JSON/include/json/config.h delete mode 100644 polly/lib/JSON/include/json/features.h delete mode 100644 polly/lib/JSON/include/json/forwards.h delete mode 100644 polly/lib/JSON/include/json/json.h delete mode 100644 polly/lib/JSON/include/json/reader.h delete mode 100644 polly/lib/JSON/include/json/value.h delete mode 100644 polly/lib/JSON/include/json/writer.h delete mode 100644 polly/lib/JSON/json_batchallocator.h delete mode 100644 polly/lib/JSON/json_internalarray.inl delete mode 100644 polly/lib/JSON/json_internalmap.inl delete mode 100644 polly/lib/JSON/json_reader.cpp delete mode 100644 polly/lib/JSON/json_value.cpp delete mode 100644 polly/lib/JSON/json_valueiterator.inl delete mode 100644 polly/lib/JSON/json_writer.cpp delete mode 100644 polly/lib/JSON/sconscript delete mode 100755 polly/lib/Makefile delete mode 100755 polly/lib/MayAliasSet.cpp delete mode 100644 polly/lib/Pocc.cpp delete mode 100644 polly/lib/RegionSimplify.cpp delete mode 100644 polly/lib/RegisterPasses.cpp delete mode 100644 polly/lib/ScheduleOptimizer.cpp delete mode 100755 polly/lib/Support/CMakeLists.txt delete mode 100644 polly/lib/Support/GICHelper.cpp delete mode 100755 polly/lib/Support/Makefile delete mode 100644 polly/lib/Support/SCEVValidator.cpp delete mode 100644 polly/lib/Support/ScopHelper.cpp delete mode 100644 polly/test/CMakeLists.txt delete mode 100644 polly/test/Cloog/ambigous_schedule.ll delete mode 100644 polly/test/Cloog/ambigous_schedule___%for.cond---%for.end30.jscop delete mode 100644 polly/test/CodeGen/20100617.ll delete mode 100644 polly/test/CodeGen/20100622.ll delete mode 100644 polly/test/CodeGen/20100707.ll delete mode 100644 polly/test/CodeGen/20100707_2.ll delete mode 100644 polly/test/CodeGen/20100708.ll delete mode 100644 polly/test/CodeGen/20100708_2.ll delete mode 100644 polly/test/CodeGen/20100713.ll delete mode 100644 polly/test/CodeGen/20100713_2.ll delete mode 100644 polly/test/CodeGen/20100717.ll delete mode 100644 polly/test/CodeGen/20100718-DomInfo-2.ll delete mode 100644 polly/test/CodeGen/20100718-DomInfo.ll delete mode 100644 polly/test/CodeGen/20100720-MultipleConditions.c delete mode 100644 polly/test/CodeGen/20100720-MultipleConditions.ll delete mode 100644 polly/test/CodeGen/20100809-IndependentBlock.ll delete mode 100644 polly/test/CodeGen/20100811-ScalarDependencyBetweenBrAndCnd.ll delete mode 100644 polly/test/CodeGen/20101030-Overflow.ll delete mode 100644 polly/test/CodeGen/20101103-Overflow3.ll delete mode 100644 polly/test/CodeGen/20101103-signmissmatch.ll delete mode 100644 polly/test/CodeGen/20110226-Ignore-Dead-Code.ll delete mode 100644 polly/test/CodeGen/20110226-PHI-Node-removed.ll delete mode 100644 polly/test/CodeGen/20110312-Fail-without-basicaa.ll delete mode 100644 polly/test/CodeGen/20120316-InvalidCast.ll delete mode 100755 polly/test/CodeGen/20120403-RHS-type-mismatch.ll delete mode 100644 polly/test/CodeGen/MemAccess/codegen_constant_offset.c delete mode 100644 polly/test/CodeGen/MemAccess/codegen_constant_offset.ll delete mode 100644 polly/test/CodeGen/MemAccess/codegen_constant_offset___%for.cond---%for.end.jscop delete mode 100644 polly/test/CodeGen/MemAccess/codegen_constant_offset___%for.cond---%for.end.jscop.transformed delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple.c delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple.ll delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple___%for.cond---%for.end.jscop delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple___%for.cond---%for.end.jscop.transformed delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple_md.c delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple_md.ll delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple_md___%for.cond---%for.end6.jscop delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple_md___%for.cond---%for.end6.jscop.transformed+withconst delete mode 100644 polly/test/CodeGen/MemAccess/codegen_simple_md___%for.cond---%for.end6.jscop.transformed+withoutconst delete mode 100644 polly/test/CodeGen/MemAccess/simple.c delete mode 100644 polly/test/CodeGen/MemAccess/simple.ll delete mode 100644 polly/test/CodeGen/MemAccess/simple___%for.cond---%for.end.jscop delete mode 100644 polly/test/CodeGen/MemAccess/simple___%for.cond---%for.end.jscop.transformed delete mode 100644 polly/test/CodeGen/MemAccess/simple___%for.cond4---%for.end14.jscop delete mode 100644 polly/test/CodeGen/MemAccess/simple___%for.cond4---%for.end14.jscop.transformed delete mode 100644 polly/test/CodeGen/MemAccess/simple_analyze.ll delete mode 100644 polly/test/CodeGen/OpenMP/20120330-argument-use.c delete mode 100644 polly/test/CodeGen/OpenMP/20120330-argument-use.ll delete mode 100644 polly/test/CodeGen/OpenMP/add_memref.c delete mode 100644 polly/test/CodeGen/OpenMP/add_memref.ll delete mode 100644 polly/test/CodeGen/OpenMP/extract_memref.c delete mode 100644 polly/test/CodeGen/OpenMP/extract_memref.ll delete mode 100644 polly/test/CodeGen/OpenMP/invalidate_subfn_scops.c delete mode 100644 polly/test/CodeGen/OpenMP/invalidate_subfn_scops.ll delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop.c delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop.ll delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop___%bb18---%bb50.jscop delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop___%bb18---%bb50.jscop.tiled delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop_simple.c delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop_simple.ll delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop_simple2.c delete mode 100644 polly/test/CodeGen/OpenMP/parallel_loop_simple2.ll delete mode 100644 polly/test/CodeGen/OpenMP/simple_nested_loop.c delete mode 100644 polly/test/CodeGen/OpenMP/simple_nested_loop.ll delete mode 100644 polly/test/CodeGen/OpenMP/structnames.c delete mode 100644 polly/test/CodeGen/OpenMP/structnames.ll delete mode 100644 polly/test/CodeGen/OpenMP/two_loop.c delete mode 100644 polly/test/CodeGen/OpenMP/two_loop.ll delete mode 100644 polly/test/CodeGen/PHIInExit.ll delete mode 100644 polly/test/CodeGen/constant_condition.c delete mode 100644 polly/test/CodeGen/constant_condition.ll delete mode 100644 polly/test/CodeGen/do_pluto_matmult.c delete mode 100644 polly/test/CodeGen/do_pluto_matmult.ll delete mode 100644 polly/test/CodeGen/do_pluto_matmult.ll.result delete mode 100644 polly/test/CodeGen/do_pluto_matmult___%do.body---%do.end45.jscop delete mode 100644 polly/test/CodeGen/do_pluto_matmult___%do.body---%do.end45.jscop.invalid_reverse delete mode 100644 polly/test/CodeGen/do_pluto_matmult___%do.body---%do.end45.jscop.valid_reverse delete mode 100644 polly/test/CodeGen/loop_with_condition.c delete mode 100644 polly/test/CodeGen/loop_with_condition.ll delete mode 100644 polly/test/CodeGen/loop_with_condition_2.ll delete mode 100644 polly/test/CodeGen/loop_with_condition_ineq.c delete mode 100644 polly/test/CodeGen/loop_with_condition_ineq.ll delete mode 100644 polly/test/CodeGen/loop_with_condition_nested.c delete mode 100644 polly/test/CodeGen/loop_with_condition_nested.ll delete mode 100644 polly/test/CodeGen/matmul_vec.c delete mode 100644 polly/test/CodeGen/matmul_vec.ll delete mode 100644 polly/test/CodeGen/matmul_vec___%1---%17.jscop delete mode 100644 polly/test/CodeGen/pluto_matmult.c delete mode 100644 polly/test/CodeGen/pluto_matmult.ll delete mode 100644 polly/test/CodeGen/pluto_matmult___%for.cond---%for.end47.jscop delete mode 100644 polly/test/CodeGen/reduction.c delete mode 100644 polly/test/CodeGen/reduction.ll delete mode 100644 polly/test/CodeGen/reduction_2.c delete mode 100644 polly/test/CodeGen/reduction_2.ll delete mode 100644 polly/test/CodeGen/scev.ll delete mode 100644 polly/test/CodeGen/sequential_loops.c delete mode 100644 polly/test/CodeGen/sequential_loops.ll delete mode 100644 polly/test/CodeGen/simple_nonaffine_loop.c delete mode 100644 polly/test/CodeGen/simple_nonaffine_loop.ll delete mode 100644 polly/test/CodeGen/simple_vec_assign_scalar.c delete mode 100644 polly/test/CodeGen/simple_vec_assign_scalar.ll delete mode 100644 polly/test/CodeGen/simple_vec_assign_scalar_2.c delete mode 100644 polly/test/CodeGen/simple_vec_assign_scalar_2.ll delete mode 100644 polly/test/CodeGen/simple_vec_call.ll delete mode 100644 polly/test/CodeGen/simple_vec_call_2.ll delete mode 100644 polly/test/CodeGen/simple_vec_cast.ll delete mode 100644 polly/test/CodeGen/simple_vec_const.c delete mode 100644 polly/test/CodeGen/simple_vec_const.ll delete mode 100644 polly/test/CodeGen/simple_vec_impossible.ll delete mode 100644 polly/test/CodeGen/simple_vec_large_width.ll delete mode 100644 polly/test/CodeGen/simple_vec_stride_one.c delete mode 100644 polly/test/CodeGen/simple_vec_stride_one.ll delete mode 100644 polly/test/CodeGen/simple_vec_stride_one___%1---%5.jscop delete mode 100644 polly/test/CodeGen/simple_vec_stride_x.c delete mode 100644 polly/test/CodeGen/simple_vec_stride_x.ll delete mode 100644 polly/test/CodeGen/simple_vec_two_stmts.ll delete mode 100644 polly/test/CodeGen/single_do_loop_int_max_iterations.c delete mode 100644 polly/test/CodeGen/single_do_loop_int_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_do_loop_int_max_iterations___%do.body---%do.end.jscop delete mode 100644 polly/test/CodeGen/single_do_loop_int_param_iterations.c delete mode 100644 polly/test/CodeGen/single_do_loop_int_param_iterations.ll delete mode 100644 polly/test/CodeGen/single_do_loop_ll_max_iterations.c delete mode 100644 polly/test/CodeGen/single_do_loop_ll_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_do_loop_one_iteration.c delete mode 100644 polly/test/CodeGen/single_do_loop_one_iteration.ll delete mode 100644 polly/test/CodeGen/single_do_loop_scev_replace.c delete mode 100644 polly/test/CodeGen/single_do_loop_scev_replace.ll delete mode 100644 polly/test/CodeGen/single_loop.c delete mode 100644 polly/test/CodeGen/single_loop.ll delete mode 100644 polly/test/CodeGen/single_loop_int_max_iterations.c delete mode 100644 polly/test/CodeGen/single_loop_int_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_loop_ll_max_iterations.c delete mode 100644 polly/test/CodeGen/single_loop_ll_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_loop_one_iteration.c delete mode 100644 polly/test/CodeGen/single_loop_one_iteration.ll delete mode 100644 polly/test/CodeGen/single_loop_param.ll delete mode 100644 polly/test/CodeGen/single_loop_uint_max_iterations.c delete mode 100644 polly/test/CodeGen/single_loop_uint_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_loop_ull_max_iterations.c delete mode 100644 polly/test/CodeGen/single_loop_ull_max_iterations.ll delete mode 100644 polly/test/CodeGen/single_loop_zero_iterations.c delete mode 100644 polly/test/CodeGen/single_loop_zero_iterations.ll delete mode 100644 polly/test/CodeGen/split_edges.ll delete mode 100644 polly/test/CodeGen/split_edges_2.ll delete mode 100644 polly/test/CodeGen/test.c delete mode 100644 polly/test/CodeGen/test.ll delete mode 100755 polly/test/Makefile delete mode 100644 polly/test/README delete mode 100644 polly/test/ScheduleOptimizer/2011-08-25-crash_in_vectorizer.ll delete mode 100644 polly/test/ScheduleOptimizer/2012-03-16-Empty-Domain.ll delete mode 100644 polly/test/ScheduleOptimizer/2012-04-16-Trivially-vectorizable-loops.ll delete mode 100644 polly/test/ScopDetection/single_function_only.ll delete mode 100644 polly/test/ScopInfo/20111108-Parameter-not-detected.ll delete mode 100644 polly/test/ScopInfo/2012-03-16-Crash-because-of-unsigned-in-scev.ll delete mode 100755 polly/test/ScopInfo/Alias-0.ll delete mode 100755 polly/test/ScopInfo/Alias-1.ll delete mode 100755 polly/test/ScopInfo/Alias-2.ll delete mode 100755 polly/test/ScopInfo/Alias-3.ll delete mode 100755 polly/test/ScopInfo/Alias-4.ll delete mode 100644 polly/test/ScopInfo/bad_loop_0.ll delete mode 100755 polly/test/ScopInfo/bug_2010_10_22.ll delete mode 100755 polly/test/ScopInfo/bug_2011_1_5.ll delete mode 100644 polly/test/ScopInfo/bug_scev_not_fully_eval.ll delete mode 100644 polly/test/ScopInfo/cond_in_loop.ll delete mode 100644 polly/test/ScopInfo/indvar_out_of_loop.ll delete mode 100644 polly/test/ScopInfo/indvar_out_of_loop_1.ll delete mode 100644 polly/test/ScopInfo/indvar_out_of_loop_2.ll delete mode 100644 polly/test/ScopInfo/loop_affine_bound_0.ll delete mode 100644 polly/test/ScopInfo/loop_affine_bound_1.ll delete mode 100644 polly/test/ScopInfo/loop_affine_bound_2.ll delete mode 100644 polly/test/ScopInfo/loop_carry.ll delete mode 100644 polly/test/ScopInfo/loop_complex_parameter.ll delete mode 100644 polly/test/ScopInfo/loop_depth_0.ll delete mode 100644 polly/test/ScopInfo/loop_multi_exits.ll delete mode 100644 polly/test/ScopInfo/out_of_loop_0.ll delete mode 100755 polly/test/ScopInfo/phi_not_grouped_at_top.ll delete mode 100755 polly/test/ScopInfo/phi_with_invoke_edge.ll delete mode 100644 polly/test/ScopInfo/simple_loop_1.ll delete mode 100644 polly/test/ScopInfo/simple_nonaffine_loop.ll delete mode 100644 polly/test/ScopInfo/simple_nonaffine_loop_not.ll delete mode 100644 polly/test/ScopInfo/undef_in_cond.ll delete mode 100644 polly/test/TempScop/not-a-reduction.c delete mode 100644 polly/test/TempScop/not-a-reduction.ll delete mode 100755 polly/test/create_ll.sh delete mode 100644 polly/test/lit.cfg delete mode 100644 polly/test/lit.site.cfg.in delete mode 100644 polly/test/polly.ll delete mode 100755 polly/test/polybench/README delete mode 100755 polly/test/polybench/datamining/correlation/correlation.c delete mode 100644 polly/test/polybench/datamining/correlation/correlation_with_param.ll delete mode 100644 polly/test/polybench/datamining/correlation/correlation_without_param.ll delete mode 100755 polly/test/polybench/datamining/covariance/covariance.c delete mode 100644 polly/test/polybench/datamining/covariance/covariance_with_param.ll delete mode 100644 polly/test/polybench/datamining/covariance/covariance_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/2mm/2mm.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/2mm/2mm_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/2mm/2mm_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/2mm/compiler.opts delete mode 100755 polly/test/polybench/linear-algebra/kernels/3mm/3mm.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/3mm/3mm_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/3mm/3mm_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/3mm/compiler.opts delete mode 100755 polly/test/polybench/linear-algebra/kernels/atax/atax.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/atax/atax_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/atax/atax_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/bicg/bicg.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/bicg/bicg_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/bicg/bicg_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/doitgen/doitgen.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/doitgen/doitgen_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/doitgen/doitgen_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/gemm/compiler.opts delete mode 100755 polly/test/polybench/linear-algebra/kernels/gemm/gemm.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/gemm/gemm_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/gemm/gemm_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/gemver/gemver.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/gemver/gemver_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/gemver/gemver_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/kernels/gesummv/gesummv.c delete mode 100644 polly/test/polybench/linear-algebra/kernels/gesummv/gesummv_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/kernels/gesummv/gesummv_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/solvers/gramschmidt/gramschmidt.c delete mode 100644 polly/test/polybench/linear-algebra/solvers/gramschmidt/gramschmidt_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/solvers/gramschmidt/gramschmidt_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/solvers/lu/lu.c delete mode 100644 polly/test/polybench/linear-algebra/solvers/lu/lu_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/solvers/lu/lu_without_param.ll delete mode 100755 polly/test/polybench/linear-algebra/solvers/ludcmp/ludcmp.c delete mode 100644 polly/test/polybench/linear-algebra/solvers/ludcmp/ludcmp_with_param.ll delete mode 100644 polly/test/polybench/linear-algebra/solvers/ludcmp/ludcmp_without_param.ll delete mode 100755 polly/test/polybench/scripts/compile.sh delete mode 100755 polly/test/polybench/scripts/runall.sh delete mode 100755 polly/test/polybench/stencils/adi/adi.c delete mode 100644 polly/test/polybench/stencils/adi/adi_with_param.ll delete mode 100644 polly/test/polybench/stencils/adi/adi_without_param.ll delete mode 100755 polly/test/polybench/stencils/jacobi-2d-imper/jacobi-2d-imper.c delete mode 100644 polly/test/polybench/stencils/jacobi-2d-imper/jacobi-2d-imper_with_param.ll delete mode 100644 polly/test/polybench/stencils/jacobi-2d-imper/jacobi-2d-imper_without_param.ll delete mode 100755 polly/test/polybench/stencils/seidel/seidel.c delete mode 100644 polly/test/polybench/stencils/seidel/seidel_with_param.ll delete mode 100644 polly/test/polybench/stencils/seidel/seidel_without_param.ll delete mode 100755 polly/test/polybench/utilities/instrument.c delete mode 100755 polly/test/polybench/utilities/instrument.h delete mode 100755 polly/test/polybench/utilities/template-for-new-benchmark.c delete mode 100644 polly/tools/CMakeLists.txt delete mode 100644 polly/tools/Makefile delete mode 100644 polly/utils/argparse.py delete mode 100755 polly/utils/checkout_cloog.sh delete mode 100755 polly/utils/jscop2cloog.py delete mode 100644 polly/utils/pyscop/isl.py delete mode 100755 polly/utils/pyscop/jscop2iscc.py delete mode 100644 polly/utils/pyscop/pyscop.py delete mode 100644 polly/www/.htaccess delete mode 100644 polly/www/bugs.html delete mode 100644 polly/www/content.css delete mode 100644 polly/www/contributors.html delete mode 100644 polly/www/documentation.html delete mode 100644 polly/www/documentation/architecture.html delete mode 100644 polly/www/documentation/memaccess.html delete mode 100644 polly/www/documentation/passes.html delete mode 100644 polly/www/example_load_Polly_into_clang.html delete mode 100644 polly/www/example_manual_matmul.html delete mode 100644 polly/www/examples.html delete mode 100644 polly/www/experiments/matmul/.htaccess delete mode 100644 polly/www/experiments/matmul/init_array___%1---%19.jscop delete mode 100644 polly/www/experiments/matmul/main___%1---%17.jscop delete mode 100644 polly/www/experiments/matmul/main___%1---%17.jscop.interchanged delete mode 100644 polly/www/experiments/matmul/main___%1---%17.jscop.interchanged+tiled delete mode 100644 polly/www/experiments/matmul/main___%1---%17.jscop.interchanged+tiled+vector delete mode 100644 polly/www/experiments/matmul/matmul.c delete mode 100755 polly/www/experiments/matmul/matmul.normalopt.exe delete mode 100644 polly/www/experiments/matmul/matmul.normalopt.ll delete mode 100644 polly/www/experiments/matmul/matmul.normalopt.s delete mode 100755 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector+openmp.exe delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector+openmp.ll delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector+openmp.s delete mode 100755 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector.exe delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector.ll delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled+vector.s delete mode 100755 polly/www/experiments/matmul/matmul.polly.interchanged+tiled.exe delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled.ll delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged+tiled.s delete mode 100755 polly/www/experiments/matmul/matmul.polly.interchanged.exe delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged.ll delete mode 100644 polly/www/experiments/matmul/matmul.polly.interchanged.s delete mode 100644 polly/www/experiments/matmul/matmul.preopt.ll delete mode 100644 polly/www/experiments/matmul/matmul.s delete mode 100755 polly/www/experiments/matmul/runall.sh delete mode 100644 polly/www/experiments/matmul/scops.init_array.dot delete mode 100644 polly/www/experiments/matmul/scops.init_array.dot.png delete mode 100644 polly/www/experiments/matmul/scops.main.dot delete mode 100644 polly/www/experiments/matmul/scops.main.dot.png delete mode 100644 polly/www/experiments/matmul/scops.print_array.dot delete mode 100644 polly/www/experiments/matmul/scops.print_array.dot.png delete mode 100644 polly/www/experiments/matmul/scopsonly.init_array.dot delete mode 100644 polly/www/experiments/matmul/scopsonly.init_array.dot.png delete mode 100644 polly/www/experiments/matmul/scopsonly.main.dot delete mode 100644 polly/www/experiments/matmul/scopsonly.main.dot.png delete mode 100644 polly/www/experiments/matmul/scopsonly.print_array.dot delete mode 100644 polly/www/experiments/matmul/scopsonly.print_array.dot.png delete mode 100644 polly/www/get_started.html delete mode 100644 polly/www/images/architecture.png delete mode 100644 polly/www/images/iit-madras.png delete mode 100644 polly/www/images/osu.png delete mode 100644 polly/www/images/performance/parallel-large.png delete mode 100644 polly/www/images/performance/parallel-small.png delete mode 100644 polly/www/images/performance/sequential-large.png delete mode 100644 polly/www/images/performance/sequential-small.png delete mode 100644 polly/www/images/sys-uni.png delete mode 100644 polly/www/images/uni-passau.png delete mode 100644 polly/www/images/video-summit-2011.png delete mode 100644 polly/www/index.html delete mode 100644 polly/www/menu.css delete mode 100644 polly/www/menu.html.incl delete mode 100644 polly/www/performance.html delete mode 100644 polly/www/phonecall.html delete mode 100644 polly/www/polly.sh delete mode 100644 polly/www/publications.html delete mode 100644 polly/www/publications/grosser-diploma-thesis.pdf delete mode 100644 polly/www/publications/grosser-impact-2011-slides.pdf delete mode 100644 polly/www/publications/grosser-impact-2011.pdf delete mode 100644 polly/www/publications/raghesh-a-masters-thesis.pdf delete mode 100644 polly/www/todo.html delete mode 100644 polly/www/video-js/video-js.css delete mode 100644 polly/www/video-js/video.js diff --git a/debuginfo-tests/README.txt b/debuginfo-tests/README.txt deleted file mode 100644 index 5ef6aa0a11a0..000000000000 --- a/debuginfo-tests/README.txt +++ /dev/null @@ -1,19 +0,0 @@ - -This is a collection of tests to check debugging information generated by -compiler. This test suite can be checked out inside clang/test folder. This -will enable 'make test' for clang to pick up these tests. Typically, test -cases included here includes debugger commands and intended debugger output -as comments in source file using DEBUGGER: and CHECK: as prefixes respectively. - -For exmaple, - -define i32 @f1(i32 %i) nounwind ssp { -; DEBUGGER: break f1 -; DEBUGGER: r -; DEBUGGER: p i -; CHECK: $1 = 42 -entry: -} - -is a testcase where the debuger is asked to break at function 'f1' and -print value of argument 'i'. The expected value of 'i' is 42 in this case. diff --git a/debuginfo-tests/aggregate-indirect-arg.cpp b/debuginfo-tests/aggregate-indirect-arg.cpp deleted file mode 100644 index a010e35bbc26..000000000000 --- a/debuginfo-tests/aggregate-indirect-arg.cpp +++ /dev/null @@ -1,32 +0,0 @@ -// RUN: %clangxx -O0 -g %s -c -o %t.o -// RUN: %clangxx %t.o -o %t.out -// RUN: %test_debuginfo %s %t.out -// Radar 8945514 -// DEBUGGER: break 22 -// DEBUGGER: r -// DEBUGGER: p v -// CHECK: $1 = (SVal &) -// CHECK: Data = 0x0, -// CHECK: Kind = 2142 - -class SVal { -public: - ~SVal() {} - const void* Data; - unsigned Kind; -}; - -void bar(SVal &v) {} -class A { -public: - void foo(SVal v) { bar(v); } -}; - -int main() { - SVal v; - v.Data = 0; - v.Kind = 2142; - A a; - a.foo(v); - return 0; -} diff --git a/debuginfo-tests/block_var.m b/debuginfo-tests/block_var.m deleted file mode 100644 index a1c94c885135..000000000000 --- a/debuginfo-tests/block_var.m +++ /dev/null @@ -1,32 +0,0 @@ -// RUN: %clang -O0 -g %s -c -o %t.o -// RUN: %clang %t.o -o %t.out -framework Foundation -// RUN: %test_debuginfo %s %t.out -// XFAIL: * -// XTARGET: darwin - -// DEBUGGER: break 24 -// DEBUGGER: r -// DEBUGGER: p result -// CHECK: $1 = 42 - -void doBlock(void (^block)(void)) -{ - block(); -} - -int I(int n) -{ - __block int result; - int i = 2; - doBlock(^{ - result = n; - }); - return result + i; /* Check value of 'result' */ -} - - -int main (int argc, const char * argv[]) { - return I(42); -} - - diff --git a/debuginfo-tests/blocks.m b/debuginfo-tests/blocks.m deleted file mode 100644 index 84610419c719..000000000000 --- a/debuginfo-tests/blocks.m +++ /dev/null @@ -1,43 +0,0 @@ -// RUN: %clang -O0 -g %s -c -o %t.o -// RUN: %clang %t.o -o %t.out -framework Foundation -// RUN: %test_debuginfo %s %t.out -// XFAIL: * -// XTARGET: darwin -// Radar 9279956 - -// DEBUGGER: break 31 -// DEBUGGER: r -// DEBUGGER: p m2 -// DEBUGGER: p dbTransaction -// DEBUGGER: p master -// CHECK: $1 = 1 -// CHECK: $2 = 0 -// CHECK: $3 = 0 - -#include - -extern void foo(void(^)(void)); - -@interface A:NSObject @end -@implementation A -- (void) helper { - int master = 0; - __block int m2 = 0; - __block int dbTransaction = 0; - int (^x)(void) = ^(void) { (void) self; - (void) master; - (void) dbTransaction; - m2++; - return m2; - }; - master = x(); -} -@end - -void foo(void(^x)(void)) {} - -int main() { - A *a = [A alloc]; - [a helper]; - return 0; -} diff --git a/debuginfo-tests/ctor.cpp b/debuginfo-tests/ctor.cpp deleted file mode 100644 index 331d4e5756cc..000000000000 --- a/debuginfo-tests/ctor.cpp +++ /dev/null @@ -1,25 +0,0 @@ -// RUN: %clangxx -O0 -g %s -c -o %t.o -// RUN: %clangxx %t.o -o %t.out -// RUN: %test_debuginfo %s %t.out - - -// DEBUGGER: break 14 -// DEBUGGER: r -// DEBUGGER: p *this -// CHECK-NEXT-NOT: Cannot access memory at address - -class A { -public: - A() : zero(0), data(42) - { - } -private: - int zero; - int data; -}; - -int main() { - A a; - return 0; -} - diff --git a/debuginfo-tests/dbg-arg.ll b/debuginfo-tests/dbg-arg.ll deleted file mode 100644 index 52f36858e79f..000000000000 --- a/debuginfo-tests/dbg-arg.ll +++ /dev/null @@ -1,126 +0,0 @@ -; This test case checks debug info during register moves for an argument. -; RUN: %clang -arch x86_64 -mllvm -fast-isel=false %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin -; Radar 8412415 - -target triple = "x86_64-apple-darwin10.0.0" - -%struct._mtx = type { i64, i32, %struct.anon } -%struct.anon = type { i32, i32 } - -define i32 @foobar(%struct._mtx* nocapture %mutex) nounwind readonly noinline ssp { -; DEBUGGER: break foobar -; DEBUGGER: r -; DEBUGGER: info address mutex -; CHECK: Symbol "mutex" is -; CHECK-NEXT: -; CHECK-NEXT: in register -entry: - tail call void @llvm.dbg.value(metadata !{%struct._mtx* %mutex}, i64 0, metadata !8), !dbg !29 - tail call void @llvm.dbg.value(metadata !30, i64 0, metadata !21), !dbg !31 - tail call void @llvm.dbg.value(metadata !32, i64 0, metadata !23), !dbg !33 - tail call void @llvm.dbg.value(metadata !32, i64 0, metadata !24), !dbg !34 - br label %do.body1, !dbg !37 - -do.body1: ; preds = %entry, %do.body1 - %0 = phi i32 [ 0, %entry ], [ %inc, %do.body1 ] - %r.1 = phi i32 [ 1, %entry ], [ %r.0, %do.body1 ] - %inc = add i32 %0, 1 - %tmp2 = getelementptr inbounds %struct._mtx* %mutex, i64 0, i32 1, !dbg !35 - %tmp3 = load i32* %tmp2, align 4, !dbg !35 - %tobool = icmp eq i32 %tmp3, 0, !dbg !35 - %r.0 = select i1 %tobool, i32 %r.1, i32 2 - %call = tail call i32 @bar(i32 %r.0, i32 %0), !dbg !38 - %cmp = icmp slt i32 %inc, %call, !dbg !39 - br i1 %cmp, label %do.body1, label %do.end9, !dbg !39 - -do.end9: ; preds = %do.body1 - tail call void @llvm.dbg.value(metadata !40, i64 0, metadata !21), !dbg !41 - tail call void @llvm.dbg.value(metadata !{i32 %call}, i64 0, metadata !24), !dbg !38 - tail call void @llvm.dbg.value(metadata !{i32 %inc}, i64 0, metadata !23), !dbg !42 - %add = add nsw i32 %r.0, %call, !dbg !43 - ret i32 %add, !dbg !43 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -define i32 @bar(i32 %i, i32 %j) nounwind readnone noinline ssp { -entry: - tail call void @llvm.dbg.value(metadata !{i32 %i}, i64 0, metadata !25), !dbg !44 - tail call void @llvm.dbg.value(metadata !{i32 %j}, i64 0, metadata !26), !dbg !45 - %add = add nsw i32 %j, %i, !dbg !46 - ret i32 %add, !dbg !46 -} - -define i32 @main() nounwind readonly ssp { -entry: - %m = alloca %struct._mtx, align 8 - call void @llvm.dbg.declare(metadata !{%struct._mtx* %m}, metadata !27), !dbg !48 - %tmp = getelementptr inbounds %struct._mtx* %m, i64 0, i32 1, !dbg !49 - store i32 0, i32* %tmp, align 8, !dbg !49 - %call = call i32 @foobar(%struct._mtx* %m), !dbg !50 - ret i32 %call, !dbg !50 -} - -declare void @llvm.dbg.value(metadata, i64, metadata) nounwind readnone - -!llvm.dbg.sp = !{!0, !6, !7} -!llvm.dbg.lv.foobar = !{!8, !21, !23, !24} -!llvm.dbg.lv.bar = !{!25, !26} -!llvm.dbg.lv.main = !{!27} - -!0 = metadata !{i32 524334, i32 0, metadata !1, metadata !"foobar", metadata !"foobar", metadata !"foobar", metadata !1, i32 12, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 true, i32 (%struct._mtx*)* @foobar} ; [ DW_TAG_subprogram ] -!1 = metadata !{i32 524329, metadata !"mu.c", metadata !"/private/tmp", metadata !2} ; [ DW_TAG_file_type ] -!2 = metadata !{i32 524305, i32 0, i32 12, metadata !"mu.c", metadata !"/private/tmp", metadata !"clang version 2.9 (trunk 114183)", i1 true, i1 true, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!3 = metadata !{i32 524309, metadata !1, metadata !"", metadata !1, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !4, i32 0, null} ; [ DW_TAG_subroutine_type ] -!4 = metadata !{metadata !5} -!5 = metadata !{i32 524324, metadata !1, metadata !"int", metadata !1, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!6 = metadata !{i32 524334, i32 0, metadata !1, metadata !"bar", metadata !"bar", metadata !"bar", metadata !1, i32 26, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 true, i32 (i32, i32)* @bar} ; [ DW_TAG_subprogram ] -!7 = metadata !{i32 524334, i32 0, metadata !1, metadata !"main", metadata !"main", metadata !"main", metadata !1, i32 30, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 true, i32 ()* @main} ; [ DW_TAG_subprogram ] -!8 = metadata !{i32 524545, metadata !0, metadata !"mutex", metadata !1, i32 12, metadata !9} ; [ DW_TAG_arg_variable ] -!9 = metadata !{i32 524303, metadata !1, metadata !"", metadata !1, i32 0, i64 64, i64 64, i64 0, i32 0, metadata !10} ; [ DW_TAG_pointer_type ] -!10 = metadata !{i32 524310, metadata !1, metadata !"mtx_t", metadata !1, i32 9, i64 0, i64 0, i64 0, i32 0, metadata !11} ; [ DW_TAG_typedef ] -!11 = metadata !{i32 524307, metadata !1, metadata !"_mtx", metadata !1, i32 2, i64 192, i64 64, i64 0, i32 0, null, metadata !12, i32 0, null} ; [ DW_TAG_structure_type ] -!12 = metadata !{metadata !13, metadata !15, metadata !16} -!13 = metadata !{i32 524301, metadata !1, metadata !"ptr", metadata !1, i32 3, i64 64, i64 64, i64 0, i32 0, metadata !14} ; [ DW_TAG_member ] -!14 = metadata !{i32 524324, metadata !1, metadata !"long unsigned int", metadata !1, i32 0, i64 64, i64 64, i64 0, i32 0, i32 7} ; [ DW_TAG_base_type ] -!15 = metadata !{i32 524301, metadata !1, metadata !"waiters", metadata !1, i32 4, i64 32, i64 32, i64 64, i32 0, metadata !5} ; [ DW_TAG_member ] -!16 = metadata !{i32 524301, metadata !1, metadata !"mtxi", metadata !1, i32 8, i64 64, i64 32, i64 96, i32 0, metadata !17} ; [ DW_TAG_member ] -!17 = metadata !{i32 524307, metadata !11, metadata !"", metadata !1, i32 5, i64 64, i64 32, i64 0, i32 0, null, metadata !18, i32 0, null} ; [ DW_TAG_structure_type ] -!18 = metadata !{metadata !19, metadata !20} -!19 = metadata !{i32 524301, metadata !1, metadata !"tag", metadata !1, i32 6, i64 32, i64 32, i64 0, i32 0, metadata !5} ; [ DW_TAG_member ] -!20 = metadata !{i32 524301, metadata !1, metadata !"pad", metadata !1, i32 7, i64 32, i64 32, i64 32, i32 0, metadata !5} ; [ DW_TAG_member ] -!21 = metadata !{i32 524544, metadata !22, metadata !"r", metadata !1, i32 13, metadata !5} ; [ DW_TAG_auto_variable ] -!22 = metadata !{i32 524299, metadata !0, i32 12, i32 52, metadata !1, i32 0} ; [ DW_TAG_lexical_block ] -!23 = metadata !{i32 524544, metadata !22, metadata !"l", metadata !1, i32 14, metadata !5} ; [ DW_TAG_auto_variable ] -!24 = metadata !{i32 524544, metadata !22, metadata !"j", metadata !1, i32 15, metadata !5} ; [ DW_TAG_auto_variable ] -!25 = metadata !{i32 524545, metadata !6, metadata !"i", metadata !1, i32 26, metadata !5} ; [ DW_TAG_arg_variable ] -!26 = metadata !{i32 524545, metadata !6, metadata !"j", metadata !1, i32 26, metadata !5} ; [ DW_TAG_arg_variable ] -!27 = metadata !{i32 524544, metadata !28, metadata !"m", metadata !1, i32 31, metadata !10} ; [ DW_TAG_auto_variable ] -!28 = metadata !{i32 524299, metadata !7, i32 30, i32 12, metadata !1, i32 4} ; [ DW_TAG_lexical_block ] -!29 = metadata !{i32 12, i32 45, metadata !0, null} -!30 = metadata !{i32 1} -!31 = metadata !{i32 13, i32 12, metadata !22, null} -!32 = metadata !{i32 0} -!33 = metadata !{i32 14, i32 12, metadata !22, null} -!34 = metadata !{i32 15, i32 12, metadata !22, null} -!35 = metadata !{i32 18, i32 5, metadata !36, null} -!36 = metadata !{i32 524299, metadata !22, i32 17, i32 6, metadata !1, i32 2} ; [ DW_TAG_lexical_block ] -!37 = metadata !{i32 16, i32 3, metadata !22, null} -!38 = metadata !{i32 20, i32 5, metadata !36, null} -!39 = metadata !{i32 22, i32 3, metadata !36, null} -!40 = metadata !{i32 2} -!41 = metadata !{i32 19, i32 7, metadata !36, null} -!42 = metadata !{i32 21, i32 5, metadata !36, null} -!43 = metadata !{i32 23, i32 3, metadata !22, null} -!44 = metadata !{i32 26, i32 39, metadata !6, null} -!45 = metadata !{i32 26, i32 46, metadata !6, null} -!46 = metadata !{i32 27, i32 3, metadata !47, null} -!47 = metadata !{i32 524299, metadata !6, i32 26, i32 49, metadata !1, i32 3} ; [ DW_TAG_lexical_block ] -!48 = metadata !{i32 31, i32 9, metadata !28, null} -!49 = metadata !{i32 32, i32 3, metadata !28, null} -!50 = metadata !{i32 33, i32 3, metadata !28, null} - diff --git a/debuginfo-tests/dbg-declare.ll b/debuginfo-tests/dbg-declare.ll deleted file mode 100644 index b520c68a5fa8..000000000000 --- a/debuginfo-tests/dbg-declare.ll +++ /dev/null @@ -1,263 +0,0 @@ -; This test case checks handling of llvm.dbg.declare intrinsic during fast-isel. -; RUN: %clang -arch x86_64 -O0 -g %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin - -target triple = "x86_64-apple-darwin" -%struct.XYZ = type { i32, i32, i32, i32, i32 } - -; Check handling of llvm.dbg.declare for an argument referred through alloca, where -; alloca dominates llvm.dbg.declare -define i32 @f1(i32 %i) nounwind ssp { -; DEBUGGER: break f1 -; DEBUGGER: r -; DEBUGGER: p i -; CHECK: $1 = 42 -entry: - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i.addr}, metadata !16), !dbg !17 - %tmp = load i32* %i.addr, align 4, !dbg !18 - ret i32 %tmp, !dbg !18 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -; Check handling of llvm.dbg.declare for an argument referred through alloca, where -; llvm.dbg.declare dominates alloca. -define i32 @f2(i32 %i) nounwind ssp { -; DEBUGGER: break f2 -; DEBUGGER: c -; DEBUGGER: p i -; CHECK: $2 = 43 -entry: - call void @llvm.dbg.declare(metadata !{i32* %i.addr}, metadata !20), !dbg !21 - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - %tmp = load i32* %i.addr, align 4, !dbg !22 - ret i32 %tmp, !dbg !22 -} - -; If llvm.dbg.declare is using an argument after its last use then register -; allocator may destroy debug info for the argument. This is expected and -; it should be fixed before registers are allocated. -define i32 @f3(i32 %i) nounwind ssp { -entry: - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !24), !dbg !25 - %tmp = load i32* %i.addr, align 4, !dbg !26 - ret i32 %tmp, !dbg !26 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument. -define i32 @f4(i32 %i) nounwind ssp { -; DEBUGGER: break f4 -; DEBUGGER: c -; DEBUGGER: p i -; CHECK: $3 = 45 -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !28), !dbg !29 - ret i32 %i, !dbg !30 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument in separate basic block. -define i32 @f5(i32 %i) nounwind ssp { -; DEBUGGER: break f5 -; DEBUGGER: c -; DEBUGGER: p i -; CHECK: $4 = 46 -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !32), !dbg !33 - br label %bbr -bbr: - ret i32 %i, !dbg !34 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; argument is not used. -define i32 @f6(i32 %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !36), !dbg !37 - ret i32 1, !dbg !38 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; argument is not used. -define i32 @f7(%struct.XYZ* byval %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !40), !dbg !48 - ret i32 1, !dbg !49 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; argument use dominates llvm.dbg.declare. -define i32 @f8(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f8 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $5 = 51 -entry: - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 1, !dbg !53 - %tmp1 = load i32* %tmp, align 4, !dbg !53 - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !51), !dbg !52 - ret i32 %tmp1, !dbg !53 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument. -define i32 @f9(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f9 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $6 = 51 -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !55), !dbg !56 - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 2, !dbg !57 - %tmp1 = load i32* %tmp, align 4, !dbg !57 - ret i32 %tmp1, !dbg !57 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument in separate basic block. -define i32 @f10(%struct.XYZ* byval %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !59), !dbg !60 - br label %bbr -bbr: - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 3, !dbg !61 - %tmp1 = load i32* %tmp, align 4, !dbg !61 - ret i32 %tmp1, !dbg !61 -} - -define i32 @main() nounwind ssp { -entry: - %retval = alloca i32, align 4 - %abc = alloca %struct.XYZ, align 4 - %agg.tmp = alloca %struct.XYZ, align 4 - %agg.tmp13 = alloca %struct.XYZ, align 4 - %agg.tmp17 = alloca %struct.XYZ, align 4 - %agg.tmp21 = alloca %struct.XYZ, align 4 - store i32 0, i32* %retval - %call = call i32 @f1(i32 42), !dbg !63 - %call1 = call i32 @f2(i32 43), !dbg !65 - %call2 = call i32 @f3(i32 44), !dbg !66 - %call3 = call i32 @f4(i32 45), !dbg !67 - %call4 = call i32 @f5(i32 46), !dbg !68 - %call5 = call i32 @f6(i32 47), !dbg !69 - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %abc}, metadata !70), !dbg !71 - %tmp = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 0, !dbg !72 - store i32 51, i32* %tmp, align 4, !dbg !72 - %tmp6 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 1, !dbg !72 - store i32 52, i32* %tmp6, align 4, !dbg !72 - %tmp7 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 2, !dbg !72 - store i32 53, i32* %tmp7, align 4, !dbg !72 - %tmp8 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 3, !dbg !72 - store i32 54, i32* %tmp8, align 4, !dbg !72 - %tmp9 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 4, !dbg !72 - store i32 55, i32* %tmp9, align 4, !dbg !72 - %tmp10 = bitcast %struct.XYZ* %agg.tmp to i8*, !dbg !73 - %tmp11 = bitcast %struct.XYZ* %abc to i8*, !dbg !73 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp10, i8* %tmp11, i64 20, i32 4, i1 false), !dbg !73 - %call12 = call i32 @f7(%struct.XYZ* byval %agg.tmp), !dbg !73 - %tmp14 = bitcast %struct.XYZ* %agg.tmp13 to i8*, !dbg !74 - %tmp15 = bitcast %struct.XYZ* %abc to i8*, !dbg !74 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp14, i8* %tmp15, i64 20, i32 4, i1 false), !dbg !74 - %call16 = call i32 @f8(%struct.XYZ* byval %agg.tmp13), !dbg !74 - %tmp18 = bitcast %struct.XYZ* %agg.tmp17 to i8*, !dbg !75 - %tmp19 = bitcast %struct.XYZ* %abc to i8*, !dbg !75 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp18, i8* %tmp19, i64 20, i32 4, i1 false), !dbg !75 - %call20 = call i32 @f9(%struct.XYZ* byval %agg.tmp17), !dbg !75 - %tmp22 = bitcast %struct.XYZ* %agg.tmp21 to i8*, !dbg !76 - %tmp23 = bitcast %struct.XYZ* %abc to i8*, !dbg !76 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp22, i8* %tmp23, i64 20, i32 4, i1 false), !dbg !76 - %call24 = call i32 @f10(%struct.XYZ* byval %agg.tmp21), !dbg !76 - ret i32 0, !dbg !77 -} - -declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture, i64, i32, i1) nounwind - -!llvm.dbg.sp = !{!0, !6, !7, !8, !9, !10, !11, !12, !13, !14, !15} - -!0 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f1", metadata !"f1", metadata !"f1", metadata !1, i32 11, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f1} ; [ DW_TAG_subprogram ] -!1 = metadata !{i32 524329, metadata !"fastisel_arg.c", metadata !"/private/tmp", metadata !2} ; [ DW_TAG_file_type ] -!2 = metadata !{i32 524305, i32 0, i32 12, metadata !"fastisel_arg.c", metadata !"/private/tmp", metadata !"clang version 2.8 (trunk 112967)", i1 true, i1 false, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!3 = metadata !{i32 524309, metadata !1, metadata !"", metadata !1, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !4, i32 0, null} ; [ DW_TAG_subroutine_type ] -!4 = metadata !{metadata !5} -!5 = metadata !{i32 524324, metadata !1, metadata !"int", metadata !1, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!6 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f2", metadata !"f2", metadata !"f2", metadata !1, i32 12, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f2} ; [ DW_TAG_subprogram ] -!7 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f3", metadata !"f3", metadata !"f3", metadata !1, i32 13, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f3} ; [ DW_TAG_subprogram ] -!8 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f4", metadata !"f4", metadata !"f4", metadata !1, i32 14, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f4} ; [ DW_TAG_subprogram ] -!9 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f5", metadata !"f5", metadata !"f5", metadata !1, i32 15, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f5} ; [ DW_TAG_subprogram ] -!10 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f6", metadata !"f6", metadata !"f6", metadata !1, i32 16, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f6} ; [ DW_TAG_subprogram ] -!11 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f7", metadata !"f7", metadata !"f7", metadata !1, i32 17, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f7} ; [ DW_TAG_subprogram ] -!12 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f8", metadata !"f8", metadata !"f8", metadata !1, i32 18, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f8} ; [ DW_TAG_subprogram ] -!13 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f9", metadata !"f9", metadata !"f9", metadata !1, i32 19, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f9} ; [ DW_TAG_subprogram ] -!14 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f10", metadata !"f10", metadata !"f10", metadata !1, i32 20, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f10} ; [ DW_TAG_subprogram ] -!15 = metadata !{i32 524334, i32 0, metadata !1, metadata !"main", metadata !"main", metadata !"main", metadata !1, i32 23, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @main} ; [ DW_TAG_subprogram ] -!16 = metadata !{i32 524545, metadata !0, metadata !"i", metadata !1, i32 11, metadata !5} ; [ DW_TAG_arg_variable ] -!17 = metadata !{i32 11, i32 12, metadata !0, null} -!18 = metadata !{i32 11, i32 17, metadata !19, null} -!19 = metadata !{i32 524299, metadata !0, i32 11, i32 15, metadata !1, i32 0} ; [ DW_TAG_lexical_block ] -!20 = metadata !{i32 524545, metadata !6, metadata !"i", metadata !1, i32 12, metadata !5} ; [ DW_TAG_arg_variable ] -!21 = metadata !{i32 12, i32 12, metadata !6, null} -!22 = metadata !{i32 12, i32 17, metadata !23, null} -!23 = metadata !{i32 524299, metadata !6, i32 12, i32 15, metadata !1, i32 1} ; [ DW_TAG_lexical_block ] -!24 = metadata !{i32 524545, metadata !7, metadata !"i", metadata !1, i32 13, metadata !5} ; [ DW_TAG_arg_variable ] -!25 = metadata !{i32 13, i32 12, metadata !7, null} -!26 = metadata !{i32 13, i32 17, metadata !27, null} -!27 = metadata !{i32 524299, metadata !7, i32 13, i32 15, metadata !1, i32 2} ; [ DW_TAG_lexical_block ] -!28 = metadata !{i32 524545, metadata !8, metadata !"i", metadata !1, i32 14, metadata !5} ; [ DW_TAG_arg_variable ] -!29 = metadata !{i32 14, i32 12, metadata !8, null} -!30 = metadata !{i32 14, i32 17, metadata !31, null} -!31 = metadata !{i32 524299, metadata !8, i32 14, i32 15, metadata !1, i32 3} ; [ DW_TAG_lexical_block ] -!32 = metadata !{i32 524545, metadata !9, metadata !"i", metadata !1, i32 15, metadata !5} ; [ DW_TAG_arg_variable ] -!33 = metadata !{i32 15, i32 12, metadata !9, null} -!34 = metadata !{i32 15, i32 17, metadata !35, null} -!35 = metadata !{i32 524299, metadata !9, i32 15, i32 15, metadata !1, i32 4} ; [ DW_TAG_lexical_block ] -!36 = metadata !{i32 524545, metadata !10, metadata !"i", metadata !1, i32 16, metadata !5} ; [ DW_TAG_arg_variable ] -!37 = metadata !{i32 16, i32 12, metadata !10, null} -!38 = metadata !{i32 16, i32 17, metadata !39, null} -!39 = metadata !{i32 524299, metadata !10, i32 16, i32 15, metadata !1, i32 5} ; [ DW_TAG_lexical_block ] -!40 = metadata !{i32 524545, metadata !11, metadata !"i", metadata !1, i32 17, metadata !41} ; [ DW_TAG_arg_variable ] -!41 = metadata !{i32 524307, metadata !1, metadata !"XYZ", metadata !1, i32 2, i64 160, i64 32, i64 0, i32 0, null, metadata !42, i32 0, null} ; [ DW_TAG_structure_type ] -!42 = metadata !{metadata !43, metadata !44, metadata !45, metadata !46, metadata !47} -!43 = metadata !{i32 524301, metadata !1, metadata !"x", metadata !1, i32 3, i64 32, i64 32, i64 0, i32 0, metadata !5} ; [ DW_TAG_member ] -!44 = metadata !{i32 524301, metadata !1, metadata !"y", metadata !1, i32 4, i64 32, i64 32, i64 32, i32 0, metadata !5} ; [ DW_TAG_member ] -!45 = metadata !{i32 524301, metadata !1, metadata !"z", metadata !1, i32 5, i64 32, i64 32, i64 64, i32 0, metadata !5} ; [ DW_TAG_member ] -!46 = metadata !{i32 524301, metadata !1, metadata !"a", metadata !1, i32 6, i64 32, i64 32, i64 96, i32 0, metadata !5} ; [ DW_TAG_member ] -!47 = metadata !{i32 524301, metadata !1, metadata !"b", metadata !1, i32 7, i64 32, i64 32, i64 128, i32 0, metadata !5} ; [ DW_TAG_member ] -!48 = metadata !{i32 17, i32 19, metadata !11, null} -!49 = metadata !{i32 17, i32 24, metadata !50, null} -!50 = metadata !{i32 524299, metadata !11, i32 17, i32 22, metadata !1, i32 6} ; [ DW_TAG_lexical_block ] -!51 = metadata !{i32 524545, metadata !12, metadata !"i", metadata !1, i32 18, metadata !41} ; [ DW_TAG_arg_variable ] -!52 = metadata !{i32 18, i32 19, metadata !12, null} -!53 = metadata !{i32 18, i32 24, metadata !54, null} -!54 = metadata !{i32 524299, metadata !12, i32 18, i32 22, metadata !1, i32 7} ; [ DW_TAG_lexical_block ] -!55 = metadata !{i32 524545, metadata !13, metadata !"i", metadata !1, i32 19, metadata !41} ; [ DW_TAG_arg_variable ] -!56 = metadata !{i32 19, i32 19, metadata !13, null} -!57 = metadata !{i32 19, i32 24, metadata !58, null} -!58 = metadata !{i32 524299, metadata !13, i32 19, i32 22, metadata !1, i32 8} ; [ DW_TAG_lexical_block ] -!59 = metadata !{i32 524545, metadata !14, metadata !"i", metadata !1, i32 20, metadata !41} ; [ DW_TAG_arg_variable ] -!60 = metadata !{i32 20, i32 20, metadata !14, null} -!61 = metadata !{i32 20, i32 25, metadata !62, null} -!62 = metadata !{i32 524299, metadata !14, i32 20, i32 23, metadata !1, i32 9} ; [ DW_TAG_lexical_block ] -!63 = metadata !{i32 24, i32 3, metadata !64, null} -!64 = metadata !{i32 524299, metadata !15, i32 23, i32 12, metadata !1, i32 10} ; [ DW_TAG_lexical_block ] -!65 = metadata !{i32 25, i32 3, metadata !64, null} -!66 = metadata !{i32 26, i32 3, metadata !64, null} -!67 = metadata !{i32 27, i32 3, metadata !64, null} -!68 = metadata !{i32 28, i32 3, metadata !64, null} -!69 = metadata !{i32 29, i32 3, metadata !64, null} -!70 = metadata !{i32 524544, metadata !64, metadata !"abc", metadata !1, i32 30, metadata !41} ; [ DW_TAG_auto_variable ] -!71 = metadata !{i32 30, i32 14, metadata !64, null} -!72 = metadata !{i32 30, i32 17, metadata !64, null} -!73 = metadata !{i32 31, i32 3, metadata !64, null} -!74 = metadata !{i32 32, i32 3, metadata !64, null} -!75 = metadata !{i32 33, i32 3, metadata !64, null} -!76 = metadata !{i32 34, i32 3, metadata !64, null} -!77 = metadata !{i32 36, i32 3, metadata !64, null} diff --git a/debuginfo-tests/dbg-declare2.ll b/debuginfo-tests/dbg-declare2.ll deleted file mode 100644 index f8155b816e5f..000000000000 --- a/debuginfo-tests/dbg-declare2.ll +++ /dev/null @@ -1,264 +0,0 @@ -; This test case checks handling of llvm.dbg.declare intrinsic during isel. -; RUN: %clang -arch x86_64 -mllvm -fast-isel=false -mllvm -regalloc=default -g %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin - -target triple = "x86_64-apple-darwin" -%struct.XYZ = type { i32, i32, i32, i32, i32 } - -; Check handling of llvm.dbg.declare for an argument referred through alloca, where -; alloca dominates llvm.dbg.declare -define i32 @f1(i32 %i) nounwind ssp { -; DEBUGGER: break f1 -; DEBUGGER: r -; DEBUGGER: p i -; CHECK: $1 = 42 -entry: - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i.addr}, metadata !16), !dbg !17 - %tmp = load i32* %i.addr, align 4, !dbg !18 - ret i32 %tmp, !dbg !18 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -; Check handling of llvm.dbg.declare for an argument referred through alloca, where -; llvm.dbg.declare dominates alloca. -define i32 @f2(i32 %i) nounwind ssp { -; DEBUGGER: break f2 -; DEBUGGER: c -; DEBUGGER: p i -; CHECK: $2 = 43 -entry: - call void @llvm.dbg.declare(metadata !{i32* %i.addr}, metadata !20), !dbg !21 - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - %tmp = load i32* %i.addr, align 4, !dbg !22 - ret i32 %tmp, !dbg !22 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where at least -; one argument use dominates llvm.dbg.declare. -; This is expected to not work because registor allocator has freedom to kill 'i' -; after its last use. -define i32 @f3(i32 %i) nounwind ssp { -entry: - %i.addr = alloca i32, align 4 - store i32 %i, i32* %i.addr, align 4 - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !24), !dbg !25 - %tmp = load i32* %i.addr, align 4, !dbg !26 - ret i32 %tmp, !dbg !26 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument. -define i32 @f4(i32 %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !28), !dbg !29 - ret i32 %i, !dbg !30 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument in separate basic block. -define i32 @f5(i32 %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !32), !dbg !33 - br label %bbr -bbr: - ret i32 %i, !dbg !34 -} - -; Check handling of an argument referred directly by llvm.dbg.declare where -; argument is not used. -define i32 @f6(i32 %i) nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32 %i}, metadata !36), !dbg !37 - ret i32 1, !dbg !38 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; argument is not used. -define i32 @f7(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f7 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $3 = 51 -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !40), !dbg !48 - ret i32 1, !dbg !49 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; argument use dominates llvm.dbg.declare. -define i32 @f8(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f8 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $4 = 51 -entry: - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 1, !dbg !53 - %tmp1 = load i32* %tmp, align 4, !dbg !53 - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !51), !dbg !52 - ret i32 %tmp1, !dbg !53 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument. -define i32 @f9(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f9 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $5 = 51 -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !55), !dbg !56 - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 2, !dbg !57 - %tmp1 = load i32* %tmp, align 4, !dbg !57 - ret i32 %tmp1, !dbg !57 -} - -; Check handling of an byval argument referred directly by llvm.dbg.declare where -; llvm.dbg.declare dominates all uses of argument in separate basic block. -define i32 @f10(%struct.XYZ* byval %i) nounwind ssp { -; DEBUGGER: break f10 -; DEBUGGER: c -; DEBUGGER: p i.x -; CHECK: $6 = 51 -entry: - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %i}, metadata !59), !dbg !60 - br label %bbr -bbr: - %tmp = getelementptr inbounds %struct.XYZ* %i, i32 0, i32 3, !dbg !61 - %tmp1 = load i32* %tmp, align 4, !dbg !61 - ret i32 %tmp1, !dbg !61 -} - -define i32 @main() nounwind ssp { -entry: - %retval = alloca i32, align 4 - %abc = alloca %struct.XYZ, align 4 - %agg.tmp = alloca %struct.XYZ, align 4 - %agg.tmp13 = alloca %struct.XYZ, align 4 - %agg.tmp17 = alloca %struct.XYZ, align 4 - %agg.tmp21 = alloca %struct.XYZ, align 4 - store i32 0, i32* %retval - %call = call i32 @f1(i32 42), !dbg !63 - %call1 = call i32 @f2(i32 43), !dbg !65 - %call2 = call i32 @f3(i32 44), !dbg !66 - %call3 = call i32 @f4(i32 45), !dbg !67 - %call4 = call i32 @f5(i32 46), !dbg !68 - %call5 = call i32 @f6(i32 47), !dbg !69 - call void @llvm.dbg.declare(metadata !{%struct.XYZ* %abc}, metadata !70), !dbg !71 - %tmp = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 0, !dbg !72 - store i32 51, i32* %tmp, align 4, !dbg !72 - %tmp6 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 1, !dbg !72 - store i32 52, i32* %tmp6, align 4, !dbg !72 - %tmp7 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 2, !dbg !72 - store i32 53, i32* %tmp7, align 4, !dbg !72 - %tmp8 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 3, !dbg !72 - store i32 54, i32* %tmp8, align 4, !dbg !72 - %tmp9 = getelementptr inbounds %struct.XYZ* %abc, i32 0, i32 4, !dbg !72 - store i32 55, i32* %tmp9, align 4, !dbg !72 - %tmp10 = bitcast %struct.XYZ* %agg.tmp to i8*, !dbg !73 - %tmp11 = bitcast %struct.XYZ* %abc to i8*, !dbg !73 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp10, i8* %tmp11, i64 20, i32 4, i1 false), !dbg !73 - %call12 = call i32 @f7(%struct.XYZ* byval %agg.tmp), !dbg !73 - %tmp14 = bitcast %struct.XYZ* %agg.tmp13 to i8*, !dbg !74 - %tmp15 = bitcast %struct.XYZ* %abc to i8*, !dbg !74 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp14, i8* %tmp15, i64 20, i32 4, i1 false), !dbg !74 - %call16 = call i32 @f8(%struct.XYZ* byval %agg.tmp13), !dbg !74 - %tmp18 = bitcast %struct.XYZ* %agg.tmp17 to i8*, !dbg !75 - %tmp19 = bitcast %struct.XYZ* %abc to i8*, !dbg !75 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp18, i8* %tmp19, i64 20, i32 4, i1 false), !dbg !75 - %call20 = call i32 @f9(%struct.XYZ* byval %agg.tmp17), !dbg !75 - %tmp22 = bitcast %struct.XYZ* %agg.tmp21 to i8*, !dbg !76 - %tmp23 = bitcast %struct.XYZ* %abc to i8*, !dbg !76 - call void @llvm.memcpy.p0i8.p0i8.i64(i8* %tmp22, i8* %tmp23, i64 20, i32 4, i1 false), !dbg !76 - %call24 = call i32 @f10(%struct.XYZ* byval %agg.tmp21), !dbg !76 - ret i32 0, !dbg !77 -} - -declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture, i64, i32, i1) nounwind - -!llvm.dbg.sp = !{!0, !6, !7, !8, !9, !10, !11, !12, !13, !14, !15} - -!0 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f1", metadata !"f1", metadata !"f1", metadata !1, i32 11, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f1} ; [ DW_TAG_subprogram ] -!1 = metadata !{i32 524329, metadata !"fastisel_arg.c", metadata !"/private/tmp", metadata !2} ; [ DW_TAG_file_type ] -!2 = metadata !{i32 524305, i32 0, i32 12, metadata !"fastisel_arg.c", metadata !"/private/tmp", metadata !"clang version 2.8 (trunk 112967)", i1 true, i1 false, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!3 = metadata !{i32 524309, metadata !1, metadata !"", metadata !1, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !4, i32 0, null} ; [ DW_TAG_subroutine_type ] -!4 = metadata !{metadata !5} -!5 = metadata !{i32 524324, metadata !1, metadata !"int", metadata !1, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!6 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f2", metadata !"f2", metadata !"f2", metadata !1, i32 12, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f2} ; [ DW_TAG_subprogram ] -!7 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f3", metadata !"f3", metadata !"f3", metadata !1, i32 13, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f3} ; [ DW_TAG_subprogram ] -!8 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f4", metadata !"f4", metadata !"f4", metadata !1, i32 14, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f4} ; [ DW_TAG_subprogram ] -!9 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f5", metadata !"f5", metadata !"f5", metadata !1, i32 15, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f5} ; [ DW_TAG_subprogram ] -!10 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f6", metadata !"f6", metadata !"f6", metadata !1, i32 16, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (i32)* @f6} ; [ DW_TAG_subprogram ] -!11 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f7", metadata !"f7", metadata !"f7", metadata !1, i32 17, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f7} ; [ DW_TAG_subprogram ] -!12 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f8", metadata !"f8", metadata !"f8", metadata !1, i32 18, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f8} ; [ DW_TAG_subprogram ] -!13 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f9", metadata !"f9", metadata !"f9", metadata !1, i32 19, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f9} ; [ DW_TAG_subprogram ] -!14 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f10", metadata !"f10", metadata !"f10", metadata !1, i32 20, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 (%struct.XYZ*)* @f10} ; [ DW_TAG_subprogram ] -!15 = metadata !{i32 524334, i32 0, metadata !1, metadata !"main", metadata !"main", metadata !"main", metadata !1, i32 23, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @main} ; [ DW_TAG_subprogram ] -!16 = metadata !{i32 524545, metadata !0, metadata !"i", metadata !1, i32 11, metadata !5} ; [ DW_TAG_arg_variable ] -!17 = metadata !{i32 11, i32 12, metadata !0, null} -!18 = metadata !{i32 11, i32 17, metadata !19, null} -!19 = metadata !{i32 524299, metadata !0, i32 11, i32 15, metadata !1, i32 0} ; [ DW_TAG_lexical_block ] -!20 = metadata !{i32 524545, metadata !6, metadata !"i", metadata !1, i32 12, metadata !5} ; [ DW_TAG_arg_variable ] -!21 = metadata !{i32 12, i32 12, metadata !6, null} -!22 = metadata !{i32 12, i32 17, metadata !23, null} -!23 = metadata !{i32 524299, metadata !6, i32 12, i32 15, metadata !1, i32 1} ; [ DW_TAG_lexical_block ] -!24 = metadata !{i32 524545, metadata !7, metadata !"i", metadata !1, i32 13, metadata !5} ; [ DW_TAG_arg_variable ] -!25 = metadata !{i32 13, i32 12, metadata !7, null} -!26 = metadata !{i32 13, i32 17, metadata !27, null} -!27 = metadata !{i32 524299, metadata !7, i32 13, i32 15, metadata !1, i32 2} ; [ DW_TAG_lexical_block ] -!28 = metadata !{i32 524545, metadata !8, metadata !"i", metadata !1, i32 14, metadata !5} ; [ DW_TAG_arg_variable ] -!29 = metadata !{i32 14, i32 12, metadata !8, null} -!30 = metadata !{i32 14, i32 17, metadata !31, null} -!31 = metadata !{i32 524299, metadata !8, i32 14, i32 15, metadata !1, i32 3} ; [ DW_TAG_lexical_block ] -!32 = metadata !{i32 524545, metadata !9, metadata !"i", metadata !1, i32 15, metadata !5} ; [ DW_TAG_arg_variable ] -!33 = metadata !{i32 15, i32 12, metadata !9, null} -!34 = metadata !{i32 15, i32 17, metadata !35, null} -!35 = metadata !{i32 524299, metadata !9, i32 15, i32 15, metadata !1, i32 4} ; [ DW_TAG_lexical_block ] -!36 = metadata !{i32 524545, metadata !10, metadata !"i", metadata !1, i32 16, metadata !5} ; [ DW_TAG_arg_variable ] -!37 = metadata !{i32 16, i32 12, metadata !10, null} -!38 = metadata !{i32 16, i32 17, metadata !39, null} -!39 = metadata !{i32 524299, metadata !10, i32 16, i32 15, metadata !1, i32 5} ; [ DW_TAG_lexical_block ] -!40 = metadata !{i32 524545, metadata !11, metadata !"i", metadata !1, i32 17, metadata !41} ; [ DW_TAG_arg_variable ] -!41 = metadata !{i32 524307, metadata !1, metadata !"XYZ", metadata !1, i32 2, i64 160, i64 32, i64 0, i32 0, null, metadata !42, i32 0, null} ; [ DW_TAG_structure_type ] -!42 = metadata !{metadata !43, metadata !44, metadata !45, metadata !46, metadata !47} -!43 = metadata !{i32 524301, metadata !1, metadata !"x", metadata !1, i32 3, i64 32, i64 32, i64 0, i32 0, metadata !5} ; [ DW_TAG_member ] -!44 = metadata !{i32 524301, metadata !1, metadata !"y", metadata !1, i32 4, i64 32, i64 32, i64 32, i32 0, metadata !5} ; [ DW_TAG_member ] -!45 = metadata !{i32 524301, metadata !1, metadata !"z", metadata !1, i32 5, i64 32, i64 32, i64 64, i32 0, metadata !5} ; [ DW_TAG_member ] -!46 = metadata !{i32 524301, metadata !1, metadata !"a", metadata !1, i32 6, i64 32, i64 32, i64 96, i32 0, metadata !5} ; [ DW_TAG_member ] -!47 = metadata !{i32 524301, metadata !1, metadata !"b", metadata !1, i32 7, i64 32, i64 32, i64 128, i32 0, metadata !5} ; [ DW_TAG_member ] -!48 = metadata !{i32 17, i32 19, metadata !11, null} -!49 = metadata !{i32 17, i32 24, metadata !50, null} -!50 = metadata !{i32 524299, metadata !11, i32 17, i32 22, metadata !1, i32 6} ; [ DW_TAG_lexical_block ] -!51 = metadata !{i32 524545, metadata !12, metadata !"i", metadata !1, i32 18, metadata !41} ; [ DW_TAG_arg_variable ] -!52 = metadata !{i32 18, i32 19, metadata !12, null} -!53 = metadata !{i32 18, i32 24, metadata !54, null} -!54 = metadata !{i32 524299, metadata !12, i32 18, i32 22, metadata !1, i32 7} ; [ DW_TAG_lexical_block ] -!55 = metadata !{i32 524545, metadata !13, metadata !"i", metadata !1, i32 19, metadata !41} ; [ DW_TAG_arg_variable ] -!56 = metadata !{i32 19, i32 19, metadata !13, null} -!57 = metadata !{i32 19, i32 24, metadata !58, null} -!58 = metadata !{i32 524299, metadata !13, i32 19, i32 22, metadata !1, i32 8} ; [ DW_TAG_lexical_block ] -!59 = metadata !{i32 524545, metadata !14, metadata !"i", metadata !1, i32 20, metadata !41} ; [ DW_TAG_arg_variable ] -!60 = metadata !{i32 20, i32 20, metadata !14, null} -!61 = metadata !{i32 20, i32 25, metadata !62, null} -!62 = metadata !{i32 524299, metadata !14, i32 20, i32 23, metadata !1, i32 9} ; [ DW_TAG_lexical_block ] -!63 = metadata !{i32 24, i32 3, metadata !64, null} -!64 = metadata !{i32 524299, metadata !15, i32 23, i32 12, metadata !1, i32 10} ; [ DW_TAG_lexical_block ] -!65 = metadata !{i32 25, i32 3, metadata !64, null} -!66 = metadata !{i32 26, i32 3, metadata !64, null} -!67 = metadata !{i32 27, i32 3, metadata !64, null} -!68 = metadata !{i32 28, i32 3, metadata !64, null} -!69 = metadata !{i32 29, i32 3, metadata !64, null} -!70 = metadata !{i32 524544, metadata !64, metadata !"abc", metadata !1, i32 30, metadata !41} ; [ DW_TAG_auto_variable ] -!71 = metadata !{i32 30, i32 14, metadata !64, null} -!72 = metadata !{i32 30, i32 17, metadata !64, null} -!73 = metadata !{i32 31, i32 3, metadata !64, null} -!74 = metadata !{i32 32, i32 3, metadata !64, null} -!75 = metadata !{i32 33, i32 3, metadata !64, null} -!76 = metadata !{i32 34, i32 3, metadata !64, null} -!77 = metadata !{i32 36, i32 3, metadata !64, null} diff --git a/debuginfo-tests/foreach.m b/debuginfo-tests/foreach.m deleted file mode 100644 index 96a0d0cd13f1..000000000000 --- a/debuginfo-tests/foreach.m +++ /dev/null @@ -1,31 +0,0 @@ -// RUN: %clang -O0 -g %s -c -o %t.o -// RUN: %clang %t.o -o %t.out -framework Foundation -// RUN: %test_debuginfo %s %t.out -// XFAIL: * -// XTARGET: darwin -// Radar 8757124 - -// DEBUGGER: break 25 -// DEBUGGER: r -// DEBUGGER: po thing -// CHECK: aaa - -#import - -int main (int argc, const char * argv[]) { - - NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; - NSArray *things = [NSArray arrayWithObjects:@"one", @"two", @"three" , nil]; - for (NSString *thing in things) { - NSLog (@"%@", thing); - } - - things = [NSArray arrayWithObjects:@"aaa", @"bbb", @"ccc" , nil]; - for (NSString *thing in things) { - NSLog (@"%@", thing); - } - [pool release]; - return 0; -} - - diff --git a/debuginfo-tests/forward-declare-class.cpp b/debuginfo-tests/forward-declare-class.cpp deleted file mode 100644 index c133d2c5871e..000000000000 --- a/debuginfo-tests/forward-declare-class.cpp +++ /dev/null @@ -1,24 +0,0 @@ -// RUN: %clangxx -O0 -g %s -c -o %t.o -// RUN: %test_debuginfo %s %t.o -// Radar 9168773 - -// DEBUGGER: ptype A -// CHECK: type = class A { -// CHECK-NEXT: public: -// CHECK-NEXT: int MyData; -// CHECK-NEXT: } -class A; -class B { -public: - void foo(const A *p); -}; - -B iEntry; - -class A { -public: - int MyData; -}; - -A irp; - diff --git a/debuginfo-tests/local-var.ll b/debuginfo-tests/local-var.ll deleted file mode 100644 index ecec8c7ee89d..000000000000 --- a/debuginfo-tests/local-var.ll +++ /dev/null @@ -1,109 +0,0 @@ -; This test case checks handling of llvm.dbg.declare intrinsic during fast-isel. -; RUN: %clang -arch x86_64 -O0 -g %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin - -target triple = "x86_64-apple-darwin10.0.0" - -define i32 @f1() nounwind ssp { -; DEBUGGER: break f1 -; DEBUGGER: r -; DEBUGGER: n -; DEBUGGER: p i -; CHECK: $1 = 42 -entry: - %i = alloca i32, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !10), !dbg !12 - store i32 42, i32* %i, align 4, !dbg !13 - %tmp = load i32* %i, align 4, !dbg !14 - ret i32 %tmp, !dbg !14 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -define i32 @f2() nounwind ssp { -; DEBUGGER: break f2 -; DEBUGGER: c -; DEBUGGER: n -; DEBUGGER: p i -; CHECK: $2 = 42 -entry: - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !15), !dbg !17 - %i = alloca i32, align 4 - store i32 42, i32* %i, align 4, !dbg !18 - %tmp = load i32* %i, align 4, !dbg !19 - ret i32 %tmp, !dbg !19 -} - -; dbg.declare is dropped, as expected, by instruction selector. -; THIS IS NOT EXPECTED TO WORK. -define i32 @f3() nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !20), !dbg !22 - br label %bbr -bbr: - %i = alloca i32, align 4 - store i32 42, i32* %i, align 4, !dbg !23 - %tmp = load i32* %i, align 4, !dbg !24 - ret i32 %tmp, !dbg !24 -} - -; dbg.declare is dropped, as expected, by instruction selector. -; THIS IS NOT EXPECTED TO WORK. -define i32 @f4() nounwind ssp { -entry: - %i = alloca i32, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !25), !dbg !27 - ret i32 42, !dbg !28 -} - -define i32 @main() nounwind ssp { -entry: - %retval = alloca i32, align 4 - store i32 0, i32* %retval - %call = call i32 @f1(), !dbg !29 - %call1 = call i32 @f2(), !dbg !31 - %call2 = call i32 @f3(), !dbg !32 - %call3 = call i32 @f4(), !dbg !33 - ret i32 0, !dbg !34 -} - -!llvm.dbg.sp = !{!0, !6, !7, !8, !9} - -!0 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f1", metadata !"f1", metadata !"f1", metadata !1, i32 2, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f1} ; [ DW_TAG_subprogram ] -!1 = metadata !{i32 524329, metadata !"lv.c", metadata !"dbg_info_bugs", metadata !2} ; [ DW_TAG_file_type ] -!2 = metadata !{i32 524305, i32 0, i32 12, metadata !"lv.c", metadata !"dbg_info_bugs", metadata !"clang version 2.9 (trunk 113428)", i1 true, i1 false, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!3 = metadata !{i32 524309, metadata !1, metadata !"", metadata !1, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !4, i32 0, null} ; [ DW_TAG_subroutine_type ] -!4 = metadata !{metadata !5} -!5 = metadata !{i32 524324, metadata !1, metadata !"int", metadata !1, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!6 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f2", metadata !"f2", metadata !"f2", metadata !1, i32 8, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f2} ; [ DW_TAG_subprogram ] -!7 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f3", metadata !"f3", metadata !"f3", metadata !1, i32 14, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f3} ; [ DW_TAG_subprogram ] -!8 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f4", metadata !"f4", metadata !"f4", metadata !1, i32 20, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f4} ; [ DW_TAG_subprogram ] -!9 = metadata !{i32 524334, i32 0, metadata !1, metadata !"main", metadata !"main", metadata !"main", metadata !1, i32 25, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @main} ; [ DW_TAG_subprogram ] -!10 = metadata !{i32 524544, metadata !11, metadata !"i", metadata !1, i32 3, metadata !5} ; [ DW_TAG_auto_variable ] -!11 = metadata !{i32 524299, metadata !0, i32 2, i32 10, metadata !1, i32 0} ; [ DW_TAG_lexical_block ] -!12 = metadata !{i32 3, i32 7, metadata !11, null} -!13 = metadata !{i32 4, i32 3, metadata !11, null} -!14 = metadata !{i32 5, i32 3, metadata !11, null} -!15 = metadata !{i32 524544, metadata !16, metadata !"i", metadata !1, i32 9, metadata !5} ; [ DW_TAG_auto_variable ] -!16 = metadata !{i32 524299, metadata !6, i32 8, i32 10, metadata !1, i32 1} ; [ DW_TAG_lexical_block ] -!17 = metadata !{i32 9, i32 7, metadata !16, null} -!18 = metadata !{i32 10, i32 3, metadata !16, null} -!19 = metadata !{i32 11, i32 3, metadata !16, null} -!20 = metadata !{i32 524544, metadata !21, metadata !"i", metadata !1, i32 15, metadata !5} ; [ DW_TAG_auto_variable ] -!21 = metadata !{i32 524299, metadata !7, i32 14, i32 10, metadata !1, i32 2} ; [ DW_TAG_lexical_block ] -!22 = metadata !{i32 15, i32 7, metadata !21, null} -!23 = metadata !{i32 16, i32 3, metadata !21, null} -!24 = metadata !{i32 17, i32 3, metadata !21, null} -!25 = metadata !{i32 524544, metadata !26, metadata !"i", metadata !1, i32 21, metadata !5} ; [ DW_TAG_auto_variable ] -!26 = metadata !{i32 524299, metadata !8, i32 20, i32 10, metadata !1, i32 3} ; [ DW_TAG_lexical_block ] -!27 = metadata !{i32 21, i32 7, metadata !26, null} -!28 = metadata !{i32 22, i32 3, metadata !26, null} -!29 = metadata !{i32 26, i32 3, metadata !30, null} -!30 = metadata !{i32 524299, metadata !9, i32 25, i32 12, metadata !1, i32 4} ; [ DW_TAG_lexical_block ] -!31 = metadata !{i32 27, i32 3, metadata !30, null} -!32 = metadata !{i32 28, i32 3, metadata !30, null} -!33 = metadata !{i32 29, i32 3, metadata !30, null} -!34 = metadata !{i32 30, i32 3, metadata !30, null} diff --git a/debuginfo-tests/local-var2.ll b/debuginfo-tests/local-var2.ll deleted file mode 100644 index 37c7a31424ac..000000000000 --- a/debuginfo-tests/local-var2.ll +++ /dev/null @@ -1,109 +0,0 @@ -; This test case checks handling of llvm.dbg.declare intrinsic during isel. -; RUN: %clang -arch x86_64 -O0 -mllvm -fast-isel=false -g %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin - -target triple = "x86_64-apple-darwin10.0.0" - -define i32 @f1() nounwind ssp { -; DEBUGGER: break f1 -; DEBUGGER: r -; DEBUGGER: n -; DEBUGGER: p i -; CHECK: $1 = 42 -entry: - %i = alloca i32, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !10), !dbg !12 - store i32 42, i32* %i, align 4, !dbg !13 - %tmp = load i32* %i, align 4, !dbg !14 - ret i32 %tmp, !dbg !14 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -define i32 @f2() nounwind ssp { -; DEBUGGER: break f2 -; DEBUGGER: c -; DEBUGGER: n -; DEBUGGER: p i -; CHECK: $2 = 42 -entry: - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !15), !dbg !17 - %i = alloca i32, align 4 - store i32 42, i32* %i, align 4, !dbg !18 - %tmp = load i32* %i, align 4, !dbg !19 - ret i32 %tmp, !dbg !19 -} - -; dbg.declare is dropped, as expected, by instruction selector. -; THIS IS NOT EXPECTED TO WORK. -define i32 @f3() nounwind ssp { -entry: - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !20), !dbg !22 - br label %bbr -bbr: - %i = alloca i32, align 4 - store i32 42, i32* %i, align 4, !dbg !23 - %tmp = load i32* %i, align 4, !dbg !24 - ret i32 %tmp, !dbg !24 -} - -; dbg.declare is dropped, as expected, by instruction selector. -; THIS IS NOT EXPECTED TO WORK. -define i32 @f4() nounwind ssp { -entry: - %i = alloca i32, align 4 - call void @llvm.dbg.declare(metadata !{i32* %i}, metadata !25), !dbg !27 - ret i32 42, !dbg !28 -} - -define i32 @main() nounwind ssp { -entry: - %retval = alloca i32, align 4 - store i32 0, i32* %retval - %call = call i32 @f1(), !dbg !29 - %call1 = call i32 @f2(), !dbg !31 - %call2 = call i32 @f3(), !dbg !32 - %call3 = call i32 @f4(), !dbg !33 - ret i32 0, !dbg !34 -} - -!llvm.dbg.sp = !{!0, !6, !7, !8, !9} - -!0 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f1", metadata !"f1", metadata !"f1", metadata !1, i32 2, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f1} ; [ DW_TAG_subprogram ] -!1 = metadata !{i32 524329, metadata !"lv.c", metadata !"dbg_info_bugs", metadata !2} ; [ DW_TAG_file_type ] -!2 = metadata !{i32 524305, i32 0, i32 12, metadata !"lv.c", metadata !"dbg_info_bugs", metadata !"clang version 2.9 (trunk 113428)", i1 true, i1 false, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!3 = metadata !{i32 524309, metadata !1, metadata !"", metadata !1, i32 0, i64 0, i64 0, i64 0, i32 0, null, metadata !4, i32 0, null} ; [ DW_TAG_subroutine_type ] -!4 = metadata !{metadata !5} -!5 = metadata !{i32 524324, metadata !1, metadata !"int", metadata !1, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!6 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f2", metadata !"f2", metadata !"f2", metadata !1, i32 8, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f2} ; [ DW_TAG_subprogram ] -!7 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f3", metadata !"f3", metadata !"f3", metadata !1, i32 14, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f3} ; [ DW_TAG_subprogram ] -!8 = metadata !{i32 524334, i32 0, metadata !1, metadata !"f4", metadata !"f4", metadata !"f4", metadata !1, i32 20, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @f4} ; [ DW_TAG_subprogram ] -!9 = metadata !{i32 524334, i32 0, metadata !1, metadata !"main", metadata !"main", metadata !"main", metadata !1, i32 25, metadata !3, i1 false, i1 true, i32 0, i32 0, null, i1 false, i1 false, i32 ()* @main} ; [ DW_TAG_subprogram ] -!10 = metadata !{i32 524544, metadata !11, metadata !"i", metadata !1, i32 3, metadata !5} ; [ DW_TAG_auto_variable ] -!11 = metadata !{i32 524299, metadata !0, i32 2, i32 10, metadata !1, i32 0} ; [ DW_TAG_lexical_block ] -!12 = metadata !{i32 3, i32 7, metadata !11, null} -!13 = metadata !{i32 4, i32 3, metadata !11, null} -!14 = metadata !{i32 5, i32 3, metadata !11, null} -!15 = metadata !{i32 524544, metadata !16, metadata !"i", metadata !1, i32 9, metadata !5} ; [ DW_TAG_auto_variable ] -!16 = metadata !{i32 524299, metadata !6, i32 8, i32 10, metadata !1, i32 1} ; [ DW_TAG_lexical_block ] -!17 = metadata !{i32 9, i32 7, metadata !16, null} -!18 = metadata !{i32 10, i32 3, metadata !16, null} -!19 = metadata !{i32 11, i32 3, metadata !16, null} -!20 = metadata !{i32 524544, metadata !21, metadata !"i", metadata !1, i32 15, metadata !5} ; [ DW_TAG_auto_variable ] -!21 = metadata !{i32 524299, metadata !7, i32 14, i32 10, metadata !1, i32 2} ; [ DW_TAG_lexical_block ] -!22 = metadata !{i32 15, i32 7, metadata !21, null} -!23 = metadata !{i32 16, i32 3, metadata !21, null} -!24 = metadata !{i32 17, i32 3, metadata !21, null} -!25 = metadata !{i32 524544, metadata !26, metadata !"i", metadata !1, i32 21, metadata !5} ; [ DW_TAG_auto_variable ] -!26 = metadata !{i32 524299, metadata !8, i32 20, i32 10, metadata !1, i32 3} ; [ DW_TAG_lexical_block ] -!27 = metadata !{i32 21, i32 7, metadata !26, null} -!28 = metadata !{i32 22, i32 3, metadata !26, null} -!29 = metadata !{i32 26, i32 3, metadata !30, null} -!30 = metadata !{i32 524299, metadata !9, i32 25, i32 12, metadata !1, i32 4} ; [ DW_TAG_lexical_block ] -!31 = metadata !{i32 27, i32 3, metadata !30, null} -!32 = metadata !{i32 28, i32 3, metadata !30, null} -!33 = metadata !{i32 29, i32 3, metadata !30, null} -!34 = metadata !{i32 30, i32 3, metadata !30, null} diff --git a/debuginfo-tests/nested-struct.cpp b/debuginfo-tests/nested-struct.cpp deleted file mode 100644 index 5a626c5418fb..000000000000 --- a/debuginfo-tests/nested-struct.cpp +++ /dev/null @@ -1,21 +0,0 @@ -// RUN: %clangxx -O0 -g %s -c -o %t.o -// RUN: %test_debuginfo %s %t.o -// Radar 9440721 -// If debug info for my_number() is emitted outside function foo's scope -// then a debugger may not be able to handle it. At least one version of -// gdb crashes in such cases. - -// DEBUGGER: ptype foo -// CHECK: type = int (void) - -int foo() { - struct Local { - static int my_number() { - return 42; - } - }; - - int i = 0; - i = Local::my_number(); - return i + 1; -} diff --git a/debuginfo-tests/sret.cpp b/debuginfo-tests/sret.cpp deleted file mode 100644 index 90145f8c194c..000000000000 --- a/debuginfo-tests/sret.cpp +++ /dev/null @@ -1,71 +0,0 @@ -// RUN: %clangxx -O0 -g %s -c -o %t.o -// RUN: %clangxx %t.o -o %t.out -// RUN: %test_debuginfo %s %t.out -// Radar 8775834 -// DEBUGGER: break 61 -// DEBUGGER: r -// DEBUGGER: p a -// CHECK: $1 = (A &) -// CHECK: _vptr$A = -// CHECK: m_int = 12 - -class A -{ -public: - A (int i=0); - A (const A& rhs); - const A& - operator= (const A& rhs); - virtual ~A() {} - - int get_int(); - -protected: - int m_int; -}; - -A::A (int i) : - m_int(i) -{ -} - -A::A (const A& rhs) : - m_int (rhs.m_int) -{ -} - -const A & -A::operator =(const A& rhs) -{ - m_int = rhs.m_int; - return *this; -} - -int A::get_int() -{ - return m_int; -} - -class B -{ -public: - B () {} - - A AInstance(); -}; - -A -B::AInstance() -{ - A a(12); - return a; -} - -int main (int argc, char const *argv[]) -{ - B b; - int return_val = b.AInstance().get_int(); - - A a(b.AInstance()); - return return_val; -} diff --git a/debuginfo-tests/unused-boolean-arg.ll b/debuginfo-tests/unused-boolean-arg.ll deleted file mode 100644 index 77c31f5e7557..000000000000 --- a/debuginfo-tests/unused-boolean-arg.ll +++ /dev/null @@ -1,84 +0,0 @@ -; This test checks debug info of unused, zero extended argument. -; RUN: %clang -arch x86_64 -mllvm -fast-isel=false %s -c -o %t.o -; RUN: %clang -arch x86_64 %t.o -o %t.out -; RUN: %test_debuginfo %s %t.out -; XFAIL: * -; XTARGET: darwin -; Radar 9422775 - -target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" -target triple = "x86_64-apple-macosx10.6.7" - -%class.aClass = type { float } - -; DEBUGGER: break aClass::setValues -; DEBUGGER: r -; DEBUGGER: p Filter -; CHECK: true - -define void @_ZN6aClass9setValuesEibf(%class.aClass* nocapture %this, i32 %ch, i1 zeroext %Filter, float %a1) nounwind noinline ssp align 2 { -entry: - tail call void @llvm.dbg.value(metadata !{%class.aClass* %this}, i64 0, metadata !19), !dbg !25 - tail call void @llvm.dbg.value(metadata !{i32 %ch}, i64 0, metadata !20), !dbg !26 - tail call void @llvm.dbg.value(metadata !{i1 %Filter}, i64 0, metadata !21), !dbg !27 - tail call void @llvm.dbg.value(metadata !{float %a1}, i64 0, metadata !22), !dbg !28 - %m = getelementptr inbounds %class.aClass* %this, i64 0, i32 0, !dbg !29 - store float %a1, float* %m, align 4, !dbg !29, !tbaa !31 - ret void, !dbg !34 -} - -declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone - -define i32 @main() nounwind ssp { -entry: - %a = alloca %class.aClass, align 4 - call void @llvm.dbg.declare(metadata !{%class.aClass* %a}, metadata !23), !dbg !35 - call void @_ZN6aClass9setValuesEibf(%class.aClass* %a, i32 undef, i1 zeroext 1, float 1.000000e+00), !dbg !36 - ret i32 0, !dbg !37 -} - -declare void @llvm.dbg.value(metadata, i64, metadata) nounwind readnone - -!llvm.dbg.cu = !{!0} -!llvm.dbg.sp = !{!1, !12, !16} -!llvm.dbg.lv._ZN6aClass9setValuesEibf = !{!19, !20, !21, !22} -!llvm.dbg.lv.main = !{!23} - -!0 = metadata !{i32 589841, i32 0, i32 4, metadata !"two.cpp", metadata !"/private/tmp/inc", metadata !"clang version 3.0 (trunk 131411)", i1 true, i1 true, metadata !"", i32 0} ; [ DW_TAG_compile_unit ] -!1 = metadata !{i32 589870, i32 0, metadata !2, metadata !"setValues", metadata !"setValues", metadata !"_ZN6aClass9setValuesEibf", metadata !3, i32 6, metadata !7, i1 false, i1 false, i32 0, i32 0, null, i32 256, i1 true, null, null} ; [ DW_TAG_subprogram ] -!2 = metadata !{i32 589826, metadata !0, metadata !"aClass", metadata !3, i32 2, i64 32, i64 32, i32 0, i32 0, null, metadata !4, i32 0, null, null} ; [ DW_TAG_class_type ] -!3 = metadata !{i32 589865, metadata !"./one.h", metadata !"/private/tmp/inc", metadata !0} ; [ DW_TAG_file_type ] -!4 = metadata !{metadata !5, metadata !1} -!5 = metadata !{i32 589837, metadata !3, metadata !"m", metadata !3, i32 4, i64 32, i64 32, i64 0, i32 1, metadata !6} ; [ DW_TAG_member ] -!6 = metadata !{i32 589860, metadata !0, metadata !"float", null, i32 0, i64 32, i64 32, i64 0, i32 0, i32 4} ; [ DW_TAG_base_type ] -!7 = metadata !{i32 589845, metadata !3, metadata !"", metadata !3, i32 0, i64 0, i64 0, i32 0, i32 0, i32 0, metadata !8, i32 0, i32 0} ; [ DW_TAG_subroutine_type ] -!8 = metadata !{null, metadata !9, metadata !10, metadata !11, metadata !6} -!9 = metadata !{i32 589839, metadata !0, metadata !"", i32 0, i32 0, i64 64, i64 64, i64 0, i32 64, metadata !2} ; [ DW_TAG_pointer_type ] -!10 = metadata !{i32 589860, metadata !0, metadata !"int", null, i32 0, i64 32, i64 32, i64 0, i32 0, i32 5} ; [ DW_TAG_base_type ] -!11 = metadata !{i32 589860, metadata !0, metadata !"bool", null, i32 0, i64 8, i64 8, i64 0, i32 0, i32 2} ; [ DW_TAG_base_type ] -!12 = metadata !{i32 589870, i32 0, metadata !13, metadata !"setValues", metadata !"setValues", metadata !"_ZN6aClass9setValuesEibf", metadata !13, i32 4, metadata !14, i1 false, i1 true, i32 0, i32 0, i32 0, i32 256, i1 true, void (%class.aClass*, i32, i1, float)* @_ZN6aClass9setValuesEibf, null, metadata !1} ; [ DW_TAG_subprogram ] -!13 = metadata !{i32 589865, metadata !"two.cpp", metadata !"/private/tmp/inc", metadata !0} ; [ DW_TAG_file_type ] -!14 = metadata !{i32 589845, metadata !13, metadata !"", metadata !13, i32 0, i64 0, i64 0, i32 0, i32 0, i32 0, metadata !15, i32 0, i32 0} ; [ DW_TAG_subroutine_type ] -!15 = metadata !{null} -!16 = metadata !{i32 589870, i32 0, metadata !13, metadata !"main", metadata !"main", metadata !"", metadata !13, i32 9, metadata !17, i1 false, i1 true, i32 0, i32 0, i32 0, i32 256, i1 true, i32 ()* @main, null, null} ; [ DW_TAG_subprogram ] -!17 = metadata !{i32 589845, metadata !13, metadata !"", metadata !13, i32 0, i64 0, i64 0, i32 0, i32 0, i32 0, metadata !18, i32 0, i32 0} ; [ DW_TAG_subroutine_type ] -!18 = metadata !{metadata !10} -!19 = metadata !{i32 590081, metadata !12, metadata !"this", metadata !13, i32 16777219, metadata !9, i32 64} ; [ DW_TAG_arg_variable ] -!20 = metadata !{i32 590081, metadata !12, metadata !"ch", metadata !13, i32 33554435, metadata !10, i32 0} ; [ DW_TAG_arg_variable ] -!21 = metadata !{i32 590081, metadata !12, metadata !"Filter", metadata !13, i32 50331651, metadata !11, i32 0} ; [ DW_TAG_arg_variable ] -!22 = metadata !{i32 590081, metadata !12, metadata !"a1", metadata !13, i32 67108867, metadata !6, i32 0} ; [ DW_TAG_arg_variable ] -!23 = metadata !{i32 590080, metadata !24, metadata !"a", metadata !13, i32 10, metadata !2, i32 0} ; [ DW_TAG_auto_variable ] -!24 = metadata !{i32 589835, metadata !16, i32 9, i32 1, metadata !13, i32 1} ; [ DW_TAG_lexical_block ] -!25 = metadata !{i32 3, i32 40, metadata !12, null} -!26 = metadata !{i32 3, i32 54, metadata !12, null} -!27 = metadata !{i32 3, i32 63, metadata !12, null} -!28 = metadata !{i32 3, i32 77, metadata !12, null} -!29 = metadata !{i32 5, i32 2, metadata !30, null} -!30 = metadata !{i32 589835, metadata !12, i32 4, i32 1, metadata !13, i32 0} ; [ DW_TAG_lexical_block ] -!31 = metadata !{metadata !"float", metadata !32} -!32 = metadata !{metadata !"omnipotent char", metadata !33} -!33 = metadata !{metadata !"Simple C/C++ TBAA", null} -!34 = metadata !{i32 6, i32 1, metadata !30, null} -!35 = metadata !{i32 10, i32 11, metadata !24, null} -!36 = metadata !{i32 11, i32 4, metadata !24, null} -!37 = metadata !{i32 12, i32 4, metadata !24, null} diff --git a/libclc/CREDITS.TXT b/libclc/CREDITS.TXT deleted file mode 100644 index b18d40bd7339..000000000000 --- a/libclc/CREDITS.TXT +++ /dev/null @@ -1,2 +0,0 @@ -N: Peter Collingbourne -E: peter@pcc.me.uk diff --git a/libclc/LICENSE.TXT b/libclc/LICENSE.TXT deleted file mode 100644 index e4df97bb02da..000000000000 --- a/libclc/LICENSE.TXT +++ /dev/null @@ -1,64 +0,0 @@ -============================================================================== -libclc License -============================================================================== - -The libclc library is dual licensed under both the University of Illinois -"BSD-Like" license and the MIT license. As a user of this code you may choose -to use it under either license. As a contributor, you agree to allow your code -to be used under both. - -Full text of the relevant licenses is included below. - -============================================================================== - -Copyright (c) 2011-2012 by the contributors listed in CREDITS.TXT - -All rights reserved. - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal with -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: - - * Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimers. - - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimers in the - documentation and/or other materials provided with the distribution. - - * The names of the contributors may not be used to endorse or promote - products derived from this Software without specific prior written - permission. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE -SOFTWARE. - -============================================================================== - -Copyright (c) 2011-2012 by the contributors listed in CREDITS.TXT - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/libclc/README.TXT b/libclc/README.TXT deleted file mode 100644 index 40eddb31e1cb..000000000000 --- a/libclc/README.TXT +++ /dev/null @@ -1,37 +0,0 @@ -libclc ------- - -libclc is an open source, BSD licensed implementation of the library -requirements of the OpenCL C programming language, as specified by the -OpenCL 1.1 Specification. The following sections of the specification -impose library requirements: - - * 6.1: Supported Data Types - * 6.2.3: Explicit Conversions - * 6.2.4.2: Reinterpreting Types Using as_type() and as_typen() - * 6.9: Preprocessor Directives and Macros - * 6.11: Built-in Functions - * 9.3: Double Precision Floating-Point - * 9.4: 64-bit Atomics - * 9.5: Writing to 3D image memory objects - * 9.6: Half Precision Floating-Point - -libclc is intended to be used with the Clang compiler's OpenCL frontend. - -libclc is designed to be portable and extensible. To this end, it provides -generic implementations of most library requirements, allowing the target -to override the generic implementation at the granularity of individual -functions. - -libclc currently only supports the PTX target, but support for more -targets is welcome. - -Compiling ---------- - -./configure.py --with-llvm-config=/path/to/llvm-config && make - -Website -------- - -http://www.pcc.me.uk/~peter/libclc/ diff --git a/libclc/build/metabuild.py b/libclc/build/metabuild.py deleted file mode 100644 index 65870acda8d1..000000000000 --- a/libclc/build/metabuild.py +++ /dev/null @@ -1,91 +0,0 @@ -import ninja_syntax -import os - -# Simple meta-build system. - -class Make(object): - def __init__(self): - self.output = open(self.output_filename(), 'w') - self.rules = {} - self.rule_text = '' - self.all_targets = [] - self.clean_files = [] - self.distclean_files = [] - self.output.write("""all:: - -ifndef VERBOSE - Verb = @ -endif - -""") - - def output_filename(self): - return 'Makefile' - - def rule(self, name, command, description=None, depfile=None, - generator=False): - self.rules[name] = {'command': command, 'description': description, - 'depfile': depfile, 'generator': generator} - - def build(self, output, rule, inputs=[], implicit=[], order_only=[]): - inputs = self._as_list(inputs) - implicit = self._as_list(implicit) - order_only = self._as_list(order_only) - - output_dir = os.path.dirname(output) - if output_dir != '' and not os.path.isdir(output_dir): - os.makedirs(output_dir) - - dollar_in = ' '.join(inputs) - subst = lambda text: text.replace('$in', dollar_in).replace('$out', output) - - deps = ' '.join(inputs + implicit) - if order_only: - deps += ' | ' - deps += ' '.join(order_only) - self.output.write('%s: %s\n' % (output, deps)) - - r = self.rules[rule] - command = subst(r['command']) - if r['description']: - desc = subst(r['description']) - self.output.write('\t@echo %s\n\t$(Verb) %s\n' % (desc, command)) - else: - self.output.write('\t%s\n' % command) - if r['depfile']: - depfile = subst(r['depfile']) - self.output.write('-include '+depfile+'\n') - self.output.write('\n') - - self.all_targets.append(output) - if r['generator']: - self.distclean_files.append(output) - else: - self.clean_files.append(output) - - def _as_list(self, input): - if isinstance(input, list): - return input - return [input] - - def finish(self): - self.output.write('all:: %s\n\n' % ' '.join(self.all_targets)) - self.output.write('clean: \n\trm -f %s\n\n' % ' '.join(self.clean_files)) - self.output.write('distclean: clean\n\trm -f %s\n' % ' '.join(self.distclean_files)) - -class Ninja(ninja_syntax.Writer): - def __init__(self): - ninja_syntax.Writer.__init__(self, open(self.output_filename(), 'w')) - - def output_filename(self): - return 'build.ninja' - - def finish(self): - pass - -def from_name(name): - if name == 'make': - return Make() - if name == 'ninja': - return Ninja() - raise LookupError, 'unknown generator: %s; supported generators are make and ninja' % name diff --git a/libclc/build/ninja_syntax.py b/libclc/build/ninja_syntax.py deleted file mode 100644 index 6e8a87c74068..000000000000 --- a/libclc/build/ninja_syntax.py +++ /dev/null @@ -1,110 +0,0 @@ -#!/usr/bin/python - -"""Python module for generating .ninja files. - -Note that this is emphatically not a required piece of Ninja; it's -just a helpful utility for build-file-generation systems that already -use Python. -""" - -import textwrap - -class Writer(object): - def __init__(self, output, width=78): - self.output = output - self.width = width - - def newline(self): - self.output.write('\n') - - def comment(self, text): - for line in textwrap.wrap(text, self.width - 2): - self.output.write('# ' + line + '\n') - - def variable(self, key, value, indent=0): - if value is None: - return - if isinstance(value, list): - value = ' '.join(value) - self._line('%s = %s' % (key, value), indent) - - def rule(self, name, command, description=None, depfile=None, - generator=False): - self._line('rule %s' % name) - self.variable('command', command, indent=1) - if description: - self.variable('description', description, indent=1) - if depfile: - self.variable('depfile', depfile, indent=1) - if generator: - self.variable('generator', '1', indent=1) - - def build(self, outputs, rule, inputs=None, implicit=None, order_only=None, - variables=None): - outputs = self._as_list(outputs) - all_inputs = self._as_list(inputs)[:] - - if implicit: - all_inputs.append('|') - all_inputs.extend(self._as_list(implicit)) - if order_only: - all_inputs.append('||') - all_inputs.extend(self._as_list(order_only)) - - self._line('build %s: %s %s' % (' '.join(outputs), - rule, - ' '.join(all_inputs))) - - if variables: - for key, val in variables: - self.variable(key, val, indent=1) - - return outputs - - def include(self, path): - self._line('include %s' % path) - - def subninja(self, path): - self._line('subninja %s' % path) - - def default(self, paths): - self._line('default %s' % ' '.join(self._as_list(paths))) - - def _line(self, text, indent=0): - """Write 'text' word-wrapped at self.width characters.""" - leading_space = ' ' * indent - while len(text) > self.width: - # The text is too wide; wrap if possible. - - # Find the rightmost space that would obey our width constraint. - available_space = self.width - len(leading_space) - len(' $') - space = text.rfind(' ', 0, available_space) - if space < 0: - # No such space; just use the first space we can find. - space = text.find(' ', available_space) - if space < 0: - # Give up on breaking. - break - - self.output.write(leading_space + text[0:space] + ' $\n') - text = text[space+1:] - - # Subsequent lines are continuations, so indent them. - leading_space = ' ' * (indent+2) - - self.output.write(leading_space + text + '\n') - - def _as_list(self, input): - if input is None: - return [] - if isinstance(input, list): - return input - return [input] - - -def escape(string): - """Escape a string such that it can be embedded into a Ninja file without - further interpretation.""" - assert '\n' not in string, 'Ninja syntax does not allow newlines' - # We only have one special metacharacter: '$'. - return string.replace('$', '$$') diff --git a/libclc/compile-test.sh b/libclc/compile-test.sh deleted file mode 100755 index f322fbd57ef3..000000000000 --- a/libclc/compile-test.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh - -clang -ccc-host-triple ptx32--nvidiacl -Iptx-nvidiacl/include -Igeneric/include -Xclang -mlink-bitcode-file -Xclang ptx32--nvidiacl/lib/builtins.bc -include clc/clc.h -Dcl_clang_storage_class_specifiers "$@" diff --git a/libclc/configure.py b/libclc/configure.py deleted file mode 100755 index 310122be4356..000000000000 --- a/libclc/configure.py +++ /dev/null @@ -1,133 +0,0 @@ -#!/usr/bin/python - -def c_compiler_rule(b, name, description, compiler, flags): - command = "%s -MMD -MF $out.d %s -c -o $out $in" % (compiler, flags) - b.rule(name, command, description + " $out", depfile="$out.d") - -from optparse import OptionParser -import os -from subprocess import * -import sys - -srcdir = os.path.dirname(sys.argv[0]) - -sys.path.insert(0, os.path.join(srcdir, 'build')) -import metabuild - -p = OptionParser() -p.add_option('--with-llvm-config', metavar='PATH', - help='use given llvm-config script') -p.add_option('-g', metavar='GENERATOR', default='make', - help='use given generator (default: make)') -(options, args) = p.parse_args() - -llvm_config_exe = options.with_llvm_config or "llvm-config" - -def llvm_config(args): - try: - proc = Popen([llvm_config_exe] + args, stdout=PIPE) - return proc.communicate()[0].rstrip().replace('\n', ' ') - except OSError: - print "Error executing llvm-config." - print "Please ensure that llvm-config is in your $PATH, or use --with-llvm-config." - sys.exit(1) - -llvm_bindir = llvm_config(['--bindir']) -llvm_core_libs = llvm_config(['--ldflags', '--libs', 'core', 'bitreader', 'bitwriter']) -llvm_cxxflags = llvm_config(['--cxxflags']) + ' -fno-exceptions -fno-rtti' - -llvm_clang = os.path.join(llvm_bindir, 'clang') -llvm_link = os.path.join(llvm_bindir, 'llvm-link') -llvm_opt = os.path.join(llvm_bindir, 'opt') - -default_targets = ['ptx32--nvidiacl', 'ptx64--nvidiacl'] - -targets = args -if not targets: - targets = default_targets - -b = metabuild.from_name(options.g) - -b.rule("LLVM_AS", "%s -o $out $in" % os.path.join(llvm_bindir, "llvm-as"), - 'LLVM-AS $out') -b.rule("LLVM_LINK", command = llvm_link + " -o $out $in", - description = 'LLVM-LINK $out') -b.rule("OPT", command = llvm_opt + " -O3 -o $out $in", - description = 'OPT $out') - -c_compiler_rule(b, "LLVM_TOOL_CXX", 'CXX', 'c++', llvm_cxxflags) -b.rule("LLVM_TOOL_LINK", "c++ -o $out $in %s" % llvm_core_libs, 'LINK $out') - -prepare_builtins = os.path.join('utils', 'prepare-builtins') -b.build(os.path.join('utils', 'prepare-builtins.o'), "LLVM_TOOL_CXX", - os.path.join(srcdir, 'utils', 'prepare-builtins.cpp')) -b.build(prepare_builtins, "LLVM_TOOL_LINK", - os.path.join('utils', 'prepare-builtins.o')) - -b.rule("PREPARE_BUILTINS", "%s -o $out $in" % prepare_builtins, - 'PREPARE-BUILTINS $out') - -manifest_deps = set([sys.argv[0], os.path.join(srcdir, 'build', 'metabuild.py'), - os.path.join(srcdir, 'build', 'ninja_syntax.py')]) - -for target in targets: - (t_arch, t_vendor, t_os) = target.split('-') - archs = [t_arch] - if t_arch == 'ptx32' or t_arch == 'ptx64': - archs.append('ptx') - archs.append('generic') - - subdirs = [] - for arch in archs: - subdirs.append("%s-%s-%s" % (arch, t_vendor, t_os)) - subdirs.append("%s-%s" % (arch, t_os)) - subdirs.append(arch) - - subdirs = [subdir for subdir in subdirs - if os.path.isdir(os.path.join(srcdir, subdir, 'include')) or - os.path.isfile(os.path.join(srcdir, subdir, 'lib', 'SOURCES'))] - - clang_cl_includes = ' '.join(["-I%s" % os.path.join(srcdir, subdir, 'include') - for subdir in subdirs]) - - # The rule for building a .bc file for the specified architecture using clang. - clang_bc_flags = "-ccc-host-triple %s -I`dirname $in` %s " \ - "-Dcl_clang_storage_class_specifiers " \ - "-emit-llvm" % (target, clang_cl_includes) - clang_bc_rule = "CLANG_CL_BC_" + target - c_compiler_rule(b, clang_bc_rule, "LLVM-CC", llvm_clang, clang_bc_flags) - - objects = [] - sources_seen = set() - - for subdir in subdirs: - src_libdir = os.path.join(srcdir, subdir, 'lib') - if not os.path.isdir(src_libdir): - continue - subdir_list_file = os.path.join(src_libdir, 'SOURCES') - manifest_deps.add(subdir_list_file) - for src in open(subdir_list_file).readlines(): - src = src.rstrip() - if src not in sources_seen: - sources_seen.add(src) - obj = os.path.join(target, 'lib', src + '.bc') - objects.append(obj) - src_file = os.path.join(src_libdir, src) - ext = os.path.splitext(src)[1] - if ext == '.ll': - b.build(obj, 'LLVM_AS', src_file) - else: - b.build(obj, clang_bc_rule, src_file) - - builtins_link_bc = os.path.join(target, 'lib', 'builtins.link.bc') - builtins_opt_bc = os.path.join(target, 'lib', 'builtins.opt.bc') - builtins_bc = os.path.join(target, 'lib', 'builtins.bc') - b.build(builtins_link_bc, "LLVM_LINK", objects) - b.build(builtins_opt_bc, "OPT", builtins_link_bc) - b.build(builtins_bc, "PREPARE_BUILTINS", builtins_opt_bc, prepare_builtins) - -b.rule("configure", command = ' '.join(sys.argv), description = 'CONFIGURE', - generator = True) -b.build(b.output_filename(), 'configure', list(manifest_deps)) - -b.finish() diff --git a/libclc/generic/include/clc/as_type.h b/libclc/generic/include/clc/as_type.h deleted file mode 100644 index ef7b2b17c8d0..000000000000 --- a/libclc/generic/include/clc/as_type.h +++ /dev/null @@ -1,53 +0,0 @@ -#define as_char(x) __builtin_astype(x, char) -#define as_uchar(x) __builtin_astype(x, uchar) -#define as_short(x) __builtin_astype(x, short) -#define as_ushort(x) __builtin_astype(x, ushort) -#define as_int(x) __builtin_astype(x, int) -#define as_uint(x) __builtin_astype(x, uint) -#define as_long(x) __builtin_astype(x, long) -#define as_ulong(x) __builtin_astype(x, ulong) - -#define as_char2(x) __builtin_astype(x, char2) -#define as_uchar2(x) __builtin_astype(x, uchar2) -#define as_short2(x) __builtin_astype(x, short2) -#define as_ushort2(x) __builtin_astype(x, ushort2) -#define as_int2(x) __builtin_astype(x, int2) -#define as_uint2(x) __builtin_astype(x, uint2) -#define as_long2(x) __builtin_astype(x, long2) -#define as_ulong2(x) __builtin_astype(x, ulong2) - -#define as_char3(x) __builtin_astype(x, char3) -#define as_uchar3(x) __builtin_astype(x, uchar3) -#define as_short3(x) __builtin_astype(x, short3) -#define as_ushort3(x) __builtin_astype(x, ushort3) -#define as_int3(x) __builtin_astype(x, int3) -#define as_uint3(x) __builtin_astype(x, uint3) -#define as_long3(x) __builtin_astype(x, long3) -#define as_ulong3(x) __builtin_astype(x, ulong3) - -#define as_char4(x) __builtin_astype(x, char4) -#define as_uchar4(x) __builtin_astype(x, uchar4) -#define as_short4(x) __builtin_astype(x, short4) -#define as_ushort4(x) __builtin_astype(x, ushort4) -#define as_int4(x) __builtin_astype(x, int4) -#define as_uint4(x) __builtin_astype(x, uint4) -#define as_long4(x) __builtin_astype(x, long4) -#define as_ulong4(x) __builtin_astype(x, ulong4) - -#define as_char8(x) __builtin_astype(x, char8) -#define as_uchar8(x) __builtin_astype(x, uchar8) -#define as_short8(x) __builtin_astype(x, short8) -#define as_ushort8(x) __builtin_astype(x, ushort8) -#define as_int8(x) __builtin_astype(x, int8) -#define as_uint8(x) __builtin_astype(x, uint8) -#define as_long8(x) __builtin_astype(x, long8) -#define as_ulong8(x) __builtin_astype(x, ulong8) - -#define as_char16(x) __builtin_astype(x, char16) -#define as_uchar16(x) __builtin_astype(x, uchar16) -#define as_short16(x) __builtin_astype(x, short16) -#define as_ushort16(x) __builtin_astype(x, ushort16) -#define as_int16(x) __builtin_astype(x, int16) -#define as_uint16(x) __builtin_astype(x, uint16) -#define as_long16(x) __builtin_astype(x, long16) -#define as_ulong16(x) __builtin_astype(x, ulong16) diff --git a/libclc/generic/include/clc/clc.h b/libclc/generic/include/clc/clc.h deleted file mode 100644 index 983884b8f786..000000000000 --- a/libclc/generic/include/clc/clc.h +++ /dev/null @@ -1,57 +0,0 @@ -#ifndef cl_clang_storage_class_specifiers -#error Implementation requires cl_clang_storage_class_specifiers extension! -#endif - -#pragma OPENCL EXTENSION cl_clang_storage_class_specifiers : enable - -#ifdef cl_khr_fp64 -#pragma OPENCL EXTENSION cl_khr_fp64 : enable -#endif - -/* Function Attributes */ -#include - -/* Pattern Macro Definitions */ -#include - -/* 6.1 Supported Data Types */ -#include - -/* 6.2.4.2 Reinterpreting Types Using as_type() and as_typen() */ -#include - -/* 6.11.1 Work-Item Functions */ -#include -#include -#include -#include -#include -#include - -/* 6.11.2 Math Functions */ -#include -#include -#include -#include -#include -#include -#include - -/* 6.11.3 Integer Functions */ -#include -#include -#include - -/* 6.11.5 Geometric Functions */ -#include -#include -#include - -/* 6.11.6 Relational Functions */ -#include - -/* 6.11.8 Synchronization Functions */ -#include -#include - -#pragma OPENCL EXTENSION all : disable diff --git a/libclc/generic/include/clc/clcfunc.h b/libclc/generic/include/clc/clcfunc.h deleted file mode 100644 index 46067fc47ed0..000000000000 --- a/libclc/generic/include/clc/clcfunc.h +++ /dev/null @@ -1,4 +0,0 @@ -#define _CLC_OVERLOAD __attribute__((overloadable)) -#define _CLC_DECL -#define _CLC_DEF __attribute__((always_inline)) -#define _CLC_INLINE __attribute__((always_inline)) static inline diff --git a/libclc/generic/include/clc/clcmacro.h b/libclc/generic/include/clc/clcmacro.h deleted file mode 100644 index d10a613d1a66..000000000000 --- a/libclc/generic/include/clc/clcmacro.h +++ /dev/null @@ -1,42 +0,0 @@ -#define _CLC_UNARY_VECTORIZE(DECLSPEC, RET_TYPE, FUNCTION, ARG1_TYPE) \ - DECLSPEC RET_TYPE##2 FUNCTION(ARG1_TYPE##2 x) { \ - return (RET_TYPE##2)(FUNCTION(x.x), FUNCTION(x.y)); \ - } \ -\ - DECLSPEC RET_TYPE##3 FUNCTION(ARG1_TYPE##3 x) { \ - return (RET_TYPE##3)(FUNCTION(x.x), FUNCTION(x.y), FUNCTION(x.z)); \ - } \ -\ - DECLSPEC RET_TYPE##4 FUNCTION(ARG1_TYPE##4 x) { \ - return (RET_TYPE##4)(FUNCTION(x.lo), FUNCTION(x.hi)); \ - } \ -\ - DECLSPEC RET_TYPE##8 FUNCTION(ARG1_TYPE##8 x) { \ - return (RET_TYPE##8)(FUNCTION(x.lo), FUNCTION(x.hi)); \ - } \ -\ - DECLSPEC RET_TYPE##16 FUNCTION(ARG1_TYPE##16 x) { \ - return (RET_TYPE##16)(FUNCTION(x.lo), FUNCTION(x.hi)); \ - } - -#define _CLC_BINARY_VECTORIZE(DECLSPEC, RET_TYPE, FUNCTION, ARG1_TYPE, ARG2_TYPE) \ - DECLSPEC RET_TYPE##2 FUNCTION(ARG1_TYPE##2 x, ARG2_TYPE##2 y) { \ - return (RET_TYPE##2)(FUNCTION(x.x, y.x), FUNCTION(x.y, y.y)); \ - } \ -\ - DECLSPEC RET_TYPE##3 FUNCTION(ARG1_TYPE##3 x, ARG2_TYPE##3 y) { \ - return (RET_TYPE##3)(FUNCTION(x.x, y.x), FUNCTION(x.y, y.y), \ - FUNCTION(x.z, y.z)); \ - } \ -\ - DECLSPEC RET_TYPE##4 FUNCTION(ARG1_TYPE##4 x, ARG2_TYPE##4 y) { \ - return (RET_TYPE##4)(FUNCTION(x.lo, y.lo), FUNCTION(x.hi, y.hi)); \ - } \ -\ - DECLSPEC RET_TYPE##8 FUNCTION(ARG1_TYPE##8 x, ARG2_TYPE##8 y) { \ - return (RET_TYPE##8)(FUNCTION(x.lo, y.lo), FUNCTION(x.hi, y.hi)); \ - } \ -\ - DECLSPEC RET_TYPE##16 FUNCTION(ARG1_TYPE##16 x, ARG2_TYPE##16 y) { \ - return (RET_TYPE##16)(FUNCTION(x.lo, y.lo), FUNCTION(x.hi, y.hi)); \ - } diff --git a/libclc/generic/include/clc/clctypes.h b/libclc/generic/include/clc/clctypes.h deleted file mode 100644 index ca729f76fd3d..000000000000 --- a/libclc/generic/include/clc/clctypes.h +++ /dev/null @@ -1,74 +0,0 @@ -/* 6.1.1 Built-in Scalar Data Types */ - -#include - -typedef unsigned char uchar; -typedef unsigned short ushort; -typedef unsigned int uint; -typedef unsigned long ulong; - -/* 6.1.2 Built-in Vector Data Types */ - -typedef __attribute__((ext_vector_type(2))) char char2; -typedef __attribute__((ext_vector_type(3))) char char3; -typedef __attribute__((ext_vector_type(4))) char char4; -typedef __attribute__((ext_vector_type(8))) char char8; -typedef __attribute__((ext_vector_type(16))) char char16; - -typedef __attribute__((ext_vector_type(2))) uchar uchar2; -typedef __attribute__((ext_vector_type(3))) uchar uchar3; -typedef __attribute__((ext_vector_type(4))) uchar uchar4; -typedef __attribute__((ext_vector_type(8))) uchar uchar8; -typedef __attribute__((ext_vector_type(16))) uchar uchar16; - -typedef __attribute__((ext_vector_type(2))) short short2; -typedef __attribute__((ext_vector_type(3))) short short3; -typedef __attribute__((ext_vector_type(4))) short short4; -typedef __attribute__((ext_vector_type(8))) short short8; -typedef __attribute__((ext_vector_type(16))) short short16; - -typedef __attribute__((ext_vector_type(2))) ushort ushort2; -typedef __attribute__((ext_vector_type(3))) ushort ushort3; -typedef __attribute__((ext_vector_type(4))) ushort ushort4; -typedef __attribute__((ext_vector_type(8))) ushort ushort8; -typedef __attribute__((ext_vector_type(16))) ushort ushort16; - -typedef __attribute__((ext_vector_type(2))) int int2; -typedef __attribute__((ext_vector_type(3))) int int3; -typedef __attribute__((ext_vector_type(4))) int int4; -typedef __attribute__((ext_vector_type(8))) int int8; -typedef __attribute__((ext_vector_type(16))) int int16; - -typedef __attribute__((ext_vector_type(2))) uint uint2; -typedef __attribute__((ext_vector_type(3))) uint uint3; -typedef __attribute__((ext_vector_type(4))) uint uint4; -typedef __attribute__((ext_vector_type(8))) uint uint8; -typedef __attribute__((ext_vector_type(16))) uint uint16; - -typedef __attribute__((ext_vector_type(2))) long long2; -typedef __attribute__((ext_vector_type(3))) long long3; -typedef __attribute__((ext_vector_type(4))) long long4; -typedef __attribute__((ext_vector_type(8))) long long8; -typedef __attribute__((ext_vector_type(16))) long long16; - -typedef __attribute__((ext_vector_type(2))) ulong ulong2; -typedef __attribute__((ext_vector_type(3))) ulong ulong3; -typedef __attribute__((ext_vector_type(4))) ulong ulong4; -typedef __attribute__((ext_vector_type(8))) ulong ulong8; -typedef __attribute__((ext_vector_type(16))) ulong ulong16; - -typedef __attribute__((ext_vector_type(2))) float float2; -typedef __attribute__((ext_vector_type(3))) float float3; -typedef __attribute__((ext_vector_type(4))) float float4; -typedef __attribute__((ext_vector_type(8))) float float8; -typedef __attribute__((ext_vector_type(16))) float float16; - -/* 9.3 Double Precision Floating-Point */ - -#ifdef cl_khr_fp64 -typedef __attribute__((ext_vector_type(2))) double double2; -typedef __attribute__((ext_vector_type(3))) double double3; -typedef __attribute__((ext_vector_type(4))) double double4; -typedef __attribute__((ext_vector_type(8))) double double8; -typedef __attribute__((ext_vector_type(16))) double double16; -#endif diff --git a/libclc/generic/include/clc/gentype.inc b/libclc/generic/include/clc/gentype.inc deleted file mode 100644 index 450692080feb..000000000000 --- a/libclc/generic/include/clc/gentype.inc +++ /dev/null @@ -1,51 +0,0 @@ -#define GENTYPE float -#include BODY -#undef GENTYPE - -#define GENTYPE float2 -#include BODY -#undef GENTYPE - -#define GENTYPE float3 -#include BODY -#undef GENTYPE - -#define GENTYPE float4 -#include BODY -#undef GENTYPE - -#define GENTYPE float8 -#include BODY -#undef GENTYPE - -#define GENTYPE float16 -#include BODY -#undef GENTYPE - -#ifdef cl_khr_fp64 -#define GENTYPE double -#include BODY -#undef GENTYPE - -#define GENTYPE double2 -#include BODY -#undef GENTYPE - -#define GENTYPE double3 -#include BODY -#undef GENTYPE - -#define GENTYPE double4 -#include BODY -#undef GENTYPE - -#define GENTYPE double8 -#include BODY -#undef GENTYPE - -#define GENTYPE double16 -#include BODY -#undef GENTYPE -#endif - -#undef BODY diff --git a/libclc/generic/include/clc/geometric/cross.h b/libclc/generic/include/clc/geometric/cross.h deleted file mode 100644 index 74117c0ec452..000000000000 --- a/libclc/generic/include/clc/geometric/cross.h +++ /dev/null @@ -1,2 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL float3 cross(float3 p0, float3 p1); -_CLC_OVERLOAD _CLC_DECL float4 cross(float4 p0, float4 p1); diff --git a/libclc/generic/include/clc/geometric/distance.h b/libclc/generic/include/clc/geometric/distance.h deleted file mode 100644 index 1660dcd64cd5..000000000000 --- a/libclc/generic/include/clc/geometric/distance.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/geometric/dot.h b/libclc/generic/include/clc/geometric/dot.h deleted file mode 100644 index 5f0464f68944..000000000000 --- a/libclc/generic/include/clc/geometric/dot.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/geometric/floatn.inc b/libclc/generic/include/clc/geometric/floatn.inc deleted file mode 100644 index c77c464ca2a4..000000000000 --- a/libclc/generic/include/clc/geometric/floatn.inc +++ /dev/null @@ -1,35 +0,0 @@ -#define FLOATN float -#include BODY -#undef FLOATN - -#define FLOATN float2 -#include BODY -#undef FLOATN - -#define FLOATN float3 -#include BODY -#undef FLOATN - -#define FLOATN float4 -#include BODY -#undef FLOATN - -#ifdef cl_khr_fp64 -#define FLOATN double -#include BODY -#undef FLOATN - -#define FLOATN double2 -#include BODY -#undef FLOATN - -#define FLOATN double3 -#include BODY -#undef FLOATN - -#define FLOATN double4 -#include BODY -#undef FLOATN -#endif - -#undef BODY diff --git a/libclc/generic/include/clc/geometric/length.h b/libclc/generic/include/clc/geometric/length.h deleted file mode 100644 index fbba63405cff..000000000000 --- a/libclc/generic/include/clc/geometric/length.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/geometric/length.inc b/libclc/generic/include/clc/geometric/length.inc deleted file mode 100644 index 8ee8bf30667f..000000000000 --- a/libclc/generic/include/clc/geometric/length.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL float length(FLOATN p0); diff --git a/libclc/generic/include/clc/geometric/normalize.h b/libclc/generic/include/clc/geometric/normalize.h deleted file mode 100644 index 3aaf61c78bcb..000000000000 --- a/libclc/generic/include/clc/geometric/normalize.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/geometric/normalize.inc b/libclc/generic/include/clc/geometric/normalize.inc deleted file mode 100644 index 7b4f69dc567e..000000000000 --- a/libclc/generic/include/clc/geometric/normalize.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL FLOATN normalize(FLOATN p); diff --git a/libclc/generic/include/clc/integer/abs.h b/libclc/generic/include/clc/integer/abs.h deleted file mode 100644 index 7592e4b39ca4..000000000000 --- a/libclc/generic/include/clc/integer/abs.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/integer/abs.inc b/libclc/generic/include/clc/integer/abs.inc deleted file mode 100644 index bfbec207e86b..000000000000 --- a/libclc/generic/include/clc/integer/abs.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL UGENTYPE abs(GENTYPE x); diff --git a/libclc/generic/include/clc/integer/abs_diff.h b/libclc/generic/include/clc/integer/abs_diff.h deleted file mode 100644 index 16fb465f2d2b..000000000000 --- a/libclc/generic/include/clc/integer/abs_diff.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/integer/abs_diff.inc b/libclc/generic/include/clc/integer/abs_diff.inc deleted file mode 100644 index 8cfdb9b9513a..000000000000 --- a/libclc/generic/include/clc/integer/abs_diff.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL UGENTYPE abs_diff(GENTYPE x, GENTYPE y); diff --git a/libclc/generic/include/clc/integer/add_sat.h b/libclc/generic/include/clc/integer/add_sat.h deleted file mode 100644 index 9dbe12a7f929..000000000000 --- a/libclc/generic/include/clc/integer/add_sat.h +++ /dev/null @@ -1,2 +0,0 @@ -#define BODY -#include diff --git a/libclc/generic/include/clc/integer/add_sat.inc b/libclc/generic/include/clc/integer/add_sat.inc deleted file mode 100644 index 2ea8a8366409..000000000000 --- a/libclc/generic/include/clc/integer/add_sat.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL GENTYPE add_sat(GENTYPE x, GENTYPE y); diff --git a/libclc/generic/include/clc/integer/gentype.inc b/libclc/generic/include/clc/integer/gentype.inc deleted file mode 100644 index 0b32efda9f0d..000000000000 --- a/libclc/generic/include/clc/integer/gentype.inc +++ /dev/null @@ -1,385 +0,0 @@ -#define GENTYPE char -#define UGENTYPE uchar -#define SGENTYPE char -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE char2 -#define UGENTYPE uchar2 -#define SGENTYPE char2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE char3 -#define UGENTYPE uchar3 -#define SGENTYPE char3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE char4 -#define UGENTYPE uchar4 -#define SGENTYPE char4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE char8 -#define UGENTYPE uchar8 -#define SGENTYPE char8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE char16 -#define UGENTYPE uchar16 -#define SGENTYPE char16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar -#define UGENTYPE uchar -#define SGENTYPE char -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar2 -#define UGENTYPE uchar2 -#define SGENTYPE char2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar3 -#define UGENTYPE uchar3 -#define SGENTYPE char3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar4 -#define UGENTYPE uchar4 -#define SGENTYPE char4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar8 -#define UGENTYPE uchar8 -#define SGENTYPE char8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uchar16 -#define UGENTYPE uchar16 -#define SGENTYPE char16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short -#define UGENTYPE ushort -#define SGENTYPE short -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short2 -#define UGENTYPE ushort2 -#define SGENTYPE short2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short3 -#define UGENTYPE ushort3 -#define SGENTYPE short3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short4 -#define UGENTYPE ushort4 -#define SGENTYPE short4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short8 -#define UGENTYPE ushort8 -#define SGENTYPE short8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE short16 -#define UGENTYPE ushort16 -#define SGENTYPE short16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort -#define UGENTYPE ushort -#define SGENTYPE short -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort2 -#define UGENTYPE ushort2 -#define SGENTYPE short2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort3 -#define UGENTYPE ushort3 -#define SGENTYPE short3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort4 -#define UGENTYPE ushort4 -#define SGENTYPE short4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort8 -#define UGENTYPE ushort8 -#define SGENTYPE short8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ushort16 -#define UGENTYPE ushort16 -#define SGENTYPE short16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int -#define UGENTYPE uint -#define SGENTYPE int -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int2 -#define UGENTYPE uint2 -#define SGENTYPE int2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int3 -#define UGENTYPE uint3 -#define SGENTYPE int3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int4 -#define UGENTYPE uint4 -#define SGENTYPE int4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int8 -#define UGENTYPE uint8 -#define SGENTYPE int8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE int16 -#define UGENTYPE uint16 -#define SGENTYPE int16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint -#define UGENTYPE uint -#define SGENTYPE int -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint2 -#define UGENTYPE uint2 -#define SGENTYPE int2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint3 -#define UGENTYPE uint3 -#define SGENTYPE int3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint4 -#define UGENTYPE uint4 -#define SGENTYPE int4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint8 -#define UGENTYPE uint8 -#define SGENTYPE int8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE uint16 -#define UGENTYPE uint16 -#define SGENTYPE int16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long -#define UGENTYPE ulong -#define SGENTYPE long -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long2 -#define UGENTYPE ulong2 -#define SGENTYPE long2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long3 -#define UGENTYPE ulong3 -#define SGENTYPE long3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long4 -#define UGENTYPE ulong4 -#define SGENTYPE long4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long8 -#define UGENTYPE ulong8 -#define SGENTYPE long8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE long16 -#define UGENTYPE ulong16 -#define SGENTYPE long16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong -#define UGENTYPE ulong -#define SGENTYPE long -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong2 -#define UGENTYPE ulong2 -#define SGENTYPE long2 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong3 -#define UGENTYPE ulong3 -#define SGENTYPE long3 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong4 -#define UGENTYPE ulong4 -#define SGENTYPE long4 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong8 -#define UGENTYPE ulong8 -#define SGENTYPE long8 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#define GENTYPE ulong16 -#define UGENTYPE ulong16 -#define SGENTYPE long16 -#include BODY -#undef GENTYPE -#undef UGENTYPE -#undef SGENTYPE - -#undef BODY diff --git a/libclc/generic/include/clc/math/cos.h b/libclc/generic/include/clc/math/cos.h deleted file mode 100644 index e876c1af7c39..000000000000 --- a/libclc/generic/include/clc/math/cos.h +++ /dev/null @@ -1,6 +0,0 @@ -#undef cos -#define cos __clc_cos - -#define FUNCTION __clc_cos -#define INTRINSIC "llvm.cos" -#include diff --git a/libclc/generic/include/clc/math/native_cos.h b/libclc/generic/include/clc/math/native_cos.h deleted file mode 100644 index c7212cc4b663..000000000000 --- a/libclc/generic/include/clc/math/native_cos.h +++ /dev/null @@ -1 +0,0 @@ -#define native_cos cos diff --git a/libclc/generic/include/clc/math/native_divide.h b/libclc/generic/include/clc/math/native_divide.h deleted file mode 100644 index 5c52167fd3e7..000000000000 --- a/libclc/generic/include/clc/math/native_divide.h +++ /dev/null @@ -1 +0,0 @@ -#define native_divide(x, y) ((x) / (y)) diff --git a/libclc/generic/include/clc/math/native_sin.h b/libclc/generic/include/clc/math/native_sin.h deleted file mode 100644 index 569a051ccc75..000000000000 --- a/libclc/generic/include/clc/math/native_sin.h +++ /dev/null @@ -1 +0,0 @@ -#define native_sin sin diff --git a/libclc/generic/include/clc/math/native_sqrt.h b/libclc/generic/include/clc/math/native_sqrt.h deleted file mode 100644 index a9525fccb7c1..000000000000 --- a/libclc/generic/include/clc/math/native_sqrt.h +++ /dev/null @@ -1 +0,0 @@ -#define native_sqrt sqrt diff --git a/libclc/generic/include/clc/math/sin.h b/libclc/generic/include/clc/math/sin.h deleted file mode 100644 index 2216804ad5ec..000000000000 --- a/libclc/generic/include/clc/math/sin.h +++ /dev/null @@ -1,6 +0,0 @@ -#undef sin -#define sin __clc_sin - -#define FUNCTION __clc_sin -#define INTRINSIC "llvm.sin" -#include diff --git a/libclc/generic/include/clc/math/sqrt.h b/libclc/generic/include/clc/math/sqrt.h deleted file mode 100644 index a000e243eb48..000000000000 --- a/libclc/generic/include/clc/math/sqrt.h +++ /dev/null @@ -1,6 +0,0 @@ -#undef sqrt -#define sqrt __clc_sqrt - -#define FUNCTION __clc_sqrt -#define INTRINSIC "llvm.sqrt" -#include diff --git a/libclc/generic/include/clc/math/unary_decl.inc b/libclc/generic/include/clc/math/unary_decl.inc deleted file mode 100644 index 392c4d60a087..000000000000 --- a/libclc/generic/include/clc/math/unary_decl.inc +++ /dev/null @@ -1 +0,0 @@ -_CLC_OVERLOAD _CLC_DECL GENTYPE FUNCTION(GENTYPE x); diff --git a/libclc/generic/include/clc/math/unary_intrin.inc b/libclc/generic/include/clc/math/unary_intrin.inc deleted file mode 100644 index 2da5a9c67f4b..000000000000 --- a/libclc/generic/include/clc/math/unary_intrin.inc +++ /dev/null @@ -1,18 +0,0 @@ -_CLC_OVERLOAD float FUNCTION(float f) __asm(INTRINSIC ".f32"); -_CLC_OVERLOAD float2 FUNCTION(float2 f) __asm(INTRINSIC ".v2f32"); -_CLC_OVERLOAD float3 FUNCTION(float3 f) __asm(INTRINSIC ".v3f32"); -_CLC_OVERLOAD float4 FUNCTION(float4 f) __asm(INTRINSIC ".v4f32"); -_CLC_OVERLOAD float8 FUNCTION(float8 f) __asm(INTRINSIC ".v8f32"); -_CLC_OVERLOAD float16 FUNCTION(float16 f) __asm(INTRINSIC ".v16f32"); - -#ifdef cl_khr_fp64 -_CLC_OVERLOAD double FUNCTION(double d) __asm(INTRINSIC ".f64"); -_CLC_OVERLOAD double2 FUNCTION(double2 d) __asm(INTRINSIC ".v2f64"); -_CLC_OVERLOAD double3 FUNCTION(double3 d) __asm(INTRINSIC ".v3f64"); -_CLC_OVERLOAD double4 FUNCTION(double4 d) __asm(INTRINSIC ".v4f64"); -_CLC_OVERLOAD double8 FUNCTION(double8 d) __asm(INTRINSIC ".v8f64"); -_CLC_OVERLOAD double16 FUNCTION(double16 d) __asm(INTRINSIC ".v16f64"); -#endif - -#undef FUNCTION -#undef INTRINSIC diff --git a/libclc/generic/include/clc/relational/select.h b/libclc/generic/include/clc/relational/select.h deleted file mode 100644 index 33a6909fb929..000000000000 --- a/libclc/generic/include/clc/relational/select.h +++ /dev/null @@ -1 +0,0 @@ -#define select(a, b, c) ((c) ? (b) : (a)) diff --git a/libclc/generic/include/clc/synchronization/cl_mem_fence_flags.h b/libclc/generic/include/clc/synchronization/cl_mem_fence_flags.h deleted file mode 100644 index c57eb4249a41..000000000000 --- a/libclc/generic/include/clc/synchronization/cl_mem_fence_flags.h +++ /dev/null @@ -1,4 +0,0 @@ -typedef uint cl_mem_fence_flags; - -#define CLK_LOCAL_MEM_FENCE 1 -#define CLK_GLOBAL_MEM_FENCE 2 diff --git a/libclc/generic/lib/SOURCES b/libclc/generic/lib/SOURCES deleted file mode 100644 index 11531fca37a3..000000000000 --- a/libclc/generic/lib/SOURCES +++ /dev/null @@ -1,8 +0,0 @@ -geometric/cross.cl -geometric/dot.cl -geometric/length.cl -geometric/normalize.cl -integer/abs.cl -integer/add_sat.cl -integer/add_sat.ll -integer/add_sat_impl.ll diff --git a/libclc/generic/lib/geometric/cross.cl b/libclc/generic/lib/geometric/cross.cl deleted file mode 100644 index 4c1bc6f03465..000000000000 --- a/libclc/generic/lib/geometric/cross.cl +++ /dev/null @@ -1,11 +0,0 @@ -#include - -_CLC_OVERLOAD _CLC_DEF float3 cross(float3 p0, float3 p1) { - return (float3)(p0.y*p1.z - p0.z*p1.y, p0.z*p1.x - p0.x*p1.z, - p0.x*p1.y - p0.y*p1.x); -} - -_CLC_OVERLOAD _CLC_DEF float4 cross(float4 p0, float4 p1) { - return (float4)(p0.y*p1.z - p0.z*p1.y, p0.z*p1.x - p0.x*p1.z, - p0.x*p1.y - p0.y*p1.x, 0.f); -} diff --git a/libclc/generic/lib/geometric/dot.cl b/libclc/generic/lib/geometric/dot.cl deleted file mode 100644 index 76cc1d2bdc6a..000000000000 --- a/libclc/generic/lib/geometric/dot.cl +++ /dev/null @@ -1,17 +0,0 @@ -#include - -_CLC_OVERLOAD _CLC_DEF float dot(float p0, float p1) { - return p0*p1; -} - -_CLC_OVERLOAD _CLC_DEF float dot(float2 p0, float2 p1) { - return p0.x*p1.x + p0.y*p1.y; -} - -_CLC_OVERLOAD _CLC_DEF float dot(float3 p0, float3 p1) { - return p0.x*p1.x + p0.y*p1.y + p0.z*p1.z; -} - -_CLC_OVERLOAD _CLC_DEF float dot(float4 p0, float4 p1) { - return p0.x*p1.x + p0.y*p1.y + p0.z*p1.z + p0.w*p1.w; -} diff --git a/libclc/generic/lib/geometric/length.cl b/libclc/generic/lib/geometric/length.cl deleted file mode 100644 index 957fbfdea0d6..000000000000 --- a/libclc/generic/lib/geometric/length.cl +++ /dev/null @@ -1,4 +0,0 @@ -#include - -#define BODY "length.inc" -#include diff --git a/libclc/generic/lib/geometric/length.inc b/libclc/generic/lib/geometric/length.inc deleted file mode 100644 index 66d160475aad..000000000000 --- a/libclc/generic/lib/geometric/length.inc +++ /dev/null @@ -1,3 +0,0 @@ -_CLC_OVERLOAD _CLC_DEF float length(FLOATN p) { - return native_sqrt(dot(p, p)); -} diff --git a/libclc/generic/lib/geometric/normalize.cl b/libclc/generic/lib/geometric/normalize.cl deleted file mode 100644 index 95d327cfa6db..000000000000 --- a/libclc/generic/lib/geometric/normalize.cl +++ /dev/null @@ -1,4 +0,0 @@ -#include - -#define BODY "normalize.inc" -#include diff --git a/libclc/generic/lib/geometric/normalize.inc b/libclc/generic/lib/geometric/normalize.inc deleted file mode 100644 index a23908bf038c..000000000000 --- a/libclc/generic/lib/geometric/normalize.inc +++ /dev/null @@ -1,3 +0,0 @@ -_CLC_OVERLOAD _CLC_DEF FLOATN normalize(FLOATN p) { - return p/length(p); -} diff --git a/libclc/generic/lib/integer/abs.cl b/libclc/generic/lib/integer/abs.cl deleted file mode 100644 index 86f1a34c1726..000000000000 --- a/libclc/generic/lib/integer/abs.cl +++ /dev/null @@ -1,4 +0,0 @@ -#include - -#define BODY -#include diff --git a/libclc/generic/lib/integer/abs.inc b/libclc/generic/lib/integer/abs.inc deleted file mode 100644 index fff6691274af..000000000000 --- a/libclc/generic/lib/integer/abs.inc +++ /dev/null @@ -1,3 +0,0 @@ -_CLC_OVERLOAD _CLC_DEF UGENTYPE abs(GENTYPE x) { - return __builtin_astype((GENTYPE)(x > (GENTYPE)(0) ? x : -x), UGENTYPE); -} diff --git a/libclc/generic/lib/integer/abs_diff.cl b/libclc/generic/lib/integer/abs_diff.cl deleted file mode 100644 index c9ca8213c327..000000000000 --- a/libclc/generic/lib/integer/abs_diff.cl +++ /dev/null @@ -1,4 +0,0 @@ -#include - -#define BODY -#include diff --git a/libclc/generic/lib/integer/abs_diff.inc b/libclc/generic/lib/integer/abs_diff.inc deleted file mode 100644 index 93efdba34535..000000000000 --- a/libclc/generic/lib/integer/abs_diff.inc +++ /dev/null @@ -1,3 +0,0 @@ -_CLC_OVERLOAD _CLC_DEF UGENTYPE abs_diff(GENTYPE x) { - return __builtin_astype((GENTYPE)(x > y ? x-y : y-x), UGENTYPE); -} diff --git a/libclc/generic/lib/integer/add_sat.cl b/libclc/generic/lib/integer/add_sat.cl deleted file mode 100644 index aae2e7fdd142..000000000000 --- a/libclc/generic/lib/integer/add_sat.cl +++ /dev/null @@ -1,52 +0,0 @@ -#include - -// From add_sat.ll -_CLC_DECL char __clc_add_sat_s8(char, char); -_CLC_DECL char __clc_add_sat_u8(uchar, uchar); -_CLC_DECL char __clc_add_sat_s16(short, short); -_CLC_DECL char __clc_add_sat_u16(ushort, ushort); -_CLC_DECL char __clc_add_sat_s32(int, int); -_CLC_DECL char __clc_add_sat_u32(uint, uint); -_CLC_DECL char __clc_add_sat_s64(long, long); -_CLC_DECL char __clc_add_sat_u64(ulong, ulong); - -_CLC_OVERLOAD _CLC_DEF char add_sat(char x, char y) { - return __clc_add_sat_s8(x, y); -} - -_CLC_OVERLOAD _CLC_DEF uchar add_sat(uchar x, uchar y) { - return __clc_add_sat_u8(x, y); -} - -_CLC_OVERLOAD _CLC_DEF short add_sat(short x, short y) { - return __clc_add_sat_s16(x, y); -} - -_CLC_OVERLOAD _CLC_DEF ushort add_sat(ushort x, ushort y) { - return __clc_add_sat_u16(x, y); -} - -_CLC_OVERLOAD _CLC_DEF int add_sat(int x, int y) { - return __clc_add_sat_s32(x, y); -} - -_CLC_OVERLOAD _CLC_DEF uint add_sat(uint x, uint y) { - return __clc_add_sat_u32(x, y); -} - -_CLC_OVERLOAD _CLC_DEF long add_sat(long x, long y) { - return __clc_add_sat_s64(x, y); -} - -_CLC_OVERLOAD _CLC_DEF ulong add_sat(ulong x, ulong y) { - return __clc_add_sat_u64(x, y); -} - -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, char, add_sat, char, char) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, uchar, add_sat, uchar, uchar) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, short, add_sat, short, short) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, ushort, add_sat, ushort, ushort) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, int, add_sat, int, int) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, uint, add_sat, uint, uint) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, long, add_sat, long, long) -_CLC_BINARY_VECTORIZE(_CLC_OVERLOAD _CLC_DEF, ulong, add_sat, ulong, ulong) diff --git a/libclc/generic/lib/integer/add_sat.ll b/libclc/generic/lib/integer/add_sat.ll deleted file mode 100644 index d6814c33a065..000000000000 --- a/libclc/generic/lib/integer/add_sat.ll +++ /dev/null @@ -1,55 +0,0 @@ -declare i8 @__clc_add_sat_impl_s8(i8 %x, i8 %y) - -define linkonce_odr i8 @__clc_add_sat_s8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call i8 @__clc_add_sat_impl_s8(i8 %x, i8 %y) - ret i8 %call -} - -declare i8 @__clc_add_sat_impl_u8(i8 %x, i8 %y) - -define linkonce_odr i8 @__clc_add_sat_u8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call i8 @__clc_add_sat_impl_u8(i8 %x, i8 %y) - ret i8 %call -} - -declare i16 @__clc_add_sat_impl_s16(i16 %x, i16 %y) - -define linkonce_odr i16 @__clc_add_sat_s16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call i16 @__clc_add_sat_impl_s16(i16 %x, i16 %y) - ret i16 %call -} - -declare i16 @__clc_add_sat_impl_u16(i16 %x, i16 %y) - -define linkonce_odr i16 @__clc_add_sat_u16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call i16 @__clc_add_sat_impl_u16(i16 %x, i16 %y) - ret i16 %call -} - -declare i32 @__clc_add_sat_impl_s32(i32 %x, i32 %y) - -define linkonce_odr i32 @__clc_add_sat_s32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call i32 @__clc_add_sat_impl_s32(i32 %x, i32 %y) - ret i32 %call -} - -declare i32 @__clc_add_sat_impl_u32(i32 %x, i32 %y) - -define linkonce_odr i32 @__clc_add_sat_u32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call i32 @__clc_add_sat_impl_u32(i32 %x, i32 %y) - ret i32 %call -} - -declare i64 @__clc_add_sat_impl_s64(i64 %x, i64 %y) - -define linkonce_odr i64 @__clc_add_sat_s64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call i64 @__clc_add_sat_impl_s64(i64 %x, i64 %y) - ret i64 %call -} - -declare i64 @__clc_add_sat_impl_u64(i64 %x, i64 %y) - -define linkonce_odr i64 @__clc_add_sat_u64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call i64 @__clc_add_sat_impl_u64(i64 %x, i64 %y) - ret i64 %call -} diff --git a/libclc/generic/lib/integer/add_sat_impl.ll b/libclc/generic/lib/integer/add_sat_impl.ll deleted file mode 100644 index 92f4c536fc2a..000000000000 --- a/libclc/generic/lib/integer/add_sat_impl.ll +++ /dev/null @@ -1,83 +0,0 @@ -declare {i8, i1} @llvm.sadd.with.overflow.i8(i8, i8) -declare {i8, i1} @llvm.uadd.with.overflow.i8(i8, i8) - -define linkonce_odr i8 @__clc_add_sat_impl_s8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call {i8, i1} @llvm.sadd.with.overflow.i8(i8 %x, i8 %y) - %res = extractvalue {i8, i1} %call, 0 - %over = extractvalue {i8, i1} %call, 1 - %x.msb = ashr i8 %x, 7 - %x.limit = xor i8 %x.msb, 127 - %sat = select i1 %over, i8 %x.limit, i8 %res - ret i8 %sat -} - -define linkonce_odr i8 @__clc_add_sat_impl_u8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call {i8, i1} @llvm.uadd.with.overflow.i8(i8 %x, i8 %y) - %res = extractvalue {i8, i1} %call, 0 - %over = extractvalue {i8, i1} %call, 1 - %sat = select i1 %over, i8 -1, i8 %res - ret i8 %sat -} - -declare {i16, i1} @llvm.sadd.with.overflow.i16(i16, i16) -declare {i16, i1} @llvm.uadd.with.overflow.i16(i16, i16) - -define linkonce_odr i16 @__clc_add_sat_impl_s16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call {i16, i1} @llvm.sadd.with.overflow.i16(i16 %x, i16 %y) - %res = extractvalue {i16, i1} %call, 0 - %over = extractvalue {i16, i1} %call, 1 - %x.msb = ashr i16 %x, 15 - %x.limit = xor i16 %x.msb, 32767 - %sat = select i1 %over, i16 %x.limit, i16 %res - ret i16 %sat -} - -define linkonce_odr i16 @__clc_add_sat_impl_u16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call {i16, i1} @llvm.uadd.with.overflow.i16(i16 %x, i16 %y) - %res = extractvalue {i16, i1} %call, 0 - %over = extractvalue {i16, i1} %call, 1 - %sat = select i1 %over, i16 -1, i16 %res - ret i16 %sat -} - -declare {i32, i1} @llvm.sadd.with.overflow.i32(i32, i32) -declare {i32, i1} @llvm.uadd.with.overflow.i32(i32, i32) - -define linkonce_odr i32 @__clc_add_sat_impl_s32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call {i32, i1} @llvm.sadd.with.overflow.i32(i32 %x, i32 %y) - %res = extractvalue {i32, i1} %call, 0 - %over = extractvalue {i32, i1} %call, 1 - %x.msb = ashr i32 %x, 31 - %x.limit = xor i32 %x.msb, 2147483647 - %sat = select i1 %over, i32 %x.limit, i32 %res - ret i32 %sat -} - -define linkonce_odr i32 @__clc_add_sat_impl_u32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call {i32, i1} @llvm.uadd.with.overflow.i32(i32 %x, i32 %y) - %res = extractvalue {i32, i1} %call, 0 - %over = extractvalue {i32, i1} %call, 1 - %sat = select i1 %over, i32 -1, i32 %res - ret i32 %sat -} - -declare {i64, i1} @llvm.sadd.with.overflow.i64(i64, i64) -declare {i64, i1} @llvm.uadd.with.overflow.i64(i64, i64) - -define linkonce_odr i64 @__clc_add_sat_impl_s64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call {i64, i1} @llvm.sadd.with.overflow.i64(i64 %x, i64 %y) - %res = extractvalue {i64, i1} %call, 0 - %over = extractvalue {i64, i1} %call, 1 - %x.msb = ashr i64 %x, 63 - %x.limit = xor i64 %x.msb, 9223372036854775807 - %sat = select i1 %over, i64 %x.limit, i64 %res - ret i64 %sat -} - -define linkonce_odr i64 @__clc_add_sat_impl_u64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call {i64, i1} @llvm.uadd.with.overflow.i64(i64 %x, i64 %y) - %res = extractvalue {i64, i1} %call, 0 - %over = extractvalue {i64, i1} %call, 1 - %sat = select i1 %over, i64 -1, i64 %res - ret i64 %sat -} diff --git a/libclc/ptx-nvidiacl/include/clc/synchronization/barrier.h b/libclc/ptx-nvidiacl/include/clc/synchronization/barrier.h deleted file mode 100644 index cd9f3276af62..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/synchronization/barrier.h +++ /dev/null @@ -1,6 +0,0 @@ -_CLC_INLINE void barrier(cl_mem_fence_flags flags) { - if (flags & CLK_LOCAL_MEM_FENCE) { - __builtin_ptx_bar_sync(0); - } -} - diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_global_id.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_global_id.h deleted file mode 100644 index 026d2fea31f8..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_global_id.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_global_id(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_ctaid_x()*__builtin_ptx_read_ntid_x()+__builtin_ptx_read_tid_x(); - case 1: return __builtin_ptx_read_ctaid_y()*__builtin_ptx_read_ntid_y()+__builtin_ptx_read_tid_y(); - case 2: return __builtin_ptx_read_ctaid_z()*__builtin_ptx_read_ntid_z()+__builtin_ptx_read_tid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_global_size.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_global_size.h deleted file mode 100644 index 5cd4222d5ae7..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_global_size.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_global_size(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_nctaid_x()*__builtin_ptx_read_ntid_x(); - case 1: return __builtin_ptx_read_nctaid_y()*__builtin_ptx_read_ntid_y(); - case 2: return __builtin_ptx_read_nctaid_z()*__builtin_ptx_read_ntid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_group_id.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_group_id.h deleted file mode 100644 index 18b1bd4db079..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_group_id.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_group_id(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_ctaid_x(); - case 1: return __builtin_ptx_read_ctaid_y(); - case 2: return __builtin_ptx_read_ctaid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_local_id.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_local_id.h deleted file mode 100644 index 1b8c776badf6..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_local_id.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_local_id(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_tid_x(); - case 1: return __builtin_ptx_read_tid_y(); - case 2: return __builtin_ptx_read_tid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_local_size.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_local_size.h deleted file mode 100644 index cbc1f6ee2893..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_local_size.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_local_size(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_ntid_x(); - case 1: return __builtin_ptx_read_ntid_y(); - case 2: return __builtin_ptx_read_ntid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/include/clc/workitem/get_num_groups.h b/libclc/ptx-nvidiacl/include/clc/workitem/get_num_groups.h deleted file mode 100644 index 36ee849c613f..000000000000 --- a/libclc/ptx-nvidiacl/include/clc/workitem/get_num_groups.h +++ /dev/null @@ -1,8 +0,0 @@ -_CLC_INLINE size_t get_num_groups(uint dim) { - switch (dim) { - case 0: return __builtin_ptx_read_nctaid_x(); - case 1: return __builtin_ptx_read_nctaid_y(); - case 2: return __builtin_ptx_read_nctaid_z(); - default: return 0; - } -} diff --git a/libclc/ptx-nvidiacl/lib/SOURCES b/libclc/ptx-nvidiacl/lib/SOURCES deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/libclc/ptx/lib/SOURCES b/libclc/ptx/lib/SOURCES deleted file mode 100644 index aab8e3fb8d74..000000000000 --- a/libclc/ptx/lib/SOURCES +++ /dev/null @@ -1 +0,0 @@ -integer/add_sat.ll diff --git a/libclc/ptx/lib/integer/add_sat.ll b/libclc/ptx/lib/integer/add_sat.ll deleted file mode 100644 index 9b8311cfb9ce..000000000000 --- a/libclc/ptx/lib/integer/add_sat.ll +++ /dev/null @@ -1,55 +0,0 @@ -declare i8 @__clc_add_sat_impl_s8(i8 %x, i8 %y) - -define linkonce_odr ptx_device i8 @__clc_add_sat_s8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call i8 @__clc_add_sat_impl_s8(i8 %x, i8 %y) - ret i8 %call -} - -declare i8 @__clc_add_sat_impl_u8(i8 %x, i8 %y) - -define linkonce_odr ptx_device i8 @__clc_add_sat_u8(i8 %x, i8 %y) nounwind readnone alwaysinline { - %call = call i8 @__clc_add_sat_impl_u8(i8 %x, i8 %y) - ret i8 %call -} - -declare i16 @__clc_add_sat_impl_s16(i16 %x, i16 %y) - -define linkonce_odr ptx_device i16 @__clc_add_sat_s16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call i16 @__clc_add_sat_impl_s16(i16 %x, i16 %y) - ret i16 %call -} - -declare i16 @__clc_add_sat_impl_u16(i16 %x, i16 %y) - -define linkonce_odr ptx_device i16 @__clc_add_sat_u16(i16 %x, i16 %y) nounwind readnone alwaysinline { - %call = call i16 @__clc_add_sat_impl_u16(i16 %x, i16 %y) - ret i16 %call -} - -declare i32 @__clc_add_sat_impl_s32(i32 %x, i32 %y) - -define linkonce_odr ptx_device i32 @__clc_add_sat_s32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call i32 @__clc_add_sat_impl_s32(i32 %x, i32 %y) - ret i32 %call -} - -declare i32 @__clc_add_sat_impl_u32(i32 %x, i32 %y) - -define linkonce_odr ptx_device i32 @__clc_add_sat_u32(i32 %x, i32 %y) nounwind readnone alwaysinline { - %call = call i32 @__clc_add_sat_impl_u32(i32 %x, i32 %y) - ret i32 %call -} - -declare i64 @__clc_add_sat_impl_s64(i64 %x, i64 %y) - -define linkonce_odr ptx_device i64 @__clc_add_sat_s64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call i64 @__clc_add_sat_impl_s64(i64 %x, i64 %y) - ret i64 %call -} - -declare i64 @__clc_add_sat_impl_u64(i64 %x, i64 %y) - -define linkonce_odr ptx_device i64 @__clc_add_sat_u64(i64 %x, i64 %y) nounwind readnone alwaysinline { - %call = call i64 @__clc_add_sat_impl_u64(i64 %x, i64 %y) - ret i64 %call -} diff --git a/libclc/test/cos.cl b/libclc/test/cos.cl deleted file mode 100644 index 4230eb2a0e93..000000000000 --- a/libclc/test/cos.cl +++ /dev/null @@ -1,3 +0,0 @@ -__kernel void foo(float4 *f) { - *f = cos(*f); -} diff --git a/libclc/test/cross.cl b/libclc/test/cross.cl deleted file mode 100644 index 08955cbd9af5..000000000000 --- a/libclc/test/cross.cl +++ /dev/null @@ -1,3 +0,0 @@ -__kernel void foo(float4 *f) { - *f = cross(f[0], f[1]); -} diff --git a/libclc/test/get_group_id.cl b/libclc/test/get_group_id.cl deleted file mode 100644 index 43725cda8027..000000000000 --- a/libclc/test/get_group_id.cl +++ /dev/null @@ -1,3 +0,0 @@ -__kernel void foo(int *i) { - i[get_group_id(0)] = 1; -} diff --git a/libclc/utils/prepare-builtins.cpp b/libclc/utils/prepare-builtins.cpp deleted file mode 100644 index ae7731b03b07..000000000000 --- a/libclc/utils/prepare-builtins.cpp +++ /dev/null @@ -1,81 +0,0 @@ -#include "llvm/ADT/OwningPtr.h" -#include "llvm/Bitcode/ReaderWriter.h" -#include "llvm/Function.h" -#include "llvm/GlobalVariable.h" -#include "llvm/LLVMContext.h" -#include "llvm/Module.h" -#include "llvm/Support/CommandLine.h" -#include "llvm/Support/ManagedStatic.h" -#include "llvm/Support/MemoryBuffer.h" -#include "llvm/Support/raw_ostream.h" -#include "llvm/Support/system_error.h" -#include "llvm/Support/ToolOutputFile.h" - -using namespace llvm; - -static cl::opt -InputFilename(cl::Positional, cl::desc(""), cl::init("-")); - -static cl::opt -OutputFilename("o", cl::desc("Output filename"), - cl::value_desc("filename")); - -int main(int argc, char **argv) { - LLVMContext &Context = getGlobalContext(); - llvm_shutdown_obj Y; // Call llvm_shutdown() on exit. - - cl::ParseCommandLineOptions(argc, argv, "libclc builtin preparation tool\n"); - - std::string ErrorMessage; - std::auto_ptr M; - - { - OwningPtr BufferPtr; - if (error_code ec = MemoryBuffer::getFileOrSTDIN(InputFilename, BufferPtr)) - ErrorMessage = ec.message(); - else - M.reset(ParseBitcodeFile(BufferPtr.get(), Context, &ErrorMessage)); - } - - if (M.get() == 0) { - errs() << argv[0] << ": "; - if (ErrorMessage.size()) - errs() << ErrorMessage << "\n"; - else - errs() << "bitcode didn't read correctly.\n"; - return 1; - } - - // Set linkage of every external definition to linkonce_odr. - for (Module::iterator i = M->begin(), e = M->end(); i != e; ++i) { - if (!i->isDeclaration() && i->getLinkage() == GlobalValue::ExternalLinkage) - i->setLinkage(GlobalValue::LinkOnceODRLinkage); - } - - for (Module::global_iterator i = M->global_begin(), e = M->global_end(); - i != e; ++i) { - if (!i->isDeclaration() && i->getLinkage() == GlobalValue::ExternalLinkage) - i->setLinkage(GlobalValue::LinkOnceODRLinkage); - } - - if (OutputFilename.empty()) { - errs() << "no output file\n"; - return 1; - } - - std::string ErrorInfo; - OwningPtr Out - (new tool_output_file(OutputFilename.c_str(), ErrorInfo, - raw_fd_ostream::F_Binary)); - if (!ErrorInfo.empty()) { - errs() << ErrorInfo << '\n'; - exit(1); - } - - WriteBitcodeToFile(M.get(), Out->os()); - - // Declare success. - Out->keep(); - return 0; -} - diff --git a/libclc/www/index.html b/libclc/www/index.html deleted file mode 100644 index bbd0dc8fcede..000000000000 --- a/libclc/www/index.html +++ /dev/null @@ -1,55 +0,0 @@ - - -libclc - - -

libclc

-

-libclc is an open source, BSD/MIT dual licensed -implementation of the library requirements of the -OpenCL C programming language, as specified by the OpenCL -1.1 Specification. The following sections of the specification -impose library requirements: -

    -
  • 6.1: Supported Data Types -
  • 6.2.3: Explicit Conversions -
  • 6.2.4.2: Reinterpreting Types Using as_type() and as_typen() -
  • 6.9: Preprocessor Directives and Macros -
  • 6.11: Built-in Functions -
  • 9.3: Double Precision Floating-Point -
  • 9.4: 64-bit Atomics -
  • 9.5: Writing to 3D image memory objects -
  • 9.6: Half Precision Floating-Point -
-

- -

-libclc is intended to be used with the Clang -compiler's OpenCL frontend. -

- -

-libclc is designed to be portable and extensible. To this end, -it provides generic implementations of most library requirements, -allowing the target to override the generic implementation at the -granularity of individual functions. -

- -

-libclc currently only supports the PTX target, but support for more -targets is welcome. -

- -

Download

- -svn checkout http://llvm.org/svn/llvm-project/libclc/trunk libclc (ViewVC) -
- or -
-git clone http://llvm.org/git/libclc.git - -

Mailing List

- -libclc-dev@pcc.me.uk (subscribe/unsubscribe, archives) - - - diff --git a/libcxx/CMakeLists.txt b/libcxx/CMakeLists.txt deleted file mode 100644 index a7429f675534..000000000000 --- a/libcxx/CMakeLists.txt +++ /dev/null @@ -1,159 +0,0 @@ -# See www/CMake.html for instructions on how to build libcxx with CMake. - -#=============================================================================== -# Setup Project -#=============================================================================== - -project(libcxx CXX C) -cmake_minimum_required(VERSION 2.8) - -set(PACKAGE_NAME libcxx) -set(PACKAGE_VERSION trunk-svn) -set(PACKAGE_STRING "${PACKAGE_NAME} ${PACKAGE_VERSION}") -set(PACKAGE_BUGREPORT "llvmbugs@cs.uiuc.edu") - -# Add path for custom modules -set(CMAKE_MODULE_PATH - ${CMAKE_MODULE_PATH} - "${CMAKE_CURRENT_SOURCE_DIR}/cmake" - "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules" - ) - -# Require out of source build. -include(MacroEnsureOutOfSourceBuild) -MACRO_ENSURE_OUT_OF_SOURCE_BUILD( - "${PROJECT_NAME} requires an out of source build. Please create a separate - build directory and run 'cmake /path/to/${PROJECT_NAME} [options]' there." - ) - -#=============================================================================== -# Setup CMake Options -#=============================================================================== - -# Define options. -option(LIBCXX_ENABLE_EXCEPTIONS "Use exceptions." ON) -option(LIBCXX_ENABLE_RTTI "Use run time type information." ON) -option(LIBCXX_ENABLE_ASSERTIONS "Enable assertions independent of build mode." ON) -option(LIBCXX_ENABLE_PEDANTIC "Compile with pedantic enabled." ON) -option(LIBCXX_ENABLE_WERROR "Fail and stop if a warning is triggered." OFF) -option(LIBCXX_ENABLE_CXX0X "Enable -std=c++0x and use of c++0x language features if the compiler supports it." ON) -option(LIBCXX_ENABLE_SHARED "Build libc++ as a shared library." ON) - -#=============================================================================== -# Configure System -#=============================================================================== - -# Get triples. -include(GetTriple) -get_host_triple(LIBCXX_HOST_TRIPLE - LIBCXX_HOST_ARCH - LIBCXX_HOST_VENDOR - LIBCXX_HOST_OS - ) -set(LIBCXX_HOST_TRIPLE ${LIBCXX_HOST_TRIPLE} CACHE STRING "Host triple.") -get_target_triple(LIBCXX_TARGET_TRIPLE - LIBCXX_TARGET_ARCH - LIBCXX_TARGET_VENDOR - LIBCXX_TARGET_OS - ) -set(LIBCXX_TARGET_TRIPLE ${LIBCXX_TARGET_TRIPLE} CACHE STRING "Target triple.") - -# Configure compiler. -include(config-ix) - -#=============================================================================== -# Setup Compiler Flags -#=============================================================================== - -# Get required flags. -# On all systems the system c++ standard library headers need to be excluded. -if (MSVC) - # MSVC only has -X, which disables all default includes; including the crt. - # Thus, we do nothing and hope we don't accidentally include any of the C++ - # headers. -else() - if (LIBCXX_HAS_NOSTDINCXX_FLAG) - set(LIBCXX_CXX_REQUIRED_FLAGS -nostdinc++) - endif() - if (LIBCXX_ENABLE_CXX0X AND LIBCXX_HAS_STDCXX0X_FLAG) - list(APPEND LIBCXX_CXX_REQUIRED_FLAGS -std=c++0x) - endif() -endif() - -macro(append_if list condition var) - if (${condition}) - list(APPEND ${list} ${var}) - endif() -endmacro() - -# Get warning flags -append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WALL_FLAG -Wall) -append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_W_FLAG -W) -append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WNO_UNUSED_PARAMETER_FLAG -Wno-unused-parameter) -append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WWRITE_STRINGS_FLAG -Wwrite-strings) -append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WNO_LONG_LONG_FLAG -Wno-long-long) -if (LIBCXX_ENABLE_WERROR) - append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WERROR_FLAG -Werror) - append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_WX_FLAG -WX) -endif() -if (LIBCXX_ENABLE_PEDANTIC) - append_if(LIBCXX_WARNING_FLAGS LIBCXX_HAS_PEDANTIC_FLAG -pedantic) -endif() - -# Get feature flags. -# Exceptions -if (LIBCXX_ENABLE_EXCEPTIONS) - # Catches C++ exceptions only and tells the compiler to assume that extern C - # functions never throw a C++ exception. - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_EHSC_FLAG -EHsc) -else() - list(APPEND LIBCXX_CXX_FEATURE_FLAGS -D_LIBCPP_NO_EXCEPTIONS) - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_NO_EHS_FLAG -EHs-) - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_NO_EHA_FLAG -EHa-) - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_FNO_EXCEPTIONS_FLAG -fno-exceptions) -endif() -# RTTI -if (NOT LIBCXX_ENABLE_RTTI) - list(APPEND LIBCXX_CXX_FEATURE_FLAGS -D_LIBCPP_NO_RTTI) - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_NO_GR_FLAG -GR-) - append_if(LIBCXX_CXX_FEATURE_FLAGS LIBCXX_HAS_FNO_RTTI_FLAG -fno-rtti) -endif() -# Assert -if (LLVM_ENABLE_ASSERTIONS) - # MSVC doesn't like _DEBUG on release builds. See PR 4379. - if (NOT MSVC) - list(APPEND LIBCXX_CXX_FEATURE_FLAGS -D_DEBUG) - endif() - # On Release builds cmake automatically defines NDEBUG, so we - # explicitly undefine it: - if (uppercase_CMAKE_BUILD_TYPE STREQUAL "RELEASE") - list(APPEND LIBCXX_CXX_FEATURE_FLAGS -UNDEBUG) - endif() -else() - if (NOT uppercase_CMAKE_BUILD_TYPE STREQUAL "RELEASE") - list(APPEND LIBCXX_CXX_FEATURE_FLAGS -DNDEBUG) - endif() -endif() - -# This is the _ONLY_ place where add_definitions is called. -add_definitions( - ${LIBCXX_CXX_REQUIRED_FLAGS} - ${LIBCXX_CXX_WARNING_FLAGS} - ${LIBCXX_CXX_FEATURE_FLAGS} - ) - -#=============================================================================== -# Setup Source Code -#=============================================================================== - -include_directories(include) - -# Add source code. This also contains all of the logic for deciding linker flags -# soname, etc... -add_subdirectory(lib) - -#=============================================================================== -# Setup Tests -#=============================================================================== - -add_subdirectory(test) diff --git a/libcxx/CREDITS.TXT b/libcxx/CREDITS.TXT deleted file mode 100644 index 408cda317475..000000000000 --- a/libcxx/CREDITS.TXT +++ /dev/null @@ -1,49 +0,0 @@ -This file is a partial list of people who have contributed to the LLVM/libc++ -project. If you have contributed a patch or made some other contribution to -LLVM/libc++, please submit a patch to this file to add yourself, and it will be -done! - -The list is sorted by surname and formatted to allow easy grepping and -beautification by scripts. The fields are: name (N), email (E), web-address -(W), PGP key ID and fingerprint (P), description (D), and snail-mail address -(S). - -N: Howard Hinnant -E: hhinnant@apple.com -D: Architect and primary author of libc++ - -N: Marshall Clow -E: marshall@idio.com -E: mclow@qualcomm.com -D: Minor patches and bug fixes. - -N: Bjorn Reese -E: breese@users.sourceforge.net -D: Initial regex prototype - -N: David Chisnall -E: theraven at theravensnest dot org -D: FreeBSD and Solaris ports, libcxxrt support, some atomics work. - -N: Ruben Van Boxem -E: vanboxem dot ruben at gmail dot com -D: Initial Windows patches. - -N: Arvid Picciani -E: aep at exys dot org -D: Minor patches and musl port. - -N: Craig Silverstein -E: csilvers@google.com -D: Implemented Cityhash as the string hash function on 64-bit machines - -N: Google Inc. -D: Copyright owner and contributor of the CityHash algorithm - -N: Jeffrey Yasskin -E: jyasskin@gmail.com -E: jyasskin@google.com -D: Linux fixes. - -N: Jonathan Sauer -D: Minor patches, mostly related to constexpr diff --git a/libcxx/LICENSE.TXT b/libcxx/LICENSE.TXT deleted file mode 100644 index 14645d080198..000000000000 --- a/libcxx/LICENSE.TXT +++ /dev/null @@ -1,76 +0,0 @@ -============================================================================== -libc++ License -============================================================================== - -The libc++ library is dual licensed under both the University of Illinois -"BSD-Like" license and the MIT license. As a user of this code you may choose -to use it under either license. As a contributor, you agree to allow your code -to be used under both. - -Full text of the relevant licenses is included below. - -============================================================================== - -University of Illinois/NCSA -Open Source License - -Copyright (c) 2009-2012 by the contributors listed in CREDITS.TXT - -All rights reserved. - -Developed by: - - LLVM Team - - University of Illinois at Urbana-Champaign - - http://llvm.org - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal with -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: - - * Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimers. - - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimers in the - documentation and/or other materials provided with the distribution. - - * Neither the names of the LLVM Team, University of Illinois at - Urbana-Champaign, nor the names of its contributors may be used to - endorse or promote products derived from this Software without specific - prior written permission. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE -SOFTWARE. - -============================================================================== - -Copyright (c) 2009-2012 by the contributors listed in CREDITS.TXT - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/libcxx/Makefile b/libcxx/Makefile deleted file mode 100644 index 79385b28ebe6..000000000000 --- a/libcxx/Makefile +++ /dev/null @@ -1,55 +0,0 @@ -## -# libcpp Makefile -## - -SRCDIRS = . -DESTDIR = $(DSTROOT) - -OBJROOT=. -SYMROOT=. -export TRIPLE=-apple- - -ifeq (,$(RC_INDIGO)) - INSTALL_PREFIX="" -else - INSTALL_PREFIX="$(SDKROOT)" -endif -INSTALL_DIR=$(DSTROOT)/$(INSTALL_PREFIX) - -.PHONY: help installsrc clean installheaders do-installhdrs install - -help:: - echo Use make install DSTROOT= - -installsrc:: $(SRCROOT) - - ditto $(SRCDIRS)/include $(SRCROOT)/include - ditto $(SRCDIRS)/lib $(SRCROOT)/lib - ditto $(SRCDIRS)/src $(SRCROOT)/src - ditto $(SRCDIRS)/Makefile $(SRCROOT)/Makefile - -clean:: - -installheaders:: do-installhdrs - -# The do-installhdrs target is also used by clang's runtime/libcxx makefile. -do-installhdrs: - mkdir -p $(HEADER_DIR)/c++/v1/ext - rsync -r --exclude=".*" --exclude="support" $(SRCDIRS)/include/* \ - $(HEADER_DIR)/c++/v1/ - chown -R root:wheel $(HEADER_DIR)/c++ - chmod 755 $(HEADER_DIR)/c++/v1 - chmod 644 $(HEADER_DIR)/c++/v1/* - chmod 755 $(HEADER_DIR)/c++/v1/ext - chmod 644 $(HEADER_DIR)/c++/v1/ext/* - -install:: - - cd lib && ./buildit - ditto lib/libc++.1.dylib $(SYMROOT)/usr/lib/libc++.1.dylib - cd lib && dsymutil -o $(SYMROOT)/libc++.1.dylib.dSYM \ - $(SYMROOT)/usr/lib/libc++.1.dylib - mkdir -p $(INSTALL_DIR)/usr/lib - strip -S -o $(INSTALL_DIR)/usr/lib/libc++.1.dylib \ - $(SYMROOT)/usr/lib/libc++.1.dylib - cd $(INSTALL_DIR)/usr/lib && ln -s libc++.1.dylib libc++.dylib diff --git a/libcxx/cmake/Modules/GetTriple.cmake b/libcxx/cmake/Modules/GetTriple.cmake deleted file mode 100644 index c555931ded5a..000000000000 --- a/libcxx/cmake/Modules/GetTriple.cmake +++ /dev/null @@ -1,53 +0,0 @@ -# Define functions to get the host and target triple. - -function(get_host_triple out out_arch out_vendor out_os) - # Get the architecture. - set(arch ${CMAKE_HOST_SYSTEM_PROCESSOR}) - if (arch STREQUAL "x86") - set(arch "i686") - endif() - # Get the vendor. - if (${CMAKE_HOST_SYSTEM_NAME} STREQUAL "Darwin") - set(vendor "apple") - else() - set(vendor "pc") - endif() - # Get os. - if (${CMAKE_HOST_SYSTEM_NAME} STREQUAL "Windows") - set(os "win32") - else() - string(TOLOWER ${CMAKE_HOST_SYSTEM_NAME} os) - endif() - set(triple "${arch}-${vendor}-${os}") - set(${out} ${triple} PARENT_SCOPE) - set(${out_arch} ${arch} PARENT_SCOPE) - set(${out_vendor} ${vendor} PARENT_SCOPE) - set(${out_os} ${os} PARENT_SCOPE) - message(STATUS "Host triple: ${triple}") -endfunction() - -function(get_target_triple out out_arch out_vendor out_os) - # Get the architecture. - set(arch ${CMAKE_SYSTEM_PROCESSOR}) - if (arch STREQUAL "x86") - set(arch "i686") - endif() - # Get the vendor. - if (${CMAKE_SYSTEM_NAME} STREQUAL "Darwin") - set(vendor "apple") - else() - set(vendor "pc") - endif() - # Get os. - if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows") - set(os "win32") - else() - string(TOLOWER ${CMAKE_SYSTEM_NAME} os) - endif() - set(triple "${arch}-${vendor}-${os}") - set(${out} ${triple} PARENT_SCOPE) - set(${out_arch} ${arch} PARENT_SCOPE) - set(${out_vendor} ${vendor} PARENT_SCOPE) - set(${out_os} ${os} PARENT_SCOPE) - message(STATUS "Target triple: ${triple}") -endfunction() diff --git a/libcxx/cmake/Modules/MacroEnsureOutOfSourceBuild.cmake b/libcxx/cmake/Modules/MacroEnsureOutOfSourceBuild.cmake deleted file mode 100644 index a0669365bf99..000000000000 --- a/libcxx/cmake/Modules/MacroEnsureOutOfSourceBuild.cmake +++ /dev/null @@ -1,18 +0,0 @@ -# MACRO_ENSURE_OUT_OF_SOURCE_BUILD() - -macro( MACRO_ENSURE_OUT_OF_SOURCE_BUILD _errorMessage ) - -string( COMPARE EQUAL "${CMAKE_SOURCE_DIR}" "${CMAKE_BINARY_DIR}" _insource ) -if( _insource ) - message( SEND_ERROR "${_errorMessage}" ) - message( FATAL_ERROR - "In-source builds are not allowed. - CMake would overwrite the makefiles distributed with Compiler-RT. - Please create a directory and run cmake from there, passing the path - to this source directory as the last argument. - This process created the file `CMakeCache.txt' and the directory `CMakeFiles'. - Please delete them." - ) -endif( _insource ) - -endmacro( MACRO_ENSURE_OUT_OF_SOURCE_BUILD ) diff --git a/libcxx/cmake/config-ix.cmake b/libcxx/cmake/config-ix.cmake deleted file mode 100644 index 977acdc26caa..000000000000 --- a/libcxx/cmake/config-ix.cmake +++ /dev/null @@ -1,38 +0,0 @@ -include(CheckLibraryExists) -include(CheckCXXCompilerFlag) - -# Check compiler flags -check_cxx_compiler_flag(-std=c++0x LIBCXX_HAS_STDCXX0X_FLAG) -check_cxx_compiler_flag(-fPIC LIBCXX_HAS_FPIC_FLAG) -check_cxx_compiler_flag(-nodefaultlibs LIBCXX_HAS_NODEFAULTLIBS_FLAG) -check_cxx_compiler_flag(-nostdinc++ LIBCXX_HAS_NOSTDINCXX_FLAG) -check_cxx_compiler_flag(-Wall LIBCXX_HAS_WALL_FLAG) -check_cxx_compiler_flag(-W LIBCXX_HAS_W_FLAG) -check_cxx_compiler_flag(-Wno-unused-parameter LIBCXX_HAS_WNO_UNUSED_PARAMETER_FLAG) -check_cxx_compiler_flag(-Wwrite-strings LIBCXX_HAS_WWRITE_STRINGS_FLAG) -check_cxx_compiler_flag(-Wno-long-long LIBCXX_HAS_WNO_LONG_LONG_FLAG) -check_cxx_compiler_flag(-pedantic LIBCXX_HAS_PEDANTIC_FLAG) -check_cxx_compiler_flag(-Werror LIBCXX_HAS_WERROR_FLAG) -check_cxx_compiler_flag(-fno-exceptions LIBCXX_HAS_FNO_EXCEPTIONS_FLAG) -check_cxx_compiler_flag(-fno-rtti LIBCXX_HAS_FNO_RTTI_FLAG) -check_cxx_compiler_flag(/WX LIBCXX_HAS_WX_FLAG) -check_cxx_compiler_flag(/EHsc LIBCXX_HAS_EHSC_FLAG) -check_cxx_compiler_flag(/EHs- LIBCXX_HAS_NO_EHS_FLAG) -check_cxx_compiler_flag(/EHa- LIBCXX_HAS_NO_EHA_FLAG) -check_cxx_compiler_flag(/GR- LIBCXX_HAS_NO_GR_FLAG) - -# Check libraries -check_library_exists(pthread pthread_create "" LIBCXX_HAS_PTHREAD_LIB) -check_library_exists(c printf "" LIBCXX_HAS_C_LIB) -check_library_exists(m ccos "" LIBCXX_HAS_M_LIB) -check_library_exists(rt clock_gettime "" LIBCXX_HAS_RT_LIB) -check_library_exists(gcc_s __gcc_personality_v0 "" LIBCXX_HAS_GCC_S_LIB) - -# Check C++0x features -if (LIBCXX_ENABLE_CXX0X) - if (LIBCXX_HAS_STDCXX0X_FLAG) - set(CMAKE_REQUIRED_DEFINITIONS -std=c++0x) - endif() -else() - set(LIBCXX_HAS_STDCXX0X_FLAG FALSE) -endif() diff --git a/libcxx/include/__bit_reference b/libcxx/include/__bit_reference deleted file mode 100644 index 906b9da462e6..000000000000 --- a/libcxx/include/__bit_reference +++ /dev/null @@ -1,1248 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___BIT_REFERENCE -#define _LIBCPP___BIT_REFERENCE - -#include <__config> -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class __bit_iterator; -template class __bit_const_reference; - -template -struct __has_storage_type -{ - static const bool value = false; -}; - -template ::value> -class __bit_reference -{ - typedef typename _Cp::__storage_type __storage_type; - typedef typename _Cp::__storage_pointer __storage_pointer; - - __storage_pointer __seg_; - __storage_type __mask_; - -#if defined(__clang__) - friend typename _Cp::__self; -#else - friend class _Cp::__self; -#endif - friend class __bit_const_reference<_Cp>; - friend class __bit_iterator<_Cp, false>; -public: - _LIBCPP_INLINE_VISIBILITY operator bool() const _NOEXCEPT - {return static_cast(*__seg_ & __mask_);} - _LIBCPP_INLINE_VISIBILITY bool operator ~() const _NOEXCEPT - {return !static_cast(*this);} - - _LIBCPP_INLINE_VISIBILITY - __bit_reference& operator=(bool __x) _NOEXCEPT - { - if (__x) - *__seg_ |= __mask_; - else - *__seg_ &= ~__mask_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __bit_reference& operator=(const __bit_reference& __x) _NOEXCEPT - {return operator=(static_cast(__x));} - - _LIBCPP_INLINE_VISIBILITY void flip() _NOEXCEPT {*__seg_ ^= __mask_;} - _LIBCPP_INLINE_VISIBILITY __bit_iterator<_Cp, false> operator&() const _NOEXCEPT - {return __bit_iterator<_Cp, false>(__seg_, static_cast(__ctz(__mask_)));} -private: - _LIBCPP_INLINE_VISIBILITY - __bit_reference(__storage_pointer __s, __storage_type __m) _NOEXCEPT - : __seg_(__s), __mask_(__m) {} -}; - -template -class __bit_reference<_Cp, false> -{ -}; - -template -_LIBCPP_INLINE_VISIBILITY inline -void -swap(__bit_reference<_Cp> __x, __bit_reference<_Dp> __y) _NOEXCEPT -{ - bool __t = __x; - __x = __y; - __y = __t; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -swap(__bit_reference<_Cp> __x, bool& __y) _NOEXCEPT -{ - bool __t = __x; - __x = __y; - __y = __t; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -swap(bool& __x, __bit_reference<_Cp> __y) _NOEXCEPT -{ - bool __t = __x; - __x = __y; - __y = __t; -} - -template -class __bit_const_reference -{ - typedef typename _Cp::__storage_type __storage_type; - typedef typename _Cp::__const_storage_pointer __storage_pointer; - - __storage_pointer __seg_; - __storage_type __mask_; - -#if defined(__clang__) - friend typename _Cp::__self; -#else - friend class _Cp::__self; -#endif - friend class __bit_iterator<_Cp, true>; -public: - _LIBCPP_INLINE_VISIBILITY - __bit_const_reference(const __bit_reference<_Cp>& __x) _NOEXCEPT - : __seg_(__x.__seg_), __mask_(__x.__mask_) {} - - _LIBCPP_INLINE_VISIBILITY operator bool() const _NOEXCEPT - {return static_cast(*__seg_ & __mask_);} - - _LIBCPP_INLINE_VISIBILITY __bit_iterator<_Cp, true> operator&() const _NOEXCEPT - {return __bit_iterator<_Cp, true>(__seg_, static_cast(__ctz(__mask_)));} -private: - _LIBCPP_INLINE_VISIBILITY - __bit_const_reference(__storage_pointer __s, __storage_type __m) _NOEXCEPT - : __seg_(__s), __mask_(__m) {} - - __bit_const_reference& operator=(const __bit_const_reference& __x); -}; - -// find - -template -__bit_iterator<_Cp, false> -__find_bool_true(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __storage_type __b = *__first.__seg_ & __m; - if (__b) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(__b))); - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word) - if (*__first.__seg_) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(*__first.__seg_))); - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = *__first.__seg_ & __m; - if (__b) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(__b))); - } - return _It(__first.__seg_, static_cast(__n)); -} - -template -__bit_iterator<_Cp, false> -__find_bool_false(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __storage_type __b = ~(*__first.__seg_ & __m); - if (__b) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(__b))); - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word) - { - __storage_type __b = ~*__first.__seg_; - if (__b) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(__b))); - } - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = ~(*__first.__seg_ & __m); - if (__b) - return _It(__first.__seg_, static_cast(_VSTD::__ctz(__b))); - } - return _It(__first.__seg_, static_cast(__n)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<_Cp, false> -find(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __last, const _Tp& __value_) -{ - if (static_cast(__value_)) - return __find_bool_true(__first, static_cast(__last - __first)); - return __find_bool_false(__first, static_cast(__last - __first)); -} - -// count - -template -typename __bit_iterator<_Cp, false>::difference_type -__count_bool_true(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - typedef typename _It::difference_type difference_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - difference_type __r = 0; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __r = _VSTD::__pop_count(*__first.__seg_ & __m); - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word) - __r += _VSTD::__pop_count(*__first.__seg_); - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __r += _VSTD::__pop_count(*__first.__seg_ & __m); - } - return __r; -} - -template -typename __bit_iterator<_Cp, false>::difference_type -__count_bool_false(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - typedef typename _It::difference_type difference_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - difference_type __r = 0; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __r = _VSTD::__pop_count(~(*__first.__seg_ & __m)); - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - for (; __n >= __bits_per_word; ++__first.__seg_, __n -= __bits_per_word) - __r += _VSTD::__pop_count(~*__first.__seg_); - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __r += _VSTD::__pop_count(~(*__first.__seg_ & __m)); - } - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __bit_iterator<_Cp, false>::difference_type -count(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __last, const _Tp& __value_) -{ - if (static_cast(__value_)) - return __count_bool_true(__first, static_cast(__last - __first)); - return __count_bool_false(__first, static_cast(__last - __first)); -} - -// fill_n - -template -void -__fill_n_false(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - *__first.__seg_ &= ~__m; - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - __storage_type __nw = __n / __bits_per_word; - _VSTD::memset(__first.__seg_, 0, __nw * sizeof(__storage_type)); - __n -= __nw * __bits_per_word; - // do last partial word - if (__n > 0) - { - __first.__seg_ += __nw; - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - *__first.__seg_ &= ~__m; - } -} - -template -void -__fill_n_true(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n) -{ - typedef __bit_iterator<_Cp, false> _It; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - // do first partial word - if (__first.__ctz_ != 0) - { - __storage_type __clz_f = static_cast<__storage_type>(__bits_per_word - __first.__ctz_); - __storage_type __dn = _VSTD::min(__clz_f, __n); - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - *__first.__seg_ |= __m; - __n -= __dn; - ++__first.__seg_; - } - // do middle whole words - __storage_type __nw = __n / __bits_per_word; - _VSTD::memset(__first.__seg_, -1, __nw * sizeof(__storage_type)); - __n -= __nw * __bits_per_word; - // do last partial word - if (__n > 0) - { - __first.__seg_ += __nw; - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - *__first.__seg_ |= __m; - } -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -fill_n(__bit_iterator<_Cp, false> __first, typename _Cp::size_type __n, bool __value_) -{ - if (__n > 0) - { - if (__value_) - __fill_n_true(__first, __n); - else - __fill_n_false(__first, __n); - } -} - -// fill - -template -inline _LIBCPP_INLINE_VISIBILITY -void -fill(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __last, bool __value_) -{ - _VSTD::fill_n(__first, static_cast(__last - __first), __value_); -} - -// copy - -template -__bit_iterator<_Cp, false> -__copy_aligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, - __bit_iterator<_Cp, false> __result) -{ - typedef __bit_iterator<_Cp, _IsConst> _In; - typedef typename _In::difference_type difference_type; - typedef typename _In::__storage_type __storage_type; - static const unsigned __bits_per_word = _In::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__first.__ctz_ != 0) - { - unsigned __clz = __bits_per_word - __first.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz - __dn)); - __storage_type __b = *__first.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b; - __result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__dn + __result.__ctz_) % __bits_per_word); - ++__first.__seg_; - // __first.__ctz_ = 0; - } - // __first.__ctz_ == 0; - // do middle words - __storage_type __nw = __n / __bits_per_word; - _VSTD::memmove(__result.__seg_, __first.__seg_, __nw * sizeof(__storage_type)); - __n -= __nw * __bits_per_word; - __result.__seg_ += __nw; - // do last word - if (__n > 0) - { - __first.__seg_ += __nw; - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = *__first.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b; - __result.__ctz_ = static_cast(__n); - } - } - return __result; -} - -template -__bit_iterator<_Cp, false> -__copy_unaligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, - __bit_iterator<_Cp, false> __result) -{ - typedef __bit_iterator<_Cp, _IsConst> _In; - typedef typename _In::difference_type difference_type; - typedef typename _In::__storage_type __storage_type; - static const unsigned __bits_per_word = _In::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__first.__ctz_ != 0) - { - unsigned __clz_f = __bits_per_word - __first.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz_f), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __storage_type __b = *__first.__seg_ & __m; - unsigned __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __ddn = _VSTD::min<__storage_type>(__dn, __clz_r); - __m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn)); - *__result.__seg_ &= ~__m; - if (__result.__ctz_ > __first.__ctz_) - *__result.__seg_ |= __b << (__result.__ctz_ - __first.__ctz_); - else - *__result.__seg_ |= __b >> (__first.__ctz_ - __result.__ctz_); - __result.__seg_ += (__ddn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__ddn + __result.__ctz_) % __bits_per_word); - __dn -= __ddn; - if (__dn > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __dn); - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b >> (__first.__ctz_ + __ddn); - __result.__ctz_ = static_cast(__dn); - } - ++__first.__seg_; - // __first.__ctz_ = 0; - } - // __first.__ctz_ == 0; - // do middle words - unsigned __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __m = ~__storage_type(0) << __result.__ctz_; - for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_) - { - __storage_type __b = *__first.__seg_; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b << __result.__ctz_; - ++__result.__seg_; - *__result.__seg_ &= __m; - *__result.__seg_ |= __b >> __clz_r; - } - // do last word - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = *__first.__seg_ & __m; - __storage_type __dn = _VSTD::min(__n, static_cast(__clz_r)); - __m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn)); - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b << __result.__ctz_; - __result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__dn + __result.__ctz_) % __bits_per_word); - __n -= __dn; - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b >> __dn; - __result.__ctz_ = static_cast(__n); - } - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<_Cp, false> -copy(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result) -{ - if (__first.__ctz_ == __result.__ctz_) - return __copy_aligned(__first, __last, __result); - return __copy_unaligned(__first, __last, __result); -} - -// copy_backward - -template -__bit_iterator<_Cp, false> -__copy_backward_aligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, - __bit_iterator<_Cp, false> __result) -{ - typedef __bit_iterator<_Cp, _IsConst> _In; - typedef typename _In::difference_type difference_type; - typedef typename _In::__storage_type __storage_type; - static const unsigned __bits_per_word = _In::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__last.__ctz_ != 0) - { - difference_type __dn = _VSTD::min(static_cast(__last.__ctz_), __n); - __n -= __dn; - unsigned __clz = __bits_per_word - __last.__ctz_; - __storage_type __m = (~__storage_type(0) << (__last.__ctz_ - __dn)) & (~__storage_type(0) >> __clz); - __storage_type __b = *__last.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b; - __result.__ctz_ = static_cast(((-__dn & (__bits_per_word - 1)) + - __result.__ctz_) % __bits_per_word); - // __last.__ctz_ = 0 - } - // __last.__ctz_ == 0 || __n == 0 - // __result.__ctz_ == 0 || __n == 0 - // do middle words - __storage_type __nw = __n / __bits_per_word; - __result.__seg_ -= __nw; - __last.__seg_ -= __nw; - _VSTD::memmove(__result.__seg_, __last.__seg_, __nw * sizeof(__storage_type)); - __n -= __nw * __bits_per_word; - // do last word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) << (__bits_per_word - __n); - __storage_type __b = *--__last.__seg_ & __m; - *--__result.__seg_ &= ~__m; - *__result.__seg_ |= __b; - __result.__ctz_ = static_cast(-__n & (__bits_per_word - 1)); - } - } - return __result; -} - -template -__bit_iterator<_Cp, false> -__copy_backward_unaligned(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, - __bit_iterator<_Cp, false> __result) -{ - typedef __bit_iterator<_Cp, _IsConst> _In; - typedef typename _In::difference_type difference_type; - typedef typename _In::__storage_type __storage_type; - static const unsigned __bits_per_word = _In::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__last.__ctz_ != 0) - { - difference_type __dn = _VSTD::min(static_cast(__last.__ctz_), __n); - __n -= __dn; - unsigned __clz_l = __bits_per_word - __last.__ctz_; - __storage_type __m = (~__storage_type(0) << (__last.__ctz_ - __dn)) & (~__storage_type(0) >> __clz_l); - __storage_type __b = *__last.__seg_ & __m; - unsigned __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __ddn = _VSTD::min(__dn, static_cast(__result.__ctz_)); - if (__ddn > 0) - { - __m = (~__storage_type(0) << (__result.__ctz_ - __ddn)) & (~__storage_type(0) >> __clz_r); - *__result.__seg_ &= ~__m; - if (__result.__ctz_ > __last.__ctz_) - *__result.__seg_ |= __b << (__result.__ctz_ - __last.__ctz_); - else - *__result.__seg_ |= __b >> (__last.__ctz_ - __result.__ctz_); - __result.__ctz_ = static_cast(((-__ddn & (__bits_per_word - 1)) + - __result.__ctz_) % __bits_per_word); - __dn -= __ddn; - } - if (__dn > 0) - { - // __result.__ctz_ == 0 - --__result.__seg_; - __result.__ctz_ = static_cast(-__dn & (__bits_per_word - 1)); - __m = ~__storage_type(0) << __result.__ctz_; - *__result.__seg_ &= ~__m; - __last.__ctz_ -= __dn + __ddn; - *__result.__seg_ |= __b << (__result.__ctz_ - __last.__ctz_); - } - // __last.__ctz_ = 0 - } - // __last.__ctz_ == 0 || __n == 0 - // __result.__ctz_ != 0 || __n == 0 - // do middle words - unsigned __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __m = ~__storage_type(0) >> __clz_r; - for (; __n >= __bits_per_word; __n -= __bits_per_word) - { - __storage_type __b = *--__last.__seg_; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b >> __clz_r; - *--__result.__seg_ &= __m; - *__result.__seg_ |= __b << __result.__ctz_; - } - // do last word - if (__n > 0) - { - __m = ~__storage_type(0) << (__bits_per_word - __n); - __storage_type __b = *--__last.__seg_ & __m; - __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __dn = _VSTD::min(__n, static_cast(__result.__ctz_)); - __m = (~__storage_type(0) << (__result.__ctz_ - __dn)) & (~__storage_type(0) >> __clz_r); - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b >> (__bits_per_word - __result.__ctz_); - __result.__ctz_ = static_cast(((-__dn & (__bits_per_word - 1)) + - __result.__ctz_) % __bits_per_word); - __n -= __dn; - if (__n > 0) - { - // __result.__ctz_ == 0 - --__result.__seg_; - __result.__ctz_ = static_cast(-__n & (__bits_per_word - 1)); - __m = ~__storage_type(0) << __result.__ctz_; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b << (__result.__ctz_ - (__bits_per_word - __n - __dn)); - } - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<_Cp, false> -copy_backward(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result) -{ - if (__last.__ctz_ == __result.__ctz_) - return __copy_backward_aligned(__first, __last, __result); - return __copy_backward_unaligned(__first, __last, __result); -} - -// move - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<_Cp, false> -move(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result) -{ - return _VSTD::copy(__first, __last, __result); -} - -// move_backward - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<_Cp, false> -move_backward(__bit_iterator<_Cp, _IsConst> __first, __bit_iterator<_Cp, _IsConst> __last, __bit_iterator<_Cp, false> __result) -{ - return _VSTD::copy(__first, __last, __result); -} - -// swap_ranges - -template -__bit_iterator<__C2, false> -__swap_ranges_aligned(__bit_iterator<__C1, false> __first, __bit_iterator<__C1, false> __last, - __bit_iterator<__C2, false> __result) -{ - typedef __bit_iterator<__C1, false> _I1; - typedef typename _I1::difference_type difference_type; - typedef typename _I1::__storage_type __storage_type; - static const unsigned __bits_per_word = _I1::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__first.__ctz_ != 0) - { - unsigned __clz = __bits_per_word - __first.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz - __dn)); - __storage_type __b1 = *__first.__seg_ & __m; - *__first.__seg_ &= ~__m; - __storage_type __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b1; - *__first.__seg_ |= __b2; - __result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__dn + __result.__ctz_) % __bits_per_word); - ++__first.__seg_; - // __first.__ctz_ = 0; - } - // __first.__ctz_ == 0; - // do middle words - for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_, ++__result.__seg_) - swap(*__first.__seg_, *__result.__seg_); - // do last word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b1 = *__first.__seg_ & __m; - *__first.__seg_ &= ~__m; - __storage_type __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b1; - *__first.__seg_ |= __b2; - __result.__ctz_ = static_cast(__n); - } - } - return __result; -} - -template -__bit_iterator<__C2, false> -__swap_ranges_unaligned(__bit_iterator<__C1, false> __first, __bit_iterator<__C1, false> __last, - __bit_iterator<__C2, false> __result) -{ - typedef __bit_iterator<__C1, false> _I1; - typedef typename _I1::difference_type difference_type; - typedef typename _I1::__storage_type __storage_type; - static const unsigned __bits_per_word = _I1::__bits_per_word; - difference_type __n = __last - __first; - if (__n > 0) - { - // do first word - if (__first.__ctz_ != 0) - { - unsigned __clz_f = __bits_per_word - __first.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz_f), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __storage_type __b1 = *__first.__seg_ & __m; - *__first.__seg_ &= ~__m; - unsigned __clz_r = __bits_per_word - __result.__ctz_; - __storage_type __ddn = _VSTD::min<__storage_type>(__dn, __clz_r); - __m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn)); - __storage_type __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - if (__result.__ctz_ > __first.__ctz_) - { - unsigned __s = __result.__ctz_ - __first.__ctz_; - *__result.__seg_ |= __b1 << __s; - *__first.__seg_ |= __b2 >> __s; - } - else - { - unsigned __s = __first.__ctz_ - __result.__ctz_; - *__result.__seg_ |= __b1 >> __s; - *__first.__seg_ |= __b2 << __s; - } - __result.__seg_ += (__ddn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__ddn + __result.__ctz_) % __bits_per_word); - __dn -= __ddn; - if (__dn > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __dn); - __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - unsigned __s = __first.__ctz_ + __ddn; - *__result.__seg_ |= __b1 >> __s; - *__first.__seg_ |= __b2 << __s; - __result.__ctz_ = static_cast(__dn); - } - ++__first.__seg_; - // __first.__ctz_ = 0; - } - // __first.__ctz_ == 0; - // do middle words - __storage_type __m = ~__storage_type(0) << __result.__ctz_; - unsigned __clz_r = __bits_per_word - __result.__ctz_; - for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first.__seg_) - { - __storage_type __b1 = *__first.__seg_; - __storage_type __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b1 << __result.__ctz_; - *__first.__seg_ = __b2 >> __result.__ctz_; - ++__result.__seg_; - __b2 = *__result.__seg_ & ~__m; - *__result.__seg_ &= __m; - *__result.__seg_ |= __b1 >> __clz_r; - *__first.__seg_ |= __b2 << __clz_r; - } - // do last word - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b1 = *__first.__seg_ & __m; - *__first.__seg_ &= ~__m; - __storage_type __dn = _VSTD::min<__storage_type>(__n, __clz_r); - __m = (~__storage_type(0) << __result.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn)); - __storage_type __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b1 << __result.__ctz_; - *__first.__seg_ |= __b2 >> __result.__ctz_; - __result.__seg_ += (__dn + __result.__ctz_) / __bits_per_word; - __result.__ctz_ = static_cast((__dn + __result.__ctz_) % __bits_per_word); - __n -= __dn; - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - __b2 = *__result.__seg_ & __m; - *__result.__seg_ &= ~__m; - *__result.__seg_ |= __b1 >> __dn; - *__first.__seg_ |= __b2 << __dn; - __result.__ctz_ = static_cast(__n); - } - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bit_iterator<__C2, false> -swap_ranges(__bit_iterator<__C1, false> __first1, __bit_iterator<__C1, false> __last1, - __bit_iterator<__C2, false> __first2) -{ - if (__first1.__ctz_ == __first2.__ctz_) - return __swap_ranges_aligned(__first1, __last1, __first2); - return __swap_ranges_unaligned(__first1, __last1, __first2); -} - -// rotate - -template -struct __bit_array -{ - typedef typename _Cp::difference_type difference_type; - typedef typename _Cp::__storage_type __storage_type; - typedef typename _Cp::iterator iterator; - static const unsigned __bits_per_word = _Cp::__bits_per_word; - static const unsigned _Np = 4; - - difference_type __size_; - __storage_type __word_[_Np]; - - _LIBCPP_INLINE_VISIBILITY static difference_type capacity() - {return static_cast(_Np * __bits_per_word);} - _LIBCPP_INLINE_VISIBILITY explicit __bit_array(difference_type __s) : __size_(__s) {} - _LIBCPP_INLINE_VISIBILITY iterator begin() {return iterator(__word_, 0);} - _LIBCPP_INLINE_VISIBILITY iterator end() {return iterator(__word_ + __size_ / __bits_per_word, - static_cast(__size_ % __bits_per_word));} -}; - -template -__bit_iterator<_Cp, false> -rotate(__bit_iterator<_Cp, false> __first, __bit_iterator<_Cp, false> __middle, __bit_iterator<_Cp, false> __last) -{ - typedef __bit_iterator<_Cp, false> _I1; - typedef typename _I1::difference_type difference_type; - typedef typename _I1::__storage_type __storage_type; - difference_type __d1 = __middle - __first; - difference_type __d2 = __last - __middle; - _I1 __r = __first + __d2; - while (__d1 != 0 && __d2 != 0) - { - if (__d1 <= __d2) - { - if (__d1 <= __bit_array<_Cp>::capacity()) - { - __bit_array<_Cp> __b(__d1); - _VSTD::copy(__first, __middle, __b.begin()); - _VSTD::copy(__b.begin(), __b.end(), _VSTD::copy(__middle, __last, __first)); - break; - } - else - { - __bit_iterator<_Cp, false> __mp = _VSTD::swap_ranges(__first, __middle, __middle); - __first = __middle; - __middle = __mp; - __d2 -= __d1; - } - } - else - { - if (__d2 <= __bit_array<_Cp>::capacity()) - { - __bit_array<_Cp> __b(__d2); - _VSTD::copy(__middle, __last, __b.begin()); - _VSTD::copy_backward(__b.begin(), __b.end(), _VSTD::copy_backward(__first, __middle, __last)); - break; - } - else - { - __bit_iterator<_Cp, false> __mp = __first + __d2; - _VSTD::swap_ranges(__first, __mp, __middle); - __first = __mp; - __d1 -= __d2; - } - } - } - return __r; -} - -// equal - -template -bool -__equal_unaligned(__bit_iterator<_Cp, true> __first1, __bit_iterator<_Cp, true> __last1, - __bit_iterator<_Cp, true> __first2) -{ - typedef __bit_iterator<_Cp, true> _It; - typedef typename _It::difference_type difference_type; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - difference_type __n = __last1 - __first1; - if (__n > 0) - { - // do first word - if (__first1.__ctz_ != 0) - { - unsigned __clz_f = __bits_per_word - __first1.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz_f), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first1.__ctz_) & (~__storage_type(0) >> (__clz_f - __dn)); - __storage_type __b = *__first1.__seg_ & __m; - unsigned __clz_r = __bits_per_word - __first2.__ctz_; - __storage_type __ddn = _VSTD::min<__storage_type>(__dn, __clz_r); - __m = (~__storage_type(0) << __first2.__ctz_) & (~__storage_type(0) >> (__clz_r - __ddn)); - if (__first2.__ctz_ > __first1.__ctz_) - if ((*__first2.__seg_ & __m) != (__b << (__first2.__ctz_ - __first1.__ctz_))) - return false; - else - if ((*__first2.__seg_ & __m) != (__b >> (__first1.__ctz_ - __first2.__ctz_))) - return false; - __first2.__seg_ += (__ddn + __first2.__ctz_) / __bits_per_word; - __first2.__ctz_ = static_cast((__ddn + __first2.__ctz_) % __bits_per_word); - __dn -= __ddn; - if (__dn > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __dn); - if ((*__first2.__seg_ & __m) != (__b >> (__first1.__ctz_ + __ddn))) - return false; - __first2.__ctz_ = static_cast(__dn); - } - ++__first1.__seg_; - // __first1.__ctz_ = 0; - } - // __first1.__ctz_ == 0; - // do middle words - unsigned __clz_r = __bits_per_word - __first2.__ctz_; - __storage_type __m = ~__storage_type(0) << __first2.__ctz_; - for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first1.__seg_) - { - __storage_type __b = *__first1.__seg_; - if ((*__first2.__seg_ & __m) != (__b << __first2.__ctz_)) - return false; - ++__first2.__seg_; - if ((*__first2.__seg_ & ~__m) != (__b >> __clz_r)) - return false; - } - // do last word - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = *__first1.__seg_ & __m; - __storage_type __dn = _VSTD::min(__n, static_cast(__clz_r)); - __m = (~__storage_type(0) << __first2.__ctz_) & (~__storage_type(0) >> (__clz_r - __dn)); - if ((*__first2.__seg_ & __m) != (__b << __first2.__ctz_)) - return false; - __first2.__seg_ += (__dn + __first2.__ctz_) / __bits_per_word; - __first2.__ctz_ = static_cast((__dn + __first2.__ctz_) % __bits_per_word); - __n -= __dn; - if (__n > 0) - { - __m = ~__storage_type(0) >> (__bits_per_word - __n); - if ((*__first2.__seg_ & __m) != (__b >> __dn)) - return false; - } - } - } - return true; -} - -template -bool -__equal_aligned(__bit_iterator<_Cp, true> __first1, __bit_iterator<_Cp, true> __last1, - __bit_iterator<_Cp, true> __first2) -{ - typedef __bit_iterator<_Cp, true> _It; - typedef typename _It::difference_type difference_type; - typedef typename _It::__storage_type __storage_type; - static const unsigned __bits_per_word = _It::__bits_per_word; - difference_type __n = __last1 - __first1; - if (__n > 0) - { - // do first word - if (__first1.__ctz_ != 0) - { - unsigned __clz = __bits_per_word - __first1.__ctz_; - difference_type __dn = _VSTD::min(static_cast(__clz), __n); - __n -= __dn; - __storage_type __m = (~__storage_type(0) << __first1.__ctz_) & (~__storage_type(0) >> (__clz - __dn)); - if ((*__first2.__seg_ & __m) != (*__first1.__seg_ & __m)) - return false; - ++__first2.__seg_; - ++__first1.__seg_; - // __first1.__ctz_ = 0; - // __first2.__ctz_ = 0; - } - // __first1.__ctz_ == 0; - // __first2.__ctz_ == 0; - // do middle words - for (; __n >= __bits_per_word; __n -= __bits_per_word, ++__first1.__seg_, ++__first2.__seg_) - if (*__first2.__seg_ != *__first1.__seg_) - return false; - // do last word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - if ((*__first2.__seg_ & __m) != (*__first1.__seg_ & __m)) - return false; - } - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -equal(__bit_iterator<_Cp, _IC1> __first1, __bit_iterator<_Cp, _IC1> __last1, __bit_iterator<_Cp, _IC2> __first2) -{ - if (__first1.__ctz_ == __first2.__ctz_) - return __equal_aligned(__first1, __last1, __first2); - return __equal_unaligned(__first1, __last1, __first2); -} - -template -class __bit_iterator -{ -public: - typedef typename _Cp::difference_type difference_type; - typedef bool value_type; - typedef __bit_iterator pointer; - typedef typename conditional<_IsConst, __bit_const_reference<_Cp>, __bit_reference<_Cp> >::type reference; - typedef random_access_iterator_tag iterator_category; - -private: - typedef typename _Cp::__storage_type __storage_type; - typedef typename conditional<_IsConst, typename _Cp::__const_storage_pointer, - typename _Cp::__storage_pointer>::type __storage_pointer; - static const unsigned __bits_per_word = _Cp::__bits_per_word; - - __storage_pointer __seg_; - unsigned __ctz_; - -public: - _LIBCPP_INLINE_VISIBILITY __bit_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - __bit_iterator(const __bit_iterator<_Cp, false>& __it) _NOEXCEPT - : __seg_(__it.__seg_), __ctz_(__it.__ctz_) {} - - _LIBCPP_INLINE_VISIBILITY reference operator*() const _NOEXCEPT - {return reference(__seg_, __storage_type(1) << __ctz_);} - - _LIBCPP_INLINE_VISIBILITY __bit_iterator& operator++() - { - if (__ctz_ != __bits_per_word-1) - ++__ctz_; - else - { - __ctz_ = 0; - ++__seg_; - } - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator operator++(int) - { - __bit_iterator __tmp = *this; - ++(*this); - return __tmp; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator& operator--() - { - if (__ctz_ != 0) - --__ctz_; - else - { - __ctz_ = __bits_per_word - 1; - --__seg_; - } - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator operator--(int) - { - __bit_iterator __tmp = *this; - --(*this); - return __tmp; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator& operator+=(difference_type __n) - { - if (__n >= 0) - __seg_ += (__n + __ctz_) / __bits_per_word; - else - __seg_ += static_cast(__n - __bits_per_word + __ctz_ + 1) - / static_cast(__bits_per_word); - __n &= (__bits_per_word - 1); - __ctz_ = static_cast((__n + __ctz_) % __bits_per_word); - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator& operator-=(difference_type __n) - { - return *this += -__n; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator operator+(difference_type __n) const - { - __bit_iterator __t(*this); - __t += __n; - return __t; - } - - _LIBCPP_INLINE_VISIBILITY __bit_iterator operator-(difference_type __n) const - { - __bit_iterator __t(*this); - __t -= __n; - return __t; - } - - _LIBCPP_INLINE_VISIBILITY - friend __bit_iterator operator+(difference_type __n, const __bit_iterator& __it) {return __it + __n;} - - _LIBCPP_INLINE_VISIBILITY - friend difference_type operator-(const __bit_iterator& __x, const __bit_iterator& __y) - {return (__x.__seg_ - __y.__seg_) * __bits_per_word + __x.__ctz_ - __y.__ctz_;} - - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const {return *(*this + __n);} - - _LIBCPP_INLINE_VISIBILITY friend bool operator==(const __bit_iterator& __x, const __bit_iterator& __y) - {return __x.__seg_ == __y.__seg_ && __x.__ctz_ == __y.__ctz_;} - - _LIBCPP_INLINE_VISIBILITY friend bool operator!=(const __bit_iterator& __x, const __bit_iterator& __y) - {return !(__x == __y);} - - _LIBCPP_INLINE_VISIBILITY friend bool operator<(const __bit_iterator& __x, const __bit_iterator& __y) - {return __x.__seg_ < __y.__seg_ || (__x.__seg_ == __y.__seg_ && __x.__ctz_ < __y.__ctz_);} - - _LIBCPP_INLINE_VISIBILITY friend bool operator>(const __bit_iterator& __x, const __bit_iterator& __y) - {return __y < __x;} - - _LIBCPP_INLINE_VISIBILITY friend bool operator<=(const __bit_iterator& __x, const __bit_iterator& __y) - {return !(__y < __x);} - - _LIBCPP_INLINE_VISIBILITY friend bool operator>=(const __bit_iterator& __x, const __bit_iterator& __y) - {return !(__x < __y);} - -private: - _LIBCPP_INLINE_VISIBILITY - __bit_iterator(__storage_pointer __s, unsigned __ctz) _NOEXCEPT - : __seg_(__s), __ctz_(__ctz) {} - -#if defined(__clang__) - friend typename _Cp::__self; -#else - friend class _Cp::__self; -#endif - friend class __bit_reference<_Cp>; - friend class __bit_const_reference<_Cp>; - friend class __bit_iterator<_Cp, true>; - template friend struct __bit_array; - template friend void __fill_n_false(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n); - template friend void __fill_n_true(__bit_iterator<_Dp, false> __first, typename _Dp::size_type __n); - template friend __bit_iterator<_Dp, false> __copy_aligned(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<_Dp, false> __copy_unaligned(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<_Dp, false> copy(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<_Dp, false> __copy_backward_aligned(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<_Dp, false> __copy_backward_unaligned(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<_Dp, false> copy_backward(__bit_iterator<_Dp, _IC> __first, - __bit_iterator<_Dp, _IC> __last, - __bit_iterator<_Dp, false> __result); - template friend __bit_iterator<__C2, false> __swap_ranges_aligned(__bit_iterator<__C1, false>, - __bit_iterator<__C1, false>, - __bit_iterator<__C2, false>); - template friend __bit_iterator<__C2, false> __swap_ranges_unaligned(__bit_iterator<__C1, false>, - __bit_iterator<__C1, false>, - __bit_iterator<__C2, false>); - template friend __bit_iterator<__C2, false> swap_ranges(__bit_iterator<__C1, false>, - __bit_iterator<__C1, false>, - __bit_iterator<__C2, false>); - template friend __bit_iterator<_Dp, false> rotate(__bit_iterator<_Dp, false>, - __bit_iterator<_Dp, false>, - __bit_iterator<_Dp, false>); - template friend bool __equal_aligned(__bit_iterator<_Dp, true>, - __bit_iterator<_Dp, true>, - __bit_iterator<_Dp, true>); - template friend bool __equal_unaligned(__bit_iterator<_Dp, true>, - __bit_iterator<_Dp, true>, - __bit_iterator<_Dp, true>); - template friend bool equal(__bit_iterator<_Dp, _IC1>, - __bit_iterator<_Dp, _IC1>, - __bit_iterator<_Dp, _IC2>); - template friend __bit_iterator<_Dp, false> __find_bool_true(__bit_iterator<_Dp, false>, - typename _Dp::size_type); - template friend __bit_iterator<_Dp, false> __find_bool_false(__bit_iterator<_Dp, false>, - typename _Dp::size_type); -}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___BIT_REFERENCE diff --git a/libcxx/include/__config b/libcxx/include/__config deleted file mode 100644 index 7cd01dc1b55b..000000000000 --- a/libcxx/include/__config +++ /dev/null @@ -1,445 +0,0 @@ -// -*- C++ -*- -//===--------------------------- __config ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CONFIG -#define _LIBCPP_CONFIG - -#if !_MSC_VER // explicit macro necessary because it is only defined below in this file -#pragma GCC system_header -#endif - -#define _LIBCPP_VERSION 1001 - -#define _LIBCPP_ABI_VERSION 1 - -#define _LIBCPP_CONCAT1(_LIBCPP_X,_LIBCPP_Y) _LIBCPP_X##_LIBCPP_Y -#define _LIBCPP_CONCAT(_LIBCPP_X,_LIBCPP_Y) _LIBCPP_CONCAT1(_LIBCPP_X,_LIBCPP_Y) - -#define _LIBCPP_NAMESPACE _LIBCPP_CONCAT(__,_LIBCPP_ABI_VERSION) - -#ifdef __LITTLE_ENDIAN__ -#if __LITTLE_ENDIAN__ -#define _LIBCPP_LITTLE_ENDIAN 1 -#define _LIBCPP_BIG_ENDIAN 0 -#endif // __LITTLE_ENDIAN__ -#endif // __LITTLE_ENDIAN__ - -#ifdef __BIG_ENDIAN__ -#if __BIG_ENDIAN__ -#define _LIBCPP_LITTLE_ENDIAN 0 -#define _LIBCPP_BIG_ENDIAN 1 -#endif // __BIG_ENDIAN__ -#endif // __BIG_ENDIAN__ - -#ifdef __FreeBSD__ -# include -# if _BYTE_ORDER == _LITTLE_ENDIAN -# define _LIBCPP_LITTLE_ENDIAN 1 -# define _LIBCPP_BIG_ENDIAN 0 -# else // _BYTE_ORDER == _LITTLE_ENDIAN -# define _LIBCPP_LITTLE_ENDIAN 0 -# define _LIBCPP_BIG_ENDIAN 1 -# endif // _BYTE_ORDER == _LITTLE_ENDIAN -#endif // __FreeBSD__ - -#ifdef _WIN32 -# define _LIBCPP_LITTLE_ENDIAN 1 -# define _LIBCPP_BIG_ENDIAN 0 -// Compiler intrinsics (GCC or MSVC) -# if (defined(_MSC_VER) && _MSC_VER >= 1400) || (__GNUC__ >= 4 && __GNUC_MINOR__ > 3) -# define _LIBCP_HAS_IS_BASE_OF -# endif -#endif // _WIN32 - -#ifdef __sun__ -# include -# ifdef _LITTLE_ENDIAN -# define _LIBCPP_LITTLE_ENDIAN 1 -# define _LIBCPP_BIG_ENDIAN 0 -# else -# define _LIBCPP_LITTLE_ENDIAN 0 -# define _LIBCPP_BIG_ENDIAN 1 -# endif -#endif // __sun__ - -#if !defined(_LIBCPP_LITTLE_ENDIAN) || !defined(_LIBCPP_BIG_ENDIAN) -# include -# if __BYTE_ORDER == __LITTLE_ENDIAN -# define _LIBCPP_LITTLE_ENDIAN 1 -# define _LIBCPP_BIG_ENDIAN 0 -# elif __BYTE_ORDER == __BIG_ENDIAN -# define _LIBCPP_LITTLE_ENDIAN 0 -# define _LIBCPP_BIG_ENDIAN 1 -# else // __BYTE_ORDER == __BIG_ENDIAN -# error unable to determine endian -# endif -#endif // !defined(_LIBCPP_LITTLE_ENDIAN) || !defined(_LIBCPP_BIG_ENDIAN) - -#if _WIN32 - -// only really useful for a DLL -#ifdef _LIBCPP_DLL // this should be a compiler builtin define ideally... -# ifdef cxx_EXPORTS -# define _LIBCPP_HIDDEN -# define _LIBCPP_VISIBLE __declspec(dllexport) -# else -# define _LIBCPP_HIDDEN -# define _LIBCPP_VISIBLE __declspec(dllimport) -# endif -#else -# define _LIBCPP_HIDDEN -# define _LIBCPP_VISIBLE -#endif - -#ifndef _LIBCPP_INLINE_VISIBILITY -# if _MSC_VER -# define _LIBCPP_INLINE_VISIBILITY __forceinline -# else // MinGW GCC and Clang -# define _LIBCPP_INLINE_VISIBILITY __attribute__ ((__always_inline__)) -# endif -#endif - -#ifndef _LIBCPP_EXCEPTION_ABI -#define _LIBCPP_EXCEPTION_ABI _LIBCPP_VISIBLE -#endif - -#ifndef _LIBCPP_ALWAYS_INLINE -# if _MSC_VER -# define _LIBCPP_ALWAYS_INLINE __forceinline -# endif -#endif - -#endif // _WIN32 - -#ifndef _LIBCPP_HIDDEN -#define _LIBCPP_HIDDEN __attribute__ ((__visibility__("hidden"))) -#endif - -#ifndef _LIBCPP_VISIBLE -#define _LIBCPP_VISIBLE __attribute__ ((__visibility__("default"))) -#endif - -#ifndef _LIBCPP_INLINE_VISIBILITY -#define _LIBCPP_INLINE_VISIBILITY __attribute__ ((__visibility__("hidden"), __always_inline__)) -#endif - -#ifndef _LIBCPP_EXCEPTION_ABI -#define _LIBCPP_EXCEPTION_ABI __attribute__ ((__visibility__("default"))) -#endif - -#ifndef _LIBCPP_CANTTHROW -#define _LIBCPP_CANTTHROW __attribute__ ((__nothrow__)) -#endif - -#ifndef _LIBCPP_ALWAYS_INLINE -#define _LIBCPP_ALWAYS_INLINE __attribute__ ((__visibility__("hidden"), __always_inline__)) -#endif - -#if defined(__clang__) - -#if __has_feature(cxx_alignas) -# define _ALIGNAS(x) alignas(x) -#else -# define _ALIGNAS(x) __attribute__((__aligned__(x))) -#endif - -#if !__has_feature(cxx_alias_templates) -#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES -#endif - -#ifndef __GXX_EXPERIMENTAL_CXX0X__ -#ifdef __linux__ -#define _LIBCPP_HAS_NO_UNICODE_CHARS -#else -typedef __char16_t char16_t; -typedef __char32_t char32_t; -#endif -#endif - -#if !(__has_feature(cxx_exceptions)) -#define _LIBCPP_NO_EXCEPTIONS -#endif - -#if !(__has_feature(cxx_rtti)) -#define _LIBCPP_NO_RTTI -#endif - -#if !(__has_feature(cxx_strong_enums)) -#define _LIBCPP_HAS_NO_STRONG_ENUMS -#endif - -#if !(__has_feature(cxx_decltype)) -#define _LIBCPP_HAS_NO_DECLTYPE -#endif - -#if __has_feature(cxx_attributes) -# define _ATTRIBUTE(x) [[x]] -#else -# define _ATTRIBUTE(x) __attribute__ ((x)) -#endif - -#define _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS - -#if !(__has_feature(cxx_deleted_functions)) -#define _LIBCPP_HAS_NO_DELETED_FUNCTIONS -#endif // !(__has_feature(cxx_deleted_functions)) - -#if !(__has_feature(cxx_lambdas)) -#define _LIBCPP_HAS_NO_LAMBDAS -#endif - -#if !(__has_feature(cxx_nullptr)) -#define _LIBCPP_HAS_NO_NULLPTR -#endif - -#if !(__has_feature(cxx_rvalue_references)) -#define _LIBCPP_HAS_NO_RVALUE_REFERENCES -#endif - -#if !(__has_feature(cxx_static_assert)) -#define _LIBCPP_HAS_NO_STATIC_ASSERT -#endif - -#if !(__has_feature(cxx_auto_type)) -#define _LIBCPP_HAS_NO_AUTO_TYPE -#endif - -#if !(__has_feature(cxx_access_control_sfinae)) || !__has_feature(cxx_trailing_return) -#define _LIBCPP_HAS_NO_ADVANCED_SFINAE -#endif - -#if !(__has_feature(cxx_variadic_templates)) -#define _LIBCPP_HAS_NO_VARIADICS -#endif - -#if !(__has_feature(cxx_trailing_return)) -#define _LIBCPP_HAS_NO_TRAILING_RETURN -#endif - -#if !(__has_feature(cxx_generalized_initializers)) -#define _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS -#endif - -#if __has_feature(is_base_of) -# define _LIBCP_HAS_IS_BASE_OF -#endif - -// Objective-C++ features (opt-in) -#if __has_feature(objc_arc) -#define _LIBCPP_HAS_OBJC_ARC -#endif - -#if __has_feature(objc_arc_weak) -#define _LIBCPP_HAS_OBJC_ARC_WEAK -#define _LIBCPP_HAS_NO_STRONG_ENUMS -#endif - -#if !(__has_feature(cxx_constexpr)) -#define _LIBCPP_HAS_NO_CONSTEXPR -#endif - -#if __FreeBSD__ -#define _LIBCPP_HAS_QUICK_EXIT -#endif - -#if (__has_feature(cxx_noexcept)) -# define _NOEXCEPT noexcept -# define _NOEXCEPT_(x) noexcept(x) -#else -# define _NOEXCEPT throw() -# define _NOEXCEPT_(x) -#endif - -#if __has_feature(underlying_type) -# define _LIBCXX_UNDERLYING_TYPE(T) __underlying_type(T) -#endif - -// Inline namespaces are available in Clang regardless of C++ dialect. -#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std {inline namespace _LIBCPP_NAMESPACE { -#define _LIBCPP_END_NAMESPACE_STD } } -#define _VSTD std::_LIBCPP_NAMESPACE - -namespace std { - inline namespace _LIBCPP_NAMESPACE { - } -} - -#elif defined(__GNUC__) - -#define _ALIGNAS(x) __attribute__((__aligned__(x))) - -#define _ATTRIBUTE(x) __attribute__((x)) - -#if !__EXCEPTIONS -#define _LIBCPP_NO_EXCEPTIONS -#endif - -#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES -#define _LIBCPP_HAS_NO_CONSTEXPR - -#define _NOEXCEPT throw() -#define _NOEXCEPT_(x) - -#ifndef __GXX_EXPERIMENTAL_CXX0X__ - -#define _LIBCPP_HAS_NO_ADVANCED_SFINAE -#define _LIBCPP_HAS_NO_DECLTYPE -#define _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS -#define _LIBCPP_HAS_NO_DELETED_FUNCTIONS -#define _LIBCPP_HAS_NO_NULLPTR -#define _LIBCPP_HAS_NO_STATIC_ASSERT -#define _LIBCPP_HAS_NO_UNICODE_CHARS -#define _LIBCPP_HAS_NO_VARIADICS -#define _LIBCPP_HAS_NO_RVALUE_REFERENCES -#define _LIBCPP_HAS_NO_ALWAYS_INLINE_VARIADICS - -#else // __GXX_EXPERIMENTAL_CXX0X__ - -#define _LIBCPP_HAS_NO_TRAILING_RETURN -#define _LIBCPP_HAS_NO_ALWAYS_INLINE_VARIADICS - -#if !(__GNUC__ >= 4 && __GNUC_MINOR__ >= 3) -#define _LIBCPP_HAS_NO_RVALUE_REFERENCES -#endif - -#if !(__GNUC__ >= 4 && __GNUC_MINOR__ >= 3) -#define _LIBCPP_HAS_NO_STATIC_ASSERT -#endif - -#if !(__GNUC__ >= 4 && __GNUC_MINOR__ >= 4) -#define _LIBCPP_HAS_NO_ADVANCED_SFINAE -#define _LIBCPP_HAS_NO_DECLTYPE -#define _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS -#define _LIBCPP_HAS_NO_DELETED_FUNCTIONS -#define _LIBCPP_HAS_NO_UNICODE_CHARS -#define _LIBCPP_HAS_NO_VARIADICS -#define _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS -#endif // !(__GNUC__ >= 4 && __GNUC_MINOR__ >= 4) - -#if !(__GNUC__ >= 4 && __GNUC_MINOR__ >= 6) -#define _LIBCPP_HAS_NO_NULLPTR -#endif - -#endif // __GXX_EXPERIMENTAL_CXX0X__ - -#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std { namespace _LIBCPP_NAMESPACE { -#define _LIBCPP_END_NAMESPACE_STD } } -#define _VSTD std::_LIBCPP_NAMESPACE - -namespace std { -namespace _LIBCPP_NAMESPACE { -} -using namespace _LIBCPP_NAMESPACE __attribute__((__strong__)); -} - -#elif defined(_MSC_VER) - -#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES -#define _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER -#define _LIBCPP_HAS_NO_CONSTEXPR -#define _LIBCPP_HAS_NO_UNICODE_CHARS -#define _LIBCPP_HAS_NO_DELETED_FUNCTIONS -#define __alignof__ __alignof -#define _ATTRIBUTE __declspec -#define _ALIGNAS(x) __declspec(align(x)) -#define _LIBCPP_HAS_NO_VARIADICS - -#define _NOEXCEPT throw() -#define _NOEXCEPT_(x) - -#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std { -#define _LIBCPP_END_NAMESPACE_STD } -#define _VSTD std - -namespace std { -} - -#endif // __clang__ || __GNUC___ || _MSC_VER - -#ifdef _LIBCPP_HAS_NO_UNICODE_CHARS -typedef unsigned short char16_t; -typedef unsigned int char32_t; -#endif // _LIBCPP_HAS_NO_UNICODE_CHARS - -#ifdef _LIBCPP_HAS_NO_STATIC_ASSERT - -template struct __static_assert_test; -template <> struct __static_assert_test {}; -template struct __static_assert_check {}; -#define static_assert(__b, __m) \ - typedef __static_assert_check)> \ - _LIBCPP_CONCAT(__t, __LINE__) - -#endif // _LIBCPP_HAS_NO_STATIC_ASSERT - -#ifdef _LIBCPP_HAS_NO_DECLTYPE -#define decltype(x) __typeof__(x) -#endif - -#ifdef _LIBCPP_HAS_NO_CONSTEXPR -#define _LIBCPP_CONSTEXPR -#else -#define _LIBCPP_CONSTEXPR constexpr -#endif - -#ifndef __has_feature -#define __has_feature(__x) 0 -#endif - -#if __has_feature(cxx_explicit_conversions) -# define _LIBCPP_EXPLICIT explicit -#else -# define _LIBCPP_EXPLICIT -#endif - -#ifdef _LIBCPP_HAS_NO_STRONG_ENUMS -#define _LIBCPP_DECLARE_STRONG_ENUM(x) struct _LIBCPP_VISIBLE x { enum _ -#define _LIBCPP_DECLARE_STRONG_ENUM_EPILOG(x) \ - _ __v_; \ - _LIBCPP_ALWAYS_INLINE x(_ __v) : __v_(__v) {} \ - _LIBCPP_ALWAYS_INLINE operator int() const {return __v_;} \ - }; -#else // _LIBCPP_HAS_NO_STRONG_ENUMS -#define _LIBCPP_DECLARE_STRONG_ENUM(x) enum class _LIBCPP_VISIBLE x -#define _LIBCPP_DECLARE_STRONG_ENUM_EPILOG(x) -#endif // _LIBCPP_HAS_NO_STRONG_ENUMS - -#if __APPLE__ || __FreeBSD__ || _WIN32 || __sun__ -#define _LIBCPP_LOCALE__L_EXTENSIONS 1 -#endif -#if __FreeBSD__ -#define _DECLARE_C99_LDBL_MATH 1 -#endif - -#if __APPLE__ || __FreeBSD__ -#define _LIBCPP_HAS_DEFAULTRUNELOCALE -#endif - -#if __APPLE__ || __FreeBSD__ || __sun__ -#define _LIBCPP_WCTYPE_IS_MASK -#endif - -#ifdef _LIBCPP_DEBUG2 -# if _LIBCPP_DEBUG2 == 0 -# define _LIBCPP_DEBUG_LEVEL 1 -# elif _LIBCPP_DEBUG2 == 1 -# define _LIBCPP_DEBUG_LEVEL 2 -# else -# error Supported values for _LIBCPP_DEBUG2 are 0 and 1 -# endif -#endif - -#ifdef _LIBCPP_DEBUG2 -# include <__debug> -#else -# define _LIBCPP_ASSERT(x, m) ((void)0) -#endif - -#endif // _LIBCPP_CONFIG diff --git a/libcxx/include/__debug b/libcxx/include/__debug deleted file mode 100644 index 4a0e3cecbb62..000000000000 --- a/libcxx/include/__debug +++ /dev/null @@ -1,191 +0,0 @@ -// -*- C++ -*- -//===--------------------------- __debug ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_DEBUG_H -#define _LIBCPP_DEBUG_H - -#if _LIBCPP_DEBUG_LEVEL >= 1 - -# include -# include -# include -# define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : (_VSTD::printf("%s\n", m), _VSTD::abort())) - -#endif - -#if _LIBCPP_DEBUG_LEVEL >= 2 - -_LIBCPP_BEGIN_NAMESPACE_STD - -struct _LIBCPP_VISIBLE __c_node; - -struct _LIBCPP_VISIBLE __i_node -{ - void* __i_; - __i_node* __next_; - __c_node* __c_; - - __i_node(const __i_node&) = delete; - __i_node& operator=(const __i_node&) = delete; - _LIBCPP_INLINE_VISIBILITY - __i_node(void* __i, __i_node* __next, __c_node* __c) - : __i_(__i), __next_(__next), __c_(__c) {} - ~__i_node(); -}; - -struct _LIBCPP_VISIBLE __c_node -{ - void* __c_; - __c_node* __next_; - __i_node** beg_; - __i_node** end_; - __i_node** cap_; - - __c_node(const __c_node&) = delete; - __c_node& operator=(const __c_node&) = delete; - _LIBCPP_INLINE_VISIBILITY - __c_node(void* __c, __c_node* __next) - : __c_(__c), __next_(__next), beg_(nullptr), end_(nullptr), cap_(nullptr) {} - virtual ~__c_node(); - - virtual bool __dereferenceable(const void*) const = 0; - virtual bool __decrementable(const void*) const = 0; - virtual bool __addable(const void*, ptrdiff_t) const = 0; - virtual bool __subscriptable(const void*, ptrdiff_t) const = 0; - - void __add(__i_node* __i); - _LIBCPP_HIDDEN void __remove(__i_node* __i); -}; - -template -struct _C_node - : public __c_node -{ - _C_node(void* __c, __c_node* __n) - : __c_node(__c, __n) {} - - virtual bool __dereferenceable(const void*) const; - virtual bool __decrementable(const void*) const; - virtual bool __addable(const void*, ptrdiff_t) const; - virtual bool __subscriptable(const void*, ptrdiff_t) const; -}; - -template -bool -_C_node<_Cont>::__dereferenceable(const void* __i) const -{ - typedef typename _Cont::const_iterator iterator; - const iterator* __j = static_cast(__i); - _Cont* _Cp = static_cast<_Cont*>(__c_); - return _Cp->__dereferenceable(__j); -} - -template -bool -_C_node<_Cont>::__decrementable(const void* __i) const -{ - typedef typename _Cont::const_iterator iterator; - const iterator* __j = static_cast(__i); - _Cont* _Cp = static_cast<_Cont*>(__c_); - return _Cp->__decrementable(__j); -} - -template -bool -_C_node<_Cont>::__addable(const void* __i, ptrdiff_t __n) const -{ - typedef typename _Cont::const_iterator iterator; - const iterator* __j = static_cast(__i); - _Cont* _Cp = static_cast<_Cont*>(__c_); - return _Cp->__addable(__j, __n); -} - -template -bool -_C_node<_Cont>::__subscriptable(const void* __i, ptrdiff_t __n) const -{ - typedef typename _Cont::const_iterator iterator; - const iterator* __j = static_cast(__i); - _Cont* _Cp = static_cast<_Cont*>(__c_); - return _Cp->__subscriptable(__j, __n); -} - -class _LIBCPP_VISIBLE __libcpp_db -{ - __c_node** __cbeg_; - __c_node** __cend_; - size_t __csz_; - __i_node** __ibeg_; - __i_node** __iend_; - size_t __isz_; - - __libcpp_db(); -public: - __libcpp_db(const __libcpp_db&) = delete; - __libcpp_db& operator=(const __libcpp_db&) = delete; - ~__libcpp_db(); - - class __db_c_iterator; - class __db_c_const_iterator; - class __db_i_iterator; - class __db_i_const_iterator; - - __db_c_const_iterator __c_end() const; - __db_i_const_iterator __i_end() const; - - template - _LIBCPP_INLINE_VISIBILITY - void __insert_c(_Cont* __c) - { - __c_node* __n = __insert_c(static_cast(__c)); - ::new(__n) _C_node<_Cont>(__n->__c_, __n->__next_); - } - - void __insert_i(void* __i); - __c_node* __insert_c(void* __c); - void __erase_c(void* __c); - - void __insert_ic(void* __i, const void* __c); - void __iterator_copy(void* __i, const void* __i0); - void __erase_i(void* __i); - - void* __find_c_from_i(void* __i) const; - void __invalidate_all(void* __c); - __c_node* __find_c_and_lock(void* __c) const; - __c_node* __find_c(void* __c) const; - void unlock() const; - - void swap(void* __c1, void* __c2); - - - bool __dereferenceable(const void* __i) const; - bool __decrementable(const void* __i) const; - bool __addable(const void* __i, ptrdiff_t __n) const; - bool __subscriptable(const void* __i, ptrdiff_t __n) const; - bool __comparable(const void* __i, const void* __j) const; -private: - _LIBCPP_HIDDEN - __i_node* __insert_iterator(void* __i); - _LIBCPP_HIDDEN - __i_node* __find_iterator(const void* __i) const; - - friend _LIBCPP_VISIBLE __libcpp_db* __get_db(); -}; - -_LIBCPP_VISIBLE __libcpp_db* __get_db(); -_LIBCPP_VISIBLE const __libcpp_db* __get_const_db(); - - -_LIBCPP_END_NAMESPACE_STD - -#endif - -#endif // _LIBCPP_DEBUG_H - diff --git a/libcxx/include/__functional_03 b/libcxx/include/__functional_03 deleted file mode 100644 index 3a5397d809d1..000000000000 --- a/libcxx/include/__functional_03 +++ /dev/null @@ -1,2130 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FUNCTIONAL_03 -#define _LIBCPP_FUNCTIONAL_03 - -// manual variadic expansion for - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -template -class __mem_fn - : public __weak_result_type<_Tp> -{ -public: - // types - typedef _Tp type; -private: - type __f_; - -public: - _LIBCPP_INLINE_VISIBILITY __mem_fn(type __f) : __f_(__f) {} - - // invoke - - typename __invoke_return::type - operator() () - { - return __invoke(__f_); - } - - template - typename __invoke_return0::type - operator() (_A0& __a0) - { - return __invoke(__f_, __a0); - } - - template - typename __invoke_return1::type - operator() (_A0& __a0, _A1& __a1) - { - return __invoke(__f_, __a0, __a1); - } - - template - typename __invoke_return2::type - operator() (_A0& __a0, _A1& __a1, _A2& __a2) - { - return __invoke(__f_, __a0, __a1, __a2); - } -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp _Tp::*> -mem_fn(_Rp _Tp::* __pm) -{ - return __mem_fn<_Rp _Tp::*>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)()> -mem_fn(_Rp (_Tp::* __pm)()) -{ - return __mem_fn<_Rp (_Tp::*)()>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0)> -mem_fn(_Rp (_Tp::* __pm)(_A0)) -{ - return __mem_fn<_Rp (_Tp::*)(_A0)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1)) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1, _A2)) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)()> -mem_fn(_Rp (_Tp::* __pm)() const) -{ - return __mem_fn<_Rp (_Tp::*)()>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0)> -mem_fn(_Rp (_Tp::* __pm)(_A0) const) -{ - return __mem_fn<_Rp (_Tp::*)(_A0)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1) const) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1, _A2) const) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)()> -mem_fn(_Rp (_Tp::* __pm)() volatile) -{ - return __mem_fn<_Rp (_Tp::*)()>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0)> -mem_fn(_Rp (_Tp::* __pm)(_A0) volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1) volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1, _A2) volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)()> -mem_fn(_Rp (_Tp::* __pm)() const volatile) -{ - return __mem_fn<_Rp (_Tp::*)()>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0)> -mem_fn(_Rp (_Tp::* __pm)(_A0) const volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1) const volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)> -mem_fn(_Rp (_Tp::* __pm)(_A0, _A1, _A2) const volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_A0, _A1, _A2)>(__pm); -} - -// bad_function_call - -class _LIBCPP_EXCEPTION_ABI bad_function_call - : public exception -{ -}; - -template class _LIBCPP_VISIBLE function; // undefined - -namespace __function -{ - -template -struct __maybe_derive_from_unary_function -{ -}; - -template -struct __maybe_derive_from_unary_function<_Rp(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __maybe_derive_from_binary_function -{ -}; - -template -struct __maybe_derive_from_binary_function<_Rp(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template class __base; - -template -class __base<_Rp()> -{ - __base(const __base&); - __base& operator=(const __base&); -public: - __base() {} - virtual ~__base() {} - virtual __base* __clone() const = 0; - virtual void __clone(__base*) const = 0; - virtual void destroy() = 0; - virtual void destroy_deallocate() = 0; - virtual _Rp operator()() = 0; -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const = 0; - virtual const std::type_info& target_type() const = 0; -#endif // _LIBCPP_NO_RTTI -}; - -template -class __base<_Rp(_A0)> -{ - __base(const __base&); - __base& operator=(const __base&); -public: - __base() {} - virtual ~__base() {} - virtual __base* __clone() const = 0; - virtual void __clone(__base*) const = 0; - virtual void destroy() = 0; - virtual void destroy_deallocate() = 0; - virtual _Rp operator()(_A0) = 0; -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const = 0; - virtual const std::type_info& target_type() const = 0; -#endif // _LIBCPP_NO_RTTI -}; - -template -class __base<_Rp(_A0, _A1)> -{ - __base(const __base&); - __base& operator=(const __base&); -public: - __base() {} - virtual ~__base() {} - virtual __base* __clone() const = 0; - virtual void __clone(__base*) const = 0; - virtual void destroy() = 0; - virtual void destroy_deallocate() = 0; - virtual _Rp operator()(_A0, _A1) = 0; -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const = 0; - virtual const std::type_info& target_type() const = 0; -#endif // _LIBCPP_NO_RTTI -}; - -template -class __base<_Rp(_A0, _A1, _A2)> -{ - __base(const __base&); - __base& operator=(const __base&); -public: - __base() {} - virtual ~__base() {} - virtual __base* __clone() const = 0; - virtual void __clone(__base*) const = 0; - virtual void destroy() = 0; - virtual void destroy_deallocate() = 0; - virtual _Rp operator()(_A0, _A1, _A2) = 0; -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const = 0; - virtual const std::type_info& target_type() const = 0; -#endif // _LIBCPP_NO_RTTI -}; - -template class __func; - -template -class __func<_Fp, _Alloc, _Rp()> - : public __base<_Rp()> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - explicit __func(_Fp __f) : __f_(_VSTD::move(__f)) {} - explicit __func(_Fp __f, _Alloc __a) : __f_(_VSTD::move(__f), _VSTD::move(__a)) {} - virtual __base<_Rp()>* __clone() const; - virtual void __clone(__base<_Rp()>*) const; - virtual void destroy(); - virtual void destroy_deallocate(); - virtual _Rp operator()(); -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const; - virtual const std::type_info& target_type() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -__base<_Rp()>* -__func<_Fp, _Alloc, _Rp()>::__clone() const -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) __func(__f_.first(), _Alloc(__a)); - return __hold.release(); -} - -template -void -__func<_Fp, _Alloc, _Rp()>::__clone(__base<_Rp()>* __p) const -{ - ::new (__p) __func(__f_.first(), __f_.second()); -} - -template -void -__func<_Fp, _Alloc, _Rp()>::destroy() -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__func<_Fp, _Alloc, _Rp()>::destroy_deallocate() -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__func<_Fp, _Alloc, _Rp()>::operator()() -{ - return __invoke(__f_.first()); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const void* -__func<_Fp, _Alloc, _Rp()>::target(const type_info& __ti) const -{ - if (__ti == typeid(_Fp)) - return &__f_.first(); - return (const void*)0; -} - -template -const std::type_info& -__func<_Fp, _Alloc, _Rp()>::target_type() const -{ - return typeid(_Fp); -} - -#endif // _LIBCPP_NO_RTTI - -template -class __func<_Fp, _Alloc, _Rp(_A0)> - : public __base<_Rp(_A0)> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f) : __f_(_VSTD::move(__f)) {} - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f, _Alloc __a) - : __f_(_VSTD::move(__f), _VSTD::move(__a)) {} - virtual __base<_Rp(_A0)>* __clone() const; - virtual void __clone(__base<_Rp(_A0)>*) const; - virtual void destroy(); - virtual void destroy_deallocate(); - virtual _Rp operator()(_A0); -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const; - virtual const std::type_info& target_type() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -__base<_Rp(_A0)>* -__func<_Fp, _Alloc, _Rp(_A0)>::__clone() const -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) __func(__f_.first(), _Alloc(__a)); - return __hold.release(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0)>::__clone(__base<_Rp(_A0)>* __p) const -{ - ::new (__p) __func(__f_.first(), __f_.second()); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0)>::destroy() -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0)>::destroy_deallocate() -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__func<_Fp, _Alloc, _Rp(_A0)>::operator()(_A0 __a0) -{ - return __invoke(__f_.first(), __a0); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const void* -__func<_Fp, _Alloc, _Rp(_A0)>::target(const type_info& __ti) const -{ - if (__ti == typeid(_Fp)) - return &__f_.first(); - return (const void*)0; -} - -template -const std::type_info& -__func<_Fp, _Alloc, _Rp(_A0)>::target_type() const -{ - return typeid(_Fp); -} - -#endif // _LIBCPP_NO_RTTI - -template -class __func<_Fp, _Alloc, _Rp(_A0, _A1)> - : public __base<_Rp(_A0, _A1)> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f) : __f_(_VSTD::move(__f)) {} - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f, _Alloc __a) - : __f_(_VSTD::move(__f), _VSTD::move(__a)) {} - virtual __base<_Rp(_A0, _A1)>* __clone() const; - virtual void __clone(__base<_Rp(_A0, _A1)>*) const; - virtual void destroy(); - virtual void destroy_deallocate(); - virtual _Rp operator()(_A0, _A1); -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const; - virtual const std::type_info& target_type() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -__base<_Rp(_A0, _A1)>* -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::__clone() const -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) __func(__f_.first(), _Alloc(__a)); - return __hold.release(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::__clone(__base<_Rp(_A0, _A1)>* __p) const -{ - ::new (__p) __func(__f_.first(), __f_.second()); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::destroy() -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::destroy_deallocate() -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::operator()(_A0 __a0, _A1 __a1) -{ - return __invoke(__f_.first(), __a0, __a1); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const void* -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::target(const type_info& __ti) const -{ - if (__ti == typeid(_Fp)) - return &__f_.first(); - return (const void*)0; -} - -template -const std::type_info& -__func<_Fp, _Alloc, _Rp(_A0, _A1)>::target_type() const -{ - return typeid(_Fp); -} - -#endif // _LIBCPP_NO_RTTI - -template -class __func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)> - : public __base<_Rp(_A0, _A1, _A2)> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f) : __f_(_VSTD::move(__f)) {} - _LIBCPP_INLINE_VISIBILITY explicit __func(_Fp __f, _Alloc __a) - : __f_(_VSTD::move(__f), _VSTD::move(__a)) {} - virtual __base<_Rp(_A0, _A1, _A2)>* __clone() const; - virtual void __clone(__base<_Rp(_A0, _A1, _A2)>*) const; - virtual void destroy(); - virtual void destroy_deallocate(); - virtual _Rp operator()(_A0, _A1, _A2); -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const; - virtual const std::type_info& target_type() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -__base<_Rp(_A0, _A1, _A2)>* -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::__clone() const -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) __func(__f_.first(), _Alloc(__a)); - return __hold.release(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::__clone(__base<_Rp(_A0, _A1, _A2)>* __p) const -{ - ::new (__p) __func(__f_.first(), __f_.second()); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::destroy() -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::destroy_deallocate() -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::operator()(_A0 __a0, _A1 __a1, _A2 __a2) -{ - return __invoke(__f_.first(), __a0, __a1, __a2); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const void* -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::target(const type_info& __ti) const -{ - if (__ti == typeid(_Fp)) - return &__f_.first(); - return (const void*)0; -} - -template -const std::type_info& -__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)>::target_type() const -{ - return typeid(_Fp); -} - -#endif // _LIBCPP_NO_RTTI - -} // __function - -template -class _LIBCPP_VISIBLE function<_Rp()> -{ - typedef __function::__base<_Rp()> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - - template - static bool __not_null(const _Fp&) {return true;} - template - static bool __not_null(const function<_Rp()>& __p) {return __p;} -public: - typedef _Rp result_type; - - // 20.7.16.2.1, construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY explicit function() : __f_(0) {} - _LIBCPP_INLINE_VISIBILITY function(nullptr_t) : __f_(0) {} - function(const function&); - template - function(_Fp, - typename enable_if::value>::type* = 0); - - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&) : __f_(0) {} - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {} - template - function(allocator_arg_t, const _Alloc&, const function&); - template - function(allocator_arg_t, const _Alloc& __a, _Fp __f, - typename enable_if::value>::type* = 0); - - function& operator=(const function&); - function& operator=(nullptr_t); - template - typename enable_if - < - !is_integral<_Fp>::value, - function& - >::type - operator=(_Fp); - - ~function(); - - // 20.7.16.2.2, function modifiers: - void swap(function&); - template - _LIBCPP_INLINE_VISIBILITY - void assign(_Fp __f, const _Alloc& __a) - {function(allocator_arg, __a, __f).swap(*this);} - - // 20.7.16.2.3, function capacity: - _LIBCPP_INLINE_VISIBILITY operator bool() const {return __f_;} - -private: - // deleted overloads close possible hole in the type system - template - bool operator==(const function<_R2()>&) const;// = delete; - template - bool operator!=(const function<_R2()>&) const;// = delete; -public: - // 20.7.16.2.4, function invocation: - _Rp operator()() const; - -#ifndef _LIBCPP_NO_RTTI - // 20.7.16.2.5, function target access: - const std::type_info& target_type() const; - template _Tp* target(); - template const _Tp* target() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -function<_Rp()>::function(const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp()>::function(allocator_arg_t, const _Alloc&, const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp()>::function(_Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - if (__not_null(__f)) - { - typedef __function::__func<_Fp, allocator<_Fp>, _Rp()> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, allocator<_Fp>(__a)); - __f_ = __hold.release(); - } - } -} - -template -template -function<_Rp()>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - if (__not_null(__f)) - { - typedef __function::__func<_Fp, _Alloc, _Rp()> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, _Alloc(__a)); - __f_ = __hold.release(); - } - } -} - -template -function<_Rp()>& -function<_Rp()>::operator=(const function& __f) -{ - function(__f).swap(*this); - return *this; -} - -template -function<_Rp()>& -function<_Rp()>::operator=(nullptr_t) -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; -} - -template -template -typename enable_if -< - !is_integral<_Fp>::value, - function<_Rp()>& ->::type -function<_Rp()>::operator=(_Fp __f) -{ - function(_VSTD::move(__f)).swap(*this); - return *this; -} - -template -function<_Rp()>::~function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -function<_Rp()>::swap(function& __f) -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__clone(__t); - __f_->destroy(); - __f_ = 0; - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = 0; - __f_ = (__base*)&__buf_; - __t->__clone((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__clone((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -_Rp -function<_Rp()>::operator()() const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__f_ == 0) - throw bad_function_call(); -#endif // _LIBCPP_NO_EXCEPTIONS - return (*__f_)(); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const std::type_info& -function<_Rp()>::target_type() const -{ - if (__f_ == 0) - return typeid(void); - return __f_->target_type(); -} - -template -template -_Tp* -function<_Rp()>::target() -{ - if (__f_ == 0) - return (_Tp*)0; - return (_Tp*)__f_->target(typeid(_Tp)); -} - -template -template -const _Tp* -function<_Rp()>::target() const -{ - if (__f_ == 0) - return (const _Tp*)0; - return (const _Tp*)__f_->target(typeid(_Tp)); -} - -#endif // _LIBCPP_NO_RTTI - -template -class _LIBCPP_VISIBLE function<_Rp(_A0)> - : public unary_function<_A0, _Rp> -{ - typedef __function::__base<_Rp(_A0)> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const _Fp&) {return true;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (*__p)(_B0)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)()) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)() const) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)() volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)() const volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const function<_Rp(_B0)>& __p) {return __p;} -public: - typedef _Rp result_type; - - // 20.7.16.2.1, construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY explicit function() : __f_(0) {} - _LIBCPP_INLINE_VISIBILITY function(nullptr_t) : __f_(0) {} - function(const function&); - template - function(_Fp, - typename enable_if::value>::type* = 0); - - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&) : __f_(0) {} - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {} - template - function(allocator_arg_t, const _Alloc&, const function&); - template - function(allocator_arg_t, const _Alloc& __a, _Fp __f, - typename enable_if::value>::type* = 0); - - function& operator=(const function&); - function& operator=(nullptr_t); - template - typename enable_if - < - !is_integral<_Fp>::value, - function& - >::type - operator=(_Fp); - - ~function(); - - // 20.7.16.2.2, function modifiers: - void swap(function&); - template - _LIBCPP_INLINE_VISIBILITY - void assign(_Fp __f, const _Alloc& __a) - {function(allocator_arg, __a, __f).swap(*this);} - - // 20.7.16.2.3, function capacity: - _LIBCPP_INLINE_VISIBILITY operator bool() const {return __f_;} - -private: - // deleted overloads close possible hole in the type system - template - bool operator==(const function<_R2(_B0)>&) const;// = delete; - template - bool operator!=(const function<_R2(_B0)>&) const;// = delete; -public: - // 20.7.16.2.4, function invocation: - _Rp operator()(_A0) const; - -#ifndef _LIBCPP_NO_RTTI - // 20.7.16.2.5, function target access: - const std::type_info& target_type() const; - template _Tp* target(); - template const _Tp* target() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -function<_Rp(_A0)>::function(const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0)>::function(allocator_arg_t, const _Alloc&, const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0)>::function(_Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - if (__not_null(__f)) - { - typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, allocator<_Fp>(__a)); - __f_ = __hold.release(); - } - } -} - -template -template -function<_Rp(_A0)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - if (__not_null(__f)) - { - typedef __function::__func<_Fp, _Alloc, _Rp(_A0)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, _Alloc(__a)); - __f_ = __hold.release(); - } - } -} - -template -function<_Rp(_A0)>& -function<_Rp(_A0)>::operator=(const function& __f) -{ - function(__f).swap(*this); - return *this; -} - -template -function<_Rp(_A0)>& -function<_Rp(_A0)>::operator=(nullptr_t) -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; -} - -template -template -typename enable_if -< - !is_integral<_Fp>::value, - function<_Rp(_A0)>& ->::type -function<_Rp(_A0)>::operator=(_Fp __f) -{ - function(_VSTD::move(__f)).swap(*this); - return *this; -} - -template -function<_Rp(_A0)>::~function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -function<_Rp(_A0)>::swap(function& __f) -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__clone(__t); - __f_->destroy(); - __f_ = 0; - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = 0; - __f_ = (__base*)&__buf_; - __t->__clone((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__clone((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -_Rp -function<_Rp(_A0)>::operator()(_A0 __a0) const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__f_ == 0) - throw bad_function_call(); -#endif // _LIBCPP_NO_EXCEPTIONS - return (*__f_)(__a0); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const std::type_info& -function<_Rp(_A0)>::target_type() const -{ - if (__f_ == 0) - return typeid(void); - return __f_->target_type(); -} - -template -template -_Tp* -function<_Rp(_A0)>::target() -{ - if (__f_ == 0) - return (_Tp*)0; - return (_Tp*)__f_->target(typeid(_Tp)); -} - -template -template -const _Tp* -function<_Rp(_A0)>::target() const -{ - if (__f_ == 0) - return (const _Tp*)0; - return (const _Tp*)__f_->target(typeid(_Tp)); -} - -#endif // _LIBCPP_NO_RTTI - -template -class _LIBCPP_VISIBLE function<_Rp(_A0, _A1)> - : public binary_function<_A0, _A1, _Rp> -{ - typedef __function::__base<_Rp(_A0, _A1)> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const _Fp&) {return true;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (*__p)(_B0, _B1)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1) const) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1) volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1) const volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const function<_Rp(_B0, _B1)>& __p) {return __p;} -public: - typedef _Rp result_type; - - // 20.7.16.2.1, construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY explicit function() : __f_(0) {} - _LIBCPP_INLINE_VISIBILITY function(nullptr_t) : __f_(0) {} - function(const function&); - template - function(_Fp, - typename enable_if::value>::type* = 0); - - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&) : __f_(0) {} - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {} - template - function(allocator_arg_t, const _Alloc&, const function&); - template - function(allocator_arg_t, const _Alloc& __a, _Fp __f, - typename enable_if::value>::type* = 0); - - function& operator=(const function&); - function& operator=(nullptr_t); - template - typename enable_if - < - !is_integral<_Fp>::value, - function& - >::type - operator=(_Fp); - - ~function(); - - // 20.7.16.2.2, function modifiers: - void swap(function&); - template - _LIBCPP_INLINE_VISIBILITY - void assign(_Fp __f, const _Alloc& __a) - {function(allocator_arg, __a, __f).swap(*this);} - - // 20.7.16.2.3, function capacity: - operator bool() const {return __f_;} - -private: - // deleted overloads close possible hole in the type system - template - bool operator==(const function<_R2(_B0, _B1)>&) const;// = delete; - template - bool operator!=(const function<_R2(_B0, _B1)>&) const;// = delete; -public: - // 20.7.16.2.4, function invocation: - _Rp operator()(_A0, _A1) const; - -#ifndef _LIBCPP_NO_RTTI - // 20.7.16.2.5, function target access: - const std::type_info& target_type() const; - template _Tp* target(); - template const _Tp* target() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -function<_Rp(_A0, _A1)>::function(const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0, _A1)>::function(allocator_arg_t, const _Alloc&, const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0, _A1)>::function(_Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - if (__not_null(__f)) - { - typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0, _A1)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, allocator<_Fp>(__a)); - __f_ = __hold.release(); - } - } -} - -template -template -function<_Rp(_A0, _A1)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - if (__not_null(__f)) - { - typedef __function::__func<_Fp, _Alloc, _Rp(_A0, _A1)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, _Alloc(__a)); - __f_ = __hold.release(); - } - } -} - -template -function<_Rp(_A0, _A1)>& -function<_Rp(_A0, _A1)>::operator=(const function& __f) -{ - function(__f).swap(*this); - return *this; -} - -template -function<_Rp(_A0, _A1)>& -function<_Rp(_A0, _A1)>::operator=(nullptr_t) -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; -} - -template -template -typename enable_if -< - !is_integral<_Fp>::value, - function<_Rp(_A0, _A1)>& ->::type -function<_Rp(_A0, _A1)>::operator=(_Fp __f) -{ - function(_VSTD::move(__f)).swap(*this); - return *this; -} - -template -function<_Rp(_A0, _A1)>::~function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -function<_Rp(_A0, _A1)>::swap(function& __f) -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__clone(__t); - __f_->destroy(); - __f_ = 0; - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = 0; - __f_ = (__base*)&__buf_; - __t->__clone((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__clone((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -_Rp -function<_Rp(_A0, _A1)>::operator()(_A0 __a0, _A1 __a1) const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__f_ == 0) - throw bad_function_call(); -#endif // _LIBCPP_NO_EXCEPTIONS - return (*__f_)(__a0, __a1); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const std::type_info& -function<_Rp(_A0, _A1)>::target_type() const -{ - if (__f_ == 0) - return typeid(void); - return __f_->target_type(); -} - -template -template -_Tp* -function<_Rp(_A0, _A1)>::target() -{ - if (__f_ == 0) - return (_Tp*)0; - return (_Tp*)__f_->target(typeid(_Tp)); -} - -template -template -const _Tp* -function<_Rp(_A0, _A1)>::target() const -{ - if (__f_ == 0) - return (const _Tp*)0; - return (const _Tp*)__f_->target(typeid(_Tp)); -} - -#endif // _LIBCPP_NO_RTTI - -template -class _LIBCPP_VISIBLE function<_Rp(_A0, _A1, _A2)> -{ - typedef __function::__base<_Rp(_A0, _A1, _A2)> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const _Fp&) {return true;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (*__p)(_B0, _B1, _B2)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1, _B2)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1, _B2) const) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1, _B2) volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_B1, _B2) const volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const function<_Rp(_B0, _B1, _B2)>& __p) {return __p;} -public: - typedef _Rp result_type; - - // 20.7.16.2.1, construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY explicit function() : __f_(0) {} - _LIBCPP_INLINE_VISIBILITY function(nullptr_t) : __f_(0) {} - function(const function&); - template - function(_Fp, - typename enable_if::value>::type* = 0); - - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&) : __f_(0) {} - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&, nullptr_t) : __f_(0) {} - template - function(allocator_arg_t, const _Alloc&, const function&); - template - function(allocator_arg_t, const _Alloc& __a, _Fp __f, - typename enable_if::value>::type* = 0); - - function& operator=(const function&); - function& operator=(nullptr_t); - template - typename enable_if - < - !is_integral<_Fp>::value, - function& - >::type - operator=(_Fp); - - ~function(); - - // 20.7.16.2.2, function modifiers: - void swap(function&); - template - _LIBCPP_INLINE_VISIBILITY - void assign(_Fp __f, const _Alloc& __a) - {function(allocator_arg, __a, __f).swap(*this);} - - // 20.7.16.2.3, function capacity: - _LIBCPP_INLINE_VISIBILITY operator bool() const {return __f_;} - -private: - // deleted overloads close possible hole in the type system - template - bool operator==(const function<_R2(_B0, _B1, _B2)>&) const;// = delete; - template - bool operator!=(const function<_R2(_B0, _B1, _B2)>&) const;// = delete; -public: - // 20.7.16.2.4, function invocation: - _Rp operator()(_A0, _A1, _A2) const; - -#ifndef _LIBCPP_NO_RTTI - // 20.7.16.2.5, function target access: - const std::type_info& target_type() const; - template _Tp* target(); - template const _Tp* target() const; -#endif // _LIBCPP_NO_RTTI -}; - -template -function<_Rp(_A0, _A1, _A2)>::function(const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0, _A1, _A2)>::function(allocator_arg_t, const _Alloc&, - const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_A0, _A1, _A2)>::function(_Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - if (__not_null(__f)) - { - typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_A0, _A1, _A2)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, allocator<_Fp>(__a)); - __f_ = __hold.release(); - } - } -} - -template -template -function<_Rp(_A0, _A1, _A2)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f, - typename enable_if::value>::type*) - : __f_(0) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - if (__not_null(__f)) - { - typedef __function::__func<_Fp, _Alloc, _Rp(_A0, _A1, _A2)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(__f); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(__f, _Alloc(__a)); - __f_ = __hold.release(); - } - } -} - -template -function<_Rp(_A0, _A1, _A2)>& -function<_Rp(_A0, _A1, _A2)>::operator=(const function& __f) -{ - function(__f).swap(*this); - return *this; -} - -template -function<_Rp(_A0, _A1, _A2)>& -function<_Rp(_A0, _A1, _A2)>::operator=(nullptr_t) -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; -} - -template -template -typename enable_if -< - !is_integral<_Fp>::value, - function<_Rp(_A0, _A1, _A2)>& ->::type -function<_Rp(_A0, _A1, _A2)>::operator=(_Fp __f) -{ - function(_VSTD::move(__f)).swap(*this); - return *this; -} - -template -function<_Rp(_A0, _A1, _A2)>::~function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -function<_Rp(_A0, _A1, _A2)>::swap(function& __f) -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__clone(__t); - __f_->destroy(); - __f_ = 0; - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = 0; - __f_ = (__base*)&__buf_; - __t->__clone((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__clone((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -_Rp -function<_Rp(_A0, _A1, _A2)>::operator()(_A0 __a0, _A1 __a1, _A2 __a2) const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__f_ == 0) - throw bad_function_call(); -#endif // _LIBCPP_NO_EXCEPTIONS - return (*__f_)(__a0, __a1, __a2); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const std::type_info& -function<_Rp(_A0, _A1, _A2)>::target_type() const -{ - if (__f_ == 0) - return typeid(void); - return __f_->target_type(); -} - -template -template -_Tp* -function<_Rp(_A0, _A1, _A2)>::target() -{ - if (__f_ == 0) - return (_Tp*)0; - return (_Tp*)__f_->target(typeid(_Tp)); -} - -template -template -const _Tp* -function<_Rp(_A0, _A1, _A2)>::target() const -{ - if (__f_ == 0) - return (const _Tp*)0; - return (const _Tp*)__f_->target(typeid(_Tp)); -} - -#endif // _LIBCPP_NO_RTTI - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const function<_Fp>& __f, nullptr_t) {return !__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(nullptr_t, const function<_Fp>& __f) {return !__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const function<_Fp>& __f, nullptr_t) {return (bool)__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(nullptr_t, const function<_Fp>& __f) {return (bool)__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(function<_Fp>& __x, function<_Fp>& __y) -{return __x.swap(__y);} - -template struct __is_bind_expression : public false_type {}; -template struct _LIBCPP_VISIBLE is_bind_expression - : public __is_bind_expression::type> {}; - -template struct __is_placeholder : public integral_constant {}; -template struct _LIBCPP_VISIBLE is_placeholder - : public __is_placeholder::type> {}; - -namespace placeholders -{ - -template struct __ph {}; - -extern __ph<1> _1; -extern __ph<2> _2; -extern __ph<3> _3; -extern __ph<4> _4; -extern __ph<5> _5; -extern __ph<6> _6; -extern __ph<7> _7; -extern __ph<8> _8; -extern __ph<9> _9; -extern __ph<10> _10; - -} // placeholders - -template -struct __is_placeholder > - : public integral_constant {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp& -__mu(reference_wrapper<_Tp> __t, _Uj&) -{ - return __t.get(); -} -/* -template -struct __mu_return1 {}; - -template -struct __mu_return1 -{ - typedef typename result_of<_Ti(_Uj...)>::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __mu_return1::type -__mu_expand(_Ti& __ti, tuple<_Uj...>&& __uj, __tuple_indices<_Indx...>) -{ - __ti(_VSTD::forward::type>(get<_Indx>(__uj))...); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_bind_expression<_Ti>::value, - typename __mu_return1::value, _Ti, _Uj...>::type ->::type -__mu(_Ti& __ti, tuple<_Uj...>& __uj) -{ - typedef typename __make_tuple_indices::type __indices; - return __mu_expand(__ti, __uj, __indices()); -} - -template -struct __mu_return2 {}; - -template -struct __mu_return2 -{ - typedef typename tuple_element::value - 1, _Uj>::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - 0 < is_placeholder<_Ti>::value, - typename __mu_return2<0 < is_placeholder<_Ti>::value, _Ti, _Uj>::type ->::type -__mu(_Ti&, _Uj& __uj) -{ - const size_t _Indx = is_placeholder<_Ti>::value - 1; - // compiler bug workaround - typename tuple_element<_Indx, _Uj>::type __t = get<_Indx>(__uj); - return __t; -// return _VSTD::forward::type>(get<_Indx>(__uj)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_bind_expression<_Ti>::value && - is_placeholder<_Ti>::value == 0 && - !__is_reference_wrapper<_Ti>::value, - _Ti& ->::type -__mu(_Ti& __ti, _Uj& __uj) -{ - return __ti; -} - -template -struct ____mu_return; - -template -struct ____mu_return<_Ti, true, false, tuple<_Uj...> > -{ - typedef typename result_of<_Ti(_Uj...)>::type type; -}; - -template -struct ____mu_return<_Ti, false, true, _TupleUj> -{ - typedef typename tuple_element::value - 1, - _TupleUj>::type&& type; -}; - -template -struct ____mu_return<_Ti, false, false, _TupleUj> -{ - typedef _Ti& type; -}; - -template -struct __mu_return - : public ____mu_return<_Ti, - is_bind_expression<_Ti>::value, - 0 < is_placeholder<_Ti>::value, - _TupleUj> -{ -}; - -template -struct __mu_return, _TupleUj> -{ - typedef _Ti& type; -}; - -template -struct __bind_return; - -template -struct __bind_return<_Fp, tuple<_BoundArgs...>, _TupleUj> -{ - typedef typename __ref_return - < - _Fp&, - typename __mu_return - < - _BoundArgs, - _TupleUj - >::type... - >::type type; -}; - -template -struct __bind_return<_Fp, const tuple<_BoundArgs...>, _TupleUj> -{ - typedef typename __ref_return - < - _Fp&, - typename __mu_return - < - const _BoundArgs, - _TupleUj - >::type... - >::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __bind_return<_Fp, _BoundArgs, _Args>::type -__apply_functor(_Fp& __f, _BoundArgs& __bound_args, __tuple_indices<_Indx...>, - _Args&& __args) -{ - return __invoke(__f, __mu(get<_Indx>(__bound_args), __args)...); -} - -template -class __bind -{ - _Fp __f_; - tuple<_BoundArgs...> __bound_args_; - - typedef typename __make_tuple_indices::type __indices; -public: - template - explicit __bind(_Gp&& __f, _BA&& ...__bound_args) - : __f_(_VSTD::forward<_Gp>(__f)), - __bound_args_(_VSTD::forward<_BA>(__bound_args)...) {} - - template - typename __bind_return<_Fp, tuple<_BoundArgs...>, tuple<_Args&&...> >::type - operator()(_Args&& ...__args) - { - // compiler bug workaround - return __apply_functor(__f_, __bound_args_, __indices(), - tuple<_Args&&...>(__args...)); - } - - template - typename __bind_return<_Fp, tuple<_BoundArgs...>, tuple<_Args&&...> >::type - operator()(_Args&& ...__args) const - { - return __apply_functor(__f_, __bound_args_, __indices(), - tuple<_Args&&...>(__args...)); - } -}; - -template -struct __is_bind_expression<__bind<_Fp, _BoundArgs...> > : public true_type {}; - -template -class __bind_r - : public __bind<_Fp, _BoundArgs...> -{ - typedef __bind<_Fp, _BoundArgs...> base; -public: - typedef _Rp result_type; - - template - explicit __bind_r(_Gp&& __f, _BA&& ...__bound_args) - : base(_VSTD::forward<_Gp>(__f), - _VSTD::forward<_BA>(__bound_args)...) {} - - template - result_type - operator()(_Args&& ...__args) - { - return base::operator()(_VSTD::forward<_Args>(__args)...); - } - - template - result_type - operator()(_Args&& ...__args) const - { - return base::operator()(_VSTD::forward<_Args>(__args)...); - } -}; - -template -struct __is_bind_expression<__bind_r<_Rp, _Fp, _BoundArgs...> > : public true_type {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__bind::type, typename decay<_BoundArgs>::type...> -bind(_Fp&& __f, _BoundArgs&&... __bound_args) -{ - typedef __bind::type, typename decay<_BoundArgs>::type...> type; - return type(_VSTD::forward<_Fp>(__f), _VSTD::forward<_BoundArgs>(__bound_args)...); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bind_r<_Rp, typename decay<_Fp>::type, typename decay<_BoundArgs>::type...> -bind(_Fp&& __f, _BoundArgs&&... __bound_args) -{ - typedef __bind_r<_Rp, typename decay<_Fp>::type, typename decay<_BoundArgs>::type...> type; - return type(_VSTD::forward<_Fp>(__f), _VSTD::forward<_BoundArgs>(__bound_args)...); -} -*/ - -#endif // _LIBCPP_FUNCTIONAL_03 diff --git a/libcxx/include/__functional_base b/libcxx/include/__functional_base deleted file mode 100644 index 63aa41d52555..000000000000 --- a/libcxx/include/__functional_base +++ /dev/null @@ -1,437 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FUNCTIONAL_BASE -#define _LIBCPP_FUNCTIONAL_BASE - -#include <__config> -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -struct _LIBCPP_VISIBLE unary_function -{ - typedef _Arg argument_type; - typedef _Result result_type; -}; - -template -struct _LIBCPP_VISIBLE binary_function -{ - typedef _Arg1 first_argument_type; - typedef _Arg2 second_argument_type; - typedef _Result result_type; -}; - -template struct _LIBCPP_VISIBLE hash; - -template -struct __has_result_type -{ -private: - struct __two {char _; char __;}; - template static __two __test(...); - template static char __test(typename _Up::result_type* = 0); -public: - static const bool value = sizeof(__test<_Tp>(0)) == 1; -}; - -template -struct _LIBCPP_VISIBLE less : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x < __y;} -}; - -#ifdef _LIBCPP_HAS_NO_VARIADICS - -#include <__functional_base_03> - -#else // _LIBCPP_HAS_NO_VARIADICS - -// __weak_result_type - -template -struct __derives_from_unary_function -{ -private: - struct __two {char _; char __;}; - static __two __test(...); - template - static unary_function<_Ap, _Rp> - __test(const volatile unary_function<_Ap, _Rp>*); -public: - static const bool value = !is_same::value; - typedef decltype(__test((_Tp*)0)) type; -}; - -template -struct __derives_from_binary_function -{ -private: - struct __two {char _; char __;}; - static __two __test(...); - template - static binary_function<_A1, _A2, _Rp> - __test(const volatile binary_function<_A1, _A2, _Rp>*); -public: - static const bool value = !is_same::value; - typedef decltype(__test((_Tp*)0)) type; -}; - -template ::value> -struct __maybe_derive_from_unary_function // bool is true - : public __derives_from_unary_function<_Tp>::type -{ -}; - -template -struct __maybe_derive_from_unary_function<_Tp, false> -{ -}; - -template ::value> -struct __maybe_derive_from_binary_function // bool is true - : public __derives_from_binary_function<_Tp>::type -{ -}; - -template -struct __maybe_derive_from_binary_function<_Tp, false> -{ -}; - -template ::value> -struct __weak_result_type_imp // bool is true - : public __maybe_derive_from_unary_function<_Tp>, - public __maybe_derive_from_binary_function<_Tp> -{ - typedef typename _Tp::result_type result_type; -}; - -template -struct __weak_result_type_imp<_Tp, false> - : public __maybe_derive_from_unary_function<_Tp>, - public __maybe_derive_from_binary_function<_Tp> -{ -}; - -template -struct __weak_result_type - : public __weak_result_type_imp<_Tp> -{ -}; - -// 0 argument case - -template -struct __weak_result_type<_Rp ()> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (&)()> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (*)()> -{ - typedef _Rp result_type; -}; - -// 1 argument case - -template -struct __weak_result_type<_Rp (_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (&)(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (*)(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)()> - : public unary_function<_Cp*, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() const> - : public unary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() volatile> - : public unary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() const volatile> - : public unary_function -{ -}; - -// 2 argument case - -template -struct __weak_result_type<_Rp (_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (*)(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (&)(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1)> - : public binary_function<_Cp*, _A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) const> - : public binary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) volatile> - : public binary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) const volatile> - : public binary_function -{ -}; - -// 3 or more arguments - -template -struct __weak_result_type<_Rp (_A1, _A2, _A3, _A4...)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (&)(_A1, _A2, _A3, _A4...)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (*)(_A1, _A2, _A3, _A4...)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2, _A3...)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2, _A3...) const> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2, _A3...) volatile> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2, _A3...) const volatile> -{ - typedef _Rp result_type; -}; - -// __invoke - -// bullets 1 and 2 - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0, _Args&& ...__args) - -> decltype((_VSTD::forward<_A0>(__a0).*__f)(_VSTD::forward<_Args>(__args)...)) -{ - return (_VSTD::forward<_A0>(__a0).*__f)(_VSTD::forward<_Args>(__args)...); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0, _Args&& ...__args) - -> decltype(((*_VSTD::forward<_A0>(__a0)).*__f)(_VSTD::forward<_Args>(__args)...)) -{ - return ((*_VSTD::forward<_A0>(__a0)).*__f)(_VSTD::forward<_Args>(__args)...); -} - -// bullets 3 and 4 - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0) - -> decltype(_VSTD::forward<_A0>(__a0).*__f) -{ - return _VSTD::forward<_A0>(__a0).*__f; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0) - -> decltype((*_VSTD::forward<_A0>(__a0)).*__f) -{ - return (*_VSTD::forward<_A0>(__a0)).*__f; -} - -// bullet 5 - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _Args&& ...__args) - -> decltype(_VSTD::forward<_Fp>(__f)(_VSTD::forward<_Args>(__args)...)) -{ - return _VSTD::forward<_Fp>(__f)(_VSTD::forward<_Args>(__args)...); -} - -template -struct __invoke_return -{ - typedef decltype(__invoke(_VSTD::declval<_Tp>(), _VSTD::declval<_Args>()...)) type; -}; - -template -class _LIBCPP_VISIBLE reference_wrapper - : public __weak_result_type<_Tp> -{ -public: - // types - typedef _Tp type; -private: - type* __f_; - -public: - // construct/copy/destroy - _LIBCPP_INLINE_VISIBILITY reference_wrapper(type& __f) _NOEXCEPT : __f_(&__f) {} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - private: reference_wrapper(type&&); public: // = delete; // do not bind to temps -#endif - - // access - _LIBCPP_INLINE_VISIBILITY operator type& () const _NOEXCEPT {return *__f_;} - _LIBCPP_INLINE_VISIBILITY type& get() const _NOEXCEPT {return *__f_;} - - // invoke - template - _LIBCPP_INLINE_VISIBILITY - typename __invoke_of::type - operator() (_ArgTypes&&... __args) const - { - return __invoke(get(), _VSTD::forward<_ArgTypes>(__args)...); - } -}; - -template struct ____is_reference_wrapper : public false_type {}; -template struct ____is_reference_wrapper > : public true_type {}; -template struct __is_reference_wrapper - : public ____is_reference_wrapper::type> {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper<_Tp> -ref(_Tp& __t) _NOEXCEPT -{ - return reference_wrapper<_Tp>(__t); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper<_Tp> -ref(reference_wrapper<_Tp> __t) _NOEXCEPT -{ - return ref(__t.get()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper -cref(const _Tp& __t) _NOEXCEPT -{ - return reference_wrapper(__t); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper -cref(reference_wrapper<_Tp> __t) _NOEXCEPT -{ - return cref(__t.get()); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_DELETED_FUNCTIONS - -template void ref(const _Tp&&) = delete; -template void cref(const _Tp&&) = delete; - -#else // _LIBCPP_HAS_NO_DELETED_FUNCTIONS - -template void ref(const _Tp&&);// = delete; -template void cref(const _Tp&&);// = delete; - -#endif // _LIBCPP_HAS_NO_DELETED_FUNCTIONS - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_VARIADICS - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_FUNCTIONAL_BASE diff --git a/libcxx/include/__functional_base_03 b/libcxx/include/__functional_base_03 deleted file mode 100644 index 6c6ce53e6d25..000000000000 --- a/libcxx/include/__functional_base_03 +++ /dev/null @@ -1,1087 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FUNCTIONAL_BASE_03 -#define _LIBCPP_FUNCTIONAL_BASE_03 - -// manual variadic expansion for - -// __weak_result_type - -template -struct __derives_from_unary_function -{ -private: - struct __two {char _; char __;}; - static __two __test(...); - template - static unary_function<_Ap, _Rp> - __test(const volatile unary_function<_Ap, _Rp>*); -public: - static const bool value = !is_same::value; - typedef decltype(__test((_Tp*)0)) type; -}; - -template -struct __derives_from_binary_function -{ -private: - struct __two {char _; char __;}; - static __two __test(...); - template - static binary_function<_A1, _A2, _Rp> - __test(const volatile binary_function<_A1, _A2, _Rp>*); -public: - static const bool value = !is_same::value; - typedef decltype(__test((_Tp*)0)) type; -}; - -template ::value> -struct __maybe_derive_from_unary_function // bool is true - : public __derives_from_unary_function<_Tp>::type -{ -}; - -template -struct __maybe_derive_from_unary_function<_Tp, false> -{ -}; - -template ::value> -struct __maybe_derive_from_binary_function // bool is true - : public __derives_from_binary_function<_Tp>::type -{ -}; - -template -struct __maybe_derive_from_binary_function<_Tp, false> -{ -}; - -template ::value> -struct __weak_result_type_imp // bool is true - : public __maybe_derive_from_unary_function<_Tp>, - public __maybe_derive_from_binary_function<_Tp> -{ - typedef typename _Tp::result_type result_type; -}; - -template -struct __weak_result_type_imp<_Tp, false> - : public __maybe_derive_from_unary_function<_Tp>, - public __maybe_derive_from_binary_function<_Tp> -{ -}; - -template -struct __weak_result_type - : public __weak_result_type_imp::type> -{ -}; - -// 0 argument case - -template -struct __weak_result_type<_Rp ()> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (&)()> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (*)()> -{ - typedef _Rp result_type; -}; - -// 1 argument case - -template -struct __weak_result_type<_Rp (_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (&)(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (*)(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)()> - : public unary_function<_Cp*, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() const> - : public unary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() volatile> - : public unary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)() const volatile> - : public unary_function -{ -}; - -// 2 argument case - -template -struct __weak_result_type<_Rp (_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (*)(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (&)(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1)> - : public binary_function<_Cp*, _A1, _Rp> -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) const> - : public binary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) volatile> - : public binary_function -{ -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1) const volatile> - : public binary_function -{ -}; - -// 3 or more arguments - -template -struct __weak_result_type<_Rp (_A1, _A2, _A3)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (&)(_A1, _A2, _A3)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (*)(_A1, _A2, _A3)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2)> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2) const> -{ - typedef _Rp result_type; -}; - -template -struct __weak_result_type<_Rp (_Cp::*)(_A1, _A2) volatile> -{ - typedef _Rp result_type; -}; - -// __invoke - -// __ref_return0 -// -// template -// struct ________ref_return0 // _HasResultType is true -// { -// typedef typename _Tp::result_type type; -// }; -// -// template -// struct ________ref_return0<_Tp, false> -// { -// typedef void type; -// }; -// -// template -// struct ____ref_return0 // _IsClass is true -// : public ________ref_return0<_Tp, __has_result_type::type>::value> -// { -// }; -// -// template -// struct ______ref_return0 // _HasResultType is true -// { -// typedef typename __callable_type<_Tp>::result_type type; -// }; -// -// template -// struct ______ref_return0<_Tp, false> // pointer to member data -// { -// typedef void type; -// }; -// -// template -// struct ____ref_return0<_Tp, false> -// : public ______ref_return0::type, -// __has_result_type<__callable_type::type> >::value> -// { -// }; -// -// template -// struct __ref_return0 -// : public ____ref_return0::type, -// is_class::type>::value> -// { -// }; -// -// __ref_return1 -// -// template -// struct ____ref_return1 // _IsClass is true -// { -// typedef typename result_of<_Tp(_A0)>::type type; -// }; -// -// template -// struct ______ref_return1 // _HasResultType is true -// { -// typedef typename __callable_type<_Tp>::result_type type; -// }; -// -// template -// struct __ref_return1_member_data1; -// -// template -// struct __ref_return1_member_data1<_Rp _Cp::*, _A0, true> -// { -// typedef typename __apply_cv<_A0, _Rp>::type& type; -// }; -// -// template -// struct __ref_return1_member_data1<_Rp _Cp::*, _A0, false> -// { -// static _A0 __a; -// typedef typename __apply_cv::type& type; -// }; -// -// template -// struct __ref_return1_member_data; -// -// template -// struct __ref_return1_member_data<_Rp _Cp::*, _A0> -// : public __ref_return1_member_data1<_Rp _Cp::*, _A0, -// is_same::type, -// typename remove_cv::type>::type>::value> -// { -// }; -// -// template -// struct ______ref_return1<_Tp, false, _A0> // pointer to member data -// : public __ref_return1_member_data::type, _A0> -// { -// }; -// -// template -// struct ____ref_return1<_Tp, false, _A0> -// : public ______ref_return1::type, -// __has_result_type<__callable_type::type> >::value, _A0> -// { -// }; -// -// template -// struct __ref_return1 -// : public ____ref_return1::type, -// is_class::type>::value, _A0> -// { -// }; -// -// __ref_return2 -// -// template -// struct ____ref_return2 // _IsClass is true -// { -// typedef typename result_of<_Tp(_A0, _A1)>::type type; -// }; -// -// template -// struct ______ref_return2 // _HasResultType is true -// { -// typedef typename __callable_type<_Tp>::result_type type; -// }; -// -// template -// struct ______ref_return2<_Tp, false, class _A0, class _A1> // pointer to member data -// { -// static_assert(sizeof(_Tp) == 0, "An attempt has been made to `call` a pointer" -// " to member data with too many arguments."); -// }; -// -// template -// struct ____ref_return2<_Tp, false, _A0, _A1> -// : public ______ref_return2::type, -// __has_result_type<__callable_type::type> >::value, _A0, _A1> -// { -// }; -// -// template -// struct __ref_return2 -// : public ____ref_return2::type, -// is_class::type>::value, _A0, _A1> -// { -// }; -// -// __ref_return3 -// -// template -// struct ____ref_return3 // _IsClass is true -// { -// typedef typename result_of<_Tp(_A0, _A1, _A2)>::type type; -// }; -// -// template -// struct ______ref_return3 // _HasResultType is true -// { -// typedef typename __callable_type<_Tp>::result_type type; -// }; -// -// template -// struct ______ref_return3<_Tp, false, class _A0, class _A1, class _A2> // pointer to member data -// { -// static_assert(sizeof(_Tp) == 0, "An attempt has been made to `call` a pointer" -// " to member data with too many arguments."); -// }; -// -// template -// struct ____ref_return3<_Tp, false, _A0, _A1, _A2> -// : public ______ref_return3::type, -// __has_result_type<__callable_type::type> >::value, _A0, _A1, _A2> -// { -// }; -// -// template -// struct __ref_return3 -// : public ____ref_return3::type, -// is_class::type>::value, _A0, _A1, _A2> -// { -// }; - -// first bullet - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(), _T1& __t1) -{ - return (__t1.*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0), _T1& __t1, _A0& __a0) -{ - return (__t1.*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1), _T1& __t1, _A0& __a0, _A1& __a1) -{ - return (__t1.*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2), _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return (__t1.*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() const, _T1& __t1) -{ - return (__t1.*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) const, _T1& __t1, _A0& __a0) -{ - return (__t1.*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) const, _T1& __t1, _A0& __a0, _A1& __a1) -{ - return (__t1.*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) const, _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return (__t1.*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() volatile, _T1& __t1) -{ - return (__t1.*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) volatile, _T1& __t1, _A0& __a0) -{ - return (__t1.*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) volatile, _T1& __t1, _A0& __a0, _A1& __a1) -{ - return (__t1.*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) volatile, _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return (__t1.*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() const volatile, _T1& __t1) -{ - return (__t1.*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) const volatile, _T1& __t1, _A0& __a0) -{ - return (__t1.*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) const volatile, _T1& __t1, _A0& __a0, _A1& __a1) -{ - return (__t1.*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) const volatile, _T1& __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return (__t1.*__f)(__a0, __a1, __a2); -} - -// second bullet - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(), _T1 __t1) -{ - return ((*__t1).*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0), _T1 __t1, _A0& __a0) -{ - return ((*__t1).*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1), _T1 __t1, _A0& __a0, _A1& __a1) -{ - return ((*__t1).*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2), _T1 __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return ((*__t1).*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() const, _T1 __t1) -{ - return ((*__t1).*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) const, _T1 __t1, _A0& __a0) -{ - return ((*__t1).*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) const, _T1 __t1, _A0& __a0, _A1& __a1) -{ - return ((*__t1).*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) const, _T1 __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return ((*__t1).*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() volatile, _T1 __t1) -{ - return ((*__t1).*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) volatile, _T1 __t1, _A0& __a0) -{ - return ((*__t1).*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) volatile, _T1 __t1, _A0& __a0, _A1& __a1) -{ - return ((*__t1).*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) volatile, _T1 __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return ((*__t1).*__f)(__a0, __a1, __a2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)() const volatile, _T1 __t1) -{ - return ((*__t1).*__f)(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0) const volatile, _T1 __t1, _A0& __a0) -{ - return ((*__t1).*__f)(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1) const volatile, _T1 __t1, _A0& __a0, _A1& __a1) -{ - return ((*__t1).*__f)(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - _Rp ->::type -__invoke(_Rp (_Tp::*__f)(_A0, _A1, _A2) const volatile, _T1 __t1, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return ((*__t1).*__f)(__a0, __a1, __a2); -} - -// third bullet - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_base_of<_Tp, typename remove_reference<_T1>::type>::value, - typename __apply_cv<_T1, _Rp>::type& ->::type -__invoke(_Rp _Tp::* __f, _T1& __t1) -{ - return __t1.*__f; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__invoke(_Rp _Tp::*) -{ -} - -// template -// inline _LIBCPP_INLINE_VISIBILITY -// typename enable_if -// < -// is_base_of<_Tp, typename remove_reference<_T1>::type>::value, -// typename __ref_return1<_Rp _Tp::*, _T1>::type -// >::type -// __invoke(_Rp _Tp::* __f, _T1& __t1) -// { -// return __t1.*__f; -// } - -// forth bullet - -template -struct __4th_helper -{ -}; - -template -struct __4th_helper<_T1, _Rp, true> -{ - typedef typename __apply_cv()), _Rp>::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __4th_helper<_T1, _Rp, - !is_base_of<_Tp, - typename remove_reference<_T1>::type - >::value - >::type& -__invoke(_Rp _Tp::* __f, _T1& __t1) -{ - return (*__t1).*__f; -} - -// template -// inline _LIBCPP_INLINE_VISIBILITY -// typename enable_if -// < -// !is_base_of<_Tp, typename remove_reference<_T1>::type>::value, -// typename __ref_return1<_Rp _Tp::*, _T1>::type -// >::type -// __invoke(_Rp _Tp::* __f, _T1 __t1) -// { -// return (*__t1).*__f; -// } - -// fifth bullet - -template -inline _LIBCPP_INLINE_VISIBILITY -decltype(declval<_Fp>()()) -__invoke(_Fp __f) -{ - return __f(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -decltype(declval<_Fp>()(declval<_A0&>())) -__invoke(_Fp __f, _A0& __a0) -{ - return __f(__a0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -decltype(declval<_Fp>()(declval<_A0&>(), declval<_A1&>())) -__invoke(_Fp __f, _A0& __a0, _A1& __a1) -{ - return __f(__a0, __a1); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -decltype(declval<_Fp>()(declval<_A0&>(), declval<_A1&>(), declval<_A2&>())) -__invoke(_Fp __f, _A0& __a0, _A1& __a1, _A2& __a2) -{ - return __f(__a0, __a1, __a2); -} - -// template -// inline _LIBCPP_INLINE_VISIBILITY -// _Rp -// __invoke(_Fp& __f) -// { -// return __f(); -// } -// -// template -// inline _LIBCPP_INLINE_VISIBILITY -// typename enable_if -// < -// !is_member_pointer<_Fp>::value, -// _Rp -// >::type -// __invoke(_Fp& __f, _A0& __a0) -// { -// return __f(__a0); -// } -// -// template -// inline _LIBCPP_INLINE_VISIBILITY -// _Rp -// __invoke(_Fp& __f, _A0& __a0, _A1& __a1) -// { -// return __f(__a0, __a1); -// } -// -// template -// inline _LIBCPP_INLINE_VISIBILITY -// _Rp -// __invoke(_Fp& __f, _A0& __a0, _A1& __a1, _A2& __a2) -// { -// return __f(__a0, __a1, __a2); -// } - -template -struct __has_type -{ -private: - struct __two {char _; char __;}; - template static __two __test(...); - template static char __test(typename _Up::type* = 0); -public: - static const bool value = sizeof(__test<_Tp>(0)) == 1; -}; - -template >::value> -struct __invoke_return -{ - typedef typename __weak_result_type<_Fp>::result_type type; -}; - -template -struct __invoke_return<_Fp, false> -{ - typedef decltype(__invoke(_VSTD::declval<_Fp>())) type; -}; - -template -struct __invoke_return0 -{ - typedef decltype(__invoke(_VSTD::declval<_Tp>(), _VSTD::declval<_A0>())) type; -}; - -template -struct __invoke_return0<_Rp _Tp::*, _A0> -{ - typedef typename __apply_cv<_A0, _Rp>::type& type; -}; - -template -struct __invoke_return0<_Rp _Tp::*, _A0*> -{ - typedef typename __apply_cv<_A0, _Rp>::type& type; -}; - -template -struct __invoke_return1 -{ - typedef decltype(__invoke(_VSTD::declval<_Tp>(), _VSTD::declval<_A0>(), - _VSTD::declval<_A1>())) type; -}; - -template -struct __invoke_return2 -{ - typedef decltype(__invoke(_VSTD::declval<_Tp>(), _VSTD::declval<_A0>(), - _VSTD::declval<_A1>(), - _VSTD::declval<_A2>())) type; -}; - -template -class _LIBCPP_VISIBLE reference_wrapper - : public __weak_result_type<_Tp> -{ -public: - // types - typedef _Tp type; -private: - type* __f_; - -public: - // construct/copy/destroy - _LIBCPP_INLINE_VISIBILITY reference_wrapper(type& __f) : __f_(&__f) {} - - // access - _LIBCPP_INLINE_VISIBILITY operator type& () const {return *__f_;} - _LIBCPP_INLINE_VISIBILITY type& get() const {return *__f_;} - - // invoke - - _LIBCPP_INLINE_VISIBILITY - typename __invoke_return::type - operator() () const - { - return __invoke(get()); - } - - template - _LIBCPP_INLINE_VISIBILITY - typename __invoke_return0::type - operator() (_A0& __a0) const - { - return __invoke(get(), __a0); - } - - template - _LIBCPP_INLINE_VISIBILITY - typename __invoke_return1::type - operator() (_A0& __a0, _A1& __a1) const - { - return __invoke(get(), __a0, __a1); - } - - template - _LIBCPP_INLINE_VISIBILITY - typename __invoke_return2::type - operator() (_A0& __a0, _A1& __a1, _A2& __a2) const - { - return __invoke(get(), __a0, __a1, __a2); - } -}; - -template struct ____is_reference_wrapper : public false_type {}; -template struct ____is_reference_wrapper > : public true_type {}; -template struct __is_reference_wrapper - : public ____is_reference_wrapper::type> {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper<_Tp> -ref(_Tp& __t) -{ - return reference_wrapper<_Tp>(__t); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper<_Tp> -ref(reference_wrapper<_Tp> __t) -{ - return ref(__t.get()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper -cref(const _Tp& __t) -{ - return reference_wrapper(__t); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reference_wrapper -cref(reference_wrapper<_Tp> __t) -{ - return cref(__t.get()); -} - -#endif // _LIBCPP_FUNCTIONAL_BASE_03 diff --git a/libcxx/include/__hash_table b/libcxx/include/__hash_table deleted file mode 100644 index fad4e0e6ad4a..000000000000 --- a/libcxx/include/__hash_table +++ /dev/null @@ -1,1920 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP__HASH_TABLE -#define _LIBCPP__HASH_TABLE - -#include <__config> -#include -#include -#include -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -_LIBCPP_VISIBLE -size_t __next_prime(size_t __n); - -template -struct __hash_node_base -{ - typedef __hash_node_base __first_node; - // typedef _NodePtr pointer; - - _NodePtr __next_; - - _LIBCPP_INLINE_VISIBILITY __hash_node_base() _NOEXCEPT : __next_(nullptr) {} -}; - -template -struct __hash_node - : public __hash_node_base - < - typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__hash_node<_Tp, _VoidPtr> > -#else - rebind<__hash_node<_Tp, _VoidPtr> >::other -#endif - > -{ - typedef _Tp value_type; - - size_t __hash_; - value_type __value_; -}; - -template class __hash_table; -template class __hash_const_iterator; -template class __hash_map_iterator; -template class __hash_map_const_iterator; -template - class _LIBCPP_VISIBLE unordered_map; - -template -class _LIBCPP_VISIBLE __hash_iterator -{ - typedef _NodePtr __node_pointer; - - __node_pointer __node_; - -public: - typedef forward_iterator_tag iterator_category; - typedef typename pointer_traits<__node_pointer>::element_type::value_type value_type; - typedef typename pointer_traits<__node_pointer>::difference_type difference_type; - typedef value_type& reference; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __hash_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __node_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return _VSTD::addressof(__node_->__value_);} - - _LIBCPP_INLINE_VISIBILITY - __hash_iterator& operator++() - { - __node_ = __node_->__next_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __hash_iterator operator++(int) - { - __hash_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_iterator& __x, const __hash_iterator& __y) - {return __x.__node_ == __y.__node_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_iterator& __x, const __hash_iterator& __y) - {return __x.__node_ != __y.__node_;} - -private: - _LIBCPP_INLINE_VISIBILITY - __hash_iterator(__node_pointer __node) _NOEXCEPT - : __node_(__node) - {} - - template friend class __hash_table; - template friend class _LIBCPP_VISIBLE __hash_const_iterator; - template friend class _LIBCPP_VISIBLE __hash_map_iterator; - template friend class _LIBCPP_VISIBLE unordered_map; - template friend class _LIBCPP_VISIBLE unordered_multimap; -}; - -template -class _LIBCPP_VISIBLE __hash_const_iterator -{ - typedef _ConstNodePtr __node_pointer; - - __node_pointer __node_; - - typedef typename remove_const< - typename pointer_traits<__node_pointer>::element_type - >::type __node; - -public: - typedef forward_iterator_tag iterator_category; - typedef typename __node::value_type value_type; - typedef typename pointer_traits<__node_pointer>::difference_type difference_type; - typedef const value_type& reference; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__node> -#else - rebind<__node>::other -#endif - __non_const_node_pointer; - typedef __hash_iterator<__non_const_node_pointer> __non_const_iterator; - - _LIBCPP_INLINE_VISIBILITY __hash_const_iterator() _NOEXCEPT {} - _LIBCPP_INLINE_VISIBILITY - __hash_const_iterator(const __non_const_iterator& __x) _NOEXCEPT - : __node_(__x.__node_) - {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __node_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return _VSTD::addressof(__node_->__value_);} - - _LIBCPP_INLINE_VISIBILITY - __hash_const_iterator& operator++() - { - __node_ = __node_->__next_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __hash_const_iterator operator++(int) - { - __hash_const_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_const_iterator& __x, const __hash_const_iterator& __y) - {return __x.__node_ == __y.__node_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_const_iterator& __x, const __hash_const_iterator& __y) - {return __x.__node_ != __y.__node_;} - -private: - _LIBCPP_INLINE_VISIBILITY - __hash_const_iterator(__node_pointer __node) _NOEXCEPT - : __node_(__node) - {} - - template friend class __hash_table; - template friend class _LIBCPP_VISIBLE __hash_map_const_iterator; - template friend class _LIBCPP_VISIBLE unordered_map; - template friend class _LIBCPP_VISIBLE unordered_multimap; -}; - -template class _LIBCPP_VISIBLE __hash_const_local_iterator; - -template -class _LIBCPP_VISIBLE __hash_local_iterator -{ - typedef _NodePtr __node_pointer; - - __node_pointer __node_; - size_t __bucket_; - size_t __bucket_count_; - - typedef pointer_traits<__node_pointer> __pointer_traits; -public: - typedef forward_iterator_tag iterator_category; - typedef typename __pointer_traits::element_type::value_type value_type; - typedef typename __pointer_traits::difference_type difference_type; - typedef value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __hash_local_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __node_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &__node_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __hash_local_iterator& operator++() - { - __node_ = __node_->__next_; - if (__node_ != nullptr && __node_->__hash_ % __bucket_count_ != __bucket_) - __node_ = nullptr; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __hash_local_iterator operator++(int) - { - __hash_local_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_local_iterator& __x, const __hash_local_iterator& __y) - {return __x.__node_ == __y.__node_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_local_iterator& __x, const __hash_local_iterator& __y) - {return __x.__node_ != __y.__node_;} - -private: - _LIBCPP_INLINE_VISIBILITY - __hash_local_iterator(__node_pointer __node, size_t __bucket, - size_t __bucket_count) _NOEXCEPT - : __node_(__node), - __bucket_(__bucket), - __bucket_count_(__bucket_count) - { - if (__node_ != nullptr) - __node_ = __node_->__next_; - } - - template friend class __hash_table; - template friend class _LIBCPP_VISIBLE __hash_const_local_iterator; - template friend class _LIBCPP_VISIBLE __hash_map_iterator; -}; - -template -class _LIBCPP_VISIBLE __hash_const_local_iterator -{ - typedef _ConstNodePtr __node_pointer; - - __node_pointer __node_; - size_t __bucket_; - size_t __bucket_count_; - - typedef pointer_traits<__node_pointer> __pointer_traits; - typedef typename __pointer_traits::element_type __node; - typedef typename remove_const<__node>::type __non_const_node; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__non_const_node> -#else - rebind<__non_const_node>::other -#endif - __non_const_node_pointer; - typedef __hash_local_iterator<__non_const_node_pointer> - __non_const_iterator; -public: - typedef forward_iterator_tag iterator_category; - typedef typename remove_const< - typename __pointer_traits::element_type::value_type - >::type value_type; - typedef typename __pointer_traits::difference_type difference_type; - typedef const value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __hash_const_local_iterator() _NOEXCEPT {} - _LIBCPP_INLINE_VISIBILITY - __hash_const_local_iterator(const __non_const_iterator& __x) _NOEXCEPT - : __node_(__x.__node_), - __bucket_(__x.__bucket_), - __bucket_count_(__x.__bucket_count_) - {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __node_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &__node_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __hash_const_local_iterator& operator++() - { - __node_ = __node_->__next_; - if (__node_ != nullptr && __node_->__hash_ % __bucket_count_ != __bucket_) - __node_ = nullptr; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __hash_const_local_iterator operator++(int) - { - __hash_const_local_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_const_local_iterator& __x, const __hash_const_local_iterator& __y) - {return __x.__node_ == __y.__node_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_const_local_iterator& __x, const __hash_const_local_iterator& __y) - {return __x.__node_ != __y.__node_;} - -private: - _LIBCPP_INLINE_VISIBILITY - __hash_const_local_iterator(__node_pointer __node, size_t __bucket, - size_t __bucket_count) _NOEXCEPT - : __node_(__node), - __bucket_(__bucket), - __bucket_count_(__bucket_count) - { - if (__node_ != nullptr) - __node_ = __node_->__next_; - } - - template friend class __hash_table; - template friend class _LIBCPP_VISIBLE __hash_map_const_iterator; -}; - -template -class __bucket_list_deallocator -{ - typedef _Alloc allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::size_type size_type; - - __compressed_pair __data_; -public: - typedef typename __alloc_traits::pointer pointer; - - _LIBCPP_INLINE_VISIBILITY - __bucket_list_deallocator() - _NOEXCEPT_(is_nothrow_default_constructible::value) - : __data_(0) {} - - _LIBCPP_INLINE_VISIBILITY - __bucket_list_deallocator(const allocator_type& __a, size_type __size) - _NOEXCEPT_(is_nothrow_copy_constructible::value) - : __data_(__size, __a) {} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - __bucket_list_deallocator(__bucket_list_deallocator&& __x) - _NOEXCEPT_(is_nothrow_move_constructible::value) - : __data_(_VSTD::move(__x.__data_)) - { - __x.size() = 0; - } - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - size_type& size() _NOEXCEPT {return __data_.first();} - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return __data_.first();} - - _LIBCPP_INLINE_VISIBILITY - allocator_type& __alloc() _NOEXCEPT {return __data_.second();} - _LIBCPP_INLINE_VISIBILITY - const allocator_type& __alloc() const _NOEXCEPT {return __data_.second();} - - _LIBCPP_INLINE_VISIBILITY - void operator()(pointer __p) _NOEXCEPT - { - __alloc_traits::deallocate(__alloc(), __p, size()); - } -}; - -template class __hash_map_node_destructor; - -template -class __hash_node_destructor -{ - typedef _Alloc allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::value_type::value_type value_type; -public: - typedef typename __alloc_traits::pointer pointer; -private: - - allocator_type& __na_; - - __hash_node_destructor& operator=(const __hash_node_destructor&); - -public: - bool __value_constructed; - - _LIBCPP_INLINE_VISIBILITY - explicit __hash_node_destructor(allocator_type& __na, - bool __constructed = false) _NOEXCEPT - : __na_(__na), - __value_constructed(__constructed) - {} - - _LIBCPP_INLINE_VISIBILITY - void operator()(pointer __p) _NOEXCEPT - { - if (__value_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_)); - if (__p) - __alloc_traits::deallocate(__na_, __p, 1); - } - - template friend class __hash_map_node_destructor; -}; - -template -class __hash_table -{ -public: - typedef _Tp value_type; - typedef _Hash hasher; - typedef _Equal key_equal; - typedef _Alloc allocator_type; - -private: - typedef allocator_traits __alloc_traits; -public: - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; -public: - // Create __node - typedef __hash_node __node; - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__node> -#else - rebind_alloc<__node>::other -#endif - __node_allocator; - typedef allocator_traits<__node_allocator> __node_traits; - typedef typename __node_traits::pointer __node_pointer; - typedef typename __node_traits::const_pointer __node_const_pointer; - typedef __hash_node_base<__node_pointer> __first_node; - -private: - - typedef typename __node_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__node_pointer> -#else - rebind_alloc<__node_pointer>::other -#endif - __pointer_allocator; - typedef __bucket_list_deallocator<__pointer_allocator> __bucket_list_deleter; - typedef unique_ptr<__node_pointer[], __bucket_list_deleter> __bucket_list; - typedef allocator_traits<__pointer_allocator> __pointer_alloc_traits; - typedef typename __bucket_list_deleter::pointer __node_pointer_pointer; - - // --- Member data begin --- - __bucket_list __bucket_list_; - __compressed_pair<__first_node, __node_allocator> __p1_; - __compressed_pair __p2_; - __compressed_pair __p3_; - // --- Member data end --- - - _LIBCPP_INLINE_VISIBILITY - size_type& size() _NOEXCEPT {return __p2_.first();} -public: - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return __p2_.first();} - - _LIBCPP_INLINE_VISIBILITY - hasher& hash_function() _NOEXCEPT {return __p2_.second();} - _LIBCPP_INLINE_VISIBILITY - const hasher& hash_function() const _NOEXCEPT {return __p2_.second();} - - _LIBCPP_INLINE_VISIBILITY - float& max_load_factor() _NOEXCEPT {return __p3_.first();} - _LIBCPP_INLINE_VISIBILITY - float max_load_factor() const _NOEXCEPT {return __p3_.first();} - - _LIBCPP_INLINE_VISIBILITY - key_equal& key_eq() _NOEXCEPT {return __p3_.second();} - _LIBCPP_INLINE_VISIBILITY - const key_equal& key_eq() const _NOEXCEPT {return __p3_.second();} - - _LIBCPP_INLINE_VISIBILITY - __node_allocator& __node_alloc() _NOEXCEPT {return __p1_.second();} - _LIBCPP_INLINE_VISIBILITY - const __node_allocator& __node_alloc() const _NOEXCEPT - {return __p1_.second();} - -public: - typedef __hash_iterator<__node_pointer> iterator; - typedef __hash_const_iterator<__node_const_pointer> const_iterator; - typedef __hash_local_iterator<__node_pointer> local_iterator; - typedef __hash_const_local_iterator<__node_const_pointer> const_local_iterator; - - __hash_table() - _NOEXCEPT_( - is_nothrow_default_constructible<__bucket_list>::value && - is_nothrow_default_constructible<__first_node>::value && - is_nothrow_default_constructible<__node_allocator>::value && - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value); - __hash_table(const hasher& __hf, const key_equal& __eql); - __hash_table(const hasher& __hf, const key_equal& __eql, - const allocator_type& __a); - explicit __hash_table(const allocator_type& __a); - __hash_table(const __hash_table& __u); - __hash_table(const __hash_table& __u, const allocator_type& __a); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __hash_table(__hash_table&& __u) - _NOEXCEPT_( - is_nothrow_move_constructible<__bucket_list>::value && - is_nothrow_move_constructible<__first_node>::value && - is_nothrow_move_constructible<__node_allocator>::value && - is_nothrow_move_constructible::value && - is_nothrow_move_constructible::value); - __hash_table(__hash_table&& __u, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~__hash_table(); - - __hash_table& operator=(const __hash_table& __u); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __hash_table& operator=(__hash_table&& __u) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable<__node_allocator>::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value); -#endif - template - void __assign_unique(_InputIterator __first, _InputIterator __last); - template - void __assign_multi(_InputIterator __first, _InputIterator __last); - - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT - { - return allocator_traits<__pointer_allocator>::max_size( - __bucket_list_.get_deleter().__alloc()); - } - - pair __node_insert_unique(__node_pointer __nd); - iterator __node_insert_multi(__node_pointer __nd); - iterator __node_insert_multi(const_iterator __p, - __node_pointer __nd); - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - template - pair __emplace_unique(_Args&&... __args); - template - iterator __emplace_multi(_Args&&... __args); - template - iterator __emplace_hint_multi(const_iterator __p, _Args&&... __args); -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - - pair __insert_unique(const value_type& __x); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - pair __insert_unique(_Pp&& __x); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - iterator __insert_multi(_Pp&& __x); - template - iterator __insert_multi(const_iterator __p, _Pp&& __x); -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - iterator __insert_multi(const value_type& __x); - iterator __insert_multi(const_iterator __p, const value_type& __x); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - void clear() _NOEXCEPT; - void rehash(size_type __n); - _LIBCPP_INLINE_VISIBILITY void reserve(size_type __n) - {rehash(static_cast(ceil(__n / max_load_factor())));} - - _LIBCPP_INLINE_VISIBILITY - size_type bucket_count() const _NOEXCEPT - { - return __bucket_list_.get_deleter().size(); - } - - iterator begin() _NOEXCEPT; - iterator end() _NOEXCEPT; - const_iterator begin() const _NOEXCEPT; - const_iterator end() const _NOEXCEPT; - - template - _LIBCPP_INLINE_VISIBILITY - size_type bucket(const _Key& __k) const - {return hash_function()(__k) % bucket_count();} - - template - iterator find(const _Key& __x); - template - const_iterator find(const _Key& __x) const; - - typedef __hash_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - - iterator erase(const_iterator __p); - iterator erase(const_iterator __first, const_iterator __last); - template - size_type __erase_unique(const _Key& __k); - template - size_type __erase_multi(const _Key& __k); - __node_holder remove(const_iterator __p) _NOEXCEPT; - - template - size_type __count_unique(const _Key& __k) const; - template - size_type __count_multi(const _Key& __k) const; - - template - pair - __equal_range_unique(const _Key& __k); - template - pair - __equal_range_unique(const _Key& __k) const; - - template - pair - __equal_range_multi(const _Key& __k); - template - pair - __equal_range_multi(const _Key& __k) const; - - void swap(__hash_table& __u) - _NOEXCEPT_( - (!allocator_traits<__pointer_allocator>::propagate_on_container_swap::value || - __is_nothrow_swappable<__pointer_allocator>::value) && - (!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) && - __is_nothrow_swappable::value && - __is_nothrow_swappable::value); - - _LIBCPP_INLINE_VISIBILITY - size_type max_bucket_count() const _NOEXCEPT - {return __bucket_list_.get_deleter().__alloc().max_size();} - size_type bucket_size(size_type __n) const; - _LIBCPP_INLINE_VISIBILITY float load_factor() const _NOEXCEPT - { - size_type __bc = bucket_count(); - return __bc != 0 ? (float)size() / __bc : 0.f; - } - _LIBCPP_INLINE_VISIBILITY void max_load_factor(float __mlf) _NOEXCEPT - {max_load_factor() = _VSTD::max(__mlf, load_factor());} - - _LIBCPP_INLINE_VISIBILITY local_iterator begin(size_type __n) - {return local_iterator(__bucket_list_[__n], __n, bucket_count());} - _LIBCPP_INLINE_VISIBILITY local_iterator end(size_type __n) - {return local_iterator(nullptr, __n, bucket_count());} - _LIBCPP_INLINE_VISIBILITY const_local_iterator cbegin(size_type __n) const - {return const_local_iterator(__bucket_list_[__n], __n, bucket_count());} - _LIBCPP_INLINE_VISIBILITY const_local_iterator cend(size_type __n) const - {return const_local_iterator(nullptr, __n, bucket_count());} -private: - void __rehash(size_type __n); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - template - __node_holder __construct_node(_Args&& ...__args); -#endif // _LIBCPP_HAS_NO_VARIADICS - __node_holder __construct_node(value_type&& __v, size_t __hash); -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - __node_holder __construct_node(const value_type& __v); -#endif - __node_holder __construct_node(const value_type& __v, size_t __hash); - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __hash_table& __u) - {__copy_assign_alloc(__u, integral_constant());} - void __copy_assign_alloc(const __hash_table& __u, true_type); - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __hash_table&, false_type) {} - - void __move_assign(__hash_table& __u, false_type); - void __move_assign(__hash_table& __u, true_type) - _NOEXCEPT_( - is_nothrow_move_assignable<__node_allocator>::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value); - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__hash_table& __u) - _NOEXCEPT_( - !__node_traits::propagate_on_container_move_assignment::value || - (is_nothrow_move_assignable<__pointer_allocator>::value && - is_nothrow_move_assignable<__node_allocator>::value)) - {__move_assign_alloc(__u, integral_constant());} - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__hash_table& __u, true_type) - _NOEXCEPT_( - is_nothrow_move_assignable<__pointer_allocator>::value && - is_nothrow_move_assignable<__node_allocator>::value) - { - __bucket_list_.get_deleter().__alloc() = - _VSTD::move(__u.__bucket_list_.get_deleter().__alloc()); - __node_alloc() = _VSTD::move(__u.__node_alloc()); - } - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__hash_table&, false_type) _NOEXCEPT {} - - template - _LIBCPP_INLINE_VISIBILITY - static - void - __swap_alloc(_Ap& __x, _Ap& __y) - _NOEXCEPT_( - !allocator_traits<_Ap>::propagate_on_container_swap::value || - __is_nothrow_swappable<_Ap>::value) - { - __swap_alloc(__x, __y, - integral_constant::propagate_on_container_swap::value - >()); - } - - template - _LIBCPP_INLINE_VISIBILITY - static - void - __swap_alloc(_Ap& __x, _Ap& __y, true_type) - _NOEXCEPT_(__is_nothrow_swappable<_Ap>::value) - { - using _VSTD::swap; - swap(__x, __y); - } - - template - _LIBCPP_INLINE_VISIBILITY - static - void - __swap_alloc(_Ap&, _Ap&, false_type) _NOEXCEPT {} - - void __deallocate(__node_pointer __np) _NOEXCEPT; - __node_pointer __detach() _NOEXCEPT; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table() - _NOEXCEPT_( - is_nothrow_default_constructible<__bucket_list>::value && - is_nothrow_default_constructible<__first_node>::value && - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value) - : __p2_(0), - __p3_(1.0f) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(const hasher& __hf, - const key_equal& __eql) - : __bucket_list_(nullptr, __bucket_list_deleter()), - __p1_(), - __p2_(0, __hf), - __p3_(1.0f, __eql) -{ -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(const hasher& __hf, - const key_equal& __eql, - const allocator_type& __a) - : __bucket_list_(nullptr, __bucket_list_deleter(__pointer_allocator(__a), 0)), - __p1_(__node_allocator(__a)), - __p2_(0, __hf), - __p3_(1.0f, __eql) -{ -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(const allocator_type& __a) - : __bucket_list_(nullptr, __bucket_list_deleter(__pointer_allocator(__a), 0)), - __p1_(__node_allocator(__a)), - __p2_(0), - __p3_(1.0f) -{ -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(const __hash_table& __u) - : __bucket_list_(nullptr, - __bucket_list_deleter(allocator_traits<__pointer_allocator>:: - select_on_container_copy_construction( - __u.__bucket_list_.get_deleter().__alloc()), 0)), - __p1_(allocator_traits<__node_allocator>:: - select_on_container_copy_construction(__u.__node_alloc())), - __p2_(0, __u.hash_function()), - __p3_(__u.__p3_) -{ -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(const __hash_table& __u, - const allocator_type& __a) - : __bucket_list_(nullptr, __bucket_list_deleter(__pointer_allocator(__a), 0)), - __p1_(__node_allocator(__a)), - __p2_(0, __u.hash_function()), - __p3_(__u.__p3_) -{ -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(__hash_table&& __u) - _NOEXCEPT_( - is_nothrow_move_constructible<__bucket_list>::value && - is_nothrow_move_constructible<__first_node>::value && - is_nothrow_move_constructible::value && - is_nothrow_move_constructible::value) - : __bucket_list_(_VSTD::move(__u.__bucket_list_)), - __p1_(_VSTD::move(__u.__p1_)), - __p2_(_VSTD::move(__u.__p2_)), - __p3_(_VSTD::move(__u.__p3_)) -{ - if (size() > 0) - { - __bucket_list_[__p1_.first().__next_->__hash_ % bucket_count()] = - static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - __u.__p1_.first().__next_ = nullptr; - __u.size() = 0; - } -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(__hash_table&& __u, - const allocator_type& __a) - : __bucket_list_(nullptr, __bucket_list_deleter(__pointer_allocator(__a), 0)), - __p1_(__node_allocator(__a)), - __p2_(0, _VSTD::move(__u.hash_function())), - __p3_(_VSTD::move(__u.__p3_)) -{ - if (__a == allocator_type(__u.__node_alloc())) - { - __bucket_list_.reset(__u.__bucket_list_.release()); - __bucket_list_.get_deleter().size() = __u.__bucket_list_.get_deleter().size(); - __u.__bucket_list_.get_deleter().size() = 0; - if (__u.size() > 0) - { - __p1_.first().__next_ = __u.__p1_.first().__next_; - __u.__p1_.first().__next_ = nullptr; - __bucket_list_[__p1_.first().__next_->__hash_ % bucket_count()] = - static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - size() = __u.size(); - __u.size() = 0; - } - } -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>::~__hash_table() -{ - __deallocate(__p1_.first().__next_); -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__copy_assign_alloc( - const __hash_table& __u, true_type) -{ - if (__node_alloc() != __u.__node_alloc()) - { - clear(); - __bucket_list_.reset(); - __bucket_list_.get_deleter().size() = 0; - } - __bucket_list_.get_deleter().__alloc() = __u.__bucket_list_.get_deleter().__alloc(); - __node_alloc() = __u.__node_alloc(); -} - -template -__hash_table<_Tp, _Hash, _Equal, _Alloc>& -__hash_table<_Tp, _Hash, _Equal, _Alloc>::operator=(const __hash_table& __u) -{ - if (this != &__u) - { - __copy_assign_alloc(__u); - hash_function() = __u.hash_function(); - key_eq() = __u.key_eq(); - max_load_factor() = __u.max_load_factor(); - __assign_multi(__u.begin(), __u.end()); - } - return *this; -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__deallocate(__node_pointer __np) - _NOEXCEPT -{ - __node_allocator& __na = __node_alloc(); - while (__np != nullptr) - { - __node_pointer __next = __np->__next_; - __node_traits::destroy(__na, _VSTD::addressof(__np->__value_)); - __node_traits::deallocate(__na, __np, 1); - __np = __next; - } -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_pointer -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__detach() _NOEXCEPT -{ - size_type __bc = bucket_count(); - for (size_type __i = 0; __i < __bc; ++__i) - __bucket_list_[__i] = nullptr; - size() = 0; - __node_pointer __cache = __p1_.first().__next_; - __p1_.first().__next_ = nullptr; - return __cache; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__move_assign( - __hash_table& __u, true_type) - _NOEXCEPT_( - is_nothrow_move_assignable<__node_allocator>::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value) -{ - clear(); - __bucket_list_.reset(__u.__bucket_list_.release()); - __bucket_list_.get_deleter().size() = __u.__bucket_list_.get_deleter().size(); - __u.__bucket_list_.get_deleter().size() = 0; - __move_assign_alloc(__u); - size() = __u.size(); - hash_function() = _VSTD::move(__u.hash_function()); - max_load_factor() = __u.max_load_factor(); - key_eq() = _VSTD::move(__u.key_eq()); - __p1_.first().__next_ = __u.__p1_.first().__next_; - if (size() > 0) - { - __bucket_list_[__p1_.first().__next_->__hash_ % bucket_count()] = - static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - __u.__p1_.first().__next_ = nullptr; - __u.size() = 0; - } -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__move_assign( - __hash_table& __u, false_type) -{ - if (__node_alloc() == __u.__node_alloc()) - __move_assign(__u, true_type()); - else - { - hash_function() = _VSTD::move(__u.hash_function()); - key_eq() = _VSTD::move(__u.key_eq()); - max_load_factor() = __u.max_load_factor(); - if (bucket_count() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - const_iterator __i = __u.begin(); - while (__cache != nullptr && __u.size() != 0) - { - __cache->__value_ = _VSTD::move(__u.remove(__i++)->__value_); - __node_pointer __next = __cache->__next_; - __node_insert_multi(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __deallocate(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __deallocate(__cache); - } - const_iterator __i = __u.begin(); - while (__u.size() != 0) - { - __node_holder __h = - __construct_node(_VSTD::move(__u.remove(__i++)->__value_)); - __node_insert_multi(__h.get()); - __h.release(); - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__hash_table<_Tp, _Hash, _Equal, _Alloc>& -__hash_table<_Tp, _Hash, _Equal, _Alloc>::operator=(__hash_table&& __u) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable<__node_allocator>::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value) -{ - __move_assign(__u, integral_constant()); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__assign_unique(_InputIterator __first, - _InputIterator __last) -{ - if (bucket_count() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __cache != nullptr && __first != __last; ++__first) - { - __cache->__value_ = *__first; - __node_pointer __next = __cache->__next_; - __node_insert_unique(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __deallocate(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __deallocate(__cache); - } - for (; __first != __last; ++__first) - __insert_unique(*__first); -} - -template -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__assign_multi(_InputIterator __first, - _InputIterator __last) -{ - if (bucket_count() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __cache != nullptr && __first != __last; ++__first) - { - __cache->__value_ = *__first; - __node_pointer __next = __cache->__next_; - __node_insert_multi(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __deallocate(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __deallocate(__cache); - } - for (; __first != __last; ++__first) - __insert_multi(*__first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::begin() _NOEXCEPT -{ - return iterator(__p1_.first().__next_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::end() _NOEXCEPT -{ - return iterator(nullptr); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::const_iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::begin() const _NOEXCEPT -{ - return const_iterator(__p1_.first().__next_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::const_iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::end() const _NOEXCEPT -{ - return const_iterator(nullptr); -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::clear() _NOEXCEPT -{ - if (size() > 0) - { - __deallocate(__p1_.first().__next_); - __p1_.first().__next_ = nullptr; - size_type __bc = bucket_count(); - for (size_type __i = 0; __i < __bc; ++__i) - __bucket_list_[__i] = nullptr; - size() = 0; - } -} - -template -pair::iterator, bool> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_insert_unique(__node_pointer __nd) -{ - __nd->__hash_ = hash_function()(__nd->__value_); - size_type __bc = bucket_count(); - bool __inserted = false; - __node_pointer __ndptr; - size_t __chash; - if (__bc != 0) - { - __chash = __nd->__hash_ % __bc; - __ndptr = __bucket_list_[__chash]; - if (__ndptr != nullptr) - { - for (__ndptr = __ndptr->__next_; __ndptr != nullptr && - __ndptr->__hash_ % __bc == __chash; - __ndptr = __ndptr->__next_) - { - if (key_eq()(__ndptr->__value_, __nd->__value_)) - goto __done; - } - } - } - { - if (size()+1 > __bc * max_load_factor() || __bc == 0) - { - rehash(_VSTD::max(2 * __bc + 1, - size_type(ceil(float(size() + 1) / max_load_factor())))); - __bc = bucket_count(); - __chash = __nd->__hash_ % __bc; - } - // insert_after __bucket_list_[__chash], or __first_node if bucket is null - __node_pointer __pn = __bucket_list_[__chash]; - if (__pn == nullptr) - { - __pn = static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - __nd->__next_ = __pn->__next_; - __pn->__next_ = __nd; - // fix up __bucket_list_ - __bucket_list_[__chash] = __pn; - if (__nd->__next_ != nullptr) - __bucket_list_[__nd->__next_->__hash_ % __bc] = __nd; - } - else - { - __nd->__next_ = __pn->__next_; - __pn->__next_ = __nd; - } - __ndptr = __nd; - // increment size - ++size(); - __inserted = true; - } -__done: - return pair(iterator(__ndptr), __inserted); -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_insert_multi(__node_pointer __cp) -{ - __cp->__hash_ = hash_function()(__cp->__value_); - size_type __bc = bucket_count(); - if (size()+1 > __bc * max_load_factor() || __bc == 0) - { - rehash(_VSTD::max(2 * __bc + 1, - size_type(ceil(float(size() + 1) / max_load_factor())))); - __bc = bucket_count(); - } - size_t __chash = __cp->__hash_ % __bc; - __node_pointer __pn = __bucket_list_[__chash]; - if (__pn == nullptr) - { - __pn = static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - __cp->__next_ = __pn->__next_; - __pn->__next_ = __cp; - // fix up __bucket_list_ - __bucket_list_[__chash] = __pn; - if (__cp->__next_ != nullptr) - __bucket_list_[__cp->__next_->__hash_ % __bc] = __cp; - } - else - { - for (bool __found = false; __pn->__next_ != nullptr && - __pn->__next_->__hash_ % __bc == __chash; - __pn = __pn->__next_) - { - // __found key_eq() action - // false false loop - // true true loop - // false true set __found to true - // true false break - if (__found != (__pn->__next_->__hash_ == __cp->__hash_ && - key_eq()(__pn->__next_->__value_, __cp->__value_))) - { - if (!__found) - __found = true; - else - break; - } - } - __cp->__next_ = __pn->__next_; - __pn->__next_ = __cp; - if (__cp->__next_ != nullptr) - { - size_t __nhash = __cp->__next_->__hash_ % __bc; - if (__nhash != __chash) - __bucket_list_[__nhash] = __cp; - } - } - ++size(); - return iterator(__cp); -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_insert_multi( - const_iterator __p, __node_pointer __cp) -{ - if (__p != end() && key_eq()(*__p, __cp->__value_)) - { - __node_pointer __np = const_cast<__node_pointer>(__p.__node_); - __cp->__hash_ = __np->__hash_; - size_type __bc = bucket_count(); - if (size()+1 > __bc * max_load_factor() || __bc == 0) - { - rehash(_VSTD::max(2 * __bc + 1, - size_type(ceil(float(size() + 1) / max_load_factor())))); - __bc = bucket_count(); - } - size_t __chash = __cp->__hash_ % __bc; - __node_pointer __pp = __bucket_list_[__chash]; - while (__pp->__next_ != __np) - __pp = __pp->__next_; - __cp->__next_ = __np; - __pp->__next_ = __cp; - ++size(); - return iterator(__cp); - } - return __node_insert_multi(__cp); -} - -template -pair::iterator, bool> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_unique(const value_type& __x) -{ - size_t __hash = hash_function()(__x); - size_type __bc = bucket_count(); - bool __inserted = false; - __node_pointer __nd; - size_t __chash; - if (__bc != 0) - { - __chash = __hash % __bc; - __nd = __bucket_list_[__chash]; - if (__nd != nullptr) - { - for (__nd = __nd->__next_; __nd != nullptr && - __nd->__hash_ % __bc == __chash; - __nd = __nd->__next_) - { - if (key_eq()(__nd->__value_, __x)) - goto __done; - } - } - } - { - __node_holder __h = __construct_node(__x, __hash); - if (size()+1 > __bc * max_load_factor() || __bc == 0) - { - rehash(_VSTD::max(2 * __bc + 1, - size_type(ceil(float(size() + 1) / max_load_factor())))); - __bc = bucket_count(); - __chash = __hash % __bc; - } - // insert_after __bucket_list_[__chash], or __first_node if bucket is null - __node_pointer __pn = __bucket_list_[__chash]; - if (__pn == nullptr) - { - __pn = static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - __h->__next_ = __pn->__next_; - __pn->__next_ = __h.get(); - // fix up __bucket_list_ - __bucket_list_[__chash] = __pn; - if (__h->__next_ != nullptr) - __bucket_list_[__h->__next_->__hash_ % __bc] = __h.get(); - } - else - { - __h->__next_ = __pn->__next_; - __pn->__next_ = __h.get(); - } - __nd = __h.release(); - // increment size - ++size(); - __inserted = true; - } -__done: - return pair(iterator(__nd), __inserted); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -pair::iterator, bool> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__emplace_unique(_Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - pair __r = __node_insert_unique(__h.get()); - if (__r.second) - __h.release(); - return __r; -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__emplace_multi(_Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - iterator __r = __node_insert_multi(__h.get()); - __h.release(); - return __r; -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__emplace_hint_multi( - const_iterator __p, _Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - iterator __r = __node_insert_multi(__p, __h.get()); - __h.release(); - return __r; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -template -pair::iterator, bool> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_unique(_Pp&& __x) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Pp>(__x)); - pair __r = __node_insert_unique(__h.get()); - if (__r.second) - __h.release(); - return __r; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_multi(_Pp&& __x) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Pp>(__x)); - iterator __r = __node_insert_multi(__h.get()); - __h.release(); - return __r; -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_multi(const_iterator __p, - _Pp&& __x) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Pp>(__x)); - iterator __r = __node_insert_multi(__p, __h.get()); - __h.release(); - return __r; -} - -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_multi(const value_type& __x) -{ - __node_holder __h = __construct_node(__x); - iterator __r = __node_insert_multi(__h.get()); - __h.release(); - return __r; -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__insert_multi(const_iterator __p, - const value_type& __x) -{ - __node_holder __h = __construct_node(__x); - iterator __r = __node_insert_multi(__p, __h.get()); - __h.release(); - return __r; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::rehash(size_type __n) -{ - __n = __next_prime(_VSTD::max(__n, size() > 0)); - size_type __bc = bucket_count(); - if (__n > __bc) - __rehash(__n); - else - { - __n = _VSTD::max - ( - __n, - __next_prime(size_t(ceil(float(size()) / max_load_factor()))) - ); - if (__n < __bc) - __rehash(__n); - } -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__rehash(size_type __nbc) -{ - __pointer_allocator& __npa = __bucket_list_.get_deleter().__alloc(); - __bucket_list_.reset(__nbc > 0 ? - __pointer_alloc_traits::allocate(__npa, __nbc) : nullptr); - __bucket_list_.get_deleter().size() = __nbc; - if (__nbc > 0) - { - for (size_type __i = 0; __i < __nbc; ++__i) - __bucket_list_[__i] = nullptr; - __node_pointer __pp(static_cast<__node_pointer>(_VSTD::addressof(__p1_.first()))); - __node_pointer __cp = __pp->__next_; - if (__cp != nullptr) - { - size_type __chash = __cp->__hash_ % __nbc; - __bucket_list_[__chash] = __pp; - size_type __phash = __chash; - for (__pp = __cp, __cp = __cp->__next_; __cp != nullptr; - __cp = __pp->__next_) - { - __chash = __cp->__hash_ % __nbc; - if (__chash == __phash) - __pp = __cp; - else - { - if (__bucket_list_[__chash] == nullptr) - { - __bucket_list_[__chash] = __pp; - __pp = __cp; - __phash = __chash; - } - else - { - __node_pointer __np = __cp; - for (; __np->__next_ != nullptr && - key_eq()(__cp->__value_, __np->__next_->__value_); - __np = __np->__next_) - ; - __pp->__next_ = __np->__next_; - __np->__next_ = __bucket_list_[__chash]->__next_; - __bucket_list_[__chash]->__next_ = __cp; - - } - } - } - } - } -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::find(const _Key& __k) -{ - size_t __hash = hash_function()(__k); - size_type __bc = bucket_count(); - if (__bc != 0) - { - size_t __chash = __hash % __bc; - __node_pointer __nd = __bucket_list_[__chash]; - if (__nd != nullptr) - { - for (__nd = __nd->__next_; __nd != nullptr && - __nd->__hash_ % __bc == __chash; - __nd = __nd->__next_) - { - if (key_eq()(__nd->__value_, __k)) - return iterator(__nd); - } - } - } - return end(); -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::const_iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::find(const _Key& __k) const -{ - size_t __hash = hash_function()(__k); - size_type __bc = bucket_count(); - if (__bc != 0) - { - size_t __chash = __hash % __bc; - __node_const_pointer __nd = __bucket_list_[__chash]; - if (__nd != nullptr) - { - for (__nd = __nd->__next_; __nd != nullptr && - __nd->__hash_ % __bc == __chash; - __nd = __nd->__next_) - { - if (key_eq()(__nd->__value_, __k)) - return const_iterator(__nd); - } - } - - } - return end(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_holder -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__construct_node(_Args&& ...__args) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), _VSTD::forward<_Args>(__args)...); - __h.get_deleter().__value_constructed = true; - __h->__hash_ = hash_function()(__h->__value_); - __h->__next_ = nullptr; - return __h; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_holder -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__construct_node(value_type&& __v, - size_t __hash) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), _VSTD::move(__v)); - __h.get_deleter().__value_constructed = true; - __h->__hash_ = __hash; - __h->__next_ = nullptr; - return _VSTD::move(__h); -} - -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_holder -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__construct_node(const value_type& __v) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), __v); - __h.get_deleter().__value_constructed = true; - __h->__hash_ = hash_function()(__h->__value_); - __h->__next_ = nullptr; - return _VSTD::move(__h); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_holder -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__construct_node(const value_type& __v, - size_t __hash) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), __v); - __h.get_deleter().__value_constructed = true; - __h->__hash_ = __hash; - __h->__next_ = nullptr; - return _VSTD::move(__h); -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::erase(const_iterator __p) -{ - __node_pointer __np = const_cast<__node_pointer>(__p.__node_); - iterator __r(__np); - ++__r; - remove(__p); - return __r; -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator -__hash_table<_Tp, _Hash, _Equal, _Alloc>::erase(const_iterator __first, - const_iterator __last) -{ - for (const_iterator __p = __first; __first != __last; __p = __first) - { - ++__first; - erase(__p); - } - __node_pointer __np = const_cast<__node_pointer>(__last.__node_); - return iterator (__np); -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::size_type -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__erase_unique(const _Key& __k) -{ - iterator __i = find(__k); - if (__i == end()) - return 0; - erase(__i); - return 1; -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::size_type -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__erase_multi(const _Key& __k) -{ - size_type __r = 0; - iterator __i = find(__k); - if (__i != end()) - { - iterator __e = end(); - do - { - erase(__i++); - ++__r; - } while (__i != __e && key_eq()(*__i, __k)); - } - return __r; -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::__node_holder -__hash_table<_Tp, _Hash, _Equal, _Alloc>::remove(const_iterator __p) _NOEXCEPT -{ - // current node - __node_pointer __cn = const_cast<__node_pointer>(__p.__node_); - size_type __bc = bucket_count(); - size_t __chash = __cn->__hash_ % __bc; - // find previous node - __node_pointer __pn = __bucket_list_[__chash]; - for (; __pn->__next_ != __cn; __pn = __pn->__next_) - ; - // Fix up __bucket_list_ - // if __pn is not in same bucket (before begin is not in same bucket) && - // if __cn->__next_ is not in same bucket (nullptr is not in same bucket) - if (__pn == _VSTD::addressof(__p1_.first()) || __pn->__hash_ % __bc != __chash) - { - if (__cn->__next_ == nullptr || __cn->__next_->__hash_ % __bc != __chash) - __bucket_list_[__chash] = nullptr; - } - // if __cn->__next_ is not in same bucket (nullptr is in same bucket) - if (__cn->__next_ != nullptr) - { - size_t __nhash = __cn->__next_->__hash_ % __bc; - if (__nhash != __chash) - __bucket_list_[__nhash] = __pn; - } - // remove __cn - __pn->__next_ = __cn->__next_; - __cn->__next_ = nullptr; - --size(); - return __node_holder(__cn, _Dp(__node_alloc(), true)); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::size_type -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__count_unique(const _Key& __k) const -{ - return static_cast(find(__k) != end()); -} - -template -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::size_type -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__count_multi(const _Key& __k) const -{ - size_type __r = 0; - const_iterator __i = find(__k); - if (__i != end()) - { - const_iterator __e = end(); - do - { - ++__i; - ++__r; - } while (__i != __e && key_eq()(*__i, __k)); - } - return __r; -} - -template -template -pair::iterator, - typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__equal_range_unique( - const _Key& __k) -{ - iterator __i = find(__k); - iterator __j = __i; - if (__i != end()) - ++__j; - return pair(__i, __j); -} - -template -template -pair::const_iterator, - typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::const_iterator> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__equal_range_unique( - const _Key& __k) const -{ - const_iterator __i = find(__k); - const_iterator __j = __i; - if (__i != end()) - ++__j; - return pair(__i, __j); -} - -template -template -pair::iterator, - typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::iterator> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__equal_range_multi( - const _Key& __k) -{ - iterator __i = find(__k); - iterator __j = __i; - if (__i != end()) - { - iterator __e = end(); - do - { - ++__j; - } while (__j != __e && key_eq()(*__j, __k)); - } - return pair(__i, __j); -} - -template -template -pair::const_iterator, - typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::const_iterator> -__hash_table<_Tp, _Hash, _Equal, _Alloc>::__equal_range_multi( - const _Key& __k) const -{ - const_iterator __i = find(__k); - const_iterator __j = __i; - if (__i != end()) - { - const_iterator __e = end(); - do - { - ++__j; - } while (__j != __e && key_eq()(*__j, __k)); - } - return pair(__i, __j); -} - -template -void -__hash_table<_Tp, _Hash, _Equal, _Alloc>::swap(__hash_table& __u) - _NOEXCEPT_( - (!allocator_traits<__pointer_allocator>::propagate_on_container_swap::value || - __is_nothrow_swappable<__pointer_allocator>::value) && - (!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) && - __is_nothrow_swappable::value && - __is_nothrow_swappable::value) -{ - { - __node_pointer_pointer __npp = __bucket_list_.release(); - __bucket_list_.reset(__u.__bucket_list_.release()); - __u.__bucket_list_.reset(__npp); - } - _VSTD::swap(__bucket_list_.get_deleter().size(), __u.__bucket_list_.get_deleter().size()); - __swap_alloc(__bucket_list_.get_deleter().__alloc(), - __u.__bucket_list_.get_deleter().__alloc()); - __swap_alloc(__node_alloc(), __u.__node_alloc()); - _VSTD::swap(__p1_.first().__next_, __u.__p1_.first().__next_); - __p2_.swap(__u.__p2_); - __p3_.swap(__u.__p3_); - if (size() > 0) - __bucket_list_[__p1_.first().__next_->__hash_ % bucket_count()] = - static_cast<__node_pointer>(_VSTD::addressof(__p1_.first())); - if (__u.size() > 0) - __u.__bucket_list_[__u.__p1_.first().__next_->__hash_ % __u.bucket_count()] = - static_cast<__node_pointer>(_VSTD::addressof(__u.__p1_.first())); -} - -template -typename __hash_table<_Tp, _Hash, _Equal, _Alloc>::size_type -__hash_table<_Tp, _Hash, _Equal, _Alloc>::bucket_size(size_type __n) const -{ - __node_const_pointer __np = __bucket_list_[__n]; - size_type __bc = bucket_count(); - size_type __r = 0; - if (__np != nullptr) - { - for (__np = __np->__next_; __np != nullptr && - __np->__hash_ % __bc == __n; - __np = __np->__next_, ++__r) - ; - } - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(__hash_table<_Tp, _Hash, _Equal, _Alloc>& __x, - __hash_table<_Tp, _Hash, _Equal, _Alloc>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP__HASH_TABLE diff --git a/libcxx/include/__locale b/libcxx/include/__locale deleted file mode 100644 index b1e07113e7d4..000000000000 --- a/libcxx/include/__locale +++ /dev/null @@ -1,1426 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___LOCALE -#define _LIBCPP___LOCALE - -#include <__config> -#include -#include -#include -#include -#include -#include -#include -#if _WIN32 -# include -#elif (__GLIBC__ || __APPLE__ || __FreeBSD__ || __sun__) -# include -#endif // _WIN32 || __GLIBC__ || __APPLE__ || __FreeBSD_ - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -class locale; - -template bool has_facet(const locale&) _NOEXCEPT; -template const _Facet& use_facet(const locale&); - -class _LIBCPP_VISIBLE locale -{ -public: - // types: - class facet; - class id; - - typedef int category; - static const category // values assigned here are for exposition only - none = 0, - collate = LC_COLLATE_MASK, - ctype = LC_CTYPE_MASK, - monetary = LC_MONETARY_MASK, - numeric = LC_NUMERIC_MASK, - time = LC_TIME_MASK, - messages = LC_MESSAGES_MASK, - all = collate | ctype | monetary | numeric | time | messages; - - // construct/copy/destroy: - locale() _NOEXCEPT; - locale(const locale&) _NOEXCEPT; - explicit locale(const char*); - explicit locale(const string&); - locale(const locale&, const char*, category); - locale(const locale&, const string&, category); - template - _LIBCPP_INLINE_VISIBILITY locale(const locale&, _Facet*); - locale(const locale&, const locale&, category); - - ~locale(); - - const locale& operator=(const locale&) _NOEXCEPT; - - template locale combine(const locale&) const; - - // locale operations: - string name() const; - bool operator==(const locale&) const; - bool operator!=(const locale& __y) const {return !(*this == __y);} - template - bool operator()(const basic_string<_CharT, _Traits, _Allocator>&, - const basic_string<_CharT, _Traits, _Allocator>&) const; - - // global locale objects: - static locale global(const locale&); - static const locale& classic(); - -private: - class __imp; - __imp* __locale_; - - void __install_ctor(const locale&, facet*, long); - static locale& __global(); - bool has_facet(id&) const; - const facet* use_facet(id&) const; - - template friend bool has_facet(const locale&) _NOEXCEPT; - template friend const _Facet& use_facet(const locale&); -}; - -class _LIBCPP_VISIBLE locale::facet - : public __shared_count -{ -protected: - _LIBCPP_INLINE_VISIBILITY - explicit facet(size_t __refs = 0) - : __shared_count(static_cast(__refs)-1) {} - - virtual ~facet(); - -// facet(const facet&) = delete; // effectively done in __shared_count -// void operator=(const facet&) = delete; -private: - virtual void __on_zero_shared() _NOEXCEPT; -}; - -class _LIBCPP_VISIBLE locale::id -{ - once_flag __flag_; - int32_t __id_; - - static int32_t __next_id; -public: - _LIBCPP_INLINE_VISIBILITY id() {} -private: - void __init(); - void operator=(const id&); // = delete; - id(const id&); // = delete; -public: // only needed for tests - long __get(); - - friend class locale; - friend class locale::__imp; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -locale::locale(const locale& __other, _Facet* __f) -{ - __install_ctor(__other, __f, __f ? __f->id.__get() : 0); -} - -template -locale -locale::combine(const locale& __other) const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (!_VSTD::has_facet<_Facet>(__other)) - throw runtime_error("locale::combine: locale missing facet"); -#endif // _LIBCPP_NO_EXCEPTIONS - return locale(*this, &const_cast<_Facet&>(_VSTD::use_facet<_Facet>(__other))); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -has_facet(const locale& __l) _NOEXCEPT -{ - return __l.has_facet(_Facet::id); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Facet& -use_facet(const locale& __l) -{ - return static_cast(*__l.use_facet(_Facet::id)); -} - -// template class collate; - -template -class _LIBCPP_VISIBLE collate - : public locale::facet -{ -public: - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_INLINE_VISIBILITY - explicit collate(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_INLINE_VISIBILITY - int compare(const char_type* __lo1, const char_type* __hi1, - const char_type* __lo2, const char_type* __hi2) const - { - return do_compare(__lo1, __hi1, __lo2, __hi2); - } - - _LIBCPP_INLINE_VISIBILITY - string_type transform(const char_type* __lo, const char_type* __hi) const - { - return do_transform(__lo, __hi); - } - - _LIBCPP_INLINE_VISIBILITY - long hash(const char_type* __lo, const char_type* __hi) const - { - return do_hash(__lo, __hi); - } - - static locale::id id; - -protected: - ~collate(); - virtual int do_compare(const char_type* __lo1, const char_type* __hi1, - const char_type* __lo2, const char_type* __hi2) const; - virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const - {return string_type(__lo, __hi);} - virtual long do_hash(const char_type* __lo, const char_type* __hi) const; -}; - -template locale::id collate<_CharT>::id; - -template -collate<_CharT>::~collate() -{ -} - -template -int -collate<_CharT>::do_compare(const char_type* __lo1, const char_type* __hi1, - const char_type* __lo2, const char_type* __hi2) const -{ - for (; __lo2 != __hi2; ++__lo1, ++__lo2) - { - if (__lo1 == __hi1 || *__lo1 < *__lo2) - return -1; - if (*__lo2 < *__lo1) - return 1; - } - return __lo1 != __hi1; -} - -template -long -collate<_CharT>::do_hash(const char_type* __lo, const char_type* __hi) const -{ - size_t __h = 0; - const size_t __sr = __CHAR_BIT__ * sizeof(size_t) - 8; - const size_t __mask = size_t(0xF) << (__sr + 4); - for(const char_type* __p = __lo; __p != __hi; ++__p) - { - __h = (__h << 4) + static_cast(*__p); - size_t __g = __h & __mask; - __h ^= __g | (__g >> __sr); - } - return static_cast(__h); -} - -extern template class _LIBCPP_VISIBLE collate; -extern template class _LIBCPP_VISIBLE collate; - -// template class collate_byname; - -template class _LIBCPP_VISIBLE collate_byname; - -template <> -class _LIBCPP_VISIBLE collate_byname - : public collate -{ - locale_t __l; -public: - typedef char char_type; - typedef basic_string string_type; - - explicit collate_byname(const char* __n, size_t __refs = 0); - explicit collate_byname(const string& __n, size_t __refs = 0); - -protected: - ~collate_byname(); - virtual int do_compare(const char_type* __lo1, const char_type* __hi1, - const char_type* __lo2, const char_type* __hi2) const; - virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const; -}; - -template <> -class _LIBCPP_VISIBLE collate_byname - : public collate -{ - locale_t __l; -public: - typedef wchar_t char_type; - typedef basic_string string_type; - - explicit collate_byname(const char* __n, size_t __refs = 0); - explicit collate_byname(const string& __n, size_t __refs = 0); - -protected: - ~collate_byname(); - - virtual int do_compare(const char_type* __lo1, const char_type* __hi1, - const char_type* __lo2, const char_type* __hi2) const; - virtual string_type do_transform(const char_type* __lo, const char_type* __hi) const; -}; - -template -bool -locale::operator()(const basic_string<_CharT, _Traits, _Allocator>& __x, - const basic_string<_CharT, _Traits, _Allocator>& __y) const -{ - return _VSTD::use_facet<_VSTD::collate<_CharT> >(*this).compare( - __x.data(), __x.data() + __x.size(), - __y.data(), __y.data() + __y.size()) < 0; -} - -// template class ctype - -class _LIBCPP_VISIBLE ctype_base -{ -public: -#if __GLIBC__ - typedef unsigned short mask; - static const mask space = _ISspace; - static const mask print = _ISprint; - static const mask cntrl = _IScntrl; - static const mask upper = _ISupper; - static const mask lower = _ISlower; - static const mask alpha = _ISalpha; - static const mask digit = _ISdigit; - static const mask punct = _ISpunct; - static const mask xdigit = _ISxdigit; - static const mask blank = _ISblank; -#elif _WIN32 - typedef unsigned short mask; - static const mask space = _SPACE; - static const mask print = _BLANK|_PUNCT|_ALPHA|_DIGIT; - static const mask cntrl = _CONTROL; - static const mask upper = _UPPER; - static const mask lower = _LOWER; - static const mask alpha = _ALPHA; - static const mask digit = _DIGIT; - static const mask punct = _PUNCT; - static const mask xdigit = _HEX; - static const mask blank = _BLANK; -#elif (__APPLE__ || __FreeBSD__) -#if __APPLE__ - typedef __uint32_t mask; -#elif __FreeBSD__ - typedef unsigned long mask; -#endif - static const mask space = _CTYPE_S; - static const mask print = _CTYPE_R; - static const mask cntrl = _CTYPE_C; - static const mask upper = _CTYPE_U; - static const mask lower = _CTYPE_L; - static const mask alpha = _CTYPE_A; - static const mask digit = _CTYPE_D; - static const mask punct = _CTYPE_P; - static const mask xdigit = _CTYPE_X; - static const mask blank = _CTYPE_B; -#elif __sun__ - typedef unsigned int mask; - static const mask space = _ISSPACE; - static const mask print = _ISPRINT; - static const mask cntrl = _ISCNTRL; - static const mask upper = _ISUPPER; - static const mask lower = _ISLOWER; - static const mask alpha = _ISALPHA; - static const mask digit = _ISDIGIT; - static const mask punct = _ISPUNCT; - static const mask xdigit = _ISXDIGIT; - static const mask blank = _ISBLANK; -#else // __GLIBC__ || _WIN32 || __APPLE__ || __FreeBSD__ || __sun__ - typedef unsigned long mask; - static const mask space = 1<<0; - static const mask print = 1<<1; - static const mask cntrl = 1<<2; - static const mask upper = 1<<3; - static const mask lower = 1<<4; - static const mask alpha = 1<<5; - static const mask digit = 1<<6; - static const mask punct = 1<<7; - static const mask xdigit = 1<<8; - static const mask blank = 1<<9; -#endif // __GLIBC__ || _WIN32 || __APPLE__ || __FreeBSD__ - static const mask alnum = alpha | digit; - static const mask graph = alnum | punct; - - _LIBCPP_ALWAYS_INLINE ctype_base() {} -}; - -template class _LIBCPP_VISIBLE ctype; - -template <> -class _LIBCPP_VISIBLE ctype - : public locale::facet, - public ctype_base -{ -public: - typedef wchar_t char_type; - - _LIBCPP_ALWAYS_INLINE - explicit ctype(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - bool is(mask __m, char_type __c) const - { - return do_is(__m, __c); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* is(const char_type* __low, const char_type* __high, mask* __vec) const - { - return do_is(__low, __high, __vec); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* scan_is(mask __m, const char_type* __low, const char_type* __high) const - { - return do_scan_is(__m, __low, __high); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* scan_not(mask __m, const char_type* __low, const char_type* __high) const - { - return do_scan_not(__m, __low, __high); - } - - _LIBCPP_ALWAYS_INLINE - char_type toupper(char_type __c) const - { - return do_toupper(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* toupper(char_type* __low, const char_type* __high) const - { - return do_toupper(__low, __high); - } - - _LIBCPP_ALWAYS_INLINE - char_type tolower(char_type __c) const - { - return do_tolower(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* tolower(char_type* __low, const char_type* __high) const - { - return do_tolower(__low, __high); - } - - _LIBCPP_ALWAYS_INLINE - char_type widen(char __c) const - { - return do_widen(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char* widen(const char* __low, const char* __high, char_type* __to) const - { - return do_widen(__low, __high, __to); - } - - _LIBCPP_ALWAYS_INLINE - char narrow(char_type __c, char __dfault) const - { - return do_narrow(__c, __dfault); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const - { - return do_narrow(__low, __high, __dfault, __to); - } - - static locale::id id; - -protected: - ~ctype(); - virtual bool do_is(mask __m, char_type __c) const; - virtual const char_type* do_is(const char_type* __low, const char_type* __high, mask* __vec) const; - virtual const char_type* do_scan_is(mask __m, const char_type* __low, const char_type* __high) const; - virtual const char_type* do_scan_not(mask __m, const char_type* __low, const char_type* __high) const; - virtual char_type do_toupper(char_type) const; - virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const; - virtual char_type do_tolower(char_type) const; - virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const; - virtual char_type do_widen(char) const; - virtual const char* do_widen(const char* __low, const char* __high, char_type* __dest) const; - virtual char do_narrow(char_type, char __dfault) const; - virtual const char_type* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __dest) const; -}; - -template <> -class _LIBCPP_VISIBLE ctype - : public locale::facet, public ctype_base -{ - const mask* __tab_; - bool __del_; -public: - typedef char char_type; - - explicit ctype(const mask* __tab = 0, bool __del = false, size_t __refs = 0); - - _LIBCPP_ALWAYS_INLINE - bool is(mask __m, char_type __c) const - { - return isascii(__c) ? __tab_[static_cast(__c)] & __m : false; - } - - _LIBCPP_ALWAYS_INLINE - const char_type* is(const char_type* __low, const char_type* __high, mask* __vec) const - { - for (; __low != __high; ++__low, ++__vec) - *__vec = isascii(*__low) ? __tab_[static_cast(*__low)] : 0; - return __low; - } - - _LIBCPP_ALWAYS_INLINE - const char_type* scan_is (mask __m, const char_type* __low, const char_type* __high) const - { - for (; __low != __high; ++__low) - if (isascii(*__low) && (__tab_[static_cast(*__low)] & __m)) - break; - return __low; - } - - _LIBCPP_ALWAYS_INLINE - const char_type* scan_not(mask __m, const char_type* __low, const char_type* __high) const - { - for (; __low != __high; ++__low) - if (!(isascii(*__low) && (__tab_[static_cast(*__low)] & __m))) - break; - return __low; - } - - _LIBCPP_ALWAYS_INLINE - char_type toupper(char_type __c) const - { - return do_toupper(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* toupper(char_type* __low, const char_type* __high) const - { - return do_toupper(__low, __high); - } - - _LIBCPP_ALWAYS_INLINE - char_type tolower(char_type __c) const - { - return do_tolower(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char_type* tolower(char_type* __low, const char_type* __high) const - { - return do_tolower(__low, __high); - } - - _LIBCPP_ALWAYS_INLINE - char_type widen(char __c) const - { - return do_widen(__c); - } - - _LIBCPP_ALWAYS_INLINE - const char* widen(const char* __low, const char* __high, char_type* __to) const - { - return do_widen(__low, __high, __to); - } - - _LIBCPP_ALWAYS_INLINE - char narrow(char_type __c, char __dfault) const - { - return do_narrow(__c, __dfault); - } - - _LIBCPP_ALWAYS_INLINE - const char* narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const - { - return do_narrow(__low, __high, __dfault, __to); - } - - static locale::id id; - -#ifdef _CACHED_RUNES - static const size_t table_size = _CACHED_RUNES; -#else - static const size_t table_size = 256; // FIXME: Don't hardcode this. -#endif - _LIBCPP_ALWAYS_INLINE const mask* table() const _NOEXCEPT {return __tab_;} - static const mask* classic_table() _NOEXCEPT; -#if defined(__GLIBC__) - static const int* __classic_upper_table() _NOEXCEPT; - static const int* __classic_lower_table() _NOEXCEPT; -#endif - -protected: - ~ctype(); - virtual char_type do_toupper(char_type __c) const; - virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const; - virtual char_type do_tolower(char_type __c) const; - virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const; - virtual char_type do_widen(char __c) const; - virtual const char* do_widen(const char* __low, const char* __high, char_type* __to) const; - virtual char do_narrow(char_type __c, char __dfault) const; - virtual const char* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __to) const; -}; - -// template class ctype_byname; - -template class _LIBCPP_VISIBLE ctype_byname; - -template <> -class _LIBCPP_VISIBLE ctype_byname - : public ctype -{ - locale_t __l; - -public: - explicit ctype_byname(const char*, size_t = 0); - explicit ctype_byname(const string&, size_t = 0); - -protected: - ~ctype_byname(); - virtual char_type do_toupper(char_type) const; - virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const; - virtual char_type do_tolower(char_type) const; - virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const; -}; - -template <> -class _LIBCPP_VISIBLE ctype_byname - : public ctype -{ - locale_t __l; - -public: - explicit ctype_byname(const char*, size_t = 0); - explicit ctype_byname(const string&, size_t = 0); - -protected: - ~ctype_byname(); - virtual bool do_is(mask __m, char_type __c) const; - virtual const char_type* do_is(const char_type* __low, const char_type* __high, mask* __vec) const; - virtual const char_type* do_scan_is(mask __m, const char_type* __low, const char_type* __high) const; - virtual const char_type* do_scan_not(mask __m, const char_type* __low, const char_type* __high) const; - virtual char_type do_toupper(char_type) const; - virtual const char_type* do_toupper(char_type* __low, const char_type* __high) const; - virtual char_type do_tolower(char_type) const; - virtual const char_type* do_tolower(char_type* __low, const char_type* __high) const; - virtual char_type do_widen(char) const; - virtual const char* do_widen(const char* __low, const char* __high, char_type* __dest) const; - virtual char do_narrow(char_type, char __dfault) const; - virtual const char_type* do_narrow(const char_type* __low, const char_type* __high, char __dfault, char* __dest) const; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isspace(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::space, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isprint(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::print, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -iscntrl(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::cntrl, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isupper(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::upper, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -islower(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::lower, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isalpha(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::alpha, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isdigit(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::digit, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -ispunct(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::punct, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isxdigit(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::xdigit, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isalnum(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::alnum, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -isgraph(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).is(ctype_base::graph, __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_CharT -toupper(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).toupper(__c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_CharT -tolower(_CharT __c, const locale& __loc) -{ - return use_facet >(__loc).tolower(__c); -} - -// codecvt_base - -class _LIBCPP_VISIBLE codecvt_base -{ -public: - _LIBCPP_ALWAYS_INLINE codecvt_base() {} - enum result {ok, partial, error, noconv}; -}; - -// template class codecvt; - -template class _LIBCPP_VISIBLE codecvt; - -// template <> class codecvt - -template <> -class _LIBCPP_VISIBLE codecvt - : public locale::facet, - public codecvt_base -{ -public: - typedef char intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit codecvt(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - result out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_unshift(__st, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const - { - return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - int encoding() const _NOEXCEPT - { - return do_encoding(); - } - - _LIBCPP_ALWAYS_INLINE - bool always_noconv() const _NOEXCEPT - { - return do_always_noconv(); - } - - _LIBCPP_ALWAYS_INLINE - int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const - { - return do_length(__st, __frm, __end, __mx); - } - - _LIBCPP_ALWAYS_INLINE - int max_length() const _NOEXCEPT - { - return do_max_length(); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - explicit codecvt(const char*, size_t __refs = 0) - : locale::facet(__refs) {} - - ~codecvt(); - - virtual result do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const _NOEXCEPT; - virtual bool do_always_noconv() const _NOEXCEPT; - virtual int do_length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const; - virtual int do_max_length() const _NOEXCEPT; -}; - -// template <> class codecvt - -template <> -class _LIBCPP_VISIBLE codecvt - : public locale::facet, - public codecvt_base -{ - locale_t __l; -public: - typedef wchar_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - explicit codecvt(size_t __refs = 0); - - _LIBCPP_ALWAYS_INLINE - result out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_unshift(__st, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const - { - return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - int encoding() const _NOEXCEPT - { - return do_encoding(); - } - - _LIBCPP_ALWAYS_INLINE - bool always_noconv() const _NOEXCEPT - { - return do_always_noconv(); - } - - _LIBCPP_ALWAYS_INLINE - int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const - { - return do_length(__st, __frm, __end, __mx); - } - - _LIBCPP_ALWAYS_INLINE - int max_length() const _NOEXCEPT - { - return do_max_length(); - } - - static locale::id id; - -protected: - explicit codecvt(const char*, size_t __refs = 0); - - ~codecvt(); - - virtual result do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const _NOEXCEPT; - virtual bool do_always_noconv() const _NOEXCEPT; - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const; - virtual int do_max_length() const _NOEXCEPT; -}; - -// template <> class codecvt - -template <> -class _LIBCPP_VISIBLE codecvt - : public locale::facet, - public codecvt_base -{ -public: - typedef char16_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit codecvt(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - result out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_unshift(__st, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const - { - return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - int encoding() const _NOEXCEPT - { - return do_encoding(); - } - - _LIBCPP_ALWAYS_INLINE - bool always_noconv() const _NOEXCEPT - { - return do_always_noconv(); - } - - _LIBCPP_ALWAYS_INLINE - int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const - { - return do_length(__st, __frm, __end, __mx); - } - - _LIBCPP_ALWAYS_INLINE - int max_length() const _NOEXCEPT - { - return do_max_length(); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - explicit codecvt(const char*, size_t __refs = 0) - : locale::facet(__refs) {} - - ~codecvt(); - - virtual result do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const _NOEXCEPT; - virtual bool do_always_noconv() const _NOEXCEPT; - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const; - virtual int do_max_length() const _NOEXCEPT; -}; - -// template <> class codecvt - -template <> -class _LIBCPP_VISIBLE codecvt - : public locale::facet, - public codecvt_base -{ -public: - typedef char32_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit codecvt(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - result out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_out(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const - { - return do_unshift(__st, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - result in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const - { - return do_in(__st, __frm, __frm_end, __frm_nxt, __to, __to_end, __to_nxt); - } - - _LIBCPP_ALWAYS_INLINE - int encoding() const _NOEXCEPT - { - return do_encoding(); - } - - _LIBCPP_ALWAYS_INLINE - bool always_noconv() const _NOEXCEPT - { - return do_always_noconv(); - } - - _LIBCPP_ALWAYS_INLINE - int length(state_type& __st, const extern_type* __frm, const extern_type* __end, size_t __mx) const - { - return do_length(__st, __frm, __end, __mx); - } - - _LIBCPP_ALWAYS_INLINE - int max_length() const _NOEXCEPT - { - return do_max_length(); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - explicit codecvt(const char*, size_t __refs = 0) - : locale::facet(__refs) {} - - ~codecvt(); - - virtual result do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const _NOEXCEPT; - virtual bool do_always_noconv() const _NOEXCEPT; - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, size_t __mx) const; - virtual int do_max_length() const _NOEXCEPT; -}; - -// template class codecvt_byname - -template -class _LIBCPP_VISIBLE codecvt_byname - : public codecvt<_InternT, _ExternT, _StateT> -{ -public: - _LIBCPP_ALWAYS_INLINE - explicit codecvt_byname(const char* __nm, size_t __refs = 0) - : codecvt<_InternT, _ExternT, _StateT>(__nm, __refs) {} - _LIBCPP_ALWAYS_INLINE - explicit codecvt_byname(const string& __nm, size_t __refs = 0) - : codecvt<_InternT, _ExternT, _StateT>(__nm.c_str(), __refs) {} -protected: - ~codecvt_byname(); -}; - -template -codecvt_byname<_InternT, _ExternT, _StateT>::~codecvt_byname() -{ -} - -extern template class codecvt_byname; -extern template class codecvt_byname; -extern template class codecvt_byname; -extern template class codecvt_byname; - -_LIBCPP_VISIBLE void __throw_runtime_error(const char*); - -template -struct __narrow_to_utf8 -{ - template - _OutputIterator - operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const; -}; - -template <> -struct __narrow_to_utf8<8> -{ - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const - { - for (; __wb < __we; ++__wb, ++__s) - *__s = *__wb; - return __s; - } -}; - -template <> -struct __narrow_to_utf8<16> - : public codecvt -{ - _LIBCPP_ALWAYS_INLINE - __narrow_to_utf8() : codecvt(1) {} - - ~__narrow_to_utf8(); - - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const - { - result __r = ok; - mbstate_t __mb; - while (__wb < __we && __r != error) - { - const int __sz = 32; - char __buf[__sz]; - char* __bn; - const char16_t* __wn = (const char16_t*)__wb; - __r = do_out(__mb, (const char16_t*)__wb, (const char16_t*)__we, __wn, - __buf, __buf+__sz, __bn); - if (__r == codecvt_base::error || __wn == (const char16_t*)__wb) - __throw_runtime_error("locale not supported"); - for (const char* __p = __buf; __p < __bn; ++__p, ++__s) - *__s = *__p; - __wb = (const _CharT*)__wn; - } - return __s; - } -}; - -template <> -struct __narrow_to_utf8<32> - : public codecvt -{ - _LIBCPP_ALWAYS_INLINE - __narrow_to_utf8() : codecvt(1) {} - - ~__narrow_to_utf8(); - - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const _CharT* __wb, const _CharT* __we) const - { - result __r = ok; - mbstate_t __mb; - while (__wb < __we && __r != error) - { - const int __sz = 32; - char __buf[__sz]; - char* __bn; - const char32_t* __wn = (const char32_t*)__wb; - __r = do_out(__mb, (const char32_t*)__wb, (const char32_t*)__we, __wn, - __buf, __buf+__sz, __bn); - if (__r == codecvt_base::error || __wn == (const char32_t*)__wb) - __throw_runtime_error("locale not supported"); - for (const char* __p = __buf; __p < __bn; ++__p, ++__s) - *__s = *__p; - __wb = (const _CharT*)__wn; - } - return __s; - } -}; - -template -struct __widen_from_utf8 -{ - template - _OutputIterator - operator()(_OutputIterator __s, const char* __nb, const char* __ne) const; -}; - -template <> -struct __widen_from_utf8<8> -{ - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const char* __nb, const char* __ne) const - { - for (; __nb < __ne; ++__nb, ++__s) - *__s = *__nb; - return __s; - } -}; - -template <> -struct __widen_from_utf8<16> - : public codecvt -{ - _LIBCPP_ALWAYS_INLINE - __widen_from_utf8() : codecvt(1) {} - - ~__widen_from_utf8(); - - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const char* __nb, const char* __ne) const - { - result __r = ok; - mbstate_t __mb; - while (__nb < __ne && __r != error) - { - const int __sz = 32; - char16_t __buf[__sz]; - char16_t* __bn; - const char* __nn = __nb; - __r = do_in(__mb, __nb, __ne - __nb > __sz ? __nb+__sz : __ne, __nn, - __buf, __buf+__sz, __bn); - if (__r == codecvt_base::error || __nn == __nb) - __throw_runtime_error("locale not supported"); - for (const char16_t* __p = __buf; __p < __bn; ++__p, ++__s) - *__s = (wchar_t)*__p; - __nb = __nn; - } - return __s; - } -}; - -template <> -struct __widen_from_utf8<32> - : public codecvt -{ - _LIBCPP_ALWAYS_INLINE - __widen_from_utf8() : codecvt(1) {} - - ~__widen_from_utf8(); - - template - _LIBCPP_ALWAYS_INLINE - _OutputIterator - operator()(_OutputIterator __s, const char* __nb, const char* __ne) const - { - result __r = ok; - mbstate_t __mb; - while (__nb < __ne && __r != error) - { - const int __sz = 32; - char32_t __buf[__sz]; - char32_t* __bn; - const char* __nn = __nb; - __r = do_in(__mb, __nb, __ne - __nb > __sz ? __nb+__sz : __ne, __nn, - __buf, __buf+__sz, __bn); - if (__r == codecvt_base::error || __nn == __nb) - __throw_runtime_error("locale not supported"); - for (const char32_t* __p = __buf; __p < __bn; ++__p, ++__s) - *__s = (wchar_t)*__p; - __nb = __nn; - } - return __s; - } -}; - -// template class numpunct - -template class _LIBCPP_VISIBLE numpunct; - -template <> -class _LIBCPP_VISIBLE numpunct - : public locale::facet -{ -public: - typedef char char_type; - typedef basic_string string_type; - - explicit numpunct(size_t __refs = 0); - - _LIBCPP_ALWAYS_INLINE char_type decimal_point() const {return do_decimal_point();} - _LIBCPP_ALWAYS_INLINE char_type thousands_sep() const {return do_thousands_sep();} - _LIBCPP_ALWAYS_INLINE string grouping() const {return do_grouping();} - _LIBCPP_ALWAYS_INLINE string_type truename() const {return do_truename();} - _LIBCPP_ALWAYS_INLINE string_type falsename() const {return do_falsename();} - - static locale::id id; - -protected: - ~numpunct(); - virtual char_type do_decimal_point() const; - virtual char_type do_thousands_sep() const; - virtual string do_grouping() const; - virtual string_type do_truename() const; - virtual string_type do_falsename() const; - - char_type __decimal_point_; - char_type __thousands_sep_; - string __grouping_; -}; - -template <> -class _LIBCPP_VISIBLE numpunct - : public locale::facet -{ -public: - typedef wchar_t char_type; - typedef basic_string string_type; - - explicit numpunct(size_t __refs = 0); - - _LIBCPP_ALWAYS_INLINE char_type decimal_point() const {return do_decimal_point();} - _LIBCPP_ALWAYS_INLINE char_type thousands_sep() const {return do_thousands_sep();} - _LIBCPP_ALWAYS_INLINE string grouping() const {return do_grouping();} - _LIBCPP_ALWAYS_INLINE string_type truename() const {return do_truename();} - _LIBCPP_ALWAYS_INLINE string_type falsename() const {return do_falsename();} - - static locale::id id; - -protected: - ~numpunct(); - virtual char_type do_decimal_point() const; - virtual char_type do_thousands_sep() const; - virtual string do_grouping() const; - virtual string_type do_truename() const; - virtual string_type do_falsename() const; - - char_type __decimal_point_; - char_type __thousands_sep_; - string __grouping_; -}; - -// template class numpunct_byname - -template class _LIBCPP_VISIBLE numpunct_byname; - -template <> -class _LIBCPP_VISIBLE numpunct_byname -: public numpunct -{ -public: - typedef char char_type; - typedef basic_string string_type; - - explicit numpunct_byname(const char* __nm, size_t __refs = 0); - explicit numpunct_byname(const string& __nm, size_t __refs = 0); - -protected: - ~numpunct_byname(); - -private: - void __init(const char*); -}; - -template <> -class _LIBCPP_VISIBLE numpunct_byname -: public numpunct -{ -public: - typedef wchar_t char_type; - typedef basic_string string_type; - - explicit numpunct_byname(const char* __nm, size_t __refs = 0); - explicit numpunct_byname(const string& __nm, size_t __refs = 0); - -protected: - ~numpunct_byname(); - -private: - void __init(const char*); -}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___LOCALE diff --git a/libcxx/include/__mutex_base b/libcxx/include/__mutex_base deleted file mode 100644 index 5410272b4c99..000000000000 --- a/libcxx/include/__mutex_base +++ /dev/null @@ -1,439 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___MUTEX_BASE -#define _LIBCPP___MUTEX_BASE - -#include <__config> -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#ifdef _LIBCPP_SHARED_LOCK - -namespace ting { -template class shared_lock; -template class upgrade_lock; -} - -#endif // _LIBCPP_SHARED_LOCK - - -_LIBCPP_BEGIN_NAMESPACE_STD - -class _LIBCPP_VISIBLE mutex -{ - pthread_mutex_t __m_; - -public: - _LIBCPP_INLINE_VISIBILITY - mutex() {__m_ = (pthread_mutex_t)PTHREAD_MUTEX_INITIALIZER;} - ~mutex(); - -private: - mutex(const mutex&);// = delete; - mutex& operator=(const mutex&);// = delete; - -public: - void lock(); - bool try_lock(); - void unlock(); - - typedef pthread_mutex_t* native_handle_type; - _LIBCPP_INLINE_VISIBILITY native_handle_type native_handle() {return &__m_;} -}; - -struct _LIBCPP_VISIBLE defer_lock_t {}; -struct _LIBCPP_VISIBLE try_to_lock_t {}; -struct _LIBCPP_VISIBLE adopt_lock_t {}; - -//constexpr -extern const -defer_lock_t defer_lock; - -//constexpr -extern const -try_to_lock_t try_to_lock; - -//constexpr -extern const -adopt_lock_t adopt_lock; - -template -class _LIBCPP_VISIBLE lock_guard -{ -public: - typedef _Mutex mutex_type; - -private: - mutex_type& __m_; -public: - - _LIBCPP_INLINE_VISIBILITY - explicit lock_guard(mutex_type& __m) - : __m_(__m) {__m_.lock();} - _LIBCPP_INLINE_VISIBILITY - lock_guard(mutex_type& __m, adopt_lock_t) - : __m_(__m) {} - _LIBCPP_INLINE_VISIBILITY - ~lock_guard() {__m_.unlock();} - -private: - lock_guard(lock_guard const&);// = delete; - lock_guard& operator=(lock_guard const&);// = delete; -}; - -template -class _LIBCPP_VISIBLE unique_lock -{ -public: - typedef _Mutex mutex_type; - -private: - mutex_type* __m_; - bool __owns_; - -public: - _LIBCPP_INLINE_VISIBILITY - unique_lock() : __m_(nullptr), __owns_(false) {} - _LIBCPP_INLINE_VISIBILITY - explicit unique_lock(mutex_type& __m) - : __m_(&__m), __owns_(true) {__m_->lock();} - _LIBCPP_INLINE_VISIBILITY - unique_lock(mutex_type& __m, defer_lock_t) - : __m_(&__m), __owns_(false) {} - _LIBCPP_INLINE_VISIBILITY - unique_lock(mutex_type& __m, try_to_lock_t) - : __m_(&__m), __owns_(__m.try_lock()) {} - _LIBCPP_INLINE_VISIBILITY - unique_lock(mutex_type& __m, adopt_lock_t) - : __m_(&__m), __owns_(true) {} - template - _LIBCPP_INLINE_VISIBILITY - unique_lock(mutex_type& __m, const chrono::time_point<_Clock, _Duration>& __t) - : __m_(&__m), __owns_(__m.try_lock_until(__t)) {} - template - _LIBCPP_INLINE_VISIBILITY - unique_lock(mutex_type& __m, const chrono::duration<_Rep, _Period>& __d) - : __m_(&__m), __owns_(__m.try_lock_for(__d)) {} - _LIBCPP_INLINE_VISIBILITY - ~unique_lock() - { - if (__owns_) - __m_->unlock(); - } - -private: - unique_lock(unique_lock const&); // = delete; - unique_lock& operator=(unique_lock const&); // = delete; - -public: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - unique_lock(unique_lock&& __u) - : __m_(__u.__m_), __owns_(__u.__owns_) - {__u.__m_ = nullptr; __u.__owns_ = false;} - _LIBCPP_INLINE_VISIBILITY - unique_lock& operator=(unique_lock&& __u) - { - if (__owns_) - __m_->unlock(); - __m_ = __u.__m_; - __owns_ = __u.__owns_; - __u.__m_ = nullptr; - __u.__owns_ = false; - return *this; - } - -#ifdef _LIBCPP_SHARED_LOCK - - unique_lock(ting::shared_lock&&, try_to_lock_t); - template - unique_lock(ting::shared_lock&&, - const chrono::time_point<_Clock, _Duration>&); - template - unique_lock(ting::shared_lock&&, - const chrono::duration<_Rep, _Period>&); - - explicit unique_lock(ting::upgrade_lock&&); - unique_lock(ting::upgrade_lock&&, try_to_lock_t); - template - unique_lock(ting::upgrade_lock&&, - const chrono::time_point<_Clock, _Duration>&); - template - unique_lock(ting::upgrade_lock&&, - const chrono::duration<_Rep, _Period>&); - -#endif // _LIBCPP_SHARED_LOCK - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - void lock(); - bool try_lock(); - - template - bool try_lock_for(const chrono::duration<_Rep, _Period>& __d); - template - bool try_lock_until(const chrono::time_point<_Clock, _Duration>& __t); - - void unlock(); - - _LIBCPP_INLINE_VISIBILITY - void swap(unique_lock& __u) - { - _VSTD::swap(__m_, __u.__m_); - _VSTD::swap(__owns_, __u.__owns_); - } - _LIBCPP_INLINE_VISIBILITY - mutex_type* release() - { - mutex_type* __m = __m_; - __m_ = nullptr; - __owns_ = false; - return __m; - } - - _LIBCPP_INLINE_VISIBILITY - bool owns_lock() const {return __owns_;} - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_EXPLICIT - operator bool () const {return __owns_;} - _LIBCPP_INLINE_VISIBILITY - mutex_type* mutex() const {return __m_;} -}; - -template -void -unique_lock<_Mutex>::lock() -{ - if (__m_ == nullptr) - __throw_system_error(EPERM, "unique_lock::lock: references null mutex"); - if (__owns_) - __throw_system_error(EDEADLK, "unique_lock::lock: already locked"); - __m_->lock(); - __owns_ = true; -} - -template -bool -unique_lock<_Mutex>::try_lock() -{ - if (__m_ == nullptr) - __throw_system_error(EPERM, "unique_lock::try_lock: references null mutex"); - if (__owns_) - __throw_system_error(EDEADLK, "unique_lock::try_lock: already locked"); - __owns_ = __m_->try_lock(); - return __owns_; -} - -template -template -bool -unique_lock<_Mutex>::try_lock_for(const chrono::duration<_Rep, _Period>& __d) -{ - if (__m_ == nullptr) - __throw_system_error(EPERM, "unique_lock::try_lock_for: references null mutex"); - if (__owns_) - __throw_system_error(EDEADLK, "unique_lock::try_lock_for: already locked"); - __owns_ = __m_->try_lock_for(__d); - return __owns_; -} - -template -template -bool -unique_lock<_Mutex>::try_lock_until(const chrono::time_point<_Clock, _Duration>& __t) -{ - if (__m_ == nullptr) - __throw_system_error(EPERM, "unique_lock::try_lock_until: references null mutex"); - if (__owns_) - __throw_system_error(EDEADLK, "unique_lock::try_lock_until: already locked"); - __owns_ = __m_->try_lock_until(__t); - return __owns_; -} - -template -void -unique_lock<_Mutex>::unlock() -{ - if (!__owns_) - __throw_system_error(EPERM, "unique_lock::unlock: not locked"); - __m_->unlock(); - __owns_ = false; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(unique_lock<_Mutex>& __x, unique_lock<_Mutex>& __y) {__x.swap(__y);} - -struct _LIBCPP_VISIBLE cv_status -{ - enum _ { - no_timeout, - timeout - }; - - _ __v_; - - _LIBCPP_INLINE_VISIBILITY cv_status(_ __v) : __v_(__v) {} - _LIBCPP_INLINE_VISIBILITY operator int() const {return __v_;} - -}; - -class _LIBCPP_VISIBLE condition_variable -{ - pthread_cond_t __cv_; -public: - _LIBCPP_INLINE_VISIBILITY - condition_variable() {__cv_ = (pthread_cond_t)PTHREAD_COND_INITIALIZER;} - ~condition_variable(); - -private: - condition_variable(const condition_variable&); // = delete; - condition_variable& operator=(const condition_variable&); // = delete; - -public: - void notify_one(); - void notify_all(); - - void wait(unique_lock& __lk); - template - void wait(unique_lock& __lk, _Predicate __pred); - - template - cv_status - wait_until(unique_lock& __lk, - const chrono::time_point& __t); - - template - cv_status - wait_until(unique_lock& __lk, - const chrono::time_point<_Clock, _Duration>& __t); - - template - bool - wait_until(unique_lock& __lk, - const chrono::time_point<_Clock, _Duration>& __t, - _Predicate __pred); - - template - cv_status - wait_for(unique_lock& __lk, - const chrono::duration<_Rep, _Period>& __d); - - template - bool - wait_for(unique_lock& __lk, - const chrono::duration<_Rep, _Period>& __d, - _Predicate __pred); - - typedef pthread_cond_t* native_handle_type; - _LIBCPP_INLINE_VISIBILITY native_handle_type native_handle() {return &__cv_;} - -private: - void __do_timed_wait(unique_lock& __lk, - chrono::time_point); -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - chrono::__is_duration<_To>::value, - _To ->::type -__ceil(chrono::duration<_Rep, _Period> __d) -{ - using namespace chrono; - _To __r = duration_cast<_To>(__d); - if (__r < __d) - ++__r; - return __r; -} - -template -void -condition_variable::wait(unique_lock& __lk, _Predicate __pred) -{ - while (!__pred()) - wait(__lk); -} - -template -cv_status -condition_variable::wait_until(unique_lock& __lk, - const chrono::time_point& __t) -{ - using namespace chrono; - typedef time_point __nano_sys_tmpt; - __do_timed_wait(__lk, - __nano_sys_tmpt(__ceil(__t.time_since_epoch()))); - return system_clock::now() < __t ? cv_status::no_timeout : - cv_status::timeout; -} - -template -cv_status -condition_variable::wait_until(unique_lock& __lk, - const chrono::time_point<_Clock, _Duration>& __t) -{ - using namespace chrono; - system_clock::time_point __s_now = system_clock::now(); - typename _Clock::time_point __c_now = _Clock::now(); - __do_timed_wait(__lk, __s_now + __ceil(__t - __c_now)); - return _Clock::now() < __t ? cv_status::no_timeout : cv_status::timeout; -} - -template -bool -condition_variable::wait_until(unique_lock& __lk, - const chrono::time_point<_Clock, _Duration>& __t, - _Predicate __pred) -{ - while (!__pred()) - { - if (wait_until(__lk, __t) == cv_status::timeout) - return __pred(); - } - return true; -} - -template -cv_status -condition_variable::wait_for(unique_lock& __lk, - const chrono::duration<_Rep, _Period>& __d) -{ - using namespace chrono; - system_clock::time_point __s_now = system_clock::now(); - steady_clock::time_point __c_now = steady_clock::now(); - __do_timed_wait(__lk, __s_now + __ceil(__d)); - return steady_clock::now() - __c_now < __d ? cv_status::no_timeout : - cv_status::timeout; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -condition_variable::wait_for(unique_lock& __lk, - const chrono::duration<_Rep, _Period>& __d, - _Predicate __pred) -{ - return wait_until(__lk, chrono::steady_clock::now() + __d, - _VSTD::move(__pred)); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___MUTEX_BASE diff --git a/libcxx/include/__split_buffer b/libcxx/include/__split_buffer deleted file mode 100644 index e0aa13b89883..000000000000 --- a/libcxx/include/__split_buffer +++ /dev/null @@ -1,654 +0,0 @@ -// -*- C++ -*- -#ifndef _LIBCPP_SPLIT_BUFFER -#define _LIBCPP_SPLIT_BUFFER - -#include <__config> -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -class __split_buffer_common -{ -protected: - void __throw_length_error() const; - void __throw_out_of_range() const; -}; - -template > -struct __split_buffer - : private __split_buffer_common -{ -private: - __split_buffer(const __split_buffer&); - __split_buffer& operator=(const __split_buffer&); -public: - typedef _Tp value_type; - typedef _Allocator allocator_type; - typedef typename remove_reference::type __alloc_rr; - typedef allocator_traits<__alloc_rr> __alloc_traits; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef pointer iterator; - typedef const_pointer const_iterator; - - pointer __first_; - pointer __begin_; - pointer __end_; - __compressed_pair __end_cap_; - - typedef typename add_lvalue_reference::type __alloc_ref; - typedef typename add_lvalue_reference::type __alloc_const_ref; - - _LIBCPP_INLINE_VISIBILITY __alloc_rr& __alloc() _NOEXCEPT {return __end_cap_.second();} - _LIBCPP_INLINE_VISIBILITY const __alloc_rr& __alloc() const _NOEXCEPT {return __end_cap_.second();} - _LIBCPP_INLINE_VISIBILITY pointer& __end_cap() _NOEXCEPT {return __end_cap_.first();} - _LIBCPP_INLINE_VISIBILITY const pointer& __end_cap() const _NOEXCEPT {return __end_cap_.first();} - - __split_buffer() - _NOEXCEPT_(is_nothrow_default_constructible::value); - explicit __split_buffer(__alloc_rr& __a); - explicit __split_buffer(const __alloc_rr& __a); - __split_buffer(size_type __cap, size_type __start, __alloc_rr& __a); - ~__split_buffer(); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __split_buffer(__split_buffer&& __c) - _NOEXCEPT_(is_nothrow_move_constructible::value); - __split_buffer(__split_buffer&& __c, const __alloc_rr& __a); - __split_buffer& operator=(__split_buffer&& __c) - _NOEXCEPT_((__alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value) || - !__alloc_traits::propagate_on_container_move_assignment::value); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY iterator begin() _NOEXCEPT {return __begin_;} - _LIBCPP_INLINE_VISIBILITY const_iterator begin() const _NOEXCEPT {return __begin_;} - _LIBCPP_INLINE_VISIBILITY iterator end() _NOEXCEPT {return __end_;} - _LIBCPP_INLINE_VISIBILITY const_iterator end() const _NOEXCEPT {return __end_;} - - _LIBCPP_INLINE_VISIBILITY - void clear() _NOEXCEPT - {__destruct_at_end(__begin_);} - _LIBCPP_INLINE_VISIBILITY size_type size() const {return static_cast(__end_ - __begin_);} - _LIBCPP_INLINE_VISIBILITY bool empty() const {return __end_ == __begin_;} - _LIBCPP_INLINE_VISIBILITY size_type capacity() const {return static_cast(__end_cap() - __first_);} - _LIBCPP_INLINE_VISIBILITY size_type __front_spare() const {return static_cast(__begin_ - __first_);} - _LIBCPP_INLINE_VISIBILITY size_type __back_spare() const {return static_cast(__end_cap() - __end_);} - - _LIBCPP_INLINE_VISIBILITY reference front() {return *__begin_;} - _LIBCPP_INLINE_VISIBILITY const_reference front() const {return *__begin_;} - _LIBCPP_INLINE_VISIBILITY reference back() {return *(__end_ - 1);} - _LIBCPP_INLINE_VISIBILITY const_reference back() const {return *(__end_ - 1);} - - void reserve(size_type __n); - void shrink_to_fit() _NOEXCEPT; - void push_front(const_reference __x); - _LIBCPP_INLINE_VISIBILITY void push_back(const_reference __x); -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) - void push_front(value_type&& __x); - void push_back(value_type&& __x); -#if !defined(_LIBCPP_HAS_NO_VARIADICS) - template - void emplace_back(_Args&&... __args); -#endif // !defined(_LIBCPP_HAS_NO_VARIADICS) -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) - - _LIBCPP_INLINE_VISIBILITY void pop_front() {__destruct_at_begin(__begin_+1);} - _LIBCPP_INLINE_VISIBILITY void pop_back() {__destruct_at_end(__end_-1);} - - void __construct_at_end(size_type __n); - void __construct_at_end(size_type __n, const_reference __x); - template - typename enable_if - < - __is_input_iterator<_InputIter>::value && - !__is_forward_iterator<_InputIter>::value, - void - >::type - __construct_at_end(_InputIter __first, _InputIter __last); - template - typename enable_if - < - __is_forward_iterator<_ForwardIterator>::value, - void - >::type - __construct_at_end(_ForwardIterator __first, _ForwardIterator __last); - - _LIBCPP_INLINE_VISIBILITY void __destruct_at_begin(pointer __new_begin) - {__destruct_at_begin(__new_begin, is_trivially_destructible());} - void __destruct_at_begin(pointer __new_begin, false_type); - void __destruct_at_begin(pointer __new_begin, true_type); - - _LIBCPP_INLINE_VISIBILITY - void __destruct_at_end(pointer __new_last) _NOEXCEPT - {__destruct_at_end(__new_last, false_type());} - _LIBCPP_INLINE_VISIBILITY - void __destruct_at_end(pointer __new_last, false_type) _NOEXCEPT; - _LIBCPP_INLINE_VISIBILITY - void __destruct_at_end(pointer __new_last, true_type) _NOEXCEPT; - - void swap(__split_buffer& __x) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value|| - __is_nothrow_swappable<__alloc_rr>::value); - - bool __invariants() const; - -private: - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__split_buffer& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value) - { - __alloc() = _VSTD::move(__c.__alloc()); - } - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__split_buffer&, false_type) _NOEXCEPT - {} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__alloc_rr& __x, __alloc_rr& __y) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value|| - __is_nothrow_swappable<__alloc_rr>::value) - {__swap_alloc(__x, __y, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__alloc_rr& __x, __alloc_rr& __y, true_type) - _NOEXCEPT_(__is_nothrow_swappable<__alloc_rr>::value) - { - using _VSTD::swap; - swap(__x, __y); - } - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__alloc_rr&, __alloc_rr&, false_type) _NOEXCEPT - {} -}; - -template -bool -__split_buffer<_Tp, _Allocator>::__invariants() const -{ - if (__first_ == nullptr) - { - if (__begin_ != nullptr) - return false; - if (__end_ != nullptr) - return false; - if (__end_cap() != nullptr) - return false; - } - else - { - if (__begin_ < __first_) - return false; - if (__end_ < __begin_) - return false; - if (__end_cap() < __end_) - return false; - } - return true; -} - -// Default constructs __n objects starting at __end_ -// throws if construction throws -// Precondition: __n > 0 -// Precondition: size() + __n <= capacity() -// Postcondition: size() == size() + __n -template -void -__split_buffer<_Tp, _Allocator>::__construct_at_end(size_type __n) -{ - __alloc_rr& __a = this->__alloc(); - do - { - __alloc_traits::construct(__a, _VSTD::__to_raw_pointer(this->__end_)); - ++this->__end_; - --__n; - } while (__n > 0); -} - -// Copy constructs __n objects starting at __end_ from __x -// throws if construction throws -// Precondition: __n > 0 -// Precondition: size() + __n <= capacity() -// Postcondition: size() == old size() + __n -// Postcondition: [i] == __x for all i in [size() - __n, __n) -template -void -__split_buffer<_Tp, _Allocator>::__construct_at_end(size_type __n, const_reference __x) -{ - __alloc_rr& __a = this->__alloc(); - do - { - __alloc_traits::construct(__a, _VSTD::__to_raw_pointer(this->__end_), __x); - ++this->__end_; - --__n; - } while (__n > 0); -} - -template -template -typename enable_if -< - __is_input_iterator<_InputIter>::value && - !__is_forward_iterator<_InputIter>::value, - void ->::type -__split_buffer<_Tp, _Allocator>::__construct_at_end(_InputIter __first, _InputIter __last) -{ - __alloc_rr& __a = this->__alloc(); - for (; __first != __last; ++__first) - { - if (__end_ == __end_cap()) - { - size_type __old_cap = __end_cap() - __first_; - size_type __new_cap = _VSTD::max(2 * __old_cap, 8); - __split_buffer __buf(__new_cap, 0, __a); - for (pointer __p = __begin_; __p != __end_; ++__p, ++__buf.__end_) - __alloc_traits::construct(__buf.__alloc(), - _VSTD::__to_raw_pointer(__buf.__end_), _VSTD::move(*__p)); - swap(__buf); - } - __alloc_traits::construct(__a, _VSTD::__to_raw_pointer(this->__end_), *__first); - ++this->__end_; - } -} - -template -template -typename enable_if -< - __is_forward_iterator<_ForwardIterator>::value, - void ->::type -__split_buffer<_Tp, _Allocator>::__construct_at_end(_ForwardIterator __first, _ForwardIterator __last) -{ - __alloc_rr& __a = this->__alloc(); - for (; __first != __last; ++__first) - { - __alloc_traits::construct(__a, _VSTD::__to_raw_pointer(this->__end_), *__first); - ++this->__end_; - } -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -__split_buffer<_Tp, _Allocator>::__destruct_at_begin(pointer __new_begin, false_type) -{ - while (__begin_ != __new_begin) - __alloc_traits::destroy(__alloc(), __begin_++); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -__split_buffer<_Tp, _Allocator>::__destruct_at_begin(pointer __new_begin, true_type) -{ - __begin_ = __new_begin; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -__split_buffer<_Tp, _Allocator>::__destruct_at_end(pointer __new_last, false_type) _NOEXCEPT -{ - while (__new_last != __end_) - __alloc_traits::destroy(__alloc(), --__end_); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -__split_buffer<_Tp, _Allocator>::__destruct_at_end(pointer __new_last, true_type) _NOEXCEPT -{ - __end_ = __new_last; -} - -template -__split_buffer<_Tp, _Allocator>::__split_buffer(size_type __cap, size_type __start, __alloc_rr& __a) - : __end_cap_(0, __a) -{ - __first_ = __cap != 0 ? __alloc_traits::allocate(__alloc(), __cap) : nullptr; - __begin_ = __end_ = __first_ + __start; - __end_cap() = __first_ + __cap; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -__split_buffer<_Tp, _Allocator>::__split_buffer() - _NOEXCEPT_(is_nothrow_default_constructible::value) - : __first_(0), __begin_(0), __end_(0), __end_cap_(0) -{ -} - -template -_LIBCPP_INLINE_VISIBILITY inline -__split_buffer<_Tp, _Allocator>::__split_buffer(__alloc_rr& __a) - : __first_(0), __begin_(0), __end_(0), __end_cap_(0, __a) -{ -} - -template -_LIBCPP_INLINE_VISIBILITY inline -__split_buffer<_Tp, _Allocator>::__split_buffer(const __alloc_rr& __a) - : __first_(0), __begin_(0), __end_(0), __end_cap_(0, __a) -{ -} - -template -__split_buffer<_Tp, _Allocator>::~__split_buffer() -{ - clear(); - if (__first_) - __alloc_traits::deallocate(__alloc(), __first_, capacity()); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__split_buffer<_Tp, _Allocator>::__split_buffer(__split_buffer&& __c) - _NOEXCEPT_(is_nothrow_move_constructible::value) - : __first_(_VSTD::move(__c.__first_)), - __begin_(_VSTD::move(__c.__begin_)), - __end_(_VSTD::move(__c.__end_)), - __end_cap_(_VSTD::move(__c.__end_cap_)) -{ - __c.__first_ = nullptr; - __c.__begin_ = nullptr; - __c.__end_ = nullptr; - __c.__end_cap() = nullptr; -} - -template -__split_buffer<_Tp, _Allocator>::__split_buffer(__split_buffer&& __c, const __alloc_rr& __a) - : __end_cap_(__a) -{ - if (__a == __c.__alloc()) - { - __first_ = __c.__first_; - __begin_ = __c.__begin_; - __end_ = __c.__end_; - __end_cap() = __c.__end_cap(); - __c.__first_ = nullptr; - __c.__begin_ = nullptr; - __c.__end_ = nullptr; - __c.__end_cap() = nullptr; - } - else - { - size_type __cap = __c.size(); - __first_ = __alloc_traits::allocate(__alloc(), __cap); - __begin_ = __end_ = __first_; - __end_cap() = __first_ + __cap; - typedef move_iterator _Ip; - __construct_at_end(_Ip(__c.begin()), _Ip(__c.end())); - } -} - -template -__split_buffer<_Tp, _Allocator>& -__split_buffer<_Tp, _Allocator>::operator=(__split_buffer&& __c) - _NOEXCEPT_((__alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value) || - !__alloc_traits::propagate_on_container_move_assignment::value) -{ - clear(); - shrink_to_fit(); - __first_ = __c.__first_; - __begin_ = __c.__begin_; - __end_ = __c.__end_; - __end_cap() = __c.__end_cap(); - __move_assign_alloc(__c, - integral_constant()); - __c.__first_ = __c.__begin_ = __c.__end_ = __c.__end_cap() = nullptr; - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__split_buffer<_Tp, _Allocator>::swap(__split_buffer& __x) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value|| - __is_nothrow_swappable<__alloc_rr>::value) -{ - _VSTD::swap(__first_, __x.__first_); - _VSTD::swap(__begin_, __x.__begin_); - _VSTD::swap(__end_, __x.__end_); - _VSTD::swap(__end_cap(), __x.__end_cap()); - __swap_alloc(__alloc(), __x.__alloc()); -} - -template -void -__split_buffer<_Tp, _Allocator>::reserve(size_type __n) -{ - if (__n < capacity()) - { - __split_buffer __t(__n, 0, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } -} - -template -void -__split_buffer<_Tp, _Allocator>::shrink_to_fit() _NOEXCEPT -{ - if (capacity() > size()) - { -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __split_buffer __t(size(), 0, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - __t.__end_ = __t.__begin_ + (__end_ - __begin_); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - } -#endif // _LIBCPP_NO_EXCEPTIONS - } -} - -template -void -__split_buffer<_Tp, _Allocator>::push_front(const_reference __x) -{ - if (__begin_ == __first_) - { - if (__end_ < __end_cap()) - { - difference_type __d = __end_cap() - __end_; - __d = (__d + 1) / 2; - __begin_ = _VSTD::move_backward(__begin_, __end_, __end_ + __d); - __end_ += __d; - } - else - { - size_type __c = max(2 * static_cast(__end_cap() - __first_), 1); - __split_buffer __t(__c, (__c + 3) / 4, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } - } - __alloc_traits::construct(__alloc(), _VSTD::__to_raw_pointer(__begin_-1), __x); - --__begin_; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__split_buffer<_Tp, _Allocator>::push_front(value_type&& __x) -{ - if (__begin_ == __first_) - { - if (__end_ < __end_cap()) - { - difference_type __d = __end_cap() - __end_; - __d = (__d + 1) / 2; - __begin_ = _VSTD::move_backward(__begin_, __end_, __end_ + __d); - __end_ += __d; - } - else - { - size_type __c = max(2 * static_cast(__end_cap() - __first_), 1); - __split_buffer __t(__c, (__c + 3) / 4, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } - } - __alloc_traits::construct(__alloc(), _VSTD::__to_raw_pointer(__begin_-1), - _VSTD::move(__x)); - --__begin_; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_LIBCPP_INLINE_VISIBILITY inline -void -__split_buffer<_Tp, _Allocator>::push_back(const_reference __x) -{ - if (__end_ == __end_cap()) - { - if (__begin_ > __first_) - { - difference_type __d = __begin_ - __first_; - __d = (__d + 1) / 2; - __end_ = _VSTD::move(__begin_, __end_, __begin_ - __d); - __begin_ -= __d; - } - else - { - size_type __c = max(2 * static_cast(__end_cap() - __first_), 1); - __split_buffer __t(__c, __c / 4, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } - } - __alloc_traits::construct(__alloc(), _VSTD::__to_raw_pointer(__end_), __x); - ++__end_; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__split_buffer<_Tp, _Allocator>::push_back(value_type&& __x) -{ - if (__end_ == __end_cap()) - { - if (__begin_ > __first_) - { - difference_type __d = __begin_ - __first_; - __d = (__d + 1) / 2; - __end_ = _VSTD::move(__begin_, __end_, __begin_ - __d); - __begin_ -= __d; - } - else - { - size_type __c = max(2 * static_cast(__end_cap() - __first_), 1); - __split_buffer __t(__c, __c / 4, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } - } - __alloc_traits::construct(__alloc(), _VSTD::__to_raw_pointer(__end_), - _VSTD::move(__x)); - ++__end_; -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -void -__split_buffer<_Tp, _Allocator>::emplace_back(_Args&&... __args) -{ - if (__end_ == __end_cap()) - { - if (__begin_ > __first_) - { - difference_type __d = __begin_ - __first_; - __d = (__d + 1) / 2; - __end_ = _VSTD::move(__begin_, __end_, __begin_ - __d); - __begin_ -= __d; - } - else - { - size_type __c = max(2 * static_cast(__end_cap() - __first_), 1); - __split_buffer __t(__c, __c / 4, __alloc()); - __t.__construct_at_end(move_iterator(__begin_), - move_iterator(__end_)); - _VSTD::swap(__first_, __t.__first_); - _VSTD::swap(__begin_, __t.__begin_); - _VSTD::swap(__end_, __t.__end_); - _VSTD::swap(__end_cap(), __t.__end_cap()); - } - } - __alloc_traits::construct(__alloc(), _VSTD::__to_raw_pointer(__end_), - _VSTD::forward<_Args>(__args)...); - ++__end_; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_LIBCPP_INLINE_VISIBILITY inline -void -swap(__split_buffer<_Tp, _Allocator>& __x, __split_buffer<_Tp, _Allocator>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_SPLIT_BUFFER diff --git a/libcxx/include/__sso_allocator b/libcxx/include/__sso_allocator deleted file mode 100644 index 7240072cafdf..000000000000 --- a/libcxx/include/__sso_allocator +++ /dev/null @@ -1,77 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___SSO_ALLOCATOR -#define _LIBCPP___SSO_ALLOCATOR - -#include <__config> -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class _LIBCPP_HIDDEN __sso_allocator; - -template -class _LIBCPP_HIDDEN __sso_allocator -{ -public: - typedef const void* const_pointer; - typedef void value_type; -}; - -template -class _LIBCPP_HIDDEN __sso_allocator -{ - typename aligned_storage::type buf_; - bool __allocated_; -public: - typedef size_t size_type; - typedef _Tp* pointer; - typedef _Tp value_type; - - _LIBCPP_INLINE_VISIBILITY __sso_allocator() throw() : __allocated_(false) {} - _LIBCPP_INLINE_VISIBILITY __sso_allocator(const __sso_allocator&) throw() : __allocated_(false) {} - template _LIBCPP_INLINE_VISIBILITY __sso_allocator(const __sso_allocator<_Up, _Np>&) throw() - : __allocated_(false) {} -private: - __sso_allocator& operator=(const __sso_allocator&); -public: - _LIBCPP_INLINE_VISIBILITY pointer allocate(size_type __n, typename __sso_allocator::const_pointer = 0) - { - if (!__allocated_ && __n <= _Np) - { - __allocated_ = true; - return (pointer)&buf_; - } - return static_cast(::operator new(__n * sizeof(_Tp))); - } - _LIBCPP_INLINE_VISIBILITY void deallocate(pointer __p, size_type) - { - if (__p == (pointer)&buf_) - __allocated_ = false; - else - ::operator delete(__p); - } - _LIBCPP_INLINE_VISIBILITY size_type max_size() const throw() {return size_type(~0) / sizeof(_Tp);} - - _LIBCPP_INLINE_VISIBILITY - bool operator==(__sso_allocator& __a) const {return &buf_ == &__a.buf_;} - _LIBCPP_INLINE_VISIBILITY - bool operator!=(__sso_allocator& __a) const {return &buf_ != &__a.buf_;} -}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___SSO_ALLOCATOR diff --git a/libcxx/include/__std_stream b/libcxx/include/__std_stream deleted file mode 100644 index e562e2c47304..000000000000 --- a/libcxx/include/__std_stream +++ /dev/null @@ -1,317 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___STD_STREAM -#define _LIBCPP___STD_STREAM - -#include <__config> -#include -#include -#include <__locale> -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -static const int __limit = 8; - -// __stdinbuf - -template -class _LIBCPP_HIDDEN __stdinbuf - : public basic_streambuf<_CharT, char_traits<_CharT> > -{ -public: - typedef _CharT char_type; - typedef char_traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - typedef typename traits_type::state_type state_type; - - explicit __stdinbuf(FILE* __fp); - -protected: - virtual int_type underflow(); - virtual int_type uflow(); - virtual int_type pbackfail(int_type __c = traits_type::eof()); - virtual void imbue(const locale& __loc); - -private: - - FILE* __file_; - const codecvt* __cv_; - state_type __st_; - int __encoding_; - bool __always_noconv_; - - __stdinbuf(const __stdinbuf&); - __stdinbuf& operator=(const __stdinbuf&); - - int_type __getchar(bool __consume); -}; - -template -__stdinbuf<_CharT>::__stdinbuf(FILE* __fp) - : __file_(__fp), - __st_() -{ - imbue(this->getloc()); -} - -template -void -__stdinbuf<_CharT>::imbue(const locale& __loc) -{ - __cv_ = &use_facet >(__loc); - __encoding_ = __cv_->encoding(); - __always_noconv_ = __cv_->always_noconv(); - if (__encoding_ > __limit) - __throw_runtime_error("unsupported locale for standard input"); -} - -template -typename __stdinbuf<_CharT>::int_type -__stdinbuf<_CharT>::underflow() -{ - return __getchar(false); -} - -template -typename __stdinbuf<_CharT>::int_type -__stdinbuf<_CharT>::uflow() -{ - return __getchar(true); -} - -template -typename __stdinbuf<_CharT>::int_type -__stdinbuf<_CharT>::__getchar(bool __consume) -{ - char __extbuf[__limit]; - int __nread = _VSTD::max(1, __encoding_); - for (int __i = 0; __i < __nread; ++__i) - { - int __c = getc(__file_); - if (__c == EOF) - return traits_type::eof(); - __extbuf[__i] = static_cast(__c); - } - char_type __1buf; - if (__always_noconv_) - __1buf = static_cast(__extbuf[0]); - else - { - const char* __enxt; - char_type* __inxt; - codecvt_base::result __r; - do - { - state_type __sv_st = __st_; - __r = __cv_->in(__st_, __extbuf, __extbuf + __nread, __enxt, - &__1buf, &__1buf + 1, __inxt); - switch (__r) - { - case _VSTD::codecvt_base::ok: - break; - case codecvt_base::partial: - __st_ = __sv_st; - if (__nread == sizeof(__extbuf)) - return traits_type::eof(); - { - int __c = getc(__file_); - if (__c == EOF) - return traits_type::eof(); - __extbuf[__nread] = static_cast(__c); - } - ++__nread; - break; - case codecvt_base::error: - return traits_type::eof(); - case _VSTD::codecvt_base::noconv: - __1buf = static_cast(__extbuf[0]); - break; - } - } while (__r == _VSTD::codecvt_base::partial); - } - if (!__consume) - { - for (int __i = __nread; __i > 0;) - { - if (ungetc(__extbuf[--__i], __file_) == EOF) - return traits_type::eof(); - } - } - return traits_type::to_int_type(__1buf); -} - -template -typename __stdinbuf<_CharT>::int_type -__stdinbuf<_CharT>::pbackfail(int_type __c) -{ - if (traits_type::eq_int_type(__c, traits_type::eof())) - return __c; - char __extbuf[__limit]; - char* __enxt; - const char_type __ci = traits_type::to_char_type(__c); - const char_type* __inxt; - switch (__cv_->out(__st_, &__ci, &__ci + 1, __inxt, - __extbuf, __extbuf + sizeof(__extbuf), __enxt)) - { - case _VSTD::codecvt_base::ok: - break; - case _VSTD::codecvt_base::noconv: - __extbuf[0] = static_cast(__c); - __enxt = __extbuf + 1; - break; - case codecvt_base::partial: - case codecvt_base::error: - return traits_type::eof(); - } - while (__enxt > __extbuf) - if (ungetc(*--__enxt, __file_) == EOF) - return traits_type::eof(); - return traits_type::not_eof(__c); -} - -// __stdoutbuf - -template -class _LIBCPP_HIDDEN __stdoutbuf - : public basic_streambuf<_CharT, char_traits<_CharT> > -{ -public: - typedef _CharT char_type; - typedef char_traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - typedef typename traits_type::state_type state_type; - - explicit __stdoutbuf(FILE* __fp); - -protected: - virtual int_type overflow (int_type __c = traits_type::eof()); - virtual int sync(); - virtual void imbue(const locale& __loc); - -private: - FILE* __file_; - const codecvt* __cv_; - state_type __st_; - bool __always_noconv_; - - __stdoutbuf(const __stdoutbuf&); - __stdoutbuf& operator=(const __stdoutbuf&); -}; - -template -__stdoutbuf<_CharT>::__stdoutbuf(FILE* __fp) - : __file_(__fp), - __cv_(&use_facet >(this->getloc())), - __st_(), - __always_noconv_(__cv_->always_noconv()) -{ -} - -template -typename __stdoutbuf<_CharT>::int_type -__stdoutbuf<_CharT>::overflow(int_type __c) -{ - char __extbuf[__limit]; - char_type __1buf; - if (!traits_type::eq_int_type(__c, traits_type::eof())) - { - this->setp(&__1buf, &__1buf+1); - *this->pptr() = traits_type::to_char_type(__c); - this->pbump(1); - if (__always_noconv_) - { - if (fwrite(this->pbase(), sizeof(char_type), 1, __file_) != 1) - return traits_type::eof(); - } - else - { - char* __extbe = __extbuf; - codecvt_base::result __r; - do - { - const char_type* __e; - __r = __cv_->out(__st_, this->pbase(), this->pptr(), __e, - __extbuf, - __extbuf + sizeof(__extbuf), - __extbe); - if (__e == this->pbase()) - return traits_type::eof(); - if (__r == codecvt_base::noconv) - { - if (fwrite(this->pbase(), 1, 1, __file_) != 1) - return traits_type::eof(); - } - else if (__r == codecvt_base::ok || __r == codecvt_base::partial) - { - size_t __nmemb = static_cast(__extbe - __extbuf); - if (fwrite(__extbuf, 1, __nmemb, __file_) != __nmemb) - return traits_type::eof(); - if (__r == codecvt_base::partial) - { - this->setp((char_type*)__e, this->pptr()); - this->pbump(static_cast(this->epptr() - this->pbase())); - } - } - else - return traits_type::eof(); - } while (__r == codecvt_base::partial); - } - this->setp(0, 0); - } - return traits_type::not_eof(__c); -} - -template -int -__stdoutbuf<_CharT>::sync() -{ - char __extbuf[__limit]; - codecvt_base::result __r; - do - { - char* __extbe; - __r = __cv_->unshift(__st_, __extbuf, - __extbuf + sizeof(__extbuf), - __extbe); - size_t __nmemb = static_cast(__extbe - __extbuf); - if (fwrite(__extbuf, 1, __nmemb, __file_) != __nmemb) - return -1; - } while (__r == codecvt_base::partial); - if (__r == codecvt_base::error) - return -1; - if (fflush(__file_)) - return -1; - return 0; -} - -template -void -__stdoutbuf<_CharT>::imbue(const locale& __loc) -{ - sync(); - __cv_ = &use_facet >(__loc); - __always_noconv_ = __cv_->always_noconv(); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___STD_STREAM diff --git a/libcxx/include/__tree b/libcxx/include/__tree deleted file mode 100644 index f57c80c850e2..000000000000 --- a/libcxx/include/__tree +++ /dev/null @@ -1,2293 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___TREE -#define _LIBCPP___TREE - -#include <__config> -#include -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class __tree; -template - class _LIBCPP_VISIBLE __tree_iterator; -template - class _LIBCPP_VISIBLE __tree_const_iterator; -template - class _LIBCPP_VISIBLE map; -template - class _LIBCPP_VISIBLE multimap; -template - class _LIBCPP_VISIBLE set; -template - class _LIBCPP_VISIBLE multiset; - -/* - -_NodePtr algorithms - -The algorithms taking _NodePtr are red black tree algorithms. Those -algorithms taking a parameter named __root should assume that __root -points to a proper red black tree (unless otherwise specified). - -Each algorithm herein assumes that __root->__parent_ points to a non-null -structure which has a member __left_ which points back to __root. No other -member is read or written to at __root->__parent_. - -__root->__parent_ will be referred to below (in comments only) as end_node. -end_node->__left_ is an externably accessible lvalue for __root, and can be -changed by node insertion and removal (without explicit reference to end_node). - -All nodes (with the exception of end_node), even the node referred to as -__root, have a non-null __parent_ field. - -*/ - -// Returns: true if __x is a left child of its parent, else false -// Precondition: __x != nullptr. -template -inline _LIBCPP_INLINE_VISIBILITY -bool -__tree_is_left_child(_NodePtr __x) _NOEXCEPT -{ - return __x == __x->__parent_->__left_; -} - -// Determintes if the subtree rooted at __x is a proper red black subtree. If -// __x is a proper subtree, returns the black height (null counts as 1). If -// __x is an improper subtree, returns 0. -template -unsigned -__tree_sub_invariant(_NodePtr __x) -{ - if (__x == nullptr) - return 1; - // parent consistency checked by caller - // check __x->__left_ consistency - if (__x->__left_ != nullptr && __x->__left_->__parent_ != __x) - return 0; - // check __x->__right_ consistency - if (__x->__right_ != nullptr && __x->__right_->__parent_ != __x) - return 0; - // check __x->__left_ != __x->__right_ unless both are nullptr - if (__x->__left_ == __x->__right_ && __x->__left_ != nullptr) - return 0; - // If this is red, neither child can be red - if (!__x->__is_black_) - { - if (__x->__left_ && !__x->__left_->__is_black_) - return 0; - if (__x->__right_ && !__x->__right_->__is_black_) - return 0; - } - unsigned __h = __tree_sub_invariant(__x->__left_); - if (__h == 0) - return 0; // invalid left subtree - if (__h != __tree_sub_invariant(__x->__right_)) - return 0; // invalid or different height right subtree - return __h + __x->__is_black_; // return black height of this node -} - -// Determintes if the red black tree rooted at __root is a proper red black tree. -// __root == nullptr is a proper tree. Returns true is __root is a proper -// red black tree, else returns false. -template -bool -__tree_invariant(_NodePtr __root) -{ - if (__root == nullptr) - return true; - // check __x->__parent_ consistency - if (__root->__parent_ == nullptr) - return false; - if (!__tree_is_left_child(__root)) - return false; - // root must be black - if (!__root->__is_black_) - return false; - // do normal node checks - return __tree_sub_invariant(__root) != 0; -} - -// Returns: pointer to the left-most node under __x. -// Precondition: __x != nullptr. -template -inline _LIBCPP_INLINE_VISIBILITY -_NodePtr -__tree_min(_NodePtr __x) _NOEXCEPT -{ - while (__x->__left_ != nullptr) - __x = __x->__left_; - return __x; -} - -// Returns: pointer to the right-most node under __x. -// Precondition: __x != nullptr. -template -inline _LIBCPP_INLINE_VISIBILITY -_NodePtr -__tree_max(_NodePtr __x) _NOEXCEPT -{ - while (__x->__right_ != nullptr) - __x = __x->__right_; - return __x; -} - -// Returns: pointer to the next in-order node after __x. -// Precondition: __x != nullptr. -template -_NodePtr -__tree_next(_NodePtr __x) _NOEXCEPT -{ - if (__x->__right_ != nullptr) - return __tree_min(__x->__right_); - while (!__tree_is_left_child(__x)) - __x = __x->__parent_; - return __x->__parent_; -} - -// Returns: pointer to the previous in-order node before __x. -// Precondition: __x != nullptr. -template -_NodePtr -__tree_prev(_NodePtr __x) _NOEXCEPT -{ - if (__x->__left_ != nullptr) - return __tree_max(__x->__left_); - while (__tree_is_left_child(__x)) - __x = __x->__parent_; - return __x->__parent_; -} - -// Returns: pointer to a node which has no children -// Precondition: __x != nullptr. -template -_NodePtr -__tree_leaf(_NodePtr __x) _NOEXCEPT -{ - while (true) - { - if (__x->__left_ != nullptr) - { - __x = __x->__left_; - continue; - } - if (__x->__right_ != nullptr) - { - __x = __x->__right_; - continue; - } - break; - } - return __x; -} - -// Effects: Makes __x->__right_ the subtree root with __x as its left child -// while preserving in-order order. -// Precondition: __x->__right_ != nullptr -template -void -__tree_left_rotate(_NodePtr __x) _NOEXCEPT -{ - _NodePtr __y = __x->__right_; - __x->__right_ = __y->__left_; - if (__x->__right_ != nullptr) - __x->__right_->__parent_ = __x; - __y->__parent_ = __x->__parent_; - if (__tree_is_left_child(__x)) - __x->__parent_->__left_ = __y; - else - __x->__parent_->__right_ = __y; - __y->__left_ = __x; - __x->__parent_ = __y; -} - -// Effects: Makes __x->__left_ the subtree root with __x as its right child -// while preserving in-order order. -// Precondition: __x->__left_ != nullptr -template -void -__tree_right_rotate(_NodePtr __x) _NOEXCEPT -{ - _NodePtr __y = __x->__left_; - __x->__left_ = __y->__right_; - if (__x->__left_ != nullptr) - __x->__left_->__parent_ = __x; - __y->__parent_ = __x->__parent_; - if (__tree_is_left_child(__x)) - __x->__parent_->__left_ = __y; - else - __x->__parent_->__right_ = __y; - __y->__right_ = __x; - __x->__parent_ = __y; -} - -// Effects: Rebalances __root after attaching __x to a leaf. -// Precondition: __root != nulptr && __x != nullptr. -// __x has no children. -// __x == __root or == a direct or indirect child of __root. -// If __x were to be unlinked from __root (setting __root to -// nullptr if __root == __x), __tree_invariant(__root) == true. -// Postcondition: __tree_invariant(end_node->__left_) == true. end_node->__left_ -// may be different than the value passed in as __root. -template -void -__tree_balance_after_insert(_NodePtr __root, _NodePtr __x) _NOEXCEPT -{ - __x->__is_black_ = __x == __root; - while (__x != __root && !__x->__parent_->__is_black_) - { - // __x->__parent_ != __root because __x->__parent_->__is_black == false - if (__tree_is_left_child(__x->__parent_)) - { - _NodePtr __y = __x->__parent_->__parent_->__right_; - if (__y != nullptr && !__y->__is_black_) - { - __x = __x->__parent_; - __x->__is_black_ = true; - __x = __x->__parent_; - __x->__is_black_ = __x == __root; - __y->__is_black_ = true; - } - else - { - if (!__tree_is_left_child(__x)) - { - __x = __x->__parent_; - __tree_left_rotate(__x); - } - __x = __x->__parent_; - __x->__is_black_ = true; - __x = __x->__parent_; - __x->__is_black_ = false; - __tree_right_rotate(__x); - break; - } - } - else - { - _NodePtr __y = __x->__parent_->__parent_->__left_; - if (__y != nullptr && !__y->__is_black_) - { - __x = __x->__parent_; - __x->__is_black_ = true; - __x = __x->__parent_; - __x->__is_black_ = __x == __root; - __y->__is_black_ = true; - } - else - { - if (__tree_is_left_child(__x)) - { - __x = __x->__parent_; - __tree_right_rotate(__x); - } - __x = __x->__parent_; - __x->__is_black_ = true; - __x = __x->__parent_; - __x->__is_black_ = false; - __tree_left_rotate(__x); - break; - } - } - } -} - -// Precondition: __root != nullptr && __z != nullptr. -// __tree_invariant(__root) == true. -// __z == __root or == a direct or indirect child of __root. -// Effects: unlinks __z from the tree rooted at __root, rebalancing as needed. -// Postcondition: __tree_invariant(end_node->__left_) == true && end_node->__left_ -// nor any of its children refer to __z. end_node->__left_ -// may be different than the value passed in as __root. -template -void -__tree_remove(_NodePtr __root, _NodePtr __z) _NOEXCEPT -{ - // __z will be removed from the tree. Client still needs to destruct/deallocate it - // __y is either __z, or if __z has two children, __tree_next(__z). - // __y will have at most one child. - // __y will be the initial hole in the tree (make the hole at a leaf) - _NodePtr __y = (__z->__left_ == nullptr || __z->__right_ == nullptr) ? - __z : __tree_next(__z); - // __x is __y's possibly null single child - _NodePtr __x = __y->__left_ != nullptr ? __y->__left_ : __y->__right_; - // __w is __x's possibly null uncle (will become __x's sibling) - _NodePtr __w = nullptr; - // link __x to __y's parent, and find __w - if (__x != nullptr) - __x->__parent_ = __y->__parent_; - if (__tree_is_left_child(__y)) - { - __y->__parent_->__left_ = __x; - if (__y != __root) - __w = __y->__parent_->__right_; - else - __root = __x; // __w == nullptr - } - else - { - __y->__parent_->__right_ = __x; - // __y can't be root if it is a right child - __w = __y->__parent_->__left_; - } - bool __removed_black = __y->__is_black_; - // If we didn't remove __z, do so now by splicing in __y for __z, - // but copy __z's color. This does not impact __x or __w. - if (__y != __z) - { - // __z->__left_ != nulptr but __z->__right_ might == __x == nullptr - __y->__parent_ = __z->__parent_; - if (__tree_is_left_child(__z)) - __y->__parent_->__left_ = __y; - else - __y->__parent_->__right_ = __y; - __y->__left_ = __z->__left_; - __y->__left_->__parent_ = __y; - __y->__right_ = __z->__right_; - if (__y->__right_ != nullptr) - __y->__right_->__parent_ = __y; - __y->__is_black_ = __z->__is_black_; - if (__root == __z) - __root = __y; - } - // There is no need to rebalance if we removed a red, or if we removed - // the last node. - if (__removed_black && __root != nullptr) - { - // Rebalance: - // __x has an implicit black color (transferred from the removed __y) - // associated with it, no matter what its color is. - // If __x is __root (in which case it can't be null), it is supposed - // to be black anyway, and if it is doubly black, then the double - // can just be ignored. - // If __x is red (in which case it can't be null), then it can absorb - // the implicit black just by setting its color to black. - // Since __y was black and only had one child (which __x points to), __x - // is either red with no children, else null, otherwise __y would have - // different black heights under left and right pointers. - // if (__x == __root || __x != nullptr && !__x->__is_black_) - if (__x != nullptr) - __x->__is_black_ = true; - else - { - // Else __x isn't root, and is "doubly black", even though it may - // be null. __w can not be null here, else the parent would - // see a black height >= 2 on the __x side and a black height - // of 1 on the __w side (__w must be a non-null black or a red - // with a non-null black child). - while (true) - { - if (!__tree_is_left_child(__w)) // if x is left child - { - if (!__w->__is_black_) - { - __w->__is_black_ = true; - __w->__parent_->__is_black_ = false; - __tree_left_rotate(__w->__parent_); - // __x is still valid - // reset __root only if necessary - if (__root == __w->__left_) - __root = __w; - // reset sibling, and it still can't be null - __w = __w->__left_->__right_; - } - // __w->__is_black_ is now true, __w may have null children - if ((__w->__left_ == nullptr || __w->__left_->__is_black_) && - (__w->__right_ == nullptr || __w->__right_->__is_black_)) - { - __w->__is_black_ = false; - __x = __w->__parent_; - // __x can no longer be null - if (__x == __root || !__x->__is_black_) - { - __x->__is_black_ = true; - break; - } - // reset sibling, and it still can't be null - __w = __tree_is_left_child(__x) ? - __x->__parent_->__right_ : - __x->__parent_->__left_; - // continue; - } - else // __w has a red child - { - if (__w->__right_ == nullptr || __w->__right_->__is_black_) - { - // __w left child is non-null and red - __w->__left_->__is_black_ = true; - __w->__is_black_ = false; - __tree_right_rotate(__w); - // __w is known not to be root, so root hasn't changed - // reset sibling, and it still can't be null - __w = __w->__parent_; - } - // __w has a right red child, left child may be null - __w->__is_black_ = __w->__parent_->__is_black_; - __w->__parent_->__is_black_ = true; - __w->__right_->__is_black_ = true; - __tree_left_rotate(__w->__parent_); - break; - } - } - else - { - if (!__w->__is_black_) - { - __w->__is_black_ = true; - __w->__parent_->__is_black_ = false; - __tree_right_rotate(__w->__parent_); - // __x is still valid - // reset __root only if necessary - if (__root == __w->__right_) - __root = __w; - // reset sibling, and it still can't be null - __w = __w->__right_->__left_; - } - // __w->__is_black_ is now true, __w may have null children - if ((__w->__left_ == nullptr || __w->__left_->__is_black_) && - (__w->__right_ == nullptr || __w->__right_->__is_black_)) - { - __w->__is_black_ = false; - __x = __w->__parent_; - // __x can no longer be null - if (!__x->__is_black_ || __x == __root) - { - __x->__is_black_ = true; - break; - } - // reset sibling, and it still can't be null - __w = __tree_is_left_child(__x) ? - __x->__parent_->__right_ : - __x->__parent_->__left_; - // continue; - } - else // __w has a red child - { - if (__w->__left_ == nullptr || __w->__left_->__is_black_) - { - // __w right child is non-null and red - __w->__right_->__is_black_ = true; - __w->__is_black_ = false; - __tree_left_rotate(__w); - // __w is known not to be root, so root hasn't changed - // reset sibling, and it still can't be null - __w = __w->__parent_; - } - // __w has a left red child, right child may be null - __w->__is_black_ = __w->__parent_->__is_black_; - __w->__parent_->__is_black_ = true; - __w->__left_->__is_black_ = true; - __tree_right_rotate(__w->__parent_); - break; - } - } - } - } - } -} - -template class __map_node_destructor; - -template -class __tree_node_destructor -{ - typedef _Allocator allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::value_type::value_type value_type; -public: - typedef typename __alloc_traits::pointer pointer; -private: - - allocator_type& __na_; - - __tree_node_destructor& operator=(const __tree_node_destructor&); - -public: - bool __value_constructed; - - _LIBCPP_INLINE_VISIBILITY - explicit __tree_node_destructor(allocator_type& __na) _NOEXCEPT - : __na_(__na), - __value_constructed(false) - {} - - _LIBCPP_INLINE_VISIBILITY - void operator()(pointer __p) _NOEXCEPT - { - if (__value_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_)); - if (__p) - __alloc_traits::deallocate(__na_, __p, 1); - } - - template friend class __map_node_destructor; -}; - -// node - -template -class __tree_end_node -{ -public: - typedef _Pointer pointer; - pointer __left_; - - _LIBCPP_INLINE_VISIBILITY - __tree_end_node() _NOEXCEPT : __left_() {} -}; - -template -class __tree_node_base - : public __tree_end_node - < - typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__tree_node_base<_VoidPtr> > -#else - rebind<__tree_node_base<_VoidPtr> >::other -#endif - > -{ - __tree_node_base(const __tree_node_base&); - __tree_node_base& operator=(const __tree_node_base&); -public: - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__tree_node_base> -#else - rebind<__tree_node_base>::other -#endif - pointer; - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - const_pointer; - typedef __tree_end_node base; - - pointer __right_; - pointer __parent_; - bool __is_black_; - - _LIBCPP_INLINE_VISIBILITY - __tree_node_base() _NOEXCEPT - : __right_(), __parent_(), __is_black_(false) {} -}; - -template -class __tree_node - : public __tree_node_base<_VoidPtr> -{ -public: - typedef __tree_node_base<_VoidPtr> base; - typedef _Tp value_type; - - value_type __value_; - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - template - _LIBCPP_INLINE_VISIBILITY - explicit __tree_node(_Args&& ...__args) - : __value_(_VSTD::forward<_Args>(__args)...) {} -#else // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - _LIBCPP_INLINE_VISIBILITY - explicit __tree_node(const value_type& __v) - : __value_(__v) {} -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) -}; - -template class __map_iterator; -template class __map_const_iterator; - -template -class _LIBCPP_VISIBLE __tree_iterator -{ - typedef _NodePtr __node_pointer; - typedef typename pointer_traits<__node_pointer>::element_type __node; - typedef typename __node::base __node_base; - typedef typename __node_base::pointer __node_base_pointer; - - __node_pointer __ptr_; - - typedef pointer_traits<__node_pointer> __pointer_traits; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef _Tp value_type; - typedef _DiffType difference_type; - typedef value_type& reference; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __tree_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY reference operator*() const {return __ptr_->__value_;} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return &__ptr_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __tree_iterator& operator++() - {__ptr_ = static_cast<__node_pointer>(__tree_next(static_cast<__node_base_pointer>(__ptr_))); - return *this;} - _LIBCPP_INLINE_VISIBILITY - __tree_iterator operator++(int) - {__tree_iterator __t(*this); ++(*this); return __t;} - - _LIBCPP_INLINE_VISIBILITY - __tree_iterator& operator--() - {__ptr_ = static_cast<__node_pointer>(__tree_prev(static_cast<__node_base_pointer>(__ptr_))); - return *this;} - _LIBCPP_INLINE_VISIBILITY - __tree_iterator operator--(int) - {__tree_iterator __t(*this); --(*this); return __t;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __tree_iterator& __x, const __tree_iterator& __y) - {return __x.__ptr_ == __y.__ptr_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __tree_iterator& __x, const __tree_iterator& __y) - {return !(__x == __y);} - -private: - _LIBCPP_INLINE_VISIBILITY - explicit __tree_iterator(__node_pointer __p) _NOEXCEPT : __ptr_(__p) {} - template friend class __tree; - template friend class _LIBCPP_VISIBLE __tree_const_iterator; - template friend class _LIBCPP_VISIBLE __map_iterator; - template friend class _LIBCPP_VISIBLE map; - template friend class _LIBCPP_VISIBLE multimap; - template friend class _LIBCPP_VISIBLE set; - template friend class _LIBCPP_VISIBLE multiset; -}; - -template -class _LIBCPP_VISIBLE __tree_const_iterator -{ - typedef _ConstNodePtr __node_pointer; - typedef typename pointer_traits<__node_pointer>::element_type __node; - typedef const typename __node::base __node_base; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__node_base> -#else - rebind<__node_base>::other -#endif - __node_base_pointer; - - __node_pointer __ptr_; - - typedef pointer_traits<__node_pointer> __pointer_traits; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef _Tp value_type; - typedef _DiffType difference_type; - typedef const value_type& reference; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __tree_const_iterator() {} -private: - typedef typename remove_const<__node>::type __non_const_node; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__non_const_node> -#else - rebind<__non_const_node>::other -#endif - __non_const_node_pointer; - typedef __tree_iterator - __non_const_iterator; -public: - _LIBCPP_INLINE_VISIBILITY - __tree_const_iterator(__non_const_iterator __p) _NOEXCEPT - : __ptr_(__p.__ptr_) {} - - _LIBCPP_INLINE_VISIBILITY reference operator*() const {return __ptr_->__value_;} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return &__ptr_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __tree_const_iterator& operator++() - {__ptr_ = static_cast<__node_pointer>(__tree_next(static_cast<__node_base_pointer>(__ptr_))); - return *this;} - _LIBCPP_INLINE_VISIBILITY - __tree_const_iterator operator++(int) - {__tree_const_iterator __t(*this); ++(*this); return __t;} - - _LIBCPP_INLINE_VISIBILITY - __tree_const_iterator& operator--() - {__ptr_ = static_cast<__node_pointer>(__tree_prev(static_cast<__node_base_pointer>(__ptr_))); - return *this;} - _LIBCPP_INLINE_VISIBILITY - __tree_const_iterator operator--(int) - {__tree_const_iterator __t(*this); --(*this); return __t;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __tree_const_iterator& __x, const __tree_const_iterator& __y) - {return __x.__ptr_ == __y.__ptr_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __tree_const_iterator& __x, const __tree_const_iterator& __y) - {return !(__x == __y);} - -private: - _LIBCPP_INLINE_VISIBILITY - explicit __tree_const_iterator(__node_pointer __p) _NOEXCEPT - : __ptr_(__p) {} - template friend class __tree; - template friend class _LIBCPP_VISIBLE map; - template friend class _LIBCPP_VISIBLE multimap; - template friend class _LIBCPP_VISIBLE set; - template friend class _LIBCPP_VISIBLE multiset; - template friend class _LIBCPP_VISIBLE __map_const_iterator; -}; - -template -class __tree -{ -public: - typedef _Tp value_type; - typedef _Compare value_compare; - typedef _Allocator allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - - typedef __tree_node __node; - typedef __tree_node_base __node_base; - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__node> -#else - rebind_alloc<__node>::other -#endif - __node_allocator; - typedef allocator_traits<__node_allocator> __node_traits; - typedef typename __node_traits::pointer __node_pointer; - typedef typename __node_traits::const_pointer __node_const_pointer; - typedef typename __node_base::pointer __node_base_pointer; - typedef typename __node_base::const_pointer __node_base_const_pointer; -private: - typedef typename __node_base::base __end_node_t; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__end_node_t> -#else - rebind<__end_node_t>::other -#endif - __end_node_ptr; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - __end_node_const_ptr; - - __node_pointer __begin_node_; - __compressed_pair<__end_node_t, __node_allocator> __pair1_; - __compressed_pair __pair3_; - -public: - _LIBCPP_INLINE_VISIBILITY - __node_pointer __end_node() _NOEXCEPT - { - return static_cast<__node_pointer> - ( - pointer_traits<__end_node_ptr>::pointer_to(__pair1_.first()) - ); - } - _LIBCPP_INLINE_VISIBILITY - __node_const_pointer __end_node() const _NOEXCEPT - { - return static_cast<__node_const_pointer> - ( - pointer_traits<__end_node_const_ptr>::pointer_to(__pair1_.first()) - ); - } - _LIBCPP_INLINE_VISIBILITY - __node_allocator& __node_alloc() _NOEXCEPT {return __pair1_.second();} -private: - _LIBCPP_INLINE_VISIBILITY - const __node_allocator& __node_alloc() const _NOEXCEPT - {return __pair1_.second();} - _LIBCPP_INLINE_VISIBILITY - __node_pointer& __begin_node() _NOEXCEPT {return __begin_node_;} - _LIBCPP_INLINE_VISIBILITY - const __node_pointer& __begin_node() const _NOEXCEPT {return __begin_node_;} -public: - _LIBCPP_INLINE_VISIBILITY - allocator_type __alloc() const _NOEXCEPT - {return allocator_type(__node_alloc());} -private: - _LIBCPP_INLINE_VISIBILITY - size_type& size() _NOEXCEPT {return __pair3_.first();} -public: - _LIBCPP_INLINE_VISIBILITY - const size_type& size() const _NOEXCEPT {return __pair3_.first();} - _LIBCPP_INLINE_VISIBILITY - value_compare& value_comp() _NOEXCEPT {return __pair3_.second();} - _LIBCPP_INLINE_VISIBILITY - const value_compare& value_comp() const _NOEXCEPT - {return __pair3_.second();} -public: - _LIBCPP_INLINE_VISIBILITY - __node_pointer __root() _NOEXCEPT - {return static_cast<__node_pointer> (__end_node()->__left_);} - _LIBCPP_INLINE_VISIBILITY - __node_const_pointer __root() const _NOEXCEPT - {return static_cast<__node_const_pointer>(__end_node()->__left_);} - - typedef __tree_iterator iterator; - typedef __tree_const_iterator const_iterator; - - explicit __tree(const value_compare& __comp) - _NOEXCEPT_( - is_nothrow_default_constructible<__node_allocator>::value && - is_nothrow_copy_constructible::value); - explicit __tree(const allocator_type& __a); - __tree(const value_compare& __comp, const allocator_type& __a); - __tree(const __tree& __t); - __tree& operator=(const __tree& __t); - template - void __assign_unique(_InputIterator __first, _InputIterator __last); - template - void __assign_multi(_InputIterator __first, _InputIterator __last); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __tree(__tree&& __t) - _NOEXCEPT_( - is_nothrow_move_constructible<__node_allocator>::value && - is_nothrow_move_constructible::value); - __tree(__tree&& __t, const allocator_type& __a); - __tree& operator=(__tree&& __t) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable<__node_allocator>::value); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - ~__tree(); - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return iterator(__begin_node());} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return const_iterator(__begin_node());} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return iterator(__end_node());} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return const_iterator(__end_node());} - - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT - {return __node_traits::max_size(__node_alloc());} - - void clear() _NOEXCEPT; - - void swap(__tree& __t) - _NOEXCEPT_( - __is_nothrow_swappable::value && - (!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value)); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - template - pair - __emplace_unique(_Args&&... __args); - template - iterator - __emplace_multi(_Args&&... __args); - - template - iterator - __emplace_hint_unique(const_iterator __p, _Args&&... __args); - template - iterator - __emplace_hint_multi(const_iterator __p, _Args&&... __args); -#endif // _LIBCPP_HAS_NO_VARIADICS - - template - pair __insert_unique(_Vp&& __v); - template - iterator __insert_unique(const_iterator __p, _Vp&& __v); - template - iterator __insert_multi(_Vp&& __v); - template - iterator __insert_multi(const_iterator __p, _Vp&& __v); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - pair __insert_unique(const value_type& __v); - iterator __insert_unique(const_iterator __p, const value_type& __v); - iterator __insert_multi(const value_type& __v); - iterator __insert_multi(const_iterator __p, const value_type& __v); - - pair __node_insert_unique(__node_pointer __nd); - iterator __node_insert_unique(const_iterator __p, - __node_pointer __nd); - - iterator __node_insert_multi(__node_pointer __nd); - iterator __node_insert_multi(const_iterator __p, __node_pointer __nd); - - iterator erase(const_iterator __p); - iterator erase(const_iterator __f, const_iterator __l); - template - size_type __erase_unique(const _Key& __k); - template - size_type __erase_multi(const _Key& __k); - - void __insert_node_at(__node_base_pointer __parent, - __node_base_pointer& __child, - __node_base_pointer __new_node); - - template - iterator find(const _Key& __v); - template - const_iterator find(const _Key& __v) const; - - template - size_type __count_unique(const _Key& __k) const; - template - size_type __count_multi(const _Key& __k) const; - - template - _LIBCPP_INLINE_VISIBILITY - iterator lower_bound(const _Key& __v) - {return __lower_bound(__v, __root(), __end_node());} - template - iterator __lower_bound(const _Key& __v, - __node_pointer __root, - __node_pointer __result); - template - _LIBCPP_INLINE_VISIBILITY - const_iterator lower_bound(const _Key& __v) const - {return __lower_bound(__v, __root(), __end_node());} - template - const_iterator __lower_bound(const _Key& __v, - __node_const_pointer __root, - __node_const_pointer __result) const; - template - _LIBCPP_INLINE_VISIBILITY - iterator upper_bound(const _Key& __v) - {return __upper_bound(__v, __root(), __end_node());} - template - iterator __upper_bound(const _Key& __v, - __node_pointer __root, - __node_pointer __result); - template - _LIBCPP_INLINE_VISIBILITY - const_iterator upper_bound(const _Key& __v) const - {return __upper_bound(__v, __root(), __end_node());} - template - const_iterator __upper_bound(const _Key& __v, - __node_const_pointer __root, - __node_const_pointer __result) const; - template - pair - __equal_range_unique(const _Key& __k); - template - pair - __equal_range_unique(const _Key& __k) const; - - template - pair - __equal_range_multi(const _Key& __k); - template - pair - __equal_range_multi(const _Key& __k) const; - - typedef __tree_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - - __node_holder remove(const_iterator __p) _NOEXCEPT; -private: - typename __node_base::pointer& - __find_leaf_low(typename __node_base::pointer& __parent, const value_type& __v); - typename __node_base::pointer& - __find_leaf_high(typename __node_base::pointer& __parent, const value_type& __v); - typename __node_base::pointer& - __find_leaf(const_iterator __hint, - typename __node_base::pointer& __parent, const value_type& __v); - template - typename __node_base::pointer& - __find_equal(typename __node_base::pointer& __parent, const _Key& __v); - template - typename __node_base::pointer& - __find_equal(const_iterator __hint, typename __node_base::pointer& __parent, - const _Key& __v); - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - template - __node_holder __construct_node(_Args&& ...__args); -#else // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - __node_holder __construct_node(const value_type& __v); -#endif - - void destroy(__node_pointer __nd) _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __tree& __t) - {__copy_assign_alloc(__t, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __tree& __t, true_type) - {__node_alloc() = __t.__node_alloc();} - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __tree& __t, false_type) {} - - void __move_assign(__tree& __t, false_type); - void __move_assign(__tree& __t, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value && - is_nothrow_move_assignable<__node_allocator>::value); - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__tree& __t) - _NOEXCEPT_( - !__node_traits::propagate_on_container_move_assignment::value || - is_nothrow_move_assignable<__node_allocator>::value) - {__move_assign_alloc(__t, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__tree& __t, true_type) - _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value) - {__node_alloc() = _VSTD::move(__t.__node_alloc());} - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__tree& __t, false_type) _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y) - _NOEXCEPT_( - !__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) - {__swap_alloc(__x, __y, integral_constant());} - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, true_type) - _NOEXCEPT_(__is_nothrow_swappable<__node_allocator>::value) - { - using _VSTD::swap; - swap(__x, __y); - } - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, false_type) - _NOEXCEPT - {} - - __node_pointer __detach(); - static __node_pointer __detach(__node_pointer); -}; - -template -__tree<_Tp, _Compare, _Allocator>::__tree(const value_compare& __comp) - _NOEXCEPT_( - is_nothrow_default_constructible<__node_allocator>::value && - is_nothrow_copy_constructible::value) - : __pair3_(0, __comp) -{ - __begin_node() = __end_node(); -} - -template -__tree<_Tp, _Compare, _Allocator>::__tree(const allocator_type& __a) - : __pair1_(__node_allocator(__a)), - __begin_node_(__node_pointer()), - __pair3_(0) -{ - __begin_node() = __end_node(); -} - -template -__tree<_Tp, _Compare, _Allocator>::__tree(const value_compare& __comp, - const allocator_type& __a) - : __pair1_(__node_allocator(__a)), - __begin_node_(__node_pointer()), - __pair3_(0, __comp) -{ - __begin_node() = __end_node(); -} - -// Precondition: size() != 0 -template -typename __tree<_Tp, _Compare, _Allocator>::__node_pointer -__tree<_Tp, _Compare, _Allocator>::__detach() -{ - __node_pointer __cache = __begin_node(); - __begin_node() = __end_node(); - __end_node()->__left_->__parent_ = nullptr; - __end_node()->__left_ = nullptr; - size() = 0; - // __cache->__left_ == nullptr - if (__cache->__right_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__right_); - // __cache->__left_ == nullptr - // __cache->__right_ == nullptr - return __cache; -} - -// Precondition: __cache != nullptr -// __cache->left_ == nullptr -// __cache->right_ == nullptr -// This is no longer a red-black tree -template -typename __tree<_Tp, _Compare, _Allocator>::__node_pointer -__tree<_Tp, _Compare, _Allocator>::__detach(__node_pointer __cache) -{ - if (__cache->__parent_ == nullptr) - return nullptr; - if (__tree_is_left_child(__cache)) - { - __cache->__parent_->__left_ = nullptr; - __cache = static_cast<__node_pointer>(__cache->__parent_); - if (__cache->__right_ == nullptr) - return __cache; - return static_cast<__node_pointer>(__tree_leaf(__cache->__right_)); - } - // __cache is right child - __cache->__parent_->__right_ = nullptr; - __cache = static_cast<__node_pointer>(__cache->__parent_); - if (__cache->__left_ == nullptr) - return __cache; - return static_cast<__node_pointer>(__tree_leaf(__cache->__left_)); -} - -template -__tree<_Tp, _Compare, _Allocator>& -__tree<_Tp, _Compare, _Allocator>::operator=(const __tree& __t) -{ - if (this != &__t) - { - value_comp() = __t.value_comp(); - __copy_assign_alloc(__t); - __assign_multi(__t.begin(), __t.end()); - } - return *this; -} - -template -template -void -__tree<_Tp, _Compare, _Allocator>::__assign_unique(_InputIterator __first, _InputIterator __last) -{ - if (size() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __cache != nullptr && __first != __last; ++__first) - { - __cache->__value_ = *__first; - __node_pointer __next = __detach(__cache); - __node_insert_unique(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - if (__cache != nullptr) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - } - } - for (; __first != __last; ++__first) - __insert_unique(*__first); -} - -template -template -void -__tree<_Tp, _Compare, _Allocator>::__assign_multi(_InputIterator __first, _InputIterator __last) -{ - if (size() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __cache != nullptr && __first != __last; ++__first) - { - __cache->__value_ = *__first; - __node_pointer __next = __detach(__cache); - __node_insert_multi(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - if (__cache != nullptr) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - } - } - for (; __first != __last; ++__first) - __insert_multi(*__first); -} - -template -__tree<_Tp, _Compare, _Allocator>::__tree(const __tree& __t) - : __begin_node_(__node_pointer()), - __pair1_(__node_traits::select_on_container_copy_construction(__t.__node_alloc())), - __pair3_(0, __t.value_comp()) -{ - __begin_node() = __end_node(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__tree<_Tp, _Compare, _Allocator>::__tree(__tree&& __t) - _NOEXCEPT_( - is_nothrow_move_constructible<__node_allocator>::value && - is_nothrow_move_constructible::value) - : __begin_node_(_VSTD::move(__t.__begin_node_)), - __pair1_(_VSTD::move(__t.__pair1_)), - __pair3_(_VSTD::move(__t.__pair3_)) -{ - if (size() == 0) - __begin_node() = __end_node(); - else - { - __end_node()->__left_->__parent_ = __end_node(); - __t.__begin_node() = __t.__end_node(); - __t.__end_node()->__left_ = nullptr; - __t.size() = 0; - } -} - -template -__tree<_Tp, _Compare, _Allocator>::__tree(__tree&& __t, const allocator_type& __a) - : __pair1_(__node_allocator(__a)), - __pair3_(0, _VSTD::move(__t.value_comp())) -{ - if (__a == __t.__alloc()) - { - if (__t.size() == 0) - __begin_node() = __end_node(); - else - { - __begin_node() = __t.__begin_node(); - __end_node()->__left_ = __t.__end_node()->__left_; - __end_node()->__left_->__parent_ = __end_node(); - size() = __t.size(); - __t.__begin_node() = __t.__end_node(); - __t.__end_node()->__left_ = nullptr; - __t.size() = 0; - } - } - else - { - __begin_node() = __end_node(); - } -} - -template -void -__tree<_Tp, _Compare, _Allocator>::__move_assign(__tree& __t, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value && - is_nothrow_move_assignable<__node_allocator>::value) -{ - destroy(static_cast<__node_pointer>(__end_node()->__left_)); - __begin_node_ = __t.__begin_node_; - __pair1_.first() = __t.__pair1_.first(); - __move_assign_alloc(__t); - __pair3_ = _VSTD::move(__t.__pair3_); - if (size() == 0) - __begin_node() = __end_node(); - else - { - __end_node()->__left_->__parent_ = __end_node(); - __t.__begin_node() = __t.__end_node(); - __t.__end_node()->__left_ = nullptr; - __t.size() = 0; - } -} - -template -void -__tree<_Tp, _Compare, _Allocator>::__move_assign(__tree& __t, false_type) -{ - if (__node_alloc() == __t.__node_alloc()) - __move_assign(__t, true_type()); - else - { - value_comp() = _VSTD::move(__t.value_comp()); - const_iterator __e = end(); - if (size() != 0) - { - __node_pointer __cache = __detach(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - while (__cache != nullptr && __t.size() != 0) - { - __cache->__value_ = _VSTD::move(__t.remove(__t.begin())->__value_); - __node_pointer __next = __detach(__cache); - __node_insert_multi(__cache); - __cache = __next; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - if (__cache != nullptr) - { - while (__cache->__parent_ != nullptr) - __cache = static_cast<__node_pointer>(__cache->__parent_); - destroy(__cache); - } - } - while (__t.size() != 0) - __insert_multi(__e, _VSTD::move(__t.remove(__t.begin())->__value_)); - } -} - -template -__tree<_Tp, _Compare, _Allocator>& -__tree<_Tp, _Compare, _Allocator>::operator=(__tree&& __t) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable<__node_allocator>::value) - -{ - __move_assign(__t, integral_constant()); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__tree<_Tp, _Compare, _Allocator>::~__tree() -{ - destroy(__root()); -} - -template -void -__tree<_Tp, _Compare, _Allocator>::destroy(__node_pointer __nd) _NOEXCEPT -{ - if (__nd != nullptr) - { - destroy(static_cast<__node_pointer>(__nd->__left_)); - destroy(static_cast<__node_pointer>(__nd->__right_)); - __node_allocator& __na = __node_alloc(); - __node_traits::destroy(__na, _VSTD::addressof(__nd->__value_)); - __node_traits::deallocate(__na, __nd, 1); - } -} - -template -void -__tree<_Tp, _Compare, _Allocator>::swap(__tree& __t) - _NOEXCEPT_( - __is_nothrow_swappable::value && - (!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value)) -{ - using _VSTD::swap; - swap(__begin_node_, __t.__begin_node_); - swap(__pair1_.first(), __t.__pair1_.first()); - __swap_alloc(__node_alloc(), __t.__node_alloc()); - __pair3_.swap(__t.__pair3_); - if (size() == 0) - __begin_node() = __end_node(); - else - __end_node()->__left_->__parent_ = __end_node(); - if (__t.size() == 0) - __t.__begin_node() = __t.__end_node(); - else - __t.__end_node()->__left_->__parent_ = __t.__end_node(); -} - -template -void -__tree<_Tp, _Compare, _Allocator>::clear() _NOEXCEPT -{ - destroy(__root()); - size() = 0; - __begin_node() = __end_node(); - __end_node()->__left_ = nullptr; -} - -// Find lower_bound place to insert -// Set __parent to parent of null leaf -// Return reference to null leaf -template -typename __tree<_Tp, _Compare, _Allocator>::__node_base::pointer& -__tree<_Tp, _Compare, _Allocator>::__find_leaf_low(typename __node_base::pointer& __parent, - const value_type& __v) -{ - __node_pointer __nd = __root(); - if (__nd != nullptr) - { - while (true) - { - if (value_comp()(__nd->__value_, __v)) - { - if (__nd->__right_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__right_); - else - { - __parent = __nd; - return __parent->__right_; - } - } - else - { - if (__nd->__left_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__left_); - else - { - __parent = __nd; - return __parent->__left_; - } - } - } - } - __parent = __end_node(); - return __parent->__left_; -} - -// Find upper_bound place to insert -// Set __parent to parent of null leaf -// Return reference to null leaf -template -typename __tree<_Tp, _Compare, _Allocator>::__node_base::pointer& -__tree<_Tp, _Compare, _Allocator>::__find_leaf_high(typename __node_base::pointer& __parent, - const value_type& __v) -{ - __node_pointer __nd = __root(); - if (__nd != nullptr) - { - while (true) - { - if (value_comp()(__v, __nd->__value_)) - { - if (__nd->__left_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__left_); - else - { - __parent = __nd; - return __parent->__left_; - } - } - else - { - if (__nd->__right_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__right_); - else - { - __parent = __nd; - return __parent->__right_; - } - } - } - } - __parent = __end_node(); - return __parent->__left_; -} - -// Find leaf place to insert closest to __hint -// First check prior to __hint. -// Next check after __hint. -// Next do O(log N) search. -// Set __parent to parent of null leaf -// Return reference to null leaf -template -typename __tree<_Tp, _Compare, _Allocator>::__node_base::pointer& -__tree<_Tp, _Compare, _Allocator>::__find_leaf(const_iterator __hint, - typename __node_base::pointer& __parent, - const value_type& __v) -{ - if (__hint == end() || !value_comp()(*__hint, __v)) // check before - { - // __v <= *__hint - const_iterator __prior = __hint; - if (__prior == begin() || !value_comp()(__v, *--__prior)) - { - // *prev(__hint) <= __v <= *__hint - if (__hint.__ptr_->__left_ == nullptr) - { - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent->__left_; - } - else - { - __parent = const_cast<__node_pointer&>(__prior.__ptr_); - return __parent->__right_; - } - } - // __v < *prev(__hint) - return __find_leaf_high(__parent, __v); - } - // else __v > *__hint - return __find_leaf_low(__parent, __v); -} - -// Find place to insert if __v doesn't exist -// Set __parent to parent of null leaf -// Return reference to null leaf -// If __v exists, set parent to node of __v and return reference to node of __v -template -template -typename __tree<_Tp, _Compare, _Allocator>::__node_base::pointer& -__tree<_Tp, _Compare, _Allocator>::__find_equal(typename __node_base::pointer& __parent, - const _Key& __v) -{ - __node_pointer __nd = __root(); - if (__nd != nullptr) - { - while (true) - { - if (value_comp()(__v, __nd->__value_)) - { - if (__nd->__left_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__left_); - else - { - __parent = __nd; - return __parent->__left_; - } - } - else if (value_comp()(__nd->__value_, __v)) - { - if (__nd->__right_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__right_); - else - { - __parent = __nd; - return __parent->__right_; - } - } - else - { - __parent = __nd; - return __parent; - } - } - } - __parent = __end_node(); - return __parent->__left_; -} - -// Find place to insert if __v doesn't exist -// First check prior to __hint. -// Next check after __hint. -// Next do O(log N) search. -// Set __parent to parent of null leaf -// Return reference to null leaf -// If __v exists, set parent to node of __v and return reference to node of __v -template -template -typename __tree<_Tp, _Compare, _Allocator>::__node_base::pointer& -__tree<_Tp, _Compare, _Allocator>::__find_equal(const_iterator __hint, - typename __node_base::pointer& __parent, - const _Key& __v) -{ - if (__hint == end() || value_comp()(__v, *__hint)) // check before - { - // __v < *__hint - const_iterator __prior = __hint; - if (__prior == begin() || value_comp()(*--__prior, __v)) - { - // *prev(__hint) < __v < *__hint - if (__hint.__ptr_->__left_ == nullptr) - { - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent->__left_; - } - else - { - __parent = const_cast<__node_pointer&>(__prior.__ptr_); - return __parent->__right_; - } - } - // __v <= *prev(__hint) - return __find_equal(__parent, __v); - } - else if (value_comp()(*__hint, __v)) // check after - { - // *__hint < __v - const_iterator __next = _VSTD::next(__hint); - if (__next == end() || value_comp()(__v, *__next)) - { - // *__hint < __v < *_VSTD::next(__hint) - if (__hint.__ptr_->__right_ == nullptr) - { - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent->__right_; - } - else - { - __parent = const_cast<__node_pointer&>(__next.__ptr_); - return __parent->__left_; - } - } - // *next(__hint) <= __v - return __find_equal(__parent, __v); - } - // else __v == *__hint - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent; -} - -template -void -__tree<_Tp, _Compare, _Allocator>::__insert_node_at(__node_base_pointer __parent, - __node_base_pointer& __child, - __node_base_pointer __new_node) -{ - __new_node->__left_ = nullptr; - __new_node->__right_ = nullptr; - __new_node->__parent_ = __parent; - __child = __new_node; - if (__begin_node()->__left_ != nullptr) - __begin_node() = static_cast<__node_pointer>(__begin_node()->__left_); - __tree_balance_after_insert(__end_node()->__left_, __child); - ++size(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -typename __tree<_Tp, _Compare, _Allocator>::__node_holder -__tree<_Tp, _Compare, _Allocator>::__construct_node(_Args&& ...__args) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), _VSTD::forward<_Args>(__args)...); - __h.get_deleter().__value_constructed = true; - return __h; -} - -template -template -pair::iterator, bool> -__tree<_Tp, _Compare, _Allocator>::__emplace_unique(_Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__parent, __h->__value_); - __node_pointer __r = static_cast<__node_pointer>(__child); - bool __inserted = false; - if (__child == nullptr) - { - __insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - __inserted = true; - } - return pair(iterator(__r), __inserted); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__emplace_hint_unique(const_iterator __p, _Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__p, __parent, __h->__value_); - __node_pointer __r = static_cast<__node_pointer>(__child); - if (__child == nullptr) - { - __insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - } - return iterator(__r); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__emplace_multi(_Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf_high(__parent, __h->__value_); - __insert_node_at(__parent, __child, __h.get()); - return iterator(static_cast<__node_pointer>(__h.release())); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__emplace_hint_multi(const_iterator __p, - _Args&&... __args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf(__p, __parent, __h->__value_); - __insert_node_at(__parent, __child, __h.get()); - return iterator(static_cast<__node_pointer>(__h.release())); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -template -pair::iterator, bool> -__tree<_Tp, _Compare, _Allocator>::__insert_unique(_Vp&& __v) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Vp>(__v)); - pair __r = __node_insert_unique(__h.get()); - if (__r.second) - __h.release(); - return __r; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_unique(const_iterator __p, _Vp&& __v) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Vp>(__v)); - iterator __r = __node_insert_unique(__p, __h.get()); - if (__r.__ptr_ == __h.get()) - __h.release(); - return __r; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_multi(_Vp&& __v) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Vp>(__v)); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf_high(__parent, __h->__value_); - __insert_node_at(__parent, __child, __h.get()); - return iterator(__h.release()); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_multi(const_iterator __p, _Vp&& __v) -{ - __node_holder __h = __construct_node(_VSTD::forward<_Vp>(__v)); - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf(__p, __parent, __h->__value_); - __insert_node_at(__parent, __child, __h.get()); - return iterator(__h.release()); -} - -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename __tree<_Tp, _Compare, _Allocator>::__node_holder -__tree<_Tp, _Compare, _Allocator>::__construct_node(const value_type& __v) -{ - __node_allocator& __na = __node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), __v); - __h.get_deleter().__value_constructed = true; - return _VSTD::move(__h); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -pair::iterator, bool> -__tree<_Tp, _Compare, _Allocator>::__insert_unique(const value_type& __v) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__parent, __v); - __node_pointer __r = static_cast<__node_pointer>(__child); - bool __inserted = false; - if (__child == nullptr) - { - __node_holder __h = __construct_node(__v); - __insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - __inserted = true; - } - return pair(iterator(__r), __inserted); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_unique(const_iterator __p, const value_type& __v) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__p, __parent, __v); - __node_pointer __r = static_cast<__node_pointer>(__child); - if (__child == nullptr) - { - __node_holder __h = __construct_node(__v); - __insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - } - return iterator(__r); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_multi(const value_type& __v) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf_high(__parent, __v); - __node_holder __h = __construct_node(__v); - __insert_node_at(__parent, __child, __h.get()); - return iterator(__h.release()); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__insert_multi(const_iterator __p, const value_type& __v) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf(__p, __parent, __v); - __node_holder __h = __construct_node(__v); - __insert_node_at(__parent, __child, __h.get()); - return iterator(__h.release()); -} - -template -pair::iterator, bool> -__tree<_Tp, _Compare, _Allocator>::__node_insert_unique(__node_pointer __nd) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__parent, __nd->__value_); - __node_pointer __r = static_cast<__node_pointer>(__child); - bool __inserted = false; - if (__child == nullptr) - { - __insert_node_at(__parent, __child, __nd); - __r = __nd; - __inserted = true; - } - return pair(iterator(__r), __inserted); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__node_insert_unique(const_iterator __p, - __node_pointer __nd) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal(__p, __parent, __nd->__value_); - __node_pointer __r = static_cast<__node_pointer>(__child); - if (__child == nullptr) - { - __insert_node_at(__parent, __child, __nd); - __r = __nd; - } - return iterator(__r); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__node_insert_multi(__node_pointer __nd) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf_high(__parent, __nd->__value_); - __insert_node_at(__parent, __child, __nd); - return iterator(__nd); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__node_insert_multi(const_iterator __p, - __node_pointer __nd) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_leaf(__p, __parent, __nd->__value_); - __insert_node_at(__parent, __child, __nd); - return iterator(__nd); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::erase(const_iterator __p) -{ - __node_pointer __np = const_cast<__node_pointer>(__p.__ptr_); - iterator __r(__np); - ++__r; - if (__begin_node() == __np) - __begin_node() = __r.__ptr_; - --size(); - __node_allocator& __na = __node_alloc(); - __node_traits::destroy(__na, const_cast(_VSTD::addressof(*__p))); - __tree_remove(__end_node()->__left_, - static_cast<__node_base_pointer>(__np)); - __node_traits::deallocate(__na, __np, 1); - return __r; -} - -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::erase(const_iterator __f, const_iterator __l) -{ - while (__f != __l) - __f = erase(__f); - return iterator(const_cast<__node_pointer>(__l.__ptr_)); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::size_type -__tree<_Tp, _Compare, _Allocator>::__erase_unique(const _Key& __k) -{ - iterator __i = find(__k); - if (__i == end()) - return 0; - erase(__i); - return 1; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::size_type -__tree<_Tp, _Compare, _Allocator>::__erase_multi(const _Key& __k) -{ - pair __p = __equal_range_multi(__k); - size_type __r = 0; - for (; __p.first != __p.second; ++__r) - __p.first = erase(__p.first); - return __r; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::find(const _Key& __v) -{ - iterator __p = __lower_bound(__v, __root(), __end_node()); - if (__p != end() && !value_comp()(__v, *__p)) - return __p; - return end(); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::const_iterator -__tree<_Tp, _Compare, _Allocator>::find(const _Key& __v) const -{ - const_iterator __p = __lower_bound(__v, __root(), __end_node()); - if (__p != end() && !value_comp()(__v, *__p)) - return __p; - return end(); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::size_type -__tree<_Tp, _Compare, _Allocator>::__count_unique(const _Key& __k) const -{ - __node_const_pointer __result = __end_node(); - __node_const_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_const_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_const_pointer>(__rt->__right_); - else - return 1; - } - return 0; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::size_type -__tree<_Tp, _Compare, _Allocator>::__count_multi(const _Key& __k) const -{ - typedef pair _Pp; - __node_const_pointer __result = __end_node(); - __node_const_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_const_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_const_pointer>(__rt->__right_); - else - return _VSTD::distance( - __lower_bound(__k, static_cast<__node_const_pointer>(__rt->__left_), __rt), - __upper_bound(__k, static_cast<__node_const_pointer>(__rt->__right_), __result) - ); - } - return 0; -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__lower_bound(const _Key& __v, - __node_pointer __root, - __node_pointer __result) -{ - while (__root != nullptr) - { - if (!value_comp()(__root->__value_, __v)) - { - __result = __root; - __root = static_cast<__node_pointer>(__root->__left_); - } - else - __root = static_cast<__node_pointer>(__root->__right_); - } - return iterator(__result); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::const_iterator -__tree<_Tp, _Compare, _Allocator>::__lower_bound(const _Key& __v, - __node_const_pointer __root, - __node_const_pointer __result) const -{ - while (__root != nullptr) - { - if (!value_comp()(__root->__value_, __v)) - { - __result = __root; - __root = static_cast<__node_const_pointer>(__root->__left_); - } - else - __root = static_cast<__node_const_pointer>(__root->__right_); - } - return const_iterator(__result); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::iterator -__tree<_Tp, _Compare, _Allocator>::__upper_bound(const _Key& __v, - __node_pointer __root, - __node_pointer __result) -{ - while (__root != nullptr) - { - if (value_comp()(__v, __root->__value_)) - { - __result = __root; - __root = static_cast<__node_pointer>(__root->__left_); - } - else - __root = static_cast<__node_pointer>(__root->__right_); - } - return iterator(__result); -} - -template -template -typename __tree<_Tp, _Compare, _Allocator>::const_iterator -__tree<_Tp, _Compare, _Allocator>::__upper_bound(const _Key& __v, - __node_const_pointer __root, - __node_const_pointer __result) const -{ - while (__root != nullptr) - { - if (value_comp()(__v, __root->__value_)) - { - __result = __root; - __root = static_cast<__node_const_pointer>(__root->__left_); - } - else - __root = static_cast<__node_const_pointer>(__root->__right_); - } - return const_iterator(__result); -} - -template -template -pair::iterator, - typename __tree<_Tp, _Compare, _Allocator>::iterator> -__tree<_Tp, _Compare, _Allocator>::__equal_range_unique(const _Key& __k) -{ - typedef pair _Pp; - __node_pointer __result = __end_node(); - __node_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_pointer>(__rt->__right_); - else - return _Pp(iterator(__rt), - iterator( - __rt->__right_ != nullptr ? - static_cast<__node_pointer>(__tree_min(__rt->__right_)) - : __result)); - } - return _Pp(iterator(__result), iterator(__result)); -} - -template -template -pair::const_iterator, - typename __tree<_Tp, _Compare, _Allocator>::const_iterator> -__tree<_Tp, _Compare, _Allocator>::__equal_range_unique(const _Key& __k) const -{ - typedef pair _Pp; - __node_const_pointer __result = __end_node(); - __node_const_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_const_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_const_pointer>(__rt->__right_); - else - return _Pp(const_iterator(__rt), - const_iterator( - __rt->__right_ != nullptr ? - static_cast<__node_const_pointer>(__tree_min(__rt->__right_)) - : __result)); - } - return _Pp(const_iterator(__result), const_iterator(__result)); -} - -template -template -pair::iterator, - typename __tree<_Tp, _Compare, _Allocator>::iterator> -__tree<_Tp, _Compare, _Allocator>::__equal_range_multi(const _Key& __k) -{ - typedef pair _Pp; - __node_pointer __result = __end_node(); - __node_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_pointer>(__rt->__right_); - else - return _Pp(__lower_bound(__k, static_cast<__node_pointer>(__rt->__left_), __rt), - __upper_bound(__k, static_cast<__node_pointer>(__rt->__right_), __result)); - } - return _Pp(iterator(__result), iterator(__result)); -} - -template -template -pair::const_iterator, - typename __tree<_Tp, _Compare, _Allocator>::const_iterator> -__tree<_Tp, _Compare, _Allocator>::__equal_range_multi(const _Key& __k) const -{ - typedef pair _Pp; - __node_const_pointer __result = __end_node(); - __node_const_pointer __rt = __root(); - while (__rt != nullptr) - { - if (value_comp()(__k, __rt->__value_)) - { - __result = __rt; - __rt = static_cast<__node_const_pointer>(__rt->__left_); - } - else if (value_comp()(__rt->__value_, __k)) - __rt = static_cast<__node_const_pointer>(__rt->__right_); - else - return _Pp(__lower_bound(__k, static_cast<__node_const_pointer>(__rt->__left_), __rt), - __upper_bound(__k, static_cast<__node_const_pointer>(__rt->__right_), __result)); - } - return _Pp(const_iterator(__result), const_iterator(__result)); -} - -template -typename __tree<_Tp, _Compare, _Allocator>::__node_holder -__tree<_Tp, _Compare, _Allocator>::remove(const_iterator __p) _NOEXCEPT -{ - __node_pointer __np = const_cast<__node_pointer>(__p.__ptr_); - if (__begin_node() == __np) - { - if (__np->__right_ != nullptr) - __begin_node() = static_cast<__node_pointer>(__np->__right_); - else - __begin_node() = static_cast<__node_pointer>(__np->__parent_); - } - --size(); - __tree_remove(__end_node()->__left_, - static_cast<__node_base_pointer>(__np)); - return __node_holder(__np, _Dp(__node_alloc())); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(__tree<_Tp, _Compare, _Allocator>& __x, - __tree<_Tp, _Compare, _Allocator>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___TREE diff --git a/libcxx/include/__tuple b/libcxx/include/__tuple deleted file mode 100644 index 82168048e6ce..000000000000 --- a/libcxx/include/__tuple +++ /dev/null @@ -1,296 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___TUPLE -#define _LIBCPP___TUPLE - -#include <__config> -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#ifdef _LIBCPP_HAS_NO_VARIADICS - -#include <__tuple_03> - -#else // _LIBCPP_HAS_NO_VARIADICS - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class _LIBCPP_VISIBLE tuple_size; - -template -class _LIBCPP_VISIBLE tuple_size - : public tuple_size<_Tp> {}; - -template -class _LIBCPP_VISIBLE tuple_size - : public tuple_size<_Tp> {}; - -template -class _LIBCPP_VISIBLE tuple_size - : public tuple_size<_Tp> {}; - -template class _LIBCPP_VISIBLE tuple_element; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, const _Tp> -{ -public: - typedef typename add_const::type>::type type; -}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, volatile _Tp> -{ -public: - typedef typename add_volatile::type>::type type; -}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, const volatile _Tp> -{ -public: - typedef typename add_cv::type>::type type; -}; - -template class _LIBCPP_VISIBLE tuple; -template struct _LIBCPP_VISIBLE pair; -template struct _LIBCPP_VISIBLE array; - -template struct __tuple_like : false_type {}; - -template struct __tuple_like : public __tuple_like<_Tp> {}; -template struct __tuple_like : public __tuple_like<_Tp> {}; -template struct __tuple_like : public __tuple_like<_Tp> {}; - -template struct __tuple_like > : true_type {}; -template struct __tuple_like > : true_type {}; -template struct __tuple_like > : true_type {}; - -template -typename tuple_element<_Ip, tuple<_Tp...> >::type& -get(tuple<_Tp...>&) _NOEXCEPT; - -template -const typename tuple_element<_Ip, tuple<_Tp...> >::type& -get(const tuple<_Tp...>&) _NOEXCEPT; - -template -typename tuple_element<_Ip, tuple<_Tp...> >::type&& -get(tuple<_Tp...>&&) _NOEXCEPT; - -template -typename tuple_element<_Ip, pair<_T1, _T2> >::type& -get(pair<_T1, _T2>&) _NOEXCEPT; - -template -const typename tuple_element<_Ip, pair<_T1, _T2> >::type& -get(const pair<_T1, _T2>&) _NOEXCEPT; - -template -typename tuple_element<_Ip, pair<_T1, _T2> >::type&& -get(pair<_T1, _T2>&&) _NOEXCEPT; - -template -_Tp& -get(array<_Tp, _Size>&) _NOEXCEPT; - -template -const _Tp& -get(const array<_Tp, _Size>&) _NOEXCEPT; - -template -_Tp&& -get(array<_Tp, _Size>&&) _NOEXCEPT; - -// __make_tuple_indices - -template struct __tuple_indices {}; - -template -struct __make_indices_imp; - -template -struct __make_indices_imp<_Sp, __tuple_indices<_Indices...>, _Ep> -{ - typedef typename __make_indices_imp<_Sp+1, __tuple_indices<_Indices..., _Sp>, _Ep>::type type; -}; - -template -struct __make_indices_imp<_Ep, __tuple_indices<_Indices...>, _Ep> -{ - typedef __tuple_indices<_Indices...> type; -}; - -template -struct __make_tuple_indices -{ - static_assert(_Sp <= _Ep, "__make_tuple_indices input error"); - typedef typename __make_indices_imp<_Sp, __tuple_indices<>, _Ep>::type type; -}; - -// __tuple_types - -template struct __tuple_types {}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, __tuple_types<> > -{ -public: - static_assert(_Ip == 0, "tuple_element index out of range"); - static_assert(_Ip != 0, "tuple_element index out of range"); -}; - -template -class _LIBCPP_VISIBLE tuple_element<0, __tuple_types<_Hp, _Tp...> > -{ -public: - typedef _Hp type; -}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, __tuple_types<_Hp, _Tp...> > -{ -public: - typedef typename tuple_element<_Ip-1, __tuple_types<_Tp...> >::type type; -}; - -template -class _LIBCPP_VISIBLE tuple_size<__tuple_types<_Tp...> > - : public integral_constant -{ -}; - -template struct __tuple_like<__tuple_types<_Tp...> > : true_type {}; - -// __make_tuple_types - -// __make_tuple_types<_Tuple<_Types...>, _Ep, _Sp>::type is a -// __tuple_types<_Types...> using only those _Types in the range [_Sp, _Ep). -// _Sp defaults to 0 and _Ep defaults to tuple_size<_Tuple>. If _Tuple is a -// lvalue_reference type, then __tuple_types<_Types&...> is the result. - -template -struct __make_tuple_types_imp; - -template -struct __make_tuple_types_imp<__tuple_types<_Types...>, _Tp, _Sp, _Ep> -{ - typedef typename remove_reference<_Tp>::type _Tpr; - typedef typename __make_tuple_types_imp<__tuple_types<_Types..., - typename conditional::value, - typename tuple_element<_Sp, _Tpr>::type&, - typename tuple_element<_Sp, _Tpr>::type>::type>, - _Tp, _Sp+1, _Ep>::type type; -}; - -template -struct __make_tuple_types_imp<__tuple_types<_Types...>, _Tp, _Ep, _Ep> -{ - typedef __tuple_types<_Types...> type; -}; - -template ::type>::value, size_t _Sp = 0> -struct __make_tuple_types -{ - static_assert(_Sp <= _Ep, "__make_tuple_types input error"); - typedef typename __make_tuple_types_imp<__tuple_types<>, _Tp, _Sp, _Ep>::type type; -}; - -// __tuple_convertible - -template -struct __tuple_convertible_imp : public false_type {}; - -template -struct __tuple_convertible_imp, __tuple_types<_Up0, _Up...> > - : public integral_constant::value && - __tuple_convertible_imp, __tuple_types<_Up...> >::value> {}; - -template <> -struct __tuple_convertible_imp, __tuple_types<> > - : public true_type {}; - -template ::type>::value, - bool = __tuple_like<_Up>::value> -struct __tuple_convertible - : public false_type {}; - -template -struct __tuple_convertible<_Tp, _Up, true, true> - : public __tuple_convertible_imp::type>::value == - tuple_size<_Up>::value, - typename __make_tuple_types<_Tp>::type, typename __make_tuple_types<_Up>::type> -{}; - -// __tuple_constructible - -template -struct __tuple_constructible_imp : public false_type {}; - -template -struct __tuple_constructible_imp, __tuple_types<_Up0, _Up...> > - : public integral_constant::value && - __tuple_constructible_imp, __tuple_types<_Up...> >::value> {}; - -template <> -struct __tuple_constructible_imp, __tuple_types<> > - : public true_type {}; - -template ::type>::value, - bool = __tuple_like<_Up>::value> -struct __tuple_constructible - : public false_type {}; - -template -struct __tuple_constructible<_Tp, _Up, true, true> - : public __tuple_constructible_imp::type>::value == - tuple_size<_Up>::value, - typename __make_tuple_types<_Tp>::type, typename __make_tuple_types<_Up>::type> -{}; - -// __tuple_assignable - -template -struct __tuple_assignable_imp : public false_type {}; - -template -struct __tuple_assignable_imp, __tuple_types<_Up0, _Up...> > - : public integral_constant::value && - __tuple_assignable_imp, __tuple_types<_Up...> >::value> {}; - -template <> -struct __tuple_assignable_imp, __tuple_types<> > - : public true_type {}; - -template ::type>::value, - bool = __tuple_like<_Up>::value> -struct __tuple_assignable - : public false_type {}; - -template -struct __tuple_assignable<_Tp, _Up, true, true> - : public __tuple_assignable_imp::type>::value == - tuple_size<_Up>::value, - typename __make_tuple_types<_Tp>::type, typename __make_tuple_types<_Up>::type> -{}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_HAS_NO_VARIADICS - -#endif // _LIBCPP___TUPLE diff --git a/libcxx/include/__tuple_03 b/libcxx/include/__tuple_03 deleted file mode 100644 index a28ac0800ae9..000000000000 --- a/libcxx/include/__tuple_03 +++ /dev/null @@ -1,27 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP___TUPLE_03 -#define _LIBCPP___TUPLE_03 - -#include <__config> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class _LIBCPP_VISIBLE tuple_size; -template class _LIBCPP_VISIBLE tuple_element; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP___TUPLE_03 diff --git a/libcxx/include/__undef_min_max b/libcxx/include/__undef_min_max deleted file mode 100644 index 88bc53feaaf8..000000000000 --- a/libcxx/include/__undef_min_max +++ /dev/null @@ -1,19 +0,0 @@ -// -*- C++ -*- -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifdef min -#warning: macro min is incompatible with C++. #undef'ing min -#undef min -#endif - -#ifdef max -#warning: macro max is incompatible with C++. #undef'ing max -#undef max -#endif diff --git a/libcxx/include/algorithm b/libcxx/include/algorithm deleted file mode 100644 index d924a7de3f2d..000000000000 --- a/libcxx/include/algorithm +++ /dev/null @@ -1,5401 +0,0 @@ -// -*- C++ -*- -//===-------------------------- algorithm ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_ALGORITHM -#define _LIBCPP_ALGORITHM - -/* - algorithm synopsis - -#include - -namespace std -{ - -template - bool - all_of(InputIterator first, InputIterator last, Predicate pred); - -template - bool - any_of(InputIterator first, InputIterator last, Predicate pred); - -template - bool - none_of(InputIterator first, InputIterator last, Predicate pred); - -template - Function - for_each(InputIterator first, InputIterator last, Function f); - -template - InputIterator - find(InputIterator first, InputIterator last, const T& value); - -template - InputIterator - find_if(InputIterator first, InputIterator last, Predicate pred); - -template - InputIterator - find_if_not(InputIterator first, InputIterator last, Predicate pred); - -template - ForwardIterator1 - find_end(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2); - -template - ForwardIterator1 - find_end(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2, BinaryPredicate pred); - -template - ForwardIterator1 - find_first_of(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2); - -template - ForwardIterator1 - find_first_of(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2, BinaryPredicate pred); - -template - ForwardIterator - adjacent_find(ForwardIterator first, ForwardIterator last); - -template - ForwardIterator - adjacent_find(ForwardIterator first, ForwardIterator last, BinaryPredicate pred); - -template - typename iterator_traits::difference_type - count(InputIterator first, InputIterator last, const T& value); - -template - typename iterator_traits::difference_type - count_if(InputIterator first, InputIterator last, Predicate pred); - -template - pair - mismatch(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2); - -template - pair - mismatch(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, BinaryPredicate pred); - -template - bool - equal(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2); - -template - bool - equal(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, BinaryPredicate pred); - -template - bool - is_permutation(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2); - -template - bool - is_permutation(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, BinaryPredicate pred); - -template - ForwardIterator1 - search(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2); - -template - ForwardIterator1 - search(ForwardIterator1 first1, ForwardIterator1 last1, - ForwardIterator2 first2, ForwardIterator2 last2, BinaryPredicate pred); - -template - ForwardIterator - search_n(ForwardIterator first, ForwardIterator last, Size count, const T& value); - -template - ForwardIterator - search_n(ForwardIterator first, ForwardIterator last, - Size count, const T& value, BinaryPredicate pred); - -template - OutputIterator - copy(InputIterator first, InputIterator last, OutputIterator result); - -template - OutputIterator - copy_if(InputIterator first, InputIterator last, - OutputIterator result, Predicate pred); - -template - OutputIterator - copy_n(InputIterator first, Size n, OutputIterator result); - -template - BidirectionalIterator2 - copy_backward(BidirectionalIterator1 first, BidirectionalIterator1 last, - BidirectionalIterator2 result); - -template - ForwardIterator2 - swap_ranges(ForwardIterator1 first1, ForwardIterator1 last1, ForwardIterator2 first2); - -template - void - iter_swap(ForwardIterator1 a, ForwardIterator2 b); - -template - OutputIterator - transform(InputIterator first, InputIterator last, OutputIterator result, UnaryOperation op); - -template - OutputIterator - transform(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, - OutputIterator result, BinaryOperation binary_op); - -template - void - replace(ForwardIterator first, ForwardIterator last, const T& old_value, const T& new_value); - -template - void - replace_if(ForwardIterator first, ForwardIterator last, Predicate pred, const T& new_value); - -template - OutputIterator - replace_copy(InputIterator first, InputIterator last, OutputIterator result, - const T& old_value, const T& new_value); - -template - OutputIterator - replace_copy_if(InputIterator first, InputIterator last, OutputIterator result, Predicate pred, const T& new_value); - -template - void - fill(ForwardIterator first, ForwardIterator last, const T& value); - -template - OutputIterator - fill_n(OutputIterator first, Size n, const T& value); - -template - void - generate(ForwardIterator first, ForwardIterator last, Generator gen); - -template - OutputIterator - generate_n(OutputIterator first, Size n, Generator gen); - -template - ForwardIterator - remove(ForwardIterator first, ForwardIterator last, const T& value); - -template - ForwardIterator - remove_if(ForwardIterator first, ForwardIterator last, Predicate pred); - -template - OutputIterator - remove_copy(InputIterator first, InputIterator last, OutputIterator result, const T& value); - -template - OutputIterator - remove_copy_if(InputIterator first, InputIterator last, OutputIterator result, Predicate pred); - -template - ForwardIterator - unique(ForwardIterator first, ForwardIterator last); - -template - ForwardIterator - unique(ForwardIterator first, ForwardIterator last, BinaryPredicate pred); - -template - OutputIterator - unique_copy(InputIterator first, InputIterator last, OutputIterator result); - -template - OutputIterator - unique_copy(InputIterator first, InputIterator last, OutputIterator result, BinaryPredicate pred); - -template - void - reverse(BidirectionalIterator first, BidirectionalIterator last); - -template - OutputIterator - reverse_copy(BidirectionalIterator first, BidirectionalIterator last, OutputIterator result); - -template - ForwardIterator - rotate(ForwardIterator first, ForwardIterator middle, ForwardIterator last); - -template - OutputIterator - rotate_copy(ForwardIterator first, ForwardIterator middle, ForwardIterator last, OutputIterator result); - -template - void - random_shuffle(RandomAccessIterator first, RandomAccessIterator last); - -template - void - random_shuffle(RandomAccessIterator first, RandomAccessIterator last, RandomNumberGenerator& rand); - -template - void shuffle(RandomAccessIterator first, RandomAccessIterator last, - UniformRandomNumberGenerator&& g); - -template - bool - is_partitioned(InputIterator first, InputIterator last, Predicate pred); - -template - ForwardIterator - partition(ForwardIterator first, ForwardIterator last, Predicate pred); - -template - pair - partition_copy(InputIterator first, InputIterator last, - OutputIterator1 out_true, OutputIterator2 out_false, - Predicate pred); - -template - ForwardIterator - stable_partition(ForwardIterator first, ForwardIterator last, Predicate pred); - -template - ForwardIterator - partition_point(ForwardIterator first, ForwardIterator last, Predicate pred); - -template - bool - is_sorted(ForwardIterator first, ForwardIterator last); - -template - bool - is_sorted(ForwardIterator first, ForwardIterator last, Compare comp); - -template - ForwardIterator - is_sorted_until(ForwardIterator first, ForwardIterator last); - -template - ForwardIterator - is_sorted_until(ForwardIterator first, ForwardIterator last, Compare comp); - -template - void - sort(RandomAccessIterator first, RandomAccessIterator last); - -template - void - sort(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - void - stable_sort(RandomAccessIterator first, RandomAccessIterator last); - -template - void - stable_sort(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - void - partial_sort(RandomAccessIterator first, RandomAccessIterator middle, RandomAccessIterator last); - -template - void - partial_sort(RandomAccessIterator first, RandomAccessIterator middle, RandomAccessIterator last, Compare comp); - -template - RandomAccessIterator - partial_sort_copy(InputIterator first, InputIterator last, - RandomAccessIterator result_first, RandomAccessIterator result_last); - -template - RandomAccessIterator - partial_sort_copy(InputIterator first, InputIterator last, - RandomAccessIterator result_first, RandomAccessIterator result_last, Compare comp); - -template - void - nth_element(RandomAccessIterator first, RandomAccessIterator nth, RandomAccessIterator last); - -template - void - nth_element(RandomAccessIterator first, RandomAccessIterator nth, RandomAccessIterator last, Compare comp); - -template - ForwardIterator - lower_bound(ForwardIterator first, ForwardIterator last, const T& value); - -template - ForwardIterator - lower_bound(ForwardIterator first, ForwardIterator last, const T& value, Compare comp); - -template - ForwardIterator - upper_bound(ForwardIterator first, ForwardIterator last, const T& value); - -template - ForwardIterator - upper_bound(ForwardIterator first, ForwardIterator last, const T& value, Compare comp); - -template - pair - equal_range(ForwardIterator first, ForwardIterator last, const T& value); - -template - pair - equal_range(ForwardIterator first, ForwardIterator last, const T& value, Compare comp); - -template - bool - binary_search(ForwardIterator first, ForwardIterator last, const T& value); - -template - bool - binary_search(ForwardIterator first, ForwardIterator last, const T& value, Compare comp); - -template - OutputIterator - merge(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result); - -template - OutputIterator - merge(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result, Compare comp); - -template - void - inplace_merge(BidirectionalIterator first, BidirectionalIterator middle, BidirectionalIterator last); - -template - void - inplace_merge(BidirectionalIterator first, BidirectionalIterator middle, BidirectionalIterator last, Compare comp); - -template - bool - includes(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, InputIterator2 last2); - -template - bool - includes(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, InputIterator2 last2, Compare comp); - -template - OutputIterator - set_union(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result); - -template - OutputIterator - set_union(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result, Compare comp); - -template - OutputIterator - set_intersection(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result); - -template - OutputIterator - set_intersection(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result, Compare comp); - -template - OutputIterator - set_difference(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result); - -template - OutputIterator - set_difference(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result, Compare comp); - -template - OutputIterator - set_symmetric_difference(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result); - -template - OutputIterator - set_symmetric_difference(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, OutputIterator result, Compare comp); - -template - void - push_heap(RandomAccessIterator first, RandomAccessIterator last); - -template - void - push_heap(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - void - pop_heap(RandomAccessIterator first, RandomAccessIterator last); - -template - void - pop_heap(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - void - make_heap(RandomAccessIterator first, RandomAccessIterator last); - -template - void - make_heap(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - void - sort_heap(RandomAccessIterator first, RandomAccessIterator last); - -template - void - sort_heap(RandomAccessIterator first, RandomAccessIterator last, Compare comp); - -template - bool - is_heap(RandomAccessIterator first, RandomAccessiterator last); - -template - bool - is_heap(RandomAccessIterator first, RandomAccessiterator last, Compare comp); - -template - RandomAccessIterator - is_heap_until(RandomAccessIterator first, RandomAccessiterator last); - -template - RandomAccessIterator - is_heap_until(RandomAccessIterator first, RandomAccessiterator last, Compare comp); - -template - ForwardIterator - min_element(ForwardIterator first, ForwardIterator last); - -template - ForwardIterator - min_element(ForwardIterator first, ForwardIterator last, Compare comp); - -template - const T& - min(const T& a, const T& b); - -template - const T& - min(const T& a, const T& b, Compare comp); - -template - T - min(initializer_list t); - -template - T - min(initializer_list t, Compare comp); - -template - ForwardIterator - max_element(ForwardIterator first, ForwardIterator last); - -template - ForwardIterator - max_element(ForwardIterator first, ForwardIterator last, Compare comp); - -template - const T& - max(const T& a, const T& b); - -template - const T& - max(const T& a, const T& b, Compare comp); - -template - T - max(initializer_list t); - -template - T - max(initializer_list t, Compare comp); - -template - pair - minmax_element(ForwardIterator first, ForwardIterator last); - -template - pair - minmax_element(ForwardIterator first, ForwardIterator last, Compare comp); - -template - pair - minmax(const T& a, const T& b); - -template - pair - minmax(const T& a, const T& b, Compare comp); - -template - pair - minmax(initializer_list t); - -template - pair - minmax(initializer_list t, Compare comp); - -template - bool - lexicographical_compare(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, InputIterator2 last2); - -template - bool - lexicographical_compare(InputIterator1 first1, InputIterator1 last1, - InputIterator2 first2, InputIterator2 last2, Compare comp); - -template - bool - next_permutation(BidirectionalIterator first, BidirectionalIterator last); - -template - bool - next_permutation(BidirectionalIterator first, BidirectionalIterator last, Compare comp); - -template - bool - prev_permutation(BidirectionalIterator first, BidirectionalIterator last); - -template - bool - prev_permutation(BidirectionalIterator first, BidirectionalIterator last, Compare comp); - -} // std - -*/ - -#include <__config> -#include -#include -#include -#include -#include -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -struct __equal_to -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T2& __y) const {return __x == __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T2& __x, const _T1& __y) const {return __x == __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T2& __x, const _T2& __y) const {return __x == __y;} -}; - -template -struct __equal_to<_T1, _T1> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;} -}; - -template -struct __equal_to -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;} -}; - -template -struct __equal_to<_T1, const _T1> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x == __y;} -}; - -template -struct __less -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T2& __y) const {return __x < __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T2& __x, const _T1& __y) const {return __x < __y;} - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T2& __x, const _T2& __y) const {return __x < __y;} -}; - -template -struct __less<_T1, _T1> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;} -}; - -template -struct __less -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;} -}; - -template -struct __less<_T1, const _T1> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _T1& __x, const _T1& __y) const {return __x < __y;} -}; - -template -class __negate -{ -private: - _Predicate __p_; -public: - _LIBCPP_INLINE_VISIBILITY __negate() {} - - _LIBCPP_INLINE_VISIBILITY - explicit __negate(_Predicate __p) : __p_(__p) {} - - template - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _T1& __x) {return !__p_(__x);} - - template - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _T1& __x, const _T2& __y) {return !__p_(__x, __y);} -}; - -#ifdef _LIBCPP_DEBUG2 - -template -struct __debug_less -{ - _Compare __comp_; - __debug_less(_Compare& __c) : __comp_(__c) {} - template - bool operator()(const _Tp& __x, const _Up& __y) - { - bool __r = __comp_(__x, __y); - if (__r) - _LIBCPP_ASSERT(!__comp_(__y, __x), "Comparator does not induce a strict weak ordering"); - return __r; - } -}; - -#endif // _LIBCPP_DEBUG2 - -// Precondition: __x != 0 -inline _LIBCPP_INLINE_VISIBILITY -unsigned -__ctz(unsigned __x) -{ - return static_cast(__builtin_ctz(__x)); -} - -inline _LIBCPP_INLINE_VISIBILITY -unsigned long -__ctz(unsigned long __x) -{ - return static_cast(__builtin_ctzl(__x)); -} - -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -__ctz(unsigned long long __x) -{ - return static_cast(__builtin_ctzll(__x)); -} - -// Precondition: __x != 0 -inline _LIBCPP_INLINE_VISIBILITY -unsigned -__clz(unsigned __x) -{ - return static_cast(__builtin_clz(__x)); -} - -inline _LIBCPP_INLINE_VISIBILITY -unsigned long -__clz(unsigned long __x) -{ - return static_cast(__builtin_clzl (__x)); -} - -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -__clz(unsigned long long __x) -{ - return static_cast(__builtin_clzll(__x)); -} - -inline _LIBCPP_INLINE_VISIBILITY int __pop_count(unsigned __x) {return __builtin_popcount (__x);} -inline _LIBCPP_INLINE_VISIBILITY int __pop_count(unsigned long __x) {return __builtin_popcountl (__x);} -inline _LIBCPP_INLINE_VISIBILITY int __pop_count(unsigned long long __x) {return __builtin_popcountll(__x);} - -// all_of - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -all_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (!__pred(*__first)) - return false; - return true; -} - -// any_of - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -any_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (__pred(*__first)) - return true; - return false; -} - -// none_of - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -none_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (__pred(*__first)) - return false; - return true; -} - -// for_each - -template -inline _LIBCPP_INLINE_VISIBILITY -_Function -for_each(_InputIterator __first, _InputIterator __last, _Function __f) -{ - for (; __first != __last; ++__first) - __f(*__first); - return _VSTD::move(__f); -} - -// find - -template -inline _LIBCPP_INLINE_VISIBILITY -_InputIterator -find(_InputIterator __first, _InputIterator __last, const _Tp& __value_) -{ - for (; __first != __last; ++__first) - if (*__first == __value_) - break; - return __first; -} - -// find_if - -template -inline _LIBCPP_INLINE_VISIBILITY -_InputIterator -find_if(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (__pred(*__first)) - break; - return __first; -} - -// find_if_not - -template -inline _LIBCPP_INLINE_VISIBILITY -_InputIterator -find_if_not(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (!__pred(*__first)) - break; - return __first; -} - -// find_end - -template -_ForwardIterator1 -__find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred, - forward_iterator_tag, forward_iterator_tag) -{ - // modeled after search algorithm - _ForwardIterator1 __r = __last1; // __last1 is the "default" answer - if (__first2 == __last2) - return __r; - while (true) - { - while (true) - { - if (__first1 == __last1) // if source exhausted return last correct answer - return __r; // (or __last1 if never found) - if (__pred(*__first1, *__first2)) - break; - ++__first1; - } - // *__first1 matches *__first2, now match elements after here - _ForwardIterator1 __m1 = __first1; - _ForwardIterator2 __m2 = __first2; - while (true) - { - if (++__m2 == __last2) - { // Pattern exhaused, record answer and search for another one - __r = __first1; - ++__first1; - break; - } - if (++__m1 == __last1) // Source exhausted, return last answer - return __r; - if (!__pred(*__m1, *__m2)) // mismatch, restart with a new __first - { - ++__first1; - break; - } // else there is a match, check next elements - } - } -} - -template -_BidirectionalIterator1 -__find_end(_BidirectionalIterator1 __first1, _BidirectionalIterator1 __last1, - _BidirectionalIterator2 __first2, _BidirectionalIterator2 __last2, _BinaryPredicate __pred, - bidirectional_iterator_tag, bidirectional_iterator_tag) -{ - // modeled after search algorithm (in reverse) - if (__first2 == __last2) - return __last1; // Everything matches an empty sequence - _BidirectionalIterator1 __l1 = __last1; - _BidirectionalIterator2 __l2 = __last2; - --__l2; - while (true) - { - // Find last element in sequence 1 that matchs *(__last2-1), with a mininum of loop checks - while (true) - { - if (__first1 == __l1) // return __last1 if no element matches *__first2 - return __last1; - if (__pred(*--__l1, *__l2)) - break; - } - // *__l1 matches *__l2, now match elements before here - _BidirectionalIterator1 __m1 = __l1; - _BidirectionalIterator2 __m2 = __l2; - while (true) - { - if (__m2 == __first2) // If pattern exhausted, __m1 is the answer (works for 1 element pattern) - return __m1; - if (__m1 == __first1) // Otherwise if source exhaused, pattern not found - return __last1; - if (!__pred(*--__m1, *--__m2)) // if there is a mismatch, restart with a new __l1 - { - break; - } // else there is a match, check next elements - } - } -} - -template -_RandomAccessIterator1 -__find_end(_RandomAccessIterator1 __first1, _RandomAccessIterator1 __last1, - _RandomAccessIterator2 __first2, _RandomAccessIterator2 __last2, _BinaryPredicate __pred, - random_access_iterator_tag, random_access_iterator_tag) -{ - // Take advantage of knowing source and pattern lengths. Stop short when source is smaller than pattern - typename iterator_traits<_RandomAccessIterator2>::difference_type __len2 = __last2 - __first2; - if (__len2 == 0) - return __last1; - typename iterator_traits<_RandomAccessIterator1>::difference_type __len1 = __last1 - __first1; - if (__len1 < __len2) - return __last1; - const _RandomAccessIterator1 __s = __first1 + (__len2 - 1); // End of pattern match can't go before here - _RandomAccessIterator1 __l1 = __last1; - _RandomAccessIterator2 __l2 = __last2; - --__l2; - while (true) - { - while (true) - { - if (__s == __l1) - return __last1; - if (__pred(*--__l1, *__l2)) - break; - } - _RandomAccessIterator1 __m1 = __l1; - _RandomAccessIterator2 __m2 = __l2; - while (true) - { - if (__m2 == __first2) - return __m1; - // no need to check range on __m1 because __s guarantees we have enough source - if (!__pred(*--__m1, *--__m2)) - { - break; - } - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator1 -find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred) -{ - return _VSTD::__find_end::type> - (__first1, __last1, __first2, __last2, __pred, - typename iterator_traits<_ForwardIterator1>::iterator_category(), - typename iterator_traits<_ForwardIterator2>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator1 -find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2) -{ - typedef typename iterator_traits<_ForwardIterator1>::value_type __v1; - typedef typename iterator_traits<_ForwardIterator2>::value_type __v2; - return _VSTD::find_end(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>()); -} - -// find_first_of - -template -_ForwardIterator1 -find_first_of(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred) -{ - for (; __first1 != __last1; ++__first1) - for (_ForwardIterator2 __j = __first2; __j != __last2; ++__j) - if (__pred(*__first1, *__j)) - return __first1; - return __last1; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator1 -find_first_of(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2) -{ - typedef typename iterator_traits<_ForwardIterator1>::value_type __v1; - typedef typename iterator_traits<_ForwardIterator2>::value_type __v2; - return _VSTD::find_first_of(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>()); -} - -// adjacent_find - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -adjacent_find(_ForwardIterator __first, _ForwardIterator __last, _BinaryPredicate __pred) -{ - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - { - if (__pred(*__first, *__i)) - return __first; - __first = __i; - } - } - return __last; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -adjacent_find(_ForwardIterator __first, _ForwardIterator __last) -{ - typedef typename iterator_traits<_ForwardIterator>::value_type __v; - return _VSTD::adjacent_find(__first, __last, __equal_to<__v>()); -} - -// count - -template -inline _LIBCPP_INLINE_VISIBILITY -typename iterator_traits<_InputIterator>::difference_type -count(_InputIterator __first, _InputIterator __last, const _Tp& __value_) -{ - typename iterator_traits<_InputIterator>::difference_type __r(0); - for (; __first != __last; ++__first) - if (*__first == __value_) - ++__r; - return __r; -} - -// count_if - -template -inline _LIBCPP_INLINE_VISIBILITY -typename iterator_traits<_InputIterator>::difference_type -count_if(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - typename iterator_traits<_InputIterator>::difference_type __r(0); - for (; __first != __last; ++__first) - if (__pred(*__first)) - ++__r; - return __r; -} - -// mismatch - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_InputIterator1, _InputIterator2> -mismatch(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _BinaryPredicate __pred) -{ - for (; __first1 != __last1; ++__first1, ++__first2) - if (!__pred(*__first1, *__first2)) - break; - return pair<_InputIterator1, _InputIterator2>(__first1, __first2); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_InputIterator1, _InputIterator2> -mismatch(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2) -{ - typedef typename iterator_traits<_InputIterator1>::value_type __v1; - typedef typename iterator_traits<_InputIterator2>::value_type __v2; - return _VSTD::mismatch(__first1, __last1, __first2, __equal_to<__v1, __v2>()); -} - -// equal - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -equal(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _BinaryPredicate __pred) -{ - for (; __first1 != __last1; ++__first1, ++__first2) - if (!__pred(*__first1, *__first2)) - return false; - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -equal(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2) -{ - typedef typename iterator_traits<_InputIterator1>::value_type __v1; - typedef typename iterator_traits<_InputIterator2>::value_type __v2; - return _VSTD::equal(__first1, __last1, __first2, __equal_to<__v1, __v2>()); -} - -// is_permutation - -template -bool -is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _BinaryPredicate __pred) -{ - // shorten sequences as much as possible by lopping of any equal parts - for (; __first1 != __last1; ++__first1, ++__first2) - if (!__pred(*__first1, *__first2)) - goto __not_done; - return true; -__not_done: - // __first1 != __last1 && *__first1 != *__first2 - typedef typename iterator_traits<_ForwardIterator1>::difference_type _D1; - _D1 __l1 = _VSTD::distance(__first1, __last1); - if (__l1 == _D1(1)) - return false; - _ForwardIterator2 __last2 = _VSTD::next(__first2, __l1); - // For each element in [f1, l1) see if there are the same number of - // equal elements in [f2, l2) - for (_ForwardIterator1 __i = __first1; __i != __last1; ++__i) - { - // Have we already counted the number of *__i in [f1, l1)? - for (_ForwardIterator1 __j = __first1; __j != __i; ++__j) - if (__pred(*__j, *__i)) - goto __next_iter; - { - // Count number of *__i in [f2, l2) - _D1 __c2 = 0; - for (_ForwardIterator2 __j = __first2; __j != __last2; ++__j) - if (__pred(*__i, *__j)) - ++__c2; - if (__c2 == 0) - return false; - // Count number of *__i in [__i, l1) (we can start with 1) - _D1 __c1 = 1; - for (_ForwardIterator1 __j = _VSTD::next(__i); __j != __last1; ++__j) - if (__pred(*__i, *__j)) - ++__c1; - if (__c1 != __c2) - return false; - } -__next_iter:; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2) -{ - typedef typename iterator_traits<_ForwardIterator1>::value_type __v1; - typedef typename iterator_traits<_ForwardIterator2>::value_type __v2; - return _VSTD::is_permutation(__first1, __last1, __first2, __equal_to<__v1, __v2>()); -} - -// search - -template -_ForwardIterator1 -__search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred, - forward_iterator_tag, forward_iterator_tag) -{ - if (__first2 == __last2) - return __first1; // Everything matches an empty sequence - while (true) - { - // Find first element in sequence 1 that matchs *__first2, with a mininum of loop checks - while (true) - { - if (__first1 == __last1) // return __last1 if no element matches *__first2 - return __last1; - if (__pred(*__first1, *__first2)) - break; - ++__first1; - } - // *__first1 matches *__first2, now match elements after here - _ForwardIterator1 __m1 = __first1; - _ForwardIterator2 __m2 = __first2; - while (true) - { - if (++__m2 == __last2) // If pattern exhausted, __first1 is the answer (works for 1 element pattern) - return __first1; - if (++__m1 == __last1) // Otherwise if source exhaused, pattern not found - return __last1; - if (!__pred(*__m1, *__m2)) // if there is a mismatch, restart with a new __first1 - { - ++__first1; - break; - } // else there is a match, check next elements - } - } -} - -template -_RandomAccessIterator1 -__search(_RandomAccessIterator1 __first1, _RandomAccessIterator1 __last1, - _RandomAccessIterator2 __first2, _RandomAccessIterator2 __last2, _BinaryPredicate __pred, - random_access_iterator_tag, random_access_iterator_tag) -{ - typedef typename std::iterator_traits<_RandomAccessIterator1>::difference_type _D1; - typedef typename std::iterator_traits<_RandomAccessIterator2>::difference_type _D2; - // Take advantage of knowing source and pattern lengths. Stop short when source is smaller than pattern - _D2 __len2 = __last2 - __first2; - if (__len2 == 0) - return __first1; - _D1 __len1 = __last1 - __first1; - if (__len1 < __len2) - return __last1; - const _RandomAccessIterator1 __s = __last1 - (__len2 - 1); // Start of pattern match can't go beyond here - while (true) - { -#if !_LIBCPP_UNROLL_LOOPS - while (true) - { - if (__first1 == __s) - return __last1; - if (__pred(*__first1, *__first2)) - break; - ++__first1; - } -#else // !_LIBCPP_UNROLL_LOOPS - for (_D1 __loop_unroll = (__s - __first1) / 4; __loop_unroll > 0; --__loop_unroll) - { - if (__pred(*__first1, *__first2)) - goto __phase2; - if (__pred(*++__first1, *__first2)) - goto __phase2; - if (__pred(*++__first1, *__first2)) - goto __phase2; - if (__pred(*++__first1, *__first2)) - goto __phase2; - ++__first1; - } - switch (__s - __first1) - { - case 3: - if (__pred(*__first1, *__first2)) - break; - ++__first1; - case 2: - if (__pred(*__first1, *__first2)) - break; - ++__first1; - case 1: - if (__pred(*__first1, *__first2)) - break; - case 0: - return __last1; - } - __phase2: -#endif // !_LIBCPP_UNROLL_LOOPS - _RandomAccessIterator1 __m1 = __first1; - _RandomAccessIterator2 __m2 = __first2; -#if !_LIBCPP_UNROLL_LOOPS - while (true) - { - if (++__m2 == __last2) - return __first1; - ++__m1; // no need to check range on __m1 because __s guarantees we have enough source - if (!__pred(*__m1, *__m2)) - { - ++__first1; - break; - } - } -#else // !_LIBCPP_UNROLL_LOOPS - ++__m2; - ++__m1; - for (_D2 __loop_unroll = (__last2 - __m2) / 4; __loop_unroll > 0; --__loop_unroll) - { - if (!__pred(*__m1, *__m2)) - goto __continue; - if (!__pred(*++__m1, *++__m2)) - goto __continue; - if (!__pred(*++__m1, *++__m2)) - goto __continue; - if (!__pred(*++__m1, *++__m2)) - goto __continue; - ++__m1; - ++__m2; - } - switch (__last2 - __m2) - { - case 3: - if (!__pred(*__m1, *__m2)) - break; - ++__m1; - ++__m2; - case 2: - if (!__pred(*__m1, *__m2)) - break; - ++__m1; - ++__m2; - case 1: - if (!__pred(*__m1, *__m2)) - break; - case 0: - return __first1; - } - __continue: - ++__first1; -#endif // !_LIBCPP_UNROLL_LOOPS - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator1 -search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2, _BinaryPredicate __pred) -{ - return _VSTD::__search::type> - (__first1, __last1, __first2, __last2, __pred, - typename std::iterator_traits<_ForwardIterator1>::iterator_category(), - typename std::iterator_traits<_ForwardIterator2>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator1 -search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, - _ForwardIterator2 __first2, _ForwardIterator2 __last2) -{ - typedef typename std::iterator_traits<_ForwardIterator1>::value_type __v1; - typedef typename std::iterator_traits<_ForwardIterator2>::value_type __v2; - return _VSTD::search(__first1, __last1, __first2, __last2, __equal_to<__v1, __v2>()); -} - -// search_n - -template -_ForwardIterator -__search_n(_ForwardIterator __first, _ForwardIterator __last, - _Size __count, const _Tp& __value_, _BinaryPredicate __pred, forward_iterator_tag) -{ - if (__count <= 0) - return __first; - while (true) - { - // Find first element in sequence that matchs __value_, with a mininum of loop checks - while (true) - { - if (__first == __last) // return __last if no element matches __value_ - return __last; - if (__pred(*__first, __value_)) - break; - ++__first; - } - // *__first matches __value_, now match elements after here - _ForwardIterator __m = __first; - _Size __c(0); - while (true) - { - if (++__c == __count) // If pattern exhausted, __first is the answer (works for 1 element pattern) - return __first; - if (++__m == __last) // Otherwise if source exhaused, pattern not found - return __last; - if (!__pred(*__m, __value_)) // if there is a mismatch, restart with a new __first - { - __first = __m; - ++__first; - break; - } // else there is a match, check next elements - } - } -} - -template -_RandomAccessIterator -__search_n(_RandomAccessIterator __first, _RandomAccessIterator __last, - _Size __count, const _Tp& __value_, _BinaryPredicate __pred, random_access_iterator_tag) -{ - if (__count <= 0) - return __first; - _Size __len = static_cast<_Size>(__last - __first); - if (__len < __count) - return __last; - const _RandomAccessIterator __s = __last - (__count - 1); // Start of pattern match can't go beyond here - while (true) - { - // Find first element in sequence that matchs __value_, with a mininum of loop checks - while (true) - { - if (__first == __s) // return __last if no element matches __value_ - return __last; - if (__pred(*__first, __value_)) - break; - ++__first; - } - // *__first matches __value_, now match elements after here - _RandomAccessIterator __m = __first; - _Size __c(0); - while (true) - { - if (++__c == __count) // If pattern exhausted, __first is the answer (works for 1 element pattern) - return __first; - ++__m; // no need to check range on __m because __s guarantees we have enough source - if (!__pred(*__m, __value_)) // if there is a mismatch, restart with a new __first - { - __first = __m; - ++__first; - break; - } // else there is a match, check next elements - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -search_n(_ForwardIterator __first, _ForwardIterator __last, - _Size __count, const _Tp& __value_, _BinaryPredicate __pred) -{ - return _VSTD::__search_n::type> - (__first, __last, __count, __value_, __pred, typename iterator_traits<_ForwardIterator>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -search_n(_ForwardIterator __first, _ForwardIterator __last, _Size __count, const _Tp& __value_) -{ - typedef typename iterator_traits<_ForwardIterator>::value_type __v; - return _VSTD::search_n(__first, __last, __count, __value_, __equal_to<__v, _Tp>()); -} - -// copy - -template -struct __libcpp_is_trivial_iterator -{ - static const bool value = is_pointer<_Iter>::value; -}; - -template -struct __libcpp_is_trivial_iterator > -{ - static const bool value = is_pointer<_Iter>::value; -}; - -template -struct __libcpp_is_trivial_iterator<__wrap_iter<_Iter> > -{ - static const bool value = is_pointer<_Iter>::value; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -_Iter -__unwrap_iter(_Iter __i) -{ - return __i; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_trivially_copy_assignable<_Tp>::value, - _Tp* ->::type -__unwrap_iter(move_iterator<_Tp*> __i) -{ - return __i.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_trivially_copy_assignable<_Tp>::value, - _Tp* ->::type -__unwrap_iter(__wrap_iter<_Tp*> __i) -{ - return __i.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - for (; __first != __last; ++__first, ++__result) - *__result = *__first; - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_same::type, _Up>::value && - is_trivially_copy_assignable<_Up>::value, - _Up* ->::type -__copy(_Tp* __first, _Tp* __last, _Up* __result) -{ - const size_t __n = static_cast(__last - __first); - _VSTD::memmove(__result, __first, __n * sizeof(_Up)); - return __result + __n; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - return _VSTD::__copy(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result)); -} - -// copy_backward - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__copy_backward(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - while (__first != __last) - *--__result = *--__last; - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_same::type, _Up>::value && - is_trivially_copy_assignable<_Up>::value, - _Up* ->::type -__copy_backward(_Tp* __first, _Tp* __last, _Up* __result) -{ - const size_t __n = static_cast(__last - __first); - __result -= __n; - _VSTD::memmove(__result, __first, __n * sizeof(_Up)); - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_BidirectionalIterator2 -copy_backward(_BidirectionalIterator1 __first, _BidirectionalIterator1 __last, - _BidirectionalIterator2 __result) -{ - return _VSTD::__copy_backward(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result)); -} - -// copy_if - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -copy_if(_InputIterator __first, _InputIterator __last, - _OutputIterator __result, _Predicate __pred) -{ - for (; __first != __last; ++__first) - { - if (__pred(*__first)) - { - *__result = *__first; - ++__result; - } - } - return __result; -} - -// copy_n - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - __is_input_iterator<_InputIterator>::value && - !__is_random_access_iterator<_InputIterator>::value, - _OutputIterator ->::type -copy_n(_InputIterator __first, _Size __n, _OutputIterator __result) -{ - if (__n > 0) - { - *__result = *__first; - ++__result; - for (--__n; __n > 0; --__n) - { - ++__first; - *__result = *__first; - ++__result; - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - __is_random_access_iterator<_InputIterator>::value, - _OutputIterator ->::type -copy_n(_InputIterator __first, _Size __n, _OutputIterator __result) -{ - return _VSTD::copy(__first, __first + __n, __result); -} - -// move - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__move(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - for (; __first != __last; ++__first, ++__result) - *__result = _VSTD::move(*__first); - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_same::type, _Up>::value && - is_trivially_copy_assignable<_Up>::value, - _Up* ->::type -__move(_Tp* __first, _Tp* __last, _Up* __result) -{ - const size_t __n = static_cast(__last - __first); - _VSTD::memmove(__result, __first, __n * sizeof(_Up)); - return __result + __n; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -move(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - return _VSTD::__move(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result)); -} - -// move_backward - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__move_backward(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - while (__first != __last) - *--__result = _VSTD::move(*--__last); - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_same::type, _Up>::value && - is_trivially_copy_assignable<_Up>::value, - _Up* ->::type -__move_backward(_Tp* __first, _Tp* __last, _Up* __result) -{ - const size_t __n = static_cast(__last - __first); - __result -= __n; - _VSTD::memmove(__result, __first, __n * sizeof(_Up)); - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_BidirectionalIterator2 -move_backward(_BidirectionalIterator1 __first, _BidirectionalIterator1 __last, - _BidirectionalIterator2 __result) -{ - return _VSTD::__move_backward(__unwrap_iter(__first), __unwrap_iter(__last), __unwrap_iter(__result)); -} - -// iter_swap - -// moved to for better swap / noexcept support - -// transform - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -transform(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _UnaryOperation __op) -{ - for (; __first != __last; ++__first, ++__result) - *__result = __op(*__first); - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -transform(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, - _OutputIterator __result, _BinaryOperation __binary_op) -{ - for (; __first1 != __last1; ++__first1, ++__first2, ++__result) - *__result = __binary_op(*__first1, *__first2); - return __result; -} - -// replace - -template -inline _LIBCPP_INLINE_VISIBILITY -void -replace(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __old_value, const _Tp& __new_value) -{ - for (; __first != __last; ++__first) - if (*__first == __old_value) - *__first = __new_value; -} - -// replace_if - -template -inline _LIBCPP_INLINE_VISIBILITY -void -replace_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, const _Tp& __new_value) -{ - for (; __first != __last; ++__first) - if (__pred(*__first)) - *__first = __new_value; -} - -// replace_copy - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -replace_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, - const _Tp& __old_value, const _Tp& __new_value) -{ - for (; __first != __last; ++__first, ++__result) - if (*__first == __old_value) - *__result = __new_value; - else - *__result = *__first; - return __result; -} - -// replace_copy_if - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -replace_copy_if(_InputIterator __first, _InputIterator __last, _OutputIterator __result, - _Predicate __pred, const _Tp& __new_value) -{ - for (; __first != __last; ++__first, ++__result) - if (__pred(*__first)) - *__result = __new_value; - else - *__result = *__first; - return __result; -} - -// fill_n - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_, false_type) -{ - for (; __n > 0; ++__first, --__n) - *__first = __value_; - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -__fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_, true_type) -{ - if (__n > 0) - _VSTD::memset(__first, (unsigned char)__value_, (size_t)(__n)); - return __first + __n; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_) -{ - return _VSTD::__fill_n(__first, __n, __value_, integral_constant::value && - is_trivially_copy_assignable<_Tp>::value && - sizeof(_Tp) == 1>()); -} - -// fill - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__fill(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, forward_iterator_tag) -{ - for (; __first != __last; ++__first) - *__first = __value_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__fill(_RandomAccessIterator __first, _RandomAccessIterator __last, const _Tp& __value_, random_access_iterator_tag) -{ - _VSTD::fill_n(__first, __last - __first, __value_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -fill(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - _VSTD::__fill(__first, __last, __value_, typename iterator_traits<_ForwardIterator>::iterator_category()); -} - -// generate - -template -inline _LIBCPP_INLINE_VISIBILITY -void -generate(_ForwardIterator __first, _ForwardIterator __last, _Generator __gen) -{ - for (; __first != __last; ++__first) - *__first = __gen(); -} - -// generate_n - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -generate_n(_OutputIterator __first, _Size __n, _Generator __gen) -{ - for (; __n > 0; ++__first, --__n) - *__first = __gen(); - return __first; -} - -// remove - -template -_ForwardIterator -remove(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - __first = _VSTD::find(__first, __last, __value_); - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - { - if (!(*__i == __value_)) - { - *__first = _VSTD::move(*__i); - ++__first; - } - } - } - return __first; -} - -// remove_if - -template -_ForwardIterator -remove_if(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) -{ - __first = _VSTD::find_if<_ForwardIterator, typename add_lvalue_reference<_Predicate>::type> - (__first, __last, __pred); - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - { - if (!__pred(*__i)) - { - *__first = _VSTD::move(*__i); - ++__first; - } - } - } - return __first; -} - -// remove_copy - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -remove_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, const _Tp& __value_) -{ - for (; __first != __last; ++__first) - { - if (!(*__first == __value_)) - { - *__result = *__first; - ++__result; - } - } - return __result; -} - -// remove_copy_if - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -remove_copy_if(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _Predicate __pred) -{ - for (; __first != __last; ++__first) - { - if (!__pred(*__first)) - { - *__result = *__first; - ++__result; - } - } - return __result; -} - -// unique - -template -_ForwardIterator -unique(_ForwardIterator __first, _ForwardIterator __last, _BinaryPredicate __pred) -{ - __first = _VSTD::adjacent_find<_ForwardIterator, typename add_lvalue_reference<_BinaryPredicate>::type> - (__first, __last, __pred); - if (__first != __last) - { - // ... a a ? ... - // f i - _ForwardIterator __i = __first; - for (++__i; ++__i != __last;) - if (!__pred(*__first, *__i)) - *++__first = _VSTD::move(*__i); - ++__first; - } - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -unique(_ForwardIterator __first, _ForwardIterator __last) -{ - typedef typename iterator_traits<_ForwardIterator>::value_type __v; - return _VSTD::unique(__first, __last, __equal_to<__v>()); -} - -// unique_copy - -template -_OutputIterator -__unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _BinaryPredicate __pred, - input_iterator_tag, output_iterator_tag) -{ - if (__first != __last) - { - typename iterator_traits<_InputIterator>::value_type __t(*__first); - *__result = __t; - ++__result; - while (++__first != __last) - { - if (!__pred(__t, *__first)) - { - __t = *__first; - *__result = __t; - ++__result; - } - } - } - return __result; -} - -template -_OutputIterator -__unique_copy(_ForwardIterator __first, _ForwardIterator __last, _OutputIterator __result, _BinaryPredicate __pred, - forward_iterator_tag, output_iterator_tag) -{ - if (__first != __last) - { - _ForwardIterator __i = __first; - *__result = *__i; - ++__result; - while (++__first != __last) - { - if (!__pred(*__i, *__first)) - { - *__result = *__first; - ++__result; - __i = __first; - } - } - } - return __result; -} - -template -_ForwardIterator -__unique_copy(_InputIterator __first, _InputIterator __last, _ForwardIterator __result, _BinaryPredicate __pred, - input_iterator_tag, forward_iterator_tag) -{ - if (__first != __last) - { - *__result = *__first; - while (++__first != __last) - if (!__pred(*__result, *__first)) - *++__result = *__first; - ++__result; - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result, _BinaryPredicate __pred) -{ - return _VSTD::__unique_copy::type> - (__first, __last, __result, __pred, - typename iterator_traits<_InputIterator>::iterator_category(), - typename iterator_traits<_OutputIterator>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -unique_copy(_InputIterator __first, _InputIterator __last, _OutputIterator __result) -{ - typedef typename iterator_traits<_InputIterator>::value_type __v; - return _VSTD::unique_copy(__first, __last, __result, __equal_to<__v>()); -} - -// reverse - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__reverse(_BidirectionalIterator __first, _BidirectionalIterator __last, bidirectional_iterator_tag) -{ - while (__first != __last) - { - if (__first == --__last) - break; - swap(*__first, *__last); - ++__first; - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__reverse(_RandomAccessIterator __first, _RandomAccessIterator __last, random_access_iterator_tag) -{ - if (__first != __last) - for (; __first < --__last; ++__first) - swap(*__first, *__last); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -reverse(_BidirectionalIterator __first, _BidirectionalIterator __last) -{ - _VSTD::__reverse(__first, __last, typename iterator_traits<_BidirectionalIterator>::iterator_category()); -} - -// reverse_copy - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -reverse_copy(_BidirectionalIterator __first, _BidirectionalIterator __last, _OutputIterator __result) -{ - for (; __first != __last; ++__result) - *__result = *--__last; - return __result; -} - -// rotate - -template -_ForwardIterator -__rotate(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last, false_type) -{ - if (__first == __middle) - return __last; - if (__middle == __last) - return __first; - _ForwardIterator __i = __middle; - while (true) - { - swap(*__first, *__i); - ++__first; - if (++__i == __last) - break; - if (__first == __middle) - __middle = __i; - } - _ForwardIterator __r = __first; - if (__first != __middle) - { - __i = __middle; - while (true) - { - swap(*__first, *__i); - ++__first; - if (++__i == __last) - { - if (__first == __middle) - break; - __i = __middle; - } - else if (__first == __middle) - __middle = __i; - } - } - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Integral -__gcd(_Integral __x, _Integral __y) -{ - do - { - _Integral __t = __x % __y; - __x = __y; - __y = __t; - } while (__y); - return __x; -} - -template -_RandomAccessIterator -__rotate(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last, true_type) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - - if (__first == __middle) - return __last; - if (__middle == __last) - return __first; - const difference_type __m1 = __middle - __first; - const difference_type __m2 = __last - __middle; - if (__m1 == __m2) - { - _VSTD::swap_ranges(__first, __middle, __middle); - return __middle; - } - const difference_type __g = __gcd(__m1, __m2); - for (_RandomAccessIterator __p = __first + __g; __p != __first;) - { - value_type __t(*--__p); - _RandomAccessIterator __p1 = __p; - _RandomAccessIterator __p2 = __p1 + __m1; - do - { - *__p1 = *__p2; - __p1 = __p2; - const difference_type __d = __last - __p2; - if (__m1 < __d) - __p2 += __m1; - else - __p2 = __first + (__m1 - __d); - } while (__p2 != __p); - *__p1 = __t; - } - return __first + __m2; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -rotate(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last) -{ - return _VSTD::__rotate(__first, __middle, __last, - integral_constant - < - bool, - is_convertible - < - typename iterator_traits<_ForwardIterator>::iterator_category, - random_access_iterator_tag - >::value && - is_trivially_copy_assignable - < - typename iterator_traits<_ForwardIterator>::value_type - >::value - >()); -} - -// rotate_copy - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -rotate_copy(_ForwardIterator __first, _ForwardIterator __middle, _ForwardIterator __last, _OutputIterator __result) -{ - return _VSTD::copy(__first, __middle, _VSTD::copy(__middle, __last, __result)); -} - -// min_element - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -min_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp) -{ - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - if (__comp(*__i, *__first)) - __first = __i; - } - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -min_element(_ForwardIterator __first, _ForwardIterator __last) -{ - return _VSTD::min_element(__first, __last, - __less::value_type>()); -} - -// min - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Tp& -min(const _Tp& __a, const _Tp& __b, _Compare __comp) -{ - return __comp(__b, __a) ? __b : __a; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Tp& -min(const _Tp& __a, const _Tp& __b) -{ - return _VSTD::min(__a, __b, __less<_Tp>()); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -min(initializer_list<_Tp> __t, _Compare __comp) -{ - return *_VSTD::min_element(__t.begin(), __t.end(), __comp); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -min(initializer_list<_Tp> __t) -{ - return *_VSTD::min_element(__t.begin(), __t.end()); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -// max_element - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -max_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp) -{ - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - if (__comp(*__first, *__i)) - __first = __i; - } - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -max_element(_ForwardIterator __first, _ForwardIterator __last) -{ - return _VSTD::max_element(__first, __last, - __less::value_type>()); -} - -// max - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Tp& -max(const _Tp& __a, const _Tp& __b, _Compare __comp) -{ - return __comp(__a, __b) ? __b : __a; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Tp& -max(const _Tp& __a, const _Tp& __b) -{ - return _VSTD::max(__a, __b, __less<_Tp>()); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -max(initializer_list<_Tp> __t, _Compare __comp) -{ - return *_VSTD::max_element(__t.begin(), __t.end(), __comp); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -max(initializer_list<_Tp> __t) -{ - return *_VSTD::max_element(__t.begin(), __t.end()); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -// minmax_element - -template -std::pair<_ForwardIterator, _ForwardIterator> -minmax_element(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp) -{ - std::pair<_ForwardIterator, _ForwardIterator> __result(__first, __first); - if (__first != __last) - { - if (++__first != __last) - { - if (__comp(*__first, *__result.first)) - __result.first = __first; - else - __result.second = __first; - while (++__first != __last) - { - _ForwardIterator __i = __first; - if (++__first == __last) - { - if (__comp(*__i, *__result.first)) - __result.first = __i; - else if (!__comp(*__i, *__result.second)) - __result.second = __i; - break; - } - else - { - if (__comp(*__first, *__i)) - { - if (__comp(*__first, *__result.first)) - __result.first = __first; - if (!__comp(*__i, *__result.second)) - __result.second = __i; - } - else - { - if (__comp(*__i, *__result.first)) - __result.first = __i; - if (!__comp(*__first, *__result.second)) - __result.second = __first; - } - } - } - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -std::pair<_ForwardIterator, _ForwardIterator> -minmax_element(_ForwardIterator __first, _ForwardIterator __last) -{ - return _VSTD::minmax_element(__first, __last, __less::value_type>()); -} - -// minmax - -template -inline _LIBCPP_INLINE_VISIBILITY -pair -minmax(const _Tp& __a, const _Tp& __b, _Compare __comp) -{ - return __comp(__b, __a) ? pair(__b, __a) : - pair(__a, __b); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -pair -minmax(const _Tp& __a, const _Tp& __b) -{ - return _VSTD::minmax(__a, __b, __less<_Tp>()); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_Tp, _Tp> -minmax(initializer_list<_Tp> __t) -{ - pair __p = - _VSTD::minmax_element(__t.begin(), __t.end()); - return pair<_Tp, _Tp>(*__p.first, *__p.second); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_Tp, _Tp> -minmax(initializer_list<_Tp> __t, _Compare __comp) -{ - pair __p = - _VSTD::minmax_element(__t.begin(), __t.end(), __comp); - return pair<_Tp, _Tp>(*__p.first, *__p.second); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -// random_shuffle - -// __independent_bits_engine - -template -struct __log2_imp -{ - static const size_t value = _Xp & ((unsigned long long)(1) << _Rp) ? _Rp - : __log2_imp<_Xp, _Rp - 1>::value; -}; - -template -struct __log2_imp<_Xp, 0> -{ - static const size_t value = 0; -}; - -template -struct __log2_imp<0, _Rp> -{ - static const size_t value = _Rp + 1; -}; - -template -struct __log2 -{ - static const size_t value = __log2_imp<_Xp, - sizeof(_UI) * __CHAR_BIT__ - 1>::value; -}; - -template -class __independent_bits_engine -{ -public: - // types - typedef _UIntType result_type; - -private: - typedef typename _Engine::result_type _Engine_result_type; - typedef typename conditional - < - sizeof(_Engine_result_type) <= sizeof(result_type), - result_type, - _Engine_result_type - >::type _Working_result_type; - - _Engine& __e_; - size_t __w_; - size_t __w0_; - size_t __n_; - size_t __n0_; - _Working_result_type __y0_; - _Working_result_type __y1_; - _Engine_result_type __mask0_; - _Engine_result_type __mask1_; - -#ifdef _LIBCPP_HAS_NO_CONSTEXPR - static const _Working_result_type _Rp = _Engine::_Max - _Engine::_Min - + _Working_result_type(1); -#else - static _LIBCPP_CONSTEXPR const _Working_result_type _Rp = _Engine::max() - _Engine::min() - + _Working_result_type(1); -#endif - static _LIBCPP_CONSTEXPR const size_t __m = __log2<_Working_result_type, _Rp>::value; - static _LIBCPP_CONSTEXPR const size_t _WDt = numeric_limits<_Working_result_type>::digits; - static _LIBCPP_CONSTEXPR const size_t _EDt = numeric_limits<_Engine_result_type>::digits; - -public: - // constructors and seeding functions - __independent_bits_engine(_Engine& __e, size_t __w); - - // generating functions - result_type operator()() {return __eval(integral_constant());} - -private: - result_type __eval(false_type); - result_type __eval(true_type); -}; - -template -__independent_bits_engine<_Engine, _UIntType> - ::__independent_bits_engine(_Engine& __e, size_t __w) - : __e_(__e), - __w_(__w) -{ - __n_ = __w_ / __m + (__w_ % __m != 0); - __w0_ = __w_ / __n_; - if (_Rp == 0) - __y0_ = _Rp; - else if (__w0_ < _WDt) - __y0_ = (_Rp >> __w0_) << __w0_; - else - __y0_ = 0; - if (_Rp - __y0_ > __y0_ / __n_) - { - ++__n_; - __w0_ = __w_ / __n_; - if (__w0_ < _WDt) - __y0_ = (_Rp >> __w0_) << __w0_; - else - __y0_ = 0; - } - __n0_ = __n_ - __w_ % __n_; - if (__w0_ < _WDt - 1) - __y1_ = (_Rp >> (__w0_ + 1)) << (__w0_ + 1); - else - __y1_ = 0; - __mask0_ = __w0_ > 0 ? _Engine_result_type(~0) >> (_EDt - __w0_) : - _Engine_result_type(0); - __mask1_ = __w0_ < _EDt - 1 ? - _Engine_result_type(~0) >> (_EDt - (__w0_ + 1)) : - _Engine_result_type(~0); -} - -template -inline -_UIntType -__independent_bits_engine<_Engine, _UIntType>::__eval(false_type) -{ - return static_cast(__e_() & __mask0_); -} - -template -_UIntType -__independent_bits_engine<_Engine, _UIntType>::__eval(true_type) -{ - result_type _Sp = 0; - for (size_t __k = 0; __k < __n0_; ++__k) - { - _Engine_result_type __u; - do - { - __u = __e_() - _Engine::min(); - } while (__u >= __y0_); - if (__w0_ < _WDt) - _Sp <<= __w0_; - else - _Sp = 0; - _Sp += __u & __mask0_; - } - for (size_t __k = __n0_; __k < __n_; ++__k) - { - _Engine_result_type __u; - do - { - __u = __e_() - _Engine::min(); - } while (__u >= __y1_); - if (__w0_ < _WDt - 1) - _Sp <<= __w0_ + 1; - else - _Sp = 0; - _Sp += __u & __mask1_; - } - return _Sp; -} - -// uniform_int_distribution - -template -class uniform_int_distribution -{ -public: - // types - typedef _IntType result_type; - - class param_type - { - result_type __a_; - result_type __b_; - public: - typedef uniform_int_distribution distribution_type; - - explicit param_type(result_type __a = 0, - result_type __b = numeric_limits::max()) - : __a_(__a), __b_(__b) {} - - result_type a() const {return __a_;} - result_type b() const {return __b_;} - - friend bool operator==(const param_type& __x, const param_type& __y) - {return __x.__a_ == __y.__a_ && __x.__b_ == __y.__b_;} - friend bool operator!=(const param_type& __x, const param_type& __y) - {return !(__x == __y);} - }; - -private: - param_type __p_; - -public: - // constructors and reset functions - explicit uniform_int_distribution(result_type __a = 0, - result_type __b = numeric_limits::max()) - : __p_(param_type(__a, __b)) {} - explicit uniform_int_distribution(const param_type& __p) : __p_(__p) {} - void reset() {} - - // generating functions - template result_type operator()(_URNG& __g) - {return (*this)(__g, __p_);} - template result_type operator()(_URNG& __g, const param_type& __p); - - // property functions - result_type a() const {return __p_.a();} - result_type b() const {return __p_.b();} - - param_type param() const {return __p_;} - void param(const param_type& __p) {__p_ = __p;} - - result_type min() const {return a();} - result_type max() const {return b();} - - friend bool operator==(const uniform_int_distribution& __x, - const uniform_int_distribution& __y) - {return __x.__p_ == __y.__p_;} - friend bool operator!=(const uniform_int_distribution& __x, - const uniform_int_distribution& __y) - {return !(__x == __y);} -}; - -template -template -typename uniform_int_distribution<_IntType>::result_type -uniform_int_distribution<_IntType>::operator()(_URNG& __g, const param_type& __p) -{ - typedef typename conditional::type _UIntType; - const _UIntType _Rp = __p.b() - __p.a() + _UIntType(1); - if (_Rp == 1) - return __p.a(); - const size_t _Dt = numeric_limits<_UIntType>::digits; - typedef __independent_bits_engine<_URNG, _UIntType> _Eng; - if (_Rp == 0) - return static_cast(_Eng(__g, _Dt)()); - size_t __w = _Dt - __clz(_Rp) - 1; - if ((_Rp & (_UIntType(~0) >> (_Dt - __w))) != 0) - ++__w; - _Eng __e(__g, __w); - _UIntType __u; - do - { - __u = __e(); - } while (__u >= _Rp); - return static_cast(__u + __p.a()); -} - -class __rs_default; - -__rs_default __rs_get(); - -class __rs_default -{ - static unsigned __c_; - - __rs_default(); -public: - typedef unsigned result_type; - - static const result_type _Min = 0; - static const result_type _Max = 0xFFFFFFFF; - - __rs_default(const __rs_default&); - ~__rs_default(); - - result_type operator()(); - - static _LIBCPP_CONSTEXPR result_type min() {return _Min;} - static _LIBCPP_CONSTEXPR result_type max() {return _Max;} - - friend __rs_default __rs_get(); -}; - -__rs_default __rs_get(); - -template -void -random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef uniform_int_distribution _Dp; - typedef typename _Dp::param_type _Pp; - difference_type __d = __last - __first; - if (__d > 1) - { - _Dp __uid; - __rs_default __g = __rs_get(); - for (--__last, --__d; __first < __last; ++__first, --__d) - { - difference_type __i = __uid(__g, _Pp(0, __d)); - if (__i != difference_type(0)) - swap(*__first, *(__first + __i)); - } - } -} - -template -void -random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _RandomNumberGenerator&& __rand) -#else - _RandomNumberGenerator& __rand) -#endif -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - difference_type __d = __last - __first; - if (__d > 1) - { - for (--__last; __first < __last; ++__first, --__d) - { - difference_type __i = __rand(__d); - swap(*__first, *(__first + __i)); - } - } -} - -template - void shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _UniformRandomNumberGenerator&& __g) -#else - _UniformRandomNumberGenerator& __g) -#endif -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef uniform_int_distribution _Dp; - typedef typename _Dp::param_type _Pp; - difference_type __d = __last - __first; - if (__d > 1) - { - _Dp __uid; - for (--__last, --__d; __first < __last; ++__first, --__d) - { - difference_type __i = __uid(__g, _Pp(0, __d)); - if (__i != difference_type(0)) - swap(*__first, *(__first + __i)); - } - } -} - -template -bool -is_partitioned(_InputIterator __first, _InputIterator __last, _Predicate __pred) -{ - for (; __first != __last; ++__first) - if (!__pred(*__first)) - break; - for (; __first != __last; ++__first) - if (__pred(*__first)) - return false; - return true; -} - -// partition - -template -_ForwardIterator -__partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, forward_iterator_tag) -{ - while (true) - { - if (__first == __last) - return __first; - if (!__pred(*__first)) - break; - ++__first; - } - for (_ForwardIterator __p = __first; ++__p != __last;) - { - if (__pred(*__p)) - { - swap(*__first, *__p); - ++__first; - } - } - return __first; -} - -template -_BidirectionalIterator -__partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred, - bidirectional_iterator_tag) -{ - while (true) - { - while (true) - { - if (__first == __last) - return __first; - if (!__pred(*__first)) - break; - ++__first; - } - do - { - if (__first == --__last) - return __first; - } while (!__pred(*__last)); - swap(*__first, *__last); - ++__first; - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) -{ - return _VSTD::__partition::type> - (__first, __last, __pred, typename iterator_traits<_ForwardIterator>::iterator_category()); -} - -// partition_copy - -template -pair<_OutputIterator1, _OutputIterator2> -partition_copy(_InputIterator __first, _InputIterator __last, - _OutputIterator1 __out_true, _OutputIterator2 __out_false, - _Predicate __pred) -{ - for (; __first != __last; ++__first) - { - if (__pred(*__first)) - { - *__out_true = *__first; - ++__out_true; - } - else - { - *__out_false = *__first; - ++__out_false; - } - } - return pair<_OutputIterator1, _OutputIterator2>(__out_true, __out_false); -} - -// partition_point - -template -_ForwardIterator -partition_point(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) -{ - typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type; - difference_type __len = _VSTD::distance(__first, __last); - while (__len != 0) - { - difference_type __l2 = __len / 2; - _ForwardIterator __m = __first; - _VSTD::advance(__m, __l2); - if (__pred(*__m)) - { - __first = ++__m; - __len -= __l2 + 1; - } - else - __len = __l2; - } - return __first; -} - -// stable_partition - -template -_ForwardIterator -__stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, - _Distance __len, _Pair __p, forward_iterator_tag __fit) -{ - // *__first is known to be false - // __len >= 1 - if (__len == 1) - return __first; - if (__len == 2) - { - _ForwardIterator __m = __first; - if (__pred(*++__m)) - { - swap(*__first, *__m); - return __m; - } - return __first; - } - if (__len <= __p.second) - { // The buffer is big enough to use - typedef typename iterator_traits<_ForwardIterator>::value_type value_type; - __destruct_n __d(0); - unique_ptr __h(__p.first, __d); - // Move the falses into the temporary buffer, and the trues to the front of the line - // Update __first to always point to the end of the trues - value_type* __t = __p.first; - ::new(__t) value_type(_VSTD::move(*__first)); - __d.__incr((value_type*)0); - ++__t; - _ForwardIterator __i = __first; - while (++__i != __last) - { - if (__pred(*__i)) - { - *__first = _VSTD::move(*__i); - ++__first; - } - else - { - ::new(__t) value_type(_VSTD::move(*__i)); - __d.__incr((value_type*)0); - ++__t; - } - } - // All trues now at start of range, all falses in buffer - // Move falses back into range, but don't mess up __first which points to first false - __i = __first; - for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i) - *__i = _VSTD::move(*__t2); - // __h destructs moved-from values out of the temp buffer, but doesn't deallocate buffer - return __first; - } - // Else not enough buffer, do in place - // __len >= 3 - _ForwardIterator __m = __first; - _Distance __len2 = __len / 2; // __len2 >= 2 - _VSTD::advance(__m, __len2); - // recurse on [__first, __m), *__first know to be false - // F????????????????? - // f m l - typedef typename add_lvalue_reference<_Predicate>::type _PredRef; - _ForwardIterator __first_false = __stable_partition<_PredRef>(__first, __m, __pred, __len2, __p, __fit); - // TTTFFFFF?????????? - // f ff m l - // recurse on [__m, __last], except increase __m until *(__m) is false, *__last know to be true - _ForwardIterator __m1 = __m; - _ForwardIterator __second_false = __last; - _Distance __len_half = __len - __len2; - while (__pred(*__m1)) - { - if (++__m1 == __last) - goto __second_half_done; - --__len_half; - } - // TTTFFFFFTTTF?????? - // f ff m m1 l - __second_false = __stable_partition<_PredRef>(__m1, __last, __pred, __len_half, __p, __fit); -__second_half_done: - // TTTFFFFFTTTTTFFFFF - // f ff m sf l - return _VSTD::rotate(__first_false, __m, __second_false); - // TTTTTTTTFFFFFFFFFF - // | -} - -struct __return_temporary_buffer -{ - template - _LIBCPP_INLINE_VISIBILITY void operator()(_Tp* __p) const {_VSTD::return_temporary_buffer(__p);} -}; - -template -_ForwardIterator -__stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred, - forward_iterator_tag) -{ - const unsigned __alloc_limit = 3; // might want to make this a function of trivial assignment - // Either prove all true and return __first or point to first false - while (true) - { - if (__first == __last) - return __first; - if (!__pred(*__first)) - break; - ++__first; - } - // We now have a reduced range [__first, __last) - // *__first is known to be false - typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type; - typedef typename iterator_traits<_ForwardIterator>::value_type value_type; - difference_type __len = _VSTD::distance(__first, __last); - pair __p(0, 0); - unique_ptr __h; - if (__len >= __alloc_limit) - { - __p = _VSTD::get_temporary_buffer(__len); - __h.reset(__p.first); - } - return __stable_partition::type> - (__first, __last, __pred, __len, __p, forward_iterator_tag()); -} - -template -_BidirectionalIterator -__stable_partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred, - _Distance __len, _Pair __p, bidirectional_iterator_tag __bit) -{ - // *__first is known to be false - // *__last is known to be true - // __len >= 2 - if (__len == 2) - { - swap(*__first, *__last); - return __last; - } - if (__len == 3) - { - _BidirectionalIterator __m = __first; - if (__pred(*++__m)) - { - swap(*__first, *__m); - swap(*__m, *__last); - return __last; - } - swap(*__m, *__last); - swap(*__first, *__m); - return __m; - } - if (__len <= __p.second) - { // The buffer is big enough to use - typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type; - __destruct_n __d(0); - unique_ptr __h(__p.first, __d); - // Move the falses into the temporary buffer, and the trues to the front of the line - // Update __first to always point to the end of the trues - value_type* __t = __p.first; - ::new(__t) value_type(_VSTD::move(*__first)); - __d.__incr((value_type*)0); - ++__t; - _BidirectionalIterator __i = __first; - while (++__i != __last) - { - if (__pred(*__i)) - { - *__first = _VSTD::move(*__i); - ++__first; - } - else - { - ::new(__t) value_type(_VSTD::move(*__i)); - __d.__incr((value_type*)0); - ++__t; - } - } - // move *__last, known to be true - *__first = _VSTD::move(*__i); - __i = ++__first; - // All trues now at start of range, all falses in buffer - // Move falses back into range, but don't mess up __first which points to first false - for (value_type* __t2 = __p.first; __t2 < __t; ++__t2, ++__i) - *__i = _VSTD::move(*__t2); - // __h destructs moved-from values out of the temp buffer, but doesn't deallocate buffer - return __first; - } - // Else not enough buffer, do in place - // __len >= 4 - _BidirectionalIterator __m = __first; - _Distance __len2 = __len / 2; // __len2 >= 2 - _VSTD::advance(__m, __len2); - // recurse on [__first, __m-1], except reduce __m-1 until *(__m-1) is true, *__first know to be false - // F????????????????T - // f m l - _BidirectionalIterator __m1 = __m; - _BidirectionalIterator __first_false = __first; - _Distance __len_half = __len2; - while (!__pred(*--__m1)) - { - if (__m1 == __first) - goto __first_half_done; - --__len_half; - } - // F???TFFF?????????T - // f m1 m l - typedef typename add_lvalue_reference<_Predicate>::type _PredRef; - __first_false = __stable_partition<_PredRef>(__first, __m1, __pred, __len_half, __p, __bit); -__first_half_done: - // TTTFFFFF?????????T - // f ff m l - // recurse on [__m, __last], except increase __m until *(__m) is false, *__last know to be true - __m1 = __m; - _BidirectionalIterator __second_false = __last; - ++__second_false; - __len_half = __len - __len2; - while (__pred(*__m1)) - { - if (++__m1 == __last) - goto __second_half_done; - --__len_half; - } - // TTTFFFFFTTTF?????T - // f ff m m1 l - __second_false = __stable_partition<_PredRef>(__m1, __last, __pred, __len_half, __p, __bit); -__second_half_done: - // TTTFFFFFTTTTTFFFFF - // f ff m sf l - return _VSTD::rotate(__first_false, __m, __second_false); - // TTTTTTTTFFFFFFFFFF - // | -} - -template -_BidirectionalIterator -__stable_partition(_BidirectionalIterator __first, _BidirectionalIterator __last, _Predicate __pred, - bidirectional_iterator_tag) -{ - typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type; - typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type; - const difference_type __alloc_limit = 4; // might want to make this a function of trivial assignment - // Either prove all true and return __first or point to first false - while (true) - { - if (__first == __last) - return __first; - if (!__pred(*__first)) - break; - ++__first; - } - // __first points to first false, everything prior to __first is already set. - // Either prove [__first, __last) is all false and return __first, or point __last to last true - do - { - if (__first == --__last) - return __first; - } while (!__pred(*__last)); - // We now have a reduced range [__first, __last] - // *__first is known to be false - // *__last is known to be true - // __len >= 2 - difference_type __len = _VSTD::distance(__first, __last) + 1; - pair __p(0, 0); - unique_ptr __h; - if (__len >= __alloc_limit) - { - __p = _VSTD::get_temporary_buffer(__len); - __h.reset(__p.first); - } - return __stable_partition::type> - (__first, __last, __pred, __len, __p, bidirectional_iterator_tag()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -stable_partition(_ForwardIterator __first, _ForwardIterator __last, _Predicate __pred) -{ - return __stable_partition::type> - (__first, __last, __pred, typename iterator_traits<_ForwardIterator>::iterator_category()); -} - -// is_sorted_until - -template -_ForwardIterator -is_sorted_until(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp) -{ - if (__first != __last) - { - _ForwardIterator __i = __first; - while (++__i != __last) - { - if (__comp(*__i, *__first)) - return __i; - __first = __i; - } - } - return __last; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -is_sorted_until(_ForwardIterator __first, _ForwardIterator __last) -{ - return _VSTD::is_sorted_until(__first, __last, __less::value_type>()); -} - -// is_sorted - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -is_sorted(_ForwardIterator __first, _ForwardIterator __last, _Compare __comp) -{ - return _VSTD::is_sorted_until(__first, __last, __comp) == __last; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -is_sorted(_ForwardIterator __first, _ForwardIterator __last) -{ - return _VSTD::is_sorted(__first, __last, __less::value_type>()); -} - -// sort - -// stable, 2-3 compares, 0-2 swaps - -template -unsigned -__sort3(_ForwardIterator __x, _ForwardIterator __y, _ForwardIterator __z, _Compare __c) -{ - unsigned __r = 0; - if (!__c(*__y, *__x)) // if x <= y - { - if (!__c(*__z, *__y)) // if y <= z - return __r; // x <= y && y <= z - // x <= y && y > z - swap(*__y, *__z); // x <= z && y < z - __r = 1; - if (__c(*__y, *__x)) // if x > y - { - swap(*__x, *__y); // x < y && y <= z - __r = 2; - } - return __r; // x <= y && y < z - } - if (__c(*__z, *__y)) // x > y, if y > z - { - swap(*__x, *__z); // x < y && y < z - __r = 1; - return __r; - } - swap(*__x, *__y); // x > y && y <= z - __r = 1; // x < y && x <= z - if (__c(*__z, *__y)) // if y > z - { - swap(*__y, *__z); // x <= y && y < z - __r = 2; - } - return __r; -} // x <= y && y <= z - -// stable, 3-6 compares, 0-5 swaps - -template -unsigned -__sort4(_ForwardIterator __x1, _ForwardIterator __x2, _ForwardIterator __x3, - _ForwardIterator __x4, _Compare __c) -{ - unsigned __r = __sort3<_Compare>(__x1, __x2, __x3, __c); - if (__c(*__x4, *__x3)) - { - swap(*__x3, *__x4); - ++__r; - if (__c(*__x3, *__x2)) - { - swap(*__x2, *__x3); - ++__r; - if (__c(*__x2, *__x1)) - { - swap(*__x1, *__x2); - ++__r; - } - } - } - return __r; -} - -// stable, 4-10 compares, 0-9 swaps - -template -unsigned -__sort5(_ForwardIterator __x1, _ForwardIterator __x2, _ForwardIterator __x3, - _ForwardIterator __x4, _ForwardIterator __x5, _Compare __c) -{ - unsigned __r = __sort4<_Compare>(__x1, __x2, __x3, __x4, __c); - if (__c(*__x5, *__x4)) - { - swap(*__x4, *__x5); - ++__r; - if (__c(*__x4, *__x3)) - { - swap(*__x3, *__x4); - ++__r; - if (__c(*__x3, *__x2)) - { - swap(*__x2, *__x3); - ++__r; - if (__c(*__x2, *__x1)) - { - swap(*__x1, *__x2); - ++__r; - } - } - } - } - return __r; -} - -// Assumes size > 0 -template -void -__selection_sort(_BirdirectionalIterator __first, _BirdirectionalIterator __last, _Compare __comp) -{ - _BirdirectionalIterator __lm1 = __last; - for (--__lm1; __first != __lm1; ++__first) - { - _BirdirectionalIterator __i = _VSTD::min_element<_BirdirectionalIterator, - typename add_lvalue_reference<_Compare>::type> - (__first, __last, __comp); - if (__i != __first) - swap(*__first, *__i); - } -} - -template -void -__insertion_sort(_BirdirectionalIterator __first, _BirdirectionalIterator __last, _Compare __comp) -{ - typedef typename iterator_traits<_BirdirectionalIterator>::value_type value_type; - if (__first != __last) - { - _BirdirectionalIterator __i = __first; - for (++__i; __i != __last; ++__i) - { - _BirdirectionalIterator __j = __i; - value_type __t(_VSTD::move(*__j)); - for (_BirdirectionalIterator __k = __i; __k != __first && __comp(__t, *--__k); --__j) - *__j = _VSTD::move(*__k); - *__j = _VSTD::move(__t); - } - } -} - -template -void -__insertion_sort_3(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - _RandomAccessIterator __j = __first+2; - __sort3<_Compare>(__first, __first+1, __j, __comp); - for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i) - { - if (__comp(*__i, *__j)) - { - value_type __t(_VSTD::move(*__i)); - _RandomAccessIterator __k = __j; - __j = __i; - do - { - *__j = _VSTD::move(*__k); - __j = __k; - } while (__j != __first && __comp(__t, *--__k)); - *__j = _VSTD::move(__t); - } - __j = __i; - } -} - -template -bool -__insertion_sort_incomplete(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - switch (__last - __first) - { - case 0: - case 1: - return true; - case 2: - if (__comp(*--__last, *__first)) - swap(*__first, *__last); - return true; - case 3: - _VSTD::__sort3<_Compare>(__first, __first+1, --__last, __comp); - return true; - case 4: - _VSTD::__sort4<_Compare>(__first, __first+1, __first+2, --__last, __comp); - return true; - case 5: - _VSTD::__sort5<_Compare>(__first, __first+1, __first+2, __first+3, --__last, __comp); - return true; - } - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - _RandomAccessIterator __j = __first+2; - __sort3<_Compare>(__first, __first+1, __j, __comp); - const unsigned __limit = 8; - unsigned __count = 0; - for (_RandomAccessIterator __i = __j+1; __i != __last; ++__i) - { - if (__comp(*__i, *__j)) - { - value_type __t(_VSTD::move(*__i)); - _RandomAccessIterator __k = __j; - __j = __i; - do - { - *__j = _VSTD::move(*__k); - __j = __k; - } while (__j != __first && __comp(__t, *--__k)); - *__j = _VSTD::move(__t); - if (++__count == __limit) - return ++__i == __last; - } - __j = __i; - } - return true; -} - -template -void -__insertion_sort_move(_BirdirectionalIterator __first1, _BirdirectionalIterator __last1, - typename iterator_traits<_BirdirectionalIterator>::value_type* __first2, _Compare __comp) -{ - typedef typename iterator_traits<_BirdirectionalIterator>::value_type value_type; - if (__first1 != __last1) - { - __destruct_n __d(0); - unique_ptr __h(__first2, __d); - value_type* __last2 = __first2; - ::new(__last2) value_type(_VSTD::move(*__first1)); - __d.__incr((value_type*)0); - for (++__last2; ++__first1 != __last1; ++__last2) - { - value_type* __j2 = __last2; - value_type* __i2 = __j2; - if (__comp(*__first1, *--__i2)) - { - ::new(__j2) value_type(_VSTD::move(*__i2)); - __d.__incr((value_type*)0); - for (--__j2; __i2 != __first2 && __comp(*__first1, *--__i2); --__j2) - *__j2 = _VSTD::move(*__i2); - *__j2 = _VSTD::move(*__first1); - } - else - { - ::new(__j2) value_type(_VSTD::move(*__first1)); - __d.__incr((value_type*)0); - } - } - __h.release(); - } -} - -template -void -__sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - // _Compare is known to be a reference type - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - const difference_type __limit = is_trivially_copy_constructible::value && - is_trivially_copy_assignable::value ? 30 : 6; - while (true) - { - __restart: - difference_type __len = __last - __first; - switch (__len) - { - case 0: - case 1: - return; - case 2: - if (__comp(*--__last, *__first)) - swap(*__first, *__last); - return; - case 3: - _VSTD::__sort3<_Compare>(__first, __first+1, --__last, __comp); - return; - case 4: - _VSTD::__sort4<_Compare>(__first, __first+1, __first+2, --__last, __comp); - return; - case 5: - _VSTD::__sort5<_Compare>(__first, __first+1, __first+2, __first+3, --__last, __comp); - return; - } - if (__len <= __limit) - { - _VSTD::__insertion_sort_3<_Compare>(__first, __last, __comp); - return; - } - // __len > 5 - _RandomAccessIterator __m = __first; - _RandomAccessIterator __lm1 = __last; - --__lm1; - unsigned __n_swaps; - { - difference_type __delta; - if (__len >= 1000) - { - __delta = __len/2; - __m += __delta; - __delta /= 2; - __n_swaps = _VSTD::__sort5<_Compare>(__first, __first + __delta, __m, __m+__delta, __lm1, __comp); - } - else - { - __delta = __len/2; - __m += __delta; - __n_swaps = _VSTD::__sort3<_Compare>(__first, __m, __lm1, __comp); - } - } - // *__m is median - // partition [__first, __m) < *__m and *__m <= [__m, __last) - // (this inhibits tossing elements equivalent to __m around unnecessarily) - _RandomAccessIterator __i = __first; - _RandomAccessIterator __j = __lm1; - // j points beyond range to be tested, *__m is known to be <= *__lm1 - // The search going up is known to be guarded but the search coming down isn't. - // Prime the downward search with a guard. - if (!__comp(*__i, *__m)) // if *__first == *__m - { - // *__first == *__m, *__first doesn't go in first part - // manually guard downward moving __j against __i - while (true) - { - if (__i == --__j) - { - // *__first == *__m, *__m <= all other elements - // Parition instead into [__first, __i) == *__first and *__first < [__i, __last) - ++__i; // __first + 1 - __j = __last; - if (!__comp(*__first, *--__j)) // we need a guard if *__first == *(__last-1) - { - while (true) - { - if (__i == __j) - return; // [__first, __last) all equivalent elements - if (__comp(*__first, *__i)) - { - swap(*__i, *__j); - ++__n_swaps; - ++__i; - break; - } - ++__i; - } - } - // [__first, __i) == *__first and *__first < [__j, __last) and __j == __last - 1 - if (__i == __j) - return; - while (true) - { - while (!__comp(*__first, *__i)) - ++__i; - while (__comp(*__first, *--__j)) - ; - if (__i >= __j) - break; - swap(*__i, *__j); - ++__n_swaps; - ++__i; - } - // [__first, __i) == *__first and *__first < [__i, __last) - // The first part is sorted, sort the secod part - // _VSTD::__sort<_Compare>(__i, __last, __comp); - __first = __i; - goto __restart; - } - if (__comp(*__j, *__m)) - { - swap(*__i, *__j); - ++__n_swaps; - break; // found guard for downward moving __j, now use unguarded partition - } - } - } - // It is known that *__i < *__m - ++__i; - // j points beyond range to be tested, *__m is known to be <= *__lm1 - // if not yet partitioned... - if (__i < __j) - { - // known that *(__i - 1) < *__m - // known that __i <= __m - while (true) - { - // __m still guards upward moving __i - while (__comp(*__i, *__m)) - ++__i; - // It is now known that a guard exists for downward moving __j - while (!__comp(*--__j, *__m)) - ; - if (__i > __j) - break; - swap(*__i, *__j); - ++__n_swaps; - // It is known that __m != __j - // If __m just moved, follow it - if (__m == __i) - __m = __j; - ++__i; - } - } - // [__first, __i) < *__m and *__m <= [__i, __last) - if (__i != __m && __comp(*__m, *__i)) - { - swap(*__i, *__m); - ++__n_swaps; - } - // [__first, __i) < *__i and *__i <= [__i+1, __last) - // If we were given a perfect partition, see if insertion sort is quick... - if (__n_swaps == 0) - { - bool __fs = _VSTD::__insertion_sort_incomplete<_Compare>(__first, __i, __comp); - if (_VSTD::__insertion_sort_incomplete<_Compare>(__i+1, __last, __comp)) - { - if (__fs) - return; - __last = __i; - continue; - } - else - { - if (__fs) - { - __first = ++__i; - continue; - } - } - } - // sort smaller range with recursive call and larger with tail recursion elimination - if (__i - __first < __last - __i) - { - _VSTD::__sort<_Compare>(__first, __i, __comp); - // _VSTD::__sort<_Compare>(__i+1, __last, __comp); - __first = ++__i; - } - else - { - _VSTD::__sort<_Compare>(__i+1, __last, __comp); - // _VSTD::__sort<_Compare>(__first, __i, __comp); - __last = __i; - } - } -} - -// This forwarder keeps the top call and the recursive calls using the same instantiation, forcing a reference _Compare -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __sort<_Comp_ref>(__first, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __sort<_Comp_ref>(__first, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::sort(__first, __last, __less::value_type>()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort(_Tp** __first, _Tp** __last) -{ - _VSTD::sort((size_t*)__first, (size_t*)__last, __less()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort(__wrap_iter<_Tp*> __first, __wrap_iter<_Tp*> __last) -{ - _VSTD::sort(__first.base(), __last.base()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort(__wrap_iter<_Tp*> __first, __wrap_iter<_Tp*> __last, _Compare __comp) -{ - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - _VSTD::sort<_Tp*, _Comp_ref>(__first.base(), __last.base(), __comp); -} - -#ifdef _MSC_VER -#pragma warning( push ) -#pragma warning( disable: 4231) -#endif // _MSC_VER -extern template void __sort<__less&, char*>(char*, char*, __less&); -extern template void __sort<__less&, wchar_t*>(wchar_t*, wchar_t*, __less&); -extern template void __sort<__less&, signed char*>(signed char*, signed char*, __less&); -extern template void __sort<__less&, unsigned char*>(unsigned char*, unsigned char*, __less&); -extern template void __sort<__less&, short*>(short*, short*, __less&); -extern template void __sort<__less&, unsigned short*>(unsigned short*, unsigned short*, __less&); -extern template void __sort<__less&, int*>(int*, int*, __less&); -extern template void __sort<__less&, unsigned*>(unsigned*, unsigned*, __less&); -extern template void __sort<__less&, long*>(long*, long*, __less&); -extern template void __sort<__less&, unsigned long*>(unsigned long*, unsigned long*, __less&); -extern template void __sort<__less&, long long*>(long long*, long long*, __less&); -extern template void __sort<__less&, unsigned long long*>(unsigned long long*, unsigned long long*, __less&); -extern template void __sort<__less&, float*>(float*, float*, __less&); -extern template void __sort<__less&, double*>(double*, double*, __less&); -extern template void __sort<__less&, long double*>(long double*, long double*, __less&); - -extern template bool __insertion_sort_incomplete<__less&, char*>(char*, char*, __less&); -extern template bool __insertion_sort_incomplete<__less&, wchar_t*>(wchar_t*, wchar_t*, __less&); -extern template bool __insertion_sort_incomplete<__less&, signed char*>(signed char*, signed char*, __less&); -extern template bool __insertion_sort_incomplete<__less&, unsigned char*>(unsigned char*, unsigned char*, __less&); -extern template bool __insertion_sort_incomplete<__less&, short*>(short*, short*, __less&); -extern template bool __insertion_sort_incomplete<__less&, unsigned short*>(unsigned short*, unsigned short*, __less&); -extern template bool __insertion_sort_incomplete<__less&, int*>(int*, int*, __less&); -extern template bool __insertion_sort_incomplete<__less&, unsigned*>(unsigned*, unsigned*, __less&); -extern template bool __insertion_sort_incomplete<__less&, long*>(long*, long*, __less&); -extern template bool __insertion_sort_incomplete<__less&, unsigned long*>(unsigned long*, unsigned long*, __less&); -extern template bool __insertion_sort_incomplete<__less&, long long*>(long long*, long long*, __less&); -extern template bool __insertion_sort_incomplete<__less&, unsigned long long*>(unsigned long long*, unsigned long long*, __less&); -extern template bool __insertion_sort_incomplete<__less&, float*>(float*, float*, __less&); -extern template bool __insertion_sort_incomplete<__less&, double*>(double*, double*, __less&); -extern template bool __insertion_sort_incomplete<__less&, long double*>(long double*, long double*, __less&); - -extern template unsigned __sort5<__less&, long double*>(long double*, long double*, long double*, long double*, long double*, __less&); -#ifdef _MSC_VER -#pragma warning( pop ) -#endif // _MSC_VER - -// lower_bound - -template -_ForwardIterator -__lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ - typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type; - difference_type __len = _VSTD::distance(__first, __last); - while (__len != 0) - { - difference_type __l2 = __len / 2; - _ForwardIterator __m = __first; - _VSTD::advance(__m, __l2); - if (__comp(*__m, __value_)) - { - __first = ++__m; - __len -= __l2 + 1; - } - else - __len = __l2; - } - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __lower_bound<_Comp_ref>(__first, __last, __value_, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __lower_bound<_Comp_ref>(__first, __last, __value_, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -lower_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - return _VSTD::lower_bound(__first, __last, __value_, - __less::value_type, _Tp>()); -} - -// upper_bound - -template -_ForwardIterator -__upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ - typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type; - difference_type __len = _VSTD::distance(__first, __last); - while (__len != 0) - { - difference_type __l2 = __len / 2; - _ForwardIterator __m = __first; - _VSTD::advance(__m, __l2); - if (__comp(__value_, *__m)) - __len = __l2; - else - { - __first = ++__m; - __len -= __l2 + 1; - } - } - return __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __upper_bound<_Comp_ref>(__first, __last, __value_, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __upper_bound<_Comp_ref>(__first, __last, __value_, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIterator -upper_bound(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - return _VSTD::upper_bound(__first, __last, __value_, - __less<_Tp, typename iterator_traits<_ForwardIterator>::value_type>()); -} - -// equal_range - -template -pair<_ForwardIterator, _ForwardIterator> -__equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ - typedef typename iterator_traits<_ForwardIterator>::difference_type difference_type; - difference_type __len = _VSTD::distance(__first, __last); - while (__len != 0) - { - difference_type __l2 = __len / 2; - _ForwardIterator __m = __first; - _VSTD::advance(__m, __l2); - if (__comp(*__m, __value_)) - { - __first = ++__m; - __len -= __l2 + 1; - } - else if (__comp(__value_, *__m)) - { - __last = __m; - __len = __l2; - } - else - { - _ForwardIterator __mp1 = __m; - return pair<_ForwardIterator, _ForwardIterator> - ( - __lower_bound<_Compare>(__first, __m, __value_, __comp), - __upper_bound<_Compare>(++__mp1, __last, __value_, __comp) - ); - } - } - return pair<_ForwardIterator, _ForwardIterator>(__first, __first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_ForwardIterator, _ForwardIterator> -equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __equal_range<_Comp_ref>(__first, __last, __value_, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __equal_range<_Comp_ref>(__first, __last, __value_, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -pair<_ForwardIterator, _ForwardIterator> -equal_range(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - return _VSTD::equal_range(__first, __last, __value_, - __less::value_type, _Tp>()); -} - -// binary_search - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -__binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ - __first = __lower_bound<_Compare>(__first, __last, __value_, __comp); - return __first != __last && !__comp(__value_, *__first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __binary_search<_Comp_ref>(__first, __last, __value_, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __binary_search<_Comp_ref>(__first, __last, __value_, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -binary_search(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value_) -{ - return _VSTD::binary_search(__first, __last, __value_, - __less::value_type, _Tp>()); -} - -// merge - -template -_OutputIterator -__merge(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ - for (; __first1 != __last1; ++__result) - { - if (__first2 == __last2) - return _VSTD::copy(__first1, __last1, __result); - if (__comp(*__first2, *__first1)) - { - *__result = *__first2; - ++__first2; - } - else - { - *__result = *__first1; - ++__first1; - } - } - return _VSTD::copy(__first2, __last2, __result); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -merge(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return _VSTD::__merge<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return _VSTD::__merge<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -merge(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result) -{ - typedef typename iterator_traits<_InputIterator1>::value_type __v1; - typedef typename iterator_traits<_InputIterator2>::value_type __v2; - return merge(__first1, __last1, __first2, __last2, __result, __less<__v1, __v2>()); -} - -// inplace_merge - -template -void -__buffered_inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last, - _Compare __comp, typename iterator_traits<_BidirectionalIterator>::difference_type __len1, - typename iterator_traits<_BidirectionalIterator>::difference_type __len2, - typename iterator_traits<_BidirectionalIterator>::value_type* __buff) -{ - typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type; - typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type; - typedef typename iterator_traits<_BidirectionalIterator>::pointer pointer; - __destruct_n __d(0); - unique_ptr __h2(__buff, __d); - if (__len1 <= __len2) - { - value_type* __p = __buff; - for (_BidirectionalIterator __i = __first; __i != __middle; __d.__incr((value_type*)0), ++__i, ++__p) - ::new(__p) value_type(_VSTD::move(*__i)); - __merge<_Compare>(move_iterator(__buff), - move_iterator(__p), - move_iterator<_BidirectionalIterator>(__middle), - move_iterator<_BidirectionalIterator>(__last), - __first, __comp); - } - else - { - value_type* __p = __buff; - for (_BidirectionalIterator __i = __middle; __i != __last; __d.__incr((value_type*)0), ++__i, ++__p) - ::new(__p) value_type(_VSTD::move(*__i)); - typedef reverse_iterator<_BidirectionalIterator> _RBi; - typedef reverse_iterator _Rv; - __merge(move_iterator<_RBi>(_RBi(__middle)), move_iterator<_RBi>(_RBi(__first)), - move_iterator<_Rv>(_Rv(__p)), move_iterator<_Rv>(_Rv(__buff)), - _RBi(__last), __negate<_Compare>(__comp)); - } -} - -template -void -__inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last, - _Compare __comp, typename iterator_traits<_BidirectionalIterator>::difference_type __len1, - typename iterator_traits<_BidirectionalIterator>::difference_type __len2, - typename iterator_traits<_BidirectionalIterator>::value_type* __buff, ptrdiff_t __buff_size) -{ - typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type; - typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type; - while (true) - { - // if __middle == __last, we're done - if (__len2 == 0) - return; - // shrink [__first, __middle) as much as possible (with no moves), returning if it shrinks to 0 - for (; true; ++__first, --__len1) - { - if (__len1 == 0) - return; - if (__comp(*__middle, *__first)) - break; - } - if (__len1 <= __buff_size || __len2 <= __buff_size) - { - __buffered_inplace_merge<_Compare>(__first, __middle, __last, __comp, __len1, __len2, __buff); - return; - } - // __first < __middle < __last - // *__first > *__middle - // partition [__first, __m1) [__m1, __middle) [__middle, __m2) [__m2, __last) such that - // all elements in: - // [__first, __m1) <= [__middle, __m2) - // [__middle, __m2) < [__m1, __middle) - // [__m1, __middle) <= [__m2, __last) - // and __m1 or __m2 is in the middle of its range - _BidirectionalIterator __m1; // "median" of [__first, __middle) - _BidirectionalIterator __m2; // "median" of [__middle, __last) - difference_type __len11; // distance(__first, __m1) - difference_type __len21; // distance(__middle, __m2) - // binary search smaller range - if (__len1 < __len2) - { // __len >= 1, __len2 >= 2 - __len21 = __len2 / 2; - __m2 = __middle; - _VSTD::advance(__m2, __len21); - __m1 = __upper_bound<_Compare>(__first, __middle, *__m2, __comp); - __len11 = _VSTD::distance(__first, __m1); - } - else - { - if (__len1 == 1) - { // __len1 >= __len2 && __len2 > 0, therefore __len2 == 1 - // It is known *__first > *__middle - swap(*__first, *__middle); - return; - } - // __len1 >= 2, __len2 >= 1 - __len11 = __len1 / 2; - __m1 = __first; - _VSTD::advance(__m1, __len11); - __m2 = __lower_bound<_Compare>(__middle, __last, *__m1, __comp); - __len21 = _VSTD::distance(__middle, __m2); - } - difference_type __len12 = __len1 - __len11; // distance(__m1, __middle) - difference_type __len22 = __len2 - __len21; // distance(__m2, __last) - // [__first, __m1) [__m1, __middle) [__middle, __m2) [__m2, __last) - // swap middle two partitions - __middle = _VSTD::rotate(__m1, __middle, __m2); - // __len12 and __len21 now have swapped meanings - // merge smaller range with recurisve call and larger with tail recursion elimination - if (__len11 + __len21 < __len12 + __len22) - { - __inplace_merge<_Compare>(__first, __m1, __middle, __comp, __len11, __len21, __buff, __buff_size); -// __inplace_merge<_Compare>(__middle, __m2, __last, __comp, __len12, __len22, __buff, __buff_size); - __first = __middle; - __middle = __m2; - __len1 = __len12; - __len2 = __len22; - } - else - { - __inplace_merge<_Compare>(__middle, __m2, __last, __comp, __len12, __len22, __buff, __buff_size); -// __inplace_merge<_Compare>(__first, __m1, __middle, __comp, __len11, __len21, __buff, __buff_size); - __last = __middle; - __middle = __m1; - __len1 = __len11; - __len2 = __len21; - } - } -} - -template -struct __inplace_merge_switch -{ - static const unsigned value = is_trivially_copy_assignable<_Tp>::value; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -void -inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last, - _Compare __comp) -{ - typedef typename iterator_traits<_BidirectionalIterator>::value_type value_type; - typedef typename iterator_traits<_BidirectionalIterator>::difference_type difference_type; - difference_type __len1 = _VSTD::distance(__first, __middle); - difference_type __len2 = _VSTD::distance(__middle, __last); - difference_type __buf_size = _VSTD::min(__len1, __len2); - pair __buf(0, 0); - unique_ptr __h; - if (__inplace_merge_switch::value && __buf_size > 8) - { - __buf = _VSTD::get_temporary_buffer(__buf_size); - __h.reset(__buf.first); - } -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return _VSTD::__inplace_merge<_Comp_ref>(__first, __middle, __last, __c, __len1, __len2, - __buf.first, __buf.second); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return _VSTD::__inplace_merge<_Comp_ref>(__first, __middle, __last, __comp, __len1, __len2, - __buf.first, __buf.second); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -inplace_merge(_BidirectionalIterator __first, _BidirectionalIterator __middle, _BidirectionalIterator __last) -{ - _VSTD::inplace_merge(__first, __middle, __last, - __less::value_type>()); -} - -// stable_sort - -template -void -__merge_move_construct(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, - typename iterator_traits<_InputIterator1>::value_type* __result, _Compare __comp) -{ - typedef typename iterator_traits<_InputIterator1>::value_type value_type; - __destruct_n __d(0); - unique_ptr __h(__result, __d); - for (; true; ++__result) - { - if (__first1 == __last1) - { - for (; __first2 != __last2; ++__first2, ++__result, __d.__incr((value_type*)0)) - ::new (__result) value_type(_VSTD::move(*__first2)); - __h.release(); - return; - } - if (__first2 == __last2) - { - for (; __first1 != __last1; ++__first1, ++__result, __d.__incr((value_type*)0)) - ::new (__result) value_type(_VSTD::move(*__first1)); - __h.release(); - return; - } - if (__comp(*__first2, *__first1)) - { - ::new (__result) value_type(_VSTD::move(*__first2)); - __d.__incr((value_type*)0); - ++__first2; - } - else - { - ::new (__result) value_type(_VSTD::move(*__first1)); - __d.__incr((value_type*)0); - ++__first1; - } - } -} - -template -void -__merge_move_assign(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, - _OutputIterator __result, _Compare __comp) -{ - for (; __first1 != __last1; ++__result) - { - if (__first2 == __last2) - { - for (; __first1 != __last1; ++__first1, ++__result) - *__result = _VSTD::move(*__first1); - return; - } - if (__comp(*__first2, *__first1)) - { - *__result = _VSTD::move(*__first2); - ++__first2; - } - else - { - *__result = _VSTD::move(*__first1); - ++__first1; - } - } - for (; __first2 != __last2; ++__first2, ++__result) - *__result = _VSTD::move(*__first2); -} - -template -void -__stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len, - typename iterator_traits<_RandomAccessIterator>::value_type* __buff, ptrdiff_t __buff_size); - -template -void -__stable_sort_move(_RandomAccessIterator __first1, _RandomAccessIterator __last1, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len, - typename iterator_traits<_RandomAccessIterator>::value_type* __first2) -{ - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - switch (__len) - { - case 0: - return; - case 1: - ::new(__first2) value_type(_VSTD::move(*__first1)); - return; - case 2: - __destruct_n __d(0); - unique_ptr __h2(__first2, __d); - if (__comp(*--__last1, *__first1)) - { - ::new(__first2) value_type(_VSTD::move(*__last1)); - __d.__incr((value_type*)0); - ++__first2; - ::new(__first2) value_type(_VSTD::move(*__first1)); - } - else - { - ::new(__first2) value_type(_VSTD::move(*__first1)); - __d.__incr((value_type*)0); - ++__first2; - ::new(__first2) value_type(_VSTD::move(*__last1)); - } - __h2.release(); - return; - } - if (__len <= 8) - { - __insertion_sort_move<_Compare>(__first1, __last1, __first2, __comp); - return; - } - typename iterator_traits<_RandomAccessIterator>::difference_type __l2 = __len / 2; - _RandomAccessIterator __m = __first1 + __l2; - __stable_sort<_Compare>(__first1, __m, __comp, __l2, __first2, __l2); - __stable_sort<_Compare>(__m, __last1, __comp, __len - __l2, __first2 + __l2, __len - __l2); - __merge_move_construct<_Compare>(__first1, __m, __m, __last1, __first2, __comp); -} - -template -struct __stable_sort_switch -{ - static const unsigned value = 128*is_trivially_copy_assignable<_Tp>::value; -}; - -template -void -__stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len, - typename iterator_traits<_RandomAccessIterator>::value_type* __buff, ptrdiff_t __buff_size) -{ - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - switch (__len) - { - case 0: - case 1: - return; - case 2: - if (__comp(*--__last, *__first)) - swap(*__first, *__last); - return; - } - if (__len <= static_cast(__stable_sort_switch::value)) - { - __insertion_sort<_Compare>(__first, __last, __comp); - return; - } - typename iterator_traits<_RandomAccessIterator>::difference_type __l2 = __len / 2; - _RandomAccessIterator __m = __first + __l2; - if (__len <= __buff_size) - { - __destruct_n __d(0); - unique_ptr __h2(__buff, __d); - __stable_sort_move<_Compare>(__first, __m, __comp, __l2, __buff); - __d.__set(__l2, (value_type*)0); - __stable_sort_move<_Compare>(__m, __last, __comp, __len - __l2, __buff + __l2); - __d.__set(__len, (value_type*)0); - __merge_move_assign<_Compare>(__buff, __buff + __l2, __buff + __l2, __buff + __len, __first, __comp); -// __merge<_Compare>(move_iterator(__buff), -// move_iterator(__buff + __l2), -// move_iterator<_RandomAccessIterator>(__buff + __l2), -// move_iterator<_RandomAccessIterator>(__buff + __len), -// __first, __comp); - return; - } - __stable_sort<_Compare>(__first, __m, __comp, __l2, __buff, __buff_size); - __stable_sort<_Compare>(__m, __last, __comp, __len - __l2, __buff, __buff_size); - __inplace_merge<_Compare>(__first, __m, __last, __comp, __l2, __len - __l2, __buff, __buff_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - difference_type __len = __last - __first; - pair __buf(0, 0); - unique_ptr __h; - if (__len > static_cast(__stable_sort_switch::value)) - { - __buf = _VSTD::get_temporary_buffer(__len); - __h.reset(__buf.first); - } -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __stable_sort<_Comp_ref>(__first, __last, __c, __len, __buf.first, __buf.second); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __stable_sort<_Comp_ref>(__first, __last, __comp, __len, __buf.first, __buf.second); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::stable_sort(__first, __last, __less::value_type>()); -} - -// is_heap_until - -template -_RandomAccessIterator -is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - typedef typename _VSTD::iterator_traits<_RandomAccessIterator>::difference_type difference_type; - difference_type __len = __last - __first; - difference_type __p = 0; - difference_type __c = 1; - _RandomAccessIterator __pp = __first; - while (__c < __len) - { - _RandomAccessIterator __cp = __first + __c; - if (__comp(*__pp, *__cp)) - return __cp; - ++__c; - ++__cp; - if (__c == __len) - return __last; - if (__comp(*__pp, *__cp)) - return __cp; - ++__p; - ++__pp; - __c = 2 * __p + 1; - } - return __last; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_RandomAccessIterator -is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - return _VSTD::is_heap_until(__first, __last, __less::value_type>()); -} - -// is_heap - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - return _VSTD::is_heap_until(__first, __last, __comp) == __last; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - return _VSTD::is_heap(__first, __last, __less::value_type>()); -} - -// push_heap - -template -void -__push_heap_front(_RandomAccessIterator __first, _RandomAccessIterator, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - if (__len > 1) - { - difference_type __p = 0; - _RandomAccessIterator __pp = __first; - difference_type __c = 2; - _RandomAccessIterator __cp = __first + __c; - if (__c == __len || __comp(*__cp, *(__cp - 1))) - { - --__c; - --__cp; - } - if (__comp(*__pp, *__cp)) - { - value_type __t(_VSTD::move(*__pp)); - do - { - *__pp = _VSTD::move(*__cp); - __pp = __cp; - __p = __c; - __c = (__p + 1) * 2; - if (__c > __len) - break; - __cp = __first + __c; - if (__c == __len || __comp(*__cp, *(__cp - 1))) - { - --__c; - --__cp; - } - } while (__comp(__t, *__cp)); - *__pp = _VSTD::move(__t); - } - } -} - -template -void -__push_heap_back(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - typedef typename iterator_traits<_RandomAccessIterator>::value_type value_type; - if (__len > 1) - { - __len = (__len - 2) / 2; - _RandomAccessIterator __ptr = __first + __len; - if (__comp(*__ptr, *--__last)) - { - value_type __t(_VSTD::move(*__last)); - do - { - *__last = _VSTD::move(*__ptr); - __last = __ptr; - if (__len == 0) - break; - __len = (__len - 1) / 2; - __ptr = __first + __len; - } while (__comp(*__ptr, __t)); - *__last = _VSTD::move(__t); - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __push_heap_back<_Comp_ref>(__first, __last, __c, __last - __first); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __push_heap_back<_Comp_ref>(__first, __last, __comp, __last - __first); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::push_heap(__first, __last, __less::value_type>()); -} - -// pop_heap - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp, - typename iterator_traits<_RandomAccessIterator>::difference_type __len) -{ - if (__len > 1) - { - swap(*__first, *--__last); - __push_heap_front<_Compare>(__first, __last, __comp, __len-1); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __pop_heap<_Comp_ref>(__first, __last, __c, __last - __first); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __pop_heap<_Comp_ref>(__first, __last, __comp, __last - __first); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::pop_heap(__first, __last, __less::value_type>()); -} - -// make_heap - -template -void -__make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - difference_type __n = __last - __first; - if (__n > 1) - { - __last = __first; - ++__last; - for (difference_type __i = 1; __i < __n;) - __push_heap_back<_Compare>(__first, ++__last, __comp, ++__i); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __make_heap<_Comp_ref>(__first, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __make_heap<_Comp_ref>(__first, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::make_heap(__first, __last, __less::value_type>()); -} - -// sort_heap - -template -void -__sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - for (difference_type __n = __last - __first; __n > 1; --__last, --__n) - __pop_heap<_Compare>(__first, __last, __comp, __n); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __sort_heap<_Comp_ref>(__first, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __sort_heap<_Comp_ref>(__first, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) -{ - _VSTD::sort_heap(__first, __last, __less::value_type>()); -} - -// partial_sort - -template -void -__partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last, - _Compare __comp) -{ - __make_heap<_Compare>(__first, __middle, __comp); - typename iterator_traits<_RandomAccessIterator>::difference_type __len = __middle - __first; - for (_RandomAccessIterator __i = __middle; __i != __last; ++__i) - { - if (__comp(*__i, *__first)) - { - swap(*__i, *__first); - __push_heap_front<_Compare>(__first, __middle, __comp, __len); - } - } - __sort_heap<_Compare>(__first, __middle, __comp); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last, - _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __partial_sort<_Comp_ref>(__first, __middle, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __partial_sort<_Comp_ref>(__first, __middle, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -partial_sort(_RandomAccessIterator __first, _RandomAccessIterator __middle, _RandomAccessIterator __last) -{ - _VSTD::partial_sort(__first, __middle, __last, - __less::value_type>()); -} - -// partial_sort_copy - -template -_RandomAccessIterator -__partial_sort_copy(_InputIterator __first, _InputIterator __last, - _RandomAccessIterator __result_first, _RandomAccessIterator __result_last, _Compare __comp) -{ - _RandomAccessIterator __r = __result_first; - if (__r != __result_last) - { - typename iterator_traits<_RandomAccessIterator>::difference_type __len = 0; - for (; __first != __last && __r != __result_last; ++__first, ++__r, ++__len) - *__r = *__first; - __make_heap<_Compare>(__result_first, __r, __comp); - for (; __first != __last; ++__first) - if (__comp(*__first, *__result_first)) - { - *__result_first = *__first; - __push_heap_front<_Compare>(__result_first, __r, __comp, __len); - } - __sort_heap<_Compare>(__result_first, __r, __comp); - } - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_RandomAccessIterator -partial_sort_copy(_InputIterator __first, _InputIterator __last, - _RandomAccessIterator __result_first, _RandomAccessIterator __result_last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __partial_sort_copy<_Comp_ref>(__first, __last, __result_first, __result_last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __partial_sort_copy<_Comp_ref>(__first, __last, __result_first, __result_last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_RandomAccessIterator -partial_sort_copy(_InputIterator __first, _InputIterator __last, - _RandomAccessIterator __result_first, _RandomAccessIterator __result_last) -{ - return _VSTD::partial_sort_copy(__first, __last, __result_first, __result_last, - __less::value_type>()); -} - -// nth_element - -template -void -__nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last, _Compare __comp) -{ - // _Compare is known to be a reference type - typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; - const difference_type __limit = 7; - while (true) - { - __restart: - if (__nth == __last) - return; - difference_type __len = __last - __first; - switch (__len) - { - case 0: - case 1: - return; - case 2: - if (__comp(*--__last, *__first)) - swap(*__first, *__last); - return; - case 3: - { - _RandomAccessIterator __m = __first; - _VSTD::__sort3<_Compare>(__first, ++__m, --__last, __comp); - return; - } - } - if (__len <= __limit) - { - __selection_sort<_Compare>(__first, __last, __comp); - return; - } - // __len > __limit >= 3 - _RandomAccessIterator __m = __first + __len/2; - _RandomAccessIterator __lm1 = __last; - unsigned __n_swaps = _VSTD::__sort3<_Compare>(__first, __m, --__lm1, __comp); - // *__m is median - // partition [__first, __m) < *__m and *__m <= [__m, __last) - // (this inhibits tossing elements equivalent to __m around unnecessarily) - _RandomAccessIterator __i = __first; - _RandomAccessIterator __j = __lm1; - // j points beyond range to be tested, *__lm1 is known to be <= *__m - // The search going up is known to be guarded but the search coming down isn't. - // Prime the downward search with a guard. - if (!__comp(*__i, *__m)) // if *__first == *__m - { - // *__first == *__m, *__first doesn't go in first part - // manually guard downward moving __j against __i - while (true) - { - if (__i == --__j) - { - // *__first == *__m, *__m <= all other elements - // Parition instead into [__first, __i) == *__first and *__first < [__i, __last) - ++__i; // __first + 1 - __j = __last; - if (!__comp(*__first, *--__j)) // we need a guard if *__first == *(__last-1) - { - while (true) - { - if (__i == __j) - return; // [__first, __last) all equivalent elements - if (__comp(*__first, *__i)) - { - swap(*__i, *__j); - ++__n_swaps; - ++__i; - break; - } - ++__i; - } - } - // [__first, __i) == *__first and *__first < [__j, __last) and __j == __last - 1 - if (__i == __j) - return; - while (true) - { - while (!__comp(*__first, *__i)) - ++__i; - while (__comp(*__first, *--__j)) - ; - if (__i >= __j) - break; - swap(*__i, *__j); - ++__n_swaps; - ++__i; - } - // [__first, __i) == *__first and *__first < [__i, __last) - // The first part is sorted, - if (__nth < __i) - return; - // __nth_element the secod part - // __nth_element<_Compare>(__i, __nth, __last, __comp); - __first = __i; - goto __restart; - } - if (__comp(*__j, *__m)) - { - swap(*__i, *__j); - ++__n_swaps; - break; // found guard for downward moving __j, now use unguarded partition - } - } - } - ++__i; - // j points beyond range to be tested, *__lm1 is known to be <= *__m - // if not yet partitioned... - if (__i < __j) - { - // known that *(__i - 1) < *__m - while (true) - { - // __m still guards upward moving __i - while (__comp(*__i, *__m)) - ++__i; - // It is now known that a guard exists for downward moving __j - while (!__comp(*--__j, *__m)) - ; - if (__i >= __j) - break; - swap(*__i, *__j); - ++__n_swaps; - // It is known that __m != __j - // If __m just moved, follow it - if (__m == __i) - __m = __j; - ++__i; - } - } - // [__first, __i) < *__m and *__m <= [__i, __last) - if (__i != __m && __comp(*__m, *__i)) - { - swap(*__i, *__m); - ++__n_swaps; - } - // [__first, __i) < *__i and *__i <= [__i+1, __last) - if (__nth == __i) - return; - if (__n_swaps == 0) - { - // We were given a perfectly partitioned sequence. Coincidence? - if (__nth < __i) - { - // Check for [__first, __i) already sorted - __j = __m = __first; - while (++__j != __i) - { - if (__comp(*__j, *__m)) - // not yet sorted, so sort - goto not_sorted; - __m = __j; - } - // [__first, __i) sorted - return; - } - else - { - // Check for [__i, __last) already sorted - __j = __m = __i; - while (++__j != __last) - { - if (__comp(*__j, *__m)) - // not yet sorted, so sort - goto not_sorted; - __m = __j; - } - // [__i, __last) sorted - return; - } - } -not_sorted: - // __nth_element on range containing __nth - if (__nth < __i) - { - // __nth_element<_Compare>(__first, __nth, __i, __comp); - __last = __i; - } - else - { - // __nth_element<_Compare>(__i+1, __nth, __last, __comp); - __first = ++__i; - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - __nth_element<_Comp_ref>(__first, __nth, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - __nth_element<_Comp_ref>(__first, __nth, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, _RandomAccessIterator __last) -{ - _VSTD::nth_element(__first, __nth, __last, __less::value_type>()); -} - -// includes - -template -bool -__includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2, - _Compare __comp) -{ - for (; __first2 != __last2; ++__first1) - { - if (__first1 == __last1 || __comp(*__first2, *__first1)) - return false; - if (!__comp(*__first1, *__first2)) - ++__first2; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2, - _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __includes<_Comp_ref>(__first1, __last1, __first2, __last2, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __includes<_Comp_ref>(__first1, __last1, __first2, __last2, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -includes(_InputIterator1 __first1, _InputIterator1 __last1, _InputIterator2 __first2, _InputIterator2 __last2) -{ - return _VSTD::includes(__first1, __last1, __first2, __last2, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// set_union - -template -_OutputIterator -__set_union(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ - for (; __first1 != __last1; ++__result) - { - if (__first2 == __last2) - return _VSTD::copy(__first1, __last1, __result); - if (__comp(*__first2, *__first1)) - { - *__result = *__first2; - ++__first2; - } - else - { - *__result = *__first1; - if (!__comp(*__first1, *__first2)) - ++__first2; - ++__first1; - } - } - return _VSTD::copy(__first2, __last2, __result); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_union(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __set_union<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __set_union<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_union(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result) -{ - return _VSTD::set_union(__first1, __last1, __first2, __last2, __result, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// set_intersection - -template -_OutputIterator -__set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ - while (__first1 != __last1 && __first2 != __last2) - { - if (__comp(*__first1, *__first2)) - ++__first1; - else - { - if (!__comp(*__first2, *__first1)) - { - *__result = *__first1; - ++__result; - ++__first1; - } - ++__first2; - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __set_intersection<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __set_intersection<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result) -{ - return _VSTD::set_intersection(__first1, __last1, __first2, __last2, __result, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// set_difference - -template -_OutputIterator -__set_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ - while (__first1 != __last1) - { - if (__first2 == __last2) - return _VSTD::copy(__first1, __last1, __result); - if (__comp(*__first1, *__first2)) - { - *__result = *__first1; - ++__result; - ++__first1; - } - else - { - if (!__comp(*__first2, *__first1)) - ++__first1; - ++__first2; - } - } - return __result; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __set_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __set_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result) -{ - return _VSTD::set_difference(__first1, __last1, __first2, __last2, __result, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// set_symmetric_difference - -template -_OutputIterator -__set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ - while (__first1 != __last1) - { - if (__first2 == __last2) - return _VSTD::copy(__first1, __last1, __result); - if (__comp(*__first1, *__first2)) - { - *__result = *__first1; - ++__result; - ++__first1; - } - else - { - if (__comp(*__first2, *__first1)) - { - *__result = *__first2; - ++__result; - } - else - ++__first1; - ++__first2; - } - } - return _VSTD::copy(__first2, __last2, __result); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __set_symmetric_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __set_symmetric_difference<_Comp_ref>(__first1, __last1, __first2, __last2, __result, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_OutputIterator -set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _OutputIterator __result) -{ - return _VSTD::set_symmetric_difference(__first1, __last1, __first2, __last2, __result, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// lexicographical_compare - -template -bool -__lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _Compare __comp) -{ - for (; __first2 != __last2; ++__first1, ++__first2) - { - if (__first1 == __last1 || __comp(*__first1, *__first2)) - return true; - if (__comp(*__first2, *__first1)) - return false; - } - return false; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __lexicographical_compare<_Comp_ref>(__first1, __last1, __first2, __last2, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __lexicographical_compare<_Comp_ref>(__first1, __last1, __first2, __last2, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -lexicographical_compare(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2, _InputIterator2 __last2) -{ - return _VSTD::lexicographical_compare(__first1, __last1, __first2, __last2, - __less::value_type, - typename iterator_traits<_InputIterator2>::value_type>()); -} - -// next_permutation - -template -bool -__next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp) -{ - _BidirectionalIterator __i = __last; - if (__first == __last || __first == --__i) - return false; - while (true) - { - _BidirectionalIterator __ip1 = __i; - if (__comp(*--__i, *__ip1)) - { - _BidirectionalIterator __j = __last; - while (!__comp(*__i, *--__j)) - ; - swap(*__i, *__j); - _VSTD::reverse(__ip1, __last); - return true; - } - if (__i == __first) - { - _VSTD::reverse(__first, __last); - return false; - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __next_permutation<_Comp_ref>(__first, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __next_permutation<_Comp_ref>(__first, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -next_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last) -{ - return _VSTD::next_permutation(__first, __last, - __less::value_type>()); -} - -// prev_permutation - -template -bool -__prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp) -{ - _BidirectionalIterator __i = __last; - if (__first == __last || __first == --__i) - return false; - while (true) - { - _BidirectionalIterator __ip1 = __i; - if (__comp(*__ip1, *--__i)) - { - _BidirectionalIterator __j = __last; - while (!__comp(*--__j, *__i)) - ; - swap(*__i, *__j); - _VSTD::reverse(__ip1, __last); - return true; - } - if (__i == __first) - { - _VSTD::reverse(__first, __last); - return false; - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last, _Compare __comp) -{ -#ifdef _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<__debug_less<_Compare> >::type _Comp_ref; - __debug_less<_Compare> __c(__comp); - return __prev_permutation<_Comp_ref>(__first, __last, __c); -#else // _LIBCPP_DEBUG2 - typedef typename add_lvalue_reference<_Compare>::type _Comp_ref; - return __prev_permutation<_Comp_ref>(__first, __last, __comp); -#endif // _LIBCPP_DEBUG2 -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -prev_permutation(_BidirectionalIterator __first, _BidirectionalIterator __last) -{ - return _VSTD::prev_permutation(__first, __last, - __less::value_type>()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - _Tp ->::type -__rotate_left(_Tp __t, _Tp __n = 1) -{ - const unsigned __bits = static_cast(sizeof(_Tp) * __CHAR_BIT__ - 1); - __n &= __bits; - return static_cast<_Tp>((__t << __n) | (static_cast::type>(__t) >> (__bits - __n))); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - _Tp ->::type -__rotate_right(_Tp __t, _Tp __n = 1) -{ - const unsigned __bits = static_cast(sizeof(_Tp) * __CHAR_BIT__ - 1); - __n &= __bits; - return static_cast<_Tp>((__t << (__bits - __n)) | (static_cast::type>(__t) >> __n)); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_ALGORITHM diff --git a/libcxx/include/array b/libcxx/include/array deleted file mode 100644 index c11f4bd74f5f..000000000000 --- a/libcxx/include/array +++ /dev/null @@ -1,338 +0,0 @@ -// -*- C++ -*- -//===---------------------------- array -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_ARRAY -#define _LIBCPP_ARRAY - -/* - array synopsis - -namespace std -{ -template -struct array -{ - // types: - typedef T & reference; - typedef const T & const_reference; - typedef implementation defined iterator; - typedef implementation defined const_iterator; - typedef size_t size_type; - typedef ptrdiff_t difference_type; - typedef T value_type; - typedef T* pointer; - typedef const T* const_pointer; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - // No explicit construct/copy/destroy for aggregate type - void fill(const T& u); - void swap(array& a) noexcept(noexcept(swap(declval(), declval()))); - - // iterators: - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - - reverse_iterator rbegin() noexcept; - const_reverse_iterator rbegin() const noexcept; - reverse_iterator rend() noexcept; - const_reverse_iterator rend() const noexcept; - - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - const_reverse_iterator crbegin() const noexcept; - const_reverse_iterator crend() const noexcept; - - // capacity: - constexpr size_type size() const noexcept; - constexpr size_type max_size() const noexcept; - bool empty() const noexcept; - - // element access: - reference operator[](size_type n); - const_reference operator[](size_type n) const; - const_reference at(size_type n) const; - reference at(size_type n); - - reference front(); - const_reference front() const; - reference back(); - const_reference back() const; - - T* data() noexcept; - const T* data() const noexcept; -}; - -template - bool operator==(const array& x, const array& y); -template - bool operator!=(const array& x, const array& y); -template - bool operator<(const array& x, const array& y); -template - bool operator>(const array& x, const array& y); -template - bool operator<=(const array& x, const array& y); -template - bool operator>=(const array& x, const array& y); - -template - void swap(array& x, array& y) noexcept(noexcept(x.swap(y))); - -template class tuple_size; -template class tuple_element; -template struct tuple_size>; -template struct tuple_element>; -template T& get(array&) noexcept; -template const T& get(const array&) noexcept; -template T&& get(array&&) noexcept; - -} // std - -*/ - -#include <__config> -#include <__tuple> -#include -#include -#include -#include -#include -#if defined(_LIBCPP_NO_EXCEPTIONS) - #include -#endif - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -struct _LIBCPP_VISIBLE array -{ - // types: - typedef array __self; - typedef _Tp value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef value_type* iterator; - typedef const value_type* const_iterator; - typedef value_type* pointer; - typedef const value_type* const_pointer; - typedef size_t size_type; - typedef ptrdiff_t difference_type; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - value_type __elems_[_Size > 0 ? _Size : 1]; - - // No explicit construct/copy/destroy for aggregate type - _LIBCPP_INLINE_VISIBILITY void fill(const value_type& __u) - {_VSTD::fill_n(__elems_, _Size, __u);} - _LIBCPP_INLINE_VISIBILITY - void swap(array& __a) _NOEXCEPT_(__is_nothrow_swappable<_Tp>::value) - {_VSTD::swap_ranges(__elems_, __elems_ + _Size, __a.__elems_);} - - // iterators: - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return iterator(__elems_);} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return const_iterator(__elems_);} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return iterator(__elems_ + _Size);} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return const_iterator(__elems_ + _Size);} - - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rbegin() _NOEXCEPT {return reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rbegin() const _NOEXCEPT {return const_reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rend() _NOEXCEPT {return reverse_iterator(begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rend() const _NOEXCEPT {return const_reverse_iterator(begin());} - - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT {return begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT {return end();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crbegin() const _NOEXCEPT {return rbegin();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crend() const _NOEXCEPT {return rend();} - - // capacity: - _LIBCPP_INLINE_VISIBILITY - /*constexpr*/ size_type size() const _NOEXCEPT {return _Size;} - _LIBCPP_INLINE_VISIBILITY - /*constexpr*/ size_type max_size() const _NOEXCEPT {return _Size;} - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return _Size == 0;} - - // element access: - _LIBCPP_INLINE_VISIBILITY reference operator[](size_type __n) {return __elems_[__n];} - _LIBCPP_INLINE_VISIBILITY const_reference operator[](size_type __n) const {return __elems_[__n];} - reference at(size_type __n); - const_reference at(size_type __n) const; - - _LIBCPP_INLINE_VISIBILITY reference front() {return __elems_[0];} - _LIBCPP_INLINE_VISIBILITY const_reference front() const {return __elems_[0];} - _LIBCPP_INLINE_VISIBILITY reference back() {return __elems_[_Size > 0 ? _Size-1 : 0];} - _LIBCPP_INLINE_VISIBILITY const_reference back() const {return __elems_[_Size > 0 ? _Size-1 : 0];} - - _LIBCPP_INLINE_VISIBILITY - value_type* data() _NOEXCEPT {return __elems_;} - _LIBCPP_INLINE_VISIBILITY - const value_type* data() const _NOEXCEPT {return __elems_;} -}; - -template -typename array<_Tp, _Size>::reference -array<_Tp, _Size>::at(size_type __n) -{ - if (__n >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("array::at"); -#else - assert(!"array::at out_of_range"); -#endif - return __elems_[__n]; -} - -template -typename array<_Tp, _Size>::const_reference -array<_Tp, _Size>::at(size_type __n) const -{ - if (__n >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("array::at"); -#else - assert(!"array::at out_of_range"); -#endif - return __elems_[__n]; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator==(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return _VSTD::equal(__x.__elems_, __x.__elems_ + _Size, __y.__elems_); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator!=(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return !(__x == __y); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator<(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return _VSTD::lexicographical_compare(__x.__elems_, __x.__elems_ + _Size, __y.__elems_, __y.__elems_ + _Size); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator>(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return __y < __x; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator<=(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return !(__y < __x); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator>=(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) -{ - return !(__x < __y); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -typename enable_if -< - __is_swappable<_Tp>::value, - void ->::type -swap(const array<_Tp, _Size>& __x, const array<_Tp, _Size>& __y) - _NOEXCEPT_(__is_nothrow_swappable<_Tp>::value) -{ - __x.swap(__y); -} - -template -class _LIBCPP_VISIBLE tuple_size > - : public integral_constant {}; - -template -class _LIBCPP_VISIBLE tuple_size > - : public integral_constant {}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, array<_Tp, _Size> > -{ -public: - typedef _Tp type; -}; - -template -class _LIBCPP_VISIBLE tuple_element<_Ip, const array<_Tp, _Size> > -{ -public: - typedef const _Tp type; -}; - -template -_LIBCPP_INLINE_VISIBILITY inline -_Tp& -get(array<_Tp, _Size>& __a) _NOEXCEPT -{ - return __a[_Ip]; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -const _Tp& -get(const array<_Tp, _Size>& __a) _NOEXCEPT -{ - return __a[_Ip]; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_LIBCPP_INLINE_VISIBILITY inline -_Tp&& -get(array<_Tp, _Size>&& __a) _NOEXCEPT -{ - return _VSTD::move(__a[_Ip]); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_ARRAY diff --git a/libcxx/include/atomic b/libcxx/include/atomic deleted file mode 100644 index 6a200eba599f..000000000000 --- a/libcxx/include/atomic +++ /dev/null @@ -1,1515 +0,0 @@ -// -*- C++ -*- -//===--------------------------- atomic -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_ATOMIC -#define _LIBCPP_ATOMIC - -/* - atomic synopsis - -namespace std -{ - -// order and consistency - -typedef enum memory_order -{ - memory_order_relaxed, - memory_order_consume, // load-consume - memory_order_acquire, // load-acquire - memory_order_release, // store-release - memory_order_acq_rel, // store-release load-acquire - memory_order_seq_cst // store-release load-acquire -} memory_order; - -template T kill_dependency(T y) noexcept; - -// lock-free property - -#define ATOMIC_CHAR_LOCK_FREE unspecified -#define ATOMIC_CHAR16_T_LOCK_FREE unspecified -#define ATOMIC_CHAR32_T_LOCK_FREE unspecified -#define ATOMIC_WCHAR_T_LOCK_FREE unspecified -#define ATOMIC_SHORT_LOCK_FREE unspecified -#define ATOMIC_INT_LOCK_FREE unspecified -#define ATOMIC_LONG_LOCK_FREE unspecified -#define ATOMIC_LLONG_LOCK_FREE unspecified - -// flag type and operations - -typedef struct atomic_flag -{ - bool test_and_set(memory_order m = memory_order_seq_cst) volatile noexcept; - bool test_and_set(memory_order m = memory_order_seq_cst) noexcept; - void clear(memory_order m = memory_order_seq_cst) volatile noexcept; - void clear(memory_order m = memory_order_seq_cst) noexcept; - atomic_flag() noexcept = default; - atomic_flag(const atomic_flag&) = delete; - atomic_flag& operator=(const atomic_flag&) = delete; - atomic_flag& operator=(const atomic_flag&) volatile = delete; -} atomic_flag; - -bool - atomic_flag_test_and_set(volatile atomic_flag* obj) noexcept; - -bool - atomic_flag_test_and_set(atomic_flag* obj) noexcept; - -bool - atomic_flag_test_and_set_explicit(volatile atomic_flag* obj, - memory_order m) noexcept; - -bool - atomic_flag_test_and_set_explicit(atomic_flag* obj, memory_order m) noexcept; - -void - atomic_flag_clear(volatile atomic_flag* obj) noexcept; - -void - atomic_flag_clear(atomic_flag* obj) noexcept; - -void - atomic_flag_clear_explicit(volatile atomic_flag* obj, memory_order m) noexcept; - -void - atomic_flag_clear_explicit(atomic_flag* obj, memory_order m) noexcept; - -#define ATOMIC_FLAG_INIT see below -#define ATOMIC_VAR_INIT(value) see below - -template -struct atomic -{ - bool is_lock_free() const volatile noexcept; - bool is_lock_free() const noexcept; - void store(T desr, memory_order m = memory_order_seq_cst) volatile noexcept; - void store(T desr, memory_order m = memory_order_seq_cst) noexcept; - T load(memory_order m = memory_order_seq_cst) const volatile noexcept; - T load(memory_order m = memory_order_seq_cst) const noexcept; - operator T() const volatile noexcept; - operator T() const noexcept; - T exchange(T desr, memory_order m = memory_order_seq_cst) volatile noexcept; - T exchange(T desr, memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_weak(T& expc, T desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_weak(T& expc, T desr, memory_order s, memory_order f) noexcept; - bool compare_exchange_strong(T& expc, T desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_strong(T& expc, T desr, - memory_order s, memory_order f) noexcept; - bool compare_exchange_weak(T& expc, T desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_weak(T& expc, T desr, - memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_strong(T& expc, T desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_strong(T& expc, T desr, - memory_order m = memory_order_seq_cst) noexcept; - - atomic() noexcept = default; - constexpr atomic(T desr) noexcept; - atomic(const atomic&) = delete; - atomic& operator=(const atomic&) = delete; - atomic& operator=(const atomic&) volatile = delete; - T operator=(T) volatile noexcept; - T operator=(T) noexcept; -}; - -template <> -struct atomic -{ - bool is_lock_free() const volatile noexcept; - bool is_lock_free() const noexcept; - void store(integral desr, memory_order m = memory_order_seq_cst) volatile noexcept; - void store(integral desr, memory_order m = memory_order_seq_cst) noexcept; - integral load(memory_order m = memory_order_seq_cst) const volatile noexcept; - integral load(memory_order m = memory_order_seq_cst) const noexcept; - operator integral() const volatile noexcept; - operator integral() const noexcept; - integral exchange(integral desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - integral exchange(integral desr, memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_weak(integral& expc, integral desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_weak(integral& expc, integral desr, - memory_order s, memory_order f) noexcept; - bool compare_exchange_strong(integral& expc, integral desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_strong(integral& expc, integral desr, - memory_order s, memory_order f) noexcept; - bool compare_exchange_weak(integral& expc, integral desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_weak(integral& expc, integral desr, - memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_strong(integral& expc, integral desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_strong(integral& expc, integral desr, - memory_order m = memory_order_seq_cst) noexcept; - - integral - fetch_add(integral op, memory_order m = memory_order_seq_cst) volatile noexcept; - integral fetch_add(integral op, memory_order m = memory_order_seq_cst) noexcept; - integral - fetch_sub(integral op, memory_order m = memory_order_seq_cst) volatile noexcept; - integral fetch_sub(integral op, memory_order m = memory_order_seq_cst) noexcept; - integral - fetch_and(integral op, memory_order m = memory_order_seq_cst) volatile noexcept; - integral fetch_and(integral op, memory_order m = memory_order_seq_cst) noexcept; - integral - fetch_or(integral op, memory_order m = memory_order_seq_cst) volatile noexcept; - integral fetch_or(integral op, memory_order m = memory_order_seq_cst) noexcept; - integral - fetch_xor(integral op, memory_order m = memory_order_seq_cst) volatile noexcept; - integral fetch_xor(integral op, memory_order m = memory_order_seq_cst) noexcept; - - atomic() noexcept = default; - constexpr atomic(integral desr) noexcept; - atomic(const atomic&) = delete; - atomic& operator=(const atomic&) = delete; - atomic& operator=(const atomic&) volatile = delete; - integral operator=(integral desr) volatile noexcept; - integral operator=(integral desr) noexcept; - - integral operator++(int) volatile noexcept; - integral operator++(int) noexcept; - integral operator--(int) volatile noexcept; - integral operator--(int) noexcept; - integral operator++() volatile noexcept; - integral operator++() noexcept; - integral operator--() volatile noexcept; - integral operator--() noexcept; - integral operator+=(integral op) volatile noexcept; - integral operator+=(integral op) noexcept; - integral operator-=(integral op) volatile noexcept; - integral operator-=(integral op) noexcept; - integral operator&=(integral op) volatile noexcept; - integral operator&=(integral op) noexcept; - integral operator|=(integral op) volatile noexcept; - integral operator|=(integral op) noexcept; - integral operator^=(integral op) volatile noexcept; - integral operator^=(integral op) noexcept; -}; - -template -struct atomic -{ - bool is_lock_free() const volatile noexcept; - bool is_lock_free() const noexcept; - void store(T* desr, memory_order m = memory_order_seq_cst) volatile noexcept; - void store(T* desr, memory_order m = memory_order_seq_cst) noexcept; - T* load(memory_order m = memory_order_seq_cst) const volatile noexcept; - T* load(memory_order m = memory_order_seq_cst) const noexcept; - operator T*() const volatile noexcept; - operator T*() const noexcept; - T* exchange(T* desr, memory_order m = memory_order_seq_cst) volatile noexcept; - T* exchange(T* desr, memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_weak(T*& expc, T* desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_weak(T*& expc, T* desr, - memory_order s, memory_order f) noexcept; - bool compare_exchange_strong(T*& expc, T* desr, - memory_order s, memory_order f) volatile noexcept; - bool compare_exchange_strong(T*& expc, T* desr, - memory_order s, memory_order f) noexcept; - bool compare_exchange_weak(T*& expc, T* desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_weak(T*& expc, T* desr, - memory_order m = memory_order_seq_cst) noexcept; - bool compare_exchange_strong(T*& expc, T* desr, - memory_order m = memory_order_seq_cst) volatile noexcept; - bool compare_exchange_strong(T*& expc, T* desr, - memory_order m = memory_order_seq_cst) noexcept; - T* fetch_add(ptrdiff_t op, memory_order m = memory_order_seq_cst) volatile noexcept; - T* fetch_add(ptrdiff_t op, memory_order m = memory_order_seq_cst) noexcept; - T* fetch_sub(ptrdiff_t op, memory_order m = memory_order_seq_cst) volatile noexcept; - T* fetch_sub(ptrdiff_t op, memory_order m = memory_order_seq_cst) noexcept; - - atomic() noexcept = default; - constexpr atomic(T* desr) noexcept; - atomic(const atomic&) = delete; - atomic& operator=(const atomic&) = delete; - atomic& operator=(const atomic&) volatile = delete; - - T* operator=(T*) volatile noexcept; - T* operator=(T*) noexcept; - T* operator++(int) volatile noexcept; - T* operator++(int) noexcept; - T* operator--(int) volatile noexcept; - T* operator--(int) noexcept; - T* operator++() volatile noexcept; - T* operator++() noexcept; - T* operator--() volatile noexcept; - T* operator--() noexcept; - T* operator+=(ptrdiff_t op) volatile noexcept; - T* operator+=(ptrdiff_t op) noexcept; - T* operator-=(ptrdiff_t op) volatile noexcept; - T* operator-=(ptrdiff_t op) noexcept; -}; - - -template - bool - atomic_is_lock_free(const volatile atomic* obj) noexcept; - -template - bool - atomic_is_lock_free(const atomic* obj) noexcept; - -template - void - atomic_init(volatile atomic* obj, T desr) noexcept; - -template - void - atomic_init(atomic* obj, T desr) noexcept; - -template - void - atomic_store(volatile atomic* obj, T desr) noexcept; - -template - void - atomic_store(atomic* obj, T desr) noexcept; - -template - void - atomic_store_explicit(volatile atomic* obj, T desr, memory_order m) noexcept; - -template - void - atomic_store_explicit(atomic* obj, T desr, memory_order m) noexcept; - -template - T - atomic_load(const volatile atomic* obj) noexcept; - -template - T - atomic_load(const atomic* obj) noexcept; - -template - T - atomic_load_explicit(const volatile atomic* obj, memory_order m) noexcept; - -template - T - atomic_load_explicit(const atomic* obj, memory_order m) noexcept; - -template - T - atomic_exchange(volatile atomic* obj, T desr) noexcept; - -template - T - atomic_exchange(atomic* obj, T desr) noexcept; - -template - T - atomic_exchange_explicit(volatile atomic* obj, T desr, memory_order m) noexcept; - -template - T - atomic_exchange_explicit(atomic* obj, T desr, memory_order m) noexcept; - -template - bool - atomic_compare_exchange_weak(volatile atomic* obj, T* expc, T desr) noexcept; - -template - bool - atomic_compare_exchange_weak(atomic* obj, T* expc, T desr) noexcept; - -template - bool - atomic_compare_exchange_strong(volatile atomic* obj, T* expc, T desr) noexcept; - -template - bool - atomic_compare_exchange_strong(atomic* obj, T* expc, T desr) noexcept; - -template - bool - atomic_compare_exchange_weak_explicit(volatile atomic* obj, T* expc, - T desr, - memory_order s, memory_order f) noexcept; - -template - bool - atomic_compare_exchange_weak_explicit(atomic* obj, T* expc, T desr, - memory_order s, memory_order f) noexcept; - -template - bool - atomic_compare_exchange_strong_explicit(volatile atomic* obj, - T* expc, T desr, - memory_order s, memory_order f) noexcept; - -template - bool - atomic_compare_exchange_strong_explicit(atomic* obj, T* expc, - T desr, - memory_order s, memory_order f) noexcept; - -template - Integral - atomic_fetch_add(volatile atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_add(atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_add_explicit(volatile atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_add_explicit(atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_sub(volatile atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_sub(atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_sub_explicit(volatile atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_sub_explicit(atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_and(volatile atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_and(atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_and_explicit(volatile atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_and_explicit(atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_or(volatile atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_or(atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_or_explicit(volatile atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_or_explicit(atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_xor(volatile atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_xor(atomic* obj, Integral op) noexcept; - -template - Integral - atomic_fetch_xor_explicit(volatile atomic* obj, Integral op, - memory_order m) noexcept; -template - Integral - atomic_fetch_xor_explicit(atomic* obj, Integral op, - memory_order m) noexcept; - -template - T* - atomic_fetch_add(volatile atomic* obj, ptrdiff_t op) noexcept; - -template - T* - atomic_fetch_add(atomic* obj, ptrdiff_t op) noexcept; - -template - T* - atomic_fetch_add_explicit(volatile atomic* obj, ptrdiff_t op, - memory_order m) noexcept; -template - T* - atomic_fetch_add_explicit(atomic* obj, ptrdiff_t op, memory_order m) noexcept; - -template - T* - atomic_fetch_sub(volatile atomic* obj, ptrdiff_t op) noexcept; - -template - T* - atomic_fetch_sub(atomic* obj, ptrdiff_t op) noexcept; - -template - T* - atomic_fetch_sub_explicit(volatile atomic* obj, ptrdiff_t op, - memory_order m) noexcept; -template - T* - atomic_fetch_sub_explicit(atomic* obj, ptrdiff_t op, memory_order m) noexcept; - -// Atomics for standard typedef types - -typedef atomic atomic_char; -typedef atomic atomic_schar; -typedef atomic atomic_uchar; -typedef atomic atomic_short; -typedef atomic atomic_ushort; -typedef atomic atomic_int; -typedef atomic atomic_uint; -typedef atomic atomic_long; -typedef atomic atomic_ulong; -typedef atomic atomic_llong; -typedef atomic atomic_ullong; -typedef atomic atomic_char16_t; -typedef atomic atomic_char32_t; -typedef atomic atomic_wchar_t; - -typedef atomic atomic_int_least8_t; -typedef atomic atomic_uint_least8_t; -typedef atomic atomic_int_least16_t; -typedef atomic atomic_uint_least16_t; -typedef atomic atomic_int_least32_t; -typedef atomic atomic_uint_least32_t; -typedef atomic atomic_int_least64_t; -typedef atomic atomic_uint_least64_t; - -typedef atomic atomic_int_fast8_t; -typedef atomic atomic_uint_fast8_t; -typedef atomic atomic_int_fast16_t; -typedef atomic atomic_uint_fast16_t; -typedef atomic atomic_int_fast32_t; -typedef atomic atomic_uint_fast32_t; -typedef atomic atomic_int_fast64_t; -typedef atomic atomic_uint_fast64_t; - -typedef atomic atomic_intptr_t; -typedef atomic atomic_uintptr_t; -typedef atomic atomic_size_t; -typedef atomic atomic_ptrdiff_t; -typedef atomic atomic_intmax_t; -typedef atomic atomic_uintmax_t; - -// fences - -void atomic_thread_fence(memory_order m) noexcept; -void atomic_signal_fence(memory_order m) noexcept; - -} // std - -*/ - -#include <__config> -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -#if !__has_feature(cxx_atomic) -#error is not implemented -#else - -typedef enum memory_order -{ - memory_order_relaxed, memory_order_consume, memory_order_acquire, - memory_order_release, memory_order_acq_rel, memory_order_seq_cst -} memory_order; - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -kill_dependency(_Tp __y) _NOEXCEPT -{ - return __y; -} - -// general atomic - -template ::value && !is_same<_Tp, bool>::value> -struct __atomic_base // false -{ - _Atomic(_Tp) __a_; - - _LIBCPP_INLINE_VISIBILITY - bool is_lock_free() const volatile _NOEXCEPT - {return __c11_atomic_is_lock_free(sizeof(_Tp));} - _LIBCPP_INLINE_VISIBILITY - bool is_lock_free() const _NOEXCEPT - {return __c11_atomic_is_lock_free(sizeof(_Tp));} - _LIBCPP_INLINE_VISIBILITY - void store(_Tp __d, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {__c11_atomic_store(&__a_, __d, __m);} - _LIBCPP_INLINE_VISIBILITY - void store(_Tp __d, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {__c11_atomic_store(&__a_, __d, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp load(memory_order __m = memory_order_seq_cst) const volatile _NOEXCEPT - {return __c11_atomic_load(&__a_, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp load(memory_order __m = memory_order_seq_cst) const _NOEXCEPT - {return __c11_atomic_load(&__a_, __m);} - _LIBCPP_INLINE_VISIBILITY - operator _Tp() const volatile _NOEXCEPT {return load();} - _LIBCPP_INLINE_VISIBILITY - operator _Tp() const _NOEXCEPT {return load();} - _LIBCPP_INLINE_VISIBILITY - _Tp exchange(_Tp __d, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_exchange(&__a_, __d, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp exchange(_Tp __d, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_exchange(&__a_, __d, __m);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_weak(_Tp& __e, _Tp __d, - memory_order __s, memory_order __f) volatile _NOEXCEPT - {return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __s, __f);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_weak(_Tp& __e, _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT - {return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __s, __f);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_strong(_Tp& __e, _Tp __d, - memory_order __s, memory_order __f) volatile _NOEXCEPT - {return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __s, __f);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_strong(_Tp& __e, _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT - {return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __s, __f);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_weak(_Tp& __e, _Tp __d, - memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __m, __m);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_weak(_Tp& __e, _Tp __d, - memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_compare_exchange_weak(&__a_, &__e, __d, __m, __m);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_strong(_Tp& __e, _Tp __d, - memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __m, __m);} - _LIBCPP_INLINE_VISIBILITY - bool compare_exchange_strong(_Tp& __e, _Tp __d, - memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_compare_exchange_strong(&__a_, &__e, __d, __m, __m);} - - _LIBCPP_INLINE_VISIBILITY - __atomic_base() _NOEXCEPT {} // = default; - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_CONSTEXPR __atomic_base(_Tp __d) _NOEXCEPT : __a_(__d) {} -#ifndef _LIBCPP_HAS_NO_DELETED_FUNCTIONS - __atomic_base(const __atomic_base&) = delete; - __atomic_base& operator=(const __atomic_base&) = delete; - __atomic_base& operator=(const __atomic_base&) volatile = delete; -#else // _LIBCPP_HAS_NO_DELETED_FUNCTIONS -private: - __atomic_base(const __atomic_base&); - __atomic_base& operator=(const __atomic_base&); - __atomic_base& operator=(const __atomic_base&) volatile; -#endif // _LIBCPP_HAS_NO_DELETED_FUNCTIONS -}; - -// atomic - -template -struct __atomic_base<_Tp, true> - : public __atomic_base<_Tp, false> -{ - typedef __atomic_base<_Tp, false> __base; - _LIBCPP_INLINE_VISIBILITY - __atomic_base() _NOEXCEPT {} // = default; - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_CONSTEXPR __atomic_base(_Tp __d) _NOEXCEPT : __base(__d) {} - - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_add(_Tp __op, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_fetch_add(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_add(_Tp __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_add(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_sub(_Tp __op, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_fetch_sub(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_sub(_Tp __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_sub(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_and(_Tp __op, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_fetch_and(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_and(_Tp __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_and(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_or(_Tp __op, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_fetch_or(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_or(_Tp __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_or(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_xor(_Tp __op, memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_fetch_xor(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp fetch_xor(_Tp __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_xor(&this->__a_, __op, __m);} - - _LIBCPP_INLINE_VISIBILITY - _Tp operator++(int) volatile _NOEXCEPT {return fetch_add(_Tp(1));} - _LIBCPP_INLINE_VISIBILITY - _Tp operator++(int) _NOEXCEPT {return fetch_add(_Tp(1));} - _LIBCPP_INLINE_VISIBILITY - _Tp operator--(int) volatile _NOEXCEPT {return fetch_sub(_Tp(1));} - _LIBCPP_INLINE_VISIBILITY - _Tp operator--(int) _NOEXCEPT {return fetch_sub(_Tp(1));} - _LIBCPP_INLINE_VISIBILITY - _Tp operator++() volatile _NOEXCEPT {return fetch_add(_Tp(1)) + _Tp(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp operator++() _NOEXCEPT {return fetch_add(_Tp(1)) + _Tp(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp operator--() volatile _NOEXCEPT {return fetch_sub(_Tp(1)) - _Tp(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp operator--() _NOEXCEPT {return fetch_sub(_Tp(1)) - _Tp(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp operator+=(_Tp __op) volatile _NOEXCEPT {return fetch_add(__op) + __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator+=(_Tp __op) _NOEXCEPT {return fetch_add(__op) + __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator-=(_Tp __op) volatile _NOEXCEPT {return fetch_sub(__op) - __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator-=(_Tp __op) _NOEXCEPT {return fetch_sub(__op) - __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator&=(_Tp __op) volatile _NOEXCEPT {return fetch_and(__op) & __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator&=(_Tp __op) _NOEXCEPT {return fetch_and(__op) & __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator|=(_Tp __op) volatile _NOEXCEPT {return fetch_or(__op) | __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator|=(_Tp __op) _NOEXCEPT {return fetch_or(__op) | __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator^=(_Tp __op) volatile _NOEXCEPT {return fetch_xor(__op) ^ __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator^=(_Tp __op) _NOEXCEPT {return fetch_xor(__op) ^ __op;} -}; - -// atomic - -template -struct atomic - : public __atomic_base<_Tp> -{ - typedef __atomic_base<_Tp> __base; - _LIBCPP_INLINE_VISIBILITY - atomic() _NOEXCEPT {} // = default; - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_CONSTEXPR atomic(_Tp __d) _NOEXCEPT : __base(__d) {} - - _LIBCPP_INLINE_VISIBILITY - _Tp operator=(_Tp __d) volatile _NOEXCEPT - {__base::store(__d); return __d;} - _LIBCPP_INLINE_VISIBILITY - _Tp operator=(_Tp __d) _NOEXCEPT - {__base::store(__d); return __d;} -}; - -// atomic - -template -struct atomic<_Tp*> - : public __atomic_base<_Tp*> -{ - typedef __atomic_base<_Tp*> __base; - _LIBCPP_INLINE_VISIBILITY - atomic() _NOEXCEPT {} // = default; - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_CONSTEXPR atomic(_Tp* __d) _NOEXCEPT : __base(__d) {} - - _LIBCPP_INLINE_VISIBILITY - _Tp* operator=(_Tp* __d) volatile _NOEXCEPT - {__base::store(__d); return __d;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator=(_Tp* __d) _NOEXCEPT - {__base::store(__d); return __d;} - - _LIBCPP_INLINE_VISIBILITY - _Tp* fetch_add(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) - volatile _NOEXCEPT - {return __c11_atomic_fetch_add(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp* fetch_add(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_add(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp* fetch_sub(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) - volatile _NOEXCEPT - {return __c11_atomic_fetch_sub(&this->__a_, __op, __m);} - _LIBCPP_INLINE_VISIBILITY - _Tp* fetch_sub(ptrdiff_t __op, memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_fetch_sub(&this->__a_, __op, __m);} - - _LIBCPP_INLINE_VISIBILITY - _Tp* operator++(int) volatile _NOEXCEPT {return fetch_add(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator++(int) _NOEXCEPT {return fetch_add(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator--(int) volatile _NOEXCEPT {return fetch_sub(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator--(int) _NOEXCEPT {return fetch_sub(1);} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator++() volatile _NOEXCEPT {return fetch_add(1) + 1;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator++() _NOEXCEPT {return fetch_add(1) + 1;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator--() volatile _NOEXCEPT {return fetch_sub(1) - 1;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator--() _NOEXCEPT {return fetch_sub(1) - 1;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator+=(ptrdiff_t __op) volatile _NOEXCEPT {return fetch_add(__op) + __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator+=(ptrdiff_t __op) _NOEXCEPT {return fetch_add(__op) + __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator-=(ptrdiff_t __op) volatile _NOEXCEPT {return fetch_sub(__op) - __op;} - _LIBCPP_INLINE_VISIBILITY - _Tp* operator-=(ptrdiff_t __op) _NOEXCEPT {return fetch_sub(__op) - __op;} -}; - -// atomic_is_lock_free - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_is_lock_free(const volatile atomic<_Tp>* __o) _NOEXCEPT -{ - return __o->is_lock_free(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_is_lock_free(const atomic<_Tp>* __o) _NOEXCEPT -{ - return __o->is_lock_free(); -} - -// atomic_init - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_init(volatile atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - __c11_atomic_init(&__o->__a_, __d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_init(atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - __c11_atomic_init(&__o->__a_, __d); -} - -// atomic_store - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_store(volatile atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - __o->store(__d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_store(atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - __o->store(__d); -} - -// atomic_store_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_store_explicit(volatile atomic<_Tp>* __o, _Tp __d, memory_order __m) _NOEXCEPT -{ - __o->store(__d, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_store_explicit(atomic<_Tp>* __o, _Tp __d, memory_order __m) _NOEXCEPT -{ - __o->store(__d, __m); -} - -// atomic_load - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_load(const volatile atomic<_Tp>* __o) _NOEXCEPT -{ - return __o->load(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_load(const atomic<_Tp>* __o) _NOEXCEPT -{ - return __o->load(); -} - -// atomic_load_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_load_explicit(const volatile atomic<_Tp>* __o, memory_order __m) _NOEXCEPT -{ - return __o->load(__m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_load_explicit(const atomic<_Tp>* __o, memory_order __m) _NOEXCEPT -{ - return __o->load(__m); -} - -// atomic_exchange - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_exchange(volatile atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - return __o->exchange(__d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_exchange(atomic<_Tp>* __o, _Tp __d) _NOEXCEPT -{ - return __o->exchange(__d); -} - -// atomic_exchange_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_exchange_explicit(volatile atomic<_Tp>* __o, _Tp __d, memory_order __m) _NOEXCEPT -{ - return __o->exchange(__d, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -atomic_exchange_explicit(atomic<_Tp>* __o, _Tp __d, memory_order __m) _NOEXCEPT -{ - return __o->exchange(__d, __m); -} - -// atomic_compare_exchange_weak - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_weak(volatile atomic<_Tp>* __o, _Tp* __e, _Tp __d) _NOEXCEPT -{ - return __o->compare_exchange_weak(*__e, __d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_weak(atomic<_Tp>* __o, _Tp* __e, _Tp __d) _NOEXCEPT -{ - return __o->compare_exchange_weak(*__e, __d); -} - -// atomic_compare_exchange_strong - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_strong(volatile atomic<_Tp>* __o, _Tp* __e, _Tp __d) _NOEXCEPT -{ - return __o->compare_exchange_strong(*__e, __d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_strong(atomic<_Tp>* __o, _Tp* __e, _Tp __d) _NOEXCEPT -{ - return __o->compare_exchange_strong(*__e, __d); -} - -// atomic_compare_exchange_weak_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_weak_explicit(volatile atomic<_Tp>* __o, _Tp* __e, - _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT -{ - return __o->compare_exchange_weak(*__e, __d, __s, __f); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_weak_explicit(atomic<_Tp>* __o, _Tp* __e, _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT -{ - return __o->compare_exchange_weak(*__e, __d, __s, __f); -} - -// atomic_compare_exchange_strong_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_strong_explicit(volatile atomic<_Tp>* __o, - _Tp* __e, _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT -{ - return __o->compare_exchange_strong(*__e, __d, __s, __f); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_compare_exchange_strong_explicit(atomic<_Tp>* __o, _Tp* __e, - _Tp __d, - memory_order __s, memory_order __f) _NOEXCEPT -{ - return __o->compare_exchange_strong(*__e, __d, __s, __f); -} - -// atomic_fetch_add - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_add(volatile atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_add(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_add(atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_add(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_add(volatile atomic<_Tp*>* __o, ptrdiff_t __op) _NOEXCEPT -{ - return __o->fetch_add(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_add(atomic<_Tp*>* __o, ptrdiff_t __op) _NOEXCEPT -{ - return __o->fetch_add(__op); -} - -// atomic_fetch_add_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_add_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_add(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_add_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_add(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_add_explicit(volatile atomic<_Tp*>* __o, ptrdiff_t __op, - memory_order __m) _NOEXCEPT -{ - return __o->fetch_add(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_add_explicit(atomic<_Tp*>* __o, ptrdiff_t __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_add(__op, __m); -} - -// atomic_fetch_sub - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_sub(volatile atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_sub(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_sub(atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_sub(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_sub(volatile atomic<_Tp*>* __o, ptrdiff_t __op) _NOEXCEPT -{ - return __o->fetch_sub(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_sub(atomic<_Tp*>* __o, ptrdiff_t __op) _NOEXCEPT -{ - return __o->fetch_sub(__op); -} - -// atomic_fetch_sub_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_sub_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_sub(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_sub_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_sub(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_sub_explicit(volatile atomic<_Tp*>* __o, ptrdiff_t __op, - memory_order __m) _NOEXCEPT -{ - return __o->fetch_sub(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -atomic_fetch_sub_explicit(atomic<_Tp*>* __o, ptrdiff_t __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_sub(__op, __m); -} - -// atomic_fetch_and - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_and(volatile atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_and(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_and(atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_and(__op); -} - -// atomic_fetch_and_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_and_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_and(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_and_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_and(__op, __m); -} - -// atomic_fetch_or - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_or(volatile atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_or(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_or(atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_or(__op); -} - -// atomic_fetch_or_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_or_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_or(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_or_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_or(__op, __m); -} - -// atomic_fetch_xor - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_xor(volatile atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_xor(__op); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_xor(atomic<_Tp>* __o, _Tp __op) _NOEXCEPT -{ - return __o->fetch_xor(__op); -} - -// atomic_fetch_xor_explicit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_xor_explicit(volatile atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_xor(__op, __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value && !is_same<_Tp, bool>::value, - _Tp ->::type -atomic_fetch_xor_explicit(atomic<_Tp>* __o, _Tp __op, memory_order __m) _NOEXCEPT -{ - return __o->fetch_xor(__op, __m); -} - -// flag type and operations - -typedef struct atomic_flag -{ - _Atomic(bool) __a_; - - _LIBCPP_INLINE_VISIBILITY - bool test_and_set(memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {return __c11_atomic_exchange(&__a_, true, __m);} - _LIBCPP_INLINE_VISIBILITY - bool test_and_set(memory_order __m = memory_order_seq_cst) _NOEXCEPT - {return __c11_atomic_exchange(&__a_, true, __m);} - _LIBCPP_INLINE_VISIBILITY - void clear(memory_order __m = memory_order_seq_cst) volatile _NOEXCEPT - {__c11_atomic_store(&__a_, false, __m);} - _LIBCPP_INLINE_VISIBILITY - void clear(memory_order __m = memory_order_seq_cst) _NOEXCEPT - {__c11_atomic_store(&__a_, false, __m);} - - _LIBCPP_INLINE_VISIBILITY - atomic_flag() _NOEXCEPT {} // = default; - _LIBCPP_INLINE_VISIBILITY - atomic_flag(bool __b) _NOEXCEPT : __a_(__b) {} - -#ifndef _LIBCPP_HAS_NO_DELETED_FUNCTIONS - atomic_flag(const atomic_flag&) = delete; - atomic_flag& operator=(const atomic_flag&) = delete; - atomic_flag& operator=(const atomic_flag&) volatile = delete; -#else // _LIBCPP_HAS_NO_DELETED_FUNCTIONS -private: - atomic_flag(const atomic_flag&); - atomic_flag& operator=(const atomic_flag&); - atomic_flag& operator=(const atomic_flag&) volatile; -#endif // _LIBCPP_HAS_NO_DELETED_FUNCTIONS -} atomic_flag; - -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_flag_test_and_set(volatile atomic_flag* __o) _NOEXCEPT -{ - return __o->test_and_set(); -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_flag_test_and_set(atomic_flag* __o) _NOEXCEPT -{ - return __o->test_and_set(); -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_flag_test_and_set_explicit(volatile atomic_flag* __o, memory_order __m) _NOEXCEPT -{ - return __o->test_and_set(__m); -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -atomic_flag_test_and_set_explicit(atomic_flag* __o, memory_order __m) _NOEXCEPT -{ - return __o->test_and_set(__m); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_flag_clear(volatile atomic_flag* __o) _NOEXCEPT -{ - __o->clear(); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_flag_clear(atomic_flag* __o) _NOEXCEPT -{ - __o->clear(); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_flag_clear_explicit(volatile atomic_flag* __o, memory_order __m) _NOEXCEPT -{ - __o->clear(__m); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_flag_clear_explicit(atomic_flag* __o, memory_order __m) _NOEXCEPT -{ - __o->clear(__m); -} - -// fences - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_thread_fence(memory_order __m) _NOEXCEPT -{ - __c11_atomic_thread_fence(__m); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -atomic_signal_fence(memory_order __m) _NOEXCEPT -{ - __c11_atomic_signal_fence(__m); -} - -// Atomics for standard typedef types - -typedef atomic atomic_char; -typedef atomic atomic_schar; -typedef atomic atomic_uchar; -typedef atomic atomic_short; -typedef atomic atomic_ushort; -typedef atomic atomic_int; -typedef atomic atomic_uint; -typedef atomic atomic_long; -typedef atomic atomic_ulong; -typedef atomic atomic_llong; -typedef atomic atomic_ullong; -typedef atomic atomic_char16_t; -typedef atomic atomic_char32_t; -typedef atomic atomic_wchar_t; - -typedef atomic atomic_int_least8_t; -typedef atomic atomic_uint_least8_t; -typedef atomic atomic_int_least16_t; -typedef atomic atomic_uint_least16_t; -typedef atomic atomic_int_least32_t; -typedef atomic atomic_uint_least32_t; -typedef atomic atomic_int_least64_t; -typedef atomic atomic_uint_least64_t; - -typedef atomic atomic_int_fast8_t; -typedef atomic atomic_uint_fast8_t; -typedef atomic atomic_int_fast16_t; -typedef atomic atomic_uint_fast16_t; -typedef atomic atomic_int_fast32_t; -typedef atomic atomic_uint_fast32_t; -typedef atomic atomic_int_fast64_t; -typedef atomic atomic_uint_fast64_t; - -typedef atomic atomic_intptr_t; -typedef atomic atomic_uintptr_t; -typedef atomic atomic_size_t; -typedef atomic atomic_ptrdiff_t; -typedef atomic atomic_intmax_t; -typedef atomic atomic_uintmax_t; - -#define ATOMIC_FLAG_INIT {false} -#define ATOMIC_VAR_INIT(__v) {__v} - -// lock-free property - -#define ATOMIC_CHAR_LOCK_FREE 0 -#define ATOMIC_CHAR16_T_LOCK_FREE 0 -#define ATOMIC_CHAR32_T_LOCK_FREE 0 -#define ATOMIC_WCHAR_T_LOCK_FREE 0 -#define ATOMIC_SHORT_LOCK_FREE 0 -#define ATOMIC_INT_LOCK_FREE 0 -#define ATOMIC_LONG_LOCK_FREE 0 -#define ATOMIC_LLONG_LOCK_FREE 0 - -#endif // !__has_feature(cxx_atomic) - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_ATOMIC diff --git a/libcxx/include/bitset b/libcxx/include/bitset deleted file mode 100644 index 6e12e5ccc515..000000000000 --- a/libcxx/include/bitset +++ /dev/null @@ -1,1050 +0,0 @@ -// -*- C++ -*- -//===---------------------------- bitset ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_BITSET -#define _LIBCPP_BITSET - -/* - bitset synopsis - -namespace std -{ - -namespace std { - -template -class bitset -{ -public: - // bit reference: - class reference - { - friend class bitset; - reference() noexcept; - public: - ~reference() noexcept; - reference& operator=(bool x) noexcept; // for b[i] = x; - reference& operator=(const reference&) noexcept; // for b[i] = b[j]; - bool operator~() const noexcept; // flips the bit - operator bool() const noexcept; // for x = b[i]; - reference& flip() noexcept; // for b[i].flip(); - }; - - // 23.3.5.1 constructors: - constexpr bitset() noexcept; - constexpr bitset(unsigned long long val) noexcept; - template - explicit bitset(const charT* str, - typename basic_string::size_type n = basic_string::npos, - charT zero = charT('0'), charT one = charT('1')); - template - explicit bitset(const basic_string& str, - typename basic_string::size_type pos = 0, - typename basic_string::size_type n = - basic_string::npos, - charT zero = charT('0'), charT one = charT('1')); - - // 23.3.5.2 bitset operations: - bitset& operator&=(const bitset& rhs) noexcept; - bitset& operator|=(const bitset& rhs) noexcept; - bitset& operator^=(const bitset& rhs) noexcept; - bitset& operator<<=(size_t pos) noexcept; - bitset& operator>>=(size_t pos) noexcept; - bitset& set() noexcept; - bitset& set(size_t pos, bool val = true); - bitset& reset() noexcept; - bitset& reset(size_t pos); - bitset operator~() const noexcept; - bitset& flip() noexcept; - bitset& flip(size_t pos); - - // element access: - constexpr bool operator[](size_t pos) const; // for b[i]; - reference operator[](size_t pos); // for b[i]; - unsigned long to_ulong() const; - unsigned long long to_ullong() const; - template - basic_string to_string(charT zero = charT('0'), charT one = charT('1')) const; - template - basic_string > to_string(charT zero = charT('0'), charT one = charT('1')) const; - template - basic_string, allocator > to_string(charT zero = charT('0'), charT one = charT('1')) const; - basic_string, allocator > to_string(char zero = '0', char one = '1') const; - size_t count() const noexcept; - constexpr size_t size() const noexcept; - bool operator==(const bitset& rhs) const noexcept; - bool operator!=(const bitset& rhs) const noexcept; - bool test(size_t pos) const; - bool all() const noexcept; - bool any() const noexcept; - bool none() const noexcept; - bitset operator<<(size_t pos) const noexcept; - bitset operator>>(size_t pos) const noexcept; -}; - -// 23.3.5.3 bitset operators: -template -bitset operator&(const bitset&, const bitset&) noexcept; - -template -bitset operator|(const bitset&, const bitset&) noexcept; - -template -bitset operator^(const bitset&, const bitset&) noexcept; - -template -basic_istream& -operator>>(basic_istream& is, bitset& x); - -template -basic_ostream& -operator<<(basic_ostream& os, const bitset& x); - -template struct hash>; - -} // std - -*/ - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#include <__config> -#include <__bit_reference> -#include -#include -#include -#include -#include -#include <__functional_base> -#if defined(_LIBCPP_NO_EXCEPTIONS) - #include -#endif - -#include <__undef_min_max> - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -class __bitset; - -template -struct __has_storage_type<__bitset<_N_words, _Size> > -{ - static const bool value = true; -}; - -template -class __bitset -{ -public: - typedef ptrdiff_t difference_type; - typedef size_t size_type; -protected: - typedef __bitset __self; - typedef size_type __storage_type; - typedef __storage_type* __storage_pointer; - typedef const __storage_type* __const_storage_pointer; - static const unsigned __bits_per_word = static_cast(sizeof(__storage_type) * CHAR_BIT); - - friend class __bit_reference<__bitset>; - friend class __bit_const_reference<__bitset>; - friend class __bit_iterator<__bitset, false>; - friend class __bit_iterator<__bitset, true>; - friend class __bit_array<__bitset>; - - __storage_type __first_[_N_words]; - - typedef __bit_reference<__bitset> reference; - typedef __bit_const_reference<__bitset> const_reference; - typedef __bit_iterator<__bitset, false> iterator; - typedef __bit_iterator<__bitset, true> const_iterator; - - __bitset() _NOEXCEPT; - explicit __bitset(unsigned long long __v) _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY reference __make_ref(size_t __pos) _NOEXCEPT - {return reference(__first_ + __pos / __bits_per_word, __storage_type(1) << __pos % __bits_per_word);} - _LIBCPP_INLINE_VISIBILITY const_reference __make_ref(size_t __pos) const _NOEXCEPT - {return const_reference(__first_ + __pos / __bits_per_word, __storage_type(1) << __pos % __bits_per_word);} - _LIBCPP_INLINE_VISIBILITY iterator __make_iter(size_t __pos) _NOEXCEPT - {return iterator(__first_ + __pos / __bits_per_word, __pos % __bits_per_word);} - _LIBCPP_INLINE_VISIBILITY const_iterator __make_iter(size_t __pos) const _NOEXCEPT - {return const_iterator(__first_ + __pos / __bits_per_word, __pos % __bits_per_word);} - - void operator&=(const __bitset& __v) _NOEXCEPT; - void operator|=(const __bitset& __v) _NOEXCEPT; - void operator^=(const __bitset& __v) _NOEXCEPT; - - void flip() _NOEXCEPT; - _LIBCPP_INLINE_VISIBILITY unsigned long to_ulong() const - {return to_ulong(integral_constant());} - _LIBCPP_INLINE_VISIBILITY unsigned long long to_ullong() const - {return to_ullong(integral_constant());} - - bool all() const _NOEXCEPT; - bool any() const _NOEXCEPT; - size_t __hash_code() const _NOEXCEPT; -private: - void __init(unsigned long long __v, false_type) _NOEXCEPT; - void __init(unsigned long long __v, true_type) _NOEXCEPT; - unsigned long to_ulong(false_type) const; - unsigned long to_ulong(true_type) const; - unsigned long long to_ullong(false_type) const; - unsigned long long to_ullong(true_type) const; - unsigned long long to_ullong(true_type, false_type) const; - unsigned long long to_ullong(true_type, true_type) const; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__bitset<_N_words, _Size>::__bitset() _NOEXCEPT -{ - _VSTD::fill_n(__first_, _N_words, __storage_type(0)); -} - -template -void -__bitset<_N_words, _Size>::__init(unsigned long long __v, false_type) _NOEXCEPT -{ - __storage_type __t[sizeof(unsigned long long) / sizeof(__storage_type)]; - for (size_t __i = 0; __i < sizeof(__t)/sizeof(__t[0]); ++__i, __v >>= __bits_per_word) - __t[__i] = static_cast<__storage_type>(__v); - _VSTD::copy(__t, __t + sizeof(__t)/sizeof(__t[0]), __first_); - _VSTD::fill(__first_ + sizeof(__t)/sizeof(__t[0]), __first_ + sizeof(__first_)/sizeof(__first_[0]), - __storage_type(0)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<_N_words, _Size>::__init(unsigned long long __v, true_type) _NOEXCEPT -{ - __first_[0] = __v; - _VSTD::fill(__first_ + 1, __first_ + sizeof(__first_)/sizeof(__first_[0]), __storage_type(0)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bitset<_N_words, _Size>::__bitset(unsigned long long __v) _NOEXCEPT -{ - __init(__v, integral_constant()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<_N_words, _Size>::operator&=(const __bitset& __v) _NOEXCEPT -{ - for (size_type __i = 0; __i < _N_words; ++__i) - __first_[__i] &= __v.__first_[__i]; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<_N_words, _Size>::operator|=(const __bitset& __v) _NOEXCEPT -{ - for (size_type __i = 0; __i < _N_words; ++__i) - __first_[__i] |= __v.__first_[__i]; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<_N_words, _Size>::operator^=(const __bitset& __v) _NOEXCEPT -{ - for (size_type __i = 0; __i < _N_words; ++__i) - __first_[__i] ^= __v.__first_[__i]; -} - -template -void -__bitset<_N_words, _Size>::flip() _NOEXCEPT -{ - // do middle whole words - size_type __n = _Size; - __storage_pointer __p = __first_; - for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word) - *__p = ~*__p; - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - __storage_type __b = *__p & __m; - *__p &= ~__m; - *__p |= ~__b & __m; - } -} - -template -unsigned long -__bitset<_N_words, _Size>::to_ulong(false_type) const -{ - const_iterator __e = __make_iter(_Size); - const_iterator __i = _VSTD::find(__make_iter(sizeof(unsigned long) * CHAR_BIT), __e, true); - if (__i != __e) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw overflow_error("bitset to_ulong overflow error"); -#else - assert(!"bitset to_ulong overflow error"); -#endif - return __first_[0]; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long -__bitset<_N_words, _Size>::to_ulong(true_type) const -{ - return __first_[0]; -} - -template -unsigned long long -__bitset<_N_words, _Size>::to_ullong(false_type) const -{ - const_iterator __e = __make_iter(_Size); - const_iterator __i = _VSTD::find(__make_iter(sizeof(unsigned long long) * CHAR_BIT), __e, true); - if (__i != __e) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw overflow_error("bitset to_ullong overflow error"); -#else - assert(!"bitset to_ullong overflow error"); -#endif - return to_ullong(true_type()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -__bitset<_N_words, _Size>::to_ullong(true_type) const -{ - return to_ullong(true_type(), integral_constant()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -__bitset<_N_words, _Size>::to_ullong(true_type, false_type) const -{ - return __first_[0]; -} - -template -unsigned long long -__bitset<_N_words, _Size>::to_ullong(true_type, true_type) const -{ - unsigned long long __r = __first_[0]; - for (std::size_t __i = 1; __i < sizeof(unsigned long long) / sizeof(__storage_type); ++__i) - __r |= static_cast(__first_[__i]) << (sizeof(__storage_type) * CHAR_BIT); - return __r; -} - -template -bool -__bitset<_N_words, _Size>::all() const _NOEXCEPT -{ - // do middle whole words - size_type __n = _Size; - __const_storage_pointer __p = __first_; - for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word) - if (~*__p) - return false; - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - if (~*__p & __m) - return false; - } - return true; -} - -template -bool -__bitset<_N_words, _Size>::any() const _NOEXCEPT -{ - // do middle whole words - size_type __n = _Size; - __const_storage_pointer __p = __first_; - for (; __n >= __bits_per_word; ++__p, __n -= __bits_per_word) - if (*__p) - return true; - // do last partial word - if (__n > 0) - { - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - __n); - if (*__p & __m) - return true; - } - return false; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -size_t -__bitset<_N_words, _Size>::__hash_code() const _NOEXCEPT -{ - size_t __h = 0; - for (size_type __i = 0; __i < _N_words; ++__i) - __h ^= __first_[__i]; - return __h; -} - -template -class __bitset<1, _Size> -{ -public: - typedef ptrdiff_t difference_type; - typedef size_t size_type; -protected: - typedef __bitset __self; - typedef size_type __storage_type; - typedef __storage_type* __storage_pointer; - typedef const __storage_type* __const_storage_pointer; - static const unsigned __bits_per_word = static_cast(sizeof(__storage_type) * CHAR_BIT); - - friend class __bit_reference<__bitset>; - friend class __bit_const_reference<__bitset>; - friend class __bit_iterator<__bitset, false>; - friend class __bit_iterator<__bitset, true>; - friend class __bit_array<__bitset>; - - __storage_type __first_; - - typedef __bit_reference<__bitset> reference; - typedef __bit_const_reference<__bitset> const_reference; - typedef __bit_iterator<__bitset, false> iterator; - typedef __bit_iterator<__bitset, true> const_iterator; - - __bitset() _NOEXCEPT; - explicit __bitset(unsigned long long __v) _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY reference __make_ref(size_t __pos) _NOEXCEPT - {return reference(&__first_, __storage_type(1) << __pos);} - _LIBCPP_INLINE_VISIBILITY const_reference __make_ref(size_t __pos) const _NOEXCEPT - {return const_reference(&__first_, __storage_type(1) << __pos);} - _LIBCPP_INLINE_VISIBILITY iterator __make_iter(size_t __pos) _NOEXCEPT - {return iterator(&__first_ + __pos / __bits_per_word, __pos % __bits_per_word);} - _LIBCPP_INLINE_VISIBILITY const_iterator __make_iter(size_t __pos) const _NOEXCEPT - {return const_iterator(&__first_ + __pos / __bits_per_word, __pos % __bits_per_word);} - - void operator&=(const __bitset& __v) _NOEXCEPT; - void operator|=(const __bitset& __v) _NOEXCEPT; - void operator^=(const __bitset& __v) _NOEXCEPT; - - void flip() _NOEXCEPT; - - unsigned long to_ulong() const; - unsigned long long to_ullong() const; - - bool all() const _NOEXCEPT; - bool any() const _NOEXCEPT; - - size_t __hash_code() const _NOEXCEPT; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__bitset<1, _Size>::__bitset() _NOEXCEPT - : __first_(0) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bitset<1, _Size>::__bitset(unsigned long long __v) _NOEXCEPT - : __first_(static_cast<__storage_type>(__v)) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<1, _Size>::operator&=(const __bitset& __v) _NOEXCEPT -{ - __first_ &= __v.__first_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<1, _Size>::operator|=(const __bitset& __v) _NOEXCEPT -{ - __first_ |= __v.__first_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<1, _Size>::operator^=(const __bitset& __v) _NOEXCEPT -{ - __first_ ^= __v.__first_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__bitset<1, _Size>::flip() _NOEXCEPT -{ - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size); - __first_ = ~__first_; - __first_ &= __m; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long -__bitset<1, _Size>::to_ulong() const -{ - return __first_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -__bitset<1, _Size>::to_ullong() const -{ - return __first_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -__bitset<1, _Size>::all() const _NOEXCEPT -{ - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size); - return !(~__first_ & __m); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -__bitset<1, _Size>::any() const _NOEXCEPT -{ - __storage_type __m = ~__storage_type(0) >> (__bits_per_word - _Size); - return __first_ & __m; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -size_t -__bitset<1, _Size>::__hash_code() const _NOEXCEPT -{ - return __first_; -} - -template <> -class __bitset<0, 0> -{ -public: - typedef ptrdiff_t difference_type; - typedef size_t size_type; -protected: - typedef __bitset __self; - typedef size_type __storage_type; - typedef __storage_type* __storage_pointer; - typedef const __storage_type* __const_storage_pointer; - static const unsigned __bits_per_word = static_cast(sizeof(__storage_type) * CHAR_BIT); - - friend class __bit_reference<__bitset>; - friend class __bit_const_reference<__bitset>; - friend class __bit_iterator<__bitset, false>; - friend class __bit_iterator<__bitset, true>; - friend struct __bit_array<__bitset>; - - typedef __bit_reference<__bitset> reference; - typedef __bit_const_reference<__bitset> const_reference; - typedef __bit_iterator<__bitset, false> iterator; - typedef __bit_iterator<__bitset, true> const_iterator; - - __bitset() _NOEXCEPT; - explicit __bitset(unsigned long long) _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY reference __make_ref(size_t) _NOEXCEPT - {return reference(0, 1);} - _LIBCPP_INLINE_VISIBILITY const_reference __make_ref(size_t) const _NOEXCEPT - {return const_reference(0, 1);} - _LIBCPP_INLINE_VISIBILITY iterator __make_iter(size_t) _NOEXCEPT - {return iterator(0, 0);} - _LIBCPP_INLINE_VISIBILITY const_iterator __make_iter(size_t) const _NOEXCEPT - {return const_iterator(0, 0);} - - _LIBCPP_INLINE_VISIBILITY void operator&=(const __bitset&) _NOEXCEPT {} - _LIBCPP_INLINE_VISIBILITY void operator|=(const __bitset&) _NOEXCEPT {} - _LIBCPP_INLINE_VISIBILITY void operator^=(const __bitset&) _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY void flip() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY unsigned long to_ulong() const {return 0;} - _LIBCPP_INLINE_VISIBILITY unsigned long long to_ullong() const {return 0;} - - _LIBCPP_INLINE_VISIBILITY bool all() const _NOEXCEPT {return true;} - _LIBCPP_INLINE_VISIBILITY bool any() const _NOEXCEPT {return false;} - - _LIBCPP_INLINE_VISIBILITY size_t __hash_code() const _NOEXCEPT {return 0;} -}; - -inline _LIBCPP_INLINE_VISIBILITY -__bitset<0, 0>::__bitset() _NOEXCEPT -{ -} - -inline _LIBCPP_INLINE_VISIBILITY -__bitset<0, 0>::__bitset(unsigned long long) _NOEXCEPT -{ -} - -template class bitset; -template struct hash >; - -template -class _LIBCPP_VISIBLE bitset - : private __bitset<_Size == 0 ? 0 : (_Size - 1) / (sizeof(size_t) * CHAR_BIT) + 1, _Size> -{ - static const unsigned __n_words = _Size == 0 ? 0 : (_Size - 1) / (sizeof(size_t) * CHAR_BIT) + 1; - typedef __bitset<__n_words, _Size> base; - -public: - typedef typename base::reference reference; - typedef typename base::const_reference const_reference; - - // 23.3.5.1 constructors: - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY bitset() _NOEXCEPT {} - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY bitset(unsigned long long __v) _NOEXCEPT : base(__v) {} - template - explicit bitset(const _CharT* __str, - typename basic_string<_CharT>::size_type __n = basic_string<_CharT>::npos, - _CharT __zero = _CharT('0'), _CharT __one = _CharT('1')); - template - explicit bitset(const basic_string<_CharT,_Traits,_Allocator>& __str, - typename basic_string<_CharT,_Traits,_Allocator>::size_type __pos = 0, - typename basic_string<_CharT,_Traits,_Allocator>::size_type __n = - (basic_string<_CharT,_Traits,_Allocator>::npos), - _CharT __zero = _CharT('0'), _CharT __one = _CharT('1')); - - // 23.3.5.2 bitset operations: - bitset& operator&=(const bitset& __rhs) _NOEXCEPT; - bitset& operator|=(const bitset& __rhs) _NOEXCEPT; - bitset& operator^=(const bitset& __rhs) _NOEXCEPT; - bitset& operator<<=(size_t __pos) _NOEXCEPT; - bitset& operator>>=(size_t __pos) _NOEXCEPT; - bitset& set() _NOEXCEPT; - bitset& set(size_t __pos, bool __val = true); - bitset& reset() _NOEXCEPT; - bitset& reset(size_t __pos); - bitset operator~() const _NOEXCEPT; - bitset& flip() _NOEXCEPT; - bitset& flip(size_t __pos); - - // element access: - _LIBCPP_INLINE_VISIBILITY const_reference operator[](size_t __p) const {return base::__make_ref(__p);} - _LIBCPP_INLINE_VISIBILITY reference operator[](size_t __p) {return base::__make_ref(__p);} - unsigned long to_ulong() const; - unsigned long long to_ullong() const; - template - basic_string<_CharT, _Traits, _Allocator> to_string(_CharT __zero = _CharT('0'), - _CharT __one = _CharT('1')) const; - template - basic_string<_CharT, _Traits, allocator<_CharT> > to_string(_CharT __zero = _CharT('0'), - _CharT __one = _CharT('1')) const; - template - basic_string<_CharT, char_traits<_CharT>, allocator<_CharT> > to_string(_CharT __zero = _CharT('0'), - _CharT __one = _CharT('1')) const; - basic_string, allocator > to_string(char __zero = '0', - char __one = '1') const; - size_t count() const _NOEXCEPT; - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY size_t size() const _NOEXCEPT {return _Size;} - bool operator==(const bitset& __rhs) const _NOEXCEPT; - bool operator!=(const bitset& __rhs) const _NOEXCEPT; - bool test(size_t __pos) const; - bool all() const _NOEXCEPT; - bool any() const _NOEXCEPT; - _LIBCPP_INLINE_VISIBILITY bool none() const _NOEXCEPT {return !any();} - bitset operator<<(size_t __pos) const _NOEXCEPT; - bitset operator>>(size_t __pos) const _NOEXCEPT; - -private: - - _LIBCPP_INLINE_VISIBILITY - size_t __hash_code() const _NOEXCEPT {return base::__hash_code();} - - friend struct hash; -}; - -template -template -bitset<_Size>::bitset(const _CharT* __str, - typename basic_string<_CharT>::size_type __n, - _CharT __zero, _CharT __one) -{ - size_t __rlen = _VSTD::min(__n, char_traits<_CharT>::length(__str)); - for (size_t __i = 0; __i < __rlen; ++__i) - if (__str[__i] != __zero && __str[__i] != __one) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw invalid_argument("bitset string ctor has invalid argument"); -#else - assert(!"bitset string ctor has invalid argument"); -#endif - size_t _Mp = _VSTD::min(__rlen, _Size); - size_t __i = 0; - for (; __i < _Mp; ++__i) - { - _CharT __c = __str[_Mp - 1 - __i]; - if (__c == __zero) - (*this)[__i] = false; - else - (*this)[__i] = true; - } - _VSTD::fill(base::__make_iter(__i), base::__make_iter(_Size), false); -} - -template -template -bitset<_Size>::bitset(const basic_string<_CharT,_Traits,_Allocator>& __str, - typename basic_string<_CharT,_Traits,_Allocator>::size_type __pos, - typename basic_string<_CharT,_Traits,_Allocator>::size_type __n, - _CharT __zero, _CharT __one) -{ - if (__pos > __str.size()) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("bitset string pos out of range"); -#else - assert(!"bitset string pos out of range"); -#endif - size_t __rlen = _VSTD::min(__n, __str.size() - __pos); - for (size_t __i = __pos; __i < __pos + __rlen; ++__i) - if (!_Traits::eq(__str[__i], __zero) && !_Traits::eq(__str[__i], __one)) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw invalid_argument("bitset string ctor has invalid argument"); -#else - assert(!"bitset string ctor has invalid argument"); -#endif - size_t _Mp = _VSTD::min(__rlen, _Size); - size_t __i = 0; - for (; __i < _Mp; ++__i) - { - _CharT __c = __str[__pos + _Mp - 1 - __i]; - if (_Traits::eq(__c, __zero)) - (*this)[__i] = false; - else - (*this)[__i] = true; - } - _VSTD::fill(base::__make_iter(__i), base::__make_iter(_Size), false); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::operator&=(const bitset& __rhs) _NOEXCEPT -{ - base::operator&=(__rhs); - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::operator|=(const bitset& __rhs) _NOEXCEPT -{ - base::operator|=(__rhs); - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::operator^=(const bitset& __rhs) _NOEXCEPT -{ - base::operator^=(__rhs); - return *this; -} - -template -bitset<_Size>& -bitset<_Size>::operator<<=(size_t __pos) _NOEXCEPT -{ - __pos = _VSTD::min(__pos, _Size); - _VSTD::copy_backward(base::__make_iter(0), base::__make_iter(_Size - __pos), base::__make_iter(_Size)); - _VSTD::fill_n(base::__make_iter(0), __pos, false); - return *this; -} - -template -bitset<_Size>& -bitset<_Size>::operator>>=(size_t __pos) _NOEXCEPT -{ - __pos = _VSTD::min(__pos, _Size); - _VSTD::copy(base::__make_iter(__pos), base::__make_iter(_Size), base::__make_iter(0)); - _VSTD::fill_n(base::__make_iter(_Size - __pos), __pos, false); - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::set() _NOEXCEPT -{ - _VSTD::fill_n(base::__make_iter(0), _Size, true); - return *this; -} - -template -bitset<_Size>& -bitset<_Size>::set(size_t __pos, bool __val) -{ - if (__pos >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("bitset set argument out of range"); -#else - assert(!"bitset set argument out of range"); -#endif - (*this)[__pos] = __val; - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::reset() _NOEXCEPT -{ - _VSTD::fill_n(base::__make_iter(0), _Size, false); - return *this; -} - -template -bitset<_Size>& -bitset<_Size>::reset(size_t __pos) -{ - if (__pos >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("bitset reset argument out of range"); -#else - assert(!"bitset reset argument out of range"); -#endif - (*this)[__pos] = false; - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -bitset<_Size>::operator~() const _NOEXCEPT -{ - bitset __x(*this); - __x.flip(); - return __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size>& -bitset<_Size>::flip() _NOEXCEPT -{ - base::flip(); - return *this; -} - -template -bitset<_Size>& -bitset<_Size>::flip(size_t __pos) -{ - if (__pos >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("bitset flip argument out of range"); -#else - assert(!"bitset flip argument out of range"); -#endif - reference r = base::__make_ref(__pos); - r = ~r; - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long -bitset<_Size>::to_ulong() const -{ - return base::to_ulong(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -unsigned long long -bitset<_Size>::to_ullong() const -{ - return base::to_ullong(); -} - -template -template -basic_string<_CharT, _Traits, _Allocator> -bitset<_Size>::to_string(_CharT __zero, _CharT __one) const -{ - basic_string<_CharT, _Traits, _Allocator> __r(_Size, __zero); - for (size_t __i = 0; __i < _Size; ++__i) - { - if ((*this)[__i]) - __r[_Size - 1 - __i] = __one; - } - return __r; -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -basic_string<_CharT, _Traits, allocator<_CharT> > -bitset<_Size>::to_string(_CharT __zero, _CharT __one) const -{ - return to_string<_CharT, _Traits, allocator<_CharT> >(__zero, __one); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -basic_string<_CharT, char_traits<_CharT>, allocator<_CharT> > -bitset<_Size>::to_string(_CharT __zero, _CharT __one) const -{ - return to_string<_CharT, char_traits<_CharT>, allocator<_CharT> >(__zero, __one); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_string, allocator > -bitset<_Size>::to_string(char __zero, char __one) const -{ - return to_string, allocator >(__zero, __one); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -size_t -bitset<_Size>::count() const _NOEXCEPT -{ - return static_cast(_VSTD::count(base::__make_iter(0), base::__make_iter(_Size), true)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -bitset<_Size>::operator==(const bitset& __rhs) const _NOEXCEPT -{ - return _VSTD::equal(base::__make_iter(0), base::__make_iter(_Size), __rhs.__make_iter(0)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -bitset<_Size>::operator!=(const bitset& __rhs) const _NOEXCEPT -{ - return !(*this == __rhs); -} - -template -bool -bitset<_Size>::test(size_t __pos) const -{ - if (__pos >= _Size) -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("bitset test argument out of range"); -#else - assert(!"bitset test argument out of range"); -#endif - return (*this)[__pos]; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -bitset<_Size>::all() const _NOEXCEPT -{ - return base::all(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -bitset<_Size>::any() const _NOEXCEPT -{ - return base::any(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -bitset<_Size>::operator<<(size_t __pos) const _NOEXCEPT -{ - bitset __r = *this; - __r <<= __pos; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -bitset<_Size>::operator>>(size_t __pos) const _NOEXCEPT -{ - bitset __r = *this; - __r >>= __pos; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -operator&(const bitset<_Size>& __x, const bitset<_Size>& __y) _NOEXCEPT -{ - bitset<_Size> __r = __x; - __r &= __y; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -operator|(const bitset<_Size>& __x, const bitset<_Size>& __y) _NOEXCEPT -{ - bitset<_Size> __r = __x; - __r |= __y; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bitset<_Size> -operator^(const bitset<_Size>& __x, const bitset<_Size>& __y) _NOEXCEPT -{ - bitset<_Size> __r = __x; - __r ^= __y; - return __r; -} - -template -struct _LIBCPP_VISIBLE hash > - : public unary_function, size_t> -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const bitset<_Size>& __bs) const _NOEXCEPT - {return __bs.__hash_code();} -}; - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x); - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const bitset<_Size>& __x); - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_BITSET diff --git a/libcxx/include/cassert b/libcxx/include/cassert deleted file mode 100644 index 3775990640a9..000000000000 --- a/libcxx/include/cassert +++ /dev/null @@ -1,25 +0,0 @@ -// -*- C++ -*- -//===-------------------------- cassert -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -/* - cassert synopsis - -Macros: - - assert - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif diff --git a/libcxx/include/ccomplex b/libcxx/include/ccomplex deleted file mode 100644 index 6ed116445e64..000000000000 --- a/libcxx/include/ccomplex +++ /dev/null @@ -1,29 +0,0 @@ -// -*- C++ -*- -//===--------------------------- ccomplex ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CCOMPLEX -#define _LIBCPP_CCOMPLEX - -/* - ccomplex synopsis - -#include - -*/ - -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -// hh 080623 Created - -#endif // _LIBCPP_CCOMPLEX diff --git a/libcxx/include/cctype b/libcxx/include/cctype deleted file mode 100644 index e33244e7daa2..000000000000 --- a/libcxx/include/cctype +++ /dev/null @@ -1,164 +0,0 @@ -// -*- C++ -*- -//===---------------------------- cctype ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CCTYPE -#define _LIBCPP_CCTYPE - -/* - cctype synopsis - -namespace std -{ - -int isalnum(int c); -int isalpha(int c); -int isblank(int c); // C99 -int iscntrl(int c); -int isdigit(int c); -int isgraph(int c); -int islower(int c); -int isprint(int c); -int ispunct(int c); -int isspace(int c); -int isupper(int c); -int isxdigit(int c); -int tolower(int c); -int toupper(int c); - -} // std -*/ - -#include <__config> -#include -#if defined(_MSC_VER) -#include "support/win32/support.h" -#endif // _MSC_VER - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -#ifdef isalnum -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isalnum(int __c) {return isalnum(__c);} -#undef isalnum -inline _LIBCPP_INLINE_VISIBILITY int isalnum(int __c) {return __libcpp_isalnum(__c);} -#else // isalnum -using ::isalnum; -#endif // isalnum - -#ifdef isalpha -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isalpha(int __c) {return isalpha(__c);} -#undef isalpha -inline _LIBCPP_INLINE_VISIBILITY int isalpha(int __c) {return __libcpp_isalpha(__c);} -#else // isalpha -using ::isalpha; -#endif // isalpha - -#ifdef isblank -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isblank(int __c) {return isblank(__c);} -#undef isblank -inline _LIBCPP_INLINE_VISIBILITY int isblank(int __c) {return __libcpp_isblank(__c);} -#else // isblank -using ::isblank; -#endif // isblank - -#ifdef iscntrl -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iscntrl(int __c) {return iscntrl(__c);} -#undef iscntrl -inline _LIBCPP_INLINE_VISIBILITY int iscntrl(int __c) {return __libcpp_iscntrl(__c);} -#else // iscntrl -using ::iscntrl; -#endif // iscntrl - -#ifdef isdigit -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isdigit(int __c) {return isdigit(__c);} -#undef isdigit -inline _LIBCPP_INLINE_VISIBILITY int isdigit(int __c) {return __libcpp_isdigit(__c);} -#else // isdigit -using ::isdigit; -#endif // isdigit - -#ifdef isgraph -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isgraph(int __c) {return isgraph(__c);} -#undef isgraph -inline _LIBCPP_INLINE_VISIBILITY int isgraph(int __c) {return __libcpp_isgraph(__c);} -#else // isgraph -using ::isgraph; -#endif // isgraph - -#ifdef islower -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_islower(int __c) {return islower(__c);} -#undef islower -inline _LIBCPP_INLINE_VISIBILITY int islower(int __c) {return __libcpp_islower(__c);} -#else // islower -using ::islower; -#endif // islower - -#ifdef isprint -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isprint(int __c) {return isprint(__c);} -#undef isprint -inline _LIBCPP_INLINE_VISIBILITY int isprint(int __c) {return __libcpp_isprint(__c);} -#else // isprint -using ::isprint; -#endif // isprint - -#ifdef ispunct -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_ispunct(int __c) {return ispunct(__c);} -#undef ispunct -inline _LIBCPP_INLINE_VISIBILITY int ispunct(int __c) {return __libcpp_ispunct(__c);} -#else // ispunct -using ::ispunct; -#endif // ispunct - -#ifdef isspace -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isspace(int __c) {return isspace(__c);} -#undef isspace -inline _LIBCPP_INLINE_VISIBILITY int isspace(int __c) {return __libcpp_isspace(__c);} -#else // isspace -using ::isspace; -#endif // isspace - -#ifdef isupper -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isupper(int __c) {return isupper(__c);} -#undef isupper -inline _LIBCPP_INLINE_VISIBILITY int isupper(int __c) {return __libcpp_isupper(__c);} -#else // isupper -using ::isupper; -#endif // isupper - -#ifdef isxdigit -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isxdigit(int __c) {return isxdigit(__c);} -#undef isxdigit -inline _LIBCPP_INLINE_VISIBILITY int isxdigit(int __c) {return __libcpp_isxdigit(__c);} -#else // isxdigit -using ::isxdigit; -#endif // isxdigit - -#ifdef tolower -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_tolower(int __c) {return tolower(__c);} -#undef tolower -inline _LIBCPP_INLINE_VISIBILITY int tolower(int __c) {return __libcpp_tolower(__c);} -#else // tolower -using ::tolower; -#endif // tolower - -#ifdef toupper -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_toupper(int __c) {return toupper(__c);} -#undef toupper -inline _LIBCPP_INLINE_VISIBILITY int toupper(int __c) {return __libcpp_toupper(__c);} -#else // toupper -using ::toupper; -#endif // toupper - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CCTYPE diff --git a/libcxx/include/cerrno b/libcxx/include/cerrno deleted file mode 100644 index 9804e4e3dcfe..000000000000 --- a/libcxx/include/cerrno +++ /dev/null @@ -1,393 +0,0 @@ -// -*- C++ -*- -//===-------------------------- cerrno ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CERRNO -#define _LIBCPP_CERRNO - -/* - cerrno synopsis - -Macros: - - EDOM - EILSEQ // C99 - ERANGE - errno - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#if !defined(EOWNERDEAD) || !defined(ENOTRECOVERABLE) - -#ifdef ELAST - -const int __elast1 = ELAST+1; -const int __elast2 = ELAST+2; - -#else - -const int __elast1 = 104; -const int __elast2 = 105; - -#endif - -#ifdef ENOTRECOVERABLE - -#define EOWNERDEAD __elast1 - -#ifdef ELAST -#undef ELAST -#define ELAST EOWNERDEAD -#endif - -#elif defined(EOWNERDEAD) - -#define ENOTRECOVERABLE __elast1 -#ifdef ELAST -#undef ELAST -#define ELAST ENOTRECOVERABLE -#endif - -#else // defined(EOWNERDEAD) - -#define EOWNERDEAD __elast1 -#define ENOTRECOVERABLE __elast2 -#ifdef ELAST -#undef ELAST -#define ELAST ENOTRECOVERABLE -#endif - -#endif // defined(EOWNERDEAD) - -#endif // !defined(EOWNERDEAD) || !defined(ENOTRECOVERABLE) - -// supply errno values likely to be missing, particularly on Windows - -#ifndef EAFNOSUPPORT -#define EAFNOSUPPORT 9901 -#endif - -#ifndef EADDRINUSE -#define EADDRINUSE 9902 -#endif - -#ifndef EADDRNOTAVAIL -#define EADDRNOTAVAIL 9903 -#endif - -#ifndef EISCONN -#define EISCONN 9904 -#endif - -#ifndef EBADMSG -#define EBADMSG 9905 -#endif - -#ifndef ECONNABORTED -#define ECONNABORTED 9906 -#endif - -#ifndef EALREADY -#define EALREADY 9907 -#endif - -#ifndef ECONNREFUSED -#define ECONNREFUSED 9908 -#endif - -#ifndef ECONNRESET -#define ECONNRESET 9909 -#endif - -#ifndef EDESTADDRREQ -#define EDESTADDRREQ 9910 -#endif - -#ifndef EHOSTUNREACH -#define EHOSTUNREACH 9911 -#endif - -#ifndef EIDRM -#define EIDRM 9912 -#endif - -#ifndef EMSGSIZE -#define EMSGSIZE 9913 -#endif - -#ifndef ENETDOWN -#define ENETDOWN 9914 -#endif - -#ifndef ENETRESET -#define ENETRESET 9915 -#endif - -#ifndef ENETUNREACH -#define ENETUNREACH 9916 -#endif - -#ifndef ENOBUFS -#define ENOBUFS 9917 -#endif - -#ifndef ENOLINK -#define ENOLINK 9918 -#endif - -#ifndef ENODATA -#define ENODATA 9919 -#endif - -#ifndef ENOMSG -#define ENOMSG 9920 -#endif - -#ifndef ENOPROTOOPT -#define ENOPROTOOPT 9921 -#endif - -#ifndef ENOSR -#define ENOSR 9922 -#endif - -#ifndef ENOTSOCK -#define ENOTSOCK 9923 -#endif - -#ifndef ENOSTR -#define ENOSTR 9924 -#endif - -#ifndef ENOTCONN -#define ENOTCONN 9925 -#endif - -#ifndef ENOTSUP -#define ENOTSUP 9926 -#endif - -#ifndef ECANCELED -#define ECANCELED 9927 -#endif - -#ifndef EINPROGRESS -#define EINPROGRESS 9928 -#endif - -#ifndef EOPNOTSUPP -#define EOPNOTSUPP 9929 -#endif - -#ifndef EWOULDBLOCK -#define EWOULDBLOCK 9930 -#endif - -#ifndef EOWNERDEAD -#define EOWNERDEAD 9931 -#endif - -#ifndef EPROTO -#define EPROTO 9932 -#endif - -#ifndef EPROTONOSUPPORT -#define EPROTONOSUPPORT 9933 -#endif - -#ifndef ENOTRECOVERABLE -#define ENOTRECOVERABLE 9934 -#endif - -#ifndef ETIME -#define ETIME 9935 -#endif - -#ifndef ETXTBSY -#define ETXTBSY 9936 -#endif - -#ifndef ETIMEDOUT -#define ETIMEDOUT 9938 -#endif - -#ifndef ELOOP -#define ELOOP 9939 -#endif - -#ifndef EOVERFLOW -#define EOVERFLOW 9940 -#endif - -#ifndef EPROTOTYPE -#define EPROTOTYPE 9941 -#endif - -#ifndef ENOSYS -#define ENOSYS 9942 -#endif - -#ifndef EINVAL -#define EINVAL 9943 -#endif - -#ifndef ERANGE -#define ERANGE 9944 -#endif - -#ifndef EILSEQ -#define EILSEQ 9945 -#endif - -// Windows Mobile doesn't appear to define these: - -#ifndef E2BIG -#define E2BIG 9946 -#endif - -#ifndef EDOM -#define EDOM 9947 -#endif - -#ifndef EFAULT -#define EFAULT 9948 -#endif - -#ifndef EBADF -#define EBADF 9949 -#endif - -#ifndef EPIPE -#define EPIPE 9950 -#endif - -#ifndef EXDEV -#define EXDEV 9951 -#endif - -#ifndef EBUSY -#define EBUSY 9952 -#endif - -#ifndef ENOTEMPTY -#define ENOTEMPTY 9953 -#endif - -#ifndef ENOEXEC -#define ENOEXEC 9954 -#endif - -#ifndef EEXIST -#define EEXIST 9955 -#endif - -#ifndef EFBIG -#define EFBIG 9956 -#endif - -#ifndef ENAMETOOLONG -#define ENAMETOOLONG 9957 -#endif - -#ifndef ENOTTY -#define ENOTTY 9958 -#endif - -#ifndef EINTR -#define EINTR 9959 -#endif - -#ifndef ESPIPE -#define ESPIPE 9960 -#endif - -#ifndef EIO -#define EIO 9961 -#endif - -#ifndef EISDIR -#define EISDIR 9962 -#endif - -#ifndef ECHILD -#define ECHILD 9963 -#endif - -#ifndef ENOLCK -#define ENOLCK 9964 -#endif - -#ifndef ENOSPC -#define ENOSPC 9965 -#endif - -#ifndef ENXIO -#define ENXIO 9966 -#endif - -#ifndef ENODEV -#define ENODEV 9967 -#endif - -#ifndef ENOENT -#define ENOENT 9968 -#endif - -#ifndef ESRCH -#define ESRCH 9969 -#endif - -#ifndef ENOTDIR -#define ENOTDIR 9970 -#endif - -#ifndef ENOMEM -#define ENOMEM 9971 -#endif - -#ifndef EPERM -#define EPERM 9972 -#endif - -#ifndef EACCES -#define EACCES 9973 -#endif - -#ifndef EROFS -#define EROFS 9974 -#endif - -#ifndef EDEADLK -#define EDEADLK 9975 -#endif - -#ifndef EAGAIN -#define EAGAIN 9976 -#endif - -#ifndef ENFILE -#define ENFILE 9977 -#endif - -#ifndef EMFILE -#define EMFILE 9978 -#endif - -#ifndef EMLINK -#define EMLINK 9979 -#endif - -#endif // _LIBCPP_CERRNO diff --git a/libcxx/include/cfenv b/libcxx/include/cfenv deleted file mode 100644 index dd7db37f8e48..000000000000 --- a/libcxx/include/cfenv +++ /dev/null @@ -1,82 +0,0 @@ -// -*- C++ -*- -//===---------------------------- cctype ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CFENV -#define _LIBCPP_CFENV - -/* - cfenv synopsis - -This entire header is C99 / C++0X - -Macros: - - FE_DIVBYZERO - FE_INEXACT - FE_INVALID - FE_OVERFLOW - FE_UNDERFLOW - FE_ALL_EXCEPT - FE_DOWNWARD - FE_TONEAREST - FE_TOWARDZERO - FE_UPWARD - FE_DFL_ENV - -namespace std -{ - -Types: - - fenv_t - fexcept_t - -int feclearexcept(int excepts); -int fegetexceptflag(fexcept_t* flagp, int excepts); -int feraiseexcept(int excepts); -int fesetexceptflag(const fexcept_t* flagp, int excepts); -int fetestexcept(int excepts); -int fegetround(); -int fesetround(int round); -int fegetenv(fenv_t* envp); -int feholdexcept(fenv_t* envp); -int fesetenv(const fenv_t* envp); -int feupdateenv(const fenv_t* envp); - -} // std -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::fenv_t; -using ::fexcept_t; - -using ::feclearexcept; -using ::fegetexceptflag; -using ::feraiseexcept; -using ::fesetexceptflag; -using ::fetestexcept; -using ::fegetround; -using ::fesetround; -using ::fegetenv; -using ::feholdexcept; -using ::fesetenv; -using ::feupdateenv; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CFENV diff --git a/libcxx/include/cfloat b/libcxx/include/cfloat deleted file mode 100644 index 5fa56550fa6a..000000000000 --- a/libcxx/include/cfloat +++ /dev/null @@ -1,78 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cfloat -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CFLOAT -#define _LIBCPP_CFLOAT - -/* - cfloat synopsis - -Macros: - - FLT_ROUNDS - FLT_EVAL_METHOD // C99 - FLT_RADIX - - FLT_MANT_DIG - DBL_MANT_DIG - LDBL_MANT_DIG - - DECIMAL_DIG // C99 - - FLT_DIG - DBL_DIG - LDBL_DIG - - FLT_MIN_EXP - DBL_MIN_EXP - LDBL_MIN_EXP - - FLT_MIN_10_EXP - DBL_MIN_10_EXP - LDBL_MIN_10_EXP - - FLT_MAX_EXP - DBL_MAX_EXP - LDBL_MAX_EXP - - FLT_MAX_10_EXP - DBL_MAX_10_EXP - LDBL_MAX_10_EXP - - FLT_MAX - DBL_MAX - LDBL_MAX - - FLT_EPSILON - DBL_EPSILON - LDBL_EPSILON - - FLT_MIN - DBL_MIN - LDBL_MIN - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#ifndef FLT_EVAL_METHOD -#define FLT_EVAL_METHOD __FLT_EVAL_METHOD__ -#endif - -#ifndef DECIMAL_DIG -#define DECIMAL_DIG __DECIMAL_DIG__ -#endif - -#endif // _LIBCPP_CFLOAT diff --git a/libcxx/include/chrono b/libcxx/include/chrono deleted file mode 100644 index 0571f9dff7e4..000000000000 --- a/libcxx/include/chrono +++ /dev/null @@ -1,875 +0,0 @@ -// -*- C++ -*- -//===---------------------------- chrono ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CHRONO -#define _LIBCPP_CHRONO - -/* - chrono synopsis - -namespace std -{ -namespace chrono -{ - -template -ToDuration -duration_cast(const duration& fd); - -template struct treat_as_floating_point : is_floating_point {}; - -template -struct duration_values -{ -public: - static Rep zero(); - static Rep max(); - static Rep min(); -}; - -// duration - -template > -class duration -{ - static_assert(!__is_duration::value, "A duration representation can not be a duration"); - static_assert(__is_ratio::value, "Second template parameter of duration must be a std::ratio"); - static_assert(Period::num > 0, "duration period must be positive"); -public: - typedef Rep rep; - typedef Period period; - - duration() = default; - template - explicit duration(const Rep2& r, - typename enable_if - < - is_convertible::value && - (treat_as_floating_point::value || - !treat_as_floating_point::value && !treat_as_floating_point::value) - >::type* = 0); - - // conversions - template - duration(const duration& d, - typename enable_if - < - treat_as_floating_point::value || - ratio_divide::type::den == 1 - >::type* = 0); - - // observer - - rep count() const; - - // arithmetic - - duration operator+() const; - duration operator-() const; - duration& operator++(); - duration operator++(int); - duration& operator--(); - duration operator--(int); - - duration& operator+=(const duration& d); - duration& operator-=(const duration& d); - - duration& operator*=(const rep& rhs); - duration& operator/=(const rep& rhs); - - // special values - - static duration zero(); - static duration min(); - static duration max(); -}; - -typedef duration nanoseconds; -typedef duration microseconds; -typedef duration milliseconds; -typedef duration seconds; -typedef duration< long, ratio< 60> > minutes; -typedef duration< long, ratio<3600> > hours; - -template -class time_point -{ -public: - typedef Clock clock; - typedef Duration duration; - typedef typename duration::rep rep; - typedef typename duration::period period; -private: - duration d_; // exposition only - -public: - time_point(); // has value "epoch" - explicit time_point(const duration& d); // same as time_point() + d - - // conversions - template - time_point(const time_point& t); - - // observer - - duration time_since_epoch() const; - - // arithmetic - - time_point& operator+=(const duration& d); - time_point& operator-=(const duration& d); - - // special values - - static constexpr time_point min(); - static constexpr time_point max(); -}; - -} // chrono - -// common_type traits -template - struct common_type, chrono::duration>; - -template - struct common_type, chrono::time_point>; - -namespace chrono { - -// duration arithmetic -template - typename common_type, duration>::type - operator+(const duration& lhs, const duration& rhs); -template - typename common_type, duration>::type - operator-(const duration& lhs, const duration& rhs); -template - duration::type, Period> - operator*(const duration& d, const Rep2& s); -template - duration::type, Period> - operator*(const Rep1& s, const duration& d); -template - duration::type, Period> - operator/(const duration& d, const Rep2& s); -template - typename common_type::type - operator/(const duration& lhs, const duration& rhs); - -// duration comparisons -template - bool operator==(const duration& lhs, const duration& rhs); -template - bool operator!=(const duration& lhs, const duration& rhs); -template - bool operator< (const duration& lhs, const duration& rhs); -template - bool operator<=(const duration& lhs, const duration& rhs); -template - bool operator> (const duration& lhs, const duration& rhs); -template - bool operator>=(const duration& lhs, const duration& rhs); - -// duration_cast -template - ToDuration duration_cast(const duration& d); - -// time_point arithmetic -template - time_point>::type> - operator+(const time_point& lhs, const duration& rhs); -template - time_point, Duration2>::type> - operator+(const duration& lhs, const time_point& rhs); -template - time_point>::type> - operator-(const time_point& lhs, const duration& rhs); -template - typename common_type::type - operator-(const time_point& lhs, const time_point& rhs); - -// time_point comparisons -template - bool operator==(const time_point& lhs, const time_point& rhs); -template - bool operator!=(const time_point& lhs, const time_point& rhs); -template - bool operator< (const time_point& lhs, const time_point& rhs); -template - bool operator<=(const time_point& lhs, const time_point& rhs); -template - bool operator> (const time_point& lhs, const time_point& rhs); -template - bool operator>=(const time_point& lhs, const time_point& rhs); - -// time_point_cast - -template - time_point time_point_cast(const time_point& t); - -// Clocks - -class system_clock -{ -public: - typedef microseconds duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - static const bool is_steady = false; - - static time_point now() noexcept; - static time_t to_time_t (const time_point& __t) noexcept; - static time_point from_time_t(time_t __t) noexcept; -}; - -class steady_clock -{ -public: - typedef nanoseconds duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - static const bool is_steady = true; - - static time_point now() noexcept; -}; - -typedef steady_clock high_resolution_clock; - -} // chrono - -} // std -*/ - -#include <__config> -#include -#include -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -namespace chrono -{ - -template > class _LIBCPP_VISIBLE duration; - -template -struct __is_duration : false_type {}; - -template -struct __is_duration > : true_type {}; - -template -struct __is_duration > : true_type {}; - -template -struct __is_duration > : true_type {}; - -template -struct __is_duration > : true_type {}; - -} // chrono - -template -struct _LIBCPP_VISIBLE common_type, - chrono::duration<_Rep2, _Period2> > -{ - typedef chrono::duration::type, - typename __ratio_gcd<_Period1, _Period2>::type> type; -}; - -namespace chrono { - -// duration_cast - -template ::type, - bool = _Period::num == 1, - bool = _Period::den == 1> -struct __duration_cast; - -template -struct __duration_cast<_FromDuration, _ToDuration, _Period, true, true> -{ - _LIBCPP_INLINE_VISIBILITY - _ToDuration operator()(const _FromDuration& __fd) const - { - return _ToDuration(static_cast(__fd.count())); - } -}; - -template -struct __duration_cast<_FromDuration, _ToDuration, _Period, true, false> -{ - _LIBCPP_INLINE_VISIBILITY - _ToDuration operator()(const _FromDuration& __fd) const - { - typedef typename common_type::type _Ct; - return _ToDuration(static_cast( - static_cast<_Ct>(__fd.count()) / static_cast<_Ct>(_Period::den))); - } -}; - -template -struct __duration_cast<_FromDuration, _ToDuration, _Period, false, true> -{ - _LIBCPP_INLINE_VISIBILITY - _ToDuration operator()(const _FromDuration& __fd) const - { - typedef typename common_type::type _Ct; - return _ToDuration(static_cast( - static_cast<_Ct>(__fd.count()) * static_cast<_Ct>(_Period::num))); - } -}; - -template -struct __duration_cast<_FromDuration, _ToDuration, _Period, false, false> -{ - _LIBCPP_INLINE_VISIBILITY - _ToDuration operator()(const _FromDuration& __fd) const - { - typedef typename common_type::type _Ct; - return _ToDuration(static_cast( - static_cast<_Ct>(__fd.count()) * static_cast<_Ct>(_Period::num) - / static_cast<_Ct>(_Period::den))); - } -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - __is_duration<_ToDuration>::value, - _ToDuration ->::type -duration_cast(const duration<_Rep, _Period>& __fd) -{ - return __duration_cast, _ToDuration>()(__fd); -} - -template -struct _LIBCPP_VISIBLE treat_as_floating_point : is_floating_point<_Rep> {}; - -template -struct _LIBCPP_VISIBLE duration_values -{ -public: - _LIBCPP_INLINE_VISIBILITY static _Rep zero() {return _Rep(0);} - _LIBCPP_INLINE_VISIBILITY static _Rep max() {return numeric_limits<_Rep>::max();} - _LIBCPP_INLINE_VISIBILITY static _Rep min() {return numeric_limits<_Rep>::lowest();} -}; - -// duration - -template -class _LIBCPP_VISIBLE duration -{ - static_assert(!__is_duration<_Rep>::value, "A duration representation can not be a duration"); - static_assert(__is_ratio<_Period>::value, "Second template parameter of duration must be a std::ratio"); - static_assert(_Period::num > 0, "duration period must be positive"); -public: - typedef _Rep rep; - typedef _Period period; -private: - rep __rep_; -public: - - _LIBCPP_INLINE_VISIBILITY duration() {} // = default; - template - _LIBCPP_INLINE_VISIBILITY - explicit duration(const _Rep2& __r, - typename enable_if - < - is_convertible<_Rep2, rep>::value && - (treat_as_floating_point::value || - !treat_as_floating_point<_Rep2>::value) - >::type* = 0) - : __rep_(__r) {} - - // conversions - template - _LIBCPP_INLINE_VISIBILITY - duration(const duration<_Rep2, _Period2>& __d, - typename enable_if - < - treat_as_floating_point::value || - (ratio_divide<_Period2, period>::type::den == 1 && - !treat_as_floating_point<_Rep2>::value) - >::type* = 0) - : __rep_(_VSTD::chrono::duration_cast(__d).count()) {} - - // observer - - _LIBCPP_INLINE_VISIBILITY rep count() const {return __rep_;} - - // arithmetic - - _LIBCPP_INLINE_VISIBILITY duration operator+() const {return *this;} - _LIBCPP_INLINE_VISIBILITY duration operator-() const {return duration(-__rep_);} - _LIBCPP_INLINE_VISIBILITY duration& operator++() {++__rep_; return *this;} - _LIBCPP_INLINE_VISIBILITY duration operator++(int) {return duration(__rep_++);} - _LIBCPP_INLINE_VISIBILITY duration& operator--() {--__rep_; return *this;} - _LIBCPP_INLINE_VISIBILITY duration operator--(int) {return duration(__rep_--);} - - _LIBCPP_INLINE_VISIBILITY duration& operator+=(const duration& __d) {__rep_ += __d.count(); return *this;} - _LIBCPP_INLINE_VISIBILITY duration& operator-=(const duration& __d) {__rep_ -= __d.count(); return *this;} - - _LIBCPP_INLINE_VISIBILITY duration& operator*=(const rep& rhs) {__rep_ *= rhs; return *this;} - _LIBCPP_INLINE_VISIBILITY duration& operator/=(const rep& rhs) {__rep_ /= rhs; return *this;} - _LIBCPP_INLINE_VISIBILITY duration& operator%=(const rep& rhs) {__rep_ %= rhs; return *this;} - _LIBCPP_INLINE_VISIBILITY duration& operator%=(const duration& rhs) {__rep_ %= rhs.count(); return *this;} - - // special values - - _LIBCPP_INLINE_VISIBILITY static duration zero() {return duration(duration_values::zero());} - _LIBCPP_INLINE_VISIBILITY static duration min() {return duration(duration_values::min());} - _LIBCPP_INLINE_VISIBILITY static duration max() {return duration(duration_values::max());} -}; - -typedef duration nanoseconds; -typedef duration microseconds; -typedef duration milliseconds; -typedef duration seconds; -typedef duration< long, ratio< 60> > minutes; -typedef duration< long, ratio<3600> > hours; - -// Duration == - -template -struct __duration_eq -{ - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _LhsDuration& __lhs, const _RhsDuration& __rhs) - { - typedef typename common_type<_LhsDuration, _RhsDuration>::type _Ct; - return _Ct(__lhs).count() == _Ct(__rhs).count(); - } -}; - -template -struct __duration_eq<_LhsDuration, _LhsDuration> -{ - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _LhsDuration& __lhs, const _LhsDuration& __rhs) - {return __lhs.count() == __rhs.count();} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return __duration_eq, duration<_Rep2, _Period2> >()(__lhs, __rhs); -} - -// Duration != - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return !(__lhs == __rhs); -} - -// Duration < - -template -struct __duration_lt -{ - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _LhsDuration& __lhs, const _RhsDuration& __rhs) - { - typedef typename common_type<_LhsDuration, _RhsDuration>::type _Ct; - return _Ct(__lhs).count() < _Ct(__rhs).count(); - } -}; - -template -struct __duration_lt<_LhsDuration, _LhsDuration> -{ - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _LhsDuration& __lhs, const _LhsDuration& __rhs) - {return __lhs.count() < __rhs.count();} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator< (const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return __duration_lt, duration<_Rep2, _Period2> >()(__lhs, __rhs); -} - -// Duration > - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator> (const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return __rhs < __lhs; -} - -// Duration <= - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return !(__rhs < __lhs); -} - -// Duration >= - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return !(__lhs < __rhs); -} - -// Duration + - -template -inline _LIBCPP_INLINE_VISIBILITY -typename common_type, duration<_Rep2, _Period2> >::type -operator+(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - typename common_type, duration<_Rep2, _Period2> >::type __r = __lhs; - __r += __rhs; - return __r; -} - -// Duration - - -template -inline _LIBCPP_INLINE_VISIBILITY -typename common_type, duration<_Rep2, _Period2> >::type -operator-(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - typename common_type, duration<_Rep2, _Period2> >::type __r = __lhs; - __r -= __rhs; - return __r; -} - -// Duration * - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_convertible<_Rep2, typename common_type<_Rep1, _Rep2>::type>::value, - duration::type, _Period> ->::type -operator*(const duration<_Rep1, _Period>& __d, const _Rep2& __s) -{ - typedef typename common_type<_Rep1, _Rep2>::type _Cr; - duration<_Cr, _Period> __r = __d; - __r *= static_cast<_Cr>(__s); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_convertible<_Rep1, typename common_type<_Rep1, _Rep2>::type>::value, - duration::type, _Period> ->::type -operator*(const _Rep1& __s, const duration<_Rep2, _Period>& __d) -{ - return __d * __s; -} - -// Duration / - -template ::value> -struct __duration_divide_result -{ -}; - -template ::type>::value> -struct __duration_divide_imp -{ -}; - -template -struct __duration_divide_imp, _Rep2, true> -{ - typedef duration::type, _Period> type; -}; - -template -struct __duration_divide_result, _Rep2, false> - : __duration_divide_imp, _Rep2> -{ -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __duration_divide_result, _Rep2>::type -operator/(const duration<_Rep1, _Period>& __d, const _Rep2& __s) -{ - typedef typename common_type<_Rep1, _Rep2>::type _Cr; - duration<_Cr, _Period> __r = __d; - __r /= static_cast<_Cr>(__s); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename common_type<_Rep1, _Rep2>::type -operator/(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - typedef typename common_type, duration<_Rep2, _Period2> >::type _Ct; - return _Ct(__lhs).count() / _Ct(__rhs).count(); -} - -// Duration % - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __duration_divide_result, _Rep2>::type -operator%(const duration<_Rep1, _Period>& __d, const _Rep2& __s) -{ - typedef typename common_type<_Rep1, _Rep2>::type _Cr; - duration<_Cr, _Period> __r = __d; - __r %= static_cast<_Cr>(__s); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename common_type, duration<_Rep2, _Period2> >::type -operator%(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - typename common_type, duration<_Rep2, _Period2> >::type __r = __lhs; - __r %= __rhs; - return __r; -} - -////////////////////////////////////////////////////////// -///////////////////// time_point ///////////////////////// -////////////////////////////////////////////////////////// - -template -class _LIBCPP_VISIBLE time_point -{ - static_assert(__is_duration<_Duration>::value, - "Second template parameter of time_point must be a std::chrono::duration"); -public: - typedef _Clock clock; - typedef _Duration duration; - typedef typename duration::rep rep; - typedef typename duration::period period; -private: - duration __d_; - -public: - _LIBCPP_INLINE_VISIBILITY time_point() : __d_(duration::zero()) {} - _LIBCPP_INLINE_VISIBILITY explicit time_point(const duration& __d) : __d_(__d) {} - - // conversions - template - _LIBCPP_INLINE_VISIBILITY - time_point(const time_point& t, - typename enable_if - < - is_convertible<_Duration2, duration>::value - >::type* = 0) - : __d_(t.time_since_epoch()) {} - - // observer - - _LIBCPP_INLINE_VISIBILITY duration time_since_epoch() const {return __d_;} - - // arithmetic - - _LIBCPP_INLINE_VISIBILITY time_point& operator+=(const duration& __d) {__d_ += __d;} - _LIBCPP_INLINE_VISIBILITY time_point& operator-=(const duration& __d) {__d_ -= __d;} - - // special values - - _LIBCPP_INLINE_VISIBILITY static time_point min() {return time_point(duration::min());} - _LIBCPP_INLINE_VISIBILITY static time_point max() {return time_point(duration::max());} -}; - -} // chrono - -template -struct _LIBCPP_VISIBLE common_type, - chrono::time_point<_Clock, _Duration2> > -{ - typedef chrono::time_point<_Clock, typename common_type<_Duration1, _Duration2>::type> type; -}; - -namespace chrono { - -template -inline _LIBCPP_INLINE_VISIBILITY -time_point<_Clock, _ToDuration> -time_point_cast(const time_point<_Clock, _Duration>& __t) -{ - return time_point<_Clock, _ToDuration>(_VSTD::chrono::duration_cast<_ToDuration>(__t.time_since_epoch())); -} - -// time_point == - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return __lhs.time_since_epoch() == __rhs.time_since_epoch(); -} - -// time_point != - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return !(__lhs == __rhs); -} - -// time_point < - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return __lhs.time_since_epoch() < __rhs.time_since_epoch(); -} - -// time_point > - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return __rhs < __lhs; -} - -// time_point <= - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return !(__rhs < __lhs); -} - -// time_point >= - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return !(__lhs < __rhs); -} - -// time_point operator+(time_point x, duration y); - -template -inline _LIBCPP_INLINE_VISIBILITY -time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type> -operator+(const time_point<_Clock, _Duration1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - typedef time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type> _Tr; - _Tr __r(__lhs.time_since_epoch()); - __r += __rhs; - return __r; -} - -// time_point operator+(duration x, time_point y); - -template -inline _LIBCPP_INLINE_VISIBILITY -time_point<_Clock, typename common_type, _Duration2>::type> -operator+(const duration<_Rep1, _Period1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return __rhs + __lhs; -} - -// time_point operator-(time_point x, duration y); - -template -inline _LIBCPP_INLINE_VISIBILITY -time_point<_Clock, typename common_type<_Duration1, duration<_Rep2, _Period2> >::type> -operator-(const time_point<_Clock, _Duration1>& __lhs, const duration<_Rep2, _Period2>& __rhs) -{ - return __lhs + (-__rhs); -} - -// duration operator-(time_point x, time_point y); - -template -inline _LIBCPP_INLINE_VISIBILITY -typename common_type<_Duration1, _Duration2>::type -operator-(const time_point<_Clock, _Duration1>& __lhs, const time_point<_Clock, _Duration2>& __rhs) -{ - return __lhs.time_since_epoch() - __rhs.time_since_epoch(); -} - -////////////////////////////////////////////////////////// -/////////////////////// clocks /////////////////////////// -////////////////////////////////////////////////////////// - -class _LIBCPP_VISIBLE system_clock -{ -public: - typedef microseconds duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - static const bool is_steady = false; - - static time_point now() _NOEXCEPT; - static time_t to_time_t (const time_point& __t) _NOEXCEPT; - static time_point from_time_t(time_t __t) _NOEXCEPT; -}; - -class _LIBCPP_VISIBLE steady_clock -{ -public: - typedef nanoseconds duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - static const bool is_steady = true; - - static time_point now() _NOEXCEPT; -}; - -typedef steady_clock high_resolution_clock; - -} // chrono - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CHRONO diff --git a/libcxx/include/cinttypes b/libcxx/include/cinttypes deleted file mode 100644 index 786692b8fec3..000000000000 --- a/libcxx/include/cinttypes +++ /dev/null @@ -1,259 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cinttypes --------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CINTTYPES -#define _LIBCPP_CINTTYPES - -/* - cinttypes synopsis - -This entire header is C99 / C++0X - -#include // includes - -Macros: - - PRId8 - PRId16 - PRId32 - PRId64 - - PRIdLEAST8 - PRIdLEAST16 - PRIdLEAST32 - PRIdLEAST64 - - PRIdFAST8 - PRIdFAST16 - PRIdFAST32 - PRIdFAST64 - - PRIdMAX - PRIdPTR - - PRIi8 - PRIi16 - PRIi32 - PRIi64 - - PRIiLEAST8 - PRIiLEAST16 - PRIiLEAST32 - PRIiLEAST64 - - PRIiFAST8 - PRIiFAST16 - PRIiFAST32 - PRIiFAST64 - - PRIiMAX - PRIiPTR - - PRIo8 - PRIo16 - PRIo32 - PRIo64 - - PRIoLEAST8 - PRIoLEAST16 - PRIoLEAST32 - PRIoLEAST64 - - PRIoFAST8 - PRIoFAST16 - PRIoFAST32 - PRIoFAST64 - - PRIoMAX - PRIoPTR - - PRIu8 - PRIu16 - PRIu32 - PRIu64 - - PRIuLEAST8 - PRIuLEAST16 - PRIuLEAST32 - PRIuLEAST64 - - PRIuFAST8 - PRIuFAST16 - PRIuFAST32 - PRIuFAST64 - - PRIuMAX - PRIuPTR - - PRIx8 - PRIx16 - PRIx32 - PRIx64 - - PRIxLEAST8 - PRIxLEAST16 - PRIxLEAST32 - PRIxLEAST64 - - PRIxFAST8 - PRIxFAST16 - PRIxFAST32 - PRIxFAST64 - - PRIxMAX - PRIxPTR - - PRIX8 - PRIX16 - PRIX32 - PRIX64 - - PRIXLEAST8 - PRIXLEAST16 - PRIXLEAST32 - PRIXLEAST64 - - PRIXFAST8 - PRIXFAST16 - PRIXFAST32 - PRIXFAST64 - - PRIXMAX - PRIXPTR - - SCNd8 - SCNd16 - SCNd32 - SCNd64 - - SCNdLEAST8 - SCNdLEAST16 - SCNdLEAST32 - SCNdLEAST64 - - SCNdFAST8 - SCNdFAST16 - SCNdFAST32 - SCNdFAST64 - - SCNdMAX - SCNdPTR - - SCNi8 - SCNi16 - SCNi32 - SCNi64 - - SCNiLEAST8 - SCNiLEAST16 - SCNiLEAST32 - SCNiLEAST64 - - SCNiFAST8 - SCNiFAST16 - SCNiFAST32 - SCNiFAST64 - - SCNiMAX - SCNiPTR - - SCNo8 - SCNo16 - SCNo32 - SCNo64 - - SCNoLEAST8 - SCNoLEAST16 - SCNoLEAST32 - SCNoLEAST64 - - SCNoFAST8 - SCNoFAST16 - SCNoFAST32 - SCNoFAST64 - - SCNoMAX - SCNoPTR - - SCNu8 - SCNu16 - SCNu32 - SCNu64 - - SCNuLEAST8 - SCNuLEAST16 - SCNuLEAST32 - SCNuLEAST64 - - SCNuFAST8 - SCNuFAST16 - SCNuFAST32 - SCNuFAST64 - - SCNuMAX - SCNuPTR - - SCNx8 - SCNx16 - SCNx32 - SCNx64 - - SCNxLEAST8 - SCNxLEAST16 - SCNxLEAST32 - SCNxLEAST64 - - SCNxFAST8 - SCNxFAST16 - SCNxFAST32 - SCNxFAST64 - - SCNxMAX - SCNxPTR - -namespace std -{ - -Types: - - imaxdiv_t - -intmax_t imaxabs(intmax_t j); -imaxdiv_t imaxdiv(intmax_t numer, intmax_t denom); -intmax_t strtoimax(const char* restrict nptr, char** restrict endptr, int base); -uintmax_t strtoumax(const char* restrict nptr, char** restrict endptr, int base); -intmax_t wcstoimax(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); -uintmax_t wcstoumax(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); - -} // std -*/ - -#include <__config> -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using::imaxdiv_t; - -using::imaxabs; -using::imaxdiv; -using::strtoimax; -using::strtoumax; -using::wcstoimax; -using::wcstoumax; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CINTTYPES diff --git a/libcxx/include/ciso646 b/libcxx/include/ciso646 deleted file mode 100644 index b2efc72a9aa1..000000000000 --- a/libcxx/include/ciso646 +++ /dev/null @@ -1,25 +0,0 @@ -// -*- C++ -*- -//===--------------------------- ciso646 ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CISO646 -#define _LIBCPP_CISO646 - -/* - ciso646 synopsis - -*/ - -#include <__config> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#endif // _LIBCPP_CISO646 diff --git a/libcxx/include/climits b/libcxx/include/climits deleted file mode 100644 index 81ffecdf6eef..000000000000 --- a/libcxx/include/climits +++ /dev/null @@ -1,48 +0,0 @@ -// -*- C++ -*- -//===--------------------------- climits ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CLIMITS -#define _LIBCPP_CLIMITS - -/* - climits synopsis - -Macros: - - CHAR_BIT - SCHAR_MIN - SCHAR_MAX - UCHAR_MAX - CHAR_MIN - CHAR_MAX - MB_LEN_MAX - SHRT_MIN - SHRT_MAX - USHRT_MAX - INT_MIN - INT_MAX - UINT_MAX - LONG_MIN - LONG_MAX - ULONG_MAX - LLONG_MIN // C99 - LLONG_MAX // C99 - ULLONG_MAX // C99 - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#endif // _LIBCPP_CLIMITS diff --git a/libcxx/include/clocale b/libcxx/include/clocale deleted file mode 100644 index f8b8f0dd34b6..000000000000 --- a/libcxx/include/clocale +++ /dev/null @@ -1,53 +0,0 @@ -// -*- C++ -*- -//===--------------------------- clocale ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CLOCALE -#define _LIBCPP_CLOCALE - -/* - clocale synopsis - -Macros: - - LC_ALL - LC_COLLATE - LC_CTYPE - LC_MONETARY - LC_NUMERIC - LC_TIME - NULL - -namespace std -{ - -struct lconv; -char* setlocale(int category, const char* locale); -lconv* localeconv(); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::lconv; -using ::setlocale; -using ::localeconv; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CLOCALE diff --git a/libcxx/include/cmath b/libcxx/include/cmath deleted file mode 100644 index 026889f81e5b..000000000000 --- a/libcxx/include/cmath +++ /dev/null @@ -1,1668 +0,0 @@ -// -*- C++ -*- -//===---------------------------- cmath -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CMATH -#define _LIBCPP_CMATH - -/* - cmath synopsis - -Macros: - - HUGE_VAL - HUGE_VALF // C99 - HUGE_VALL // C99 - INFINITY // C99 - NAN // C99 - FP_INFINITE // C99 - FP_NAN // C99 - FP_NORMAL // C99 - FP_SUBNORMAL // C99 - FP_ZERO // C99 - FP_FAST_FMA // C99 - FP_FAST_FMAF // C99 - FP_FAST_FMAL // C99 - FP_ILOGB0 // C99 - FP_ILOGBNAN // C99 - MATH_ERRNO // C99 - MATH_ERREXCEPT // C99 - math_errhandling // C99 - -namespace std -{ - -Types: - - float_t // C99 - double_t // C99 - -// C90 - -floating_point abs(floating_point x); - -floating_point acos (arithmetic x); -float acosf(float x); -long double acosl(long double x); - -floating_point asin (arithmetic x); -float asinf(float x); -long double asinl(long double x); - -floating_point atan (arithmetic x); -float atanf(float x); -long double atanl(long double x); - -floating_point atan2 (arithmetic y, arithmetic x); -float atan2f(float y, float x); -long double atan2l(long double y, long double x); - -floating_point ceil (arithmetic x); -float ceilf(float x); -long double ceill(long double x); - -floating_point cos (arithmetic x); -float cosf(float x); -long double cosl(long double x); - -floating_point cosh (arithmetic x); -float coshf(float x); -long double coshl(long double x); - -floating_point exp (arithmetic x); -float expf(float x); -long double expl(long double x); - -floating_point fabs (arithmetic x); -float fabsf(float x); -long double fabsl(long double x); - -floating_point floor (arithmetic x); -float floorf(float x); -long double floorl(long double x); - -floating_point fmod (arithmetic x, arithmetic y); -float fmodf(float x, float y); -long double fmodl(long double x, long double y); - -floating_point frexp (arithmetic value, int* exp); -float frexpf(float value, int* exp); -long double frexpl(long double value, int* exp); - -floating_point ldexp (arithmetic value, int exp); -float ldexpf(float value, int exp); -long double ldexpl(long double value, int exp); - -floating_point log (arithmetic x); -float logf(float x); -long double logl(long double x); - -floating_point log10 (arithmetic x); -float log10f(float x); -long double log10l(long double x); - -floating_point modf (floating_point value, floating_point* iptr); -float modff(float value, float* iptr); -long double modfl(long double value, long double* iptr); - -floating_point pow (arithmetic x, arithmetic y); -float powf(float x, float y); -long double powl(long double x, long double y); - -floating_point sin (arithmetic x); -float sinf(float x); -long double sinl(long double x); - -floating_point sinh (arithmetic x); -float sinhf(float x); -long double sinhl(long double x); - -floating_point sqrt (arithmetic x); -float sqrtf(float x); -long double sqrtl(long double x); - -floating_point tan (arithmetic x); -float tanf(float x); -long double tanl(long double x); - -floating_point tanh (arithmetic x); -float tanhf(float x); -long double tanhl(long double x); - -// C99 - -bool signbit(floating_point x); - -int fpclassify(floating_point x); - -bool isfinite(floating_point x); -bool isinf(floating_point x); -bool isnan(floating_point x); -bool isnormal(floating_point x); - -bool isgreater(floating_point x, floating_point y); -bool isgreaterequal(floating_point x, floating_point y); -bool isless(floating_point x, floating_point y); -bool islessequal(floating_point x, floating_point y); -bool islessgreater(floating_point x, floating_point y); -bool isunordered(floating_point x, floating_point y); - -floating_point acosh (arithmetic x); -float acoshf(float x); -long double acoshl(long double x); - -floating_point asinh (arithmetic x); -float asinhf(float x); -long double asinhl(long double x); - -floating_point atanh (arithmetic x); -float atanhf(float x); -long double atanhl(long double x); - -floating_point cbrt (arithmetic x); -float cbrtf(float x); -long double cbrtl(long double x); - -floating_point copysign (arithmetic x, arithmetic y); -float copysignf(float x, float y); -long double copysignl(long double x, long double y); - -floating_point erf (arithmetic x); -float erff(float x); -long double erfl(long double x); - -floating_point erfc (arithmetic x); -float erfcf(float x); -long double erfcl(long double x); - -floating_point exp2 (arithmetic x); -float exp2f(float x); -long double exp2l(long double x); - -floating_point expm1 (arithmetic x); -float expm1f(float x); -long double expm1l(long double x); - -floating_point fdim (arithmetic x, arithmetic y); -float fdimf(float x, float y); -long double fdiml(long double x, long double y); - -floating_point fma (arithmetic x, arithmetic y, arithmetic z); -float fmaf(float x, float y, float z); -long double fmal(long double x, long double y, long double z); - -floating_point fmax (arithmetic x, arithmetic y); -float fmaxf(float x, float y); -long double fmaxl(long double x, long double y); - -floating_point fmin (arithmetic x, arithmetic y); -float fminf(float x, float y); -long double fminl(long double x, long double y); - -floating_point hypot (arithmetic x, arithmetic y); -float hypotf(float x, float y); -long double hypotl(long double x, long double y); - -int ilogb (arithmetic x); -int ilogbf(float x); -int ilogbl(long double x); - -floating_point lgamma (arithmetic x); -float lgammaf(float x); -long double lgammal(long double x); - -long long llrint (arithmetic x); -long long llrintf(float x); -long long llrintl(long double x); - -long long llround (arithmetic x); -long long llroundf(float x); -long long llroundl(long double x); - -floating_point log1p (arithmetic x); -float log1pf(float x); -long double log1pl(long double x); - -floating_point log2 (arithmetic x); -float log2f(float x); -long double log2l(long double x); - -floating_point logb (arithmetic x); -float logbf(float x); -long double logbl(long double x); - -long lrint (arithmetic x); -long lrintf(float x); -long lrintl(long double x); - -long lround (arithmetic x); -long lroundf(float x); -long lroundl(long double x); - -double nan (const char* str); -float nanf(const char* str); -long double nanl(const char* str); - -floating_point nearbyint (arithmetic x); -float nearbyintf(float x); -long double nearbyintl(long double x); - -floating_point nextafter (arithmetic x, arithmetic y); -float nextafterf(float x, float y); -long double nextafterl(long double x, long double y); - -floating_point nexttoward (arithmetic x, long double y); -float nexttowardf(float x, long double y); -long double nexttowardl(long double x, long double y); - -floating_point remainder (arithmetic x, arithmetic y); -float remainderf(float x, float y); -long double remainderl(long double x, long double y); - -floating_point remquo (arithmetic x, arithmetic y, int* pquo); -float remquof(float x, float y, int* pquo); -long double remquol(long double x, long double y, int* pquo); - -floating_point rint (arithmetic x); -float rintf(float x); -long double rintl(long double x); - -floating_point round (arithmetic x); -float roundf(float x); -long double roundl(long double x); - -floating_point scalbln (arithmetic x, long ex); -float scalblnf(float x, long ex); -long double scalblnl(long double x, long ex); - -floating_point scalbn (arithmetic x, int ex); -float scalbnf(float x, int ex); -long double scalbnl(long double x, int ex); - -floating_point tgamma (arithmetic x); -float tgammaf(float x); -long double tgammal(long double x); - -floating_point trunc (arithmetic x); -float truncf(float x); -long double truncl(long double x); - -} // std - -*/ - -#include <__config> -#include -#include - -#ifdef _MSC_VER -#include "support/win32/math_win32.h" -#endif - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -// signbit - -#ifdef signbit - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_signbit(_A1 __x) -{ - return signbit(__x); -} - -#undef signbit - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, bool>::type -signbit(_A1 __x) -{ - return __libcpp_signbit(__x); -} - -#endif // signbit - -// fpclassify - -#ifdef fpclassify - -template -_LIBCPP_ALWAYS_INLINE -int -__libcpp_fpclassify(_A1 __x) -{ - return fpclassify(__x); -} - -#undef fpclassify - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, int>::type -fpclassify(_A1 __x) -{ - return __libcpp_fpclassify(__x); -} - -#endif // fpclassify - -// isfinite - -#ifdef isfinite - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isfinite(_A1 __x) -{ - return isfinite(__x); -} - -#undef isfinite - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, bool>::type -isfinite(_A1 __x) -{ - return __libcpp_isfinite(__x); -} - -#endif // isfinite - -// isinf - -#ifdef isinf - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isinf(_A1 __x) -{ - return isinf(__x); -} - -#undef isinf - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, bool>::type -isinf(_A1 __x) -{ - return __libcpp_isinf(__x); -} - -#endif // isinf - -// isnan - -#ifdef isnan - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isnan(_A1 __x) -{ - return isnan(__x); -} - -#undef isnan - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, bool>::type -isnan(_A1 __x) -{ - return __libcpp_isnan(__x); -} - -#endif // isnan - -// isnormal - -#ifdef isnormal - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isnormal(_A1 __x) -{ - return isnormal(__x); -} - -#undef isnormal - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if::value, bool>::type -isnormal(_A1 __x) -{ - return __libcpp_isnormal(__x); -} - -#endif // isnormal - -// isgreater - -#ifdef isgreater - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isgreater(_A1 __x, _A2 __y) -{ - return isgreater(__x, __y); -} - -#undef isgreater - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -isgreater(_A1 __x, _A2 __y) -{ - return __libcpp_isgreater(__x, __y); -} - -#endif // isgreater - -// isgreaterequal - -#ifdef isgreaterequal - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isgreaterequal(_A1 __x, _A2 __y) -{ - return isgreaterequal(__x, __y); -} - -#undef isgreaterequal - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -isgreaterequal(_A1 __x, _A2 __y) -{ - return __libcpp_isgreaterequal(__x, __y); -} - -#endif // isgreaterequal - -// isless - -#ifdef isless - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isless(_A1 __x, _A2 __y) -{ - return isless(__x, __y); -} - -#undef isless - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -isless(_A1 __x, _A2 __y) -{ - return __libcpp_isless(__x, __y); -} - -#endif // isless - -// islessequal - -#ifdef islessequal - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_islessequal(_A1 __x, _A2 __y) -{ - return islessequal(__x, __y); -} - -#undef islessequal - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -islessequal(_A1 __x, _A2 __y) -{ - return __libcpp_islessequal(__x, __y); -} - -#endif // islessequal - -// islessgreater - -#ifdef islessgreater - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_islessgreater(_A1 __x, _A2 __y) -{ - return islessgreater(__x, __y); -} - -#undef islessgreater - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -islessgreater(_A1 __x, _A2 __y) -{ - return __libcpp_islessgreater(__x, __y); -} - -#endif // islessgreater - -// isunordered - -#ifdef isunordered - -template -_LIBCPP_ALWAYS_INLINE -bool -__libcpp_isunordered(_A1 __x, _A2 __y) -{ - return isunordered(__x, __y); -} - -#undef isunordered - -template -inline _LIBCPP_INLINE_VISIBILITY -typename std::enable_if -< - std::is_floating_point<_A1>::value && - std::is_floating_point<_A2>::value, - bool ->::type -isunordered(_A1 __x, _A2 __y) -{ - return __libcpp_isunordered(__x, __y); -} - -#endif // isunordered - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::signbit; -using ::fpclassify; -using ::isfinite; -using ::isinf; -using ::isnan; -using ::isnormal; -using ::isgreater; -using ::isgreaterequal; -using ::isless; -using ::islessequal; -using ::islessgreater; -using ::isunordered; -using ::isunordered; - -using ::float_t; -using ::double_t; - -// abs - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, _A1>::type -abs(_A1 __x) {return fabs(__x);} - -#ifndef __sun__ - -// acos - -using ::acos; -using ::acosf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float acos(float __x) {return acosf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double acos(long double __x) {return acosl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -acos(_A1 __x) {return acos((double)__x);} - -// asin - -using ::asin; -using ::asinf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float asin(float __x) {return asinf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double asin(long double __x) {return asinl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -asin(_A1 __x) {return asin((double)__x);} - -// atan - -using ::atan; -using ::atanf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float atan(float __x) {return atanf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double atan(long double __x) {return atanl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -atan(_A1 __x) {return atan((double)__x);} - -// atan2 - -using ::atan2; -using ::atan2f; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float atan2(float __y, float __x) {return atan2f(__y, __x);} -inline _LIBCPP_INLINE_VISIBILITY long double atan2(long double __y, long double __x) {return atan2l(__y, __x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -atan2(_A1 __y, _A2 __x) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return atan2((__result_type)__y, (__result_type)__x); -} - -// ceil - -using ::ceil; -using ::ceilf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float ceil(float __x) {return ceilf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double ceil(long double __x) {return ceill(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -ceil(_A1 __x) {return ceil((double)__x);} - -// cos - -using ::cos; -using ::cosf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float cos(float __x) {return cosf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double cos(long double __x) {return cosl(__x);} -#endif - -template -inline _LIBCPP_ALWAYS_INLINE _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -cos(_A1 __x) {return cos((double)__x);} - -// cosh - -using ::cosh; -using ::coshf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float cosh(float __x) {return coshf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double cosh(long double __x) {return coshl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -cosh(_A1 __x) {return cosh((double)__x);} - -#endif // __sun__ -// exp - -using ::exp; -using ::expf; - -#ifndef __sun__ - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float exp(float __x) {return expf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double exp(long double __x) {return expl(__x);} -#endif - - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -exp(_A1 __x) {return exp((double)__x);} - -// fabs - -using ::fabs; -using ::fabsf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float fabs(float __x) {return fabsf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double fabs(long double __x) {return fabsl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -fabs(_A1 __x) {return fabs((double)__x);} - -// floor - -using ::floor; -using ::floorf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float floor(float __x) {return floorf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double floor(long double __x) {return floorl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -floor(_A1 __x) {return floor((double)__x);} - -// fmod - -#endif //__sun__ -using ::fmod; -using ::fmodf; -#ifndef __sun__ - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float fmod(float __x, float __y) {return fmodf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double fmod(long double __x, long double __y) {return fmodl(__x, __y);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -fmod(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return fmod((__result_type)__x, (__result_type)__y); -} - - -// frexp - -using ::frexp; -using ::frexpf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float frexp(float __x, int* __e) {return frexpf(__x, __e);} -inline _LIBCPP_INLINE_VISIBILITY long double frexp(long double __x, int* __e) {return frexpl(__x, __e);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -frexp(_A1 __x, int* __e) {return frexp((double)__x, __e);} - -// ldexp - -using ::ldexp; -using ::ldexpf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float ldexp(float __x, int __e) {return ldexpf(__x, __e);} -inline _LIBCPP_INLINE_VISIBILITY long double ldexp(long double __x, int __e) {return ldexpl(__x, __e);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -ldexp(_A1 __x, int __e) {return ldexp((double)__x, __e);} - -// log - -#endif // __sun__ -using ::log; -using ::logf; -#ifndef __sun__ - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float log(float __x) {return logf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double log(long double __x) {return logl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -log(_A1 __x) {return log((double)__x);} - - -// log10 - -using ::log10; -using ::log10f; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float log10(float __x) {return log10f(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double log10(long double __x) {return log10l(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -log10(_A1 __x) {return log10((double)__x);} - -// modf - -using ::modf; -using ::modff; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float modf(float __x, float* __y) {return modff(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double modf(long double __x, long double* __y) {return modfl(__x, __y);} -#endif - -// pow - -#endif // __sun__ -using ::pow; -using ::powf; - -#ifndef __sun__ - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float pow(float __x, float __y) {return powf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double pow(long double __x, long double __y) {return powl(__x, __y);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -pow(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return pow((__result_type)__x, (__result_type)__y); -} - - -// sin - -using ::sin; -using ::sinf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float sin(float __x) {return sinf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double sin(long double __x) {return sinl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -sin(_A1 __x) {return sin((double)__x);} - -// sinh - -using ::sinh; -using ::sinhf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float sinh(float __x) {return sinhf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double sinh(long double __x) {return sinhl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -sinh(_A1 __x) {return sinh((double)__x);} - -// sqrt - -#endif // __sun__ -using ::sqrt; -using ::sqrtf; - - -#if !(defined(_MSC_VER) || defined(__sun__)) -inline _LIBCPP_INLINE_VISIBILITY float sqrt(float __x) {return sqrtf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double sqrt(long double __x) {return sqrtl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -sqrt(_A1 __x) {return sqrt((double)__x);} - -// tan - -using ::tan; -using ::tanf; -#ifndef __sun__ - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float tan(float __x) {return tanf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double tan(long double __x) {return tanl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -tan(_A1 __x) {return tan((double)__x);} - -// tanh - -using ::tanh; -using ::tanhf; - -#ifndef _MSC_VER -inline _LIBCPP_INLINE_VISIBILITY float tanh(float __x) {return tanhf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double tanh(long double __x) {return tanhl(__x);} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -tanh(_A1 __x) {return tanh((double)__x);} - -// acosh - -#ifndef _MSC_VER -using ::acosh; -using ::acoshf; - -inline _LIBCPP_INLINE_VISIBILITY float acosh(float __x) {return acoshf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double acosh(long double __x) {return acoshl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -acosh(_A1 __x) {return acosh((double)__x);} -#endif - -// asinh - -#ifndef _MSC_VER -using ::asinh; -using ::asinhf; - -inline _LIBCPP_INLINE_VISIBILITY float asinh(float __x) {return asinhf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double asinh(long double __x) {return asinhl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -asinh(_A1 __x) {return asinh((double)__x);} -#endif - -// atanh - -#ifndef _MSC_VER -using ::atanh; -using ::atanhf; - -inline _LIBCPP_INLINE_VISIBILITY float atanh(float __x) {return atanhf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double atanh(long double __x) {return atanhl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -atanh(_A1 __x) {return atanh((double)__x);} -#endif - -// cbrt - -#ifndef _MSC_VER -using ::cbrt; -using ::cbrtf; - -inline _LIBCPP_INLINE_VISIBILITY float cbrt(float __x) {return cbrtf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double cbrt(long double __x) {return cbrtl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -cbrt(_A1 __x) {return cbrt((double)__x);} -#endif - -// copysign - -using ::copysign; -using ::copysignf; - -inline _LIBCPP_INLINE_VISIBILITY float copysign(float __x, float __y) {return copysignf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double copysign(long double __x, long double __y) {return copysignl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -copysign(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return copysign((__result_type)__x, (__result_type)__y); -} - -#ifndef _MSC_VER - -// erf - -using ::erf; -using ::erff; - -inline _LIBCPP_INLINE_VISIBILITY float erf(float __x) {return erff(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double erf(long double __x) {return erfl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -erf(_A1 __x) {return erf((double)__x);} - -// erfc - -using ::erfc; -using ::erfcf; - -inline _LIBCPP_INLINE_VISIBILITY float erfc(float __x) {return erfcf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double erfc(long double __x) {return erfcl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -erfc(_A1 __x) {return erfc((double)__x);} - -// exp2 - -using ::exp2; -using ::exp2f; - -inline _LIBCPP_INLINE_VISIBILITY float exp2(float __x) {return exp2f(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double exp2(long double __x) {return exp2l(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -exp2(_A1 __x) {return exp2((double)__x);} - -// expm1 - -using ::expm1; -using ::expm1f; - -inline _LIBCPP_INLINE_VISIBILITY float expm1(float __x) {return expm1f(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double expm1(long double __x) {return expm1l(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -expm1(_A1 __x) {return expm1((double)__x);} - -// fdim - -using ::fdim; -using ::fdimf; - -inline _LIBCPP_INLINE_VISIBILITY float fdim(float __x, float __y) {return fdimf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double fdim(long double __x, long double __y) {return fdiml(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -fdim(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return fdim((__result_type)__x, (__result_type)__y); -} - -// fma - -inline _LIBCPP_INLINE_VISIBILITY float fmaf(float __x, float __y, float __z) {return (float)((double)__x*__y + __z);} -#define FP_FAST_FMAF - -using ::fma; - -inline _LIBCPP_INLINE_VISIBILITY float fma(float __x, float __y, float __z) {return fmaf(__x, __y, __z);} -inline _LIBCPP_INLINE_VISIBILITY long double fma(long double __x, long double __y, long double __z) {return fmal(__x, __y, __z);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value && - is_arithmetic<_A3>::value, - typename __promote<_A1, _A2, _A3>::type ->::type -fma(_A1 __x, _A2 __y, _A3 __z) -{ - typedef typename __promote<_A1, _A2, _A3>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value && - is_same<_A3, __result_type>::value)), ""); - return fma((__result_type)__x, (__result_type)__y, (__result_type)__z); -} - -// fmax - -using ::fmax; -using ::fmaxf; - -inline _LIBCPP_INLINE_VISIBILITY float fmax(float __x, float __y) {return fmaxf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double fmax(long double __x, long double __y) {return fmaxl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -fmax(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return fmax((__result_type)__x, (__result_type)__y); -} - -// fmin - -using ::fmin; -using ::fminf; - -inline _LIBCPP_INLINE_VISIBILITY float fmin(float __x, float __y) {return fminf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double fmin(long double __x, long double __y) {return fminl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -fmin(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return fmin((__result_type)__x, (__result_type)__y); -} - -// hypot - -using ::hypot; -using ::hypotf; - -inline _LIBCPP_INLINE_VISIBILITY float hypot(float __x, float __y) {return hypotf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double hypot(long double __x, long double __y) {return hypotl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -hypot(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return hypot((__result_type)__x, (__result_type)__y); -} - -// ilogb - -using ::ilogb; -using ::ilogbf; - -inline _LIBCPP_INLINE_VISIBILITY int ilogb(float __x) {return ilogbf(__x);} -inline _LIBCPP_INLINE_VISIBILITY int ilogb(long double __x) {return ilogbl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, int>::type -ilogb(_A1 __x) {return ilogb((double)__x);} - -// lgamma - -using ::lgamma; -using ::lgammaf; - -inline _LIBCPP_INLINE_VISIBILITY float lgamma(float __x) {return lgammaf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double lgamma(long double __x) {return lgammal(__x);} - - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -lgamma(_A1 __x) {return lgamma((double)__x);} - - -// llrint - -using ::llrint; -using ::llrintf; - -inline _LIBCPP_INLINE_VISIBILITY long long llrint(float __x) {return llrintf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long long llrint(long double __x) {return llrintl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, long long>::type -llrint(_A1 __x) {return llrint((double)__x);} - -// llround - -using ::llround; -using ::llroundf; - -inline _LIBCPP_INLINE_VISIBILITY long long llround(float __x) {return llroundf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long long llround(long double __x) {return llroundl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, long long>::type -llround(_A1 __x) {return llround((double)__x);} - -// log1p - -using ::log1p; -using ::log1pf; - -inline _LIBCPP_INLINE_VISIBILITY float log1p(float __x) {return log1pf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double log1p(long double __x) {return log1pl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -log1p(_A1 __x) {return log1p((double)__x);} - -// log2 - -using ::log2; -using ::log2f; - -inline _LIBCPP_INLINE_VISIBILITY float log2(float __x) {return log2f(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double log2(long double __x) {return log2l(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -log2(_A1 __x) {return log2((double)__x);} - -// logb - -using ::logb; -using ::logbf; - -inline _LIBCPP_INLINE_VISIBILITY float logb(float __x) {return logbf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double logb(long double __x) {return logbl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -logb(_A1 __x) {return logb((double)__x);} - -// lrint - -using ::lrint; -using ::lrintf; - -inline _LIBCPP_INLINE_VISIBILITY long lrint(float __x) {return lrintf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long lrint(long double __x) {return lrintl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, long>::type -lrint(_A1 __x) {return lrint((double)__x);} - -// lround - -using ::lround; -using ::lroundf; - -inline _LIBCPP_INLINE_VISIBILITY long lround(float __x) {return lroundf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long lround(long double __x) {return lroundl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, long>::type -lround(_A1 __x) {return lround((double)__x);} - -// nan -#endif // _MSC_VER -#endif // __sun__ -using ::nan; -using ::nanf; -#ifndef __sun__ -#ifndef _MSC_VER - -// nearbyint - -using ::nearbyint; -using ::nearbyintf; - -inline _LIBCPP_INLINE_VISIBILITY float nearbyint(float __x) {return nearbyintf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double nearbyint(long double __x) {return nearbyintl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -nearbyint(_A1 __x) {return nearbyint((double)__x);} - -// nextafter - -using ::nextafter; -using ::nextafterf; - -inline _LIBCPP_INLINE_VISIBILITY float nextafter(float __x, float __y) {return nextafterf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double nextafter(long double __x, long double __y) {return nextafterl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -nextafter(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return nextafter((__result_type)__x, (__result_type)__y); -} - -// nexttoward - -using ::nexttoward; -using ::nexttowardf; - -inline _LIBCPP_INLINE_VISIBILITY float nexttoward(float __x, long double __y) {return nexttowardf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double nexttoward(long double __x, long double __y) {return nexttowardl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -nexttoward(_A1 __x, long double __y) {return nexttoward((double)__x, __y);} - -// remainder - -using ::remainder; -using ::remainderf; - -inline _LIBCPP_INLINE_VISIBILITY float remainder(float __x, float __y) {return remainderf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double remainder(long double __x, long double __y) {return remainderl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -remainder(_A1 __x, _A2 __y) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return remainder((__result_type)__x, (__result_type)__y); -} - -// remquo - -using ::remquo; -using ::remquof; - -inline _LIBCPP_INLINE_VISIBILITY float remquo(float __x, float __y, int* __z) {return remquof(__x, __y, __z);} -inline _LIBCPP_INLINE_VISIBILITY long double remquo(long double __x, long double __y, int* __z) {return remquol(__x, __y, __z);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_A1>::value && - is_arithmetic<_A2>::value, - typename __promote<_A1, _A2>::type ->::type -remquo(_A1 __x, _A2 __y, int* __z) -{ - typedef typename __promote<_A1, _A2>::type __result_type; - static_assert((!(is_same<_A1, __result_type>::value && - is_same<_A2, __result_type>::value)), ""); - return remquo((__result_type)__x, (__result_type)__y, __z); -} - -// rint - -using ::rint; -using ::rintf; - -inline _LIBCPP_INLINE_VISIBILITY float rint(float __x) {return rintf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double rint(long double __x) {return rintl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -rint(_A1 __x) {return rint((double)__x);} - -// round - -using ::round; -using ::roundf; - -inline _LIBCPP_INLINE_VISIBILITY float round(float __x) {return roundf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double round(long double __x) {return roundl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -round(_A1 __x) {return round((double)__x);} - -// scalbln - -using ::scalbln; -using ::scalblnf; - -inline _LIBCPP_INLINE_VISIBILITY float scalbln(float __x, long __y) {return scalblnf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double scalbln(long double __x, long __y) {return scalblnl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -scalbln(_A1 __x, long __y) {return scalbln((double)__x, __y);} - -// scalbn - -using ::scalbn; -using ::scalbnf; - -inline _LIBCPP_INLINE_VISIBILITY float scalbn(float __x, int __y) {return scalbnf(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY long double scalbn(long double __x, int __y) {return scalbnl(__x, __y);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -scalbn(_A1 __x, int __y) {return scalbn((double)__x, __y);} - -// tgamma - -using ::tgamma; -using ::tgammaf; - -inline _LIBCPP_INLINE_VISIBILITY float tgamma(float __x) {return tgammaf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double tgamma(long double __x) {return tgammal(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -tgamma(_A1 __x) {return tgamma((double)__x);} - -// trunc - -using ::trunc; -using ::truncf; - -inline _LIBCPP_INLINE_VISIBILITY float trunc(float __x) {return truncf(__x);} -inline _LIBCPP_INLINE_VISIBILITY long double trunc(long double __x) {return truncl(__x);} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if::value, double>::type -trunc(_A1 __x) {return trunc((double)__x);} - -#endif // !_MSC_VER - -using ::acosl; -using ::asinl; -using ::atanl; -using ::atan2l; -using ::ceill; -using ::cosl; -using ::coshl; -using ::expl; -using ::fabsl; -using ::floorl; -using ::fmodl; -using ::frexpl; -using ::ldexpl; -using ::logl; -using ::log10l; -using ::modfl; -using ::powl; -using ::sinl; -using ::sinhl; -using ::sqrtl; -using ::tanl; -#ifndef _MSC_VER -using ::tanhl; -using ::acoshl; -using ::asinhl; -using ::atanhl; -using ::cbrtl; -#endif // !_MSC_VER -using ::copysignl; -#ifndef _MSC_VER -using ::erfl; -using ::erfcl; -using ::exp2l; -using ::expm1l; -using ::fdiml; -using ::fmal; -using ::fmaxl; -using ::fminl; -using ::hypotl; -using ::ilogbl; -using ::lgammal; -using ::llrintl; -using ::llroundl; -using ::log1pl; -using ::log2l; -using ::logbl; -using ::lrintl; -using ::lroundl; -using ::nanl; -using ::nearbyintl; -using ::nextafterl; -using ::nexttowardl; -using ::remainderl; -using ::remquol; -using ::rintl; -using ::roundl; -using ::scalblnl; -using ::scalbnl; -using ::tgammal; -using ::truncl; -#endif // !_MSC_VER - -#else -using ::lgamma; -using ::lgammaf; -#endif // __sun__ -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CMATH diff --git a/libcxx/include/codecvt b/libcxx/include/codecvt deleted file mode 100644 index 6c44e3434746..000000000000 --- a/libcxx/include/codecvt +++ /dev/null @@ -1,547 +0,0 @@ -// -*- C++ -*- -//===-------------------------- codecvt -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CODECVT -#define _LIBCPP_CODECVT - -/* - codecvt synopsis - -namespace std -{ - -enum codecvt_mode -{ - consume_header = 4, - generate_header = 2, - little_endian = 1 -}; - -template -class codecvt_utf8 - : public codecvt -{ - // unspecified -}; - -template -class codecvt_utf16 - : public codecvt -{ - // unspecified -}; - -template -class codecvt_utf8_utf16 - : public codecvt -{ - // unspecified -}; - -} // std - -*/ - -#include <__config> -#include <__locale> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -enum codecvt_mode -{ - consume_header = 4, - generate_header = 2, - little_endian = 1 -}; - -// codecvt_utf8 - -template class __codecvt_utf8; - -template <> -class __codecvt_utf8 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef wchar_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf8 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char16_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf8 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char32_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template -class _LIBCPP_VISIBLE codecvt_utf8 - : public __codecvt_utf8<_Elem> -{ -public: - _LIBCPP_ALWAYS_INLINE - explicit codecvt_utf8(size_t __refs = 0) - : __codecvt_utf8<_Elem>(__refs, _Maxcode, _Mode) {} - - _LIBCPP_ALWAYS_INLINE - ~codecvt_utf8() {} -}; - -// codecvt_utf16 - -template class __codecvt_utf16; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef wchar_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef wchar_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char16_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char16_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char32_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char32_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template -class _LIBCPP_VISIBLE codecvt_utf16 - : public __codecvt_utf16<_Elem, _Mode & little_endian> -{ -public: - _LIBCPP_ALWAYS_INLINE - explicit codecvt_utf16(size_t __refs = 0) - : __codecvt_utf16<_Elem, _Mode & little_endian>(__refs, _Maxcode, _Mode) {} - - _LIBCPP_ALWAYS_INLINE - ~codecvt_utf16() {} -}; - -// codecvt_utf8_utf16 - -template class __codecvt_utf8_utf16; - -template <> -class __codecvt_utf8_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef wchar_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf8_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char32_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template <> -class __codecvt_utf8_utf16 - : public codecvt -{ - unsigned long _Maxcode_; - codecvt_mode _Mode_; -public: - typedef char16_t intern_type; - typedef char extern_type; - typedef mbstate_t state_type; - - _LIBCPP_ALWAYS_INLINE - explicit __codecvt_utf8_utf16(size_t __refs, unsigned long _Maxcode, - codecvt_mode _Mode) - : codecvt(__refs), _Maxcode_(_Maxcode), - _Mode_(_Mode) {} -protected: - virtual result - do_out(state_type& __st, - const intern_type* __frm, const intern_type* __frm_end, const intern_type*& __frm_nxt, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual result - do_in(state_type& __st, - const extern_type* __frm, const extern_type* __frm_end, const extern_type*& __frm_nxt, - intern_type* __to, intern_type* __to_end, intern_type*& __to_nxt) const; - virtual result - do_unshift(state_type& __st, - extern_type* __to, extern_type* __to_end, extern_type*& __to_nxt) const; - virtual int do_encoding() const throw(); - virtual bool do_always_noconv() const throw(); - virtual int do_length(state_type&, const extern_type* __frm, const extern_type* __end, - size_t __mx) const; - virtual int do_max_length() const throw(); -}; - -template -class _LIBCPP_VISIBLE codecvt_utf8_utf16 - : public __codecvt_utf8_utf16<_Elem> -{ -public: - _LIBCPP_ALWAYS_INLINE - explicit codecvt_utf8_utf16(size_t __refs = 0) - : __codecvt_utf8_utf16<_Elem>(__refs, _Maxcode, _Mode) {} - - _LIBCPP_ALWAYS_INLINE - ~codecvt_utf8_utf16() {} -}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CODECVT diff --git a/libcxx/include/complex b/libcxx/include/complex deleted file mode 100644 index 3b660a35a9ab..000000000000 --- a/libcxx/include/complex +++ /dev/null @@ -1,1520 +0,0 @@ -// -*- C++ -*- -//===--------------------------- complex ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_COMPLEX -#define _LIBCPP_COMPLEX - -/* - complex synopsis - -namespace std -{ - -template -class complex -{ -public: - typedef T value_type; - - complex(const T& re = T(), const T& im = T()); - complex(const complex&); - template complex(const complex&); - - T real() const; - T imag() const; - - void real(T); - void imag(T); - - complex& operator= (const T&); - complex& operator+=(const T&); - complex& operator-=(const T&); - complex& operator*=(const T&); - complex& operator/=(const T&); - - complex& operator=(const complex&); - template complex& operator= (const complex&); - template complex& operator+=(const complex&); - template complex& operator-=(const complex&); - template complex& operator*=(const complex&); - template complex& operator/=(const complex&); -}; - -template<> -class complex -{ -public: - typedef float value_type; - - constexpr complex(float re = 0.0f, float im = 0.0f); - explicit constexpr complex(const complex&); - explicit constexpr complex(const complex&); - - constexpr float real() const; - void real(float); - constexpr float imag() const; - void imag(float); - - complex& operator= (float); - complex& operator+=(float); - complex& operator-=(float); - complex& operator*=(float); - complex& operator/=(float); - - complex& operator=(const complex&); - template complex& operator= (const complex&); - template complex& operator+=(const complex&); - template complex& operator-=(const complex&); - template complex& operator*=(const complex&); - template complex& operator/=(const complex&); -}; - -template<> -class complex -{ -public: - typedef double value_type; - - constexpr complex(double re = 0.0, double im = 0.0); - constexpr complex(const complex&); - explicit constexpr complex(const complex&); - - constexpr double real() const; - void real(double); - constexpr double imag() const; - void imag(double); - - complex& operator= (double); - complex& operator+=(double); - complex& operator-=(double); - complex& operator*=(double); - complex& operator/=(double); - complex& operator=(const complex&); - - template complex& operator= (const complex&); - template complex& operator+=(const complex&); - template complex& operator-=(const complex&); - template complex& operator*=(const complex&); - template complex& operator/=(const complex&); -}; - -template<> -class complex -{ -public: - typedef long double value_type; - - constexpr complex(long double re = 0.0L, long double im = 0.0L); - constexpr complex(const complex&); - constexpr complex(const complex&); - - constexpr long double real() const; - void real(long double); - constexpr long double imag() const; - void imag(long double); - - complex& operator=(const complex&); - complex& operator= (long double); - complex& operator+=(long double); - complex& operator-=(long double); - complex& operator*=(long double); - complex& operator/=(long double); - - template complex& operator= (const complex&); - template complex& operator+=(const complex&); - template complex& operator-=(const complex&); - template complex& operator*=(const complex&); - template complex& operator/=(const complex&); -}; - -// 26.3.6 operators: -template complex operator+(const complex&, const complex&); -template complex operator+(const complex&, const T&); -template complex operator+(const T&, const complex&); -template complex operator-(const complex&, const complex&); -template complex operator-(const complex&, const T&); -template complex operator-(const T&, const complex&); -template complex operator*(const complex&, const complex&); -template complex operator*(const complex&, const T&); -template complex operator*(const T&, const complex&); -template complex operator/(const complex&, const complex&); -template complex operator/(const complex&, const T&); -template complex operator/(const T&, const complex&); -template complex operator+(const complex&); -template complex operator-(const complex&); -template bool operator==(const complex&, const complex&); -template bool operator==(const complex&, const T&); -template bool operator==(const T&, const complex&); -template bool operator!=(const complex&, const complex&); -template bool operator!=(const complex&, const T&); -template bool operator!=(const T&, const complex&); - -template - basic_istream& - operator>>(basic_istream&, complex&); -template - basic_ostream& - operator<<(basic_ostream&, const complex&); - -// 26.3.7 values: - -template T real(const complex&); - long double real(long double); - double real(double); -template double real(T); - float real(float); - -template T imag(const complex&); - long double imag(long double); - double imag(double); -template double imag(T); - float imag(float); - -template T abs(const complex&); - -template T arg(const complex&); - long double arg(long double); - double arg(double); -template double arg(T); - float arg(float); - -template T norm(const complex&); - long double norm(long double); - double norm(double); -template double norm(T); - float norm(float); - -template complex conj(const complex&); - complex conj(long double); - complex conj(double); -template complex conj(T); - complex conj(float); - -template complex proj(const complex&); - complex proj(long double); - complex proj(double); -template complex proj(T); - complex proj(float); - -template complex polar(const T&, const T& = 0); - -// 26.3.8 transcendentals: -template complex acos(const complex&); -template complex asin(const complex&); -template complex atan(const complex&); -template complex acosh(const complex&); -template complex asinh(const complex&); -template complex atanh(const complex&); -template complex cos (const complex&); -template complex cosh (const complex&); -template complex exp (const complex&); -template complex log (const complex&); -template complex log10(const complex&); - -template complex pow(const complex&, const T&); -template complex pow(const complex&, const complex&); -template complex pow(const T&, const complex&); - -template complex sin (const complex&); -template complex sinh (const complex&); -template complex sqrt (const complex&); -template complex tan (const complex&); -template complex tanh (const complex&); - -template - basic_istream& - operator>>(basic_istream& is, complex& x); - -template - basic_ostream& - operator<<(basic_ostream& o, const complex& x); - -} // std - -*/ - -#include <__config> -#include -#include -#include -#include -#if defined(_LIBCPP_NO_EXCEPTIONS) - #include -#endif - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class _LIBCPP_VISIBLE complex; - -template complex<_Tp> operator*(const complex<_Tp>& __z, const complex<_Tp>& __w); -template complex<_Tp> operator/(const complex<_Tp>& __x, const complex<_Tp>& __y); - -template -class _LIBCPP_VISIBLE complex -{ -public: - typedef _Tp value_type; -private: - value_type __re_; - value_type __im_; -public: - _LIBCPP_INLINE_VISIBILITY - complex(const value_type& __re = value_type(), const value_type& __im = value_type()) - : __re_(__re), __im_(__im) {} - template _LIBCPP_INLINE_VISIBILITY - complex(const complex<_Xp>& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - - _LIBCPP_INLINE_VISIBILITY value_type real() const {return __re_;} - _LIBCPP_INLINE_VISIBILITY value_type imag() const {return __im_;} - - _LIBCPP_INLINE_VISIBILITY void real(value_type __re) {__re_ = __re;} - _LIBCPP_INLINE_VISIBILITY void imag(value_type __im) {__im_ = __im;} - - _LIBCPP_INLINE_VISIBILITY complex& operator= (const value_type& __re) - {__re_ = __re; __im_ = value_type(); return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator+=(const value_type& __re) {__re_ += __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator-=(const value_type& __re) {__re_ -= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator*=(const value_type& __re) {__re_ *= __re; __im_ *= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator/=(const value_type& __re) {__re_ /= __re; __im_ /= __re; return *this;} - - template _LIBCPP_INLINE_VISIBILITY complex& operator= (const complex<_Xp>& __c) - { - __re_ = __c.real(); - __im_ = __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator+=(const complex<_Xp>& __c) - { - __re_ += __c.real(); - __im_ += __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator-=(const complex<_Xp>& __c) - { - __re_ -= __c.real(); - __im_ -= __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator*=(const complex<_Xp>& __c) - { - *this = *this * __c; - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator/=(const complex<_Xp>& __c) - { - *this = *this / __c; - return *this; - } -}; - -template<> class _LIBCPP_VISIBLE complex; -template<> class _LIBCPP_VISIBLE complex; - -template<> -class _LIBCPP_VISIBLE complex -{ - float __re_; - float __im_; -public: - typedef float value_type; - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY complex(float __re = 0.0f, float __im = 0.0f) - : __re_(__re), __im_(__im) {} - explicit /*constexpr*/ complex(const complex& __c); - explicit /*constexpr*/ complex(const complex& __c); - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY float real() const {return __re_;} - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY float imag() const {return __im_;} - - _LIBCPP_INLINE_VISIBILITY void real(value_type __re) {__re_ = __re;} - _LIBCPP_INLINE_VISIBILITY void imag(value_type __im) {__im_ = __im;} - - _LIBCPP_INLINE_VISIBILITY complex& operator= (float __re) - {__re_ = __re; __im_ = value_type(); return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator+=(float __re) {__re_ += __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator-=(float __re) {__re_ -= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator*=(float __re) {__re_ *= __re; __im_ *= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator/=(float __re) {__re_ /= __re; __im_ /= __re; return *this;} - - template _LIBCPP_INLINE_VISIBILITY complex& operator= (const complex<_Xp>& __c) - { - __re_ = __c.real(); - __im_ = __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator+=(const complex<_Xp>& __c) - { - __re_ += __c.real(); - __im_ += __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator-=(const complex<_Xp>& __c) - { - __re_ -= __c.real(); - __im_ -= __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator*=(const complex<_Xp>& __c) - { - *this = *this * __c; - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator/=(const complex<_Xp>& __c) - { - *this = *this / __c; - return *this; - } -}; - -template<> -class _LIBCPP_VISIBLE complex -{ - double __re_; - double __im_; -public: - typedef double value_type; - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY complex(double __re = 0.0, double __im = 0.0) - : __re_(__re), __im_(__im) {} - /*constexpr*/ complex(const complex& __c); - explicit /*constexpr*/ complex(const complex& __c); - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY double real() const {return __re_;} - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY double imag() const {return __im_;} - - _LIBCPP_INLINE_VISIBILITY void real(value_type __re) {__re_ = __re;} - _LIBCPP_INLINE_VISIBILITY void imag(value_type __im) {__im_ = __im;} - - _LIBCPP_INLINE_VISIBILITY complex& operator= (double __re) - {__re_ = __re; __im_ = value_type(); return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator+=(double __re) {__re_ += __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator-=(double __re) {__re_ -= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator*=(double __re) {__re_ *= __re; __im_ *= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator/=(double __re) {__re_ /= __re; __im_ /= __re; return *this;} - - template _LIBCPP_INLINE_VISIBILITY complex& operator= (const complex<_Xp>& __c) - { - __re_ = __c.real(); - __im_ = __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator+=(const complex<_Xp>& __c) - { - __re_ += __c.real(); - __im_ += __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator-=(const complex<_Xp>& __c) - { - __re_ -= __c.real(); - __im_ -= __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator*=(const complex<_Xp>& __c) - { - *this = *this * __c; - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator/=(const complex<_Xp>& __c) - { - *this = *this / __c; - return *this; - } -}; - -template<> -class _LIBCPP_VISIBLE complex -{ - long double __re_; - long double __im_; -public: - typedef long double value_type; - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY complex(long double __re = 0.0L, long double __im = 0.0L) - : __re_(__re), __im_(__im) {} - /*constexpr*/ complex(const complex& __c); - /*constexpr*/ complex(const complex& __c); - - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY long double real() const {return __re_;} - /*constexpr*/ _LIBCPP_INLINE_VISIBILITY long double imag() const {return __im_;} - - _LIBCPP_INLINE_VISIBILITY void real(value_type __re) {__re_ = __re;} - _LIBCPP_INLINE_VISIBILITY void imag(value_type __im) {__im_ = __im;} - - _LIBCPP_INLINE_VISIBILITY complex& operator= (long double __re) - {__re_ = __re; __im_ = value_type(); return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator+=(long double __re) {__re_ += __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator-=(long double __re) {__re_ -= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator*=(long double __re) {__re_ *= __re; __im_ *= __re; return *this;} - _LIBCPP_INLINE_VISIBILITY complex& operator/=(long double __re) {__re_ /= __re; __im_ /= __re; return *this;} - - template _LIBCPP_INLINE_VISIBILITY complex& operator= (const complex<_Xp>& __c) - { - __re_ = __c.real(); - __im_ = __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator+=(const complex<_Xp>& __c) - { - __re_ += __c.real(); - __im_ += __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator-=(const complex<_Xp>& __c) - { - __re_ -= __c.real(); - __im_ -= __c.imag(); - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator*=(const complex<_Xp>& __c) - { - *this = *this * __c; - return *this; - } - template _LIBCPP_INLINE_VISIBILITY complex& operator/=(const complex<_Xp>& __c) - { - *this = *this / __c; - return *this; - } -}; - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -//constexpr -inline _LIBCPP_INLINE_VISIBILITY -complex::complex(const complex& __c) - : __re_(__c.real()), __im_(__c.imag()) {} - -// 26.3.6 operators: - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator+(const complex<_Tp>& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(__x); - __t += __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator+(const complex<_Tp>& __x, const _Tp& __y) -{ - complex<_Tp> __t(__x); - __t += __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator+(const _Tp& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(__y); - __t += __x; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator-(const complex<_Tp>& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(__x); - __t -= __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator-(const complex<_Tp>& __x, const _Tp& __y) -{ - complex<_Tp> __t(__x); - __t -= __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator-(const _Tp& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(-__y); - __t += __x; - return __t; -} - -template -complex<_Tp> -operator*(const complex<_Tp>& __z, const complex<_Tp>& __w) -{ - _Tp __a = __z.real(); - _Tp __b = __z.imag(); - _Tp __c = __w.real(); - _Tp __d = __w.imag(); - _Tp __ac = __a * __c; - _Tp __bd = __b * __d; - _Tp __ad = __a * __d; - _Tp __bc = __b * __c; - _Tp __x = __ac - __bd; - _Tp __y = __ad + __bc; - if (isnan(__x) && isnan(__y)) - { - bool __recalc = false; - if (isinf(__a) || isinf(__b)) - { - __a = copysign(isinf(__a) ? _Tp(1) : _Tp(0), __a); - __b = copysign(isinf(__b) ? _Tp(1) : _Tp(0), __b); - if (isnan(__c)) - __c = copysign(_Tp(0), __c); - if (isnan(__d)) - __d = copysign(_Tp(0), __d); - __recalc = true; - } - if (isinf(__c) || isinf(__d)) - { - __c = copysign(isinf(__c) ? _Tp(1) : _Tp(0), __c); - __d = copysign(isinf(__d) ? _Tp(1) : _Tp(0), __d); - if (isnan(__a)) - __a = copysign(_Tp(0), __a); - if (isnan(__b)) - __b = copysign(_Tp(0), __b); - __recalc = true; - } - if (!__recalc && (isinf(__ac) || isinf(__bd) || - isinf(__ad) || isinf(__bc))) - { - if (isnan(__a)) - __a = copysign(_Tp(0), __a); - if (isnan(__b)) - __b = copysign(_Tp(0), __b); - if (isnan(__c)) - __c = copysign(_Tp(0), __c); - if (isnan(__d)) - __d = copysign(_Tp(0), __d); - __recalc = true; - } - if (__recalc) - { - __x = _Tp(INFINITY) * (__a * __c - __b * __d); - __y = _Tp(INFINITY) * (__a * __d + __b * __c); - } - } - return complex<_Tp>(__x, __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator*(const complex<_Tp>& __x, const _Tp& __y) -{ - complex<_Tp> __t(__x); - __t *= __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator*(const _Tp& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(__y); - __t *= __x; - return __t; -} - -template -complex<_Tp> -operator/(const complex<_Tp>& __z, const complex<_Tp>& __w) -{ - int __ilogbw = 0; - _Tp __a = __z.real(); - _Tp __b = __z.imag(); - _Tp __c = __w.real(); - _Tp __d = __w.imag(); - _Tp __logbw = logb(fmax(fabs(__c), fabs(__d))); - if (isfinite(__logbw)) - { - __ilogbw = static_cast(__logbw); - __c = scalbn(__c, -__ilogbw); - __d = scalbn(__d, -__ilogbw); - } - _Tp __denom = __c * __c + __d * __d; - _Tp __x = scalbn((__a * __c + __b * __d) / __denom, -__ilogbw); - _Tp __y = scalbn((__b * __c - __a * __d) / __denom, -__ilogbw); - if (isnan(__x) && isnan(__y)) - { - if ((__denom == _Tp(0)) && (!isnan(__a) || !isnan(__b))) - { - __x = copysign(_Tp(INFINITY), __c) * __a; - __y = copysign(_Tp(INFINITY), __c) * __b; - } - else if ((isinf(__a) || isinf(__b)) && isfinite(__c) && isfinite(__d)) - { - __a = copysign(isinf(__a) ? _Tp(1) : _Tp(0), __a); - __b = copysign(isinf(__b) ? _Tp(1) : _Tp(0), __b); - __x = _Tp(INFINITY) * (__a * __c + __b * __d); - __y = _Tp(INFINITY) * (__b * __c - __a * __d); - } - else if (isinf(__logbw) && __logbw > _Tp(0) && isfinite(__a) && isfinite(__b)) - { - __c = copysign(isinf(__c) ? _Tp(1) : _Tp(0), __c); - __d = copysign(isinf(__d) ? _Tp(1) : _Tp(0), __d); - __x = _Tp(0) * (__a * __c + __b * __d); - __y = _Tp(0) * (__b * __c - __a * __d); - } - } - return complex<_Tp>(__x, __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator/(const complex<_Tp>& __x, const _Tp& __y) -{ - return complex<_Tp>(__x.real() / __y, __x.imag() / __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator/(const _Tp& __x, const complex<_Tp>& __y) -{ - complex<_Tp> __t(__x); - __t /= __y; - return __t; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator+(const complex<_Tp>& __x) -{ - return __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -operator-(const complex<_Tp>& __x) -{ - return complex<_Tp>(-__x.real(), -__x.imag()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const complex<_Tp>& __x, const complex<_Tp>& __y) -{ - return __x.real() == __y.real() && __x.imag() == __y.imag(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const complex<_Tp>& __x, const _Tp& __y) -{ - return __x.real() == __y && __x.imag() == 0; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const _Tp& __x, const complex<_Tp>& __y) -{ - return __x == __y.real() && 0 == __y.imag(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const complex<_Tp>& __x, const complex<_Tp>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const complex<_Tp>& __x, const _Tp& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const _Tp& __x, const complex<_Tp>& __y) -{ - return !(__x == __y); -} - -// 26.3.7 values: - -// real - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -real(const complex<_Tp>& __c) -{ - return __c.real(); -} - -inline _LIBCPP_INLINE_VISIBILITY -long double -real(long double __re) -{ - return __re; -} - -inline _LIBCPP_INLINE_VISIBILITY -double -real(double __re) -{ - return __re; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - double ->::type -real(_Tp __re) -{ - return __re; -} - -inline _LIBCPP_INLINE_VISIBILITY -float -real(float __re) -{ - return __re; -} - -// imag - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -imag(const complex<_Tp>& __c) -{ - return __c.imag(); -} - -inline _LIBCPP_INLINE_VISIBILITY -long double -imag(long double __re) -{ - return 0; -} - -inline _LIBCPP_INLINE_VISIBILITY -double -imag(double __re) -{ - return 0; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - double ->::type -imag(_Tp __re) -{ - return 0; -} - -inline _LIBCPP_INLINE_VISIBILITY -float -imag(float __re) -{ - return 0; -} - -// abs - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -abs(const complex<_Tp>& __c) -{ - return hypot(__c.real(), __c.imag()); -} - -// arg - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -arg(const complex<_Tp>& __c) -{ - return atan2(__c.imag(), __c.real()); -} - -inline _LIBCPP_INLINE_VISIBILITY -long double -arg(long double __re) -{ - return atan2l(0.L, __re); -} - -inline _LIBCPP_INLINE_VISIBILITY -double -arg(double __re) -{ - return atan2(0., __re); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - double ->::type -arg(_Tp __re) -{ - return atan2(0., __re); -} - -inline _LIBCPP_INLINE_VISIBILITY -float -arg(float __re) -{ - return atan2f(0.F, __re); -} - -// norm - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp -norm(const complex<_Tp>& __c) -{ - if (isinf(__c.real())) - return abs(__c.real()); - if (isinf(__c.imag())) - return abs(__c.imag()); - return __c.real() * __c.real() + __c.imag() * __c.imag(); -} - -inline _LIBCPP_INLINE_VISIBILITY -long double -norm(long double __re) -{ - return __re * __re; -} - -inline _LIBCPP_INLINE_VISIBILITY -double -norm(double __re) -{ - return __re * __re; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - double ->::type -norm(_Tp __re) -{ - return (double)__re * __re; -} - -inline _LIBCPP_INLINE_VISIBILITY -float -norm(float __re) -{ - return __re * __re; -} - -// conj - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -conj(const complex<_Tp>& __c) -{ - return complex<_Tp>(__c.real(), -__c.imag()); -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -conj(long double __re) -{ - return complex(__re); -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -conj(double __re) -{ - return complex(__re); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - complex ->::type -conj(_Tp __re) -{ - return complex(__re); -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -conj(float __re) -{ - return complex(__re); -} - -// proj - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -proj(const complex<_Tp>& __c) -{ - std::complex<_Tp> __r = __c; - if (isinf(__c.real()) || isinf(__c.imag())) - __r = complex<_Tp>(INFINITY, copysign(_Tp(0), __c.imag())); - return __r; -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -proj(long double __re) -{ - if (isinf(__re)) - __re = abs(__re); - return complex(__re); -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -proj(double __re) -{ - if (isinf(__re)) - __re = abs(__re); - return complex(__re); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_integral<_Tp>::value, - complex ->::type -proj(_Tp __re) -{ - return complex(__re); -} - -inline _LIBCPP_INLINE_VISIBILITY -complex -proj(float __re) -{ - if (isinf(__re)) - __re = abs(__re); - return complex(__re); -} - -// polar - -template -complex<_Tp> -polar(const _Tp& __rho, const _Tp& __theta = _Tp(0)) -{ - if (isnan(__rho) || signbit(__rho)) - return complex<_Tp>(_Tp(NAN), _Tp(NAN)); - if (isnan(__theta)) - { - if (isinf(__rho)) - return complex<_Tp>(__rho, __theta); - return complex<_Tp>(__theta, __theta); - } - if (isinf(__theta)) - { - if (isinf(__rho)) - return complex<_Tp>(__rho, _Tp(NAN)); - return complex<_Tp>(_Tp(NAN), _Tp(NAN)); - } - _Tp __x = __rho * cos(__theta); - if (isnan(__x)) - __x = 0; - _Tp __y = __rho * sin(__theta); - if (isnan(__y)) - __y = 0; - return complex<_Tp>(__x, __y); -} - -// log - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -log(const complex<_Tp>& __x) -{ - return complex<_Tp>(log(abs(__x)), arg(__x)); -} - -// log10 - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -log10(const complex<_Tp>& __x) -{ - return log(__x) / log(_Tp(10)); -} - -// sqrt - -template -complex<_Tp> -sqrt(const complex<_Tp>& __x) -{ - if (isinf(__x.imag())) - return complex<_Tp>(_Tp(INFINITY), __x.imag()); - if (isinf(__x.real())) - { - if (__x.real() > _Tp(0)) - return complex<_Tp>(__x.real(), isnan(__x.imag()) ? __x.imag() : copysign(_Tp(0), __x.imag())); - return complex<_Tp>(isnan(__x.imag()) ? __x.imag() : _Tp(0), copysign(__x.real(), __x.imag())); - } - return polar(sqrt(abs(__x)), arg(__x) / _Tp(2)); -} - -// exp - -template -complex<_Tp> -exp(const complex<_Tp>& __x) -{ - _Tp __i = __x.imag(); - if (isinf(__x.real())) - { - if (__x.real() < _Tp(0)) - { - if (!isfinite(__i)) - __i = _Tp(1); - } - else if (__i == 0 || !isfinite(__i)) - { - if (isinf(__i)) - __i = _Tp(NAN); - return complex<_Tp>(__x.real(), __i); - } - } - else if (isnan(__x.real()) && __x.imag() == 0) - return __x; - _Tp __e = exp(__x.real()); - return complex<_Tp>(__e * cos(__i), __e * sin(__i)); -} - -// pow - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -pow(const complex<_Tp>& __x, const complex<_Tp>& __y) -{ - return exp(__y * log(__x)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -complex::type> -pow(const complex<_Tp>& __x, const complex<_Up>& __y) -{ - typedef complex::type> result_type; - return _VSTD::pow(result_type(__x), result_type(__y)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_Up>::value, - complex::type> ->::type -pow(const complex<_Tp>& __x, const _Up& __y) -{ - typedef complex::type> result_type; - return _VSTD::pow(result_type(__x), result_type(__y)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_arithmetic<_Tp>::value, - complex::type> ->::type -pow(const _Tp& __x, const complex<_Up>& __y) -{ - typedef complex::type> result_type; - return _VSTD::pow(result_type(__x), result_type(__y)); -} - -// asinh - -template -complex<_Tp> -asinh(const complex<_Tp>& __x) -{ - const _Tp __pi(atan2(+0., -0.)); - if (isinf(__x.real())) - { - if (isnan(__x.imag())) - return __x; - if (isinf(__x.imag())) - return complex<_Tp>(__x.real(), copysign(__pi * _Tp(0.25), __x.imag())); - return complex<_Tp>(__x.real(), copysign(_Tp(0), __x.imag())); - } - if (isnan(__x.real())) - { - if (isinf(__x.imag())) - return complex<_Tp>(__x.imag(), __x.real()); - if (__x.imag() == 0) - return __x; - return complex<_Tp>(__x.real(), __x.real()); - } - if (isinf(__x.imag())) - return complex<_Tp>(copysign(__x.imag(), __x.real()), copysign(__pi/_Tp(2), __x.imag())); - complex<_Tp> __z = log(__x + sqrt(pow(__x, _Tp(2)) + _Tp(1))); - return complex<_Tp>(copysign(__z.real(), __x.real()), copysign(__z.imag(), __x.imag())); -} - -// acosh - -template -complex<_Tp> -acosh(const complex<_Tp>& __x) -{ - const _Tp __pi(atan2(+0., -0.)); - if (isinf(__x.real())) - { - if (isnan(__x.imag())) - return complex<_Tp>(abs(__x.real()), __x.imag()); - if (isinf(__x.imag())) - if (__x.real() > 0) - return complex<_Tp>(__x.real(), copysign(__pi * _Tp(0.25), __x.imag())); - else - return complex<_Tp>(-__x.real(), copysign(__pi * _Tp(0.75), __x.imag())); - if (__x.real() < 0) - return complex<_Tp>(-__x.real(), copysign(__pi, __x.imag())); - return complex<_Tp>(__x.real(), copysign(_Tp(0), __x.imag())); - } - if (isnan(__x.real())) - { - if (isinf(__x.imag())) - return complex<_Tp>(abs(__x.imag()), __x.real()); - return complex<_Tp>(__x.real(), __x.real()); - } - if (isinf(__x.imag())) - return complex<_Tp>(abs(__x.imag()), copysign(__pi/_Tp(2), __x.imag())); - complex<_Tp> __z = log(__x + sqrt(pow(__x, _Tp(2)) - _Tp(1))); - return complex<_Tp>(copysign(__z.real(), _Tp(0)), copysign(__z.imag(), __x.imag())); -} - -// atanh - -template -complex<_Tp> -atanh(const complex<_Tp>& __x) -{ - const _Tp __pi(atan2(+0., -0.)); - if (isinf(__x.imag())) - { - return complex<_Tp>(copysign(_Tp(0), __x.real()), copysign(__pi/_Tp(2), __x.imag())); - } - if (isnan(__x.imag())) - { - if (isinf(__x.real()) || __x.real() == 0) - return complex<_Tp>(copysign(_Tp(0), __x.real()), __x.imag()); - return complex<_Tp>(__x.imag(), __x.imag()); - } - if (isnan(__x.real())) - { - return complex<_Tp>(__x.real(), __x.real()); - } - if (isinf(__x.real())) - { - return complex<_Tp>(copysign(_Tp(0), __x.real()), copysign(__pi/_Tp(2), __x.imag())); - } - if (abs(__x.real()) == _Tp(1) && __x.imag() == _Tp(0)) - { - return complex<_Tp>(copysign(_Tp(INFINITY), __x.real()), copysign(_Tp(0), __x.imag())); - } - complex<_Tp> __z = log((_Tp(1) + __x) / (_Tp(1) - __x)) / _Tp(2); - return complex<_Tp>(copysign(__z.real(), __x.real()), copysign(__z.imag(), __x.imag())); -} - -// sinh - -template -complex<_Tp> -sinh(const complex<_Tp>& __x) -{ - if (isinf(__x.real()) && !isfinite(__x.imag())) - return complex<_Tp>(__x.real(), _Tp(NAN)); - if (__x.real() == 0 && !isfinite(__x.imag())) - return complex<_Tp>(__x.real(), _Tp(NAN)); - if (__x.imag() == 0 && !isfinite(__x.real())) - return __x; - return complex<_Tp>(sinh(__x.real()) * cos(__x.imag()), cosh(__x.real()) * sin(__x.imag())); -} - -// cosh - -template -complex<_Tp> -cosh(const complex<_Tp>& __x) -{ - if (isinf(__x.real()) && !isfinite(__x.imag())) - return complex<_Tp>(abs(__x.real()), _Tp(NAN)); - if (__x.real() == 0 && !isfinite(__x.imag())) - return complex<_Tp>(_Tp(NAN), __x.real()); - if (__x.real() == 0 && __x.imag() == 0) - return complex<_Tp>(_Tp(1), __x.imag()); - if (__x.imag() == 0 && !isfinite(__x.real())) - return complex<_Tp>(abs(__x.real()), __x.imag()); - return complex<_Tp>(cosh(__x.real()) * cos(__x.imag()), sinh(__x.real()) * sin(__x.imag())); -} - -// tanh - -template -complex<_Tp> -tanh(const complex<_Tp>& __x) -{ - if (isinf(__x.real())) - { - if (!isfinite(__x.imag())) - return complex<_Tp>(_Tp(1), _Tp(0)); - return complex<_Tp>(_Tp(1), copysign(_Tp(0), sin(_Tp(2) * __x.imag()))); - } - if (isnan(__x.real()) && __x.imag() == 0) - return __x; - _Tp __2r(_Tp(2) * __x.real()); - _Tp __2i(_Tp(2) * __x.imag()); - _Tp __d(cosh(__2r) + cos(__2i)); - return complex<_Tp>(sinh(__2r)/__d, sin(__2i)/__d); -} - -// asin - -template -complex<_Tp> -asin(const complex<_Tp>& __x) -{ - complex<_Tp> __z = asinh(complex<_Tp>(-__x.imag(), __x.real())); - return complex<_Tp>(__z.imag(), -__z.real()); -} - -// acos - -template -complex<_Tp> -acos(const complex<_Tp>& __x) -{ - const _Tp __pi(atan2(+0., -0.)); - if (isinf(__x.real())) - { - if (isnan(__x.imag())) - return complex<_Tp>(__x.imag(), __x.real()); - if (isinf(__x.imag())) - { - if (__x.real() < _Tp(0)) - return complex<_Tp>(_Tp(0.75) * __pi, -__x.imag()); - return complex<_Tp>(_Tp(0.25) * __pi, -__x.imag()); - } - if (__x.real() < _Tp(0)) - return complex<_Tp>(__pi, signbit(__x.imag()) ? -__x.real() : __x.real()); - return complex<_Tp>(_Tp(0), signbit(__x.imag()) ? __x.real() : -__x.real()); - } - if (isnan(__x.real())) - { - if (isinf(__x.imag())) - return complex<_Tp>(__x.real(), -__x.imag()); - return complex<_Tp>(__x.real(), __x.real()); - } - if (isinf(__x.imag())) - return complex<_Tp>(__pi/_Tp(2), -__x.imag()); - if (__x.real() == 0) - return complex<_Tp>(__pi/_Tp(2), -__x.imag()); - complex<_Tp> __z = log(__x + sqrt(pow(__x, _Tp(2)) - _Tp(1))); - if (signbit(__x.imag())) - return complex<_Tp>(abs(__z.imag()), abs(__z.real())); - return complex<_Tp>(abs(__z.imag()), -abs(__z.real())); -} - -// atan - -template -complex<_Tp> -atan(const complex<_Tp>& __x) -{ - complex<_Tp> __z = atanh(complex<_Tp>(-__x.imag(), __x.real())); - return complex<_Tp>(__z.imag(), -__z.real()); -} - -// sin - -template -complex<_Tp> -sin(const complex<_Tp>& __x) -{ - complex<_Tp> __z = sinh(complex<_Tp>(-__x.imag(), __x.real())); - return complex<_Tp>(__z.imag(), -__z.real()); -} - -// cos - -template -inline _LIBCPP_INLINE_VISIBILITY -complex<_Tp> -cos(const complex<_Tp>& __x) -{ - return cosh(complex<_Tp>(-__x.imag(), __x.real())); -} - -// tan - -template -complex<_Tp> -tan(const complex<_Tp>& __x) -{ - complex<_Tp> __z = tanh(complex<_Tp>(-__x.imag(), __x.real())); - return complex<_Tp>(__z.imag(), -__z.real()); -} - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) -{ - if (__is.good()) - { - ws(__is); - if (__is.peek() == _CharT('(')) - { - __is.get(); - _Tp __r; - __is >> __r; - if (!__is.fail()) - { - ws(__is); - _CharT __c = __is.peek(); - if (__c == _CharT(',')) - { - __is.get(); - _Tp __i; - __is >> __i; - if (!__is.fail()) - { - ws(__is); - __c = __is.peek(); - if (__c == _CharT(')')) - { - __is.get(); - __x = complex<_Tp>(__r, __i); - } - else - __is.setstate(ios_base::failbit); - } - else - __is.setstate(ios_base::failbit); - } - else if (__c == _CharT(')')) - { - __is.get(); - __x = complex<_Tp>(__r, _Tp(0)); - } - else - __is.setstate(ios_base::failbit); - } - else - __is.setstate(ios_base::failbit); - } - else - { - _Tp __r; - __is >> __r; - if (!__is.fail()) - __x = complex<_Tp>(__r, _Tp(0)); - else - __is.setstate(ios_base::failbit); - } - } - else - __is.setstate(ios_base::failbit); - return __is; -} - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const complex<_Tp>& __x) -{ - basic_ostringstream<_CharT, _Traits> __s; - __s.flags(__os.flags()); - __s.imbue(__os.getloc()); - __s.precision(__os.precision()); - __s << '(' << __x.real() << ',' << __x.imag() << ')'; - return __os << __s.str(); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_COMPLEX diff --git a/libcxx/include/complex.h b/libcxx/include/complex.h deleted file mode 100644 index 7003d31a89cd..000000000000 --- a/libcxx/include/complex.h +++ /dev/null @@ -1,35 +0,0 @@ -// -*- C++ -*- -//===--------------------------- complex.h --------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_COMPLEX_H -#define _LIBCPP_COMPLEX_H - -/* - complex.h synopsis - -#include - -*/ - -#ifdef __cplusplus - -#include - -#else // __cplusplus - -#include_next - -#endif // __cplusplus - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#endif // _LIBCPP_COMPLEX_H diff --git a/libcxx/include/condition_variable b/libcxx/include/condition_variable deleted file mode 100644 index b4da556f6356..000000000000 --- a/libcxx/include/condition_variable +++ /dev/null @@ -1,256 +0,0 @@ -// -*- C++ -*- -//===---------------------- condition_variable ----------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CONDITION_VARIABLE -#define _LIBCPP_CONDITION_VARIABLE - -/* - condition_variable synopsis - -namespace std -{ - -enum class cv_status { no_timeout, timeout }; - -class condition_variable -{ -public: - condition_variable(); - ~condition_variable(); - - condition_variable(const condition_variable&) = delete; - condition_variable& operator=(const condition_variable&) = delete; - - void notify_one(); - void notify_all(); - - void wait(unique_lock& lock); - template - void wait(unique_lock& lock, Predicate pred); - - template - cv_status - wait_until(unique_lock& lock, - const chrono::time_point& abs_time); - - template - bool - wait_until(unique_lock& lock, - const chrono::time_point& abs_time, - Predicate pred); - - template - cv_status - wait_for(unique_lock& lock, - const chrono::duration& rel_time); - - template - bool - wait_for(unique_lock& lock, - const chrono::duration& rel_time, - Predicate pred); - - typedef pthread_cond_t* native_handle_type; - native_handle_type native_handle(); -}; - -void notify_all_at_thread_exit(condition_variable& cond, unique_lock lk); - -class condition_variable_any -{ -public: - condition_variable_any(); - ~condition_variable_any(); - - condition_variable_any(const condition_variable_any&) = delete; - condition_variable_any& operator=(const condition_variable_any&) = delete; - - void notify_one(); - void notify_all(); - - template - void wait(Lock& lock); - template - void wait(Lock& lock, Predicate pred); - - template - cv_status - wait_until(Lock& lock, - const chrono::time_point& abs_time); - - template - bool - wait_until(Lock& lock, - const chrono::time_point& abs_time, - Predicate pred); - - template - cv_status - wait_for(Lock& lock, - const chrono::duration& rel_time); - - template - bool - wait_for(Lock& lock, - const chrono::duration& rel_time, - Predicate pred); -}; - -} // std - -*/ - -#include <__config> -#include <__mutex_base> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -class _LIBCPP_VISIBLE condition_variable_any -{ - condition_variable __cv_; - shared_ptr __mut_; -public: - condition_variable_any(); - - void notify_one(); - void notify_all(); - - template - void wait(_Lock& __lock); - template - void wait(_Lock& __lock, _Predicate __pred); - - template - cv_status - wait_until(_Lock& __lock, - const chrono::time_point<_Clock, _Duration>& __t); - - template - bool - wait_until(_Lock& __lock, - const chrono::time_point<_Clock, _Duration>& __t, - _Predicate __pred); - - template - cv_status - wait_for(_Lock& __lock, - const chrono::duration<_Rep, _Period>& __d); - - template - bool - wait_for(_Lock& __lock, - const chrono::duration<_Rep, _Period>& __d, - _Predicate __pred); -}; - -inline _LIBCPP_INLINE_VISIBILITY -condition_variable_any::condition_variable_any() - : __mut_(make_shared()) {} - -inline _LIBCPP_INLINE_VISIBILITY -void -condition_variable_any::notify_one() -{ - {lock_guard _(*__mut_);} - __cv_.notify_one(); -} - -inline _LIBCPP_INLINE_VISIBILITY -void -condition_variable_any::notify_all() -{ - {lock_guard _(*__mut_);} - __cv_.notify_all(); -} - -struct __lock_external -{ - template - void operator()(_Lock* __m) {__m->lock();} -}; - -template -void -condition_variable_any::wait(_Lock& __lock) -{ - shared_ptr __mut = __mut_; - unique_lock __lk(*__mut); - __lock.unlock(); - unique_ptr<_Lock, __lock_external> __(&__lock); - lock_guard > _(__lk, adopt_lock); - __cv_.wait(__lk); -} // __mut_.unlock(), __lock.lock() - -template -inline _LIBCPP_INLINE_VISIBILITY -void -condition_variable_any::wait(_Lock& __lock, _Predicate __pred) -{ - while (!__pred()) - wait(__lock); -} - -template -cv_status -condition_variable_any::wait_until(_Lock& __lock, - const chrono::time_point<_Clock, _Duration>& __t) -{ - shared_ptr __mut = __mut_; - unique_lock __lk(*__mut); - __lock.unlock(); - unique_ptr<_Lock, __lock_external> __(&__lock); - lock_guard > _(__lk, adopt_lock); - return __cv_.wait_until(__lk, __t); -} // __mut_.unlock(), __lock.lock() - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -condition_variable_any::wait_until(_Lock& __lock, - const chrono::time_point<_Clock, _Duration>& __t, - _Predicate __pred) -{ - while (!__pred()) - if (wait_until(__lock, __t) == cv_status::timeout) - return __pred(); - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -cv_status -condition_variable_any::wait_for(_Lock& __lock, - const chrono::duration<_Rep, _Period>& __d) -{ - return wait_until(__lock, chrono::steady_clock::now() + __d); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -condition_variable_any::wait_for(_Lock& __lock, - const chrono::duration<_Rep, _Period>& __d, - _Predicate __pred) -{ - return wait_until(__lock, chrono::steady_clock::now() + __d, - _VSTD::move(__pred)); -} - -_LIBCPP_VISIBLE -void notify_all_at_thread_exit(condition_variable& cond, unique_lock lk); - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CONDITION_VARIABLE diff --git a/libcxx/include/csetjmp b/libcxx/include/csetjmp deleted file mode 100644 index d0b2c078967d..000000000000 --- a/libcxx/include/csetjmp +++ /dev/null @@ -1,52 +0,0 @@ -// -*- C++ -*- -//===--------------------------- csetjmp ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSETJMP -#define _LIBCPP_CSETJMP - -/* - csetjmp synopsis - -Macros: - - setjmp - -namespace std -{ - -Types: - - jmp_buf - -void longjmp(jmp_buf env, int val); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#ifndef setjmp -#define setjmp(env) setjmp(env) -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::jmp_buf; -using ::longjmp; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSETJMP diff --git a/libcxx/include/csignal b/libcxx/include/csignal deleted file mode 100644 index 97282661872a..000000000000 --- a/libcxx/include/csignal +++ /dev/null @@ -1,58 +0,0 @@ -// -*- C++ -*- -//===--------------------------- csignal ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSIGNAL -#define _LIBCPP_CSIGNAL - -/* - csignal synopsis - -Macros: - - SIG_DFL - SIG_ERR - SIG_IGN - SIGABRT - SIGFPE - SIGILL - SIGINT - SIGSEGV - SIGTERM - -namespace std -{ - -Types: - - sig_atomic_t - -void (*signal(int sig, void (*func)(int)))(int); -int raise(int sig); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::sig_atomic_t; -using ::signal; -using ::raise; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSIGNAL diff --git a/libcxx/include/cstdarg b/libcxx/include/cstdarg deleted file mode 100644 index c8b6999242f7..000000000000 --- a/libcxx/include/cstdarg +++ /dev/null @@ -1,48 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstdarg ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDARG -#define _LIBCPP_CSTDARG - -/* - cstdarg synopsis - -Macros: - - type va_arg(va_list ap, type); - void va_copy(va_list dest, va_list src); // C99 - void va_end(va_list ap); - void va_start(va_list ap, parmN); - -namespace std -{ - -Types: - - va_list - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::va_list; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSTDARG diff --git a/libcxx/include/cstdbool b/libcxx/include/cstdbool deleted file mode 100644 index 2c764a61f211..000000000000 --- a/libcxx/include/cstdbool +++ /dev/null @@ -1,32 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstdbool ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDBOOL -#define _LIBCPP_CSTDBOOL - -/* - cstdbool synopsis - -Macros: - - __bool_true_false_are_defined - -*/ - -#include <__config> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#undef __bool_true_false_are_defined -#define __bool_true_false_are_defined 1 - -#endif // _LIBCPP_CSTDBOOL diff --git a/libcxx/include/cstddef b/libcxx/include/cstddef deleted file mode 100644 index 4a6b16e186b8..000000000000 --- a/libcxx/include/cstddef +++ /dev/null @@ -1,103 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstddef ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDDEF -#define _LIBCPP_CSTDDEF - -/* - cstddef synopsis - -Macros: - - offsetof(type,member-designator) - NULL - -namespace std -{ - -Types: - - ptrdiff_t - size_t - max_align_t - nullptr_t - -} // std - -*/ - -#include <__config> - -#ifdef __GLIBC__ -#define __need_NULL -#define __need_ptrdiff_t -#define __need_size_t -#endif // __GLIBC__ - -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::ptrdiff_t; -using ::size_t; - -typedef long double max_align_t; - -#ifdef _LIBCPP_HAS_NO_NULLPTR - -struct _LIBCPP_VISIBLE nullptr_t -{ - void* _; - - struct __nat {int __for_bool_;}; - - _LIBCPP_ALWAYS_INLINE nullptr_t() {} - _LIBCPP_ALWAYS_INLINE nullptr_t(int __nat::*) {} - - _LIBCPP_ALWAYS_INLINE operator int __nat::*() const {return 0;} - - template - _LIBCPP_ALWAYS_INLINE - operator _Tp* () const {return 0;} - - template - _LIBCPP_ALWAYS_INLINE - operator _Tp _Up::* () const {return 0;} - - friend _LIBCPP_ALWAYS_INLINE bool operator==(nullptr_t, nullptr_t) {return true;} - friend _LIBCPP_ALWAYS_INLINE bool operator!=(nullptr_t, nullptr_t) {return false;} - friend _LIBCPP_ALWAYS_INLINE bool operator<(nullptr_t, nullptr_t) {return false;} - friend _LIBCPP_ALWAYS_INLINE bool operator<=(nullptr_t, nullptr_t) {return true;} - friend _LIBCPP_ALWAYS_INLINE bool operator>(nullptr_t, nullptr_t) {return false;} - friend _LIBCPP_ALWAYS_INLINE bool operator>=(nullptr_t, nullptr_t) {return true;} -}; - -inline _LIBCPP_ALWAYS_INLINE nullptr_t __get_nullptr_t() {return nullptr_t(0);} - -#define nullptr _VSTD::__get_nullptr_t() - -#endif // _LIBCPP_HAS_NO_NULLPTR - -_LIBCPP_END_NAMESPACE_STD - -#ifndef _LIBCPP_HAS_NO_NULLPTR - -namespace std -{ - typedef decltype(nullptr) nullptr_t; -} - -#endif // _LIBCPP_HAS_NO_NULLPTR - -#endif // _LIBCPP_CSTDDEF diff --git a/libcxx/include/cstdint b/libcxx/include/cstdint deleted file mode 100644 index 7a187d3ebf28..000000000000 --- a/libcxx/include/cstdint +++ /dev/null @@ -1,191 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstdint ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDINT -#define _LIBCPP_CSTDINT - -/* - cstdint synopsis - -Macros: - - INT8_MIN - INT16_MIN - INT32_MIN - INT64_MIN - - INT8_MAX - INT16_MAX - INT32_MAX - INT64_MAX - - UINT8_MAX - UINT16_MAX - UINT32_MAX - UINT64_MAX - - INT_LEAST8_MIN - INT_LEAST16_MIN - INT_LEAST32_MIN - INT_LEAST64_MIN - - INT_LEAST8_MAX - INT_LEAST16_MAX - INT_LEAST32_MAX - INT_LEAST64_MAX - - UINT_LEAST8_MAX - UINT_LEAST16_MAX - UINT_LEAST32_MAX - UINT_LEAST64_MAX - - INT_FAST8_MIN - INT_FAST16_MIN - INT_FAST32_MIN - INT_FAST64_MIN - - INT_FAST8_MAX - INT_FAST16_MAX - INT_FAST32_MAX - INT_FAST64_MAX - - UINT_FAST8_MAX - UINT_FAST16_MAX - UINT_FAST32_MAX - UINT_FAST64_MAX - - INTPTR_MIN - INTPTR_MAX - UINTPTR_MAX - - INTMAX_MIN - INTMAX_MAX - - UINTMAX_MAX - - PTRDIFF_MIN - PTRDIFF_MAX - - SIG_ATOMIC_MIN - SIG_ATOMIC_MAX - - SIZE_MAX - - WCHAR_MIN - WCHAR_MAX - - WINT_MIN - WINT_MAX - - INT8_C(value) - INT16_C(value) - INT32_C(value) - INT64_C(value) - - UINT8_C(value) - UINT16_C(value) - UINT32_C(value) - UINT64_C(value) - - INTMAX_C(value) - UINTMAX_C(value) - -namespace std -{ - -Types: - - int8_t - int16_t - int32_t - int64_t - - uint8_t - uint16_t - uint32_t - uint64_t - - int_least8_t - int_least16_t - int_least32_t - int_least64_t - - uint_least8_t - uint_least16_t - uint_least32_t - uint_least64_t - - int_fast8_t - int_fast16_t - int_fast32_t - int_fast64_t - - uint_fast8_t - uint_fast16_t - uint_fast32_t - uint_fast64_t - - intptr_t - uintptr_t - - intmax_t - uintmax_t - -} // std -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using::int8_t; -using::int16_t; -using::int32_t; -using::int64_t; - -using::uint8_t; -using::uint16_t; -using::uint32_t; -using::uint64_t; - -using::int_least8_t; -using::int_least16_t; -using::int_least32_t; -using::int_least64_t; - -using::uint_least8_t; -using::uint_least16_t; -using::uint_least32_t; -using::uint_least64_t; - -using::int_fast8_t; -using::int_fast16_t; -using::int_fast32_t; -using::int_fast64_t; - -using::uint_fast8_t; -using::uint_fast16_t; -using::uint_fast32_t; -using::uint_fast64_t; - -using::intptr_t; -using::uintptr_t; - -using::intmax_t; -using::uintmax_t; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSTDINT diff --git a/libcxx/include/cstdio b/libcxx/include/cstdio deleted file mode 100644 index 2a6ec762deae..000000000000 --- a/libcxx/include/cstdio +++ /dev/null @@ -1,163 +0,0 @@ -// -*- C++ -*- -//===---------------------------- cstdio ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDIO -#define _LIBCPP_CSTDIO - -/* - cstdio synopsis - -Macros: - - BUFSIZ - EOF - FILENAME_MAX - FOPEN_MAX - L_tmpnam - NULL - SEEK_CUR - SEEK_END - SEEK_SET - TMP_MAX - _IOFBF - _IOLBF - _IONBF - stderr - stdin - stdout - -namespace std -{ - -Types: - -FILE -fpos_t -size_t - -int remove(const char* filename); -int rename(const char* old, const char* new); -FILE* tmpfile(void); -char* tmpnam(char* s); -int fclose(FILE* stream); -int fflush(FILE* stream); -FILE* fopen(const char* restrict filename, const char* restrict mode); -FILE* freopen(const char* restrict filename, const char * restrict mode, - FILE * restrict stream); -void setbuf(FILE* restrict stream, char* restrict buf); -int setvbuf(FILE* restrict stream, char* restrict buf, int mode, size_t size); -int fprintf(FILE* restrict stream, const char* restrict format, ...); -int fscanf(FILE* restrict stream, const char * restrict format, ...); -int printf(const char* restrict format, ...); -int scanf(const char* restrict format, ...); -int snprintf(char* restrict s, size_t n, const char* restrict format, ...); // C99 -int sprintf(char* restrict s, const char* restrict format, ...); -int sscanf(const char* restrict s, const char* restrict format, ...); -int vfprintf(FILE* restrict stream, const char* restrict format, va_list arg); -int vfscanf(FILE* restrict stream, const char* restrict format, va_list arg); // C99 -int vprintf(const char* restrict format, va_list arg); -int vscanf(const char* restrict format, va_list arg); // C99 -int vsnprintf(char* restrict s, size_t n, const char* restrict format, // C99 - va_list arg); -int vsprintf(char* restrict s, const char* restrict format, va_list arg); -int vsscanf(const char* restrict s, const char* restrict format, va_list arg); // C99 -int fgetc(FILE* stream); -char* fgets(char* restrict s, int n, FILE* restrict stream); -int fputc(int c, FILE* stream); -int fputs(const char* restrict s, FILE* restrict stream); -int getc(FILE* stream); -int getchar(void); -char* gets(char* s); -int putc(int c, FILE* stream); -int putchar(int c); -int puts(const char* s); -int ungetc(int c, FILE* stream); -size_t fread(void* restrict ptr, size_t size, size_t nmemb, - FILE* restrict stream); -size_t fwrite(const void* restrict ptr, size_t size, size_t nmemb, - FILE* restrict stream); -int fgetpos(FILE* restrict stream, fpos_t* restrict pos); -int fseek(FILE* stream, long offset, int whence); -int fsetpos(FILE*stream, const fpos_t* pos); -long ftell(FILE* stream); -void rewind(FILE* stream); -void clearerr(FILE* stream); -int feof(FILE* stream); -int ferror(FILE* stream); -void perror(const char* s); - -} // std -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::FILE; -using ::fpos_t; -using ::size_t; - -using ::remove; -using ::rename; -using ::tmpfile; -using ::tmpnam; -using ::fclose; -using ::fflush; -using ::fopen; -using ::freopen; -using ::setbuf; -using ::setvbuf; -using ::fprintf; -using ::fscanf; -using ::printf; -using ::scanf; -using ::snprintf; -using ::sprintf; -using ::sscanf; -#ifndef _MSC_VER -using ::vfprintf; -using ::vfscanf; -using ::vscanf; -using ::vsscanf; -#endif // _MSC_VER -using ::vprintf; -using ::vsnprintf; -using ::vsprintf; -using ::fgetc; -using ::fgets; -using ::fputc; -using ::fputs; -using ::getc; -using ::getchar; -using ::gets; -using ::putc; -using ::putchar; -using ::puts; -using ::ungetc; -using ::fread; -using ::fwrite; -using ::fgetpos; -using ::fseek; -using ::fsetpos; -using ::ftell; -using ::rewind; -using ::clearerr; -using ::feof; -using ::ferror; -using ::perror; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSTDIO diff --git a/libcxx/include/cstdlib b/libcxx/include/cstdlib deleted file mode 100644 index a5c78e98274f..000000000000 --- a/libcxx/include/cstdlib +++ /dev/null @@ -1,150 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstdlib ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTDLIB -#define _LIBCPP_CSTDLIB - -/* - cstdlib synopsis - -Macros: - - EXIT_FAILURE - EXIT_SUCCESS - MB_CUR_MAX - NULL - RAND_MAX - -namespace std -{ - -Types: - - size_t - div_t - ldiv_t - lldiv_t // C99 - -double atof (const char* nptr); -int atoi (const char* nptr); -long atol (const char* nptr); -long long atoll(const char* nptr); // C99 -double strtod (const char* restrict nptr, char** restrict endptr); -float strtof (const char* restrict nptr, char** restrict endptr); // C99 -long double strtold (const char* restrict nptr, char** restrict endptr); // C99 -long strtol (const char* restrict nptr, char** restrict endptr, int base); -long long strtoll (const char* restrict nptr, char** restrict endptr, int base); // C99 -unsigned long strtoul (const char* restrict nptr, char** restrict endptr, int base); -unsigned long long strtoull(const char* restrict nptr, char** restrict endptr, int base); // C99 -int rand(void); -void srand(unsigned int seed); -void* calloc(size_t nmemb, size_t size); -void free(void* ptr); -void* malloc(size_t size); -void* realloc(void* ptr, size_t size); -void abort(void); -int atexit(void (*func)(void)); -void exit(int status); -void _Exit(int status); -char* getenv(const char* name); -int system(const char* string); -void* bsearch(const void* key, const void* base, size_t nmemb, size_t size, - int (*compar)(const void *, const void *)); -void qsort(void* base, size_t nmemb, size_t size, - int (*compar)(const void *, const void *)); -int abs( int j); -long abs( long j); -long long abs(long long j); // C++0X -long labs( long j); -long long llabs(long long j); // C99 -div_t div( int numer, int denom); -ldiv_t div( long numer, long denom); -lldiv_t div(long long numer, long long denom); // C++0X -ldiv_t ldiv( long numer, long denom); -lldiv_t lldiv(long long numer, long long denom); // C99 -int mblen(const char* s, size_t n); -int mbtowc(wchar_t* restrict pwc, const char* restrict s, size_t n); -int wctomb(char* s, wchar_t wchar); -size_t mbstowcs(wchar_t* restrict pwcs, const char* restrict s, size_t n); -size_t wcstombs(char* restrict s, const wchar_t* restrict pwcs, size_t n); - -} // std - -*/ - -#include <__config> -#include -#ifdef _MSC_VER -#include "support/win32/locale_win32.h" -#endif // _MSC_VER - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::size_t; -using ::div_t; -using ::ldiv_t; -using ::lldiv_t; -using ::atof; -using ::atoi; -using ::atol; -using ::atoll; -using ::strtod; -using ::strtof; -using ::strtold; -using ::strtol; -using ::strtoll; -using ::strtoul; -using ::strtoull; -using ::rand; -using ::srand; -using ::calloc; -using ::free; -using ::malloc; -using ::realloc; -using ::abort; -using ::atexit; -using ::exit; -using ::_Exit; -using ::getenv; -using ::system; -using ::bsearch; -using ::qsort; -using ::abs; -using ::labs; -using ::llabs; -using ::div; -using ::ldiv; -using ::lldiv; -using ::mblen; -using ::mbtowc; -using ::wctomb; -using ::mbstowcs; -using ::wcstombs; -#ifdef _LIBCPP_HAS_QUICK_EXIT -using ::at_quick_exit; -using ::quick_exit; -#endif - -// MSVC already has the correct prototype in #ifdef __cplusplus -#if !defined(_MSC_VER) && !defined(__sun__) -inline _LIBCPP_INLINE_VISIBILITY long abs( long __x) {return labs(__x);} -inline _LIBCPP_INLINE_VISIBILITY long long abs(long long __x) {return llabs(__x);} - -inline _LIBCPP_INLINE_VISIBILITY ldiv_t div( long __x, long __y) {return ldiv(__x, __y);} -inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x, long long __y) {return lldiv(__x, __y);} -#endif // _MSC_VER - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSTDLIB diff --git a/libcxx/include/cstring b/libcxx/include/cstring deleted file mode 100644 index 13bb11892dc3..000000000000 --- a/libcxx/include/cstring +++ /dev/null @@ -1,112 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cstring ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CSTRING -#define _LIBCPP_CSTRING - -/* - cstring synopsis - -Macros: - - NULL - -namespace std -{ - -Types: - - size_t - -void* memcpy(void* restrict s1, const void* restrict s2, size_t n); -void* memmove(void* s1, const void* s2, size_t n); -char* strcpy (char* restrict s1, const char* restrict s2); -char* strncpy(char* restrict s1, const char* restrict s2, size_t n); -char* strcat (char* restrict s1, const char* restrict s2); -char* strncat(char* restrict s1, const char* restrict s2, size_t n); -int memcmp(const void* s1, const void* s2, size_t n); -int strcmp (const char* s1, const char* s2); -int strncmp(const char* s1, const char* s2, size_t n); -int strcoll(const char* s1, const char* s2); -size_t strxfrm(char* restrict s1, const char* restrict s2, size_t n); -const void* memchr(const void* s, int c, size_t n); - void* memchr( void* s, int c, size_t n); -const char* strchr(const char* s, int c); - char* strchr( char* s, int c); -size_t strcspn(const char* s1, const char* s2); -const char* strpbrk(const char* s1, const char* s2); - char* strpbrk( char* s1, const char* s2); -const char* strrchr(const char* s, int c); - char* strrchr( char* s, int c); -size_t strspn(const char* s1, const char* s2); -const char* strstr(const char* s1, const char* s2); - char* strstr( char* s1, const char* s2); -char* strtok(char* restrict s1, const char* restrict s2); -void* memset(void* s, int c, size_t n); -char* strerror(int errnum); -size_t strlen(const char* s); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::size_t; -using ::memcpy; -using ::memmove; -using ::strcpy; -using ::strncpy; -using ::strcat; -using ::strncat; -using ::memcmp; -using ::strcmp; -using ::strncmp; -using ::strcoll; -using ::strxfrm; - -using ::memchr; - -using ::strchr; - -using ::strcspn; - -using ::strpbrk; - -using ::strrchr; - -using ::strspn; - -using ::strstr; - -// MSVC, GNU libc and its derivates already have the correct prototype in #ifdef __cplusplus -#if !defined(__GLIBC__) && !defined(_MSC_VER) && !defined(__sun__) -inline _LIBCPP_INLINE_VISIBILITY char* strchr( char* __s, int __c) {return ::strchr(__s, __c);} -inline _LIBCPP_INLINE_VISIBILITY char* strpbrk( char* __s1, const char* __s2) {return ::strpbrk(__s1, __s2);} -inline _LIBCPP_INLINE_VISIBILITY char* strrchr( char* __s, int __c) {return ::strrchr(__s, __c);} -inline _LIBCPP_INLINE_VISIBILITY void* memchr( void* __s, int __c, size_t __n) {return ::memchr(__s, __c, __n);} -inline _LIBCPP_INLINE_VISIBILITY char* strstr( char* __s1, const char* __s2) {return ::strstr(__s1, __s2);} -#endif - -using ::strtok; -using ::memset; -using ::strerror; -using ::strlen; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CSTRING diff --git a/libcxx/include/ctgmath b/libcxx/include/ctgmath deleted file mode 100644 index 535eb7dccd15..000000000000 --- a/libcxx/include/ctgmath +++ /dev/null @@ -1,29 +0,0 @@ -// -*- C++ -*- -//===-------------------------- ctgmath -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CTGMATH -#define _LIBCPP_CTGMATH - -/* - ctgmath synopsis - -#include -#include - -*/ - -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#endif // _LIBCPP_CTGMATH diff --git a/libcxx/include/ctime b/libcxx/include/ctime deleted file mode 100644 index fc4eb26f5430..000000000000 --- a/libcxx/include/ctime +++ /dev/null @@ -1,72 +0,0 @@ -// -*- C++ -*- -//===---------------------------- ctime -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CTIME -#define _LIBCPP_CTIME - -/* - ctime synopsis - -Macros: - - NULL - CLOCKS_PER_SEC - -namespace std -{ - -Types: - - clock_t - size_t - time_t - tm - -clock_t clock(); -double difftime(time_t time1, time_t time0); -time_t mktime(tm* timeptr); -time_t time(time_t* timer); -char* asctime(const tm* timeptr); -char* ctime(const time_t* timer); -tm* gmtime(const time_t* timer); -tm* localtime(const time_t* timer); -size_t strftime(char* restrict s, size_t maxsize, const char* restrict format, - const tm* restrict timeptr); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::clock_t; -using ::size_t; -using ::time_t; -using ::tm; -using ::clock; -using ::difftime; -using ::mktime; -using ::time; -using ::asctime; -using ::ctime; -using ::gmtime; -using ::localtime; -using ::strftime; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CTIME diff --git a/libcxx/include/cwchar b/libcxx/include/cwchar deleted file mode 100644 index 8e788fc764e1..000000000000 --- a/libcxx/include/cwchar +++ /dev/null @@ -1,204 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cwchar -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CWCHAR -#define _LIBCPP_CWCHAR - -/* - cwchar synopsis - -Macros: - - NULL - WCHAR_MAX - WCHAR_MIN - WEOF - -namespace std -{ - -Types: - - mbstate_t - size_t - tm - wint_t - -int fwprintf(FILE* restrict stream, const wchar_t* restrict format, ...); -int fwscanf(FILE* restrict stream, const wchar_t* restrict format, ...); -int swprintf(wchar_t* restrict s, size_t n, const wchar_t* restrict format, ...); -int swscanf(const wchar_t* restrict s, const wchar_t* restrict format, ...); -int vfwprintf(FILE* restrict stream, const wchar_t* restrict format, va_list arg); -int vfwscanf(FILE* restrict stream, const wchar_t* restrict format, va_list arg); // C99 -int vswprintf(wchar_t* restrict s, size_t n, const wchar_t* restrict format, va_list arg); -int vswscanf(const wchar_t* restrict s, const wchar_t* restrict format, va_list arg); // C99 -int vwprintf(const wchar_t* restrict format, va_list arg); -int vwscanf(const wchar_t* restrict format, va_list arg); // C99 -int wprintf(const wchar_t* restrict format, ...); -int wscanf(const wchar_t* restrict format, ...); -wint_t fgetwc(FILE* stream); -wchar_t* fgetws(wchar_t* restrict s, int n, FILE* restrict stream); -wint_t fputwc(wchar_t c, FILE* stream); -int fputws(const wchar_t* restrict s, FILE* restrict stream); -int fwide(FILE* stream, int mode); -wint_t getwc(FILE* stream); -wint_t getwchar(); -wint_t putwc(wchar_t c, FILE* stream); -wint_t putwchar(wchar_t c); -wint_t ungetwc(wint_t c, FILE* stream); -double wcstod(const wchar_t* restrict nptr, wchar_t** restrict endptr); -float wcstof(const wchar_t* restrict nptr, wchar_t** restrict endptr); // C99 -long double wcstold(const wchar_t* restrict nptr, wchar_t** restrict endptr); // C99 -long wcstol(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); -long long wcstoll(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); // C99 -unsigned long wcstoul(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); -unsigned long long wcstoull(const wchar_t* restrict nptr, wchar_t** restrict endptr, int base); // C99 -wchar_t* wcscpy(wchar_t* restrict s1, const wchar_t* restrict s2); -wchar_t* wcsncpy(wchar_t* restrict s1, const wchar_t* restrict s2, size_t n); -wchar_t* wcscat(wchar_t* restrict s1, const wchar_t* restrict s2); -wchar_t* wcsncat(wchar_t* restrict s1, const wchar_t* restrict s2, size_t n); -int wcscmp(const wchar_t* s1, const wchar_t* s2); -int wcscoll(const wchar_t* s1, const wchar_t* s2); -int wcsncmp(const wchar_t* s1, const wchar_t* s2, size_t n); -size_t wcsxfrm(wchar_t* restrict s1, const wchar_t* restrict s2, size_t n); -const wchar_t* wcschr(const wchar_t* s, wchar_t c); - wchar_t* wcschr( wchar_t* s, wchar_t c); -size_t wcscspn(const wchar_t* s1, const wchar_t* s2); -size_t wcslen(const wchar_t* s); -const wchar_t* wcspbrk(const wchar_t* s1, const wchar_t* s2); - wchar_t* wcspbrk( wchar_t* s1, const wchar_t* s2); -const wchar_t* wcsrchr(const wchar_t* s, wchar_t c); - wchar_t* wcsrchr( wchar_t* s, wchar_t c); -size_t wcsspn(const wchar_t* s1, const wchar_t* s2); -const wchar_t* wcsstr(const wchar_t* s1, const wchar_t* s2); - wchar_t* wcsstr( wchar_t* s1, const wchar_t* s2); -wchar_t* wcstok(wchar_t* restrict s1, const wchar_t* restrict s2, wchar_t** restrict ptr); -const wchar_t* wmemchr(const wchar_t* s, wchar_t c, size_t n); - wchar_t* wmemchr( wchar_t* s, wchar_t c, size_t n); -int wmemcmp(wchar_t* restrict s1, const wchar_t* restrict s2, size_t n); -wchar_t* wmemcpy(wchar_t* restrict s1, const wchar_t* restrict s2, size_t n); -wchar_t* wmemmove(wchar_t* s1, const wchar_t* s2, size_t n); -wchar_t* wmemset(wchar_t* s, wchar_t c, size_t n); -size_t wcsftime(wchar_t* restrict s, size_t maxsize, const wchar_t* restrict format, - const tm* restrict timeptr); -wint_t btowc(int c); -int wctob(wint_t c); -int mbsinit(const mbstate_t* ps); -size_t mbrlen(const char* restrict s, size_t n, mbstate_t* restrict ps); -size_t mbrtowc(wchar_t* restrict pwc, const char* restrict s, size_t n, mbstate_t* restrict ps); -size_t wcrtomb(char* restrict s, wchar_t wc, mbstate_t* restrict ps); -size_t mbsrtowcs(wchar_t* restrict dst, const char** restrict src, size_t len, - mbstate_t* restrict ps); -size_t wcsrtombs(char* restrict dst, const wchar_t** restrict src, size_t len, - mbstate_t* restrict ps); - -} // std - -*/ - -#include <__config> -#include -#include -#if _WIN32 -#include // pull in *swprintf defines -#endif // _WIN32 - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::mbstate_t; -using ::size_t; -using ::tm; -using ::wint_t; -using ::FILE; -using ::fwprintf; -using ::fwscanf; -using ::swprintf; -using ::vfwprintf; -using ::vswprintf; -using ::vwprintf; -#ifndef _MSC_VER -using ::swscanf; -using ::vfwscanf; -using ::vswscanf; -using ::vwscanf; -#endif // _MSC_VER -using ::wprintf; -using ::wscanf; -using ::fgetwc; -using ::fgetws; -using ::fputwc; -using ::fputws; -using ::fwide; -using ::getwc; -using ::getwchar; -using ::putwc; -using ::putwchar; -using ::ungetwc; -using ::wcstod; -#ifndef _MSC_VER -using ::wcstof; -using ::wcstold; -#endif // _MSC_VER -using ::wcstol; -using ::wcstoll; -using ::wcstoul; -using ::wcstoull; -using ::wcscpy; -using ::wcsncpy; -using ::wcscat; -using ::wcsncat; -using ::wcscmp; -using ::wcscoll; -using ::wcsncmp; -using ::wcsxfrm; - -inline _LIBCPP_INLINE_VISIBILITY const wchar_t* wcschr(const wchar_t* __s, wchar_t __c) {return ::wcschr(__s, __c);} -inline _LIBCPP_INLINE_VISIBILITY wchar_t* wcschr( wchar_t* __s, wchar_t __c) {return ::wcschr(__s, __c);} - -using ::wcscspn; -using ::wcslen; - -inline _LIBCPP_INLINE_VISIBILITY const wchar_t* wcspbrk(const wchar_t* __s1, const wchar_t* __s2) {return ::wcspbrk(__s1, __s2);} -inline _LIBCPP_INLINE_VISIBILITY wchar_t* wcspbrk( wchar_t* __s1, const wchar_t* __s2) {return ::wcspbrk(__s1, __s2);} - -inline _LIBCPP_INLINE_VISIBILITY const wchar_t* wcsrchr(const wchar_t* __s, wchar_t __c) {return ::wcsrchr(__s, __c);} -inline _LIBCPP_INLINE_VISIBILITY wchar_t* wcsrchr( wchar_t* __s, wchar_t __c) {return ::wcsrchr(__s, __c);} - -using ::wcsspn; - -inline _LIBCPP_INLINE_VISIBILITY const wchar_t* wcsstr(const wchar_t* __s1, const wchar_t* __s2) {return ::wcsstr(__s1, __s2);} -inline _LIBCPP_INLINE_VISIBILITY wchar_t* wcsstr( wchar_t* __s1, const wchar_t* __s2) {return ::wcsstr(__s1, __s2);} - -using ::wcstok; - -inline _LIBCPP_INLINE_VISIBILITY const wchar_t* wmemchr(const wchar_t* __s, wchar_t __c, size_t __n) {return ::wmemchr(__s, __c, __n);} -inline _LIBCPP_INLINE_VISIBILITY wchar_t* wmemchr( wchar_t* __s, wchar_t __c, size_t __n) {return ::wmemchr(__s, __c, __n);} - -using ::wmemcmp; -using ::wmemcpy; -using ::wmemmove; -using ::wmemset; -using ::wcsftime; -using ::btowc; -using ::wctob; -using ::mbsinit; -using ::mbrlen; -using ::mbrtowc; -using ::wcrtomb; -using ::mbsrtowcs; -using ::wcsrtombs; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CWCHAR diff --git a/libcxx/include/cwctype b/libcxx/include/cwctype deleted file mode 100644 index 4f89b52db27c..000000000000 --- a/libcxx/include/cwctype +++ /dev/null @@ -1,213 +0,0 @@ -// -*- C++ -*- -//===--------------------------- cwctype ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_CWCTYPE -#define _LIBCPP_CWCTYPE - -/* - cwctype synopsis - -Macros: - - WEOF - -namespace std -{ - -Types: - - wint_t - wctrans_t - wctype_t - -int iswalnum(wint_t wc); -int iswalpha(wint_t wc); -int iswblank(wint_t wc); // C99 -int iswcntrl(wint_t wc); -int iswdigit(wint_t wc); -int iswgraph(wint_t wc); -int iswlower(wint_t wc); -int iswprint(wint_t wc); -int iswpunct(wint_t wc); -int iswspace(wint_t wc); -int iswupper(wint_t wc); -int iswxdigit(wint_t wc); -int iswctype(wint_t wc, wctype_t desc); -wctype_t wctype(const char* property); -wint_t towlower(wint_t wc); -wint_t towupper(wint_t wc); -wint_t towctrans(wint_t wc, wctrans_t desc); -wctrans_t wctrans(const char* property); - -} // std - -*/ - -#include <__config> -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -using ::wint_t; -using ::wctrans_t; -using ::wctype_t; - -#ifdef iswalnum -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswalnum(wint_t __wc) {return iswalnum(__wc);} -#undef iswalnum -inline _LIBCPP_INLINE_VISIBILITY int iswalnum(wint_t __wc) {return __libcpp_iswalnum(__wc);} -#else // iswalnum -using ::iswalnum; -#endif - -#ifdef iswalpha -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswalpha(wint_t __wc) {return iswalpha(__wc);} -#undef iswalpha -inline _LIBCPP_INLINE_VISIBILITY int iswalpha(wint_t __wc) {return __libcpp_iswalpha(__wc);} -#else // iswalpha -using ::iswalpha; -#endif - -#ifdef iswblank -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswblank(wint_t __wc) {return iswblank(__wc);} -#undef iswblank -inline _LIBCPP_INLINE_VISIBILITY int iswblank(wint_t __wc) {return __libcpp_iswblank(__wc);} -#else // iswblank -using ::iswblank; -#endif - -#ifdef iswcntrl -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswcntrl(wint_t __wc) {return iswcntrl(__wc);} -#undef iswcntrl -inline _LIBCPP_INLINE_VISIBILITY int iswcntrl(wint_t __wc) {return __libcpp_iswcntrl(__wc);} -#else // iswcntrl -using ::iswcntrl; -#endif - -#ifdef iswdigit -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswdigit(wint_t __wc) {return iswdigit(__wc);} -#undef iswdigit -inline _LIBCPP_INLINE_VISIBILITY int iswdigit(wint_t __wc) {return __libcpp_iswdigit(__wc);} -#else // iswdigit -using ::iswdigit; -#endif - -#ifdef iswgraph -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswgraph(wint_t __wc) {return iswgraph(__wc);} -#undef iswgraph -inline _LIBCPP_INLINE_VISIBILITY int iswgraph(wint_t __wc) {return __libcpp_iswgraph(__wc);} -#else // iswgraph -using ::iswgraph; -#endif - -#ifdef iswlower -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswlower(wint_t __wc) {return iswlower(__wc);} -#undef iswlower -inline _LIBCPP_INLINE_VISIBILITY int iswlower(wint_t __wc) {return __libcpp_iswlower(__wc);} -#else // iswlower -using ::iswlower; -#endif - -#ifdef iswprint -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswprint(wint_t __wc) {return iswprint(__wc);} -#undef iswprint -inline _LIBCPP_INLINE_VISIBILITY int iswprint(wint_t __wc) {return __libcpp_iswprint(__wc);} -#else // iswprint -using ::iswprint; -#endif - -#ifdef iswpunct -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswpunct(wint_t __wc) {return iswpunct(__wc);} -#undef iswpunct -inline _LIBCPP_INLINE_VISIBILITY int iswpunct(wint_t __wc) {return __libcpp_iswpunct(__wc);} -#else // iswpunct -using ::iswpunct; -#endif - -#ifdef iswspace -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswspace(wint_t __wc) {return iswspace(__wc);} -#undef iswspace -inline _LIBCPP_INLINE_VISIBILITY int iswspace(wint_t __wc) {return __libcpp_iswspace(__wc);} -#else // iswspace -using ::iswspace; -#endif - -#ifdef iswupper -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswupper(wint_t __wc) {return iswupper(__wc);} -#undef iswupper -inline _LIBCPP_INLINE_VISIBILITY int iswupper(wint_t __wc) {return __libcpp_iswupper(__wc);} -#else // iswupper -using ::iswupper; -#endif - -#ifdef iswxdigit -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswxdigit(wint_t __wc) {return iswxdigit(__wc);} -#undef iswxdigit -inline _LIBCPP_INLINE_VISIBILITY int iswxdigit(wint_t __wc) {return __libcpp_iswxdigit(__wc);} -#else // iswxdigit -using ::iswxdigit; -#endif - -#ifdef iswctype -inline _LIBCPP_INLINE_VISIBILITY int __libcpp_iswctype(wint_t __w, wctype_t __d) {return iswctype(__w, __d);} -#undef iswctype -inline _LIBCPP_INLINE_VISIBILITY int iswctype(wint_t __w, wctype_t __d) {return __libcpp_iswctype(__w, __d);} -#else // iswctype -using ::iswctype; -#endif - -#ifdef wctype -inline _LIBCPP_INLINE_VISIBILITY wctype_t __libcpp_wctype(const char* __p) {return wctype(__p);} -#undef wctype -inline _LIBCPP_INLINE_VISIBILITY wctype_t wctype(const char* __p) {return __libcpp_wctype(__p);} -#else // wctype -using ::wctype; -#endif - -#ifdef towlower -inline _LIBCPP_INLINE_VISIBILITY wint_t __libcpp_towlower(wint_t __wc) {return towlower(__wc);} -#undef towlower -inline _LIBCPP_INLINE_VISIBILITY wint_t towlower(wint_t __wc) {return __libcpp_towlower(__wc);} -#else // towlower -using ::towlower; -#endif - -#ifdef towupper -inline _LIBCPP_INLINE_VISIBILITY wint_t __libcpp_towupper(wint_t __wc) {return towupper(__wc);} -#undef towupper -inline _LIBCPP_INLINE_VISIBILITY wint_t towupper(wint_t __wc) {return __libcpp_towupper(__wc);} -#else // towupper -using ::towupper; -#endif - -#ifdef towctrans -inline _LIBCPP_INLINE_VISIBILITY wint_t __libcpp_towctrans(wint_t __wc, wctype_t __d) {return towctrans(__wc, __d);} -#undef towctrans -inline _LIBCPP_INLINE_VISIBILITY wint_t towctrans(wint_t __wc, wctype_t __d) {return __libcpp_towctrans(__wc, __d);} -#else // towctrans -using ::towctrans; -#endif - -#ifdef wctrans -inline _LIBCPP_INLINE_VISIBILITY wctrans_t __libcpp_wctrans(const char* __p) {return wctrans(__p);} -#undef wctrans -inline _LIBCPP_INLINE_VISIBILITY wctrans_t wctrans(const char* __p) {return __libcpp_wctrans(__p);} -#else // wctrans -using ::wctrans; -#endif - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_CWCTYPE diff --git a/libcxx/include/deque b/libcxx/include/deque deleted file mode 100644 index e65acfc806d4..000000000000 --- a/libcxx/include/deque +++ /dev/null @@ -1,2844 +0,0 @@ -// -*- C++ -*- -//===---------------------------- deque -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_DEQUE -#define _LIBCPP_DEQUE - -/* - deque synopsis - -namespace std -{ - -template > -class deque -{ -public: - // types: - typedef T value_type; - typedef Allocator allocator_type; - - typedef typename allocator_type::reference reference; - typedef typename allocator_type::const_reference const_reference; - typedef implementation-defined iterator; - typedef implementation-defined const_iterator; - typedef typename allocator_type::size_type size_type; - typedef typename allocator_type::difference_type difference_type; - - typedef typename allocator_type::pointer pointer; - typedef typename allocator_type::const_pointer const_pointer; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - // construct/copy/destroy: - deque() noexcept(is_nothrow_default_constructible::value); - explicit deque(const allocator_type& a); - explicit deque(size_type n); - deque(size_type n, const value_type& v); - deque(size_type n, const value_type& v, const allocator_type& a); - template - deque(InputIterator f, InputIterator l); - template - deque(InputIterator f, InputIterator l, const allocator_type& a); - deque(const deque& c); - deque(deque&& c) - noexcept(is_nothrow_move_constructible::value); - deque(initializer_list il, const Allocator& a = allocator_type()); - deque(const deque& c, const allocator_type& a); - deque(deque&& c, const allocator_type& a); - ~deque(); - - deque& operator=(const deque& c); - deque& operator=(deque&& c) - noexcept( - allocator_type::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value); - deque& operator=(initializer_list il); - - template - void assign(InputIterator f, InputIterator l); - void assign(size_type n, const value_type& v); - void assign(initializer_list il); - - allocator_type get_allocator() const noexcept; - - // iterators: - - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - - reverse_iterator rbegin() noexcept; - const_reverse_iterator rbegin() const noexcept; - reverse_iterator rend() noexcept; - const_reverse_iterator rend() const noexcept; - - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - const_reverse_iterator crbegin() const noexcept; - const_reverse_iterator crend() const noexcept; - - // capacity: - size_type size() const noexcept; - size_type max_size() const noexcept; - void resize(size_type n); - void resize(size_type n, const value_type& v); - void shrink_to_fit(); - bool empty() const noexcept; - - // element access: - reference operator[](size_type i); - const_reference operator[](size_type i) const; - reference at(size_type i); - const_reference at(size_type i) const; - reference front(); - const_reference front() const; - reference back(); - const_reference back() const; - - // modifiers: - void push_front(const value_type& v); - void push_front(value_type&& v); - void push_back(const value_type& v); - void push_back(value_type&& v); - template void emplace_front(Args&&... args); - template void emplace_back(Args&&... args); - template iterator emplace(const_iterator p, Args&&... args); - iterator insert(const_iterator p, const value_type& v); - iterator insert(const_iterator p, value_type&& v); - iterator insert(const_iterator p, size_type n, const value_type& v); - template - iterator insert (const_iterator p, InputIterator f, InputIterator l); - iterator insert(const_iterator p, initializer_list il); - void pop_front(); - void pop_back(); - iterator erase(const_iterator p); - iterator erase(const_iterator f, const_iterator l); - void swap(deque& c) - noexcept(!allocator_type::propagate_on_container_swap::value || - __is_nothrow_swappable::value); - void clear() noexcept; -}; - -template - bool operator==(const deque& x, const deque& y); -template - bool operator< (const deque& x, const deque& y); -template - bool operator!=(const deque& x, const deque& y); -template - bool operator> (const deque& x, const deque& y); -template - bool operator>=(const deque& x, const deque& y); -template - bool operator<=(const deque& x, const deque& y); - -// specialized algorithms: -template - void swap(deque& x, deque& y) - noexcept(noexcept(x.swap(y))); - -} // std - -*/ - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#include <__config> -#include <__split_buffer> -#include -#include -#include -#include -#include - -#include <__undef_min_max> - -_LIBCPP_BEGIN_NAMESPACE_STD - -template class __deque_base; - -template -class _LIBCPP_VISIBLE __deque_iterator; - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type* = 0); - -template -_OutputIterator -copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type* = 0); - -template -_OutputIterator -copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type* = 0); - -template -_OutputIterator -move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type* = 0); - -template -_OutputIterator -move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - -template -class _LIBCPP_VISIBLE __deque_iterator -{ - typedef _MapPointer __map_iterator; -public: - typedef _Pointer pointer; - typedef _DiffType difference_type; -private: - __map_iterator __m_iter_; - pointer __ptr_; - - static const difference_type __block_size = _BlockSize; -public: - typedef _ValueType value_type; - typedef random_access_iterator_tag iterator_category; - typedef _Reference reference; - - _LIBCPP_INLINE_VISIBILITY __deque_iterator() _NOEXCEPT {} - - template - _LIBCPP_INLINE_VISIBILITY - __deque_iterator(const __deque_iterator& __it, - typename enable_if::value>::type* = 0) _NOEXCEPT - : __m_iter_(__it.__m_iter_), __ptr_(__it.__ptr_) {} - - _LIBCPP_INLINE_VISIBILITY reference operator*() const {return *__ptr_;} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return __ptr_;} - - _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator++() - { - if (++__ptr_ - *__m_iter_ == __block_size) - { - ++__m_iter_; - __ptr_ = *__m_iter_; - } - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator operator++(int) - { - __deque_iterator __tmp = *this; - ++(*this); - return __tmp; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator--() - { - if (__ptr_ == *__m_iter_) - { - --__m_iter_; - __ptr_ = *__m_iter_ + __block_size; - } - --__ptr_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator operator--(int) - { - __deque_iterator __tmp = *this; - --(*this); - return __tmp; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator+=(difference_type __n) - { - if (__n != 0) - { - __n += __ptr_ - *__m_iter_; - if (__n > 0) - { - __m_iter_ += __n / __block_size; - __ptr_ = *__m_iter_ + __n % __block_size; - } - else // (__n < 0) - { - difference_type __z = __block_size - 1 - __n; - __m_iter_ -= __z / __block_size; - __ptr_ = *__m_iter_ + (__block_size - 1 - __z % __block_size); - } - } - return *this; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator& operator-=(difference_type __n) - { - return *this += -__n; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator operator+(difference_type __n) const - { - __deque_iterator __t(*this); - __t += __n; - return __t; - } - - _LIBCPP_INLINE_VISIBILITY __deque_iterator operator-(difference_type __n) const - { - __deque_iterator __t(*this); - __t -= __n; - return __t; - } - - _LIBCPP_INLINE_VISIBILITY - friend __deque_iterator operator+(difference_type __n, const __deque_iterator& __it) - {return __it + __n;} - - _LIBCPP_INLINE_VISIBILITY - friend difference_type operator-(const __deque_iterator& __x, const __deque_iterator& __y) - { - if (__x != __y) - return (__x.__m_iter_ - __y.__m_iter_) * __block_size - + (__x.__ptr_ - *__x.__m_iter_) - - (__y.__ptr_ - *__y.__m_iter_); - return 0; - } - - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const - {return *(*this + __n);} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator==(const __deque_iterator& __x, const __deque_iterator& __y) - {return __x.__ptr_ == __y.__ptr_;} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator!=(const __deque_iterator& __x, const __deque_iterator& __y) - {return !(__x == __y);} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator<(const __deque_iterator& __x, const __deque_iterator& __y) - {return __x.__m_iter_ < __y.__m_iter_ || - (__x.__m_iter_ == __y.__m_iter_ && __x.__ptr_ < __y.__ptr_);} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator>(const __deque_iterator& __x, const __deque_iterator& __y) - {return __y < __x;} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator<=(const __deque_iterator& __x, const __deque_iterator& __y) - {return !(__y < __x);} - - _LIBCPP_INLINE_VISIBILITY friend - bool operator>=(const __deque_iterator& __x, const __deque_iterator& __y) - {return !(__x < __y);} - -private: - _LIBCPP_INLINE_VISIBILITY __deque_iterator(__map_iterator __m, pointer __p) _NOEXCEPT - : __m_iter_(__m), __ptr_(__p) {} - - template friend class __deque_base; - template friend class _LIBCPP_VISIBLE deque; - template - friend class _LIBCPP_VISIBLE __deque_iterator; - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - copy(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*); - - template - friend - _OutputIterator - copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - copy_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*); - - template - friend - _OutputIterator - copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - move(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*); - - template - friend - _OutputIterator - move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - move_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*); - - template - friend - _OutputIterator - move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r); - - template - friend - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> - move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r); -}; - -// copy - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*) -{ - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::difference_type difference_type; - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::pointer pointer; - while (__f != __l) - { - pointer __rb = __r.__ptr_; - pointer __re = *__r.__m_iter_ + _B2; - difference_type __bs = __re - __rb; - difference_type __n = __l - __f; - _RAIter __m = __l; - if (__n > __bs) - { - __n = __bs; - __m = __f + __n; - } - _VSTD::copy(__f, __m, __rb); - __f = __m; - __r += __n; - } - return __r; -} - -template -_OutputIterator -copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + _B1; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - __r = _VSTD::copy(__fb, __fe, __r); - __n -= __bs; - __f += __bs; - } - return __r; -} - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + _B1; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - __r = _VSTD::copy(__fb, __fe, __r); - __n -= __bs; - __f += __bs; - } - return __r; -} - -// copy_backward - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*) -{ - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::difference_type difference_type; - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::pointer pointer; - while (__f != __l) - { - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __rp = _VSTD::prev(__r); - pointer __rb = *__rp.__m_iter_; - pointer __re = __rp.__ptr_ + 1; - difference_type __bs = __re - __rb; - difference_type __n = __l - __f; - _RAIter __m = __f; - if (__n > __bs) - { - __n = __bs; - __m = __l - __n; - } - _VSTD::copy_backward(__m, __l, __re); - __l = __m; - __r -= __n; - } - return __r; -} - -template -_OutputIterator -copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - __r = _VSTD::copy_backward(__lb, __le, __r); - __n -= __bs; - __l -= __bs - 1; - } - return __r; -} - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -copy_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - __r = _VSTD::copy_backward(__lb, __le, __r); - __n -= __bs; - __l -= __bs - 1; - } - return __r; -} - -// move - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*) -{ - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::difference_type difference_type; - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::pointer pointer; - while (__f != __l) - { - pointer __rb = __r.__ptr_; - pointer __re = *__r.__m_iter_ + _B2; - difference_type __bs = __re - __rb; - difference_type __n = __l - __f; - _RAIter __m = __l; - if (__n > __bs) - { - __n = __bs; - __m = __f + __n; - } - _VSTD::move(__f, __m, __rb); - __f = __m; - __r += __n; - } - return __r; -} - -template -_OutputIterator -move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + _B1; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - __r = _VSTD::move(__fb, __fe, __r); - __n -= __bs; - __f += __bs; - } - return __r; -} - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + _B1; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - __r = _VSTD::move(__fb, __fe, __r); - __n -= __bs; - __f += __bs; - } - return __r; -} - -// move_backward - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move_backward(_RAIter __f, - _RAIter __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*) -{ - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::difference_type difference_type; - typedef typename __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2>::pointer pointer; - while (__f != __l) - { - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __rp = _VSTD::prev(__r); - pointer __rb = *__rp.__m_iter_; - pointer __re = __rp.__ptr_ + 1; - difference_type __bs = __re - __rb; - difference_type __n = __l - __f; - _RAIter __m = __f; - if (__n > __bs) - { - __n = __bs; - __m = __l - __n; - } - _VSTD::move_backward(__m, __l, __re); - __l = __m; - __r -= __n; - } - return __r; -} - -template -_OutputIterator -move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - _OutputIterator __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - __r = _VSTD::move_backward(__lb, __le, __r); - __n -= __bs; - __l -= __bs - 1; - } - return __r; -} - -template -__deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> -move_backward(__deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __f, - __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1> __l, - __deque_iterator<_V2, _P2, _R2, _M2, _D2, _B2> __r) -{ - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::difference_type difference_type; - typedef typename __deque_iterator<_V1, _P1, _R1, _M1, _D1, _B1>::pointer pointer; - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - __r = _VSTD::move_backward(__lb, __le, __r); - __n -= __bs; - __l -= __bs - 1; - } - return __r; -} - -template -class __deque_base_common -{ -protected: - void __throw_length_error() const; - void __throw_out_of_range() const; -}; - -template -void -__deque_base_common<__b>::__throw_length_error() const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - throw length_error("deque"); -#endif -} - -template -void -__deque_base_common<__b>::__throw_out_of_range() const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - throw out_of_range("deque"); -#endif -} - -template -class __deque_base - : protected __deque_base_common -{ - __deque_base(const __deque_base& __c); - __deque_base& operator=(const __deque_base& __c); -protected: - typedef _Tp value_type; - typedef _Allocator allocator_type; - typedef allocator_traits __alloc_traits; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - - static const difference_type __block_size = sizeof(value_type) < 256 ? 4096 / sizeof(value_type) : 16; - - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc -#else - rebind_alloc::other -#endif - __pointer_allocator; - typedef allocator_traits<__pointer_allocator> __map_traits; - typedef typename __map_traits::pointer __map_pointer; - typedef typename __map_traits::const_pointer __map_const_pointer; - typedef __split_buffer __map; - - typedef __deque_iterator iterator; - typedef __deque_iterator const_iterator; - - __map __map_; - size_type __start_; - __compressed_pair __size_; - - iterator begin() _NOEXCEPT; - const_iterator begin() const _NOEXCEPT; - iterator end() _NOEXCEPT; - const_iterator end() const _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY size_type& size() {return __size_.first();} - _LIBCPP_INLINE_VISIBILITY - const size_type& size() const _NOEXCEPT {return __size_.first();} - _LIBCPP_INLINE_VISIBILITY allocator_type& __alloc() {return __size_.second();} - _LIBCPP_INLINE_VISIBILITY - const allocator_type& __alloc() const _NOEXCEPT {return __size_.second();} - - __deque_base() - _NOEXCEPT_(is_nothrow_default_constructible::value); - explicit __deque_base(const allocator_type& __a); -public: - ~__deque_base(); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - __deque_base(__deque_base&& __c) - _NOEXCEPT_(is_nothrow_move_constructible::value); - __deque_base(__deque_base&& __c, const allocator_type& __a); - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - void swap(__deque_base& __c) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable::value); -protected: - void clear() _NOEXCEPT; - - bool __invariants() const; - - _LIBCPP_INLINE_VISIBILITY - void __move_assign(__deque_base& __c) - _NOEXCEPT_(__alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value) - { - __map_ = _VSTD::move(__c.__map_); - __start_ = __c.__start_; - size() = __c.size(); - __move_assign_alloc(__c); - __c.__start_ = __c.size() = 0; - } - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__deque_base& __c) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_move_assignment::value || - is_nothrow_move_assignable::value) - {__move_assign_alloc(__c, integral_constant());} - -private: - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__deque_base& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value) - { - __alloc() = _VSTD::move(__c.__alloc()); - } - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__deque_base&, false_type) _NOEXCEPT - {} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(allocator_type& __x, allocator_type& __y) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable::value) - {__swap_alloc(__x, __y, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(allocator_type& __x, allocator_type& __y, true_type) - _NOEXCEPT_(__is_nothrow_swappable::value) - { - using _VSTD::swap; - swap(__x, __y); - } - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(allocator_type&, allocator_type&, false_type) - _NOEXCEPT - {} -}; - -template -bool -__deque_base<_Tp, _Allocator>::__invariants() const -{ - if (!__map_.__invariants()) - return false; - if (__map_.size() >= size_type(-1) / __block_size) - return false; - for (typename __map::const_iterator __i = __map_.begin(), __e = __map_.end(); - __i != __e; ++__i) - if (*__i == nullptr) - return false; - if (__map_.size() != 0) - { - if (size() >= __map_.size() * __block_size) - return false; - if (__start_ >= __map_.size() * __block_size - size()) - return false; - } - else - { - if (size() != 0) - return false; - if (__start_ != 0) - return false; - } - return true; -} - -template -typename __deque_base<_Tp, _Allocator>::iterator -__deque_base<_Tp, _Allocator>::begin() _NOEXCEPT -{ - __map_pointer __mp = __map_.begin() + __start_ / __block_size; - return iterator(__mp, __map_.empty() ? 0 : *__mp + __start_ % __block_size); -} - -template -typename __deque_base<_Tp, _Allocator>::const_iterator -__deque_base<_Tp, _Allocator>::begin() const _NOEXCEPT -{ - __map_const_pointer __mp = __map_.begin() + __start_ / __block_size; - return const_iterator(__mp, __map_.empty() ? 0 : *__mp + __start_ % __block_size); -} - -template -typename __deque_base<_Tp, _Allocator>::iterator -__deque_base<_Tp, _Allocator>::end() _NOEXCEPT -{ - size_type __p = size() + __start_; - __map_pointer __mp = __map_.begin() + __p / __block_size; - return iterator(__mp, __map_.empty() ? 0 : *__mp + __p % __block_size); -} - -template -typename __deque_base<_Tp, _Allocator>::const_iterator -__deque_base<_Tp, _Allocator>::end() const _NOEXCEPT -{ - size_type __p = size() + __start_; - __map_const_pointer __mp = __map_.begin() + __p / __block_size; - return const_iterator(__mp, __map_.empty() ? 0 : *__mp + __p % __block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__deque_base<_Tp, _Allocator>::__deque_base() - _NOEXCEPT_(is_nothrow_default_constructible::value) - : __start_(0), __size_(0) {} - -template -inline _LIBCPP_INLINE_VISIBILITY -__deque_base<_Tp, _Allocator>::__deque_base(const allocator_type& __a) - : __map_(__pointer_allocator(__a)), __start_(0), __size_(0, __a) {} - -template -__deque_base<_Tp, _Allocator>::~__deque_base() -{ - clear(); - typename __map::iterator __i = __map_.begin(); - typename __map::iterator __e = __map_.end(); - for (; __i != __e; ++__i) - __alloc_traits::deallocate(__alloc(), *__i, __block_size); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__deque_base<_Tp, _Allocator>::__deque_base(__deque_base&& __c) - _NOEXCEPT_(is_nothrow_move_constructible::value) - : __map_(_VSTD::move(__c.__map_)), - __start_(_VSTD::move(__c.__start_)), - __size_(_VSTD::move(__c.__size_)) -{ - __c.__start_ = 0; - __c.size() = 0; -} - -template -__deque_base<_Tp, _Allocator>::__deque_base(__deque_base&& __c, const allocator_type& __a) - : __map_(_VSTD::move(__c.__map_), __pointer_allocator(__a)), - __start_(_VSTD::move(__c.__start_)), - __size_(_VSTD::move(__c.size()), __a) -{ - if (__a == __c.__alloc()) - { - __c.__start_ = 0; - __c.size() = 0; - } - else - { - __map_.clear(); - __start_ = 0; - size() = 0; - } -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__deque_base<_Tp, _Allocator>::swap(__deque_base& __c) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value|| - __is_nothrow_swappable::value) -{ - __map_.swap(__c.__map_); - _VSTD::swap(__start_, __c.__start_); - _VSTD::swap(size(), __c.size()); - __swap_alloc(__alloc(), __c.__alloc()); -} - -template -void -__deque_base<_Tp, _Allocator>::clear() _NOEXCEPT -{ - allocator_type& __a = __alloc(); - for (iterator __i = begin(), __e = end(); __i != __e; ++__i) - __alloc_traits::destroy(__a, _VSTD::addressof(*__i)); - size() = 0; - while (__map_.size() > 2) - { - __alloc_traits::deallocate(__a, __map_.front(), __block_size); - __map_.pop_front(); - } - switch (__map_.size()) - { - case 1: - __start_ = __block_size / 2; - break; - case 2: - __start_ = __block_size; - break; - } -} - -template > -class _LIBCPP_VISIBLE deque - : private __deque_base<_Tp, _Allocator> -{ -public: - // types: - - typedef _Tp value_type; - typedef _Allocator allocator_type; - - typedef __deque_base __base; - - typedef typename __base::__alloc_traits __alloc_traits; - typedef typename __base::reference reference; - typedef typename __base::const_reference const_reference; - typedef typename __base::iterator iterator; - typedef typename __base::const_iterator const_iterator; - typedef typename __base::size_type size_type; - typedef typename __base::difference_type difference_type; - - typedef typename __base::pointer pointer; - typedef typename __base::const_pointer const_pointer; - typedef _VSTD::reverse_iterator reverse_iterator; - typedef _VSTD::reverse_iterator const_reverse_iterator; - - // construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY - deque() - _NOEXCEPT_(is_nothrow_default_constructible::value) - {} - _LIBCPP_INLINE_VISIBILITY deque(const allocator_type& __a) : __base(__a) {} - explicit deque(size_type __n); - deque(size_type __n, const value_type& __v); - deque(size_type __n, const value_type& __v, const allocator_type& __a); - template - deque(_InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value>::type* = 0); - template - deque(_InputIter __f, _InputIter __l, const allocator_type& __a, - typename enable_if<__is_input_iterator<_InputIter>::value>::type* = 0); - deque(const deque& __c); - deque(const deque& __c, const allocator_type& __a); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - deque(initializer_list __il); - deque(initializer_list __il, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - deque& operator=(const deque& __c); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - deque& operator=(initializer_list __il) {assign(__il); return *this;} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - deque(deque&& __c) _NOEXCEPT_(is_nothrow_move_constructible<__base>::value); - deque(deque&& __c, const allocator_type& __a); - deque& operator=(deque&& __c) - _NOEXCEPT_(__alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - template - void assign(_InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value && - !__is_random_access_iterator<_InputIter>::value>::type* = 0); - template - void assign(_RAIter __f, _RAIter __l, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type* = 0); - void assign(size_type __n, const value_type& __v); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - void assign(initializer_list __il) {assign(__il.begin(), __il.end());} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - allocator_type get_allocator() const _NOEXCEPT; - - // iterators: - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return __base::begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return __base::begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return __base::end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return __base::end();} - - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rbegin() _NOEXCEPT - {return reverse_iterator(__base::end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rbegin() const _NOEXCEPT - {return const_reverse_iterator(__base::end());} - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rend() _NOEXCEPT - {return reverse_iterator(__base::begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rend() const _NOEXCEPT - {return const_reverse_iterator(__base::begin());} - - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT - {return __base::begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT - {return __base::end();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crbegin() const _NOEXCEPT - {return const_reverse_iterator(__base::end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crend() const _NOEXCEPT - {return const_reverse_iterator(__base::begin());} - - // capacity: - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return __base::size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT - {return __alloc_traits::max_size(__base::__alloc());} - void resize(size_type __n); - void resize(size_type __n, const value_type& __v); - void shrink_to_fit() _NOEXCEPT; - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return __base::size() == 0;} - - // element access: - reference operator[](size_type __i); - const_reference operator[](size_type __i) const; - reference at(size_type __i); - const_reference at(size_type __i) const; - reference front(); - const_reference front() const; - reference back(); - const_reference back() const; - - // 23.2.2.3 modifiers: - void push_front(const value_type& __v); - void push_back(const value_type& __v); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - template void emplace_front(_Args&&... __args); - template void emplace_back(_Args&&... __args); - template iterator emplace(const_iterator __p, _Args&&... __args); -#endif // _LIBCPP_HAS_NO_VARIADICS - void push_front(value_type&& __v); - void push_back(value_type&& __v); - iterator insert(const_iterator __p, value_type&& __v); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - iterator insert(const_iterator __p, const value_type& __v); - iterator insert(const_iterator __p, size_type __n, const value_type& __v); - template - iterator insert (const_iterator __p, _InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value - &&!__is_bidirectional_iterator<_InputIter>::value>::type* = 0); - template - iterator insert (const_iterator __p, _BiIter __f, _BiIter __l, - typename enable_if<__is_bidirectional_iterator<_BiIter>::value>::type* = 0); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator __p, initializer_list __il) - {return insert(__p, __il.begin(), __il.end());} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - void pop_front(); - void pop_back(); - iterator erase(const_iterator __p); - iterator erase(const_iterator __f, const_iterator __l); - - void swap(deque& __c) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable::value); - void clear() _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY - bool __invariants() const {return __base::__invariants();} -private: - _LIBCPP_INLINE_VISIBILITY - static size_type __recommend_blocks(size_type __n) - { - return __n / __base::__block_size + (__n % __base::__block_size != 0); - } - _LIBCPP_INLINE_VISIBILITY - size_type __capacity() const - { - return __base::__map_.size() == 0 ? 0 : __base::__map_.size() * __base::__block_size - 1; - } - _LIBCPP_INLINE_VISIBILITY - size_type __front_spare() const - { - return __base::__start_; - } - _LIBCPP_INLINE_VISIBILITY - size_type __back_spare() const - { - return __capacity() - (__base::__start_ + __base::size()); - } - - template - void __append(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value && - !__is_forward_iterator<_InpIter>::value>::type* = 0); - template - void __append(_ForIter __f, _ForIter __l, - typename enable_if<__is_forward_iterator<_ForIter>::value>::type* = 0); - void __append(size_type __n); - void __append(size_type __n, const value_type& __v); - void __erase_to_end(const_iterator __f); - void __add_front_capacity(); - void __add_front_capacity(size_type __n); - void __add_back_capacity(); - void __add_back_capacity(size_type __n); - iterator __move_and_check(iterator __f, iterator __l, iterator __r, - const_pointer& __vt); - iterator __move_backward_and_check(iterator __f, iterator __l, iterator __r, - const_pointer& __vt); - void __move_construct_and_check(iterator __f, iterator __l, - iterator __r, const_pointer& __vt); - void __move_construct_backward_and_check(iterator __f, iterator __l, - iterator __r, const_pointer& __vt); - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const deque& __c) - {__copy_assign_alloc(__c, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const deque& __c, true_type) - { - if (__base::__alloc() != __c.__alloc()) - { - clear(); - shrink_to_fit(); - } - __base::__alloc() = __c.__alloc(); - __base::__map_.__alloc() = __c.__map_.__alloc(); - } - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const deque&, false_type) - {} - - void __move_assign(deque& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value); - void __move_assign(deque& __c, false_type); -}; - -template -deque<_Tp, _Allocator>::deque(size_type __n) -{ - if (__n > 0) - __append(__n); -} - -template -deque<_Tp, _Allocator>::deque(size_type __n, const value_type& __v) -{ - if (__n > 0) - __append(__n, __v); -} - -template -deque<_Tp, _Allocator>::deque(size_type __n, const value_type& __v, const allocator_type& __a) - : __base(__a) -{ - if (__n > 0) - __append(__n, __v); -} - -template -template -deque<_Tp, _Allocator>::deque(_InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value>::type*) -{ - __append(__f, __l); -} - -template -template -deque<_Tp, _Allocator>::deque(_InputIter __f, _InputIter __l, const allocator_type& __a, - typename enable_if<__is_input_iterator<_InputIter>::value>::type*) - : __base(__a) -{ - __append(__f, __l); -} - -template -deque<_Tp, _Allocator>::deque(const deque& __c) - : __base(__alloc_traits::select_on_container_copy_construction(__c.__alloc())) -{ - __append(__c.begin(), __c.end()); -} - -template -deque<_Tp, _Allocator>::deque(const deque& __c, const allocator_type& __a) - : __base(__a) -{ - __append(__c.begin(), __c.end()); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -deque<_Tp, _Allocator>::deque(initializer_list __il) -{ - __append(__il.begin(), __il.end()); -} - -template -deque<_Tp, _Allocator>::deque(initializer_list __il, const allocator_type& __a) - : __base(__a) -{ - __append(__il.begin(), __il.end()); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -deque<_Tp, _Allocator>& -deque<_Tp, _Allocator>::operator=(const deque& __c) -{ - if (this != &__c) - { - __copy_assign_alloc(__c); - assign(__c.begin(), __c.end()); - } - return *this; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -deque<_Tp, _Allocator>::deque(deque&& __c) - _NOEXCEPT_(is_nothrow_move_constructible<__base>::value) - : __base(_VSTD::move(__c)) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -deque<_Tp, _Allocator>::deque(deque&& __c, const allocator_type& __a) - : __base(_VSTD::move(__c), __a) -{ - if (__a != __c.__alloc()) - { - typedef move_iterator _Ip; - assign(_Ip(__c.begin()), _Ip(__c.end())); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -deque<_Tp, _Allocator>& -deque<_Tp, _Allocator>::operator=(deque&& __c) - _NOEXCEPT_(__alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value) -{ - __move_assign(__c, integral_constant()); - return *this; -} - -template -void -deque<_Tp, _Allocator>::__move_assign(deque& __c, false_type) -{ - if (__base::__alloc() != __c.__alloc()) - { - typedef move_iterator _Ip; - assign(_Ip(__c.begin()), _Ip(__c.end())); - } - else - __move_assign(__c, true_type()); -} - -template -void -deque<_Tp, _Allocator>::__move_assign(deque& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value) -{ - clear(); - shrink_to_fit(); - __base::__move_assign(__c); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -template -void -deque<_Tp, _Allocator>::assign(_InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value && - !__is_random_access_iterator<_InputIter>::value>::type*) -{ - iterator __i = __base::begin(); - iterator __e = __base::end(); - for (; __f != __l && __i != __e; ++__f, ++__i) - *__i = *__f; - if (__f != __l) - __append(__f, __l); - else - __erase_to_end(__i); -} - -template -template -void -deque<_Tp, _Allocator>::assign(_RAIter __f, _RAIter __l, - typename enable_if<__is_random_access_iterator<_RAIter>::value>::type*) -{ - if (static_cast(__l - __f) > __base::size()) - { - _RAIter __m = __f + __base::size(); - _VSTD::copy(__f, __m, __base::begin()); - __append(__m, __l); - } - else - __erase_to_end(_VSTD::copy(__f, __l, __base::begin())); -} - -template -void -deque<_Tp, _Allocator>::assign(size_type __n, const value_type& __v) -{ - if (__n > __base::size()) - { - _VSTD::fill_n(__base::begin(), __base::size(), __v); - __n -= __base::size(); - __append(__n, __v); - } - else - __erase_to_end(_VSTD::fill_n(__base::begin(), __n, __v)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Allocator -deque<_Tp, _Allocator>::get_allocator() const _NOEXCEPT -{ - return __base::__alloc(); -} - -template -void -deque<_Tp, _Allocator>::resize(size_type __n) -{ - if (__n > __base::size()) - __append(__n - __base::size()); - else if (__n < __base::size()) - __erase_to_end(__base::begin() + __n); -} - -template -void -deque<_Tp, _Allocator>::resize(size_type __n, const value_type& __v) -{ - if (__n > __base::size()) - __append(__n - __base::size(), __v); - else if (__n < __base::size()) - __erase_to_end(__base::begin() + __n); -} - -template -void -deque<_Tp, _Allocator>::shrink_to_fit() _NOEXCEPT -{ - allocator_type& __a = __base::__alloc(); - if (empty()) - { - while (__base::__map_.size() > 0) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } - __base::__start_ = 0; - } - else - { - if (__front_spare() >= __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.front(), __base::__block_size); - __base::__map_.pop_front(); - __base::__start_ -= __base::__block_size; - } - if (__back_spare() >= __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } - } - __base::__map_.shrink_to_fit(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::reference -deque<_Tp, _Allocator>::operator[](size_type __i) -{ - size_type __p = __base::__start_ + __i; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::const_reference -deque<_Tp, _Allocator>::operator[](size_type __i) const -{ - size_type __p = __base::__start_ + __i; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::reference -deque<_Tp, _Allocator>::at(size_type __i) -{ - if (__i >= __base::size()) - __base::__throw_out_of_range(); - size_type __p = __base::__start_ + __i; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::const_reference -deque<_Tp, _Allocator>::at(size_type __i) const -{ - if (__i >= __base::size()) - __base::__throw_out_of_range(); - size_type __p = __base::__start_ + __i; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::reference -deque<_Tp, _Allocator>::front() -{ - return *(*(__base::__map_.begin() + __base::__start_ / __base::__block_size) - + __base::__start_ % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::const_reference -deque<_Tp, _Allocator>::front() const -{ - return *(*(__base::__map_.begin() + __base::__start_ / __base::__block_size) - + __base::__start_ % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::reference -deque<_Tp, _Allocator>::back() -{ - size_type __p = __base::size() + __base::__start_ - 1; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename deque<_Tp, _Allocator>::const_reference -deque<_Tp, _Allocator>::back() const -{ - size_type __p = __base::size() + __base::__start_ - 1; - return *(*(__base::__map_.begin() + __p / __base::__block_size) + __p % __base::__block_size); -} - -template -void -deque<_Tp, _Allocator>::push_back(const value_type& __v) -{ - allocator_type& __a = __base::__alloc(); - if (__back_spare() == 0) - __add_back_capacity(); - // __back_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), __v); - ++__base::size(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -deque<_Tp, _Allocator>::push_back(value_type&& __v) -{ - allocator_type& __a = __base::__alloc(); - if (__back_spare() == 0) - __add_back_capacity(); - // __back_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), _VSTD::move(__v)); - ++__base::size(); -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -void -deque<_Tp, _Allocator>::emplace_back(_Args&&... __args) -{ - allocator_type& __a = __base::__alloc(); - if (__back_spare() == 0) - __add_back_capacity(); - // __back_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), _VSTD::forward<_Args>(__args)...); - ++__base::size(); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -deque<_Tp, _Allocator>::push_front(const value_type& __v) -{ - allocator_type& __a = __base::__alloc(); - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), __v); - --__base::__start_; - ++__base::size(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -deque<_Tp, _Allocator>::push_front(value_type&& __v) -{ - allocator_type& __a = __base::__alloc(); - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), _VSTD::move(__v)); - --__base::__start_; - ++__base::size(); -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -void -deque<_Tp, _Allocator>::emplace_front(_Args&&... __args) -{ - allocator_type& __a = __base::__alloc(); - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), _VSTD::forward<_Args>(__args)...); - --__base::__start_; - ++__base::size(); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::insert(const_iterator __p, const value_type& __v) -{ - size_type __pos = __p - __base::begin(); - size_type __to_end = __base::size() - __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < __to_end) - { // insert by shifting things backward - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - if (__pos == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), __v); - --__base::__start_; - ++__base::size(); - } - else - { - const_pointer __vt = pointer_traits::pointer_to(__v); - iterator __b = __base::begin(); - iterator __bm1 = _VSTD::prev(__b); - if (__vt == pointer_traits::pointer_to(*__b)) - __vt = pointer_traits::pointer_to(*__bm1); - __alloc_traits::construct(__a, _VSTD::addressof(*__bm1), _VSTD::move(*__b)); - --__base::__start_; - ++__base::size(); - if (__pos > 1) - __b = __move_and_check(_VSTD::next(__b), __b + __pos, __b, __vt); - *__b = *__vt; - } - } - else - { // insert by shifting things forward - if (__back_spare() == 0) - __add_back_capacity(); - // __back_capacity >= 1 - size_type __de = __base::size() - __pos; - if (__de == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), __v); - ++__base::size(); - } - else - { - const_pointer __vt = pointer_traits::pointer_to(__v); - iterator __e = __base::end(); - iterator __em1 = _VSTD::prev(__e); - if (__vt == pointer_traits::pointer_to(*__em1)) - __vt = pointer_traits::pointer_to(*__e); - __alloc_traits::construct(__a, _VSTD::addressof(*__e), _VSTD::move(*__em1)); - ++__base::size(); - if (__de > 1) - __e = __move_backward_and_check(__e - __de, __em1, __e, __vt); - *--__e = *__vt; - } - } - return __base::begin() + __pos; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::insert(const_iterator __p, value_type&& __v) -{ - size_type __pos = __p - __base::begin(); - size_type __to_end = __base::size() - __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < __to_end) - { // insert by shifting things backward - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - if (__pos == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), _VSTD::move(__v)); - --__base::__start_; - ++__base::size(); - } - else - { - iterator __b = __base::begin(); - iterator __bm1 = _VSTD::prev(__b); - __alloc_traits::construct(__a, _VSTD::addressof(*__bm1), _VSTD::move(*__b)); - --__base::__start_; - ++__base::size(); - if (__pos > 1) - __b = _VSTD::move(_VSTD::next(__b), __b + __pos, __b); - *__b = _VSTD::move(__v); - } - } - else - { // insert by shifting things forward - if (__back_spare() == 0) - __add_back_capacity(); - // __back_capacity >= 1 - size_type __de = __base::size() - __pos; - if (__de == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), _VSTD::move(__v)); - ++__base::size(); - } - else - { - iterator __e = __base::end(); - iterator __em1 = _VSTD::prev(__e); - __alloc_traits::construct(__a, _VSTD::addressof(*__e), _VSTD::move(*__em1)); - ++__base::size(); - if (__de > 1) - __e = _VSTD::move_backward(__e - __de, __em1, __e); - *--__e = _VSTD::move(__v); - } - } - return __base::begin() + __pos; -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::emplace(const_iterator __p, _Args&&... __args) -{ - size_type __pos = __p - __base::begin(); - size_type __to_end = __base::size() - __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < __to_end) - { // insert by shifting things backward - if (__front_spare() == 0) - __add_front_capacity(); - // __front_spare() >= 1 - if (__pos == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*--__base::begin()), _VSTD::forward<_Args>(__args)...); - --__base::__start_; - ++__base::size(); - } - else - { - iterator __b = __base::begin(); - iterator __bm1 = _VSTD::prev(__b); - __alloc_traits::construct(__a, _VSTD::addressof(*__bm1), _VSTD::move(*__b)); - --__base::__start_; - ++__base::size(); - if (__pos > 1) - __b = _VSTD::move(_VSTD::next(__b), __b + __pos, __b); - *__b = value_type(_VSTD::forward<_Args>(__args)...); - } - } - else - { // insert by shifting things forward - if (__back_spare() == 0) - __add_back_capacity(); - // __back_capacity >= 1 - size_type __de = __base::size() - __pos; - if (__de == 0) - { - __alloc_traits::construct(__a, _VSTD::addressof(*__base::end()), _VSTD::forward<_Args>(__args)...); - ++__base::size(); - } - else - { - iterator __e = __base::end(); - iterator __em1 = _VSTD::prev(__e); - __alloc_traits::construct(__a, _VSTD::addressof(*__e), _VSTD::move(*__em1)); - ++__base::size(); - if (__de > 1) - __e = _VSTD::move_backward(__e - __de, __em1, __e); - *--__e = value_type(_VSTD::forward<_Args>(__args)...); - } - } - return __base::begin() + __pos; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::insert(const_iterator __p, size_type __n, const value_type& __v) -{ - size_type __pos = __p - __base::begin(); - size_type __to_end = __base::size() - __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < __to_end) - { // insert by shifting things backward - if (__n > __front_spare()) - __add_front_capacity(__n - __front_spare()); - // __n <= __front_spare() - size_type __old_n = __n; - iterator __old_begin = __base::begin(); - iterator __i = __old_begin; - if (__n > __pos) - { - for (size_type __m = __n - __pos; __m; --__m, --__base::__start_, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*--__i), __v); - __n = __pos; - } - if (__n > 0) - { - const_pointer __vt = pointer_traits::pointer_to(__v); - iterator __obn = __old_begin + __n; - __move_construct_backward_and_check(__old_begin, __obn, __i, __vt); - if (__n < __pos) - __old_begin = __move_and_check(__obn, __old_begin + __pos, __old_begin, __vt); - _VSTD::fill_n(__old_begin, __n, *__vt); - } - } - else - { // insert by shifting things forward - size_type __back_capacity = __back_spare(); - if (__n > __back_capacity) - __add_back_capacity(__n - __back_capacity); - // __n <= __back_capacity - size_type __old_n = __n; - iterator __old_end = __base::end(); - iterator __i = __old_end; - size_type __de = __base::size() - __pos; - if (__n > __de) - { - for (size_type __m = __n - __de; __m; --__m, ++__i, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i), __v); - __n = __de; - } - if (__n > 0) - { - const_pointer __vt = pointer_traits::pointer_to(__v); - iterator __oen = __old_end - __n; - __move_construct_and_check(__oen, __old_end, __i, __vt); - if (__n < __de) - __old_end = __move_backward_and_check(__old_end - __de, __oen, __old_end, __vt); - _VSTD::fill_n(__old_end - __n, __n, *__vt); - } - } - return __base::begin() + __pos; -} - -template -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::insert(const_iterator __p, _InputIter __f, _InputIter __l, - typename enable_if<__is_input_iterator<_InputIter>::value - &&!__is_bidirectional_iterator<_InputIter>::value>::type*) -{ - __split_buffer __buf(__base::__alloc()); - __buf.__construct_at_end(__f, __l); - typedef typename __split_buffer::iterator __bi; - return insert(__p, move_iterator<__bi>(__buf.begin()), move_iterator<__bi>(__buf.end())); -} - -template -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::insert(const_iterator __p, _BiIter __f, _BiIter __l, - typename enable_if<__is_bidirectional_iterator<_BiIter>::value>::type*) -{ - size_type __n = _VSTD::distance(__f, __l); - size_type __pos = __p - __base::begin(); - size_type __to_end = __base::size() - __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < __to_end) - { // insert by shifting things backward - if (__n > __front_spare()) - __add_front_capacity(__n - __front_spare()); - // __n <= __front_spare() - size_type __old_n = __n; - iterator __old_begin = __base::begin(); - iterator __i = __old_begin; - _BiIter __m = __f; - if (__n > __pos) - { - __m = __pos < __n / 2 ? _VSTD::prev(__l, __pos) : _VSTD::next(__f, __n - __pos); - for (_BiIter __j = __m; __j != __f; --__base::__start_, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*--__i), *--__j); - __n = __pos; - } - if (__n > 0) - { - iterator __obn = __old_begin + __n; - for (iterator __j = __obn; __j != __old_begin;) - { - __alloc_traits::construct(__a, _VSTD::addressof(*--__i), _VSTD::move(*--__j)); - --__base::__start_; - ++__base::size(); - } - if (__n < __pos) - __old_begin = _VSTD::move(__obn, __old_begin + __pos, __old_begin); - _VSTD::copy(__m, __l, __old_begin); - } - } - else - { // insert by shifting things forward - size_type __back_capacity = __back_spare(); - if (__n > __back_capacity) - __add_back_capacity(__n - __back_capacity); - // __n <= __back_capacity - size_type __old_n = __n; - iterator __old_end = __base::end(); - iterator __i = __old_end; - _BiIter __m = __l; - size_type __de = __base::size() - __pos; - if (__n > __de) - { - __m = __de < __n / 2 ? _VSTD::next(__f, __de) : _VSTD::prev(__l, __n - __de); - for (_BiIter __j = __m; __j != __l; ++__i, ++__j, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i), *__j); - __n = __de; - } - if (__n > 0) - { - iterator __oen = __old_end - __n; - for (iterator __j = __oen; __j != __old_end; ++__i, ++__j, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i), _VSTD::move(*__j)); - if (__n < __de) - __old_end = _VSTD::move_backward(__old_end - __de, __oen, __old_end); - _VSTD::copy_backward(__f, __m, __old_end); - } - } - return __base::begin() + __pos; -} - -template -template -void -deque<_Tp, _Allocator>::__append(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value && - !__is_forward_iterator<_InpIter>::value>::type*) -{ - for (; __f != __l; ++__f) - push_back(*__f); -} - -template -template -void -deque<_Tp, _Allocator>::__append(_ForIter __f, _ForIter __l, - typename enable_if<__is_forward_iterator<_ForIter>::value>::type*) -{ - size_type __n = _VSTD::distance(__f, __l); - allocator_type& __a = __base::__alloc(); - size_type __back_capacity = __back_spare(); - if (__n > __back_capacity) - __add_back_capacity(__n - __back_capacity); - // __n <= __back_capacity - for (iterator __i = __base::end(); __f != __l; ++__i, ++__f, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i), *__f); -} - -template -void -deque<_Tp, _Allocator>::__append(size_type __n) -{ - allocator_type& __a = __base::__alloc(); - size_type __back_capacity = __back_spare(); - if (__n > __back_capacity) - __add_back_capacity(__n - __back_capacity); - // __n <= __back_capacity - for (iterator __i = __base::end(); __n; --__n, ++__i, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i)); -} - -template -void -deque<_Tp, _Allocator>::__append(size_type __n, const value_type& __v) -{ - allocator_type& __a = __base::__alloc(); - size_type __back_capacity = __back_spare(); - if (__n > __back_capacity) - __add_back_capacity(__n - __back_capacity); - // __n <= __back_capacity - for (iterator __i = __base::end(); __n; --__n, ++__i, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__i), __v); -} - -// Create front capacity for one block of elements. -// Strong guarantee. Either do it or don't touch anything. -template -void -deque<_Tp, _Allocator>::__add_front_capacity() -{ - allocator_type& __a = __base::__alloc(); - if (__back_spare() >= __base::__block_size) - { - __base::__start_ += __base::__block_size; - pointer __pt = __base::__map_.back(); - __base::__map_.pop_back(); - __base::__map_.push_front(__pt); - } - // Else if __base::__map_.size() < __base::__map_.capacity() then we need to allocate 1 buffer - else if (__base::__map_.size() < __base::__map_.capacity()) - { // we can put the new buffer into the map, but don't shift things around - // until all buffers are allocated. If we throw, we don't need to fix - // anything up (any added buffers are undetectible) - if (__base::__map_.__front_spare() > 0) - __base::__map_.push_front(__alloc_traits::allocate(__a, __base::__block_size)); - else - { - __base::__map_.push_back(__alloc_traits::allocate(__a, __base::__block_size)); - // Done allocating, reorder capacity - pointer __pt = __base::__map_.back(); - __base::__map_.pop_back(); - __base::__map_.push_front(__pt); - } - __base::__start_ = __base::__map_.size() == 1 ? - __base::__block_size / 2 : - __base::__start_ + __base::__block_size; - } - // Else need to allocate 1 buffer, *and* we need to reallocate __map_. - else - { - __split_buffer - __buf(max(2 * __base::__map_.capacity(), 1), - 0, __base::__map_.__alloc()); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __buf.push_back(__alloc_traits::allocate(__a, __base::__block_size)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __alloc_traits::deallocate(__a, __buf.front(), __base::__block_size); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - for (typename __base::__map_pointer __i = __base::__map_.begin(); - __i != __base::__map_.end(); ++__i) - __buf.push_back(*__i); - _VSTD::swap(__base::__map_.__first_, __buf.__first_); - _VSTD::swap(__base::__map_.__begin_, __buf.__begin_); - _VSTD::swap(__base::__map_.__end_, __buf.__end_); - _VSTD::swap(__base::__map_.__end_cap(), __buf.__end_cap()); - __base::__start_ = __base::__map_.size() == 1 ? - __base::__block_size / 2 : - __base::__start_ + __base::__block_size; - } -} - -// Create front capacity for __n elements. -// Strong guarantee. Either do it or don't touch anything. -template -void -deque<_Tp, _Allocator>::__add_front_capacity(size_type __n) -{ - allocator_type& __a = __base::__alloc(); - size_type __nb = __recommend_blocks(__n + __base::__map_.empty()); - // Number of unused blocks at back: - size_type __back_capacity = __back_spare() / __base::__block_size; - __back_capacity = _VSTD::min(__back_capacity, __nb); // don't take more than you need - __nb -= __back_capacity; // number of blocks need to allocate - // If __nb == 0, then we have sufficient capacity. - if (__nb == 0) - { - __base::__start_ += __base::__block_size * __back_capacity; - for (; __back_capacity > 0; --__back_capacity) - { - pointer __pt = __base::__map_.back(); - __base::__map_.pop_back(); - __base::__map_.push_front(__pt); - } - } - // Else if __nb <= __map_.capacity() - __map_.size() then we need to allocate __nb buffers - else if (__nb <= __base::__map_.capacity() - __base::__map_.size()) - { // we can put the new buffers into the map, but don't shift things around - // until all buffers are allocated. If we throw, we don't need to fix - // anything up (any added buffers are undetectible) - for (; __nb > 0; --__nb, __base::__start_ += __base::__block_size - (__base::__map_.size() == 1)) - { - if (__base::__map_.__front_spare() == 0) - break; - __base::__map_.push_front(__alloc_traits::allocate(__a, __base::__block_size)); - } - for (; __nb > 0; --__nb, ++__back_capacity) - __base::__map_.push_back(__alloc_traits::allocate(__a, __base::__block_size)); - // Done allocating, reorder capacity - __base::__start_ += __back_capacity * __base::__block_size; - for (; __back_capacity > 0; --__back_capacity) - { - pointer __pt = __base::__map_.back(); - __base::__map_.pop_back(); - __base::__map_.push_front(__pt); - } - } - // Else need to allocate __nb buffers, *and* we need to reallocate __map_. - else - { - size_type __ds = (__nb + __back_capacity) * __base::__block_size - __base::__map_.empty(); - __split_buffer - __buf(max(2* __base::__map_.capacity(), - __nb + __base::__map_.size()), - 0, __base::__map_.__alloc()); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __nb > 0; --__nb) - __buf.push_back(__alloc_traits::allocate(__a, __base::__block_size)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - for (typename __base::__map_pointer __i = __buf.begin(); - __i != __buf.end(); ++__i) - __alloc_traits::deallocate(__a, *__i, __base::__block_size); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __back_capacity > 0; --__back_capacity) - { - __buf.push_back(__base::__map_.back()); - __base::__map_.pop_back(); - } - for (typename __base::__map_pointer __i = __base::__map_.begin(); - __i != __base::__map_.end(); ++__i) - __buf.push_back(*__i); - _VSTD::swap(__base::__map_.__first_, __buf.__first_); - _VSTD::swap(__base::__map_.__begin_, __buf.__begin_); - _VSTD::swap(__base::__map_.__end_, __buf.__end_); - _VSTD::swap(__base::__map_.__end_cap(), __buf.__end_cap()); - __base::__start_ += __ds; - } -} - -// Create back capacity for one block of elements. -// Strong guarantee. Either do it or don't touch anything. -template -void -deque<_Tp, _Allocator>::__add_back_capacity() -{ - allocator_type& __a = __base::__alloc(); - if (__front_spare() >= __base::__block_size) - { - __base::__start_ -= __base::__block_size; - pointer __pt = __base::__map_.front(); - __base::__map_.pop_front(); - __base::__map_.push_back(__pt); - } - // Else if __nb <= __map_.capacity() - __map_.size() then we need to allocate __nb buffers - else if (__base::__map_.size() < __base::__map_.capacity()) - { // we can put the new buffer into the map, but don't shift things around - // until it is allocated. If we throw, we don't need to fix - // anything up (any added buffers are undetectible) - if (__base::__map_.__back_spare() != 0) - __base::__map_.push_back(__alloc_traits::allocate(__a, __base::__block_size)); - else - { - __base::__map_.push_front(__alloc_traits::allocate(__a, __base::__block_size)); - // Done allocating, reorder capacity - pointer __pt = __base::__map_.front(); - __base::__map_.pop_front(); - __base::__map_.push_back(__pt); - } - } - // Else need to allocate 1 buffer, *and* we need to reallocate __map_. - else - { - __split_buffer - __buf(max(2* __base::__map_.capacity(), 1), - __base::__map_.size(), - __base::__map_.__alloc()); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __buf.push_back(__alloc_traits::allocate(__a, __base::__block_size)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __alloc_traits::deallocate(__a, __buf.back(), __base::__block_size); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - for (typename __base::__map_pointer __i = __base::__map_.end(); - __i != __base::__map_.begin();) - __buf.push_front(*--__i); - _VSTD::swap(__base::__map_.__first_, __buf.__first_); - _VSTD::swap(__base::__map_.__begin_, __buf.__begin_); - _VSTD::swap(__base::__map_.__end_, __buf.__end_); - _VSTD::swap(__base::__map_.__end_cap(), __buf.__end_cap()); - } -} - -// Create back capacity for __n elements. -// Strong guarantee. Either do it or don't touch anything. -template -void -deque<_Tp, _Allocator>::__add_back_capacity(size_type __n) -{ - allocator_type& __a = __base::__alloc(); - size_type __nb = __recommend_blocks(__n + __base::__map_.empty()); - // Number of unused blocks at front: - size_type __front_capacity = __front_spare() / __base::__block_size; - __front_capacity = _VSTD::min(__front_capacity, __nb); // don't take more than you need - __nb -= __front_capacity; // number of blocks need to allocate - // If __nb == 0, then we have sufficient capacity. - if (__nb == 0) - { - __base::__start_ -= __base::__block_size * __front_capacity; - for (; __front_capacity > 0; --__front_capacity) - { - pointer __pt = __base::__map_.front(); - __base::__map_.pop_front(); - __base::__map_.push_back(__pt); - } - } - // Else if __nb <= __map_.capacity() - __map_.size() then we need to allocate __nb buffers - else if (__nb <= __base::__map_.capacity() - __base::__map_.size()) - { // we can put the new buffers into the map, but don't shift things around - // until all buffers are allocated. If we throw, we don't need to fix - // anything up (any added buffers are undetectible) - for (; __nb > 0; --__nb) - { - if (__base::__map_.__back_spare() == 0) - break; - __base::__map_.push_back(__alloc_traits::allocate(__a, __base::__block_size)); - } - for (; __nb > 0; --__nb, ++__front_capacity, __base::__start_ += - __base::__block_size - (__base::__map_.size() == 1)) - __base::__map_.push_front(__alloc_traits::allocate(__a, __base::__block_size)); - // Done allocating, reorder capacity - __base::__start_ -= __base::__block_size * __front_capacity; - for (; __front_capacity > 0; --__front_capacity) - { - pointer __pt = __base::__map_.front(); - __base::__map_.pop_front(); - __base::__map_.push_back(__pt); - } - } - // Else need to allocate __nb buffers, *and* we need to reallocate __map_. - else - { - size_type __ds = __front_capacity * __base::__block_size; - __split_buffer - __buf(max(2* __base::__map_.capacity(), - __nb + __base::__map_.size()), - __base::__map_.size() - __front_capacity, - __base::__map_.__alloc()); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __nb > 0; --__nb) - __buf.push_back(__alloc_traits::allocate(__a, __base::__block_size)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - for (typename __base::__map_pointer __i = __buf.begin(); - __i != __buf.end(); ++__i) - __alloc_traits::deallocate(__a, *__i, __base::__block_size); - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - for (; __front_capacity > 0; --__front_capacity) - { - __buf.push_back(__base::__map_.front()); - __base::__map_.pop_front(); - } - for (typename __base::__map_pointer __i = __base::__map_.end(); - __i != __base::__map_.begin();) - __buf.push_front(*--__i); - _VSTD::swap(__base::__map_.__first_, __buf.__first_); - _VSTD::swap(__base::__map_.__begin_, __buf.__begin_); - _VSTD::swap(__base::__map_.__end_, __buf.__end_); - _VSTD::swap(__base::__map_.__end_cap(), __buf.__end_cap()); - __base::__start_ -= __ds; - } -} - -template -void -deque<_Tp, _Allocator>::pop_front() -{ - allocator_type& __a = __base::__alloc(); - __alloc_traits::destroy(__a, *(__base::__map_.begin() + - __base::__start_ / __base::__block_size) + - __base::__start_ % __base::__block_size); - --__base::size(); - if (++__base::__start_ >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.front(), __base::__block_size); - __base::__map_.pop_front(); - __base::__start_ -= __base::__block_size; - } -} - -template -void -deque<_Tp, _Allocator>::pop_back() -{ - allocator_type& __a = __base::__alloc(); - size_type __p = __base::size() + __base::__start_ - 1; - __alloc_traits::destroy(__a, *(__base::__map_.begin() + - __p / __base::__block_size) + - __p % __base::__block_size); - --__base::size(); - if (__back_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } -} - -// move assign [__f, __l) to [__r, __r + (__l-__f)). -// If __vt points into [__f, __l), then subtract (__f - __r) from __vt. -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::__move_and_check(iterator __f, iterator __l, iterator __r, - const_pointer& __vt) -{ - // as if - // for (; __f != __l; ++__f, ++__r) - // *__r = _VSTD::move(*__f); - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + __base::__block_size; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - if (__fb <= __vt && __vt < __fe) - __vt = (const_iterator(__f.__m_iter_, __vt) -= __f - __r).__ptr_; - __r = _VSTD::move(__fb, __fe, __r); - __n -= __bs; - __f += __bs; - } - return __r; -} - -// move assign [__f, __l) to [__r - (__l-__f), __r) backwards. -// If __vt points into [__f, __l), then add (__r - __l) to __vt. -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::__move_backward_and_check(iterator __f, iterator __l, iterator __r, - const_pointer& __vt) -{ - // as if - // while (__f != __l) - // *--__r = _VSTD::move(*--__l); - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - if (__lb <= __vt && __vt < __le) - __vt = (const_iterator(__l.__m_iter_, __vt) += __r - __l - 1).__ptr_; - __r = _VSTD::move_backward(__lb, __le, __r); - __n -= __bs; - __l -= __bs - 1; - } - return __r; -} - -// move construct [__f, __l) to [__r, __r + (__l-__f)). -// If __vt points into [__f, __l), then add (__r - __f) to __vt. -template -void -deque<_Tp, _Allocator>::__move_construct_and_check(iterator __f, iterator __l, - iterator __r, const_pointer& __vt) -{ - allocator_type& __a = __base::__alloc(); - // as if - // for (; __f != __l; ++__r, ++__f, ++__base::size()) - // __alloc_traits::construct(__a, _VSTD::addressof(*__r), _VSTD::move(*__f)); - difference_type __n = __l - __f; - while (__n > 0) - { - pointer __fb = __f.__ptr_; - pointer __fe = *__f.__m_iter_ + __base::__block_size; - difference_type __bs = __fe - __fb; - if (__bs > __n) - { - __bs = __n; - __fe = __fb + __bs; - } - if (__fb <= __vt && __vt < __fe) - __vt = (const_iterator(__f.__m_iter_, __vt) += __r - __f).__ptr_; - for (; __fb != __fe; ++__fb, ++__r, ++__base::size()) - __alloc_traits::construct(__a, _VSTD::addressof(*__r), _VSTD::move(*__fb)); - __n -= __bs; - __f += __bs; - } -} - -// move construct [__f, __l) to [__r - (__l-__f), __r) backwards. -// If __vt points into [__f, __l), then subtract (__l - __r) from __vt. -template -void -deque<_Tp, _Allocator>::__move_construct_backward_and_check(iterator __f, iterator __l, - iterator __r, const_pointer& __vt) -{ - allocator_type& __a = __base::__alloc(); - // as if - // for (iterator __j = __l; __j != __f;) - // { - // __alloc_traitsconstruct(__a, _VSTD::addressof(*--__r), _VSTD::move(*--__j)); - // --__base::__start_; - // ++__base::size(); - // } - difference_type __n = __l - __f; - while (__n > 0) - { - --__l; - pointer __lb = *__l.__m_iter_; - pointer __le = __l.__ptr_ + 1; - difference_type __bs = __le - __lb; - if (__bs > __n) - { - __bs = __n; - __lb = __le - __bs; - } - if (__lb <= __vt && __vt < __le) - __vt = (const_iterator(__l.__m_iter_, __vt) -= __l - __r + 1).__ptr_; - while (__le != __lb) - { - __alloc_traits::construct(__a, _VSTD::addressof(*--__r), _VSTD::move(*--__le)); - --__base::__start_; - ++__base::size(); - } - __n -= __bs; - __l -= __bs - 1; - } -} - -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::erase(const_iterator __f) -{ - difference_type __n = 1; - iterator __b = __base::begin(); - difference_type __pos = __f - __b; - iterator __p = __b + __pos; - allocator_type& __a = __base::__alloc(); - if (__pos < (__base::size() - 1) / 2) - { // erase from front - _VSTD::move_backward(__b, __p, _VSTD::next(__p)); - __alloc_traits::destroy(__a, _VSTD::addressof(*__b)); - --__base::size(); - ++__base::__start_; - if (__front_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.front(), __base::__block_size); - __base::__map_.pop_front(); - __base::__start_ -= __base::__block_size; - } - } - else - { // erase from back - iterator __i = _VSTD::move(_VSTD::next(__p), __base::end(), __p); - __alloc_traits::destroy(__a, _VSTD::addressof(*__i)); - --__base::size(); - if (__back_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } - } - return __base::begin() + __pos; -} - -template -typename deque<_Tp, _Allocator>::iterator -deque<_Tp, _Allocator>::erase(const_iterator __f, const_iterator __l) -{ - difference_type __n = __l - __f; - iterator __b = __base::begin(); - difference_type __pos = __f - __b; - iterator __p = __b + __pos; - if (__n > 0) - { - allocator_type& __a = __base::__alloc(); - if (__pos < (__base::size() - __n) / 2) - { // erase from front - iterator __i = _VSTD::move_backward(__b, __p, __p + __n); - for (; __b != __i; ++__b) - __alloc_traits::destroy(__a, _VSTD::addressof(*__b)); - __base::size() -= __n; - __base::__start_ += __n; - while (__front_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.front(), __base::__block_size); - __base::__map_.pop_front(); - __base::__start_ -= __base::__block_size; - } - } - else - { // erase from back - iterator __i = _VSTD::move(__p + __n, __base::end(), __p); - for (iterator __e = __base::end(); __i != __e; ++__i) - __alloc_traits::destroy(__a, _VSTD::addressof(*__i)); - __base::size() -= __n; - while (__back_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } - } - } - return __base::begin() + __pos; -} - -template -void -deque<_Tp, _Allocator>::__erase_to_end(const_iterator __f) -{ - iterator __e = __base::end(); - difference_type __n = __e - __f; - if (__n > 0) - { - allocator_type& __a = __base::__alloc(); - iterator __b = __base::begin(); - difference_type __pos = __f - __b; - for (iterator __p = __b + __pos; __p != __e; ++__p) - __alloc_traits::destroy(__a, _VSTD::addressof(*__p)); - __base::size() -= __n; - while (__back_spare() >= 2 * __base::__block_size) - { - __alloc_traits::deallocate(__a, __base::__map_.back(), __base::__block_size); - __base::__map_.pop_back(); - } - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -deque<_Tp, _Allocator>::swap(deque& __c) - _NOEXCEPT_(!__alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable::value) -{ - __base::swap(__c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -deque<_Tp, _Allocator>::clear() _NOEXCEPT -{ - __base::clear(); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator==(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - const typename deque<_Tp, _Allocator>::size_type __sz = __x.size(); - return __sz == __y.size() && _VSTD::equal(__x.begin(), __x.end(), __y.begin()); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator!=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - return !(__x == __y); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator< (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - return _VSTD::lexicographical_compare(__x.begin(), __x.end(), __y.begin(), __y.end()); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator> (const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - return __y < __x; -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator>=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - return !(__x < __y); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -bool -operator<=(const deque<_Tp, _Allocator>& __x, const deque<_Tp, _Allocator>& __y) -{ - return !(__y < __x); -} - -template -_LIBCPP_INLINE_VISIBILITY inline -void -swap(deque<_Tp, _Allocator>& __x, deque<_Tp, _Allocator>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_DEQUE diff --git a/libcxx/include/exception b/libcxx/include/exception deleted file mode 100644 index f7c3b70b00ea..000000000000 --- a/libcxx/include/exception +++ /dev/null @@ -1,250 +0,0 @@ -// -*- C++ -*- -//===-------------------------- exception ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_EXCEPTION -#define _LIBCPP_EXCEPTION - -/* - exception synopsis - -namespace std -{ - -class exception -{ -public: - exception() noexcept; - exception(const exception&) noexcept; - exception& operator=(const exception&) noexcept; - virtual ~exception() noexcept; - virtual const char* what() const noexcept; -}; - -class bad_exception - : public exception -{ -public: - bad_exception() noexcept; - bad_exception(const bad_exception&) noexcept; - bad_exception& operator=(const bad_exception&) noexcept; - virtual ~bad_exception() noexcept; - virtual const char* what() const noexcept; -}; - -typedef void (*unexpected_handler)(); -unexpected_handler set_unexpected(unexpected_handler f ) noexcept; -unexpected_handler get_unexpected() noexcept; -[[noreturn]] void unexpected(); - -typedef void (*terminate_handler)(); -terminate_handler set_terminate(terminate_handler f ) noexcept; -terminate_handler get_terminate() noexcept; -[[noreturn]] void terminate() noexcept; - -bool uncaught_exception() noexcept; - -typedef unspecified exception_ptr; - -exception_ptr current_exception() noexcept; -void rethrow_exception [[noreturn]] (exception_ptr p); -template exception_ptr make_exception_ptr(E e) noexcept; - -class nested_exception -{ -public: - nested_exception() noexcept; - nested_exception(const nested_exception&) noexcept = default; - nested_exception& operator=(const nested_exception&) noexcept = default; - virtual ~nested_exception() = default; - - // access functions - [[noreturn]] void rethrow_nested() const; - exception_ptr nested_ptr() const noexcept; -}; - -template [[noreturn]] void throw_with_nested(T&& t); -template void rethrow_if_nested(const E& e); - -} // std - -*/ - -#include <__config> -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -namespace std // purposefully not using versioning namespace -{ - -class _LIBCPP_EXCEPTION_ABI exception -{ -public: - _LIBCPP_INLINE_VISIBILITY exception() _NOEXCEPT {} - virtual ~exception() _NOEXCEPT; - virtual const char* what() const _NOEXCEPT; -}; - -class _LIBCPP_EXCEPTION_ABI bad_exception - : public exception -{ -public: - _LIBCPP_INLINE_VISIBILITY bad_exception() _NOEXCEPT {} - virtual ~bad_exception() _NOEXCEPT; - virtual const char* what() const _NOEXCEPT; -}; - -typedef void (*unexpected_handler)(); -_LIBCPP_VISIBLE unexpected_handler set_unexpected(unexpected_handler) _NOEXCEPT; -_LIBCPP_VISIBLE unexpected_handler get_unexpected() _NOEXCEPT; -_ATTRIBUTE(noreturn) _LIBCPP_VISIBLE void unexpected(); - -typedef void (*terminate_handler)(); -_LIBCPP_VISIBLE terminate_handler set_terminate(terminate_handler) _NOEXCEPT; -_LIBCPP_VISIBLE terminate_handler get_terminate() _NOEXCEPT; -_ATTRIBUTE(noreturn) _LIBCPP_VISIBLE void terminate() _NOEXCEPT; - -_LIBCPP_VISIBLE bool uncaught_exception() _NOEXCEPT; - -class exception_ptr; - -exception_ptr current_exception() _NOEXCEPT; -_ATTRIBUTE(noreturn) void rethrow_exception(exception_ptr); - -class _LIBCPP_VISIBLE exception_ptr -{ - void* __ptr_; -public: - _LIBCPP_INLINE_VISIBILITY exception_ptr() _NOEXCEPT : __ptr_() {} - _LIBCPP_INLINE_VISIBILITY exception_ptr(nullptr_t) _NOEXCEPT : __ptr_() {} - exception_ptr(const exception_ptr&) _NOEXCEPT; - exception_ptr& operator=(const exception_ptr&) _NOEXCEPT; - ~exception_ptr() _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_EXPLICIT - operator bool() const _NOEXCEPT {return __ptr_ != nullptr;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const exception_ptr& __x, const exception_ptr& __y) _NOEXCEPT - {return __x.__ptr_ == __y.__ptr_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const exception_ptr& __x, const exception_ptr& __y) _NOEXCEPT - {return !(__x == __y);} - - friend exception_ptr current_exception() _NOEXCEPT; - _ATTRIBUTE(noreturn) friend void rethrow_exception(exception_ptr); -}; - -template -exception_ptr -make_exception_ptr(_Ep __e) _NOEXCEPT -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { - throw __e; - } - catch (...) - { - return current_exception(); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -// nested_exception - -class _LIBCPP_EXCEPTION_ABI nested_exception -{ - exception_ptr __ptr_; -public: - nested_exception() _NOEXCEPT; -// nested_exception(const nested_exception&) noexcept = default; -// nested_exception& operator=(const nested_exception&) noexcept = default; - virtual ~nested_exception() _NOEXCEPT; - - // access functions - _ATTRIBUTE(noreturn) void rethrow_nested() const; - _LIBCPP_INLINE_VISIBILITY exception_ptr nested_ptr() const _NOEXCEPT {return __ptr_;} -}; - -template -struct __nested - : public _Tp, - public nested_exception -{ - _LIBCPP_INLINE_VISIBILITY explicit __nested(const _Tp& __t) : _Tp(__t) {} -}; - -template -_ATTRIBUTE(noreturn) -void -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -throw_with_nested(_Tp&& __t, typename enable_if< - is_class::type>::value && - !is_base_of::type>::value - >::type* = 0) -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -throw_with_nested (_Tp& __t, typename enable_if< - is_class<_Tp>::value && !is_base_of::value - >::type* = 0) -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - throw __nested::type>(_VSTD::forward<_Tp>(__t)); -#endif -} - -template -_ATTRIBUTE(noreturn) -void -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -throw_with_nested(_Tp&& __t, typename enable_if< - !is_class::type>::value || - is_base_of::type>::value - >::type* = 0) -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -throw_with_nested (_Tp& __t, typename enable_if< - !is_class<_Tp>::value || is_base_of::value - >::type* = 0) -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - throw _VSTD::forward<_Tp>(__t); -#endif -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -rethrow_if_nested(const _Ep& __e, typename enable_if< - is_polymorphic<_Ep>::value - >::type* = 0) -{ - const nested_exception* __nep = dynamic_cast(&__e); - if (__nep) - __nep->rethrow_nested(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -rethrow_if_nested(const _Ep&, typename enable_if< - !is_polymorphic<_Ep>::value - >::type* = 0) -{ -} - -} // std - -#endif // _LIBCPP_EXCEPTION diff --git a/libcxx/include/ext/__hash b/libcxx/include/ext/__hash deleted file mode 100644 index 8e9635d07f57..000000000000 --- a/libcxx/include/ext/__hash +++ /dev/null @@ -1,46 +0,0 @@ -// -*- C++ -*- -//===------------------------- hash_set ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_EXT_HASH -#define _LIBCPP_EXT_HASH - -#pragma GCC system_header - -#include -#include - -namespace __gnu_cxx { -using namespace std; - -template struct _LIBCPP_VISIBLE hash : public std::hash - { }; - -template <> struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const char *__c) const _NOEXCEPT - { - return __do_string_hash(__c, __c + strlen(__c)); - } -}; - -template <> struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(char *__c) const _NOEXCEPT - { - return __do_string_hash(__c, __c + strlen(__c)); - } -}; -} - -#endif _LIBCPP_EXT_HASH diff --git a/libcxx/include/ext/hash_map b/libcxx/include/ext/hash_map deleted file mode 100644 index bebdccb3c41c..000000000000 --- a/libcxx/include/ext/hash_map +++ /dev/null @@ -1,1003 +0,0 @@ -// -*- C++ -*- -//===-------------------------- hash_map ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_HASH_MAP -#define _LIBCPP_HASH_MAP - -/* - - hash_map synopsis - -namespace __gnu_cxx -{ - -template , class Pred = equal_to, - class Alloc = allocator>> -class hash_map -{ -public: - // types - typedef Key key_type; - typedef T mapped_type; - typedef Hash hasher; - typedef Pred key_equal; - typedef Alloc allocator_type; - typedef pair value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef /unspecified/ iterator; - typedef /unspecified/ const_iterator; - - explicit hash_map(size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - template - hash_map(InputIterator f, InputIterator l, - size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - hash_map(const hash_map&); - ~hash_map(); - hash_map& operator=(const hash_map&); - - allocator_type get_allocator() const; - - bool empty() const; - size_type size() const; - size_type max_size() const; - - iterator begin(); - iterator end(); - const_iterator begin() const; - const_iterator end() const; - - pair insert(const value_type& obj); - template - void insert(InputIterator first, InputIterator last); - - void erase(const_iterator position); - size_type erase(const key_type& k); - void erase(const_iterator first, const_iterator last); - void clear(); - - void swap(hash_map&); - - hasher hash_funct() const; - key_equal key_eq() const; - - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; - - mapped_type& operator[](const key_type& k); - - size_type bucket_count() const; - size_type max_bucket_count() const; - - size_type elems_in_bucket(size_type n) const; - - void resize(size_type n); -}; - -template - void swap(hash_map& x, - hash_map& y); - -template - bool - operator==(const hash_map& x, - const hash_map& y); - -template - bool - operator!=(const hash_map& x, - const hash_map& y); - -template , class Pred = equal_to, - class Alloc = allocator>> -class hash_multimap -{ -public: - // types - typedef Key key_type; - typedef T mapped_type; - typedef Hash hasher; - typedef Pred key_equal; - typedef Alloc allocator_type; - typedef pair value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef /unspecified/ iterator; - typedef /unspecified/ const_iterator; - - explicit hash_multimap(size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - template - hash_multimap(InputIterator f, InputIterator l, - size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - explicit hash_multimap(const allocator_type&); - hash_multimap(const hash_multimap&); - ~hash_multimap(); - hash_multimap& operator=(const hash_multimap&); - - allocator_type get_allocator() const; - - bool empty() const; - size_type size() const; - size_type max_size() const; - - iterator begin(); - iterator end(); - const_iterator begin() const; - const_iterator end() const; - - iterator insert(const value_type& obj); - template - void insert(InputIterator first, InputIterator last); - - void erase(const_iterator position); - size_type erase(const key_type& k); - void erase(const_iterator first, const_iterator last); - void clear(); - - void swap(hash_multimap&); - - hasher hash_funct() const; - key_equal key_eq() const; - - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; - - size_type bucket_count() const; - size_type max_bucket_count() const; - - size_type elems_in_bucket(size_type n) const; - - void resize(size_type n); -}; - -template - void swap(hash_multimap& x, - hash_multimap& y); - -template - bool - operator==(const hash_multimap& x, - const hash_multimap& y); - -template - bool - operator!=(const hash_multimap& x, - const hash_multimap& y); - -} // __gnu_cxx - -*/ - -#include <__config> -#include <__hash_table> -#include -#include -#include - -#if __DEPRECATED -#warning Use of the header is deprecated. Migrate to -#endif - -#pragma GCC system_header - -namespace __gnu_cxx { - -using namespace std; - -template ::value -#if __has_feature(is_final) - && !__is_final(_Hash) -#endif - > -class __hash_map_hasher - : private _Hash -{ -public: - _LIBCPP_INLINE_VISIBILITY __hash_map_hasher() : _Hash() {} - _LIBCPP_INLINE_VISIBILITY __hash_map_hasher(const _Hash& __h) : _Hash(__h) {} - _LIBCPP_INLINE_VISIBILITY const _Hash& hash_function() const {return *this;} - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const _Tp& __x) const - {return static_cast(*this)(__x.first);} - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const typename _Tp::first_type& __x) const - {return static_cast(*this)(__x);} -}; - -template -class __hash_map_hasher<_Tp, _Hash, false> -{ - _Hash __hash_; -public: - _LIBCPP_INLINE_VISIBILITY __hash_map_hasher() : __hash_() {} - _LIBCPP_INLINE_VISIBILITY __hash_map_hasher(const _Hash& __h) : __hash_(__h) {} - _LIBCPP_INLINE_VISIBILITY const _Hash& hash_function() const {return __hash_;} - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const _Tp& __x) const - {return __hash_(__x.first);} - _LIBCPP_INLINE_VISIBILITY - size_t operator()(const typename _Tp::first_type& __x) const - {return __hash_(__x);} -}; - -template ::value -#if __has_feature(is_final) - && !__is_final(_Pred) -#endif - > -class __hash_map_equal - : private _Pred -{ -public: - _LIBCPP_INLINE_VISIBILITY __hash_map_equal() : _Pred() {} - _LIBCPP_INLINE_VISIBILITY __hash_map_equal(const _Pred& __p) : _Pred(__p) {} - _LIBCPP_INLINE_VISIBILITY const _Pred& key_eq() const {return *this;} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Tp& __x, const _Tp& __y) const - {return static_cast(*this)(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const typename _Tp::first_type& __x, const _Tp& __y) const - {return static_cast(*this)(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Tp& __x, const typename _Tp::first_type& __y) const - {return static_cast(*this)(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const typename _Tp::first_type& __x, - const typename _Tp::first_type& __y) const - {return static_cast(*this)(__x, __y);} -}; - -template -class __hash_map_equal<_Tp, _Pred, false> -{ - _Pred __pred_; -public: - _LIBCPP_INLINE_VISIBILITY __hash_map_equal() : __pred_() {} - _LIBCPP_INLINE_VISIBILITY __hash_map_equal(const _Pred& __p) : __pred_(__p) {} - _LIBCPP_INLINE_VISIBILITY const _Pred& key_eq() const {return __pred_;} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Tp& __x, const _Tp& __y) const - {return __pred_(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const typename _Tp::first_type& __x, const _Tp& __y) const - {return __pred_(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Tp& __x, const typename _Tp::first_type& __y) const - {return __pred_(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const typename _Tp::first_type& __x, - const typename _Tp::first_type& __y) const - {return __pred_(__x, __y);} -}; - -template -class __hash_map_node_destructor -{ - typedef _Alloc allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::value_type::value_type value_type; -public: - typedef typename __alloc_traits::pointer pointer; -private: - typedef typename value_type::first_type first_type; - typedef typename value_type::second_type second_type; - - allocator_type& __na_; - - __hash_map_node_destructor& operator=(const __hash_map_node_destructor&); - -public: - bool __first_constructed; - bool __second_constructed; - - _LIBCPP_INLINE_VISIBILITY - explicit __hash_map_node_destructor(allocator_type& __na) - : __na_(__na), - __first_constructed(false), - __second_constructed(false) - {} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - __hash_map_node_destructor(__hash_node_destructor&& __x) - : __na_(__x.__na_), - __first_constructed(__x.__value_constructed), - __second_constructed(__x.__value_constructed) - { - __x.__value_constructed = false; - } -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - __hash_map_node_destructor(const __hash_node_destructor& __x) - : __na_(__x.__na_), - __first_constructed(__x.__value_constructed), - __second_constructed(__x.__value_constructed) - { - const_cast(__x.__value_constructed) = false; - } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - void operator()(pointer __p) - { - if (__second_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_.second)); - if (__first_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_.first)); - if (__p) - __alloc_traits::deallocate(__na_, __p, 1); - } -}; - -template -class _LIBCPP_VISIBLE __hash_map_iterator -{ - _HashIterator __i_; - - typedef pointer_traits __pointer_traits; - typedef const typename _HashIterator::value_type::first_type key_type; - typedef typename _HashIterator::value_type::second_type mapped_type; -public: - typedef forward_iterator_tag iterator_category; - typedef pair value_type; - typedef typename _HashIterator::difference_type difference_type; - typedef value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __hash_map_iterator() {} - - _LIBCPP_INLINE_VISIBILITY __hash_map_iterator(_HashIterator __i) : __i_(__i) {} - - _LIBCPP_INLINE_VISIBILITY reference operator*() const {return *operator->();} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return (pointer)__i_.operator->();} - - _LIBCPP_INLINE_VISIBILITY __hash_map_iterator& operator++() {++__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __hash_map_iterator operator++(int) - { - __hash_map_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_map_iterator& __x, const __hash_map_iterator& __y) - {return __x.__i_ == __y.__i_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_map_iterator& __x, const __hash_map_iterator& __y) - {return __x.__i_ != __y.__i_;} - - template friend class _LIBCPP_VISIBLE hash_map; - template friend class _LIBCPP_VISIBLE hash_multimap; - template friend class _LIBCPP_VISIBLE __hash_const_iterator; - template friend class _LIBCPP_VISIBLE __hash_const_local_iterator; - template friend class _LIBCPP_VISIBLE __hash_map_const_iterator; -}; - -template -class _LIBCPP_VISIBLE __hash_map_const_iterator -{ - _HashIterator __i_; - - typedef pointer_traits __pointer_traits; - typedef const typename _HashIterator::value_type::first_type key_type; - typedef typename _HashIterator::value_type::second_type mapped_type; -public: - typedef forward_iterator_tag iterator_category; - typedef pair value_type; - typedef typename _HashIterator::difference_type difference_type; - typedef const value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY __hash_map_const_iterator() {} - - _LIBCPP_INLINE_VISIBILITY - __hash_map_const_iterator(_HashIterator __i) : __i_(__i) {} - _LIBCPP_INLINE_VISIBILITY - __hash_map_const_iterator( - __hash_map_iterator __i) - : __i_(__i.__i_) {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return *operator->();} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return (pointer)__i_.operator->();} - - _LIBCPP_INLINE_VISIBILITY - __hash_map_const_iterator& operator++() {++__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __hash_map_const_iterator operator++(int) - { - __hash_map_const_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __hash_map_const_iterator& __x, const __hash_map_const_iterator& __y) - {return __x.__i_ == __y.__i_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __hash_map_const_iterator& __x, const __hash_map_const_iterator& __y) - {return __x.__i_ != __y.__i_;} - - template friend class _LIBCPP_VISIBLE hash_map; - template friend class _LIBCPP_VISIBLE hash_multimap; - template friend class _LIBCPP_VISIBLE __hash_const_iterator; - template friend class _LIBCPP_VISIBLE __hash_const_local_iterator; -}; - -template , class _Pred = equal_to<_Key>, - class _Alloc = allocator > > -class _LIBCPP_VISIBLE hash_map -{ -public: - // types - typedef _Key key_type; - typedef _Tp mapped_type; - typedef _Tp data_type; - typedef _Hash hasher; - typedef _Pred key_equal; - typedef _Alloc allocator_type; - typedef pair value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - -private: - typedef pair __value_type; - typedef __hash_map_hasher<__value_type, hasher> __hasher; - typedef __hash_map_equal<__value_type, key_equal> __key_equal; - typedef typename allocator_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__value_type> -#else - rebind_alloc<__value_type>::other -#endif - __allocator_type; - - typedef __hash_table<__value_type, __hasher, - __key_equal, __allocator_type> __table; - - __table __table_; - - typedef typename __table::__node_pointer __node_pointer; - typedef typename __table::__node_const_pointer __node_const_pointer; - typedef typename __table::__node_traits __node_traits; - typedef typename __table::__node_allocator __node_allocator; - typedef typename __table::__node __node; - typedef __hash_map_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - typedef allocator_traits __alloc_traits; -public: - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - - typedef __hash_map_iterator iterator; - typedef __hash_map_const_iterator const_iterator; - - _LIBCPP_INLINE_VISIBILITY hash_map() {__table_.rehash(193);} - explicit hash_map(size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - hash_map(size_type __n, const hasher& __hf, - const key_equal& __eql, - const allocator_type& __a); - template - hash_map(_InputIterator __first, _InputIterator __last); - template - hash_map(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - template - hash_map(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf, - const key_equal& __eql, - const allocator_type& __a); - hash_map(const hash_map& __u); - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const - {return allocator_type(__table_.__node_alloc());} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const {return __table_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const {return __table_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const {return __table_.max_size();} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() {return __table_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const {return __table_.end();} - - _LIBCPP_INLINE_VISIBILITY - pair insert(const value_type& __x) - {return __table_.__insert_unique(__x);} - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator, const value_type& __x) {return insert(__x).first;} - template - void insert(_InputIterator __first, _InputIterator __last); - - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __p) {__table_.erase(__p.__i_);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) {return __table_.__erase_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __first, const_iterator __last) - {__table_.erase(__first.__i_, __last.__i_);} - _LIBCPP_INLINE_VISIBILITY - void clear() {__table_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(hash_map& __u) {__table_.swap(__u.__table_);} - - _LIBCPP_INLINE_VISIBILITY - hasher hash_funct() const - {return __table_.hash_function().hash_function();} - _LIBCPP_INLINE_VISIBILITY - key_equal key_eq() const - {return __table_.key_eq().key_eq();} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const {return __table_.__count_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __table_.__equal_range_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __table_.__equal_range_unique(__k);} - - mapped_type& operator[](const key_type& __k); - - _LIBCPP_INLINE_VISIBILITY - size_type bucket_count() const {return __table_.bucket_count();} - _LIBCPP_INLINE_VISIBILITY - size_type max_bucket_count() const {return __table_.max_bucket_count();} - - _LIBCPP_INLINE_VISIBILITY - size_type elems_in_bucket(size_type __n) const - {return __table_.bucket_size(__n);} - - _LIBCPP_INLINE_VISIBILITY - void resize(size_type __n) {__table_.rehash(__n);} - -private: - __node_holder __construct_node(const key_type& __k); -}; - -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - size_type __n, const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); -} - -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - size_type __n, const hasher& __hf, const key_equal& __eql, - const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); -} - -template -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - _InputIterator __first, _InputIterator __last) -{ - __table_.rehash(193); - insert(__first, __last); -} - -template -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql, const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_map( - const hash_map& __u) - : __table_(__u.__table_) -{ - __table_.rehash(__u.bucket_count()); - insert(__u.begin(), __u.end()); -} - -template -typename hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::__node_holder -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::__construct_node(const key_type& __k) -{ - __node_allocator& __na = __table_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first), __k); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second)); - __h.get_deleter().__second_constructed = true; - return _VSTD::move(__h); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_InputIterator __first, - _InputIterator __last) -{ - for (; __first != __last; ++__first) - __table_.__insert_unique(*__first); -} - -template -_Tp& -hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::operator[](const key_type& __k) -{ - iterator __i = find(__k); - if (__i != end()) - return __i->second; - __node_holder __h = __construct_node(__k); - pair __r = __table_.__node_insert_unique(__h.get()); - __h.release(); - return __r.first->second; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - __x.swap(__y); -} - -template -bool -operator==(const hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - const hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - if (__x.size() != __y.size()) - return false; - typedef typename hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator - const_iterator; - for (const_iterator __i = __x.begin(), __ex = __x.end(), __ey = __y.end(); - __i != __ex; ++__i) - { - const_iterator __j = __y.find(__i->first); - if (__j == __ey || !(*__i == *__j)) - return false; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - const hash_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - return !(__x == __y); -} - -template , class _Pred = equal_to<_Key>, - class _Alloc = allocator > > -class _LIBCPP_VISIBLE hash_multimap -{ -public: - // types - typedef _Key key_type; - typedef _Tp mapped_type; - typedef _Tp data_type; - typedef _Hash hasher; - typedef _Pred key_equal; - typedef _Alloc allocator_type; - typedef pair value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - -private: - typedef pair __value_type; - typedef __hash_map_hasher<__value_type, hasher> __hasher; - typedef __hash_map_equal<__value_type, key_equal> __key_equal; - typedef typename allocator_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__value_type> -#else - rebind_alloc<__value_type>::other -#endif - __allocator_type; - - typedef __hash_table<__value_type, __hasher, - __key_equal, __allocator_type> __table; - - __table __table_; - - typedef typename __table::__node_traits __node_traits; - typedef typename __table::__node_allocator __node_allocator; - typedef typename __table::__node __node; - typedef __hash_map_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - typedef allocator_traits __alloc_traits; -public: - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - - typedef __hash_map_iterator iterator; - typedef __hash_map_const_iterator const_iterator; - - _LIBCPP_INLINE_VISIBILITY - hash_multimap() {__table_.rehash(193);} - explicit hash_multimap(size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - hash_multimap(size_type __n, const hasher& __hf, - const key_equal& __eql, - const allocator_type& __a); - template - hash_multimap(_InputIterator __first, _InputIterator __last); - template - hash_multimap(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - template - hash_multimap(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf, - const key_equal& __eql, - const allocator_type& __a); - hash_multimap(const hash_multimap& __u); - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const - {return allocator_type(__table_.__node_alloc());} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const {return __table_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const {return __table_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const {return __table_.max_size();} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() {return __table_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const {return __table_.end();} - - _LIBCPP_INLINE_VISIBILITY - iterator insert(const value_type& __x) {return __table_.__insert_multi(__x);} - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator, const value_type& __x) {return insert(__x);} - template - void insert(_InputIterator __first, _InputIterator __last); - - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __p) {__table_.erase(__p.__i_);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) {return __table_.__erase_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __first, const_iterator __last) - {__table_.erase(__first.__i_, __last.__i_);} - _LIBCPP_INLINE_VISIBILITY - void clear() {__table_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(hash_multimap& __u) {__table_.swap(__u.__table_);} - - _LIBCPP_INLINE_VISIBILITY - hasher hash_funct() const - {return __table_.hash_function().hash_function();} - _LIBCPP_INLINE_VISIBILITY - key_equal key_eq() const - {return __table_.key_eq().key_eq();} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const {return __table_.__count_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __table_.__equal_range_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __table_.__equal_range_multi(__k);} - - _LIBCPP_INLINE_VISIBILITY - size_type bucket_count() const {return __table_.bucket_count();} - _LIBCPP_INLINE_VISIBILITY - size_type max_bucket_count() const {return __table_.max_bucket_count();} - - _LIBCPP_INLINE_VISIBILITY - size_type elems_in_bucket(size_type __n) const - {return __table_.bucket_size(__n);} - - _LIBCPP_INLINE_VISIBILITY - void resize(size_type __n) {__table_.rehash(__n);} -}; - -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - size_type __n, const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); -} - -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - size_type __n, const hasher& __hf, const key_equal& __eql, - const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); -} - -template -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - _InputIterator __first, _InputIterator __last) -{ - __table_.rehash(193); - insert(__first, __last); -} - -template -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql, const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::hash_multimap( - const hash_multimap& __u) - : __table_(__u.__table_) -{ - __table_.rehash(__u.bucket_count()); - insert(__u.begin(), __u.end()); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_InputIterator __first, - _InputIterator __last) -{ - for (; __first != __last; ++__first) - __table_.__insert_multi(*__first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - __x.swap(__y); -} - -template -bool -operator==(const hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - const hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - if (__x.size() != __y.size()) - return false; - typedef typename hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>::const_iterator - const_iterator; - typedef pair _EqRng; - for (const_iterator __i = __x.begin(), __ex = __x.end(); __i != __ex;) - { - _EqRng __xeq = __x.equal_range(__i->first); - _EqRng __yeq = __y.equal_range(__i->first); - if (_VSTD::distance(__xeq.first, __xeq.second) != - _VSTD::distance(__yeq.first, __yeq.second) || - !_VSTD::is_permutation(__xeq.first, __xeq.second, __yeq.first)) - return false; - __i = __xeq.second; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, - const hash_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) -{ - return !(__x == __y); -} - -} // __gnu_cxx - -#endif // _LIBCPP_HASH_MAP diff --git a/libcxx/include/ext/hash_set b/libcxx/include/ext/hash_set deleted file mode 100644 index 14daf7bc29e4..000000000000 --- a/libcxx/include/ext/hash_set +++ /dev/null @@ -1,657 +0,0 @@ -// -*- C++ -*- -//===------------------------- hash_set ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_HASH_SET -#define _LIBCPP_HASH_SET - -/* - - hash_set synopsis - -namespace __gnu_cxx -{ - -template , class Pred = equal_to, - class Alloc = allocator> -class hash_set -{ -public: - // types - typedef Value key_type; - typedef key_type value_type; - typedef Hash hasher; - typedef Pred key_equal; - typedef Alloc allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef /unspecified/ iterator; - typedef /unspecified/ const_iterator; - - explicit hash_set(size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - template - hash_set(InputIterator f, InputIterator l, - size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - hash_set(const hash_set&); - ~hash_set(); - hash_set& operator=(const hash_set&); - - allocator_type get_allocator() const; - - bool empty() const; - size_type size() const; - size_type max_size() const; - - iterator begin(); - iterator end(); - const_iterator begin() const; - const_iterator end() const; - - pair insert(const value_type& obj); - template - void insert(InputIterator first, InputIterator last); - - void erase(const_iterator position); - size_type erase(const key_type& k); - void erase(const_iterator first, const_iterator last); - void clear(); - - void swap(hash_set&); - - hasher hash_funct() const; - key_equal key_eq() const; - - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; - - size_type bucket_count() const; - size_type max_bucket_count() const; - - size_type elems_in_bucket(size_type n) const; - - void resize(size_type n); -}; - -template - void swap(hash_set& x, - hash_set& y); - -template - bool - operator==(const hash_set& x, - const hash_set& y); - -template - bool - operator!=(const hash_set& x, - const hash_set& y); - -template , class Pred = equal_to, - class Alloc = allocator> -class hash_multiset -{ -public: - // types - typedef Value key_type; - typedef key_type value_type; - typedef Hash hasher; - typedef Pred key_equal; - typedef Alloc allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef /unspecified/ iterator; - typedef /unspecified/ const_iterator; - - explicit hash_multiset(size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - template - hash_multiset(InputIterator f, InputIterator l, - size_type n = 193, const hasher& hf = hasher(), - const key_equal& eql = key_equal(), - const allocator_type& a = allocator_type()); - hash_multiset(const hash_multiset&); - ~hash_multiset(); - hash_multiset& operator=(const hash_multiset&); - - allocator_type get_allocator() const; - - bool empty() const; - size_type size() const; - size_type max_size() const; - - iterator begin(); - iterator end(); - const_iterator begin() const; - const_iterator end() const; - - iterator insert(const value_type& obj); - template - void insert(InputIterator first, InputIterator last); - - void erase(const_iterator position); - size_type erase(const key_type& k); - void erase(const_iterator first, const_iterator last); - void clear(); - - void swap(hash_multiset&); - - hasher hash_funct() const; - key_equal key_eq() const; - - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; - - size_type bucket_count() const; - size_type max_bucket_count() const; - - size_type elems_in_bucket(size_type n) const; - - void resize(size_type n); -}; - -template - void swap(hash_multiset& x, - hash_multiset& y); - -template - bool - operator==(const hash_multiset& x, - const hash_multiset& y); - -template - bool - operator!=(const hash_multiset& x, - const hash_multiset& y); -} // __gnu_cxx - -*/ - -#include <__config> -#include <__hash_table> -#include -#include - -#if __DEPRECATED -#warning Use of the header is deprecated. Migrate to -#endif - -namespace __gnu_cxx { - -using namespace std; - -template , class _Pred = equal_to<_Value>, - class _Alloc = allocator<_Value> > -class _LIBCPP_VISIBLE hash_set -{ -public: - // types - typedef _Value key_type; - typedef key_type value_type; - typedef _Hash hasher; - typedef _Pred key_equal; - typedef _Alloc allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - -private: - typedef __hash_table __table; - - __table __table_; - -public: - typedef typename __table::pointer pointer; - typedef typename __table::const_pointer const_pointer; - typedef typename __table::size_type size_type; - typedef typename __table::difference_type difference_type; - - typedef typename __table::const_iterator iterator; - typedef typename __table::const_iterator const_iterator; - - _LIBCPP_INLINE_VISIBILITY - hash_set() {__table_.rehash(193);} - explicit hash_set(size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - hash_set(size_type __n, const hasher& __hf, const key_equal& __eql, - const allocator_type& __a); - template - hash_set(_InputIterator __first, _InputIterator __last); - template - hash_set(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - template - hash_set(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf, const key_equal& __eql, - const allocator_type& __a); - hash_set(const hash_set& __u); - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const - {return allocator_type(__table_.__node_alloc());} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const {return __table_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const {return __table_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const {return __table_.max_size();} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() {return __table_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const {return __table_.end();} - - _LIBCPP_INLINE_VISIBILITY - pair insert(const value_type& __x) - {return __table_.__insert_unique(__x);} - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator, const value_type& __x) {return insert(__x).first;} - template - void insert(_InputIterator __first, _InputIterator __last); - - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __p) {__table_.erase(__p);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) {return __table_.__erase_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __first, const_iterator __last) - {__table_.erase(__first, __last);} - _LIBCPP_INLINE_VISIBILITY - void clear() {__table_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(hash_set& __u) {__table_.swap(__u.__table_);} - - _LIBCPP_INLINE_VISIBILITY - hasher hash_funct() const {return __table_.hash_function();} - _LIBCPP_INLINE_VISIBILITY - key_equal key_eq() const {return __table_.key_eq();} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const {return __table_.__count_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __table_.__equal_range_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __table_.__equal_range_unique(__k);} - - _LIBCPP_INLINE_VISIBILITY - size_type bucket_count() const {return __table_.bucket_count();} - _LIBCPP_INLINE_VISIBILITY - size_type max_bucket_count() const {return __table_.max_bucket_count();} - - _LIBCPP_INLINE_VISIBILITY - size_type elems_in_bucket(size_type __n) const {return __table_.bucket_size(__n);} - - _LIBCPP_INLINE_VISIBILITY - void resize(size_type __n) {__table_.rehash(__n);} -}; - -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set(size_type __n, - const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); -} - -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set(size_type __n, - const hasher& __hf, const key_equal& __eql, const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); -} - -template -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set( - _InputIterator __first, _InputIterator __last) -{ - __table_.rehash(193); - insert(__first, __last); -} - -template -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql, const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -hash_set<_Value, _Hash, _Pred, _Alloc>::hash_set( - const hash_set& __u) - : __table_(__u.__table_) -{ - __table_.rehash(__u.bucket_count()); - insert(__u.begin(), __u.end()); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -hash_set<_Value, _Hash, _Pred, _Alloc>::insert(_InputIterator __first, - _InputIterator __last) -{ - for (; __first != __last; ++__first) - __table_.__insert_unique(*__first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(hash_set<_Value, _Hash, _Pred, _Alloc>& __x, - hash_set<_Value, _Hash, _Pred, _Alloc>& __y) -{ - __x.swap(__y); -} - -template -bool -operator==(const hash_set<_Value, _Hash, _Pred, _Alloc>& __x, - const hash_set<_Value, _Hash, _Pred, _Alloc>& __y) -{ - if (__x.size() != __y.size()) - return false; - typedef typename hash_set<_Value, _Hash, _Pred, _Alloc>::const_iterator - const_iterator; - for (const_iterator __i = __x.begin(), __ex = __x.end(), __ey = __y.end(); - __i != __ex; ++__i) - { - const_iterator __j = __y.find(*__i); - if (__j == __ey || !(*__i == *__j)) - return false; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const hash_set<_Value, _Hash, _Pred, _Alloc>& __x, - const hash_set<_Value, _Hash, _Pred, _Alloc>& __y) -{ - return !(__x == __y); -} - -template , class _Pred = equal_to<_Value>, - class _Alloc = allocator<_Value> > -class _LIBCPP_VISIBLE hash_multiset -{ -public: - // types - typedef _Value key_type; - typedef key_type value_type; - typedef _Hash hasher; - typedef _Pred key_equal; - typedef _Alloc allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - -private: - typedef __hash_table __table; - - __table __table_; - -public: - typedef typename __table::pointer pointer; - typedef typename __table::const_pointer const_pointer; - typedef typename __table::size_type size_type; - typedef typename __table::difference_type difference_type; - - typedef typename __table::const_iterator iterator; - typedef typename __table::const_iterator const_iterator; - - _LIBCPP_INLINE_VISIBILITY - hash_multiset() {__table_.rehash(193);} - explicit hash_multiset(size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - hash_multiset(size_type __n, const hasher& __hf, - const key_equal& __eql, const allocator_type& __a); - template - hash_multiset(_InputIterator __first, _InputIterator __last); - template - hash_multiset(_InputIterator __first, _InputIterator __last, - size_type __n, const hasher& __hf = hasher(), - const key_equal& __eql = key_equal()); - template - hash_multiset(_InputIterator __first, _InputIterator __last, - size_type __n , const hasher& __hf, - const key_equal& __eql, const allocator_type& __a); - hash_multiset(const hash_multiset& __u); - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const - {return allocator_type(__table_.__node_alloc());} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const {return __table_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const {return __table_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const {return __table_.max_size();} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() {return __table_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const {return __table_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const {return __table_.end();} - - _LIBCPP_INLINE_VISIBILITY - iterator insert(const value_type& __x) {return __table_.__insert_multi(__x);} - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator, const value_type& __x) {return insert(__x);} - template - void insert(_InputIterator __first, _InputIterator __last); - - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __p) {__table_.erase(__p);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) {return __table_.__erase_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - void erase(const_iterator __first, const_iterator __last) - {__table_.erase(__first, __last);} - _LIBCPP_INLINE_VISIBILITY - void clear() {__table_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(hash_multiset& __u) {__table_.swap(__u.__table_);} - - _LIBCPP_INLINE_VISIBILITY - hasher hash_funct() const {return __table_.hash_function();} - _LIBCPP_INLINE_VISIBILITY - key_equal key_eq() const {return __table_.key_eq();} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __table_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const {return __table_.__count_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __table_.__equal_range_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __table_.__equal_range_multi(__k);} - - _LIBCPP_INLINE_VISIBILITY - size_type bucket_count() const {return __table_.bucket_count();} - _LIBCPP_INLINE_VISIBILITY - size_type max_bucket_count() const {return __table_.max_bucket_count();} - - _LIBCPP_INLINE_VISIBILITY - size_type elems_in_bucket(size_type __n) const {return __table_.bucket_size(__n);} - - _LIBCPP_INLINE_VISIBILITY - void resize(size_type __n) {__table_.rehash(__n);} -}; - -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - size_type __n, const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); -} - -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - size_type __n, const hasher& __hf, const key_equal& __eql, - const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); -} - -template -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - _InputIterator __first, _InputIterator __last) -{ - __table_.rehash(193); - insert(__first, __last); -} - -template -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql) - : __table_(__hf, __eql) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - _InputIterator __first, _InputIterator __last, size_type __n, - const hasher& __hf, const key_equal& __eql, const allocator_type& __a) - : __table_(__hf, __eql, __a) -{ - __table_.rehash(__n); - insert(__first, __last); -} - -template -hash_multiset<_Value, _Hash, _Pred, _Alloc>::hash_multiset( - const hash_multiset& __u) - : __table_(__u.__table_) -{ - __table_.rehash(__u.bucket_count()); - insert(__u.begin(), __u.end()); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -hash_multiset<_Value, _Hash, _Pred, _Alloc>::insert(_InputIterator __first, - _InputIterator __last) -{ - for (; __first != __last; ++__first) - __table_.__insert_multi(*__first); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(hash_multiset<_Value, _Hash, _Pred, _Alloc>& __x, - hash_multiset<_Value, _Hash, _Pred, _Alloc>& __y) -{ - __x.swap(__y); -} - -template -bool -operator==(const hash_multiset<_Value, _Hash, _Pred, _Alloc>& __x, - const hash_multiset<_Value, _Hash, _Pred, _Alloc>& __y) -{ - if (__x.size() != __y.size()) - return false; - typedef typename hash_multiset<_Value, _Hash, _Pred, _Alloc>::const_iterator - const_iterator; - typedef pair _EqRng; - for (const_iterator __i = __x.begin(), __ex = __x.end(); __i != __ex;) - { - _EqRng __xeq = __x.equal_range(*__i); - _EqRng __yeq = __y.equal_range(*__i); - if (_VSTD::distance(__xeq.first, __xeq.second) != - _VSTD::distance(__yeq.first, __yeq.second) || - !_VSTD::is_permutation(__xeq.first, __xeq.second, __yeq.first)) - return false; - __i = __xeq.second; - } - return true; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const hash_multiset<_Value, _Hash, _Pred, _Alloc>& __x, - const hash_multiset<_Value, _Hash, _Pred, _Alloc>& __y) -{ - return !(__x == __y); -} - -} // __gnu_cxx - -#endif // _LIBCPP_HASH_SET diff --git a/libcxx/include/forward_list b/libcxx/include/forward_list deleted file mode 100644 index 19f748478f5d..000000000000 --- a/libcxx/include/forward_list +++ /dev/null @@ -1,1636 +0,0 @@ -// -*- C++ -*- -//===----------------------- forward_list ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FORWARD_LIST -#define _LIBCPP_FORWARD_LIST - -/* - forward_list synopsis - -namespace std -{ - -template > -class forward_list -{ -public: - typedef T value_type; - typedef Allocator allocator_type; - - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef
iterator; - typedef
const_iterator; - - forward_list() - noexcept(is_nothrow_default_constructible::value); - explicit forward_list(const allocator_type& a); - explicit forward_list(size_type n); - forward_list(size_type n, const value_type& v); - forward_list(size_type n, const value_type& v, const allocator_type& a); - template - forward_list(InputIterator first, InputIterator last); - template - forward_list(InputIterator first, InputIterator last, const allocator_type& a); - forward_list(const forward_list& x); - forward_list(const forward_list& x, const allocator_type& a); - forward_list(forward_list&& x) - noexcept(is_nothrow_move_constructible::value); - forward_list(forward_list&& x, const allocator_type& a); - forward_list(initializer_list il); - forward_list(initializer_list il, const allocator_type& a); - - ~forward_list(); - - forward_list& operator=(const forward_list& x); - forward_list& operator=(forward_list&& x) - noexcept( - allocator_type::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value); - forward_list& operator=(initializer_list il); - - template - void assign(InputIterator first, InputIterator last); - void assign(size_type n, const value_type& v); - void assign(initializer_list il); - - allocator_type get_allocator() const noexcept; - - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - - iterator before_begin() noexcept; - const_iterator before_begin() const noexcept; - const_iterator cbefore_begin() const noexcept; - - bool empty() const noexcept; - size_type max_size() const noexcept; - - reference front(); - const_reference front() const; - - template void emplace_front(Args&&... args); - void push_front(const value_type& v); - void push_front(value_type&& v); - - void pop_front(); - - template - iterator emplace_after(const_iterator p, Args&&... args); - iterator insert_after(const_iterator p, const value_type& v); - iterator insert_after(const_iterator p, value_type&& v); - iterator insert_after(const_iterator p, size_type n, const value_type& v); - template - iterator insert_after(const_iterator p, - InputIterator first, InputIterator last); - iterator insert_after(const_iterator p, initializer_list il); - - iterator erase_after(const_iterator p); - iterator erase_after(const_iterator first, const_iterator last); - - void swap(forward_list& x) - noexcept(!allocator_type::propagate_on_container_swap::value || - __is_nothrow_swappable::value); - - void resize(size_type n); - void resize(size_type n, const value_type& v); - void clear() noexcept; - - void splice_after(const_iterator p, forward_list& x); - void splice_after(const_iterator p, forward_list&& x); - void splice_after(const_iterator p, forward_list& x, const_iterator i); - void splice_after(const_iterator p, forward_list&& x, const_iterator i); - void splice_after(const_iterator p, forward_list& x, - const_iterator first, const_iterator last); - void splice_after(const_iterator p, forward_list&& x, - const_iterator first, const_iterator last); - void remove(const value_type& v); - template void remove_if(Predicate pred); - void unique(); - template void unique(BinaryPredicate binary_pred); - void merge(forward_list& x); - void merge(forward_list&& x); - template void merge(forward_list& x, Compare comp); - template void merge(forward_list&& x, Compare comp); - void sort(); - template void sort(Compare comp); - void reverse() noexcept; -}; - -template - bool operator==(const forward_list& x, - const forward_list& y); - -template - bool operator< (const forward_list& x, - const forward_list& y); - -template - bool operator!=(const forward_list& x, - const forward_list& y); - -template - bool operator> (const forward_list& x, - const forward_list& y); - -template - bool operator>=(const forward_list& x, - const forward_list& y); - -template - bool operator<=(const forward_list& x, - const forward_list& y); - -template - void swap(forward_list& x, forward_list& y) - noexcept(noexcept(x.swap(y))); - -} // std - -*/ - -#include <__config> - -#include -#include -#include -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template struct __forward_list_node; - -template -struct __forward_begin_node -{ - typedef __forward_begin_node __self; - typedef _NodePtr pointer; - - pointer __next_; - - _LIBCPP_INLINE_VISIBILITY __forward_begin_node() : __next_(nullptr) {} -}; - -template -struct __forward_list_node - : public __forward_begin_node - < - typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__forward_list_node<_Tp, _VoidPtr> > -#else - rebind<__forward_list_node<_Tp, _VoidPtr> >::other -#endif - > -{ - typedef _Tp value_type; - - value_type __value_; -}; - -template class forward_list; -template class __forward_list_const_iterator; - -template -class _LIBCPP_VISIBLE __forward_list_iterator -{ - typedef _NodePtr __node_pointer; - - __node_pointer __ptr_; - - _LIBCPP_INLINE_VISIBILITY - explicit __forward_list_iterator(__node_pointer __p) _NOEXCEPT : __ptr_(__p) {} - - template friend class forward_list; - template friend class __forward_list_const_iterator; - -public: - typedef forward_iterator_tag iterator_category; - typedef typename pointer_traits<__node_pointer>::element_type::value_type - value_type; - typedef value_type& reference; - typedef typename pointer_traits<__node_pointer>::difference_type - difference_type; - typedef typename pointer_traits<__node_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY - __forward_list_iterator() _NOEXCEPT : __ptr_(nullptr) {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __ptr_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &__ptr_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __forward_list_iterator& operator++() - { - __ptr_ = __ptr_->__next_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __forward_list_iterator operator++(int) - { - __forward_list_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __forward_list_iterator& __x, - const __forward_list_iterator& __y) - {return __x.__ptr_ == __y.__ptr_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __forward_list_iterator& __x, - const __forward_list_iterator& __y) - {return !(__x == __y);} -}; - -template -class _LIBCPP_VISIBLE __forward_list_const_iterator -{ - typedef _NodeConstPtr __node_const_pointer; - - __node_const_pointer __ptr_; - - _LIBCPP_INLINE_VISIBILITY - explicit __forward_list_const_iterator(__node_const_pointer __p) _NOEXCEPT - : __ptr_(__p) {} - - typedef typename remove_const - < - typename pointer_traits<__node_const_pointer>::element_type - >::type __node; - typedef typename pointer_traits<__node_const_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__node> -#else - rebind<__node>::other -#endif - __node_pointer; - - template friend class forward_list; - -public: - typedef forward_iterator_tag iterator_category; - typedef typename __node::value_type value_type; - typedef const value_type& reference; - typedef typename pointer_traits<__node_const_pointer>::difference_type - difference_type; - typedef typename pointer_traits<__node_const_pointer>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY - __forward_list_const_iterator() _NOEXCEPT : __ptr_(nullptr) {} - _LIBCPP_INLINE_VISIBILITY - __forward_list_const_iterator(__forward_list_iterator<__node_pointer> __p) _NOEXCEPT - : __ptr_(__p.__ptr_) {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return __ptr_->__value_;} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &__ptr_->__value_;} - - _LIBCPP_INLINE_VISIBILITY - __forward_list_const_iterator& operator++() - { - __ptr_ = __ptr_->__next_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __forward_list_const_iterator operator++(int) - { - __forward_list_const_iterator __t(*this); - ++(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __forward_list_const_iterator& __x, - const __forward_list_const_iterator& __y) - {return __x.__ptr_ == __y.__ptr_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __forward_list_const_iterator& __x, - const __forward_list_const_iterator& __y) - {return !(__x == __y);} -}; - -template -class __forward_list_base -{ -protected: - typedef _Tp value_type; - typedef _Alloc allocator_type; - - typedef typename allocator_traits::void_pointer void_pointer; - typedef __forward_list_node __node; - typedef typename __node::__self __begin_node; - typedef typename allocator_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__node> -#else - rebind_alloc<__node>::other -#endif - __node_allocator; - typedef allocator_traits<__node_allocator> __node_traits; - typedef typename __node_traits::pointer __node_pointer; - typedef typename __node_traits::const_pointer __node_const_pointer; - - __compressed_pair<__begin_node, __node_allocator> __before_begin_; - - _LIBCPP_INLINE_VISIBILITY - __node_pointer __before_begin() _NOEXCEPT - {return pointer_traits<__node_pointer>::pointer_to( - static_cast<__node&>(__before_begin_.first()));} - _LIBCPP_INLINE_VISIBILITY - __node_const_pointer __before_begin() const _NOEXCEPT - {return pointer_traits<__node_const_pointer>::pointer_to( - static_cast(__before_begin_.first()));} - - _LIBCPP_INLINE_VISIBILITY - __node_allocator& __alloc() _NOEXCEPT - {return __before_begin_.second();} - _LIBCPP_INLINE_VISIBILITY - const __node_allocator& __alloc() const _NOEXCEPT - {return __before_begin_.second();} - - typedef __forward_list_iterator<__node_pointer> iterator; - typedef __forward_list_const_iterator<__node_const_pointer> const_iterator; - - _LIBCPP_INLINE_VISIBILITY - __forward_list_base() - _NOEXCEPT_(is_nothrow_default_constructible<__node_allocator>::value) - : __before_begin_(__begin_node()) {} - _LIBCPP_INLINE_VISIBILITY - __forward_list_base(const allocator_type& __a) - : __before_begin_(__begin_node(), __node_allocator(__a)) {} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -public: - __forward_list_base(__forward_list_base&& __x) - _NOEXCEPT_(is_nothrow_move_constructible<__node_allocator>::value); - __forward_list_base(__forward_list_base&& __x, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -private: - __forward_list_base(const __forward_list_base&); - __forward_list_base& operator=(const __forward_list_base&); - -public: - ~__forward_list_base(); - -protected: - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __forward_list_base& __x) - {__copy_assign_alloc(__x, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__forward_list_base& __x) - _NOEXCEPT_(!__node_traits::propagate_on_container_move_assignment::value || - is_nothrow_move_assignable<__node_allocator>::value) - {__move_assign_alloc(__x, integral_constant());} - -public: - void swap(__forward_list_base& __x) - _NOEXCEPT_(!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value); -protected: - void clear() _NOEXCEPT; - -private: - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __forward_list_base&, false_type) {} - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __forward_list_base& __x, true_type) - { - if (__alloc() != __x.__alloc()) - clear(); - __alloc() = __x.__alloc(); - } - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__forward_list_base& __x, false_type) _NOEXCEPT - {} - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__forward_list_base& __x, true_type) - _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value) - {__alloc() = _VSTD::move(__x.__alloc());} - - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y) - _NOEXCEPT_(!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) - {__swap_alloc(__x, __y, integral_constant());} - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, - false_type) - _NOEXCEPT - {} - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, - true_type) - _NOEXCEPT_(__is_nothrow_swappable<__node_allocator>::value) - { - using _VSTD::swap; - swap(__x, __y); - } -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -__forward_list_base<_Tp, _Alloc>::__forward_list_base(__forward_list_base&& __x) - _NOEXCEPT_(is_nothrow_move_constructible<__node_allocator>::value) - : __before_begin_(_VSTD::move(__x.__before_begin_)) -{ - __x.__before_begin()->__next_ = nullptr; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__forward_list_base<_Tp, _Alloc>::__forward_list_base(__forward_list_base&& __x, - const allocator_type& __a) - : __before_begin_(__begin_node(), __node_allocator(__a)) -{ - if (__alloc() == __x.__alloc()) - { - __before_begin()->__next_ = __x.__before_begin()->__next_; - __x.__before_begin()->__next_ = nullptr; - } -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -__forward_list_base<_Tp, _Alloc>::~__forward_list_base() -{ - clear(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -__forward_list_base<_Tp, _Alloc>::swap(__forward_list_base& __x) - _NOEXCEPT_(!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) -{ - __swap_alloc(__alloc(), __x.__alloc()); - using _VSTD::swap; - swap(__before_begin()->__next_, __x.__before_begin()->__next_); -} - -template -void -__forward_list_base<_Tp, _Alloc>::clear() _NOEXCEPT -{ - __node_allocator& __a = __alloc(); - for (__node_pointer __p = __before_begin()->__next_; __p != nullptr;) - { - __node_pointer __next = __p->__next_; - __node_traits::destroy(__a, _VSTD::addressof(__p->__value_)); - __node_traits::deallocate(__a, __p, 1); - __p = __next; - } - __before_begin()->__next_ = nullptr; -} - -template > -class _LIBCPP_VISIBLE forward_list - : private __forward_list_base<_Tp, _Alloc> -{ - typedef __forward_list_base<_Tp, _Alloc> base; - typedef typename base::__node_allocator __node_allocator; - typedef typename base::__node __node; - typedef typename base::__node_traits __node_traits; - typedef typename base::__node_pointer __node_pointer; - -public: - typedef _Tp value_type; - typedef _Alloc allocator_type; - - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename allocator_traits::pointer pointer; - typedef typename allocator_traits::const_pointer const_pointer; - typedef typename allocator_traits::size_type size_type; - typedef typename allocator_traits::difference_type difference_type; - - typedef typename base::iterator iterator; - typedef typename base::const_iterator const_iterator; - - _LIBCPP_INLINE_VISIBILITY - forward_list() - _NOEXCEPT_(is_nothrow_default_constructible<__node_allocator>::value) - {} // = default; - explicit forward_list(const allocator_type& __a); - explicit forward_list(size_type __n); - forward_list(size_type __n, const value_type& __v); - forward_list(size_type __n, const value_type& __v, const allocator_type& __a); - template - forward_list(_InputIterator __f, _InputIterator __l, - typename enable_if< - __is_input_iterator<_InputIterator>::value - >::type* = nullptr); - template - forward_list(_InputIterator __f, _InputIterator __l, - const allocator_type& __a, - typename enable_if< - __is_input_iterator<_InputIterator>::value - >::type* = nullptr); - forward_list(const forward_list& __x); - forward_list(const forward_list& __x, const allocator_type& __a); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - forward_list(forward_list&& __x) - _NOEXCEPT_(is_nothrow_move_constructible::value) - : base(_VSTD::move(__x)) {} - forward_list(forward_list&& __x, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - forward_list(initializer_list __il); - forward_list(initializer_list __il, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - // ~forward_list() = default; - - forward_list& operator=(const forward_list& __x); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - forward_list& operator=(forward_list&& __x) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value); -#endif -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - forward_list& operator=(initializer_list __il); -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - template - typename enable_if - < - __is_input_iterator<_InputIterator>::value, - void - >::type - assign(_InputIterator __f, _InputIterator __l); - void assign(size_type __n, const value_type& __v); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - void assign(initializer_list __il); -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const _NOEXCEPT - {return allocator_type(base::__alloc());} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT - {return iterator(base::__before_begin()->__next_);} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT - {return const_iterator(base::__before_begin()->__next_);} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT - {return iterator(nullptr);} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT - {return const_iterator(nullptr);} - - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT - {return const_iterator(base::__before_begin()->__next_);} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT - {return const_iterator(nullptr);} - - _LIBCPP_INLINE_VISIBILITY - iterator before_begin() _NOEXCEPT - {return iterator(base::__before_begin());} - _LIBCPP_INLINE_VISIBILITY - const_iterator before_begin() const _NOEXCEPT - {return const_iterator(base::__before_begin());} - _LIBCPP_INLINE_VISIBILITY - const_iterator cbefore_begin() const _NOEXCEPT - {return const_iterator(base::__before_begin());} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT - {return base::__before_begin()->__next_ == nullptr;} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT - {return numeric_limits::max();} - - _LIBCPP_INLINE_VISIBILITY - reference front() {return base::__before_begin()->__next_->__value_;} - _LIBCPP_INLINE_VISIBILITY - const_reference front() const {return base::__before_begin()->__next_->__value_;} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - template void emplace_front(_Args&&... __args); -#endif - void push_front(value_type&& __v); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - void push_front(const value_type& __v); - - void pop_front(); - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - template - iterator emplace_after(const_iterator __p, _Args&&... __args); -#endif // _LIBCPP_HAS_NO_VARIADICS - iterator insert_after(const_iterator __p, value_type&& __v); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - iterator insert_after(const_iterator __p, const value_type& __v); - iterator insert_after(const_iterator __p, size_type __n, const value_type& __v); - template - _LIBCPP_INLINE_VISIBILITY - typename enable_if - < - __is_input_iterator<_InputIterator>::value, - iterator - >::type - insert_after(const_iterator __p, _InputIterator __f, _InputIterator __l); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - iterator insert_after(const_iterator __p, initializer_list __il) - {return insert_after(__p, __il.begin(), __il.end());} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - iterator erase_after(const_iterator __p); - iterator erase_after(const_iterator __f, const_iterator __l); - - _LIBCPP_INLINE_VISIBILITY - void swap(forward_list& __x) - _NOEXCEPT_(!__node_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) - {base::swap(__x);} - - void resize(size_type __n); - void resize(size_type __n, const value_type& __v); - _LIBCPP_INLINE_VISIBILITY - void clear() _NOEXCEPT {base::clear();} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void splice_after(const_iterator __p, forward_list&& __x); - _LIBCPP_INLINE_VISIBILITY - void splice_after(const_iterator __p, forward_list&& __x, const_iterator __i); - _LIBCPP_INLINE_VISIBILITY - void splice_after(const_iterator __p, forward_list&& __x, - const_iterator __f, const_iterator __l); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - void splice_after(const_iterator __p, forward_list& __x); - void splice_after(const_iterator __p, forward_list& __x, const_iterator __i); - void splice_after(const_iterator __p, forward_list& __x, - const_iterator __f, const_iterator __l); - void remove(const value_type& __v); - template void remove_if(_Predicate __pred); - _LIBCPP_INLINE_VISIBILITY - void unique() {unique(__equal_to());} - template void unique(_BinaryPredicate __binary_pred); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void merge(forward_list&& __x) {merge(__x, __less());} - template - _LIBCPP_INLINE_VISIBILITY - void merge(forward_list&& __x, _Compare __comp) - {merge(__x, _VSTD::move(__comp));} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void merge(forward_list& __x) {merge(__x, __less());} - template void merge(forward_list& __x, _Compare __comp); - _LIBCPP_INLINE_VISIBILITY - void sort() {sort(__less());} - template void sort(_Compare __comp); - void reverse() _NOEXCEPT; - -private: - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void __move_assign(forward_list& __x, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value); - void __move_assign(forward_list& __x, false_type); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - template - static - __node_pointer - __merge(__node_pointer __f1, __node_pointer __f2, _Compare& __comp); - - template - static - __node_pointer - __sort(__node_pointer __f, difference_type __sz, _Compare& __comp); -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -forward_list<_Tp, _Alloc>::forward_list(const allocator_type& __a) - : base(__a) -{ -} - -template -forward_list<_Tp, _Alloc>::forward_list(size_type __n) -{ - if (__n > 0) - { - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(nullptr, _Dp(__a, 1)); - for (__node_pointer __p = base::__before_begin(); __n > 0; --__n, - __p = __p->__next_) - { - __h.reset(__node_traits::allocate(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_)); - __h->__next_ = nullptr; - __p->__next_ = __h.release(); - } - } -} - -template -forward_list<_Tp, _Alloc>::forward_list(size_type __n, const value_type& __v) -{ - insert_after(cbefore_begin(), __n, __v); -} - -template -forward_list<_Tp, _Alloc>::forward_list(size_type __n, const value_type& __v, - const allocator_type& __a) - : base(__a) -{ - insert_after(cbefore_begin(), __n, __v); -} - -template -template -forward_list<_Tp, _Alloc>::forward_list(_InputIterator __f, _InputIterator __l, - typename enable_if< - __is_input_iterator<_InputIterator>::value - >::type*) -{ - insert_after(cbefore_begin(), __f, __l); -} - -template -template -forward_list<_Tp, _Alloc>::forward_list(_InputIterator __f, _InputIterator __l, - const allocator_type& __a, - typename enable_if< - __is_input_iterator<_InputIterator>::value - >::type*) - : base(__a) -{ - insert_after(cbefore_begin(), __f, __l); -} - -template -forward_list<_Tp, _Alloc>::forward_list(const forward_list& __x) - : base(allocator_type( - __node_traits::select_on_container_copy_construction(__x.__alloc()) - ) - ) -{ - insert_after(cbefore_begin(), __x.begin(), __x.end()); -} - -template -forward_list<_Tp, _Alloc>::forward_list(const forward_list& __x, - const allocator_type& __a) - : base(__a) -{ - insert_after(cbefore_begin(), __x.begin(), __x.end()); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -forward_list<_Tp, _Alloc>::forward_list(forward_list&& __x, - const allocator_type& __a) - : base(_VSTD::move(__x), __a) -{ - if (base::__alloc() != __x.__alloc()) - { - typedef move_iterator _Ip; - insert_after(cbefore_begin(), _Ip(__x.begin()), _Ip(__x.end())); - } -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -forward_list<_Tp, _Alloc>::forward_list(initializer_list __il) -{ - insert_after(cbefore_begin(), __il.begin(), __il.end()); -} - -template -forward_list<_Tp, _Alloc>::forward_list(initializer_list __il, - const allocator_type& __a) - : base(__a) -{ - insert_after(cbefore_begin(), __il.begin(), __il.end()); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -forward_list<_Tp, _Alloc>& -forward_list<_Tp, _Alloc>::operator=(const forward_list& __x) -{ - if (this != &__x) - { - base::__copy_assign_alloc(__x); - assign(__x.begin(), __x.end()); - } - return *this; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -forward_list<_Tp, _Alloc>::__move_assign(forward_list& __x, true_type) - _NOEXCEPT_(is_nothrow_move_assignable::value) -{ - clear(); - base::__move_assign_alloc(__x); - base::__before_begin()->__next_ = __x.__before_begin()->__next_; - __x.__before_begin()->__next_ = nullptr; -} - -template -void -forward_list<_Tp, _Alloc>::__move_assign(forward_list& __x, false_type) -{ - if (base::__alloc() == __x.__alloc()) - __move_assign(__x, true_type()); - else - { - typedef move_iterator _Ip; - assign(_Ip(__x.begin()), _Ip(__x.end())); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -forward_list<_Tp, _Alloc>& -forward_list<_Tp, _Alloc>::operator=(forward_list&& __x) - _NOEXCEPT_( - __node_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value) -{ - __move_assign(__x, integral_constant()); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -forward_list<_Tp, _Alloc>& -forward_list<_Tp, _Alloc>::operator=(initializer_list __il) -{ - assign(__il.begin(), __il.end()); - return *this; -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -template -typename enable_if -< - __is_input_iterator<_InputIterator>::value, - void ->::type -forward_list<_Tp, _Alloc>::assign(_InputIterator __f, _InputIterator __l) -{ - iterator __i = before_begin(); - iterator __j = _VSTD::next(__i); - iterator __e = end(); - for (; __j != __e && __f != __l; ++__i, ++__j, ++__f) - *__j = *__f; - if (__j == __e) - insert_after(__i, __f, __l); - else - erase_after(__i, __e); -} - -template -void -forward_list<_Tp, _Alloc>::assign(size_type __n, const value_type& __v) -{ - iterator __i = before_begin(); - iterator __j = _VSTD::next(__i); - iterator __e = end(); - for (; __j != __e && __n > 0; --__n, ++__i, ++__j) - *__j = __v; - if (__j == __e) - insert_after(__i, __n, __v); - else - erase_after(__i, __e); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -void -forward_list<_Tp, _Alloc>::assign(initializer_list __il) -{ - assign(__il.begin(), __il.end()); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -void -forward_list<_Tp, _Alloc>::emplace_front(_Args&&... __args) -{ - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), - _VSTD::forward<_Args>(__args)...); - __h->__next_ = base::__before_begin()->__next_; - base::__before_begin()->__next_ = __h.release(); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -void -forward_list<_Tp, _Alloc>::push_front(value_type&& __v) -{ - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), _VSTD::move(__v)); - __h->__next_ = base::__before_begin()->__next_; - base::__before_begin()->__next_ = __h.release(); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -forward_list<_Tp, _Alloc>::push_front(const value_type& __v) -{ - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), __v); - __h->__next_ = base::__before_begin()->__next_; - base::__before_begin()->__next_ = __h.release(); -} - -template -void -forward_list<_Tp, _Alloc>::pop_front() -{ - __node_allocator& __a = base::__alloc(); - __node_pointer __p = base::__before_begin()->__next_; - base::__before_begin()->__next_ = __p->__next_; - __node_traits::destroy(__a, _VSTD::addressof(__p->__value_)); - __node_traits::deallocate(__a, __p, 1); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::emplace_after(const_iterator __p, _Args&&... __args) -{ - __node_pointer const __r = const_cast<__node_pointer>(__p.__ptr_); - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), - _VSTD::forward<_Args>(__args)...); - __h->__next_ = __r->__next_; - __r->__next_ = __h.release(); - return iterator(__r->__next_); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::insert_after(const_iterator __p, value_type&& __v) -{ - __node_pointer const __r = const_cast<__node_pointer>(__p.__ptr_); - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), _VSTD::move(__v)); - __h->__next_ = __r->__next_; - __r->__next_ = __h.release(); - return iterator(__r->__next_); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::insert_after(const_iterator __p, const value_type& __v) -{ - __node_pointer const __r = const_cast<__node_pointer>(__p.__ptr_); - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), __v); - __h->__next_ = __r->__next_; - __r->__next_ = __h.release(); - return iterator(__r->__next_); -} - -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::insert_after(const_iterator __p, size_type __n, - const value_type& __v) -{ - __node_pointer __r = const_cast<__node_pointer>(__p.__ptr_); - if (__n > 0) - { - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), __v); - __node_pointer __first = __h.release(); - __node_pointer __last = __first; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (--__n; __n != 0; --__n, __last = __last->__next_) - { - __h.reset(__node_traits::allocate(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), __v); - __last->__next_ = __h.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (__first != nullptr) - { - __node_pointer __next = __first->__next_; - __node_traits::destroy(__a, _VSTD::addressof(__first->__value_)); - __node_traits::deallocate(__a, __first, 1); - __first = __next; - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __last->__next_ = __r->__next_; - __r->__next_ = __first; - __r = __last; - } - return iterator(__r); -} - -template -template -typename enable_if -< - __is_input_iterator<_InputIterator>::value, - typename forward_list<_Tp, _Alloc>::iterator ->::type -forward_list<_Tp, _Alloc>::insert_after(const_iterator __p, - _InputIterator __f, _InputIterator __l) -{ - __node_pointer __r = const_cast<__node_pointer>(__p.__ptr_); - if (__f != __l) - { - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(__node_traits::allocate(__a, 1), _Dp(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), *__f); - __node_pointer __first = __h.release(); - __node_pointer __last = __first; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (++__f; __f != __l; ++__f, __last = __last->__next_) - { - __h.reset(__node_traits::allocate(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), *__f); - __last->__next_ = __h.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (__first != nullptr) - { - __node_pointer __next = __first->__next_; - __node_traits::destroy(__a, _VSTD::addressof(__first->__value_)); - __node_traits::deallocate(__a, __first, 1); - __first = __next; - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __last->__next_ = __r->__next_; - __r->__next_ = __first; - __r = __last; - } - return iterator(__r); -} - -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::erase_after(const_iterator __f) -{ - __node_pointer __p = const_cast<__node_pointer>(__f.__ptr_); - __node_pointer __n = __p->__next_; - __p->__next_ = __n->__next_; - __node_allocator& __a = base::__alloc(); - __node_traits::destroy(__a, _VSTD::addressof(__n->__value_)); - __node_traits::deallocate(__a, __n, 1); - return iterator(__p->__next_); -} - -template -typename forward_list<_Tp, _Alloc>::iterator -forward_list<_Tp, _Alloc>::erase_after(const_iterator __f, const_iterator __l) -{ - __node_pointer __e = const_cast<__node_pointer>(__l.__ptr_); - if (__f != __l) - { - __node_pointer __p = const_cast<__node_pointer>(__f.__ptr_); - __node_pointer __n = __p->__next_; - if (__n != __e) - { - __p->__next_ = __e; - __node_allocator& __a = base::__alloc(); - do - { - __p = __n->__next_; - __node_traits::destroy(__a, _VSTD::addressof(__n->__value_)); - __node_traits::deallocate(__a, __n, 1); - __n = __p; - } while (__n != __e); - } - } - return iterator(__e); -} - -template -void -forward_list<_Tp, _Alloc>::resize(size_type __n) -{ - size_type __sz = 0; - iterator __p = before_begin(); - iterator __i = begin(); - iterator __e = end(); - for (; __i != __e && __sz < __n; ++__p, ++__i, ++__sz) - ; - if (__i != __e) - erase_after(__p, __e); - else - { - __n -= __sz; - if (__n > 0) - { - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(nullptr, _Dp(__a, 1)); - for (__node_pointer __ptr = __p.__ptr_; __n > 0; --__n, - __ptr = __ptr->__next_) - { - __h.reset(__node_traits::allocate(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_)); - __h->__next_ = nullptr; - __ptr->__next_ = __h.release(); - } - } - } -} - -template -void -forward_list<_Tp, _Alloc>::resize(size_type __n, const value_type& __v) -{ - size_type __sz = 0; - iterator __p = before_begin(); - iterator __i = begin(); - iterator __e = end(); - for (; __i != __e && __sz < __n; ++__p, ++__i, ++__sz) - ; - if (__i != __e) - erase_after(__p, __e); - else - { - __n -= __sz; - if (__n > 0) - { - __node_allocator& __a = base::__alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __h(nullptr, _Dp(__a, 1)); - for (__node_pointer __ptr = __p.__ptr_; __n > 0; --__n, - __ptr = __ptr->__next_) - { - __h.reset(__node_traits::allocate(__a, 1)); - __node_traits::construct(__a, _VSTD::addressof(__h->__value_), __v); - __h->__next_ = nullptr; - __ptr->__next_ = __h.release(); - } - } - } -} - -template -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list& __x) -{ - if (!__x.empty()) - { - if (__p.__ptr_->__next_ != nullptr) - { - const_iterator __lm1 = __x.before_begin(); - while (__lm1.__ptr_->__next_ != nullptr) - ++__lm1; - const_cast<__node_pointer>(__lm1.__ptr_)->__next_ = - const_cast<__node_pointer>(__p.__ptr_)->__next_; - } - const_cast<__node_pointer>(__p.__ptr_)->__next_ = - const_cast<__node_pointer>(__x.__before_begin())->__next_; - const_cast<__node_pointer>(__x.__before_begin())->__next_ = nullptr; - } -} - -template -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list& __x, - const_iterator __i) -{ - const_iterator __lm1 = _VSTD::next(__i); - if (__p != __i && __p != __lm1) - { - const_cast<__node_pointer>(__i.__ptr_)->__next_ = - const_cast<__node_pointer>(__lm1.__ptr_)->__next_; - const_cast<__node_pointer>(__lm1.__ptr_)->__next_ = - const_cast<__node_pointer>(__p.__ptr_)->__next_; - const_cast<__node_pointer>(__p.__ptr_)->__next_ = - const_cast<__node_pointer>(__lm1.__ptr_); - } -} - -template -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list& __x, - const_iterator __f, const_iterator __l) -{ - if (__f != __l && __p != __f) - { - const_iterator __lm1 = __f; - while (__lm1.__ptr_->__next_ != __l.__ptr_) - ++__lm1; - if (__f != __lm1) - { - const_cast<__node_pointer>(__lm1.__ptr_)->__next_ = - const_cast<__node_pointer>(__p.__ptr_)->__next_; - const_cast<__node_pointer>(__p.__ptr_)->__next_ = - const_cast<__node_pointer>(__f.__ptr_)->__next_; - const_cast<__node_pointer>(__f.__ptr_)->__next_ = - const_cast<__node_pointer>(__l.__ptr_); - } - } -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list&& __x) -{ - splice_after(__p, __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list&& __x, - const_iterator __i) -{ - splice_after(__p, __x, __i); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -forward_list<_Tp, _Alloc>::splice_after(const_iterator __p, - forward_list&& __x, - const_iterator __f, const_iterator __l) -{ - splice_after(__p, __x, __f, __l); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -forward_list<_Tp, _Alloc>::remove(const value_type& __v) -{ - iterator __e = end(); - for (iterator __i = before_begin(); __i.__ptr_->__next_ != nullptr;) - { - if (__i.__ptr_->__next_->__value_ == __v) - { - iterator __j = _VSTD::next(__i, 2); - for (; __j != __e && *__j == __v; ++__j) - ; - erase_after(__i, __j); - if (__j == __e) - break; - __i = __j; - } - else - ++__i; - } -} - -template -template -void -forward_list<_Tp, _Alloc>::remove_if(_Predicate __pred) -{ - iterator __e = end(); - for (iterator __i = before_begin(); __i.__ptr_->__next_ != nullptr;) - { - if (__pred(__i.__ptr_->__next_->__value_)) - { - iterator __j = _VSTD::next(__i, 2); - for (; __j != __e && __pred(*__j); ++__j) - ; - erase_after(__i, __j); - if (__j == __e) - break; - __i = __j; - } - else - ++__i; - } -} - -template -template -void -forward_list<_Tp, _Alloc>::unique(_BinaryPredicate __binary_pred) -{ - for (iterator __i = begin(), __e = end(); __i != __e;) - { - iterator __j = _VSTD::next(__i); - for (; __j != __e && __binary_pred(*__i, *__j); ++__j) - ; - if (__i.__ptr_->__next_ != __j.__ptr_) - erase_after(__i, __j); - __i = __j; - } -} - -template -template -void -forward_list<_Tp, _Alloc>::merge(forward_list& __x, _Compare __comp) -{ - if (this != &__x) - { - base::__before_begin()->__next_ = __merge(base::__before_begin()->__next_, - __x.__before_begin()->__next_, - __comp); - __x.__before_begin()->__next_ = nullptr; - } -} - -template -template -typename forward_list<_Tp, _Alloc>::__node_pointer -forward_list<_Tp, _Alloc>::__merge(__node_pointer __f1, __node_pointer __f2, - _Compare& __comp) -{ - if (__f1 == nullptr) - return __f2; - if (__f2 == nullptr) - return __f1; - __node_pointer __r; - if (__comp(__f2->__value_, __f1->__value_)) - { - __node_pointer __t = __f2; - while (__t->__next_ != nullptr && - __comp(__t->__next_->__value_, __f1->__value_)) - __t = __t->__next_; - __r = __f2; - __f2 = __t->__next_; - __t->__next_ = __f1; - } - else - __r = __f1; - __node_pointer __p = __f1; - __f1 = __f1->__next_; - while (__f1 != nullptr && __f2 != nullptr) - { - if (__comp(__f2->__value_, __f1->__value_)) - { - __node_pointer __t = __f2; - while (__t->__next_ != nullptr && - __comp(__t->__next_->__value_, __f1->__value_)) - __t = __t->__next_; - __p->__next_ = __f2; - __f2 = __t->__next_; - __t->__next_ = __f1; - } - __p = __f1; - __f1 = __f1->__next_; - } - if (__f2 != nullptr) - __p->__next_ = __f2; - return __r; -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -forward_list<_Tp, _Alloc>::sort(_Compare __comp) -{ - base::__before_begin()->__next_ = __sort(base::__before_begin()->__next_, - _VSTD::distance(begin(), end()), __comp); -} - -template -template -typename forward_list<_Tp, _Alloc>::__node_pointer -forward_list<_Tp, _Alloc>::__sort(__node_pointer __f1, difference_type __sz, - _Compare& __comp) -{ - switch (__sz) - { - case 0: - case 1: - return __f1; - case 2: - if (__comp(__f1->__next_->__value_, __f1->__value_)) - { - __node_pointer __t = __f1->__next_; - __t->__next_ = __f1; - __f1->__next_ = nullptr; - __f1 = __t; - } - return __f1; - } - difference_type __sz1 = __sz / 2; - difference_type __sz2 = __sz - __sz1; - __node_pointer __t = _VSTD::next(iterator(__f1), __sz1 - 1).__ptr_; - __node_pointer __f2 = __t->__next_; - __t->__next_ = nullptr; - return __merge(__sort(__f1, __sz1, __comp), - __sort(__f2, __sz2, __comp), __comp); -} - -template -void -forward_list<_Tp, _Alloc>::reverse() _NOEXCEPT -{ - __node_pointer __p = base::__before_begin()->__next_; - if (__p != nullptr) - { - __node_pointer __f = __p->__next_; - __p->__next_ = nullptr; - while (__f != nullptr) - { - __node_pointer __t = __f->__next_; - __f->__next_ = __p; - __p = __f; - __f = __t; - } - base::__before_begin()->__next_ = __p; - } -} - -template -bool operator==(const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - typedef forward_list<_Tp, _Alloc> _Cp; - typedef typename _Cp::const_iterator _Ip; - _Ip __ix = __x.begin(); - _Ip __ex = __x.end(); - _Ip __iy = __y.begin(); - _Ip __ey = __y.end(); - for (; __ix != __ex && __iy != __ey; ++__ix, ++__iy) - if (!(*__ix == *__iy)) - return false; - return (__ix == __ex) == (__iy == __ey); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator!=(const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator< (const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - return _VSTD::lexicographical_compare(__x.begin(), __x.end(), - __y.begin(), __y.end()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator> (const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator>=(const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator<=(const forward_list<_Tp, _Alloc>& __x, - const forward_list<_Tp, _Alloc>& __y) -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(forward_list<_Tp, _Alloc>& __x, forward_list<_Tp, _Alloc>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_FORWARD_LIST diff --git a/libcxx/include/fstream b/libcxx/include/fstream deleted file mode 100644 index 8e1b1fb69e25..000000000000 --- a/libcxx/include/fstream +++ /dev/null @@ -1,1398 +0,0 @@ -// -*- C++ -*- -//===------------------------- fstream ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FSTREAM -#define _LIBCPP_FSTREAM - -/* - fstream synopsis - -template > -class basic_filebuf - : public basic_streambuf -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - // 27.9.1.2 Constructors/destructor: - basic_filebuf(); - basic_filebuf(basic_filebuf&& rhs); - virtual ~basic_filebuf(); - - // 27.9.1.3 Assign/swap: - basic_filebuf& operator=(basic_filebuf&& rhs); - void swap(basic_filebuf& rhs); - - // 27.9.1.4 Members: - bool is_open() const; - basic_filebuf* open(const char* s, ios_base::openmode mode); - basic_filebuf* open(const string& s, ios_base::openmode mode); - basic_filebuf* close(); - -protected: - // 27.9.1.5 Overridden virtual functions: - virtual streamsize showmanyc(); - virtual int_type underflow(); - virtual int_type uflow(); - virtual int_type pbackfail(int_type c = traits_type::eof()); - virtual int_type overflow (int_type c = traits_type::eof()); - virtual basic_streambuf* setbuf(char_type* s, streamsize n); - virtual pos_type seekoff(off_type off, ios_base::seekdir way, - ios_base::openmode which = ios_base::in | ios_base::out); - virtual pos_type seekpos(pos_type sp, - ios_base::openmode which = ios_base::in | ios_base::out); - virtual int sync(); - virtual void imbue(const locale& loc); -}; - -template - void - swap(basic_filebuf& x, basic_filebuf& y); - -typedef basic_filebuf filebuf; -typedef basic_filebuf wfilebuf; - -template > -class basic_ifstream - : public basic_istream -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_ifstream(); - explicit basic_ifstream(const char* s, ios_base::openmode mode = ios_base::in); - explicit basic_ifstream(const string& s, ios_base::openmode mode = ios_base::in); - basic_ifstream(basic_ifstream&& rhs); - - basic_ifstream& operator=(basic_ifstream&& rhs); - void swap(basic_ifstream& rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* s, ios_base::openmode mode = ios_base::in); - void open(const string& s, ios_base::openmode mode = ios_base::in); - void close(); -}; - -template - void - swap(basic_ifstream& x, basic_ifstream& y); - -typedef basic_ifstream ifstream; -typedef basic_ifstream wifstream; - -template > -class basic_ofstream - : public basic_ostream -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_ofstream(); - explicit basic_ofstream(const char* s, ios_base::openmode mode = ios_base::out); - explicit basic_ofstream(const string& s, ios_base::openmode mode = ios_base::out); - basic_ofstream(basic_ofstream&& rhs); - - basic_ofstream& operator=(basic_ofstream&& rhs); - void swap(basic_ofstream& rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* s, ios_base::openmode mode = ios_base::out); - void open(const string& s, ios_base::openmode mode = ios_base::out); - void close(); -}; - -template - void - swap(basic_ofstream& x, basic_ofstream& y); - -typedef basic_ofstream ofstream; -typedef basic_ofstream wofstream; - -template > -class basic_fstream - : public basic_iostream -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_fstream(); - explicit basic_fstream(const char* s, ios_base::openmode mode = ios_base::in|ios_base::out); - explicit basic_fstream(const string& s, ios_base::openmode mode = ios_base::in|ios_base::out); - basic_fstream(basic_fstream&& rhs); - - basic_fstream& operator=(basic_fstream&& rhs); - void swap(basic_fstream& rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* s, ios_base::openmode mode = ios_base::in|ios_base::out); - void open(const string& s, ios_base::openmode mode = ios_base::in|ios_base::out); - void close(); -}; - -template - void swap(basic_fstream& x, basic_fstream& y); - -typedef basic_fstream fstream; -typedef basic_fstream wfstream; - -} // std - -*/ - -#include <__config> -#include -#include -#include <__locale> -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -class _LIBCPP_VISIBLE basic_filebuf - : public basic_streambuf<_CharT, _Traits> -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - typedef typename traits_type::state_type state_type; - - // 27.9.1.2 Constructors/destructor: - basic_filebuf(); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_filebuf(basic_filebuf&& __rhs); -#endif - virtual ~basic_filebuf(); - - // 27.9.1.3 Assign/swap: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_filebuf& operator=(basic_filebuf&& __rhs); -#endif - void swap(basic_filebuf& __rhs); - - // 27.9.1.4 Members: - bool is_open() const; - basic_filebuf* open(const char* __s, ios_base::openmode __mode); - basic_filebuf* open(const string& __s, ios_base::openmode __mode); - basic_filebuf* close(); - -protected: - // 27.9.1.5 Overridden virtual functions: - virtual int_type underflow(); - virtual int_type pbackfail(int_type __c = traits_type::eof()); - virtual int_type overflow (int_type __c = traits_type::eof()); - virtual basic_streambuf* setbuf(char_type* __s, streamsize __n); - virtual pos_type seekoff(off_type __off, ios_base::seekdir __way, - ios_base::openmode __wch = ios_base::in | ios_base::out); - virtual pos_type seekpos(pos_type __sp, - ios_base::openmode __wch = ios_base::in | ios_base::out); - virtual int sync(); - virtual void imbue(const locale& __loc); - -private: - char* __extbuf_; - const char* __extbufnext_; - const char* __extbufend_; - char __extbuf_min_[8]; - size_t __ebs_; - char_type* __intbuf_; - size_t __ibs_; - FILE* __file_; - const codecvt* __cv_; - state_type __st_; - ios_base::openmode __om_; - ios_base::openmode __cm_; - bool __owns_eb_; - bool __owns_ib_; - bool __always_noconv_; - - bool __read_mode(); - void __write_mode(); -}; - -template -basic_filebuf<_CharT, _Traits>::basic_filebuf() - : __extbuf_(0), - __extbufnext_(0), - __extbufend_(0), - __ebs_(0), - __intbuf_(0), - __ibs_(0), - __file_(0), - __cv_(&use_facet >(this->getloc())), - __st_(), - __om_(0), - __cm_(0), - __owns_eb_(false), - __owns_ib_(false), - __always_noconv_(__cv_->always_noconv()) -{ - setbuf(0, 4096); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -basic_filebuf<_CharT, _Traits>::basic_filebuf(basic_filebuf&& __rhs) - : basic_streambuf<_CharT, _Traits>(__rhs) -{ - if (__rhs.__extbuf_ == __rhs.__extbuf_min_) - { - __extbuf_ = __extbuf_min_; - __extbufnext_ = __extbuf_ + (__rhs.__extbufnext_ - __rhs.__extbuf_); - __extbufend_ = __extbuf_ + (__rhs.__extbufend_ - __rhs.__extbuf_); - } - else - { - __extbuf_ = __rhs.__extbuf_; - __extbufnext_ = __rhs.__extbufnext_; - __extbufend_ = __rhs.__extbufend_; - } - __ebs_ = __rhs.__ebs_; - __intbuf_ = __rhs.__intbuf_; - __ibs_ = __rhs.__ibs_; - __file_ = __rhs.__file_; - __cv_ = __rhs.__cv_; - __st_ = __rhs.__st_; - __om_ = __rhs.__om_; - __cm_ = __rhs.__cm_; - __owns_eb_ = __rhs.__owns_eb_; - __owns_ib_ = __rhs.__owns_ib_; - __always_noconv_ = __rhs.__always_noconv_; - if (__rhs.pbase()) - { - if (__rhs.pbase() == __rhs.__intbuf_) - this->setp(__intbuf_, __intbuf_ + (__rhs. epptr() - __rhs.pbase())); - else - this->setp((char_type*)__extbuf_, - (char_type*)__extbuf_ + (__rhs. epptr() - __rhs.pbase())); - this->pbump(__rhs. pptr() - __rhs.pbase()); - } - else if (__rhs.eback()) - { - if (__rhs.eback() == __rhs.__intbuf_) - this->setg(__intbuf_, __intbuf_ + (__rhs.gptr() - __rhs.eback()), - __intbuf_ + (__rhs.egptr() - __rhs.eback())); - else - this->setg((char_type*)__extbuf_, - (char_type*)__extbuf_ + (__rhs.gptr() - __rhs.eback()), - (char_type*)__extbuf_ + (__rhs.egptr() - __rhs.eback())); - } - __rhs.__extbuf_ = 0; - __rhs.__extbufnext_ = 0; - __rhs.__extbufend_ = 0; - __rhs.__ebs_ = 0; - __rhs.__intbuf_ = 0; - __rhs.__ibs_ = 0; - __rhs.__file_ = 0; - __rhs.__st_ = state_type(); - __rhs.__om_ = 0; - __rhs.__cm_ = 0; - __rhs.__owns_eb_ = false; - __rhs.__owns_ib_ = false; - __rhs.setg(0, 0, 0); - __rhs.setp(0, 0); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_filebuf<_CharT, _Traits>& -basic_filebuf<_CharT, _Traits>::operator=(basic_filebuf&& __rhs) -{ - close(); - swap(__rhs); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -basic_filebuf<_CharT, _Traits>::~basic_filebuf() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - close(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - } -#endif // _LIBCPP_NO_EXCEPTIONS - if (__owns_eb_) - delete [] __extbuf_; - if (__owns_ib_) - delete [] __intbuf_; -} - -template -void -basic_filebuf<_CharT, _Traits>::swap(basic_filebuf& __rhs) -{ - basic_streambuf::swap(__rhs); - if (__extbuf_ != __extbuf_min_ && __rhs.__extbuf_ != __rhs.__extbuf_min_) - { - _VSTD::swap(__extbuf_, __rhs.__extbuf_); - _VSTD::swap(__extbufnext_, __rhs.__extbufnext_); - _VSTD::swap(__extbufend_, __rhs.__extbufend_); - } - else - { - ptrdiff_t __ln = __extbufnext_ - __extbuf_; - ptrdiff_t __le = __extbufend_ - __extbuf_; - ptrdiff_t __rn = __rhs.__extbufnext_ - __rhs.__extbuf_; - ptrdiff_t __re = __rhs.__extbufend_ - __rhs.__extbuf_; - if (__extbuf_ == __extbuf_min_ && __rhs.__extbuf_ != __rhs.__extbuf_min_) - { - __extbuf_ = __rhs.__extbuf_; - __rhs.__extbuf_ = __rhs.__extbuf_min_; - } - else if (__extbuf_ != __extbuf_min_ && __rhs.__extbuf_ == __rhs.__extbuf_min_) - { - __rhs.__extbuf_ = __extbuf_; - __extbuf_ = __extbuf_min_; - } - __extbufnext_ = __extbuf_ + __rn; - __extbufend_ = __extbuf_ + __re; - __rhs.__extbufnext_ = __rhs.__extbuf_ + __ln; - __rhs.__extbufend_ = __rhs.__extbuf_ + __le; - } - _VSTD::swap(__ebs_, __rhs.__ebs_); - _VSTD::swap(__intbuf_, __rhs.__intbuf_); - _VSTD::swap(__ibs_, __rhs.__ibs_); - _VSTD::swap(__file_, __rhs.__file_); - _VSTD::swap(__cv_, __rhs.__cv_); - _VSTD::swap(__st_, __rhs.__st_); - _VSTD::swap(__om_, __rhs.__om_); - _VSTD::swap(__cm_, __rhs.__cm_); - _VSTD::swap(__owns_eb_, __rhs.__owns_eb_); - _VSTD::swap(__owns_ib_, __rhs.__owns_ib_); - _VSTD::swap(__always_noconv_, __rhs.__always_noconv_); - if (this->eback() == (char_type*)__rhs.__extbuf_min_) - { - ptrdiff_t __n = this->gptr() - this->eback(); - ptrdiff_t __e = this->egptr() - this->eback(); - this->setg((char_type*)__extbuf_min_, - (char_type*)__extbuf_min_ + __n, - (char_type*)__extbuf_min_ + __e); - } - else if (this->pbase() == (char_type*)__rhs.__extbuf_min_) - { - ptrdiff_t __n = this->pptr() - this->pbase(); - ptrdiff_t __e = this->epptr() - this->pbase(); - this->setp((char_type*)__extbuf_min_, - (char_type*)__extbuf_min_ + __e); - this->pbump(__n); - } - if (__rhs.eback() == (char_type*)__extbuf_min_) - { - ptrdiff_t __n = __rhs.gptr() - __rhs.eback(); - ptrdiff_t __e = __rhs.egptr() - __rhs.eback(); - __rhs.setg((char_type*)__rhs.__extbuf_min_, - (char_type*)__rhs.__extbuf_min_ + __n, - (char_type*)__rhs.__extbuf_min_ + __e); - } - else if (__rhs.pbase() == (char_type*)__extbuf_min_) - { - ptrdiff_t __n = __rhs.pptr() - __rhs.pbase(); - ptrdiff_t __e = __rhs.epptr() - __rhs.pbase(); - __rhs.setp((char_type*)__rhs.__extbuf_min_, - (char_type*)__rhs.__extbuf_min_ + __e); - __rhs.pbump(__n); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(basic_filebuf<_CharT, _Traits>& __x, basic_filebuf<_CharT, _Traits>& __y) -{ - __x.swap(__y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -basic_filebuf<_CharT, _Traits>::is_open() const -{ - return __file_ != 0; -} - -template -basic_filebuf<_CharT, _Traits>* -basic_filebuf<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode) -{ - basic_filebuf<_CharT, _Traits>* __rt = 0; - if (__file_ == 0) - { - __rt = this; - const char* __mdstr; - switch (__mode & ~ios_base::ate) - { - case ios_base::out: - case ios_base::out | ios_base::trunc: - __mdstr = "w"; - break; - case ios_base::out | ios_base::app: - case ios_base::app: - __mdstr = "a"; - break; - case ios_base::in: - __mdstr = "r"; - break; - case ios_base::in | ios_base::out: - __mdstr = "r+"; - break; - case ios_base::in | ios_base::out | ios_base::trunc: - __mdstr = "w+"; - break; - case ios_base::in | ios_base::out | ios_base::app: - case ios_base::in | ios_base::app: - __mdstr = "a+"; - break; - case ios_base::out | ios_base::binary: - case ios_base::out | ios_base::trunc | ios_base::binary: - __mdstr = "wb"; - break; - case ios_base::out | ios_base::app | ios_base::binary: - case ios_base::app | ios_base::binary: - __mdstr = "ab"; - break; - case ios_base::in | ios_base::binary: - __mdstr = "rb"; - break; - case ios_base::in | ios_base::out | ios_base::binary: - __mdstr = "r+b"; - break; - case ios_base::in | ios_base::out | ios_base::trunc | ios_base::binary: - __mdstr = "w+b"; - break; - case ios_base::in | ios_base::out | ios_base::app | ios_base::binary: - case ios_base::in | ios_base::app | ios_base::binary: - __mdstr = "a+b"; - break; - default: - __rt = 0; - break; - } - if (__rt) - { - __file_ = fopen(__s, __mdstr); - if (__file_) - { - __om_ = __mode; - if (__mode & ios_base::ate) - { - if (fseek(__file_, 0, SEEK_END)) - { - fclose(__file_); - __file_ = 0; - __rt = 0; - } - } - } - else - __rt = 0; - } - } - return __rt; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_filebuf<_CharT, _Traits>* -basic_filebuf<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mode) -{ - return open(__s.c_str(), __mode); -} - -template -basic_filebuf<_CharT, _Traits>* -basic_filebuf<_CharT, _Traits>::close() -{ - basic_filebuf<_CharT, _Traits>* __rt = 0; - if (__file_) - { - __rt = this; - unique_ptr __h(__file_, fclose); - if (sync()) - __rt = 0; - if (fclose(__h.release()) == 0) - __file_ = 0; - else - __rt = 0; - } - return __rt; -} - -template -typename basic_filebuf<_CharT, _Traits>::int_type -basic_filebuf<_CharT, _Traits>::underflow() -{ - if (__file_ == 0) - return traits_type::eof(); - bool __initial = __read_mode(); - char_type __1buf; - if (this->gptr() == 0) - this->setg(&__1buf, &__1buf+1, &__1buf+1); - const size_t __unget_sz = __initial ? 0 : min((this->egptr() - this->eback()) / 2, 4); - int_type __c = traits_type::eof(); - if (this->gptr() == this->egptr()) - { - memmove(this->eback(), this->egptr() - __unget_sz, __unget_sz * sizeof(char_type)); - if (__always_noconv_) - { - size_t __nmemb = static_cast(this->egptr() - this->eback() - __unget_sz); - __nmemb = fread(this->eback() + __unget_sz, 1, __nmemb, __file_); - if (__nmemb != 0) - { - this->setg(this->eback(), - this->eback() + __unget_sz, - this->eback() + __unget_sz + __nmemb); - __c = traits_type::to_int_type(*this->gptr()); - } - } - else - { - memmove(__extbuf_, __extbufnext_, __extbufend_ - __extbufnext_); - __extbufnext_ = __extbuf_ + (__extbufend_ - __extbufnext_); - __extbufend_ = __extbuf_ + (__extbuf_ == __extbuf_min_ ? sizeof(__extbuf_min_) : __ebs_); - size_t __nmemb = _VSTD::min(static_cast(this->egptr() - this->eback() - __unget_sz), - static_cast(__extbufend_ - __extbufnext_)); - codecvt_base::result __r; - state_type __svs = __st_; - size_t __nr = fread((void*)__extbufnext_, 1, __nmemb, __file_); - if (__nr != 0) - { - __extbufend_ = __extbufnext_ + __nr; - char_type* __inext; - __r = __cv_->in(__st_, __extbuf_, __extbufend_, __extbufnext_, - this->eback() + __unget_sz, - this->egptr(), __inext); - if (__r == codecvt_base::noconv) - { - this->setg((char_type*)__extbuf_, (char_type*)__extbuf_, (char_type*)__extbufend_); - __c = traits_type::to_int_type(*this->gptr()); - } - else if (__inext != this->eback() + __unget_sz) - { - this->setg(this->eback(), this->eback() + __unget_sz, __inext); - __c = traits_type::to_int_type(*this->gptr()); - } - } - } - } - else - __c = traits_type::to_int_type(*this->gptr()); - if (this->eback() == &__1buf) - this->setg(0, 0, 0); - return __c; -} - -template -typename basic_filebuf<_CharT, _Traits>::int_type -basic_filebuf<_CharT, _Traits>::pbackfail(int_type __c) -{ - if (__file_ && this->eback() < this->gptr()) - { - if (traits_type::eq_int_type(__c, traits_type::eof())) - { - this->gbump(-1); - return traits_type::not_eof(__c); - } - if ((__om_ & ios_base::out) || - traits_type::eq(traits_type::to_char_type(__c), this->gptr()[-1])) - { - this->gbump(-1); - *this->gptr() = traits_type::to_char_type(__c); - return __c; - } - } - return traits_type::eof(); -} - -template -typename basic_filebuf<_CharT, _Traits>::int_type -basic_filebuf<_CharT, _Traits>::overflow(int_type __c) -{ - if (__file_ == 0) - return traits_type::eof(); - __write_mode(); - char_type __1buf; - char_type* __pb_save = this->pbase(); - char_type* __epb_save = this->epptr(); - if (!traits_type::eq_int_type(__c, traits_type::eof())) - { - if (this->pptr() == 0) - this->setp(&__1buf, &__1buf+1); - *this->pptr() = traits_type::to_char_type(__c); - this->pbump(1); - } - if (this->pptr() != this->pbase()) - { - if (__always_noconv_) - { - size_t __nmemb = static_cast(this->pptr() - this->pbase()); - if (fwrite(this->pbase(), sizeof(char_type), __nmemb, __file_) != __nmemb) - return traits_type::eof(); - } - else - { - char* __extbe = __extbuf_; - codecvt_base::result __r; - do - { - const char_type* __e; - __r = __cv_->out(__st_, this->pbase(), this->pptr(), __e, - __extbuf_, __extbuf_ + __ebs_, __extbe); - if (__e == this->pbase()) - return traits_type::eof(); - if (__r == codecvt_base::noconv) - { - size_t __nmemb = static_cast(this->pptr() - this->pbase()); - if (fwrite(this->pbase(), 1, __nmemb, __file_) != __nmemb) - return traits_type::eof(); - } - else if (__r == codecvt_base::ok || __r == codecvt_base::partial) - { - size_t __nmemb = static_cast(__extbe - __extbuf_); - if (fwrite(__extbuf_, 1, __nmemb, __file_) != __nmemb) - return traits_type::eof(); - if (__r == codecvt_base::partial) - { - this->setp((char_type*)__e, this->pptr()); - this->pbump(this->epptr() - this->pbase()); - } - } - else - return traits_type::eof(); - } while (__r == codecvt_base::partial); - } - this->setp(__pb_save, __epb_save); - } - return traits_type::not_eof(__c); -} - -template -basic_streambuf<_CharT, _Traits>* -basic_filebuf<_CharT, _Traits>::setbuf(char_type* __s, streamsize __n) -{ - this->setg(0, 0, 0); - this->setp(0, 0); - if (__owns_eb_) - delete [] __extbuf_; - if (__owns_ib_) - delete [] __intbuf_; - __ebs_ = __n; - if (__ebs_ > sizeof(__extbuf_min_)) - { - if (__always_noconv_ && __s) - { - __extbuf_ = (char*)__s; - __owns_eb_ = false; - } - else - { - __extbuf_ = new char[__ebs_]; - __owns_eb_ = true; - } - } - else - { - __extbuf_ = __extbuf_min_; - __ebs_ = sizeof(__extbuf_min_); - __owns_eb_ = false; - } - if (!__always_noconv_) - { - __ibs_ = max(__n, sizeof(__extbuf_min_)); - if (__s && __ibs_ >= sizeof(__extbuf_min_)) - { - __intbuf_ = __s; - __owns_ib_ = false; - } - else - { - __intbuf_ = new char_type[__ibs_]; - __owns_ib_ = true; - } - } - else - { - __ibs_ = 0; - __intbuf_ = 0; - __owns_ib_ = false; - } - return this; -} - -template -typename basic_filebuf<_CharT, _Traits>::pos_type -basic_filebuf<_CharT, _Traits>::seekoff(off_type __off, ios_base::seekdir __way, - ios_base::openmode) -{ - int __width = __cv_->encoding(); - if (__file_ == 0 || (__width <= 0 && __off != 0) || sync()) - return pos_type(off_type(-1)); - // __width > 0 || __off == 0 - int __whence; - switch (__way) - { - case ios_base::beg: - __whence = SEEK_SET; - break; - case ios_base::cur: - __whence = SEEK_CUR; - break; - case ios_base::end: - __whence = SEEK_END; - break; - default: - return pos_type(off_type(-1)); - } - if (fseeko(__file_, __width > 0 ? __width * __off : 0, __whence)) - return pos_type(off_type(-1)); - pos_type __r = ftello(__file_); - __r.state(__st_); - return __r; -} - -template -typename basic_filebuf<_CharT, _Traits>::pos_type -basic_filebuf<_CharT, _Traits>::seekpos(pos_type __sp, ios_base::openmode) -{ - if (__file_ == 0 || sync()) - return pos_type(off_type(-1)); - if (fseeko(__file_, __sp, SEEK_SET)) - return pos_type(off_type(-1)); - return __sp; -} - -template -int -basic_filebuf<_CharT, _Traits>::sync() -{ - if (__file_ == 0) - return 0; - if (__cm_ & ios_base::out) - { - if (this->pptr() != this->pbase()) - if (overflow() == traits_type::eof()) - return -1; - codecvt_base::result __r; - do - { - char* __extbe; - __r = __cv_->unshift(__st_, __extbuf_, __extbuf_ + __ebs_, __extbe); - size_t __nmemb = static_cast(__extbe - __extbuf_); - if (fwrite(__extbuf_, 1, __nmemb, __file_) != __nmemb) - return -1; - } while (__r == codecvt_base::partial); - if (__r == codecvt_base::error) - return -1; - if (fflush(__file_)) - return -1; - } - else if (__cm_ & ios_base::in) - { - off_type __c; - if (__always_noconv_) - __c = this->egptr() - this->gptr(); - else - { - int __width = __cv_->encoding(); - __c = __extbufend_ - __extbufnext_; - if (__width > 0) - __c += __width * (this->egptr() - this->gptr()); - else - { - if (this->gptr() != this->egptr()) - { - reverse(this->gptr(), this->egptr()); - codecvt_base::result __r; - const char_type* __e = this->gptr(); - char* __extbe; - do - { - __r = __cv_->out(__st_, __e, this->egptr(), __e, - __extbuf_, __extbuf_ + __ebs_, __extbe); - switch (__r) - { - case codecvt_base::noconv: - __c += this->egptr() - this->gptr(); - break; - case codecvt_base::ok: - case codecvt_base::partial: - __c += __extbe - __extbuf_; - break; - default: - return -1; - } - } while (__r == codecvt_base::partial); - } - } - } - if (fseeko(__file_, -__c, SEEK_CUR)) - return -1; - this->setg(0, 0, 0); - __cm_ = 0; - } - return 0; -} - -template -void -basic_filebuf<_CharT, _Traits>::imbue(const locale& __loc) -{ - sync(); - __cv_ = &use_facet >(__loc); - bool __old_anc = __always_noconv_; - __always_noconv_ = __cv_->always_noconv(); - if (__old_anc != __always_noconv_) - { - this->setg(0, 0, 0); - this->setp(0, 0); - // invariant, char_type is char, else we couldn't get here - if (__always_noconv_) // need to dump __intbuf_ - { - if (__owns_eb_) - delete [] __extbuf_; - __owns_eb_ = __owns_ib_; - __ebs_ = __ibs_; - __extbuf_ = (char*)__intbuf_; - __ibs_ = 0; - __intbuf_ = 0; - __owns_ib_ = false; - } - else // need to obtain an __intbuf_. - { // If __extbuf_ is user-supplied, use it, else new __intbuf_ - if (!__owns_eb_ && __extbuf_ != __extbuf_min_) - { - __ibs_ = __ebs_; - __intbuf_ = (char_type*)__extbuf_; - __owns_ib_ = false; - __extbuf_ = new char[__ebs_]; - __owns_eb_ = true; - } - else - { - __ibs_ = __ebs_; - __intbuf_ = new char_type[__ibs_]; - __owns_ib_ = true; - } - } - } -} - -template -bool -basic_filebuf<_CharT, _Traits>::__read_mode() -{ - if (!(__cm_ & ios_base::in)) - { - this->setp(0, 0); - if (__always_noconv_) - this->setg((char_type*)__extbuf_, - (char_type*)__extbuf_ + __ebs_, - (char_type*)__extbuf_ + __ebs_); - else - this->setg(__intbuf_, __intbuf_ + __ibs_, __intbuf_ + __ibs_); - __cm_ = ios_base::in; - return true; - } - return false; -} - -template -void -basic_filebuf<_CharT, _Traits>::__write_mode() -{ - if (!(__cm_ & ios_base::out)) - { - this->setg(0, 0, 0); - if (__ebs_ > sizeof(__extbuf_min_)) - { - if (__always_noconv_) - this->setp((char_type*)__extbuf_, - (char_type*)__extbuf_ + (__ebs_ - 1)); - else - this->setp(__intbuf_, __intbuf_ + (__ibs_ - 1)); - } - else - this->setp(0, 0); - __cm_ = ios_base::out; - } -} - -// basic_ifstream - -template -class _LIBCPP_VISIBLE basic_ifstream - : public basic_istream<_CharT, _Traits> -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_ifstream(); - explicit basic_ifstream(const char* __s, ios_base::openmode __mode = ios_base::in); - explicit basic_ifstream(const string& __s, ios_base::openmode __mode = ios_base::in); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_ifstream(basic_ifstream&& __rhs); -#endif - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_ifstream& operator=(basic_ifstream&& __rhs); -#endif - void swap(basic_ifstream& __rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* __s, ios_base::openmode __mode = ios_base::in); - void open(const string& __s, ios_base::openmode __mode = ios_base::in); - void close(); - -private: - basic_filebuf __sb_; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ifstream<_CharT, _Traits>::basic_ifstream() - : basic_istream(&__sb_) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ifstream<_CharT, _Traits>::basic_ifstream(const char* __s, ios_base::openmode __mode) - : basic_istream(&__sb_) -{ - if (__sb_.open(__s, __mode | ios_base::in) == 0) - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ifstream<_CharT, _Traits>::basic_ifstream(const string& __s, ios_base::openmode __mode) - : basic_istream(&__sb_) -{ - if (__sb_.open(__s, __mode | ios_base::in) == 0) - this->setstate(ios_base::failbit); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ifstream<_CharT, _Traits>::basic_ifstream(basic_ifstream&& __rhs) - : basic_istream(_VSTD::move(__rhs)), - __sb_(_VSTD::move(__rhs.__sb_)) -{ - this->set_rdbuf(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ifstream<_CharT, _Traits>& -basic_ifstream<_CharT, _Traits>::operator=(basic_ifstream&& __rhs) -{ - basic_istream::operator=(_VSTD::move(__rhs)); - __sb_ = _VSTD::move(__rhs.__sb_); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ifstream<_CharT, _Traits>::swap(basic_ifstream& __rhs) -{ - basic_istream::swap(__rhs); - __sb_.swap(__rhs.__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(basic_ifstream<_CharT, _Traits>& __x, basic_ifstream<_CharT, _Traits>& __y) -{ - __x.swap(__y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_filebuf<_CharT, _Traits>* -basic_ifstream<_CharT, _Traits>::rdbuf() const -{ - return const_cast*>(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -basic_ifstream<_CharT, _Traits>::is_open() const -{ - return __sb_.is_open(); -} - -template -void -basic_ifstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode | ios_base::in)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -void -basic_ifstream<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode | ios_base::in)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ifstream<_CharT, _Traits>::close() -{ - if (__sb_.close() == 0) - this->setstate(ios_base::failbit); -} - -// basic_ofstream - -template -class _LIBCPP_VISIBLE basic_ofstream - : public basic_ostream<_CharT, _Traits> -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_ofstream(); - explicit basic_ofstream(const char* __s, ios_base::openmode __mode = ios_base::out); - explicit basic_ofstream(const string& __s, ios_base::openmode __mode = ios_base::out); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_ofstream(basic_ofstream&& __rhs); -#endif - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_ofstream& operator=(basic_ofstream&& __rhs); -#endif - void swap(basic_ofstream& __rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* __s, ios_base::openmode __mode = ios_base::out); - void open(const string& __s, ios_base::openmode __mode = ios_base::out); - void close(); - -private: - basic_filebuf __sb_; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ofstream<_CharT, _Traits>::basic_ofstream() - : basic_ostream(&__sb_) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ofstream<_CharT, _Traits>::basic_ofstream(const char* __s, ios_base::openmode __mode) - : basic_ostream(&__sb_) -{ - if (__sb_.open(__s, __mode | ios_base::out) == 0) - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ofstream<_CharT, _Traits>::basic_ofstream(const string& __s, ios_base::openmode __mode) - : basic_ostream(&__sb_) -{ - if (__sb_.open(__s, __mode | ios_base::out) == 0) - this->setstate(ios_base::failbit); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ofstream<_CharT, _Traits>::basic_ofstream(basic_ofstream&& __rhs) - : basic_ostream(_VSTD::move(__rhs)), - __sb_(_VSTD::move(__rhs.__sb_)) -{ - this->set_rdbuf(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ofstream<_CharT, _Traits>& -basic_ofstream<_CharT, _Traits>::operator=(basic_ofstream&& __rhs) -{ - basic_ostream::operator=(_VSTD::move(__rhs)); - __sb_ = _VSTD::move(__rhs.__sb_); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ofstream<_CharT, _Traits>::swap(basic_ofstream& __rhs) -{ - basic_ostream::swap(__rhs); - __sb_.swap(__rhs.__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(basic_ofstream<_CharT, _Traits>& __x, basic_ofstream<_CharT, _Traits>& __y) -{ - __x.swap(__y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_filebuf<_CharT, _Traits>* -basic_ofstream<_CharT, _Traits>::rdbuf() const -{ - return const_cast*>(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -basic_ofstream<_CharT, _Traits>::is_open() const -{ - return __sb_.is_open(); -} - -template -void -basic_ofstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode | ios_base::out)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -void -basic_ofstream<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode | ios_base::out)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ofstream<_CharT, _Traits>::close() -{ - if (__sb_.close() == 0) - this->setstate(ios_base::failbit); -} - -// basic_fstream - -template -class _LIBCPP_VISIBLE basic_fstream - : public basic_iostream<_CharT, _Traits> -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - basic_fstream(); - explicit basic_fstream(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out); - explicit basic_fstream(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_fstream(basic_fstream&& __rhs); -#endif - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - basic_fstream& operator=(basic_fstream&& __rhs); -#endif - void swap(basic_fstream& __rhs); - - basic_filebuf* rdbuf() const; - bool is_open() const; - void open(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out); - void open(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out); - void close(); - -private: - basic_filebuf __sb_; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_fstream<_CharT, _Traits>::basic_fstream() - : basic_iostream(&__sb_) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_fstream<_CharT, _Traits>::basic_fstream(const char* __s, ios_base::openmode __mode) - : basic_iostream(&__sb_) -{ - if (__sb_.open(__s, __mode) == 0) - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_fstream<_CharT, _Traits>::basic_fstream(const string& __s, ios_base::openmode __mode) - : basic_iostream(&__sb_) -{ - if (__sb_.open(__s, __mode) == 0) - this->setstate(ios_base::failbit); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_fstream<_CharT, _Traits>::basic_fstream(basic_fstream&& __rhs) - : basic_iostream(_VSTD::move(__rhs)), - __sb_(_VSTD::move(__rhs.__sb_)) -{ - this->set_rdbuf(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_fstream<_CharT, _Traits>& -basic_fstream<_CharT, _Traits>::operator=(basic_fstream&& __rhs) -{ - basic_iostream::operator=(_VSTD::move(__rhs)); - __sb_ = _VSTD::move(__rhs.__sb_); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_fstream<_CharT, _Traits>::swap(basic_fstream& __rhs) -{ - basic_iostream::swap(__rhs); - __sb_.swap(__rhs.__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(basic_fstream<_CharT, _Traits>& __x, basic_fstream<_CharT, _Traits>& __y) -{ - __x.swap(__y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_filebuf<_CharT, _Traits>* -basic_fstream<_CharT, _Traits>::rdbuf() const -{ - return const_cast*>(&__sb_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -basic_fstream<_CharT, _Traits>::is_open() const -{ - return __sb_.is_open(); -} - -template -void -basic_fstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -void -basic_fstream<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mode) -{ - if (__sb_.open(__s, __mode)) - this->clear(); - else - this->setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_fstream<_CharT, _Traits>::close() -{ - if (__sb_.close() == 0) - this->setstate(ios_base::failbit); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_FSTREAM diff --git a/libcxx/include/functional b/libcxx/include/functional deleted file mode 100644 index 884a57773514..000000000000 --- a/libcxx/include/functional +++ /dev/null @@ -1,2020 +0,0 @@ -// -*- C++ -*- -//===------------------------ functional ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FUNCTIONAL -#define _LIBCPP_FUNCTIONAL - -/* - functional synopsis - -namespace std -{ - -template -struct unary_function -{ - typedef Arg argument_type; - typedef Result result_type; -}; - -template -struct binary_function -{ - typedef Arg1 first_argument_type; - typedef Arg2 second_argument_type; - typedef Result result_type; -}; - -template -class reference_wrapper - : public unary_function // if wrapping a unary functor - : public binary_function // if wraping a binary functor -{ -public: - // types - typedef T type; - typedef see below result_type; // Not always defined - - // construct/copy/destroy - reference_wrapper(T&) noexcept; - reference_wrapper(T&&) = delete; // do not bind to temps - reference_wrapper(const reference_wrapper& x) noexcept; - - // assignment - reference_wrapper& operator=(const reference_wrapper& x) noexcept; - - // access - operator T& () const noexcept; - T& get() const noexcept; - - // invoke - template - typename result_of::type - operator() (ArgTypes&&...) const; -}; - -template reference_wrapper ref(T& t) noexcept; -template void ref(const T&& t) = delete; -template reference_wrapper ref(reference_wrappert) noexcept; - -template reference_wrapper cref(const T& t) noexcept; -template void cref(const T&& t) = delete; -template reference_wrapper cref(reference_wrapper t) noexcept; - -template -struct plus : binary_function -{ - T operator()(const T& x, const T& y) const; -}; - -template -struct minus : binary_function -{ - T operator()(const T& x, const T& y) const; -}; - -template -struct multiplies : binary_function -{ - T operator()(const T& x, const T& y) const; -}; - -template -struct divides : binary_function -{ - T operator()(const T& x, const T& y) const; -}; - -template -struct modulus : binary_function -{ - T operator()(const T& x, const T& y) const; -}; - -template -struct negate : unary_function -{ - T operator()(const T& x) const; -}; - -template -struct equal_to : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct not_equal_to : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct greater : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct less : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct greater_equal : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct less_equal : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct logical_and : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct logical_or : binary_function -{ - bool operator()(const T& x, const T& y) const; -}; - -template -struct logical_not : unary_function -{ - bool operator()(const T& x) const; -}; - -template -class unary_negate - : public unary_function -{ -public: - explicit unary_negate(const Predicate& pred); - bool operator()(const typename Predicate::argument_type& x) const; -}; - -template unary_negate not1(const Predicate& pred); - -template -class binary_negate - : public binary_function -{ -public: - explicit binary_negate(const Predicate& pred); - bool operator()(const typename Predicate::first_argument_type& x, - const typename Predicate::second_argument_type& y) const; -}; - -template binary_negate not2(const Predicate& pred); - -template struct is_bind_expression; -template struct is_placeholder; - -template - unspecified bind(Fn&&, BoundArgs&&...); -template - unspecified bind(Fn&&, BoundArgs&&...); - -namespace placeholders { - // M is the implementation-defined number of placeholders - extern unspecified _1; - extern unspecified _2; - . - . - . - extern unspecified _Mp; -} - -template -class binder1st - : public unary_function -{ -protected: - Operation op; - typename Operation::first_argument_type value; -public: - binder1st(const Operation& x, const typename Operation::first_argument_type y); - typename Operation::result_type operator()( typename Operation::second_argument_type& x) const; - typename Operation::result_type operator()(const typename Operation::second_argument_type& x) const; -}; - -template -binder1st bind1st(const Operation& op, const T& x); - -template -class binder2nd - : public unary_function -{ -protected: - Operation op; - typename Operation::second_argument_type value; -public: - binder2nd(const Operation& x, const typename Operation::second_argument_type y); - typename Operation::result_type operator()( typename Operation::first_argument_type& x) const; - typename Operation::result_type operator()(const typename Operation::first_argument_type& x) const; -}; - -template -binder2nd bind2nd(const Operation& op, const T& x); - -template -class pointer_to_unary_function : public unary_function -{ -public: - explicit pointer_to_unary_function(Result (*f)(Arg)); - Result operator()(Arg x) const; -}; - -template -pointer_to_unary_function ptr_fun(Result (*f)(Arg)); - -template -class pointer_to_binary_function : public binary_function -{ -public: - explicit pointer_to_binary_function(Result (*f)(Arg1, Arg2)); - Result operator()(Arg1 x, Arg2 y) const; -}; - -template -pointer_to_binary_function ptr_fun(Result (*f)(Arg1,Arg2)); - -template -class mem_fun_t : public unary_function -{ -public: - explicit mem_fun_t(S (T::*p)()); - S operator()(T* p) const; -}; - -template -class mem_fun1_t : public binary_function -{ -public: - explicit mem_fun1_t(S (T::*p)(A)); - S operator()(T* p, A x) const; -}; - -template mem_fun_t mem_fun(S (T::*f)()); -template mem_fun1_t mem_fun(S (T::*f)(A)); - -template -class mem_fun_ref_t : public unary_function -{ -public: - explicit mem_fun_ref_t(S (T::*p)()); - S operator()(T& p) const; -}; - -template -class mem_fun1_ref_t : public binary_function -{ -public: - explicit mem_fun1_ref_t(S (T::*p)(A)); - S operator()(T& p, A x) const; -}; - -template mem_fun_ref_t mem_fun_ref(S (T::*f)()); -template mem_fun1_ref_t mem_fun_ref(S (T::*f)(A)); - -template -class const_mem_fun_t : public unary_function -{ -public: - explicit const_mem_fun_t(S (T::*p)() const); - S operator()(const T* p) const; -}; - -template -class const_mem_fun1_t : public binary_function -{ -public: - explicit const_mem_fun1_t(S (T::*p)(A) const); - S operator()(const T* p, A x) const; -}; - -template const_mem_fun_t mem_fun(S (T::*f)() const); -template const_mem_fun1_t mem_fun(S (T::*f)(A) const); - -template -class const_mem_fun_ref_t : public unary_function -{ -public: - explicit const_mem_fun_ref_t(S (T::*p)() const); - S operator()(const T& p) const; -}; - -template -class const_mem_fun1_ref_t : public binary_function -{ -public: - explicit const_mem_fun1_ref_t(S (T::*p)(A) const); - S operator()(const T& p, A x) const; -}; - -template const_mem_fun_ref_t mem_fun_ref(S (T::*f)() const); -template const_mem_fun1_ref_t mem_fun_ref(S (T::*f)(A) const); - -template unspecified mem_fn(R T::*); -template unspecified mem_fn(R (T::*)(Args...)); -template unspecified mem_fn(R (T::*)(Args...) const); -template unspecified mem_fn(R (T::*)(Args...) volatile); -template unspecified mem_fn(R (T::*)(Args...) const volatile); -template unspecified mem_fn(R (T::*)(Args...) &); -template unspecified mem_fn(R (T::*)(Args...) const &); -template unspecified mem_fn(R (T::*)(Args...) volatile &); -template unspecified mem_fn(R (T::*)(Args...) const volatile &); -template unspecified mem_fn(R (T::*)(Args...) &&); -template unspecified mem_fn(R (T::*)(Args...) const &&); -template unspecified mem_fn(R (T::*)(Args...) volatile &&); -template unspecified mem_fn(R (T::*)(Args...) const volatile &&); - -class bad_function_call - : public exception -{ -}; - -template class function; // undefined - -template -class function - : public unary_function // iff sizeof...(ArgTypes) == 1 and - // ArgTypes contains T1 - : public binary_function // iff sizeof...(ArgTypes) == 2 and - // ArgTypes contains T1 and T2 -{ -public: - typedef R result_type; - - // construct/copy/destroy: - function() noexcept; - function(nullptr_t) noexcept; - function(const function&); - function(function&&) noexcept; - template - function(F); - template - function(allocator_arg_t, const Alloc&) noexcept; - template - function(allocator_arg_t, const Alloc&, nullptr_t) noexcept; - template - function(allocator_arg_t, const Alloc&, const function&); - template - function(allocator_arg_t, const Alloc&, function&&); - template - function(allocator_arg_t, const Alloc&, F); - - function& operator=(const function&); - function& operator=(function&&) noexcept; - function& operator=(nullptr_t) noexcept; - template - function& operator=(F&&); - template - function& operator=(reference_wrapper) noexcept; - - ~function(); - - // function modifiers: - void swap(function&) noexcept; - template - void assign(F&&, const Alloc&); - - // function capacity: - explicit operator bool() const noexcept; - - // function invocation: - R operator()(ArgTypes...) const; - - // function target access: - const std::type_info& target_type() const noexcept; - template T* target() noexcept; - template const T* target() const noexcept; -}; - -// Null pointer comparisons: -template - bool operator==(const function&, nullptr_t) noexcept; - -template - bool operator==(nullptr_t, const function&) noexcept; - -template - bool operator!=(const function&, nullptr_t) noexcept; - -template - bool operator!=(nullptr_t, const function&) noexcept; - -// specialized algorithms: -template - void swap(function&, function&) noexcept; - -template struct hash; - -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; -template <> struct hash; - -template <> struct hash; -template <> struct hash; -template <> struct hash; - -template struct hash; - -} // std - -POLICY: For non-variadic implementations, the number of arguments is limited - to 3. It is hoped that the need for non-variadic implementations - will be minimal. - -*/ - -#include <__config> -#include -#include -#include -#include -#include - -#include <__functional_base> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -struct _LIBCPP_VISIBLE plus : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x + __y;} -}; - -template -struct _LIBCPP_VISIBLE minus : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x - __y;} -}; - -template -struct _LIBCPP_VISIBLE multiplies : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x * __y;} -}; - -template -struct _LIBCPP_VISIBLE divides : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x / __y;} -}; - -template -struct _LIBCPP_VISIBLE modulus : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x % __y;} -}; - -template -struct _LIBCPP_VISIBLE negate : unary_function<_Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x) const - {return -__x;} -}; - -template -struct _LIBCPP_VISIBLE equal_to : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x == __y;} -}; - -template -struct _LIBCPP_VISIBLE not_equal_to : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x != __y;} -}; - -template -struct _LIBCPP_VISIBLE greater : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x > __y;} -}; - -// less in <__functional_base> - -template -struct _LIBCPP_VISIBLE greater_equal : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x >= __y;} -}; - -template -struct _LIBCPP_VISIBLE less_equal : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x <= __y;} -}; - -template -struct _LIBCPP_VISIBLE logical_and : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x && __y;} -}; - -template -struct _LIBCPP_VISIBLE logical_or : binary_function<_Tp, _Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x, const _Tp& __y) const - {return __x || __y;} -}; - -template -struct _LIBCPP_VISIBLE logical_not : unary_function<_Tp, bool> -{ - _LIBCPP_INLINE_VISIBILITY bool operator()(const _Tp& __x) const - {return !__x;} -}; - -template -struct _LIBCPP_VISIBLE bit_and : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x & __y;} -}; - -template -struct _LIBCPP_VISIBLE bit_or : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x | __y;} -}; - -template -struct _LIBCPP_VISIBLE bit_xor : binary_function<_Tp, _Tp, _Tp> -{ - _LIBCPP_INLINE_VISIBILITY _Tp operator()(const _Tp& __x, const _Tp& __y) const - {return __x ^ __y;} -}; - -template -class _LIBCPP_VISIBLE unary_negate - : public unary_function -{ - _Predicate __pred_; -public: - _LIBCPP_INLINE_VISIBILITY explicit unary_negate(const _Predicate& __pred) - : __pred_(__pred) {} - _LIBCPP_INLINE_VISIBILITY bool operator()(const typename _Predicate::argument_type& __x) const - {return !__pred_(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -unary_negate<_Predicate> -not1(const _Predicate& __pred) {return unary_negate<_Predicate>(__pred);} - -template -class _LIBCPP_VISIBLE binary_negate - : public binary_function -{ - _Predicate __pred_; -public: - _LIBCPP_INLINE_VISIBILITY explicit binary_negate(const _Predicate& __pred) - : __pred_(__pred) {} - _LIBCPP_INLINE_VISIBILITY bool operator()(const typename _Predicate::first_argument_type& __x, - const typename _Predicate::second_argument_type& __y) const - {return !__pred_(__x, __y);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -binary_negate<_Predicate> -not2(const _Predicate& __pred) {return binary_negate<_Predicate>(__pred);} - -template -class _LIBCPP_VISIBLE binder1st - : public unary_function -{ -protected: - __Operation op; - typename __Operation::first_argument_type value; -public: - _LIBCPP_INLINE_VISIBILITY binder1st(const __Operation& __x, - const typename __Operation::first_argument_type __y) - : op(__x), value(__y) {} - _LIBCPP_INLINE_VISIBILITY typename __Operation::result_type operator() - (typename __Operation::second_argument_type& __x) const - {return op(value, __x);} - _LIBCPP_INLINE_VISIBILITY typename __Operation::result_type operator() - (const typename __Operation::second_argument_type& __x) const - {return op(value, __x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -binder1st<__Operation> -bind1st(const __Operation& __op, const _Tp& __x) - {return binder1st<__Operation>(__op, __x);} - -template -class _LIBCPP_VISIBLE binder2nd - : public unary_function -{ -protected: - __Operation op; - typename __Operation::second_argument_type value; -public: - _LIBCPP_INLINE_VISIBILITY - binder2nd(const __Operation& __x, const typename __Operation::second_argument_type __y) - : op(__x), value(__y) {} - _LIBCPP_INLINE_VISIBILITY typename __Operation::result_type operator() - ( typename __Operation::first_argument_type& __x) const - {return op(__x, value);} - _LIBCPP_INLINE_VISIBILITY typename __Operation::result_type operator() - (const typename __Operation::first_argument_type& __x) const - {return op(__x, value);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -binder2nd<__Operation> -bind2nd(const __Operation& __op, const _Tp& __x) - {return binder2nd<__Operation>(__op, __x);} - -template -class _LIBCPP_VISIBLE pointer_to_unary_function - : public unary_function<_Arg, _Result> -{ - _Result (*__f_)(_Arg); -public: - _LIBCPP_INLINE_VISIBILITY explicit pointer_to_unary_function(_Result (*__f)(_Arg)) - : __f_(__f) {} - _LIBCPP_INLINE_VISIBILITY _Result operator()(_Arg __x) const - {return __f_(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -pointer_to_unary_function<_Arg,_Result> -ptr_fun(_Result (*__f)(_Arg)) - {return pointer_to_unary_function<_Arg,_Result>(__f);} - -template -class _LIBCPP_VISIBLE pointer_to_binary_function - : public binary_function<_Arg1, _Arg2, _Result> -{ - _Result (*__f_)(_Arg1, _Arg2); -public: - _LIBCPP_INLINE_VISIBILITY explicit pointer_to_binary_function(_Result (*__f)(_Arg1, _Arg2)) - : __f_(__f) {} - _LIBCPP_INLINE_VISIBILITY _Result operator()(_Arg1 __x, _Arg2 __y) const - {return __f_(__x, __y);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -pointer_to_binary_function<_Arg1,_Arg2,_Result> -ptr_fun(_Result (*__f)(_Arg1,_Arg2)) - {return pointer_to_binary_function<_Arg1,_Arg2,_Result>(__f);} - -template -class _LIBCPP_VISIBLE mem_fun_t : public unary_function<_Tp*, _Sp> -{ - _Sp (_Tp::*__p_)(); -public: - _LIBCPP_INLINE_VISIBILITY explicit mem_fun_t(_Sp (_Tp::*__p)()) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(_Tp* __p) const - {return (__p->*__p_)();} -}; - -template -class _LIBCPP_VISIBLE mem_fun1_t : public binary_function<_Tp*, _Ap, _Sp> -{ - _Sp (_Tp::*__p_)(_Ap); -public: - _LIBCPP_INLINE_VISIBILITY explicit mem_fun1_t(_Sp (_Tp::*__p)(_Ap)) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(_Tp* __p, _Ap __x) const - {return (__p->*__p_)(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -mem_fun_t<_Sp,_Tp> -mem_fun(_Sp (_Tp::*__f)()) - {return mem_fun_t<_Sp,_Tp>(__f);} - -template -inline _LIBCPP_INLINE_VISIBILITY -mem_fun1_t<_Sp,_Tp,_Ap> -mem_fun(_Sp (_Tp::*__f)(_Ap)) - {return mem_fun1_t<_Sp,_Tp,_Ap>(__f);} - -template -class _LIBCPP_VISIBLE mem_fun_ref_t : public unary_function<_Tp, _Sp> -{ - _Sp (_Tp::*__p_)(); -public: - _LIBCPP_INLINE_VISIBILITY explicit mem_fun_ref_t(_Sp (_Tp::*__p)()) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(_Tp& __p) const - {return (__p.*__p_)();} -}; - -template -class _LIBCPP_VISIBLE mem_fun1_ref_t : public binary_function<_Tp, _Ap, _Sp> -{ - _Sp (_Tp::*__p_)(_Ap); -public: - _LIBCPP_INLINE_VISIBILITY explicit mem_fun1_ref_t(_Sp (_Tp::*__p)(_Ap)) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(_Tp& __p, _Ap __x) const - {return (__p.*__p_)(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -mem_fun_ref_t<_Sp,_Tp> -mem_fun_ref(_Sp (_Tp::*__f)()) - {return mem_fun_ref_t<_Sp,_Tp>(__f);} - -template -inline _LIBCPP_INLINE_VISIBILITY -mem_fun1_ref_t<_Sp,_Tp,_Ap> -mem_fun_ref(_Sp (_Tp::*__f)(_Ap)) - {return mem_fun1_ref_t<_Sp,_Tp,_Ap>(__f);} - -template -class _LIBCPP_VISIBLE const_mem_fun_t : public unary_function -{ - _Sp (_Tp::*__p_)() const; -public: - _LIBCPP_INLINE_VISIBILITY explicit const_mem_fun_t(_Sp (_Tp::*__p)() const) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(const _Tp* __p) const - {return (__p->*__p_)();} -}; - -template -class _LIBCPP_VISIBLE const_mem_fun1_t : public binary_function -{ - _Sp (_Tp::*__p_)(_Ap) const; -public: - _LIBCPP_INLINE_VISIBILITY explicit const_mem_fun1_t(_Sp (_Tp::*__p)(_Ap) const) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(const _Tp* __p, _Ap __x) const - {return (__p->*__p_)(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -const_mem_fun_t<_Sp,_Tp> -mem_fun(_Sp (_Tp::*__f)() const) - {return const_mem_fun_t<_Sp,_Tp>(__f);} - -template -inline _LIBCPP_INLINE_VISIBILITY -const_mem_fun1_t<_Sp,_Tp,_Ap> -mem_fun(_Sp (_Tp::*__f)(_Ap) const) - {return const_mem_fun1_t<_Sp,_Tp,_Ap>(__f);} - -template -class _LIBCPP_VISIBLE const_mem_fun_ref_t : public unary_function<_Tp, _Sp> -{ - _Sp (_Tp::*__p_)() const; -public: - _LIBCPP_INLINE_VISIBILITY explicit const_mem_fun_ref_t(_Sp (_Tp::*__p)() const) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(const _Tp& __p) const - {return (__p.*__p_)();} -}; - -template -class _LIBCPP_VISIBLE const_mem_fun1_ref_t - : public binary_function<_Tp, _Ap, _Sp> -{ - _Sp (_Tp::*__p_)(_Ap) const; -public: - _LIBCPP_INLINE_VISIBILITY explicit const_mem_fun1_ref_t(_Sp (_Tp::*__p)(_Ap) const) - : __p_(__p) {} - _LIBCPP_INLINE_VISIBILITY _Sp operator()(const _Tp& __p, _Ap __x) const - {return (__p.*__p_)(__x);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -const_mem_fun_ref_t<_Sp,_Tp> -mem_fun_ref(_Sp (_Tp::*__f)() const) - {return const_mem_fun_ref_t<_Sp,_Tp>(__f);} - -template -inline _LIBCPP_INLINE_VISIBILITY -const_mem_fun1_ref_t<_Sp,_Tp,_Ap> -mem_fun_ref(_Sp (_Tp::*__f)(_Ap) const) - {return const_mem_fun1_ref_t<_Sp,_Tp,_Ap>(__f);} - -#ifdef _LIBCPP_HAS_NO_VARIADICS - -#include <__functional_03> - -#else // _LIBCPP_HAS_NO_VARIADICS - -template -class __mem_fn - : public __weak_result_type<_Tp> -{ -public: - // types - typedef _Tp type; -private: - type __f_; - -public: - _LIBCPP_INLINE_VISIBILITY __mem_fn(type __f) : __f_(__f) {} - - // invoke - template - _LIBCPP_INLINE_VISIBILITY - typename __invoke_return::type - operator() (_ArgTypes&&... __args) - { - return __invoke(__f_, _VSTD::forward<_ArgTypes>(__args)...); - } -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp _Tp::*> -mem_fn(_Rp _Tp::* __pm) -{ - return __mem_fn<_Rp _Tp::*>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_Args...)> -mem_fn(_Rp (_Tp::* __pm)(_Args...)) -{ - return __mem_fn<_Rp (_Tp::*)(_Args...)>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_Args...) const> -mem_fn(_Rp (_Tp::* __pm)(_Args...) const) -{ - return __mem_fn<_Rp (_Tp::*)(_Args...) const>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_Args...) volatile> -mem_fn(_Rp (_Tp::* __pm)(_Args...) volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_Args...) volatile>(__pm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__mem_fn<_Rp (_Tp::*)(_Args...) const volatile> -mem_fn(_Rp (_Tp::* __pm)(_Args...) const volatile) -{ - return __mem_fn<_Rp (_Tp::*)(_Args...) const volatile>(__pm); -} - -// bad_function_call - -class _LIBCPP_EXCEPTION_ABI bad_function_call - : public exception -{ -}; - -template class _LIBCPP_VISIBLE function; // undefined - -namespace __function -{ - -template -struct __maybe_derive_from_unary_function -{ -}; - -template -struct __maybe_derive_from_unary_function<_Rp(_A1)> - : public unary_function<_A1, _Rp> -{ -}; - -template -struct __maybe_derive_from_binary_function -{ -}; - -template -struct __maybe_derive_from_binary_function<_Rp(_A1, _A2)> - : public binary_function<_A1, _A2, _Rp> -{ -}; - -template class __base; - -template -class __base<_Rp(_ArgTypes...)> -{ - __base(const __base&); - __base& operator=(const __base&); -public: - _LIBCPP_INLINE_VISIBILITY __base() {} - _LIBCPP_INLINE_VISIBILITY virtual ~__base() {} - virtual __base* __clone() const = 0; - virtual void __clone(__base*) const = 0; - virtual void destroy() _NOEXCEPT = 0; - virtual void destroy_deallocate() _NOEXCEPT = 0; - virtual _Rp operator()(_ArgTypes&& ...) = 0; -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const _NOEXCEPT = 0; - virtual const std::type_info& target_type() const _NOEXCEPT = 0; -#endif // _LIBCPP_NO_RTTI -}; - -template class __func; - -template -class __func<_Fp, _Alloc, _Rp(_ArgTypes...)> - : public __base<_Rp(_ArgTypes...)> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __func(_Fp&& __f) - : __f_(piecewise_construct, _VSTD::forward_as_tuple(_VSTD::move(__f)), - _VSTD::forward_as_tuple()) {} - _LIBCPP_INLINE_VISIBILITY - explicit __func(const _Fp& __f, const _Alloc& __a) - : __f_(piecewise_construct, _VSTD::forward_as_tuple(__f), - _VSTD::forward_as_tuple(__a)) {} - - _LIBCPP_INLINE_VISIBILITY - explicit __func(const _Fp& __f, _Alloc&& __a) - : __f_(piecewise_construct, _VSTD::forward_as_tuple(__f), - _VSTD::forward_as_tuple(_VSTD::move(__a))) {} - - _LIBCPP_INLINE_VISIBILITY - explicit __func(_Fp&& __f, _Alloc&& __a) - : __f_(piecewise_construct, _VSTD::forward_as_tuple(_VSTD::move(__f)), - _VSTD::forward_as_tuple(_VSTD::move(__a))) {} - virtual __base<_Rp(_ArgTypes...)>* __clone() const; - virtual void __clone(__base<_Rp(_ArgTypes...)>*) const; - virtual void destroy() _NOEXCEPT; - virtual void destroy_deallocate() _NOEXCEPT; - virtual _Rp operator()(_ArgTypes&& ... __arg); -#ifndef _LIBCPP_NO_RTTI - virtual const void* target(const type_info&) const _NOEXCEPT; - virtual const std::type_info& target_type() const _NOEXCEPT; -#endif // _LIBCPP_NO_RTTI -}; - -template -__base<_Rp(_ArgTypes...)>* -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::__clone() const -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__func, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) __func(__f_.first(), _Alloc(__a)); - return __hold.release(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::__clone(__base<_Rp(_ArgTypes...)>* __p) const -{ - ::new (__p) __func(__f_.first(), __f_.second()); -} - -template -void -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::destroy() _NOEXCEPT -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::destroy_deallocate() _NOEXCEPT -{ - typedef typename _Alloc::template rebind<__func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::operator()(_ArgTypes&& ... __arg) -{ - return __invoke(__f_.first(), _VSTD::forward<_ArgTypes>(__arg)...); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const void* -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::target(const type_info& __ti) const _NOEXCEPT -{ - if (__ti == typeid(_Fp)) - return &__f_.first(); - return (const void*)0; -} - -template -const std::type_info& -__func<_Fp, _Alloc, _Rp(_ArgTypes...)>::target_type() const _NOEXCEPT -{ - return typeid(_Fp); -} - -#endif // _LIBCPP_NO_RTTI - -} // __function - -template -class _LIBCPP_VISIBLE function<_Rp(_ArgTypes...)> - : public __function::__maybe_derive_from_unary_function<_Rp(_ArgTypes...)>, - public __function::__maybe_derive_from_binary_function<_Rp(_ArgTypes...)> -{ - typedef __function::__base<_Rp(_ArgTypes...)> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const _Fp&) {return true;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (*__p)(_Ap...)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_Ap...)) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_Ap...) const) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_Ap...) volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(_R2 (_Cp::*__p)(_Ap...) const volatile) {return __p;} - template - _LIBCPP_INLINE_VISIBILITY - static bool __not_null(const function<_Rp(_Ap...)>& __p) {return __p;} - - template ::value> - struct __callable; - template - struct __callable<_Fp, true> - { - static const bool value = - is_convertible::type, - _Rp>::value; - }; - template - struct __callable<_Fp, false> - { - static const bool value = false; - }; -public: - typedef _Rp result_type; - - // construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY - function() _NOEXCEPT : __f_(0) {} - _LIBCPP_INLINE_VISIBILITY - function(nullptr_t) _NOEXCEPT : __f_(0) {} - function(const function&); - function(function&&) _NOEXCEPT; - template - function(_Fp, - typename enable_if<__callable<_Fp>::value>::type* = 0); - - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&) _NOEXCEPT : __f_(0) {} - template - _LIBCPP_INLINE_VISIBILITY - function(allocator_arg_t, const _Alloc&, nullptr_t) _NOEXCEPT : __f_(0) {} - template - function(allocator_arg_t, const _Alloc&, const function&); - template - function(allocator_arg_t, const _Alloc&, function&&); - template - function(allocator_arg_t, const _Alloc& __a, _Fp __f, - typename enable_if<__callable<_Fp>::value>::type* = 0); - - function& operator=(const function&); - function& operator=(function&&) _NOEXCEPT; - function& operator=(nullptr_t) _NOEXCEPT; - template - typename enable_if - < - __callable::type>::value, - function& - >::type - operator=(_Fp&&); - - ~function(); - - // function modifiers: - void swap(function&) _NOEXCEPT; - template - _LIBCPP_INLINE_VISIBILITY - void assign(_Fp&& __f, const _Alloc& __a) - {function(allocator_arg, __a, _VSTD::forward<_Fp>(__f)).swap(*this);} - - // function capacity: - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_EXPLICIT operator bool() const _NOEXCEPT {return __f_;} - - // deleted overloads close possible hole in the type system - template - bool operator==(const function<_R2(_ArgTypes2...)>&) const = delete; - template - bool operator!=(const function<_R2(_ArgTypes2...)>&) const = delete; -public: - // function invocation: - _Rp operator()(_ArgTypes...) const; - -#ifndef _LIBCPP_NO_RTTI - // function target access: - const std::type_info& target_type() const _NOEXCEPT; - template _Tp* target() _NOEXCEPT; - template const _Tp* target() const _NOEXCEPT; -#endif // _LIBCPP_NO_RTTI -}; - -template -function<_Rp(_ArgTypes...)>::function(const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -template -function<_Rp(_ArgTypes...)>::function(allocator_arg_t, const _Alloc&, - const function& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (const __base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - __f_ = __f.__f_->__clone(); -} - -template -function<_Rp(_ArgTypes...)>::function(function&& __f) _NOEXCEPT -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - { - __f_ = __f.__f_; - __f.__f_ = 0; - } -} - -template -template -function<_Rp(_ArgTypes...)>::function(allocator_arg_t, const _Alloc&, - function&& __f) -{ - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - { - __f_ = __f.__f_; - __f.__f_ = 0; - } -} - -template -template -function<_Rp(_ArgTypes...)>::function(_Fp __f, - typename enable_if<__callable<_Fp>::value>::type*) - : __f_(0) -{ - if (__not_null(__f)) - { - typedef __function::__func<_Fp, allocator<_Fp>, _Rp(_ArgTypes...)> _FF; - if (sizeof(_FF) <= sizeof(__buf_) && is_nothrow_copy_constructible<_Fp>::value) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(_VSTD::move(__f)); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(_VSTD::move(__f), allocator<_Fp>(__a)); - __f_ = __hold.release(); - } - } -} - -template -template -function<_Rp(_ArgTypes...)>::function(allocator_arg_t, const _Alloc& __a0, _Fp __f, - typename enable_if<__callable<_Fp>::value>::type*) - : __f_(0) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - if (__not_null(__f)) - { - typedef __function::__func<_Fp, _Alloc, _Rp(_ArgTypes...)> _FF; - if (sizeof(_FF) <= sizeof(__buf_) && is_nothrow_copy_constructible<_Fp>::value) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(_VSTD::move(__f)); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(_VSTD::move(__f), _Alloc(__a)); - __f_ = __hold.release(); - } - } -} - -template -function<_Rp(_ArgTypes...)>& -function<_Rp(_ArgTypes...)>::operator=(const function& __f) -{ - function(__f).swap(*this); - return *this; -} - -template -function<_Rp(_ArgTypes...)>& -function<_Rp(_ArgTypes...)>::operator=(function&& __f) _NOEXCEPT -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; - if (__f.__f_ == 0) - __f_ = 0; - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__clone(__f_); - } - else - { - __f_ = __f.__f_; - __f.__f_ = 0; - } -} - -template -function<_Rp(_ArgTypes...)>& -function<_Rp(_ArgTypes...)>::operator=(nullptr_t) _NOEXCEPT -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = 0; -} - -template -template -typename enable_if -< - function<_Rp(_ArgTypes...)>::template __callable::type>::value, - function<_Rp(_ArgTypes...)>& ->::type -function<_Rp(_ArgTypes...)>::operator=(_Fp&& __f) -{ - function(_VSTD::forward<_Fp>(__f)).swap(*this); - return *this; -} - -template -function<_Rp(_ArgTypes...)>::~function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -function<_Rp(_ArgTypes...)>::swap(function& __f) _NOEXCEPT -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__clone(__t); - __f_->destroy(); - __f_ = 0; - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = 0; - __f_ = (__base*)&__buf_; - __t->__clone((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__clone((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__clone((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -_Rp -function<_Rp(_ArgTypes...)>::operator()(_ArgTypes... __arg) const -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__f_ == 0) - throw bad_function_call(); -#endif // _LIBCPP_NO_EXCEPTIONS - return (*__f_)(_VSTD::forward<_ArgTypes>(__arg)...); -} - -#ifndef _LIBCPP_NO_RTTI - -template -const std::type_info& -function<_Rp(_ArgTypes...)>::target_type() const _NOEXCEPT -{ - if (__f_ == 0) - return typeid(void); - return __f_->target_type(); -} - -template -template -_Tp* -function<_Rp(_ArgTypes...)>::target() _NOEXCEPT -{ - if (__f_ == 0) - return (_Tp*)0; - return (_Tp*)__f_->target(typeid(_Tp)); -} - -template -template -const _Tp* -function<_Rp(_ArgTypes...)>::target() const _NOEXCEPT -{ - if (__f_ == 0) - return (const _Tp*)0; - return (const _Tp*)__f_->target(typeid(_Tp)); -} - -#endif // _LIBCPP_NO_RTTI - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const function<_Rp(_ArgTypes...)>& __f, nullptr_t) _NOEXCEPT {return !__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(nullptr_t, const function<_Rp(_ArgTypes...)>& __f) _NOEXCEPT {return !__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const function<_Rp(_ArgTypes...)>& __f, nullptr_t) _NOEXCEPT {return (bool)__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(nullptr_t, const function<_Rp(_ArgTypes...)>& __f) _NOEXCEPT {return (bool)__f;} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(function<_Rp(_ArgTypes...)>& __x, function<_Rp(_ArgTypes...)>& __y) _NOEXCEPT -{return __x.swap(__y);} - -template struct __is_bind_expression : public false_type {}; -template struct _LIBCPP_VISIBLE is_bind_expression - : public __is_bind_expression::type> {}; - -template struct __is_placeholder : public integral_constant {}; -template struct _LIBCPP_VISIBLE is_placeholder - : public __is_placeholder::type> {}; - -namespace placeholders -{ - -template struct __ph {}; - -extern __ph<1> _1; -extern __ph<2> _2; -extern __ph<3> _3; -extern __ph<4> _4; -extern __ph<5> _5; -extern __ph<6> _6; -extern __ph<7> _7; -extern __ph<8> _8; -extern __ph<9> _9; -extern __ph<10> _10; - -} // placeholders - -template -struct __is_placeholder > - : public integral_constant {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp& -__mu(reference_wrapper<_Tp> __t, _Uj&) -{ - return __t.get(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __invoke_of<_Ti&, _Uj...>::type -__mu_expand(_Ti& __ti, tuple<_Uj...>& __uj, __tuple_indices<_Indx...>) -{ - return __ti(_VSTD::forward<_Uj>(get<_Indx>(__uj))...); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - is_bind_expression<_Ti>::value, - typename __invoke_of<_Ti&, _Uj...>::type ->::type -__mu(_Ti& __ti, tuple<_Uj...>& __uj) -{ - typedef typename __make_tuple_indices::type __indices; - return __mu_expand(__ti, __uj, __indices()); -} - -template -struct __mu_return2 {}; - -template -struct __mu_return2 -{ - typedef typename tuple_element::value - 1, _Uj>::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - 0 < is_placeholder<_Ti>::value, - typename __mu_return2<0 < is_placeholder<_Ti>::value, _Ti, _Uj>::type ->::type -__mu(_Ti&, _Uj& __uj) -{ - const size_t _Indx = is_placeholder<_Ti>::value - 1; - return _VSTD::forward::type>(get<_Indx>(__uj)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename enable_if -< - !is_bind_expression<_Ti>::value && - is_placeholder<_Ti>::value == 0 && - !__is_reference_wrapper<_Ti>::value, - _Ti& ->::type -__mu(_Ti& __ti, _Uj&) -{ - return __ti; -} - -template -struct ____mu_return; - -template -struct ____mu_return<_Ti, false, true, false, tuple<_Uj...> > -{ - typedef typename __invoke_of<_Ti&, _Uj...>::type type; -}; - -template -struct ____mu_return<_Ti, false, false, true, _TupleUj> -{ - typedef typename tuple_element::value - 1, - _TupleUj>::type&& type; -}; - -template -struct ____mu_return<_Ti, true, false, false, _TupleUj> -{ - typedef typename _Ti::type& type; -}; - -template -struct ____mu_return<_Ti, false, false, false, _TupleUj> -{ - typedef _Ti& type; -}; - -template -struct __mu_return - : public ____mu_return<_Ti, - __is_reference_wrapper<_Ti>::value, - is_bind_expression<_Ti>::value, - 0 < is_placeholder<_Ti>::value, - _TupleUj> -{ -}; - -template -struct __bind_return; - -template -struct __bind_return<_Fp, tuple<_BoundArgs...>, _TupleUj> -{ - typedef typename __invoke_of - < - _Fp&, - typename __mu_return - < - _BoundArgs, - _TupleUj - >::type... - >::type type; -}; - -template -struct __bind_return<_Fp, const tuple<_BoundArgs...>, _TupleUj> -{ - typedef typename __invoke_of - < - _Fp&, - typename __mu_return - < - const _BoundArgs, - _TupleUj - >::type... - >::type type; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __bind_return<_Fp, _BoundArgs, _Args>::type -__apply_functor(_Fp& __f, _BoundArgs& __bound_args, __tuple_indices<_Indx...>, - _Args&& __args) -{ - return __invoke(__f, __mu(get<_Indx>(__bound_args), __args)...); -} - -template -class __bind - : public __weak_result_type::type> -{ - typedef typename decay<_Fp>::type _Fd; - typedef tuple::type...> _Td; - _Fd __f_; - _Td __bound_args_; - - typedef typename __make_tuple_indices::type __indices; -public: -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS - - _LIBCPP_INLINE_VISIBILITY - __bind(const __bind& __b) - : __f_(__b.__f_), - __bound_args_(__b.__bound_args_) {} - - _LIBCPP_INLINE_VISIBILITY - __bind& operator=(const __bind& __b) - { - __f_ = __b.__f_; - __bound_args_ = __b.__bound_args_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __bind(__bind&& __b) - : __f_(_VSTD::move(__b.__f_)), - __bound_args_(_VSTD::move(__b.__bound_args_)) {} - - _LIBCPP_INLINE_VISIBILITY - __bind& operator=(__bind&& __b) - { - __f_ = _VSTD::move(__b.__f_); - __bound_args_ = _VSTD::move(__b.__bound_args_); - return *this; - } - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS - - template - _LIBCPP_INLINE_VISIBILITY - explicit __bind(_Gp&& __f, _BA&& ...__bound_args) - : __f_(_VSTD::forward<_Gp>(__f)), - __bound_args_(_VSTD::forward<_BA>(__bound_args)...) {} - - template - _LIBCPP_INLINE_VISIBILITY - typename __bind_return<_Fd, _Td, tuple<_Args&&...> >::type - operator()(_Args&& ...__args) - { - return __apply_functor(__f_, __bound_args_, __indices(), - tuple<_Args&&...>(_VSTD::forward<_Args>(__args)...)); - } - - template - _LIBCPP_INLINE_VISIBILITY - typename __bind_return<_Fd, _Td, tuple<_Args&&...> >::type - operator()(_Args&& ...__args) const - { - return __apply_functor(__f_, __bound_args_, __indices(), - tuple<_Args&&...>(_VSTD::forward<_Args>(__args)...)); - } -}; - -template -struct __is_bind_expression<__bind<_Fp, _BoundArgs...> > : public true_type {}; - -template -class __bind_r - : public __bind<_Fp, _BoundArgs...> -{ - typedef __bind<_Fp, _BoundArgs...> base; -public: - typedef _Rp result_type; - -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS - - _LIBCPP_INLINE_VISIBILITY - __bind_r(const __bind_r& __b) - : base(_VSTD::forward(__b)) {} - - _LIBCPP_INLINE_VISIBILITY - __bind_r& operator=(const __bind_r& __b) - { - base::operator=(_VSTD::forward(__b)); - return *this; - } - - _LIBCPP_INLINE_VISIBILITY - __bind_r(__bind_r&& __b) - : base(_VSTD::forward(__b)) {} - - _LIBCPP_INLINE_VISIBILITY - __bind_r& operator=(__bind_r&& __b) - { - base::operator=(_VSTD::forward(__b)); - return *this; - } - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS - - template - _LIBCPP_INLINE_VISIBILITY - explicit __bind_r(_Gp&& __f, _BA&& ...__bound_args) - : base(_VSTD::forward<_Gp>(__f), - _VSTD::forward<_BA>(__bound_args)...) {} - - template - _LIBCPP_INLINE_VISIBILITY - result_type - operator()(_Args&& ...__args) - { - return base::operator()(_VSTD::forward<_Args>(__args)...); - } - - template - _LIBCPP_INLINE_VISIBILITY - result_type - operator()(_Args&& ...__args) const - { - return base::operator()(_VSTD::forward<_Args>(__args)...); - } -}; - -template -struct __is_bind_expression<__bind_r<_Rp, _Fp, _BoundArgs...> > : public true_type {}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__bind<_Fp, _BoundArgs...> -bind(_Fp&& __f, _BoundArgs&&... __bound_args) -{ - typedef __bind<_Fp, _BoundArgs...> type; - return type(_VSTD::forward<_Fp>(__f), _VSTD::forward<_BoundArgs>(__bound_args)...); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__bind_r<_Rp, _Fp, _BoundArgs...> -bind(_Fp&& __f, _BoundArgs&&... __bound_args) -{ - typedef __bind_r<_Rp, _Fp, _BoundArgs...> type; - return type(_VSTD::forward<_Fp>(__f), _VSTD::forward<_BoundArgs>(__bound_args)...); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(bool __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(char __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(signed char __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(unsigned char __v) const _NOEXCEPT {return static_cast(__v);} -}; - -#ifndef _LIBCPP_HAS_NO_UNICODE_CHARS - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(char16_t __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(char32_t __v) const _NOEXCEPT {return static_cast(__v);} -}; - -#endif // _LIBCPP_HAS_NO_UNICODE_CHARS - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(wchar_t __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(short __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(unsigned short __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(int __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(unsigned int __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(long __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public unary_function -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(unsigned long __v) const _NOEXCEPT {return static_cast(__v);} -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public __scalar_hash -{ -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public __scalar_hash -{ -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public __scalar_hash -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(float __v) const _NOEXCEPT - { - // -0.0 and 0.0 should return same hash - if (__v == 0) - return 0; - return __scalar_hash::operator()(__v); - } -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public __scalar_hash -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(double __v) const _NOEXCEPT - { - // -0.0 and 0.0 should return same hash - if (__v == 0) - return 0; - return __scalar_hash::operator()(__v); - } -}; - -template <> -struct _LIBCPP_VISIBLE hash - : public __scalar_hash -{ - _LIBCPP_INLINE_VISIBILITY - size_t operator()(long double __v) const _NOEXCEPT - { - // -0.0 and 0.0 should return same hash - if (__v == 0) - return 0; -#if defined(__i386__) - // Zero out padding bits - union - { - long double __t; - struct - { - size_t __a; - size_t __b; - size_t __c; - size_t __d; - }; - } __u; - __u.__a = 0; - __u.__b = 0; - __u.__c = 0; - __u.__d = 0; - __u.__t = __v; - return __u.__a ^ __u.__b ^ __u.__c ^ __u.__d; -#elif defined(__x86_64__) - // Zero out padding bits - union - { - long double __t; - struct - { - size_t __a; - size_t __b; - }; - } __u; - __u.__a = 0; - __u.__b = 0; - __u.__t = __v; - return __u.__a ^ __u.__b; -#else - return __scalar_hash::operator()(__v); -#endif - } -}; - -// struct hash in - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_FUNCTIONAL diff --git a/libcxx/include/future b/libcxx/include/future deleted file mode 100644 index aae707e1e4e8..000000000000 --- a/libcxx/include/future +++ /dev/null @@ -1,2501 +0,0 @@ -// -*- C++ -*- -//===--------------------------- future -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_FUTURE -#define _LIBCPP_FUTURE - -/* - future synopsis - -namespace std -{ - -enum class future_errc -{ - broken_promise, - future_already_retrieved, - promise_already_satisfied, - no_state -}; - -enum class launch -{ - async = 1, - deferred = 2, - any = async | deferred -}; - -enum class future_status -{ - ready, - timeout, - deferred -}; - -template <> struct is_error_code_enum : public true_type { }; -error_code make_error_code(future_errc e); -error_condition make_error_condition(future_errc e); - -const error_category& future_category(); - -class future_error - : public logic_error -{ -public: - future_error(error_code ec); // exposition only - - const error_code& code() const throw(); - const char* what() const throw(); -}; - -template -class promise -{ -public: - promise(); - template - promise(allocator_arg_t, const Allocator& a); - promise(promise&& rhs); - promise(const promise& rhs) = delete; - ~promise(); - - // assignment - promise& operator=(promise&& rhs); - promise& operator=(const promise& rhs) = delete; - void swap(promise& other); - - // retrieving the result - future get_future(); - - // setting the result - void set_value(const R& r); - void set_value(R&& r); - void set_exception(exception_ptr p); - - // setting the result with deferred notification - void set_value_at_thread_exit(const R& r); - void set_value_at_thread_exit(R&& r); - void set_exception_at_thread_exit(exception_ptr p); -}; - -template -class promise -{ -public: - promise(); - template - promise(allocator_arg_t, const Allocator& a); - promise(promise&& rhs); - promise(const promise& rhs) = delete; - ~promise(); - - // assignment - promise& operator=(promise&& rhs); - promise& operator=(const promise& rhs) = delete; - void swap(promise& other); - - // retrieving the result - future get_future(); - - // setting the result - void set_value(R& r); - void set_exception(exception_ptr p); - - // setting the result with deferred notification - void set_value_at_thread_exit(R&); - void set_exception_at_thread_exit(exception_ptr p); -}; - -template <> -class promise -{ -public: - promise(); - template - promise(allocator_arg_t, const Allocator& a); - promise(promise&& rhs); - promise(const promise& rhs) = delete; - ~promise(); - - // assignment - promise& operator=(promise&& rhs); - promise& operator=(const promise& rhs) = delete; - void swap(promise& other); - - // retrieving the result - future get_future(); - - // setting the result - void set_value(); - void set_exception(exception_ptr p); - - // setting the result with deferred notification - void set_value_at_thread_exit(); - void set_exception_at_thread_exit(exception_ptr p); -}; - -template void swap(promise& x, promise& y); - -template - struct uses_allocator, Alloc> : public true_type {}; - -template -class future -{ -public: - future(); - future(future&&); - future(const future& rhs) = delete; - ~future(); - future& operator=(const future& rhs) = delete; - future& operator=(future&&); - shared_future share() &&; - - // retrieving the value - R get(); - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template -class future -{ -public: - future(); - future(future&&); - future(const future& rhs) = delete; - ~future(); - future& operator=(const future& rhs) = delete; - future& operator=(future&&); - shared_future share() &&; - - // retrieving the value - R& get(); - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template <> -class future -{ -public: - future(); - future(future&&); - future(const future& rhs) = delete; - ~future(); - future& operator=(const future& rhs) = delete; - future& operator=(future&&); - shared_future share() &&; - - // retrieving the value - void get(); - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template -class shared_future -{ -public: - shared_future(); - shared_future(const shared_future& rhs); - shared_future(future&&); - shared_future(shared_future&& rhs); - ~shared_future(); - shared_future& operator=(const shared_future& rhs); - shared_future& operator=(shared_future&& rhs); - - // retrieving the value - const R& get() const; - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template -class shared_future -{ -public: - shared_future(); - shared_future(const shared_future& rhs); - shared_future(future&&); - shared_future(shared_future&& rhs); - ~shared_future(); - shared_future& operator=(const shared_future& rhs); - shared_future& operator=(shared_future&& rhs); - - // retrieving the value - R& get() const; - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template <> -class shared_future -{ -public: - shared_future(); - shared_future(const shared_future& rhs); - shared_future(future&&); - shared_future(shared_future&& rhs); - ~shared_future(); - shared_future& operator=(const shared_future& rhs); - shared_future& operator=(shared_future&& rhs); - - // retrieving the value - void get() const; - - // functions to check state - bool valid() const; - - void wait() const; - template - future_status - wait_for(const chrono::duration& rel_time) const; - template - future_status - wait_until(const chrono::time_point& abs_time) const; -}; - -template - future::type> - async(F&& f, Args&&... args); - -template - future::type> - async(launch policy, F&& f, Args&&... args); - -template class packaged_task; // undefined - -template -class packaged_task -{ -public: - typedef R result_type; - - // construction and destruction - packaged_task(); - template - explicit packaged_task(F&& f); - template - explicit packaged_task(allocator_arg_t, const Allocator& a, F&& f); - ~packaged_task(); - - // no copy - packaged_task(packaged_task&) = delete; - packaged_task& operator=(packaged_task&) = delete; - - // move support - packaged_task(packaged_task&& other); - packaged_task& operator=(packaged_task&& other); - void swap(packaged_task& other); - - bool valid() const; - - // result retrieval - future get_future(); - - // execution - void operator()(ArgTypes... ); - void make_ready_at_thread_exit(ArgTypes...); - - void reset(); -}; - -template - void swap(packaged_task&); - -template struct uses_allocator, Alloc>; - -} // std - -*/ - -#include <__config> -#include -#include -#include -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -//enum class future_errc -_LIBCPP_DECLARE_STRONG_ENUM(future_errc) -{ - broken_promise, - future_already_retrieved, - promise_already_satisfied, - no_state -}; -_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(future_errc) - -template <> -struct _LIBCPP_VISIBLE is_error_code_enum : public true_type {}; - -#ifdef _LIBCPP_HAS_NO_STRONG_ENUMS -template <> -struct _LIBCPP_VISIBLE is_error_code_enum : public true_type { }; -#endif - -//enum class launch -_LIBCPP_DECLARE_STRONG_ENUM(launch) -{ - async = 1, - deferred = 2, - any = async | deferred -}; -_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(launch) - -//enum class future_status -_LIBCPP_DECLARE_STRONG_ENUM(future_status) -{ - ready, - timeout, - deferred -}; -_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(future_status) - -_LIBCPP_VISIBLE -const error_category& future_category(); - -inline _LIBCPP_INLINE_VISIBILITY -error_code -make_error_code(future_errc __e) -{ - return error_code(static_cast(__e), future_category()); -} - -inline _LIBCPP_INLINE_VISIBILITY -error_condition -make_error_condition(future_errc __e) -{ - return error_condition(static_cast(__e), future_category()); -} - -class _LIBCPP_EXCEPTION_ABI future_error - : public logic_error -{ - error_code __ec_; -public: - future_error(error_code __ec); - - _LIBCPP_INLINE_VISIBILITY - const error_code& code() const throw() {return __ec_;} - - virtual ~future_error() _NOEXCEPT; -}; - -class __assoc_sub_state - : public __shared_count -{ -protected: - exception_ptr __exception_; - mutable mutex __mut_; - mutable condition_variable __cv_; - unsigned __state_; - - virtual void __on_zero_shared() _NOEXCEPT; - void __sub_wait(unique_lock& __lk); -public: - enum - { - __constructed = 1, - __future_attached = 2, - ready = 4, - deferred = 8 - }; - - _LIBCPP_INLINE_VISIBILITY - __assoc_sub_state() : __state_(0) {} - - _LIBCPP_INLINE_VISIBILITY - bool __has_value() const - {return (__state_ & __constructed) || (__exception_ != nullptr);} - - _LIBCPP_INLINE_VISIBILITY - void __set_future_attached() {__state_ |= __future_attached;} - _LIBCPP_INLINE_VISIBILITY - bool __has_future_attached() const {return __state_ & __future_attached;} - - _LIBCPP_INLINE_VISIBILITY - void __set_deferred() {__state_ |= deferred;} - - void __make_ready(); - _LIBCPP_INLINE_VISIBILITY - bool __is_ready() const {return __state_ & ready;} - - void set_value(); - void set_value_at_thread_exit(); - - void set_exception(exception_ptr __p); - void set_exception_at_thread_exit(exception_ptr __p); - - void copy(); - - void wait(); - template - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const; - template - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const; - - virtual void __execute(); -}; - -template -future_status -__assoc_sub_state::wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const -{ - unique_lock __lk(__mut_); - if (__state_ & deferred) - return future_status::deferred; - while (!(__state_ & ready) && _Clock::now() < __abs_time) - __cv_.wait_until(__lk, __abs_time); - if (__state_ & ready) - return future_status::ready; - return future_status::timeout; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -future_status -__assoc_sub_state::wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const -{ - return wait_until(chrono::steady_clock::now() + __rel_time); -} - -template -class __assoc_state - : public __assoc_sub_state -{ - typedef __assoc_sub_state base; - typedef typename aligned_storage::value>::type _Up; -protected: - _Up __value_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: - - template -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void set_value(_Arg&& __arg); -#else - void set_value(_Arg& __arg); -#endif - - template -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void set_value_at_thread_exit(_Arg&& __arg); -#else - void set_value_at_thread_exit(_Arg& __arg); -#endif - - _Rp move(); - typename add_lvalue_reference<_Rp>::type copy(); -}; - -template -void -__assoc_state<_Rp>::__on_zero_shared() _NOEXCEPT -{ - if (this->__state_ & base::__constructed) - reinterpret_cast<_Rp*>(&__value_)->~_Rp(); - delete this; -} - -template -template -void -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__assoc_state<_Rp>::set_value(_Arg&& __arg) -#else -__assoc_state<_Rp>::set_value(_Arg& __arg) -#endif -{ - unique_lock __lk(this->__mut_); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (this->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); -#endif - ::new(&__value_) _Rp(_VSTD::forward<_Arg>(__arg)); - this->__state_ |= base::__constructed | base::ready; - __lk.unlock(); - __cv_.notify_all(); -} - -template -template -void -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__assoc_state<_Rp>::set_value_at_thread_exit(_Arg&& __arg) -#else -__assoc_state<_Rp>::set_value_at_thread_exit(_Arg& __arg) -#endif -{ - unique_lock __lk(this->__mut_); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (this->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); -#endif - ::new(&__value_) _Rp(_VSTD::forward<_Arg>(__arg)); - this->__state_ |= base::__constructed; - __thread_local_data()->__make_ready_at_thread_exit(this); - __lk.unlock(); -} - -template -_Rp -__assoc_state<_Rp>::move() -{ - unique_lock __lk(this->__mut_); - this->__sub_wait(__lk); - if (this->__exception_ != nullptr) - rethrow_exception(this->__exception_); - return _VSTD::move(*reinterpret_cast<_Rp*>(&__value_)); -} - -template -typename add_lvalue_reference<_Rp>::type -__assoc_state<_Rp>::copy() -{ - unique_lock __lk(this->__mut_); - this->__sub_wait(__lk); - if (this->__exception_ != nullptr) - rethrow_exception(this->__exception_); - return *reinterpret_cast<_Rp*>(&__value_); -} - -template -class __assoc_state<_Rp&> - : public __assoc_sub_state -{ - typedef __assoc_sub_state base; - typedef _Rp* _Up; -protected: - _Up __value_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: - - void set_value(_Rp& __arg); - void set_value_at_thread_exit(_Rp& __arg); - - _Rp& copy(); -}; - -template -void -__assoc_state<_Rp&>::__on_zero_shared() _NOEXCEPT -{ - delete this; -} - -template -void -__assoc_state<_Rp&>::set_value(_Rp& __arg) -{ - unique_lock __lk(this->__mut_); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (this->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); -#endif - __value_ = &__arg; - this->__state_ |= base::__constructed | base::ready; - __lk.unlock(); - __cv_.notify_all(); -} - -template -void -__assoc_state<_Rp&>::set_value_at_thread_exit(_Rp& __arg) -{ - unique_lock __lk(this->__mut_); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (this->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); -#endif - __value_ = &__arg; - this->__state_ |= base::__constructed; - __thread_local_data()->__make_ready_at_thread_exit(this); - __lk.unlock(); -} - -template -_Rp& -__assoc_state<_Rp&>::copy() -{ - unique_lock __lk(this->__mut_); - this->__sub_wait(__lk); - if (this->__exception_ != nullptr) - rethrow_exception(this->__exception_); - return *__value_; -} - -template -class __assoc_state_alloc - : public __assoc_state<_Rp> -{ - typedef __assoc_state<_Rp> base; - _Alloc __alloc_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __assoc_state_alloc(const _Alloc& __a) - : __alloc_(__a) {} -}; - -template -void -__assoc_state_alloc<_Rp, _Alloc>::__on_zero_shared() _NOEXCEPT -{ - if (this->__state_ & base::__constructed) - reinterpret_cast<_Rp*>(&this->__value_)->~_Rp(); - typename _Alloc::template rebind<__assoc_state_alloc>::other __a(__alloc_); - this->~__assoc_state_alloc(); - __a.deallocate(this, 1); -} - -template -class __assoc_state_alloc<_Rp&, _Alloc> - : public __assoc_state<_Rp&> -{ - typedef __assoc_state<_Rp&> base; - _Alloc __alloc_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __assoc_state_alloc(const _Alloc& __a) - : __alloc_(__a) {} -}; - -template -void -__assoc_state_alloc<_Rp&, _Alloc>::__on_zero_shared() _NOEXCEPT -{ - typename _Alloc::template rebind<__assoc_state_alloc>::other __a(__alloc_); - this->~__assoc_state_alloc(); - __a.deallocate(this, 1); -} - -template -class __assoc_sub_state_alloc - : public __assoc_sub_state -{ - typedef __assoc_sub_state base; - _Alloc __alloc_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __assoc_sub_state_alloc(const _Alloc& __a) - : __alloc_(__a) {} -}; - -template -void -__assoc_sub_state_alloc<_Alloc>::__on_zero_shared() _NOEXCEPT -{ - this->~base(); - typename _Alloc::template rebind<__assoc_sub_state_alloc>::other __a(__alloc_); - this->~__assoc_sub_state_alloc(); - __a.deallocate(this, 1); -} - -template -class __deferred_assoc_state - : public __assoc_state<_Rp> -{ - typedef __assoc_state<_Rp> base; - - _Fp __func_; - -public: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - explicit __deferred_assoc_state(_Fp&& __f); -#endif - - virtual void __execute(); -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -__deferred_assoc_state<_Rp, _Fp>::__deferred_assoc_state(_Fp&& __f) - : __func_(_VSTD::forward<_Fp>(__f)) -{ - this->__set_deferred(); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__deferred_assoc_state<_Rp, _Fp>::__execute() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - this->set_value(__func_()); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -class __deferred_assoc_state - : public __assoc_sub_state -{ - typedef __assoc_sub_state base; - - _Fp __func_; - -public: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - explicit __deferred_assoc_state(_Fp&& __f); -#endif - - virtual void __execute(); -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -__deferred_assoc_state::__deferred_assoc_state(_Fp&& __f) - : __func_(_VSTD::forward<_Fp>(__f)) -{ - this->__set_deferred(); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__deferred_assoc_state::__execute() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __func_(); - this->set_value(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -class __async_assoc_state - : public __assoc_state<_Rp> -{ - typedef __assoc_state<_Rp> base; - - _Fp __func_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - explicit __async_assoc_state(_Fp&& __f); -#endif - - virtual void __execute(); -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -__async_assoc_state<_Rp, _Fp>::__async_assoc_state(_Fp&& __f) - : __func_(_VSTD::forward<_Fp>(__f)) -{ -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__async_assoc_state<_Rp, _Fp>::__execute() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - this->set_value(__func_()); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -__async_assoc_state<_Rp, _Fp>::__on_zero_shared() _NOEXCEPT -{ - this->wait(); - base::__on_zero_shared(); -} - -template -class __async_assoc_state - : public __assoc_sub_state -{ - typedef __assoc_sub_state base; - - _Fp __func_; - - virtual void __on_zero_shared() _NOEXCEPT; -public: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - explicit __async_assoc_state(_Fp&& __f); -#endif - - virtual void __execute(); -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -__async_assoc_state::__async_assoc_state(_Fp&& __f) - : __func_(_VSTD::forward<_Fp>(__f)) -{ -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -__async_assoc_state::__execute() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __func_(); - this->set_value(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -__async_assoc_state::__on_zero_shared() _NOEXCEPT -{ - this->wait(); - base::__on_zero_shared(); -} - -template class promise; -template class shared_future; - -// future - -template class future; - -template -future<_Rp> -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__make_deferred_assoc_state(_Fp&& __f); -#else -__make_deferred_assoc_state(_Fp __f); -#endif - -template -future<_Rp> -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__make_async_assoc_state(_Fp&& __f); -#else -__make_async_assoc_state(_Fp __f); -#endif - -template -class _LIBCPP_VISIBLE future -{ - __assoc_state<_Rp>* __state_; - - explicit future(__assoc_state<_Rp>* __state); - - template friend class promise; - template friend class shared_future; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - friend future<_R1> __make_deferred_assoc_state(_Fp&& __f); - template - friend future<_R1> __make_async_assoc_state(_Fp&& __f); -#else - template - friend future<_R1> __make_deferred_assoc_state(_Fp __f); - template - friend future<_R1> __make_async_assoc_state(_Fp __f); -#endif - -public: - _LIBCPP_INLINE_VISIBILITY - future() : __state_(nullptr) {} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - future(future&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - future(const future&) = delete; - future& operator=(const future&) = delete; - _LIBCPP_INLINE_VISIBILITY - future& operator=(future&& __rhs) - { - future(std::move(__rhs)).swap(*this); - return *this; - } -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - future(const future&); - future& operator=(const future&); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~future(); - shared_future<_Rp> share(); - - // retrieving the value - _Rp get(); - - _LIBCPP_INLINE_VISIBILITY - void swap(future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -future<_Rp>::future(__assoc_state<_Rp>* __state) - : __state_(__state) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_->__has_future_attached()) - throw future_error(make_error_code(future_errc::future_already_retrieved)); -#endif - __state_->__add_shared(); - __state_->__set_future_attached(); -} - -struct __release_shared_count -{ - void operator()(__shared_count* p) {p->__release_shared();} -}; - -template -future<_Rp>::~future() -{ - if (__state_) - __state_->__release_shared(); -} - -template -_Rp -future<_Rp>::get() -{ - unique_ptr<__shared_count, __release_shared_count> __(__state_); - __assoc_state<_Rp>* __s = __state_; - __state_ = nullptr; - return __s->move(); -} - -template -class _LIBCPP_VISIBLE future<_Rp&> -{ - __assoc_state<_Rp&>* __state_; - - explicit future(__assoc_state<_Rp&>* __state); - - template friend class promise; - template friend class shared_future; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - friend future<_R1> __make_deferred_assoc_state(_Fp&& __f); - template - friend future<_R1> __make_async_assoc_state(_Fp&& __f); -#else - template - friend future<_R1> __make_deferred_assoc_state(_Fp __f); - template - friend future<_R1> __make_async_assoc_state(_Fp __f); -#endif - -public: - _LIBCPP_INLINE_VISIBILITY - future() : __state_(nullptr) {} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - future(future&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - future(const future&) = delete; - future& operator=(const future&) = delete; - _LIBCPP_INLINE_VISIBILITY - future& operator=(future&& __rhs) - { - future(std::move(__rhs)).swap(*this); - return *this; - } -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - future(const future&); - future& operator=(const future&); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~future(); - shared_future<_Rp&> share(); - - // retrieving the value - _Rp& get(); - - _LIBCPP_INLINE_VISIBILITY - void swap(future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -future<_Rp&>::future(__assoc_state<_Rp&>* __state) - : __state_(__state) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_->__has_future_attached()) - throw future_error(make_error_code(future_errc::future_already_retrieved)); -#endif - __state_->__add_shared(); - __state_->__set_future_attached(); -} - -template -future<_Rp&>::~future() -{ - if (__state_) - __state_->__release_shared(); -} - -template -_Rp& -future<_Rp&>::get() -{ - unique_ptr<__shared_count, __release_shared_count> __(__state_); - __assoc_state<_Rp&>* __s = __state_; - __state_ = nullptr; - return __s->copy(); -} - -template <> -class _LIBCPP_VISIBLE future -{ - __assoc_sub_state* __state_; - - explicit future(__assoc_sub_state* __state); - - template friend class promise; - template friend class shared_future; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - friend future<_R1> __make_deferred_assoc_state(_Fp&& __f); - template - friend future<_R1> __make_async_assoc_state(_Fp&& __f); -#else - template - friend future<_R1> __make_deferred_assoc_state(_Fp __f); - template - friend future<_R1> __make_async_assoc_state(_Fp __f); -#endif - -public: - _LIBCPP_INLINE_VISIBILITY - future() : __state_(nullptr) {} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - future(future&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - future(const future&) = delete; - future& operator=(const future&) = delete; - _LIBCPP_INLINE_VISIBILITY - future& operator=(future&& __rhs) - { - future(std::move(__rhs)).swap(*this); - return *this; - } -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - future(const future&); - future& operator=(const future&); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~future(); - shared_future share(); - - // retrieving the value - void get(); - - _LIBCPP_INLINE_VISIBILITY - void swap(future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(future<_Rp>& __x, future<_Rp>& __y) -{ - __x.swap(__y); -} - -// promise - -template class packaged_task; - -template -class _LIBCPP_VISIBLE promise -{ - __assoc_state<_Rp>* __state_; - - _LIBCPP_INLINE_VISIBILITY - explicit promise(nullptr_t) : __state_(nullptr) {} - - template friend class packaged_task; -public: - promise(); - template - promise(allocator_arg_t, const _Alloc& __a); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise(promise&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - promise(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~promise(); - - // assignment -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise& operator=(promise&& __rhs) - { - promise(std::move(__rhs)).swap(*this); - return *this; - } - promise& operator=(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise& operator=(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void swap(promise& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // retrieving the result - future<_Rp> get_future(); - - // setting the result - void set_value(const _Rp& __r); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void set_value(_Rp&& __r); -#endif - void set_exception(exception_ptr __p); - - // setting the result with deferred notification - void set_value_at_thread_exit(const _Rp& __r); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void set_value_at_thread_exit(_Rp&& __r); -#endif - void set_exception_at_thread_exit(exception_ptr __p); -}; - -template -promise<_Rp>::promise() - : __state_(new __assoc_state<_Rp>) -{ -} - -template -template -promise<_Rp>::promise(allocator_arg_t, const _Alloc& __a0) -{ - typedef typename _Alloc::template rebind<__assoc_state_alloc<_Rp, _Alloc> >::other _A2; - typedef __allocator_destructor<_A2> _D2; - _A2 __a(__a0); - unique_ptr<__assoc_state_alloc<_Rp, _Alloc>, _D2> __hold(__a.allocate(1), _D2(__a, 1)); - ::new(__hold.get()) __assoc_state_alloc<_Rp, _Alloc>(__a0); - __state_ = __hold.release(); -} - -template -promise<_Rp>::~promise() -{ - if (__state_) - { - if (!__state_->__has_value() && __state_->use_count() > 1) - __state_->set_exception(make_exception_ptr( - future_error(make_error_code(future_errc::broken_promise)) - )); - __state_->__release_shared(); - } -} - -template -future<_Rp> -promise<_Rp>::get_future() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - return future<_Rp>(__state_); -} - -template -void -promise<_Rp>::set_value(const _Rp& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value(__r); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -promise<_Rp>::set_value(_Rp&& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value(_VSTD::move(__r)); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -promise<_Rp>::set_exception(exception_ptr __p) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_exception(__p); -} - -template -void -promise<_Rp>::set_value_at_thread_exit(const _Rp& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value_at_thread_exit(__r); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -promise<_Rp>::set_value_at_thread_exit(_Rp&& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value_at_thread_exit(_VSTD::move(__r)); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -promise<_Rp>::set_exception_at_thread_exit(exception_ptr __p) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_exception_at_thread_exit(__p); -} - -// promise - -template -class _LIBCPP_VISIBLE promise<_Rp&> -{ - __assoc_state<_Rp&>* __state_; - - _LIBCPP_INLINE_VISIBILITY - explicit promise(nullptr_t) : __state_(nullptr) {} - - template friend class packaged_task; - -public: - promise(); - template - promise(allocator_arg_t, const _Allocator& __a); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise(promise&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - promise(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~promise(); - - // assignment -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise& operator=(promise&& __rhs) - { - promise(std::move(__rhs)).swap(*this); - return *this; - } - promise& operator=(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise& operator=(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void swap(promise& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // retrieving the result - future<_Rp&> get_future(); - - // setting the result - void set_value(_Rp& __r); - void set_exception(exception_ptr __p); - - // setting the result with deferred notification - void set_value_at_thread_exit(_Rp&); - void set_exception_at_thread_exit(exception_ptr __p); -}; - -template -promise<_Rp&>::promise() - : __state_(new __assoc_state<_Rp&>) -{ -} - -template -template -promise<_Rp&>::promise(allocator_arg_t, const _Alloc& __a0) -{ - typedef typename _Alloc::template rebind<__assoc_state_alloc<_Rp&, _Alloc> >::other _A2; - typedef __allocator_destructor<_A2> _D2; - _A2 __a(__a0); - unique_ptr<__assoc_state_alloc<_Rp&, _Alloc>, _D2> __hold(__a.allocate(1), _D2(__a, 1)); - ::new(__hold.get()) __assoc_state_alloc<_Rp&, _Alloc>(__a0); - __state_ = __hold.release(); -} - -template -promise<_Rp&>::~promise() -{ - if (__state_) - { - if (!__state_->__has_value() && __state_->use_count() > 1) - __state_->set_exception(make_exception_ptr( - future_error(make_error_code(future_errc::broken_promise)) - )); - __state_->__release_shared(); - } -} - -template -future<_Rp&> -promise<_Rp&>::get_future() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - return future<_Rp&>(__state_); -} - -template -void -promise<_Rp&>::set_value(_Rp& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value(__r); -} - -template -void -promise<_Rp&>::set_exception(exception_ptr __p) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_exception(__p); -} - -template -void -promise<_Rp&>::set_value_at_thread_exit(_Rp& __r) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_value_at_thread_exit(__r); -} - -template -void -promise<_Rp&>::set_exception_at_thread_exit(exception_ptr __p) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); -#endif - __state_->set_exception_at_thread_exit(__p); -} - -// promise - -template <> -class _LIBCPP_VISIBLE promise -{ - __assoc_sub_state* __state_; - - _LIBCPP_INLINE_VISIBILITY - explicit promise(nullptr_t) : __state_(nullptr) {} - - template friend class packaged_task; - -public: - promise(); - template - promise(allocator_arg_t, const _Allocator& __a); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise(promise&& __rhs) - : __state_(__rhs.__state_) {__rhs.__state_ = nullptr;} - promise(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~promise(); - - // assignment -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - promise& operator=(promise&& __rhs) - { - promise(std::move(__rhs)).swap(*this); - return *this; - } - promise& operator=(const promise& __rhs) = delete; -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES -private: - promise& operator=(const promise& __rhs); -public: -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void swap(promise& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // retrieving the result - future get_future(); - - // setting the result - void set_value(); - void set_exception(exception_ptr __p); - - // setting the result with deferred notification - void set_value_at_thread_exit(); - void set_exception_at_thread_exit(exception_ptr __p); -}; - -template -promise::promise(allocator_arg_t, const _Alloc& __a0) -{ - typedef typename _Alloc::template rebind<__assoc_sub_state_alloc<_Alloc> >::other _A2; - typedef __allocator_destructor<_A2> _D2; - _A2 __a(__a0); - unique_ptr<__assoc_sub_state_alloc<_Alloc>, _D2> __hold(__a.allocate(1), _D2(__a, 1)); - ::new(__hold.get()) __assoc_sub_state_alloc<_Alloc>(__a0); - __state_ = __hold.release(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(promise<_Rp>& __x, promise<_Rp>& __y) -{ - __x.swap(__y); -} - -template - struct _LIBCPP_VISIBLE uses_allocator, _Alloc> - : public true_type {}; - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -// packaged_task - -template class __packaged_task_base; - -template -class __packaged_task_base<_Rp(_ArgTypes...)> -{ - __packaged_task_base(const __packaged_task_base&); - __packaged_task_base& operator=(const __packaged_task_base&); -public: - _LIBCPP_INLINE_VISIBILITY - __packaged_task_base() {} - _LIBCPP_INLINE_VISIBILITY - virtual ~__packaged_task_base() {} - virtual void __move_to(__packaged_task_base*) = 0; - virtual void destroy() = 0; - virtual void destroy_deallocate() = 0; - virtual _Rp operator()(_ArgTypes&& ...) = 0; -}; - -template class __packaged_task_func; - -template -class __packaged_task_func<_Fp, _Alloc, _Rp(_ArgTypes...)> - : public __packaged_task_base<_Rp(_ArgTypes...)> -{ - __compressed_pair<_Fp, _Alloc> __f_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __packaged_task_func(const _Fp& __f) : __f_(__f) {} - _LIBCPP_INLINE_VISIBILITY - explicit __packaged_task_func(_Fp&& __f) : __f_(_VSTD::move(__f)) {} - _LIBCPP_INLINE_VISIBILITY - __packaged_task_func(const _Fp& __f, const _Alloc& __a) - : __f_(__f, __a) {} - _LIBCPP_INLINE_VISIBILITY - __packaged_task_func(_Fp&& __f, const _Alloc& __a) - : __f_(_VSTD::move(__f), __a) {} - virtual void __move_to(__packaged_task_base<_Rp(_ArgTypes...)>*); - virtual void destroy(); - virtual void destroy_deallocate(); - virtual _Rp operator()(_ArgTypes&& ... __args); -}; - -template -void -__packaged_task_func<_Fp, _Alloc, _Rp(_ArgTypes...)>::__move_to( - __packaged_task_base<_Rp(_ArgTypes...)>* __p) -{ - ::new (__p) __packaged_task_func(_VSTD::move(__f_.first()), _VSTD::move(__f_.second())); -} - -template -void -__packaged_task_func<_Fp, _Alloc, _Rp(_ArgTypes...)>::destroy() -{ - __f_.~__compressed_pair<_Fp, _Alloc>(); -} - -template -void -__packaged_task_func<_Fp, _Alloc, _Rp(_ArgTypes...)>::destroy_deallocate() -{ - typedef typename _Alloc::template rebind<__packaged_task_func>::other _Ap; - _Ap __a(__f_.second()); - __f_.~__compressed_pair<_Fp, _Alloc>(); - __a.deallocate(this, 1); -} - -template -_Rp -__packaged_task_func<_Fp, _Alloc, _Rp(_ArgTypes...)>::operator()(_ArgTypes&& ... __arg) -{ - return __invoke(__f_.first(), _VSTD::forward<_ArgTypes>(__arg)...); -} - -template class __packaged_task_function; - -template -class __packaged_task_function<_Rp(_ArgTypes...)> -{ - typedef __packaged_task_base<_Rp(_ArgTypes...)> __base; - aligned_storage<3*sizeof(void*)>::type __buf_; - __base* __f_; - -public: - typedef _Rp result_type; - - // construct/copy/destroy: - _LIBCPP_INLINE_VISIBILITY - __packaged_task_function() : __f_(nullptr) {} - template - __packaged_task_function(_Fp&& __f); - template - __packaged_task_function(allocator_arg_t, const _Alloc& __a, _Fp&& __f); - - __packaged_task_function(__packaged_task_function&&); - __packaged_task_function& operator=(__packaged_task_function&&); - - __packaged_task_function(const __packaged_task_function&) = delete; - __packaged_task_function& operator=(const __packaged_task_function&) = delete; - - ~__packaged_task_function(); - - void swap(__packaged_task_function&); - - _Rp operator()(_ArgTypes...) const; -}; - -template -__packaged_task_function<_Rp(_ArgTypes...)>::__packaged_task_function(__packaged_task_function&& __f) -{ - if (__f.__f_ == nullptr) - __f_ = nullptr; - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__move_to(__f_); - } - else - { - __f_ = __f.__f_; - __f.__f_ = nullptr; - } -} - -template -template -__packaged_task_function<_Rp(_ArgTypes...)>::__packaged_task_function(_Fp&& __f) - : __f_(nullptr) -{ - typedef typename remove_reference<_Fp>::type _FR; - typedef __packaged_task_func<_FR, allocator<_FR>, _Rp(_ArgTypes...)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(_VSTD::forward<_Fp>(__f)); - } - else - { - typedef allocator<_FF> _Ap; - _Ap __a; - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(_VSTD::forward<_Fp>(__f), allocator<_FR>(__a)); - __f_ = __hold.release(); - } -} - -template -template -__packaged_task_function<_Rp(_ArgTypes...)>::__packaged_task_function( - allocator_arg_t, const _Alloc& __a0, _Fp&& __f) - : __f_(nullptr) -{ - typedef allocator_traits<_Alloc> __alloc_traits; - typedef typename remove_reference<_Fp>::type _FR; - typedef __packaged_task_func<_FR, _Alloc, _Rp(_ArgTypes...)> _FF; - if (sizeof(_FF) <= sizeof(__buf_)) - { - __f_ = (__base*)&__buf_; - ::new (__f_) _FF(_VSTD::forward<_Fp>(__f)); - } - else - { - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<_FF> -#else - rebind_alloc<_FF>::other -#endif - _Ap; - _Ap __a(__a0); - typedef __allocator_destructor<_Ap> _Dp; - unique_ptr<__base, _Dp> __hold(__a.allocate(1), _Dp(__a, 1)); - ::new (__hold.get()) _FF(_VSTD::forward<_Fp>(__f), _Alloc(__a)); - __f_ = __hold.release(); - } -} - -template -__packaged_task_function<_Rp(_ArgTypes...)>& -__packaged_task_function<_Rp(_ArgTypes...)>::operator=(__packaged_task_function&& __f) -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); - __f_ = nullptr; - if (__f.__f_ == nullptr) - __f_ = nullptr; - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f_ = (__base*)&__buf_; - __f.__f_->__move_to(__f_); - } - else - { - __f_ = __f.__f_; - __f.__f_ = nullptr; - } -} - -template -__packaged_task_function<_Rp(_ArgTypes...)>::~__packaged_task_function() -{ - if (__f_ == (__base*)&__buf_) - __f_->destroy(); - else if (__f_) - __f_->destroy_deallocate(); -} - -template -void -__packaged_task_function<_Rp(_ArgTypes...)>::swap(__packaged_task_function& __f) -{ - if (__f_ == (__base*)&__buf_ && __f.__f_ == (__base*)&__f.__buf_) - { - typename aligned_storage::type __tempbuf; - __base* __t = (__base*)&__tempbuf; - __f_->__move_to(__t); - __f_->destroy(); - __f_ = nullptr; - __f.__f_->__move_to((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = nullptr; - __f_ = (__base*)&__buf_; - __t->__move_to((__base*)&__f.__buf_); - __t->destroy(); - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f_ == (__base*)&__buf_) - { - __f_->__move_to((__base*)&__f.__buf_); - __f_->destroy(); - __f_ = __f.__f_; - __f.__f_ = (__base*)&__f.__buf_; - } - else if (__f.__f_ == (__base*)&__f.__buf_) - { - __f.__f_->__move_to((__base*)&__buf_); - __f.__f_->destroy(); - __f.__f_ = __f_; - __f_ = (__base*)&__buf_; - } - else - _VSTD::swap(__f_, __f.__f_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Rp -__packaged_task_function<_Rp(_ArgTypes...)>::operator()(_ArgTypes... __arg) const -{ - return (*__f_)(_VSTD::forward<_ArgTypes>(__arg)...); -} - -template -class _LIBCPP_VISIBLE packaged_task<_Rp(_ArgTypes...)> -{ -public: - typedef _Rp result_type; - -private: - __packaged_task_function __f_; - promise __p_; - -public: - // construction and destruction - _LIBCPP_INLINE_VISIBILITY - packaged_task() : __p_(nullptr) {} - template - _LIBCPP_INLINE_VISIBILITY - explicit packaged_task(_Fp&& __f) : __f_(_VSTD::forward<_Fp>(__f)) {} - template - _LIBCPP_INLINE_VISIBILITY - explicit packaged_task(allocator_arg_t, const _Allocator& __a, _Fp&& __f) - : __f_(allocator_arg, __a, _VSTD::forward<_Fp>(__f)), - __p_(allocator_arg, __a) {} - // ~packaged_task() = default; - - // no copy - packaged_task(packaged_task&) = delete; - packaged_task& operator=(packaged_task&) = delete; - - // move support - _LIBCPP_INLINE_VISIBILITY - packaged_task(packaged_task&& __other) - : __f_(_VSTD::move(__other.__f_)), __p_(_VSTD::move(__other.__p_)) {} - _LIBCPP_INLINE_VISIBILITY - packaged_task& operator=(packaged_task&& __other) - { - __f_ = _VSTD::move(__other.__f_); - __p_ = _VSTD::move(__other.__p_); - return *this; - } - _LIBCPP_INLINE_VISIBILITY - void swap(packaged_task& __other) - { - __f_.swap(__other.__f_); - __p_.swap(__other.__p_); - } - - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __p_.__state_ != nullptr;} - - // result retrieval - _LIBCPP_INLINE_VISIBILITY - future get_future() {return __p_.get_future();} - - // execution - void operator()(_ArgTypes... __args); - void make_ready_at_thread_exit(_ArgTypes... __args); - - void reset(); -}; - -template -void -packaged_task<_Rp(_ArgTypes...)>::operator()(_ArgTypes... __args) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__p_.__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); - if (__p_.__state_->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __p_.set_value(__f_(_VSTD::forward<_ArgTypes>(__args)...)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __p_.set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -packaged_task<_Rp(_ArgTypes...)>::make_ready_at_thread_exit(_ArgTypes... __args) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__p_.__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); - if (__p_.__state_->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __p_.set_value_at_thread_exit(__f_(_VSTD::forward<_ArgTypes>(__args)...)); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __p_.set_exception_at_thread_exit(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -packaged_task<_Rp(_ArgTypes...)>::reset() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (!valid()) - throw future_error(make_error_code(future_errc::no_state)); -#endif // _LIBCPP_NO_EXCEPTIONS - __p_ = promise(); -} - -template -class _LIBCPP_VISIBLE packaged_task -{ -public: - typedef void result_type; - -private: - __packaged_task_function __f_; - promise __p_; - -public: - // construction and destruction - _LIBCPP_INLINE_VISIBILITY - packaged_task() : __p_(nullptr) {} - template - _LIBCPP_INLINE_VISIBILITY - explicit packaged_task(_Fp&& __f) : __f_(_VSTD::forward<_Fp>(__f)) {} - template - _LIBCPP_INLINE_VISIBILITY - explicit packaged_task(allocator_arg_t, const _Allocator& __a, _Fp&& __f) - : __f_(allocator_arg, __a, _VSTD::forward<_Fp>(__f)), - __p_(allocator_arg, __a) {} - // ~packaged_task() = default; - - // no copy - packaged_task(packaged_task&) = delete; - packaged_task& operator=(packaged_task&) = delete; - - // move support - _LIBCPP_INLINE_VISIBILITY - packaged_task(packaged_task&& __other) - : __f_(_VSTD::move(__other.__f_)), __p_(_VSTD::move(__other.__p_)) {} - _LIBCPP_INLINE_VISIBILITY - packaged_task& operator=(packaged_task&& __other) - { - __f_ = _VSTD::move(__other.__f_); - __p_ = _VSTD::move(__other.__p_); - return *this; - } - _LIBCPP_INLINE_VISIBILITY - void swap(packaged_task& __other) - { - __f_.swap(__other.__f_); - __p_.swap(__other.__p_); - } - - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __p_.__state_ != nullptr;} - - // result retrieval - _LIBCPP_INLINE_VISIBILITY - future get_future() {return __p_.get_future();} - - // execution - void operator()(_ArgTypes... __args); - void make_ready_at_thread_exit(_ArgTypes... __args); - - void reset(); -}; - -template -void -packaged_task::operator()(_ArgTypes... __args) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__p_.__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); - if (__p_.__state_->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __f_(_VSTD::forward<_ArgTypes>(__args)...); - __p_.set_value(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __p_.set_exception(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -packaged_task::make_ready_at_thread_exit(_ArgTypes... __args) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__p_.__state_ == nullptr) - throw future_error(make_error_code(future_errc::no_state)); - if (__p_.__state_->__has_value()) - throw future_error(make_error_code(future_errc::promise_already_satisfied)); - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - __f_(_VSTD::forward<_ArgTypes>(__args)...); - __p_.set_value_at_thread_exit(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __p_.set_exception_at_thread_exit(current_exception()); - } -#endif // _LIBCPP_NO_EXCEPTIONS -} - -template -void -packaged_task::reset() -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - if (!valid()) - throw future_error(make_error_code(future_errc::no_state)); -#endif // _LIBCPP_NO_EXCEPTIONS - __p_ = promise(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(packaged_task<_Callable>& __x, packaged_task<_Callable>& __y) -{ - __x.swap(__y); -} - -template -struct _LIBCPP_VISIBLE uses_allocator, _Alloc> - : public true_type {}; - -template -future<_Rp> -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__make_deferred_assoc_state(_Fp&& __f) -#else -__make_deferred_assoc_state(_Fp __f) -#endif -{ - unique_ptr<__deferred_assoc_state<_Rp, _Fp>, __release_shared_count> - __h(new __deferred_assoc_state<_Rp, _Fp>(_VSTD::forward<_Fp>(__f))); - return future<_Rp>(__h.get()); -} - -template -future<_Rp> -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES -__make_async_assoc_state(_Fp&& __f) -#else -__make_async_assoc_state(_Fp __f) -#endif -{ - unique_ptr<__async_assoc_state<_Rp, _Fp>, __release_shared_count> - __h(new __async_assoc_state<_Rp, _Fp>(_VSTD::forward<_Fp>(__f))); - _VSTD::thread(&__async_assoc_state<_Rp, _Fp>::__execute, __h.get()).detach(); - return future<_Rp>(__h.get()); -} - -template -class __async_func -{ - tuple<_Fp, _Args...> __f_; - -public: - typedef typename __invoke_of<_Fp, _Args...>::type _Rp; - - _LIBCPP_INLINE_VISIBILITY - explicit __async_func(_Fp&& __f, _Args&&... __args) - : __f_(_VSTD::move(__f), _VSTD::move(__args)...) {} - - _LIBCPP_INLINE_VISIBILITY - __async_func(__async_func&& __f) : __f_(_VSTD::move(__f.__f_)) {} - - _Rp operator()() - { - typedef typename __make_tuple_indices<1+sizeof...(_Args), 1>::type _Index; - return __execute(_Index()); - } -private: - template - _Rp - __execute(__tuple_indices<_Indices...>) - { - return __invoke(_VSTD::move(_VSTD::get<0>(__f_)), _VSTD::move(_VSTD::get<_Indices>(__f_))...); - } -}; - -template -future::type, typename decay<_Args>::type...>::type> -async(launch __policy, _Fp&& __f, _Args&&... __args) -{ - typedef __async_func::type, typename decay<_Args>::type...> _BF; - typedef typename _BF::_Rp _Rp; - future<_Rp> __r; - if (int(__policy) & int(launch::async)) - __r = _VSTD::__make_async_assoc_state<_Rp>(_BF(__decay_copy(_VSTD::forward<_Fp>(__f)), - __decay_copy(_VSTD::forward<_Args>(__args))...)); - else if (int(__policy) & int(launch::deferred)) - __r = _VSTD::__make_deferred_assoc_state<_Rp>(_BF(__decay_copy(_VSTD::forward<_Fp>(__f)), - __decay_copy(_VSTD::forward<_Args>(__args))...)); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -future::type, typename decay<_Args>::type...>::type> -async(_Fp&& __f, _Args&&... __args) -{ - return _VSTD::async(launch::any, _VSTD::forward<_Fp>(__f), - _VSTD::forward<_Args>(__args)...); -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -// shared_future - -template -class _LIBCPP_VISIBLE shared_future -{ - __assoc_state<_Rp>* __state_; - -public: - _LIBCPP_INLINE_VISIBILITY - shared_future() : __state_(nullptr) {} - _LIBCPP_INLINE_VISIBILITY - shared_future(const shared_future& __rhs) : __state_(__rhs.__state_) - {if (__state_) __state_->__add_shared();} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future(future<_Rp>&& __f) : __state_(__f.__state_) - {__f.__state_ = nullptr;} - _LIBCPP_INLINE_VISIBILITY - shared_future(shared_future&& __rhs) : __state_(__rhs.__state_) - {__rhs.__state_ = nullptr;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~shared_future(); - shared_future& operator=(const shared_future& __rhs); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future& operator=(shared_future&& __rhs) - { - shared_future(std::move(__rhs)).swap(*this); - return *this; - } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - // retrieving the value - _LIBCPP_INLINE_VISIBILITY - const _Rp& get() const {return __state_->copy();} - - _LIBCPP_INLINE_VISIBILITY - void swap(shared_future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -shared_future<_Rp>::~shared_future() -{ - if (__state_) - __state_->__release_shared(); -} - -template -shared_future<_Rp>& -shared_future<_Rp>::operator=(const shared_future& __rhs) -{ - if (__rhs.__state_) - __rhs.__state_->__add_shared(); - if (__state_) - __state_->__release_shared(); - __state_ = __rhs.__state_; - return *this; -} - -template -class _LIBCPP_VISIBLE shared_future<_Rp&> -{ - __assoc_state<_Rp&>* __state_; - -public: - _LIBCPP_INLINE_VISIBILITY - shared_future() : __state_(nullptr) {} - _LIBCPP_INLINE_VISIBILITY - shared_future(const shared_future& __rhs) : __state_(__rhs.__state_) - {if (__state_) __state_->__add_shared();} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future(future<_Rp&>&& __f) : __state_(__f.__state_) - {__f.__state_ = nullptr;} - _LIBCPP_INLINE_VISIBILITY - shared_future(shared_future&& __rhs) : __state_(__rhs.__state_) - {__rhs.__state_ = nullptr;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~shared_future(); - shared_future& operator=(const shared_future& __rhs); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future& operator=(shared_future&& __rhs) - { - shared_future(std::move(__rhs)).swap(*this); - return *this; - } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - // retrieving the value - _LIBCPP_INLINE_VISIBILITY - _Rp& get() const {return __state_->copy();} - - _LIBCPP_INLINE_VISIBILITY - void swap(shared_future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -shared_future<_Rp&>::~shared_future() -{ - if (__state_) - __state_->__release_shared(); -} - -template -shared_future<_Rp&>& -shared_future<_Rp&>::operator=(const shared_future& __rhs) -{ - if (__rhs.__state_) - __rhs.__state_->__add_shared(); - if (__state_) - __state_->__release_shared(); - __state_ = __rhs.__state_; - return *this; -} - -template <> -class _LIBCPP_VISIBLE shared_future -{ - __assoc_sub_state* __state_; - -public: - _LIBCPP_INLINE_VISIBILITY - shared_future() : __state_(nullptr) {} - _LIBCPP_INLINE_VISIBILITY - shared_future(const shared_future& __rhs) : __state_(__rhs.__state_) - {if (__state_) __state_->__add_shared();} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future(future&& __f) : __state_(__f.__state_) - {__f.__state_ = nullptr;} - _LIBCPP_INLINE_VISIBILITY - shared_future(shared_future&& __rhs) : __state_(__rhs.__state_) - {__rhs.__state_ = nullptr;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - ~shared_future(); - shared_future& operator=(const shared_future& __rhs); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - shared_future& operator=(shared_future&& __rhs) - { - shared_future(std::move(__rhs)).swap(*this); - return *this; - } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - // retrieving the value - _LIBCPP_INLINE_VISIBILITY - void get() const {__state_->copy();} - - _LIBCPP_INLINE_VISIBILITY - void swap(shared_future& __rhs) {_VSTD::swap(__state_, __rhs.__state_);} - - // functions to check state - _LIBCPP_INLINE_VISIBILITY - bool valid() const {return __state_ != nullptr;} - - _LIBCPP_INLINE_VISIBILITY - void wait() const {__state_->wait();} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_for(const chrono::duration<_Rep, _Period>& __rel_time) const - {return __state_->wait_for(__rel_time);} - template - _LIBCPP_INLINE_VISIBILITY - future_status - wait_until(const chrono::time_point<_Clock, _Duration>& __abs_time) const - {return __state_->wait_until(__abs_time);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(shared_future<_Rp>& __x, shared_future<_Rp>& __y) -{ - __x.swap(__y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -shared_future<_Rp> -future<_Rp>::share() -{ - return shared_future<_Rp>(_VSTD::move(*this)); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -shared_future<_Rp&> -future<_Rp&>::share() -{ - return shared_future<_Rp&>(_VSTD::move(*this)); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -inline _LIBCPP_INLINE_VISIBILITY -shared_future -future::share() -{ - return shared_future(_VSTD::move(*this)); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_FUTURE diff --git a/libcxx/include/initializer_list b/libcxx/include/initializer_list deleted file mode 100644 index 2f88514b7f78..000000000000 --- a/libcxx/include/initializer_list +++ /dev/null @@ -1,105 +0,0 @@ -// -*- C++ -*- -//===----------------------- initializer_list -----------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_INITIALIZER_LIST -#define _LIBCPP_INITIALIZER_LIST - -/* - initializer_list synopsis - -namespace std -{ - -template -class initializer_list -{ -public: - typedef E value_type; - typedef const E& reference; - typedef const E& const_reference; - typedef size_t size_type; - - typedef const E* iterator; - typedef const E* const_iterator; - - initializer_list() noexcept; - - size_t size() const noexcept; - const E* begin() const noexcept; - const E* end() const noexcept; -}; - -template const E* begin(initializer_list il) noexcept; -template const E* end(initializer_list il) noexcept; - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -namespace std // purposefully not versioned -{ - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -class _LIBCPP_VISIBLE initializer_list -{ - const _Ep* __begin_; - size_t __size_; - - _LIBCPP_ALWAYS_INLINE - initializer_list(const _Ep* __b, size_t __s) _NOEXCEPT - : __begin_(__b), - __size_(__s) - {} -public: - typedef _Ep value_type; - typedef const _Ep& reference; - typedef const _Ep& const_reference; - typedef size_t size_type; - - typedef const _Ep* iterator; - typedef const _Ep* const_iterator; - - _LIBCPP_ALWAYS_INLINE initializer_list() _NOEXCEPT : __begin_(nullptr), __size_(0) {} - - _LIBCPP_ALWAYS_INLINE size_t size() const _NOEXCEPT {return __size_;} - _LIBCPP_ALWAYS_INLINE const _Ep* begin() const _NOEXCEPT {return __begin_;} - _LIBCPP_ALWAYS_INLINE const _Ep* end() const _NOEXCEPT {return __begin_ + __size_;} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Ep* -begin(initializer_list<_Ep> __il) _NOEXCEPT -{ - return __il.begin(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -const _Ep* -end(initializer_list<_Ep> __il) _NOEXCEPT -{ - return __il.end(); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -} // std - -#endif // _LIBCPP_INITIALIZER_LIST diff --git a/libcxx/include/iomanip b/libcxx/include/iomanip deleted file mode 100644 index 0c58e1980f3f..000000000000 --- a/libcxx/include/iomanip +++ /dev/null @@ -1,504 +0,0 @@ -// -*- C++ -*- -//===--------------------------- iomanip ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_IOMANIP -#define _LIBCPP_IOMANIP - -/* - iomanip synopsis - -// types T1, T2, ... are unspecified implementation types -T1 resetiosflags(ios_base::fmtflags mask); -T2 setiosflags (ios_base::fmtflags mask); -T3 setbase(int base); -template T4 setfill(charT c); -T5 setprecision(int n); -T6 setw(int n); -template T7 get_money(moneyT& mon, bool intl = false); -template T8 put_money(const moneyT& mon, bool intl = false); -template T9 get_time(struct tm* tmb, const charT* fmt); -template T10 put_time(const struct tm* tmb, const charT* fmt); - -} // std - -*/ - -#include <__config> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -// resetiosflags - -class __iom_t1 -{ - ios_base::fmtflags __mask_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t1(ios_base::fmtflags __m) : __mask_(__m) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t1& __x) - { - __is.unsetf(__x.__mask_); - return __is; - } - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t1& __x) - { - __os.unsetf(__x.__mask_); - return __os; - } -}; - -inline _LIBCPP_INLINE_VISIBILITY -__iom_t1 -resetiosflags(ios_base::fmtflags __mask) -{ - return __iom_t1(__mask); -} - -// setiosflags - -class __iom_t2 -{ - ios_base::fmtflags __mask_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t2(ios_base::fmtflags __m) : __mask_(__m) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t2& __x) - { - __is.setf(__x.__mask_); - return __is; - } - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t2& __x) - { - __os.setf(__x.__mask_); - return __os; - } -}; - -inline _LIBCPP_INLINE_VISIBILITY -__iom_t2 -setiosflags(ios_base::fmtflags __mask) -{ - return __iom_t2(__mask); -} - -// setbase - -class __iom_t3 -{ - int __base_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t3(int __b) : __base_(__b) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t3& __x) - { - __is.setf(__x.__base_ == 8 ? ios_base::oct : - __x.__base_ == 10 ? ios_base::dec : - __x.__base_ == 16 ? ios_base::hex : - ios_base::fmtflags(0), ios_base::basefield); - return __is; - } - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t3& __x) - { - __os.setf(__x.__base_ == 8 ? ios_base::oct : - __x.__base_ == 10 ? ios_base::dec : - __x.__base_ == 16 ? ios_base::hex : - ios_base::fmtflags(0), ios_base::basefield); - return __os; - } -}; - -inline _LIBCPP_INLINE_VISIBILITY -__iom_t3 -setbase(int __base) -{ - return __iom_t3(__base); -} - -// setfill - -template -class __iom_t4 -{ - _CharT __fill_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t4(_CharT __c) : __fill_(__c) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t4& __x) - { - __os.fill(__x.__fill_); - return __os; - } -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -__iom_t4<_CharT> -setfill(_CharT __c) -{ - return __iom_t4<_CharT>(__c); -} - -// setprecision - -class __iom_t5 -{ - int __n_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t5(int __n) : __n_(__n) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t5& __x) - { - __is.precision(__x.__n_); - return __is; - } - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t5& __x) - { - __os.precision(__x.__n_); - return __os; - } -}; - -inline _LIBCPP_INLINE_VISIBILITY -__iom_t5 -setprecision(int __n) -{ - return __iom_t5(__n); -} - -// setw - -class __iom_t6 -{ - int __n_; -public: - _LIBCPP_INLINE_VISIBILITY - explicit __iom_t6(int __n) : __n_(__n) {} - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t6& __x) - { - __is.width(__x.__n_); - return __is; - } - - template - friend - _LIBCPP_INLINE_VISIBILITY - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t6& __x) - { - __os.width(__x.__n_); - return __os; - } -}; - -inline _LIBCPP_INLINE_VISIBILITY -__iom_t6 -setw(int __n) -{ - return __iom_t6(__n); -} - -// get_money - -template class __iom_t7; - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t7<_MoneyT>& __x); - -template -class __iom_t7 -{ - _MoneyT& __mon_; - bool __intl_; -public: - _LIBCPP_INLINE_VISIBILITY - __iom_t7(_MoneyT& __mon, bool __intl) - : __mon_(__mon), __intl_(__intl) {} - - template - friend - basic_istream<_CharT, _Traits>& - operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t7<_Mp>& __x); -}; - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t7<_MoneyT>& __x) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __s(__is); - if (__s) - { - typedef istreambuf_iterator<_CharT, _Traits> _Ip; - typedef money_get<_CharT, _Ip> _Fp; - ios_base::iostate __err = ios_base::goodbit; - const _Fp& __mf = use_facet<_Fp>(__is.getloc()); - __mf.get(_Ip(__is), _Ip(), __x.__intl_, __is, __err, __x.__mon_); - __is.setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__iom_t7<_MoneyT> -get_money(_MoneyT& __mon, bool __intl = false) -{ - return __iom_t7<_MoneyT>(__mon, __intl); -} - -// put_money - -template class __iom_t8; - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t8<_MoneyT>& __x); - -template -class __iom_t8 -{ - const _MoneyT& __mon_; - bool __intl_; -public: - _LIBCPP_INLINE_VISIBILITY - __iom_t8(const _MoneyT& __mon, bool __intl) - : __mon_(__mon), __intl_(__intl) {} - - template - friend - basic_ostream<_CharT, _Traits>& - operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t8<_Mp>& __x); -}; - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t8<_MoneyT>& __x) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_ostream<_CharT, _Traits>::sentry __s(__os); - if (__s) - { - typedef ostreambuf_iterator<_CharT, _Traits> _Op; - typedef money_put<_CharT, _Op> _Fp; - const _Fp& __mf = use_facet<_Fp>(__os.getloc()); - if (__mf.put(_Op(__os), __x.__intl_, __os, __os.fill(), __x.__mon_).failed()) - __os.setstate(ios_base::badbit); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __os.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __os; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__iom_t8<_MoneyT> -put_money(const _MoneyT& __mon, bool __intl = false) -{ - return __iom_t8<_MoneyT>(__mon, __intl); -} - -// get_time - -template class __iom_t9; - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t9<_CharT>& __x); - -template -class __iom_t9 -{ - tm* __tm_; - const _CharT* __fmt_; -public: - _LIBCPP_INLINE_VISIBILITY - __iom_t9(tm* __tm, const _CharT* __fmt) - : __tm_(__tm), __fmt_(__fmt) {} - - template - friend - basic_istream<_Cp, _Traits>& - operator>>(basic_istream<_Cp, _Traits>& __is, const __iom_t9<_Cp>& __x); -}; - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, const __iom_t9<_CharT>& __x) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __s(__is); - if (__s) - { - typedef istreambuf_iterator<_CharT, _Traits> _Ip; - typedef time_get<_CharT, _Ip> _Fp; - ios_base::iostate __err = ios_base::goodbit; - const _Fp& __tf = use_facet<_Fp>(__is.getloc()); - __tf.get(_Ip(__is), _Ip(), __is, __err, __x.__tm_, - __x.__fmt_, __x.__fmt_ + _Traits::length(__x.__fmt_)); - __is.setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__iom_t9<_CharT> -get_time(tm* __tm, const _CharT* __fmt) -{ - return __iom_t9<_CharT>(__tm, __fmt); -} - -// put_time - -template class __iom_t10; - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t10<_CharT>& __x); - -template -class __iom_t10 -{ - const tm* __tm_; - const _CharT* __fmt_; -public: - _LIBCPP_INLINE_VISIBILITY - __iom_t10(const tm* __tm, const _CharT* __fmt) - : __tm_(__tm), __fmt_(__fmt) {} - - template - friend - basic_ostream<_Cp, _Traits>& - operator<<(basic_ostream<_Cp, _Traits>& __os, const __iom_t10<_Cp>& __x); -}; - -template -basic_ostream<_CharT, _Traits>& -operator<<(basic_ostream<_CharT, _Traits>& __os, const __iom_t10<_CharT>& __x) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_ostream<_CharT, _Traits>::sentry __s(__os); - if (__s) - { - typedef ostreambuf_iterator<_CharT, _Traits> _Op; - typedef time_put<_CharT, _Op> _Fp; - const _Fp& __tf = use_facet<_Fp>(__os.getloc()); - if (__tf.put(_Op(__os), __os, __os.fill(), __x.__tm_, - __x.__fmt_, __x.__fmt_ + _Traits::length(__x.__fmt_)).failed()) - __os.setstate(ios_base::badbit); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __os.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __os; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__iom_t10<_CharT> -put_time(const tm* __tm, const _CharT* __fmt) -{ - return __iom_t10<_CharT>(__tm, __fmt); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_IOMANIP diff --git a/libcxx/include/ios b/libcxx/include/ios deleted file mode 100644 index 51d50870b607..000000000000 --- a/libcxx/include/ios +++ /dev/null @@ -1,986 +0,0 @@ -// -*- C++ -*- -//===---------------------------- ios -------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_IOS -#define _LIBCPP_IOS - -/* - ios synopsis - -#include - -namespace std -{ - -typedef OFF_T streamoff; -typedef SZ_T streamsize; -template class fpos; - -class ios_base -{ -public: - class failure; - - typedef T1 fmtflags; - static const fmtflags boolalpha; - static const fmtflags dec; - static const fmtflags fixed; - static const fmtflags hex; - static const fmtflags internal; - static const fmtflags left; - static const fmtflags oct; - static const fmtflags right; - static const fmtflags scientific; - static const fmtflags showbase; - static const fmtflags showpoint; - static const fmtflags showpos; - static const fmtflags skipws; - static const fmtflags unitbuf; - static const fmtflags uppercase; - static const fmtflags adjustfield; - static const fmtflags basefield; - static const fmtflags floatfield; - - typedef T2 iostate; - static const iostate badbit; - static const iostate eofbit; - static const iostate failbit; - static const iostate goodbit; - - typedef T3 openmode; - static const openmode app; - static const openmode ate; - static const openmode binary; - static const openmode in; - static const openmode out; - static const openmode trunc; - - typedef T4 seekdir; - static const seekdir beg; - static const seekdir cur; - static const seekdir end; - - class Init; - - // 27.5.2.2 fmtflags state: - fmtflags flags() const; - fmtflags flags(fmtflags fmtfl); - fmtflags setf(fmtflags fmtfl); - fmtflags setf(fmtflags fmtfl, fmtflags mask); - void unsetf(fmtflags mask); - - streamsize precision() const; - streamsize precision(streamsize prec); - streamsize width() const; - streamsize width(streamsize wide); - - // 27.5.2.3 locales: - locale imbue(const locale& loc); - locale getloc() const; - - // 27.5.2.5 storage: - static int xalloc(); - long& iword(int index); - void*& pword(int index); - - // destructor - virtual ~ios_base(); - - // 27.5.2.6 callbacks; - enum event { erase_event, imbue_event, copyfmt_event }; - typedef void (*event_callback)(event, ios_base&, int index); - void register_callback(event_callback fn, int index); - - ios_base(const ios_base&) = delete; - ios_base& operator=(const ios_base&) = delete; - - static bool sync_with_stdio(bool sync = true); - -protected: - ios_base(); -}; - -template > -class basic_ios - : public ios_base -{ -public: - // types: - typedef charT char_type; - typedef typename traits::int_type int_type; - typedef typename traits::pos_type pos_type; - typedef typename traits::off_type off_type; - typedef traits traits_type; - - operator unspecified-bool-type() const; - bool operator!() const; - iostate rdstate() const; - void clear(iostate state = goodbit); - void setstate(iostate state); - bool good() const; - bool eof() const; - bool fail() const; - bool bad() const; - - iostate exceptions() const; - void exceptions(iostate except); - - // 27.5.4.1 Constructor/destructor: - explicit basic_ios(basic_streambuf* sb); - virtual ~basic_ios(); - - // 27.5.4.2 Members: - basic_ostream* tie() const; - basic_ostream* tie(basic_ostream* tiestr); - - basic_streambuf* rdbuf() const; - basic_streambuf* rdbuf(basic_streambuf* sb); - - basic_ios& copyfmt(const basic_ios& rhs); - - char_type fill() const; - char_type fill(char_type ch); - - locale imbue(const locale& loc); - - char narrow(char_type c, char dfault) const; - char_type widen(char c) const; - - basic_ios(const basic_ios& ) = delete; - basic_ios& operator=(const basic_ios&) = delete; - -protected: - basic_ios(); - void init(basic_streambuf* sb); - void move(basic_ios& rhs); - void swap(basic_ios& rhs); - void set_rdbuf(basic_streambuf* sb); -}; - -// 27.5.5, manipulators: -ios_base& boolalpha (ios_base& str); -ios_base& noboolalpha(ios_base& str); -ios_base& showbase (ios_base& str); -ios_base& noshowbase (ios_base& str); -ios_base& showpoint (ios_base& str); -ios_base& noshowpoint(ios_base& str); -ios_base& showpos (ios_base& str); -ios_base& noshowpos (ios_base& str); -ios_base& skipws (ios_base& str); -ios_base& noskipws (ios_base& str); -ios_base& uppercase (ios_base& str); -ios_base& nouppercase(ios_base& str); -ios_base& unitbuf (ios_base& str); -ios_base& nounitbuf (ios_base& str); - -// 27.5.5.2 adjustfield: -ios_base& internal (ios_base& str); -ios_base& left (ios_base& str); -ios_base& right (ios_base& str); - -// 27.5.5.3 basefield: -ios_base& dec (ios_base& str); -ios_base& hex (ios_base& str); -ios_base& oct (ios_base& str); - -// 27.5.5.4 floatfield: -ios_base& fixed (ios_base& str); -ios_base& scientific (ios_base& str); -ios_base& hexfloat (ios_base& str); -ios_base& defaultfloat(ios_base& str); - -// 27.5.5.5 error reporting: -enum class io_errc -{ - stream = 1 -}; - -concept_map ErrorCodeEnum { }; -error_code make_error_code(io_errc e); -error_condition make_error_condition(io_errc e); -storage-class-specifier const error_category& iostream_category; - -} // std - -*/ - -#include <__config> -#include -#include <__locale> -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -typedef ptrdiff_t streamsize; - -class _LIBCPP_VISIBLE ios_base -{ -public: - class failure; - - typedef unsigned int fmtflags; - static const fmtflags boolalpha = 0x0001; - static const fmtflags dec = 0x0002; - static const fmtflags fixed = 0x0004; - static const fmtflags hex = 0x0008; - static const fmtflags internal = 0x0010; - static const fmtflags left = 0x0020; - static const fmtflags oct = 0x0040; - static const fmtflags right = 0x0080; - static const fmtflags scientific = 0x0100; - static const fmtflags showbase = 0x0200; - static const fmtflags showpoint = 0x0400; - static const fmtflags showpos = 0x0800; - static const fmtflags skipws = 0x1000; - static const fmtflags unitbuf = 0x2000; - static const fmtflags uppercase = 0x4000; - static const fmtflags adjustfield = left | right | internal; - static const fmtflags basefield = dec | oct | hex; - static const fmtflags floatfield = scientific | fixed; - - typedef unsigned int iostate; - typedef iostate io_state; - static const iostate badbit = 0x1; - static const iostate eofbit = 0x2; - static const iostate failbit = 0x4; - static const iostate goodbit = 0x0; - - typedef unsigned int openmode; - typedef openmode open_mode; - static const openmode app = 0x01; - static const openmode ate = 0x02; - static const openmode binary = 0x04; - static const openmode in = 0x08; - static const openmode out = 0x10; - static const openmode trunc = 0x20; - - enum seekdir {beg, cur, end}; - typedef seekdir seek_dir; - - typedef _VSTD::streamoff streamoff; - typedef _VSTD::streampos streampos; - - class Init; - - // 27.5.2.2 fmtflags state: - _LIBCPP_INLINE_VISIBILITY fmtflags flags() const; - _LIBCPP_INLINE_VISIBILITY fmtflags flags(fmtflags __fmtfl); - _LIBCPP_INLINE_VISIBILITY fmtflags setf(fmtflags __fmtfl); - _LIBCPP_INLINE_VISIBILITY fmtflags setf(fmtflags __fmtfl, fmtflags __mask); - _LIBCPP_INLINE_VISIBILITY void unsetf(fmtflags __mask); - - _LIBCPP_INLINE_VISIBILITY streamsize precision() const; - _LIBCPP_INLINE_VISIBILITY streamsize precision(streamsize __prec); - _LIBCPP_INLINE_VISIBILITY streamsize width() const; - _LIBCPP_INLINE_VISIBILITY streamsize width(streamsize __wide); - - // 27.5.2.3 locales: - locale imbue(const locale& __loc); - locale getloc() const; - - // 27.5.2.5 storage: - static int xalloc(); - long& iword(int __index); - void*& pword(int __index); - - // destructor - virtual ~ios_base(); - - // 27.5.2.6 callbacks; - enum event { erase_event, imbue_event, copyfmt_event }; - typedef void (*event_callback)(event, ios_base&, int __index); - void register_callback(event_callback __fn, int __index); - -private: - ios_base(const ios_base&); // = delete; - ios_base& operator=(const ios_base&); // = delete; - -public: - static bool sync_with_stdio(bool __sync = true); - - _LIBCPP_INLINE_VISIBILITY iostate rdstate() const; - void clear(iostate __state = goodbit); - _LIBCPP_INLINE_VISIBILITY void setstate(iostate __state); - - _LIBCPP_INLINE_VISIBILITY bool good() const; - _LIBCPP_INLINE_VISIBILITY bool eof() const; - _LIBCPP_INLINE_VISIBILITY bool fail() const; - _LIBCPP_INLINE_VISIBILITY bool bad() const; - - _LIBCPP_INLINE_VISIBILITY iostate exceptions() const; - _LIBCPP_INLINE_VISIBILITY void exceptions(iostate __except); - - void __set_badbit_and_consider_rethrow(); - void __set_failbit_and_consider_rethrow(); - -protected: - _LIBCPP_INLINE_VISIBILITY - ios_base() {// purposefully does no initialization - } - - void init(void* __sb); - _LIBCPP_ALWAYS_INLINE void* rdbuf() const {return __rdbuf_;} - - _LIBCPP_ALWAYS_INLINE - void rdbuf(void* __sb) - { - __rdbuf_ = __sb; - clear(); - } - - void __call_callbacks(event); - void copyfmt(const ios_base&); - void move(ios_base&); - void swap(ios_base&); - - _LIBCPP_ALWAYS_INLINE - void set_rdbuf(void* __sb) - { - __rdbuf_ = __sb; - } - -private: - // All data members must be scalars - fmtflags __fmtflags_; - streamsize __precision_; - streamsize __width_; - iostate __rdstate_; - iostate __exceptions_; - void* __rdbuf_; - void* __loc_; - event_callback* __fn_; - int* __index_; - size_t __event_size_; - size_t __event_cap_; - static int __xindex_; - long* __iarray_; - size_t __iarray_size_; - size_t __iarray_cap_; - void** __parray_; - size_t __parray_size_; - size_t __parray_cap_; -}; - -//enum class io_errc -_LIBCPP_DECLARE_STRONG_ENUM(io_errc) -{ - stream = 1 -}; -_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(io_errc) - -template <> -struct _LIBCPP_VISIBLE is_error_code_enum : public true_type { }; - -#ifdef _LIBCPP_HAS_NO_STRONG_ENUMS -template <> -struct _LIBCPP_VISIBLE is_error_code_enum : public true_type { }; -#endif - -_LIBCPP_VISIBLE -const error_category& iostream_category(); - -inline _LIBCPP_INLINE_VISIBILITY -error_code -make_error_code(io_errc __e) -{ - return error_code(static_cast(__e), iostream_category()); -} - -inline _LIBCPP_INLINE_VISIBILITY -error_condition -make_error_condition(io_errc __e) -{ - return error_condition(static_cast(__e), iostream_category()); -} - -class _LIBCPP_EXCEPTION_ABI ios_base::failure - : public system_error -{ -public: - explicit failure(const string& __msg, const error_code& __ec = io_errc::stream); - explicit failure(const char* __msg, const error_code& __ec = io_errc::stream); - virtual ~failure() throw(); -}; - -class _LIBCPP_VISIBLE ios_base::Init -{ -public: - Init(); - ~Init(); -}; - -// fmtflags - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::fmtflags -ios_base::flags() const -{ - return __fmtflags_; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::fmtflags -ios_base::flags(fmtflags __fmtfl) -{ - fmtflags __r = __fmtflags_; - __fmtflags_ = __fmtfl; - return __r; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::fmtflags -ios_base::setf(fmtflags __fmtfl) -{ - fmtflags __r = __fmtflags_; - __fmtflags_ |= __fmtfl; - return __r; -} - -inline _LIBCPP_INLINE_VISIBILITY -void -ios_base::unsetf(fmtflags __mask) -{ - __fmtflags_ &= ~__mask; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::fmtflags -ios_base::setf(fmtflags __fmtfl, fmtflags __mask) -{ - fmtflags __r = __fmtflags_; - unsetf(__mask); - __fmtflags_ |= __fmtfl & __mask; - return __r; -} - -// precision - -inline _LIBCPP_INLINE_VISIBILITY -streamsize -ios_base::precision() const -{ - return __precision_; -} - -inline _LIBCPP_INLINE_VISIBILITY -streamsize -ios_base::precision(streamsize __prec) -{ - streamsize __r = __precision_; - __precision_ = __prec; - return __r; -} - -// width - -inline _LIBCPP_INLINE_VISIBILITY -streamsize -ios_base::width() const -{ - return __width_; -} - -inline _LIBCPP_INLINE_VISIBILITY -streamsize -ios_base::width(streamsize __wide) -{ - streamsize __r = __width_; - __width_ = __wide; - return __r; -} - -// iostate - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::iostate -ios_base::rdstate() const -{ - return __rdstate_; -} - -inline _LIBCPP_INLINE_VISIBILITY -void -ios_base::setstate(iostate __state) -{ - clear(__rdstate_ | __state); -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -ios_base::good() const -{ - return __rdstate_ == 0; -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -ios_base::eof() const -{ - return __rdstate_ & eofbit; -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -ios_base::fail() const -{ - return __rdstate_ & (failbit | badbit); -} - -inline _LIBCPP_INLINE_VISIBILITY -bool -ios_base::bad() const -{ - return __rdstate_ & badbit; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base::iostate -ios_base::exceptions() const -{ - return __exceptions_; -} - -inline _LIBCPP_INLINE_VISIBILITY -void -ios_base::exceptions(iostate __except) -{ - __exceptions_ = __except; - clear(__rdstate_); -} - -template -class _LIBCPP_VISIBLE basic_ios - : public ios_base -{ -public: - // types: - typedef _CharT char_type; - typedef _Traits traits_type; - - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - _LIBCPP_ALWAYS_INLINE - _LIBCPP_EXPLICIT - operator bool() const {return !fail();} - _LIBCPP_ALWAYS_INLINE bool operator!() const {return fail();} - _LIBCPP_ALWAYS_INLINE iostate rdstate() const {return ios_base::rdstate();} - _LIBCPP_ALWAYS_INLINE void clear(iostate __state = goodbit) {ios_base::clear(__state);} - _LIBCPP_ALWAYS_INLINE void setstate(iostate __state) {ios_base::setstate(__state);} - _LIBCPP_ALWAYS_INLINE bool good() const {return ios_base::good();} - _LIBCPP_ALWAYS_INLINE bool eof() const {return ios_base::eof();} - _LIBCPP_ALWAYS_INLINE bool fail() const {return ios_base::fail();} - _LIBCPP_ALWAYS_INLINE bool bad() const {return ios_base::bad();} - - _LIBCPP_ALWAYS_INLINE iostate exceptions() const {return ios_base::exceptions();} - _LIBCPP_ALWAYS_INLINE void exceptions(iostate __except) {ios_base::exceptions(__except);} - - // 27.5.4.1 Constructor/destructor: - _LIBCPP_INLINE_VISIBILITY - explicit basic_ios(basic_streambuf* __sb); - virtual ~basic_ios(); - - // 27.5.4.2 Members: - _LIBCPP_INLINE_VISIBILITY - basic_ostream* tie() const; - _LIBCPP_INLINE_VISIBILITY - basic_ostream* tie(basic_ostream* __tiestr); - - _LIBCPP_INLINE_VISIBILITY - basic_streambuf* rdbuf() const; - _LIBCPP_INLINE_VISIBILITY - basic_streambuf* rdbuf(basic_streambuf* __sb); - - basic_ios& copyfmt(const basic_ios& __rhs); - - _LIBCPP_INLINE_VISIBILITY - char_type fill() const; - _LIBCPP_INLINE_VISIBILITY - char_type fill(char_type __ch); - - _LIBCPP_INLINE_VISIBILITY - locale imbue(const locale& __loc); - - _LIBCPP_INLINE_VISIBILITY - char narrow(char_type __c, char __dfault) const; - _LIBCPP_INLINE_VISIBILITY - char_type widen(char __c) const; - -protected: - _LIBCPP_ALWAYS_INLINE - basic_ios() {// purposefully does no initialization - } - _LIBCPP_INLINE_VISIBILITY - void init(basic_streambuf* __sb); - - _LIBCPP_INLINE_VISIBILITY - void move(basic_ios& __rhs); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_ALWAYS_INLINE - void move(basic_ios&& __rhs) {move(__rhs);} -#endif - _LIBCPP_INLINE_VISIBILITY - void swap(basic_ios& __rhs); - _LIBCPP_INLINE_VISIBILITY - void set_rdbuf(basic_streambuf* __sb); -private: - basic_ostream* __tie_; - char_type __fill_; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ios<_CharT, _Traits>::basic_ios(basic_streambuf* __sb) -{ - init(__sb); -} - -template -basic_ios<_CharT, _Traits>::~basic_ios() -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ios<_CharT, _Traits>::init(basic_streambuf* __sb) -{ - ios_base::init(__sb); - __tie_ = 0; - __fill_ = widen(' '); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ostream<_CharT, _Traits>* -basic_ios<_CharT, _Traits>::tie() const -{ - return __tie_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_ostream<_CharT, _Traits>* -basic_ios<_CharT, _Traits>::tie(basic_ostream* __tiestr) -{ - basic_ostream* __r = __tie_; - __tie_ = __tiestr; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_streambuf<_CharT, _Traits>* -basic_ios<_CharT, _Traits>::rdbuf() const -{ - return static_cast*>(ios_base::rdbuf()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_streambuf<_CharT, _Traits>* -basic_ios<_CharT, _Traits>::rdbuf(basic_streambuf* __sb) -{ - basic_streambuf* __r = rdbuf(); - ios_base::rdbuf(__sb); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -locale -basic_ios<_CharT, _Traits>::imbue(const locale& __loc) -{ - locale __r = getloc(); - ios_base::imbue(__loc); - if (rdbuf()) - rdbuf()->pubimbue(__loc); - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -char -basic_ios<_CharT, _Traits>::narrow(char_type __c, char __dfault) const -{ - return use_facet >(getloc()).narrow(__c, __dfault); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_CharT -basic_ios<_CharT, _Traits>::widen(char __c) const -{ - return use_facet >(getloc()).widen(__c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_CharT -basic_ios<_CharT, _Traits>::fill() const -{ - return __fill_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_CharT -basic_ios<_CharT, _Traits>::fill(char_type __ch) -{ - char_type __r = __fill_; - __fill_ = __ch; - return __r; -} - -template -basic_ios<_CharT, _Traits>& -basic_ios<_CharT, _Traits>::copyfmt(const basic_ios& __rhs) -{ - if (this != &__rhs) - { - __call_callbacks(erase_event); - ios_base::copyfmt(__rhs); - __tie_ = __rhs.__tie_; - __fill_ = __rhs.__fill_; - __call_callbacks(copyfmt_event); - exceptions(__rhs.exceptions()); - } - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ios<_CharT, _Traits>::move(basic_ios& __rhs) -{ - ios_base::move(__rhs); - __tie_ = __rhs.__tie_; - __rhs.__tie_ = 0; - __fill_ = __rhs.__fill_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ios<_CharT, _Traits>::swap(basic_ios& __rhs) -{ - ios_base::swap(__rhs); - _VSTD::swap(__tie_, __rhs.__tie_); - _VSTD::swap(__fill_, __rhs.__fill_); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_ios<_CharT, _Traits>::set_rdbuf(basic_streambuf* __sb) -{ - ios_base::set_rdbuf(__sb); -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -boolalpha(ios_base& __str) -{ - __str.setf(ios_base::boolalpha); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -noboolalpha(ios_base& __str) -{ - __str.unsetf(ios_base::boolalpha); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -showbase(ios_base& __str) -{ - __str.setf(ios_base::showbase); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -noshowbase(ios_base& __str) -{ - __str.unsetf(ios_base::showbase); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -showpoint(ios_base& __str) -{ - __str.setf(ios_base::showpoint); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -noshowpoint(ios_base& __str) -{ - __str.unsetf(ios_base::showpoint); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -showpos(ios_base& __str) -{ - __str.setf(ios_base::showpos); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -noshowpos(ios_base& __str) -{ - __str.unsetf(ios_base::showpos); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -skipws(ios_base& __str) -{ - __str.setf(ios_base::skipws); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -noskipws(ios_base& __str) -{ - __str.unsetf(ios_base::skipws); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -uppercase(ios_base& __str) -{ - __str.setf(ios_base::uppercase); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -nouppercase(ios_base& __str) -{ - __str.unsetf(ios_base::uppercase); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -unitbuf(ios_base& __str) -{ - __str.setf(ios_base::unitbuf); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -nounitbuf(ios_base& __str) -{ - __str.unsetf(ios_base::unitbuf); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -internal(ios_base& __str) -{ - __str.setf(ios_base::internal, ios_base::adjustfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -left(ios_base& __str) -{ - __str.setf(ios_base::left, ios_base::adjustfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -right(ios_base& __str) -{ - __str.setf(ios_base::right, ios_base::adjustfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -dec(ios_base& __str) -{ - __str.setf(ios_base::dec, ios_base::basefield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -hex(ios_base& __str) -{ - __str.setf(ios_base::hex, ios_base::basefield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -oct(ios_base& __str) -{ - __str.setf(ios_base::oct, ios_base::basefield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -fixed(ios_base& __str) -{ - __str.setf(ios_base::fixed, ios_base::floatfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -scientific(ios_base& __str) -{ - __str.setf(ios_base::scientific, ios_base::floatfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -hexfloat(ios_base& __str) -{ - __str.setf(ios_base::fixed | ios_base::scientific, ios_base::floatfield); - return __str; -} - -inline _LIBCPP_INLINE_VISIBILITY -ios_base& -defaultfloat(ios_base& __str) -{ - __str.unsetf(ios_base::floatfield); - return __str; -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_IOS diff --git a/libcxx/include/iosfwd b/libcxx/include/iosfwd deleted file mode 100644 index 7e5ac7321f54..000000000000 --- a/libcxx/include/iosfwd +++ /dev/null @@ -1,194 +0,0 @@ -// -*- C++ -*- -//===--------------------------- iosfwd -----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_IOSFWD -#define _LIBCPP_IOSFWD - -/* - iosfwd synopsis - -namespace std -{ - -template struct char_traits; -template class allocator; - -class ios_base; -template > class basic_ios; - -template > class basic_streambuf; -template > class basic_istream; -template > class basic_ostream; -template > class basic_iostream; - -template , class Allocator = allocator > - class basic_stringbuf; -template , class Allocator = allocator > - class basic_istringstream; -template , class Allocator = allocator > - class basic_ostringstream; -template , class Allocator = allocator > - class basic_stringstream; - -template > class basic_filebuf; -template > class basic_ifstream; -template > class basic_ofstream; -template > class basic_fstream; - -template > class istreambuf_iterator; -template > class ostreambuf_iterator; - -typedef basic_ios ios; -typedef basic_ios wios; - -typedef basic_streambuf streambuf; -typedef basic_istream istream; -typedef basic_ostream ostream; -typedef basic_iostream iostream; - -typedef basic_stringbuf stringbuf; -typedef basic_istringstream istringstream; -typedef basic_ostringstream ostringstream; -typedef basic_stringstream stringstream; - -typedef basic_filebuf filebuf; -typedef basic_ifstream ifstream; -typedef basic_ofstream ofstream; -typedef basic_fstream fstream; - -typedef basic_streambuf wstreambuf; -typedef basic_istream wistream; -typedef basic_ostream wostream; -typedef basic_iostream wiostream; - -typedef basic_stringbuf wstringbuf; -typedef basic_istringstream wistringstream; -typedef basic_ostringstream wostringstream; -typedef basic_stringstream wstringstream; - -typedef basic_filebuf wfilebuf; -typedef basic_ifstream wifstream; -typedef basic_ofstream wofstream; -typedef basic_fstream wfstream; - -template class fpos; -typedef fpos::state_type> streampos; -typedef fpos::state_type> wstreampos; - -} // std - -*/ - -#include <__config> -#include // for mbstate_t - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -class ios_base; - -template struct _LIBCPP_VISIBLE char_traits; -template class _LIBCPP_VISIBLE allocator; - -template > - class _LIBCPP_VISIBLE basic_ios; - -template > - class _LIBCPP_VISIBLE basic_streambuf; -template > - class _LIBCPP_VISIBLE basic_istream; -template > - class _LIBCPP_VISIBLE basic_ostream; -template > - class _LIBCPP_VISIBLE basic_iostream; - -template , - class _Allocator = allocator<_CharT> > - class _LIBCPP_VISIBLE basic_stringbuf; -template , - class _Allocator = allocator<_CharT> > - class _LIBCPP_VISIBLE basic_istringstream; -template , - class _Allocator = allocator<_CharT> > - class _LIBCPP_VISIBLE basic_ostringstream; -template , - class _Allocator = allocator<_CharT> > - class _LIBCPP_VISIBLE basic_stringstream; - -template > - class _LIBCPP_VISIBLE basic_filebuf; -template > - class _LIBCPP_VISIBLE basic_ifstream; -template > - class _LIBCPP_VISIBLE basic_ofstream; -template > - class _LIBCPP_VISIBLE basic_fstream; - -template > - class _LIBCPP_VISIBLE istreambuf_iterator; -template > - class _LIBCPP_VISIBLE ostreambuf_iterator; - -typedef basic_ios ios; -typedef basic_ios wios; - -typedef basic_streambuf streambuf; -typedef basic_istream istream; -typedef basic_ostream ostream; -typedef basic_iostream iostream; - -typedef basic_stringbuf stringbuf; -typedef basic_istringstream istringstream; -typedef basic_ostringstream ostringstream; -typedef basic_stringstream stringstream; - -typedef basic_filebuf filebuf; -typedef basic_ifstream ifstream; -typedef basic_ofstream ofstream; -typedef basic_fstream fstream; - -typedef basic_streambuf wstreambuf; -typedef basic_istream wistream; -typedef basic_ostream wostream; -typedef basic_iostream wiostream; - -typedef basic_stringbuf wstringbuf; -typedef basic_istringstream wistringstream; -typedef basic_ostringstream wostringstream; -typedef basic_stringstream wstringstream; - -typedef basic_filebuf wfilebuf; -typedef basic_ifstream wifstream; -typedef basic_ofstream wofstream; -typedef basic_fstream wfstream; - -template class _LIBCPP_VISIBLE fpos; -typedef fpos streampos; -typedef fpos wstreampos; -#ifndef _LIBCPP_HAS_NO_UNICODE_CHARS -typedef fpos u16streampos; -typedef fpos u32streampos; -#endif // _LIBCPP_HAS_NO_UNICODE_CHARS - -typedef long long streamoff; // for char_traits in - -template - class _Traits = char_traits<_CharT>, - class _Allocator = allocator<_CharT> > - class _LIBCPP_VISIBLE basic_string; -typedef basic_string, allocator > string; -typedef basic_string, allocator > wstring; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_IOSFWD diff --git a/libcxx/include/iostream b/libcxx/include/iostream deleted file mode 100644 index 53cd146cc595..000000000000 --- a/libcxx/include/iostream +++ /dev/null @@ -1,60 +0,0 @@ -// -*- C++ -*- -//===--------------------------- iostream ---------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_IOSTREAM -#define _LIBCPP_IOSTREAM - -/* - iostream synopsis - -#include -#include -#include -#include - -namespace std { - -extern istream cin; -extern ostream cout; -extern ostream cerr; -extern ostream clog; -extern wistream wcin; -extern wostream wcout; -extern wostream wcerr; -extern wostream wclog; - -} // std - -*/ - -#include <__config> -#include -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -extern _LIBCPP_VISIBLE istream cin; -extern _LIBCPP_VISIBLE ostream cout; -extern _LIBCPP_VISIBLE ostream cerr; -extern _LIBCPP_VISIBLE ostream clog; -extern _LIBCPP_VISIBLE wistream wcin; -extern _LIBCPP_VISIBLE wostream wcout; -extern _LIBCPP_VISIBLE wostream wcerr; -extern _LIBCPP_VISIBLE wostream wclog; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_IOSTREAM diff --git a/libcxx/include/istream b/libcxx/include/istream deleted file mode 100644 index 7312425eb070..000000000000 --- a/libcxx/include/istream +++ /dev/null @@ -1,1712 +0,0 @@ -// -*- C++ -*- -//===--------------------------- istream ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_ISTREAM -#define _LIBCPP_ISTREAM - -/* - istream synopsis - -template > -class basic_istream - : virtual public basic_ios -{ -public: - // types (inherited from basic_ios (27.5.4)): - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - // 27.7.1.1.1 Constructor/destructor: - explicit basic_istream(basic_streambuf* sb); - basic_istream(basic_istream&& rhs); - virtual ~basic_istream(); - - // 27.7.1.1.2 Assign/swap: - basic_istream& operator=(basic_istream&& rhs); - void swap(basic_istream& rhs); - - // 27.7.1.1.3 Prefix/suffix: - class sentry; - - // 27.7.1.2 Formatted input: - basic_istream& operator>>(basic_istream& (*pf)(basic_istream&)); - basic_istream& operator>>(basic_ios& - (*pf)(basic_ios&)); - basic_istream& operator>>(ios_base& (*pf)(ios_base&)); - basic_istream& operator>>(basic_streambuf* sb); - basic_istream& operator>>(bool& n); - basic_istream& operator>>(short& n); - basic_istream& operator>>(unsigned short& n); - basic_istream& operator>>(int& n); - basic_istream& operator>>(unsigned int& n); - basic_istream& operator>>(long& n); - basic_istream& operator>>(unsigned long& n); - basic_istream& operator>>(long long& n); - basic_istream& operator>>(unsigned long long& n); - basic_istream& operator>>(float& f); - basic_istream& operator>>(double& f); - basic_istream& operator>>(long double& f); - basic_istream& operator>>(void*& p); - - // 27.7.1.3 Unformatted input: - streamsize gcount() const; - int_type get(); - basic_istream& get(char_type& c); - basic_istream& get(char_type* s, streamsize n); - basic_istream& get(char_type* s, streamsize n, char_type delim); - basic_istream& get(basic_streambuf& sb); - basic_istream& get(basic_streambuf& sb, char_type delim); - - basic_istream& getline(char_type* s, streamsize n); - basic_istream& getline(char_type* s, streamsize n, char_type delim); - - basic_istream& ignore(streamsize n = 1, int_type delim = traits_type::eof()); - int_type peek(); - basic_istream& read (char_type* s, streamsize n); - streamsize readsome(char_type* s, streamsize n); - - basic_istream& putback(char_type c); - basic_istream& unget(); - int sync(); - - pos_type tellg(); - basic_istream& seekg(pos_type); - basic_istream& seekg(off_type, ios_base::seekdir); -}; - -// 27.7.1.2.3 character extraction templates: -template - basic_istream& operator>>(basic_istream&, charT&); - -template - basic_istream& operator>>(basic_istream&, unsigned char&); - -template - basic_istream& operator>>(basic_istream&, signed char&); - -template - basic_istream& operator>>(basic_istream&, charT*); - -template - basic_istream& operator>>(basic_istream&, unsigned char*); - -template - basic_istream& operator>>(basic_istream&, signed char*); - -template - void - swap(basic_istream& x, basic_istream& y); - -typedef basic_istream istream; -typedef basic_istream wistream; - -template > -class basic_iostream : - public basic_istream, - public basic_ostream -{ -public: - // types: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - // constructor/destructor - explicit basic_iostream(basic_streambuf* sb); - basic_iostream(basic_iostream&& rhs); - virtual ~basic_iostream(); - - // assign/swap - basic_iostream& operator=(basic_iostream&& rhs); - void swap(basic_iostream& rhs); -}; - -template - void - swap(basic_iostream& x, basic_iostream& y); - -typedef basic_iostream iostream; -typedef basic_iostream wiostream; - -template - basic_istream& - ws(basic_istream& is); - -template - basic_istream& - operator>>(basic_istream&& is, T& x); - -} // std - -*/ - -#include <__config> -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template -class _LIBCPP_VISIBLE basic_istream - : virtual public basic_ios<_CharT, _Traits> -{ - streamsize __gc_; -public: - // types (inherited from basic_ios (27.5.4)): - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - // 27.7.1.1.1 Constructor/destructor: - explicit basic_istream(basic_streambuf* __sb); - virtual ~basic_istream(); -protected: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - basic_istream(basic_istream&& __rhs); -#endif - - // 27.7.1.1.2 Assign/swap: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - basic_istream& operator=(basic_istream&& __rhs); -#endif - void swap(basic_istream& __rhs); -public: - - // 27.7.1.1.3 Prefix/suffix: - class sentry; - - // 27.7.1.2 Formatted input: - basic_istream& operator>>(basic_istream& (*__pf)(basic_istream&)); - basic_istream& operator>>(basic_ios& - (*__pf)(basic_ios&)); - basic_istream& operator>>(ios_base& (*__pf)(ios_base&)); - basic_istream& operator>>(basic_streambuf* __sb); - basic_istream& operator>>(bool& __n); - basic_istream& operator>>(short& __n); - basic_istream& operator>>(unsigned short& __n); - basic_istream& operator>>(int& __n); - basic_istream& operator>>(unsigned int& __n); - basic_istream& operator>>(long& __n); - basic_istream& operator>>(unsigned long& __n); - basic_istream& operator>>(long long& __n); - basic_istream& operator>>(unsigned long long& __n); - basic_istream& operator>>(float& __f); - basic_istream& operator>>(double& __f); - basic_istream& operator>>(long double& __f); - basic_istream& operator>>(void*& __p); - - // 27.7.1.3 Unformatted input: - _LIBCPP_INLINE_VISIBILITY - streamsize gcount() const {return __gc_;} - int_type get(); - basic_istream& get(char_type& __c); - basic_istream& get(char_type* __s, streamsize __n); - basic_istream& get(char_type* __s, streamsize __n, char_type __dlm); - basic_istream& get(basic_streambuf& __sb); - basic_istream& get(basic_streambuf& __sb, char_type __dlm); - - basic_istream& getline(char_type* __s, streamsize __n); - basic_istream& getline(char_type* __s, streamsize __n, char_type __dlm); - - basic_istream& ignore(streamsize __n = 1, int_type __dlm = traits_type::eof()); - int_type peek(); - basic_istream& read (char_type* __s, streamsize __n); - streamsize readsome(char_type* __s, streamsize __n); - - basic_istream& putback(char_type __c); - basic_istream& unget(); - int sync(); - - pos_type tellg(); - basic_istream& seekg(pos_type __pos); - basic_istream& seekg(off_type __off, ios_base::seekdir __dir); -}; - -template -class _LIBCPP_VISIBLE basic_istream<_CharT, _Traits>::sentry -{ - bool __ok_; - - sentry(const sentry&); // = delete; - sentry& operator=(const sentry&); // = delete; - -public: - explicit sentry(basic_istream<_CharT, _Traits>& __is, bool __noskipws = false); -// ~sentry() = default; - - _LIBCPP_INLINE_VISIBILITY - _LIBCPP_EXPLICIT - operator bool() const {return __ok_;} -}; - -template -basic_istream<_CharT, _Traits>::sentry::sentry(basic_istream<_CharT, _Traits>& __is, - bool __noskipws) - : __ok_(false) -{ - if (__is.good()) - { - if (__is.tie()) - __is.tie()->flush(); - if (!__noskipws && (__is.flags() & ios_base::skipws)) - { - typedef istreambuf_iterator<_CharT, _Traits> _Ip; - const ctype<_CharT>& __ct = use_facet >(__is.getloc()); - _Ip __i(__is); - _Ip __eof; - for (; __i != __eof; ++__i) - if (!__ct.is(__ct.space, *__i)) - break; - if (__i == __eof) - __is.setstate(ios_base::failbit | ios_base::eofbit); - } - __ok_ = __is.good(); - } - else - __is.setstate(ios_base::failbit); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>::basic_istream(basic_streambuf* __sb) - : __gc_(0) -{ - this->init(__sb); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>::basic_istream(basic_istream&& __rhs) - : __gc_(__rhs.__gc_) -{ - __rhs.__gc_ = 0; - this->move(__rhs); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator=(basic_istream&& __rhs) -{ - swap(__rhs); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -basic_istream<_CharT, _Traits>::~basic_istream() -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_istream<_CharT, _Traits>::swap(basic_istream& __rhs) -{ - _VSTD::swap(__gc_, __rhs.__gc_); - basic_ios::swap(__rhs); -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(unsigned short& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(unsigned int& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(long& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(unsigned long& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(long long& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(unsigned long long& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(float& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(double& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(long double& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(bool& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(void*& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __n); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(short& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - long __temp; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __temp); - if (__temp < numeric_limits::min()) - { - __err |= ios_base::failbit; - __n = numeric_limits::min(); - } - else if (__temp > numeric_limits::max()) - { - __err |= ios_base::failbit; - __n = numeric_limits::max(); - } - else - __n = static_cast(__temp); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(int& __n) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this); - if (__s) - { - typedef istreambuf_iterator _Ip; - typedef num_get _Fp; - ios_base::iostate __err = ios_base::goodbit; - long __temp; - use_facet<_Fp>(this->getloc()).get(_Ip(*this), _Ip(), *this, __err, __temp); - if (__temp < numeric_limits::min()) - { - __err |= ios_base::failbit; - __n = numeric_limits::min(); - } - else if (__temp > numeric_limits::max()) - { - __err |= ios_base::failbit; - __n = numeric_limits::max(); - } - else - __n = static_cast(__temp); - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(basic_istream& (*__pf)(basic_istream&)) -{ - return __pf(*this); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(basic_ios& - (*__pf)(basic_ios&)) -{ - __pf(*this); - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(ios_base& (*__pf)(ios_base&)) -{ - __pf(*this); - return *this; -} - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, _CharT* __s) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is); - if (__sen) - { - streamsize __n = __is.width(); - if (__n <= 0) - __n = numeric_limits::max() / sizeof(_CharT) - 1; - streamsize __c = 0; - const ctype<_CharT>& __ct = use_facet >(__is.getloc()); - ios_base::iostate __err = ios_base::goodbit; - while (__c < __n-1) - { - typename _Traits::int_type __i = __is.rdbuf()->sgetc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - { - __err |= ios_base::eofbit; - break; - } - _CharT __ch = _Traits::to_char_type(__i); - if (__ct.is(__ct.space, __ch)) - break; - *__s++ = __ch; - ++__c; - __is.rdbuf()->sbumpc(); - } - *__s = _CharT(); - __is.width(0); - if (__c == 0) - __err |= ios_base::failbit; - __is.setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream& -operator>>(basic_istream& __is, unsigned char* __s) -{ - return __is >> (char*)__s; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream& -operator>>(basic_istream& __is, signed char* __s) -{ - return __is >> (char*)__s; -} - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, _CharT& __c) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is); - if (__sen) - { - typename _Traits::int_type __i = __is.rdbuf()->sbumpc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - __is.setstate(ios_base::eofbit | ios_base::failbit); - else - __c = _Traits::to_char_type(__i); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream& -operator>>(basic_istream& __is, unsigned char& __c) -{ - return __is >> (char&)__c; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream& -operator>>(basic_istream& __is, signed char& __c) -{ - return __is >> (char&)__c; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::operator>>(basic_streambuf* __sb) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this, true); - if (__s) - { - if (__sb) - { -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - ios_base::iostate __err = ios_base::goodbit; - while (true) - { - typename traits_type::int_type __i = this->rdbuf()->sgetc(); - if (traits_type::eq_int_type(__i, _Traits::eof())) - { - __err |= ios_base::eofbit; - break; - } - if (traits_type::eq_int_type( - __sb->sputc(traits_type::to_char_type(__i)), - traits_type::eof())) - break; - ++__gc_; - this->rdbuf()->sbumpc(); - } - if (__gc_ == 0) - __err |= ios_base::failbit; - this->setstate(__err); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - if (__gc_ == 0) - this->__set_failbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - } - else - this->setstate(ios_base::failbit); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -typename basic_istream<_CharT, _Traits>::int_type -basic_istream<_CharT, _Traits>::get() -{ - __gc_ = 0; - int_type __r = traits_type::eof(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __s(*this, true); - if (__s) - { - __r = this->rdbuf()->sbumpc(); - if (traits_type::eq_int_type(__r, traits_type::eof())) - this->setstate(ios_base::failbit | ios_base::eofbit); - else - __gc_ = 1; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::get(char_type& __c) -{ - int_type __ch = get(); - if (__ch != traits_type::eof()) - __c = traits_type::to_char_type(__ch); - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::get(char_type* __s, streamsize __n, char_type __dlm) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - if (__n > 0) - { - ios_base::iostate __err = ios_base::goodbit; - while (__gc_ < __n-1) - { - int_type __i = this->rdbuf()->sgetc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - __err |= ios_base::eofbit; - break; - } - char_type __ch = traits_type::to_char_type(__i); - if (traits_type::eq(__ch, __dlm)) - break; - *__s++ = __ch; - ++__gc_; - this->rdbuf()->sbumpc(); - } - *__s = char_type(); - if (__gc_ == 0) - __err |= ios_base::failbit; - this->setstate(__err); - } - else - this->setstate(ios_base::failbit); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::get(char_type* __s, streamsize __n) -{ - return get(__s, __n, this->widen('\n')); -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::get(basic_streambuf& __sb, - char_type __dlm) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - ios_base::iostate __err = ios_base::goodbit; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - while (true) - { - typename traits_type::int_type __i = this->rdbuf()->sgetc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - __err |= ios_base::eofbit; - break; - } - char_type __ch = traits_type::to_char_type(__i); - if (traits_type::eq(__ch, __dlm)) - break; - if (traits_type::eq_int_type(__sb.sputc(__ch), traits_type::eof())) - break; - ++__gc_; - this->rdbuf()->sbumpc(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - } -#endif // _LIBCPP_NO_EXCEPTIONS - if (__gc_ == 0) - __err |= ios_base::failbit; - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::get(basic_streambuf& __sb) -{ - return get(__sb, this->widen('\n')); -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::getline(char_type* __s, streamsize __n, char_type __dlm) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - ios_base::iostate __err = ios_base::goodbit; - while (true) - { - typename traits_type::int_type __i = this->rdbuf()->sgetc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - __err |= ios_base::eofbit; - break; - } - char_type __ch = traits_type::to_char_type(__i); - if (traits_type::eq(__ch, __dlm)) - { - this->rdbuf()->sbumpc(); - ++__gc_; - break; - } - if (__gc_ >= __n-1) - { - __err |= ios_base::failbit; - break; - } - *__s++ = __ch; - this->rdbuf()->sbumpc(); - ++__gc_; - } - if (__n > 0) - *__s = char_type(); - if (__gc_ == 0) - __err |= ios_base::failbit; - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::getline(char_type* __s, streamsize __n) -{ - return getline(__s, __n, this->widen('\n')); -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::ignore(streamsize __n, int_type __dlm) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - ios_base::iostate __err = ios_base::goodbit; - if (__n == numeric_limits::max()) - { - while (true) - { - typename traits_type::int_type __i = this->rdbuf()->sbumpc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - __err |= ios_base::eofbit; - break; - } - ++__gc_; - char_type __ch = traits_type::to_char_type(__i); - if (traits_type::eq(__ch, static_cast(__dlm))) - break; - } - } - else - { - while (__gc_ < __n) - { - typename traits_type::int_type __i = this->rdbuf()->sbumpc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - __err |= ios_base::eofbit; - break; - } - ++__gc_; - char_type __ch = traits_type::to_char_type(__i); - if (traits_type::eq(__ch, static_cast(__dlm))) - break; - } - } - this->setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -typename basic_istream<_CharT, _Traits>::int_type -basic_istream<_CharT, _Traits>::peek() -{ - __gc_ = 0; - int_type __r = traits_type::eof(); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - __r = this->rdbuf()->sgetc(); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __r; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::read(char_type* __s, streamsize __n) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - for (; __gc_ < __n; ++__gc_) - { - typename traits_type::int_type __i = this->rdbuf()->sbumpc(); - if (traits_type::eq_int_type(__i, traits_type::eof())) - { - this->setstate(ios_base::failbit | ios_base::eofbit); - break; - } - *__s++ = traits_type::to_char_type(__i); - } - } - else - this->setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -streamsize -basic_istream<_CharT, _Traits>::readsome(char_type* __s, streamsize __n) -{ - streamsize __c = this->rdbuf()->in_avail(); - switch (__c) - { - case -1: - this->setstate(ios_base::eofbit); - break; - case 0: - break; - default: - read(__s, _VSTD::min(__c, __n)); - break; - } - return __gc_; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::putback(char_type __c) -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - if (this->rdbuf() == 0 || this->rdbuf()->sputbackc(__c) == traits_type::eof()) - this->setstate(ios_base::badbit); - } - else - this->setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::unget() -{ - __gc_ = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - if (this->rdbuf() == 0 || this->rdbuf()->sungetc() == traits_type::eof()) - this->setstate(ios_base::badbit); - } - else - this->setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -int -basic_istream<_CharT, _Traits>::sync() -{ - int __r = 0; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - { - if (this->rdbuf() == 0) - return -1; - if (this->rdbuf()->pubsync() == -1) - { - this->setstate(ios_base::badbit); - return -1; - } - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __r; -} - -template -typename basic_istream<_CharT, _Traits>::pos_type -basic_istream<_CharT, _Traits>::tellg() -{ - pos_type __r(-1); -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - __r = this->rdbuf()->pubseekoff(0, ios_base::cur, ios_base::in); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __r; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::seekg(pos_type __pos) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - if (this->rdbuf()->pubseekpos(__pos, ios_base::in) == pos_type(-1)) - this->setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -basic_istream<_CharT, _Traits>::seekg(off_type __off, ios_base::seekdir __dir) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - sentry __sen(*this, true); - if (__sen) - this->rdbuf()->pubseekoff(__off, __dir, ios_base::in); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - this->__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return *this; -} - -template -basic_istream<_CharT, _Traits>& -ws(basic_istream<_CharT, _Traits>& __is) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is, true); - if (__sen) - { - const ctype<_CharT>& __ct = use_facet >(__is.getloc()); - while (true) - { - typename _Traits::int_type __i = __is.rdbuf()->sgetc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - { - __is.setstate(ios_base::eofbit); - break; - } - if (!__ct.is(__ct.space, _Traits::to_char_type(__i))) - break; - __is.rdbuf()->sbumpc(); - } - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>&& __is, _Tp& __x) -{ - __is >> __x; - return __is; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -class _LIBCPP_VISIBLE basic_iostream - : public basic_istream<_CharT, _Traits>, - public basic_ostream<_CharT, _Traits> -{ -public: - // types: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - - // constructor/destructor - explicit basic_iostream(basic_streambuf* __sb); - virtual ~basic_iostream(); -protected: -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - basic_iostream(basic_iostream&& __rhs); -#endif - - // assign/swap -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - basic_iostream& operator=(basic_iostream&& __rhs); -#endif - void swap(basic_iostream& __rhs); -public: -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_iostream<_CharT, _Traits>::basic_iostream(basic_streambuf* __sb) - : basic_istream<_CharT, _Traits>(__sb) -{ -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_iostream<_CharT, _Traits>::basic_iostream(basic_iostream&& __rhs) - : basic_istream<_CharT, _Traits>(_VSTD::move(__rhs)) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_iostream<_CharT, _Traits>& -basic_iostream<_CharT, _Traits>::operator=(basic_iostream&& __rhs) -{ - swap(__rhs); - return *this; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -basic_iostream<_CharT, _Traits>::~basic_iostream() -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -basic_iostream<_CharT, _Traits>::swap(basic_iostream& __rhs) -{ - basic_istream::swap(__rhs); -} - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, - basic_string<_CharT, _Traits, _Allocator>& __str) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is); - if (__sen) - { - __str.clear(); - streamsize __n = __is.width(); - if (__n <= 0) - __n = __str.max_size(); - if (__n <= 0) - __n = numeric_limits::max(); - streamsize __c = 0; - const ctype<_CharT>& __ct = use_facet >(__is.getloc()); - ios_base::iostate __err = ios_base::goodbit; - while (__c < __n) - { - typename _Traits::int_type __i = __is.rdbuf()->sgetc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - { - __err |= ios_base::eofbit; - break; - } - _CharT __ch = _Traits::to_char_type(__i); - if (__ct.is(__ct.space, __ch)) - break; - __str.push_back(__ch); - ++__c; - __is.rdbuf()->sbumpc(); - } - __is.width(0); - if (__c == 0) - __err |= ios_base::failbit; - __is.setstate(__err); - } - else - __is.setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -basic_istream<_CharT, _Traits>& -getline(basic_istream<_CharT, _Traits>& __is, - basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is, true); - if (__sen) - { - __str.clear(); - ios_base::iostate __err = ios_base::goodbit; - streamsize __extr = 0; - while (true) - { - typename _Traits::int_type __i = __is.rdbuf()->sbumpc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - { - __err |= ios_base::eofbit; - break; - } - ++__extr; - _CharT __ch = _Traits::to_char_type(__i); - if (_Traits::eq(__ch, __dlm)) - break; - __str.push_back(__ch); - if (__str.size() == __str.max_size()) - { - __err |= ios_base::failbit; - break; - } - } - if (__extr == 0) - __err |= ios_base::failbit; - __is.setstate(__err); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -getline(basic_istream<_CharT, _Traits>& __is, - basic_string<_CharT, _Traits, _Allocator>& __str) -{ - return getline(__is, __str, __is.widen('\n')); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -getline(basic_istream<_CharT, _Traits>&& __is, - basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm) -{ - return getline(__is, __str, __dlm); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -basic_istream<_CharT, _Traits>& -getline(basic_istream<_CharT, _Traits>&& __is, - basic_string<_CharT, _Traits, _Allocator>& __str) -{ - return getline(__is, __str, __is.widen('\n')); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -basic_istream<_CharT, _Traits>& -operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x) -{ -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - typename basic_istream<_CharT, _Traits>::sentry __sen(__is); - if (__sen) - { - basic_string<_CharT, _Traits> __str; - const ctype<_CharT>& __ct = use_facet >(__is.getloc()); - streamsize __c = 0; - ios_base::iostate __err = ios_base::goodbit; - _CharT __zero = __ct.widen('0'); - _CharT __one = __ct.widen('1'); - while (__c < _Size) - { - typename _Traits::int_type __i = __is.rdbuf()->sgetc(); - if (_Traits::eq_int_type(__i, _Traits::eof())) - { - __err |= ios_base::eofbit; - break; - } - _CharT __ch = _Traits::to_char_type(__i); - if (!_Traits::eq(__ch, __zero) && !_Traits::eq(__ch, __one)) - break; - __str.push_back(__ch); - ++__c; - __is.rdbuf()->sbumpc(); - } - __x = bitset<_Size>(__str); - if (__c == 0) - __err |= ios_base::failbit; - __is.setstate(__err); - } - else - __is.setstate(ios_base::failbit); -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - __is.__set_badbit_and_consider_rethrow(); - } -#endif // _LIBCPP_NO_EXCEPTIONS - return __is; -} - -extern template class basic_istream; -extern template class basic_istream; -extern template class basic_iostream; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_ISTREAM diff --git a/libcxx/include/iterator b/libcxx/include/iterator deleted file mode 100644 index 75fee4b9db55..000000000000 --- a/libcxx/include/iterator +++ /dev/null @@ -1,1805 +0,0 @@ -// -*- C++ -*- -//===-------------------------- iterator ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_ITERATOR -#define _LIBCPP_ITERATOR - -/* - iterator synopsis - -namespace std -{ - -template -struct iterator_traits -{ - typedef typename Iterator::difference_type difference_type; - typedef typename Iterator::value_type value_type; - typedef typename Iterator::pointer pointer; - typedef typename Iterator::reference reference; - typedef typename Iterator::iterator_category iterator_category; -}; - -template -struct iterator_traits -{ - typedef ptrdiff_t difference_type; - typedef T value_type; - typedef T* pointer; - typedef T& reference; - typedef random_access_iterator_tag iterator_category; -}; - -template -struct iterator_traits -{ - typedef ptrdiff_t difference_type; - typedef T value_type; - typedef const T* pointer; - typedef const T& reference; - typedef random_access_iterator_tag iterator_category; -}; - -template -struct iterator -{ - typedef T value_type; - typedef Distance difference_type; - typedef Pointer pointer; - typedef Reference reference; - typedef Category iterator_category; -}; - -struct input_iterator_tag {}; -struct output_iterator_tag {}; -struct forward_iterator_tag : public input_iterator_tag {}; -struct bidirectional_iterator_tag : public forward_iterator_tag {}; -struct random_access_iterator_tag : public bidirectional_iterator_tag {}; - -// extension: second argument not conforming to C++03 -template -void advance(InputIterator& i, - typename iterator_traits::difference_type n); - -template -typename iterator_traits::difference_type -distance(InputIterator first, InputIterator last); - -template -class reverse_iterator - : public iterator::iterator_category, - typename iterator_traits::value_type, - typename iterator_traits::difference_type, - typename iterator_traits::pointer, - typename iterator_traits::reference> -{ -protected: - Iterator current; -public: - typedef Iterator iterator_type; - typedef typename iterator_traits::difference_type difference_type; - typedef typename iterator_traits::reference reference; - typedef typename iterator_traits::pointer pointer; - - reverse_iterator(); - explicit reverse_iterator(Iterator x); - template reverse_iterator(const reverse_iterator& u); - Iterator base() const; - reference operator*() const; - pointer operator->() const; - reverse_iterator& operator++(); - reverse_iterator operator++(int); - reverse_iterator& operator--(); - reverse_iterator operator--(int); - reverse_iterator operator+ (difference_type n) const; - reverse_iterator& operator+=(difference_type n); - reverse_iterator operator- (difference_type n) const; - reverse_iterator& operator-=(difference_type n); - reference operator[](difference_type n) const; -}; - -template -bool -operator==(const reverse_iterator& x, const reverse_iterator& y); - -template -bool -operator<(const reverse_iterator& x, const reverse_iterator& y); - -template -bool -operator!=(const reverse_iterator& x, const reverse_iterator& y); - -template -bool -operator>(const reverse_iterator& x, const reverse_iterator& y); - -template -bool -operator>=(const reverse_iterator& x, const reverse_iterator& y); - -template -bool -operator<=(const reverse_iterator& x, const reverse_iterator& y); - -template -typename reverse_iterator::difference_type -operator-(const reverse_iterator& x, const reverse_iterator& y); - -template -reverse_iterator -operator+(typename reverse_iterator::difference_type n, const reverse_iterator& x); - -template -class back_insert_iterator -{ -protected: - Container* container; -public: - typedef Container container_type; - typedef void value_type; - typedef void difference_type; - typedef back_insert_iterator& reference; - typedef void pointer; - - explicit back_insert_iterator(Container& x); - back_insert_iterator& operator=(const typename Container::value_type& value); - back_insert_iterator& operator*(); - back_insert_iterator& operator++(); - back_insert_iterator operator++(int); -}; - -template back_insert_iterator back_inserter(Container& x); - -template -class front_insert_iterator -{ -protected: - Container* container; -public: - typedef Container container_type; - typedef void value_type; - typedef void difference_type; - typedef front_insert_iterator& reference; - typedef void pointer; - - explicit front_insert_iterator(Container& x); - front_insert_iterator& operator=(const typename Container::value_type& value); - front_insert_iterator& operator*(); - front_insert_iterator& operator++(); - front_insert_iterator operator++(int); -}; - -template front_insert_iterator front_inserter(Container& x); - -template -class insert_iterator -{ -protected: - Container* container; - typename Container::iterator iter; -public: - typedef Container container_type; - typedef void value_type; - typedef void difference_type; - typedef insert_iterator& reference; - typedef void pointer; - - insert_iterator(Container& x, typename Container::iterator i); - insert_iterator& operator=(const typename Container::value_type& value); - insert_iterator& operator*(); - insert_iterator& operator++(); - insert_iterator& operator++(int); -}; - -template -insert_iterator inserter(Container& x, Iterator i); - -template , class Distance = ptrdiff_t> -class istream_iterator - : public iterator -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef basic_istream istream_type; - - istream_iterator(); - istream_iterator(istream_type& s); - istream_iterator(const istream_iterator& x); - ~istream_iterator(); - - const T& operator*() const; - const T* operator->() const; - istream_iterator& operator++(); - istream_iterator operator++(int); -}; - -template -bool operator==(const istream_iterator& x, - const istream_iterator& y); -template -bool operator!=(const istream_iterator& x, - const istream_iterator& y); - -template > -class ostream_iterator - : public iterator -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef basic_ostream ostream_type; - - ostream_iterator(ostream_type& s); - ostream_iterator(ostream_type& s, const charT* delimiter); - ostream_iterator(const ostream_iterator& x); - ~ostream_iterator(); - ostream_iterator& operator=(const T& value); - - ostream_iterator& operator*(); - ostream_iterator& operator++(); - ostream_iterator& operator++(int); -}; - -template > -class istreambuf_iterator - : public iterator -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef typename traits::int_type int_type; - typedef basic_streambuf streambuf_type; - typedef basic_istream istream_type; - - istreambuf_iterator() throw(); - istreambuf_iterator(istream_type& s) throw(); - istreambuf_iterator(streambuf_type* s) throw(); - istreambuf_iterator(a-private-type) throw(); - - charT operator*() const; - pointer operator->() const; - istreambuf_iterator& operator++(); - a-private-type operator++(int); - - bool equal(const istreambuf_iterator& b) const; -}; - -template -bool operator==(const istreambuf_iterator& a, - const istreambuf_iterator& b); -template -bool operator!=(const istreambuf_iterator& a, - const istreambuf_iterator& b); - -template > -class ostreambuf_iterator - : public iterator -{ -public: - typedef charT char_type; - typedef traits traits_type; - typedef basic_streambuf streambuf_type; - typedef basic_ostream ostream_type; - - ostreambuf_iterator(ostream_type& s) throw(); - ostreambuf_iterator(streambuf_type* s) throw(); - ostreambuf_iterator& operator=(charT c); - ostreambuf_iterator& operator*(); - ostreambuf_iterator& operator++(); - ostreambuf_iterator& operator++(int); - bool failed() const throw(); -}; - -template auto begin(C& c) -> decltype(c.begin()); -template auto begin(const C& c) -> decltype(c.begin()); -template auto end(C& c) -> decltype(c.end()); -template auto end(const C& c) -> decltype(c.end()); -template T* begin(T (&array)[N]); -template T* end(T (&array)[N]); - -} // std - -*/ - -#include <__config> -#include -#include -#include -#ifdef _LIBCPP_DEBUG -#include -#endif - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -struct _LIBCPP_VISIBLE input_iterator_tag {}; -struct _LIBCPP_VISIBLE output_iterator_tag {}; -struct _LIBCPP_VISIBLE forward_iterator_tag : public input_iterator_tag {}; -struct _LIBCPP_VISIBLE bidirectional_iterator_tag : public forward_iterator_tag {}; -struct _LIBCPP_VISIBLE random_access_iterator_tag : public bidirectional_iterator_tag {}; - -template -struct __has_iterator_category -{ -private: - struct __two {char _; char __;}; - template static __two __test(...); - template static char __test(typename _Up::iterator_category* = 0); -public: - static const bool value = sizeof(__test<_Tp>(0)) == 1; -}; - -template struct ____iterator_traits {}; - -template -struct ____iterator_traits<_Iter, true> -{ - typedef typename _Iter::difference_type difference_type; - typedef typename _Iter::value_type value_type; - typedef typename _Iter::pointer pointer; - typedef typename _Iter::reference reference; - typedef typename _Iter::iterator_category iterator_category; -}; - -template struct __iterator_traits {}; - -template -struct __iterator_traits<_Iter, true> - : ____iterator_traits - < - _Iter, - is_convertible::value || - is_convertible::value - > -{}; - -// iterator_traits will only have the nested types if Iterator::iterator_category -// exists. Else iterator_traits will be an empty class. This is a -// conforming extension which allows some programs to compile and behave as -// the client expects instead of failing at compile time. - -template -struct _LIBCPP_VISIBLE iterator_traits - : __iterator_traits<_Iter, __has_iterator_category<_Iter>::value> {}; - -template -struct _LIBCPP_VISIBLE iterator_traits<_Tp*> -{ - typedef ptrdiff_t difference_type; - typedef typename remove_const<_Tp>::type value_type; - typedef _Tp* pointer; - typedef _Tp& reference; - typedef random_access_iterator_tag iterator_category; -}; - -template >::value> -struct __has_iterator_category_convertible_to - : public integral_constant::iterator_category, _Up>::value> -{}; - -template -struct __has_iterator_category_convertible_to<_Tp, _Up, false> : public false_type {}; - -template -struct __is_input_iterator : public __has_iterator_category_convertible_to<_Tp, input_iterator_tag> {}; - -template -struct __is_forward_iterator : public __has_iterator_category_convertible_to<_Tp, forward_iterator_tag> {}; - -template -struct __is_bidirectional_iterator : public __has_iterator_category_convertible_to<_Tp, bidirectional_iterator_tag> {}; - -template -struct __is_random_access_iterator : public __has_iterator_category_convertible_to<_Tp, random_access_iterator_tag> {}; - -template -struct _LIBCPP_VISIBLE iterator -{ - typedef _Tp value_type; - typedef _Distance difference_type; - typedef _Pointer pointer; - typedef _Reference reference; - typedef _Category iterator_category; -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -void __advance(_InputIter& __i, - typename iterator_traits<_InputIter>::difference_type __n, input_iterator_tag) -{ - for (; __n > 0; --__n) - ++__i; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void __advance(_BiDirIter& __i, - typename iterator_traits<_BiDirIter>::difference_type __n, bidirectional_iterator_tag) -{ - if (__n >= 0) - for (; __n > 0; --__n) - ++__i; - else - for (; __n < 0; ++__n) - --__i; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void __advance(_RandIter& __i, - typename iterator_traits<_RandIter>::difference_type __n, random_access_iterator_tag) -{ - __i += __n; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void advance(_InputIter& __i, - typename iterator_traits<_InputIter>::difference_type __n) -{ - __advance(__i, __n, typename iterator_traits<_InputIter>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename iterator_traits<_InputIter>::difference_type -__distance(_InputIter __first, _InputIter __last, input_iterator_tag) -{ - typename iterator_traits<_InputIter>::difference_type __r(0); - for (; __first != __last; ++__first) - ++__r; - return __r; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename iterator_traits<_RandIter>::difference_type -__distance(_RandIter __first, _RandIter __last, random_access_iterator_tag) -{ - return __last - __first; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename iterator_traits<_InputIter>::difference_type -distance(_InputIter __first, _InputIter __last) -{ - return __distance(__first, __last, typename iterator_traits<_InputIter>::iterator_category()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_ForwardIter -next(_ForwardIter __x, - typename iterator_traits<_ForwardIter>::difference_type __n = 1, - typename enable_if<__is_forward_iterator<_ForwardIter>::value>::type* = 0) -{ - _VSTD::advance(__x, __n); - return __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_BidiretionalIter -prev(_BidiretionalIter __x, - typename iterator_traits<_BidiretionalIter>::difference_type __n = 1, - typename enable_if<__is_bidirectional_iterator<_BidiretionalIter>::value>::type* = 0) -{ - _VSTD::advance(__x, -__n); - return __x; -} - -template -class _LIBCPP_VISIBLE reverse_iterator - : public iterator::iterator_category, - typename iterator_traits<_Iter>::value_type, - typename iterator_traits<_Iter>::difference_type, - typename iterator_traits<_Iter>::pointer, - typename iterator_traits<_Iter>::reference> -{ -private: - mutable _Iter __t; -protected: - _Iter current; -public: - typedef _Iter iterator_type; - typedef typename iterator_traits<_Iter>::difference_type difference_type; - typedef typename iterator_traits<_Iter>::reference reference; - typedef typename iterator_traits<_Iter>::pointer pointer; - - _LIBCPP_INLINE_VISIBILITY reverse_iterator() : current() {} - _LIBCPP_INLINE_VISIBILITY explicit reverse_iterator(_Iter __x) : __t(__x), current(__x) {} - template _LIBCPP_INLINE_VISIBILITY reverse_iterator(const reverse_iterator<_Up>& __u) - : __t(__u.base()), current(__u.base()) {} - _LIBCPP_INLINE_VISIBILITY _Iter base() const {return current;} - _LIBCPP_INLINE_VISIBILITY reference operator*() const {__t = current; return *--__t;} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return &(operator*());} - _LIBCPP_INLINE_VISIBILITY reverse_iterator& operator++() {--current; return *this;} - _LIBCPP_INLINE_VISIBILITY reverse_iterator operator++(int) - {reverse_iterator __tmp(*this); --current; return __tmp;} - _LIBCPP_INLINE_VISIBILITY reverse_iterator& operator--() {++current; return *this;} - _LIBCPP_INLINE_VISIBILITY reverse_iterator operator--(int) - {reverse_iterator __tmp(*this); ++current; return __tmp;} - _LIBCPP_INLINE_VISIBILITY reverse_iterator operator+ (difference_type __n) const - {return reverse_iterator(current - __n);} - _LIBCPP_INLINE_VISIBILITY reverse_iterator& operator+=(difference_type __n) - {current -= __n; return *this;} - _LIBCPP_INLINE_VISIBILITY reverse_iterator operator- (difference_type __n) const - {return reverse_iterator(current + __n);} - _LIBCPP_INLINE_VISIBILITY reverse_iterator& operator-=(difference_type __n) - {current += __n; return *this;} - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const - {return current[-__n-1];} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() == __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() > __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() != __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() < __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() <= __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __x.base() >= __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename reverse_iterator<_Iter1>::difference_type -operator-(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>& __y) -{ - return __y.base() - __x.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -reverse_iterator<_Iter> -operator+(typename reverse_iterator<_Iter>::difference_type __n, const reverse_iterator<_Iter>& __x) -{ - return reverse_iterator<_Iter>(__x.base() - __n); -} - -template -class _LIBCPP_VISIBLE back_insert_iterator - : public iterator&> -{ -protected: - _Container* container; -public: - typedef _Container container_type; - - _LIBCPP_INLINE_VISIBILITY explicit back_insert_iterator(_Container& __x) : container(&__x) {} - _LIBCPP_INLINE_VISIBILITY back_insert_iterator& operator=(const typename _Container::value_type& __value_) - {container->push_back(__value_); return *this;} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY back_insert_iterator& operator=(typename _Container::value_type&& __value_) - {container->push_back(_VSTD::move(__value_)); return *this;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY back_insert_iterator& operator*() {return *this;} - _LIBCPP_INLINE_VISIBILITY back_insert_iterator& operator++() {return *this;} - _LIBCPP_INLINE_VISIBILITY back_insert_iterator operator++(int) {return *this;} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -back_insert_iterator<_Container> -back_inserter(_Container& __x) -{ - return back_insert_iterator<_Container>(__x); -} - -template -class _LIBCPP_VISIBLE front_insert_iterator - : public iterator&> -{ -protected: - _Container* container; -public: - typedef _Container container_type; - - _LIBCPP_INLINE_VISIBILITY explicit front_insert_iterator(_Container& __x) : container(&__x) {} - _LIBCPP_INLINE_VISIBILITY front_insert_iterator& operator=(const typename _Container::value_type& __value_) - {container->push_front(__value_); return *this;} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY front_insert_iterator& operator=(typename _Container::value_type&& __value_) - {container->push_front(_VSTD::move(__value_)); return *this;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY front_insert_iterator& operator*() {return *this;} - _LIBCPP_INLINE_VISIBILITY front_insert_iterator& operator++() {return *this;} - _LIBCPP_INLINE_VISIBILITY front_insert_iterator operator++(int) {return *this;} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -front_insert_iterator<_Container> -front_inserter(_Container& __x) -{ - return front_insert_iterator<_Container>(__x); -} - -template -class _LIBCPP_VISIBLE insert_iterator - : public iterator&> -{ -protected: - _Container* container; - typename _Container::iterator iter; -public: - typedef _Container container_type; - - _LIBCPP_INLINE_VISIBILITY insert_iterator(_Container& __x, typename _Container::iterator __i) - : container(&__x), iter(__i) {} - _LIBCPP_INLINE_VISIBILITY insert_iterator& operator=(const typename _Container::value_type& __value_) - {iter = container->insert(iter, __value_); ++iter; return *this;} -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY insert_iterator& operator=(typename _Container::value_type&& __value_) - {iter = container->insert(iter, _VSTD::move(__value_)); ++iter; return *this;} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY insert_iterator& operator*() {return *this;} - _LIBCPP_INLINE_VISIBILITY insert_iterator& operator++() {return *this;} - _LIBCPP_INLINE_VISIBILITY insert_iterator& operator++(int) {return *this;} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -insert_iterator<_Container> -inserter(_Container& __x, typename _Container::iterator __i) -{ - return insert_iterator<_Container>(__x, __i); -} - -template , class _Distance = ptrdiff_t> -class _LIBCPP_VISIBLE istream_iterator - : public iterator -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef basic_istream<_CharT,_Traits> istream_type; -private: - istream_type* __in_stream_; - _Tp __value_; -public: - _LIBCPP_INLINE_VISIBILITY istream_iterator() : __in_stream_(0) {} - _LIBCPP_INLINE_VISIBILITY istream_iterator(istream_type& __s) : __in_stream_(&__s) - { - if (!(*__in_stream_ >> __value_)) - __in_stream_ = 0; - } - - _LIBCPP_INLINE_VISIBILITY const _Tp& operator*() const {return __value_;} - _LIBCPP_INLINE_VISIBILITY const _Tp* operator->() const {return &(operator*());} - _LIBCPP_INLINE_VISIBILITY istream_iterator& operator++() - { - if (!(*__in_stream_ >> __value_)) - __in_stream_ = 0; - return *this; - } - _LIBCPP_INLINE_VISIBILITY istream_iterator operator++(int) - {istream_iterator __t(*this); ++(*this); return __t;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const istream_iterator& __x, const istream_iterator& __y) - {return __x.__in_stream_ == __y.__in_stream_;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const istream_iterator& __x, const istream_iterator& __y) - {return !(__x == __y);} -}; - -template > -class _LIBCPP_VISIBLE ostream_iterator - : public iterator -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef basic_ostream<_CharT,_Traits> ostream_type; -private: - ostream_type* __out_stream_; - const char_type* __delim_; -public: - _LIBCPP_INLINE_VISIBILITY ostream_iterator(ostream_type& __s) - : __out_stream_(&__s), __delim_(0) {} - _LIBCPP_INLINE_VISIBILITY ostream_iterator(ostream_type& __s, const _CharT* __delimiter) - : __out_stream_(&__s), __delim_(__delimiter) {} - _LIBCPP_INLINE_VISIBILITY ostream_iterator& operator=(const _Tp& __value_) - { - *__out_stream_ << __value_; - if (__delim_) - *__out_stream_ << __delim_; - return *this; - } - - _LIBCPP_INLINE_VISIBILITY ostream_iterator& operator*() {return *this;} - _LIBCPP_INLINE_VISIBILITY ostream_iterator& operator++() {return *this;} - _LIBCPP_INLINE_VISIBILITY ostream_iterator& operator++(int) {return *this;} -}; - -template -class _LIBCPP_VISIBLE istreambuf_iterator - : public iterator -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef typename _Traits::int_type int_type; - typedef basic_streambuf<_CharT,_Traits> streambuf_type; - typedef basic_istream<_CharT,_Traits> istream_type; -private: - streambuf_type* __sbuf_; - - class __proxy - { - char_type __keep_; - streambuf_type* __sbuf_; - _LIBCPP_INLINE_VISIBILITY __proxy(char_type __c, streambuf_type* __s) - : __keep_(__c), __sbuf_(__s) {} - friend class istreambuf_iterator; - public: - _LIBCPP_INLINE_VISIBILITY char_type operator*() const {return __keep_;} - }; - - _LIBCPP_INLINE_VISIBILITY - void __test_for_eof() - { - if (__sbuf_ && traits_type::eq_int_type(__sbuf_->sgetc(), traits_type::eof())) - __sbuf_ = 0; - } -public: - _LIBCPP_INLINE_VISIBILITY istreambuf_iterator() throw() : __sbuf_(0) {} - _LIBCPP_INLINE_VISIBILITY istreambuf_iterator(istream_type& __s) throw() - : __sbuf_(__s.rdbuf()) {__test_for_eof();} - _LIBCPP_INLINE_VISIBILITY istreambuf_iterator(streambuf_type* __s) throw() - : __sbuf_(__s) {__test_for_eof();} - _LIBCPP_INLINE_VISIBILITY istreambuf_iterator(const __proxy& __p) throw() - : __sbuf_(__p.__sbuf_) {} - - _LIBCPP_INLINE_VISIBILITY char_type operator*() const - {return static_cast(__sbuf_->sgetc());} - _LIBCPP_INLINE_VISIBILITY char_type* operator->() const {return nullptr;} - _LIBCPP_INLINE_VISIBILITY istreambuf_iterator& operator++() - { - if (traits_type::eq_int_type(__sbuf_->snextc(), traits_type::eof())) - __sbuf_ = 0; - return *this; - } - _LIBCPP_INLINE_VISIBILITY __proxy operator++(int) - { - char_type __c = __sbuf_->sgetc(); - ++(*this); - return __proxy(__c, __sbuf_); - } - - _LIBCPP_INLINE_VISIBILITY bool equal(const istreambuf_iterator& __b) const - {return (__sbuf_ == 0) == (__b.__sbuf_ == 0);} -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator==(const istreambuf_iterator<_CharT,_Traits>& __a, - const istreambuf_iterator<_CharT,_Traits>& __b) - {return __a.equal(__b);} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool operator!=(const istreambuf_iterator<_CharT,_Traits>& __a, - const istreambuf_iterator<_CharT,_Traits>& __b) - {return !__a.equal(__b);} - -template -class _LIBCPP_VISIBLE ostreambuf_iterator - : public iterator -{ -public: - typedef _CharT char_type; - typedef _Traits traits_type; - typedef basic_streambuf<_CharT,_Traits> streambuf_type; - typedef basic_ostream<_CharT,_Traits> ostream_type; -private: - streambuf_type* __sbuf_; -public: - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator(ostream_type& __s) throw() - : __sbuf_(__s.rdbuf()) {} - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator(streambuf_type* __s) throw() - : __sbuf_(__s) {} - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator& operator=(_CharT __c) - { - if (__sbuf_ && traits_type::eq_int_type(__sbuf_->sputc(__c), traits_type::eof())) - __sbuf_ = 0; - return *this; - } - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator& operator*() {return *this;} - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator& operator++() {return *this;} - _LIBCPP_INLINE_VISIBILITY ostreambuf_iterator& operator++(int) {return *this;} - _LIBCPP_INLINE_VISIBILITY bool failed() const throw() {return __sbuf_ == 0;} -}; - -template -class _LIBCPP_VISIBLE move_iterator -{ -private: - _Iter __i; -public: - typedef _Iter iterator_type; - typedef typename iterator_traits::iterator_category iterator_category; - typedef typename iterator_traits::value_type value_type; - typedef typename iterator_traits::difference_type difference_type; - typedef typename iterator_traits::pointer pointer; -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - typedef value_type&& reference; -#else - typedef typename iterator_traits::reference reference; -#endif - - _LIBCPP_INLINE_VISIBILITY move_iterator() : __i() {} - _LIBCPP_INLINE_VISIBILITY explicit move_iterator(_Iter __x) : __i(__x) {} - template _LIBCPP_INLINE_VISIBILITY move_iterator(const move_iterator<_Up>& __u) - : __i(__u.base()) {} - _LIBCPP_INLINE_VISIBILITY _Iter base() const {return __i;} - _LIBCPP_INLINE_VISIBILITY reference operator*() const { - return static_cast(*__i); - } - _LIBCPP_INLINE_VISIBILITY pointer operator->() const { - typename iterator_traits::reference __ref = *__i; - return &__ref; - } - _LIBCPP_INLINE_VISIBILITY move_iterator& operator++() {++__i; return *this;} - _LIBCPP_INLINE_VISIBILITY move_iterator operator++(int) - {move_iterator __tmp(*this); ++__i; return __tmp;} - _LIBCPP_INLINE_VISIBILITY move_iterator& operator--() {--__i; return *this;} - _LIBCPP_INLINE_VISIBILITY move_iterator operator--(int) - {move_iterator __tmp(*this); --__i; return __tmp;} - _LIBCPP_INLINE_VISIBILITY move_iterator operator+ (difference_type __n) const - {return move_iterator(__i + __n);} - _LIBCPP_INLINE_VISIBILITY move_iterator& operator+=(difference_type __n) - {__i += __n; return *this;} - _LIBCPP_INLINE_VISIBILITY move_iterator operator- (difference_type __n) const - {return move_iterator(__i - __n);} - _LIBCPP_INLINE_VISIBILITY move_iterator& operator-=(difference_type __n) - {__i -= __n; return *this;} - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const - { - return static_cast(__i[__n]); - } -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() == __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() < __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() != __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() > __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() >= __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() <= __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename move_iterator<_Iter1>::difference_type -operator-(const move_iterator<_Iter1>& __x, const move_iterator<_Iter2>& __y) -{ - return __x.base() - __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -move_iterator<_Iter> -operator+(typename move_iterator<_Iter>::difference_type __n, const move_iterator<_Iter>& __x) -{ - return move_iterator<_Iter>(__x.base() + __n); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -move_iterator<_Iter> -make_move_iterator(const _Iter& __i) -{ - return move_iterator<_Iter>(__i); -} - -// __wrap_iter - -template class __wrap_iter; - -template -bool -operator==(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -bool -operator<(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -bool -operator!=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -bool -operator>(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -bool -operator>=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -bool -operator<=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -typename __wrap_iter<_Iter1>::difference_type -operator-(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - -template -__wrap_iter<_Iter> -operator+(typename __wrap_iter<_Iter>::difference_type, __wrap_iter<_Iter>) _NOEXCEPT; - -template _Op copy(_Ip, _Ip, _Op); -template _B2 copy_backward(_B1, _B1, _B2); -template _Op move(_Ip, _Ip, _Op); -template _B2 move_backward(_B1, _B1, _B2); - -template -typename enable_if -< - is_trivially_copy_assignable<_Tp>::value, - _Tp* ->::type -__unwrap_iter(__wrap_iter<_Tp*>); - -template -class __wrap_iter -{ -public: - typedef _Iter iterator_type; - typedef typename iterator_traits::iterator_category iterator_category; - typedef typename iterator_traits::value_type value_type; - typedef typename iterator_traits::difference_type difference_type; - typedef typename iterator_traits::pointer pointer; - typedef typename iterator_traits::reference reference; -private: - iterator_type __i; -public: - _LIBCPP_INLINE_VISIBILITY __wrap_iter() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_i(this); -#endif - } - template _LIBCPP_INLINE_VISIBILITY __wrap_iter(const __wrap_iter<_Up>& __u, - typename enable_if::value>::type* = 0) _NOEXCEPT - : __i(__u.base()) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__iterator_copy(this, &__u); -#endif - } -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_INLINE_VISIBILITY - __wrap_iter(const __wrap_iter& __x) - : __i(__x.base()) - { - __get_db()->__iterator_copy(this, &__x); - } - _LIBCPP_INLINE_VISIBILITY - __wrap_iter& operator=(const __wrap_iter& __x) - { - if (this != &__x) - { - __get_db()->__iterator_copy(this, &__x); - __i = __x.__i; - } - return *this; - } - _LIBCPP_INLINE_VISIBILITY - ~__wrap_iter() - { - __get_db()->__erase_i(this); - } -#endif - _LIBCPP_INLINE_VISIBILITY reference operator*() const _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to dereference a non-dereferenceable iterator"); -#endif - return *__i; - } - _LIBCPP_INLINE_VISIBILITY pointer operator->() const _NOEXCEPT {return &(operator*());} - _LIBCPP_INLINE_VISIBILITY __wrap_iter& operator++() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to increment non-incrementable iterator"); -#endif - ++__i; - return *this; - } - _LIBCPP_INLINE_VISIBILITY __wrap_iter operator++(int) _NOEXCEPT - {__wrap_iter __tmp(*this); ++(*this); return __tmp;} - _LIBCPP_INLINE_VISIBILITY __wrap_iter& operator--() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__decrementable(this), - "Attempted to decrement non-decrementable iterator"); -#endif - --__i; - return *this; - } - _LIBCPP_INLINE_VISIBILITY __wrap_iter operator--(int) _NOEXCEPT - {__wrap_iter __tmp(*this); --(*this); return __tmp;} - _LIBCPP_INLINE_VISIBILITY __wrap_iter operator+ (difference_type __n) const _NOEXCEPT - {__wrap_iter __w(*this); __w += __n; return __w;} - _LIBCPP_INLINE_VISIBILITY __wrap_iter& operator+=(difference_type __n) _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__addable(this, __n), - "Attempted to add/subtract iterator outside of valid range"); -#endif - __i += __n; - return *this; - } - _LIBCPP_INLINE_VISIBILITY __wrap_iter operator- (difference_type __n) const _NOEXCEPT - {return *this + (-__n);} - _LIBCPP_INLINE_VISIBILITY __wrap_iter& operator-=(difference_type __n) _NOEXCEPT - {*this += -__n; return *this;} - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__subscriptable(this, __n), - "Attempted to subscript iterator outside of valid range"); -#endif - return __i[__n]; - } - - _LIBCPP_INLINE_VISIBILITY iterator_type base() const _NOEXCEPT {return __i;} - -private: - _LIBCPP_INLINE_VISIBILITY __wrap_iter(iterator_type __x) _NOEXCEPT : __i(__x) {} -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_INLINE_VISIBILITY __wrap_iter(const void* __p, iterator_type __x) : __i(__x) - { - __get_db()->__insert_ic(this, __p); - } -#endif - - template friend class __wrap_iter; - template friend class basic_string; - template friend class vector; - - template - friend - bool - operator==(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - bool - operator<(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - bool - operator!=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - bool - operator>(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - bool - operator>=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - bool - operator<=(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - typename __wrap_iter<_Iter1>::difference_type - operator-(const __wrap_iter<_Iter1>&, const __wrap_iter<_Iter2>&) _NOEXCEPT; - - template - friend - __wrap_iter<_Iter1> - operator+(typename __wrap_iter<_Iter1>::difference_type, __wrap_iter<_Iter1>) _NOEXCEPT; - - template friend _Op copy(_Ip, _Ip, _Op); - template friend _B2 copy_backward(_B1, _B1, _B2); - template friend _Op move(_Ip, _Ip, _Op); - template friend _B2 move_backward(_B1, _B1, _B2); - - template - friend - typename enable_if - < - is_trivially_copy_assignable<_Tp>::value, - _Tp* - >::type - __unwrap_iter(__wrap_iter<_Tp*>); -}; - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__comparable(&__x, &__y), - "Attempted to compare incomparable iterators"); -#endif - return __x.base() == __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__comparable(&__x, &__y), - "Attempted to compare incomparable iterators"); -#endif - return __x.base() < __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __wrap_iter<_Iter1>::difference_type -operator-(const __wrap_iter<_Iter1>& __x, const __wrap_iter<_Iter2>& __y) _NOEXCEPT -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__comparable(&__x, &__y), - "Attempted to subtract incompatible iterators"); -#endif - return __x.base() - __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__wrap_iter<_Iter> -operator+(typename __wrap_iter<_Iter>::difference_type __n, - __wrap_iter<_Iter> __x) _NOEXCEPT -{ - __x += __n; - return __x; -} - -#ifdef _LIBCPP_DEBUG - -// __debug_iter - -template class __debug_iter; - -template -bool -operator==(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -bool -operator<(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -bool -operator!=(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -bool -operator>(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -bool -operator>=(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -bool -operator<=(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -typename __debug_iter<_Container, _Iter1>::difference_type -operator-(const __debug_iter<_Container, _Iter1>&, const __debug_iter<_Container, _Iter2>&); - -template -__debug_iter<_Container, _Iter> -operator+(typename __debug_iter<_Container, _Iter>::difference_type, const __debug_iter<_Container, _Iter>&); - -template -class __debug_iter -{ -public: - typedef _Iter iterator_type; - typedef _Container __container_type; - typedef typename iterator_traits::iterator_category iterator_category; - typedef typename iterator_traits::value_type value_type; - typedef typename iterator_traits::difference_type difference_type; - typedef typename iterator_traits::pointer pointer; - typedef typename iterator_traits::reference reference; -private: - iterator_type __i; - __debug_iter* __next; - __container_type* __cont; - -public: - _LIBCPP_INLINE_VISIBILITY __debug_iter() : __next(0), __cont(0) {} - _LIBCPP_INLINE_VISIBILITY __debug_iter(const __debug_iter& __x) - : __i(__x.base()), __next(0), __cont(0) {__set_owner(__x.__cont);} - __debug_iter& operator=(const __debug_iter& __x); - template _LIBCPP_INLINE_VISIBILITY __debug_iter(const __debug_iter<_Container, _Up>& __u, - typename enable_if::value>::type* = 0) - : __i(__u.base()), __next(0), __cont(0) {__set_owner(__u.__cont);} - _LIBCPP_INLINE_VISIBILITY ~__debug_iter() {__remove_owner();} - _LIBCPP_INLINE_VISIBILITY reference operator*() const {assert(__is_deref()); return *__i;} - _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return &(operator*());} - _LIBCPP_INLINE_VISIBILITY __debug_iter& operator++() {assert(__can_increment()); ++__i; return *this;} - _LIBCPP_INLINE_VISIBILITY __debug_iter operator++(int) - {__debug_iter __tmp(*this); operator++(); return __tmp;} - _LIBCPP_INLINE_VISIBILITY __debug_iter& operator--() {assert(__can_decrement()); --__i; return *this;} - _LIBCPP_INLINE_VISIBILITY __debug_iter operator--(int) - {__debug_iter __tmp(*this); operator--(); return __tmp;} - _LIBCPP_INLINE_VISIBILITY __debug_iter operator+ (difference_type __n) const - {__debug_iter __t(*this); __t += __n; return __t;} - __debug_iter& operator+=(difference_type __n); - _LIBCPP_INLINE_VISIBILITY __debug_iter operator- (difference_type __n) const - {__debug_iter __t(*this); __t -= __n; return __t;} - _LIBCPP_INLINE_VISIBILITY __debug_iter& operator-=(difference_type __n) - {*this += -__n; return *this;} - _LIBCPP_INLINE_VISIBILITY reference operator[](difference_type __n) const - {return *(*this + __n);} - -private: - _LIBCPP_INLINE_VISIBILITY __debug_iter(const __container_type* __c, iterator_type __x) - : __i(__x), __next(0), __cont(0) {__set_owner(__c);} - _LIBCPP_INLINE_VISIBILITY iterator_type base() const {return __i;} - - void __set_owner(const __container_type* __c); - void __remove_owner(); - static void __remove_all(__container_type* __c); - static void swap(__container_type* __x, __container_type* __y); - - _LIBCPP_INLINE_VISIBILITY bool __is_deref() const - {return __is_deref(__is_random_access_iterator());} - bool __is_deref(false_type) const; - bool __is_deref(true_type) const; - _LIBCPP_INLINE_VISIBILITY bool __can_decrement() const - {return __can_decrement(integral_constant::value ? 2: - __is_random_access_iterator::value ? 1 : 0>());} - bool __can_decrement(integral_constant) const; - bool __can_decrement(integral_constant) const; - bool __can_decrement(integral_constant) const; - _LIBCPP_INLINE_VISIBILITY bool __can_increment() const - {return __can_increment(integral_constant::value ? 2: - __is_random_access_iterator::value ? 1 : 0>());} - bool __can_increment(integral_constant) const; - bool __can_increment(integral_constant) const; - bool __can_increment(integral_constant) const; - - _LIBCPP_INLINE_VISIBILITY bool __can_add(difference_type __n) const - {return __can_add(__n, is_pointer());} - bool __can_add(difference_type __n, false_type) const; - bool __can_add(difference_type __n, true_type) const; - - template friend class __debug_iter; - friend class _Container::__self; - - template - friend - bool - operator==(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - bool - operator<(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - bool - operator!=(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - bool - operator>(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - bool - operator>=(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - bool - operator<=(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - typename __debug_iter<_Cp, _Iter1>::difference_type - operator-(const __debug_iter<_Cp, _Iter1>&, const __debug_iter<_Cp, _Iter2>&); - - template - friend - __debug_iter<_Cp, _Iter1> - operator+(typename __debug_iter<_Cp, _Iter1>::difference_type, const __debug_iter<_Cp, _Iter1>&); -}; - -template -__debug_iter<_Container, _Iter>& -__debug_iter<_Container, _Iter>::operator=(const __debug_iter& __x) -{ - if (this != &__x) - { - __remove_owner(); - __i = __x.__i; - __set_owner(__x.__cont); - } - return *this; -} - -template -void -__debug_iter<_Container, _Iter>::__set_owner(const __container_type* __c) -{ - __cont = const_cast<__container_type*>(__c); - __debug_iter*& __head = __cont->__get_iterator_list(this); - __next = __head; - __head = this; -} - -template -void -__debug_iter<_Container, _Iter>::__remove_owner() -{ - if (__cont) - { - __debug_iter*& __head = __cont->__get_iterator_list(this); - if (__head == this) - __head = __next; - else - { - __debug_iter* __prev = __head; - for (__debug_iter* __p = __head->__next; __p != this; __p = __p->__next) - __prev = __p; - __prev->__next = __next; - } - __cont = 0; - } -} - -template -void -__debug_iter<_Container, _Iter>::__remove_all(__container_type* __c) -{ - __debug_iter*& __head = __c->__get_iterator_list((__debug_iter*)0); - __debug_iter* __p = __head; - __head = 0; - while (__p) - { - __p->__cont = 0; - __debug_iter* __n = __p->__next; - __p->__next = 0; - __p = __n; - } -} - -template -void -__debug_iter<_Container, _Iter>::swap(__container_type* __x, __container_type* __y) -{ - __debug_iter*& __head_x = __x->__get_iterator_list((__debug_iter*)0); - __debug_iter*& __head_y = __y->__get_iterator_list((__debug_iter*)0); - __debug_iter* __p = __head_x; - __head_x = __head_y; - __head_y = __p; - for (__p = __head_x; __p; __p = __p->__next) - __p->__cont = __x; - for (__p = __head_y; __p; __p = __p->__next) - __p->__cont = __y; -} - -template -bool -__debug_iter<_Container, _Iter>::__is_deref(false_type) const -{ - if (__cont == 0) - return false; - return __i != __cont->end().base(); -} - -template -bool -__debug_iter<_Container, _Iter>::__is_deref(true_type) const -{ - if (__cont == 0) - return false; - return __i < __cont->end().base(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_decrement(integral_constant) const -{ - if (__cont == 0) - return false; - return __i != __cont->begin().base(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_decrement(integral_constant) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - return __b < __i && __i <= __b + __cont->size(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_decrement(integral_constant) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - return __b < __i && __i <= __b + __cont->size(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_increment(integral_constant) const -{ - if (__cont == 0) - return false; - return __i != __cont->end().base(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_increment(integral_constant) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - return __b <= __i && __i < __b + __cont->size(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_increment(integral_constant) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - return __b <= __i && __i < __b + __cont->size(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_add(difference_type __n, false_type) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - iterator_type __j = __i + __n; - return __b <= __j && __j <= __b + __cont->size(); -} - -template -bool -__debug_iter<_Container, _Iter>::__can_add(difference_type __n, true_type) const -{ - if (__cont == 0) - return false; - iterator_type __b = __cont->begin().base(); - iterator_type __j = __i + __n; - return __b <= __j && __j <= __b + __cont->size(); -} - -template -__debug_iter<_Container, _Iter>& -__debug_iter<_Container, _Iter>::operator+=(difference_type __n) -{ - assert(__can_add(__n)); - __i += __n; - return *this; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - assert(__x.__cont && __x.__cont == __y.__cont); - return __x.base() == __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - assert(__x.__cont && __x.__cont == __y.__cont); - return __x.base() < __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename __debug_iter<_Container, _Iter1>::difference_type -operator-(const __debug_iter<_Container, _Iter1>& __x, const __debug_iter<_Container, _Iter2>& __y) -{ - assert(__x.__cont && __x.__cont == __y.__cont); - return __x.base() - __y.base(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__debug_iter<_Container, _Iter> -operator+(typename __debug_iter<_Container, _Iter>::difference_type __n, - const __debug_iter<_Container, _Iter>& __x) -{ - return __x + __n; -} - -#endif // _LIBCPP_DEBUG - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_TRAILING_RETURN) - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -begin(_Cp& __c) -> decltype(__c.begin()) -{ - return __c.begin(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -begin(const _Cp& __c) -> decltype(__c.begin()) -{ - return __c.begin(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -end(_Cp& __c) -> decltype(__c.end()) -{ - return __c.end(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -auto -end(const _Cp& __c) -> decltype(__c.end()) -{ - return __c.end(); -} - -#else // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_TRAILING_RETURN) - -template -inline _LIBCPP_INLINE_VISIBILITY -typename _Cp::iterator -begin(_Cp& __c) -{ - return __c.begin(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename _Cp::const_iterator -begin(const _Cp& __c) -{ - return __c.begin(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename _Cp::iterator -end(_Cp& __c) -{ - return __c.end(); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename _Cp::const_iterator -end(const _Cp& __c) -{ - return __c.end(); -} - -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_TRAILING_RETURN) - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -begin(_Tp (&__array)[_Np]) -{ - return __array; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -end(_Tp (&__array)[_Np]) -{ - return __array + _Np; -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_ITERATOR diff --git a/libcxx/include/limits b/libcxx/include/limits deleted file mode 100644 index 68e63366abec..000000000000 --- a/libcxx/include/limits +++ /dev/null @@ -1,621 +0,0 @@ -// -*- C++ -*- -//===---------------------------- limits ----------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_LIMITS -#define _LIBCPP_LIMITS - -/* - limits synopsis - -namespace std -{ - -template -class numeric_limits -{ -public: - static constexpr bool is_specialized = false; - static constexpr T min() noexcept; - static constexpr T max() noexcept; - static constexpr T lowest() noexcept; - - static constexpr int digits = 0; - static constexpr int digits10 = 0; - static constexpr int max_digits10 = 0; - static constexpr bool is_signed = false; - static constexpr bool is_integer = false; - static constexpr bool is_exact = false; - static constexpr int radix = 0; - static constexpr T epsilon() noexcept; - static constexpr T round_error() noexcept; - - static constexpr int min_exponent = 0; - static constexpr int min_exponent10 = 0; - static constexpr int max_exponent = 0; - static constexpr int max_exponent10 = 0; - - static constexpr bool has_infinity = false; - static constexpr bool has_quiet_NaN = false; - static constexpr bool has_signaling_NaN = false; - static constexpr float_denorm_style has_denorm = denorm_absent; - static constexpr bool has_denorm_loss = false; - static constexpr T infinity() noexcept; - static constexpr T quiet_NaN() noexcept; - static constexpr T signaling_NaN() noexcept; - static constexpr T denorm_min() noexcept; - - static constexpr bool is_iec559 = false; - static constexpr bool is_bounded = false; - static constexpr bool is_modulo = false; - - static constexpr bool traps = false; - static constexpr bool tinyness_before = false; - static constexpr float_round_style round_style = round_toward_zero; -}; - -enum float_round_style -{ - round_indeterminate = -1, - round_toward_zero = 0, - round_to_nearest = 1, - round_toward_infinity = 2, - round_toward_neg_infinity = 3 -}; - -enum float_denorm_style -{ - denorm_indeterminate = -1, - denorm_absent = 0, - denorm_present = 1 -}; - -template<> class numeric_limits; - -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; - -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; - -template<> class numeric_limits; -template<> class numeric_limits; -template<> class numeric_limits; - -} // std - -*/ - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -#include <__config> -#include - -#include <__undef_min_max> - -#if defined(_MSC_VER) -#include "support/win32/limits_win32.h" -#endif // _MSC_VER - -_LIBCPP_BEGIN_NAMESPACE_STD - -enum float_round_style -{ - round_indeterminate = -1, - round_toward_zero = 0, - round_to_nearest = 1, - round_toward_infinity = 2, - round_toward_neg_infinity = 3 -}; - -enum float_denorm_style -{ - denorm_indeterminate = -1, - denorm_absent = 0, - denorm_present = 1 -}; - -template ::value> -class __libcpp_numeric_limits -{ -protected: - typedef _Tp type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return type();} - - static _LIBCPP_CONSTEXPR const int digits = 0; - static _LIBCPP_CONSTEXPR const int digits10 = 0; - static _LIBCPP_CONSTEXPR const int max_digits10 = 0; - static _LIBCPP_CONSTEXPR const bool is_signed = false; - static _LIBCPP_CONSTEXPR const bool is_integer = false; - static _LIBCPP_CONSTEXPR const bool is_exact = false; - static _LIBCPP_CONSTEXPR const int radix = 0; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return type();} - - static _LIBCPP_CONSTEXPR const int min_exponent = 0; - static _LIBCPP_CONSTEXPR const int min_exponent10 = 0; - static _LIBCPP_CONSTEXPR const int max_exponent = 0; - static _LIBCPP_CONSTEXPR const int max_exponent10 = 0; - - static _LIBCPP_CONSTEXPR const bool has_infinity = false; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = false; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = false; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_absent; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return type();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return type();} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = false; - static _LIBCPP_CONSTEXPR const bool is_bounded = false; - static _LIBCPP_CONSTEXPR const bool is_modulo = false; - - static _LIBCPP_CONSTEXPR const bool traps = false; - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_toward_zero; -}; - -template -struct __libcpp_compute_min -{ - static _LIBCPP_CONSTEXPR const _Tp value = _Tp(_Tp(1) << digits); -}; - -template -struct __libcpp_compute_min<_Tp, digits, false> -{ - static _LIBCPP_CONSTEXPR const _Tp value = _Tp(0); -}; - -template -class __libcpp_numeric_limits<_Tp, true> -{ -protected: - typedef _Tp type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = true; - - static _LIBCPP_CONSTEXPR const bool is_signed = type(-1) < type(0); - static _LIBCPP_CONSTEXPR const int digits = static_cast(sizeof(type) * __CHAR_BIT__ - is_signed); - static _LIBCPP_CONSTEXPR const int digits10 = digits * 3 / 10; - static _LIBCPP_CONSTEXPR const int max_digits10 = 0; - static _LIBCPP_CONSTEXPR const type __min = __libcpp_compute_min::value; - static _LIBCPP_CONSTEXPR const type __max = is_signed ? type(type(~0) ^ __min) : type(~0); - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __min;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __max;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return min();} - - static _LIBCPP_CONSTEXPR const bool is_integer = true; - static _LIBCPP_CONSTEXPR const bool is_exact = true; - static _LIBCPP_CONSTEXPR const int radix = 2; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return type(0);} - - static _LIBCPP_CONSTEXPR const int min_exponent = 0; - static _LIBCPP_CONSTEXPR const int min_exponent10 = 0; - static _LIBCPP_CONSTEXPR const int max_exponent = 0; - static _LIBCPP_CONSTEXPR const int max_exponent10 = 0; - - static _LIBCPP_CONSTEXPR const bool has_infinity = false; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = false; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = false; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_absent; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return type(0);} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = false; - static _LIBCPP_CONSTEXPR const bool is_bounded = true; - static _LIBCPP_CONSTEXPR const bool is_modulo = true; - -#if __i386__ || __x86_64__ - static _LIBCPP_CONSTEXPR const bool traps = true; -#else - static _LIBCPP_CONSTEXPR const bool traps = false; -#endif - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_toward_zero; -}; - -template <> -class __libcpp_numeric_limits -{ -protected: - typedef bool type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = true; - - static _LIBCPP_CONSTEXPR const bool is_signed = false; - static _LIBCPP_CONSTEXPR const int digits = 1; - static _LIBCPP_CONSTEXPR const int digits10 = 0; - static _LIBCPP_CONSTEXPR const int max_digits10 = 0; - static _LIBCPP_CONSTEXPR const type __min = false; - static _LIBCPP_CONSTEXPR const type __max = true; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __min;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __max;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return min();} - - static _LIBCPP_CONSTEXPR const bool is_integer = true; - static _LIBCPP_CONSTEXPR const bool is_exact = true; - static _LIBCPP_CONSTEXPR const int radix = 2; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return type(0);} - - static _LIBCPP_CONSTEXPR const int min_exponent = 0; - static _LIBCPP_CONSTEXPR const int min_exponent10 = 0; - static _LIBCPP_CONSTEXPR const int max_exponent = 0; - static _LIBCPP_CONSTEXPR const int max_exponent10 = 0; - - static _LIBCPP_CONSTEXPR const bool has_infinity = false; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = false; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = false; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_absent; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return type(0);} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return type(0);} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = false; - static _LIBCPP_CONSTEXPR const bool is_bounded = true; - static _LIBCPP_CONSTEXPR const bool is_modulo = false; - - static _LIBCPP_CONSTEXPR const bool traps = false; - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_toward_zero; -}; - -template <> -class __libcpp_numeric_limits -{ -protected: - typedef float type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = true; - - static _LIBCPP_CONSTEXPR const bool is_signed = true; - static _LIBCPP_CONSTEXPR const int digits = __FLT_MANT_DIG__; - static _LIBCPP_CONSTEXPR const int digits10 = __FLT_DIG__; - static _LIBCPP_CONSTEXPR const int max_digits10 = 2+(digits * 30103)/100000; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __FLT_MIN__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __FLT_MAX__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return -max();} - - static _LIBCPP_CONSTEXPR const bool is_integer = false; - static _LIBCPP_CONSTEXPR const bool is_exact = false; - static _LIBCPP_CONSTEXPR const int radix = __FLT_RADIX__; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __FLT_EPSILON__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return 0.5F;} - - static _LIBCPP_CONSTEXPR const int min_exponent = __FLT_MIN_EXP__; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __FLT_MIN_10_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent = __FLT_MAX_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __FLT_MAX_10_EXP__; - - static _LIBCPP_CONSTEXPR const bool has_infinity = true; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = true; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = true; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_present; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __builtin_huge_valf();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __builtin_nanf("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansf("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __FLT_DENORM_MIN__;} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = true; - static _LIBCPP_CONSTEXPR const bool is_bounded = true; - static _LIBCPP_CONSTEXPR const bool is_modulo = false; - - static _LIBCPP_CONSTEXPR const bool traps = false; - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_to_nearest; -}; - -template <> -class __libcpp_numeric_limits -{ -protected: - typedef double type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = true; - - static _LIBCPP_CONSTEXPR const bool is_signed = true; - static _LIBCPP_CONSTEXPR const int digits = __DBL_MANT_DIG__; - static _LIBCPP_CONSTEXPR const int digits10 = __DBL_DIG__; - static _LIBCPP_CONSTEXPR const int max_digits10 = 2+(digits * 30103)/100000; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __DBL_MIN__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __DBL_MAX__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return -max();} - - static _LIBCPP_CONSTEXPR const bool is_integer = false; - static _LIBCPP_CONSTEXPR const bool is_exact = false; - static _LIBCPP_CONSTEXPR const int radix = __FLT_RADIX__; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __DBL_EPSILON__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return 0.5;} - - static _LIBCPP_CONSTEXPR const int min_exponent = __DBL_MIN_EXP__; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __DBL_MIN_10_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent = __DBL_MAX_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __DBL_MAX_10_EXP__; - - static _LIBCPP_CONSTEXPR const bool has_infinity = true; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = true; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = true; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_present; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __builtin_huge_val();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __builtin_nan("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nans("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __DBL_DENORM_MIN__;} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = true; - static _LIBCPP_CONSTEXPR const bool is_bounded = true; - static _LIBCPP_CONSTEXPR const bool is_modulo = false; - - static _LIBCPP_CONSTEXPR const bool traps = false; - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_to_nearest; -}; - -template <> -class __libcpp_numeric_limits -{ -protected: - typedef long double type; - - static _LIBCPP_CONSTEXPR const bool is_specialized = true; - - static _LIBCPP_CONSTEXPR const bool is_signed = true; - static _LIBCPP_CONSTEXPR const int digits = __LDBL_MANT_DIG__; - static _LIBCPP_CONSTEXPR const int digits10 = __LDBL_DIG__; - static _LIBCPP_CONSTEXPR const int max_digits10 = 2+(digits * 30103)/100000; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __LDBL_MIN__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __LDBL_MAX__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return -max();} - - static _LIBCPP_CONSTEXPR const bool is_integer = false; - static _LIBCPP_CONSTEXPR const bool is_exact = false; - static _LIBCPP_CONSTEXPR const int radix = __FLT_RADIX__; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __LDBL_EPSILON__;} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return 0.5;} - - static _LIBCPP_CONSTEXPR const int min_exponent = __LDBL_MIN_EXP__; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __LDBL_MIN_10_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent = __LDBL_MAX_EXP__; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __LDBL_MAX_10_EXP__; - - static _LIBCPP_CONSTEXPR const bool has_infinity = true; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = true; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = true; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = denorm_present; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = false; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __builtin_huge_vall();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __builtin_nanl("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;} - -#if (defined(__ppc__) || defined(__ppc64__)) - static _LIBCPP_CONSTEXPR const bool is_iec559 = false; -#else - static _LIBCPP_CONSTEXPR const bool is_iec559 = true; -#endif - static _LIBCPP_CONSTEXPR const bool is_bounded = true; - static _LIBCPP_CONSTEXPR const bool is_modulo = false; - - static _LIBCPP_CONSTEXPR const bool traps = false; - static _LIBCPP_CONSTEXPR const bool tinyness_before = false; - static _LIBCPP_CONSTEXPR const float_round_style round_style = round_to_nearest; -}; - -template -class _LIBCPP_VISIBLE numeric_limits - : private __libcpp_numeric_limits::type> -{ - typedef __libcpp_numeric_limits::type> __base; - typedef typename __base::type type; -public: - static _LIBCPP_CONSTEXPR const bool is_specialized = __base::is_specialized; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __base::min();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __base::max();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return __base::lowest();} - - static _LIBCPP_CONSTEXPR const int digits = __base::digits; - static _LIBCPP_CONSTEXPR const int digits10 = __base::digits10; - static _LIBCPP_CONSTEXPR const int max_digits10 = __base::max_digits10; - static _LIBCPP_CONSTEXPR const bool is_signed = __base::is_signed; - static _LIBCPP_CONSTEXPR const bool is_integer = __base::is_integer; - static _LIBCPP_CONSTEXPR const bool is_exact = __base::is_exact; - static _LIBCPP_CONSTEXPR const int radix = __base::radix; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __base::epsilon();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return __base::round_error();} - - static _LIBCPP_CONSTEXPR const int min_exponent = __base::min_exponent; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __base::min_exponent10; - static _LIBCPP_CONSTEXPR const int max_exponent = __base::max_exponent; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __base::max_exponent10; - - static _LIBCPP_CONSTEXPR const bool has_infinity = __base::has_infinity; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = __base::has_quiet_NaN; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = __base::has_signaling_NaN; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = __base::has_denorm; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = __base::has_denorm_loss; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __base::infinity();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __base::quiet_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __base::signaling_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __base::denorm_min();} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = __base::is_iec559; - static _LIBCPP_CONSTEXPR const bool is_bounded = __base::is_bounded; - static _LIBCPP_CONSTEXPR const bool is_modulo = __base::is_modulo; - - static _LIBCPP_CONSTEXPR const bool traps = __base::traps; - static _LIBCPP_CONSTEXPR const bool tinyness_before = __base::tinyness_before; - static _LIBCPP_CONSTEXPR const float_round_style round_style = __base::round_style; -}; - -template -class _LIBCPP_VISIBLE numeric_limits - : private numeric_limits<_Tp> -{ - typedef numeric_limits<_Tp> __base; - typedef _Tp type; -public: - static _LIBCPP_CONSTEXPR const bool is_specialized = __base::is_specialized; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __base::min();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __base::max();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return __base::lowest();} - - static _LIBCPP_CONSTEXPR const int digits = __base::digits; - static _LIBCPP_CONSTEXPR const int digits10 = __base::digits10; - static _LIBCPP_CONSTEXPR const int max_digits10 = __base::max_digits10; - static _LIBCPP_CONSTEXPR const bool is_signed = __base::is_signed; - static _LIBCPP_CONSTEXPR const bool is_integer = __base::is_integer; - static _LIBCPP_CONSTEXPR const bool is_exact = __base::is_exact; - static _LIBCPP_CONSTEXPR const int radix = __base::radix; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __base::epsilon();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return __base::round_error();} - - static _LIBCPP_CONSTEXPR const int min_exponent = __base::min_exponent; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __base::min_exponent10; - static _LIBCPP_CONSTEXPR const int max_exponent = __base::max_exponent; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __base::max_exponent10; - - static _LIBCPP_CONSTEXPR const bool has_infinity = __base::has_infinity; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = __base::has_quiet_NaN; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = __base::has_signaling_NaN; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = __base::has_denorm; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = __base::has_denorm_loss; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __base::infinity();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __base::quiet_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __base::signaling_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __base::denorm_min();} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = __base::is_iec559; - static _LIBCPP_CONSTEXPR const bool is_bounded = __base::is_bounded; - static _LIBCPP_CONSTEXPR const bool is_modulo = __base::is_modulo; - - static _LIBCPP_CONSTEXPR const bool traps = __base::traps; - static _LIBCPP_CONSTEXPR const bool tinyness_before = __base::tinyness_before; - static _LIBCPP_CONSTEXPR const float_round_style round_style = __base::round_style; -}; - -template -class _LIBCPP_VISIBLE numeric_limits - : private numeric_limits<_Tp> -{ - typedef numeric_limits<_Tp> __base; - typedef _Tp type; -public: - static _LIBCPP_CONSTEXPR const bool is_specialized = __base::is_specialized; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __base::min();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __base::max();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return __base::lowest();} - - static _LIBCPP_CONSTEXPR const int digits = __base::digits; - static _LIBCPP_CONSTEXPR const int digits10 = __base::digits10; - static _LIBCPP_CONSTEXPR const int max_digits10 = __base::max_digits10; - static _LIBCPP_CONSTEXPR const bool is_signed = __base::is_signed; - static _LIBCPP_CONSTEXPR const bool is_integer = __base::is_integer; - static _LIBCPP_CONSTEXPR const bool is_exact = __base::is_exact; - static _LIBCPP_CONSTEXPR const int radix = __base::radix; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __base::epsilon();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return __base::round_error();} - - static _LIBCPP_CONSTEXPR const int min_exponent = __base::min_exponent; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __base::min_exponent10; - static _LIBCPP_CONSTEXPR const int max_exponent = __base::max_exponent; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __base::max_exponent10; - - static _LIBCPP_CONSTEXPR const bool has_infinity = __base::has_infinity; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = __base::has_quiet_NaN; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = __base::has_signaling_NaN; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = __base::has_denorm; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = __base::has_denorm_loss; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __base::infinity();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __base::quiet_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __base::signaling_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __base::denorm_min();} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = __base::is_iec559; - static _LIBCPP_CONSTEXPR const bool is_bounded = __base::is_bounded; - static _LIBCPP_CONSTEXPR const bool is_modulo = __base::is_modulo; - - static _LIBCPP_CONSTEXPR const bool traps = __base::traps; - static _LIBCPP_CONSTEXPR const bool tinyness_before = __base::tinyness_before; - static _LIBCPP_CONSTEXPR const float_round_style round_style = __base::round_style; -}; - -template -class _LIBCPP_VISIBLE numeric_limits - : private numeric_limits<_Tp> -{ - typedef numeric_limits<_Tp> __base; - typedef _Tp type; -public: - static _LIBCPP_CONSTEXPR const bool is_specialized = __base::is_specialized; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type min() _NOEXCEPT {return __base::min();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type max() _NOEXCEPT {return __base::max();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type lowest() _NOEXCEPT {return __base::lowest();} - - static _LIBCPP_CONSTEXPR const int digits = __base::digits; - static _LIBCPP_CONSTEXPR const int digits10 = __base::digits10; - static _LIBCPP_CONSTEXPR const int max_digits10 = __base::max_digits10; - static _LIBCPP_CONSTEXPR const bool is_signed = __base::is_signed; - static _LIBCPP_CONSTEXPR const bool is_integer = __base::is_integer; - static _LIBCPP_CONSTEXPR const bool is_exact = __base::is_exact; - static _LIBCPP_CONSTEXPR const int radix = __base::radix; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type epsilon() _NOEXCEPT {return __base::epsilon();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type round_error() _NOEXCEPT {return __base::round_error();} - - static _LIBCPP_CONSTEXPR const int min_exponent = __base::min_exponent; - static _LIBCPP_CONSTEXPR const int min_exponent10 = __base::min_exponent10; - static _LIBCPP_CONSTEXPR const int max_exponent = __base::max_exponent; - static _LIBCPP_CONSTEXPR const int max_exponent10 = __base::max_exponent10; - - static _LIBCPP_CONSTEXPR const bool has_infinity = __base::has_infinity; - static _LIBCPP_CONSTEXPR const bool has_quiet_NaN = __base::has_quiet_NaN; - static _LIBCPP_CONSTEXPR const bool has_signaling_NaN = __base::has_signaling_NaN; - static _LIBCPP_CONSTEXPR const float_denorm_style has_denorm = __base::has_denorm; - static _LIBCPP_CONSTEXPR const bool has_denorm_loss = __base::has_denorm_loss; - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __base::infinity();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type quiet_NaN() _NOEXCEPT {return __base::quiet_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __base::signaling_NaN();} - _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __base::denorm_min();} - - static _LIBCPP_CONSTEXPR const bool is_iec559 = __base::is_iec559; - static _LIBCPP_CONSTEXPR const bool is_bounded = __base::is_bounded; - static _LIBCPP_CONSTEXPR const bool is_modulo = __base::is_modulo; - - static _LIBCPP_CONSTEXPR const bool traps = __base::traps; - static _LIBCPP_CONSTEXPR const bool tinyness_before = __base::tinyness_before; - static _LIBCPP_CONSTEXPR const float_round_style round_style = __base::round_style; -}; - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_LIMITS diff --git a/libcxx/include/list b/libcxx/include/list deleted file mode 100644 index b486e8313411..000000000000 --- a/libcxx/include/list +++ /dev/null @@ -1,2275 +0,0 @@ -// -*- C++ -*- -//===---------------------------- list ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_LIST -#define _LIBCPP_LIST - -/* - list synopsis - -namespace std -{ - -template > -class list -{ -public: - - // types: - typedef T value_type; - typedef Alloc allocator_type; - typedef typename allocator_type::reference reference; - typedef typename allocator_type::const_reference const_reference; - typedef typename allocator_type::pointer pointer; - typedef typename allocator_type::const_pointer const_pointer; - typedef implementation-defined iterator; - typedef implementation-defined const_iterator; - typedef implementation-defined size_type; - typedef implementation-defined difference_type; - typedef reverse_iterator reverse_iterator; - typedef reverse_iterator const_reverse_iterator; - - list() - noexcept(is_nothrow_default_constructible::value); - explicit list(const allocator_type& a); - explicit list(size_type n); - list(size_type n, const value_type& value); - list(size_type n, const value_type& value, const allocator_type& a); - template - list(Iter first, Iter last); - template - list(Iter first, Iter last, const allocator_type& a); - list(const list& x); - list(const list&, const allocator_type& a); - list(list&& x) - noexcept(is_nothrow_move_constructible::value); - list(list&&, const allocator_type& a); - list(initializer_list); - list(initializer_list, const allocator_type& a); - - ~list(); - - list& operator=(const list& x); - list& operator=(list&& x) - noexcept( - allocator_type::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value); - list& operator=(initializer_list); - template - void assign(Iter first, Iter last); - void assign(size_type n, const value_type& t); - void assign(initializer_list); - - allocator_type get_allocator() const noexcept; - - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - reverse_iterator rbegin() noexcept; - const_reverse_iterator rbegin() const noexcept; - reverse_iterator rend() noexcept; - const_reverse_iterator rend() const noexcept; - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - const_reverse_iterator crbegin() const noexcept; - const_reverse_iterator crend() const noexcept; - - reference front(); - const_reference front() const; - reference back(); - const_reference back() const; - - bool empty() const noexcept; - size_type size() const noexcept; - size_type max_size() const noexcept; - - template - void emplace_front(Args&&... args); - void pop_front(); - template - void emplace_back(Args&&... args); - void pop_back(); - void push_front(const value_type& x); - void push_front(value_type&& x); - void push_back(const value_type& x); - void push_back(value_type&& x); - template - iterator emplace(const_iterator position, Args&&... args); - iterator insert(const_iterator position, const value_type& x); - iterator insert(const_iterator position, value_type&& x); - iterator insert(const_iterator position, size_type n, const value_type& x); - template - iterator insert(const_iterator position, Iter first, Iter last); - iterator insert(const_iterator position, initializer_list il); - - iterator erase(const_iterator position); - iterator erase(const_iterator position, const_iterator last); - - void resize(size_type sz); - void resize(size_type sz, const value_type& c); - - void swap(list&) - noexcept(!allocator_type::propagate_on_container_swap::value || - __is_nothrow_swappable::value); - void clear() noexcept; - - void splice(const_iterator position, list& x); - void splice(const_iterator position, list&& x); - void splice(const_iterator position, list& x, const_iterator i); - void splice(const_iterator position, list&& x, const_iterator i); - void splice(const_iterator position, list& x, const_iterator first, - const_iterator last); - void splice(const_iterator position, list&& x, const_iterator first, - const_iterator last); - - void remove(const value_type& value); - template void remove_if(Pred pred); - void unique(); - template - void unique(BinaryPredicate binary_pred); - void merge(list& x); - void merge(list&& x); - template - void merge(list& x, Compare comp); - template - void merge(list&& x, Compare comp); - void sort(); - template - void sort(Compare comp); - void reverse() noexcept; -}; - -template - bool operator==(const list& x, const list& y); -template - bool operator< (const list& x, const list& y); -template - bool operator!=(const list& x, const list& y); -template - bool operator> (const list& x, const list& y); -template - bool operator>=(const list& x, const list& y); -template - bool operator<=(const list& x, const list& y); - -template - void swap(list& x, list& y) - noexcept(noexcept(x.swap(y))); - -} // std - -*/ - -#include <__config> - -#include -#include -#include -#include -#include - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template struct __list_node; - -template -struct __list_node_base -{ - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__list_node<_Tp, _VoidPtr> > pointer; -#else - rebind<__list_node<_Tp, _VoidPtr> >::other pointer; -#endif - - pointer __prev_; - pointer __next_; - - _LIBCPP_INLINE_VISIBILITY - __list_node_base() - : __prev_(static_cast(this)), - __next_(static_cast(this)) - {} -}; - -template -struct __list_node - : public __list_node_base<_Tp, _VoidPtr> -{ - _Tp __value_; -}; - -template class list; -template class __list_imp; -template class __list_const_iterator; - -template -class _LIBCPP_VISIBLE __list_iterator -{ - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind<__list_node<_Tp, _VoidPtr> > __node_pointer; -#else - rebind<__list_node<_Tp, _VoidPtr> >::other __node_pointer; -#endif - - __node_pointer __ptr_; - -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_INLINE_VISIBILITY - explicit __list_iterator(__node_pointer __p, const void* __c) _NOEXCEPT - : __ptr_(__p) - { - __get_db()->__insert_ic(this, __c); - } -#else - _LIBCPP_INLINE_VISIBILITY - explicit __list_iterator(__node_pointer __p) _NOEXCEPT : __ptr_(__p) {} -#endif - - - - template friend class list; - template friend class __list_imp; - template friend class __list_const_iterator; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef _Tp value_type; - typedef value_type& reference; - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - typedef typename pointer_traits::difference_type difference_type; - - _LIBCPP_INLINE_VISIBILITY - __list_iterator() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_i(this); -#endif - } - -#if _LIBCPP_DEBUG_LEVEL >= 2 - - _LIBCPP_INLINE_VISIBILITY - __list_iterator(const __list_iterator& __p) - : __ptr_(__p.__ptr_) - { - __get_db()->__iterator_copy(this, &__p); - } - - _LIBCPP_INLINE_VISIBILITY - ~__list_iterator() - { - __get_db()->__erase_i(this); - } - - _LIBCPP_INLINE_VISIBILITY - __list_iterator& operator=(const __list_iterator& __p) - { - if (this != &__p) - { - __get_db()->__iterator_copy(this, &__p); - __ptr_ = __p.__ptr_; - } - return *this; - } - -#endif // _LIBCPP_DEBUG_LEVEL >= 2 - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to dereference a non-dereferenceable list::iterator"); -#endif - return __ptr_->__value_; - } - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &(operator*());} - - _LIBCPP_INLINE_VISIBILITY - __list_iterator& operator++() - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to increment non-incrementable list::iterator"); -#endif - __ptr_ = __ptr_->__next_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __list_iterator operator++(int) {__list_iterator __t(*this); ++(*this); return __t;} - - _LIBCPP_INLINE_VISIBILITY - __list_iterator& operator--() - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__decrementable(this), - "Attempted to decrement non-decrementable list::iterator"); -#endif - __ptr_ = __ptr_->__prev_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __list_iterator operator--(int) {__list_iterator __t(*this); --(*this); return __t;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __list_iterator& __x, const __list_iterator& __y) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__comparable(&__x, &__y), - "Attempted to compare non-comparable list::iterator"); -#endif - return __x.__ptr_ == __y.__ptr_; - } - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __list_iterator& __x, const __list_iterator& __y) - {return !(__x == __y);} -}; - -template -class _LIBCPP_VISIBLE __list_const_iterator -{ - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind > __node_pointer; -#else - rebind >::other __node_pointer; -#endif - - __node_pointer __ptr_; - -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_INLINE_VISIBILITY - explicit __list_const_iterator(__node_pointer __p, const void* __c) _NOEXCEPT - : __ptr_(__p) - { - __get_db()->__insert_ic(this, __c); - } -#else - _LIBCPP_INLINE_VISIBILITY - explicit __list_const_iterator(__node_pointer __p) _NOEXCEPT : __ptr_(__p) {} -#endif - - template friend class list; - template friend class __list_imp; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef _Tp value_type; - typedef const value_type& reference; - typedef typename pointer_traits<_VoidPtr>::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - typedef typename pointer_traits::difference_type difference_type; - - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_i(this); -#endif - } - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator(__list_iterator<_Tp, _VoidPtr> __p) _NOEXCEPT - : __ptr_(__p.__ptr_) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__iterator_copy(this, &__p); -#endif - } - -#if _LIBCPP_DEBUG_LEVEL >= 2 - - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator(const __list_const_iterator& __p) - : __ptr_(__p.__ptr_) - { - __get_db()->__iterator_copy(this, &__p); - } - - _LIBCPP_INLINE_VISIBILITY - ~__list_const_iterator() - { - __get_db()->__erase_i(this); - } - - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator& operator=(const __list_const_iterator& __p) - { - if (this != &__p) - { - __get_db()->__iterator_copy(this, &__p); - __ptr_ = __p.__ptr_; - } - return *this; - } - -#endif // _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_INLINE_VISIBILITY - reference operator*() const - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to dereference a non-dereferenceable list::const_iterator"); -#endif - return __ptr_->__value_; - } - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return &(operator*());} - - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator& operator++() - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(this), - "Attempted to increment non-incrementable list::const_iterator"); -#endif - __ptr_ = __ptr_->__next_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator operator++(int) {__list_const_iterator __t(*this); ++(*this); return __t;} - - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator& operator--() - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__decrementable(this), - "Attempted to decrement non-decrementable list::const_iterator"); -#endif - __ptr_ = __ptr_->__prev_; - return *this; - } - _LIBCPP_INLINE_VISIBILITY - __list_const_iterator operator--(int) {__list_const_iterator __t(*this); --(*this); return __t;} - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __list_const_iterator& __x, const __list_const_iterator& __y) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__comparable(&__x, &__y), - "Attempted to compare non-comparable list::const_iterator"); -#endif - return __x.__ptr_ == __y.__ptr_; - } - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __list_const_iterator& __x, const __list_const_iterator& __y) - {return !(__x == __y);} -}; - -template -class __list_imp -{ - __list_imp(const __list_imp&); - __list_imp& operator=(const __list_imp&); -protected: - typedef _Tp value_type; - typedef _Alloc allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::void_pointer __void_pointer; - typedef __list_iterator iterator; - typedef __list_const_iterator const_iterator; - typedef __list_node_base __node_base; - typedef __list_node __node; - typedef typename __alloc_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__node> -#else - rebind_alloc<__node>::other -#endif - __node_allocator; - typedef allocator_traits<__node_allocator> __node_alloc_traits; - typedef typename __node_alloc_traits::pointer __node_pointer; - typedef typename __node_alloc_traits::const_pointer __node_const_pointer; - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::difference_type difference_type; - - __node_base __end_; - __compressed_pair __size_alloc_; - - _LIBCPP_INLINE_VISIBILITY - size_type& __sz() _NOEXCEPT {return __size_alloc_.first();} - _LIBCPP_INLINE_VISIBILITY - const size_type& __sz() const _NOEXCEPT - {return __size_alloc_.first();} - _LIBCPP_INLINE_VISIBILITY - __node_allocator& __node_alloc() _NOEXCEPT - {return __size_alloc_.second();} - _LIBCPP_INLINE_VISIBILITY - const __node_allocator& __node_alloc() const _NOEXCEPT - {return __size_alloc_.second();} - - static void __unlink_nodes(__node_base& __f, __node_base& __l) _NOEXCEPT; - - __list_imp() - _NOEXCEPT_(is_nothrow_default_constructible<__node_allocator>::value); - __list_imp(const allocator_type& __a); - ~__list_imp(); - void clear() _NOEXCEPT; - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return __sz() == 0;} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(__end_.__next_, this); -#else - return iterator(__end_.__next_); -#endif - } - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - return const_iterator(__end_.__next_, this); -#else - return const_iterator(__end_.__next_); -#endif - } - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(static_cast<__node_pointer>(&__end_), this); -#else - return iterator(static_cast<__node_pointer>(&__end_)); -#endif - } - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - return const_iterator(static_cast<__node_const_pointer>(&__end_), this); -#else - return const_iterator(static_cast<__node_const_pointer>(&__end_)); -#endif - } - - void swap(__list_imp& __c) - _NOEXCEPT_(!__node_alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value); - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __list_imp& __c) - {__copy_assign_alloc(__c, integral_constant());} - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__list_imp& __c) - _NOEXCEPT_( - !__node_alloc_traits::propagate_on_container_move_assignment::value || - is_nothrow_move_assignable<__node_allocator>::value) - {__move_assign_alloc(__c, integral_constant());} - -private: - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y) - _NOEXCEPT_(!__node_alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) - {__swap_alloc(__x, __y, integral_constant());} - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, true_type) - _NOEXCEPT_(__is_nothrow_swappable<__node_allocator>::value) - { - using _VSTD::swap; - swap(__x, __y); - } - _LIBCPP_INLINE_VISIBILITY - static void __swap_alloc(__node_allocator& __x, __node_allocator& __y, false_type) - _NOEXCEPT - {} - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __list_imp& __c, true_type) - { - if (__node_alloc() != __c.__node_alloc()) - clear(); - __node_alloc() = __c.__node_alloc(); - } - - _LIBCPP_INLINE_VISIBILITY - void __copy_assign_alloc(const __list_imp& __c, false_type) - {} - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__list_imp& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value) - { - __node_alloc() = _VSTD::move(__c.__node_alloc()); - } - - _LIBCPP_INLINE_VISIBILITY - void __move_assign_alloc(__list_imp& __c, false_type) - _NOEXCEPT - {} -}; - -// Unlink nodes [__f, __l] -template -inline _LIBCPP_INLINE_VISIBILITY -void -__list_imp<_Tp, _Alloc>::__unlink_nodes(__node_base& __f, __node_base& __l) - _NOEXCEPT -{ - __f.__prev_->__next_ = __l.__next_; - __l.__next_->__prev_ = __f.__prev_; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__list_imp<_Tp, _Alloc>::__list_imp() - _NOEXCEPT_(is_nothrow_default_constructible<__node_allocator>::value) - : __size_alloc_(0) -{ -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__list_imp<_Tp, _Alloc>::__list_imp(const allocator_type& __a) - : __size_alloc_(0, __node_allocator(__a)) -{ -} - -template -__list_imp<_Tp, _Alloc>::~__list_imp() -{ - clear(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__erase_c(this); -#endif -} - -template -void -__list_imp<_Tp, _Alloc>::clear() _NOEXCEPT -{ - if (!empty()) - { - __node_allocator& __na = __node_alloc(); - __node_pointer __f = __end_.__next_; - __node_pointer __l = static_cast<__node_pointer>(&__end_); - __unlink_nodes(*__f, *__l->__prev_); - __sz() = 0; - while (__f != __l) - { - __node& __n = *__f; - __f = __f->__next_; - __node_alloc_traits::destroy(__na, _VSTD::addressof(__n.__value_)); - __node_alloc_traits::deallocate(__na, _VSTD::addressof(__n), 1); - } -#if _LIBCPP_DEBUG_LEVEL >= 2 - __c_node* __c = __get_db()->__find_c_and_lock(this); - for (__i_node** __p = __c->end_; __p != __c->beg_; ) - { - --__p; - const_iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ != __l) - { - (*__p)->__c_ = nullptr; - if (--__c->end_ != __p) - memmove(__p, __p+1, (__c->end_ - __p)*sizeof(__i_node*)); - } - } - __get_db()->unlock(); -#endif - } -} - -template -void -__list_imp<_Tp, _Alloc>::swap(__list_imp& __c) - _NOEXCEPT_(!__node_alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) -{ - _LIBCPP_ASSERT(__alloc_traits::propagate_on_container_swap::value || - this->__node_alloc() == __c.__node_alloc(), - "list::swap: Either propagate_on_container_swap must be true" - " or the allocators must compare equal"); - using _VSTD::swap; - __swap_alloc(__node_alloc(), __c.__node_alloc()); - swap(__sz(), __c.__sz()); - swap(__end_, __c.__end_); - if (__sz() == 0) - __end_.__next_ = __end_.__prev_ = &static_cast<__node&>(__end_); - else - __end_.__prev_->__next_ = __end_.__next_->__prev_ - = &static_cast<__node&>(__end_); - if (__c.__sz() == 0) - __c.__end_.__next_ = __c.__end_.__prev_ - = &static_cast<__node&>(__c.__end_); - else - __c.__end_.__prev_->__next_ = __c.__end_.__next_->__prev_ - = &static_cast<__node&>(__c.__end_); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __libcpp_db* __db = __get_db(); - __c_node* __cn1 = __db->__find_c_and_lock(this); - __c_node* __cn2 = __db->__find_c(&__c); - std::swap(__cn1->beg_, __cn2->beg_); - std::swap(__cn1->end_, __cn2->end_); - std::swap(__cn1->cap_, __cn2->cap_); - for (__i_node** __p = __cn1->end_; __p != __cn1->beg_;) - { - --__p; - const_iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == static_cast<__node_pointer>(&__c.__end_)) - { - __cn2->__add(*__p); - if (--__cn1->end_ != __p) - memmove(__p, __p+1, (__cn1->end_ - __p)*sizeof(__i_node*)); - } - else - (*__p)->__c_ = __cn1; - } - for (__i_node** __p = __cn2->end_; __p != __cn2->beg_;) - { - --__p; - const_iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == static_cast<__node_pointer>(&__end_)) - { - __cn1->__add(*__p); - if (--__cn2->end_ != __p) - memmove(__p, __p+1, (__cn2->end_ - __p)*sizeof(__i_node*)); - } - else - (*__p)->__c_ = __cn2; - } - __db->unlock(); -#endif -} - -template > -class _LIBCPP_VISIBLE list - : private __list_imp<_Tp, _Alloc> -{ - typedef __list_imp<_Tp, _Alloc> base; - typedef typename base::__node __node; - typedef typename base::__node_allocator __node_allocator; - typedef typename base::__node_pointer __node_pointer; - typedef typename base::__node_alloc_traits __node_alloc_traits; - -public: - typedef _Tp value_type; - typedef _Alloc allocator_type; - static_assert((is_same::value), - "Invalid allocator::value_type"); - typedef value_type& reference; - typedef const value_type& const_reference; - typedef typename base::pointer pointer; - typedef typename base::const_pointer const_pointer; - typedef typename base::size_type size_type; - typedef typename base::difference_type difference_type; - typedef typename base::iterator iterator; - typedef typename base::const_iterator const_iterator; - typedef _VSTD::reverse_iterator reverse_iterator; - typedef _VSTD::reverse_iterator const_reverse_iterator; - - _LIBCPP_INLINE_VISIBILITY - list() - _NOEXCEPT_(is_nothrow_default_constructible<__node_allocator>::value) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - } - _LIBCPP_INLINE_VISIBILITY - list(const allocator_type& __a) : base(__a) - { -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - } - list(size_type __n); - list(size_type __n, const value_type& __x); - list(size_type __n, const value_type& __x, const allocator_type& __a); - template - list(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type* = 0); - template - list(_InpIter __f, _InpIter __l, const allocator_type& __a, - typename enable_if<__is_input_iterator<_InpIter>::value>::type* = 0); - - list(const list& __c); - list(const list& __c, const allocator_type& __a); - list& operator=(const list& __c); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - list(initializer_list __il); - list(initializer_list __il, const allocator_type& __a); -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - list(list&& __c) - _NOEXCEPT_(is_nothrow_move_constructible<__node_allocator>::value); - list(list&& __c, const allocator_type& __a); - list& operator=(list&& __c) - _NOEXCEPT_( - __node_alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable<__node_allocator>::value); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - list& operator=(initializer_list __il) - {assign(__il.begin(), __il.end()); return *this;} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - template - void assign(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type* = 0); - void assign(size_type __n, const value_type& __x); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - void assign(initializer_list __il) - {assign(__il.begin(), __il.end());} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - allocator_type get_allocator() const _NOEXCEPT; - - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return base::__sz();} - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return base::empty();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT - {return numeric_limits::max();} - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return base::begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return base::begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return base::end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return base::end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT {return base::begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT {return base::end();} - - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rbegin() _NOEXCEPT - {return reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rbegin() const _NOEXCEPT - {return const_reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rend() _NOEXCEPT - {return reverse_iterator(begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rend() const _NOEXCEPT - {return const_reverse_iterator(begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crbegin() const _NOEXCEPT - {return const_reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crend() const _NOEXCEPT - {return const_reverse_iterator(begin());} - - _LIBCPP_INLINE_VISIBILITY - reference front() - { - _LIBCPP_ASSERT(!empty(), "list::front called on empty list"); - return base::__end_.__next_->__value_; - } - _LIBCPP_INLINE_VISIBILITY - const_reference front() const - { - _LIBCPP_ASSERT(!empty(), "list::front called on empty list"); - return base::__end_.__next_->__value_; - } - _LIBCPP_INLINE_VISIBILITY - reference back() - { - _LIBCPP_ASSERT(!empty(), "list::back called on empty list"); - return base::__end_.__prev_->__value_; - } - _LIBCPP_INLINE_VISIBILITY - const_reference back() const - { - _LIBCPP_ASSERT(!empty(), "list::back called on empty list"); - return base::__end_.__prev_->__value_; - } - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - void push_front(value_type&& __x); - void push_back(value_type&& __x); -#ifndef _LIBCPP_HAS_NO_VARIADICS - template - void emplace_front(_Args&&... __args); - template - void emplace_back(_Args&&... __args); - template - iterator emplace(const_iterator __p, _Args&&... __args); -#endif // _LIBCPP_HAS_NO_VARIADICS - iterator insert(const_iterator __p, value_type&& __x); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - void push_front(const value_type& __x); - void push_back(const value_type& __x); - - iterator insert(const_iterator __p, const value_type& __x); - iterator insert(const_iterator __p, size_type __n, const value_type& __x); - template - iterator insert(const_iterator __p, _InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type* = 0); -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator __p, initializer_list __il) - {return insert(__p, __il.begin(), __il.end());} -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - void swap(list& __c) - _NOEXCEPT_(!__node_alloc_traits::propagate_on_container_swap::value || - __is_nothrow_swappable<__node_allocator>::value) - {base::swap(__c);} - _LIBCPP_INLINE_VISIBILITY - void clear() _NOEXCEPT {base::clear();} - - void pop_front(); - void pop_back(); - - iterator erase(const_iterator __p); - iterator erase(const_iterator __f, const_iterator __l); - - void resize(size_type __n); - void resize(size_type __n, const value_type& __x); - - void splice(const_iterator __p, list& __c); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void splice(const_iterator __p, list&& __c) {splice(__p, __c);} -#endif - void splice(const_iterator __p, list& __c, const_iterator __i); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void splice(const_iterator __p, list&& __c, const_iterator __i) - {splice(__p, __c, __i);} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - void splice(const_iterator __p, list& __c, const_iterator __f, const_iterator __l); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void splice(const_iterator __p, list&& __c, const_iterator __f, const_iterator __l) - {splice(__p, __c, __f, __l);} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - void remove(const value_type& __x); - template void remove_if(_Pred __pred); - void unique(); - template - void unique(_BinaryPred __binary_pred); - void merge(list& __c); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - void merge(list&& __c) {merge(__c);} -#endif - template - void merge(list& __c, _Comp __comp); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - template - _LIBCPP_INLINE_VISIBILITY - void merge(list&& __c, _Comp __comp) {merge(__c, __comp);} -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - void sort(); - template - void sort(_Comp __comp); - - void reverse() _NOEXCEPT; - - bool __invariants() const; - -#if _LIBCPP_DEBUG_LEVEL >= 2 - - bool __dereferenceable(const const_iterator* __i) const; - bool __decrementable(const const_iterator* __i) const; - bool __addable(const const_iterator* __i, ptrdiff_t __n) const; - bool __subscriptable(const const_iterator* __i, ptrdiff_t __n) const; - -#endif // _LIBCPP_DEBUG_LEVEL >= 2 - -private: - static void __link_nodes(__node& __p, __node& __f, __node& __l); - iterator __iterator(size_type __n); - template - static iterator __sort(iterator __f1, iterator __e2, size_type __n, _Comp& __comp); - - void __move_assign(list& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value); - void __move_assign(list& __c, false_type); -}; - -// Link in nodes [__f, __l] just prior to __p -template -inline _LIBCPP_INLINE_VISIBILITY -void -list<_Tp, _Alloc>::__link_nodes(__node& __p, __node& __f, __node& __l) -{ - __p.__prev_->__next_ = &__f; - __f.__prev_ = __p.__prev_; - __p.__prev_ = &__l; - __l.__next_ = &__p; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::__iterator(size_type __n) -{ - return __n <= base::__sz() / 2 ? _VSTD::next(begin(), __n) - : _VSTD::prev(end(), base::__sz() - __n); -} - -template -list<_Tp, _Alloc>::list(size_type __n) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (; __n > 0; --__n) -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - emplace_back(); -#else - push_back(value_type()); -#endif -} - -template -list<_Tp, _Alloc>::list(size_type __n, const value_type& __x) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (; __n > 0; --__n) - push_back(__x); -} - -template -list<_Tp, _Alloc>::list(size_type __n, const value_type& __x, const allocator_type& __a) - : base(__a) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (; __n > 0; --__n) - push_back(__x); -} - -template -template -list<_Tp, _Alloc>::list(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type*) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (; __f != __l; ++__f) - push_back(*__f); -} - -template -template -list<_Tp, _Alloc>::list(_InpIter __f, _InpIter __l, const allocator_type& __a, - typename enable_if<__is_input_iterator<_InpIter>::value>::type*) - : base(__a) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (; __f != __l; ++__f) - push_back(*__f); -} - -template -list<_Tp, _Alloc>::list(const list& __c) - : base(allocator_type( - __node_alloc_traits::select_on_container_copy_construction( - __c.__node_alloc()))) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (const_iterator __i = __c.begin(), __e = __c.end(); __i != __e; ++__i) - push_back(*__i); -} - -template -list<_Tp, _Alloc>::list(const list& __c, const allocator_type& __a) - : base(__a) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (const_iterator __i = __c.begin(), __e = __c.end(); __i != __e; ++__i) - push_back(*__i); -} - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -list<_Tp, _Alloc>::list(initializer_list __il, const allocator_type& __a) - : base(__a) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (typename initializer_list::const_iterator __i = __il.begin(), - __e = __il.end(); __i != __e; ++__i) - push_back(*__i); -} - -template -list<_Tp, _Alloc>::list(initializer_list __il) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - for (typename initializer_list::const_iterator __i = __il.begin(), - __e = __il.end(); __i != __e; ++__i) - push_back(*__i); -} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - -template -inline _LIBCPP_INLINE_VISIBILITY -list<_Tp, _Alloc>& -list<_Tp, _Alloc>::operator=(const list& __c) -{ - if (this != &__c) - { - base::__copy_assign_alloc(__c); - assign(__c.begin(), __c.end()); - } - return *this; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_INLINE_VISIBILITY -list<_Tp, _Alloc>::list(list&& __c) - _NOEXCEPT_(is_nothrow_move_constructible<__node_allocator>::value) - : base(allocator_type(_VSTD::move(__c.__node_alloc()))) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - splice(end(), __c); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -list<_Tp, _Alloc>::list(list&& __c, const allocator_type& __a) - : base(__a) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - __get_db()->__insert_c(this); -#endif - if (__a == __c.get_allocator()) - splice(end(), __c); - else - { - typedef move_iterator _Ip; - assign(_Ip(__c.begin()), _Ip(__c.end())); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -list<_Tp, _Alloc>& -list<_Tp, _Alloc>::operator=(list&& __c) - _NOEXCEPT_( - __node_alloc_traits::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable<__node_allocator>::value) -{ - __move_assign(__c, integral_constant()); - return *this; -} - -template -void -list<_Tp, _Alloc>::__move_assign(list& __c, false_type) -{ - if (base::__node_alloc() != __c.__node_alloc()) - { - typedef move_iterator _Ip; - assign(_Ip(__c.begin()), _Ip(__c.end())); - } - else - __move_assign(__c, true_type()); -} - -template -void -list<_Tp, _Alloc>::__move_assign(list& __c, true_type) - _NOEXCEPT_(is_nothrow_move_assignable<__node_allocator>::value) -{ - clear(); - base::__move_assign_alloc(__c); - splice(end(), __c); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -template -void -list<_Tp, _Alloc>::assign(_InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type*) -{ - iterator __i = begin(); - iterator __e = end(); - for (; __f != __l && __i != __e; ++__f, ++__i) - *__i = *__f; - if (__i == __e) - insert(__e, __f, __l); - else - erase(__i, __e); -} - -template -void -list<_Tp, _Alloc>::assign(size_type __n, const value_type& __x) -{ - iterator __i = begin(); - iterator __e = end(); - for (; __n > 0 && __i != __e; --__n, ++__i) - *__i = __x; - if (__i == __e) - insert(__e, __n, __x); - else - erase(__i, __e); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -_Alloc -list<_Tp, _Alloc>::get_allocator() const _NOEXCEPT -{ - return allocator_type(base::__node_alloc()); -} - -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::insert(const_iterator __p, const value_type& __x) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::insert(iterator, x) called with an iterator not" - " referring to this list"); -#endif - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - __link_nodes(const_cast<__node&>(*__p.__ptr_), *__hold, *__hold); - ++base::__sz(); - return iterator(__hold.release()); -} - -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::insert(const_iterator __p, size_type __n, const value_type& __x) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::insert(iterator, n, x) called with an iterator not" - " referring to this list"); - iterator __r(const_cast<__node_pointer>(__p.__ptr_), this); -#else - iterator __r(const_cast<__node_pointer>(__p.__ptr_)); -#endif - if (__n > 0) - { - size_type __ds = 0; - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - ++__ds; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __r = iterator(__hold.get(), this); -#else - __r = iterator(__hold.get()); -#endif - __hold.release(); - iterator __e = __r; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (--__n; __n != 0; --__n, ++__e, ++__ds) - { - __hold.reset(__node_alloc_traits::allocate(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - __e.__ptr_->__next_ = __hold.get(); - __hold->__prev_ = __e.__ptr_; - __hold.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (true) - { - __node_alloc_traits::destroy(__na, _VSTD::addressof(*__e)); - __node_pointer __prev = __e.__ptr_->__prev_; - __node_alloc_traits::deallocate(__na, __e.__ptr_, 1); - if (__prev == 0) - break; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __e = iterator(__prev, this); -#else - __e = iterator(__prev); -#endif - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __link_nodes(const_cast<__node&>(*__p.__ptr_), *__r.__ptr_, *__e.__ptr_); - base::__sz() += __ds; - } - return __r; -} - -template -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::insert(const_iterator __p, _InpIter __f, _InpIter __l, - typename enable_if<__is_input_iterator<_InpIter>::value>::type*) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::insert(iterator, range) called with an iterator not" - " referring to this list"); - iterator __r(const_cast<__node_pointer>(__p.__ptr_), this); -#else - iterator __r(const_cast<__node_pointer>(__p.__ptr_)); -#endif - if (__f != __l) - { - size_type __ds = 0; - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), *__f); - ++__ds; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __r = iterator(__hold.get(), this); -#else - __r = iterator(__hold.get()); -#endif - __hold.release(); - iterator __e = __r; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (++__f; __f != __l; ++__f, ++__e, ++__ds) - { - __hold.reset(__node_alloc_traits::allocate(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), *__f); - __e.__ptr_->__next_ = __hold.get(); - __hold->__prev_ = __e.__ptr_; - __hold.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (true) - { - __node_alloc_traits::destroy(__na, _VSTD::addressof(*__e)); - __node_pointer __prev = __e.__ptr_->__prev_; - __node_alloc_traits::deallocate(__na, __e.__ptr_, 1); - if (__prev == 0) - break; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __e = iterator(__prev, this); -#else - __e = iterator(__prev); -#endif - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __link_nodes(const_cast<__node&>(*__p.__ptr_), *__r.__ptr_, *__e.__ptr_); - base::__sz() += __ds; - } - return __r; -} - -template -void -list<_Tp, _Alloc>::push_front(const value_type& __x) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - __link_nodes(*base::__end_.__next_, *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -template -void -list<_Tp, _Alloc>::push_back(const value_type& __x) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - __link_nodes(static_cast<__node&>(base::__end_), *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -list<_Tp, _Alloc>::push_front(value_type&& __x) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::move(__x)); - __link_nodes(*base::__end_.__next_, *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -template -void -list<_Tp, _Alloc>::push_back(value_type&& __x) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::move(__x)); - __link_nodes(static_cast<__node&>(base::__end_), *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -void -list<_Tp, _Alloc>::emplace_front(_Args&&... __args) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::forward<_Args>(__args)...); - __link_nodes(*base::__end_.__next_, *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -template -template -void -list<_Tp, _Alloc>::emplace_back(_Args&&... __args) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::forward<_Args>(__args)...); - __link_nodes(static_cast<__node&>(base::__end_), *__hold, *__hold); - ++base::__sz(); - __hold.release(); -} - -template -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::emplace(const_iterator __p, _Args&&... __args) -{ - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::forward<_Args>(__args)...); - __link_nodes(const_cast<__node&>(*__p.__ptr_), *__hold, *__hold); - ++base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(__hold.release(), this); -#else - return iterator(__hold.release()); -#endif -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::insert(const_iterator __p, value_type&& __x) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::insert(iterator, x) called with an iterator not" - " referring to this list"); -#endif - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), _VSTD::move(__x)); - __link_nodes(const_cast<__node&>(*__p.__ptr_), *__hold, *__hold); - ++base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(__hold.release(), this); -#else - return iterator(__hold.release()); -#endif -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -void -list<_Tp, _Alloc>::pop_front() -{ - _LIBCPP_ASSERT(!empty(), "list::pop_front() called with empty list"); - __node_allocator& __na = base::__node_alloc(); - __node& __n = *base::__end_.__next_; - base::__unlink_nodes(__n, __n); - --base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __c_node* __c = __get_db()->__find_c_and_lock(this); - for (__i_node** __p = __c->end_; __p != __c->beg_; ) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == &__n) - { - (*__p)->__c_ = nullptr; - if (--__c->end_ != __p) - memmove(__p, __p+1, (__c->end_ - __p)*sizeof(__i_node*)); - } - } - __get_db()->unlock(); -#endif - __node_alloc_traits::destroy(__na, _VSTD::addressof(__n.__value_)); - __node_alloc_traits::deallocate(__na, _VSTD::addressof(__n), 1); -} - -template -void -list<_Tp, _Alloc>::pop_back() -{ - _LIBCPP_ASSERT(!empty(), "list::pop_front() called with empty list"); - __node_allocator& __na = base::__node_alloc(); - __node& __n = *base::__end_.__prev_; - base::__unlink_nodes(__n, __n); - --base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __c_node* __c = __get_db()->__find_c_and_lock(this); - for (__i_node** __p = __c->end_; __p != __c->beg_; ) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == &__n) - { - (*__p)->__c_ = nullptr; - if (--__c->end_ != __p) - memmove(__p, __p+1, (__c->end_ - __p)*sizeof(__i_node*)); - } - } - __get_db()->unlock(); -#endif - __node_alloc_traits::destroy(__na, _VSTD::addressof(__n.__value_)); - __node_alloc_traits::deallocate(__na, _VSTD::addressof(__n), 1); -} - -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::erase(const_iterator __p) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::erase(iterator) called with an iterator not" - " referring to this list"); -#endif - __node_allocator& __na = base::__node_alloc(); - __node& __n = const_cast<__node&>(*__p.__ptr_); - __node_pointer __r = __n.__next_; - base::__unlink_nodes(__n, __n); - --base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __c_node* __c = __get_db()->__find_c_and_lock(this); - for (__i_node** __p = __c->end_; __p != __c->beg_; ) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == &__n) - { - (*__p)->__c_ = nullptr; - if (--__c->end_ != __p) - memmove(__p, __p+1, (__c->end_ - __p)*sizeof(__i_node*)); - } - } - __get_db()->unlock(); -#endif - __node_alloc_traits::destroy(__na, _VSTD::addressof(__n.__value_)); - __node_alloc_traits::deallocate(__na, _VSTD::addressof(__n), 1); -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(__r, this); -#else - return iterator(__r); -#endif -} - -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::erase(const_iterator __f, const_iterator __l) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__f) == this, - "list::erase(iterator, iterator) called with an iterator not" - " referring to this list"); -#endif - if (__f != __l) - { - __node_allocator& __na = base::__node_alloc(); - base::__unlink_nodes(const_cast<__node&>(*__f.__ptr_), *__l.__ptr_->__prev_); - while (__f != __l) - { - __node& __n = const_cast<__node&>(*__f.__ptr_); - ++__f; - --base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __c_node* __c = __get_db()->__find_c_and_lock(this); - for (__i_node** __p = __c->end_; __p != __c->beg_; ) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ == &__n) - { - (*__p)->__c_ = nullptr; - if (--__c->end_ != __p) - memmove(__p, __p+1, (__c->end_ - __p)*sizeof(__i_node*)); - } - } - __get_db()->unlock(); -#endif - __node_alloc_traits::destroy(__na, _VSTD::addressof(__n.__value_)); - __node_alloc_traits::deallocate(__na, _VSTD::addressof(__n), 1); - } - } -#if _LIBCPP_DEBUG_LEVEL >= 2 - return iterator(const_cast<__node_pointer>(__l.__ptr_), this); -#else - return iterator(const_cast<__node_pointer>(__l.__ptr_)); -#endif -} - -template -void -list<_Tp, _Alloc>::resize(size_type __n) -{ - if (__n < base::__sz()) - erase(__iterator(__n), end()); - else if (__n > base::__sz()) - { - __n -= base::__sz(); - size_type __ds = 0; - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_)); - ++__ds; -#if _LIBCPP_DEBUG_LEVEL >= 2 - iterator __r = iterator(__hold.release(), this); -#else - iterator __r = iterator(__hold.release()); -#endif - iterator __e = __r; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (--__n; __n != 0; --__n, ++__e, ++__ds) - { - __hold.reset(__node_alloc_traits::allocate(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_)); - __e.__ptr_->__next_ = __hold.get(); - __hold->__prev_ = __e.__ptr_; - __hold.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (true) - { - __node_alloc_traits::destroy(__na, _VSTD::addressof(*__e)); - __node_pointer __prev = __e.__ptr_->__prev_; - __node_alloc_traits::deallocate(__na, __e.__ptr_, 1); - if (__prev == 0) - break; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __e = iterator(__prev, this); -#else - __e = iterator(__prev); -#endif - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __link_nodes(static_cast<__node&>(base::__end_), *__r.__ptr_, *__e.__ptr_); - base::__sz() += __ds; - } -} - -template -void -list<_Tp, _Alloc>::resize(size_type __n, const value_type& __x) -{ - if (__n < base::__sz()) - erase(__iterator(__n), end()); - else if (__n > base::__sz()) - { - __n -= base::__sz(); - size_type __ds = 0; - __node_allocator& __na = base::__node_alloc(); - typedef __allocator_destructor<__node_allocator> _Dp; - unique_ptr<__node, _Dp> __hold(__node_alloc_traits::allocate(__na, 1), _Dp(__na, 1)); - __hold->__prev_ = 0; - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - ++__ds; -#if _LIBCPP_DEBUG_LEVEL >= 2 - iterator __r = iterator(__hold.release(), this); -#else - iterator __r = iterator(__hold.release()); -#endif - iterator __e = __r; -#ifndef _LIBCPP_NO_EXCEPTIONS - try - { -#endif // _LIBCPP_NO_EXCEPTIONS - for (--__n; __n != 0; --__n, ++__e, ++__ds) - { - __hold.reset(__node_alloc_traits::allocate(__na, 1)); - __node_alloc_traits::construct(__na, _VSTD::addressof(__hold->__value_), __x); - __e.__ptr_->__next_ = __hold.get(); - __hold->__prev_ = __e.__ptr_; - __hold.release(); - } -#ifndef _LIBCPP_NO_EXCEPTIONS - } - catch (...) - { - while (true) - { - __node_alloc_traits::destroy(__na, _VSTD::addressof(*__e)); - __node_pointer __prev = __e.__ptr_->__prev_; - __node_alloc_traits::deallocate(__na, __e.__ptr_, 1); - if (__prev == 0) - break; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __e = iterator(__prev, this); -#else - __e = iterator(__prev); -#endif - } - throw; - } -#endif // _LIBCPP_NO_EXCEPTIONS - __link_nodes(static_cast<__node&>(base::__end_), *__r.__ptr_, *__e.__ptr_); - base::__sz() += __ds; - } -} - -template -void -list<_Tp, _Alloc>::splice(const_iterator __p, list& __c) -{ - _LIBCPP_ASSERT(this != &__c, - "list::splice(iterator, list) called with this == &list"); -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::splice(iterator, list) called with an iterator not" - " referring to this list"); -#endif - if (!__c.empty()) - { - __node& __f = *__c.__end_.__next_; - __node& __l = *__c.__end_.__prev_; - base::__unlink_nodes(__f, __l); - __link_nodes(const_cast<__node&>(*__p.__ptr_), __f, __l); - base::__sz() += __c.__sz(); - __c.__sz() = 0; -#if _LIBCPP_DEBUG_LEVEL >= 2 - __libcpp_db* __db = __get_db(); - __c_node* __cn1 = __db->__find_c_and_lock(this); - __c_node* __cn2 = __db->__find_c(&__c); - for (__i_node** __p = __cn2->end_; __p != __cn2->beg_;) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ != static_cast<__node_pointer>(&__c.__end_)) - { - __cn1->__add(*__p); - (*__p)->__c_ = __cn1; - if (--__cn2->end_ != __p) - memmove(__p, __p+1, (__cn2->end_ - __p)*sizeof(__i_node*)); - } - } - __db->unlock(); -#endif - } -} - -template -void -list<_Tp, _Alloc>::splice(const_iterator __p, list& __c, const_iterator __i) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::splice(iterator, list, iterator) called with first iterator not" - " referring to this list"); - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__i) == &__c, - "list::splice(iterator, list, iterator) called with second iterator not" - " referring to list argument"); - _LIBCPP_ASSERT(__get_const_db()->__dereferenceable(&__i), - "list::splice(iterator, list, iterator) called with second iterator not" - " derefereceable"); -#endif - if (__p.__ptr_ != __i.__ptr_ && __p.__ptr_ != __i.__ptr_->__next_) - { - __node& __f = const_cast<__node&>(*__i.__ptr_); - base::__unlink_nodes(__f, __f); - __link_nodes(const_cast<__node&>(*__p.__ptr_), __f, __f); - --__c.__sz(); - ++base::__sz(); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __libcpp_db* __db = __get_db(); - __c_node* __cn1 = __db->__find_c_and_lock(this); - __c_node* __cn2 = __db->__find_c(&__c); - for (__i_node** __p = __cn2->end_; __p != __cn2->beg_;) - { - --__p; - iterator* __j = static_cast((*__p)->__i_); - if (__j->__ptr_ == &__f) - { - __cn1->__add(*__p); - (*__p)->__c_ = __cn1; - if (--__cn2->end_ != __p) - memmove(__p, __p+1, (__cn2->end_ - __p)*sizeof(__i_node*)); - } - } - __db->unlock(); -#endif - } -} - -template -void -list<_Tp, _Alloc>::splice(const_iterator __p, list& __c, const_iterator __f, const_iterator __l) -{ -#if _LIBCPP_DEBUG_LEVEL >= 2 - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__p) == this, - "list::splice(iterator, list, iterator, iterator) called with first iterator not" - " referring to this list"); - _LIBCPP_ASSERT(__get_const_db()->__find_c_from_i(&__f) == &__c, - "list::splice(iterator, list, iterator, iterator) called with second iterator not" - " referring to list argument"); - if (this == &__c) - { - for (const_iterator __i = __f; __i != __l; ++__i) - _LIBCPP_ASSERT(__i != __p, - "list::splice(iterator, list, iterator, iterator)" - " called with the first iterator within the range" - " of the second and third iterators"); - } -#endif - if (__f != __l) - { - if (this != &__c) - { - size_type __s = _VSTD::distance(__f, __l); - __c.__sz() -= __s; - base::__sz() += __s; - } - __node& __first = const_cast<__node&>(*__f.__ptr_); - --__l; - __node& __last = const_cast<__node&>(*__l.__ptr_); - base::__unlink_nodes(__first, __last); - __link_nodes(const_cast<__node&>(*__p.__ptr_), __first, __last); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __libcpp_db* __db = __get_db(); - __c_node* __cn1 = __db->__find_c_and_lock(this); - __c_node* __cn2 = __db->__find_c(&__c); - for (__i_node** __p = __cn2->end_; __p != __cn2->beg_;) - { - --__p; - iterator* __j = static_cast((*__p)->__i_); - for (__node_pointer __k = const_cast<__node_pointer>(__f.__ptr_); - __k != __l.__ptr_; __k = __k->__next_) - { - if (__j->__ptr_ == __k) - { - __cn1->__add(*__p); - (*__p)->__c_ = __cn1; - if (--__cn2->end_ != __p) - memmove(__p, __p+1, (__cn2->end_ - __p)*sizeof(__i_node*)); - } - } - } - __db->unlock(); -#endif - } -} - -template -void -list<_Tp, _Alloc>::remove(const value_type& __x) -{ - for (iterator __i = begin(), __e = end(); __i != __e;) - { - if (*__i == __x) - { - iterator __j = _VSTD::next(__i); - for (; __j != __e && *__j == __x; ++__j) - ; - __i = erase(__i, __j); - } - else - ++__i; - } -} - -template -template -void -list<_Tp, _Alloc>::remove_if(_Pred __pred) -{ - for (iterator __i = begin(), __e = end(); __i != __e;) - { - if (__pred(*__i)) - { - iterator __j = _VSTD::next(__i); - for (; __j != __e && __pred(*__j); ++__j) - ; - __i = erase(__i, __j); - } - else - ++__i; - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -list<_Tp, _Alloc>::unique() -{ - unique(__equal_to()); -} - -template -template -void -list<_Tp, _Alloc>::unique(_BinaryPred __binary_pred) -{ - for (iterator __i = begin(), __e = end(); __i != __e;) - { - iterator __j = _VSTD::next(__i); - for (; __j != __e && __binary_pred(*__i, *__j); ++__j) - ; - if (++__i != __j) - __i = erase(__i, __j); - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -list<_Tp, _Alloc>::merge(list& __c) -{ - merge(__c, __less()); -} - -template -template -void -list<_Tp, _Alloc>::merge(list& __c, _Comp __comp) -{ - if (this != &__c) - { - iterator __f1 = begin(); - iterator __e1 = end(); - iterator __f2 = __c.begin(); - iterator __e2 = __c.end(); - while (__f1 != __e1 && __f2 != __e2) - { - if (__comp(*__f2, *__f1)) - { - size_type __ds = 1; - iterator __m2 = _VSTD::next(__f2); - for (; __m2 != __e2 && __comp(*__m2, *__f1); ++__m2, ++__ds) - ; - base::__sz() += __ds; - __c.__sz() -= __ds; - __node& __f = *__f2.__ptr_; - __node& __l = *__m2.__ptr_->__prev_; - __f2 = __m2; - base::__unlink_nodes(__f, __l); - __m2 = _VSTD::next(__f1); - __link_nodes(*__f1.__ptr_, __f, __l); - __f1 = __m2; - } - else - ++__f1; - } - splice(__e1, __c); -#if _LIBCPP_DEBUG_LEVEL >= 2 - __libcpp_db* __db = __get_db(); - __c_node* __cn1 = __db->__find_c_and_lock(this); - __c_node* __cn2 = __db->__find_c(&__c); - for (__i_node** __p = __cn2->end_; __p != __cn2->beg_;) - { - --__p; - iterator* __i = static_cast((*__p)->__i_); - if (__i->__ptr_ != static_cast<__node_pointer>(&__c.__end_)) - { - __cn1->__add(*__p); - (*__p)->__c_ = __cn1; - if (--__cn2->end_ != __p) - memmove(__p, __p+1, (__cn2->end_ - __p)*sizeof(__i_node*)); - } - } - __db->unlock(); -#endif - } -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -list<_Tp, _Alloc>::sort() -{ - sort(__less()); -} - -template -template -inline _LIBCPP_INLINE_VISIBILITY -void -list<_Tp, _Alloc>::sort(_Comp __comp) -{ - __sort(begin(), end(), base::__sz(), __comp); -} - -template -template -typename list<_Tp, _Alloc>::iterator -list<_Tp, _Alloc>::__sort(iterator __f1, iterator __e2, size_type __n, _Comp& __comp) -{ - switch (__n) - { - case 0: - case 1: - return __f1; - case 2: - if (__comp(*--__e2, *__f1)) - { - __node& __f = *__e2.__ptr_; - base::__unlink_nodes(__f, __f); - __link_nodes(*__f1.__ptr_, __f, __f); - return __e2; - } - return __f1; - } - size_type __n2 = __n / 2; - iterator __e1 = _VSTD::next(__f1, __n2); - iterator __r = __f1 = __sort(__f1, __e1, __n2, __comp); - iterator __f2 = __e1 = __sort(__e1, __e2, __n - __n2, __comp); - if (__comp(*__f2, *__f1)) - { - iterator __m2 = _VSTD::next(__f2); - for (; __m2 != __e2 && __comp(*__m2, *__f1); ++__m2) - ; - __node& __f = *__f2.__ptr_; - __node& __l = *__m2.__ptr_->__prev_; - __r = __f2; - __e1 = __f2 = __m2; - base::__unlink_nodes(__f, __l); - __m2 = _VSTD::next(__f1); - __link_nodes(*__f1.__ptr_, __f, __l); - __f1 = __m2; - } - else - ++__f1; - while (__f1 != __e1 && __f2 != __e2) - { - if (__comp(*__f2, *__f1)) - { - iterator __m2 = _VSTD::next(__f2); - for (; __m2 != __e2 && __comp(*__m2, *__f1); ++__m2) - ; - __node& __f = *__f2.__ptr_; - __node& __l = *__m2.__ptr_->__prev_; - if (__e1 == __f2) - __e1 = __m2; - __f2 = __m2; - base::__unlink_nodes(__f, __l); - __m2 = _VSTD::next(__f1); - __link_nodes(*__f1.__ptr_, __f, __l); - __f1 = __m2; - } - else - ++__f1; - } - return __r; -} - -template -void -list<_Tp, _Alloc>::reverse() _NOEXCEPT -{ - if (base::__sz() > 1) - { - iterator __e = end(); - for (iterator __i = begin(); __i.__ptr_ != __e.__ptr_;) - { - _VSTD::swap(__i.__ptr_->__prev_, __i.__ptr_->__next_); - __i.__ptr_ = __i.__ptr_->__prev_; - } - _VSTD::swap(__e.__ptr_->__prev_, __e.__ptr_->__next_); - } -} - -template -bool -list<_Tp, _Alloc>::__invariants() const -{ - return size() == _VSTD::distance(begin(), end()); -} - -#if _LIBCPP_DEBUG_LEVEL >= 2 - -template -bool -list<_Tp, _Alloc>::__dereferenceable(const const_iterator* __i) const -{ - return __i->__ptr_ != &this->__end_; -} - -template -bool -list<_Tp, _Alloc>::__decrementable(const const_iterator* __i) const -{ - return !empty() && __i->__ptr_ != base::__end_.__next_; -} - -template -bool -list<_Tp, _Alloc>::__addable(const const_iterator* __i, ptrdiff_t __n) const -{ - return false; -} - -template -bool -list<_Tp, _Alloc>::__subscriptable(const const_iterator* __i, ptrdiff_t __n) const -{ - return false; -} - -#endif // _LIBCPP_DEBUG_LEVEL >= 2 - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return __x.size() == __y.size() && _VSTD::equal(__x.begin(), __x.end(), __y.begin()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator< (const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return _VSTD::lexicographical_compare(__x.begin(), __x.end(), __y.begin(), __y.end()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator> (const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(list<_Tp, _Alloc>& __x, list<_Tp, _Alloc>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_LIST diff --git a/libcxx/include/locale b/libcxx/include/locale deleted file mode 100644 index bec27f6d9eb2..000000000000 --- a/libcxx/include/locale +++ /dev/null @@ -1,4524 +0,0 @@ -// -*- C++ -*- -//===-------------------------- locale ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_LOCALE -#define _LIBCPP_LOCALE - -/* - locale synopsis - -namespace std -{ - -class locale -{ -public: - // types: - class facet; - class id; - - typedef int category; - static const category // values assigned here are for exposition only - none = 0x000, - collate = 0x010, - ctype = 0x020, - monetary = 0x040, - numeric = 0x080, - time = 0x100, - messages = 0x200, - all = collate | ctype | monetary | numeric | time | messages; - - // construct/copy/destroy: - locale() noexcept; - locale(const locale& other) noexcept; - explicit locale(const char* std_name); - explicit locale(const string& std_name); - locale(const locale& other, const char* std_name, category); - locale(const locale& other, const string& std_name, category); - template locale(const locale& other, Facet* f); - locale(const locale& other, const locale& one, category); - - ~locale(); // not virtual - - const locale& operator=(const locale& other) noexcept; - - template locale combine(const locale& other) const; - - // locale operations: - basic_string name() const; - bool operator==(const locale& other) const; - bool operator!=(const locale& other) const; - template - bool operator()(const basic_string& s1, - const basic_string& s2) const; - - // global locale objects: - static locale global(const locale&); - static const locale& classic(); -}; - -template const Facet& use_facet(const locale&); -template bool has_facet(const locale&) noexcept; - -// 22.3.3, convenience interfaces: -template bool isspace (charT c, const locale& loc); -template bool isprint (charT c, const locale& loc); -template bool iscntrl (charT c, const locale& loc); -template bool isupper (charT c, const locale& loc); -template bool islower (charT c, const locale& loc); -template bool isalpha (charT c, const locale& loc); -template bool isdigit (charT c, const locale& loc); -template bool ispunct (charT c, const locale& loc); -template bool isxdigit(charT c, const locale& loc); -template bool isalnum (charT c, const locale& loc); -template bool isgraph (charT c, const locale& loc); -template charT toupper(charT c, const locale& loc); -template charT tolower(charT c, const locale& loc); - -template, - class Byte_alloc = allocator> -class wstring_convert -{ -public: - typedef basic_string, Byte_alloc> byte_string; - typedef basic_string, Wide_alloc> wide_string; - typedef typename Codecvt::state_type state_type; - typedef typename wide_string::traits_type::int_type int_type; - - wstring_convert(Codecvt* pcvt = new Codecvt); - wstring_convert(Codecvt* pcvt, state_type state); - wstring_convert(const byte_string& byte_err, - const wide_string& wide_err = wide_string()); - ~wstring_convert(); - - wide_string from_bytes(char byte); - wide_string from_bytes(const char* ptr); - wide_string from_bytes(const byte_string& str); - wide_string from_bytes(const char* first, const char* last); - - byte_string to_bytes(Elem wchar); - byte_string to_bytes(const Elem* wptr); - byte_string to_bytes(const wide_string& wstr); - byte_string to_bytes(const Elem* first, const Elem* last); - - size_t converted() const; - state_type state() const; -}; - -template > -class wbuffer_convert - : public basic_streambuf -{ -public: - typedef typename Tr::state_type state_type; - - wbuffer_convert(streambuf* bytebuf = 0, Codecvt* pcvt = new Codecvt, - state_type state = state_type()); - - streambuf* rdbuf() const; - streambuf* rdbuf(streambuf* bytebuf); - - state_type state() const; -}; - -// 22.4.1 and 22.4.1.3, ctype: -class ctype_base; -template class ctype; -template <> class ctype; // specialization -template class ctype_byname; -template <> class ctype_byname; // specialization - -class codecvt_base; -template class codecvt; -template class codecvt_byname; - -// 22.4.2 and 22.4.3, numeric: -template class num_get; -template class num_put; -template class numpunct; -template class numpunct_byname; - -// 22.4.4, col lation: -template class collate; -template class collate_byname; - -// 22.4.5, date and time: -class time_base; -template class time_get; -template class time_get_byname; -template class time_put; -template class time_put_byname; - -// 22.4.6, money: -class money_base; -template class money_get; -template class money_put; -template class moneypunct; -template class moneypunct_byname; - -// 22.4.7, message retrieval: -class messages_base; -template class messages; -template class messages_byname; - -} // std - -*/ - -#include <__config> -#include <__locale> -#include -#include -#include -#include -#include -#include -#if !__APPLE__ -#include -#endif -#include -#include -#if _WIN32 -#include -#else // _WIN32 -#include -#endif // !_WIN32 - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -#if __APPLE__ || __FreeBSD__ -# define _LIBCPP_GET_C_LOCALE 0 -#else -# define _LIBCPP_GET_C_LOCALE __cloc() - // Get the C locale object - locale_t __cloc(); -#define __cloc_defined -#endif - -typedef _VSTD::remove_pointer::type __locale_struct; -typedef _VSTD::unique_ptr<__locale_struct, decltype(&freelocale)> __locale_unique_ptr; -#ifndef _LIBCPP_LOCALE__L_EXTENSIONS -typedef _VSTD::unique_ptr<__locale_struct, decltype(&uselocale)> __locale_raii; -#endif - -// OSX has nice foo_l() functions that let you turn off use of the global -// locale. Linux, not so much. The following functions avoid the locale when -// that's possible and otherwise do the wrong thing. FIXME. -#ifdef __linux__ - -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS -decltype(MB_CUR_MAX_L(_VSTD::declval())) -inline _LIBCPP_INLINE_VISIBILITY -__mb_cur_max_l(locale_t __l) -{ - return MB_CUR_MAX_L(__l); -} -#else // _LIBCPP_LOCALE__L_EXTENSIONS -_LIBCPP_ALWAYS_INLINE inline -decltype(MB_CUR_MAX) __mb_cur_max_l(locale_t __l) -{ - __locale_raii __current(uselocale(__l), uselocale); - return MB_CUR_MAX; -} -#endif // _LIBCPP_LOCALE__L_EXTENSIONS - -_LIBCPP_ALWAYS_INLINE inline -wint_t __btowc_l(int __c, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return btowc_l(__c, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return btowc(__c); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -int __wctob_l(wint_t __c, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return wctob_l(__c, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return wctob(__c); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __wcsnrtombs_l(char *__dest, const wchar_t **__src, size_t __nwc, - size_t __len, mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return wcsnrtombs_l(__dest, __src, __nwc, __len, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return wcsnrtombs(__dest, __src, __nwc, __len, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __wcrtomb_l(char *__s, wchar_t __wc, mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return wcrtomb_l(__s, __wc, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return wcrtomb(__s, __wc, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __mbsnrtowcs_l(wchar_t * __dest, const char **__src, size_t __nms, - size_t __len, mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return mbsnrtowcs_l(__dest, __src, __nms, __len, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return mbsnrtowcs(__dest, __src, __nms, __len, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __mbrtowc_l(wchar_t *__pwc, const char *__s, size_t __n, - mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return mbrtowc_l(__pwc, __s, __n, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return mbrtowc(__pwc, __s, __n, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -int __mbtowc_l(wchar_t *__pwc, const char *__pmb, size_t __max, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return mbtowc_l(__pwc, __pmb, __max, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return mbtowc(__pwc, __pmb, __max); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __mbrlen_l(const char *__s, size_t __n, mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return mbrlen_l(__s, __n, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return mbrlen(__s, __n, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -lconv *__localeconv_l(locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return localeconv_l(__l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return localeconv(); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -size_t __mbsrtowcs_l(wchar_t *__dest, const char **__src, size_t __len, - mbstate_t *__ps, locale_t __l) -{ -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - return mbsrtowcs_l(__dest, __src, __len, __ps, __l); -#else - __locale_raii __current(uselocale(__l), uselocale); - return mbsrtowcs(__dest, __src, __len, __ps); -#endif -} - -_LIBCPP_ALWAYS_INLINE inline -int __sprintf_l(char *__s, locale_t __l, const char *__format, ...) { - va_list __va; - va_start(__va, __format); -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __res = vsprintf_l(__s, __l, __format, __va); -#else - __locale_raii __current(uselocale(__l), uselocale); - int __res = vsprintf(__s, __format, __va); -#endif - va_end(__va); - return __res; -} - -_LIBCPP_ALWAYS_INLINE inline -int __snprintf_l(char *__s, size_t __n, locale_t __l, const char *__format, ...) { - va_list __va; - va_start(__va, __format); -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __res = vsnprintf_l(__s, __n, __l, __format, __va); -#else - __locale_raii __current(uselocale(__l), uselocale); - int __res = vsnprintf(__s, __n, __format, __va); -#endif - va_end(__va); - return __res; -} - -_LIBCPP_ALWAYS_INLINE inline -int __asprintf_l(char **__s, locale_t __l, const char *__format, ...) { - va_list __va; - va_start(__va, __format); -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __res = vasprintf_l(__s, __l, __format, __va); -#else - __locale_raii __current(uselocale(__l), uselocale); - int __res = vasprintf(__s, __format, __va); -#endif - va_end(__va); - return __res; -} - -_LIBCPP_ALWAYS_INLINE inline -int __sscanf_l(const char *__s, locale_t __l, const char *__format, ...) { - va_list __va; - va_start(__va, __format); -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __res = vsscanf_l(__s, __l, __format, __va); -#else - __locale_raii __current(uselocale(__l), uselocale); - int __res = vsscanf(__s, __format, __va); -#endif - va_end(__va); - return __res; -} - -#endif // __linux__ - -// __scan_keyword -// Scans [__b, __e) until a match is found in the basic_strings range -// [__kb, __ke) or until it can be shown that there is no match in [__kb, __ke). -// __b will be incremented (visibly), consuming CharT until a match is found -// or proved to not exist. A keyword may be "", in which will match anything. -// If one keyword is a prefix of another, and the next CharT in the input -// might match another keyword, the algorithm will attempt to find the longest -// matching keyword. If the longer matching keyword ends up not matching, then -// no keyword match is found. If no keyword match is found, __ke is returned -// and failbit is set in __err. -// Else an iterator pointing to the matching keyword is found. If more than -// one keyword matches, an iterator to the first matching keyword is returned. -// If on exit __b == __e, eofbit is set in __err. If __case_senstive is false, -// __ct is used to force to lower case before comparing characters. -// Examples: -// Keywords: "a", "abb" -// If the input is "a", the first keyword matches and eofbit is set. -// If the input is "abc", no match is found and "ab" are consumed. -template -_LIBCPP_HIDDEN -_ForwardIterator -__scan_keyword(_InputIterator& __b, _InputIterator __e, - _ForwardIterator __kb, _ForwardIterator __ke, - const _Ctype& __ct, ios_base::iostate& __err, - bool __case_sensitive = true) -{ - typedef typename iterator_traits<_InputIterator>::value_type _CharT; - size_t __nkw = static_cast(_VSTD::distance(__kb, __ke)); - const unsigned char __doesnt_match = '\0'; - const unsigned char __might_match = '\1'; - const unsigned char __does_match = '\2'; - unsigned char __statbuf[100]; - unsigned char* __status = __statbuf; - unique_ptr __stat_hold(0, free); - if (__nkw > sizeof(__statbuf)) - { - __status = (unsigned char*)malloc(__nkw); - if (__status == 0) - __throw_bad_alloc(); - __stat_hold.reset(__status); - } - size_t __n_might_match = __nkw; // At this point, any keyword might match - size_t __n_does_match = 0; // but none of them definitely do - // Initialize all statuses to __might_match, except for "" keywords are __does_match - unsigned char* __st = __status; - for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, ++__st) - { - if (!__ky->empty()) - *__st = __might_match; - else - { - *__st = __does_match; - --__n_might_match; - ++__n_does_match; - } - } - // While there might be a match, test keywords against the next CharT - for (size_t __indx = 0; __b != __e && __n_might_match > 0; ++__indx) - { - // Peek at the next CharT but don't consume it - _CharT __c = *__b; - if (!__case_sensitive) - __c = __ct.toupper(__c); - bool __consume = false; - // For each keyword which might match, see if the __indx character is __c - // If a match if found, consume __c - // If a match is found, and that is the last character in the keyword, - // then that keyword matches. - // If the keyword doesn't match this character, then change the keyword - // to doesn't match - __st = __status; - for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, ++__st) - { - if (*__st == __might_match) - { - _CharT __kc = (*__ky)[__indx]; - if (!__case_sensitive) - __kc = __ct.toupper(__kc); - if (__c == __kc) - { - __consume = true; - if (__ky->size() == __indx+1) - { - *__st = __does_match; - --__n_might_match; - ++__n_does_match; - } - } - else - { - *__st = __doesnt_match; - --__n_might_match; - } - } - } - // consume if we matched a character - if (__consume) - { - ++__b; - // If we consumed a character and there might be a matched keyword that - // was marked matched on a previous iteration, then such keywords - // which are now marked as not matching. - if (__n_might_match + __n_does_match > 1) - { - __st = __status; - for (_ForwardIterator __ky = __kb; __ky != __ke; ++__ky, ++__st) - { - if (*__st == __does_match && __ky->size() != __indx+1) - { - *__st = __doesnt_match; - --__n_does_match; - } - } - } - } - } - // We've exited the loop because we hit eof and/or we have no more "might matches". - if (__b == __e) - __err |= ios_base::eofbit; - // Return the first matching result - for (__st = __status; __kb != __ke; ++__kb, ++__st) - if (*__st == __does_match) - break; - if (__kb == __ke) - __err |= ios_base::failbit; - return __kb; -} - -struct __num_get_base -{ - static const int __num_get_buf_sz = 40; - - static int __get_base(ios_base&); - static const char __src[33]; -}; - -void __check_grouping(const string& __grouping, unsigned* __g, unsigned* __g_end, - ios_base::iostate& __err); - -template -struct __num_get - : protected __num_get_base -{ - static string __stage2_int_prep(ios_base& __iob, _CharT* __atoms, _CharT& __thousands_sep); - static string __stage2_float_prep(ios_base& __iob, _CharT* __atoms, _CharT& __decimal_point, - _CharT& __thousands_sep); - static int __stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end, - unsigned& __dc, _CharT __thousands_sep, const string& __grouping, - unsigned* __g, unsigned*& __g_end, _CharT* __atoms); - static int __stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp, - char* __a, char*& __a_end, - _CharT __decimal_point, _CharT __thousands_sep, - const string& __grouping, unsigned* __g, - unsigned*& __g_end, unsigned& __dc, _CharT* __atoms); -}; - -template -string -__num_get<_CharT>::__stage2_int_prep(ios_base& __iob, _CharT* __atoms, _CharT& __thousands_sep) -{ - locale __loc = __iob.getloc(); - use_facet >(__loc).widen(__src, __src + 26, __atoms); - const numpunct<_CharT>& __np = use_facet >(__loc); - __thousands_sep = __np.thousands_sep(); - return __np.grouping(); -} - -template -string -__num_get<_CharT>::__stage2_float_prep(ios_base& __iob, _CharT* __atoms, _CharT& __decimal_point, - _CharT& __thousands_sep) -{ - locale __loc = __iob.getloc(); - use_facet >(__loc).widen(__src, __src + 32, __atoms); - const numpunct<_CharT>& __np = use_facet >(__loc); - __decimal_point = __np.decimal_point(); - __thousands_sep = __np.thousands_sep(); - return __np.grouping(); -} - -template -int -__num_get<_CharT>::__stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end, - unsigned& __dc, _CharT __thousands_sep, const string& __grouping, - unsigned* __g, unsigned*& __g_end, _CharT* __atoms) -{ - if (__a_end == __a && (__ct == __atoms[24] || __ct == __atoms[25])) - { - *__a_end++ = __ct == __atoms[24] ? '+' : '-'; - __dc = 0; - return 0; - } - if (__grouping.size() != 0 && __ct == __thousands_sep) - { - if (__g_end-__g < __num_get_buf_sz) - { - *__g_end++ = __dc; - __dc = 0; - } - return 0; - } - ptrdiff_t __f = find(__atoms, __atoms + 26, __ct) - __atoms; - if (__f >= 24) - return -1; - switch (__base) - { - case 8: - case 10: - if (__f >= __base) - return -1; - break; - case 16: - if (__f < 22) - break; - if (__a_end != __a && __a_end - __a <= 2 && __a_end[-1] == '0') - { - __dc = 0; - *__a_end++ = __src[__f]; - return 0; - } - return -1; - } - if (__a_end-__a < __num_get_buf_sz - 1) - *__a_end++ = __src[__f]; - ++__dc; - return 0; -} - -template -int -__num_get<_CharT>::__stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp, char* __a, char*& __a_end, - _CharT __decimal_point, _CharT __thousands_sep, const string& __grouping, - unsigned* __g, unsigned*& __g_end, unsigned& __dc, _CharT* __atoms) -{ - if (__ct == __decimal_point) - { - if (!__in_units) - return -1; - __in_units = false; - *__a_end++ = '.'; - if (__grouping.size() != 0 && __g_end-__g < __num_get_buf_sz) - *__g_end++ = __dc; - return 0; - } - if (__ct == __thousands_sep && __grouping.size() != 0) - { - if (!__in_units) - return -1; - if (__g_end-__g < __num_get_buf_sz) - { - *__g_end++ = __dc; - __dc = 0; - } - return 0; - } - ptrdiff_t __f = find(__atoms, __atoms + 32, __ct) - __atoms; - if (__f >= 32) - return -1; - char __x = __src[__f]; - if (__x == '-' || __x == '+') - { - if (__a_end == __a || (__a_end[-1] & 0xDF) == __exp) - { - *__a_end++ = __x; - return 0; - } - return -1; - } - if (__a_end-__a < __num_get_buf_sz - 1) - *__a_end++ = __x; - if (__x == 'x' || __x == 'X') - __exp = 'P'; - else if ((__x & 0xDF) == __exp) - { - __in_units = false; - if (__grouping.size() != 0 && __g_end-__g < __num_get_buf_sz) - *__g_end++ = __dc; - } - if (__f >= 22) - return 0; - ++__dc; - return 0; -} - -extern template struct __num_get; -extern template struct __num_get; - -template > -class _LIBCPP_VISIBLE num_get - : public locale::facet, - private __num_get<_CharT> -{ -public: - typedef _CharT char_type; - typedef _InputIterator iter_type; - - _LIBCPP_ALWAYS_INLINE - explicit num_get(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, bool& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long long& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned short& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned int& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned long& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned long long& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, float& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, double& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long double& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, void*& __v) const - { - return do_get(__b, __e, __iob, __err, __v); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~num_get() {} - - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, bool& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long long& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned short& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned int& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned long& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, unsigned long long& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, float& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, double& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, long double& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, void*& __v) const; -}; - -template -locale::id -num_get<_CharT, _InputIterator>::id; - -template -_Tp -__num_get_signed_integral(const char* __a, const char* __a_end, - ios_base::iostate& __err, int __base) -{ - if (__a != __a_end) - { - int __save_errno = errno; - errno = 0; - char *__p2; - long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE); - int __current_errno = errno; - if (__current_errno == 0) - errno = __save_errno; - if (__p2 != __a_end) - { - __err = ios_base::failbit; - return 0; - } - else if (__current_errno == ERANGE || - __ll < numeric_limits<_Tp>::min() || - numeric_limits<_Tp>::max() < __ll) - { - __err = ios_base::failbit; - if (__ll > 0) - return numeric_limits<_Tp>::max(); - else - return numeric_limits<_Tp>::min(); - } - return static_cast<_Tp>(__ll); - } - __err = ios_base::failbit; - return 0; -} - -template -_Tp -__num_get_unsigned_integral(const char* __a, const char* __a_end, - ios_base::iostate& __err, int __base) -{ - if (__a != __a_end) - { - if (*__a == '-') - { - __err = ios_base::failbit; - return 0; - } - int __save_errno = errno; - errno = 0; - char *__p2; - unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE); - int __current_errno = errno; - if (__current_errno == 0) - errno = __save_errno; - if (__p2 != __a_end) - { - __err = ios_base::failbit; - return 0; - } - else if (__current_errno == ERANGE || - numeric_limits<_Tp>::max() < __ll) - { - __err = ios_base::failbit; - return numeric_limits<_Tp>::max(); - } - return static_cast<_Tp>(__ll); - } - __err = ios_base::failbit; - return 0; -} - -template -_Tp -__num_get_float(const char* __a, const char* __a_end, ios_base::iostate& __err) -{ - if (__a != __a_end) - { - char *__p2; - long double __ld = strtold_l(__a, &__p2, _LIBCPP_GET_C_LOCALE); - if (__p2 != __a_end) - { - __err = ios_base::failbit; - return 0; - } - return static_cast<_Tp>(__ld); - } - __err = ios_base::failbit; - return 0; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - bool& __v) const -{ - if ((__iob.flags() & ios_base::boolalpha) == 0) - { - long __lv = -1; - __b = do_get(__b, __e, __iob, __err, __lv); - switch (__lv) - { - case 0: - __v = false; - break; - case 1: - __v = true; - break; - default: - __v = true; - __err = ios_base::failbit; - break; - } - return __b; - } - const ctype<_CharT>& __ct = use_facet >(__iob.getloc()); - const numpunct<_CharT>& __np = use_facet >(__iob.getloc()); - typedef typename numpunct<_CharT>::string_type string_type; - const string_type __names[2] = {__np.truename(), __np.falsename()}; - const string_type* __i = __scan_keyword(__b, __e, __names, __names+2, - __ct, __err); - __v = __i == __names; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - long& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_signed_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - long long& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_signed_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - unsigned short& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_unsigned_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - unsigned int& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_unsigned_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - unsigned long& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_unsigned_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - unsigned long long& __v) const -{ - // Stage 1 - int __base = this->__get_base(__iob); - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep; - string __grouping = this->__stage2_int_prep(__iob, __atoms, __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, __g, __g_end, - __atoms)) - break; - if (__grouping.size() != 0 && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_unsigned_integral(__a, __a_end, __err, __base); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - float& __v) const -{ - // Stage 1, nothing to do - // Stage 2 - char_type __atoms[32]; - char_type __decimal_point; - char_type __thousands_sep; - string __grouping = this->__stage2_float_prep(__iob, __atoms, - __decimal_point, - __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - bool __in_units = true; - char __exp = 'E'; - for (; __b != __e; ++__b) - if (this->__stage2_float_loop(*__b, __in_units, __exp, __a, __a_end, - __decimal_point, __thousands_sep, - __grouping, __g, __g_end, - __dc, __atoms)) - break; - if (__grouping.size() != 0 && __in_units && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_float(__a, __a_end, __err); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - double& __v) const -{ - // Stage 1, nothing to do - // Stage 2 - char_type __atoms[32]; - char_type __decimal_point; - char_type __thousands_sep; - string __grouping = this->__stage2_float_prep(__iob, __atoms, - __decimal_point, - __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - bool __in_units = true; - char __exp = 'E'; - for (; __b != __e; ++__b) - if (this->__stage2_float_loop(*__b, __in_units, __exp, __a, __a_end, - __decimal_point, __thousands_sep, - __grouping, __g, __g_end, - __dc, __atoms)) - break; - if (__grouping.size() != 0 && __in_units && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_float(__a, __a_end, __err); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - long double& __v) const -{ - // Stage 1, nothing to do - // Stage 2 - char_type __atoms[32]; - char_type __decimal_point; - char_type __thousands_sep; - string __grouping = this->__stage2_float_prep(__iob, __atoms, - __decimal_point, - __thousands_sep); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - bool __in_units = true; - char __exp = 'E'; - for (; __b != __e; ++__b) - if (this->__stage2_float_loop(*__b, __in_units, __exp, __a, __a_end, - __decimal_point, __thousands_sep, - __grouping, __g, __g_end, - __dc, __atoms)) - break; - if (__grouping.size() != 0 && __in_units && __g_end-__g < __num_get_base::__num_get_buf_sz) - *__g_end++ = __dc; - // Stage 3 - __v = __num_get_float(__a, __a_end, __err); - // Digit grouping checked - __check_grouping(__grouping, __g, __g_end, __err); - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -num_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - void*& __v) const -{ - // Stage 1 - int __base = 16; - // Stage 2 - char_type __atoms[26]; - char_type __thousands_sep = 0; - string __grouping; - use_facet >(__iob.getloc()).widen(__num_get_base::__src, - __num_get_base::__src + 26, __atoms); - char __a[__num_get_base::__num_get_buf_sz] = {0}; - char* __a_end = __a; - unsigned __g[__num_get_base::__num_get_buf_sz]; - unsigned* __g_end = __g; - unsigned __dc = 0; - for (; __b != __e; ++__b) - if (this->__stage2_int_loop(*__b, __base, __a, __a_end, __dc, - __thousands_sep, __grouping, - __g, __g_end, __atoms)) - break; - // Stage 3 - __a[sizeof(__a)-1] = 0; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - if (sscanf_l(__a, _LIBCPP_GET_C_LOCALE, "%p", &__v) != 1) -#else - if (__sscanf_l(__a, __cloc(), "%p", &__v) != 1) -#endif - __err = ios_base::failbit; - // EOF checked - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -extern template class num_get; -extern template class num_get; - -struct __num_put_base -{ -protected: - static void __format_int(char* __fmt, const char* __len, bool __signd, - ios_base::fmtflags __flags); - static bool __format_float(char* __fmt, const char* __len, - ios_base::fmtflags __flags); - static char* __identify_padding(char* __nb, char* __ne, - const ios_base& __iob); -}; - -template -struct __num_put - : protected __num_put_base -{ - static void __widen_and_group_int(char* __nb, char* __np, char* __ne, - _CharT* __ob, _CharT*& __op, _CharT*& __oe, - const locale& __loc); - static void __widen_and_group_float(char* __nb, char* __np, char* __ne, - _CharT* __ob, _CharT*& __op, _CharT*& __oe, - const locale& __loc); -}; - -template -void -__num_put<_CharT>::__widen_and_group_int(char* __nb, char* __np, char* __ne, - _CharT* __ob, _CharT*& __op, _CharT*& __oe, - const locale& __loc) -{ - const ctype<_CharT>& __ct = use_facet > (__loc); - const numpunct<_CharT>& __npt = use_facet >(__loc); - string __grouping = __npt.grouping(); - if (__grouping.empty()) - { - __ct.widen(__nb, __ne, __ob); - __oe = __ob + (__ne - __nb); - } - else - { - __oe = __ob; - char* __nf = __nb; - if (*__nf == '-' || *__nf == '+') - *__oe++ = __ct.widen(*__nf++); - if (__ne - __nf >= 2 && __nf[0] == '0' && (__nf[1] == 'x' || - __nf[1] == 'X')) - { - *__oe++ = __ct.widen(*__nf++); - *__oe++ = __ct.widen(*__nf++); - } - reverse(__nf, __ne); - _CharT __thousands_sep = __npt.thousands_sep(); - unsigned __dc = 0; - unsigned __dg = 0; - for (char* __p = __nf; __p < __ne; ++__p) - { - if (static_cast(__grouping[__dg]) > 0 && - __dc == static_cast(__grouping[__dg])) - { - *__oe++ = __thousands_sep; - __dc = 0; - if (__dg < __grouping.size()-1) - ++__dg; - } - *__oe++ = __ct.widen(*__p); - ++__dc; - } - reverse(__ob + (__nf - __nb), __oe); - } - if (__np == __ne) - __op = __oe; - else - __op = __ob + (__np - __nb); -} - -template -void -__num_put<_CharT>::__widen_and_group_float(char* __nb, char* __np, char* __ne, - _CharT* __ob, _CharT*& __op, _CharT*& __oe, - const locale& __loc) -{ - const ctype<_CharT>& __ct = use_facet > (__loc); - const numpunct<_CharT>& __npt = use_facet >(__loc); - string __grouping = __npt.grouping(); - __oe = __ob; - char* __nf = __nb; - if (*__nf == '-' || *__nf == '+') - *__oe++ = __ct.widen(*__nf++); - char* __ns; - if (__ne - __nf >= 2 && __nf[0] == '0' && (__nf[1] == 'x' || - __nf[1] == 'X')) - { - *__oe++ = __ct.widen(*__nf++); - *__oe++ = __ct.widen(*__nf++); - for (__ns = __nf; __ns < __ne; ++__ns) - if (!isxdigit_l(*__ns, _LIBCPP_GET_C_LOCALE)) - break; - } - else - { - for (__ns = __nf; __ns < __ne; ++__ns) - if (!isdigit_l(*__ns, _LIBCPP_GET_C_LOCALE)) - break; - } - if (__grouping.empty()) - { - __ct.widen(__nf, __ns, __oe); - __oe += __ns - __nf; - } - else - { - reverse(__nf, __ns); - _CharT __thousands_sep = __npt.thousands_sep(); - unsigned __dc = 0; - unsigned __dg = 0; - for (char* __p = __nf; __p < __ns; ++__p) - { - if (__grouping[__dg] > 0 && __dc == static_cast(__grouping[__dg])) - { - *__oe++ = __thousands_sep; - __dc = 0; - if (__dg < __grouping.size()-1) - ++__dg; - } - *__oe++ = __ct.widen(*__p); - ++__dc; - } - reverse(__ob + (__nf - __nb), __oe); - } - for (__nf = __ns; __nf < __ne; ++__nf) - { - if (*__nf == '.') - { - *__oe++ = __npt.decimal_point(); - ++__nf; - break; - } - else - *__oe++ = __ct.widen(*__nf); - } - __ct.widen(__nf, __ne, __oe); - __oe += __ne - __nf; - if (__np == __ne) - __op = __oe; - else - __op = __ob + (__np - __nb); -} - -extern template struct __num_put; -extern template struct __num_put; - -template > -class _LIBCPP_VISIBLE num_put - : public locale::facet, - private __num_put<_CharT> -{ -public: - typedef _CharT char_type; - typedef _OutputIterator iter_type; - - _LIBCPP_ALWAYS_INLINE - explicit num_put(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - bool __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - long __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - long long __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - unsigned long __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - unsigned long long __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - double __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - long double __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - const void* __v) const - { - return do_put(__s, __iob, __fl, __v); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~num_put() {} - - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - bool __v) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - long __v) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - long long __v) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - unsigned long) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - unsigned long long) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - double __v) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - long double __v) const; - virtual iter_type do_put(iter_type __s, ios_base& __iob, char_type __fl, - const void* __v) const; -}; - -template -locale::id -num_put<_CharT, _OutputIterator>::id; - -template -_LIBCPP_HIDDEN -_OutputIterator -__pad_and_output(_OutputIterator __s, - const _CharT* __ob, const _CharT* __op, const _CharT* __oe, - ios_base& __iob, _CharT __fl) -{ - streamsize __sz = __oe - __ob; - streamsize __ns = __iob.width(); - if (__ns > __sz) - __ns -= __sz; - else - __ns = 0; - for (;__ob < __op; ++__ob, ++__s) - *__s = *__ob; - for (; __ns; --__ns, ++__s) - *__s = __fl; - for (; __ob < __oe; ++__ob, ++__s) - *__s = *__ob; - __iob.width(0); - return __s; -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, bool __v) const -{ - if ((__iob.flags() & ios_base::boolalpha) == 0) - return do_put(__s, __iob, __fl, (unsigned long)__v); - const numpunct& __np = use_facet >(__iob.getloc()); - typedef typename numpunct::string_type string_type; - string_type __nm = __v ? __np.truename() : __np.falsename(); - for (typename string_type::iterator __i = __nm.begin(); __i != __nm.end(); ++__i, ++__s) - *__s = *__i; - return __s; -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, long __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[6] = {'%', 0}; - const char* __len = "l"; - this->__format_int(__fmt+1, __len, true, __iob.flags()); - const unsigned __nbuf = (numeric_limits::digits / 3) - + ((numeric_limits::digits % 3) != 0) - + 1; - char __nar[__nbuf]; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __nc = sprintf_l(__nar, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - int __nc = __sprintf_l(__nar, __cloc(), __fmt, __v); -#endif - char* __ne = __nar + __nc; - char* __np = this->__identify_padding(__nar, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - return __pad_and_output(__s, __o, __op, __oe, __iob, __fl); -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, long long __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[8] = {'%', 0}; - const char* __len = "ll"; - this->__format_int(__fmt+1, __len, true, __iob.flags()); - const unsigned __nbuf = (numeric_limits::digits / 3) - + ((numeric_limits::digits % 3) != 0) - + 1; - char __nar[__nbuf]; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __nc = sprintf_l(__nar, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - int __nc = __sprintf_l(__nar, __cloc(), __fmt, __v); -#endif - char* __ne = __nar + __nc; - char* __np = this->__identify_padding(__nar, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - return __pad_and_output(__s, __o, __op, __oe, __iob, __fl); -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, unsigned long __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[6] = {'%', 0}; - const char* __len = "l"; - this->__format_int(__fmt+1, __len, false, __iob.flags()); - const unsigned __nbuf = (numeric_limits::digits / 3) - + ((numeric_limits::digits % 3) != 0) - + 1; - char __nar[__nbuf]; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __nc = sprintf_l(__nar, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - int __nc = __sprintf_l(__nar, __cloc(), __fmt, __v); -#endif - char* __ne = __nar + __nc; - char* __np = this->__identify_padding(__nar, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - return __pad_and_output(__s, __o, __op, __oe, __iob, __fl); -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, unsigned long long __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[8] = {'%', 0}; - const char* __len = "ll"; - this->__format_int(__fmt+1, __len, false, __iob.flags()); - const unsigned __nbuf = (numeric_limits::digits / 3) - + ((numeric_limits::digits % 3) != 0) - + 1; - char __nar[__nbuf]; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __nc = sprintf_l(__nar, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - int __nc = __sprintf_l(__nar, __cloc(), __fmt, __v); -#endif - char* __ne = __nar + __nc; - char* __np = this->__identify_padding(__nar, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_int(__nar, __np, __ne, __o, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - return __pad_and_output(__s, __o, __op, __oe, __iob, __fl); -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, double __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[8] = {'%', 0}; - const char* __len = ""; - bool __specify_precision = this->__format_float(__fmt+1, __len, __iob.flags()); - const unsigned __nbuf = 30; - char __nar[__nbuf]; - char* __nb = __nar; - int __nc; - if (__specify_precision) -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = snprintf_l(__nb, __nbuf, _LIBCPP_GET_C_LOCALE, __fmt, - (int)__iob.precision(), __v); -#else - __nc = __snprintf_l(__nb, __nbuf, __cloc(), __fmt, - (int)__iob.precision(), __v); -#endif - else -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = snprintf_l(__nb, __nbuf, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - __nc = __snprintf_l(__nb, __nbuf, __cloc(), __fmt, __v); -#endif - unique_ptr __nbh(0, free); - if (__nc > static_cast(__nbuf-1)) - { - if (__specify_precision) -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = asprintf_l(&__nb, _LIBCPP_GET_C_LOCALE, __fmt, (int)__iob.precision(), __v); -#else - __nc = __asprintf_l(&__nb, __cloc(), __fmt, - (int)__iob.precision(), __v); -#endif - else -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = asprintf_l(&__nb, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - __nc = __asprintf_l(&__nb, __cloc(), __fmt, (int)__iob.precision(), __v); -#endif - if (__nb == 0) - __throw_bad_alloc(); - __nbh.reset(__nb); - } - char* __ne = __nb + __nc; - char* __np = this->__identify_padding(__nb, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __ob = __o; - unique_ptr __obh(0, free); - if (__nb != __nar) - { - __ob = (char_type*)malloc(2*static_cast(__nc)*sizeof(char_type)); - if (__ob == 0) - __throw_bad_alloc(); - __obh.reset(__ob); - } - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_float(__nb, __np, __ne, __ob, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - __s = __pad_and_output(__s, __ob, __op, __oe, __iob, __fl); - return __s; -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, long double __v) const -{ - // Stage 1 - Get number in narrow char - char __fmt[8] = {'%', 0}; - const char* __len = "L"; - bool __specify_precision = this->__format_float(__fmt+1, __len, __iob.flags()); - const unsigned __nbuf = 30; - char __nar[__nbuf]; - char* __nb = __nar; - int __nc; - if (__specify_precision) -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = snprintf_l(__nb, __nbuf, _LIBCPP_GET_C_LOCALE, __fmt, - (int)__iob.precision(), __v); -#else - __nc = __snprintf_l(__nb, __nbuf, __cloc(), __fmt, - (int)__iob.precision(), __v); -#endif - else -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = snprintf_l(__nb, __nbuf, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - __nc = __snprintf_l(__nb, __nbuf, __cloc(), __fmt, __v); -#endif - unique_ptr __nbh(0, free); - if (__nc > static_cast(__nbuf-1)) - { - if (__specify_precision) -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = asprintf_l(&__nb, _LIBCPP_GET_C_LOCALE, __fmt, (int)__iob.precision(), __v); -#else - __nc = __asprintf_l(&__nb, __cloc(), __fmt, - (int)__iob.precision(), __v); -#endif - else -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __nc = asprintf_l(&__nb, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - __nc = __asprintf_l(&__nb, __cloc(), __fmt, __v); -#endif - if (__nb == 0) - __throw_bad_alloc(); - __nbh.reset(__nb); - } - char* __ne = __nb + __nc; - char* __np = this->__identify_padding(__nb, __ne, __iob); - // Stage 2 - Widen __nar while adding thousands separators - char_type __o[2*(__nbuf-1) - 1]; - char_type* __ob = __o; - unique_ptr __obh(0, free); - if (__nb != __nar) - { - __ob = (char_type*)malloc(2*static_cast(__nc)*sizeof(char_type)); - if (__ob == 0) - __throw_bad_alloc(); - __obh.reset(__ob); - } - char_type* __op; // pad here - char_type* __oe; // end of output - this->__widen_and_group_float(__nb, __np, __ne, __ob, __op, __oe, __iob.getloc()); - // [__o, __oe) contains thousands_sep'd wide number - // Stage 3 & 4 - __s = __pad_and_output(__s, __ob, __op, __oe, __iob, __fl); - return __s; -} - -template -_OutputIterator -num_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base& __iob, - char_type __fl, const void* __v) const -{ - // Stage 1 - Get pointer in narrow char - char __fmt[6] = "%p"; - const unsigned __nbuf = 20; - char __nar[__nbuf]; -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - int __nc = sprintf_l(__nar, _LIBCPP_GET_C_LOCALE, __fmt, __v); -#else - int __nc = __sprintf_l(__nar, __cloc(), __fmt, __v); -#endif - char* __ne = __nar + __nc; - char* __np = this->__identify_padding(__nar, __ne, __iob); - // Stage 2 - Widen __nar - char_type __o[2*(__nbuf-1) - 1]; - char_type* __op; // pad here - char_type* __oe; // end of output - const ctype& __ct = use_facet >(__iob.getloc()); - __ct.widen(__nar, __ne, __o); - __oe = __o + (__ne - __nar); - if (__np == __ne) - __op = __oe; - else - __op = __o + (__np - __nar); - // [__o, __oe) contains wide number - // Stage 3 & 4 - return __pad_and_output(__s, __o, __op, __oe, __iob, __fl); -} - -extern template class num_put; -extern template class num_put; - -template -_LIBCPP_HIDDEN -int -__get_up_to_n_digits(_InputIterator& __b, _InputIterator __e, - ios_base::iostate& __err, const ctype<_CharT>& __ct, int __n) -{ - // Precondition: __n >= 1 - if (__b == __e) - { - __err |= ios_base::eofbit | ios_base::failbit; - return 0; - } - // get first digit - _CharT __c = *__b; - if (!__ct.is(ctype_base::digit, __c)) - { - __err |= ios_base::failbit; - return 0; - } - int __r = __ct.narrow(__c, 0) - '0'; - for (++__b, --__n; __b != __e && __n > 0; ++__b, --__n) - { - // get next digit - __c = *__b; - if (!__ct.is(ctype_base::digit, __c)) - return __r; - __r = __r * 10 + __ct.narrow(__c, 0) - '0'; - } - if (__b == __e) - __err |= ios_base::eofbit; - return __r; -} - -class _LIBCPP_VISIBLE time_base -{ -public: - enum dateorder {no_order, dmy, mdy, ymd, ydm}; -}; - -template -class __time_get_c_storage // purposefully not decorated -{ -protected: - typedef basic_string<_CharT> string_type; - - virtual const string_type* __weeks() const; - virtual const string_type* __months() const; - virtual const string_type* __am_pm() const; - virtual const string_type& __c() const; - virtual const string_type& __r() const; - virtual const string_type& __x() const; - virtual const string_type& __X() const; -}; - -template > -class _LIBCPP_VISIBLE time_get - : public locale::facet, - public time_base, - private __time_get_c_storage<_CharT> -{ -public: - typedef _CharT char_type; - typedef _InputIterator iter_type; - typedef time_base::dateorder dateorder; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE - explicit time_get(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - dateorder date_order() const - { - return this->do_date_order(); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get_time(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const - { - return do_get_time(__b, __e, __iob, __err, __tm); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get_date(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const - { - return do_get_date(__b, __e, __iob, __err, __tm); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get_weekday(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const - { - return do_get_weekday(__b, __e, __iob, __err, __tm); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get_monthname(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const - { - return do_get_monthname(__b, __e, __iob, __err, __tm); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get_year(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const - { - return do_get_year(__b, __e, __iob, __err, __tm); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm *__tm, - char __fmt, char __mod = 0) const - { - return do_get(__b, __e, __iob, __err, __tm, __fmt, __mod); - } - - iter_type get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm, - const char_type* __fmtb, const char_type* __fmte) const; - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~time_get() {} - - virtual dateorder do_date_order() const; - virtual iter_type do_get_time(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const; - virtual iter_type do_get_date(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const; - virtual iter_type do_get_weekday(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const; - virtual iter_type do_get_monthname(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const; - virtual iter_type do_get_year(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm) const; - virtual iter_type do_get(iter_type __b, iter_type __e, ios_base& __iob, - ios_base::iostate& __err, tm* __tm, - char __fmt, char __mod) const; -private: - void __get_white_space(iter_type& __b, iter_type __e, - ios_base::iostate& __err, const ctype& __ct) const; - void __get_percent(iter_type& __b, iter_type __e, ios_base::iostate& __err, - const ctype& __ct) const; - - void __get_weekdayname(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_monthname(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_day(int& __d, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_month(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_year(int& __y, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_year4(int& __y, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_hour(int& __d, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_12_hour(int& __h, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_am_pm(int& __h, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_minute(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_second(int& __s, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_weekday(int& __w, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; - void __get_day_year_num(int& __w, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const; -}; - -template -locale::id -time_get<_CharT, _InputIterator>::id; - -// time_get primatives - -template -void -time_get<_CharT, _InputIterator>::__get_weekdayname(int& __w, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - // Note: ignoring case comes from the POSIX strptime spec - const string_type* __wk = this->__weeks(); - ptrdiff_t __i = __scan_keyword(__b, __e, __wk, __wk+14, __ct, __err, false) - __wk; - if (__i < 14) - __w = __i % 7; -} - -template -void -time_get<_CharT, _InputIterator>::__get_monthname(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - // Note: ignoring case comes from the POSIX strptime spec - const string_type* __month = this->__months(); - ptrdiff_t __i = __scan_keyword(__b, __e, __month, __month+24, __ct, __err, false) - __month; - if (__i < 24) - __m = __i % 12; -} - -template -void -time_get<_CharT, _InputIterator>::__get_day(int& __d, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2); - if (!(__err & ios_base::failbit) && 1 <= __t && __t <= 31) - __d = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_month(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2) - 1; - if (!(__err & ios_base::failbit) && __t <= 11) - __m = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_year(int& __y, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 4); - if (!(__err & ios_base::failbit)) - { - if (__t < 69) - __t += 2000; - else if (69 <= __t && __t <= 99) - __t += 1900; - __y = __t - 1900; - } -} - -template -void -time_get<_CharT, _InputIterator>::__get_year4(int& __y, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 4); - if (!(__err & ios_base::failbit)) - __y = __t - 1900; -} - -template -void -time_get<_CharT, _InputIterator>::__get_hour(int& __h, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2); - if (!(__err & ios_base::failbit) && __t <= 23) - __h = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_12_hour(int& __h, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2); - if (!(__err & ios_base::failbit) && 1 <= __t && __t <= 12) - __h = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_minute(int& __m, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2); - if (!(__err & ios_base::failbit) && __t <= 59) - __m = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_second(int& __s, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 2); - if (!(__err & ios_base::failbit) && __t <= 60) - __s = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_weekday(int& __w, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 1); - if (!(__err & ios_base::failbit) && __t <= 6) - __w = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_day_year_num(int& __d, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - int __t = __get_up_to_n_digits(__b, __e, __err, __ct, 3); - if (!(__err & ios_base::failbit) && __t <= 365) - __d = __t; - else - __err |= ios_base::failbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_white_space(iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - for (; __b != __e && __ct.is(ctype_base::space, *__b); ++__b) - ; - if (__b == __e) - __err |= ios_base::eofbit; -} - -template -void -time_get<_CharT, _InputIterator>::__get_am_pm(int& __h, - iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - const string_type* __ap = this->__am_pm(); - if (__ap[0].size() + __ap[1].size() == 0) - { - __err |= ios_base::failbit; - return; - } - ptrdiff_t __i = __scan_keyword(__b, __e, __ap, __ap+2, __ct, __err, false) - __ap; - if (__i == 0 && __h == 12) - __h = 0; - else if (__i == 1 && __h < 12) - __h += 12; -} - -template -void -time_get<_CharT, _InputIterator>::__get_percent(iter_type& __b, iter_type __e, - ios_base::iostate& __err, - const ctype& __ct) const -{ - if (__b == __e) - { - __err |= ios_base::eofbit | ios_base::failbit; - return; - } - if (__ct.narrow(*__b, 0) != '%') - __err |= ios_base::failbit; - else if(++__b == __e) - __err |= ios_base::eofbit; -} - -// time_get end primatives - -template -_InputIterator -time_get<_CharT, _InputIterator>::get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, tm* __tm, - const char_type* __fmtb, const char_type* __fmte) const -{ - const ctype& __ct = use_facet >(__iob.getloc()); - __err = ios_base::goodbit; - while (__fmtb != __fmte && __err == ios_base::goodbit) - { - if (__b == __e) - { - __err = ios_base::failbit; - break; - } - if (__ct.narrow(*__fmtb, 0) == '%') - { - if (++__fmtb == __fmte) - { - __err = ios_base::failbit; - break; - } - char __cmd = __ct.narrow(*__fmtb, 0); - char __opt = '\0'; - if (__cmd == 'E' || __cmd == '0') - { - if (++__fmtb == __fmte) - { - __err = ios_base::failbit; - break; - } - __opt = __cmd; - __cmd = __ct.narrow(*__fmtb, 0); - } - __b = do_get(__b, __e, __iob, __err, __tm, __cmd, __opt); - ++__fmtb; - } - else if (__ct.is(ctype_base::space, *__fmtb)) - { - for (++__fmtb; __fmtb != __fmte && __ct.is(ctype_base::space, *__fmtb); ++__fmtb) - ; - for ( ; __b != __e && __ct.is(ctype_base::space, *__b); ++__b) - ; - } - else if (__ct.toupper(*__b) == __ct.toupper(*__fmtb)) - { - ++__b; - ++__fmtb; - } - else - __err = ios_base::failbit; - } - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -typename time_get<_CharT, _InputIterator>::dateorder -time_get<_CharT, _InputIterator>::do_date_order() const -{ - return mdy; -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get_time(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - tm* __tm) const -{ - const char_type __fmt[] = {'%', 'H', ':', '%', 'M', ':', '%', 'S'}; - return get(__b, __e, __iob, __err, __tm, __fmt, __fmt + sizeof(__fmt)/sizeof(__fmt[0])); -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get_date(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - tm* __tm) const -{ - const string_type& __fmt = this->__x(); - return get(__b, __e, __iob, __err, __tm, __fmt.data(), __fmt.data() + __fmt.size()); -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get_weekday(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - tm* __tm) const -{ - const ctype& __ct = use_facet >(__iob.getloc()); - __get_weekdayname(__tm->tm_wday, __b, __e, __err, __ct); - return __b; -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get_monthname(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - tm* __tm) const -{ - const ctype& __ct = use_facet >(__iob.getloc()); - __get_monthname(__tm->tm_mon, __b, __e, __err, __ct); - return __b; -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get_year(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, - tm* __tm) const -{ - const ctype& __ct = use_facet >(__iob.getloc()); - __get_year(__tm->tm_year, __b, __e, __err, __ct); - return __b; -} - -template -_InputIterator -time_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - ios_base& __iob, - ios_base::iostate& __err, tm* __tm, - char __fmt, char) const -{ - __err = ios_base::goodbit; - const ctype& __ct = use_facet >(__iob.getloc()); - switch (__fmt) - { - case 'a': - case 'A': - __get_weekdayname(__tm->tm_wday, __b, __e, __err, __ct); - break; - case 'b': - case 'B': - case 'h': - __get_monthname(__tm->tm_mon, __b, __e, __err, __ct); - break; - case 'c': - { - const string_type& __fm = this->__c(); - __b = get(__b, __e, __iob, __err, __tm, __fm.data(), __fm.data() + __fm.size()); - } - break; - case 'd': - case 'e': - __get_day(__tm->tm_mday, __b, __e, __err, __ct); - break; - case 'D': - { - const char_type __fm[] = {'%', 'm', '/', '%', 'd', '/', '%', 'y'}; - __b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0])); - } - break; - case 'F': - { - const char_type __fm[] = {'%', 'Y', '-', '%', 'm', '-', '%', 'd'}; - __b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0])); - } - break; - case 'H': - __get_hour(__tm->tm_hour, __b, __e, __err, __ct); - break; - case 'I': - __get_12_hour(__tm->tm_hour, __b, __e, __err, __ct); - break; - case 'j': - __get_day_year_num(__tm->tm_yday, __b, __e, __err, __ct); - break; - case 'm': - __get_month(__tm->tm_mon, __b, __e, __err, __ct); - break; - case 'M': - __get_minute(__tm->tm_min, __b, __e, __err, __ct); - break; - case 'n': - case 't': - __get_white_space(__b, __e, __err, __ct); - break; - case 'p': - __get_am_pm(__tm->tm_hour, __b, __e, __err, __ct); - break; - case 'r': - { - const char_type __fm[] = {'%', 'I', ':', '%', 'M', ':', '%', 'S', ' ', '%', 'p'}; - __b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0])); - } - break; - case 'R': - { - const char_type __fm[] = {'%', 'H', ':', '%', 'M'}; - __b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0])); - } - break; - case 'S': - __get_second(__tm->tm_sec, __b, __e, __err, __ct); - break; - case 'T': - { - const char_type __fm[] = {'%', 'H', ':', '%', 'M', ':', '%', 'S'}; - __b = get(__b, __e, __iob, __err, __tm, __fm, __fm + sizeof(__fm)/sizeof(__fm[0])); - } - break; - case 'w': - __get_weekday(__tm->tm_wday, __b, __e, __err, __ct); - break; - case 'x': - return do_get_date(__b, __e, __iob, __err, __tm); - case 'X': - { - const string_type& __fm = this->__X(); - __b = get(__b, __e, __iob, __err, __tm, __fm.data(), __fm.data() + __fm.size()); - } - break; - case 'y': - __get_year(__tm->tm_year, __b, __e, __err, __ct); - break; - case 'Y': - __get_year4(__tm->tm_year, __b, __e, __err, __ct); - break; - case '%': - __get_percent(__b, __e, __err, __ct); - break; - default: - __err |= ios_base::failbit; - } - return __b; -} - -extern template class time_get; -extern template class time_get; - -class __time_get -{ -protected: - locale_t __loc_; - - __time_get(const char* __nm); - __time_get(const string& __nm); - ~__time_get(); -}; - -template -class __time_get_storage - : public __time_get -{ -protected: - typedef basic_string<_CharT> string_type; - - string_type __weeks_[14]; - string_type __months_[24]; - string_type __am_pm_[2]; - string_type __c_; - string_type __r_; - string_type __x_; - string_type __X_; - - explicit __time_get_storage(const char* __nm); - explicit __time_get_storage(const string& __nm); - - _LIBCPP_ALWAYS_INLINE ~__time_get_storage() {} - - time_base::dateorder __do_date_order() const; - -private: - void init(const ctype<_CharT>&); - string_type __analyze(char __fmt, const ctype<_CharT>&); -}; - -template > -class _LIBCPP_VISIBLE time_get_byname - : public time_get<_CharT, _InputIterator>, - private __time_get_storage<_CharT> -{ -public: - typedef time_base::dateorder dateorder; - typedef _InputIterator iter_type; - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_INLINE_VISIBILITY - explicit time_get_byname(const char* __nm, size_t __refs = 0) - : time_get<_CharT, _InputIterator>(__refs), - __time_get_storage<_CharT>(__nm) {} - _LIBCPP_INLINE_VISIBILITY - explicit time_get_byname(const string& __nm, size_t __refs = 0) - : time_get<_CharT, _InputIterator>(__refs), - __time_get_storage<_CharT>(__nm) {} - -protected: - _LIBCPP_INLINE_VISIBILITY - ~time_get_byname() {} - - _LIBCPP_INLINE_VISIBILITY - virtual dateorder do_date_order() const {return this->__do_date_order();} -private: - _LIBCPP_INLINE_VISIBILITY - virtual const string_type* __weeks() const {return this->__weeks_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type* __months() const {return this->__months_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type* __am_pm() const {return this->__am_pm_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type& __c() const {return this->__c_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type& __r() const {return this->__r_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type& __x() const {return this->__x_;} - _LIBCPP_INLINE_VISIBILITY - virtual const string_type& __X() const {return this->__X_;} -}; - -extern template class time_get_byname; -extern template class time_get_byname; - -class __time_put -{ - locale_t __loc_; -protected: - _LIBCPP_ALWAYS_INLINE __time_put() : __loc_(_LIBCPP_GET_C_LOCALE) {} - __time_put(const char* __nm); - __time_put(const string& __nm); - ~__time_put(); - void __do_put(char* __nb, char*& __ne, const tm* __tm, - char __fmt, char __mod) const; - void __do_put(wchar_t* __wb, wchar_t*& __we, const tm* __tm, - char __fmt, char __mod) const; -}; - -template > -class _LIBCPP_VISIBLE time_put - : public locale::facet, - private __time_put -{ -public: - typedef _CharT char_type; - typedef _OutputIterator iter_type; - - _LIBCPP_ALWAYS_INLINE - explicit time_put(size_t __refs = 0) - : locale::facet(__refs) {} - - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, const tm* __tm, - const char_type* __pb, const char_type* __pe) const; - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, ios_base& __iob, char_type __fl, - const tm* __tm, char __fmt, char __mod = 0) const - { - return do_put(__s, __iob, __fl, __tm, __fmt, __mod); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~time_put() {} - virtual iter_type do_put(iter_type __s, ios_base&, char_type, const tm* __tm, - char __fmt, char __mod) const; - - _LIBCPP_ALWAYS_INLINE - explicit time_put(const char* __nm, size_t __refs) - : locale::facet(__refs), - __time_put(__nm) {} - _LIBCPP_ALWAYS_INLINE - explicit time_put(const string& __nm, size_t __refs) - : locale::facet(__refs), - __time_put(__nm) {} -}; - -template -locale::id -time_put<_CharT, _OutputIterator>::id; - -template -_OutputIterator -time_put<_CharT, _OutputIterator>::put(iter_type __s, ios_base& __iob, - char_type __fl, const tm* __tm, - const char_type* __pb, - const char_type* __pe) const -{ - const ctype& __ct = use_facet >(__iob.getloc()); - for (; __pb != __pe; ++__pb) - { - if (__ct.narrow(*__pb, 0) == '%') - { - if (++__pb == __pe) - { - *__s++ = __pb[-1]; - break; - } - char __mod = 0; - char __fmt = __ct.narrow(*__pb, 0); - if (__fmt == 'E' || __fmt == 'O') - { - if (++__pb == __pe) - { - *__s++ = __pb[-2]; - *__s++ = __pb[-1]; - break; - } - __mod = __fmt; - __fmt = __ct.narrow(*__pb, 0); - } - __s = do_put(__s, __iob, __fl, __tm, __fmt, __mod); - } - else - *__s++ = *__pb; - } - return __s; -} - -template -_OutputIterator -time_put<_CharT, _OutputIterator>::do_put(iter_type __s, ios_base&, - char_type, const tm* __tm, - char __fmt, char __mod) const -{ - char_type __nar[100]; - char_type* __nb = __nar; - char_type* __ne = __nb + 100; - __do_put(__nb, __ne, __tm, __fmt, __mod); - return _VSTD::copy(__nb, __ne, __s); -} - -extern template class time_put; -extern template class time_put; - -template > -class _LIBCPP_VISIBLE time_put_byname - : public time_put<_CharT, _OutputIterator> -{ -public: - _LIBCPP_ALWAYS_INLINE - explicit time_put_byname(const char* __nm, size_t __refs = 0) - : time_put<_CharT, _OutputIterator>(__nm, __refs) {} - - _LIBCPP_ALWAYS_INLINE - explicit time_put_byname(const string& __nm, size_t __refs = 0) - : time_put<_CharT, _OutputIterator>(__nm, __refs) {} - -protected: - _LIBCPP_ALWAYS_INLINE - ~time_put_byname() {} -}; - -extern template class time_put_byname; -extern template class time_put_byname; - -// money_base - -class _LIBCPP_VISIBLE money_base -{ -public: - enum part {none, space, symbol, sign, value}; - struct pattern {char field[4];}; - - _LIBCPP_ALWAYS_INLINE money_base() {} -}; - -// moneypunct - -template -class _LIBCPP_VISIBLE moneypunct - : public locale::facet, - public money_base -{ -public: - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE - explicit moneypunct(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE char_type decimal_point() const {return do_decimal_point();} - _LIBCPP_ALWAYS_INLINE char_type thousands_sep() const {return do_thousands_sep();} - _LIBCPP_ALWAYS_INLINE string grouping() const {return do_grouping();} - _LIBCPP_ALWAYS_INLINE string_type curr_symbol() const {return do_curr_symbol();} - _LIBCPP_ALWAYS_INLINE string_type positive_sign() const {return do_positive_sign();} - _LIBCPP_ALWAYS_INLINE string_type negative_sign() const {return do_negative_sign();} - _LIBCPP_ALWAYS_INLINE int frac_digits() const {return do_frac_digits();} - _LIBCPP_ALWAYS_INLINE pattern pos_format() const {return do_pos_format();} - _LIBCPP_ALWAYS_INLINE pattern neg_format() const {return do_neg_format();} - - static locale::id id; - static const bool intl = _International; - -protected: - _LIBCPP_ALWAYS_INLINE - ~moneypunct() {} - - virtual char_type do_decimal_point() const {return numeric_limits::max();} - virtual char_type do_thousands_sep() const {return numeric_limits::max();} - virtual string do_grouping() const {return string();} - virtual string_type do_curr_symbol() const {return string_type();} - virtual string_type do_positive_sign() const {return string_type();} - virtual string_type do_negative_sign() const {return string_type(1, '-');} - virtual int do_frac_digits() const {return 0;} - virtual pattern do_pos_format() const - {pattern __p = {symbol, sign, none, value}; return __p;} - virtual pattern do_neg_format() const - {pattern __p = {symbol, sign, none, value}; return __p;} -}; - -template -locale::id -moneypunct<_CharT, _International>::id; - -extern template class moneypunct; -extern template class moneypunct; -extern template class moneypunct; -extern template class moneypunct; - -// moneypunct_byname - -template -class _LIBCPP_VISIBLE moneypunct_byname - : public moneypunct<_CharT, _International> -{ -public: - typedef money_base::pattern pattern; - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE - explicit moneypunct_byname(const char* __nm, size_t __refs = 0) - : moneypunct<_CharT, _International>(__refs) {init(__nm);} - - _LIBCPP_ALWAYS_INLINE - explicit moneypunct_byname(const string& __nm, size_t __refs = 0) - : moneypunct<_CharT, _International>(__refs) {init(__nm.c_str());} - -protected: - _LIBCPP_ALWAYS_INLINE - ~moneypunct_byname() {} - - virtual char_type do_decimal_point() const {return __decimal_point_;} - virtual char_type do_thousands_sep() const {return __thousands_sep_;} - virtual string do_grouping() const {return __grouping_;} - virtual string_type do_curr_symbol() const {return __curr_symbol_;} - virtual string_type do_positive_sign() const {return __positive_sign_;} - virtual string_type do_negative_sign() const {return __negative_sign_;} - virtual int do_frac_digits() const {return __frac_digits_;} - virtual pattern do_pos_format() const {return __pos_format_;} - virtual pattern do_neg_format() const {return __neg_format_;} - -private: - char_type __decimal_point_; - char_type __thousands_sep_; - string __grouping_; - string_type __curr_symbol_; - string_type __positive_sign_; - string_type __negative_sign_; - int __frac_digits_; - pattern __pos_format_; - pattern __neg_format_; - - void init(const char*); -}; - -template<> void moneypunct_byname::init(const char*); -template<> void moneypunct_byname::init(const char*); -template<> void moneypunct_byname::init(const char*); -template<> void moneypunct_byname::init(const char*); - -extern template class moneypunct_byname; -extern template class moneypunct_byname; -extern template class moneypunct_byname; -extern template class moneypunct_byname; - -// money_get - -template -class __money_get -{ -protected: - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE __money_get() {} - - static void __gather_info(bool __intl, const locale& __loc, - money_base::pattern& __pat, char_type& __dp, - char_type& __ts, string& __grp, - string_type& __sym, string_type& __psn, - string_type& __nsn, int& __fd); -}; - -template -void -__money_get<_CharT>::__gather_info(bool __intl, const locale& __loc, - money_base::pattern& __pat, char_type& __dp, - char_type& __ts, string& __grp, - string_type& __sym, string_type& __psn, - string_type& __nsn, int& __fd) -{ - if (__intl) - { - const moneypunct& __mp = - use_facet >(__loc); - __pat = __mp.neg_format(); - __nsn = __mp.negative_sign(); - __psn = __mp.positive_sign(); - __dp = __mp.decimal_point(); - __ts = __mp.thousands_sep(); - __grp = __mp.grouping(); - __sym = __mp.curr_symbol(); - __fd = __mp.frac_digits(); - } - else - { - const moneypunct& __mp = - use_facet >(__loc); - __pat = __mp.neg_format(); - __nsn = __mp.negative_sign(); - __psn = __mp.positive_sign(); - __dp = __mp.decimal_point(); - __ts = __mp.thousands_sep(); - __grp = __mp.grouping(); - __sym = __mp.curr_symbol(); - __fd = __mp.frac_digits(); - } -} - -extern template class __money_get; -extern template class __money_get; - -template > -class _LIBCPP_VISIBLE money_get - : public locale::facet, - private __money_get<_CharT> -{ -public: - typedef _CharT char_type; - typedef _InputIterator iter_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE - explicit money_get(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, bool __intl, ios_base& __iob, - ios_base::iostate& __err, long double& __v) const - { - return do_get(__b, __e, __intl, __iob, __err, __v); - } - - _LIBCPP_ALWAYS_INLINE - iter_type get(iter_type __b, iter_type __e, bool __intl, ios_base& __iob, - ios_base::iostate& __err, string_type& __v) const - { - return do_get(__b, __e, __intl, __iob, __err, __v); - } - - static locale::id id; - -protected: - - _LIBCPP_ALWAYS_INLINE - ~money_get() {} - - virtual iter_type do_get(iter_type __b, iter_type __e, bool __intl, - ios_base& __iob, ios_base::iostate& __err, - long double& __v) const; - virtual iter_type do_get(iter_type __b, iter_type __e, bool __intl, - ios_base& __iob, ios_base::iostate& __err, - string_type& __v) const; - -private: - static bool __do_get(iter_type& __b, iter_type __e, - bool __intl, const locale& __loc, - ios_base::fmtflags __flags, ios_base::iostate& __err, - bool& __neg, const ctype& __ct, - unique_ptr& __wb, - char_type*& __wn, char_type* __we); -}; - -template -locale::id -money_get<_CharT, _InputIterator>::id; - -void __do_nothing(void*); - -template -_LIBCPP_HIDDEN -void -__double_or_nothing(unique_ptr<_Tp, void(*)(void*)>& __b, _Tp*& __n, _Tp*& __e) -{ - bool __owns = __b.get_deleter() != __do_nothing; - size_t __cur_cap = static_cast(__e-__b.get()) * sizeof(_Tp); - size_t __new_cap = __cur_cap < numeric_limits::max() / 2 ? - 2 * __cur_cap : numeric_limits::max(); - size_t __n_off = static_cast(__n - __b.get()); - _Tp* __t = (_Tp*)realloc(__owns ? __b.get() : 0, __new_cap); - if (__t == 0) - __throw_bad_alloc(); - if (__owns) - __b.release(); - __b = unique_ptr<_Tp, void(*)(void*)>(__t, free); - __new_cap /= sizeof(_Tp); - __n = __b.get() + __n_off; - __e = __b.get() + __new_cap; -} - -// true == success -template -bool -money_get<_CharT, _InputIterator>::__do_get(iter_type& __b, iter_type __e, - bool __intl, const locale& __loc, - ios_base::fmtflags __flags, - ios_base::iostate& __err, - bool& __neg, - const ctype& __ct, - unique_ptr& __wb, - char_type*& __wn, char_type* __we) -{ - const unsigned __bz = 100; - unsigned __gbuf[__bz]; - unique_ptr __gb(__gbuf, __do_nothing); - unsigned* __gn = __gb.get(); - unsigned* __ge = __gn + __bz; - money_base::pattern __pat; - char_type __dp; - char_type __ts; - string __grp; - string_type __sym; - string_type __psn; - string_type __nsn; - // Capture the spaces read into money_base::{space,none} so they - // can be compared to initial spaces in __sym. - string_type __spaces; - int __fd; - __money_get<_CharT>::__gather_info(__intl, __loc, __pat, __dp, __ts, __grp, - __sym, __psn, __nsn, __fd); - const string_type* __trailing_sign = 0; - __wn = __wb.get(); - for (unsigned __p = 0; __p < 4 && __b != __e; ++__p) - { - switch (__pat.field[__p]) - { - case money_base::space: - if (__p != 3) - { - if (__ct.is(ctype_base::space, *__b)) - __spaces.push_back(*__b++); - else - { - __err |= ios_base::failbit; - return false; - } - } - // drop through - case money_base::none: - if (__p != 3) - { - while (__b != __e && __ct.is(ctype_base::space, *__b)) - __spaces.push_back(*__b++); - } - break; - case money_base::sign: - if (__psn.size() + __nsn.size() > 0) - { - if (__psn.size() == 0 || __nsn.size() == 0) - { // sign is optional - if (__psn.size() > 0) - { // __nsn.size() == 0 - if (*__b == __psn[0]) - { - ++__b; - if (__psn.size() > 1) - __trailing_sign = &__psn; - } - else - __neg = true; - } - else if (*__b == __nsn[0]) // __nsn.size() > 0 && __psn.size() == 0 - { - ++__b; - __neg = true; - if (__nsn.size() > 1) - __trailing_sign = &__nsn; - } - } - else // sign is required - { - if (*__b == __psn[0]) - { - ++__b; - if (__psn.size() > 1) - __trailing_sign = &__psn; - } - else if (*__b == __nsn[0]) - { - ++__b; - __neg = true; - if (__nsn.size() > 1) - __trailing_sign = &__nsn; - } - else - { - __err |= ios_base::failbit; - return false; - } - } - } - break; - case money_base::symbol: - { - bool __more_needed = __trailing_sign || - (__p < 2) || - (__p == 2 && __pat.field[3] != static_cast(money_base::none)); - bool __sb = __flags & ios_base::showbase; - if (__sb || __more_needed) - { - ios_base::iostate __et = ios_base::goodbit; - typename string_type::const_iterator __sym_space_end = __sym.begin(); - if (__p > 0 && (__pat.field[__p - 1] == money_base::none || - __pat.field[__p - 1] == money_base::space)) { - // Match spaces we've already read against spaces at - // the beginning of __sym. - while (__sym_space_end != __sym.end() && - __ct.is(ctype_base::space, *__sym_space_end)) - ++__sym_space_end; - const size_t __num_spaces = __sym_space_end - __sym.begin(); - if (__num_spaces > __spaces.size() || - !equal(__spaces.end() - __num_spaces, __spaces.end(), - __sym.begin())) { - // No match. Put __sym_space_end back at the - // beginning of __sym, which will prevent a - // match in the next loop. - __sym_space_end = __sym.begin(); - } - } - typename string_type::const_iterator __sym_curr_char = __sym_space_end; - while (__sym_curr_char != __sym.end() && __b != __e && - *__b == *__sym_curr_char) { - ++__b; - ++__sym_curr_char; - } - if (__sb && __sym_curr_char != __sym.end()) - { - __err |= ios_base::failbit; - return false; - } - } - } - break; - case money_base::value: - { - unsigned __ng = 0; - for (; __b != __e; ++__b) - { - char_type __c = *__b; - if (__ct.is(ctype_base::digit, __c)) - { - if (__wn == __we) - __double_or_nothing(__wb, __wn, __we); - *__wn++ = __c; - ++__ng; - } - else if (__grp.size() > 0 && __ng > 0 && __c == __ts) - { - if (__gn == __ge) - __double_or_nothing(__gb, __gn, __ge); - *__gn++ = __ng; - __ng = 0; - } - else - break; - } - if (__gb.get() != __gn && __ng > 0) - { - if (__gn == __ge) - __double_or_nothing(__gb, __gn, __ge); - *__gn++ = __ng; - } - if (__fd > 0) - { - if (__b == __e || *__b != __dp) - { - __err |= ios_base::failbit; - return false; - } - for (++__b; __fd > 0; --__fd, ++__b) - { - if (__b == __e || !__ct.is(ctype_base::digit, *__b)) - { - __err |= ios_base::failbit; - return false; - } - if (__wn == __we) - __double_or_nothing(__wb, __wn, __we); - *__wn++ = *__b; - } - } - if (__wn == __wb.get()) - { - __err |= ios_base::failbit; - return false; - } - } - break; - } - } - if (__trailing_sign) - { - for (unsigned __i = 1; __i < __trailing_sign->size(); ++__i, ++__b) - { - if (__b == __e || *__b != (*__trailing_sign)[__i]) - { - __err |= ios_base::failbit; - return false; - } - } - } - if (__gb.get() != __gn) - { - ios_base::iostate __et = ios_base::goodbit; - __check_grouping(__grp, __gb.get(), __gn, __et); - if (__et) - { - __err |= ios_base::failbit; - return false; - } - } - return true; -} - -template -_InputIterator -money_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - bool __intl, ios_base& __iob, - ios_base::iostate& __err, - long double& __v) const -{ - const int __bz = 100; - char_type __wbuf[__bz]; - unique_ptr __wb(__wbuf, __do_nothing); - char_type* __wn; - char_type* __we = __wbuf + __bz; - locale __loc = __iob.getloc(); - const ctype& __ct = use_facet >(__loc); - bool __neg = false; - if (__do_get(__b, __e, __intl, __loc, __iob.flags(), __err, __neg, __ct, - __wb, __wn, __we)) - { - const char __src[] = "0123456789"; - char_type __atoms[sizeof(__src)-1]; - __ct.widen(__src, __src + (sizeof(__src)-1), __atoms); - char __nbuf[__bz]; - char* __nc = __nbuf; - unique_ptr __h(0, free); - if (__wn - __wb.get() > __bz-2) - { - __h.reset((char*)malloc(static_cast(__wn - __wb.get() + 2))); - if (__h.get() == 0) - __throw_bad_alloc(); - __nc = __h.get(); - } - if (__neg) - *__nc++ = '-'; - for (const char_type* __w = __wb.get(); __w < __wn; ++__w, ++__nc) - *__nc = __src[find(__atoms, __atoms+sizeof(__atoms), *__w) - __atoms]; - *__nc = char(); - if (sscanf(__nbuf, "%Lf", &__v) != 1) - __throw_runtime_error("money_get error"); - } - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -template -_InputIterator -money_get<_CharT, _InputIterator>::do_get(iter_type __b, iter_type __e, - bool __intl, ios_base& __iob, - ios_base::iostate& __err, - string_type& __v) const -{ - const int __bz = 100; - char_type __wbuf[__bz]; - unique_ptr __wb(__wbuf, __do_nothing); - char_type* __wn; - char_type* __we = __wbuf + __bz; - locale __loc = __iob.getloc(); - const ctype& __ct = use_facet >(__loc); - bool __neg = false; - if (__do_get(__b, __e, __intl, __loc, __iob.flags(), __err, __neg, __ct, - __wb, __wn, __we)) - { - __v.clear(); - if (__neg) - __v.push_back(__ct.widen('-')); - char_type __z = __ct.widen('0'); - char_type* __w; - for (__w = __wb.get(); __w < __wn-1; ++__w) - if (*__w != __z) - break; - __v.append(__w, __wn); - } - if (__b == __e) - __err |= ios_base::eofbit; - return __b; -} - -extern template class money_get; -extern template class money_get; - -// money_put - -template -class __money_put -{ -protected: - typedef _CharT char_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE __money_put() {} - - static void __gather_info(bool __intl, bool __neg, const locale& __loc, - money_base::pattern& __pat, char_type& __dp, - char_type& __ts, string& __grp, - string_type& __sym, string_type& __sn, - int& __fd); - static void __format(char_type* __mb, char_type*& __mi, char_type*& __me, - ios_base::fmtflags __flags, - const char_type* __db, const char_type* __de, - const ctype& __ct, bool __neg, - const money_base::pattern& __pat, char_type __dp, - char_type __ts, const string& __grp, - const string_type& __sym, const string_type& __sn, - int __fd); -}; - -template -void -__money_put<_CharT>::__gather_info(bool __intl, bool __neg, const locale& __loc, - money_base::pattern& __pat, char_type& __dp, - char_type& __ts, string& __grp, - string_type& __sym, string_type& __sn, - int& __fd) -{ - if (__intl) - { - const moneypunct& __mp = - use_facet >(__loc); - if (__neg) - { - __pat = __mp.neg_format(); - __sn = __mp.negative_sign(); - } - else - { - __pat = __mp.pos_format(); - __sn = __mp.positive_sign(); - } - __dp = __mp.decimal_point(); - __ts = __mp.thousands_sep(); - __grp = __mp.grouping(); - __sym = __mp.curr_symbol(); - __fd = __mp.frac_digits(); - } - else - { - const moneypunct& __mp = - use_facet >(__loc); - if (__neg) - { - __pat = __mp.neg_format(); - __sn = __mp.negative_sign(); - } - else - { - __pat = __mp.pos_format(); - __sn = __mp.positive_sign(); - } - __dp = __mp.decimal_point(); - __ts = __mp.thousands_sep(); - __grp = __mp.grouping(); - __sym = __mp.curr_symbol(); - __fd = __mp.frac_digits(); - } -} - -template -void -__money_put<_CharT>::__format(char_type* __mb, char_type*& __mi, char_type*& __me, - ios_base::fmtflags __flags, - const char_type* __db, const char_type* __de, - const ctype& __ct, bool __neg, - const money_base::pattern& __pat, char_type __dp, - char_type __ts, const string& __grp, - const string_type& __sym, const string_type& __sn, - int __fd) -{ - __me = __mb; - for (unsigned __p = 0; __p < 4; ++__p) - { - switch (__pat.field[__p]) - { - case money_base::none: - __mi = __me; - break; - case money_base::space: - __mi = __me; - *__me++ = __ct.widen(' '); - break; - case money_base::sign: - if (!__sn.empty()) - *__me++ = __sn[0]; - break; - case money_base::symbol: - if (!__sym.empty() && (__flags & ios_base::showbase)) - __me = _VSTD::copy(__sym.begin(), __sym.end(), __me); - break; - case money_base::value: - { - // remember start of value so we can reverse it - char_type* __t = __me; - // find beginning of digits - if (__neg) - ++__db; - // find end of digits - const char_type* __d; - for (__d = __db; __d < __de; ++__d) - if (!__ct.is(ctype_base::digit, *__d)) - break; - // print fractional part - if (__fd > 0) - { - int __f; - for (__f = __fd; __d > __db && __f > 0; --__f) - *__me++ = *--__d; - char_type __z = __f > 0 ? __ct.widen('0') : char_type(); - for (; __f > 0; --__f) - *__me++ = __z; - *__me++ = __dp; - } - // print units part - if (__d == __db) - { - *__me++ = __ct.widen('0'); - } - else - { - unsigned __ng = 0; - unsigned __ig = 0; - unsigned __gl = __grp.empty() ? numeric_limits::max() - : static_cast(__grp[__ig]); - while (__d != __db) - { - if (__ng == __gl) - { - *__me++ = __ts; - __ng = 0; - if (++__ig < __grp.size()) - __gl = __grp[__ig] == numeric_limits::max() ? - numeric_limits::max() : - static_cast(__grp[__ig]); - } - *__me++ = *--__d; - ++__ng; - } - } - // reverse it - reverse(__t, __me); - } - break; - } - } - // print rest of sign, if any - if (__sn.size() > 1) - __me = _VSTD::copy(__sn.begin()+1, __sn.end(), __me); - // set alignment - if ((__flags & ios_base::adjustfield) == ios_base::left) - __mi = __me; - else if ((__flags & ios_base::adjustfield) != ios_base::internal) - __mi = __mb; -} - -extern template class __money_put; -extern template class __money_put; - -template > -class _LIBCPP_VISIBLE money_put - : public locale::facet, - private __money_put<_CharT> -{ -public: - typedef _CharT char_type; - typedef _OutputIterator iter_type; - typedef basic_string string_type; - - _LIBCPP_ALWAYS_INLINE - explicit money_put(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, bool __intl, ios_base& __iob, char_type __fl, - long double __units) const - { - return do_put(__s, __intl, __iob, __fl, __units); - } - - _LIBCPP_ALWAYS_INLINE - iter_type put(iter_type __s, bool __intl, ios_base& __iob, char_type __fl, - const string_type& __digits) const - { - return do_put(__s, __intl, __iob, __fl, __digits); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~money_put() {} - - virtual iter_type do_put(iter_type __s, bool __intl, ios_base& __iob, - char_type __fl, long double __units) const; - virtual iter_type do_put(iter_type __s, bool __intl, ios_base& __iob, - char_type __fl, const string_type& __digits) const; -}; - -template -locale::id -money_put<_CharT, _OutputIterator>::id; - -template -_OutputIterator -money_put<_CharT, _OutputIterator>::do_put(iter_type __s, bool __intl, - ios_base& __iob, char_type __fl, - long double __units) const -{ - // convert to char - const size_t __bs = 100; - char __buf[__bs]; - char* __bb = __buf; - char_type __digits[__bs]; - char_type* __db = __digits; - size_t __n = static_cast(snprintf(__bb, __bs, "%.0Lf", __units)); - unique_ptr __hn(0, free); - unique_ptr __hd(0, free); - // secure memory for digit storage - if (__n > __bs-1) - { -#ifdef _LIBCPP_LOCALE__L_EXTENSIONS - __n = static_cast(asprintf_l(&__bb, _LIBCPP_GET_C_LOCALE, "%.0Lf", __units)); -#else - __n = __asprintf_l(&__bb, __cloc(), "%.0Lf", __units); -#endif - if (__bb == 0) - __throw_bad_alloc(); - __hn.reset(__bb); - __hd.reset((char_type*)malloc(__n * sizeof(char_type))); - if (__hd == nullptr) - __throw_bad_alloc(); - __db = __hd.get(); - } - // gather info - locale __loc = __iob.getloc(); - const ctype& __ct = use_facet >(__loc); - __ct.widen(__bb, __bb + __n, __db); - bool __neg = __n > 0 && __bb[0] == '-'; - money_base::pattern __pat; - char_type __dp; - char_type __ts; - string __grp; - string_type __sym; - string_type __sn; - int __fd; - this->__gather_info(__intl, __neg, __loc, __pat, __dp, __ts, __grp, __sym, __sn, __fd); - // secure memory for formatting - char_type __mbuf[__bs]; - char_type* __mb = __mbuf; - unique_ptr __hw(0, free); - size_t __exn = static_cast(__n) > __fd ? - (__n - static_cast(__fd)) * 2 + __sn.size() + - __sym.size() + static_cast(__fd) + 1 - : __sn.size() + __sym.size() + static_cast(__fd) + 2; - if (__exn > __bs) - { - __hw.reset((char_type*)malloc(__exn * sizeof(char_type))); - __mb = __hw.get(); - if (__mb == 0) - __throw_bad_alloc(); - } - // format - char_type* __mi; - char_type* __me; - this->__format(__mb, __mi, __me, __iob.flags(), - __db, __db + __n, __ct, - __neg, __pat, __dp, __ts, __grp, __sym, __sn, __fd); - return __pad_and_output(__s, __mb, __mi, __me, __iob, __fl); -} - -template -_OutputIterator -money_put<_CharT, _OutputIterator>::do_put(iter_type __s, bool __intl, - ios_base& __iob, char_type __fl, - const string_type& __digits) const -{ - // gather info - locale __loc = __iob.getloc(); - const ctype& __ct = use_facet >(__loc); - bool __neg = __digits.size() > 0 && __digits[0] == __ct.widen('-'); - money_base::pattern __pat; - char_type __dp; - char_type __ts; - string __grp; - string_type __sym; - string_type __sn; - int __fd; - this->__gather_info(__intl, __neg, __loc, __pat, __dp, __ts, __grp, __sym, __sn, __fd); - // secure memory for formatting - char_type __mbuf[100]; - char_type* __mb = __mbuf; - unique_ptr __h(0, free); - size_t __exn = static_cast(__digits.size()) > __fd ? - (__digits.size() - static_cast(__fd)) * 2 + - __sn.size() + __sym.size() + static_cast(__fd) + 1 - : __sn.size() + __sym.size() + static_cast(__fd) + 2; - if (__exn > 100) - { - __h.reset((char_type*)malloc(__exn * sizeof(char_type))); - __mb = __h.get(); - if (__mb == 0) - __throw_bad_alloc(); - } - // format - char_type* __mi; - char_type* __me; - this->__format(__mb, __mi, __me, __iob.flags(), - __digits.data(), __digits.data() + __digits.size(), __ct, - __neg, __pat, __dp, __ts, __grp, __sym, __sn, __fd); - return __pad_and_output(__s, __mb, __mi, __me, __iob, __fl); -} - -extern template class money_put; -extern template class money_put; - -// messages - -class _LIBCPP_VISIBLE messages_base -{ -public: - typedef ptrdiff_t catalog; - - _LIBCPP_ALWAYS_INLINE messages_base() {} -}; - -template -class _LIBCPP_VISIBLE messages - : public locale::facet, - public messages_base -{ -public: - typedef _CharT char_type; - typedef basic_string<_CharT> string_type; - - _LIBCPP_ALWAYS_INLINE - explicit messages(size_t __refs = 0) - : locale::facet(__refs) {} - - _LIBCPP_ALWAYS_INLINE - catalog open(const basic_string& __nm, const locale& __loc) const - { - return do_open(__nm, __loc); - } - - _LIBCPP_ALWAYS_INLINE - string_type get(catalog __c, int __set, int __msgid, - const string_type& __dflt) const - { - return do_get(__c, __set, __msgid, __dflt); - } - - _LIBCPP_ALWAYS_INLINE - void close(catalog __c) const - { - do_close(__c); - } - - static locale::id id; - -protected: - _LIBCPP_ALWAYS_INLINE - ~messages() {} - - virtual catalog do_open(const basic_string&, const locale&) const; - virtual string_type do_get(catalog, int __set, int __msgid, - const string_type& __dflt) const; - virtual void do_close(catalog) const; -}; - -template -locale::id -messages<_CharT>::id; - -template -typename messages<_CharT>::catalog -messages<_CharT>::do_open(const basic_string& __nm, const locale&) const -{ -#if _WIN32 - return -1; -#else // _WIN32 - catalog __cat = (catalog)catopen(__nm.c_str(), NL_CAT_LOCALE); - if (__cat != -1) - __cat = static_cast((static_cast(__cat) >> 1)); - return __cat; -#endif // _WIN32 -} - -template -typename messages<_CharT>::string_type -messages<_CharT>::do_get(catalog __c, int __set, int __msgid, - const string_type& __dflt) const -{ -#if _WIN32 - return __dflt; -#else // _WIN32 - string __ndflt; - __narrow_to_utf8()(back_inserter(__ndflt), - __dflt.c_str(), - __dflt.c_str() + __dflt.size()); - if (__c != -1) - __c <<= 1; - nl_catd __cat = (nl_catd)__c; - char* __n = catgets(__cat, __set, __msgid, __ndflt.c_str()); - string_type __w; - __widen_from_utf8()(back_inserter(__w), - __n, __n + strlen(__n)); - return __w; -#endif // _WIN32 -} - -template -void -messages<_CharT>::do_close(catalog __c) const -{ -#if !_WIN32 - if (__c != -1) - __c <<= 1; - nl_catd __cat = (nl_catd)__c; - catclose(__cat); -#endif // !_WIN32 -} - -extern template class messages; -extern template class messages; - -template -class _LIBCPP_VISIBLE messages_byname - : public messages<_CharT> -{ -public: - typedef messages_base::catalog catalog; - typedef basic_string<_CharT> string_type; - - _LIBCPP_ALWAYS_INLINE - explicit messages_byname(const char*, size_t __refs = 0) - : messages<_CharT>(__refs) {} - - _LIBCPP_ALWAYS_INLINE - explicit messages_byname(const string&, size_t __refs = 0) - : messages<_CharT>(__refs) {} - -protected: - _LIBCPP_ALWAYS_INLINE - ~messages_byname() {} -}; - -extern template class messages_byname; -extern template class messages_byname; - -template, - class _Byte_alloc = allocator > -class _LIBCPP_VISIBLE wstring_convert -{ -public: - typedef basic_string, _Byte_alloc> byte_string; - typedef basic_string<_Elem, char_traits<_Elem>, _Wide_alloc> wide_string; - typedef typename _Codecvt::state_type state_type; - typedef typename wide_string::traits_type::int_type int_type; - -private: - byte_string __byte_err_string_; - wide_string __wide_err_string_; - _Codecvt* __cvtptr_; - state_type __cvtstate_; - size_t __cvtcount_; - - wstring_convert(const wstring_convert& __wc); - wstring_convert& operator=(const wstring_convert& __wc); -public: - wstring_convert(_Codecvt* __pcvt = new _Codecvt); - wstring_convert(_Codecvt* __pcvt, state_type __state); - wstring_convert(const byte_string& __byte_err, - const wide_string& __wide_err = wide_string()); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - wstring_convert(wstring_convert&& __wc); -#endif - ~wstring_convert(); - - _LIBCPP_ALWAYS_INLINE - wide_string from_bytes(char __byte) - {return from_bytes(&__byte, &__byte+1);} - _LIBCPP_ALWAYS_INLINE - wide_string from_bytes(const char* __ptr) - {return from_bytes(__ptr, __ptr + char_traits::length(__ptr));} - _LIBCPP_ALWAYS_INLINE - wide_string from_bytes(const byte_string& __str) - {return from_bytes(__str.data(), __str.data() + __str.size());} - wide_string from_bytes(const char* __first, const char* __last); - - _LIBCPP_ALWAYS_INLINE - byte_string to_bytes(_Elem __wchar) - {return to_bytes(&__wchar, &__wchar+1);} - _LIBCPP_ALWAYS_INLINE - byte_string to_bytes(const _Elem* __wptr) - {return to_bytes(__wptr, __wptr + char_traits<_Elem>::length(__wptr));} - _LIBCPP_ALWAYS_INLINE - byte_string to_bytes(const wide_string& __wstr) - {return to_bytes(__wstr.data(), __wstr.data() + __wstr.size());} - byte_string to_bytes(const _Elem* __first, const _Elem* __last); - - _LIBCPP_ALWAYS_INLINE - size_t converted() const {return __cvtcount_;} - _LIBCPP_ALWAYS_INLINE - state_type state() const {return __cvtstate_;} -}; - -template -inline _LIBCPP_ALWAYS_INLINE -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - wstring_convert(_Codecvt* __pcvt) - : __cvtptr_(__pcvt), __cvtstate_(), __cvtcount_(0) -{ -} - -template -inline _LIBCPP_ALWAYS_INLINE -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - wstring_convert(_Codecvt* __pcvt, state_type __state) - : __cvtptr_(__pcvt), __cvtstate_(__state), __cvtcount_(0) -{ -} - -template -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - wstring_convert(const byte_string& __byte_err, const wide_string& __wide_err) - : __byte_err_string_(__byte_err), __wide_err_string_(__wide_err), - __cvtstate_(), __cvtcount_(0) -{ - __cvtptr_ = new _Codecvt; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -inline _LIBCPP_ALWAYS_INLINE -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - wstring_convert(wstring_convert&& __wc) - : __byte_err_string_(_VSTD::move(__wc.__byte_err_string_)), - __wide_err_string_(_VSTD::move(__wc.__wide_err_string_)), - __cvtptr_(__wc.__cvtptr_), - __cvtstate_(__wc.__cvtstate_), __cvtcount_(__wc.__cvtstate_) -{ - __wc.__cvtptr_ = nullptr; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::~wstring_convert() -{ - delete __cvtptr_; -} - -template -typename wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::wide_string -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - from_bytes(const char* __frm, const char* __frm_end) -{ - __cvtcount_ = 0; - if (__cvtptr_ != nullptr) - { - wide_string __ws(2*(__frm_end - __frm), _Elem()); - __ws.resize(__ws.capacity()); - codecvt_base::result __r = codecvt_base::ok; - state_type __st = __cvtstate_; - if (__frm != __frm_end) - { - _Elem* __to = &__ws[0]; - _Elem* __to_end = __to + __ws.size(); - const char* __frm_nxt; - do - { - _Elem* __to_nxt; - __r = __cvtptr_->in(__st, __frm, __frm_end, __frm_nxt, - __to, __to_end, __to_nxt); - __cvtcount_ += __frm_nxt - __frm; - if (__frm_nxt == __frm) - { - __r = codecvt_base::error; - } - else if (__r == codecvt_base::noconv) - { - __ws.resize(__to - &__ws[0]); - // This only gets executed if _Elem is char - __ws.append((const _Elem*)__frm, (const _Elem*)__frm_end); - __frm = __frm_nxt; - __r = codecvt_base::ok; - } - else if (__r == codecvt_base::ok) - { - __ws.resize(__to_nxt - &__ws[0]); - __frm = __frm_nxt; - } - else if (__r == codecvt_base::partial) - { - ptrdiff_t __s = __to_nxt - &__ws[0]; - __ws.resize(2 * __s); - __to = &__ws[0] + __s; - __to_end = &__ws[0] + __ws.size(); - __frm = __frm_nxt; - } - } while (__r == codecvt_base::partial && __frm_nxt < __frm_end); - } - if (__r == codecvt_base::ok) - return __ws; - } -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__wide_err_string_.empty()) - throw range_error("wstring_convert: from_bytes error"); -#endif // _LIBCPP_NO_EXCEPTIONS - return __wide_err_string_; -} - -template -typename wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>::byte_string -wstring_convert<_Codecvt, _Elem, _Wide_alloc, _Byte_alloc>:: - to_bytes(const _Elem* __frm, const _Elem* __frm_end) -{ - __cvtcount_ = 0; - if (__cvtptr_ != nullptr) - { - byte_string __bs(2*(__frm_end - __frm), char()); - __bs.resize(__bs.capacity()); - codecvt_base::result __r = codecvt_base::ok; - state_type __st = __cvtstate_; - if (__frm != __frm_end) - { - char* __to = &__bs[0]; - char* __to_end = __to + __bs.size(); - const _Elem* __frm_nxt; - do - { - char* __to_nxt; - __r = __cvtptr_->out(__st, __frm, __frm_end, __frm_nxt, - __to, __to_end, __to_nxt); - __cvtcount_ += __frm_nxt - __frm; - if (__frm_nxt == __frm) - { - __r = codecvt_base::error; - } - else if (__r == codecvt_base::noconv) - { - __bs.resize(__to - &__bs[0]); - // This only gets executed if _Elem is char - __bs.append((const char*)__frm, (const char*)__frm_end); - __frm = __frm_nxt; - __r = codecvt_base::ok; - } - else if (__r == codecvt_base::ok) - { - __bs.resize(__to_nxt - &__bs[0]); - __frm = __frm_nxt; - } - else if (__r == codecvt_base::partial) - { - ptrdiff_t __s = __to_nxt - &__bs[0]; - __bs.resize(2 * __s); - __to = &__bs[0] + __s; - __to_end = &__bs[0] + __bs.size(); - __frm = __frm_nxt; - } - } while (__r == codecvt_base::partial && __frm_nxt < __frm_end); - } - if (__r == codecvt_base::ok) - { - size_t __s = __bs.size(); - __bs.resize(__bs.capacity()); - char* __to = &__bs[0] + __s; - char* __to_end = __to + __bs.size(); - do - { - char* __to_nxt; - __r = __cvtptr_->unshift(__st, __to, __to_end, __to_nxt); - if (__r == codecvt_base::noconv) - { - __bs.resize(__to - &__bs[0]); - __r = codecvt_base::ok; - } - else if (__r == codecvt_base::ok) - { - __bs.resize(__to_nxt - &__bs[0]); - } - else if (__r == codecvt_base::partial) - { - ptrdiff_t __sp = __to_nxt - &__bs[0]; - __bs.resize(2 * __sp); - __to = &__bs[0] + __sp; - __to_end = &__bs[0] + __bs.size(); - } - } while (__r == codecvt_base::partial); - if (__r == codecvt_base::ok) - return __bs; - } - } -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__byte_err_string_.empty()) - throw range_error("wstring_convert: to_bytes error"); -#endif // _LIBCPP_NO_EXCEPTIONS - return __byte_err_string_; -} - -template > -class _LIBCPP_VISIBLE wbuffer_convert - : public basic_streambuf<_Elem, _Tr> -{ -public: - // types: - typedef _Elem char_type; - typedef _Tr traits_type; - typedef typename traits_type::int_type int_type; - typedef typename traits_type::pos_type pos_type; - typedef typename traits_type::off_type off_type; - typedef typename _Codecvt::state_type state_type; - -private: - char* __extbuf_; - const char* __extbufnext_; - const char* __extbufend_; - char __extbuf_min_[8]; - size_t __ebs_; - char_type* __intbuf_; - size_t __ibs_; - streambuf* __bufptr_; - _Codecvt* __cv_; - state_type __st_; - ios_base::openmode __cm_; - bool __owns_eb_; - bool __owns_ib_; - bool __always_noconv_; - - wbuffer_convert(const wbuffer_convert&); - wbuffer_convert& operator=(const wbuffer_convert&); -public: - wbuffer_convert(streambuf* __bytebuf = 0, _Codecvt* __pcvt = new _Codecvt, - state_type __state = state_type()); - ~wbuffer_convert(); - - _LIBCPP_INLINE_VISIBILITY - streambuf* rdbuf() const {return __bufptr_;} - _LIBCPP_INLINE_VISIBILITY - streambuf* rdbuf(streambuf* __bytebuf) - { - streambuf* __r = __bufptr_; - __bufptr_ = __bytebuf; - return __r; - } - - _LIBCPP_INLINE_VISIBILITY - state_type state() const {return __st_;} - -protected: - virtual int_type underflow(); - virtual int_type pbackfail(int_type __c = traits_type::eof()); - virtual int_type overflow (int_type __c = traits_type::eof()); - virtual basic_streambuf* setbuf(char_type* __s, - streamsize __n); - virtual pos_type seekoff(off_type __off, ios_base::seekdir __way, - ios_base::openmode __wch = ios_base::in | ios_base::out); - virtual pos_type seekpos(pos_type __sp, - ios_base::openmode __wch = ios_base::in | ios_base::out); - virtual int sync(); - -private: - bool __read_mode(); - void __write_mode(); - wbuffer_convert* __close(); -}; - -template -wbuffer_convert<_Codecvt, _Elem, _Tr>:: - wbuffer_convert(streambuf* __bytebuf, _Codecvt* __pcvt, state_type __state) - : __extbuf_(0), - __extbufnext_(0), - __extbufend_(0), - __ebs_(0), - __intbuf_(0), - __ibs_(0), - __bufptr_(__bytebuf), - __cv_(__pcvt), - __st_(__state), - __cm_(0), - __owns_eb_(false), - __owns_ib_(false), - __always_noconv_(__cv_ ? __cv_->always_noconv() : false) -{ - setbuf(0, 4096); -} - -template -wbuffer_convert<_Codecvt, _Elem, _Tr>::~wbuffer_convert() -{ - __close(); - delete __cv_; - if (__owns_eb_) - delete [] __extbuf_; - if (__owns_ib_) - delete [] __intbuf_; -} - -template -typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type -wbuffer_convert<_Codecvt, _Elem, _Tr>::underflow() -{ - if (__cv_ == 0 || __bufptr_ == 0) - return traits_type::eof(); - bool __initial = __read_mode(); - char_type __1buf; - if (this->gptr() == 0) - this->setg(&__1buf, &__1buf+1, &__1buf+1); - const size_t __unget_sz = __initial ? 0 : min((this->egptr() - this->eback()) / 2, 4); - int_type __c = traits_type::eof(); - if (this->gptr() == this->egptr()) - { - memmove(this->eback(), this->egptr() - __unget_sz, __unget_sz * sizeof(char_type)); - if (__always_noconv_) - { - streamsize __nmemb = static_cast(this->egptr() - this->eback() - __unget_sz); - __nmemb = __bufptr_->sgetn((char*)this->eback() + __unget_sz, __nmemb); - if (__nmemb != 0) - { - this->setg(this->eback(), - this->eback() + __unget_sz, - this->eback() + __unget_sz + __nmemb); - __c = *this->gptr(); - } - } - else - { - memmove(__extbuf_, __extbufnext_, __extbufend_ - __extbufnext_); - __extbufnext_ = __extbuf_ + (__extbufend_ - __extbufnext_); - __extbufend_ = __extbuf_ + (__extbuf_ == __extbuf_min_ ? sizeof(__extbuf_min_) : __ebs_); - streamsize __nmemb = _VSTD::min(static_cast(this->egptr() - this->eback() - __unget_sz), - static_cast(__extbufend_ - __extbufnext_)); - codecvt_base::result __r; - state_type __svs = __st_; - streamsize __nr = __bufptr_->sgetn(const_cast(__extbufnext_), __nmemb); - if (__nr != 0) - { - __extbufend_ = __extbufnext_ + __nr; - char_type* __inext; - __r = __cv_->in(__st_, __extbuf_, __extbufend_, __extbufnext_, - this->eback() + __unget_sz, - this->egptr(), __inext); - if (__r == codecvt_base::noconv) - { - this->setg((char_type*)__extbuf_, (char_type*)__extbuf_, (char_type*)__extbufend_); - __c = *this->gptr(); - } - else if (__inext != this->eback() + __unget_sz) - { - this->setg(this->eback(), this->eback() + __unget_sz, __inext); - __c = *this->gptr(); - } - } - } - } - else - __c = *this->gptr(); - if (this->eback() == &__1buf) - this->setg(0, 0, 0); - return __c; -} - -template -typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type -wbuffer_convert<_Codecvt, _Elem, _Tr>::pbackfail(int_type __c) -{ - if (__cv_ != 0 && __bufptr_ != 0 && this->eback() < this->gptr()) - { - if (traits_type::eq_int_type(__c, traits_type::eof())) - { - this->gbump(-1); - return traits_type::not_eof(__c); - } - if (traits_type::eq(traits_type::to_char_type(__c), this->gptr()[-1])) - { - this->gbump(-1); - *this->gptr() = traits_type::to_char_type(__c); - return __c; - } - } - return traits_type::eof(); -} - -template -typename wbuffer_convert<_Codecvt, _Elem, _Tr>::int_type -wbuffer_convert<_Codecvt, _Elem, _Tr>::overflow(int_type __c) -{ - if (__cv_ == 0 || __bufptr_ == 0) - return traits_type::eof(); - __write_mode(); - char_type __1buf; - char_type* __pb_save = this->pbase(); - char_type* __epb_save = this->epptr(); - if (!traits_type::eq_int_type(__c, traits_type::eof())) - { - if (this->pptr() == 0) - this->setp(&__1buf, &__1buf+1); - *this->pptr() = traits_type::to_char_type(__c); - this->pbump(1); - } - if (this->pptr() != this->pbase()) - { - if (__always_noconv_) - { - streamsize __nmemb = static_cast(this->pptr() - this->pbase()); - if (__bufptr_->sputn((const char*)this->pbase(), __nmemb) != __nmemb) - return traits_type::eof(); - } - else - { - char* __extbe = __extbuf_; - codecvt_base::result __r; - do - { - const char_type* __e; - __r = __cv_->out(__st_, this->pbase(), this->pptr(), __e, - __extbuf_, __extbuf_ + __ebs_, __extbe); - if (__e == this->pbase()) - return traits_type::eof(); - if (__r == codecvt_base::noconv) - { - streamsize __nmemb = static_cast(this->pptr() - this->pbase()); - if (__bufptr_->sputn((const char*)this->pbase(), __nmemb) != __nmemb) - return traits_type::eof(); - } - else if (__r == codecvt_base::ok || __r == codecvt_base::partial) - { - streamsize __nmemb = static_cast(__extbe - __extbuf_); - if (__bufptr_->sputn(__extbuf_, __nmemb) != __nmemb) - return traits_type::eof(); - if (__r == codecvt_base::partial) - { - this->setp((char_type*)__e, this->pptr()); - this->pbump(this->epptr() - this->pbase()); - } - } - else - return traits_type::eof(); - } while (__r == codecvt_base::partial); - } - this->setp(__pb_save, __epb_save); - } - return traits_type::not_eof(__c); -} - -template -basic_streambuf<_Elem, _Tr>* -wbuffer_convert<_Codecvt, _Elem, _Tr>::setbuf(char_type* __s, streamsize __n) -{ - this->setg(0, 0, 0); - this->setp(0, 0); - if (__owns_eb_) - delete [] __extbuf_; - if (__owns_ib_) - delete [] __intbuf_; - __ebs_ = __n; - if (__ebs_ > sizeof(__extbuf_min_)) - { - if (__always_noconv_ && __s) - { - __extbuf_ = (char*)__s; - __owns_eb_ = false; - } - else - { - __extbuf_ = new char[__ebs_]; - __owns_eb_ = true; - } - } - else - { - __extbuf_ = __extbuf_min_; - __ebs_ = sizeof(__extbuf_min_); - __owns_eb_ = false; - } - if (!__always_noconv_) - { - __ibs_ = max(__n, sizeof(__extbuf_min_)); - if (__s && __ibs_ >= sizeof(__extbuf_min_)) - { - __intbuf_ = __s; - __owns_ib_ = false; - } - else - { - __intbuf_ = new char_type[__ibs_]; - __owns_ib_ = true; - } - } - else - { - __ibs_ = 0; - __intbuf_ = 0; - __owns_ib_ = false; - } - return this; -} - -template -typename wbuffer_convert<_Codecvt, _Elem, _Tr>::pos_type -wbuffer_convert<_Codecvt, _Elem, _Tr>::seekoff(off_type __off, ios_base::seekdir __way, - ios_base::openmode __om) -{ - int __width = __cv_->encoding(); - if (__cv_ == 0 || __bufptr_ == 0 || (__width <= 0 && __off != 0) || sync()) - return pos_type(off_type(-1)); - // __width > 0 || __off == 0 - switch (__way) - { - case ios_base::beg: - break; - case ios_base::cur: - break; - case ios_base::end: - break; - default: - return pos_type(off_type(-1)); - } - pos_type __r = __bufptr_->pubseekoff(__width * __off, __way, __om); - __r.state(__st_); - return __r; -} - -template -typename wbuffer_convert<_Codecvt, _Elem, _Tr>::pos_type -wbuffer_convert<_Codecvt, _Elem, _Tr>::seekpos(pos_type __sp, ios_base::openmode __wch) -{ - if (__cv_ == 0 || __bufptr_ == 0 || sync()) - return pos_type(off_type(-1)); - if (__bufptr_->pubseekpos(__sp, __wch) == pos_type(off_type(-1))) - return pos_type(off_type(-1)); - return __sp; -} - -template -int -wbuffer_convert<_Codecvt, _Elem, _Tr>::sync() -{ - if (__cv_ == 0 || __bufptr_ == 0) - return 0; - if (__cm_ & ios_base::out) - { - if (this->pptr() != this->pbase()) - if (overflow() == traits_type::eof()) - return -1; - codecvt_base::result __r; - do - { - char* __extbe; - __r = __cv_->unshift(__st_, __extbuf_, __extbuf_ + __ebs_, __extbe); - streamsize __nmemb = static_cast(__extbe - __extbuf_); - if (__bufptr_->sputn(__extbuf_, __nmemb) != __nmemb) - return -1; - } while (__r == codecvt_base::partial); - if (__r == codecvt_base::error) - return -1; - if (__bufptr_->pubsync()) - return -1; - } - else if (__cm_ & ios_base::in) - { - off_type __c; - if (__always_noconv_) - __c = this->egptr() - this->gptr(); - else - { - int __width = __cv_->encoding(); - __c = __extbufend_ - __extbufnext_; - if (__width > 0) - __c += __width * (this->egptr() - this->gptr()); - else - { - if (this->gptr() != this->egptr()) - { - reverse(this->gptr(), this->egptr()); - codecvt_base::result __r; - const char_type* __e = this->gptr(); - char* __extbe; - do - { - __r = __cv_->out(__st_, __e, this->egptr(), __e, - __extbuf_, __extbuf_ + __ebs_, __extbe); - switch (__r) - { - case codecvt_base::noconv: - __c += this->egptr() - this->gptr(); - break; - case codecvt_base::ok: - case codecvt_base::partial: - __c += __extbe - __extbuf_; - break; - default: - return -1; - } - } while (__r == codecvt_base::partial); - } - } - } - if (__bufptr_->pubseekoff(-__c, ios_base::cur, __cm_) == pos_type(off_type(-1))) - return -1; - this->setg(0, 0, 0); - __cm_ = 0; - } - return 0; -} - -template -bool -wbuffer_convert<_Codecvt, _Elem, _Tr>::__read_mode() -{ - if (!(__cm_ & ios_base::in)) - { - this->setp(0, 0); - if (__always_noconv_) - this->setg((char_type*)__extbuf_, - (char_type*)__extbuf_ + __ebs_, - (char_type*)__extbuf_ + __ebs_); - else - this->setg(__intbuf_, __intbuf_ + __ibs_, __intbuf_ + __ibs_); - __cm_ = ios_base::in; - return true; - } - return false; -} - -template -void -wbuffer_convert<_Codecvt, _Elem, _Tr>::__write_mode() -{ - if (!(__cm_ & ios_base::out)) - { - this->setg(0, 0, 0); - if (__ebs_ > sizeof(__extbuf_min_)) - { - if (__always_noconv_) - this->setp((char_type*)__extbuf_, - (char_type*)__extbuf_ + (__ebs_ - 1)); - else - this->setp(__intbuf_, __intbuf_ + (__ibs_ - 1)); - } - else - this->setp(0, 0); - __cm_ = ios_base::out; - } -} - -template -wbuffer_convert<_Codecvt, _Elem, _Tr>* -wbuffer_convert<_Codecvt, _Elem, _Tr>::__close() -{ - wbuffer_convert* __rt = 0; - if (__cv_ != 0 && __bufptr_ != 0) - { - __rt = this; - if ((__cm_ & ios_base::out) && sync()) - __rt = 0; - } - return __rt; -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_LOCALE diff --git a/libcxx/include/map b/libcxx/include/map deleted file mode 100644 index 633579b7ee06..000000000000 --- a/libcxx/include/map +++ /dev/null @@ -1,1935 +0,0 @@ -// -*- C++ -*- -//===----------------------------- map ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_MAP -#define _LIBCPP_MAP - -/* - - map synopsis - -namespace std -{ - -template , - class Allocator = allocator>> -class map -{ -public: - // types: - typedef Key key_type; - typedef T mapped_type; - typedef pair value_type; - typedef Compare key_compare; - typedef Allocator allocator_type; - typedef typename allocator_type::reference reference; - typedef typename allocator_type::const_reference const_reference; - typedef typename allocator_type::pointer pointer; - typedef typename allocator_type::const_pointer const_pointer; - typedef typename allocator_type::size_type size_type; - typedef typename allocator_type::difference_type difference_type; - - typedef implementation-defined iterator; - typedef implementation-defined const_iterator; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - class value_compare - : public binary_function - { - friend class map; - protected: - key_compare comp; - - value_compare(key_compare c); - public: - bool operator()(const value_type& x, const value_type& y) const; - }; - - // construct/copy/destroy: - map() - noexcept( - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value && - is_nothrow_copy_constructible::value); - explicit map(const key_compare& comp); - map(const key_compare& comp, const allocator_type& a); - template - map(InputIterator first, InputIterator last, - const key_compare& comp = key_compare()); - template - map(InputIterator first, InputIterator last, - const key_compare& comp, const allocator_type& a); - map(const map& m); - map(map&& m) - noexcept( - is_nothrow_move_constructible::value && - is_nothrow_move_constructible::value); - explicit map(const allocator_type& a); - map(const map& m, const allocator_type& a); - map(map&& m, const allocator_type& a); - map(initializer_list il, const key_compare& comp = key_compare()); - map(initializer_list il, const key_compare& comp, const allocator_type& a); - ~map(); - - map& operator=(const map& m); - map& operator=(map&& m) - noexcept( - allocator_type::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value); - map& operator=(initializer_list il); - - // iterators: - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - - reverse_iterator rbegin() noexcept; - const_reverse_iterator rbegin() const noexcept; - reverse_iterator rend() noexcept; - const_reverse_iterator rend() const noexcept; - - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - const_reverse_iterator crbegin() const noexcept; - const_reverse_iterator crend() const noexcept; - - // capacity: - bool empty() const noexcept; - size_type size() const noexcept; - size_type max_size() const noexcept; - - // element access: - mapped_type& operator[](const key_type& k); - mapped_type& operator[](key_type&& k); - - mapped_type& at(const key_type& k); - const mapped_type& at(const key_type& k) const; - - // modifiers: - template - pair emplace(Args&&... args); - template - iterator emplace_hint(const_iterator position, Args&&... args); - pair insert(const value_type& v); - template - pair insert(P&& p); - iterator insert(const_iterator position, const value_type& v); - template - iterator insert(const_iterator position, P&& p); - template - void insert(InputIterator first, InputIterator last); - void insert(initializer_list il); - - iterator erase(const_iterator position); - size_type erase(const key_type& k); - iterator erase(const_iterator first, const_iterator last); - void clear() noexcept; - - void swap(map& m) - noexcept( - __is_nothrow_swappable::value && - (!allocator_type::propagate_on_container_swap::value || - __is_nothrow_swappable::value)); - - // observers: - allocator_type get_allocator() const noexcept; - key_compare key_comp() const; - value_compare value_comp() const; - - // map operations: - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - iterator lower_bound(const key_type& k); - const_iterator lower_bound(const key_type& k) const; - iterator upper_bound(const key_type& k); - const_iterator upper_bound(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; -}; - -template -bool -operator==(const map& x, - const map& y); - -template -bool -operator< (const map& x, - const map& y); - -template -bool -operator!=(const map& x, - const map& y); - -template -bool -operator> (const map& x, - const map& y); - -template -bool -operator>=(const map& x, - const map& y); - -template -bool -operator<=(const map& x, - const map& y); - -// specialized algorithms: -template -void -swap(map& x, map& y) - noexcept(noexcept(x.swap(y))); - -template , - class Allocator = allocator>> -class multimap -{ -public: - // types: - typedef Key key_type; - typedef T mapped_type; - typedef pair value_type; - typedef Compare key_compare; - typedef Allocator allocator_type; - typedef typename allocator_type::reference reference; - typedef typename allocator_type::const_reference const_reference; - typedef typename allocator_type::size_type size_type; - typedef typename allocator_type::difference_type difference_type; - typedef typename allocator_type::pointer pointer; - typedef typename allocator_type::const_pointer const_pointer; - - typedef implementation-defined iterator; - typedef implementation-defined const_iterator; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - class value_compare - : public binary_function - { - friend class multimap; - protected: - key_compare comp; - value_compare(key_compare c); - public: - bool operator()(const value_type& x, const value_type& y) const; - }; - - // construct/copy/destroy: - multimap() - noexcept( - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value && - is_nothrow_copy_constructible::value); - explicit multimap(const key_compare& comp); - multimap(const key_compare& comp, const allocator_type& a); - template - multimap(InputIterator first, InputIterator last, const key_compare& comp); - template - multimap(InputIterator first, InputIterator last, const key_compare& comp, - const allocator_type& a); - multimap(const multimap& m); - multimap(multimap&& m) - noexcept( - is_nothrow_move_constructible::value && - is_nothrow_move_constructible::value); - explicit multimap(const allocator_type& a); - multimap(const multimap& m, const allocator_type& a); - multimap(multimap&& m, const allocator_type& a); - multimap(initializer_list il, const key_compare& comp = key_compare()); - multimap(initializer_list il, const key_compare& comp, - const allocator_type& a); - ~multimap(); - - multimap& operator=(const multimap& m); - multimap& operator=(multimap&& m) - noexcept( - allocator_type::propagate_on_container_move_assignment::value && - is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value); - multimap& operator=(initializer_list il); - - // iterators: - iterator begin() noexcept; - const_iterator begin() const noexcept; - iterator end() noexcept; - const_iterator end() const noexcept; - - reverse_iterator rbegin() noexcept; - const_reverse_iterator rbegin() const noexcept; - reverse_iterator rend() noexcept; - const_reverse_iterator rend() const noexcept; - - const_iterator cbegin() const noexcept; - const_iterator cend() const noexcept; - const_reverse_iterator crbegin() const noexcept; - const_reverse_iterator crend() const noexcept; - - // capacity: - bool empty() const noexcept; - size_type size() const noexcept; - size_type max_size() const noexcept; - - // modifiers: - template - iterator emplace(Args&&... args); - template - iterator emplace_hint(const_iterator position, Args&&... args); - iterator insert(const value_type& v); - template - iterator insert(P&& p); - iterator insert(const_iterator position, const value_type& v); - template - iterator insert(const_iterator position, P&& p); - template - void insert(InputIterator first, InputIterator last); - void insert(initializer_list il); - - iterator erase(const_iterator position); - size_type erase(const key_type& k); - iterator erase(const_iterator first, const_iterator last); - void clear() noexcept; - - void swap(multimap& m) - noexcept( - __is_nothrow_swappable::value && - (!allocator_type::propagate_on_container_swap::value || - __is_nothrow_swappable::value)); - - // observers: - allocator_type get_allocator() const noexcept; - key_compare key_comp() const; - value_compare value_comp() const; - - // map operations: - iterator find(const key_type& k); - const_iterator find(const key_type& k) const; - size_type count(const key_type& k) const; - iterator lower_bound(const key_type& k); - const_iterator lower_bound(const key_type& k) const; - iterator upper_bound(const key_type& k); - const_iterator upper_bound(const key_type& k) const; - pair equal_range(const key_type& k); - pair equal_range(const key_type& k) const; -}; - -template -bool -operator==(const multimap& x, - const multimap& y); - -template -bool -operator< (const multimap& x, - const multimap& y); - -template -bool -operator!=(const multimap& x, - const multimap& y); - -template -bool -operator> (const multimap& x, - const multimap& y); - -template -bool -operator>=(const multimap& x, - const multimap& y); - -template -bool -operator<=(const multimap& x, - const multimap& y); - -// specialized algorithms: -template -void -swap(multimap& x, - multimap& y) - noexcept(noexcept(x.swap(y))); - -} // std - -*/ - -#include <__config> -#include <__tree> -#include -#include -#include -#include -#include - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -template ::value -#if __has_feature(is_final) - && !__is_final(_Compare) -#endif - > -class __map_value_compare - : private _Compare -{ - typedef pair::type, _Tp> _Pp; - typedef pair _CP; -public: - _LIBCPP_INLINE_VISIBILITY - __map_value_compare() - _NOEXCEPT_(is_nothrow_default_constructible<_Compare>::value) - : _Compare() {} - _LIBCPP_INLINE_VISIBILITY - __map_value_compare(_Compare c) - _NOEXCEPT_(is_nothrow_copy_constructible<_Compare>::value) - : _Compare(c) {} - _LIBCPP_INLINE_VISIBILITY - const _Compare& key_comp() const _NOEXCEPT {return *this;} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _CP& __y) const - {return static_cast(*this)(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _Pp& __y) const - {return static_cast(*this)(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _Key& __y) const - {return static_cast(*this)(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _CP& __y) const - {return static_cast(*this)(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _Pp& __y) const - {return static_cast(*this)(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _Key& __y) const - {return static_cast(*this)(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _CP& __y) const - {return static_cast(*this)(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _Pp& __y) const - {return static_cast(*this)(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _Key& __y) const - {return static_cast(*this)(__x, __y);} -}; - -template -class __map_value_compare<_Key, _Tp, _Compare, false> -{ - _Compare comp; - - typedef pair::type, _Tp> _Pp; - typedef pair _CP; - -public: - _LIBCPP_INLINE_VISIBILITY - __map_value_compare() - _NOEXCEPT_(is_nothrow_default_constructible<_Compare>::value) - : comp() {} - _LIBCPP_INLINE_VISIBILITY - __map_value_compare(_Compare c) - _NOEXCEPT_(is_nothrow_copy_constructible<_Compare>::value) - : comp(c) {} - _LIBCPP_INLINE_VISIBILITY - const _Compare& key_comp() const _NOEXCEPT {return comp;} - - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _CP& __y) const - {return comp(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _Pp& __y) const - {return comp(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _CP& __x, const _Key& __y) const - {return comp(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _CP& __y) const - {return comp(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _Pp& __y) const - {return comp(__x.first, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Pp& __x, const _Key& __y) const - {return comp(__x.first, __y);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _CP& __y) const - {return comp(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _Pp& __y) const - {return comp(__x, __y.first);} - _LIBCPP_INLINE_VISIBILITY - bool operator()(const _Key& __x, const _Key& __y) const - {return comp(__x, __y);} -}; - -template -class __map_node_destructor -{ - typedef _Allocator allocator_type; - typedef allocator_traits __alloc_traits; - typedef typename __alloc_traits::value_type::value_type value_type; -public: - typedef typename __alloc_traits::pointer pointer; -private: - typedef typename value_type::first_type first_type; - typedef typename value_type::second_type second_type; - - allocator_type& __na_; - - __map_node_destructor& operator=(const __map_node_destructor&); - -public: - bool __first_constructed; - bool __second_constructed; - - _LIBCPP_INLINE_VISIBILITY - explicit __map_node_destructor(allocator_type& __na) _NOEXCEPT - : __na_(__na), - __first_constructed(false), - __second_constructed(false) - {} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY - __map_node_destructor(__tree_node_destructor&& __x) _NOEXCEPT - : __na_(__x.__na_), - __first_constructed(__x.__value_constructed), - __second_constructed(__x.__value_constructed) - { - __x.__value_constructed = false; - } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - void operator()(pointer __p) _NOEXCEPT - { - if (__second_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_.second)); - if (__first_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_.first)); - if (__p) - __alloc_traits::deallocate(__na_, __p, 1); - } -}; - -template - class map; -template - class multimap; -template class __map_const_iterator; - -template -class _LIBCPP_VISIBLE __map_iterator -{ - _TreeIterator __i_; - - typedef typename _TreeIterator::__pointer_traits __pointer_traits; - typedef const typename _TreeIterator::value_type::first_type __key_type; - typedef typename _TreeIterator::value_type::second_type __mapped_type; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef pair<__key_type, __mapped_type> value_type; - typedef typename _TreeIterator::difference_type difference_type; - typedef value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY - __map_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - __map_iterator(_TreeIterator __i) _NOEXCEPT : __i_(__i) {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return *operator->();} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return (pointer)__i_.operator->();} - - _LIBCPP_INLINE_VISIBILITY - __map_iterator& operator++() {++__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __map_iterator operator++(int) - { - __map_iterator __t(*this); - ++(*this); - return __t; - } - - _LIBCPP_INLINE_VISIBILITY - __map_iterator& operator--() {--__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __map_iterator operator--(int) - { - __map_iterator __t(*this); - --(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __map_iterator& __x, const __map_iterator& __y) - {return __x.__i_ == __y.__i_;} - friend - _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __map_iterator& __x, const __map_iterator& __y) - {return __x.__i_ != __y.__i_;} - - template friend class _LIBCPP_VISIBLE map; - template friend class _LIBCPP_VISIBLE multimap; - template friend class _LIBCPP_VISIBLE __map_const_iterator; -}; - -template -class _LIBCPP_VISIBLE __map_const_iterator -{ - _TreeIterator __i_; - - typedef typename _TreeIterator::__pointer_traits __pointer_traits; - typedef const typename _TreeIterator::value_type::first_type __key_type; - typedef typename _TreeIterator::value_type::second_type __mapped_type; -public: - typedef bidirectional_iterator_tag iterator_category; - typedef pair<__key_type, __mapped_type> value_type; - typedef typename _TreeIterator::difference_type difference_type; - typedef const value_type& reference; - typedef typename __pointer_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind -#else - rebind::other -#endif - pointer; - - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator() _NOEXCEPT {} - - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator(_TreeIterator __i) _NOEXCEPT : __i_(__i) {} - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator( - __map_iterator __i) - _NOEXCEPT - : __i_(__i.__i_) {} - - _LIBCPP_INLINE_VISIBILITY - reference operator*() const {return *operator->();} - _LIBCPP_INLINE_VISIBILITY - pointer operator->() const {return (pointer)__i_.operator->();} - - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator& operator++() {++__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator operator++(int) - { - __map_const_iterator __t(*this); - ++(*this); - return __t; - } - - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator& operator--() {--__i_; return *this;} - _LIBCPP_INLINE_VISIBILITY - __map_const_iterator operator--(int) - { - __map_const_iterator __t(*this); - --(*this); - return __t; - } - - friend _LIBCPP_INLINE_VISIBILITY - bool operator==(const __map_const_iterator& __x, const __map_const_iterator& __y) - {return __x.__i_ == __y.__i_;} - friend _LIBCPP_INLINE_VISIBILITY - bool operator!=(const __map_const_iterator& __x, const __map_const_iterator& __y) - {return __x.__i_ != __y.__i_;} - - template friend class _LIBCPP_VISIBLE map; - template friend class _LIBCPP_VISIBLE multimap; - template friend class _LIBCPP_VISIBLE __tree_const_iterator; -}; - -template , - class _Allocator = allocator > > -class _LIBCPP_VISIBLE map -{ -public: - // types: - typedef _Key key_type; - typedef _Tp mapped_type; - typedef pair value_type; - typedef _Compare key_compare; - typedef _Allocator allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - - class _LIBCPP_VISIBLE value_compare - : public binary_function - { - friend class map; - protected: - key_compare comp; - - _LIBCPP_INLINE_VISIBILITY value_compare(key_compare c) : comp(c) {} - public: - _LIBCPP_INLINE_VISIBILITY - bool operator()(const value_type& __x, const value_type& __y) const - {return comp(__x.first, __y.first);} - }; - -private: - typedef pair __value_type; - typedef __map_value_compare __vc; - typedef typename allocator_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__value_type> -#else - rebind_alloc<__value_type>::other -#endif - __allocator_type; - typedef __tree<__value_type, __vc, __allocator_type> __base; - typedef typename __base::__node_traits __node_traits; - typedef allocator_traits __alloc_traits; - - __base __tree_; - -public: - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - typedef __map_iterator iterator; - typedef __map_const_iterator const_iterator; - typedef _VSTD::reverse_iterator reverse_iterator; - typedef _VSTD::reverse_iterator const_reverse_iterator; - - _LIBCPP_INLINE_VISIBILITY - explicit map(const key_compare& __comp = key_compare()) - _NOEXCEPT_( - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value && - is_nothrow_copy_constructible::value) - : __tree_(__vc(__comp)) {} - - _LIBCPP_INLINE_VISIBILITY - explicit map(const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) {} - - template - _LIBCPP_INLINE_VISIBILITY - map(_InputIterator __f, _InputIterator __l, - const key_compare& __comp = key_compare()) - : __tree_(__vc(__comp)) - { - insert(__f, __l); - } - - template - _LIBCPP_INLINE_VISIBILITY - map(_InputIterator __f, _InputIterator __l, - const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) - { - insert(__f, __l); - } - - _LIBCPP_INLINE_VISIBILITY - map(const map& __m) - : __tree_(__m.__tree_) - { - insert(__m.begin(), __m.end()); - } - - _LIBCPP_INLINE_VISIBILITY - map& operator=(const map& __m) - { - __tree_ = __m.__tree_; - return *this; - } - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - map(map&& __m) - _NOEXCEPT_(is_nothrow_move_constructible<__base>::value) - : __tree_(_VSTD::move(__m.__tree_)) - { - } - - map(map&& __m, const allocator_type& __a); - - _LIBCPP_INLINE_VISIBILITY - map& operator=(map&& __m) - _NOEXCEPT_(is_nothrow_move_assignable<__base>::value) - { - __tree_ = _VSTD::move(__m.__tree_); - return *this; - } - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - map(initializer_list __il, const key_compare& __comp = key_compare()) - : __tree_(__vc(__comp)) - { - insert(__il.begin(), __il.end()); - } - - _LIBCPP_INLINE_VISIBILITY - map(initializer_list __il, const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) - { - insert(__il.begin(), __il.end()); - } - - _LIBCPP_INLINE_VISIBILITY - map& operator=(initializer_list __il) - { - __tree_.__assign_unique(__il.begin(), __il.end()); - return *this; - } - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - explicit map(const allocator_type& __a) - : __tree_(__a) - { - } - - _LIBCPP_INLINE_VISIBILITY - map(const map& __m, const allocator_type& __a) - : __tree_(__m.__tree_.value_comp(), __a) - { - insert(__m.begin(), __m.end()); - } - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return __tree_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return __tree_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return __tree_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return __tree_.end();} - - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rbegin() _NOEXCEPT {return reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rbegin() const _NOEXCEPT - {return const_reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rend() _NOEXCEPT - {return reverse_iterator(begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rend() const _NOEXCEPT - {return const_reverse_iterator(begin());} - - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT {return begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT {return end();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crbegin() const _NOEXCEPT {return rbegin();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crend() const _NOEXCEPT {return rend();} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return __tree_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return __tree_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT {return __tree_.max_size();} - - mapped_type& operator[](const key_type& __k); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - mapped_type& operator[](key_type&& __k); -#endif - - mapped_type& at(const key_type& __k); - const mapped_type& at(const key_type& __k) const; - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const _NOEXCEPT {return __tree_.__alloc();} - _LIBCPP_INLINE_VISIBILITY - key_compare key_comp() const {return __tree_.value_comp().key_comp();} - _LIBCPP_INLINE_VISIBILITY - value_compare value_comp() const {return value_compare(__tree_.value_comp().key_comp());} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - pair - emplace() {return __tree_.__emplace_unique();} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - pair - emplace(_A0&& __a0) - {return __tree_.__emplace_unique(_VSTD::forward<_A0>(__a0));} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - pair - emplace(_A0&& __a0, _Args&& ...__args); - -#endif // _LIBCPP_HAS_NO_VARIADICS - - _LIBCPP_INLINE_VISIBILITY - iterator - emplace_hint(const_iterator __p) - {return __tree_.__emplace_hint_unique(__p.__i_);} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator - emplace_hint(const_iterator __p, _A0&& __a0) - {return __tree_.__emplace_hint_unique(__p.__i_, _VSTD::forward<_A0>(__a0));} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - iterator - emplace_hint(const_iterator __p, _A0&& __a0, _Args&& ...__args); - -#endif // _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - pair insert(_Pp&& __p) - {return __tree_.__insert_unique(_VSTD::forward<_Pp>(__p));} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator __pos, _Pp&& __p) - {return __tree_.__insert_unique(__pos.__i_, _VSTD::forward<_Pp>(__p));} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - pair - insert(const value_type& __v) {return __tree_.__insert_unique(__v);} - - _LIBCPP_INLINE_VISIBILITY - iterator - insert(const_iterator __p, const value_type& __v) - {return __tree_.__insert_unique(__p.__i_, __v);} - - template - _LIBCPP_INLINE_VISIBILITY - void insert(_InputIterator __f, _InputIterator __l) - { - for (const_iterator __e = cend(); __f != __l; ++__f) - insert(__e.__i_, *__f); - } - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - void insert(initializer_list __il) - {insert(__il.begin(), __il.end());} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - iterator erase(const_iterator __p) {return __tree_.erase(__p.__i_);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) - {return __tree_.__erase_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator erase(const_iterator __f, const_iterator __l) - {return __tree_.erase(__f.__i_, __l.__i_);} - _LIBCPP_INLINE_VISIBILITY - void clear() _NOEXCEPT {__tree_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(map& __m) - _NOEXCEPT_(__is_nothrow_swappable<__base>::value) - {__tree_.swap(__m.__tree_);} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __tree_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __tree_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const - {return __tree_.__count_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator lower_bound(const key_type& __k) - {return __tree_.lower_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator lower_bound(const key_type& __k) const - {return __tree_.lower_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator upper_bound(const key_type& __k) - {return __tree_.upper_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator upper_bound(const key_type& __k) const - {return __tree_.upper_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __tree_.__equal_range_unique(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __tree_.__equal_range_unique(__k);} - -private: - typedef typename __base::__node __node; - typedef typename __base::__node_allocator __node_allocator; - typedef typename __base::__node_pointer __node_pointer; - typedef typename __base::__node_const_pointer __node_const_pointer; - typedef typename __base::__node_base_pointer __node_base_pointer; - typedef typename __base::__node_base_const_pointer __node_base_const_pointer; - typedef __map_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __node_holder __construct_node(); - template ::value>::type> - __node_holder __construct_node(_A0&& __a0); -#ifndef _LIBCPP_HAS_NO_VARIADICS - template ::value>::type> - __node_holder __construct_node(_A0&& __a0, _Args&& ...__args); -#endif // _LIBCPP_HAS_NO_VARIADICS -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - __node_holder __construct_node(const key_type& __k); -#endif - - __node_base_pointer& - __find_equal_key(__node_base_pointer& __parent, const key_type& __k); - __node_base_pointer& - __find_equal_key(const_iterator __hint, - __node_base_pointer& __parent, const key_type& __k); - __node_base_const_pointer - __find_equal_key(__node_base_const_pointer& __parent, const key_type& __k) const; -}; - -// Find place to insert if __k doesn't exist -// Set __parent to parent of null leaf -// Return reference to null leaf -// If __k exists, set parent to node of __k and return reference to node of __k -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_base_pointer& -map<_Key, _Tp, _Compare, _Allocator>::__find_equal_key(__node_base_pointer& __parent, - const key_type& __k) -{ - __node_pointer __nd = __tree_.__root(); - if (__nd != nullptr) - { - while (true) - { - if (__tree_.value_comp().key_comp()(__k, __nd->__value_.first)) - { - if (__nd->__left_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__left_); - else - { - __parent = __nd; - return __parent->__left_; - } - } - else if (__tree_.value_comp().key_comp()(__nd->__value_.first, __k)) - { - if (__nd->__right_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__right_); - else - { - __parent = __nd; - return __parent->__right_; - } - } - else - { - __parent = __nd; - return __parent; - } - } - } - __parent = __tree_.__end_node(); - return __parent->__left_; -} - -// Find place to insert if __k doesn't exist -// First check prior to __hint. -// Next check after __hint. -// Next do O(log N) search. -// Set __parent to parent of null leaf -// Return reference to null leaf -// If __k exists, set parent to node of __k and return reference to node of __k -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_base_pointer& -map<_Key, _Tp, _Compare, _Allocator>::__find_equal_key(const_iterator __hint, - __node_base_pointer& __parent, - const key_type& __k) -{ - if (__hint == end() || __tree_.value_comp().key_comp()(__k, __hint->first)) // check before - { - // __k < *__hint - const_iterator __prior = __hint; - if (__prior == begin() || __tree_.value_comp().key_comp()((--__prior)->first, __k)) - { - // *prev(__hint) < __k < *__hint - if (__hint.__ptr_->__left_ == nullptr) - { - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent->__left_; - } - else - { - __parent = const_cast<__node_pointer&>(__prior.__ptr_); - return __parent->__right_; - } - } - // __k <= *prev(__hint) - return __find_equal_key(__parent, __k); - } - else if (__tree_.value_comp().key_comp()(__hint->first, __k)) // check after - { - // *__hint < __k - const_iterator __next = _VSTD::next(__hint); - if (__next == end() || __tree_.value_comp().key_comp()(__k, __next->first)) - { - // *__hint < __k < *next(__hint) - if (__hint.__ptr_->__right_ == nullptr) - { - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent->__right_; - } - else - { - __parent = const_cast<__node_pointer&>(__next.__ptr_); - return __parent->__left_; - } - } - // *next(__hint) <= __k - return __find_equal_key(__parent, __k); - } - // else __k == *__hint - __parent = const_cast<__node_pointer&>(__hint.__ptr_); - return __parent; -} - -// Find __k -// Set __parent to parent of null leaf and -// return reference to null leaf iv __k does not exist. -// If __k exists, set parent to node of __k and return reference to node of __k -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_base_const_pointer -map<_Key, _Tp, _Compare, _Allocator>::__find_equal_key(__node_base_const_pointer& __parent, - const key_type& __k) const -{ - __node_const_pointer __nd = __tree_.__root(); - if (__nd != nullptr) - { - while (true) - { - if (__tree_.value_comp().key_comp()(__k, __nd->__value_.first)) - { - if (__nd->__left_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__left_); - else - { - __parent = __nd; - return const_cast(__parent->__left_); - } - } - else if (__tree_.value_comp().key_comp()(__nd->__value_.first, __k)) - { - if (__nd->__right_ != nullptr) - __nd = static_cast<__node_pointer>(__nd->__right_); - else - { - __parent = __nd; - return const_cast(__parent->__right_); - } - } - else - { - __parent = __nd; - return __parent; - } - } - } - __parent = __tree_.__end_node(); - return const_cast(__parent->__left_); -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -map<_Key, _Tp, _Compare, _Allocator>::map(map&& __m, const allocator_type& __a) - : __tree_(_VSTD::move(__m.__tree_), __a) -{ - if (__a != __m.get_allocator()) - { - const_iterator __e = cend(); - while (!__m.empty()) - __tree_.__insert_unique(__e.__i_, - _VSTD::move(__m.__tree_.remove(__m.begin().__i_)->__value_)); - } -} - -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_holder -map<_Key, _Tp, _Compare, _Allocator>::__construct_node() -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first)); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second)); - __h.get_deleter().__second_constructed = true; - return __h; -} - -template -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_holder -map<_Key, _Tp, _Compare, _Allocator>::__construct_node(_A0&& __a0) -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), _VSTD::forward<_A0>(__a0)); - __h.get_deleter().__first_constructed = true; - __h.get_deleter().__second_constructed = true; - return __h; -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_holder -map<_Key, _Tp, _Compare, _Allocator>::__construct_node(_A0&& __a0, _Args&& ...__args) -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first), _VSTD::forward<_A0>(__a0)); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second), _VSTD::forward<_Args>(__args)...); - __h.get_deleter().__second_constructed = true; - return __h; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS - -#else // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -typename map<_Key, _Tp, _Compare, _Allocator>::__node_holder -map<_Key, _Tp, _Compare, _Allocator>::__construct_node(const key_type& __k) -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first), __k); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second)); - __h.get_deleter().__second_constructed = true; - return _VSTD::move(__h); -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_Tp& -map<_Key, _Tp, _Compare, _Allocator>::operator[](const key_type& __k) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal_key(__parent, __k); - __node_pointer __r = static_cast<__node_pointer>(__child); - if (__child == nullptr) - { - __node_holder __h = __construct_node(__k); - __tree_.__insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - } - return __r->__value_.second; -} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_Tp& -map<_Key, _Tp, _Compare, _Allocator>::operator[](key_type&& __k) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal_key(__parent, __k); - __node_pointer __r = static_cast<__node_pointer>(__child); - if (__child == nullptr) - { - __node_holder __h = __construct_node(_VSTD::move(__k)); - __tree_.__insert_node_at(__parent, __child, __h.get()); - __r = __h.release(); - } - return __r->__value_.second; -} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -_Tp& -map<_Key, _Tp, _Compare, _Allocator>::at(const key_type& __k) -{ - __node_base_pointer __parent; - __node_base_pointer& __child = __find_equal_key(__parent, __k); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__child == nullptr) - throw out_of_range("map::at: key not found"); -#endif // _LIBCPP_NO_EXCEPTIONS - return static_cast<__node_pointer>(__child)->__value_.second; -} - -template -const _Tp& -map<_Key, _Tp, _Compare, _Allocator>::at(const key_type& __k) const -{ - __node_base_const_pointer __parent; - __node_base_const_pointer __child = __find_equal_key(__parent, __k); -#ifndef _LIBCPP_NO_EXCEPTIONS - if (__child == nullptr) - throw out_of_range("map::at: key not found"); -#endif // _LIBCPP_NO_EXCEPTIONS - return static_cast<__node_const_pointer>(__child)->__value_.second; -} - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - -template -template ::value>::type - > -pair::iterator, bool> -map<_Key, _Tp, _Compare, _Allocator>::emplace(_A0&& __a0, _Args&& ...__args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_A0>(__a0), - _VSTD::forward<_Args>(__args)...); - pair __r = __tree_.__node_insert_unique(__h.get()); - if (__r.second) - __h.release(); - return __r; -} - -template -template ::value>::type - > -typename map<_Key, _Tp, _Compare, _Allocator>::iterator -map<_Key, _Tp, _Compare, _Allocator>::emplace_hint(const_iterator __p, - _A0&& __a0, _Args&& ...__args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_A0>(__a0), - _VSTD::forward<_Args>(__args)...); - iterator __r = __tree_.__node_insert_unique(__p.__i_, __h.get()); - if (__r.__i_.__ptr_ == __h.get()) - __h.release(); - return __r; -} - -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return __x.size() == __y.size() && _VSTD::equal(__x.begin(), __x.end(), __y.begin()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator< (const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return _VSTD::lexicographical_compare(__x.begin(), __x.end(), __y.begin(), __y.end()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator> (const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const map<_Key, _Tp, _Compare, _Allocator>& __x, - const map<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(map<_Key, _Tp, _Compare, _Allocator>& __x, - map<_Key, _Tp, _Compare, _Allocator>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -template , - class _Allocator = allocator > > -class _LIBCPP_VISIBLE multimap -{ -public: - // types: - typedef _Key key_type; - typedef _Tp mapped_type; - typedef pair value_type; - typedef _Compare key_compare; - typedef _Allocator allocator_type; - typedef value_type& reference; - typedef const value_type& const_reference; - - class _LIBCPP_VISIBLE value_compare - : public binary_function - { - friend class multimap; - protected: - key_compare comp; - - _LIBCPP_INLINE_VISIBILITY - value_compare(key_compare c) : comp(c) {} - public: - _LIBCPP_INLINE_VISIBILITY - bool operator()(const value_type& __x, const value_type& __y) const - {return comp(__x.first, __y.first);} - }; - -private: - typedef pair __value_type; - typedef __map_value_compare __vc; - typedef typename allocator_traits::template -#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES - rebind_alloc<__value_type> -#else - rebind_alloc<__value_type>::other -#endif - __allocator_type; - typedef __tree<__value_type, __vc, __allocator_type> __base; - typedef typename __base::__node_traits __node_traits; - typedef allocator_traits __alloc_traits; - - __base __tree_; - -public: - typedef typename __alloc_traits::pointer pointer; - typedef typename __alloc_traits::const_pointer const_pointer; - typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; - typedef __map_iterator iterator; - typedef __map_const_iterator const_iterator; - typedef _VSTD::reverse_iterator reverse_iterator; - typedef _VSTD::reverse_iterator const_reverse_iterator; - - _LIBCPP_INLINE_VISIBILITY - explicit multimap(const key_compare& __comp = key_compare()) - _NOEXCEPT_( - is_nothrow_default_constructible::value && - is_nothrow_default_constructible::value && - is_nothrow_copy_constructible::value) - : __tree_(__vc(__comp)) {} - - _LIBCPP_INLINE_VISIBILITY - explicit multimap(const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) {} - - template - _LIBCPP_INLINE_VISIBILITY - multimap(_InputIterator __f, _InputIterator __l, - const key_compare& __comp = key_compare()) - : __tree_(__vc(__comp)) - { - insert(__f, __l); - } - - template - _LIBCPP_INLINE_VISIBILITY - multimap(_InputIterator __f, _InputIterator __l, - const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) - { - insert(__f, __l); - } - - _LIBCPP_INLINE_VISIBILITY - multimap(const multimap& __m) - : __tree_(__m.__tree_.value_comp(), - __alloc_traits::select_on_container_copy_construction(__m.__tree_.__alloc())) - { - insert(__m.begin(), __m.end()); - } - - _LIBCPP_INLINE_VISIBILITY - multimap& operator=(const multimap& __m) - { - __tree_ = __m.__tree_; - return *this; - } - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - multimap(multimap&& __m) - _NOEXCEPT_(is_nothrow_move_constructible<__base>::value) - : __tree_(_VSTD::move(__m.__tree_)) - { - } - - multimap(multimap&& __m, const allocator_type& __a); - - _LIBCPP_INLINE_VISIBILITY - multimap& operator=(multimap&& __m) - _NOEXCEPT_(is_nothrow_move_assignable<__base>::value) - { - __tree_ = _VSTD::move(__m.__tree_); - return *this; - } - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - multimap(initializer_list __il, const key_compare& __comp = key_compare()) - : __tree_(__vc(__comp)) - { - insert(__il.begin(), __il.end()); - } - - _LIBCPP_INLINE_VISIBILITY - multimap(initializer_list __il, const key_compare& __comp, const allocator_type& __a) - : __tree_(__vc(__comp), __a) - { - insert(__il.begin(), __il.end()); - } - - _LIBCPP_INLINE_VISIBILITY - multimap& operator=(initializer_list __il) - { - __tree_.__assign_multi(__il.begin(), __il.end()); - return *this; - } - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - explicit multimap(const allocator_type& __a) - : __tree_(__a) - { - } - - _LIBCPP_INLINE_VISIBILITY - multimap(const multimap& __m, const allocator_type& __a) - : __tree_(__m.__tree_.value_comp(), __a) - { - insert(__m.begin(), __m.end()); - } - - _LIBCPP_INLINE_VISIBILITY - iterator begin() _NOEXCEPT {return __tree_.begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator begin() const _NOEXCEPT {return __tree_.begin();} - _LIBCPP_INLINE_VISIBILITY - iterator end() _NOEXCEPT {return __tree_.end();} - _LIBCPP_INLINE_VISIBILITY - const_iterator end() const _NOEXCEPT {return __tree_.end();} - - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rbegin() _NOEXCEPT {return reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rbegin() const _NOEXCEPT - {return const_reverse_iterator(end());} - _LIBCPP_INLINE_VISIBILITY - reverse_iterator rend() _NOEXCEPT {return reverse_iterator(begin());} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator rend() const _NOEXCEPT - {return const_reverse_iterator(begin());} - - _LIBCPP_INLINE_VISIBILITY - const_iterator cbegin() const _NOEXCEPT {return begin();} - _LIBCPP_INLINE_VISIBILITY - const_iterator cend() const _NOEXCEPT {return end();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crbegin() const _NOEXCEPT {return rbegin();} - _LIBCPP_INLINE_VISIBILITY - const_reverse_iterator crend() const _NOEXCEPT {return rend();} - - _LIBCPP_INLINE_VISIBILITY - bool empty() const _NOEXCEPT {return __tree_.size() == 0;} - _LIBCPP_INLINE_VISIBILITY - size_type size() const _NOEXCEPT {return __tree_.size();} - _LIBCPP_INLINE_VISIBILITY - size_type max_size() const _NOEXCEPT {return __tree_.max_size();} - - _LIBCPP_INLINE_VISIBILITY - allocator_type get_allocator() const _NOEXCEPT {return __tree_.__alloc();} - _LIBCPP_INLINE_VISIBILITY - key_compare key_comp() const {return __tree_.value_comp().key_comp();} - _LIBCPP_INLINE_VISIBILITY - value_compare value_comp() const - {return value_compare(__tree_.value_comp().key_comp());} - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - iterator emplace() {return __tree_.__emplace_multi();} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator - emplace(_A0&& __a0) - {return __tree_.__emplace_multi(_VSTD::forward<_A0>(__a0));} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - iterator - emplace(_A0&& __a0, _Args&& ...__args); - -#endif // _LIBCPP_HAS_NO_VARIADICS - - _LIBCPP_INLINE_VISIBILITY - iterator emplace_hint(const_iterator __p) - {return __tree_.__emplace_hint_multi(__p.__i_);} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator - emplace_hint(const_iterator __p, _A0&& __a0) - {return __tree_.__emplace_hint_multi(__p.__i_, _VSTD::forward<_A0>(__a0));} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - iterator - emplace_hint(const_iterator __p, _A0&& __a0, _Args&& ...__args); - -#endif // _LIBCPP_HAS_NO_VARIADICS - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator insert(_Pp&& __p) - {return __tree_.__insert_multi(_VSTD::forward<_Pp>(__p));} - - template ::value>::type> - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator __pos, _Pp&& __p) - {return __tree_.__insert_multi(__pos.__i_, _VSTD::forward<_Pp>(__p));} - -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - - _LIBCPP_INLINE_VISIBILITY - iterator insert(const value_type& __v) {return __tree_.__insert_multi(__v);} - - _LIBCPP_INLINE_VISIBILITY - iterator insert(const_iterator __p, const value_type& __v) - {return __tree_.__insert_multi(__p.__i_, __v);} - - template - _LIBCPP_INLINE_VISIBILITY - void insert(_InputIterator __f, _InputIterator __l) - { - for (const_iterator __e = cend(); __f != __l; ++__f) - __tree_.__insert_multi(__e.__i_, *__f); - } - -#ifndef _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - void insert(initializer_list __il) - {insert(__il.begin(), __il.end());} - -#endif // _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS - - _LIBCPP_INLINE_VISIBILITY - iterator erase(const_iterator __p) {return __tree_.erase(__p.__i_);} - _LIBCPP_INLINE_VISIBILITY - size_type erase(const key_type& __k) {return __tree_.__erase_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator erase(const_iterator __f, const_iterator __l) - {return __tree_.erase(__f.__i_, __l.__i_);} - _LIBCPP_INLINE_VISIBILITY - void clear() {__tree_.clear();} - - _LIBCPP_INLINE_VISIBILITY - void swap(multimap& __m) - _NOEXCEPT_(__is_nothrow_swappable<__base>::value) - {__tree_.swap(__m.__tree_);} - - _LIBCPP_INLINE_VISIBILITY - iterator find(const key_type& __k) {return __tree_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator find(const key_type& __k) const {return __tree_.find(__k);} - _LIBCPP_INLINE_VISIBILITY - size_type count(const key_type& __k) const - {return __tree_.__count_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator lower_bound(const key_type& __k) - {return __tree_.lower_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator lower_bound(const key_type& __k) const - {return __tree_.lower_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - iterator upper_bound(const key_type& __k) - {return __tree_.upper_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - const_iterator upper_bound(const key_type& __k) const - {return __tree_.upper_bound(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) - {return __tree_.__equal_range_multi(__k);} - _LIBCPP_INLINE_VISIBILITY - pair equal_range(const key_type& __k) const - {return __tree_.__equal_range_multi(__k);} - -private: - typedef typename __base::__node __node; - typedef typename __base::__node_allocator __node_allocator; - typedef typename __base::__node_pointer __node_pointer; - typedef typename __base::__node_const_pointer __node_const_pointer; - typedef __map_node_destructor<__node_allocator> _Dp; - typedef unique_ptr<__node, _Dp> __node_holder; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - __node_holder __construct_node(); - template ::value>::type> - __node_holder __construct_node(_A0&& __a0); -#ifndef _LIBCPP_HAS_NO_VARIADICS - template ::value>::type> - __node_holder __construct_node(_A0&& __a0, _Args&& ...__args); -#endif // _LIBCPP_HAS_NO_VARIADICS -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -}; - -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - -template -multimap<_Key, _Tp, _Compare, _Allocator>::multimap(multimap&& __m, const allocator_type& __a) - : __tree_(_VSTD::move(__m.__tree_), __a) -{ - if (__a != __m.get_allocator()) - { - const_iterator __e = cend(); - while (!__m.empty()) - __tree_.__insert_multi(__e.__i_, - _VSTD::move(__m.__tree_.remove(__m.begin().__i_)->__value_)); - } -} - -template -typename multimap<_Key, _Tp, _Compare, _Allocator>::__node_holder -multimap<_Key, _Tp, _Compare, _Allocator>::__construct_node() -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first)); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second)); - __h.get_deleter().__second_constructed = true; - return __h; -} - -template -template ::value>::type - > -typename multimap<_Key, _Tp, _Compare, _Allocator>::__node_holder -multimap<_Key, _Tp, _Compare, _Allocator>::__construct_node(_A0&& __a0) -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_), _VSTD::forward<_A0>(__a0)); - __h.get_deleter().__first_constructed = true; - __h.get_deleter().__second_constructed = true; - return __h; -} - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template -template ::value>::type - > -typename multimap<_Key, _Tp, _Compare, _Allocator>::__node_holder -multimap<_Key, _Tp, _Compare, _Allocator>::__construct_node(_A0&& __a0, _Args&& ...__args) -{ - __node_allocator& __na = __tree_.__node_alloc(); - __node_holder __h(__node_traits::allocate(__na, 1), _Dp(__na)); - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.first), _VSTD::forward<_A0>(__a0)); - __h.get_deleter().__first_constructed = true; - __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second), _VSTD::forward<_Args>(__args)...); - __h.get_deleter().__second_constructed = true; - return __h; -} - -#endif // _LIBCPP_HAS_NO_VARIADICS -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#if !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - -template -template ::value>::type - > -typename multimap<_Key, _Tp, _Compare, _Allocator>::iterator -multimap<_Key, _Tp, _Compare, _Allocator>::emplace(_A0&& __a0, _Args&& ...__args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_A0>(__a0), - _VSTD::forward<_Args>(__args)...); - iterator __r = __tree_.__node_insert_multi(__h.get()); - __h.release(); - return __r; -} - -template -template ::value>::type - > -typename multimap<_Key, _Tp, _Compare, _Allocator>::iterator -multimap<_Key, _Tp, _Compare, _Allocator>::emplace_hint(const_iterator __p, - _A0&& __a0, - _Args&& ...__args) -{ - __node_holder __h = __construct_node(_VSTD::forward<_A0>(__a0), - _VSTD::forward<_Args>(__args)...); - iterator __r = __tree_.__node_insert_multi(__p.__i_, __h.get()); - __h.release(); - return __r; -} - -#endif // !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) && !defined(_LIBCPP_HAS_NO_VARIADICS) - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator==(const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return __x.size() == __y.size() && _VSTD::equal(__x.begin(), __x.end(), __y.begin()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator< (const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return _VSTD::lexicographical_compare(__x.begin(), __x.end(), __y.begin(), __y.end()); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator!=(const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__x == __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator> (const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return __y < __x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator>=(const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__x < __y); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -bool -operator<=(const multimap<_Key, _Tp, _Compare, _Allocator>& __x, - const multimap<_Key, _Tp, _Compare, _Allocator>& __y) -{ - return !(__y < __x); -} - -template -inline _LIBCPP_INLINE_VISIBILITY -void -swap(multimap<_Key, _Tp, _Compare, _Allocator>& __x, - multimap<_Key, _Tp, _Compare, _Allocator>& __y) - _NOEXCEPT_(_NOEXCEPT_(__x.swap(__y))) -{ - __x.swap(__y); -} - -_LIBCPP_END_NAMESPACE_STD - -#endif // _LIBCPP_MAP diff --git a/libcxx/include/memory b/libcxx/include/memory deleted file mode 100644 index aa24f960aecf..000000000000 --- a/libcxx/include/memory +++ /dev/null @@ -1,5294 +0,0 @@ -// -*- C++ -*- -//===-------------------------- memory ------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef _LIBCPP_MEMORY -#define _LIBCPP_MEMORY - -/* - memory synopsis - -namespace std -{ - -struct allocator_arg_t { }; -constexpr allocator_arg_t allocator_arg = allocator_arg_t(); - -template struct uses_allocator; - -template -struct pointer_traits -{ - typedef Ptr pointer; - typedef
element_type; - typedef
difference_type; - - template using rebind =
; - - static pointer pointer_to(
); -}; - -template -struct pointer_traits -{ - typedef T* pointer; - typedef T element_type; - typedef ptrdiff_t difference_type; - - template using rebind = U*; - - static pointer pointer_to(
) noexcept; -}; - -template -struct allocator_traits -{ - typedef Alloc allocator_type; - typedef typename allocator_type::value_type - value_type; - - typedef Alloc::pointer | value_type* pointer; - typedef Alloc::const_pointer - | pointer_traits::rebind - const_pointer; - typedef Alloc::void_pointer - | pointer_traits::rebind - void_pointer; - typedef Alloc::const_void_pointer - | pointer_traits::rebind - const_void_pointer; - typedef Alloc::difference_type - | pointer_traits::difference_type - difference_type; - typedef Alloc::size_type - | make_unsigned::type - size_type; - typedef Alloc::propagate_on_container_copy_assignment - | false_type propagate_on_container_copy_assignment; - typedef Alloc::propagate_on_container_move_assignment - | false_type propagate_on_container_move_assignment; - typedef Alloc::propagate_on_container_swap - | false_type propagate_on_container_swap; - - template using rebind_alloc = Alloc::rebind::other | Alloc; - template using rebind_traits = allocator_traits>; - - static pointer allocate(allocator_type& a, size_type n); - static pointer allocate(allocator_type& a, size_type n, const_void_pointer hint); - - static void deallocate(allocator_type& a, pointer p, size_type n) noexcept; - - template - static void construct(allocator_type& a, T* p, Args&&... args); - - template - static void destroy(allocator_type& a, T* p); - - static size_type max_size(const allocator_type& a); - - static allocator_type - select_on_container_copy_construction(const allocator_type& a); -}; - -template <> -class allocator -{ -public: - typedef void* pointer; - typedef const void* const_pointer; - typedef void value_type; - - template struct rebind {typedef allocator<_Up> other;}; -}; - -template -class allocator -{ -public: - typedef size_t size_type; - typedef ptrdiff_t difference_type; - typedef T* pointer; - typedef const T* const_pointer; - typedef typename add_lvalue_reference::type reference; - typedef typename add_lvalue_reference::type const_reference; - typedef T value_type; - - template struct rebind {typedef allocator other;}; - - allocator() noexcept; - allocator(const allocator&) noexcept; - template allocator(const allocator&) noexcept; - ~allocator(); - pointer address(reference x) const noexcept; - const_pointer address(const_reference x) const noexcept; - pointer allocate(size_type, allocator::const_pointer hint = 0); - void deallocate(pointer p, size_type n) noexcept; - size_type max_size() const noexcept; - template - void construct(U* p, Args&&... args); - template - void destroy(U* p); -}; - -template -bool operator==(const allocator&, const allocator&) noexcept; - -template -bool operator!=(const allocator&, const allocator&) noexcept; - -template -class raw_storage_iterator - : public iterator // purposefully not C++03 -{ -public: - explicit raw_storage_iterator(OutputIterator x); - raw_storage_iterator& operator*(); - raw_storage_iterator& operator=(const T& element); - raw_storage_iterator& operator++(); - raw_storage_iterator operator++(int); -}; - -template pair get_temporary_buffer(ptrdiff_t n) noexcept; -template void return_temporary_buffer(T* p) noexcept; - -template T* addressof(T& r) noexcept; - -template -ForwardIterator -uninitialized_copy(InputIterator first, InputIterator last, ForwardIterator result); - -template -ForwardIterator -uninitialized_copy_n(InputIterator first, Size n, ForwardIterator result); - -template -void uninitialized_fill(ForwardIterator first, ForwardIterator last, const T& x); - -template -ForwardIterator -uninitialized_fill_n(ForwardIterator first, Size n, const T& x); - -template struct auto_ptr_ref {}; - -template -class auto_ptr -{ -public: - typedef X element_type; - - explicit auto_ptr(X* p =0) throw(); - auto_ptr(auto_ptr&) throw(); - template auto_ptr(auto_ptr&) throw(); - auto_ptr& operator=(auto_ptr&) throw(); - template auto_ptr& operator=(auto_ptr&) throw(); - auto_ptr& operator=(auto_ptr_ref r) throw(); - ~auto_ptr() throw(); - - typename add_lvalue_reference::type operator*() const throw(); - X* operator->() const throw(); - X* get() const throw(); - X* release() throw(); - void reset(X* p =0) throw(); - - auto_ptr(auto_ptr_ref) throw(); - template operator auto_ptr_ref() throw(); - template operator auto_ptr() throw(); -}; - -template -struct default_delete -{ - constexpr default_delete() noexcept = default; - template default_delete(const default_delete&) noexcept; - - void operator()(T*) const noexcept; -}; - -template -struct default_delete -{ - constexpr default_delete() noexcept = default; - void operator()(T*) const noexcept; - template void operator()(U*) const = delete; -}; - -template > -class unique_ptr -{ -public: - typedef see below pointer; - typedef T element_type; - typedef D deleter_type; - - // constructors - constexpr unique_ptr() noexcept; - explicit unique_ptr(pointer p) noexcept; - unique_ptr(pointer p, see below d1) noexcept; - unique_ptr(pointer p, see below d2) noexcept; - unique_ptr(unique_ptr&& u) noexcept; - unique_ptr(nullptr_t) noexcept : unique_ptr() { } - template - unique_ptr(unique_ptr&& u) noexcept; - template - unique_ptr(auto_ptr&& u) noexcept; - - // destructor - ~unique_ptr(); - - // assignment - unique_ptr& operator=(unique_ptr&& u) noexcept; - template unique_ptr& operator=(unique_ptr&& u) noexcept; - unique_ptr& operator=(nullptr_t) noexcept; - - // observers - typename add_lvalue_reference::type operator*() const; - pointer operator->() const noexcept; - pointer get() const noexcept; - deleter_type& get_deleter() noexcept; - const deleter_type& get_deleter() const noexcept; - explicit operator bool() const noexcept; - - // modifiers - pointer release() noexcept; - void reset(pointer p = pointer()) noexcept; - void swap(unique_ptr& u) noexcept; -}; - -template -class unique_ptr -{ -public: - typedef implementation-defined pointer; - typedef T element_type; - typedef D deleter_type; - - // constructors - constexpr unique_ptr() noexcept; - explicit unique_ptr(pointer p) noexcept; - unique_ptr(pointer p, see below d) noexcept; - unique_ptr(pointer p, see below d) noexcept; - unique_ptr(unique_ptr&& u) noexcept; - unique_ptr(nullptr_t) noexcept : unique_ptr() { } - - // destructor - ~unique_ptr(); - - // assignment - unique_ptr& operator=(unique_ptr&& u) noexcept; - unique_ptr& operator=(nullptr_t) noexcept; - - // observers - T& operator[](size_t i) const; - pointer get() const noexcept; - deleter_type& get_deleter() noexcept; - const deleter_type& get_deleter() const noexcept; - explicit operator bool() const noexcept; - - // modifiers - pointer release() noexcept; - void reset(pointer p = pointer()) noexcept; - void reset(nullptr_t) noexcept; - template void reset(U) = delete; - void swap(unique_ptr& u) noexcept; -}; - -template - void swap(unique_ptr& x, unique_ptr& y) noexcept; - -template - bool operator==(const unique_ptr& x, const unique_ptr& y); -template - bool operator!=(const unique_ptr& x, const unique_ptr& y); -template - bool operator<(const unique_ptr& x, const unique_ptr& y); -template - bool operator<=(const unique_ptr& x, const unique_ptr& y); -template - bool operator>(const unique_ptr& x, const unique_ptr& y); -template - bool operator>=(const unique_ptr& x, const unique_ptr& y); - -template - bool operator==(const unique_ptr& x, nullptr_t) noexcept; -template - bool operator==(nullptr_t, const unique_ptr& y) noexcept; -template - bool operator!=(const unique_ptr& x, nullptr_t) noexcept; -template - bool operator!=(nullptr_t, const unique_ptr& y) noexcept; - -template - bool operator<(const unique_ptr& x, nullptr_t); -template - bool operator<(nullptr_t, const unique_ptr& y); -template - bool operator<=(const unique_ptr& x, nullptr_t); -template - bool operator<=(nullptr_t, const unique_ptr& y); -template - bool operator>(const unique_ptr& x, nullptr_t); -template - bool operator>(nullptr_t, const unique_ptr& y); -template - bool operator>=(const unique_ptr& x, nullptr_t); -template - bool operator>=(nullptr_t, const unique_ptr& y); - -class bad_weak_ptr - : public std::exception -{ - bad_weak_ptr() noexcept; -}; - -template -class shared_ptr -{ -public: - typedef T element_type; - - // constructors: - constexpr shared_ptr() noexcept; - template explicit shared_ptr(Y* p); - template shared_ptr(Y* p, D d); - template shared_ptr(Y* p, D d, A a); - template shared_ptr(nullptr_t p, D d); - template shared_ptr(nullptr_t p, D d, A a); - template shared_ptr(const shared_ptr& r, T *p) noexcept; - shared_ptr(const shared_ptr& r) noexcept; - template shared_ptr(const shared_ptr& r) noexcept; - shared_ptr(shared_ptr&& r) noexcept; - template shared_ptr(shared_ptr&& r) noexcept; - template explicit shared_ptr(const weak_ptr& r); - template shared_ptr(auto_ptr&& r); - template shared_ptr(unique_ptr&& r); - shared_ptr(nullptr_t) : shared_ptr() { } - - // destructor: - ~shared_ptr(); - - // assignment: - shared_ptr& operator=(const shared_ptr& r) noexcept; - template shared_ptr& operator=(const shared_ptr& r) noexcept; - shared_ptr& operator=(shared_ptr&& r) noexcept; - template shared_ptr& operator=(shared_ptr&& r); - template shared_ptr& operator=(auto_ptr&& r); - template shared_ptr& operator=(unique_ptr&& r); - - // modifiers: - void swap(shared_ptr& r) noexcept; - void reset() noexcept; - template void reset(Y* p); - template void reset(Y* p, D d); - template void reset(Y* p, D d, A a); - - // observers: - T* get() const noexcept; - T& operator*() const noexcept; - T* operator->() const noexcept; - long use_count() const noexcept; - bool unique() const noexcept; - explicit operator bool() const noexcept; - template bool owner_before(shared_ptr const& b) const; - template bool owner_before(weak_ptr const& b) const; -}; - -// shared_ptr comparisons: -template - bool operator==(shared_ptr const& a, shared_ptr const& b) noexcept; -template - bool operator!=(shared_ptr const& a, shared_ptr const& b) noexcept; -template - bool operator<(shared_ptr const& a, shared_ptr const& b) noexcept; -template - bool operator>(shared_ptr const& a, shared_ptr const& b) noexcept; -template - bool operator<=(shared_ptr const& a, shared_ptr const& b) noexcept; -template - bool operator>=(shared_ptr const& a, shared_ptr const& b) noexcept; - -template - bool operator==(const shared_ptr& x, nullptr_t) noexcept; -template - bool operator==(nullptr_t, const shared_ptr& y) noexcept; -template - bool operator!=(const shared_ptr& x, nullptr_t) noexcept; -template - bool operator!=(nullptr_t, const shared_ptr& y) noexcept; -template - bool operator<(const shared_ptr& x, nullptr_t) noexcept; -template -bool operator<(nullptr_t, const shared_ptr& y) noexcept; -template - bool operator<=(const shared_ptr& x, nullptr_t) noexcept; -template - bool operator<=(nullptr_t, const shared_ptr& y) noexcept; -template - bool operator>(const shared_ptr& x, nullptr_t) noexcept; -template - bool operator>(nullptr_t, const shared_ptr& y) noexcept; -template - bool operator>=(const shared_ptr& x, nullptr_t) noexcept; -template - bool operator>=(nullptr_t, const shared_ptr& y) noexcept; - -// shared_ptr specialized algorithms: -template void swap(shared_ptr& a, shared_ptr& b) noexcept; - -// shared_ptr casts: -template - shared_ptr static_pointer_cast(shared_ptr const& r) noexcept; -template - shared_ptr dynamic_pointer_cast(shared_ptr const& r) noexcept; -template - shared_ptr const_pointer_cast(shared_ptr const& r) noexcept; - -// shared_ptr I/O: -template - basic_ostream& operator<< (basic_ostream& os, shared_ptr const& p); - -// shared_ptr get_deleter: -template D* get_deleter(shared_ptr const& p) noexcept; - -template - shared_ptr make_shared(Args&&... args); -template - shared_ptr allocate_shared(const A& a, Args&&... args); - -template -class weak_ptr -{ -public: - typedef T element_type; - - // constructors - constexpr weak_ptr() noexcept; - template weak_ptr(shared_ptr const& r) noexcept; - weak_ptr(weak_ptr const& r) noexcept; - template weak_ptr(weak_ptr const& r) noexcept; - - // destructor - ~weak_ptr(); - - // assignment - weak_ptr& operator=(weak_ptr const& r) noexcept; - template weak_ptr& operator=(weak_ptr const& r) noexcept; - template weak_ptr& operator=(shared_ptr const& r) noexcept; - - // modifiers - void swap(weak_ptr& r) noexcept; - void reset() noexcept; - - // observers - long use_count() const noexcept; - bool expired() const noexcept; - shared_ptr lock() const noexcept; - template bool owner_before(shared_ptr const& b); - template bool owner_before(weak_ptr const& b); -}; - -// weak_ptr specialized algorithms: -template void swap(weak_ptr& a, weak_ptr& b) noexcept; - -// class owner_less: -template struct owner_less; - -template -struct owner_less> - : binary_function, shared_ptr, bool> -{ - typedef bool result_type; - bool operator()(shared_ptr const&, shared_ptr const&) const; - bool operator()(shared_ptr const&, weak_ptr const&) const; - bool operator()(weak_ptr const&, shared_ptr const&) const; -}; - -template -struct owner_less> - : binary_function, weak_ptr, bool> -{ - typedef bool result_type; - bool operator()(weak_ptr const&, weak_ptr const&) const; - bool operator()(shared_ptr const&, weak_ptr const&) const; - bool operator()(weak_ptr const&, shared_ptr const&) const; -}; - -template -class enable_shared_from_this -{ -protected: - constexpr enable_shared_from_this() noexcept; - enable_shared_from_this(enable_shared_from_this const&) noexcept; - enable_shared_from_this& operator=(enable_shared_from_this const&) noexcept; - ~enable_shared_from_this(); -public: - shared_ptr shared_from_this(); - shared_ptr shared_from_this() const; -}; - -template - bool atomic_is_lock_free(const shared_ptr* p); -template - shared_ptr atomic_load(const shared_ptr* p); -template - shared_ptr atomic_load_explicit(const shared_ptr* p, memory_order mo); -template - void atomic_store(shared_ptr* p, shared_ptr r); -template - void atomic_store_explicit(shared_ptr* p, shared_ptr r, memory_order mo); -template - shared_ptr atomic_exchange(shared_ptr* p, shared_ptr r); -template - shared_ptr - atomic_exchange_explicit(shared_ptr* p, shared_ptr r, memory_order mo); -template - bool - atomic_compare_exchange_weak(shared_ptr* p, shared_ptr* v, shared_ptr w); -template - bool - atomic_compare_exchange_strong( shared_ptr* p, shared_ptr* v, shared_ptr w); -template - bool - atomic_compare_exchange_weak_explicit(shared_ptr* p, shared_ptr* v, - shared_ptr w, memory_order success, - memory_order failure); -template - bool - atomic_compare_exchange_strong_explicit(shared_ptr* p, shared_ptr* v, - shared_ptr w, memory_order success, - memory_order failure); -// Hash support -template struct hash; -template struct hash >; -template struct hash >; - -// Pointer safety -enum class pointer_safety { relaxed, preferred, strict }; -void declare_reachable(void *p); -template T *undeclare_reachable(T *p); -void declare_no_pointers(char *p, size_t n); -void undeclare_no_pointers(char *p, size_t n); -pointer_safety get_pointer_safety() noexcept; - -void* align(size_t alignment, size_t size, void*& ptr, size_t& space); - -} // std - -*/ - -#include <__config> -#include -#include -#include -#include -#include -#include -#include -#include -#include <__functional_base> -#include -#include -#include -#if defined(_LIBCPP_NO_EXCEPTIONS) - #include -#endif - -#include <__undef_min_max> - -#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) -#pragma GCC system_header -#endif - -_LIBCPP_BEGIN_NAMESPACE_STD - -// addressof - -template -inline _LIBCPP_INLINE_VISIBILITY -_Tp* -addressof(_Tp& __x) _NOEXCEPT -{ - return (_Tp*)&(char&)__x; -} - -#if defined(_LIBCPP_HAS_OBJC_ARC) && !defined(_LIBCPP_PREDEFINED_OBJC_ARC_ADDRESSOF) -// Objective-C++ Automatic Reference Counting uses qualified pointers -// that require special addressof() signatures. When -// _LIBCPP_PREDEFINED_OBJC_ARC_ADDRESSOF is defined, the compiler -// itself is providing these definitions. Otherwise, we provide them. -template -inline _LIBCPP_INLINE_VISIBILITY -__strong _Tp* -addressof(__strong _Tp& __x) _NOEXCEPT -{ - return &__x; -} - -#ifdef _LIBCPP_HAS_OBJC_ARC_WEAK -template -inline _LIBCPP_INLINE_VISIBILITY -__weak _Tp* -addressof(__weak _Tp& __x) _NOEXCEPT -{ - return &__x; -} -#endif - -template -inline _LIBCPP_INLINE_VISIBILITY -__autoreleasing _Tp* -addressof(__autoreleasing _Tp& __x) _NOEXCEPT -{ - return &__x; -} - -template -inline _LIBCPP_INLINE_VISIBILITY -__unsafe_unretained _Tp* -addressof(__unsafe_unretained _Tp& __x) _NOEXCEPT -{ - return &__x; -} -#endif - -template class allocator; - -template <> -class _LIBCPP_VISIBLE allocator -{ -public: - typedef void* pointer; - typedef const void* const_pointer; - typedef void value_type; - - template struct rebind {typedef allocator<_Up> other;}; -}; - -template <> -class _LIBCPP_VISIBLE allocator -{ -public: - typedef const void* pointer; - typedef const void* const_pointer; - typedef const void value_type; - - template struct rebind {typedef allocator<_Up> other;}; -}; - -// pointer_traits - -template -struct __has_element_type -{ -private: - struct __two {char _; char __;}; - template static __two __test(...); - template static char __test(typename _Up::element_type* = 0); -public: - static const bool value = sizeof(__test<_Tp>(0)) == 1; -}; - -template ::value> -struct __pointer_traits_element_type; - -template -struct __pointer_traits_element_type<_Ptr, true> -{ - typedef typename _Ptr::element_type type; -}; - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -template