From 621c1c83f254d84e60114c3419a70f92c94916d7 Mon Sep 17 00:00:00 2001 From: Strahinja Val Markovic Date: Thu, 15 May 2014 15:39:33 -0700 Subject: [PATCH] Removing ycmd --- third_party/ycmd/build.sh | 183 - .../ycmd/cpp/BoostParts/CMakeLists.txt | 109 - .../boost/algorithm/cxx11/any_of.hpp | 90 - .../cpp/BoostParts/boost/algorithm/string.hpp | 31 - .../boost/algorithm/string/case_conv.hpp | 176 - .../boost/algorithm/string/classification.hpp | 312 - .../boost/algorithm/string/compare.hpp | 199 - .../boost/algorithm/string/concept.hpp | 83 - .../boost/algorithm/string/config.hpp | 28 - .../boost/algorithm/string/constants.hpp | 36 - .../algorithm/string/detail/case_conv.hpp | 123 - .../string/detail/classification.hpp | 353 - .../algorithm/string/detail/find_format.hpp | 204 - .../string/detail/find_format_all.hpp | 273 - .../string/detail/find_format_store.hpp | 89 - .../algorithm/string/detail/find_iterator.hpp | 87 - .../boost/algorithm/string/detail/finder.hpp | 641 -- .../algorithm/string/detail/finder_regex.hpp | 122 - .../algorithm/string/detail/formatter.hpp | 119 - .../string/detail/formatter_regex.hpp | 61 - .../algorithm/string/detail/predicate.hpp | 77 - .../string/detail/replace_storage.hpp | 159 - .../algorithm/string/detail/sequence.hpp | 200 - .../boost/algorithm/string/detail/trim.hpp | 95 - .../boost/algorithm/string/detail/util.hpp | 106 - .../boost/algorithm/string/erase.hpp | 844 -- .../boost/algorithm/string/find.hpp | 334 - .../boost/algorithm/string/find_format.hpp | 287 - .../boost/algorithm/string/find_iterator.hpp | 383 - .../boost/algorithm/string/finder.hpp | 270 - .../boost/algorithm/string/formatter.hpp | 120 - .../boost/algorithm/string/iter_find.hpp | 193 - .../boost/algorithm/string/join.hpp | 145 - .../boost/algorithm/string/predicate.hpp | 475 -- .../algorithm/string/predicate_facade.hpp | 42 - .../boost/algorithm/string/regex.hpp | 646 -- .../algorithm/string/regex_find_format.hpp | 90 - .../boost/algorithm/string/replace.hpp | 928 -- .../algorithm/string/sequence_traits.hpp | 193 - .../boost/algorithm/string/split.hpp | 163 - .../algorithm/string/std/list_traits.hpp | 85 - .../algorithm/string/std/slist_traits.hpp | 85 - .../algorithm/string/std/string_traits.hpp | 52 - .../string/std_containers_traits.hpp | 26 - .../boost/algorithm/string/trim.hpp | 398 - .../boost/algorithm/string/yes_no_type.hpp | 33 - .../boost/algorithm/string_regex.hpp | 23 - .../cpp/BoostParts/boost/aligned_storage.hpp | 181 - .../BoostParts/boost/archive/add_facet.hpp | 55 - .../boost/archive/archive_exception.hpp | 99 - .../boost/archive/basic_archive.hpp | 301 - .../boost/archive/basic_binary_iarchive.hpp | 222 - .../boost/archive/basic_binary_iprimitive.hpp | 190 - .../boost/archive/basic_binary_oarchive.hpp | 180 - .../boost/archive/basic_binary_oprimitive.hpp | 184 - .../archive/basic_streambuf_locale_saver.hpp | 73 - .../boost/archive/basic_text_iarchive.hpp | 91 - .../boost/archive/basic_text_iprimitive.hpp | 144 - .../boost/archive/basic_text_oarchive.hpp | 116 - .../boost/archive/basic_text_oprimitive.hpp | 173 - .../boost/archive/basic_xml_archive.hpp | 67 - .../boost/archive/basic_xml_iarchive.hpp | 127 - .../boost/archive/basic_xml_oarchive.hpp | 145 - .../boost/archive/binary_iarchive.hpp | 103 - .../boost/archive/binary_iarchive_impl.hpp | 96 - .../boost/archive/binary_oarchive.hpp | 66 - .../boost/archive/binary_oarchive_impl.hpp | 97 - .../boost/archive/binary_wiarchive.hpp | 93 - .../boost/archive/binary_woarchive.hpp | 61 - .../BoostParts/boost/archive/codecvt_null.hpp | 100 - .../boost/archive/detail/abi_prefix.hpp | 20 - .../boost/archive/detail/abi_suffix.hpp | 19 - .../archive/detail/archive_serializer_map.hpp | 55 - .../archive/detail/auto_link_archive.hpp | 48 - .../archive/detail/auto_link_warchive.hpp | 47 - .../boost/archive/detail/basic_iarchive.hpp | 110 - .../archive/detail/basic_iserializer.hpp | 95 - .../boost/archive/detail/basic_oarchive.hpp | 106 - .../archive/detail/basic_oserializer.hpp | 93 - .../detail/basic_pointer_iserializer.hpp | 73 - .../detail/basic_pointer_oserializer.hpp | 72 - .../boost/archive/detail/basic_serializer.hpp | 79 - .../archive/detail/basic_serializer_map.hpp | 69 - .../BoostParts/boost/archive/detail/check.hpp | 169 - .../boost/archive/detail/common_iarchive.hpp | 88 - .../boost/archive/detail/common_oarchive.hpp | 87 - .../BoostParts/boost/archive/detail/decl.hpp | 79 - .../archive/detail/interface_iarchive.hpp | 77 - .../archive/detail/interface_oarchive.hpp | 84 - .../boost/archive/detail/iserializer.hpp | 632 -- .../boost/archive/detail/oserializer.hpp | 531 -- .../boost/archive/detail/register_archive.hpp | 91 - .../archive/detail/utf8_codecvt_facet.hpp | 21 - .../BoostParts/boost/archive/dinkumware.hpp | 224 - .../archive/impl/archive_serializer_map.ipp | 71 - .../archive/impl/basic_binary_iarchive.ipp | 129 - .../archive/impl/basic_binary_iprimitive.ipp | 209 - .../archive/impl/basic_binary_oarchive.ipp | 46 - .../archive/impl/basic_binary_oprimitive.ipp | 160 - .../archive/impl/basic_text_iarchive.ipp | 79 - .../archive/impl/basic_text_iprimitive.ipp | 152 - .../archive/impl/basic_text_oarchive.ipp | 62 - .../archive/impl/basic_text_oprimitive.ipp | 114 - .../boost/archive/impl/basic_xml_grammar.hpp | 178 - .../boost/archive/impl/basic_xml_iarchive.ipp | 114 - .../boost/archive/impl/basic_xml_oarchive.ipp | 275 - .../boost/archive/impl/text_iarchive_impl.ipp | 128 - .../boost/archive/impl/text_oarchive_impl.ipp | 124 - .../archive/impl/text_wiarchive_impl.ipp | 118 - .../archive/impl/text_woarchive_impl.ipp | 85 - .../boost/archive/impl/xml_iarchive_impl.ipp | 204 - .../boost/archive/impl/xml_oarchive_impl.ipp | 117 - .../boost/archive/impl/xml_wiarchive_impl.ipp | 206 - .../boost/archive/impl/xml_woarchive_impl.ipp | 160 - .../archive/iterators/base64_from_binary.hpp | 112 - .../archive/iterators/binary_from_base64.hpp | 120 - .../archive/iterators/dataflow_exception.hpp | 80 - .../boost/archive/iterators/escape.hpp | 115 - .../archive/iterators/insert_linebreaks.hpp | 101 - .../archive/iterators/istream_iterator.hpp | 107 - .../boost/archive/iterators/mb_from_wchar.hpp | 136 - .../archive/iterators/ostream_iterator.hpp | 83 - .../archive/iterators/remove_whitespace.hpp | 176 - .../archive/iterators/transform_width.hpp | 172 - .../boost/archive/iterators/unescape.hpp | 91 - .../boost/archive/iterators/wchar_from_mb.hpp | 129 - .../boost/archive/iterators/xml_escape.hpp | 125 - .../boost/archive/iterators/xml_unescape.hpp | 128 - .../boost/archive/polymorphic_iarchive.hpp | 181 - .../boost/archive/polymorphic_oarchive.hpp | 159 - .../boost/archive/shared_ptr_helper.hpp | 219 - .../boost/archive/text_iarchive.hpp | 156 - .../boost/archive/text_oarchive.hpp | 119 - .../boost/archive/text_wiarchive.hpp | 152 - .../boost/archive/text_woarchive.hpp | 145 - .../cpp/BoostParts/boost/archive/wcslen.hpp | 56 - .../boost/archive/xml_archive_exception.hpp | 56 - .../BoostParts/boost/archive/xml_iarchive.hpp | 164 - .../BoostParts/boost/archive/xml_oarchive.hpp | 133 - .../boost/archive/xml_wiarchive.hpp | 170 - .../boost/archive/xml_woarchive.hpp | 140 - .../ycmd/cpp/BoostParts/boost/array.hpp | 446 - .../ycmd/cpp/BoostParts/boost/assert.hpp | 141 - .../ycmd/cpp/BoostParts/boost/assign.hpp | 24 - .../boost/assign/assignment_exception.hpp | 43 - .../BoostParts/boost/assign/list_inserter.hpp | 400 - .../cpp/BoostParts/boost/assign/list_of.hpp | 681 -- .../boost/assign/ptr_list_inserter.hpp | 164 - .../BoostParts/boost/assign/ptr_list_of.hpp | 191 - .../boost/assign/ptr_map_inserter.hpp | 103 - .../ycmd/cpp/BoostParts/boost/assign/std.hpp | 27 - .../cpp/BoostParts/boost/assign/std/deque.hpp | 38 - .../cpp/BoostParts/boost/assign/std/list.hpp | 38 - .../cpp/BoostParts/boost/assign/std/map.hpp | 45 - .../cpp/BoostParts/boost/assign/std/queue.hpp | 45 - .../cpp/BoostParts/boost/assign/std/set.hpp | 44 - .../cpp/BoostParts/boost/assign/std/slist.hpp | 45 - .../cpp/BoostParts/boost/assign/std/stack.hpp | 37 - .../BoostParts/boost/assign/std/vector.hpp | 37 - .../ycmd/cpp/BoostParts/boost/atomic.hpp | 18 - .../cpp/BoostParts/boost/atomic/atomic.hpp | 232 - .../BoostParts/boost/atomic/detail/base.hpp | 605 -- .../boost/atomic/detail/cas128strong.hpp | 290 - .../boost/atomic/detail/cas32strong.hpp | 939 -- .../boost/atomic/detail/cas32weak.hpp | 1017 --- .../boost/atomic/detail/cas64strong-ptr.hpp | 247 - .../boost/atomic/detail/cas64strong.hpp | 264 - .../BoostParts/boost/atomic/detail/config.hpp | 16 - .../boost/atomic/detail/gcc-alpha.hpp | 368 - .../boost/atomic/detail/gcc-armv6plus.hpp | 255 - .../boost/atomic/detail/gcc-atomic.hpp | 1211 --- .../boost/atomic/detail/gcc-cas.hpp | 160 - .../boost/atomic/detail/gcc-ppc.hpp | 2952 ------- .../boost/atomic/detail/gcc-sparcv9.hpp | 1333 --- .../boost/atomic/detail/gcc-x86.hpp | 2017 ----- .../boost/atomic/detail/generic-cas.hpp | 206 - .../boost/atomic/detail/interlocked.hpp | 203 - .../BoostParts/boost/atomic/detail/link.hpp | 50 - .../boost/atomic/detail/linux-arm.hpp | 190 - .../boost/atomic/detail/lockpool.hpp | 91 - .../boost/atomic/detail/platform.hpp | 71 - .../atomic/detail/type-classification.hpp | 45 - .../boost/atomic/detail/windows.hpp | 1669 ---- .../ycmd/cpp/BoostParts/boost/bind.hpp | 24 - .../ycmd/cpp/BoostParts/boost/bind/arg.hpp | 62 - .../ycmd/cpp/BoostParts/boost/bind/bind.hpp | 1751 ---- .../cpp/BoostParts/boost/bind/bind_cc.hpp | 117 - .../cpp/BoostParts/boost/bind/bind_mf2_cc.hpp | 228 - .../cpp/BoostParts/boost/bind/bind_mf_cc.hpp | 227 - .../BoostParts/boost/bind/bind_template.hpp | 345 - .../ycmd/cpp/BoostParts/boost/bind/mem_fn.hpp | 389 - .../cpp/BoostParts/boost/bind/mem_fn_cc.hpp | 103 - .../BoostParts/boost/bind/mem_fn_template.hpp | 1047 --- .../cpp/BoostParts/boost/bind/mem_fn_vw.hpp | 130 - .../BoostParts/boost/bind/placeholders.hpp | 69 - .../cpp/BoostParts/boost/bind/protect.hpp | 304 - .../cpp/BoostParts/boost/bind/storage.hpp | 475 -- .../ycmd/cpp/BoostParts/boost/call_traits.hpp | 24 - .../ycmd/cpp/BoostParts/boost/cast.hpp | 107 - .../ycmd/cpp/BoostParts/boost/cerrno.hpp | 331 - .../cpp/BoostParts/boost/checked_delete.hpp | 69 - .../ycmd/cpp/BoostParts/boost/chrono/ceil.hpp | 36 - .../cpp/BoostParts/boost/chrono/chrono.hpp | 15 - .../BoostParts/boost/chrono/clock_string.hpp | 25 - .../cpp/BoostParts/boost/chrono/config.hpp | 220 - .../boost/chrono/detail/inlined/chrono.hpp | 44 - .../chrono/detail/inlined/mac/chrono.hpp | 241 - .../chrono/detail/inlined/posix/chrono.hpp | 120 - .../chrono/detail/inlined/win/chrono.hpp | 139 - .../chrono/detail/is_evenly_divisible_by.hpp | 31 - .../boost/chrono/detail/static_assert.hpp | 30 - .../BoostParts/boost/chrono/detail/system.hpp | 29 - .../cpp/BoostParts/boost/chrono/duration.hpp | 794 -- .../BoostParts/boost/chrono/system_clocks.hpp | 233 - .../BoostParts/boost/chrono/time_point.hpp | 380 - .../cpp/BoostParts/boost/circular_buffer.hpp | 74 - .../BoostParts/boost/circular_buffer/base.hpp | 3173 ------- .../boost/circular_buffer/debug.hpp | 227 - .../boost/circular_buffer/details.hpp | 518 -- .../boost/circular_buffer/space_optimized.hpp | 1746 ---- .../BoostParts/boost/circular_buffer_fwd.hpp | 43 - .../cpp/BoostParts/boost/compressed_pair.hpp | 24 - .../cpp/BoostParts/boost/concept/assert.hpp | 46 - .../concept/detail/backward_compatibility.hpp | 16 - .../boost/concept/detail/borland.hpp | 30 - .../boost/concept/detail/concept_def.hpp | 51 - .../boost/concept/detail/concept_undef.hpp | 5 - .../boost/concept/detail/general.hpp | 75 - .../boost/concept/detail/has_constraints.hpp | 50 - .../BoostParts/boost/concept/detail/msvc.hpp | 114 - .../cpp/BoostParts/boost/concept/usage.hpp | 44 - .../BoostParts/boost/concept_archetype.hpp | 669 -- .../cpp/BoostParts/boost/concept_check.hpp | 1083 --- .../ycmd/cpp/BoostParts/boost/config.hpp | 63 - .../boost/config/abi/borland_prefix.hpp | 27 - .../boost/config/abi/borland_suffix.hpp | 12 - .../boost/config/abi/msvc_prefix.hpp | 22 - .../boost/config/abi/msvc_suffix.hpp | 8 - .../BoostParts/boost/config/abi_prefix.hpp | 25 - .../BoostParts/boost/config/abi_suffix.hpp | 27 - .../cpp/BoostParts/boost/config/auto_link.hpp | 429 - .../boost/config/compiler/borland.hpp | 287 - .../boost/config/compiler/clang.hpp | 180 - .../boost/config/compiler/codegear.hpp | 189 - .../boost/config/compiler/comeau.hpp | 59 - .../boost/config/compiler/common_edg.hpp | 112 - .../boost/config/compiler/compaq_cxx.hpp | 19 - .../BoostParts/boost/config/compiler/cray.hpp | 65 - .../boost/config/compiler/digitalmars.hpp | 93 - .../BoostParts/boost/config/compiler/gcc.hpp | 261 - .../boost/config/compiler/gcc_xml.hpp | 64 - .../boost/config/compiler/greenhills.hpp | 28 - .../boost/config/compiler/hp_acc.hpp | 144 - .../boost/config/compiler/intel.hpp | 323 - .../BoostParts/boost/config/compiler/kai.hpp | 33 - .../boost/config/compiler/metrowerks.hpp | 148 - .../BoostParts/boost/config/compiler/mpw.hpp | 90 - .../BoostParts/boost/config/compiler/nvcc.hpp | 16 - .../boost/config/compiler/pathscale.hpp | 83 - .../BoostParts/boost/config/compiler/pgi.hpp | 125 - .../boost/config/compiler/sgi_mipspro.hpp | 29 - .../boost/config/compiler/sunpro_cc.hpp | 153 - .../boost/config/compiler/vacpp.hpp | 131 - .../boost/config/compiler/visualc.hpp | 276 - .../BoostParts/boost/config/no_tr1/cmath.hpp | 28 - .../boost/config/no_tr1/complex.hpp | 28 - .../boost/config/no_tr1/functional.hpp | 28 - .../BoostParts/boost/config/no_tr1/memory.hpp | 28 - .../boost/config/no_tr1/utility.hpp | 28 - .../BoostParts/boost/config/platform/aix.hpp | 33 - .../boost/config/platform/amigaos.hpp | 15 - .../BoostParts/boost/config/platform/beos.hpp | 26 - .../BoostParts/boost/config/platform/bsd.hpp | 86 - .../BoostParts/boost/config/platform/cray.hpp | 18 - .../boost/config/platform/cygwin.hpp | 58 - .../BoostParts/boost/config/platform/hpux.hpp | 87 - .../BoostParts/boost/config/platform/irix.hpp | 31 - .../boost/config/platform/linux.hpp | 103 - .../boost/config/platform/macos.hpp | 87 - .../boost/config/platform/qnxnto.hpp | 31 - .../boost/config/platform/solaris.hpp | 28 - .../boost/config/platform/symbian.hpp | 97 - .../BoostParts/boost/config/platform/vms.hpp | 25 - .../boost/config/platform/vxworks.hpp | 369 - .../boost/config/platform/win32.hpp | 73 - .../boost/config/posix_features.hpp | 95 - .../boost/config/requires_threads.hpp | 92 - .../boost/config/select_compiler_config.hpp | 114 - .../boost/config/select_platform_config.hpp | 105 - .../boost/config/select_stdlib_config.hpp | 85 - .../boost/config/stdlib/dinkumware.hpp | 157 - .../boost/config/stdlib/libcomo.hpp | 72 - .../BoostParts/boost/config/stdlib/libcpp.hpp | 37 - .../boost/config/stdlib/libstdcpp3.hpp | 166 - .../BoostParts/boost/config/stdlib/modena.hpp | 56 - .../BoostParts/boost/config/stdlib/msl.hpp | 84 - .../boost/config/stdlib/roguewave.hpp | 186 - .../BoostParts/boost/config/stdlib/sgi.hpp | 148 - .../boost/config/stdlib/stlport.hpp | 243 - .../BoostParts/boost/config/stdlib/vacpp.hpp | 54 - .../cpp/BoostParts/boost/config/suffix.hpp | 941 -- .../ycmd/cpp/BoostParts/boost/config/user.hpp | 124 - .../boost/config/warning_disable.hpp | 47 - .../boost/container/allocator_traits.hpp | 405 - .../boost/container/container_fwd.hpp | 182 - .../boost/container/detail/algorithms.hpp | 90 - .../container/detail/allocation_type.hpp | 54 - .../detail/allocator_version_traits.hpp | 167 - .../boost/container/detail/config_begin.hpp | 50 - .../boost/container/detail/config_end.hpp | 17 - .../boost/container/detail/destroyers.hpp | 376 - .../boost/container/detail/iterators.hpp | 812 -- .../boost/container/detail/memory_util.hpp | 83 - .../BoostParts/boost/container/detail/mpl.hpp | 160 - .../detail/multiallocation_chain.hpp | 286 - .../container/detail/node_alloc_holder.hpp | 387 - .../boost/container/detail/pair.hpp | 354 - .../boost/container/detail/preprocessor.hpp | 232 - .../container/detail/transform_iterator.hpp | 176 - .../boost/container/detail/tree.hpp | 1085 --- .../boost/container/detail/type_traits.hpp | 210 - .../boost/container/detail/utilities.hpp | 1180 --- .../boost/container/detail/value_init.hpp | 45 - .../detail/variadic_templates_tools.hpp | 153 - .../boost/container/detail/version_type.hpp | 92 - .../boost/container/detail/workaround.hpp | 50 - .../cpp/BoostParts/boost/container/map.hpp | 1532 ---- .../boost/container/scoped_allocator.hpp | 1534 ---- .../boost/container/scoped_allocator_fwd.hpp | 83 - .../boost/container/throw_exception.hpp | 110 - .../ycmd/cpp/BoostParts/boost/cregex.hpp | 39 - .../ycmd/cpp/BoostParts/boost/cstdint.hpp | 545 -- .../ycmd/cpp/BoostParts/boost/cstdlib.hpp | 41 - .../cpp/BoostParts/boost/current_function.hpp | 68 - .../boost/date_time/adjust_functors.hpp | 178 - .../cpp/BoostParts/boost/date_time/c_time.hpp | 123 - .../boost/date_time/compiler_config.hpp | 169 - .../boost/date_time/constrained_value.hpp | 121 - .../cpp/BoostParts/boost/date_time/date.hpp | 208 - .../boost/date_time/date_clock_device.hpp | 77 - .../BoostParts/boost/date_time/date_defs.hpp | 26 - .../boost/date_time/date_duration.hpp | 146 - .../boost/date_time/date_duration_types.hpp | 269 - .../BoostParts/boost/date_time/date_facet.hpp | 767 -- .../boost/date_time/date_format_simple.hpp | 159 - .../boost/date_time/date_formatting.hpp | 135 - .../date_time/date_formatting_limited.hpp | 121 - .../date_time/date_formatting_locales.hpp | 233 - .../date_time/date_generator_formatter.hpp | 265 - .../boost/date_time/date_generator_parser.hpp | 330 - .../boost/date_time/date_generators.hpp | 509 -- .../boost/date_time/date_iterator.hpp | 101 - .../boost/date_time/date_names_put.hpp | 320 - .../boost/date_time/date_parsing.hpp | 318 - .../BoostParts/boost/date_time/dst_rules.hpp | 391 - .../boost/date_time/filetime_functions.hpp | 170 - .../boost/date_time/format_date_parser.hpp | 731 -- .../boost/date_time/gregorian/conversion.hpp | 68 - .../boost/date_time/gregorian/formatters.hpp | 162 - .../gregorian/formatters_limited.hpp | 81 - .../date_time/gregorian/greg_calendar.hpp | 48 - .../boost/date_time/gregorian/greg_date.hpp | 136 - .../boost/date_time/gregorian/greg_day.hpp | 57 - .../date_time/gregorian/greg_day_of_year.hpp | 38 - .../date_time/gregorian/greg_duration.hpp | 134 - .../gregorian/greg_duration_types.hpp | 43 - .../boost/date_time/gregorian/greg_facet.hpp | 354 - .../boost/date_time/gregorian/greg_month.hpp | 105 - .../date_time/gregorian/greg_weekday.hpp | 66 - .../boost/date_time/gregorian/greg_year.hpp | 53 - .../boost/date_time/gregorian/greg_ymd.hpp | 33 - .../boost/date_time/gregorian/gregorian.hpp | 38 - .../date_time/gregorian/gregorian_io.hpp | 784 -- .../date_time/gregorian/gregorian_types.hpp | 109 - .../boost/date_time/gregorian/parsers.hpp | 91 - .../boost/date_time/gregorian_calendar.hpp | 70 - .../boost/date_time/gregorian_calendar.ipp | 219 - .../boost/date_time/int_adapter.hpp | 509 -- .../BoostParts/boost/date_time/iso_format.hpp | 303 - .../boost/date_time/locale_config.hpp | 31 - .../boost/date_time/microsec_time_clock.hpp | 127 - .../boost/date_time/parse_format_base.hpp | 29 - .../cpp/BoostParts/boost/date_time/period.hpp | 377 - .../boost/date_time/period_formatter.hpp | 196 - .../boost/date_time/period_parser.hpp | 198 - .../boost/date_time/posix_time/conversion.hpp | 94 - .../posix_time/date_duration_operators.hpp | 114 - .../posix_time/posix_time_config.hpp | 178 - .../posix_time/posix_time_duration.hpp | 82 - .../posix_time/posix_time_system.hpp | 68 - .../date_time/posix_time/posix_time_types.hpp | 55 - .../boost/date_time/posix_time/ptime.hpp | 65 - .../date_time/posix_time/time_formatters.hpp | 289 - .../date_time/posix_time/time_period.hpp | 29 - .../boost/date_time/special_defs.hpp | 25 - .../date_time/special_values_formatter.hpp | 96 - .../boost/date_time/special_values_parser.hpp | 159 - .../boost/date_time/string_convert.hpp | 33 - .../boost/date_time/string_parse_tree.hpp | 278 - .../boost/date_time/strings_from_facet.hpp | 127 - .../cpp/BoostParts/boost/date_time/time.hpp | 191 - .../BoostParts/boost/date_time/time_clock.hpp | 83 - .../BoostParts/boost/date_time/time_defs.hpp | 43 - .../boost/date_time/time_duration.hpp | 293 - .../date_time/time_formatting_streams.hpp | 122 - .../boost/date_time/time_iterator.hpp | 52 - .../boost/date_time/time_parsing.hpp | 324 - .../date_time/time_resolution_traits.hpp | 144 - .../boost/date_time/time_system_counted.hpp | 254 - .../boost/date_time/time_system_split.hpp | 207 - .../boost/date_time/wrapping_int.hpp | 169 - .../boost/date_time/year_month_day.hpp | 45 - .../boost/detail/allocator_utilities.hpp | 212 - .../BoostParts/boost/detail/atomic_count.hpp | 21 - .../boost/detail/atomic_redef_macros.hpp | 19 - .../boost/detail/atomic_undef_macros.hpp | 39 - .../BoostParts/boost/detail/binary_search.hpp | 216 - .../cpp/BoostParts/boost/detail/bitmask.hpp | 47 - .../BoostParts/boost/detail/call_traits.hpp | 172 - .../boost/detail/compressed_pair.hpp | 443 - .../BoostParts/boost/detail/container_fwd.hpp | 162 - .../boost/detail/dynamic_bitset.hpp | 229 - .../cpp/BoostParts/boost/detail/endian.hpp | 11 - .../ycmd/cpp/BoostParts/boost/detail/fenv.hpp | 74 - .../boost/detail/indirect_traits.hpp | 487 -- .../BoostParts/boost/detail/interlocked.hpp | 210 - .../boost/detail/is_function_ref_tester.hpp | 136 - .../boost/detail/is_incrementable.hpp | 134 - .../cpp/BoostParts/boost/detail/is_xxx.hpp | 61 - .../cpp/BoostParts/boost/detail/iterator.hpp | 494 -- .../boost/detail/lcast_precision.hpp | 184 - .../boost/detail/lightweight_mutex.hpp | 22 - .../boost/detail/no_exceptions_support.hpp | 87 - .../boost/detail/numeric_traits.hpp | 191 - .../boost/detail/ob_call_traits.hpp | 168 - .../boost/detail/ob_compressed_pair.hpp | 510 -- .../boost/detail/quick_allocator.hpp | 23 - .../boost/detail/reference_content.hpp | 141 - .../boost/detail/scoped_enum_emulation.hpp | 337 - .../BoostParts/boost/detail/select_type.hpp | 36 - .../BoostParts/boost/detail/sp_typeinfo.hpp | 135 - .../boost/detail/utf8_codecvt_facet.hpp | 190 - .../boost/detail/utf8_codecvt_facet.ipp | 285 - .../boost/detail/winapi/GetLastError.hpp | 31 - .../boost/detail/winapi/basic_types.hpp | 116 - .../BoostParts/boost/detail/winapi/time.hpp | 85 - .../BoostParts/boost/detail/winapi/timers.hpp | 44 - .../BoostParts/boost/detail/workaround.hpp | 267 - .../cpp/BoostParts/boost/dynamic_bitset.hpp | 17 - .../boost/dynamic_bitset/config.hpp | 72 - .../boost/dynamic_bitset/dynamic_bitset.hpp | 1761 ---- .../BoostParts/boost/dynamic_bitset_fwd.hpp | 25 - .../boost/enable_shared_from_this.hpp | 18 - .../cpp/BoostParts/boost/exception/all.hpp | 36 - .../exception/current_exception_cast.hpp | 43 - .../exception/detail/attribute_noreturn.hpp | 17 - .../detail/clone_current_exception.hpp | 56 - .../exception/detail/error_info_impl.hpp | 74 - .../boost/exception/detail/exception_ptr.hpp | 513 -- .../exception/detail/is_output_streamable.hpp | 60 - .../exception/detail/object_hex_dump.hpp | 50 - .../boost/exception/detail/type_info.hpp | 83 - .../exception/diagnostic_information.hpp | 201 - .../boost/exception/errinfo_api_function.hpp | 22 - .../boost/exception/errinfo_at_line.hpp | 18 - .../boost/exception/errinfo_errno.hpp | 44 - .../boost/exception/errinfo_file_handle.hpp | 20 - .../boost/exception/errinfo_file_name.hpp | 26 - .../exception/errinfo_file_open_mode.hpp | 26 - .../exception/errinfo_nested_exception.hpp | 18 - .../exception/errinfo_type_info_name.hpp | 23 - .../BoostParts/boost/exception/error_info.hpp | 9 - .../BoostParts/boost/exception/exception.hpp | 483 -- .../boost/exception/get_error_info.hpp | 130 - .../cpp/BoostParts/boost/exception/info.hpp | 198 - .../BoostParts/boost/exception/info_tuple.hpp | 100 - .../BoostParts/boost/exception/to_string.hpp | 88 - .../boost/exception/to_string_stub.hpp | 117 - .../cpp/BoostParts/boost/exception_ptr.hpp | 11 - .../ycmd/cpp/BoostParts/boost/filesystem.hpp | 20 - .../BoostParts/boost/filesystem/config.hpp | 109 - .../boost/filesystem/convenience.hpp | 58 - .../filesystem/detail/utf8_codecvt_facet.hpp | 24 - .../BoostParts/boost/filesystem/fstream.hpp | 182 - .../boost/filesystem/operations.hpp | 1096 --- .../cpp/BoostParts/boost/filesystem/path.hpp | 758 -- .../boost/filesystem/path_traits.hpp | 235 - .../ycmd/cpp/BoostParts/boost/foreach.hpp | 1128 --- .../ycmd/cpp/BoostParts/boost/foreach_fwd.hpp | 51 - .../ycmd/cpp/BoostParts/boost/format.hpp | 59 - .../BoostParts/boost/format/alt_sstream.hpp | 176 - .../boost/format/alt_sstream_impl.hpp | 313 - .../format/detail/compat_workarounds.hpp | 86 - .../boost/format/detail/config_macros.hpp | 97 - .../format/detail/msvc_disambiguater.hpp | 56 - .../boost/format/detail/unset_macros.hpp | 34 - .../format/detail/workarounds_gcc-2_95.hpp | 162 - .../format/detail/workarounds_stlport.hpp | 42 - .../BoostParts/boost/format/exceptions.hpp | 103 - .../cpp/BoostParts/boost/format/feed_args.hpp | 277 - .../BoostParts/boost/format/format_class.hpp | 168 - .../BoostParts/boost/format/format_fwd.hpp | 49 - .../boost/format/format_implementation.hpp | 329 - .../BoostParts/boost/format/free_funcs.hpp | 70 - .../cpp/BoostParts/boost/format/group.hpp | 684 -- .../cpp/BoostParts/boost/format/internals.hpp | 201 - .../BoostParts/boost/format/internals_fwd.hpp | 60 - .../cpp/BoostParts/boost/format/parsing.hpp | 504 -- .../ycmd/cpp/BoostParts/boost/function.hpp | 66 - .../function/detail/function_iterate.hpp | 16 - .../function/detail/gen_maybe_include.pl | 37 - .../boost/function/detail/maybe_include.hpp | 267 - .../boost/function/detail/prologue.hpp | 26 - .../BoostParts/boost/function/function0.hpp | 12 - .../BoostParts/boost/function/function1.hpp | 12 - .../BoostParts/boost/function/function10.hpp | 12 - .../BoostParts/boost/function/function2.hpp | 12 - .../BoostParts/boost/function/function3.hpp | 12 - .../BoostParts/boost/function/function4.hpp | 12 - .../BoostParts/boost/function/function5.hpp | 12 - .../BoostParts/boost/function/function6.hpp | 12 - .../BoostParts/boost/function/function7.hpp | 12 - .../BoostParts/boost/function/function8.hpp | 12 - .../BoostParts/boost/function/function9.hpp | 12 - .../boost/function/function_base.hpp | 910 -- .../boost/function/function_fwd.hpp | 70 - .../boost/function/function_template.hpp | 1185 --- .../cpp/BoostParts/boost/function_equal.hpp | 28 - .../ycmd/cpp/BoostParts/boost/functional.hpp | 548 -- .../cpp/BoostParts/boost/functional/hash.hpp | 7 - .../hash/detail/float_functions.hpp | 336 - .../functional/hash/detail/hash_float.hpp | 271 - .../boost/functional/hash/detail/limits.hpp | 61 - .../boost/functional/hash/extensions.hpp | 379 - .../BoostParts/boost/functional/hash/hash.hpp | 541 -- .../boost/functional/hash/hash_fwd.hpp | 40 - .../BoostParts/boost/functional/hash_fwd.hpp | 7 - .../ycmd/cpp/BoostParts/boost/get_pointer.hpp | 48 - .../boost/graph/adjacency_iterator.hpp | 102 - .../BoostParts/boost/graph/adjacency_list.hpp | 458 - .../boost/graph/breadth_first_search.hpp | 413 - .../boost/graph/buffer_concepts.hpp | 91 - .../graph/detail/adj_list_edge_iterator.hpp | 117 - .../boost/graph/detail/adjacency_list.hpp | 2784 ------ .../boost/graph/detail/d_ary_heap.hpp | 319 - .../BoostParts/boost/graph/detail/edge.hpp | 124 - .../distributed/breadth_first_search.hpp | 163 - .../boost/graph/distributed/concepts.hpp | 213 - .../distributed/detail/filtered_queue.hpp | 108 - .../boost/graph/distributed/detail/queue.ipp | 177 - .../boost/graph/distributed/queue.hpp | 278 - .../graph/distributed/two_bit_color_map.hpp | 116 - .../graph/distributed/unsafe_serialize.hpp | 85 - .../BoostParts/boost/graph/graph_concepts.hpp | 619 -- .../boost/graph/graph_mutability_traits.hpp | 204 - .../boost/graph/graph_selectors.hpp | 38 - .../BoostParts/boost/graph/graph_traits.hpp | 404 - .../boost/graph/iteration_macros.hpp | 140 - .../boost/graph/named_function_params.hpp | 738 -- .../BoostParts/boost/graph/named_graph.hpp | 547 -- .../BoostParts/boost/graph/numeric_values.hpp | 52 - .../BoostParts/boost/graph/overloading.hpp | 46 - .../boost/graph/parallel/algorithm.hpp | 84 - .../boost/graph/parallel/basic_reduce.hpp | 42 - .../boost/graph/parallel/container_traits.hpp | 45 - .../parallel/detail/inplace_all_to_all.hpp | 78 - .../graph/parallel/detail/untracked_pair.hpp | 85 - .../boost/graph/parallel/process_group.hpp | 101 - .../boost/graph/parallel/properties.hpp | 111 - .../boost/graph/parallel/simple_trigger.hpp | 108 - .../cpp/BoostParts/boost/graph/properties.hpp | 382 - .../property_maps/constant_property_map.hpp | 92 - .../graph/property_maps/null_property_map.hpp | 41 - .../BoostParts/boost/graph/reverse_graph.hpp | 525 -- .../boost/graph/two_bit_color_map.hpp | 109 - .../cpp/BoostParts/boost/graph/visitors.hpp | 321 - .../cpp/BoostParts/boost/implicit_cast.hpp | 29 - .../BoostParts/boost/indirect_reference.hpp | 43 - .../ycmd/cpp/BoostParts/boost/integer.hpp | 261 - .../BoostParts/boost/integer/static_log2.hpp | 127 - .../ycmd/cpp/BoostParts/boost/integer_fwd.hpp | 164 - .../cpp/BoostParts/boost/integer_traits.hpp | 261 - .../interprocess/allocators/allocator.hpp | 306 - .../allocators/detail/allocator_common.hpp | 850 -- .../containers/allocation_type.hpp | 40 - .../interprocess/containers/version_type.hpp | 33 - .../boost/interprocess/creation_tags.hpp | 77 - .../boost/interprocess/detail/atomic.hpp | 562 -- .../boost/interprocess/detail/cast_tags.hpp | 29 - .../interprocess/detail/config_begin.hpp | 48 - .../boost/interprocess/detail/config_end.hpp | 17 - .../detail/config_external_begin.hpp | 18 - .../detail/config_external_end.hpp | 12 - .../detail/in_place_interface.hpp | 73 - .../detail/intermodule_singleton_common.hpp | 499 -- .../detail/interprocess_tester.hpp | 31 - .../detail/managed_memory_impl.hpp | 776 -- .../detail/managed_open_or_create_impl.hpp | 493 -- .../interprocess/detail/math_functions.hpp | 110 - .../boost/interprocess/detail/min_max.hpp | 40 - .../boost/interprocess/detail/mpl.hpp | 152 - .../boost/interprocess/detail/named_proxy.hpp | 349 - .../interprocess/detail/os_file_functions.hpp | 702 -- .../detail/os_thread_functions.hpp | 570 -- .../detail/posix_time_types_wrk.hpp | 42 - .../interprocess/detail/preprocessor.hpp | 203 - .../detail/segment_manager_helper.hpp | 511 -- .../interprocess/detail/tmp_dir_helpers.hpp | 181 - .../detail/transform_iterator.hpp | 195 - .../boost/interprocess/detail/type_traits.hpp | 158 - .../boost/interprocess/detail/utilities.hpp | 218 - .../detail/variadic_templates_tools.hpp | 153 - .../boost/interprocess/detail/win32_api.hpp | 2156 ----- .../detail/windows_intermodule_singleton.hpp | 309 - .../boost/interprocess/detail/workaround.hpp | 194 - .../BoostParts/boost/interprocess/errors.hpp | 236 - .../boost/interprocess/exceptions.hpp | 150 - .../boost/interprocess/indexes/iset_index.hpp | 150 - .../boost/interprocess/interprocess_fwd.hpp | 418 - .../interprocess/managed_shared_memory.hpp | 221 - .../boost/interprocess/mapped_region.hpp | 907 -- .../mem_algo/detail/mem_algo_common.hpp | 591 -- .../interprocess/mem_algo/rbtree_best_fit.hpp | 1413 --- .../boost/interprocess/offset_ptr.hpp | 731 -- .../boost/interprocess/permissions.hpp | 132 - .../boost/interprocess/segment_manager.hpp | 1364 --- .../interprocess/shared_memory_object.hpp | 430 - .../boost/interprocess/smart_ptr/deleter.hpp | 64 - .../interprocess/streams/bufferstream.hpp | 483 -- .../interprocess/sync/interprocess_mutex.hpp | 184 - .../sync/interprocess_recursive_mutex.hpp | 177 - .../boost/interprocess/sync/lock_options.hpp | 55 - .../boost/interprocess/sync/mutex_family.hpp | 56 - .../boost/interprocess/sync/null_mutex.hpp | 147 - .../boost/interprocess/sync/posix/mutex.hpp | 155 - .../sync/posix/pthread_helpers.hpp | 168 - .../sync/posix/ptime_to_timespec.hpp | 38 - .../sync/posix/recursive_mutex.hpp | 143 - .../boost/interprocess/sync/scoped_lock.hpp | 372 - .../boost/interprocess/sync/spin/mutex.hpp | 117 - .../sync/spin/recursive_mutex.hpp | 175 - .../boost/interprocess/sync/spin/wait.hpp | 181 - .../boost/interprocess/sync/windows/mutex.hpp | 114 - .../sync/windows/recursive_mutex.hpp | 43 - .../interprocess/sync/windows/sync_utils.hpp | 236 - .../sync/windows/winapi_mutex_wrapper.hpp | 163 - .../sync/windows/winapi_semaphore_wrapper.hpp | 198 - .../cpp/BoostParts/boost/intrusive/bstree.hpp | 2014 ----- .../boost/intrusive/bstree_algorithms.hpp | 1988 ----- .../intrusive/circular_slist_algorithms.hpp | 415 - .../boost/intrusive/detail/assert.hpp | 41 - .../detail/clear_on_destructor_base.hpp | 40 - .../detail/common_slist_algorithms.hpp | 102 - .../boost/intrusive/detail/config_begin.hpp | 52 - .../boost/intrusive/detail/config_end.hpp | 15 - .../intrusive/detail/ebo_functor_holder.hpp | 95 - .../intrusive/detail/function_detector.hpp | 88 - .../boost/intrusive/detail/generic_hook.hpp | 194 - .../has_member_function_callable_with.hpp | 357 - .../detail/is_stateful_value_traits.hpp | 77 - .../boost/intrusive/detail/memory_util.hpp | 292 - .../BoostParts/boost/intrusive/detail/mpl.hpp | 376 - .../intrusive/detail/parent_from_member.hpp | 117 - .../boost/intrusive/detail/preprocessor.hpp | 52 - .../boost/intrusive/detail/rbtree_node.hpp | 203 - .../boost/intrusive/detail/slist_node.hpp | 142 - .../boost/intrusive/detail/tree_node.hpp | 188 - .../boost/intrusive/detail/utilities.hpp | 1072 --- .../boost/intrusive/detail/workaround.hpp | 26 - .../boost/intrusive/intrusive_fwd.hpp | 572 -- .../intrusive/linear_slist_algorithms.hpp | 338 - .../BoostParts/boost/intrusive/link_mode.hpp | 46 - .../BoostParts/boost/intrusive/options.hpp | 840 -- .../boost/intrusive/pointer_plus_bits.hpp | 86 - .../boost/intrusive/pointer_traits.hpp | 265 - .../cpp/BoostParts/boost/intrusive/rbtree.hpp | 534 -- .../boost/intrusive/rbtree_algorithms.hpp | 547 -- .../cpp/BoostParts/boost/intrusive/set.hpp | 923 -- .../BoostParts/boost/intrusive/set_hook.hpp | 300 - .../cpp/BoostParts/boost/intrusive/slist.hpp | 2223 ----- .../BoostParts/boost/intrusive/slist_hook.hpp | 294 - .../cpp/BoostParts/boost/intrusive_ptr.hpp | 18 - .../boost/io/detail/quoted_manip.hpp | 190 - .../cpp/BoostParts/boost/io/ios_state.hpp | 439 - .../ycmd/cpp/BoostParts/boost/io_fwd.hpp | 67 - .../cpp/BoostParts/boost/is_placeholder.hpp | 31 - .../ycmd/cpp/BoostParts/boost/iterator.hpp | 59 - .../boost/iterator/counting_iterator.hpp | 215 - .../boost/iterator/detail/config_def.hpp | 137 - .../boost/iterator/detail/config_undef.hpp | 25 - .../boost/iterator/detail/enable_if.hpp | 86 - .../detail/facade_iterator_category.hpp | 200 - .../iterator/detail/minimum_category.hpp | 116 - .../boost/iterator/filter_iterator.hpp | 135 - .../boost/iterator/interoperable.hpp | 50 - .../boost/iterator/iterator_adaptor.hpp | 365 - .../boost/iterator/iterator_categories.hpp | 188 - .../boost/iterator/iterator_concepts.hpp | 284 - .../boost/iterator/iterator_facade.hpp | 874 -- .../boost/iterator/iterator_traits.hpp | 92 - .../boost/iterator/reverse_iterator.hpp | 69 - .../boost/iterator/transform_iterator.hpp | 172 - .../ycmd/cpp/BoostParts/boost/lambda/core.hpp | 79 - .../boost/lambda/detail/actions.hpp | 174 - .../boost/lambda/detail/arity_code.hpp | 110 - .../boost/lambda/detail/function_adaptors.hpp | 789 -- .../boost/lambda/detail/is_instance_of.hpp | 104 - .../boost/lambda/detail/lambda_config.hpp | 48 - .../lambda/detail/lambda_functor_base.hpp | 615 -- .../boost/lambda/detail/lambda_functors.hpp | 357 - .../boost/lambda/detail/lambda_fwd.hpp | 74 - .../boost/lambda/detail/lambda_traits.hpp | 578 -- .../boost/lambda/detail/member_ptr.hpp | 737 -- .../boost/lambda/detail/operator_actions.hpp | 139 - .../detail/operator_lambda_func_base.hpp | 271 - .../detail/operator_return_type_traits.hpp | 917 -- .../boost/lambda/detail/operators.hpp | 370 - .../BoostParts/boost/lambda/detail/ret.hpp | 325 - .../lambda/detail/return_type_traits.hpp | 282 - .../boost/lambda/detail/select_functions.hpp | 74 - .../cpp/BoostParts/boost/lambda/lambda.hpp | 34 - .../cpp/BoostParts/boost/lexical_cast.hpp | 2748 ------ .../ycmd/cpp/BoostParts/boost/limits.hpp | 146 - .../boost/lockfree/detail/atomic.hpp | 71 - .../boost/lockfree/detail/branch_hints.hpp | 38 - .../boost/lockfree/detail/copy_payload.hpp | 66 - .../boost/lockfree/detail/freelist.hpp | 648 -- .../boost/lockfree/detail/parameter.hpp | 73 - .../boost/lockfree/detail/prefix.hpp | 56 - .../boost/lockfree/detail/tagged_ptr.hpp | 21 - .../boost/lockfree/detail/tagged_ptr_dcas.hpp | 134 - .../detail/tagged_ptr_ptrcompression.hpp | 175 - .../BoostParts/boost/lockfree/policies.hpp | 59 - .../cpp/BoostParts/boost/lockfree/queue.hpp | 554 -- .../BoostParts/boost/lockfree/spsc_queue.hpp | 716 -- .../cpp/BoostParts/boost/lockfree/stack.hpp | 588 -- .../ycmd/cpp/BoostParts/boost/make_shared.hpp | 17 - .../boost/math/common_factor_rt.hpp | 530 -- .../BoostParts/boost/math/policies/policy.hpp | 992 --- .../special_functions/detail/fp_traits.hpp | 570 -- .../special_functions/detail/round_fwd.hpp | 93 - .../math/special_functions/fpclassify.hpp | 606 -- .../boost/math/special_functions/math_fwd.hpp | 1408 --- .../boost/math/special_functions/sign.hpp | 150 - .../BoostParts/boost/math/tools/config.hpp | 352 - .../BoostParts/boost/math/tools/promotion.hpp | 175 - .../BoostParts/boost/math/tools/real_cast.hpp | 29 - .../cpp/BoostParts/boost/math/tools/user.hpp | 97 - .../ycmd/cpp/BoostParts/boost/math_fwd.hpp | 108 - .../ycmd/cpp/BoostParts/boost/mem_fn.hpp | 24 - .../cpp/BoostParts/boost/memory_order.hpp | 53 - .../cpp/BoostParts/boost/move/algorithm.hpp | 274 - .../ycmd/cpp/BoostParts/boost/move/core.hpp | 339 - .../boost/move/detail/config_begin.hpp | 23 - .../boost/move/detail/config_end.hpp | 20 - .../boost/move/detail/meta_utils.hpp | 158 - .../boost/move/detail/move_helpers.hpp | 177 - .../cpp/BoostParts/boost/move/iterator.hpp | 298 - .../ycmd/cpp/BoostParts/boost/move/move.hpp | 27 - .../ycmd/cpp/BoostParts/boost/move/traits.hpp | 150 - .../cpp/BoostParts/boost/move/utility.hpp | 194 - third_party/ycmd/cpp/BoostParts/boost/mpi.hpp | 35 - .../cpp/BoostParts/boost/mpi/allocator.hpp | 210 - .../cpp/BoostParts/boost/mpi/collectives.hpp | 561 -- .../boost/mpi/collectives/all_gather.hpp | 82 - .../boost/mpi/collectives/all_reduce.hpp | 129 - .../boost/mpi/collectives/all_to_all.hpp | 153 - .../boost/mpi/collectives/broadcast.hpp | 145 - .../boost/mpi/collectives/gather.hpp | 152 - .../boost/mpi/collectives/reduce.hpp | 376 - .../BoostParts/boost/mpi/collectives/scan.hpp | 168 - .../boost/mpi/collectives/scatter.hpp | 161 - .../BoostParts/boost/mpi/collectives_fwd.hpp | 23 - .../cpp/BoostParts/boost/mpi/communicator.hpp | 1728 ---- .../ycmd/cpp/BoostParts/boost/mpi/config.hpp | 112 - .../cpp/BoostParts/boost/mpi/datatype.hpp | 361 - .../cpp/BoostParts/boost/mpi/datatype_fwd.hpp | 36 - .../mpi/detail/binary_buffer_iprimitive.hpp | 123 - .../mpi/detail/binary_buffer_oprimitive.hpp | 104 - .../boost/mpi/detail/broadcast_sc.hpp | 41 - .../boost/mpi/detail/communicator_sc.hpp | 96 - .../boost/mpi/detail/computation_tree.hpp | 86 - .../boost/mpi/detail/content_oarchive.hpp | 66 - .../mpi/detail/forward_skeleton_iarchive.hpp | 85 - .../mpi/detail/forward_skeleton_oarchive.hpp | 83 - .../boost/mpi/detail/ignore_iprimitive.hpp | 54 - .../boost/mpi/detail/ignore_oprimitive.hpp | 62 - .../mpi/detail/ignore_skeleton_oarchive.hpp | 79 - .../boost/mpi/detail/mpi_datatype_cache.hpp | 99 - .../mpi/detail/mpi_datatype_oarchive.hpp | 78 - .../mpi/detail/mpi_datatype_primitive.hpp | 145 - .../boost/mpi/detail/packed_iprimitive.hpp | 118 - .../boost/mpi/detail/packed_oprimitive.hpp | 115 - .../boost/mpi/detail/point_to_point.hpp | 52 - .../mpi/detail/text_skeleton_oarchive.hpp | 50 - .../cpp/BoostParts/boost/mpi/environment.hpp | 281 - .../cpp/BoostParts/boost/mpi/exception.hpp | 104 - .../boost/mpi/graph_communicator.hpp | 575 -- .../ycmd/cpp/BoostParts/boost/mpi/group.hpp | 340 - .../ycmd/cpp/BoostParts/boost/mpi/inplace.hpp | 63 - .../boost/mpi/intercommunicator.hpp | 165 - .../cpp/BoostParts/boost/mpi/nonblocking.hpp | 732 -- .../cpp/BoostParts/boost/mpi/operations.hpp | 322 - .../BoostParts/boost/mpi/packed_iarchive.hpp | 156 - .../BoostParts/boost/mpi/packed_oarchive.hpp | 147 - .../ycmd/cpp/BoostParts/boost/mpi/python.hpp | 79 - .../BoostParts/boost/mpi/python/config.hpp | 47 - .../BoostParts/boost/mpi/python/serialize.hpp | 539 -- .../boost/mpi/python/skeleton_and_content.hpp | 209 - .../ycmd/cpp/BoostParts/boost/mpi/request.hpp | 102 - .../boost/mpi/skeleton_and_content.hpp | 392 - .../boost/mpi/skeleton_and_content_fwd.hpp | 31 - .../ycmd/cpp/BoostParts/boost/mpi/status.hpp | 107 - .../ycmd/cpp/BoostParts/boost/mpi/timer.hpp | 91 - .../ycmd/cpp/BoostParts/boost/mpl/O1_size.hpp | 40 - .../cpp/BoostParts/boost/mpl/O1_size_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/advance.hpp | 76 - .../cpp/BoostParts/boost/mpl/advance_fwd.hpp | 28 - .../ycmd/cpp/BoostParts/boost/mpl/always.hpp | 39 - .../ycmd/cpp/BoostParts/boost/mpl/and.hpp | 60 - .../ycmd/cpp/BoostParts/boost/mpl/apply.hpp | 229 - .../cpp/BoostParts/boost/mpl/apply_fwd.hpp | 107 - .../cpp/BoostParts/boost/mpl/apply_wrap.hpp | 234 - .../ycmd/cpp/BoostParts/boost/mpl/arg.hpp | 131 - .../ycmd/cpp/BoostParts/boost/mpl/arg_fwd.hpp | 28 - .../ycmd/cpp/BoostParts/boost/mpl/assert.hpp | 438 - .../ycmd/cpp/BoostParts/boost/mpl/at.hpp | 52 - .../ycmd/cpp/BoostParts/boost/mpl/at_fwd.hpp | 24 - .../boost/mpl/aux_/O1_size_impl.hpp | 87 - .../BoostParts/boost/mpl/aux_/adl_barrier.hpp | 48 - .../boost/mpl/aux_/advance_backward.hpp | 128 - .../boost/mpl/aux_/advance_forward.hpp | 127 - .../BoostParts/boost/mpl/aux_/arg_typedef.hpp | 31 - .../boost/mpl/aux_/arithmetic_op.hpp | 92 - .../cpp/BoostParts/boost/mpl/aux_/arity.hpp | 39 - .../BoostParts/boost/mpl/aux_/arity_spec.hpp | 67 - .../cpp/BoostParts/boost/mpl/aux_/at_impl.hpp | 45 - .../BoostParts/boost/mpl/aux_/back_impl.hpp | 43 - .../boost/mpl/aux_/begin_end_impl.hpp | 101 - .../BoostParts/boost/mpl/aux_/clear_impl.hpp | 35 - .../boost/mpl/aux_/common_name_wknd.hpp | 34 - .../boost/mpl/aux_/comparison_op.hpp | 83 - .../BoostParts/boost/mpl/aux_/config/adl.hpp | 40 - .../boost/mpl/aux_/config/arrays.hpp | 30 - .../BoostParts/boost/mpl/aux_/config/bcc.hpp | 28 - .../BoostParts/boost/mpl/aux_/config/bind.hpp | 33 - .../boost/mpl/aux_/config/compiler.hpp | 66 - .../BoostParts/boost/mpl/aux_/config/ctps.hpp | 30 - .../boost/mpl/aux_/config/dependent_nttp.hpp | 35 - .../mpl/aux_/config/dmc_ambiguous_ctps.hpp | 27 - .../BoostParts/boost/mpl/aux_/config/dtp.hpp | 46 - .../BoostParts/boost/mpl/aux_/config/eti.hpp | 47 - .../boost/mpl/aux_/config/forwarding.hpp | 27 - .../BoostParts/boost/mpl/aux_/config/gcc.hpp | 23 - .../boost/mpl/aux_/config/has_apply.hpp | 32 - .../boost/mpl/aux_/config/has_xxx.hpp | 34 - .../boost/mpl/aux_/config/integral.hpp | 38 - .../boost/mpl/aux_/config/intel.hpp | 21 - .../boost/mpl/aux_/config/lambda.hpp | 32 - .../BoostParts/boost/mpl/aux_/config/msvc.hpp | 21 - .../boost/mpl/aux_/config/msvc_typename.hpp | 26 - .../BoostParts/boost/mpl/aux_/config/nttp.hpp | 41 - .../boost/mpl/aux_/config/operators.hpp | 33 - .../mpl/aux_/config/overload_resolution.hpp | 29 - .../boost/mpl/aux_/config/pp_counter.hpp | 26 - .../boost/mpl/aux_/config/preprocessor.hpp | 39 - .../boost/mpl/aux_/config/static_constant.hpp | 25 - .../BoostParts/boost/mpl/aux_/config/ttp.hpp | 41 - .../boost/mpl/aux_/config/typeof.hpp | 38 - .../mpl/aux_/config/use_preprocessed.hpp | 19 - .../boost/mpl/aux_/config/workaround.hpp | 19 - .../boost/mpl/aux_/contains_impl.hpp | 61 - .../BoostParts/boost/mpl/aux_/count_args.hpp | 105 - .../BoostParts/boost/mpl/aux_/empty_impl.hpp | 43 - .../boost/mpl/aux_/find_if_pred.hpp | 31 - .../BoostParts/boost/mpl/aux_/fold_impl.hpp | 43 - .../boost/mpl/aux_/fold_impl_body.hpp | 365 - .../BoostParts/boost/mpl/aux_/front_impl.hpp | 41 - .../BoostParts/boost/mpl/aux_/full_lambda.hpp | 354 - .../BoostParts/boost/mpl/aux_/has_apply.hpp | 32 - .../BoostParts/boost/mpl/aux_/has_begin.hpp | 23 - .../boost/mpl/aux_/has_key_impl.hpp | 34 - .../BoostParts/boost/mpl/aux_/has_rebind.hpp | 99 - .../BoostParts/boost/mpl/aux_/has_size.hpp | 23 - .../cpp/BoostParts/boost/mpl/aux_/has_tag.hpp | 23 - .../BoostParts/boost/mpl/aux_/has_type.hpp | 23 - .../boost/mpl/aux_/include_preprocessed.hpp | 42 - .../BoostParts/boost/mpl/aux_/insert_impl.hpp | 68 - .../boost/mpl/aux_/inserter_algorithm.hpp | 159 - .../boost/mpl/aux_/integral_wrapper.hpp | 93 - .../boost/mpl/aux_/is_msvc_eti_arg.hpp | 64 - .../BoostParts/boost/mpl/aux_/iter_apply.hpp | 47 - .../boost/mpl/aux_/iter_fold_if_impl.hpp | 210 - .../boost/mpl/aux_/iter_fold_impl.hpp | 42 - .../BoostParts/boost/mpl/aux_/joint_iter.hpp | 120 - .../boost/mpl/aux_/lambda_arity_param.hpp | 25 - .../boost/mpl/aux_/lambda_no_ctps.hpp | 193 - .../BoostParts/boost/mpl/aux_/lambda_spec.hpp | 49 - .../boost/mpl/aux_/lambda_support.hpp | 169 - .../BoostParts/boost/mpl/aux_/largest_int.hpp | 63 - .../BoostParts/boost/mpl/aux_/logical_op.hpp | 165 - .../BoostParts/boost/mpl/aux_/msvc_dtw.hpp | 68 - .../boost/mpl/aux_/msvc_eti_base.hpp | 77 - .../boost/mpl/aux_/msvc_is_class.hpp | 58 - .../boost/mpl/aux_/msvc_never_true.hpp | 34 - .../BoostParts/boost/mpl/aux_/msvc_type.hpp | 62 - .../ycmd/cpp/BoostParts/boost/mpl/aux_/na.hpp | 95 - .../BoostParts/boost/mpl/aux_/na_assert.hpp | 34 - .../cpp/BoostParts/boost/mpl/aux_/na_fwd.hpp | 31 - .../cpp/BoostParts/boost/mpl/aux_/na_spec.hpp | 175 - .../boost/mpl/aux_/nested_type_wknd.hpp | 48 - .../BoostParts/boost/mpl/aux_/nttp_decl.hpp | 35 - .../boost/mpl/aux_/numeric_cast_utils.hpp | 77 - .../BoostParts/boost/mpl/aux_/numeric_op.hpp | 315 - .../boost/mpl/aux_/overload_names.hpp | 48 - .../boost/mpl/aux_/pop_front_impl.hpp | 44 - .../preprocessed/bcc/advance_backward.hpp | 97 - .../aux_/preprocessed/bcc/advance_forward.hpp | 97 - .../boost/mpl/aux_/preprocessed/bcc/and.hpp | 69 - .../boost/mpl/aux_/preprocessed/bcc/apply.hpp | 169 - .../mpl/aux_/preprocessed/bcc/apply_fwd.hpp | 52 - .../mpl/aux_/preprocessed/bcc/apply_wrap.hpp | 461 - .../boost/mpl/aux_/preprocessed/bcc/arg.hpp | 117 - .../mpl/aux_/preprocessed/bcc/basic_bind.hpp | 300 - .../boost/mpl/aux_/preprocessed/bcc/bind.hpp | 397 - .../mpl/aux_/preprocessed/bcc/bind_fwd.hpp | 46 - .../mpl/aux_/preprocessed/bcc/bitand.hpp | 147 - .../boost/mpl/aux_/preprocessed/bcc/bitor.hpp | 147 - .../mpl/aux_/preprocessed/bcc/bitxor.hpp | 147 - .../boost/mpl/aux_/preprocessed/bcc/deque.hpp | 323 - .../mpl/aux_/preprocessed/bcc/divides.hpp | 146 - .../mpl/aux_/preprocessed/bcc/equal_to.hpp | 94 - .../mpl/aux_/preprocessed/bcc/fold_impl.hpp | 180 - .../mpl/aux_/preprocessed/bcc/full_lambda.hpp | 558 -- .../mpl/aux_/preprocessed/bcc/greater.hpp | 94 - .../aux_/preprocessed/bcc/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/bcc/inherit.hpp | 139 - .../preprocessed/bcc/iter_fold_if_impl.hpp | 133 - .../aux_/preprocessed/bcc/iter_fold_impl.hpp | 180 - .../aux_/preprocessed/bcc/lambda_no_ctps.hpp | 229 - .../boost/mpl/aux_/preprocessed/bcc/less.hpp | 94 - .../mpl/aux_/preprocessed/bcc/less_equal.hpp | 94 - .../boost/mpl/aux_/preprocessed/bcc/list.hpp | 323 - .../mpl/aux_/preprocessed/bcc/list_c.hpp | 328 - .../boost/mpl/aux_/preprocessed/bcc/map.hpp | 323 - .../boost/mpl/aux_/preprocessed/bcc/minus.hpp | 146 - .../mpl/aux_/preprocessed/bcc/modulus.hpp | 101 - .../aux_/preprocessed/bcc/not_equal_to.hpp | 94 - .../boost/mpl/aux_/preprocessed/bcc/or.hpp | 69 - .../aux_/preprocessed/bcc/placeholders.hpp | 105 - .../boost/mpl/aux_/preprocessed/bcc/plus.hpp | 146 - .../boost/mpl/aux_/preprocessed/bcc/quote.hpp | 119 - .../preprocessed/bcc/reverse_fold_impl.hpp | 295 - .../bcc/reverse_iter_fold_impl.hpp | 295 - .../boost/mpl/aux_/preprocessed/bcc/set.hpp | 323 - .../boost/mpl/aux_/preprocessed/bcc/set_c.hpp | 328 - .../mpl/aux_/preprocessed/bcc/shift_left.hpp | 99 - .../mpl/aux_/preprocessed/bcc/shift_right.hpp | 99 - .../aux_/preprocessed/bcc/template_arity.hpp | 40 - .../boost/mpl/aux_/preprocessed/bcc/times.hpp | 146 - .../mpl/aux_/preprocessed/bcc/unpack_args.hpp | 97 - .../mpl/aux_/preprocessed/bcc/vector.hpp | 323 - .../mpl/aux_/preprocessed/bcc/vector_c.hpp | 309 - .../preprocessed/bcc551/advance_backward.hpp | 97 - .../preprocessed/bcc551/advance_forward.hpp | 97 - .../mpl/aux_/preprocessed/bcc551/and.hpp | 69 - .../mpl/aux_/preprocessed/bcc551/apply.hpp | 169 - .../aux_/preprocessed/bcc551/apply_fwd.hpp | 52 - .../aux_/preprocessed/bcc551/apply_wrap.hpp | 456 - .../mpl/aux_/preprocessed/bcc551/arg.hpp | 123 - .../aux_/preprocessed/bcc551/basic_bind.hpp | 306 - .../mpl/aux_/preprocessed/bcc551/bind.hpp | 403 - .../mpl/aux_/preprocessed/bcc551/bind_fwd.hpp | 46 - .../mpl/aux_/preprocessed/bcc551/bitand.hpp | 147 - .../mpl/aux_/preprocessed/bcc551/bitor.hpp | 147 - .../mpl/aux_/preprocessed/bcc551/bitxor.hpp | 147 - .../mpl/aux_/preprocessed/bcc551/deque.hpp | 323 - .../mpl/aux_/preprocessed/bcc551/divides.hpp | 146 - .../mpl/aux_/preprocessed/bcc551/equal_to.hpp | 94 - .../aux_/preprocessed/bcc551/fold_impl.hpp | 180 - .../aux_/preprocessed/bcc551/full_lambda.hpp | 558 -- .../mpl/aux_/preprocessed/bcc551/greater.hpp | 94 - .../preprocessed/bcc551/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/bcc551/inherit.hpp | 141 - .../preprocessed/bcc551/iter_fold_if_impl.hpp | 133 - .../preprocessed/bcc551/iter_fold_impl.hpp | 180 - .../preprocessed/bcc551/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/bcc551/less.hpp | 94 - .../aux_/preprocessed/bcc551/less_equal.hpp | 94 - .../mpl/aux_/preprocessed/bcc551/list.hpp | 323 - .../mpl/aux_/preprocessed/bcc551/list_c.hpp | 328 - .../mpl/aux_/preprocessed/bcc551/map.hpp | 323 - .../mpl/aux_/preprocessed/bcc551/minus.hpp | 146 - .../mpl/aux_/preprocessed/bcc551/modulus.hpp | 101 - .../aux_/preprocessed/bcc551/not_equal_to.hpp | 94 - .../boost/mpl/aux_/preprocessed/bcc551/or.hpp | 69 - .../aux_/preprocessed/bcc551/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/bcc551/plus.hpp | 146 - .../mpl/aux_/preprocessed/bcc551/quote.hpp | 11 - .../preprocessed/bcc551/reverse_fold_impl.hpp | 295 - .../bcc551/reverse_iter_fold_impl.hpp | 295 - .../mpl/aux_/preprocessed/bcc551/set.hpp | 323 - .../mpl/aux_/preprocessed/bcc551/set_c.hpp | 328 - .../aux_/preprocessed/bcc551/shift_left.hpp | 99 - .../aux_/preprocessed/bcc551/shift_right.hpp | 99 - .../preprocessed/bcc551/template_arity.hpp | 40 - .../mpl/aux_/preprocessed/bcc551/times.hpp | 146 - .../aux_/preprocessed/bcc551/unpack_args.hpp | 97 - .../mpl/aux_/preprocessed/bcc551/vector.hpp | 323 - .../mpl/aux_/preprocessed/bcc551/vector_c.hpp | 309 - .../bcc_pre590/advance_backward.hpp | 97 - .../bcc_pre590/advance_forward.hpp | 97 - .../mpl/aux_/preprocessed/bcc_pre590/and.hpp | 69 - .../aux_/preprocessed/bcc_pre590/apply.hpp | 169 - .../preprocessed/bcc_pre590/apply_fwd.hpp | 52 - .../preprocessed/bcc_pre590/apply_wrap.hpp | 456 - .../mpl/aux_/preprocessed/bcc_pre590/arg.hpp | 117 - .../preprocessed/bcc_pre590/basic_bind.hpp | 300 - .../mpl/aux_/preprocessed/bcc_pre590/bind.hpp | 397 - .../aux_/preprocessed/bcc_pre590/bind_fwd.hpp | 46 - .../aux_/preprocessed/bcc_pre590/bitand.hpp | 147 - .../aux_/preprocessed/bcc_pre590/bitor.hpp | 147 - .../aux_/preprocessed/bcc_pre590/bitxor.hpp | 147 - .../aux_/preprocessed/bcc_pre590/deque.hpp | 323 - .../aux_/preprocessed/bcc_pre590/divides.hpp | 146 - .../aux_/preprocessed/bcc_pre590/equal_to.hpp | 94 - .../preprocessed/bcc_pre590/fold_impl.hpp | 180 - .../preprocessed/bcc_pre590/full_lambda.hpp | 558 -- .../aux_/preprocessed/bcc_pre590/greater.hpp | 94 - .../preprocessed/bcc_pre590/greater_equal.hpp | 94 - .../aux_/preprocessed/bcc_pre590/inherit.hpp | 139 - .../bcc_pre590/iter_fold_if_impl.hpp | 133 - .../bcc_pre590/iter_fold_impl.hpp | 180 - .../bcc_pre590/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/bcc_pre590/less.hpp | 94 - .../preprocessed/bcc_pre590/less_equal.hpp | 94 - .../mpl/aux_/preprocessed/bcc_pre590/list.hpp | 323 - .../aux_/preprocessed/bcc_pre590/list_c.hpp | 328 - .../mpl/aux_/preprocessed/bcc_pre590/map.hpp | 323 - .../aux_/preprocessed/bcc_pre590/minus.hpp | 146 - .../aux_/preprocessed/bcc_pre590/modulus.hpp | 101 - .../preprocessed/bcc_pre590/not_equal_to.hpp | 94 - .../mpl/aux_/preprocessed/bcc_pre590/or.hpp | 69 - .../preprocessed/bcc_pre590/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/bcc_pre590/plus.hpp | 146 - .../aux_/preprocessed/bcc_pre590/quote.hpp | 11 - .../bcc_pre590/reverse_fold_impl.hpp | 295 - .../bcc_pre590/reverse_iter_fold_impl.hpp | 295 - .../mpl/aux_/preprocessed/bcc_pre590/set.hpp | 323 - .../aux_/preprocessed/bcc_pre590/set_c.hpp | 328 - .../preprocessed/bcc_pre590/shift_left.hpp | 99 - .../preprocessed/bcc_pre590/shift_right.hpp | 99 - .../bcc_pre590/template_arity.hpp | 40 - .../aux_/preprocessed/bcc_pre590/times.hpp | 146 - .../preprocessed/bcc_pre590/unpack_args.hpp | 97 - .../aux_/preprocessed/bcc_pre590/vector.hpp | 323 - .../aux_/preprocessed/bcc_pre590/vector_c.hpp | 309 - .../preprocessed/dmc/advance_backward.hpp | 97 - .../aux_/preprocessed/dmc/advance_forward.hpp | 97 - .../boost/mpl/aux_/preprocessed/dmc/and.hpp | 69 - .../boost/mpl/aux_/preprocessed/dmc/apply.hpp | 169 - .../mpl/aux_/preprocessed/dmc/apply_fwd.hpp | 52 - .../mpl/aux_/preprocessed/dmc/apply_wrap.hpp | 84 - .../boost/mpl/aux_/preprocessed/dmc/arg.hpp | 123 - .../mpl/aux_/preprocessed/dmc/basic_bind.hpp | 406 - .../boost/mpl/aux_/preprocessed/dmc/bind.hpp | 515 -- .../mpl/aux_/preprocessed/dmc/bind_fwd.hpp | 53 - .../mpl/aux_/preprocessed/dmc/bitand.hpp | 147 - .../boost/mpl/aux_/preprocessed/dmc/bitor.hpp | 147 - .../mpl/aux_/preprocessed/dmc/bitxor.hpp | 147 - .../boost/mpl/aux_/preprocessed/dmc/deque.hpp | 323 - .../mpl/aux_/preprocessed/dmc/divides.hpp | 146 - .../mpl/aux_/preprocessed/dmc/equal_to.hpp | 94 - .../mpl/aux_/preprocessed/dmc/fold_impl.hpp | 180 - .../mpl/aux_/preprocessed/dmc/full_lambda.hpp | 536 -- .../mpl/aux_/preprocessed/dmc/greater.hpp | 94 - .../aux_/preprocessed/dmc/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/dmc/inherit.hpp | 141 - .../preprocessed/dmc/iter_fold_if_impl.hpp | 133 - .../aux_/preprocessed/dmc/iter_fold_impl.hpp | 180 - .../aux_/preprocessed/dmc/lambda_no_ctps.hpp | 229 - .../boost/mpl/aux_/preprocessed/dmc/less.hpp | 94 - .../mpl/aux_/preprocessed/dmc/less_equal.hpp | 94 - .../boost/mpl/aux_/preprocessed/dmc/list.hpp | 323 - .../mpl/aux_/preprocessed/dmc/list_c.hpp | 328 - .../boost/mpl/aux_/preprocessed/dmc/map.hpp | 323 - .../boost/mpl/aux_/preprocessed/dmc/minus.hpp | 146 - .../mpl/aux_/preprocessed/dmc/modulus.hpp | 101 - .../aux_/preprocessed/dmc/not_equal_to.hpp | 94 - .../boost/mpl/aux_/preprocessed/dmc/or.hpp | 69 - .../aux_/preprocessed/dmc/placeholders.hpp | 105 - .../boost/mpl/aux_/preprocessed/dmc/plus.hpp | 146 - .../boost/mpl/aux_/preprocessed/dmc/quote.hpp | 123 - .../preprocessed/dmc/reverse_fold_impl.hpp | 231 - .../dmc/reverse_iter_fold_impl.hpp | 231 - .../boost/mpl/aux_/preprocessed/dmc/set.hpp | 323 - .../boost/mpl/aux_/preprocessed/dmc/set_c.hpp | 328 - .../mpl/aux_/preprocessed/dmc/shift_left.hpp | 99 - .../mpl/aux_/preprocessed/dmc/shift_right.hpp | 99 - .../aux_/preprocessed/dmc/template_arity.hpp | 11 - .../boost/mpl/aux_/preprocessed/dmc/times.hpp | 146 - .../mpl/aux_/preprocessed/dmc/unpack_args.hpp | 94 - .../mpl/aux_/preprocessed/dmc/vector.hpp | 323 - .../mpl/aux_/preprocessed/dmc/vector_c.hpp | 309 - .../preprocessed/gcc/advance_backward.hpp | 97 - .../aux_/preprocessed/gcc/advance_forward.hpp | 97 - .../boost/mpl/aux_/preprocessed/gcc/and.hpp | 69 - .../boost/mpl/aux_/preprocessed/gcc/apply.hpp | 169 - .../mpl/aux_/preprocessed/gcc/apply_fwd.hpp | 52 - .../mpl/aux_/preprocessed/gcc/apply_wrap.hpp | 84 - .../boost/mpl/aux_/preprocessed/gcc/arg.hpp | 123 - .../mpl/aux_/preprocessed/gcc/basic_bind.hpp | 440 - .../boost/mpl/aux_/preprocessed/gcc/bind.hpp | 561 -- .../mpl/aux_/preprocessed/gcc/bind_fwd.hpp | 52 - .../mpl/aux_/preprocessed/gcc/bitand.hpp | 147 - .../boost/mpl/aux_/preprocessed/gcc/bitor.hpp | 147 - .../mpl/aux_/preprocessed/gcc/bitxor.hpp | 147 - .../boost/mpl/aux_/preprocessed/gcc/deque.hpp | 323 - .../mpl/aux_/preprocessed/gcc/divides.hpp | 146 - .../mpl/aux_/preprocessed/gcc/equal_to.hpp | 94 - .../mpl/aux_/preprocessed/gcc/fold_impl.hpp | 180 - .../mpl/aux_/preprocessed/gcc/full_lambda.hpp | 558 -- .../mpl/aux_/preprocessed/gcc/greater.hpp | 94 - .../aux_/preprocessed/gcc/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/gcc/inherit.hpp | 141 - .../preprocessed/gcc/iter_fold_if_impl.hpp | 133 - .../aux_/preprocessed/gcc/iter_fold_impl.hpp | 180 - .../aux_/preprocessed/gcc/lambda_no_ctps.hpp | 229 - .../boost/mpl/aux_/preprocessed/gcc/less.hpp | 94 - .../mpl/aux_/preprocessed/gcc/less_equal.hpp | 94 - .../boost/mpl/aux_/preprocessed/gcc/list.hpp | 323 - .../mpl/aux_/preprocessed/gcc/list_c.hpp | 328 - .../boost/mpl/aux_/preprocessed/gcc/map.hpp | 323 - .../boost/mpl/aux_/preprocessed/gcc/minus.hpp | 146 - .../mpl/aux_/preprocessed/gcc/modulus.hpp | 101 - .../aux_/preprocessed/gcc/not_equal_to.hpp | 94 - .../boost/mpl/aux_/preprocessed/gcc/or.hpp | 69 - .../aux_/preprocessed/gcc/placeholders.hpp | 105 - .../boost/mpl/aux_/preprocessed/gcc/plus.hpp | 146 - .../boost/mpl/aux_/preprocessed/gcc/quote.hpp | 123 - .../preprocessed/gcc/reverse_fold_impl.hpp | 231 - .../gcc/reverse_iter_fold_impl.hpp | 231 - .../boost/mpl/aux_/preprocessed/gcc/set.hpp | 323 - .../boost/mpl/aux_/preprocessed/gcc/set_c.hpp | 328 - .../mpl/aux_/preprocessed/gcc/shift_left.hpp | 99 - .../mpl/aux_/preprocessed/gcc/shift_right.hpp | 99 - .../aux_/preprocessed/gcc/template_arity.hpp | 97 - .../boost/mpl/aux_/preprocessed/gcc/times.hpp | 146 - .../mpl/aux_/preprocessed/gcc/unpack_args.hpp | 94 - .../mpl/aux_/preprocessed/gcc/vector.hpp | 323 - .../mpl/aux_/preprocessed/gcc/vector_c.hpp | 309 - .../preprocessed/msvc60/advance_backward.hpp | 132 - .../preprocessed/msvc60/advance_forward.hpp | 132 - .../mpl/aux_/preprocessed/msvc60/and.hpp | 73 - .../mpl/aux_/preprocessed/msvc60/apply.hpp | 166 - .../aux_/preprocessed/msvc60/apply_fwd.hpp | 46 - .../aux_/preprocessed/msvc60/apply_wrap.hpp | 247 - .../mpl/aux_/preprocessed/msvc60/arg.hpp | 123 - .../aux_/preprocessed/msvc60/basic_bind.hpp | 328 - .../mpl/aux_/preprocessed/msvc60/bind.hpp | 432 - .../mpl/aux_/preprocessed/msvc60/bind_fwd.hpp | 46 - .../mpl/aux_/preprocessed/msvc60/bitand.hpp | 149 - .../mpl/aux_/preprocessed/msvc60/bitor.hpp | 149 - .../mpl/aux_/preprocessed/msvc60/bitxor.hpp | 149 - .../mpl/aux_/preprocessed/msvc60/deque.hpp | 556 -- .../mpl/aux_/preprocessed/msvc60/divides.hpp | 148 - .../mpl/aux_/preprocessed/msvc60/equal_to.hpp | 102 - .../aux_/preprocessed/msvc60/fold_impl.hpp | 293 - .../aux_/preprocessed/msvc60/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/msvc60/greater.hpp | 102 - .../preprocessed/msvc60/greater_equal.hpp | 102 - .../mpl/aux_/preprocessed/msvc60/inherit.hpp | 166 - .../preprocessed/msvc60/iter_fold_if_impl.hpp | 133 - .../preprocessed/msvc60/iter_fold_impl.hpp | 293 - .../preprocessed/msvc60/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/msvc60/less.hpp | 102 - .../aux_/preprocessed/msvc60/less_equal.hpp | 102 - .../mpl/aux_/preprocessed/msvc60/list.hpp | 556 -- .../mpl/aux_/preprocessed/msvc60/list_c.hpp | 534 -- .../mpl/aux_/preprocessed/msvc60/map.hpp | 556 -- .../mpl/aux_/preprocessed/msvc60/minus.hpp | 148 - .../mpl/aux_/preprocessed/msvc60/modulus.hpp | 115 - .../aux_/preprocessed/msvc60/not_equal_to.hpp | 102 - .../boost/mpl/aux_/preprocessed/msvc60/or.hpp | 73 - .../aux_/preprocessed/msvc60/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/msvc60/plus.hpp | 148 - .../mpl/aux_/preprocessed/msvc60/quote.hpp | 11 - .../preprocessed/msvc60/reverse_fold_impl.hpp | 343 - .../msvc60/reverse_iter_fold_impl.hpp | 343 - .../mpl/aux_/preprocessed/msvc60/set.hpp | 556 -- .../mpl/aux_/preprocessed/msvc60/set_c.hpp | 534 -- .../aux_/preprocessed/msvc60/shift_left.hpp | 114 - .../aux_/preprocessed/msvc60/shift_right.hpp | 114 - .../preprocessed/msvc60/template_arity.hpp | 46 - .../mpl/aux_/preprocessed/msvc60/times.hpp | 148 - .../aux_/preprocessed/msvc60/unpack_args.hpp | 109 - .../mpl/aux_/preprocessed/msvc60/vector.hpp | 556 -- .../mpl/aux_/preprocessed/msvc60/vector_c.hpp | 534 -- .../preprocessed/msvc70/advance_backward.hpp | 97 - .../preprocessed/msvc70/advance_forward.hpp | 97 - .../mpl/aux_/preprocessed/msvc70/and.hpp | 71 - .../mpl/aux_/preprocessed/msvc70/apply.hpp | 160 - .../aux_/preprocessed/msvc70/apply_fwd.hpp | 46 - .../aux_/preprocessed/msvc70/apply_wrap.hpp | 138 - .../mpl/aux_/preprocessed/msvc70/arg.hpp | 123 - .../aux_/preprocessed/msvc70/basic_bind.hpp | 328 - .../mpl/aux_/preprocessed/msvc70/bind.hpp | 432 - .../mpl/aux_/preprocessed/msvc70/bind_fwd.hpp | 46 - .../mpl/aux_/preprocessed/msvc70/bitand.hpp | 151 - .../mpl/aux_/preprocessed/msvc70/bitor.hpp | 151 - .../mpl/aux_/preprocessed/msvc70/bitxor.hpp | 151 - .../mpl/aux_/preprocessed/msvc70/deque.hpp | 556 -- .../mpl/aux_/preprocessed/msvc70/divides.hpp | 150 - .../mpl/aux_/preprocessed/msvc70/equal_to.hpp | 102 - .../aux_/preprocessed/msvc70/fold_impl.hpp | 245 - .../aux_/preprocessed/msvc70/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/msvc70/greater.hpp | 102 - .../preprocessed/msvc70/greater_equal.hpp | 102 - .../mpl/aux_/preprocessed/msvc70/inherit.hpp | 166 - .../preprocessed/msvc70/iter_fold_if_impl.hpp | 133 - .../preprocessed/msvc70/iter_fold_impl.hpp | 245 - .../preprocessed/msvc70/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/msvc70/less.hpp | 102 - .../aux_/preprocessed/msvc70/less_equal.hpp | 102 - .../mpl/aux_/preprocessed/msvc70/list.hpp | 556 -- .../mpl/aux_/preprocessed/msvc70/list_c.hpp | 534 -- .../mpl/aux_/preprocessed/msvc70/map.hpp | 556 -- .../mpl/aux_/preprocessed/msvc70/minus.hpp | 150 - .../mpl/aux_/preprocessed/msvc70/modulus.hpp | 115 - .../aux_/preprocessed/msvc70/not_equal_to.hpp | 102 - .../boost/mpl/aux_/preprocessed/msvc70/or.hpp | 71 - .../aux_/preprocessed/msvc70/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/msvc70/plus.hpp | 150 - .../mpl/aux_/preprocessed/msvc70/quote.hpp | 116 - .../preprocessed/msvc70/reverse_fold_impl.hpp | 295 - .../msvc70/reverse_iter_fold_impl.hpp | 295 - .../mpl/aux_/preprocessed/msvc70/set.hpp | 556 -- .../mpl/aux_/preprocessed/msvc70/set_c.hpp | 534 -- .../aux_/preprocessed/msvc70/shift_left.hpp | 114 - .../aux_/preprocessed/msvc70/shift_right.hpp | 114 - .../preprocessed/msvc70/template_arity.hpp | 46 - .../mpl/aux_/preprocessed/msvc70/times.hpp | 150 - .../aux_/preprocessed/msvc70/unpack_args.hpp | 109 - .../mpl/aux_/preprocessed/msvc70/vector.hpp | 556 -- .../mpl/aux_/preprocessed/msvc70/vector_c.hpp | 534 -- .../preprocessed/mwcw/advance_backward.hpp | 97 - .../preprocessed/mwcw/advance_forward.hpp | 97 - .../boost/mpl/aux_/preprocessed/mwcw/and.hpp | 69 - .../mpl/aux_/preprocessed/mwcw/apply.hpp | 169 - .../mpl/aux_/preprocessed/mwcw/apply_fwd.hpp | 52 - .../mpl/aux_/preprocessed/mwcw/apply_wrap.hpp | 456 - .../boost/mpl/aux_/preprocessed/mwcw/arg.hpp | 123 - .../mpl/aux_/preprocessed/mwcw/basic_bind.hpp | 440 - .../boost/mpl/aux_/preprocessed/mwcw/bind.hpp | 561 -- .../mpl/aux_/preprocessed/mwcw/bind_fwd.hpp | 52 - .../mpl/aux_/preprocessed/mwcw/bitand.hpp | 147 - .../mpl/aux_/preprocessed/mwcw/bitor.hpp | 147 - .../mpl/aux_/preprocessed/mwcw/bitxor.hpp | 147 - .../mpl/aux_/preprocessed/mwcw/deque.hpp | 323 - .../mpl/aux_/preprocessed/mwcw/divides.hpp | 146 - .../mpl/aux_/preprocessed/mwcw/equal_to.hpp | 94 - .../mpl/aux_/preprocessed/mwcw/fold_impl.hpp | 180 - .../aux_/preprocessed/mwcw/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/mwcw/greater.hpp | 94 - .../aux_/preprocessed/mwcw/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/mwcw/inherit.hpp | 141 - .../preprocessed/mwcw/iter_fold_if_impl.hpp | 133 - .../aux_/preprocessed/mwcw/iter_fold_impl.hpp | 180 - .../aux_/preprocessed/mwcw/lambda_no_ctps.hpp | 229 - .../boost/mpl/aux_/preprocessed/mwcw/less.hpp | 94 - .../mpl/aux_/preprocessed/mwcw/less_equal.hpp | 94 - .../boost/mpl/aux_/preprocessed/mwcw/list.hpp | 323 - .../mpl/aux_/preprocessed/mwcw/list_c.hpp | 328 - .../boost/mpl/aux_/preprocessed/mwcw/map.hpp | 323 - .../mpl/aux_/preprocessed/mwcw/minus.hpp | 146 - .../mpl/aux_/preprocessed/mwcw/modulus.hpp | 101 - .../aux_/preprocessed/mwcw/not_equal_to.hpp | 94 - .../boost/mpl/aux_/preprocessed/mwcw/or.hpp | 69 - .../aux_/preprocessed/mwcw/placeholders.hpp | 105 - .../boost/mpl/aux_/preprocessed/mwcw/plus.hpp | 146 - .../mpl/aux_/preprocessed/mwcw/quote.hpp | 123 - .../preprocessed/mwcw/reverse_fold_impl.hpp | 231 - .../mwcw/reverse_iter_fold_impl.hpp | 231 - .../boost/mpl/aux_/preprocessed/mwcw/set.hpp | 323 - .../mpl/aux_/preprocessed/mwcw/set_c.hpp | 328 - .../mpl/aux_/preprocessed/mwcw/shift_left.hpp | 99 - .../aux_/preprocessed/mwcw/shift_right.hpp | 99 - .../aux_/preprocessed/mwcw/template_arity.hpp | 11 - .../mpl/aux_/preprocessed/mwcw/times.hpp | 146 - .../aux_/preprocessed/mwcw/unpack_args.hpp | 94 - .../mpl/aux_/preprocessed/mwcw/vector.hpp | 323 - .../mpl/aux_/preprocessed/mwcw/vector_c.hpp | 309 - .../preprocessed/no_ctps/advance_backward.hpp | 97 - .../preprocessed/no_ctps/advance_forward.hpp | 97 - .../mpl/aux_/preprocessed/no_ctps/and.hpp | 73 - .../mpl/aux_/preprocessed/no_ctps/apply.hpp | 268 - .../aux_/preprocessed/no_ctps/apply_fwd.hpp | 50 - .../aux_/preprocessed/no_ctps/apply_wrap.hpp | 78 - .../mpl/aux_/preprocessed/no_ctps/arg.hpp | 123 - .../aux_/preprocessed/no_ctps/basic_bind.hpp | 486 -- .../mpl/aux_/preprocessed/no_ctps/bind.hpp | 590 -- .../aux_/preprocessed/no_ctps/bind_fwd.hpp | 52 - .../mpl/aux_/preprocessed/no_ctps/bitand.hpp | 134 - .../mpl/aux_/preprocessed/no_ctps/bitor.hpp | 134 - .../mpl/aux_/preprocessed/no_ctps/bitxor.hpp | 134 - .../mpl/aux_/preprocessed/no_ctps/deque.hpp | 556 -- .../mpl/aux_/preprocessed/no_ctps/divides.hpp | 133 - .../aux_/preprocessed/no_ctps/equal_to.hpp | 94 - .../aux_/preprocessed/no_ctps/fold_impl.hpp | 245 - .../aux_/preprocessed/no_ctps/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/no_ctps/greater.hpp | 94 - .../preprocessed/no_ctps/greater_equal.hpp | 94 - .../mpl/aux_/preprocessed/no_ctps/inherit.hpp | 166 - .../no_ctps/iter_fold_if_impl.hpp | 133 - .../preprocessed/no_ctps/iter_fold_impl.hpp | 245 - .../preprocessed/no_ctps/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/no_ctps/less.hpp | 94 - .../aux_/preprocessed/no_ctps/less_equal.hpp | 94 - .../mpl/aux_/preprocessed/no_ctps/list.hpp | 556 -- .../mpl/aux_/preprocessed/no_ctps/list_c.hpp | 534 -- .../mpl/aux_/preprocessed/no_ctps/map.hpp | 556 -- .../mpl/aux_/preprocessed/no_ctps/minus.hpp | 133 - .../mpl/aux_/preprocessed/no_ctps/modulus.hpp | 101 - .../preprocessed/no_ctps/not_equal_to.hpp | 94 - .../mpl/aux_/preprocessed/no_ctps/or.hpp | 73 - .../preprocessed/no_ctps/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/no_ctps/plus.hpp | 133 - .../mpl/aux_/preprocessed/no_ctps/quote.hpp | 116 - .../no_ctps/reverse_fold_impl.hpp | 295 - .../no_ctps/reverse_iter_fold_impl.hpp | 295 - .../mpl/aux_/preprocessed/no_ctps/set.hpp | 556 -- .../mpl/aux_/preprocessed/no_ctps/set_c.hpp | 534 -- .../aux_/preprocessed/no_ctps/shift_left.hpp | 99 - .../aux_/preprocessed/no_ctps/shift_right.hpp | 99 - .../preprocessed/no_ctps/template_arity.hpp | 40 - .../mpl/aux_/preprocessed/no_ctps/times.hpp | 133 - .../aux_/preprocessed/no_ctps/unpack_args.hpp | 109 - .../mpl/aux_/preprocessed/no_ctps/vector.hpp | 556 -- .../aux_/preprocessed/no_ctps/vector_c.hpp | 534 -- .../preprocessed/no_ttp/advance_backward.hpp | 97 - .../preprocessed/no_ttp/advance_forward.hpp | 97 - .../mpl/aux_/preprocessed/no_ttp/and.hpp | 69 - .../mpl/aux_/preprocessed/no_ttp/apply.hpp | 169 - .../aux_/preprocessed/no_ttp/apply_fwd.hpp | 52 - .../aux_/preprocessed/no_ttp/apply_wrap.hpp | 84 - .../mpl/aux_/preprocessed/no_ttp/arg.hpp | 123 - .../aux_/preprocessed/no_ttp/basic_bind.hpp | 369 - .../mpl/aux_/preprocessed/no_ttp/bind.hpp | 466 - .../mpl/aux_/preprocessed/no_ttp/bind_fwd.hpp | 52 - .../mpl/aux_/preprocessed/no_ttp/bitand.hpp | 157 - .../mpl/aux_/preprocessed/no_ttp/bitor.hpp | 157 - .../mpl/aux_/preprocessed/no_ttp/bitxor.hpp | 157 - .../mpl/aux_/preprocessed/no_ttp/deque.hpp | 323 - .../mpl/aux_/preprocessed/no_ttp/divides.hpp | 156 - .../mpl/aux_/preprocessed/no_ttp/equal_to.hpp | 98 - .../aux_/preprocessed/no_ttp/fold_impl.hpp | 180 - .../aux_/preprocessed/no_ttp/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/no_ttp/greater.hpp | 98 - .../preprocessed/no_ttp/greater_equal.hpp | 98 - .../mpl/aux_/preprocessed/no_ttp/inherit.hpp | 141 - .../preprocessed/no_ttp/iter_fold_if_impl.hpp | 133 - .../preprocessed/no_ttp/iter_fold_impl.hpp | 180 - .../preprocessed/no_ttp/lambda_no_ctps.hpp | 229 - .../mpl/aux_/preprocessed/no_ttp/less.hpp | 98 - .../aux_/preprocessed/no_ttp/less_equal.hpp | 98 - .../mpl/aux_/preprocessed/no_ttp/list.hpp | 323 - .../mpl/aux_/preprocessed/no_ttp/list_c.hpp | 328 - .../mpl/aux_/preprocessed/no_ttp/map.hpp | 323 - .../mpl/aux_/preprocessed/no_ttp/minus.hpp | 156 - .../mpl/aux_/preprocessed/no_ttp/modulus.hpp | 111 - .../aux_/preprocessed/no_ttp/not_equal_to.hpp | 98 - .../boost/mpl/aux_/preprocessed/no_ttp/or.hpp | 69 - .../aux_/preprocessed/no_ttp/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/no_ttp/plus.hpp | 156 - .../mpl/aux_/preprocessed/no_ttp/quote.hpp | 11 - .../preprocessed/no_ttp/reverse_fold_impl.hpp | 231 - .../no_ttp/reverse_iter_fold_impl.hpp | 231 - .../mpl/aux_/preprocessed/no_ttp/set.hpp | 323 - .../mpl/aux_/preprocessed/no_ttp/set_c.hpp | 328 - .../aux_/preprocessed/no_ttp/shift_left.hpp | 110 - .../aux_/preprocessed/no_ttp/shift_right.hpp | 110 - .../preprocessed/no_ttp/template_arity.hpp | 40 - .../mpl/aux_/preprocessed/no_ttp/times.hpp | 156 - .../aux_/preprocessed/no_ttp/unpack_args.hpp | 94 - .../mpl/aux_/preprocessed/no_ttp/vector.hpp | 323 - .../mpl/aux_/preprocessed/no_ttp/vector_c.hpp | 309 - .../preprocessed/plain/advance_backward.hpp | 97 - .../preprocessed/plain/advance_forward.hpp | 97 - .../boost/mpl/aux_/preprocessed/plain/and.hpp | 64 - .../mpl/aux_/preprocessed/plain/apply.hpp | 139 - .../mpl/aux_/preprocessed/plain/apply_fwd.hpp | 52 - .../aux_/preprocessed/plain/apply_wrap.hpp | 84 - .../boost/mpl/aux_/preprocessed/plain/arg.hpp | 123 - .../aux_/preprocessed/plain/basic_bind.hpp | 440 - .../mpl/aux_/preprocessed/plain/bind.hpp | 561 -- .../mpl/aux_/preprocessed/plain/bind_fwd.hpp | 52 - .../mpl/aux_/preprocessed/plain/bitand.hpp | 142 - .../mpl/aux_/preprocessed/plain/bitor.hpp | 142 - .../mpl/aux_/preprocessed/plain/bitxor.hpp | 142 - .../mpl/aux_/preprocessed/plain/deque.hpp | 323 - .../mpl/aux_/preprocessed/plain/divides.hpp | 141 - .../mpl/aux_/preprocessed/plain/equal_to.hpp | 92 - .../mpl/aux_/preprocessed/plain/fold_impl.hpp | 180 - .../aux_/preprocessed/plain/full_lambda.hpp | 554 -- .../mpl/aux_/preprocessed/plain/greater.hpp | 92 - .../aux_/preprocessed/plain/greater_equal.hpp | 92 - .../mpl/aux_/preprocessed/plain/inherit.hpp | 125 - .../preprocessed/plain/iter_fold_if_impl.hpp | 133 - .../preprocessed/plain/iter_fold_impl.hpp | 180 - .../preprocessed/plain/lambda_no_ctps.hpp | 228 - .../mpl/aux_/preprocessed/plain/less.hpp | 92 - .../aux_/preprocessed/plain/less_equal.hpp | 92 - .../mpl/aux_/preprocessed/plain/list.hpp | 323 - .../mpl/aux_/preprocessed/plain/list_c.hpp | 328 - .../boost/mpl/aux_/preprocessed/plain/map.hpp | 323 - .../mpl/aux_/preprocessed/plain/minus.hpp | 141 - .../mpl/aux_/preprocessed/plain/modulus.hpp | 99 - .../aux_/preprocessed/plain/not_equal_to.hpp | 92 - .../boost/mpl/aux_/preprocessed/plain/or.hpp | 64 - .../aux_/preprocessed/plain/placeholders.hpp | 105 - .../mpl/aux_/preprocessed/plain/plus.hpp | 141 - .../mpl/aux_/preprocessed/plain/quote.hpp | 123 - .../preprocessed/plain/reverse_fold_impl.hpp | 231 - .../plain/reverse_iter_fold_impl.hpp | 231 - .../boost/mpl/aux_/preprocessed/plain/set.hpp | 323 - .../mpl/aux_/preprocessed/plain/set_c.hpp | 328 - .../aux_/preprocessed/plain/shift_left.hpp | 97 - .../aux_/preprocessed/plain/shift_right.hpp | 97 - .../preprocessed/plain/template_arity.hpp | 11 - .../mpl/aux_/preprocessed/plain/times.hpp | 141 - .../aux_/preprocessed/plain/unpack_args.hpp | 94 - .../mpl/aux_/preprocessed/plain/vector.hpp | 323 - .../mpl/aux_/preprocessed/plain/vector_c.hpp | 309 - .../boost/mpl/aux_/preprocessor/add.hpp | 65 - .../mpl/aux_/preprocessor/def_params_tail.hpp | 105 - .../mpl/aux_/preprocessor/default_params.hpp | 67 - .../boost/mpl/aux_/preprocessor/enum.hpp | 62 - .../mpl/aux_/preprocessor/ext_params.hpp | 78 - .../mpl/aux_/preprocessor/filter_params.hpp | 28 - .../boost/mpl/aux_/preprocessor/params.hpp | 65 - .../aux_/preprocessor/partial_spec_params.hpp | 32 - .../boost/mpl/aux_/preprocessor/range.hpp | 23 - .../boost/mpl/aux_/preprocessor/repeat.hpp | 51 - .../boost/mpl/aux_/preprocessor/sub.hpp | 65 - .../boost/mpl/aux_/preprocessor/tuple.hpp | 29 - .../BoostParts/boost/mpl/aux_/ptr_to_ref.hpp | 46 - .../boost/mpl/aux_/push_back_impl.hpp | 70 - .../boost/mpl/aux_/push_front_impl.hpp | 71 - .../boost/mpl/aux_/reverse_fold_impl.hpp | 44 - .../boost/mpl/aux_/reverse_fold_impl_body.hpp | 412 - .../boost/mpl/aux_/reverse_iter_fold_impl.hpp | 43 - .../boost/mpl/aux_/sequence_wrapper.hpp | 292 - .../boost/mpl/aux_/single_element_iter.hpp | 118 - .../BoostParts/boost/mpl/aux_/size_impl.hpp | 52 - .../BoostParts/boost/mpl/aux_/static_cast.hpp | 27 - .../boost/mpl/aux_/template_arity.hpp | 189 - .../boost/mpl/aux_/template_arity_fwd.hpp | 23 - .../boost/mpl/aux_/traits_lambda_spec.hpp | 63 - .../boost/mpl/aux_/type_wrapper.hpp | 47 - .../cpp/BoostParts/boost/mpl/aux_/unwrap.hpp | 47 - .../BoostParts/boost/mpl/aux_/value_wknd.hpp | 89 - .../cpp/BoostParts/boost/mpl/aux_/yes_no.hpp | 58 - .../ycmd/cpp/BoostParts/boost/mpl/back.hpp | 39 - .../cpp/BoostParts/boost/mpl/back_fwd.hpp | 24 - .../BoostParts/boost/mpl/back_inserter.hpp | 34 - .../ycmd/cpp/BoostParts/boost/mpl/base.hpp | 35 - .../ycmd/cpp/BoostParts/boost/mpl/begin.hpp | 19 - .../cpp/BoostParts/boost/mpl/begin_end.hpp | 57 - .../BoostParts/boost/mpl/begin_end_fwd.hpp | 27 - .../ycmd/cpp/BoostParts/boost/mpl/bind.hpp | 551 -- .../cpp/BoostParts/boost/mpl/bind_fwd.hpp | 99 - .../ycmd/cpp/BoostParts/boost/mpl/bool.hpp | 39 - .../cpp/BoostParts/boost/mpl/bool_fwd.hpp | 33 - .../ycmd/cpp/BoostParts/boost/mpl/clear.hpp | 39 - .../cpp/BoostParts/boost/mpl/clear_fwd.hpp | 24 - .../cpp/BoostParts/boost/mpl/comparison.hpp | 24 - .../cpp/BoostParts/boost/mpl/contains.hpp | 41 - .../cpp/BoostParts/boost/mpl/contains_fwd.hpp | 25 - .../ycmd/cpp/BoostParts/boost/mpl/copy.hpp | 58 - .../ycmd/cpp/BoostParts/boost/mpl/deref.hpp | 41 - .../cpp/BoostParts/boost/mpl/distance.hpp | 78 - .../cpp/BoostParts/boost/mpl/distance_fwd.hpp | 28 - .../ycmd/cpp/BoostParts/boost/mpl/empty.hpp | 39 - .../cpp/BoostParts/boost/mpl/empty_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/end.hpp | 19 - .../cpp/BoostParts/boost/mpl/equal_to.hpp | 21 - .../cpp/BoostParts/boost/mpl/erase_fwd.hpp | 24 - .../BoostParts/boost/mpl/erase_key_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/eval_if.hpp | 71 - .../ycmd/cpp/BoostParts/boost/mpl/find.hpp | 38 - .../ycmd/cpp/BoostParts/boost/mpl/find_if.hpp | 50 - .../ycmd/cpp/BoostParts/boost/mpl/fold.hpp | 48 - .../cpp/BoostParts/boost/mpl/for_each.hpp | 116 - .../ycmd/cpp/BoostParts/boost/mpl/front.hpp | 39 - .../cpp/BoostParts/boost/mpl/front_fwd.hpp | 24 - .../BoostParts/boost/mpl/front_inserter.hpp | 33 - .../ycmd/cpp/BoostParts/boost/mpl/greater.hpp | 21 - .../BoostParts/boost/mpl/greater_equal.hpp | 21 - .../ycmd/cpp/BoostParts/boost/mpl/has_key.hpp | 41 - .../cpp/BoostParts/boost/mpl/has_key_fwd.hpp | 25 - .../ycmd/cpp/BoostParts/boost/mpl/has_xxx.hpp | 640 -- .../cpp/BoostParts/boost/mpl/identity.hpp | 45 - .../ycmd/cpp/BoostParts/boost/mpl/if.hpp | 135 - .../ycmd/cpp/BoostParts/boost/mpl/insert.hpp | 41 - .../cpp/BoostParts/boost/mpl/insert_fwd.hpp | 24 - .../cpp/BoostParts/boost/mpl/inserter.hpp | 32 - .../ycmd/cpp/BoostParts/boost/mpl/int.hpp | 22 - .../ycmd/cpp/BoostParts/boost/mpl/int_fwd.hpp | 27 - .../cpp/BoostParts/boost/mpl/integral_c.hpp | 51 - .../BoostParts/boost/mpl/integral_c_fwd.hpp | 32 - .../BoostParts/boost/mpl/integral_c_tag.hpp | 26 - .../BoostParts/boost/mpl/is_placeholder.hpp | 67 - .../cpp/BoostParts/boost/mpl/is_sequence.hpp | 112 - .../cpp/BoostParts/boost/mpl/iter_fold.hpp | 49 - .../cpp/BoostParts/boost/mpl/iter_fold_if.hpp | 117 - .../boost/mpl/iterator_category.hpp | 35 - .../BoostParts/boost/mpl/iterator_range.hpp | 42 - .../BoostParts/boost/mpl/iterator_tags.hpp | 27 - .../cpp/BoostParts/boost/mpl/joint_view.hpp | 65 - .../cpp/BoostParts/boost/mpl/key_type_fwd.hpp | 25 - .../ycmd/cpp/BoostParts/boost/mpl/lambda.hpp | 29 - .../cpp/BoostParts/boost/mpl/lambda_fwd.hpp | 57 - .../ycmd/cpp/BoostParts/boost/mpl/less.hpp | 21 - .../cpp/BoostParts/boost/mpl/less_equal.hpp | 21 - .../cpp/BoostParts/boost/mpl/limits/arity.hpp | 21 - .../cpp/BoostParts/boost/mpl/limits/list.hpp | 21 - .../BoostParts/boost/mpl/limits/unrolling.hpp | 21 - .../BoostParts/boost/mpl/limits/vector.hpp | 21 - .../ycmd/cpp/BoostParts/boost/mpl/list.hpp | 57 - .../boost/mpl/list/aux_/O1_size.hpp | 33 - .../boost/mpl/list/aux_/begin_end.hpp | 44 - .../BoostParts/boost/mpl/list/aux_/clear.hpp | 34 - .../BoostParts/boost/mpl/list/aux_/empty.hpp | 34 - .../BoostParts/boost/mpl/list/aux_/front.hpp | 33 - .../mpl/list/aux_/include_preprocessed.hpp | 35 - .../BoostParts/boost/mpl/list/aux_/item.hpp | 55 - .../boost/mpl/list/aux_/iterator.hpp | 76 - .../boost/mpl/list/aux_/numbered.hpp | 68 - .../boost/mpl/list/aux_/numbered_c.hpp | 71 - .../boost/mpl/list/aux_/pop_front.hpp | 34 - .../list/aux_/preprocessed/plain/list10.hpp | 149 - .../list/aux_/preprocessed/plain/list10_c.hpp | 164 - .../list/aux_/preprocessed/plain/list20.hpp | 169 - .../list/aux_/preprocessed/plain/list20_c.hpp | 173 - .../list/aux_/preprocessed/plain/list30.hpp | 189 - .../list/aux_/preprocessed/plain/list30_c.hpp | 183 - .../list/aux_/preprocessed/plain/list40.hpp | 209 - .../list/aux_/preprocessed/plain/list40_c.hpp | 193 - .../list/aux_/preprocessed/plain/list50.hpp | 229 - .../list/aux_/preprocessed/plain/list50_c.hpp | 203 - .../boost/mpl/list/aux_/push_back.hpp | 36 - .../boost/mpl/list/aux_/push_front.hpp | 39 - .../BoostParts/boost/mpl/list/aux_/size.hpp | 33 - .../BoostParts/boost/mpl/list/aux_/tag.hpp | 24 - .../cpp/BoostParts/boost/mpl/list/list0.hpp | 42 - .../cpp/BoostParts/boost/mpl/list/list0_c.hpp | 31 - .../cpp/BoostParts/boost/mpl/list/list10.hpp | 43 - .../BoostParts/boost/mpl/list/list10_c.hpp | 43 - .../cpp/BoostParts/boost/mpl/list/list20.hpp | 43 - .../BoostParts/boost/mpl/list/list20_c.hpp | 43 - .../cpp/BoostParts/boost/mpl/list/list30.hpp | 43 - .../BoostParts/boost/mpl/list/list30_c.hpp | 43 - .../cpp/BoostParts/boost/mpl/list/list40.hpp | 43 - .../BoostParts/boost/mpl/list/list40_c.hpp | 43 - .../cpp/BoostParts/boost/mpl/list/list50.hpp | 43 - .../BoostParts/boost/mpl/list/list50_c.hpp | 43 - .../ycmd/cpp/BoostParts/boost/mpl/logical.hpp | 21 - .../ycmd/cpp/BoostParts/boost/mpl/long.hpp | 22 - .../cpp/BoostParts/boost/mpl/long_fwd.hpp | 27 - .../ycmd/cpp/BoostParts/boost/mpl/min_max.hpp | 46 - .../ycmd/cpp/BoostParts/boost/mpl/minus.hpp | 21 - .../cpp/BoostParts/boost/mpl/multiplies.hpp | 53 - .../ycmd/cpp/BoostParts/boost/mpl/negate.hpp | 81 - .../ycmd/cpp/BoostParts/boost/mpl/next.hpp | 19 - .../cpp/BoostParts/boost/mpl/next_prior.hpp | 49 - .../ycmd/cpp/BoostParts/boost/mpl/not.hpp | 51 - .../cpp/BoostParts/boost/mpl/not_equal_to.hpp | 21 - .../cpp/BoostParts/boost/mpl/numeric_cast.hpp | 41 - .../ycmd/cpp/BoostParts/boost/mpl/or.hpp | 61 - .../ycmd/cpp/BoostParts/boost/mpl/pair.hpp | 70 - .../cpp/BoostParts/boost/mpl/pair_view.hpp | 169 - .../cpp/BoostParts/boost/mpl/placeholders.hpp | 100 - .../ycmd/cpp/BoostParts/boost/mpl/plus.hpp | 21 - .../cpp/BoostParts/boost/mpl/pop_back_fwd.hpp | 24 - .../cpp/BoostParts/boost/mpl/pop_front.hpp | 39 - .../BoostParts/boost/mpl/pop_front_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/print.hpp | 74 - .../ycmd/cpp/BoostParts/boost/mpl/prior.hpp | 19 - .../ycmd/cpp/BoostParts/boost/mpl/protect.hpp | 55 - .../cpp/BoostParts/boost/mpl/push_back.hpp | 53 - .../BoostParts/boost/mpl/push_back_fwd.hpp | 24 - .../cpp/BoostParts/boost/mpl/push_front.hpp | 52 - .../BoostParts/boost/mpl/push_front_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/quote.hpp | 151 - .../cpp/BoostParts/boost/mpl/remove_if.hpp | 83 - .../cpp/BoostParts/boost/mpl/reverse_fold.hpp | 50 - .../boost/mpl/reverse_iter_fold.hpp | 56 - .../ycmd/cpp/BoostParts/boost/mpl/same_as.hpp | 55 - .../cpp/BoostParts/boost/mpl/sequence_tag.hpp | 124 - .../BoostParts/boost/mpl/sequence_tag_fwd.hpp | 26 - .../BoostParts/boost/mpl/set/aux_/at_impl.hpp | 40 - .../boost/mpl/set/aux_/begin_end_impl.hpp | 43 - .../boost/mpl/set/aux_/clear_impl.hpp | 35 - .../boost/mpl/set/aux_/empty_impl.hpp | 34 - .../boost/mpl/set/aux_/erase_impl.hpp | 41 - .../boost/mpl/set/aux_/erase_key_impl.hpp | 53 - .../boost/mpl/set/aux_/has_key_impl.hpp | 60 - .../boost/mpl/set/aux_/insert_impl.hpp | 65 - .../BoostParts/boost/mpl/set/aux_/item.hpp | 80 - .../boost/mpl/set/aux_/iterator.hpp | 98 - .../boost/mpl/set/aux_/key_type_impl.hpp | 34 - .../BoostParts/boost/mpl/set/aux_/set0.hpp | 69 - .../boost/mpl/set/aux_/size_impl.hpp | 33 - .../cpp/BoostParts/boost/mpl/set/aux_/tag.hpp | 24 - .../boost/mpl/set/aux_/value_type_impl.hpp | 34 - .../cpp/BoostParts/boost/mpl/set/set0.hpp | 35 - .../cpp/BoostParts/boost/mpl/single_view.hpp | 38 - .../ycmd/cpp/BoostParts/boost/mpl/size.hpp | 42 - .../cpp/BoostParts/boost/mpl/size_fwd.hpp | 24 - .../ycmd/cpp/BoostParts/boost/mpl/size_t.hpp | 25 - .../cpp/BoostParts/boost/mpl/size_t_fwd.hpp | 28 - .../ycmd/cpp/BoostParts/boost/mpl/tag.hpp | 52 - .../ycmd/cpp/BoostParts/boost/mpl/times.hpp | 21 - .../cpp/BoostParts/boost/mpl/transform.hpp | 145 - .../BoostParts/boost/mpl/value_type_fwd.hpp | 25 - .../ycmd/cpp/BoostParts/boost/mpl/vector.hpp | 57 - .../boost/mpl/vector/aux_/O1_size.hpp | 56 - .../BoostParts/boost/mpl/vector/aux_/at.hpp | 116 - .../BoostParts/boost/mpl/vector/aux_/back.hpp | 59 - .../boost/mpl/vector/aux_/begin_end.hpp | 49 - .../boost/mpl/vector/aux_/clear.hpp | 55 - .../boost/mpl/vector/aux_/empty.hpp | 68 - .../boost/mpl/vector/aux_/front.hpp | 56 - .../mpl/vector/aux_/include_preprocessed.hpp | 55 - .../BoostParts/boost/mpl/vector/aux_/item.hpp | 103 - .../boost/mpl/vector/aux_/iterator.hpp | 130 - .../boost/mpl/vector/aux_/numbered.hpp | 218 - .../boost/mpl/vector/aux_/numbered_c.hpp | 77 - .../boost/mpl/vector/aux_/pop_back.hpp | 40 - .../boost/mpl/vector/aux_/pop_front.hpp | 40 - .../aux_/preprocessed/no_ctps/vector10.hpp | 1528 ---- .../aux_/preprocessed/no_ctps/vector10_c.hpp | 149 - .../aux_/preprocessed/no_ctps/vector20.hpp | 1804 ---- .../aux_/preprocessed/no_ctps/vector20_c.hpp | 195 - .../aux_/preprocessed/no_ctps/vector30.hpp | 2124 ----- .../aux_/preprocessed/no_ctps/vector30_c.hpp | 238 - .../aux_/preprocessed/no_ctps/vector40.hpp | 2444 ------ .../aux_/preprocessed/no_ctps/vector40_c.hpp | 281 - .../aux_/preprocessed/no_ctps/vector50.hpp | 2764 ------ .../aux_/preprocessed/no_ctps/vector50_c.hpp | 325 - .../aux_/preprocessed/plain/vector10.hpp | 829 -- .../aux_/preprocessed/plain/vector10_c.hpp | 149 - .../aux_/preprocessed/plain/vector20.hpp | 1144 --- .../aux_/preprocessed/plain/vector20_c.hpp | 195 - .../aux_/preprocessed/plain/vector30.hpp | 1464 ---- .../aux_/preprocessed/plain/vector30_c.hpp | 238 - .../aux_/preprocessed/plain/vector40.hpp | 1784 ---- .../aux_/preprocessed/plain/vector40_c.hpp | 281 - .../aux_/preprocessed/plain/vector50.hpp | 2104 ----- .../aux_/preprocessed/plain/vector50_c.hpp | 325 - .../preprocessed/typeof_based/vector10.hpp | 139 - .../preprocessed/typeof_based/vector10_c.hpp | 154 - .../preprocessed/typeof_based/vector20.hpp | 159 - .../preprocessed/typeof_based/vector20_c.hpp | 163 - .../preprocessed/typeof_based/vector30.hpp | 179 - .../preprocessed/typeof_based/vector30_c.hpp | 173 - .../preprocessed/typeof_based/vector40.hpp | 199 - .../preprocessed/typeof_based/vector40_c.hpp | 183 - .../preprocessed/typeof_based/vector50.hpp | 219 - .../preprocessed/typeof_based/vector50_c.hpp | 193 - .../boost/mpl/vector/aux_/push_back.hpp | 40 - .../boost/mpl/vector/aux_/push_front.hpp | 40 - .../BoostParts/boost/mpl/vector/aux_/size.hpp | 49 - .../BoostParts/boost/mpl/vector/aux_/tag.hpp | 32 - .../boost/mpl/vector/aux_/vector0.hpp | 52 - .../BoostParts/boost/mpl/vector/vector0.hpp | 34 - .../BoostParts/boost/mpl/vector/vector0_c.hpp | 31 - .../BoostParts/boost/mpl/vector/vector10.hpp | 45 - .../boost/mpl/vector/vector10_c.hpp | 46 - .../BoostParts/boost/mpl/vector/vector20.hpp | 45 - .../boost/mpl/vector/vector20_c.hpp | 46 - .../BoostParts/boost/mpl/vector/vector30.hpp | 45 - .../boost/mpl/vector/vector30_c.hpp | 47 - .../BoostParts/boost/mpl/vector/vector40.hpp | 45 - .../boost/mpl/vector/vector40_c.hpp | 46 - .../BoostParts/boost/mpl/vector/vector50.hpp | 45 - .../boost/mpl/vector/vector50_c.hpp | 46 - .../ycmd/cpp/BoostParts/boost/mpl/void.hpp | 76 - .../cpp/BoostParts/boost/mpl/void_fwd.hpp | 26 - .../multi_index/detail/access_specifier.hpp | 55 - .../boost/multi_index/detail/adl_swap.hpp | 44 - .../detail/archive_constructed.hpp | 79 - .../boost/multi_index/detail/auto_space.hpp | 95 - .../boost/multi_index/detail/base_type.hpp | 87 - .../detail/bidir_node_iterator.hpp | 113 - .../boost/multi_index/detail/bucket_array.hpp | 211 - .../boost/multi_index/detail/converter.hpp | 52 - .../boost/multi_index/detail/copy_map.hpp | 140 - .../detail/do_not_copy_elements_tag.hpp | 34 - .../detail/duplicates_iterator.hpp | 120 - .../boost/multi_index/detail/has_tag.hpp | 42 - .../multi_index/detail/hash_index_args.hpp | 105 - .../detail/hash_index_iterator.hpp | 111 - .../multi_index/detail/hash_index_node.hpp | 165 - .../multi_index/detail/header_holder.hpp | 50 - .../boost/multi_index/detail/index_base.hpp | 267 - .../boost/multi_index/detail/index_loader.hpp | 138 - .../multi_index/detail/index_matcher.hpp | 248 - .../multi_index/detail/index_node_base.hpp | 135 - .../boost/multi_index/detail/index_saver.hpp | 135 - .../multi_index/detail/invariant_assert.hpp | 21 - .../multi_index/detail/is_index_list.hpp | 40 - .../boost/multi_index/detail/iter_adaptor.hpp | 325 - .../multi_index/detail/modify_key_adaptor.hpp | 49 - .../detail/msvc_index_specifier.hpp | 69 - .../multi_index/detail/no_duplicate_tags.hpp | 97 - .../boost/multi_index/detail/node_type.hpp | 79 - .../multi_index/detail/ord_index_args.hpp | 83 - .../multi_index/detail/ord_index_node.hpp | 650 -- .../multi_index/detail/ord_index_ops.hpp | 147 - .../boost/multi_index/detail/prevent_eti.hpp | 60 - .../multi_index/detail/safe_ctr_proxy.hpp | 105 - .../boost/multi_index/detail/safe_mode.hpp | 574 -- .../boost/multi_index/detail/scope_guard.hpp | 453 - .../multi_index/detail/seq_index_node.hpp | 223 - .../multi_index/detail/seq_index_ops.hpp | 200 - .../detail/serialization_version.hpp | 75 - .../boost/multi_index/detail/uintptr_type.hpp | 76 - .../boost/multi_index/detail/unbounded.hpp | 83 - .../multi_index/detail/value_compare.hpp | 53 - .../multi_index/detail/vartempl_support.hpp | 247 - .../boost/multi_index/hashed_index.hpp | 1389 --- .../boost/multi_index/hashed_index_fwd.hpp | 58 - .../BoostParts/boost/multi_index/identity.hpp | 147 - .../boost/multi_index/identity_fwd.hpp | 26 - .../boost/multi_index/indexed_by.hpp | 72 - .../BoostParts/boost/multi_index/member.hpp | 269 - .../boost/multi_index/ordered_index.hpp | 1529 ---- .../boost/multi_index/ordered_index_fwd.hpp | 124 - .../boost/multi_index/safe_mode_errors.hpp | 48 - .../boost/multi_index/sequenced_index.hpp | 1070 --- .../boost/multi_index/sequenced_index_fwd.hpp | 91 - .../cpp/BoostParts/boost/multi_index/tag.hpp | 92 - .../boost/multi_index_container.hpp | 1449 ---- .../boost/multi_index_container_fwd.hpp | 121 - .../ycmd/cpp/BoostParts/boost/next_prior.hpp | 51 - .../ycmd/cpp/BoostParts/boost/non_type.hpp | 27 - .../ycmd/cpp/BoostParts/boost/noncopyable.hpp | 48 - .../ycmd/cpp/BoostParts/boost/none.hpp | 28 - .../ycmd/cpp/BoostParts/boost/none_t.hpp | 24 - .../boost/numeric/conversion/bounds.hpp | 24 - .../boost/numeric/conversion/cast.hpp | 61 - .../numeric/conversion/conversion_traits.hpp | 39 - .../boost/numeric/conversion/converter.hpp | 68 - .../numeric/conversion/converter_policies.hpp | 194 - .../numeric/conversion/detail/bounds.hpp | 58 - .../conversion/detail/conversion_traits.hpp | 97 - .../numeric/conversion/detail/converter.hpp | 602 -- .../conversion/detail/int_float_mixture.hpp | 72 - .../conversion/detail/is_subranged.hpp | 234 - .../boost/numeric/conversion/detail/meta.hpp | 120 - .../conversion/detail/numeric_cast_traits.hpp | 138 - .../conversion/detail/old_numeric_cast.hpp | 339 - .../numeric_cast_traits_common.hpp | 1741 ---- .../numeric_cast_traits_long_long.hpp | 347 - .../conversion/detail/sign_mixture.hpp | 72 - .../conversion/detail/udt_builtin_mixture.hpp | 69 - .../conversion/int_float_mixture_enum.hpp | 29 - .../conversion/numeric_cast_traits.hpp | 31 - .../numeric/conversion/sign_mixture_enum.hpp | 29 - .../conversion/udt_builtin_mixture_enum.hpp | 26 - .../ycmd/cpp/BoostParts/boost/operators.hpp | 978 --- .../ycmd/cpp/BoostParts/boost/optional.hpp | 18 - .../BoostParts/boost/optional/optional.hpp | 991 --- .../boost/optional/optional_fwd.hpp | 29 - .../ycmd/cpp/BoostParts/boost/parameter.hpp | 21 - .../boost/parameter/aux_/arg_list.hpp | 459 - .../BoostParts/boost/parameter/aux_/cast.hpp | 143 - .../boost/parameter/aux_/default.hpp | 69 - .../boost/parameter/aux_/is_maybe.hpp | 26 - .../boost/parameter/aux_/overloads.hpp | 88 - .../parameter/aux_/parameter_requirements.hpp | 25 - .../parameter/aux_/parenthesized_type.hpp | 119 - .../parameter/aux_/preprocessor/flatten.hpp | 115 - .../parameter/aux_/preprocessor/for_each.hpp | 103 - .../boost/parameter/aux_/result_of0.hpp | 36 - .../BoostParts/boost/parameter/aux_/set.hpp | 67 - .../BoostParts/boost/parameter/aux_/tag.hpp | 38 - .../boost/parameter/aux_/tagged_argument.hpp | 188 - .../boost/parameter/aux_/template_keyword.hpp | 47 - .../parameter/aux_/unwrap_cv_reference.hpp | 97 - .../BoostParts/boost/parameter/aux_/void.hpp | 29 - .../BoostParts/boost/parameter/aux_/yesno.hpp | 26 - .../BoostParts/boost/parameter/binding.hpp | 106 - .../cpp/BoostParts/boost/parameter/config.hpp | 14 - .../BoostParts/boost/parameter/keyword.hpp | 152 - .../cpp/BoostParts/boost/parameter/macros.hpp | 99 - .../cpp/BoostParts/boost/parameter/match.hpp | 55 - .../cpp/BoostParts/boost/parameter/name.hpp | 156 - .../BoostParts/boost/parameter/parameters.hpp | 931 -- .../boost/parameter/preprocessor.hpp | 1178 --- .../BoostParts/boost/parameter/value_type.hpp | 108 - .../boost/pending/container_traits.hpp | 561 -- .../cpp/BoostParts/boost/pending/cstddef.hpp | 16 - .../boost/pending/detail/property.hpp | 21 - .../BoostParts/boost/pending/integer_log2.hpp | 112 - .../BoostParts/boost/pending/lowest_bit.hpp | 39 - .../cpp/BoostParts/boost/pending/property.hpp | 270 - .../cpp/BoostParts/boost/pending/queue.hpp | 118 - .../ycmd/cpp/BoostParts/boost/pointee.hpp | 74 - .../cpp/BoostParts/boost/pointer_to_other.hpp | 55 - .../BoostParts/boost/predef/architecture.h | 30 - .../boost/predef/architecture/alpha.h | 60 - .../boost/predef/architecture/arm.h | 58 - .../boost/predef/architecture/blackfin.h | 47 - .../boost/predef/architecture/convex.h | 67 - .../boost/predef/architecture/ia64.h | 49 - .../boost/predef/architecture/m68k.h | 83 - .../boost/predef/architecture/mips.h | 74 - .../boost/predef/architecture/parisc.h | 65 - .../boost/predef/architecture/ppc.h | 73 - .../boost/predef/architecture/pyramid.h | 43 - .../boost/predef/architecture/rs6k.h | 56 - .../boost/predef/architecture/sparc.h | 55 - .../boost/predef/architecture/superh.h | 68 - .../boost/predef/architecture/sys370.h | 44 - .../boost/predef/architecture/sys390.h | 44 - .../boost/predef/architecture/x86.h | 38 - .../boost/predef/architecture/x86/32.h | 87 - .../boost/predef/architecture/x86/64.h | 50 - .../BoostParts/boost/predef/architecture/z.h | 43 - .../BoostParts/boost/predef/detail/_cassert.h | 17 - .../boost/predef/detail/endian_compat.h | 26 - .../boost/predef/detail/os_detected.h | 10 - .../cpp/BoostParts/boost/predef/detail/test.h | 17 - .../boost/predef/library/c/_prefix.h | 13 - .../BoostParts/boost/predef/library/c/gnu.h | 62 - .../ycmd/cpp/BoostParts/boost/predef/make.h | 87 - .../ycmd/cpp/BoostParts/boost/predef/os/bsd.h | 95 - .../cpp/BoostParts/boost/predef/os/bsd/bsdi.h | 48 - .../boost/predef/os/bsd/dragonfly.h | 50 - .../cpp/BoostParts/boost/predef/os/bsd/free.h | 60 - .../cpp/BoostParts/boost/predef/os/bsd/net.h | 84 - .../cpp/BoostParts/boost/predef/os/bsd/open.h | 171 - .../cpp/BoostParts/boost/predef/os/macos.h | 58 - .../cpp/BoostParts/boost/predef/os/windows.h | 51 - .../BoostParts/boost/predef/other/endian.h | 205 - .../BoostParts/boost/predef/version_number.h | 54 - .../cpp/BoostParts/boost/preprocessor.hpp | 19 - .../boost/preprocessor/arithmetic.hpp | 25 - .../boost/preprocessor/arithmetic/add.hpp | 51 - .../boost/preprocessor/arithmetic/dec.hpp | 288 - .../arithmetic/detail/div_base.hpp | 61 - .../boost/preprocessor/arithmetic/div.hpp | 39 - .../boost/preprocessor/arithmetic/inc.hpp | 288 - .../boost/preprocessor/arithmetic/mod.hpp | 39 - .../boost/preprocessor/arithmetic/mul.hpp | 53 - .../boost/preprocessor/arithmetic/sub.hpp | 50 - .../BoostParts/boost/preprocessor/array.hpp | 32 - .../boost/preprocessor/array/data.hpp | 28 - .../boost/preprocessor/array/elem.hpp | 29 - .../boost/preprocessor/array/enum.hpp | 33 - .../boost/preprocessor/array/insert.hpp | 55 - .../boost/preprocessor/array/pop_back.hpp | 37 - .../boost/preprocessor/array/pop_front.hpp | 38 - .../boost/preprocessor/array/push_back.hpp | 33 - .../boost/preprocessor/array/push_front.hpp | 33 - .../boost/preprocessor/array/remove.hpp | 54 - .../boost/preprocessor/array/replace.hpp | 49 - .../boost/preprocessor/array/reverse.hpp | 29 - .../boost/preprocessor/array/size.hpp | 28 - .../boost/preprocessor/array/to_list.hpp | 33 - .../boost/preprocessor/array/to_seq.hpp | 33 - .../boost/preprocessor/array/to_tuple.hpp | 22 - .../cpp/BoostParts/boost/preprocessor/cat.hpp | 35 - .../boost/preprocessor/comma_if.hpp | 17 - .../boost/preprocessor/comparison.hpp | 24 - .../boost/preprocessor/comparison/equal.hpp | 34 - .../boost/preprocessor/comparison/greater.hpp | 38 - .../preprocessor/comparison/greater_equal.hpp | 38 - .../boost/preprocessor/comparison/less.hpp | 46 - .../preprocessor/comparison/less_equal.hpp | 39 - .../preprocessor/comparison/not_equal.hpp | 814 -- .../boost/preprocessor/config/config.hpp | 105 - .../boost/preprocessor/config/limits.hpp | 30 - .../BoostParts/boost/preprocessor/control.hpp | 22 - .../boost/preprocessor/control/deduce_d.hpp | 22 - .../preprocessor/control/detail/dmc/while.hpp | 536 -- .../preprocessor/control/detail/edg/while.hpp | 534 -- .../control/detail/msvc/while.hpp | 277 - .../preprocessor/control/detail/while.hpp | 536 -- .../boost/preprocessor/control/expr_if.hpp | 30 - .../boost/preprocessor/control/expr_iif.hpp | 31 - .../boost/preprocessor/control/if.hpp | 30 - .../boost/preprocessor/control/iif.hpp | 34 - .../boost/preprocessor/control/while.hpp | 312 - .../BoostParts/boost/preprocessor/debug.hpp | 18 - .../boost/preprocessor/debug/assert.hpp | 44 - .../boost/preprocessor/debug/error.hpp | 33 - .../boost/preprocessor/debug/line.hpp | 35 - .../cpp/BoostParts/boost/preprocessor/dec.hpp | 17 - .../boost/preprocessor/detail/auto_rec.hpp | 293 - .../boost/preprocessor/detail/check.hpp | 48 - .../preprocessor/detail/dmc/auto_rec.hpp | 286 - .../boost/preprocessor/detail/is_binary.hpp | 30 - .../boost/preprocessor/detail/is_nullary.hpp | 30 - .../boost/preprocessor/detail/is_unary.hpp | 30 - .../boost/preprocessor/detail/split.hpp | 35 - .../BoostParts/boost/preprocessor/empty.hpp | 17 - .../BoostParts/boost/preprocessor/enum.hpp | 17 - .../boost/preprocessor/enum_params.hpp | 17 - .../enum_params_with_a_default.hpp | 17 - .../enum_params_with_defaults.hpp | 17 - .../preprocessor/enum_shifted_params.hpp | 17 - .../BoostParts/boost/preprocessor/expr_if.hpp | 17 - .../boost/preprocessor/facilities.hpp | 23 - .../boost/preprocessor/facilities/apply.hpp | 34 - .../boost/preprocessor/facilities/empty.hpp | 21 - .../boost/preprocessor/facilities/expand.hpp | 28 - .../preprocessor/facilities/identity.hpp | 23 - .../preprocessor/facilities/intercept.hpp | 277 - .../preprocessor/facilities/is_empty.hpp | 43 - .../preprocessor/facilities/overload.hpp | 25 - .../cpp/BoostParts/boost/preprocessor/for.hpp | 17 - .../boost/preprocessor/identity.hpp | 17 - .../cpp/BoostParts/boost/preprocessor/if.hpp | 17 - .../cpp/BoostParts/boost/preprocessor/inc.hpp | 17 - .../BoostParts/boost/preprocessor/iterate.hpp | 17 - .../boost/preprocessor/iteration.hpp | 19 - .../iteration/detail/bounds/lower1.hpp | 99 - .../iteration/detail/bounds/lower2.hpp | 99 - .../iteration/detail/bounds/lower3.hpp | 99 - .../iteration/detail/bounds/lower4.hpp | 99 - .../iteration/detail/bounds/lower5.hpp | 99 - .../iteration/detail/bounds/upper1.hpp | 99 - .../iteration/detail/bounds/upper2.hpp | 99 - .../iteration/detail/bounds/upper3.hpp | 99 - .../iteration/detail/bounds/upper4.hpp | 99 - .../iteration/detail/bounds/upper5.hpp | 99 - .../preprocessor/iteration/detail/finish.hpp | 99 - .../iteration/detail/iter/forward1.hpp | 1342 --- .../iteration/detail/iter/forward2.hpp | 1338 --- .../iteration/detail/iter/forward3.hpp | 1338 --- .../iteration/detail/iter/forward4.hpp | 1338 --- .../iteration/detail/iter/forward5.hpp | 1338 --- .../iteration/detail/iter/reverse1.hpp | 1296 --- .../iteration/detail/iter/reverse2.hpp | 1296 --- .../iteration/detail/iter/reverse3.hpp | 1296 --- .../iteration/detail/iter/reverse4.hpp | 1296 --- .../iteration/detail/iter/reverse5.hpp | 1296 --- .../preprocessor/iteration/detail/local.hpp | 812 -- .../preprocessor/iteration/detail/rlocal.hpp | 782 -- .../preprocessor/iteration/detail/self.hpp | 21 - .../preprocessor/iteration/detail/start.hpp | 99 - .../boost/preprocessor/iteration/iterate.hpp | 82 - .../boost/preprocessor/iteration/local.hpp | 26 - .../boost/preprocessor/iteration/self.hpp | 19 - .../BoostParts/boost/preprocessor/library.hpp | 36 - .../BoostParts/boost/preprocessor/list.hpp | 37 - .../boost/preprocessor/list/adt.hpp | 73 - .../boost/preprocessor/list/append.hpp | 40 - .../BoostParts/boost/preprocessor/list/at.hpp | 39 - .../boost/preprocessor/list/cat.hpp | 42 - .../list/detail/dmc/fold_left.hpp | 279 - .../list/detail/edg/fold_left.hpp | 536 -- .../list/detail/edg/fold_right.hpp | 794 -- .../preprocessor/list/detail/fold_left.hpp | 279 - .../preprocessor/list/detail/fold_right.hpp | 277 - .../boost/preprocessor/list/enum.hpp | 41 - .../boost/preprocessor/list/filter.hpp | 54 - .../boost/preprocessor/list/first_n.hpp | 58 - .../boost/preprocessor/list/fold_left.hpp | 303 - .../boost/preprocessor/list/fold_right.hpp | 40 - .../boost/preprocessor/list/for_each.hpp | 49 - .../boost/preprocessor/list/for_each_i.hpp | 65 - .../preprocessor/list/for_each_product.hpp | 141 - .../boost/preprocessor/list/rest_n.hpp | 55 - .../boost/preprocessor/list/reverse.hpp | 40 - .../boost/preprocessor/list/size.hpp | 58 - .../boost/preprocessor/list/to_array.hpp | 123 - .../boost/preprocessor/list/to_seq.hpp | 32 - .../boost/preprocessor/list/to_tuple.hpp | 38 - .../boost/preprocessor/list/transform.hpp | 49 - .../BoostParts/boost/preprocessor/logical.hpp | 29 - .../boost/preprocessor/logical/and.hpp | 30 - .../boost/preprocessor/logical/bitand.hpp | 38 - .../boost/preprocessor/logical/bitnor.hpp | 38 - .../boost/preprocessor/logical/bitor.hpp | 38 - .../boost/preprocessor/logical/bitxor.hpp | 38 - .../boost/preprocessor/logical/bool.hpp | 288 - .../boost/preprocessor/logical/compl.hpp | 36 - .../boost/preprocessor/logical/nor.hpp | 30 - .../boost/preprocessor/logical/not.hpp | 30 - .../boost/preprocessor/logical/or.hpp | 30 - .../boost/preprocessor/logical/xor.hpp | 30 - .../boost/preprocessor/punctuation.hpp | 20 - .../boost/preprocessor/punctuation/comma.hpp | 21 - .../preprocessor/punctuation/comma_if.hpp | 31 - .../boost/preprocessor/punctuation/paren.hpp | 23 - .../preprocessor/punctuation/paren_if.hpp | 38 - .../BoostParts/boost/preprocessor/repeat.hpp | 17 - .../boost/preprocessor/repeat_2nd.hpp | 17 - .../boost/preprocessor/repeat_from_to.hpp | 17 - .../boost/preprocessor/repetition.hpp | 32 - .../preprocessor/repetition/deduce_r.hpp | 22 - .../preprocessor/repetition/deduce_z.hpp | 22 - .../repetition/detail/dmc/for.hpp | 536 -- .../repetition/detail/edg/for.hpp | 534 -- .../preprocessor/repetition/detail/for.hpp | 536 -- .../repetition/detail/msvc/for.hpp | 277 - .../boost/preprocessor/repetition/enum.hpp | 66 - .../repetition/enum_binary_params.hpp | 54 - .../preprocessor/repetition/enum_params.hpp | 41 - .../repetition/enum_params_with_a_default.hpp | 25 - .../repetition/enum_params_with_defaults.hpp | 24 - .../preprocessor/repetition/enum_shifted.hpp | 68 - .../repetition/enum_shifted_binary_params.hpp | 51 - .../repetition/enum_shifted_params.hpp | 44 - .../preprocessor/repetition/enum_trailing.hpp | 63 - .../enum_trailing_binary_params.hpp | 53 - .../repetition/enum_trailing_params.hpp | 38 - .../boost/preprocessor/repetition/for.hpp | 306 - .../boost/preprocessor/repetition/repeat.hpp | 825 -- .../repetition/repeat_from_to.hpp | 87 - .../boost/preprocessor/selection.hpp | 18 - .../boost/preprocessor/selection/max.hpp | 39 - .../boost/preprocessor/selection/min.hpp | 39 - .../cpp/BoostParts/boost/preprocessor/seq.hpp | 43 - .../BoostParts/boost/preprocessor/seq/cat.hpp | 49 - .../seq/detail/binary_transform.hpp | 40 - .../boost/preprocessor/seq/detail/split.hpp | 284 - .../boost/preprocessor/seq/elem.hpp | 304 - .../boost/preprocessor/seq/enum.hpp | 288 - .../boost/preprocessor/seq/filter.hpp | 54 - .../boost/preprocessor/seq/first_n.hpp | 30 - .../boost/preprocessor/seq/fold_left.hpp | 1070 --- .../boost/preprocessor/seq/fold_right.hpp | 288 - .../boost/preprocessor/seq/for_each.hpp | 60 - .../boost/preprocessor/seq/for_each_i.hpp | 61 - .../preprocessor/seq/for_each_product.hpp | 126 - .../boost/preprocessor/seq/insert.hpp | 28 - .../boost/preprocessor/seq/pop_back.hpp | 29 - .../boost/preprocessor/seq/pop_front.hpp | 27 - .../boost/preprocessor/seq/push_back.hpp | 19 - .../boost/preprocessor/seq/push_front.hpp | 19 - .../boost/preprocessor/seq/remove.hpp | 29 - .../boost/preprocessor/seq/replace.hpp | 29 - .../boost/preprocessor/seq/rest_n.hpp | 30 - .../boost/preprocessor/seq/reverse.hpp | 39 - .../BoostParts/boost/preprocessor/seq/seq.hpp | 44 - .../boost/preprocessor/seq/size.hpp | 547 -- .../boost/preprocessor/seq/subseq.hpp | 28 - .../boost/preprocessor/seq/to_array.hpp | 28 - .../boost/preprocessor/seq/to_list.hpp | 29 - .../boost/preprocessor/seq/to_tuple.hpp | 27 - .../boost/preprocessor/seq/transform.hpp | 48 - .../BoostParts/boost/preprocessor/slot.hpp | 17 - .../preprocessor/slot/detail/counter.hpp | 269 - .../boost/preprocessor/slot/detail/def.hpp | 49 - .../boost/preprocessor/slot/detail/shared.hpp | 247 - .../boost/preprocessor/slot/detail/slot1.hpp | 267 - .../boost/preprocessor/slot/detail/slot2.hpp | 267 - .../boost/preprocessor/slot/detail/slot3.hpp | 267 - .../boost/preprocessor/slot/detail/slot4.hpp | 267 - .../boost/preprocessor/slot/detail/slot5.hpp | 267 - .../boost/preprocessor/slot/slot.hpp | 32 - .../boost/preprocessor/stringize.hpp | 33 - .../BoostParts/boost/preprocessor/tuple.hpp | 28 - .../boost/preprocessor/tuple/eat.hpp | 106 - .../boost/preprocessor/tuple/elem.hpp | 191 - .../boost/preprocessor/tuple/enum.hpp | 22 - .../boost/preprocessor/tuple/rem.hpp | 135 - .../boost/preprocessor/tuple/reverse.hpp | 114 - .../boost/preprocessor/tuple/size.hpp | 28 - .../boost/preprocessor/tuple/to_array.hpp | 37 - .../boost/preprocessor/tuple/to_list.hpp | 116 - .../boost/preprocessor/tuple/to_seq.hpp | 114 - .../boost/preprocessor/variadic.hpp | 23 - .../boost/preprocessor/variadic/elem.hpp | 94 - .../boost/preprocessor/variadic/size.hpp | 30 - .../boost/preprocessor/variadic/to_array.hpp | 32 - .../boost/preprocessor/variadic/to_list.hpp | 25 - .../boost/preprocessor/variadic/to_seq.hpp | 25 - .../boost/preprocessor/variadic/to_tuple.hpp | 24 - .../ycmd/cpp/BoostParts/boost/progress.hpp | 143 - .../parallel/distributed_property_map.hpp | 710 -- .../impl/distributed_property_map.ipp | 428 - .../parallel/local_property_map.hpp | 91 - .../boost/property_map/property_map.hpp | 850 -- .../shared_array_property_map.hpp | 52 - .../property_map/vector_property_map.hpp | 185 - .../boost/ptr_container/clone_allocator.hpp | 99 - .../detail/associative_ptr_container.hpp | 411 - .../ptr_container/detail/default_deleter.hpp | 69 - .../ptr_container/detail/is_convertible.hpp | 73 - .../ptr_container/detail/map_iterator.hpp | 132 - .../ptr_container/detail/meta_functions.hpp | 66 - .../boost/ptr_container/detail/move.hpp | 44 - .../detail/reversible_ptr_container.hpp | 752 -- .../ptr_container/detail/scoped_deleter.hpp | 121 - .../ptr_container/detail/static_move_ptr.hpp | 211 - .../ptr_container/detail/throw_exception.hpp | 33 - .../detail/void_ptr_iterator.hpp | 229 - .../boost/ptr_container/exception.hpp | 58 - .../boost/ptr_container/indirect_fun.hpp | 151 - .../boost/ptr_container/nullable.hpp | 73 - .../boost/ptr_container/ptr_array.hpp | 234 - .../ptr_container/ptr_circular_buffer.hpp | 531 -- .../boost/ptr_container/ptr_container.hpp | 31 - .../boost/ptr_container/ptr_deque.hpp | 69 - .../boost/ptr_container/ptr_inserter.hpp | 258 - .../boost/ptr_container/ptr_list.hpp | 110 - .../boost/ptr_container/ptr_map.hpp | 165 - .../boost/ptr_container/ptr_map_adapter.hpp | 874 -- .../ptr_container/ptr_sequence_adapter.hpp | 775 -- .../boost/ptr_container/ptr_set.hpp | 155 - .../boost/ptr_container/ptr_set_adapter.hpp | 692 -- .../boost/ptr_container/ptr_unordered_map.hpp | 248 - .../boost/ptr_container/ptr_unordered_set.hpp | 240 - .../boost/ptr_container/ptr_vector.hpp | 77 - .../ycmd/cpp/BoostParts/boost/python.hpp | 73 - .../boost/python/arg_from_python.hpp | 76 - .../ycmd/cpp/BoostParts/boost/python/args.hpp | 175 - .../cpp/BoostParts/boost/python/args_fwd.hpp | 52 - .../boost/python/back_reference.hpp | 102 - .../boost/python/base_type_traits.hpp | 43 - .../cpp/BoostParts/boost/python/bases.hpp | 68 - .../cpp/BoostParts/boost/python/borrowed.hpp | 21 - .../ycmd/cpp/BoostParts/boost/python/call.hpp | 83 - .../BoostParts/boost/python/call_method.hpp | 83 - .../ycmd/cpp/BoostParts/boost/python/cast.hpp | 106 - .../cpp/BoostParts/boost/python/class.hpp | 655 -- .../cpp/BoostParts/boost/python/class_fwd.hpp | 24 - .../python/converter/arg_from_python.hpp | 336 - .../boost/python/converter/arg_to_python.hpp | 261 - .../python/converter/arg_to_python_base.hpp | 32 - .../converter/as_to_python_function.hpp | 49 - .../python/converter/builtin_converters.hpp | 190 - .../python/converter/constructor_function.hpp | 17 - .../converter/context_result_converter.hpp | 17 - .../python/converter/convertible_function.hpp | 14 - .../boost/python/converter/from_python.hpp | 41 - .../boost/python/converter/implicit.hpp | 46 - .../converter/obj_mgr_arg_from_python.hpp | 121 - .../boost/python/converter/object_manager.hpp | 230 - .../python/converter/pointer_type_id.hpp | 68 - .../python/converter/pyobject_traits.hpp | 46 - .../boost/python/converter/pyobject_type.hpp | 37 - .../python/converter/pytype_function.hpp | 132 - .../converter/pytype_object_mgr_traits.hpp | 42 - .../boost/python/converter/registered.hpp | 111 - .../python/converter/registered_pointee.hpp | 62 - .../boost/python/converter/registrations.hpp | 99 - .../boost/python/converter/registry.hpp | 55 - .../python/converter/return_from_python.hpp | 162 - .../converter/rvalue_from_python_data.hpp | 140 - .../python/converter/shared_ptr_deleter.hpp | 22 - .../converter/shared_ptr_from_python.hpp | 63 - .../python/converter/shared_ptr_to_python.hpp | 28 - .../converter/to_python_function_type.hpp | 19 - .../boost/python/copy_const_reference.hpp | 43 - .../boost/python/copy_non_const_reference.hpp | 43 - .../BoostParts/boost/python/data_members.hpp | 318 - .../ycmd/cpp/BoostParts/boost/python/def.hpp | 114 - .../BoostParts/boost/python/def_visitor.hpp | 86 - .../boost/python/default_call_policies.hpp | 91 - .../boost/python/detail/borrowed_ptr.hpp | 111 - .../BoostParts/boost/python/detail/caller.hpp | 259 - .../BoostParts/boost/python/detail/config.hpp | 141 - .../boost/python/detail/construct.hpp | 42 - .../boost/python/detail/convertible.hpp | 38 - .../python/detail/copy_ctor_mutates_rhs.hpp | 21 - .../boost/python/detail/cv_category.hpp | 36 - .../boost/python/detail/dealloc.hpp | 17 - .../boost/python/detail/decorated_type_id.hpp | 76 - .../boost/python/detail/decref_guard.hpp | 21 - .../boost/python/detail/def_helper.hpp | 212 - .../boost/python/detail/def_helper_fwd.hpp | 17 - .../boost/python/detail/defaults_def.hpp | 291 - .../boost/python/detail/defaults_gen.hpp | 388 - .../boost/python/detail/dependent.hpp | 27 - .../boost/python/detail/destroy.hpp | 106 - .../boost/python/detail/exception_handler.hpp | 48 - .../boost/python/detail/force_instantiate.hpp | 32 - .../boost/python/detail/indirect_traits.hpp | 13 - .../BoostParts/boost/python/detail/invoke.hpp | 100 - .../boost/python/detail/is_auto_ptr.hpp | 30 - .../boost/python/detail/is_wrapper.hpp | 29 - .../BoostParts/boost/python/detail/is_xxx.hpp | 13 - .../python/detail/make_keyword_range_fn.hpp | 72 - .../boost/python/detail/make_tuple.hpp | 32 - .../boost/python/detail/map_entry.hpp | 43 - .../boost/python/detail/mpl_lambda.hpp | 12 - .../boost/python/detail/msvc_typeinfo.hpp | 75 - .../BoostParts/boost/python/detail/none.hpp | 20 - .../boost/python/detail/not_specified.hpp | 14 - .../detail/nullary_function_adaptor.hpp | 46 - .../boost/python/detail/operator_id.hpp | 63 - .../boost/python/detail/overloads_fwd.hpp | 18 - .../BoostParts/boost/python/detail/prefix.hpp | 16 - .../boost/python/detail/preprocessor.hpp | 66 - .../boost/python/detail/python22_fixed.h | 152 - .../boost/python/detail/python_type.hpp | 37 - .../boost/python/detail/raw_pyobject.hpp | 32 - .../boost/python/detail/referent_storage.hpp | 76 - .../BoostParts/boost/python/detail/scope.hpp | 16 - .../BoostParts/boost/python/detail/sfinae.hpp | 13 - .../boost/python/detail/signature.hpp | 106 - .../boost/python/detail/string_literal.hpp | 88 - .../BoostParts/boost/python/detail/target.hpp | 86 - .../python/detail/translate_exception.hpp | 69 - .../boost/python/detail/type_list.hpp | 39 - .../boost/python/detail/type_list_impl.hpp | 57 - .../python/detail/type_list_impl_no_pts.hpp | 107 - .../boost/python/detail/unwind_type.hpp | 170 - .../boost/python/detail/unwrap_type_id.hpp | 31 - .../boost/python/detail/unwrap_wrapper.hpp | 34 - .../boost/python/detail/value_arg.hpp | 27 - .../python/detail/value_is_shared_ptr.hpp | 17 - .../boost/python/detail/value_is_xxx.hpp | 62 - .../boost/python/detail/void_ptr.hpp | 35 - .../boost/python/detail/void_return.hpp | 42 - .../boost/python/detail/wrap_python.hpp | 205 - .../boost/python/detail/wrapper_base.hpp | 90 - .../ycmd/cpp/BoostParts/boost/python/dict.hpp | 152 - .../boost/python/docstring_options.hpp | 127 - .../ycmd/cpp/BoostParts/boost/python/enum.hpp | 108 - .../cpp/BoostParts/boost/python/errors.hpp | 55 - .../boost/python/exception_translator.hpp | 27 - .../ycmd/cpp/BoostParts/boost/python/exec.hpp | 47 - .../cpp/BoostParts/boost/python/extract.hpp | 260 - .../cpp/BoostParts/boost/python/handle.hpp | 264 - .../BoostParts/boost/python/handle_fwd.hpp | 16 - .../boost/python/has_back_reference.hpp | 24 - .../cpp/BoostParts/boost/python/implicit.hpp | 36 - .../cpp/BoostParts/boost/python/import.hpp | 22 - .../ycmd/cpp/BoostParts/boost/python/init.hpp | 421 - .../boost/python/instance_holder.hpp | 63 - .../cpp/BoostParts/boost/python/iterator.hpp | 137 - .../ycmd/cpp/BoostParts/boost/python/list.hpp | 148 - .../ycmd/cpp/BoostParts/boost/python/long.hpp | 68 - .../boost/python/lvalue_from_pytype.hpp | 116 - .../boost/python/make_constructor.hpp | 290 - .../BoostParts/boost/python/make_function.hpp | 153 - .../boost/python/manage_new_object.hpp | 41 - .../cpp/BoostParts/boost/python/module.hpp | 13 - .../BoostParts/boost/python/module_init.hpp | 91 - .../cpp/BoostParts/boost/python/numeric.hpp | 242 - .../cpp/BoostParts/boost/python/object.hpp | 27 - .../boost/python/object/add_to_namespace.hpp | 23 - .../BoostParts/boost/python/object/class.hpp | 63 - .../boost/python/object/class_detail.hpp | 19 - .../boost/python/object/class_metadata.hpp | 297 - .../boost/python/object/class_wrapper.hpp | 51 - .../boost/python/object/enum_base.hpp | 36 - .../boost/python/object/find_instance.hpp | 21 - .../boost/python/object/forward.hpp | 194 - .../boost/python/object/function.hpp | 82 - .../python/object/function_doc_signature.hpp | 36 - .../boost/python/object/function_handle.hpp | 44 - .../boost/python/object/function_object.hpp | 40 - .../boost/python/object/inheritance.hpp | 132 - .../boost/python/object/inheritance_query.hpp | 17 - .../boost/python/object/instance.hpp | 51 - .../boost/python/object/iterator.hpp | 258 - .../boost/python/object/iterator_core.hpp | 17 - .../boost/python/object/life_support.hpp | 15 - .../boost/python/object/make_holder.hpp | 109 - .../boost/python/object/make_instance.hpp | 78 - .../boost/python/object/make_ptr_instance.hpp | 72 - .../boost/python/object/pickle_support.hpp | 124 - .../boost/python/object/pointer_holder.hpp | 224 - .../boost/python/object/py_function.hpp | 172 - .../boost/python/object/stl_iterator_core.hpp | 27 - .../boost/python/object/value_holder.hpp | 170 - .../boost/python/object/value_holder_fwd.hpp | 16 - .../boost/python/object_attributes.hpp | 116 - .../BoostParts/boost/python/object_call.hpp | 23 - .../BoostParts/boost/python/object_core.hpp | 583 -- .../BoostParts/boost/python/object_fwd.hpp | 18 - .../BoostParts/boost/python/object_items.hpp | 89 - .../boost/python/object_operators.hpp | 136 - .../boost/python/object_protocol.hpp | 90 - .../boost/python/object_protocol_core.hpp | 53 - .../BoostParts/boost/python/object_slices.hpp | 148 - .../boost/python/opaque_pointer_converter.hpp | 199 - .../cpp/BoostParts/boost/python/operators.hpp | 374 - .../cpp/BoostParts/boost/python/other.hpp | 114 - .../cpp/BoostParts/boost/python/overloads.hpp | 13 - .../cpp/BoostParts/boost/python/override.hpp | 144 - .../cpp/BoostParts/boost/python/pointee.hpp | 43 - .../cpp/BoostParts/boost/python/proxy.hpp | 101 - .../ycmd/cpp/BoostParts/boost/python/ptr.hpp | 128 - .../BoostParts/boost/python/pure_virtual.hpp | 124 - .../cpp/BoostParts/boost/python/refcount.hpp | 41 - .../python/reference_existing_object.hpp | 46 - .../boost/python/register_ptr_to_python.hpp | 31 - .../BoostParts/boost/python/return_arg.hpp | 110 - .../boost/python/return_by_value.hpp | 31 - .../python/return_internal_reference.hpp | 43 - .../boost/python/return_opaque_pointer.hpp | 47 - .../boost/python/return_value_policy.hpp | 21 - .../cpp/BoostParts/boost/python/scope.hpp | 77 - .../ycmd/cpp/BoostParts/boost/python/self.hpp | 33 - .../cpp/BoostParts/boost/python/signature.hpp | 252 - .../cpp/BoostParts/boost/python/slice.hpp | 276 - .../cpp/BoostParts/boost/python/slice_nil.hpp | 44 - .../cpp/BoostParts/boost/python/ssize_t.hpp | 29 - .../BoostParts/boost/python/stl_iterator.hpp | 61 - .../ycmd/cpp/BoostParts/boost/python/str.hpp | 422 - .../python/suite/indexing/container_utils.hpp | 57 - .../indexing/detail/indexing_suite_detail.hpp | 759 -- .../python/suite/indexing/indexing_suite.hpp | 299 - .../suite/indexing/vector_indexing_suite.hpp | 242 - .../ycmd/cpp/BoostParts/boost/python/tag.hpp | 18 - .../boost/python/to_python_converter.hpp | 99 - .../boost/python/to_python_indirect.hpp | 113 - .../boost/python/to_python_value.hpp | 176 - .../cpp/BoostParts/boost/python/tuple.hpp | 70 - .../cpp/BoostParts/boost/python/type_id.hpp | 192 - .../boost/python/with_custodian_and_ward.hpp | 125 - .../cpp/BoostParts/boost/python/wrapper.hpp | 35 - .../boost/range/algorithm/equal.hpp | 198 - .../cpp/BoostParts/boost/range/as_literal.hpp | 127 - .../ycmd/cpp/BoostParts/boost/range/begin.hpp | 143 - .../cpp/BoostParts/boost/range/concepts.hpp | 366 - .../cpp/BoostParts/boost/range/config.hpp | 54 - .../BoostParts/boost/range/const_iterator.hpp | 67 - .../boost/range/detail/as_literal.hpp | 33 - .../BoostParts/boost/range/detail/begin.hpp | 94 - .../BoostParts/boost/range/detail/common.hpp | 117 - .../boost/range/detail/const_iterator.hpp | 71 - .../boost/range/detail/detail_str.hpp | 376 - .../cpp/BoostParts/boost/range/detail/end.hpp | 101 - .../range/detail/extract_optional_type.hpp | 52 - .../range/detail/implementation_help.hpp | 103 - .../boost/range/detail/iterator.hpp | 78 - .../boost/range/detail/misc_concept.hpp | 33 - .../boost/range/detail/remove_extent.hpp | 157 - .../boost/range/detail/safe_bool.hpp | 72 - .../BoostParts/boost/range/detail/sfinae.hpp | 77 - .../boost/range/detail/size_type.hpp | 55 - .../boost/range/detail/str_types.hpp | 38 - .../boost/range/detail/value_type.hpp | 72 - .../BoostParts/boost/range/detail/vc6/end.hpp | 170 - .../boost/range/difference_type.hpp | 29 - .../cpp/BoostParts/boost/range/distance.hpp | 34 - .../ycmd/cpp/BoostParts/boost/range/empty.hpp | 34 - .../ycmd/cpp/BoostParts/boost/range/end.hpp | 136 - .../cpp/BoostParts/boost/range/functions.hpp | 27 - .../cpp/BoostParts/boost/range/irange.hpp | 230 - .../cpp/BoostParts/boost/range/iterator.hpp | 72 - .../BoostParts/boost/range/iterator_range.hpp | 16 - .../boost/range/iterator_range_core.hpp | 653 -- .../boost/range/iterator_range_io.hpp | 93 - .../boost/range/mutable_iterator.hpp | 67 - .../cpp/BoostParts/boost/range/rbegin.hpp | 65 - .../ycmd/cpp/BoostParts/boost/range/rend.hpp | 65 - .../boost/range/result_iterator.hpp | 33 - .../boost/range/reverse_iterator.hpp | 40 - .../ycmd/cpp/BoostParts/boost/range/size.hpp | 52 - .../cpp/BoostParts/boost/range/size_type.hpp | 89 - .../cpp/BoostParts/boost/range/value_type.hpp | 34 - .../cpp/BoostParts/boost/ratio/config.hpp | 92 - .../BoostParts/boost/ratio/detail/mpl/abs.hpp | 89 - .../BoostParts/boost/ratio/detail/mpl/gcd.hpp | 124 - .../BoostParts/boost/ratio/detail/mpl/lcm.hpp | 126 - .../boost/ratio/detail/mpl/sign.hpp | 89 - .../boost/ratio/detail/overflow_helpers.hpp | 367 - .../boost/ratio/mpl/rational_c_tag.hpp | 25 - .../ycmd/cpp/BoostParts/boost/ratio/ratio.hpp | 233 - .../cpp/BoostParts/boost/ratio/ratio_fwd.hpp | 84 - .../ycmd/cpp/BoostParts/boost/rational.hpp | 611 -- third_party/ycmd/cpp/BoostParts/boost/ref.hpp | 189 - .../ycmd/cpp/BoostParts/boost/regex.hpp | 37 - .../cpp/BoostParts/boost/regex/config.hpp | 435 - .../BoostParts/boost/regex/config/borland.hpp | 72 - .../BoostParts/boost/regex/config/cwchar.hpp | 207 - .../ycmd/cpp/BoostParts/boost/regex/icu.hpp | 1031 --- .../BoostParts/boost/regex/pattern_except.hpp | 100 - .../boost/regex/pending/object_cache.hpp | 165 - .../boost/regex/pending/static_mutex.hpp | 179 - .../boost/regex/pending/unicode_iterator.hpp | 776 -- .../BoostParts/boost/regex/regex_traits.hpp | 35 - .../ycmd/cpp/BoostParts/boost/regex/user.hpp | 93 - .../BoostParts/boost/regex/v4/basic_regex.hpp | 782 -- .../boost/regex/v4/basic_regex_creator.hpp | 1571 ---- .../boost/regex/v4/basic_regex_parser.hpp | 2874 ------- .../boost/regex/v4/c_regex_traits.hpp | 211 - .../boost/regex/v4/char_regex_traits.hpp | 81 - .../boost/regex/v4/cpp_regex_traits.hpp | 1099 --- .../cpp/BoostParts/boost/regex/v4/cregex.hpp | 330 - .../BoostParts/boost/regex/v4/error_type.hpp | 59 - .../BoostParts/boost/regex/v4/fileiter.hpp | 455 - .../BoostParts/boost/regex/v4/instances.hpp | 222 - .../boost/regex/v4/iterator_category.hpp | 91 - .../boost/regex/v4/iterator_traits.hpp | 135 - .../BoostParts/boost/regex/v4/match_flags.hpp | 138 - .../boost/regex/v4/match_results.hpp | 702 -- .../boost/regex/v4/mem_block_cache.hpp | 99 - .../boost/regex/v4/perl_matcher.hpp | 587 -- .../boost/regex/v4/perl_matcher_common.hpp | 996 --- .../regex/v4/perl_matcher_non_recursive.hpp | 1660 ---- .../boost/regex/v4/perl_matcher_recursive.hpp | 1003 --- .../boost/regex/v4/primary_transform.hpp | 146 - .../boost/regex/v4/protected_call.hpp | 81 - .../cpp/BoostParts/boost/regex/v4/regbase.hpp | 180 - .../cpp/BoostParts/boost/regex/v4/regex.hpp | 202 - .../boost/regex/v4/regex_format.hpp | 1156 --- .../BoostParts/boost/regex/v4/regex_fwd.hpp | 73 - .../BoostParts/boost/regex/v4/regex_grep.hpp | 155 - .../boost/regex/v4/regex_iterator.hpp | 201 - .../BoostParts/boost/regex/v4/regex_match.hpp | 382 - .../BoostParts/boost/regex/v4/regex_merge.hpp | 93 - .../boost/regex/v4/regex_raw_buffer.hpp | 210 - .../boost/regex/v4/regex_replace.hpp | 99 - .../boost/regex/v4/regex_search.hpp | 217 - .../BoostParts/boost/regex/v4/regex_split.hpp | 172 - .../boost/regex/v4/regex_token_iterator.hpp | 342 - .../boost/regex/v4/regex_traits.hpp | 189 - .../boost/regex/v4/regex_traits_defaults.hpp | 371 - .../boost/regex/v4/regex_workaround.hpp | 232 - .../cpp/BoostParts/boost/regex/v4/states.hpp | 301 - .../BoostParts/boost/regex/v4/sub_match.hpp | 512 -- .../BoostParts/boost/regex/v4/syntax_type.hpp | 105 - .../boost/regex/v4/u32regex_iterator.hpp | 193 - .../regex/v4/u32regex_token_iterator.hpp | 377 - .../boost/regex/v4/w32_regex_traits.hpp | 741 -- .../ycmd/cpp/BoostParts/boost/regex_fwd.hpp | 33 - .../cpp/BoostParts/boost/scoped_array.hpp | 16 - .../ycmd/cpp/BoostParts/boost/scoped_ptr.hpp | 16 - .../BoostParts/boost/serialization/access.hpp | 147 - .../BoostParts/boost/serialization/array.hpp | 153 - .../boost/serialization/assume_abstract.hpp | 59 - .../boost/serialization/base_object.hpp | 112 - .../serialization/collection_size_type.hpp | 62 - .../boost/serialization/collection_traits.hpp | 79 - .../serialization/collections_load_imp.hpp | 166 - .../serialization/collections_save_imp.hpp | 72 - .../BoostParts/boost/serialization/config.hpp | 85 - .../boost/serialization/detail/get_data.hpp | 61 - .../serialization/detail/shared_count_132.hpp | 569 -- .../serialization/detail/shared_ptr_132.hpp | 478 -- .../detail/shared_ptr_nmt_132.hpp | 182 - .../detail/stack_constructor.hpp | 73 - .../serialization/extended_type_info.hpp | 120 - .../extended_type_info_no_rtti.hpp | 182 - .../extended_type_info_typeid.hpp | 165 - .../boost/serialization/factory.hpp | 101 - .../boost/serialization/force_include.hpp | 59 - .../serialization/is_bitwise_serializable.hpp | 46 - .../boost/serialization/item_version_type.hpp | 68 - .../BoostParts/boost/serialization/level.hpp | 125 - .../boost/serialization/level_enum.hpp | 55 - .../BoostParts/boost/serialization/nvp.hpp | 144 - .../BoostParts/boost/serialization/pfto.hpp | 78 - .../boost/serialization/serialization.hpp | 167 - .../boost/serialization/shared_ptr_132.hpp | 222 - .../boost/serialization/singleton.hpp | 158 - .../boost/serialization/smart_cast.hpp | 303 - .../boost/serialization/split_free.hpp | 93 - .../boost/serialization/split_member.hpp | 86 - .../boost/serialization/state_saver.hpp | 96 - .../boost/serialization/static_warning.hpp | 108 - .../BoostParts/boost/serialization/string.hpp | 91 - .../boost/serialization/strong_typedef.hpp | 66 - .../boost/serialization/throw_exception.hpp | 44 - .../boost/serialization/tracking.hpp | 118 - .../boost/serialization/tracking_enum.hpp | 41 - .../BoostParts/boost/serialization/traits.hpp | 65 - .../type_info_implementation.hpp | 86 - .../boost/serialization/utility.hpp | 56 - .../BoostParts/boost/serialization/vector.hpp | 220 - .../boost/serialization/version.hpp | 107 - .../boost/serialization/void_cast.hpp | 298 - .../boost/serialization/void_cast_fwd.hpp | 37 - .../boost/serialization/wrapper.hpp | 60 - .../cpp/BoostParts/boost/shared_array.hpp | 19 - .../ycmd/cpp/BoostParts/boost/shared_ptr.hpp | 19 - .../ycmd/cpp/BoostParts/boost/smart_ptr.hpp | 31 - .../boost/smart_ptr/allocate_shared_array.hpp | 250 - .../boost/smart_ptr/bad_weak_ptr.hpp | 59 - .../detail/allocate_array_helper.hpp | 169 - .../boost/smart_ptr/detail/array_deleter.hpp | 124 - .../boost/smart_ptr/detail/array_traits.hpp | 53 - .../boost/smart_ptr/detail/array_utility.hpp | 178 - .../boost/smart_ptr/detail/atomic_count.hpp | 119 - .../smart_ptr/detail/atomic_count_gcc.hpp | 72 - .../smart_ptr/detail/atomic_count_gcc_x86.hpp | 77 - .../detail/atomic_count_pthreads.hpp | 96 - .../smart_ptr/detail/atomic_count_sync.hpp | 61 - .../smart_ptr/detail/atomic_count_win32.hpp | 63 - .../smart_ptr/detail/lightweight_mutex.hpp | 42 - .../boost/smart_ptr/detail/lwm_nop.hpp | 37 - .../boost/smart_ptr/detail/lwm_pthreads.hpp | 87 - .../boost/smart_ptr/detail/lwm_win32_cs.hpp | 108 - .../smart_ptr/detail/make_array_helper.hpp | 157 - .../boost/smart_ptr/detail/operator_bool.hpp | 63 - .../smart_ptr/detail/quick_allocator.hpp | 199 - .../smart_ptr/detail/shared_array_nmt.hpp | 151 - .../boost/smart_ptr/detail/shared_count.hpp | 603 -- .../boost/smart_ptr/detail/shared_ptr_nmt.hpp | 182 - .../boost/smart_ptr/detail/sp_convertible.hpp | 91 - .../smart_ptr/detail/sp_counted_base.hpp | 79 - .../detail/sp_counted_base_acc_ia64.hpp | 151 - .../smart_ptr/detail/sp_counted_base_aix.hpp | 143 - .../detail/sp_counted_base_cw_ppc.hpp | 171 - .../detail/sp_counted_base_gcc_ia64.hpp | 158 - .../detail/sp_counted_base_gcc_mips.hpp | 182 - .../detail/sp_counted_base_gcc_ppc.hpp | 182 - .../detail/sp_counted_base_gcc_sparc.hpp | 167 - .../detail/sp_counted_base_gcc_x86.hpp | 174 - .../smart_ptr/detail/sp_counted_base_nt.hpp | 108 - .../smart_ptr/detail/sp_counted_base_pt.hpp | 136 - .../detail/sp_counted_base_snc_ps3.hpp | 162 - .../smart_ptr/detail/sp_counted_base_spin.hpp | 132 - .../smart_ptr/detail/sp_counted_base_sync.hpp | 156 - .../detail/sp_counted_base_vacpp_ppc.hpp | 151 - .../smart_ptr/detail/sp_counted_base_w32.hpp | 131 - .../smart_ptr/detail/sp_counted_impl.hpp | 254 - .../boost/smart_ptr/detail/sp_forward.hpp | 39 - .../boost/smart_ptr/detail/sp_has_sync.hpp | 69 - .../boost/smart_ptr/detail/sp_if_array.hpp | 31 - .../boost/smart_ptr/detail/sp_nullptr_t.hpp | 45 - .../boost/smart_ptr/detail/spinlock.hpp | 56 - .../smart_ptr/detail/spinlock_gcc_arm.hpp | 120 - .../boost/smart_ptr/detail/spinlock_nt.hpp | 89 - .../boost/smart_ptr/detail/spinlock_pool.hpp | 91 - .../boost/smart_ptr/detail/spinlock_pt.hpp | 79 - .../boost/smart_ptr/detail/spinlock_sync.hpp | 87 - .../boost/smart_ptr/detail/spinlock_w32.hpp | 113 - .../boost/smart_ptr/detail/yield_k.hpp | 148 - .../smart_ptr/enable_shared_from_this.hpp | 79 - .../boost/smart_ptr/intrusive_ptr.hpp | 324 - .../boost/smart_ptr/make_shared.hpp | 22 - .../boost/smart_ptr/make_shared_array.hpp | 247 - .../boost/smart_ptr/make_shared_object.hpp | 1032 --- .../boost/smart_ptr/scoped_array.hpp | 132 - .../BoostParts/boost/smart_ptr/scoped_ptr.hpp | 157 - .../boost/smart_ptr/shared_array.hpp | 290 - .../BoostParts/boost/smart_ptr/shared_ptr.hpp | 1035 --- .../BoostParts/boost/smart_ptr/weak_ptr.hpp | 253 - .../boost/spirit/home/classic/core/assert.hpp | 38 - .../home/classic/core/composite/actions.hpp | 136 - .../classic/core/composite/alternative.hpp | 147 - .../home/classic/core/composite/composite.hpp | 151 - .../classic/core/composite/difference.hpp | 150 - .../classic/core/composite/directives.hpp | 607 -- .../classic/core/composite/exclusive_or.hpp | 142 - .../core/composite/impl/alternative.ipp | 90 - .../core/composite/impl/difference.ipp | 90 - .../core/composite/impl/directives.ipp | 374 - .../core/composite/impl/exclusive_or.ipp | 90 - .../core/composite/impl/intersection.ipp | 90 - .../core/composite/impl/kleene_star.ipp | 34 - .../home/classic/core/composite/impl/list.ipp | 93 - .../classic/core/composite/impl/optional.ipp | 34 - .../classic/core/composite/impl/positive.ipp | 34 - .../classic/core/composite/impl/sequence.ipp | 90 - .../core/composite/impl/sequential_and.ipp | 90 - .../core/composite/impl/sequential_or.ipp | 90 - .../classic/core/composite/intersection.hpp | 142 - .../classic/core/composite/kleene_star.hpp | 109 - .../home/classic/core/composite/list.hpp | 73 - .../home/classic/core/composite/operators.hpp | 25 - .../home/classic/core/composite/optional.hpp | 94 - .../home/classic/core/composite/positive.hpp | 112 - .../home/classic/core/composite/sequence.hpp | 142 - .../classic/core/composite/sequential_and.hpp | 76 - .../classic/core/composite/sequential_or.hpp | 154 - .../boost/spirit/home/classic/core/config.hpp | 62 - .../spirit/home/classic/core/impl/match.ipp | 113 - .../classic/core/impl/match_attr_traits.ipp | 102 - .../spirit/home/classic/core/impl/parser.ipp | 55 - .../boost/spirit/home/classic/core/match.hpp | 185 - .../boost/spirit/home/classic/core/nil.hpp | 25 - .../classic/core/non_terminal/impl/rule.ipp | 420 - .../core/non_terminal/parser_context.hpp | 150 - .../classic/core/non_terminal/parser_id.hpp | 122 - .../home/classic/core/non_terminal/rule.hpp | 175 - .../boost/spirit/home/classic/core/parser.hpp | 223 - .../classic/core/primitives/impl/numerics.ipp | 478 -- .../core/primitives/impl/primitives.ipp | 476 -- .../home/classic/core/primitives/numerics.hpp | 289 - .../classic/core/primitives/numerics_fwd.hpp | 88 - .../classic/core/primitives/primitives.hpp | 654 -- .../spirit/home/classic/core/safe_bool.hpp | 64 - .../classic/core/scanner/impl/skipper.ipp | 181 - .../home/classic/core/scanner/scanner.hpp | 329 - .../home/classic/core/scanner/scanner_fwd.hpp | 52 - .../home/classic/core/scanner/skipper.hpp | 197 - .../home/classic/core/scanner/skipper_fwd.hpp | 32 - .../boost/spirit/home/classic/debug.hpp | 154 - .../spirit/home/classic/debug/debug_node.hpp | 319 - .../spirit/home/classic/debug/minimal.hpp | 81 - .../spirit/home/classic/meta/as_parser.hpp | 113 - .../boost/spirit/home/classic/namespace.hpp | 35 - .../spirit/home/classic/utility/chset.hpp | 187 - .../home/classic/utility/chset_operators.hpp | 402 - .../home/classic/utility/impl/chset.ipp | 366 - .../utility/impl/chset/basic_chset.hpp | 107 - .../utility/impl/chset/basic_chset.ipp | 246 - .../classic/utility/impl/chset/range_run.hpp | 127 - .../classic/utility/impl/chset/range_run.ipp | 218 - .../classic/utility/impl/chset_operators.ipp | 666 -- .../boost/spirit/home/classic/version.hpp | 30 - .../boost/spirit/include/classic_actions.hpp | 12 - .../boost/spirit/include/classic_chset.hpp | 12 - .../boost/spirit/include/classic_numerics.hpp | 12 - .../spirit/include/classic_operators.hpp | 12 - .../boost/spirit/include/classic_rule.hpp | 12 - .../cpp/BoostParts/boost/static_assert.hpp | 195 - .../ycmd/cpp/BoostParts/boost/swap.hpp | 12 - .../BoostParts/boost/system/api_config.hpp | 42 - .../cpp/BoostParts/boost/system/config.hpp | 69 - .../BoostParts/boost/system/error_code.hpp | 521 -- .../BoostParts/boost/system/system_error.hpp | 84 - .../ycmd/cpp/BoostParts/boost/test/debug.hpp | 101 - .../BoostParts/boost/test/debug_config.hpp | 24 - .../BoostParts/boost/test/detail/config.hpp | 104 - .../boost/test/detail/enable_warnings.hpp | 30 - .../BoostParts/boost/test/detail/fwd_decl.hpp | 48 - .../boost/test/detail/global_typedef.hpp | 88 - .../boost/test/detail/log_level.hpp | 43 - .../boost/test/detail/suppress_warnings.hpp | 31 - .../test/detail/unit_test_parameters.hpp | 69 - .../boost/test/detail/workaround.hpp | 65 - .../boost/test/execution_monitor.hpp | 263 - .../boost/test/floating_point_comparison.hpp | 286 - .../cpp/BoostParts/boost/test/framework.hpp | 112 - .../test/impl/compiler_log_formatter.ipp | 222 - .../BoostParts/boost/test/impl/cpp_main.ipp | 139 - .../cpp/BoostParts/boost/test/impl/debug.ipp | 970 --- .../boost/test/impl/exception_safety.ipp | 537 -- .../boost/test/impl/execution_monitor.ipp | 1367 --- .../BoostParts/boost/test/impl/framework.ipp | 503 -- .../boost/test/impl/interaction_based.ipp | 90 - .../boost/test/impl/logged_expectations.ipp | 246 - .../test/impl/plain_report_formatter.ipp | 198 - .../boost/test/impl/progress_monitor.ipp | 110 - .../boost/test/impl/results_collector.ipp | 294 - .../boost/test/impl/results_reporter.ipp | 202 - .../BoostParts/boost/test/impl/test_main.ipp | 68 - .../BoostParts/boost/test/impl/test_tools.ipp | 628 -- .../boost/test/impl/unit_test_log.ipp | 444 - .../boost/test/impl/unit_test_main.ipp | 246 - .../boost/test/impl/unit_test_monitor.ipp | 101 - .../boost/test/impl/unit_test_parameters.ipp | 527 -- .../boost/test/impl/unit_test_suite.ipp | 346 - .../boost/test/impl/xml_log_formatter.ipp | 180 - .../boost/test/impl/xml_report_formatter.ipp | 115 - .../boost/test/included/test_exec_monitor.hpp | 39 - .../boost/test/included/unit_test.hpp | 41 - .../boost/test/interaction_based.hpp | 262 - .../cpp/BoostParts/boost/test/minimal.hpp | 143 - .../cpp/BoostParts/boost/test/mock_object.hpp | 328 - .../test/output/compiler_log_formatter.hpp | 68 - .../test/output/plain_report_formatter.hpp | 62 - .../boost/test/output/xml_log_formatter.hpp | 72 - .../test/output/xml_report_formatter.hpp | 58 - .../boost/test/output_test_stream.hpp | 78 - .../boost/test/predicate_result.hpp | 88 - .../boost/test/progress_monitor.hpp | 70 - .../boost/test/results_collector.hpp | 112 - .../boost/test/results_reporter.hpp | 88 - .../boost/test/test_exec_monitor.hpp | 36 - .../BoostParts/boost/test/test_observer.hpp | 65 - .../cpp/BoostParts/boost/test/test_tools.hpp | 719 -- .../cpp/BoostParts/boost/test/unit_test.hpp | 66 - .../BoostParts/boost/test/unit_test_log.hpp | 177 - .../boost/test/unit_test_log_formatter.hpp | 123 - .../boost/test/unit_test_monitor.hpp | 69 - .../BoostParts/boost/test/unit_test_suite.hpp | 245 - .../boost/test/unit_test_suite_impl.hpp | 434 - .../BoostParts/boost/test/utils/algorithm.hpp | 228 - .../BoostParts/boost/test/utils/assign_op.hpp | 41 - .../utils/basic_cstring/basic_cstring.hpp | 731 -- .../utils/basic_cstring/basic_cstring_fwd.hpp | 40 - .../utils/basic_cstring/bcs_char_traits.hpp | 150 - .../test/utils/basic_cstring/compare.hpp | 115 - .../boost/test/utils/basic_cstring/io.hpp | 73 - .../BoostParts/boost/test/utils/callback.hpp | 310 - .../boost/test/utils/class_properties.hpp | 221 - .../boost/test/utils/custom_manip.hpp | 63 - .../boost/test/utils/fixed_mapping.hpp | 124 - .../BoostParts/boost/test/utils/foreach.hpp | 281 - .../utils/iterator/input_iterator_facade.hpp | 109 - .../test/utils/iterator/token_iterator.hpp | 418 - .../boost/test/utils/lazy_ostream.hpp | 114 - .../boost/test/utils/named_params.hpp | 329 - .../cpp/BoostParts/boost/test/utils/rtti.hpp | 64 - .../boost/test/utils/runtime/argument.hpp | 112 - .../utils/runtime/cla/argument_factory.hpp | 218 - .../test/utils/runtime/cla/argv_traverser.hpp | 98 - .../test/utils/runtime/cla/argv_traverser.ipp | 209 - .../utils/runtime/cla/basic_parameter.hpp | 85 - .../test/utils/runtime/cla/char_parameter.hpp | 98 - .../test/utils/runtime/cla/char_parameter.ipp | 57 - .../cla/detail/argument_value_usage.hpp | 82 - .../utils/runtime/cla/dual_name_parameter.hpp | 96 - .../utils/runtime/cla/dual_name_parameter.ipp | 90 - .../boost/test/utils/runtime/cla/fwd.hpp | 55 - .../test/utils/runtime/cla/id_policy.hpp | 145 - .../test/utils/runtime/cla/id_policy.ipp | 118 - .../runtime/cla/iface/argument_factory.hpp | 51 - .../utils/runtime/cla/iface/id_policy.hpp | 73 - .../boost/test/utils/runtime/cla/modifier.hpp | 69 - .../utils/runtime/cla/named_parameter.hpp | 93 - .../utils/runtime/cla/named_parameter.ipp | 129 - .../test/utils/runtime/cla/parameter.hpp | 150 - .../boost/test/utils/runtime/cla/parser.hpp | 153 - .../boost/test/utils/runtime/cla/parser.ipp | 258 - .../utils/runtime/cla/typed_parameter.hpp | 70 - .../test/utils/runtime/cla/validation.hpp | 55 - .../test/utils/runtime/cla/validation.ipp | 65 - .../utils/runtime/cla/value_generator.hpp | 81 - .../test/utils/runtime/cla/value_handler.hpp | 57 - .../boost/test/utils/runtime/config.hpp | 156 - .../test/utils/runtime/env/environment.hpp | 172 - .../test/utils/runtime/env/environment.ipp | 125 - .../boost/test/utils/runtime/env/fwd.hpp | 54 - .../boost/test/utils/runtime/env/modifier.hpp | 47 - .../boost/test/utils/runtime/env/variable.hpp | 223 - .../boost/test/utils/runtime/fwd.hpp | 41 - .../runtime/interpret_argument_value.hpp | 163 - .../boost/test/utils/runtime/parameter.hpp | 38 - .../boost/test/utils/runtime/trace.hpp | 30 - .../boost/test/utils/runtime/validation.hpp | 82 - .../boost/test/utils/trivial_singleton.hpp | 74 - .../boost/test/utils/wrap_stringstream.hpp | 164 - .../boost/test/utils/xml_printer.hpp | 118 - .../ycmd/cpp/BoostParts/boost/thread.hpp | 26 - .../cpp/BoostParts/boost/thread/barrier.hpp | 214 - .../boost/thread/condition_variable.hpp | 21 - .../cpp/BoostParts/boost/thread/cv_status.hpp | 26 - .../boost/thread/detail/async_func.hpp | 571 -- .../BoostParts/boost/thread/detail/config.hpp | 442 - .../BoostParts/boost/thread/detail/delete.hpp | 57 - .../BoostParts/boost/thread/detail/invoke.hpp | 1351 --- .../boost/thread/detail/is_convertible.hpp | 49 - .../boost/thread/detail/lockable_wrapper.hpp | 45 - .../thread/detail/make_tuple_indices.hpp | 224 - .../BoostParts/boost/thread/detail/memory.hpp | 157 - .../BoostParts/boost/thread/detail/move.hpp | 262 - .../boost/thread/detail/platform.hpp | 73 - .../BoostParts/boost/thread/detail/thread.hpp | 861 -- .../boost/thread/detail/thread_group.hpp | 154 - .../boost/thread/detail/thread_heap_alloc.hpp | 23 - .../thread/detail/thread_interruption.hpp | 39 - .../boost/thread/detail/tss_hooks.hpp | 65 - .../BoostParts/boost/thread/exceptions.hpp | 225 - .../cpp/BoostParts/boost/thread/future.hpp | 4241 --------- .../boost/thread/future_error_code.hpp | 61 - .../boost/thread/is_locked_by_this_thread.hpp | 39 - .../boost/thread/lock_algorithms.hpp | 468 - .../BoostParts/boost/thread/lock_guard.hpp | 88 - .../BoostParts/boost/thread/lock_options.hpp | 31 - .../BoostParts/boost/thread/lock_types.hpp | 1230 --- .../boost/thread/lockable_traits.hpp | 207 - .../cpp/BoostParts/boost/thread/locks.hpp | 16 - .../cpp/BoostParts/boost/thread/mutex.hpp | 53 - .../ycmd/cpp/BoostParts/boost/thread/once.hpp | 44 - .../thread/pthread/condition_variable.hpp | 383 - .../thread/pthread/condition_variable_fwd.hpp | 266 - .../BoostParts/boost/thread/pthread/mutex.hpp | 354 - .../BoostParts/boost/thread/pthread/once.hpp | 540 -- .../boost/thread/pthread/once_atomic.hpp | 313 - .../pthread/pthread_mutex_scoped_lock.hpp | 64 - .../boost/thread/pthread/recursive_mutex.hpp | 401 - .../boost/thread/pthread/shared_mutex.hpp | 716 -- .../boost/thread/pthread/thread_data.hpp | 263 - .../thread/pthread/thread_heap_alloc.hpp | 242 - .../boost/thread/pthread/timespec.hpp | 120 - .../boost/thread/recursive_mutex.hpp | 64 - .../BoostParts/boost/thread/shared_mutex.hpp | 49 - .../cpp/BoostParts/boost/thread/thread.hpp | 16 - .../BoostParts/boost/thread/thread_only.hpp | 29 - .../BoostParts/boost/thread/thread_time.hpp | 55 - .../ycmd/cpp/BoostParts/boost/thread/tss.hpp | 113 - .../cpp/BoostParts/boost/thread/v2/thread.hpp | 83 - .../thread/win32/basic_recursive_mutex.hpp | 164 - .../boost/thread/win32/basic_timed_mutex.hpp | 274 - .../boost/thread/win32/condition_variable.hpp | 546 -- .../boost/thread/win32/interlocked_read.hpp | 82 - .../BoostParts/boost/thread/win32/mutex.hpp | 72 - .../BoostParts/boost/thread/win32/once.hpp | 1090 --- .../boost/thread/win32/recursive_mutex.hpp | 70 - .../boost/thread/win32/shared_mutex.hpp | 892 -- .../boost/thread/win32/thread_data.hpp | 286 - .../boost/thread/win32/thread_heap_alloc.hpp | 409 - .../boost/thread/win32/thread_primitives.hpp | 472 - .../cpp/BoostParts/boost/thread/xtime.hpp | 93 - .../cpp/BoostParts/boost/throw_exception.hpp | 103 - .../ycmd/cpp/BoostParts/boost/timer.hpp | 72 - .../cpp/BoostParts/boost/token_functions.hpp | 665 -- .../cpp/BoostParts/boost/token_iterator.hpp | 128 - .../ycmd/cpp/BoostParts/boost/tokenizer.hpp | 98 - .../boost/tuple/detail/tuple_basic.hpp | 980 --- .../detail/tuple_basic_no_partial_spec.hpp | 865 -- .../ycmd/cpp/BoostParts/boost/tuple/tuple.hpp | 90 - .../boost/tuple/tuple_comparison.hpp | 175 - .../cpp/BoostParts/boost/tuple/tuple_io.hpp | 600 -- .../ycmd/cpp/BoostParts/boost/type.hpp | 18 - .../ycmd/cpp/BoostParts/boost/type_traits.hpp | 101 - .../boost/type_traits/add_const.hpp | 47 - .../BoostParts/boost/type_traits/add_cv.hpp | 48 - .../type_traits/add_lvalue_reference.hpp | 26 - .../boost/type_traits/add_pointer.hpp | 72 - .../boost/type_traits/add_reference.hpp | 107 - .../type_traits/add_rvalue_reference.hpp | 66 - .../boost/type_traits/add_volatile.hpp | 47 - .../boost/type_traits/aligned_storage.hpp | 13 - .../boost/type_traits/alignment_of.hpp | 128 - .../boost/type_traits/alignment_traits.hpp | 15 - .../boost/type_traits/arithmetic_traits.hpp | 20 - .../boost/type_traits/array_traits.hpp | 15 - .../type_traits/broken_compiler_spec.hpp | 117 - .../boost/type_traits/common_type.hpp | 157 - .../boost/type_traits/composite_traits.hpp | 29 - .../boost/type_traits/conditional.hpp | 25 - .../BoostParts/boost/type_traits/config.hpp | 76 - .../boost/type_traits/conversion_traits.hpp | 17 - .../boost/type_traits/cv_traits.hpp | 24 - .../BoostParts/boost/type_traits/decay.hpp | 44 - .../type_traits/detail/bool_trait_def.hpp | 196 - .../type_traits/detail/bool_trait_undef.hpp | 28 - .../type_traits/detail/common_type_imp.hpp | 333 - .../type_traits/detail/cv_traits_impl.hpp | 97 - .../boost/type_traits/detail/false_result.hpp | 28 - .../detail/has_binary_operator.hpp | 229 - .../detail/has_postfix_operator.hpp | 202 - .../detail/has_prefix_operator.hpp | 210 - .../boost/type_traits/detail/ice_and.hpp | 35 - .../boost/type_traits/detail/ice_eq.hpp | 36 - .../boost/type_traits/detail/ice_not.hpp | 31 - .../boost/type_traits/detail/ice_or.hpp | 34 - .../detail/is_function_ptr_helper.hpp | 220 - .../detail/is_function_ptr_tester.hpp | 654 -- .../detail/is_mem_fun_pointer_impl.hpp | 817 -- .../detail/is_mem_fun_pointer_tester.hpp | 2759 ------ .../type_traits/detail/size_t_trait_def.hpp | 60 - .../type_traits/detail/size_t_trait_undef.hpp | 16 - .../detail/template_arity_spec.hpp | 31 - .../type_traits/detail/type_trait_def.hpp | 67 - .../type_traits/detail/type_trait_undef.hpp | 19 - .../boost/type_traits/detail/wrap.hpp | 18 - .../boost/type_traits/detail/yes_no_type.hpp | 26 - .../BoostParts/boost/type_traits/extent.hpp | 145 - .../type_traits/floating_point_promotion.hpp | 91 - .../boost/type_traits/function_traits.hpp | 236 - .../boost/type_traits/has_bit_and.hpp | 49 - .../boost/type_traits/has_bit_and_assign.hpp | 55 - .../boost/type_traits/has_bit_or.hpp | 49 - .../boost/type_traits/has_bit_or_assign.hpp | 55 - .../boost/type_traits/has_bit_xor.hpp | 49 - .../boost/type_traits/has_bit_xor_assign.hpp | 55 - .../boost/type_traits/has_complement.hpp | 32 - .../boost/type_traits/has_dereference.hpp | 31 - .../boost/type_traits/has_divides.hpp | 40 - .../boost/type_traits/has_divides_assign.hpp | 47 - .../boost/type_traits/has_equal_to.hpp | 49 - .../boost/type_traits/has_greater.hpp | 49 - .../boost/type_traits/has_greater_equal.hpp | 49 - .../boost/type_traits/has_left_shift.hpp | 49 - .../type_traits/has_left_shift_assign.hpp | 55 - .../BoostParts/boost/type_traits/has_less.hpp | 49 - .../boost/type_traits/has_less_equal.hpp | 49 - .../boost/type_traits/has_logical_and.hpp | 40 - .../boost/type_traits/has_logical_not.hpp | 23 - .../boost/type_traits/has_logical_or.hpp | 40 - .../boost/type_traits/has_minus.hpp | 60 - .../boost/type_traits/has_minus_assign.hpp | 65 - .../boost/type_traits/has_modulus.hpp | 49 - .../boost/type_traits/has_modulus_assign.hpp | 55 - .../boost/type_traits/has_multiplies.hpp | 40 - .../type_traits/has_multiplies_assign.hpp | 47 - .../boost/type_traits/has_negate.hpp | 25 - .../boost/type_traits/has_new_operator.hpp | 140 - .../boost/type_traits/has_not_equal_to.hpp | 49 - .../boost/type_traits/has_nothrow_assign.hpp | 44 - .../type_traits/has_nothrow_constructor.hpp | 53 - .../boost/type_traits/has_nothrow_copy.hpp | 53 - .../type_traits/has_nothrow_destructor.hpp | 25 - .../boost/type_traits/has_operator.hpp | 51 - .../BoostParts/boost/type_traits/has_plus.hpp | 54 - .../boost/type_traits/has_plus_assign.hpp | 66 - .../boost/type_traits/has_post_decrement.hpp | 40 - .../boost/type_traits/has_post_increment.hpp | 40 - .../boost/type_traits/has_pre_decrement.hpp | 40 - .../boost/type_traits/has_pre_increment.hpp | 40 - .../boost/type_traits/has_right_shift.hpp | 49 - .../type_traits/has_right_shift_assign.hpp | 55 - .../boost/type_traits/has_trivial_assign.hpp | 57 - .../type_traits/has_trivial_constructor.hpp | 51 - .../boost/type_traits/has_trivial_copy.hpp | 64 - .../type_traits/has_trivial_destructor.hpp | 49 - .../type_traits/has_trivial_move_assign.hpp | 57 - .../has_trivial_move_constructor.hpp | 57 - .../boost/type_traits/has_unary_minus.hpp | 25 - .../boost/type_traits/has_unary_plus.hpp | 23 - .../type_traits/has_virtual_destructor.hpp | 29 - .../cpp/BoostParts/boost/type_traits/ice.hpp | 20 - .../boost/type_traits/integral_constant.hpp | 53 - .../boost/type_traits/integral_promotion.hpp | 195 - .../boost/type_traits/intrinsics.hpp | 305 - .../boost/type_traits/is_abstract.hpp | 153 - .../boost/type_traits/is_arithmetic.hpp | 51 - .../BoostParts/boost/type_traits/is_array.hpp | 91 - .../boost/type_traits/is_base_and_derived.hpp | 254 - .../boost/type_traits/is_base_of.hpp | 51 - .../BoostParts/boost/type_traits/is_class.hpp | 140 - .../boost/type_traits/is_complex.hpp | 34 - .../boost/type_traits/is_compound.hpp | 46 - .../BoostParts/boost/type_traits/is_const.hpp | 165 - .../boost/type_traits/is_convertible.hpp | 492 -- .../type_traits/is_copy_constructible.hpp | 122 - .../BoostParts/boost/type_traits/is_empty.hpp | 229 - .../BoostParts/boost/type_traits/is_enum.hpp | 189 - .../BoostParts/boost/type_traits/is_float.hpp | 27 - .../boost/type_traits/is_floating_point.hpp | 27 - .../boost/type_traits/is_function.hpp | 111 - .../boost/type_traits/is_fundamental.hpp | 45 - .../boost/type_traits/is_integral.hpp | 89 - .../boost/type_traits/is_lvalue_reference.hpp | 118 - .../is_member_function_pointer.hpp | 136 - .../type_traits/is_member_object_pointer.hpp | 46 - .../boost/type_traits/is_member_pointer.hpp | 116 - .../is_nothrow_move_assignable.hpp | 84 - .../is_nothrow_move_constructible.hpp | 84 - .../boost/type_traits/is_object.hpp | 53 - .../BoostParts/boost/type_traits/is_pod.hpp | 145 - .../boost/type_traits/is_pointer.hpp | 162 - .../boost/type_traits/is_polymorphic.hpp | 114 - .../boost/type_traits/is_reference.hpp | 45 - .../boost/type_traits/is_rvalue_reference.hpp | 29 - .../BoostParts/boost/type_traits/is_same.hpp | 103 - .../boost/type_traits/is_scalar.hpp | 55 - .../boost/type_traits/is_signed.hpp | 140 - .../boost/type_traits/is_stateless.hpp | 48 - .../BoostParts/boost/type_traits/is_union.hpp | 57 - .../boost/type_traits/is_unsigned.hpp | 135 - .../boost/type_traits/is_virtual_base_of.hpp | 104 - .../BoostParts/boost/type_traits/is_void.hpp | 38 - .../boost/type_traits/is_volatile.hpp | 152 - .../boost/type_traits/make_signed.hpp | 153 - .../boost/type_traits/make_unsigned.hpp | 153 - .../type_traits/msvc/remove_all_extents.hpp | 47 - .../boost/type_traits/msvc/remove_bounds.hpp | 43 - .../boost/type_traits/msvc/remove_const.hpp | 143 - .../boost/type_traits/msvc/remove_cv.hpp | 190 - .../boost/type_traits/msvc/remove_extent.hpp | 43 - .../boost/type_traits/msvc/remove_pointer.hpp | 42 - .../type_traits/msvc/remove_reference.hpp | 42 - .../type_traits/msvc/remove_volatile.hpp | 143 - .../boost/type_traits/msvc/typeof.hpp | 50 - .../boost/type_traits/object_traits.hpp | 33 - .../BoostParts/boost/type_traits/promote.hpp | 40 - .../cpp/BoostParts/boost/type_traits/rank.hpp | 89 - .../boost/type_traits/remove_all_extents.hpp | 48 - .../boost/type_traits/remove_bounds.hpp | 48 - .../boost/type_traits/remove_const.hpp | 90 - .../boost/type_traits/remove_cv.hpp | 84 - .../boost/type_traits/remove_extent.hpp | 48 - .../boost/type_traits/remove_pointer.hpp | 92 - .../boost/type_traits/remove_reference.hpp | 70 - .../boost/type_traits/remove_volatile.hpp | 88 - .../boost/type_traits/same_traits.hpp | 15 - .../boost/type_traits/transform_traits.hpp | 21 - .../boost/type_traits/type_with_alignment.hpp | 399 - .../boost/typeof/dmc/typeof_impl.hpp | 100 - .../BoostParts/boost/typeof/encode_decode.hpp | 61 - .../boost/typeof/encode_decode_params.hpp | 34 - .../BoostParts/boost/typeof/int_encoding.hpp | 118 - .../boost/typeof/integral_template_param.hpp | 80 - .../cpp/BoostParts/boost/typeof/message.hpp | 8 - .../cpp/BoostParts/boost/typeof/modifiers.hpp | 121 - .../boost/typeof/msvc/typeof_impl.hpp | 283 - .../cpp/BoostParts/boost/typeof/native.hpp | 60 - .../boost/typeof/pointers_data_members.hpp | 38 - .../boost/typeof/register_functions.hpp | 50 - .../typeof/register_functions_iterate.hpp | 135 - .../boost/typeof/register_fundamental.hpp | 62 - .../boost/typeof/register_mem_functions.hpp | 32 - .../boost/typeof/template_encoding.hpp | 160 - .../boost/typeof/template_template_param.hpp | 149 - .../BoostParts/boost/typeof/type_encoding.hpp | 27 - .../boost/typeof/type_template_param.hpp | 37 - .../cpp/BoostParts/boost/typeof/typeof.hpp | 218 - .../BoostParts/boost/typeof/typeof_impl.hpp | 186 - .../BoostParts/boost/typeof/unsupported.hpp | 29 - .../cpp/BoostParts/boost/typeof/vector.hpp | 166 - .../cpp/BoostParts/boost/typeof/vector100.hpp | 321 - .../cpp/BoostParts/boost/typeof/vector150.hpp | 471 - .../cpp/BoostParts/boost/typeof/vector200.hpp | 621 -- .../cpp/BoostParts/boost/typeof/vector50.hpp | 171 - .../boost/unordered/detail/allocate.hpp | 1124 --- .../boost/unordered/detail/buckets.hpp | 888 -- .../boost/unordered/detail/equivalent.hpp | 680 -- .../boost/unordered/detail/extract_key.hpp | 183 - .../BoostParts/boost/unordered/detail/fwd.hpp | 23 - .../boost/unordered/detail/table.hpp | 863 -- .../boost/unordered/detail/unique.hpp | 620 -- .../boost/unordered/detail/util.hpp | 265 - .../boost/unordered/unordered_map.hpp | 1656 ---- .../boost/unordered/unordered_map_fwd.hpp | 65 - .../boost/unordered/unordered_set.hpp | 1553 ---- .../boost/unordered/unordered_set_fwd.hpp | 63 - .../cpp/BoostParts/boost/unordered_map.hpp | 18 - .../cpp/BoostParts/boost/unordered_set.hpp | 18 - .../ycmd/cpp/BoostParts/boost/utility.hpp | 21 - .../BoostParts/boost/utility/addressof.hpp | 102 - .../boost/utility/base_from_member.hpp | 158 - .../cpp/BoostParts/boost/utility/binary.hpp | 708 -- .../boost/utility/compare_pointees.hpp | 68 - .../cpp/BoostParts/boost/utility/declval.hpp | 44 - .../detail/in_place_factory_prefix.hpp | 36 - .../detail/in_place_factory_suffix.hpp | 23 - .../utility/detail/result_of_iterate.hpp | 221 - .../BoostParts/boost/utility/enable_if.hpp | 119 - .../boost/utility/identity_type.hpp | 46 - .../boost/utility/in_place_factory.hpp | 88 - .../BoostParts/boost/utility/result_of.hpp | 207 - .../cpp/BoostParts/boost/utility/swap.hpp | 55 - .../BoostParts/boost/utility/value_init.hpp | 258 - .../ycmd/cpp/BoostParts/boost/version.hpp | 32 - .../ycmd/cpp/BoostParts/boost/visit_each.hpp | 29 - .../ycmd/cpp/BoostParts/boost/weak_ptr.hpp | 18 - .../BoostParts/libs/atomic/src/lockpool.cpp | 55 - .../src/gregorian/date_generators.cpp | 38 - .../date_time/src/gregorian/greg_month.cpp | 173 - .../date_time/src/gregorian/greg_names.hpp | 43 - .../date_time/src/gregorian/greg_weekday.cpp | 50 - .../src/gregorian/gregorian_types.cpp | 62 - .../src/posix_time/posix_time_types.cpp | 35 - .../clone_current_exception_non_intrusive.cpp | 320 - .../filesystem/src/codecvt_error_category.cpp | 84 - .../libs/filesystem/src/operations.cpp | 2230 ----- .../BoostParts/libs/filesystem/src/path.cpp | 929 -- .../libs/filesystem/src/path_traits.cpp | 200 - .../libs/filesystem/src/portability.cpp | 119 - .../libs/filesystem/src/unique_path.cpp | 142 - .../filesystem/src/utf8_codecvt_facet.cpp | 27 - .../filesystem/src/windows_file_codecvt.cpp | 75 - .../filesystem/src/windows_file_codecvt.hpp | 56 - .../src/converter/arg_to_python_base.cpp | 28 - .../src/converter/builtin_converters.cpp | 570 -- .../libs/python/src/converter/from_python.cpp | 303 - .../libs/python/src/converter/registry.cpp | 306 - .../libs/python/src/converter/type_id.cpp | 212 - .../cpp/BoostParts/libs/python/src/dict.cpp | 184 - .../cpp/BoostParts/libs/python/src/errors.cpp | 105 - .../cpp/BoostParts/libs/python/src/exec.cpp | 108 - .../cpp/BoostParts/libs/python/src/import.cpp | 25 - .../cpp/BoostParts/libs/python/src/list.cpp | 170 - .../cpp/BoostParts/libs/python/src/long.cpp | 39 - .../cpp/BoostParts/libs/python/src/module.cpp | 73 - .../BoostParts/libs/python/src/numeric.cpp | 325 - .../libs/python/src/object/class.cpp | 764 -- .../libs/python/src/object/enum.cpp | 246 - .../libs/python/src/object/function.cpp | 793 -- .../src/object/function_doc_signature.cpp | 344 - .../libs/python/src/object/inheritance.cpp | 495 -- .../libs/python/src/object/iterator.cpp | 39 - .../libs/python/src/object/life_support.cpp | 121 - .../libs/python/src/object/pickle_support.cpp | 78 - .../libs/python/src/object/stl_iterator.cpp | 48 - .../libs/python/src/object_operators.cpp | 85 - .../libs/python/src/object_protocol.cpp | 197 - .../cpp/BoostParts/libs/python/src/slice.cpp | 37 - .../cpp/BoostParts/libs/python/src/str.cpp | 403 - .../cpp/BoostParts/libs/python/src/tuple.cpp | 35 - .../BoostParts/libs/python/src/wrapper.cpp | 66 - .../libs/regex/src/c_regex_traits.cpp | 193 - .../libs/regex/src/cpp_regex_traits.cpp | 117 - .../cpp/BoostParts/libs/regex/src/cregex.cpp | 660 -- .../BoostParts/libs/regex/src/fileiter.cpp | 927 -- .../cpp/BoostParts/libs/regex/src/icu.cpp | 507 -- .../BoostParts/libs/regex/src/instances.cpp | 32 - .../BoostParts/libs/regex/src/internals.hpp | 35 - .../BoostParts/libs/regex/src/posix_api.cpp | 296 - .../cpp/BoostParts/libs/regex/src/regex.cpp | 227 - .../BoostParts/libs/regex/src/regex_debug.cpp | 59 - .../libs/regex/src/regex_raw_buffer.cpp | 72 - .../libs/regex/src/regex_traits_defaults.cpp | 692 -- .../libs/regex/src/static_mutex.cpp | 179 - .../BoostParts/libs/regex/src/usinstances.cpp | 81 - .../libs/regex/src/w32_regex_traits.cpp | 652 -- .../libs/regex/src/wc_regex_traits.cpp | 301 - .../libs/regex/src/wide_posix_api.cpp | 315 - .../BoostParts/libs/regex/src/winstances.cpp | 35 - .../serialization/src/archive_exception.cpp | 127 - .../libs/serialization/src/basic_archive.cpp | 81 - .../libs/serialization/src/basic_iarchive.cpp | 594 -- .../serialization/src/basic_iserializer.cpp | 33 - .../libs/serialization/src/basic_oarchive.cpp | 459 - .../serialization/src/basic_oserializer.cpp | 33 - .../src/basic_pointer_iserializer.cpp | 30 - .../src/basic_pointer_oserializer.cpp | 30 - .../src/basic_serializer_map.cpp | 111 - .../src/basic_text_iprimitive.cpp | 28 - .../src/basic_text_oprimitive.cpp | 28 - .../src/basic_text_wiprimitive.cpp | 35 - .../src/basic_text_woprimitive.cpp | 35 - .../serialization/src/basic_xml_archive.cpp | 51 - .../serialization/src/basic_xml_grammar.ipp | 468 - .../serialization/src/binary_iarchive.cpp | 53 - .../serialization/src/binary_oarchive.cpp | 39 - .../serialization/src/binary_wiarchive.cpp | 60 - .../serialization/src/binary_woarchive.cpp | 44 - .../libs/serialization/src/codecvt_null.cpp | 83 - .../serialization/src/extended_type_info.cpp | 188 - .../src/extended_type_info_no_rtti.cpp | 85 - .../src/extended_type_info_typeid.cpp | 161 - .../src/polymorphic_iarchive.cpp | 29 - .../src/polymorphic_oarchive.cpp | 29 - .../serialization/src/shared_ptr_helper.cpp | 138 - .../libs/serialization/src/stl_port.cpp | 43 - .../libs/serialization/src/text_iarchive.cpp | 36 - .../libs/serialization/src/text_oarchive.cpp | 33 - .../libs/serialization/src/text_wiarchive.cpp | 41 - .../libs/serialization/src/text_woarchive.cpp | 35 - .../serialization/src/utf8_codecvt_facet.cpp | 21 - .../libs/serialization/src/void_cast.cpp | 360 - .../src/xml_archive_exception.cpp | 57 - .../libs/serialization/src/xml_grammar.cpp | 73 - .../libs/serialization/src/xml_iarchive.cpp | 46 - .../libs/serialization/src/xml_oarchive.cpp | 32 - .../libs/serialization/src/xml_wgrammar.cpp | 157 - .../libs/serialization/src/xml_wiarchive.cpp | 53 - .../libs/serialization/src/xml_woarchive.cpp | 35 - .../libs/smart_ptr/src/sp_collector.cpp | 270 - .../libs/smart_ptr/src/sp_debug_hooks.cpp | 243 - .../BoostParts/libs/system/src/error_code.cpp | 479 -- .../system/src/local_free_on_destruction.hpp | 40 - .../cpp/BoostParts/libs/thread/src/future.cpp | 63 - .../libs/thread/src/pthread/once.cpp | 78 - .../libs/thread/src/pthread/once_atomic.cpp | 90 - .../libs/thread/src/pthread/thread.cpp | 767 -- .../libs/thread/src/pthread/timeconv.inl | 151 - .../BoostParts/libs/thread/src/tss_null.cpp | 38 - .../libs/thread/src/win32/thread.cpp | 769 -- .../libs/thread/src/win32/timeconv.inl | 130 - .../libs/thread/src/win32/tss_dll.cpp | 77 - .../libs/thread/src/win32/tss_pe.cpp | 325 - third_party/ycmd/cpp/CMakeLists.txt | 177 - .../include/clang-c/CXCompilationDatabase.h | 146 - .../ycmd/cpp/llvm/include/clang-c/CXString.h | 61 - .../ycmd/cpp/llvm/include/clang-c/Index.h | 5522 ------------ .../ycmd/cpp/llvm/include/clang-c/Platform.h | 45 - third_party/ycmd/cpp/ycm/.ycm_extra_conf.py | 192 - third_party/ycmd/cpp/ycm/CMakeLists.txt | 386 - third_party/ycmd/cpp/ycm/Candidate.cpp | 120 - third_party/ycmd/cpp/ycm/Candidate.h | 70 - .../ycmd/cpp/ycm/CandidateRepository.cpp | 120 - .../ycmd/cpp/ycm/CandidateRepository.h | 76 - .../cpp/ycm/ClangCompleter/ClangCompleter.cpp | 175 - .../cpp/ycm/ClangCompleter/ClangCompleter.h | 91 - .../cpp/ycm/ClangCompleter/ClangHelpers.cpp | 231 - .../cpp/ycm/ClangCompleter/ClangHelpers.h | 49 - .../cpp/ycm/ClangCompleter/ClangUtils.cpp | 55 - .../ycmd/cpp/ycm/ClangCompleter/ClangUtils.h | 41 - .../ClangCompleter/CompilationDatabase.cpp | 109 - .../ycm/ClangCompleter/CompilationDatabase.h | 63 - .../cpp/ycm/ClangCompleter/CompletionData.cpp | 233 - .../cpp/ycm/ClangCompleter/CompletionData.h | 113 - .../ycmd/cpp/ycm/ClangCompleter/Diagnostic.h | 57 - .../ycmd/cpp/ycm/ClangCompleter/Location.h | 72 - .../ycmd/cpp/ycm/ClangCompleter/Range.cpp | 29 - .../ycmd/cpp/ycm/ClangCompleter/Range.h | 47 - .../ycm/ClangCompleter/TranslationUnit.cpp | 311 - .../cpp/ycm/ClangCompleter/TranslationUnit.h | 107 - .../ClangCompleter/TranslationUnitStore.cpp | 140 - .../ycm/ClangCompleter/TranslationUnitStore.h | 84 - .../ycmd/cpp/ycm/ClangCompleter/UnsavedFile.h | 44 - third_party/ycmd/cpp/ycm/CustomAssert.cpp | 102 - third_party/ycmd/cpp/ycm/CustomAssert.h | 112 - .../ycmd/cpp/ycm/IdentifierCompleter.cpp | 113 - .../ycmd/cpp/ycm/IdentifierCompleter.h | 78 - .../ycmd/cpp/ycm/IdentifierDatabase.cpp | 158 - third_party/ycmd/cpp/ycm/IdentifierDatabase.h | 105 - third_party/ycmd/cpp/ycm/IdentifierUtils.cpp | 201 - third_party/ycmd/cpp/ycm/IdentifierUtils.h | 45 - third_party/ycmd/cpp/ycm/LetterNode.cpp | 54 - third_party/ycmd/cpp/ycm/LetterNode.h | 69 - .../ycmd/cpp/ycm/LetterNodeListMap.cpp | 84 - third_party/ycmd/cpp/ycm/LetterNodeListMap.h | 56 - third_party/ycmd/cpp/ycm/PythonSupport.cpp | 119 - third_party/ycmd/cpp/ycm/PythonSupport.h | 37 - third_party/ycmd/cpp/ycm/ReleaseGil.h | 42 - third_party/ycmd/cpp/ycm/Result.cpp | 224 - third_party/ycmd/cpp/ycm/Result.h | 119 - third_party/ycmd/cpp/ycm/Utils.cpp | 54 - third_party/ycmd/cpp/ycm/Utils.h | 78 - third_party/ycmd/cpp/ycm/exceptions.h | 44 - third_party/ycmd/cpp/ycm/standard.h | 25 - third_party/ycmd/cpp/ycm/tests/CMakeLists.txt | 94 - .../ycm/tests/CandidateRepository_test.cpp | 52 - .../ycmd/cpp/ycm/tests/Candidate_test.cpp | 222 - .../ClangCompleter/ClangCompleter_test.cpp | 63 - .../ClangCompleter/TranslationUnit_test.cpp | 118 - .../ycm/tests/IdentifierCompleter_test.cpp | 266 - .../cpp/ycm/tests/IdentifierUtils_test.cpp | 187 - .../ycmd/cpp/ycm/tests/IndexForChar_test.cpp | 35 - .../ycmd/cpp/ycm/tests/IsUppercase_test.cpp | 38 - .../ycm/tests/LetterBitsetFromString_test.cpp | 36 - third_party/ycmd/cpp/ycm/tests/TestUtils.cpp | 69 - third_party/ycmd/cpp/ycm/tests/TestUtils.h | 43 - third_party/ycmd/cpp/ycm/tests/gmock/CHANGES | 92 - .../ycmd/cpp/ycm/tests/gmock/CMakeLists.txt | 170 - .../ycmd/cpp/ycm/tests/gmock/CONTRIBUTORS | 40 - third_party/ycmd/cpp/ycm/tests/gmock/LICENSE | 28 - .../ycmd/cpp/ycm/tests/gmock/Makefile.am | 213 - third_party/ycmd/cpp/ycm/tests/gmock/README | 361 - .../ycmd/cpp/ycm/tests/gmock/configure.ac | 146 - .../ycmd/cpp/ycm/tests/gmock/gtest/CHANGES | 130 - .../cpp/ycm/tests/gmock/gtest/CMakeLists.txt | 250 - .../cpp/ycm/tests/gmock/gtest/CONTRIBUTORS | 37 - .../ycmd/cpp/ycm/tests/gmock/gtest/LICENSE | 28 - .../cpp/ycm/tests/gmock/gtest/Makefile.am | 304 - .../ycmd/cpp/ycm/tests/gmock/gtest/README | 434 - .../gmock/gtest/cmake/internal_utils.cmake | 227 - .../tests/gmock/gtest/codegear/gtest.cbproj | 138 - .../gmock/gtest/codegear/gtest.groupproj | 54 - .../tests/gmock/gtest/codegear/gtest_all.cc | 38 - .../tests/gmock/gtest/codegear/gtest_link.cc | 40 - .../gmock/gtest/codegear/gtest_main.cbproj | 82 - .../gtest/codegear/gtest_unittest.cbproj | 88 - .../cpp/ycm/tests/gmock/gtest/configure.ac | 68 - .../gtest/include/gtest/gtest-death-test.h | 294 - .../gmock/gtest/include/gtest/gtest-message.h | 230 - .../gtest/include/gtest/gtest-param-test.h | 1421 ---- .../include/gtest/gtest-param-test.h.pump | 487 -- .../gtest/include/gtest/gtest-printers.h | 799 -- .../gmock/gtest/include/gtest/gtest-spi.h | 232 - .../gtest/include/gtest/gtest-test-part.h | 177 - .../gtest/include/gtest/gtest-typed-test.h | 259 - .../tests/gmock/gtest/include/gtest/gtest.h | 2159 ----- .../gtest/include/gtest/gtest_pred_impl.h | 358 - .../gmock/gtest/include/gtest/gtest_prod.h | 58 - .../internal/gtest-death-test-internal.h | 319 - .../include/gtest/internal/gtest-filepath.h | 210 - .../include/gtest/internal/gtest-internal.h | 1232 --- .../include/gtest/internal/gtest-linked_ptr.h | 233 - .../internal/gtest-param-util-generated.h | 5143 ----------- .../gtest-param-util-generated.h.pump | 301 - .../include/gtest/internal/gtest-param-util.h | 619 -- .../gtest/include/gtest/internal/gtest-port.h | 1871 ---- .../include/gtest/internal/gtest-string.h | 350 - .../include/gtest/internal/gtest-tuple.h | 1012 --- .../include/gtest/internal/gtest-tuple.h.pump | 339 - .../include/gtest/internal/gtest-type-util.h | 3332 -------- .../gtest/internal/gtest-type-util.h.pump | 298 - .../ycm/tests/gmock/gtest/m4/acx_pthread.m4 | 363 - .../cpp/ycm/tests/gmock/gtest/m4/gtest.m4 | 74 - .../ycm/tests/gmock/gtest/msvc/gtest-md.sln | 45 - .../tests/gmock/gtest/msvc/gtest-md.vcproj | 126 - .../cpp/ycm/tests/gmock/gtest/msvc/gtest.sln | 45 - .../ycm/tests/gmock/gtest/msvc/gtest.vcproj | 126 - .../gmock/gtest/msvc/gtest_main-md.vcproj | 129 - .../tests/gmock/gtest/msvc/gtest_main.vcproj | 129 - .../gtest/msvc/gtest_prod_test-md.vcproj | 164 - .../gmock/gtest/msvc/gtest_prod_test.vcproj | 164 - .../gmock/gtest/msvc/gtest_unittest-md.vcproj | 147 - .../gmock/gtest/msvc/gtest_unittest.vcproj | 147 - .../tests/gmock/gtest/samples/prime_tables.h | 123 - .../ycm/tests/gmock/gtest/samples/sample1.cc | 68 - .../ycm/tests/gmock/gtest/samples/sample1.h | 43 - .../gmock/gtest/samples/sample10_unittest.cc | 144 - .../gmock/gtest/samples/sample1_unittest.cc | 153 - .../ycm/tests/gmock/gtest/samples/sample2.cc | 56 - .../ycm/tests/gmock/gtest/samples/sample2.h | 85 - .../gmock/gtest/samples/sample2_unittest.cc | 109 - .../tests/gmock/gtest/samples/sample3-inl.h | 172 - .../gmock/gtest/samples/sample3_unittest.cc | 151 - .../ycm/tests/gmock/gtest/samples/sample4.cc | 46 - .../ycm/tests/gmock/gtest/samples/sample4.h | 53 - .../gmock/gtest/samples/sample4_unittest.cc | 45 - .../gmock/gtest/samples/sample5_unittest.cc | 199 - .../gmock/gtest/samples/sample6_unittest.cc | 224 - .../gmock/gtest/samples/sample7_unittest.cc | 130 - .../gmock/gtest/samples/sample8_unittest.cc | 173 - .../gmock/gtest/samples/sample9_unittest.cc | 160 - .../gmock/gtest/scripts/fuse_gtest_files.py | 250 - .../gtest/scripts/gen_gtest_pred_impl.py | 730 -- .../tests/gmock/gtest/scripts/gtest-config.in | 274 - .../cpp/ycm/tests/gmock/gtest/scripts/pump.py | 847 -- .../ycm/tests/gmock/gtest/scripts/upload.py | 1387 --- .../tests/gmock/gtest/scripts/upload_gtest.py | 78 - .../ycm/tests/gmock/gtest/src/gtest-all.cc | 48 - .../tests/gmock/gtest/src/gtest-death-test.cc | 1337 --- .../tests/gmock/gtest/src/gtest-filepath.cc | 380 - .../gmock/gtest/src/gtest-internal-inl.h | 1056 --- .../ycm/tests/gmock/gtest/src/gtest-port.cc | 787 -- .../tests/gmock/gtest/src/gtest-printers.cc | 348 - .../tests/gmock/gtest/src/gtest-test-part.cc | 110 - .../tests/gmock/gtest/src/gtest-typed-test.cc | 110 - .../cpp/ycm/tests/gmock/gtest/src/gtest.cc | 4930 ----------- .../ycm/tests/gmock/gtest/src/gtest_main.cc | 38 - .../gtest/test/gtest-death-test_ex_test.cc | 93 - .../gmock/gtest/test/gtest-death-test_test.cc | 1370 --- .../gmock/gtest/test/gtest-filepath_test.cc | 696 -- .../gmock/gtest/test/gtest-linked_ptr_test.cc | 154 - .../gmock/gtest/test/gtest-listener_test.cc | 313 - .../gmock/gtest/test/gtest-message_test.cc | 166 - .../gmock/gtest/test/gtest-options_test.cc | 212 - .../gtest/test/gtest-param-test2_test.cc | 65 - .../gmock/gtest/test/gtest-param-test_test.cc | 897 -- .../gmock/gtest/test/gtest-param-test_test.h | 57 - .../tests/gmock/gtest/test/gtest-port_test.cc | 1214 --- .../gmock/gtest/test/gtest-printers_test.cc | 1311 --- .../gmock/gtest/test/gtest-test-part_test.cc | 208 - .../gmock/gtest/test/gtest-tuple_test.cc | 320 - .../gtest/test/gtest-typed-test2_test.cc | 45 - .../gmock/gtest/test/gtest-typed-test_test.cc | 360 - .../gmock/gtest/test/gtest-typed-test_test.h | 66 - .../gtest/test/gtest-unittest-api_test.cc | 341 - .../tests/gmock/gtest/test/gtest_all_test.cc | 47 - .../test/gtest_break_on_failure_unittest.py | 218 - .../test/gtest_break_on_failure_unittest_.cc | 88 - .../gtest/test/gtest_catch_exceptions_test.py | 223 - .../test/gtest_catch_exceptions_test_.cc | 311 - .../gmock/gtest/test/gtest_color_test.py | 130 - .../gmock/gtest/test/gtest_color_test_.cc | 71 - .../gmock/gtest/test/gtest_env_var_test.py | 104 - .../gmock/gtest/test/gtest_env_var_test_.cc | 126 - .../gtest/test/gtest_environment_test.cc | 192 - .../gmock/gtest/test/gtest_filter_unittest.py | 633 -- .../gtest/test/gtest_filter_unittest_.cc | 140 - .../tests/gmock/gtest/test/gtest_help_test.py | 172 - .../gmock/gtest/test/gtest_help_test_.cc | 46 - .../gtest/test/gtest_list_tests_unittest.py | 177 - .../gtest/test/gtest_list_tests_unittest_.cc | 85 - .../gmock/gtest/test/gtest_main_unittest.cc | 45 - .../gtest/test/gtest_no_test_unittest.cc | 56 - .../gmock/gtest/test/gtest_output_test.py | 335 - .../gmock/gtest/test/gtest_output_test_.cc | 1021 --- .../test/gtest_output_test_golden_lin.txt | 711 -- .../gtest/test/gtest_pred_impl_unittest.cc | 2427 ------ .../tests/gmock/gtest/test/gtest_prod_test.cc | 57 - .../gmock/gtest/test/gtest_repeat_test.cc | 253 - .../gmock/gtest/test/gtest_shuffle_test.py | 326 - .../gmock/gtest/test/gtest_shuffle_test_.cc | 104 - .../gtest/test/gtest_sole_header_test.cc | 57 - .../gmock/gtest/test/gtest_stress_test.cc | 257 - .../gmock/gtest/test/gtest_test_utils.py | 305 - .../test/gtest_throw_on_failure_ex_test.cc | 92 - .../gtest/test/gtest_throw_on_failure_test.py | 171 - .../test/gtest_throw_on_failure_test_.cc | 72 - .../gtest/test/gtest_uninitialized_test.py | 70 - .../gtest/test/gtest_uninitialized_test_.cc | 43 - .../tests/gmock/gtest/test/gtest_unittest.cc | 7557 ----------------- .../gtest/test/gtest_xml_outfile1_test_.cc | 49 - .../gtest/test/gtest_xml_outfile2_test_.cc | 49 - .../gtest/test/gtest_xml_outfiles_test.py | 132 - .../gtest/test/gtest_xml_output_unittest.py | 284 - .../gtest/test/gtest_xml_output_unittest_.cc | 177 - .../gmock/gtest/test/gtest_xml_test_utils.py | 190 - .../ycm/tests/gmock/gtest/test/production.cc | 36 - .../ycm/tests/gmock/gtest/test/production.h | 55 - .../gtest/xcode/Config/DebugProject.xcconfig | 30 - .../xcode/Config/FrameworkTarget.xcconfig | 17 - .../gmock/gtest/xcode/Config/General.xcconfig | 41 - .../xcode/Config/ReleaseProject.xcconfig | 32 - .../xcode/Config/StaticLibraryTarget.xcconfig | 18 - .../gtest/xcode/Config/TestTarget.xcconfig | 8 - .../gmock/gtest/xcode/Resources/Info.plist | 30 - .../xcode/Samples/FrameworkSample/Info.plist | 28 - .../WidgetFramework.xcodeproj/project.pbxproj | 457 - .../xcode/Samples/FrameworkSample/runtests.sh | 62 - .../xcode/Samples/FrameworkSample/widget.cc | 63 - .../xcode/Samples/FrameworkSample/widget.h | 59 - .../Samples/FrameworkSample/widget_test.cc | 68 - .../gmock/gtest/xcode/Scripts/runtests.sh | 65 - .../gtest/xcode/Scripts/versiongenerate.py | 100 - .../xcode/gtest.xcodeproj/project.pbxproj | 1084 --- .../tests/gmock/include/gmock/gmock-actions.h | 1078 --- .../gmock/include/gmock/gmock-cardinalities.h | 147 - .../include/gmock/gmock-generated-actions.h | 2415 ------ .../gmock/gmock-generated-actions.h.pump | 821 -- .../gmock/gmock-generated-function-mockers.h | 929 -- .../gmock-generated-function-mockers.h.pump | 258 - .../include/gmock/gmock-generated-matchers.h | 2254 ----- .../gmock/gmock-generated-matchers.h.pump | 741 -- .../gmock/gmock-generated-nice-strict.h | 274 - .../gmock/gmock-generated-nice-strict.h.pump | 160 - .../gmock/include/gmock/gmock-matchers.h | 3234 ------- .../gmock/include/gmock/gmock-more-actions.h | 233 - .../gmock/include/gmock/gmock-spec-builders.h | 1774 ---- .../cpp/ycm/tests/gmock/include/gmock/gmock.h | 93 - .../internal/gmock-generated-internal-utils.h | 279 - .../gmock-generated-internal-utils.h.pump | 136 - .../gmock/internal/gmock-internal-utils.h | 484 -- .../gmock/include/gmock/internal/gmock-port.h | 78 - .../cpp/ycm/tests/gmock/msvc/2005/gmock.sln | 32 - .../ycm/tests/gmock/msvc/2005/gmock.vcproj | 191 - .../gmock/msvc/2005/gmock_config.vsprops | 15 - .../tests/gmock/msvc/2005/gmock_main.vcproj | 187 - .../tests/gmock/msvc/2005/gmock_test.vcproj | 201 - .../cpp/ycm/tests/gmock/msvc/2010/gmock.sln | 32 - .../ycm/tests/gmock/msvc/2010/gmock.vcxproj | 82 - .../tests/gmock/msvc/2010/gmock_config.props | 19 - .../tests/gmock/msvc/2010/gmock_main.vcxproj | 88 - .../tests/gmock/msvc/2010/gmock_test.vcxproj | 101 - .../tests/gmock/scripts/fuse_gmock_files.py | 240 - .../ycm/tests/gmock/scripts/generator/LICENSE | 203 - .../ycm/tests/gmock/scripts/generator/README | 35 - .../gmock/scripts/generator/README.cppclean | 115 - .../gmock/scripts/generator/cpp/__init__.py | 0 .../tests/gmock/scripts/generator/cpp/ast.py | 1723 ---- .../scripts/generator/cpp/gmock_class.py | 208 - .../scripts/generator/cpp/gmock_class_test.py | 259 - .../gmock/scripts/generator/cpp/keywords.py | 59 - .../gmock/scripts/generator/cpp/tokenize.py | 287 - .../gmock/scripts/generator/cpp/utils.py | 41 - .../gmock/scripts/generator/gmock_gen.py | 31 - .../ycm/tests/gmock/scripts/gmock-config.in | 303 - .../ycm/tests/gmock/scripts/gmock_doctor.py | 631 -- .../cpp/ycm/tests/gmock/scripts/upload.py | 1387 --- .../ycm/tests/gmock/scripts/upload_gmock.py | 78 - .../ycmd/cpp/ycm/tests/gmock/src/gmock-all.cc | 47 - .../tests/gmock/src/gmock-cardinalities.cc | 156 - .../tests/gmock/src/gmock-internal-utils.cc | 174 - .../cpp/ycm/tests/gmock/src/gmock-matchers.cc | 102 - .../tests/gmock/src/gmock-spec-builders.cc | 813 -- .../ycmd/cpp/ycm/tests/gmock/src/gmock.cc | 182 - .../cpp/ycm/tests/gmock/src/gmock_main.cc | 54 - .../tests/gmock/test/gmock-actions_test.cc | 1308 --- .../gmock/test/gmock-cardinalities_test.cc | 428 - .../test/gmock-generated-actions_test.cc | 1212 --- .../gmock-generated-function-mockers_test.cc | 540 -- .../gmock-generated-internal-utils_test.cc | 127 - .../test/gmock-generated-matchers_test.cc | 1236 --- .../gmock/test/gmock-internal-utils_test.cc | 649 -- .../tests/gmock/test/gmock-matchers_test.cc | 4196 --------- .../gmock/test/gmock-more-actions_test.cc | 705 -- .../gmock/test/gmock-nice-strict_test.cc | 284 - .../ycm/tests/gmock/test/gmock-port_test.cc | 43 - .../gmock/test/gmock-spec-builders_test.cc | 2528 ------ .../ycm/tests/gmock/test/gmock_all_test.cc | 48 - .../ycm/tests/gmock/test/gmock_leak_test.py | 90 - .../ycm/tests/gmock/test/gmock_leak_test_.cc | 100 - .../ycm/tests/gmock/test/gmock_link2_test.cc | 40 - .../ycm/tests/gmock/test/gmock_link_test.cc | 40 - .../ycm/tests/gmock/test/gmock_link_test.h | 669 -- .../ycm/tests/gmock/test/gmock_output_test.py | 180 - .../tests/gmock/test/gmock_output_test_.cc | 290 - .../gmock/test/gmock_output_test_golden.txt | 310 - .../ycm/tests/gmock/test/gmock_stress_test.cc | 322 - .../cpp/ycm/tests/gmock/test/gmock_test.cc | 255 - .../ycm/tests/gmock/test/gmock_test_utils.py | 111 - third_party/ycmd/cpp/ycm/tests/main.cpp | 13 - .../ycmd/cpp/ycm/tests/testdata/basic.cpp | 12 - .../ycmd/cpp/ycm/tests/testdata/basic.tags | 15 - .../ycmd/cpp/ycm/tests/testdata/goto.cpp | 18 - third_party/ycmd/cpp/ycm/versioning.cpp | 26 - third_party/ycmd/cpp/ycm/versioning.h | 22 - .../ycmd/cpp/ycm/ycm_client_support.cpp | 44 - third_party/ycmd/cpp/ycm/ycm_core.cpp | 164 - third_party/ycmd/run_tests.sh | 49 - third_party/ycmd/style_format.sh | 27 - third_party/ycmd/update_boost.sh | 44 - third_party/ycmd/ycmd/__init__.py | 0 third_party/ycmd/ycmd/__main__.py | 142 - third_party/ycmd/ycmd/completers/__init__.py | 0 .../ycmd/ycmd/completers/all/__init__.py | 0 .../completers/all/identifier_completer.py | 237 - .../all/tests/identifier_completer_test.py | 127 - third_party/ycmd/ycmd/completers/c/hook.py | 28 - third_party/ycmd/ycmd/completers/completer.py | 327 - .../ycmd/ycmd/completers/completer_utils.py | 78 - .../ycmd/completers/completer_utils_test.py | 56 - .../ycmd/ycmd/completers/cpp/__init__.py | 0 .../ycmd/completers/cpp/clang_completer.py | 310 - .../ycmd/ycmd/completers/cpp/clang_helpers.py | 27 - third_party/ycmd/ycmd/completers/cpp/flags.py | 206 - third_party/ycmd/ycmd/completers/cpp/hook.py | 28 - .../ycmd/completers/cpp/tests/__init__.py | 0 .../ycmd/completers/cpp/tests/flags_test.py | 136 - .../ycmd/ycmd/completers/cs/__init__.py | 0 .../ycmd/ycmd/completers/cs/cs_completer.py | 392 - third_party/ycmd/ycmd/completers/cs/hook.py | 21 - .../ycmd/ycmd/completers/general/__init__.py | 0 .../completers/general/filename_completer.py | 159 - .../general/general_completer_store.py | 122 - .../ycmd/completers/general/tests/__init__.py | 0 .../general/tests/filename_completer_test.py | 104 - .../filename_completer/include/Qt/QtGui | 1 - .../filename_completer/include/QtGui/QDialog | 0 .../filename_completer/include/QtGui/QWidget | 0 .../testdata/filename_completer/test.cpp | 4 - .../testdata/filename_completer/test.hpp | 0 .../completers/general/ultisnips_completer.py | 54 - .../ycmd/ycmd/completers/general_completer.py | 37 - third_party/ycmd/ycmd/completers/objc/hook.py | 27 - .../ycmd/ycmd/completers/objcpp/hook.py | 28 - .../ycmd/ycmd/completers/python/__init__.py | 0 .../ycmd/ycmd/completers/python/hook.py | 21 - .../ycmd/completers/python/jedi_completer.py | 153 - third_party/ycmd/ycmd/default_settings.json | 38 - third_party/ycmd/ycmd/extra_conf_store.py | 221 - third_party/ycmd/ycmd/handlers.py | 232 - third_party/ycmd/ycmd/hmac_plugin.py | 69 - third_party/ycmd/ycmd/responses.py | 133 - third_party/ycmd/ycmd/server_state.py | 113 - third_party/ycmd/ycmd/server_utils.py | 29 - third_party/ycmd/ycmd/tests/__init__.py | 0 .../ycmd/ycmd/tests/diagnostics_test.py | 257 - .../ycmd/ycmd/tests/extra_conf_store_test.py | 38 - .../ycmd/ycmd/tests/get_completions_test.py | 419 - .../ycmd/ycmd/tests/misc_handlers_test.py | 52 - .../ycmd/ycmd/tests/subcommands_test.py | 109 - third_party/ycmd/ycmd/tests/test_utils.py | 95 - .../ycmd/tests/testdata/.ycm_extra_conf.py | 5 - .../ycmd/ycmd/tests/testdata/basic.cpp | 13 - .../testdata/client_data/.ycm_extra_conf.py | 5 - .../ycmd/tests/testdata/client_data/main.cpp | 11 - .../tests/testdata/noflags/.ycm_extra_conf.py | 6 - .../ycmd/tests/testdata/noflags/basic.cpp | 13 - .../solution-named-like-folder/testy.sln | 20 - .../testy/Program.cs | 12 - .../testy/Properties/AssemblyInfo.cs | 22 - .../testy/testy.csproj | 41 - .../solution-named-like-folder/testy2.sln | 20 - .../testy/Program.cs | 12 - .../testy/Properties/AssemblyInfo.cs | 22 - .../testy/testy.csproj | 41 - .../solution-not-named-like-folder/testy1.sln | 20 - .../solution-not-named-like-folder/testy2.sln | 20 - .../ycmd/ycmd/tests/testdata/testy/Program.cs | 12 - .../testdata/testy/Properties/AssemblyInfo.cs | 22 - .../ycmd/tests/testdata/testy/testy.csproj | 41 - .../ycmd/ycmd/tests/testdata/testy/testy.sln | 20 - .../ycmd/tests/testdata/testy/testy.userprefs | 13 - third_party/ycmd/ycmd/user_options_store.py | 48 - third_party/ycmd/ycmd/utils.py | 268 - third_party/ycmd/ycmd/watchdog_plugin.py | 102 - 3536 files changed, 711201 deletions(-) delete mode 100755 third_party/ycmd/build.sh delete mode 100644 third_party/ycmd/cpp/BoostParts/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/cxx11/any_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/case_conv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/classification.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/compare.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/concept.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/constants.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/case_conv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/classification.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_all.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_store.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder_regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter_regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/predicate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/replace_storage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/sequence.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/trim.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/util.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/erase.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/finder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/iter_find.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/join.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate_facade.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex_find_format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/replace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/sequence_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/split.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/list_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/slist_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/string_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std_containers_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/trim.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string/yes_no_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/algorithm/string_regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/aligned_storage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/add_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/archive_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_archive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_streambuf_locale_saver.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_archive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_wiarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/binary_woarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/codecvt_null.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/archive_serializer_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_archive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_warchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_iserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_oserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/check.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/decl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/iserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/oserializer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/register_archive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/detail/utf8_codecvt_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/dinkumware.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/archive_serializer_map.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iprimitive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oprimitive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iprimitive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oprimitive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_grammar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_iarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_oarchive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_iarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_oarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_wiarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_woarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_iarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_oarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_wiarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_woarchive_impl.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/base64_from_binary.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/binary_from_base64.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/dataflow_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/escape.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/insert_linebreaks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/istream_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/mb_from_wchar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/ostream_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/remove_whitespace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/transform_width.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/unescape.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/wchar_from_mb.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_escape.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_unescape.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/shared_ptr_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/text_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/text_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/text_wiarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/text_woarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/wcslen.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/xml_archive_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/xml_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/xml_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/xml_wiarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/archive/xml_woarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/assignment_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/list_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/list_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/ptr_map_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/slist.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/stack.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/assign/std/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas128strong.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32strong.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32weak.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong-ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-alpha.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-armv6plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-cas.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-ppc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-sparcv9.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-x86.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/generic-cas.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/interlocked.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/link.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/linux-arm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/lockpool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/platform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/type-classification.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/atomic/detail/windows.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/bind_cc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf2_cc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf_cc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/bind_template.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_cc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_template.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_vw.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/protect.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/bind/storage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/call_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/cerrno.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/checked_delete.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/ceil.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/chrono.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/clock_string.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/chrono.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/mac/chrono.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/posix/chrono.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/win/chrono.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/is_evenly_divisible_by.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/static_assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/detail/system.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/duration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/system_clocks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/chrono/time_point.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer/base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer/debug.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer/details.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer/space_optimized.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/circular_buffer_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/compressed_pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/backward_compatibility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/borland.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_undef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/general.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/has_constraints.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/detail/msvc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept/usage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept_archetype.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/concept_check.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi_prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/abi_suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/auto_link.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/borland.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/clang.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/codegear.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/comeau.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/common_edg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/compaq_cxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/cray.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/digitalmars.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc_xml.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/greenhills.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/hp_acc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/intel.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/kai.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/metrowerks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/mpw.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/nvcc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/pathscale.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/pgi.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/sgi_mipspro.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/sunpro_cc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/vacpp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/compiler/visualc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/cmath.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/complex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/functional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/memory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/utility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/aix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/amigaos.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/beos.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/bsd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/cray.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/cygwin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/hpux.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/irix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/linux.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/macos.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/qnxnto.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/solaris.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/symbian.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/vms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/vxworks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/platform/win32.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/posix_features.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/requires_threads.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/select_compiler_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/select_platform_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/select_stdlib_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/dinkumware.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcomo.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcpp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libstdcpp3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/modena.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/msl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/roguewave.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/sgi.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/stlport.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/stdlib/vacpp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/user.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/config/warning_disable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/allocator_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/container_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/allocation_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/allocator_version_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/config_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/config_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/destroyers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/iterators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/memory_util.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/mpl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/multiallocation_chain.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/node_alloc_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/transform_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/tree.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/utilities.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/value_init.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/variadic_templates_tools.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/version_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/detail/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/container/throw_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/cregex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/cstdint.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/cstdlib.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/current_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/adjust_functors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/c_time.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/compiler_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/constrained_value.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_clock_device.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_defs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_format_simple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_limited.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_locales.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_generators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_names_put.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/date_parsing.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/dst_rules.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/filetime_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/format_date_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/conversion.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters_limited.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_calendar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_date.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day_of_year.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_month.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_weekday.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_year.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_ymd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_io.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/parsers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/int_adapter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/iso_format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/locale_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/microsec_time_clock.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/parse_format_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/period.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/period_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/period_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/conversion.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/date_duration_operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_duration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_system.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/ptime.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_formatters.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_period.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/special_defs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/string_convert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/string_parse_tree.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/strings_from_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_clock.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_defs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_duration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_formatting_streams.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_parsing.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_resolution_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_counted.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_split.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/wrapping_int.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/date_time/year_month_day.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/allocator_utilities.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/atomic_count.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/atomic_redef_macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/atomic_undef_macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/binary_search.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/bitmask.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/call_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/compressed_pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/container_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/dynamic_bitset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/endian.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/fenv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/indirect_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/interlocked.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/is_function_ref_tester.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/is_incrementable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/is_xxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/lcast_precision.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/lightweight_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/no_exceptions_support.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/numeric_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/ob_call_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/ob_compressed_pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/quick_allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/reference_content.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/scoped_enum_emulation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/select_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/sp_typeinfo.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/winapi/GetLastError.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/winapi/basic_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/winapi/time.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/winapi/timers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/detail/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/dynamic_bitset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/enable_shared_from_this.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/all.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/current_exception_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/attribute_noreturn.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/clone_current_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/error_info_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/exception_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/is_output_streamable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/object_hex_dump.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/detail/type_info.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/diagnostic_information.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_api_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_at_line.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_errno.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_handle.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_name.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_open_mode.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_nested_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_type_info_name.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/error_info.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/get_error_info.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/info.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/info_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/to_string.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception/to_string_stub.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/exception_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/convenience.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/detail/utf8_codecvt_facet.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/fstream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/operations.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/path.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/filesystem/path_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/foreach.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/foreach_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/compat_workarounds.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/config_macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/msvc_disambiguater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/unset_macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_gcc-2_95.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_stlport.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/exceptions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/feed_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/format_class.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/format_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/format_implementation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/free_funcs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/group.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/internals.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/internals_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/format/parsing.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/detail/function_iterate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/detail/gen_maybe_include.pl delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/detail/maybe_include.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/detail/prologue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function6.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function7.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function8.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function9.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function/function_template.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/function_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/float_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/hash_float.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/limits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/extensions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/functional/hash_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/get_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/breadth_first_search.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/buffer_concepts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/detail/adj_list_edge_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/detail/adjacency_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/detail/d_ary_heap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/detail/edge.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/breadth_first_search.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/concepts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/filtered_queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/queue.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/two_bit_color_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/distributed/unsafe_serialize.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/graph_concepts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/graph_mutability_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/graph_selectors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/graph_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/iteration_macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/named_function_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/named_graph.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/numeric_values.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/overloading.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/algorithm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/basic_reduce.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/container_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/inplace_all_to_all.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/untracked_pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/process_group.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/properties.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/parallel/simple_trigger.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/properties.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/constant_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/null_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/reverse_graph.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/two_bit_color_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/graph/visitors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/implicit_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/indirect_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/integer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/integer/static_log2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/integer_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/integer_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/detail/allocator_common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/allocation_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/version_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/creation_tags.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/cast_tags.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/in_place_interface.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/intermodule_singleton_common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/interprocess_tester.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_memory_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_open_or_create_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/math_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/min_max.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/mpl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/named_proxy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_file_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_thread_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/posix_time_types_wrk.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/segment_manager_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/tmp_dir_helpers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/transform_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/utilities.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/variadic_templates_tools.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/win32_api.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/windows_intermodule_singleton.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/errors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/exceptions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/indexes/iset_index.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/interprocess_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/managed_shared_memory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/mapped_region.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/detail/mem_algo_common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/rbtree_best_fit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/offset_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/permissions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/segment_manager.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/shared_memory_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/smart_ptr/deleter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/streams/bufferstream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/lock_options.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/mutex_family.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/null_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/pthread_helpers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/ptime_to_timespec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/scoped_lock.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/wait.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/sync_utils.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_mutex_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_semaphore_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/circular_slist_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/clear_on_destructor_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/common_slist_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/ebo_functor_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/function_detector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/generic_hook.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/has_member_function_callable_with.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/is_stateful_value_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/memory_util.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/mpl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/parent_from_member.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/rbtree_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/slist_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/tree_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/utilities.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/intrusive_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/linear_slist_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/link_mode.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/options.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/pointer_plus_bits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/pointer_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/rbtree.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/rbtree_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/set_hook.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/slist.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive/slist_hook.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/intrusive_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/io/detail/quoted_manip.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/io/ios_state.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/io_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/is_placeholder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/counting_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/detail/config_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/detail/config_undef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/detail/enable_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/detail/facade_iterator_category.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/detail/minimum_category.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/filter_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/interoperable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/iterator_adaptor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/iterator_categories.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/iterator_concepts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/iterator_facade.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/iterator_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/reverse_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/iterator/transform_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/actions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/arity_code.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/function_adaptors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/is_instance_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/lambda_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/lambda_functor_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/lambda_functors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/lambda_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/lambda_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/member_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/operator_actions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/operator_lambda_func_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/operator_return_type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/ret.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/return_type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/detail/select_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lambda/lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lexical_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/limits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/branch_hints.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/copy_payload.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/freelist.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/tagged_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/tagged_ptr_dcas.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/detail/tagged_ptr_ptrcompression.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/policies.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/spsc_queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/lockfree/stack.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/make_shared.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/common_factor_rt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/policies/policy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/special_functions/detail/fp_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/special_functions/detail/round_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/special_functions/fpclassify.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/special_functions/math_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/special_functions/sign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/tools/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/tools/promotion.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/tools/real_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math/tools/user.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/math_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mem_fn.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/memory_order.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/algorithm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/detail/config_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/detail/config_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/detail/meta_utils.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/detail/move_helpers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/move.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/move/utility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/all_gather.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/all_reduce.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/all_to_all.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/broadcast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/gather.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/reduce.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/scan.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives/scatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/collectives_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/communicator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/datatype.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/datatype_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/binary_buffer_iprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/binary_buffer_oprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/broadcast_sc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/communicator_sc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/computation_tree.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/content_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/forward_skeleton_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/forward_skeleton_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/ignore_iprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/ignore_oprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/ignore_skeleton_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/mpi_datatype_cache.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/mpi_datatype_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/mpi_datatype_primitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/packed_iprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/packed_oprimitive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/point_to_point.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/detail/text_skeleton_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/environment.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/graph_communicator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/group.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/inplace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/intercommunicator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/nonblocking.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/operations.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/packed_iarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/packed_oarchive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/python/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/python/serialize.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/python/skeleton_and_content.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/request.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/skeleton_and_content.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/skeleton_and_content_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/status.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpi/timer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/O1_size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/O1_size_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/advance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/advance_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/always.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/arg_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/at.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/at_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/O1_size_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/adl_barrier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/arg_typedef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/arithmetic_op.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/arity_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/at_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/back_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/begin_end_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/clear_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/common_name_wknd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/comparison_op.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/adl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/arrays.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/bcc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/compiler.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/dependent_nttp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/dmc_ambiguous_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/dtp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/eti.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/forwarding.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/gcc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/has_apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/has_xxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/integral.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/intel.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/msvc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/msvc_typename.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/nttp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/overload_resolution.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/pp_counter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/static_constant.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/ttp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/typeof.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/use_preprocessed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/config/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/contains_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/count_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/empty_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/find_if_pred.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/fold_impl_body.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/front_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_key_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_rebind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/has_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/include_preprocessed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/insert_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/inserter_algorithm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/integral_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/is_msvc_eti_arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/iter_apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/joint_iter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/lambda_arity_param.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/lambda_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/lambda_support.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/largest_int.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/logical_op.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/msvc_dtw.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/msvc_eti_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/msvc_is_class.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/msvc_never_true.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/msvc_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/na.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/na_assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/na_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/na_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/nested_type_wknd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/nttp_decl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/numeric_cast_utils.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/numeric_op.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/overload_names.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/pop_front_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc551/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/bcc_pre590/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/dmc/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/gcc/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc60/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/msvc70/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/mwcw/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ctps/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/no_ttp/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/advance_backward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/advance_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/apply_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/apply_wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/basic_bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/full_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/inherit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/iter_fold_if_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/lambda_no_ctps.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/list_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/set_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/shift_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/shift_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/unpack_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessed/plain/vector_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/add.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/def_params_tail.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/default_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/ext_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/filter_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/partial_spec_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/range.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/repeat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/sub.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/preprocessor/tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/ptr_to_ref.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/push_back_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/push_front_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/reverse_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/reverse_fold_impl_body.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/reverse_iter_fold_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/sequence_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/single_element_iter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/size_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/static_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/template_arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/template_arity_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/traits_lambda_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/type_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/unwrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/value_wknd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/aux_/yes_no.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/back_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/back_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/begin_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/begin_end_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/bind.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/bind_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/bool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/bool_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/clear.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/clear_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/comparison.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/contains.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/contains_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/copy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/deref.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/distance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/distance_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/empty_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/erase_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/erase_key_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/eval_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/find.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/find_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/fold.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/for_each.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/front_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/front_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/has_key.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/has_key_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/has_xxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/identity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/insert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/insert_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/int.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/int_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/integral_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/integral_c_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/integral_c_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/is_placeholder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/is_sequence.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/iter_fold.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/iter_fold_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/iterator_category.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/iterator_range.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/iterator_tags.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/joint_view.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/key_type_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/lambda_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/limits/arity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/limits/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/limits/unrolling.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/limits/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/O1_size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/begin_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/clear.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/include_preprocessed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/item.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/numbered.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/numbered_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/pop_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/preprocessed/plain/list50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/push_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/push_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/aux_/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list0_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/list/list50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/logical.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/long.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/long_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/min_max.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/multiplies.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/negate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/next.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/next_prior.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/not.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/numeric_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/pair.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/pair_view.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/placeholders.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/pop_back_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/pop_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/pop_front_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/print.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/prior.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/protect.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/push_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/push_back_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/push_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/push_front_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/quote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/remove_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/reverse_fold.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/reverse_iter_fold.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/same_as.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/sequence_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/sequence_tag_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/at_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/begin_end_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/clear_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/empty_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/erase_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/erase_key_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/has_key_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/insert_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/item.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/key_type_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/set0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/size_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/aux_/value_type_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/set/set0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/single_view.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/size_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/size_t.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/size_t_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/times.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/transform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/value_type_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/O1_size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/at.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/begin_end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/clear.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/include_preprocessed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/item.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/numbered.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/numbered_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/pop_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/pop_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/no_ctps/vector50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/plain/vector50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/preprocessed/typeof_based/vector50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/push_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/push_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/aux_/vector0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector0_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector10.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector10_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector20.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector20_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector30.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector30_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector40.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector40_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/vector/vector50_c.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/void.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/mpl/void_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/access_specifier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/adl_swap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/archive_constructed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/auto_space.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/base_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/bidir_node_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/bucket_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/copy_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/do_not_copy_elements_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/duplicates_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/has_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/hash_index_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/hash_index_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/hash_index_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/header_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/index_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/index_loader.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/index_matcher.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/index_node_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/index_saver.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/invariant_assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/is_index_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/iter_adaptor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/modify_key_adaptor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/msvc_index_specifier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/no_duplicate_tags.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/node_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/ord_index_args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/ord_index_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/ord_index_ops.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/prevent_eti.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/safe_ctr_proxy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/safe_mode.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/scope_guard.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/seq_index_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/seq_index_ops.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/serialization_version.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/uintptr_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/unbounded.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/value_compare.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/detail/vartempl_support.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/hashed_index.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/hashed_index_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/identity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/identity_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/indexed_by.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/member.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/ordered_index.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/ordered_index_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/safe_mode_errors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/sequenced_index.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/sequenced_index_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index_container.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/multi_index_container_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/next_prior.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/non_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/noncopyable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/none.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/none_t.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/bounds.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/conversion_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/converter_policies.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/bounds.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/conversion_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/int_float_mixture.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/is_subranged.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/meta.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/numeric_cast_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/old_numeric_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_long_long.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/sign_mixture.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/detail/udt_builtin_mixture.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/int_float_mixture_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/numeric_cast_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/sign_mixture_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/numeric/conversion/udt_builtin_mixture_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/optional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/optional/optional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/optional/optional_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/arg_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/default.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/is_maybe.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/overloads.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/parameter_requirements.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/parenthesized_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/preprocessor/flatten.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/preprocessor/for_each.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/result_of0.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/tagged_argument.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/template_keyword.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/unwrap_cv_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/void.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/aux_/yesno.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/binding.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/keyword.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/macros.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/match.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/name.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/parameters.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/parameter/value_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/container_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/cstddef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/detail/property.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/integer_log2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/lowest_bit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/property.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pending/queue.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pointee.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/pointer_to_other.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/alpha.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/arm.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/blackfin.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/convex.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/ia64.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/m68k.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/mips.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/parisc.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/ppc.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/pyramid.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/rs6k.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/sparc.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/superh.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/sys370.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/sys390.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/x86.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/x86/32.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/x86/64.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/architecture/z.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/detail/_cassert.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/detail/endian_compat.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/detail/os_detected.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/detail/test.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/library/c/_prefix.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/library/c/gnu.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/make.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd/bsdi.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd/dragonfly.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd/free.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd/net.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/bsd/open.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/macos.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/os/windows.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/other/endian.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/predef/version_number.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/add.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/dec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/detail/div_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/div.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/inc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/mod.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/mul.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/arithmetic/sub.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/data.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/elem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/insert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/pop_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/pop_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/push_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/push_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/remove.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/replace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/reverse.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/to_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/to_seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/array/to_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/cat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comma_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/comparison/not_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/config/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/config/limits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/deduce_d.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/detail/dmc/while.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/detail/edg/while.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/detail/msvc/while.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/detail/while.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/expr_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/expr_iif.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/iif.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/control/while.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/debug.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/debug/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/debug/error.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/debug/line.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/dec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/auto_rec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/check.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/dmc/auto_rec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/is_binary.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/is_nullary.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/is_unary.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/detail/split.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/enum_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/enum_params_with_a_default.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/enum_params_with_defaults.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/enum_shifted_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/expr_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/apply.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/expand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/identity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/intercept.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/is_empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/facilities/overload.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/identity.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/inc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iterate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/lower1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/lower2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/lower3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/lower4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/lower5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/upper1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/upper2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/upper3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/upper4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/bounds/upper5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/finish.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/forward1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/forward2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/forward3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/forward4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/forward5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/reverse1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/reverse2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/reverse3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/reverse4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/iter/reverse5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/local.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/rlocal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/self.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/detail/start.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/iterate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/local.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/iteration/self.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/library.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/adt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/append.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/at.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/cat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/detail/dmc/fold_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/detail/edg/fold_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/detail/edg/fold_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/detail/fold_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/detail/fold_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/filter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/first_n.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/fold_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/fold_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/for_each.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/for_each_i.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/for_each_product.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/rest_n.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/reverse.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/to_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/to_seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/to_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/list/transform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/bitand.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/bitnor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/bitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/bitxor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/bool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/compl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/nor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/not.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/logical/xor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/punctuation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/punctuation/comma.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/punctuation/comma_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/punctuation/paren.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/punctuation/paren_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repeat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repeat_2nd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repeat_from_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/deduce_r.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/deduce_z.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/detail/dmc/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/detail/edg/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/detail/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/detail/msvc/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_binary_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_params_with_a_default.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_params_with_defaults.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_shifted.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_shifted_binary_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_shifted_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_trailing.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_trailing_binary_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/enum_trailing_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/for.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/repeat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/repetition/repeat_from_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/selection.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/selection/max.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/selection/min.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/cat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/detail/binary_transform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/detail/split.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/elem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/filter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/first_n.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/fold_left.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/fold_right.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/for_each.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/for_each_i.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/for_each_product.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/insert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/pop_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/pop_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/push_back.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/push_front.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/remove.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/replace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/rest_n.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/reverse.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/subseq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/to_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/to_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/to_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/seq/transform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/counter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/shared.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/slot1.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/slot2.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/slot3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/slot4.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/detail/slot5.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/slot/slot.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/stringize.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/eat.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/elem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/rem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/reverse.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/to_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/to_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/tuple/to_seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/elem.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/to_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/to_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/to_seq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/preprocessor/variadic/to_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/progress.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/parallel/distributed_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/parallel/impl/distributed_property_map.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/parallel/local_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/shared_array_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/property_map/vector_property_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/clone_allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/associative_ptr_container.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/default_deleter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/is_convertible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/map_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/meta_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/move.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/reversible_ptr_container.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/scoped_deleter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/static_move_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/throw_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/detail/void_ptr_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/indirect_fun.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/nullable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_circular_buffer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_container.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_deque.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_inserter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_map_adapter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_sequence_adapter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_set_adapter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_unordered_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_unordered_set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ptr_container/ptr_vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/arg_from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/args.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/args_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/back_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/base_type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/bases.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/borrowed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/call.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/call_method.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/class.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/class_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/arg_from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/arg_to_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/arg_to_python_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/as_to_python_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/builtin_converters.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/constructor_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/context_result_converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/convertible_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/implicit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/obj_mgr_arg_from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/object_manager.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/pointer_type_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/pyobject_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/pyobject_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/pytype_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/pytype_object_mgr_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/registered.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/registered_pointee.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/registrations.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/registry.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/return_from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/rvalue_from_python_data.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/shared_ptr_deleter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/shared_ptr_from_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/shared_ptr_to_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/converter/to_python_function_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/copy_const_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/copy_non_const_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/data_members.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/def_visitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/default_call_policies.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/borrowed_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/caller.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/construct.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/convertible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/copy_ctor_mutates_rhs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/cv_category.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/dealloc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/decorated_type_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/decref_guard.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/def_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/def_helper_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/defaults_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/defaults_gen.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/dependent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/destroy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/exception_handler.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/force_instantiate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/indirect_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/invoke.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/is_auto_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/is_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/is_xxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/make_keyword_range_fn.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/make_tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/map_entry.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/mpl_lambda.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/msvc_typeinfo.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/none.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/not_specified.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/nullary_function_adaptor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/operator_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/overloads_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/preprocessor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/python22_fixed.h delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/python_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/raw_pyobject.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/referent_storage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/scope.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/sfinae.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/signature.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/string_literal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/target.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/translate_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/type_list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/type_list_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/type_list_impl_no_pts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/unwind_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/unwrap_type_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/unwrap_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/value_arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/value_is_shared_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/value_is_xxx.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/void_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/void_return.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/wrap_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/detail/wrapper_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/dict.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/docstring_options.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/errors.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/exception_translator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/exec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/extract.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/handle.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/handle_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/has_back_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/implicit.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/import.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/init.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/instance_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/long.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/lvalue_from_pytype.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/make_constructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/make_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/manage_new_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/module.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/module_init.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/numeric.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/add_to_namespace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/class.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/class_detail.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/class_metadata.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/class_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/enum_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/find_instance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/function_doc_signature.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/function_handle.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/function_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/inheritance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/inheritance_query.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/instance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/iterator_core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/life_support.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/make_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/make_instance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/make_ptr_instance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/pickle_support.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/pointer_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/py_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/stl_iterator_core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/value_holder.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object/value_holder_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_attributes.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_call.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_items.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_protocol.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_protocol_core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/object_slices.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/opaque_pointer_converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/other.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/overloads.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/override.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/pointee.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/proxy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/pure_virtual.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/refcount.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/reference_existing_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/register_ptr_to_python.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/return_arg.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/return_by_value.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/return_internal_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/return_opaque_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/return_value_policy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/scope.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/self.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/signature.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/slice.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/slice_nil.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/ssize_t.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/stl_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/str.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/suite/indexing/container_utils.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/suite/indexing/detail/indexing_suite_detail.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/suite/indexing/indexing_suite.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/suite/indexing/vector_indexing_suite.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/to_python_converter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/to_python_indirect.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/to_python_value.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/type_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/with_custodian_and_ward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/python/wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/algorithm/equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/as_literal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/concepts.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/const_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/as_literal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/begin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/const_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/detail_str.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/extract_optional_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/implementation_help.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/misc_concept.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/remove_extent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/safe_bool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/sfinae.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/size_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/str_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/value_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/detail/vc6/end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/difference_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/distance.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/end.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/irange.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/iterator_range.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/iterator_range_core.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/iterator_range_io.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/mutable_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/rbegin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/rend.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/result_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/reverse_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/size.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/size_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/range/value_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/detail/mpl/abs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/detail/mpl/gcd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/detail/mpl/lcm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/detail/mpl/sign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/detail/overflow_helpers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/mpl/rational_c_tag.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/ratio.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ratio/ratio_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/rational.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/ref.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/config/borland.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/config/cwchar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/icu.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/pattern_except.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/pending/object_cache.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/pending/static_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/pending/unicode_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/user.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/basic_regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/basic_regex_creator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/basic_regex_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/c_regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/char_regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/cpp_regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/cregex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/error_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/fileiter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/instances.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/iterator_category.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/iterator_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/match_flags.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/match_results.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/mem_block_cache.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/perl_matcher.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/perl_matcher_common.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/perl_matcher_non_recursive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/perl_matcher_recursive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/primary_transform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/protected_call.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regbase.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_format.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_grep.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_match.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_merge.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_raw_buffer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_replace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_search.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_split.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_token_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_traits_defaults.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/regex_workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/states.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/sub_match.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/syntax_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/u32regex_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/u32regex_token_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex/v4/w32_regex_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/regex_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/scoped_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/scoped_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/access.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/assume_abstract.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/base_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/collection_size_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/collection_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/collections_load_imp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/collections_save_imp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/detail/get_data.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/detail/shared_count_132.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/detail/shared_ptr_132.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/detail/shared_ptr_nmt_132.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/detail/stack_constructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/extended_type_info.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/extended_type_info_no_rtti.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/extended_type_info_typeid.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/factory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/force_include.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/is_bitwise_serializable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/item_version_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/level.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/level_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/nvp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/pfto.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/serialization.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/shared_ptr_132.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/singleton.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/smart_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/split_free.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/split_member.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/state_saver.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/static_warning.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/string.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/strong_typedef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/throw_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/tracking.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/tracking_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/type_info_implementation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/utility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/version.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/void_cast.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/void_cast_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/serialization/wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/shared_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/shared_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/allocate_shared_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/bad_weak_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/allocate_array_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/array_deleter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/array_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/array_utility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count_gcc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count_gcc_x86.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count_pthreads.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count_sync.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/atomic_count_win32.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/lightweight_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/lwm_nop.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/lwm_pthreads.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/lwm_win32_cs.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/make_array_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/operator_bool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/quick_allocator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/shared_array_nmt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/shared_count.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/shared_ptr_nmt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_convertible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_acc_ia64.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_aix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_cw_ppc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_gcc_ia64.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_nt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_pt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_snc_ps3.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_spin.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_sync.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_vacpp_ppc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_base_w32.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_counted_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_forward.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_has_sync.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_if_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/sp_nullptr_t.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_gcc_arm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_nt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_pool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_pt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_sync.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/spinlock_w32.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/detail/yield_k.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/enable_shared_from_this.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/intrusive_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/make_shared.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/make_shared_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/make_shared_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/scoped_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/scoped_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/shared_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/shared_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/smart_ptr/weak_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/actions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/alternative.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/composite.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/difference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/directives.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/exclusive_or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/alternative.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/difference.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/directives.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/exclusive_or.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/intersection.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/kleene_star.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/list.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/optional.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/positive.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/sequence.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/sequential_and.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/impl/sequential_or.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/intersection.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/kleene_star.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/list.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/optional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/positive.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/sequence.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/sequential_and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/composite/sequential_or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/impl/match.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/impl/match_attr_traits.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/impl/parser.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/match.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/nil.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/non_terminal/impl/rule.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/non_terminal/parser_context.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/non_terminal/parser_id.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/non_terminal/rule.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/primitives/impl/numerics.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/primitives/impl/primitives.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/primitives/numerics.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/primitives/numerics_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/primitives/primitives.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/safe_bool.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/scanner/impl/skipper.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/scanner/scanner.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/scanner/scanner_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/scanner/skipper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/core/scanner/skipper_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/debug.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/debug/debug_node.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/debug/minimal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/meta/as_parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/namespace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/chset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/chset_operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset/basic_chset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset/basic_chset.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset/range_run.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset/range_run.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/utility/impl/chset_operators.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/home/classic/version.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/include/classic_actions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/include/classic_chset.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/include/classic_numerics.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/include/classic_operators.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/spirit/include/classic_rule.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/static_assert.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/swap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/system/api_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/system/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/system/error_code.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/system/system_error.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/debug.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/debug_config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/enable_warnings.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/fwd_decl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/global_typedef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/log_level.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/suppress_warnings.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/unit_test_parameters.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/detail/workaround.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/execution_monitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/floating_point_comparison.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/framework.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/compiler_log_formatter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/cpp_main.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/debug.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/exception_safety.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/execution_monitor.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/framework.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/interaction_based.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/logged_expectations.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/plain_report_formatter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/progress_monitor.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/results_collector.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/results_reporter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/test_main.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/test_tools.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/unit_test_log.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/unit_test_main.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/unit_test_monitor.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/unit_test_parameters.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/unit_test_suite.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/xml_log_formatter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/impl/xml_report_formatter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/included/test_exec_monitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/included/unit_test.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/interaction_based.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/minimal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/mock_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/output/compiler_log_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/output/plain_report_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/output/xml_log_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/output/xml_report_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/output_test_stream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/predicate_result.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/progress_monitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/results_collector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/results_reporter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/test_exec_monitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/test_observer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/test_tools.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test_log.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test_log_formatter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test_monitor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test_suite.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/unit_test_suite_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/algorithm.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/assign_op.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/basic_cstring/basic_cstring.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/basic_cstring/basic_cstring_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/basic_cstring/bcs_char_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/basic_cstring/compare.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/basic_cstring/io.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/callback.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/class_properties.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/custom_manip.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/fixed_mapping.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/foreach.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/iterator/input_iterator_facade.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/iterator/token_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/lazy_ostream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/named_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/rtti.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/argument.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/argument_factory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/argv_traverser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/argv_traverser.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/basic_parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/char_parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/char_parameter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/detail/argument_value_usage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/dual_name_parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/dual_name_parameter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/id_policy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/id_policy.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/iface/argument_factory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/iface/id_policy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/modifier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/named_parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/named_parameter.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/parser.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/parser.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/typed_parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/validation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/validation.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/value_generator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/cla/value_handler.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/env/environment.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/env/environment.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/env/fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/env/modifier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/env/variable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/interpret_argument_value.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/parameter.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/trace.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/runtime/validation.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/trivial_singleton.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/wrap_stringstream.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/test/utils/xml_printer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/barrier.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/condition_variable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/cv_status.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/async_func.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/delete.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/invoke.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/is_convertible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/lockable_wrapper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/make_tuple_indices.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/memory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/move.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/platform.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/thread.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/thread_group.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/thread_heap_alloc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/thread_interruption.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/detail/tss_hooks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/exceptions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/future.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/future_error_code.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/is_locked_by_this_thread.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/lock_algorithms.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/lock_guard.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/lock_options.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/lock_types.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/lockable_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/locks.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/once.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/condition_variable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/condition_variable_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/once.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/once_atomic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/pthread_mutex_scoped_lock.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/shared_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/thread_data.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/thread_heap_alloc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/pthread/timespec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/shared_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/thread.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/thread_only.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/thread_time.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/tss.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/v2/thread.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/basic_recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/basic_timed_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/condition_variable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/interlocked_read.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/once.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/recursive_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/shared_mutex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/thread_data.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/thread_heap_alloc.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/win32/thread_primitives.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/thread/xtime.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/throw_exception.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/timer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/token_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/token_iterator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tokenizer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tuple/detail/tuple_basic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tuple/detail/tuple_basic_no_partial_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tuple/tuple.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tuple/tuple_comparison.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/tuple/tuple_io.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_const.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_cv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_lvalue_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_rvalue_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/add_volatile.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/aligned_storage.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/alignment_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/alignment_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/arithmetic_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/array_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/broken_compiler_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/common_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/composite_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/conditional.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/config.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/conversion_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/cv_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/decay.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/bool_trait_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/bool_trait_undef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/common_type_imp.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/cv_traits_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/false_result.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/has_binary_operator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/has_postfix_operator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/has_prefix_operator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/ice_and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/ice_eq.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/ice_not.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/ice_or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/is_function_ptr_helper.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/is_function_ptr_tester.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/is_mem_fun_pointer_tester.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/size_t_trait_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/size_t_trait_undef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/template_arity_spec.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/type_trait_def.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/type_trait_undef.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/wrap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/detail/yes_no_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/extent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/floating_point_promotion.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/function_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_and_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_or_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_xor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_bit_xor_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_complement.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_dereference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_divides.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_divides_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_greater.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_greater_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_left_shift.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_left_shift_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_less.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_less_equal.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_logical_and.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_logical_not.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_logical_or.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_minus_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_modulus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_modulus_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_multiplies.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_multiplies_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_negate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_new_operator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_not_equal_to.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_nothrow_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_nothrow_constructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_nothrow_copy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_nothrow_destructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_operator.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_plus_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_post_decrement.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_post_increment.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_pre_decrement.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_pre_increment.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_right_shift.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_right_shift_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_constructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_copy.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_destructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_move_assign.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_trivial_move_constructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_unary_minus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_unary_plus.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/has_virtual_destructor.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/ice.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/integral_constant.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/integral_promotion.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/intrinsics.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_abstract.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_arithmetic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_array.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_base_and_derived.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_base_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_class.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_complex.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_compound.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_const.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_convertible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_copy_constructible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_empty.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_enum.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_float.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_floating_point.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_function.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_fundamental.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_integral.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_lvalue_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_member_function_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_member_object_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_member_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_nothrow_move_assignable.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_nothrow_move_constructible.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_object.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_pod.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_polymorphic.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_rvalue_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_same.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_scalar.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_signed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_stateless.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_union.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_unsigned.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_virtual_base_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_void.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/is_volatile.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/make_signed.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/make_unsigned.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_all_extents.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_bounds.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_const.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_cv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_extent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/remove_volatile.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/msvc/typeof.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/object_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/promote.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/rank.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_all_extents.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_bounds.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_const.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_cv.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_extent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_pointer.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_reference.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/remove_volatile.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/same_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/transform_traits.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/type_traits/type_with_alignment.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/dmc/typeof_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/encode_decode.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/encode_decode_params.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/int_encoding.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/integral_template_param.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/message.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/modifiers.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/msvc/typeof_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/native.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/pointers_data_members.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/register_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/register_functions_iterate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/register_fundamental.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/register_mem_functions.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/template_encoding.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/template_template_param.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/type_encoding.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/type_template_param.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/typeof.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/typeof_impl.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/unsupported.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/vector.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/vector100.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/vector150.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/vector200.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/typeof/vector50.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/allocate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/buckets.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/equivalent.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/extract_key.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/table.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/unique.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/detail/util.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/unordered_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/unordered_map_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/unordered_set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered/unordered_set_fwd.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered_map.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/unordered_set.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/addressof.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/base_from_member.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/binary.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/compare_pointees.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/declval.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/detail/in_place_factory_prefix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/detail/in_place_factory_suffix.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/detail/result_of_iterate.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/enable_if.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/identity_type.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/in_place_factory.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/result_of.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/swap.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/utility/value_init.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/version.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/visit_each.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/boost/weak_ptr.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/atomic/src/lockpool.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/gregorian/date_generators.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/gregorian/greg_month.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/gregorian/greg_names.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/gregorian/greg_weekday.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/gregorian/gregorian_types.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/date_time/src/posix_time/posix_time_types.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/exception/src/clone_current_exception_non_intrusive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/codecvt_error_category.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/operations.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/path.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/path_traits.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/portability.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/unique_path.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/utf8_codecvt_facet.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/windows_file_codecvt.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/filesystem/src/windows_file_codecvt.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/converter/arg_to_python_base.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/converter/builtin_converters.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/converter/from_python.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/converter/registry.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/converter/type_id.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/dict.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/errors.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/exec.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/import.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/list.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/long.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/module.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/numeric.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/class.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/enum.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/function.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/function_doc_signature.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/inheritance.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/iterator.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/life_support.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/pickle_support.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object/stl_iterator.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object_operators.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/object_protocol.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/slice.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/str.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/tuple.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/python/src/wrapper.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/c_regex_traits.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/cpp_regex_traits.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/cregex.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/fileiter.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/icu.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/instances.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/internals.hpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/posix_api.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/regex.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/regex_debug.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/regex_raw_buffer.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/regex_traits_defaults.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/static_mutex.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/usinstances.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/w32_regex_traits.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/wc_regex_traits.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/wide_posix_api.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/regex/src/winstances.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/archive_exception.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_archive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_iarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_iserializer.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_oarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_oserializer.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_pointer_iserializer.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_pointer_oserializer.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_serializer_map.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_text_iprimitive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_text_oprimitive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_text_wiprimitive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_text_woprimitive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_xml_archive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/basic_xml_grammar.ipp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/binary_iarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/binary_oarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/binary_wiarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/binary_woarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/codecvt_null.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/extended_type_info.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/extended_type_info_no_rtti.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/extended_type_info_typeid.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/polymorphic_iarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/polymorphic_oarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/shared_ptr_helper.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/stl_port.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/text_iarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/text_oarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/text_wiarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/text_woarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/utf8_codecvt_facet.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/void_cast.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_archive_exception.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_grammar.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_iarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_oarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_wgrammar.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_wiarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/serialization/src/xml_woarchive.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/smart_ptr/src/sp_collector.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/smart_ptr/src/sp_debug_hooks.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/system/src/error_code.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/system/src/local_free_on_destruction.hpp delete mode 100755 third_party/ycmd/cpp/BoostParts/libs/thread/src/future.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/pthread/once.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/pthread/once_atomic.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/pthread/thread.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/pthread/timeconv.inl delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/tss_null.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/win32/thread.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/win32/timeconv.inl delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/win32/tss_dll.cpp delete mode 100644 third_party/ycmd/cpp/BoostParts/libs/thread/src/win32/tss_pe.cpp delete mode 100644 third_party/ycmd/cpp/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/llvm/include/clang-c/CXCompilationDatabase.h delete mode 100644 third_party/ycmd/cpp/llvm/include/clang-c/CXString.h delete mode 100644 third_party/ycmd/cpp/llvm/include/clang-c/Index.h delete mode 100644 third_party/ycmd/cpp/llvm/include/clang-c/Platform.h delete mode 100644 third_party/ycmd/cpp/ycm/.ycm_extra_conf.py delete mode 100644 third_party/ycmd/cpp/ycm/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/ycm/Candidate.cpp delete mode 100644 third_party/ycmd/cpp/ycm/Candidate.h delete mode 100644 third_party/ycmd/cpp/ycm/CandidateRepository.cpp delete mode 100644 third_party/ycmd/cpp/ycm/CandidateRepository.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangCompleter.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangCompleter.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangHelpers.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangHelpers.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangUtils.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/ClangUtils.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/CompilationDatabase.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/CompilationDatabase.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/CompletionData.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/CompletionData.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/Diagnostic.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/Location.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/Range.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/Range.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/TranslationUnit.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/TranslationUnit.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/TranslationUnitStore.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/TranslationUnitStore.h delete mode 100644 third_party/ycmd/cpp/ycm/ClangCompleter/UnsavedFile.h delete mode 100644 third_party/ycmd/cpp/ycm/CustomAssert.cpp delete mode 100644 third_party/ycmd/cpp/ycm/CustomAssert.h delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierCompleter.cpp delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierCompleter.h delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierDatabase.cpp delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierDatabase.h delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierUtils.cpp delete mode 100644 third_party/ycmd/cpp/ycm/IdentifierUtils.h delete mode 100644 third_party/ycmd/cpp/ycm/LetterNode.cpp delete mode 100644 third_party/ycmd/cpp/ycm/LetterNode.h delete mode 100644 third_party/ycmd/cpp/ycm/LetterNodeListMap.cpp delete mode 100644 third_party/ycmd/cpp/ycm/LetterNodeListMap.h delete mode 100644 third_party/ycmd/cpp/ycm/PythonSupport.cpp delete mode 100644 third_party/ycmd/cpp/ycm/PythonSupport.h delete mode 100644 third_party/ycmd/cpp/ycm/ReleaseGil.h delete mode 100644 third_party/ycmd/cpp/ycm/Result.cpp delete mode 100644 third_party/ycmd/cpp/ycm/Result.h delete mode 100644 third_party/ycmd/cpp/ycm/Utils.cpp delete mode 100644 third_party/ycmd/cpp/ycm/Utils.h delete mode 100644 third_party/ycmd/cpp/ycm/exceptions.h delete mode 100644 third_party/ycmd/cpp/ycm/standard.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/ycm/tests/CandidateRepository_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/Candidate_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/ClangCompleter/ClangCompleter_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/ClangCompleter/TranslationUnit_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/IdentifierCompleter_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/IdentifierUtils_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/IndexForChar_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/IsUppercase_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/LetterBitsetFromString_test.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/TestUtils.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/TestUtils.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/CHANGES delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/CONTRIBUTORS delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/LICENSE delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/Makefile.am delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/README delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/configure.ac delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/CHANGES delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/CMakeLists.txt delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/CONTRIBUTORS delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/LICENSE delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/Makefile.am delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/README delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/cmake/internal_utils.cmake delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest.cbproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest.groupproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest_all.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest_link.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest_main.cbproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/codegear/gtest_unittest.cbproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/configure.ac delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-death-test.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-message.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-param-test.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-param-test.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-printers.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-spi.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-test-part.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest-typed-test.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest_pred_impl.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/gtest_prod.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-death-test-internal.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-filepath.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-internal.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-linked_ptr.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-param-util-generated.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-param-util-generated.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-param-util.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-port.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-string.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-tuple.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-tuple.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-type-util.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/include/gtest/internal/gtest-type-util.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/m4/acx_pthread.m4 delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/m4/gtest.m4 delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest-md.sln delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest-md.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest.sln delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_main-md.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_main.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_prod_test-md.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_prod_test.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_unittest-md.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/msvc/gtest_unittest.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/prime_tables.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample1.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample1.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample10_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample1_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample2.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample2.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample2_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample3-inl.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample3_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample4.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample4.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample4_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample5_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample6_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample7_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample8_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/samples/sample9_unittest.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/fuse_gtest_files.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/gen_gtest_pred_impl.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/gtest-config.in delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/pump.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/upload.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/scripts/upload_gtest.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-all.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-death-test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-filepath.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-internal-inl.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-port.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-printers.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-test-part.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest-typed-test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/src/gtest_main.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-death-test_ex_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-death-test_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-filepath_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-linked_ptr_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-listener_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-message_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-options_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-param-test2_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-param-test_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-param-test_test.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-port_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-printers_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-test-part_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-tuple_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-typed-test2_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-typed-test_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-typed-test_test.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest-unittest-api_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_all_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_break_on_failure_unittest.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_break_on_failure_unittest_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_catch_exceptions_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_catch_exceptions_test_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_color_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_color_test_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_env_var_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_env_var_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_environment_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_filter_unittest.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_filter_unittest_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_help_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_help_test_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_list_tests_unittest.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_list_tests_unittest_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_main_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_no_test_unittest.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_output_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_output_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_output_test_golden_lin.txt delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_pred_impl_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_prod_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_repeat_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_shuffle_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_shuffle_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_sole_header_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_stress_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_test_utils.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_throw_on_failure_ex_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_throw_on_failure_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_throw_on_failure_test_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_uninitialized_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_uninitialized_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_unittest.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_outfile1_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_outfile2_test_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_outfiles_test.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_output_unittest.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_output_unittest_.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/gtest_xml_test_utils.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/production.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/test/production.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/DebugProject.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/FrameworkTarget.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/General.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/ReleaseProject.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/StaticLibraryTarget.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Config/TestTarget.xcconfig delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Resources/Info.plist delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/Info.plist delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/WidgetFramework.xcodeproj/project.pbxproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/runtests.sh delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/widget.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/widget.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Samples/FrameworkSample/widget_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Scripts/runtests.sh delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/Scripts/versiongenerate.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/gtest/xcode/gtest.xcodeproj/project.pbxproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-actions.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-cardinalities.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-actions.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-actions.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-function-mockers.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-function-mockers.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-matchers.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-matchers.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-nice-strict.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-generated-nice-strict.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-matchers.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-more-actions.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock-spec-builders.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/gmock.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/internal/gmock-generated-internal-utils.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/internal/gmock-generated-internal-utils.h.pump delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/internal/gmock-internal-utils.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/include/gmock/internal/gmock-port.h delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2005/gmock.sln delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2005/gmock.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2005/gmock_config.vsprops delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2005/gmock_main.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2005/gmock_test.vcproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2010/gmock.sln delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2010/gmock.vcxproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2010/gmock_config.props delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2010/gmock_main.vcxproj delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/msvc/2010/gmock_test.vcxproj delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/fuse_gmock_files.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/LICENSE delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/README delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/README.cppclean delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/__init__.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/ast.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/gmock_class.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/gmock_class_test.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/keywords.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/tokenize.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/cpp/utils.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/generator/gmock_gen.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/gmock-config.in delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/gmock_doctor.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/upload.py delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/scripts/upload_gmock.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock-all.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock-cardinalities.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock-internal-utils.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock-matchers.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock-spec-builders.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/src/gmock_main.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-actions_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-cardinalities_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-generated-actions_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-generated-function-mockers_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-generated-internal-utils_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-generated-matchers_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-internal-utils_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-matchers_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-more-actions_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-nice-strict_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-port_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock-spec-builders_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_all_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_leak_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_leak_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_link2_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_link_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_link_test.h delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_output_test.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_output_test_.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_output_test_golden.txt delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_stress_test.cc delete mode 100644 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_test.cc delete mode 100755 third_party/ycmd/cpp/ycm/tests/gmock/test/gmock_test_utils.py delete mode 100644 third_party/ycmd/cpp/ycm/tests/main.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/testdata/basic.cpp delete mode 100644 third_party/ycmd/cpp/ycm/tests/testdata/basic.tags delete mode 100644 third_party/ycmd/cpp/ycm/tests/testdata/goto.cpp delete mode 100644 third_party/ycmd/cpp/ycm/versioning.cpp delete mode 100644 third_party/ycmd/cpp/ycm/versioning.h delete mode 100644 third_party/ycmd/cpp/ycm/ycm_client_support.cpp delete mode 100644 third_party/ycmd/cpp/ycm/ycm_core.cpp delete mode 100755 third_party/ycmd/run_tests.sh delete mode 100755 third_party/ycmd/style_format.sh delete mode 100755 third_party/ycmd/update_boost.sh delete mode 100644 third_party/ycmd/ycmd/__init__.py delete mode 100755 third_party/ycmd/ycmd/__main__.py delete mode 100644 third_party/ycmd/ycmd/completers/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/all/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/all/identifier_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/all/tests/identifier_completer_test.py delete mode 100644 third_party/ycmd/ycmd/completers/c/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/completer.py delete mode 100644 third_party/ycmd/ycmd/completers/completer_utils.py delete mode 100644 third_party/ycmd/ycmd/completers/completer_utils_test.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/clang_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/clang_helpers.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/flags.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/tests/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/cpp/tests/flags_test.py delete mode 100644 third_party/ycmd/ycmd/completers/cs/__init__.py delete mode 100755 third_party/ycmd/ycmd/completers/cs/cs_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/cs/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/general/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/general/filename_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/general/general_completer_store.py delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/filename_completer_test.py delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/testdata/filename_completer/include/Qt/QtGui delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/testdata/filename_completer/include/QtGui/QDialog delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/testdata/filename_completer/include/QtGui/QWidget delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/testdata/filename_completer/test.cpp delete mode 100644 third_party/ycmd/ycmd/completers/general/tests/testdata/filename_completer/test.hpp delete mode 100644 third_party/ycmd/ycmd/completers/general/ultisnips_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/general_completer.py delete mode 100644 third_party/ycmd/ycmd/completers/objc/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/objcpp/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/python/__init__.py delete mode 100644 third_party/ycmd/ycmd/completers/python/hook.py delete mode 100644 third_party/ycmd/ycmd/completers/python/jedi_completer.py delete mode 100644 third_party/ycmd/ycmd/default_settings.json delete mode 100644 third_party/ycmd/ycmd/extra_conf_store.py delete mode 100644 third_party/ycmd/ycmd/handlers.py delete mode 100644 third_party/ycmd/ycmd/hmac_plugin.py delete mode 100644 third_party/ycmd/ycmd/responses.py delete mode 100644 third_party/ycmd/ycmd/server_state.py delete mode 100644 third_party/ycmd/ycmd/server_utils.py delete mode 100644 third_party/ycmd/ycmd/tests/__init__.py delete mode 100644 third_party/ycmd/ycmd/tests/diagnostics_test.py delete mode 100644 third_party/ycmd/ycmd/tests/extra_conf_store_test.py delete mode 100644 third_party/ycmd/ycmd/tests/get_completions_test.py delete mode 100644 third_party/ycmd/ycmd/tests/misc_handlers_test.py delete mode 100644 third_party/ycmd/ycmd/tests/subcommands_test.py delete mode 100644 third_party/ycmd/ycmd/tests/test_utils.py delete mode 100644 third_party/ycmd/ycmd/tests/testdata/.ycm_extra_conf.py delete mode 100644 third_party/ycmd/ycmd/tests/testdata/basic.cpp delete mode 100644 third_party/ycmd/ycmd/tests/testdata/client_data/.ycm_extra_conf.py delete mode 100644 third_party/ycmd/ycmd/tests/testdata/client_data/main.cpp delete mode 100644 third_party/ycmd/ycmd/tests/testdata/noflags/.ycm_extra_conf.py delete mode 100644 third_party/ycmd/ycmd/tests/testdata/noflags/basic.cpp delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-named-like-folder/testy.sln delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-named-like-folder/testy/Program.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-named-like-folder/testy/Properties/AssemblyInfo.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-named-like-folder/testy/testy.csproj delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-named-like-folder/testy2.sln delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-not-named-like-folder/testy/Program.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-not-named-like-folder/testy/Properties/AssemblyInfo.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-not-named-like-folder/testy/testy.csproj delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-not-named-like-folder/testy1.sln delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy-multiple-solutions/solution-not-named-like-folder/testy2.sln delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy/Program.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy/Properties/AssemblyInfo.cs delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy/testy.csproj delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy/testy.sln delete mode 100644 third_party/ycmd/ycmd/tests/testdata/testy/testy.userprefs delete mode 100644 third_party/ycmd/ycmd/user_options_store.py delete mode 100644 third_party/ycmd/ycmd/utils.py delete mode 100644 third_party/ycmd/ycmd/watchdog_plugin.py diff --git a/third_party/ycmd/build.sh b/third_party/ycmd/build.sh deleted file mode 100755 index 4ee8c9f3..00000000 --- a/third_party/ycmd/build.sh +++ /dev/null @@ -1,183 +0,0 @@ -#!/usr/bin/env bash - -set -e - -SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" - -function command_exists { - hash "$1" 2>/dev/null ; -} - -function cmake_install { - if [[ `uname -s` == "Darwin" ]]; then - homebrew_cmake_install - else - linux_cmake_install - fi -} - -function homebrew_cmake_install { - if command_exists brew; then - brew install cmake - else - echo "Homebrew was not found installed in your system." - echo "Go to http://mxcl.github.com/homebrew/ and follow the instructions." - echo "Or install CMake somehow and retry." - exit 1 - fi -} - -function python_finder { - python_library="-DPYTHON_LIBRARY=" - python_include="-DPYTHON_INCLUDE_DIR=" - - # The CMake 'FindPythonLibs' Module does not work properly. - # So we are forced to do its job for it. - python_prefix=$(python-config --prefix | sed 's/^[ \t]*//') - if [ -f "${python_prefix}/Python" ]; then - python_library+="${python_prefix}/Python" - python_include+="${python_prefix}/Headers" - else - which_python=$(python -c 'import sys;print(sys.version)' | sed 's/^[ \t]*//') - which_python="python${which_python:0:3}" - lib_python="${python_prefix}/lib/lib${which_python}" - if [ -f "${lib_python}.a" ]; then - python_library+="${lib_python}.a" - # This check is for for CYGWIN - elif [ -f "${lib_python}.dll.a" ]; then - python_library+="${lib_python}.dll.a" - else - python_library+="${lib_python}.dylib" - fi - python_include+="${python_prefix}/include/${which_python}" - fi - - echo "${python_library} ${python_include}" -} - -function num_cores { - if command_exists nproc; then - num_cpus=$(nproc) - else - num_cpus=1 - if [[ `uname -s` == "Linux" ]]; then - num_cpus=$(grep -c ^processor /proc/cpuinfo) - else - # Works on Mac and FreeBSD - num_cpus=$(sysctl -n hw.ncpu) - fi - fi - echo $num_cpus -} - - -function install { - build_dir=`mktemp -d -t ycm_build.XXXXXX` - pushd $build_dir - - if [[ `uname -s` == "Darwin" ]]; then - cmake -G "Unix Makefiles" $(python_finder) "$@" . $SCRIPT_DIR/cpp - else - cmake -G "Unix Makefiles" "$@" . $SCRIPT_DIR/cpp - fi - - make -j $(num_cores) ycm_support_libs - popd - rm -rf $build_dir -} - -function testrun { - build_dir=`mktemp -d -t ycm_build.XXXXXX` - pushd $build_dir - - cmake -G "Unix Makefiles" "$@" . $SCRIPT_DIR/cpp - make -j $(num_cores) ycm_core_tests - cd ycm/tests - LD_LIBRARY_PATH=$SCRIPT_DIR ./ycm_core_tests - - popd - rm -rf $build_dir -} - -function linux_cmake_install { - echo "Please install CMake using your package manager and retry." - exit 1 -} - -function usage { - echo "Usage: $0 [--clang-completer [--system-libclang]] [--omnisharp-completer]" - exit 0 -} - -function check_third_party_libs { - libs_present=true - for folder in third_party/*; do - num_files_in_folder=$(find $folder -maxdepth 1 -mindepth 1 | wc -l) - if [[ $num_files_in_folder -eq 0 ]]; then - libs_present=false - fi - done - - if ! $libs_present; then - echo "Some folders in ./third_party are empty; you probably forgot to run:" - printf "\n\tgit submodule update --init --recursive\n\n" - exit 1 - fi -} - -cmake_args="" -omnisharp_completer=false -for flag in $@; do - case "$flag" in - --clang-completer) - cmake_args="-DUSE_CLANG_COMPLETER=ON" - ;; - --system-libclang) - cmake_args="$cmake_args -DUSE_SYSTEM_LIBCLANG=ON" - ;; - --omnisharp-completer) - omnisharp_completer=true - ;; - *) - usage - ;; - esac -done - -if [[ $cmake_args == *-DUSE_SYSTEM_LIBCLANG=ON* ]] && \ - [[ $cmake_args != *-DUSE_CLANG_COMPLETER=ON* ]]; then - usage -fi - -check_third_party_libs - -if ! command_exists cmake; then - echo "CMake is required to build YouCompleteMe." - cmake_install -fi - -if [ -z "$YCM_TESTRUN" ]; then - install $cmake_args $EXTRA_CMAKE_ARGS -else - testrun $cmake_args $EXTRA_CMAKE_ARGS -fi - -if $omnisharp_completer; then - buildcommand="msbuild" - if ! command_exists msbuild; then - buildcommand="msbuild.exe" - if ! command_exists msbuild.exe; then - buildcommand="xbuild" - if ! command_exists xbuild; then - echo "msbuild or xbuild is required to build Omnisharp" - exit 1 - fi - fi - fi - - build_dir=$SCRIPT_DIR"/third_party/OmniSharpServer" - - cd $build_dir - $buildcommand - cd $ycm_dir -fi diff --git a/third_party/ycmd/cpp/BoostParts/CMakeLists.txt b/third_party/ycmd/cpp/BoostParts/CMakeLists.txt deleted file mode 100644 index 6c442ff8..00000000 --- a/third_party/ycmd/cpp/BoostParts/CMakeLists.txt +++ /dev/null @@ -1,109 +0,0 @@ -# Copyright (C) 2011, 2012 Google Inc. -# -# This file is part of YouCompleteMe. -# -# YouCompleteMe is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# YouCompleteMe is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with YouCompleteMe. If not, see . - -# The interesting parts of Boost have been extracted using -# the BCP tool: -# http://www.boost.org/doc/libs/1_54_0/tools/bcp/doc/html/index.html -# -# See the top-level update_boost.sh script for details on how bcp is called to -# generate BoostParts. - -cmake_minimum_required( VERSION 2.8 ) - -project( BoostParts ) - -set( Python_ADDITIONAL_VERSIONS 2.7 2.6 ) -find_package( PythonLibs 2.6 REQUIRED ) - -if ( NOT PYTHONLIBS_VERSION_STRING VERSION_LESS "3.0.0" ) - message( FATAL_ERROR - "CMake found python3 libs instead of python2 libs. YCM works only with " - "python2.\n" ) -endif() - -file( GLOB_RECURSE SOURCES *.cpp ) - -# We need to remove all the thread cpp files and then add them on a per-platform -# basis -file( GLOB_RECURSE to_remove libs/thread/*.cpp libs/detail/*.cpp ) - -if( to_remove ) - list( REMOVE_ITEM SOURCES ${to_remove} ) -endif() - -set( COMMON_SOURCES - libs/thread/src/future.cpp - ) - -set( WIN_SOURCES - libs/thread/src/win32/thread.cpp - libs/thread/src/win32/timeconv.inl - libs/thread/src/win32/tss_dll.cpp - libs/thread/src/win32/tss_pe.cpp - ) - -set( UNIX_SOURCES - libs/thread/src/pthread/once.cpp - libs/thread/src/pthread/thread.cpp - libs/thread/src/pthread/timeconv.inl - ) - -list( APPEND SOURCES ${COMMON_SOURCES} ) - -if ( WIN32 ) - list( APPEND SOURCES ${WIN_SOURCES} ) -else() - list( APPEND SOURCES ${UNIX_SOURCES} ) -endif() - -############################################################################# - -include_directories( - SYSTEM - ${CMAKE_CURRENT_SOURCE_DIR} - ${PYTHON_INCLUDE_DIRS} - ) - -add_library( BoostParts ${SOURCES} ) - -############################################################################# - -if( CMAKE_COMPILER_IS_GNUCXX OR COMPILER_IS_CLANG ) - # No warnings. We just use Boost as is so warnings coming from it are just - # noise. - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w") -endif() - -############################################################################# - -if( NOT WIN32 ) - # Linking fails without this on some platforms, notably anything x64. - set_target_properties( BoostParts PROPERTIES COMPILE_FLAGS "-fPIC") -endif() - -############################################################################# - -# Special compiler and linker flags for MSVC -if( MSVC ) - set( CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Oi /GL" ) - set_target_properties( ${PROJECT_NAME} PROPERTIES STATIC_LIBRARY_FLAGS "/LTCG" ) -endif() - -if( SYSTEM_IS_SUNOS ) - # SunOS needs this setting for thread support - set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pthreads" ) -endif() diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/cxx11/any_of.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/cxx11/any_of.hpp deleted file mode 100644 index c3ab3ce5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/cxx11/any_of.hpp +++ /dev/null @@ -1,90 +0,0 @@ -/* - Copyright (c) Marshall Clow 2008-2012. - - Distributed under the Boost Software License, Version 1.0. (See accompanying - file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - For more information, see http://www.boost.org -*/ - -/// \file -/// \brief Test ranges to see if any elements match a value or predicate. -/// \author Marshall Clow - -#ifndef BOOST_ALGORITHM_ANY_OF_HPP -#define BOOST_ALGORITHM_ANY_OF_HPP - -#include // for std::any_of, if available -#include -#include - -namespace boost { namespace algorithm { - -// Use the C++11 versions of any_of if it is available -#if __cplusplus >= 201103L -using std::any_of; // Section 25.2.2 -#else -/// \fn any_of ( InputIterator first, InputIterator last, Predicate p ) -/// \return true if any of the elements in [first, last) satisfy the predicate -/// \note returns false on an empty range -/// -/// \param first The start of the input sequence -/// \param last One past the end of the input sequence -/// \param p A predicate for testing the elements of the sequence -/// -template -bool any_of ( InputIterator first, InputIterator last, Predicate p ) -{ - for ( ; first != last; ++first ) - if ( p(*first)) - return true; - return false; -} -#endif - -/// \fn any_of ( const Range &r, Predicate p ) -/// \return true if any elements in the range satisfy the predicate 'p' -/// \note returns false on an empty range -/// -/// \param r The input range -/// \param p A predicate for testing the elements of the range -/// -template -bool any_of ( const Range &r, Predicate p ) -{ - return boost::algorithm::any_of (boost::begin (r), boost::end (r), p); -} - -/// \fn any_of_equal ( InputIterator first, InputIterator last, const V &val ) -/// \return true if any of the elements in [first, last) are equal to 'val' -/// \note returns false on an empty range -/// -/// \param first The start of the input sequence -/// \param last One past the end of the input sequence -/// \param val A value to compare against -/// -template -bool any_of_equal ( InputIterator first, InputIterator last, const V &val ) -{ - for ( ; first != last; ++first ) - if ( val == *first ) - return true; - return false; -} - -/// \fn any_of_equal ( const Range &r, const V &val ) -/// \return true if any of the elements in the range are equal to 'val' -/// \note returns false on an empty range -/// -/// \param r The input range -/// \param val A value to compare against -/// -template -bool any_of_equal ( const Range &r, const V &val ) -{ - return boost::algorithm::any_of_equal (boost::begin (r), boost::end (r), val); -} - -}} // namespace boost and algorithm - -#endif // BOOST_ALGORITHM_ANY_OF_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string.hpp deleted file mode 100644 index 07715173..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// Boost string_algo library string_algo.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_ALGO_HPP -#define BOOST_STRING_ALGO_HPP - -/*! \file - Cumulative include for string_algo library -*/ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -#endif // BOOST_STRING_ALGO_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/case_conv.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/case_conv.hpp deleted file mode 100644 index 683340b8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/case_conv.hpp +++ /dev/null @@ -1,176 +0,0 @@ -// Boost string_algo library case_conv.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CASE_CONV_HPP -#define BOOST_STRING_CASE_CONV_HPP - -#include -#include -#include -#include - -#include -#include -#include -#include - -#include - -/*! \file - Defines sequence case-conversion algorithms. - Algorithms convert each element in the input sequence to the - desired case using provided locales. -*/ - -namespace boost { - namespace algorithm { - -// to_lower -----------------------------------------------// - - //! Convert to lower case - /*! - Each element of the input sequence is converted to lower - case. The result is a copy of the input converted to lower case. - It is returned as a sequence or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input range - \param Loc A locale used for conversion - \return - An output iterator pointing just after the last inserted character or - a copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - - */ - template - inline OutputIteratorT - to_lower_copy( - OutputIteratorT Output, - const RangeT& Input, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::detail::transform_range_copy( - Output, - ::boost::as_literal(Input), - ::boost::algorithm::detail::to_lowerF< - typename range_value::type >(Loc)); - } - - //! Convert to lower case - /*! - \overload - */ - template - inline SequenceT to_lower_copy( - const SequenceT& Input, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::detail::transform_range_copy( - Input, - ::boost::algorithm::detail::to_lowerF< - typename range_value::type >(Loc)); - } - - //! Convert to lower case - /*! - Each element of the input sequence is converted to lower - case. The input sequence is modified in-place. - - \param Input A range - \param Loc a locale used for conversion - */ - template - inline void to_lower( - WritableRangeT& Input, - const std::locale& Loc=std::locale()) - { - ::boost::algorithm::detail::transform_range( - ::boost::as_literal(Input), - ::boost::algorithm::detail::to_lowerF< - typename range_value::type >(Loc)); - } - -// to_upper -----------------------------------------------// - - //! Convert to upper case - /*! - Each element of the input sequence is converted to upper - case. The result is a copy of the input converted to upper case. - It is returned as a sequence or copied to the output iterator - - \param Output An output iterator to which the result will be copied - \param Input An input range - \param Loc A locale used for conversion - \return - An output iterator pointing just after the last inserted character or - a copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template - inline OutputIteratorT - to_upper_copy( - OutputIteratorT Output, - const RangeT& Input, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::detail::transform_range_copy( - Output, - ::boost::as_literal(Input), - ::boost::algorithm::detail::to_upperF< - typename range_value::type >(Loc)); - } - - //! Convert to upper case - /*! - \overload - */ - template - inline SequenceT to_upper_copy( - const SequenceT& Input, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::detail::transform_range_copy( - Input, - ::boost::algorithm::detail::to_upperF< - typename range_value::type >(Loc)); - } - - //! Convert to upper case - /*! - Each element of the input sequence is converted to upper - case. The input sequence is modified in-place. - - \param Input An input range - \param Loc a locale used for conversion - */ - template - inline void to_upper( - WritableRangeT& Input, - const std::locale& Loc=std::locale()) - { - ::boost::algorithm::detail::transform_range( - ::boost::as_literal(Input), - ::boost::algorithm::detail::to_upperF< - typename range_value::type >(Loc)); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::to_lower; - using algorithm::to_lower_copy; - using algorithm::to_upper; - using algorithm::to_upper_copy; - -} // namespace boost - -#endif // BOOST_STRING_CASE_CONV_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/classification.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/classification.hpp deleted file mode 100644 index ca43602d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/classification.hpp +++ /dev/null @@ -1,312 +0,0 @@ -// Boost string_algo library classification.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CLASSIFICATION_HPP -#define BOOST_STRING_CLASSIFICATION_HPP - -#include -#include -#include -#include -#include -#include - - -/*! \file - Classification predicates are included in the library to give - some more convenience when using algorithms like \c trim() and \c all(). - They wrap functionality of STL classification functions ( e.g. \c std::isspace() ) - into generic functors. -*/ - -namespace boost { - namespace algorithm { - -// classification functor generator -------------------------------------// - - //! is_classified predicate - /*! - Construct the \c is_classified predicate. This predicate holds if the input is - of specified \c std::ctype category. - - \param Type A \c std::ctype category - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_classified(std::ctype_base::mask Type, const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(Type, Loc); - } - - //! is_space predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::space category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_space(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::space, Loc); - } - - //! is_alnum predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::alnum category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_alnum(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::alnum, Loc); - } - - //! is_alpha predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::alpha category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_alpha(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::alpha, Loc); - } - - //! is_cntrl predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::cntrl category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_cntrl(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::cntrl, Loc); - } - - //! is_digit predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::digit category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_digit(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::digit, Loc); - } - - //! is_graph predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::graph category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_graph(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::graph, Loc); - } - - //! is_lower predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::lower category. - - \param Loc A locale used for classification - \return An instance of \c is_classified predicate - */ - inline detail::is_classifiedF - is_lower(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::lower, Loc); - } - - //! is_print predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::print category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_print(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::print, Loc); - } - - //! is_punct predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::punct category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_punct(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::punct, Loc); - } - - //! is_upper predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::upper category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_upper(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::upper, Loc); - } - - //! is_xdigit predicate - /*! - Construct the \c is_classified predicate for the \c ctype_base::xdigit category. - - \param Loc A locale used for classification - \return An instance of the \c is_classified predicate - */ - inline detail::is_classifiedF - is_xdigit(const std::locale& Loc=std::locale()) - { - return detail::is_classifiedF(std::ctype_base::xdigit, Loc); - } - - //! is_any_of predicate - /*! - Construct the \c is_any_of predicate. The predicate holds if the input - is included in the specified set of characters. - - \param Set A set of characters to be recognized - \return An instance of the \c is_any_of predicate - */ - template - inline detail::is_any_ofF< - BOOST_STRING_TYPENAME range_value::type> - is_any_of( const RangeT& Set ) - { - iterator_range::type> lit_set(boost::as_literal(Set)); - return detail::is_any_ofF::type>(lit_set); - } - - //! is_from_range predicate - /*! - Construct the \c is_from_range predicate. The predicate holds if the input - is included in the specified range. (i.e. From <= Ch <= To ) - - \param From The start of the range - \param To The end of the range - \return An instance of the \c is_from_range predicate - */ - template - inline detail::is_from_rangeF is_from_range(CharT From, CharT To) - { - return detail::is_from_rangeF(From,To); - } - - // predicate combinators ---------------------------------------------------// - - //! predicate 'and' composition predicate - /*! - Construct the \c class_and predicate. This predicate can be used - to logically combine two classification predicates. \c class_and holds, - if both predicates return true. - - \param Pred1 The first predicate - \param Pred2 The second predicate - \return An instance of the \c class_and predicate - */ - template - inline detail::pred_andF - operator&&( - const predicate_facade& Pred1, - const predicate_facade& Pred2 ) - { - // Doing the static_cast with the pointer instead of the reference - // is a workaround for some compilers which have problems with - // static_cast's of template references, i.e. CW8. /grafik/ - return detail::pred_andF( - *static_cast(&Pred1), - *static_cast(&Pred2) ); - } - - //! predicate 'or' composition predicate - /*! - Construct the \c class_or predicate. This predicate can be used - to logically combine two classification predicates. \c class_or holds, - if one of the predicates return true. - - \param Pred1 The first predicate - \param Pred2 The second predicate - \return An instance of the \c class_or predicate - */ - template - inline detail::pred_orF - operator||( - const predicate_facade& Pred1, - const predicate_facade& Pred2 ) - { - // Doing the static_cast with the pointer instead of the reference - // is a workaround for some compilers which have problems with - // static_cast's of template references, i.e. CW8. /grafik/ - return detail::pred_orF( - *static_cast(&Pred1), - *static_cast(&Pred2)); - } - - //! predicate negation operator - /*! - Construct the \c class_not predicate. This predicate represents a negation. - \c class_or holds if of the predicates return false. - - \param Pred The predicate to be negated - \return An instance of the \c class_not predicate - */ - template - inline detail::pred_notF - operator!( const predicate_facade& Pred ) - { - // Doing the static_cast with the pointer instead of the reference - // is a workaround for some compilers which have problems with - // static_cast's of template references, i.e. CW8. /grafik/ - return detail::pred_notF(*static_cast(&Pred)); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::is_classified; - using algorithm::is_space; - using algorithm::is_alnum; - using algorithm::is_alpha; - using algorithm::is_cntrl; - using algorithm::is_digit; - using algorithm::is_graph; - using algorithm::is_lower; - using algorithm::is_upper; - using algorithm::is_print; - using algorithm::is_punct; - using algorithm::is_xdigit; - using algorithm::is_any_of; - using algorithm::is_from_range; - -} // namespace boost - -#endif // BOOST_STRING_PREDICATE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/compare.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/compare.hpp deleted file mode 100644 index 734303a9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/compare.hpp +++ /dev/null @@ -1,199 +0,0 @@ -// Boost string_algo library compare.hpp header file -------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_COMPARE_HPP -#define BOOST_STRING_COMPARE_HPP - -#include -#include - -/*! \file - Defines element comparison predicates. Many algorithms in this library can - take an additional argument with a predicate used to compare elements. - This makes it possible, for instance, to have case insensitive versions - of the algorithms. -*/ - -namespace boost { - namespace algorithm { - - // is_equal functor -----------------------------------------------// - - //! is_equal functor - /*! - Standard STL equal_to only handle comparison between arguments - of the same type. This is a less restrictive version which wraps operator ==. - */ - struct is_equal - { - //! Function operator - /*! - Compare two operands for equality - */ - template< typename T1, typename T2 > - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - return Arg1==Arg2; - } - }; - - //! case insensitive version of is_equal - /*! - Case insensitive comparison predicate. Comparison is done using - specified locales. - */ - struct is_iequal - { - //! Constructor - /*! - \param Loc locales used for comparison - */ - is_iequal( const std::locale& Loc=std::locale() ) : - m_Loc( Loc ) {} - - //! Function operator - /*! - Compare two operands. Case is ignored. - */ - template< typename T1, typename T2 > - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x564) && !defined(_USE_OLD_RW_STL) - return std::toupper(Arg1)==std::toupper(Arg2); - #else - return std::toupper(Arg1,m_Loc)==std::toupper(Arg2,m_Loc); - #endif - } - - private: - std::locale m_Loc; - }; - - // is_less functor -----------------------------------------------// - - //! is_less functor - /*! - Convenient version of standard std::less. Operation is templated, therefore it is - not required to specify the exact types upon the construction - */ - struct is_less - { - //! Functor operation - /*! - Compare two operands using > operator - */ - template< typename T1, typename T2 > - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - return Arg1 - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x564) && !defined(_USE_OLD_RW_STL) - return std::toupper(Arg1)(Arg1,m_Loc)(Arg2,m_Loc); - #endif - } - - private: - std::locale m_Loc; - }; - - // is_not_greater functor -----------------------------------------------// - - //! is_not_greater functor - /*! - Convenient version of standard std::not_greater_to. Operation is templated, therefore it is - not required to specify the exact types upon the construction - */ - struct is_not_greater - { - //! Functor operation - /*! - Compare two operands using > operator - */ - template< typename T1, typename T2 > - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - return Arg1<=Arg2; - } - }; - - - //! case insensitive version of is_not_greater - /*! - Case insensitive comparison predicate. Comparison is done using - specified locales. - */ - struct is_not_igreater - { - //! Constructor - /*! - \param Loc locales used for comparison - */ - is_not_igreater( const std::locale& Loc=std::locale() ) : - m_Loc( Loc ) {} - - //! Function operator - /*! - Compare two operands. Case is ignored. - */ - template< typename T1, typename T2 > - bool operator()( const T1& Arg1, const T2& Arg2 ) const - { - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x564) && !defined(_USE_OLD_RW_STL) - return std::toupper(Arg1)<=std::toupper(Arg2); - #else - return std::toupper(Arg1,m_Loc)<=std::toupper(Arg2,m_Loc); - #endif - } - - private: - std::locale m_Loc; - }; - - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::is_equal; - using algorithm::is_iequal; - using algorithm::is_less; - using algorithm::is_iless; - using algorithm::is_not_greater; - using algorithm::is_not_igreater; - -} // namespace boost - - -#endif // BOOST_STRING_COMPARE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/concept.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/concept.hpp deleted file mode 100644 index 17e83495..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/concept.hpp +++ /dev/null @@ -1,83 +0,0 @@ -// Boost string_algo library concept.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CONCEPT_HPP -#define BOOST_STRING_CONCEPT_HPP - -#include -#include -#include -#include - -/*! \file - Defines concepts used in string_algo library -*/ - -namespace boost { - namespace algorithm { - - //! Finder concept - /*! - Defines the Finder concept. Finder is a functor which selects - an arbitrary part of a string. Search is performed on - the range specified by starting and ending iterators. - - Result of the find operation must be convertible to iterator_range. - */ - template - struct FinderConcept - { - private: - typedef iterator_range range; - public: - void constraints() - { - // Operation - r=(*pF)(i,i); - } - private: - range r; - IteratorT i; - FinderT* pF; - }; // Finder_concept - - - //! Formatter concept - /*! - Defines the Formatter concept. Formatter is a functor, which - takes a result from a finder operation and transforms it - in a specific way. - - Result must be a container supported by container_traits, - or a reference to it. - */ - template - struct FormatterConcept - { - public: - void constraints() - { - // Operation - ::boost::begin((*pFo)( (*pF)(i,i) )); - ::boost::end((*pFo)( (*pF)(i,i) )); - } - private: - IteratorT i; - FinderT* pF; - FormatterT *pFo; - }; // FormatterConcept; - - } // namespace algorithm -} // namespace boost - - - - -#endif // BOOST_STRING_CONCEPT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/config.hpp deleted file mode 100644 index 559750ac..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/config.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// Boost string_algo library config.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CONFIG_HPP -#define BOOST_STRING_CONFIG_HPP - -#include -#include - -#ifdef BOOST_STRING_DEDUCED_TYPENAME -# error "macro already defined!" -#endif - -#define BOOST_STRING_TYPENAME BOOST_DEDUCED_TYPENAME - -// Metrowerks workaround -#if BOOST_WORKAROUND(__MWERKS__, <= 0x3003) // 8.x -#pragma parse_func_templ off -#endif - -#endif // BOOST_STRING_CONFIG_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/constants.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/constants.hpp deleted file mode 100644 index 6ed70eff..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/constants.hpp +++ /dev/null @@ -1,36 +0,0 @@ -// Boost string_algo library constants.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CONSTANTS_HPP -#define BOOST_STRING_CONSTANTS_HPP - -namespace boost { - namespace algorithm { - - //! Token compression mode - /*! - Specifies token compression mode for the token_finder. - */ - enum token_compress_mode_type - { - token_compress_on, //!< Compress adjacent tokens - token_compress_off //!< Do not compress adjacent tokens - }; - - } // namespace algorithm - - // pull the names to the boost namespace - using algorithm::token_compress_on; - using algorithm::token_compress_off; - -} // namespace boost - -#endif // BOOST_STRING_CONSTANTS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/case_conv.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/case_conv.hpp deleted file mode 100644 index 42621c74..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/case_conv.hpp +++ /dev/null @@ -1,123 +0,0 @@ -// Boost string_algo library string_funct.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CASE_CONV_DETAIL_HPP -#define BOOST_STRING_CASE_CONV_DETAIL_HPP - -#include -#include -#include - -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// case conversion functors -----------------------------------------------// - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -#pragma warning(push) -#pragma warning(disable:4512) //assignment operator could not be generated -#endif - - // a tolower functor - template - struct to_lowerF : public std::unary_function - { - // Constructor - to_lowerF( const std::locale& Loc ) : m_Loc( &Loc ) {} - - // Operation - CharT operator ()( CharT Ch ) const - { - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x564) && !defined(_USE_OLD_RW_STL) - return std::tolower( static_cast::type> ( Ch )); - #else - return std::tolower( Ch, *m_Loc ); - #endif - } - private: - const std::locale* m_Loc; - }; - - // a toupper functor - template - struct to_upperF : public std::unary_function - { - // Constructor - to_upperF( const std::locale& Loc ) : m_Loc( &Loc ) {} - - // Operation - CharT operator ()( CharT Ch ) const - { - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x564) && !defined(_USE_OLD_RW_STL) - return std::toupper( static_cast::type> ( Ch )); - #else - return std::toupper( Ch, *m_Loc ); - #endif - } - private: - const std::locale* m_Loc; - }; - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -#pragma warning(pop) -#endif - -// algorithm implementation ------------------------------------------------------------------------- - - // Transform a range - template - OutputIteratorT transform_range_copy( - OutputIteratorT Output, - const RangeT& Input, - FunctorT Functor) - { - return std::transform( - ::boost::begin(Input), - ::boost::end(Input), - Output, - Functor); - } - - // Transform a range (in-place) - template - void transform_range( - const RangeT& Input, - FunctorT Functor) - { - std::transform( - ::boost::begin(Input), - ::boost::end(Input), - ::boost::begin(Input), - Functor); - } - - template - inline SequenceT transform_range_copy( - const RangeT& Input, - FunctorT Functor) - { - return SequenceT( - ::boost::make_transform_iterator( - ::boost::begin(Input), - Functor), - ::boost::make_transform_iterator( - ::boost::end(Input), - Functor)); - } - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_CASE_CONV_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/classification.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/classification.hpp deleted file mode 100644 index 704d9d20..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/classification.hpp +++ /dev/null @@ -1,353 +0,0 @@ -// Boost string_algo library classification.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_CLASSIFICATION_DETAIL_HPP -#define BOOST_STRING_CLASSIFICATION_DETAIL_HPP - -#include -#include -#include -#include - -#include -#include - -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// classification functors -----------------------------------------------// - - // is_classified functor - struct is_classifiedF : - public predicate_facade - { - // Boost.ResultOf support - typedef bool result_type; - - // Constructor from a locale - is_classifiedF(std::ctype_base::mask Type, std::locale const & Loc = std::locale()) : - m_Type(Type), m_Locale(Loc) {} - // Operation - template - bool operator()( CharT Ch ) const - { - return std::use_facet< std::ctype >(m_Locale).is( m_Type, Ch ); - } - - #if defined(__BORLANDC__) && (__BORLANDC__ >= 0x560) && (__BORLANDC__ <= 0x582) && !defined(_USE_OLD_RW_STL) - template<> - bool operator()( char const Ch ) const - { - return std::use_facet< std::ctype >(m_Locale).is( m_Type, Ch ); - } - #endif - - private: - std::ctype_base::mask m_Type; - std::locale m_Locale; - }; - - - // is_any_of functor - /* - returns true if the value is from the specified set - */ - template - struct is_any_ofF : - public predicate_facade > - { - private: - // set cannot operate on const value-type - typedef typename ::boost::remove_const::type set_value_type; - - public: - // Boost.ResultOf support - typedef bool result_type; - - // Constructor - template - is_any_ofF( const RangeT& Range ) : m_Size(0) - { - // Prepare storage - m_Storage.m_dynSet=0; - - std::size_t Size=::boost::distance(Range); - m_Size=Size; - set_value_type* Storage=0; - - if(use_fixed_storage(m_Size)) - { - // Use fixed storage - Storage=&m_Storage.m_fixSet[0]; - } - else - { - // Use dynamic storage - m_Storage.m_dynSet=new set_value_type[m_Size]; - Storage=m_Storage.m_dynSet; - } - - // Use fixed storage - ::std::copy(::boost::begin(Range), ::boost::end(Range), Storage); - ::std::sort(Storage, Storage+m_Size); - } - - // Copy constructor - is_any_ofF(const is_any_ofF& Other) : m_Size(Other.m_Size) - { - // Prepare storage - m_Storage.m_dynSet=0; - const set_value_type* SrcStorage=0; - set_value_type* DestStorage=0; - - if(use_fixed_storage(m_Size)) - { - // Use fixed storage - DestStorage=&m_Storage.m_fixSet[0]; - SrcStorage=&Other.m_Storage.m_fixSet[0]; - } - else - { - // Use dynamic storage - m_Storage.m_dynSet=new set_value_type[m_Size]; - DestStorage=m_Storage.m_dynSet; - SrcStorage=Other.m_Storage.m_dynSet; - } - - // Use fixed storage - ::std::memcpy(DestStorage, SrcStorage, sizeof(set_value_type)*m_Size); - } - - // Destructor - ~is_any_ofF() - { - if(!use_fixed_storage(m_Size) && m_Storage.m_dynSet!=0) - { - delete [] m_Storage.m_dynSet; - } - } - - // Assignment - is_any_ofF& operator=(const is_any_ofF& Other) - { - // Handle self assignment - if(this==&Other) return *this; - - // Prepare storage - const set_value_type* SrcStorage; - set_value_type* DestStorage; - - if(use_fixed_storage(Other.m_Size)) - { - // Use fixed storage - DestStorage=&m_Storage.m_fixSet[0]; - SrcStorage=&Other.m_Storage.m_fixSet[0]; - - // Delete old storage if was present - if(!use_fixed_storage(m_Size) && m_Storage.m_dynSet!=0) - { - delete [] m_Storage.m_dynSet; - } - - // Set new size - m_Size=Other.m_Size; - } - else - { - // Other uses dynamic storage - SrcStorage=Other.m_Storage.m_dynSet; - - // Check what kind of storage are we using right now - if(use_fixed_storage(m_Size)) - { - // Using fixed storage, allocate new - set_value_type* pTemp=new set_value_type[Other.m_Size]; - DestStorage=pTemp; - m_Storage.m_dynSet=pTemp; - m_Size=Other.m_Size; - } - else - { - // Using dynamic storage, check if can reuse - if(m_Storage.m_dynSet!=0 && m_Size>=Other.m_Size && m_Size - bool operator()( Char2T Ch ) const - { - const set_value_type* Storage= - (use_fixed_storage(m_Size)) - ? &m_Storage.m_fixSet[0] - : m_Storage.m_dynSet; - - return ::std::binary_search(Storage, Storage+m_Size, Ch); - } - private: - // check if the size is eligible for fixed storage - static bool use_fixed_storage(std::size_t size) - { - return size<=sizeof(set_value_type*)*2; - } - - - private: - // storage - // The actual used storage is selected on the type - union - { - set_value_type* m_dynSet; - set_value_type m_fixSet[sizeof(set_value_type*)*2]; - } - m_Storage; - - // storage size - ::std::size_t m_Size; - }; - - // is_from_range functor - /* - returns true if the value is from the specified range. - (i.e. x>=From && x>=To) - */ - template - struct is_from_rangeF : - public predicate_facade< is_from_rangeF > - { - // Boost.ResultOf support - typedef bool result_type; - - // Constructor - is_from_rangeF( CharT From, CharT To ) : m_From(From), m_To(To) {} - - // Operation - template - bool operator()( Char2T Ch ) const - { - return ( m_From <= Ch ) && ( Ch <= m_To ); - } - - private: - CharT m_From; - CharT m_To; - }; - - // class_and composition predicate - template - struct pred_andF : - public predicate_facade< pred_andF > - { - public: - - // Boost.ResultOf support - typedef bool result_type; - - // Constructor - pred_andF( Pred1T Pred1, Pred2T Pred2 ) : - m_Pred1(Pred1), m_Pred2(Pred2) {} - - // Operation - template - bool operator()( CharT Ch ) const - { - return m_Pred1(Ch) && m_Pred2(Ch); - } - - private: - Pred1T m_Pred1; - Pred2T m_Pred2; - }; - - // class_or composition predicate - template - struct pred_orF : - public predicate_facade< pred_orF > - { - public: - // Boost.ResultOf support - typedef bool result_type; - - // Constructor - pred_orF( Pred1T Pred1, Pred2T Pred2 ) : - m_Pred1(Pred1), m_Pred2(Pred2) {} - - // Operation - template - bool operator()( CharT Ch ) const - { - return m_Pred1(Ch) || m_Pred2(Ch); - } - - private: - Pred1T m_Pred1; - Pred2T m_Pred2; - }; - - // class_not composition predicate - template< typename PredT > - struct pred_notF : - public predicate_facade< pred_notF > - { - public: - // Boost.ResultOf support - typedef bool result_type; - - // Constructor - pred_notF( PredT Pred ) : m_Pred(Pred) {} - - // Operation - template - bool operator()( CharT Ch ) const - { - return !m_Pred(Ch); - } - - private: - PredT m_Pred; - }; - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_CLASSIFICATION_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format.hpp deleted file mode 100644 index b3987502..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format.hpp +++ /dev/null @@ -1,204 +0,0 @@ -// Boost string_algo library find_format.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_FORMAT_DETAIL_HPP -#define BOOST_STRING_FIND_FORMAT_DETAIL_HPP - -#include -#include -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// find_format_copy (iterator variant) implementation -------------------------------// - - template< - typename OutputIteratorT, - typename InputT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline OutputIteratorT find_format_copy_impl2( - OutputIteratorT Output, - const InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult, - const FormatResultT& FormatResult ) - { - typedef find_format_store< - BOOST_STRING_TYPENAME - range_const_iterator::type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - if ( !M ) - { - // Match not found - return original sequence - Output = std::copy( ::boost::begin(Input), ::boost::end(Input), Output ); - return Output; - } - - // Copy the beginning of the sequence - Output = std::copy( ::boost::begin(Input), ::boost::begin(M), Output ); - // Format find result - // Copy formatted result - Output = std::copy( ::boost::begin(M.format_result()), ::boost::end(M.format_result()), Output ); - // Copy the rest of the sequence - Output = std::copy( M.end(), ::boost::end(Input), Output ); - - return Output; - } - - template< - typename OutputIteratorT, - typename InputT, - typename FormatterT, - typename FindResultT > - inline OutputIteratorT find_format_copy_impl( - OutputIteratorT Output, - const InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult ) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - return ::boost::algorithm::detail::find_format_copy_impl2( - Output, - Input, - Formatter, - FindResult, - Formatter(FindResult) ); - } else { - return std::copy( ::boost::begin(Input), ::boost::end(Input), Output ); - } - } - - -// find_format_copy implementation --------------------------------------------------// - - template< - typename InputT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline InputT find_format_copy_impl2( - const InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult, - const FormatResultT& FormatResult) - { - typedef find_format_store< - BOOST_STRING_TYPENAME - range_const_iterator::type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - if ( !M ) - { - // Match not found - return original sequence - return InputT( Input ); - } - - InputT Output; - // Copy the beginning of the sequence - boost::algorithm::detail::insert( Output, ::boost::end(Output), ::boost::begin(Input), M.begin() ); - // Copy formatted result - boost::algorithm::detail::insert( Output, ::boost::end(Output), M.format_result() ); - // Copy the rest of the sequence - boost::algorithm::detail::insert( Output, ::boost::end(Output), M.end(), ::boost::end(Input) ); - - return Output; - } - - template< - typename InputT, - typename FormatterT, - typename FindResultT > - inline InputT find_format_copy_impl( - const InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - return ::boost::algorithm::detail::find_format_copy_impl2( - Input, - Formatter, - FindResult, - Formatter(FindResult) ); - } else { - return Input; - } - } - - // replace implementation ----------------------------------------------------// - - template< - typename InputT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline void find_format_impl2( - InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult, - const FormatResultT& FormatResult) - { - typedef find_format_store< - BOOST_STRING_TYPENAME - range_iterator::type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - if ( !M ) - { - // Search not found - return original sequence - return; - } - - // Replace match - ::boost::algorithm::detail::replace( Input, M.begin(), M.end(), M.format_result() ); - } - - template< - typename InputT, - typename FormatterT, - typename FindResultT > - inline void find_format_impl( - InputT& Input, - FormatterT Formatter, - const FindResultT& FindResult) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - ::boost::algorithm::detail::find_format_impl2( - Input, - Formatter, - FindResult, - Formatter(FindResult) ); - } - } - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FIND_FORMAT_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_all.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_all.hpp deleted file mode 100644 index 52930c83..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_all.hpp +++ /dev/null @@ -1,273 +0,0 @@ -// Boost string_algo library find_format_all.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_FORMAT_ALL_DETAIL_HPP -#define BOOST_STRING_FIND_FORMAT_ALL_DETAIL_HPP - -#include -#include -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// find_format_all_copy (iterator variant) implementation ---------------------------// - - template< - typename OutputIteratorT, - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline OutputIteratorT find_format_all_copy_impl2( - OutputIteratorT Output, - const InputT& Input, - FinderT Finder, - FormatterT Formatter, - const FindResultT& FindResult, - const FormatResultT& FormatResult ) - { - typedef BOOST_STRING_TYPENAME - range_const_iterator::type input_iterator_type; - - typedef find_format_store< - input_iterator_type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - // Initialize last match - input_iterator_type LastMatch=::boost::begin(Input); - - // Iterate through all matches - while( M ) - { - // Copy the beginning of the sequence - Output = std::copy( LastMatch, M.begin(), Output ); - // Copy formatted result - Output = std::copy( ::boost::begin(M.format_result()), ::boost::end(M.format_result()), Output ); - - // Proceed to the next match - LastMatch=M.end(); - M=Finder( LastMatch, ::boost::end(Input) ); - } - - // Copy the rest of the sequence - Output = std::copy( LastMatch, ::boost::end(Input), Output ); - - return Output; - } - - template< - typename OutputIteratorT, - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT > - inline OutputIteratorT find_format_all_copy_impl( - OutputIteratorT Output, - const InputT& Input, - FinderT Finder, - FormatterT Formatter, - const FindResultT& FindResult ) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - return ::boost::algorithm::detail::find_format_all_copy_impl2( - Output, - Input, - Finder, - Formatter, - FindResult, - Formatter(FindResult) ); - } else { - return std::copy( ::boost::begin(Input), ::boost::end(Input), Output ); - } - } - - // find_format_all_copy implementation ----------------------------------------------// - - template< - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline InputT find_format_all_copy_impl2( - const InputT& Input, - FinderT Finder, - FormatterT Formatter, - const FindResultT& FindResult, - const FormatResultT& FormatResult) - { - typedef BOOST_STRING_TYPENAME - range_const_iterator::type input_iterator_type; - - typedef find_format_store< - input_iterator_type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - // Initialize last match - input_iterator_type LastMatch=::boost::begin(Input); - - // Output temporary - InputT Output; - - // Iterate through all matches - while( M ) - { - // Copy the beginning of the sequence - boost::algorithm::detail::insert( Output, ::boost::end(Output), LastMatch, M.begin() ); - // Copy formatted result - boost::algorithm::detail::insert( Output, ::boost::end(Output), M.format_result() ); - - // Proceed to the next match - LastMatch=M.end(); - M=Finder( LastMatch, ::boost::end(Input) ); - } - - // Copy the rest of the sequence - ::boost::algorithm::detail::insert( Output, ::boost::end(Output), LastMatch, ::boost::end(Input) ); - - return Output; - } - - template< - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT > - inline InputT find_format_all_copy_impl( - const InputT& Input, - FinderT Finder, - FormatterT Formatter, - const FindResultT& FindResult) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - return ::boost::algorithm::detail::find_format_all_copy_impl2( - Input, - Finder, - Formatter, - FindResult, - Formatter(FindResult) ); - } else { - return Input; - } - } - - // find_format_all implementation ------------------------------------------------// - - template< - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT, - typename FormatResultT > - inline void find_format_all_impl2( - InputT& Input, - FinderT Finder, - FormatterT Formatter, - FindResultT FindResult, - FormatResultT FormatResult) - { - typedef BOOST_STRING_TYPENAME - range_iterator::type input_iterator_type; - typedef find_format_store< - input_iterator_type, - FormatterT, - FormatResultT > store_type; - - // Create store for the find result - store_type M( FindResult, FormatResult, Formatter ); - - // Instantiate replacement storage - std::deque< - BOOST_STRING_TYPENAME range_value::type> Storage; - - // Initialize replacement iterators - input_iterator_type InsertIt=::boost::begin(Input); - input_iterator_type SearchIt=::boost::begin(Input); - - while( M ) - { - // process the segment - InsertIt=process_segment( - Storage, - Input, - InsertIt, - SearchIt, - M.begin() ); - - // Adjust search iterator - SearchIt=M.end(); - - // Copy formatted replace to the storage - ::boost::algorithm::detail::copy_to_storage( Storage, M.format_result() ); - - // Find range for a next match - M=Finder( SearchIt, ::boost::end(Input) ); - } - - // process the last segment - InsertIt=::boost::algorithm::detail::process_segment( - Storage, - Input, - InsertIt, - SearchIt, - ::boost::end(Input) ); - - if ( Storage.empty() ) - { - // Truncate input - ::boost::algorithm::detail::erase( Input, InsertIt, ::boost::end(Input) ); - } - else - { - // Copy remaining data to the end of input - ::boost::algorithm::detail::insert( Input, ::boost::end(Input), Storage.begin(), Storage.end() ); - } - } - - template< - typename InputT, - typename FinderT, - typename FormatterT, - typename FindResultT > - inline void find_format_all_impl( - InputT& Input, - FinderT Finder, - FormatterT Formatter, - FindResultT FindResult) - { - if( ::boost::algorithm::detail::check_find_result(Input, FindResult) ) { - ::boost::algorithm::detail::find_format_all_impl2( - Input, - Finder, - Formatter, - FindResult, - Formatter(FindResult) ); - } - } - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FIND_FORMAT_ALL_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_store.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_store.hpp deleted file mode 100644 index b9f4a88d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_format_store.hpp +++ /dev/null @@ -1,89 +0,0 @@ -// Boost string_algo library find_format_store.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_FORMAT_STORE_DETAIL_HPP -#define BOOST_STRING_FIND_FORMAT_STORE_DETAIL_HPP - -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// temporary format and find result storage --------------------------------// - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -#pragma warning(push) -#pragma warning(disable:4512) //assignment operator could not be generated -#endif - template< - typename ForwardIteratorT, - typename FormatterT, - typename FormatResultT > - class find_format_store : - public iterator_range - { - public: - // typedefs - typedef iterator_range base_type; - typedef FormatterT formatter_type; - typedef FormatResultT format_result_type; - - public: - // Construction - find_format_store( - const base_type& FindResult, - const format_result_type& FormatResult, - const formatter_type& Formatter ) : - base_type(FindResult), - m_FormatResult(FormatResult), - m_Formatter(Formatter) {} - - // Assignment - template< typename FindResultT > - find_format_store& operator=( FindResultT FindResult ) - { - iterator_range::operator=(FindResult); - if( !this->empty() ) { - m_FormatResult=m_Formatter(FindResult); - } - - return *this; - } - - // Retrieve format result - const format_result_type& format_result() - { - return m_FormatResult; - } - - private: - format_result_type m_FormatResult; - const formatter_type& m_Formatter; - }; - - template - bool check_find_result(InputT&, FindResultT& FindResult) - { - typedef BOOST_STRING_TYPENAME - range_const_iterator::type input_iterator_type; - iterator_range ResultRange(FindResult); - return !ResultRange.empty(); - } - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -#pragma warning(pop) -#endif - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FIND_FORMAT_STORE_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_iterator.hpp deleted file mode 100644 index 9b78a0f7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/find_iterator.hpp +++ /dev/null @@ -1,87 +0,0 @@ -// Boost string_algo library find_iterator.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_ITERATOR_DETAIL_HPP -#define BOOST_STRING_FIND_ITERATOR_DETAIL_HPP - -#include -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// find_iterator base -----------------------------------------------// - - // Find iterator base - template - class find_iterator_base - { - protected: - // typedefs - typedef IteratorT input_iterator_type; - typedef iterator_range match_type; - typedef function2< - match_type, - input_iterator_type, - input_iterator_type> finder_type; - - protected: - // Protected construction/destruction - - // Default constructor - find_iterator_base() {}; - // Copy construction - find_iterator_base( const find_iterator_base& Other ) : - m_Finder(Other.m_Finder) {} - - // Constructor - template - find_iterator_base( FinderT Finder, int ) : - m_Finder(Finder) {} - - // Destructor - ~find_iterator_base() {} - - // Find operation - match_type do_find( - input_iterator_type Begin, - input_iterator_type End ) const - { - if (!m_Finder.empty()) - { - return m_Finder(Begin,End); - } - else - { - return match_type(End,End); - } - } - - // Check - bool is_null() const - { - return m_Finder.empty(); - } - - private: - // Finder - finder_type m_Finder; - }; - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_FIND_ITERATOR_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder.hpp deleted file mode 100644 index 209ce0b2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder.hpp +++ /dev/null @@ -1,641 +0,0 @@ -// Boost string_algo library finder.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FINDER_DETAIL_HPP -#define BOOST_STRING_FINDER_DETAIL_HPP - -#include -#include -#include - -#include -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - - -// find first functor -----------------------------------------------// - - // find a subsequence in the sequence ( functor ) - /* - Returns a pair marking the subsequence in the sequence. - If the find fails, functor returns - */ - template - struct first_finderF - { - typedef SearchIteratorT search_iterator_type; - - // Construction - template< typename SearchT > - first_finderF( const SearchT& Search, PredicateT Comp ) : - m_Search(::boost::begin(Search), ::boost::end(Search)), m_Comp(Comp) {} - first_finderF( - search_iterator_type SearchBegin, - search_iterator_type SearchEnd, - PredicateT Comp ) : - m_Search(SearchBegin, SearchEnd), m_Comp(Comp) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - typedef iterator_range result_type; - typedef ForwardIteratorT input_iterator_type; - - // Outer loop - for(input_iterator_type OuterIt=Begin; - OuterIt!=End; - ++OuterIt) - { - // Sanity check - if( boost::empty(m_Search) ) - return result_type( End, End ); - - input_iterator_type InnerIt=OuterIt; - search_iterator_type SubstrIt=m_Search.begin(); - for(; - InnerIt!=End && SubstrIt!=m_Search.end(); - ++InnerIt,++SubstrIt) - { - if( !( m_Comp(*InnerIt,*SubstrIt) ) ) - break; - } - - // Substring matching succeeded - if ( SubstrIt==m_Search.end() ) - return result_type( OuterIt, InnerIt ); - } - - return result_type( End, End ); - } - - private: - iterator_range m_Search; - PredicateT m_Comp; - }; - -// find last functor -----------------------------------------------// - - // find the last match a subsequence in the sequence ( functor ) - /* - Returns a pair marking the subsequence in the sequence. - If the find fails, returns - */ - template - struct last_finderF - { - typedef SearchIteratorT search_iterator_type; - typedef first_finderF< - search_iterator_type, - PredicateT> first_finder_type; - - // Construction - template< typename SearchT > - last_finderF( const SearchT& Search, PredicateT Comp ) : - m_Search(::boost::begin(Search), ::boost::end(Search)), m_Comp(Comp) {} - last_finderF( - search_iterator_type SearchBegin, - search_iterator_type SearchEnd, - PredicateT Comp ) : - m_Search(SearchBegin, SearchEnd), m_Comp(Comp) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - typedef iterator_range result_type; - - if( boost::empty(m_Search) ) - return result_type( End, End ); - - typedef BOOST_STRING_TYPENAME boost::detail:: - iterator_traits::iterator_category category; - - return findit( Begin, End, category() ); - } - - private: - // forward iterator - template< typename ForwardIteratorT > - iterator_range - findit( - ForwardIteratorT Begin, - ForwardIteratorT End, - std::forward_iterator_tag ) const - { - typedef iterator_range result_type; - - first_finder_type first_finder( - m_Search.begin(), m_Search.end(), m_Comp ); - - result_type M=first_finder( Begin, End ); - result_type Last=M; - - while( M ) - { - Last=M; - M=first_finder( ::boost::end(M), End ); - } - - return Last; - } - - // bidirectional iterator - template< typename ForwardIteratorT > - iterator_range - findit( - ForwardIteratorT Begin, - ForwardIteratorT End, - std::bidirectional_iterator_tag ) const - { - typedef iterator_range result_type; - typedef ForwardIteratorT input_iterator_type; - - // Outer loop - for(input_iterator_type OuterIt=End; - OuterIt!=Begin; ) - { - input_iterator_type OuterIt2=--OuterIt; - - input_iterator_type InnerIt=OuterIt2; - search_iterator_type SubstrIt=m_Search.begin(); - for(; - InnerIt!=End && SubstrIt!=m_Search.end(); - ++InnerIt,++SubstrIt) - { - if( !( m_Comp(*InnerIt,*SubstrIt) ) ) - break; - } - - // Substring matching succeeded - if( SubstrIt==m_Search.end() ) - return result_type( OuterIt2, InnerIt ); - } - - return result_type( End, End ); - } - - private: - iterator_range m_Search; - PredicateT m_Comp; - }; - -// find n-th functor -----------------------------------------------// - - // find the n-th match of a subsequence in the sequence ( functor ) - /* - Returns a pair marking the subsequence in the sequence. - If the find fails, returns - */ - template - struct nth_finderF - { - typedef SearchIteratorT search_iterator_type; - typedef first_finderF< - search_iterator_type, - PredicateT> first_finder_type; - typedef last_finderF< - search_iterator_type, - PredicateT> last_finder_type; - - // Construction - template< typename SearchT > - nth_finderF( - const SearchT& Search, - int Nth, - PredicateT Comp) : - m_Search(::boost::begin(Search), ::boost::end(Search)), - m_Nth(Nth), - m_Comp(Comp) {} - nth_finderF( - search_iterator_type SearchBegin, - search_iterator_type SearchEnd, - int Nth, - PredicateT Comp) : - m_Search(SearchBegin, SearchEnd), - m_Nth(Nth), - m_Comp(Comp) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - if(m_Nth>=0) - { - return find_forward(Begin, End, m_Nth); - } - else - { - return find_backward(Begin, End, -m_Nth); - } - - } - - private: - // Implementation helpers - template< typename ForwardIteratorT > - iterator_range - find_forward( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N) const - { - typedef iterator_range result_type; - - // Sanity check - if( boost::empty(m_Search) ) - return result_type( End, End ); - - // Instantiate find functor - first_finder_type first_finder( - m_Search.begin(), m_Search.end(), m_Comp ); - - result_type M( Begin, Begin ); - - for( unsigned int n=0; n<=N; ++n ) - { - // find next match - M=first_finder( ::boost::end(M), End ); - - if ( !M ) - { - // Subsequence not found, return - return M; - } - } - - return M; - } - - template< typename ForwardIteratorT > - iterator_range - find_backward( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N) const - { - typedef iterator_range result_type; - - // Sanity check - if( boost::empty(m_Search) ) - return result_type( End, End ); - - // Instantiate find functor - last_finder_type last_finder( - m_Search.begin(), m_Search.end(), m_Comp ); - - result_type M( End, End ); - - for( unsigned int n=1; n<=N; ++n ) - { - // find next match - M=last_finder( Begin, ::boost::begin(M) ); - - if ( !M ) - { - // Subsequence not found, return - return M; - } - } - - return M; - } - - - private: - iterator_range m_Search; - int m_Nth; - PredicateT m_Comp; - }; - -// find head/tail implementation helpers ---------------------------// - - template - iterator_range - find_head_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N, - std::forward_iterator_tag ) - { - typedef ForwardIteratorT input_iterator_type; - typedef iterator_range result_type; - - input_iterator_type It=Begin; - for( - unsigned int Index=0; - Index - iterator_range - find_head_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N, - std::random_access_iterator_tag ) - { - typedef iterator_range result_type; - - if ( (End<=Begin) || ( static_cast(End-Begin) < N ) ) - return result_type( Begin, End ); - - return result_type(Begin,Begin+N); - } - - // Find head implementation - template - iterator_range - find_head_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N ) - { - typedef BOOST_STRING_TYPENAME boost::detail:: - iterator_traits::iterator_category category; - - return ::boost::algorithm::detail::find_head_impl( Begin, End, N, category() ); - } - - template< typename ForwardIteratorT > - iterator_range - find_tail_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N, - std::forward_iterator_tag ) - { - typedef ForwardIteratorT input_iterator_type; - typedef iterator_range result_type; - - unsigned int Index=0; - input_iterator_type It=Begin; - input_iterator_type It2=Begin; - - // Advance It2 by N increments - for( Index=0; Index - iterator_range - find_tail_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N, - std::bidirectional_iterator_tag ) - { - typedef ForwardIteratorT input_iterator_type; - typedef iterator_range result_type; - - input_iterator_type It=End; - for( - unsigned int Index=0; - Index - iterator_range - find_tail_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N, - std::random_access_iterator_tag ) - { - typedef iterator_range result_type; - - if ( (End<=Begin) || ( static_cast(End-Begin) < N ) ) - return result_type( Begin, End ); - - return result_type( End-N, End ); - } - - // Operation - template< typename ForwardIteratorT > - iterator_range - find_tail_impl( - ForwardIteratorT Begin, - ForwardIteratorT End, - unsigned int N ) - { - typedef BOOST_STRING_TYPENAME boost::detail:: - iterator_traits::iterator_category category; - - return ::boost::algorithm::detail::find_tail_impl( Begin, End, N, category() ); - } - - - -// find head functor -----------------------------------------------// - - - // find a head in the sequence ( functor ) - /* - This functor find a head of the specified range. For - a specified N, the head is a subsequence of N starting - elements of the range. - */ - struct head_finderF - { - // Construction - head_finderF( int N ) : m_N(N) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - if(m_N>=0) - { - return ::boost::algorithm::detail::find_head_impl( Begin, End, m_N ); - } - else - { - iterator_range Res= - ::boost::algorithm::detail::find_tail_impl( Begin, End, -m_N ); - - return ::boost::make_iterator_range(Begin, Res.begin()); - } - } - - private: - int m_N; - }; - -// find tail functor -----------------------------------------------// - - - // find a tail in the sequence ( functor ) - /* - This functor find a tail of the specified range. For - a specified N, the head is a subsequence of N starting - elements of the range. - */ - struct tail_finderF - { - // Construction - tail_finderF( int N ) : m_N(N) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - if(m_N>=0) - { - return ::boost::algorithm::detail::find_tail_impl( Begin, End, m_N ); - } - else - { - iterator_range Res= - ::boost::algorithm::detail::find_head_impl( Begin, End, -m_N ); - - return ::boost::make_iterator_range(Res.end(), End); - } - } - - private: - int m_N; - }; - -// find token functor -----------------------------------------------// - - // find a token in a sequence ( functor ) - /* - This find functor finds a token specified be a predicate - in a sequence. It is equivalent of std::find algorithm, - with an exception that it return range instead of a single - iterator. - - If bCompress is set to true, adjacent matching tokens are - concatenated into one match. - */ - template< typename PredicateT > - struct token_finderF - { - // Construction - token_finderF( - PredicateT Pred, - token_compress_mode_type eCompress=token_compress_off ) : - m_Pred(Pred), m_eCompress(eCompress) {} - - // Operation - template< typename ForwardIteratorT > - iterator_range - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - typedef iterator_range result_type; - - ForwardIteratorT It=std::find_if( Begin, End, m_Pred ); - - if( It==End ) - { - return result_type( End, End ); - } - else - { - ForwardIteratorT It2=It; - - if( m_eCompress==token_compress_on ) - { - // Find first non-matching character - while( It2!=End && m_Pred(*It2) ) ++It2; - } - else - { - // Advance by one position - ++It2; - } - - return result_type( It, It2 ); - } - } - - private: - PredicateT m_Pred; - token_compress_mode_type m_eCompress; - }; - -// find range functor -----------------------------------------------// - - // find a range in the sequence ( functor ) - /* - This functor actually does not perform any find operation. - It always returns given iterator range as a result. - */ - template - struct range_finderF - { - typedef ForwardIterator1T input_iterator_type; - typedef iterator_range result_type; - - // Construction - range_finderF( - input_iterator_type Begin, - input_iterator_type End ) : m_Range(Begin, End) {} - - range_finderF(const iterator_range& Range) : - m_Range(Range) {} - - // Operation - template< typename ForwardIterator2T > - iterator_range - operator()( - ForwardIterator2T, - ForwardIterator2T ) const - { -#if BOOST_WORKAROUND( __MWERKS__, <= 0x3003 ) - return iterator_range(this->m_Range); -#elif BOOST_WORKAROUND(BOOST_MSVC, <= 1300) - return iterator_range(m_Range.begin(), m_Range.end()); -#else - return m_Range; -#endif - } - - private: - iterator_range m_Range; - }; - - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FINDER_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder_regex.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder_regex.hpp deleted file mode 100644 index 9cb01cfa..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/finder_regex.hpp +++ /dev/null @@ -1,122 +0,0 @@ -// Boost string_algo library find_regex.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FINDER_REGEX_DETAIL_HPP -#define BOOST_STRING_FINDER_REGEX_DETAIL_HPP - -#include -#include - -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// regex find functor -----------------------------------------------// - - // regex search result - template - struct regex_search_result : - public iterator_range - { - typedef regex_search_result type; - typedef iterator_range base_type; - typedef BOOST_STRING_TYPENAME base_type::value_type value_type; - typedef BOOST_STRING_TYPENAME base_type::difference_type difference_type; - typedef BOOST_STRING_TYPENAME base_type::const_iterator const_iterator; - typedef BOOST_STRING_TYPENAME base_type::iterator iterator; - typedef boost::match_results match_results_type; - - // Construction - - // Construction from the match result - regex_search_result( const match_results_type& MatchResults ) : - base_type( MatchResults[0].first, MatchResults[0].second ), - m_MatchResults( MatchResults ) {} - - // Construction of empty match. End iterator has to be specified - regex_search_result( IteratorT End ) : - base_type( End, End ) {} - - regex_search_result( const regex_search_result& Other ) : - base_type( Other.begin(), Other.end() ), - m_MatchResults( Other.m_MatchResults ) {} - - // Assignment - regex_search_result& operator=( const regex_search_result& Other ) - { - base_type::operator=( Other ); - m_MatchResults=Other.m_MatchResults; - return *this; - } - - // Match result retrieval - const match_results_type& match_results() const - { - return m_MatchResults; - } - - private: - // Saved match result - match_results_type m_MatchResults; - }; - - // find_regex - /* - Regex based search functor - */ - template - struct find_regexF - { - typedef RegExT regex_type; - typedef const RegExT& regex_reference_type; - - // Construction - find_regexF( regex_reference_type Rx, match_flag_type MatchFlags = match_default ) : - m_Rx(Rx), m_MatchFlags(MatchFlags) {} - - // Operation - template< typename ForwardIteratorT > - regex_search_result - operator()( - ForwardIteratorT Begin, - ForwardIteratorT End ) const - { - typedef ForwardIteratorT input_iterator_type; - typedef regex_search_result result_type; - - // instantiate match result - match_results result; - // search for a match - if ( ::boost::regex_search( Begin, End, result, m_Rx, m_MatchFlags ) ) - { - // construct a result - return result_type( result ); - } - else - { - // empty result - return result_type( End ); - } - } - - private: - regex_reference_type m_Rx; // Regexp - match_flag_type m_MatchFlags; // match flags - }; - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FIND_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter.hpp deleted file mode 100644 index c071822f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter.hpp +++ /dev/null @@ -1,119 +0,0 @@ -// Boost string_algo library formatter.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FORMATTER_DETAIL_HPP -#define BOOST_STRING_FORMATTER_DETAIL_HPP - - -#include -#include -#include -#include - -#include - -// generic replace functors -----------------------------------------------// - -namespace boost { - namespace algorithm { - namespace detail { - -// const format functor ----------------------------------------------------// - - // constant format functor - template - struct const_formatF - { - private: - typedef BOOST_STRING_TYPENAME - range_const_iterator::type format_iterator; - typedef iterator_range result_type; - - public: - // Construction - const_formatF(const RangeT& Format) : - m_Format(::boost::begin(Format), ::boost::end(Format)) {} - - // Operation -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - template - result_type& operator()(const Range2T&) - { - return m_Format; - } -#endif - - template - const result_type& operator()(const Range2T&) const - { - return m_Format; - } - - private: - result_type m_Format; - }; - -// identity format functor ----------------------------------------------------// - - // identity format functor - template - struct identity_formatF - { - // Operation - template< typename Range2T > - const RangeT& operator()(const Range2T& Replace) const - { - return RangeT(::boost::begin(Replace), ::boost::end(Replace)); - } - }; - -// empty format functor ( used by erase ) ------------------------------------// - - // empty format functor - template< typename CharT > - struct empty_formatF - { - template< typename ReplaceT > - empty_container operator()(const ReplaceT&) const - { - return empty_container(); - } - }; - -// dissect format functor ----------------------------------------------------// - - // dissect format functor - template - struct dissect_formatF - { - public: - // Construction - dissect_formatF(FinderT Finder) : - m_Finder(Finder) {} - - // Operation - template - inline iterator_range< - BOOST_STRING_TYPENAME range_const_iterator::type> - operator()(const RangeT& Replace) const - { - return m_Finder(::boost::begin(Replace), ::boost::end(Replace)); - } - - private: - FinderT m_Finder; - }; - - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FORMATTER_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter_regex.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter_regex.hpp deleted file mode 100644 index 5f26407b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/formatter_regex.hpp +++ /dev/null @@ -1,61 +0,0 @@ -// Boost string_algo library formatter_regex.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FORMATTER_REGEX_DETAIL_HPP -#define BOOST_STRING_FORMATTER_REGEX_DETAIL_HPP - -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// regex format functor -----------------------------------------// - - // regex format functor - template - struct regex_formatF - { - private: - typedef StringT result_type; - typedef BOOST_STRING_TYPENAME StringT::value_type char_type; - - public: - // Construction - regex_formatF( const StringT& Fmt, match_flag_type Flags=format_default ) : - m_Fmt(Fmt), m_Flags( Flags ) {} - - template - result_type operator()( - const regex_search_result& Replace ) const - { - if ( Replace.empty() ) - { - return result_type(); - } - else - { - return Replace.match_results().format( m_Fmt, m_Flags ); - } - } - private: - const StringT& m_Fmt; - match_flag_type m_Flags; - }; - - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_FORMATTER_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/predicate.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/predicate.hpp deleted file mode 100644 index 5acf3cc6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/predicate.hpp +++ /dev/null @@ -1,77 +0,0 @@ -// Boost string_algo library predicate.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_PREDICATE_DETAIL_HPP -#define BOOST_STRING_PREDICATE_DETAIL_HPP - -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// ends_with predicate implementation ----------------------------------// - - template< - typename ForwardIterator1T, - typename ForwardIterator2T, - typename PredicateT> - inline bool ends_with_iter_select( - ForwardIterator1T Begin, - ForwardIterator1T End, - ForwardIterator2T SubBegin, - ForwardIterator2T SubEnd, - PredicateT Comp, - std::bidirectional_iterator_tag) - { - ForwardIterator1T it=End; - ForwardIterator2T pit=SubEnd; - for(;it!=Begin && pit!=SubBegin;) - { - if( !(Comp(*(--it),*(--pit))) ) - return false; - } - - return pit==SubBegin; - } - - template< - typename ForwardIterator1T, - typename ForwardIterator2T, - typename PredicateT> - inline bool ends_with_iter_select( - ForwardIterator1T Begin, - ForwardIterator1T End, - ForwardIterator2T SubBegin, - ForwardIterator2T SubEnd, - PredicateT Comp, - std::forward_iterator_tag) - { - if ( SubBegin==SubEnd ) - { - // empty subsequence check - return true; - } - - iterator_range Result - =last_finder( - ::boost::make_iterator_range(SubBegin, SubEnd), - Comp)(Begin, End); - - return !Result.empty() && Result.end()==End; - } - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_PREDICATE_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/replace_storage.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/replace_storage.hpp deleted file mode 100644 index db35e4c5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/replace_storage.hpp +++ /dev/null @@ -1,159 +0,0 @@ -// Boost string_algo library replace_storage.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_REPLACE_STORAGE_DETAIL_HPP -#define BOOST_STRING_REPLACE_STORAGE_DETAIL_HPP - -#include -#include -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// storage handling routines -----------------------------------------------// - - template< typename StorageT, typename OutputIteratorT > - inline OutputIteratorT move_from_storage( - StorageT& Storage, - OutputIteratorT DestBegin, - OutputIteratorT DestEnd ) - { - OutputIteratorT OutputIt=DestBegin; - - while( !Storage.empty() && OutputIt!=DestEnd ) - { - *OutputIt=Storage.front(); - Storage.pop_front(); - ++OutputIt; - } - - return OutputIt; - } - - template< typename StorageT, typename WhatT > - inline void copy_to_storage( - StorageT& Storage, - const WhatT& What ) - { - Storage.insert( Storage.end(), ::boost::begin(What), ::boost::end(What) ); - } - - -// process segment routine -----------------------------------------------// - - template< bool HasStableIterators > - struct process_segment_helper - { - // Optimized version of process_segment for generic sequence - template< - typename StorageT, - typename InputT, - typename ForwardIteratorT > - ForwardIteratorT operator()( - StorageT& Storage, - InputT& /*Input*/, - ForwardIteratorT InsertIt, - ForwardIteratorT SegmentBegin, - ForwardIteratorT SegmentEnd ) - { - // Copy data from the storage until the beginning of the segment - ForwardIteratorT It=::boost::algorithm::detail::move_from_storage( Storage, InsertIt, SegmentBegin ); - - // 3 cases are possible : - // a) Storage is empty, It==SegmentBegin - // b) Storage is empty, It!=SegmentBegin - // c) Storage is not empty - - if( Storage.empty() ) - { - if( It==SegmentBegin ) - { - // Case a) everything is grand, just return end of segment - return SegmentEnd; - } - else - { - // Case b) move the segment backwards - return std::copy( SegmentBegin, SegmentEnd, It ); - } - } - else - { - // Case c) -> shift the segment to the left and keep the overlap in the storage - while( It!=SegmentEnd ) - { - // Store value into storage - Storage.push_back( *It ); - // Get the top from the storage and put it here - *It=Storage.front(); - Storage.pop_front(); - - // Advance - ++It; - } - - return It; - } - } - }; - - template<> - struct process_segment_helper< true > - { - // Optimized version of process_segment for list-like sequence - template< - typename StorageT, - typename InputT, - typename ForwardIteratorT > - ForwardIteratorT operator()( - StorageT& Storage, - InputT& Input, - ForwardIteratorT InsertIt, - ForwardIteratorT SegmentBegin, - ForwardIteratorT SegmentEnd ) - - { - // Call replace to do the job - ::boost::algorithm::detail::replace( Input, InsertIt, SegmentBegin, Storage ); - // Empty the storage - Storage.clear(); - // Iterators were not changed, simply return the end of segment - return SegmentEnd; - } - }; - - // Process one segment in the replace_all algorithm - template< - typename StorageT, - typename InputT, - typename ForwardIteratorT > - inline ForwardIteratorT process_segment( - StorageT& Storage, - InputT& Input, - ForwardIteratorT InsertIt, - ForwardIteratorT SegmentBegin, - ForwardIteratorT SegmentEnd ) - { - return - process_segment_helper< - has_stable_iterators::value>()( - Storage, Input, InsertIt, SegmentBegin, SegmentEnd ); - } - - - } // namespace detail - } // namespace algorithm -} // namespace boost - -#endif // BOOST_STRING_REPLACE_STORAGE_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/sequence.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/sequence.hpp deleted file mode 100644 index dc474091..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/sequence.hpp +++ /dev/null @@ -1,200 +0,0 @@ -// Boost string_algo library sequence.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_DETAIL_SEQUENCE_HPP -#define BOOST_STRING_DETAIL_SEQUENCE_HPP - -#include -#include -#include -#include -#include - -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// insert helpers -------------------------------------------------// - - template< typename InputT, typename ForwardIteratorT > - inline void insert( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator At, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - Input.insert( At, Begin, End ); - } - - template< typename InputT, typename InsertT > - inline void insert( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator At, - const InsertT& Insert ) - { - ::boost::algorithm::detail::insert( Input, At, ::boost::begin(Insert), ::boost::end(Insert) ); - } - -// erase helper ---------------------------------------------------// - - // Erase a range in the sequence - /* - Returns the iterator pointing just after the erase subrange - */ - template< typename InputT > - inline typename InputT::iterator erase( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To ) - { - return Input.erase( From, To ); - } - -// replace helper implementation ----------------------------------// - - // Optimized version of replace for generic sequence containers - // Assumption: insert and erase are expensive - template< bool HasConstTimeOperations > - struct replace_const_time_helper - { - template< typename InputT, typename ForwardIteratorT > - void operator()( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - // Copy data to the container ( as much as possible ) - ForwardIteratorT InsertIt=Begin; - BOOST_STRING_TYPENAME InputT::iterator InputIt=From; - for(; InsertIt!=End && InputIt!=To; InsertIt++, InputIt++ ) - { - *InputIt=*InsertIt; - } - - if ( InsertIt!=End ) - { - // Replace sequence is longer, insert it - Input.insert( InputIt, InsertIt, End ); - } - else - { - if ( InputIt!=To ) - { - // Replace sequence is shorter, erase the rest - Input.erase( InputIt, To ); - } - } - } - }; - - template<> - struct replace_const_time_helper< true > - { - // Const-time erase and insert methods -> use them - template< typename InputT, typename ForwardIteratorT > - void operator()( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - BOOST_STRING_TYPENAME InputT::iterator At=Input.erase( From, To ); - if ( Begin!=End ) - { - if(!Input.empty()) - { - Input.insert( At, Begin, End ); - } - else - { - Input.insert( Input.begin(), Begin, End ); - } - } - } - }; - - // No native replace method - template< bool HasNative > - struct replace_native_helper - { - template< typename InputT, typename ForwardIteratorT > - void operator()( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - replace_const_time_helper< - boost::mpl::and_< - has_const_time_insert, - has_const_time_erase >::value >()( - Input, From, To, Begin, End ); - } - }; - - // Container has native replace method - template<> - struct replace_native_helper< true > - { - template< typename InputT, typename ForwardIteratorT > - void operator()( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - Input.replace( From, To, Begin, End ); - } - }; - -// replace helper -------------------------------------------------// - - template< typename InputT, typename ForwardIteratorT > - inline void replace( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - replace_native_helper< has_native_replace::value >()( - Input, From, To, Begin, End ); - } - - template< typename InputT, typename InsertT > - inline void replace( - InputT& Input, - BOOST_STRING_TYPENAME InputT::iterator From, - BOOST_STRING_TYPENAME InputT::iterator To, - const InsertT& Insert ) - { - if(From!=To) - { - ::boost::algorithm::detail::replace( Input, From, To, ::boost::begin(Insert), ::boost::end(Insert) ); - } - else - { - ::boost::algorithm::detail::insert( Input, From, ::boost::begin(Insert), ::boost::end(Insert) ); - } - } - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_DETAIL_SEQUENCE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/trim.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/trim.hpp deleted file mode 100644 index 1233e49d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/trim.hpp +++ /dev/null @@ -1,95 +0,0 @@ -// Boost string_algo library trim.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_TRIM_DETAIL_HPP -#define BOOST_STRING_TRIM_DETAIL_HPP - -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// trim iterator helper -----------------------------------------------// - - template< typename ForwardIteratorT, typename PredicateT > - inline ForwardIteratorT trim_end_iter_select( - ForwardIteratorT InBegin, - ForwardIteratorT InEnd, - PredicateT IsSpace, - std::forward_iterator_tag ) - { - ForwardIteratorT TrimIt=InBegin; - - for( ForwardIteratorT It=InBegin; It!=InEnd; ++It ) - { - if ( !IsSpace(*It) ) - { - TrimIt=It; - ++TrimIt; - } - } - - return TrimIt; - } - - template< typename ForwardIteratorT, typename PredicateT > - inline ForwardIteratorT trim_end_iter_select( - ForwardIteratorT InBegin, - ForwardIteratorT InEnd, - PredicateT IsSpace, - std::bidirectional_iterator_tag ) - { - for( ForwardIteratorT It=InEnd; It!=InBegin; ) - { - if ( !IsSpace(*(--It)) ) - return ++It; - } - - return InBegin; - } - // Search for first non matching character from the beginning of the sequence - template< typename ForwardIteratorT, typename PredicateT > - inline ForwardIteratorT trim_begin( - ForwardIteratorT InBegin, - ForwardIteratorT InEnd, - PredicateT IsSpace ) - { - ForwardIteratorT It=InBegin; - for(; It!=InEnd; ++It ) - { - if (!IsSpace(*It)) - return It; - } - - return It; - } - - // Search for first non matching character from the end of the sequence - template< typename ForwardIteratorT, typename PredicateT > - inline ForwardIteratorT trim_end( - ForwardIteratorT InBegin, - ForwardIteratorT InEnd, - PredicateT IsSpace ) - { - typedef BOOST_STRING_TYPENAME boost::detail:: - iterator_traits::iterator_category category; - - return ::boost::algorithm::detail::trim_end_iter_select( InBegin, InEnd, IsSpace, category() ); - } - - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_TRIM_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/util.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/util.hpp deleted file mode 100644 index cf4a8b1c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/detail/util.hpp +++ /dev/null @@ -1,106 +0,0 @@ -// Boost string_algo library util.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_UTIL_DETAIL_HPP -#define BOOST_STRING_UTIL_DETAIL_HPP - -#include -#include -#include - -namespace boost { - namespace algorithm { - namespace detail { - -// empty container -----------------------------------------------// - - // empty_container - /* - This class represents always empty container, - containing elements of type CharT. - - It is supposed to be used in a const version only - */ - template< typename CharT > - struct empty_container - { - typedef empty_container type; - typedef CharT value_type; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - typedef const value_type& reference; - typedef const value_type& const_reference; - typedef const value_type* iterator; - typedef const value_type* const_iterator; - - - // Operations - const_iterator begin() const - { - return reinterpret_cast(0); - } - - const_iterator end() const - { - return reinterpret_cast(0); - } - - bool empty() const - { - return false; - } - - size_type size() const - { - return 0; - } - }; - -// bounded copy algorithm -----------------------------------------------// - - // Bounded version of the std::copy algorithm - template - inline OutputIteratorT bounded_copy( - InputIteratorT First, - InputIteratorT Last, - OutputIteratorT DestFirst, - OutputIteratorT DestLast ) - { - InputIteratorT InputIt=First; - OutputIteratorT OutputIt=DestFirst; - for(; InputIt!=Last && OutputIt!=DestLast; InputIt++, OutputIt++ ) - { - *OutputIt=*InputIt; - } - - return OutputIt; - } - -// iterator range utilities -----------------------------------------// - - // copy range functor - template< - typename SeqT, - typename IteratorT=BOOST_STRING_TYPENAME SeqT::const_iterator > - struct copy_iterator_rangeF : - public std::unary_function< iterator_range, SeqT > - { - SeqT operator()( const iterator_range& Range ) const - { - return copy_range(Range); - } - }; - - } // namespace detail - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_UTIL_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/erase.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/erase.hpp deleted file mode 100644 index 68837909..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/erase.hpp +++ /dev/null @@ -1,844 +0,0 @@ -// Boost string_algo library erase.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_ERASE_HPP -#define BOOST_STRING_ERASE_HPP - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines various erase algorithms. Each algorithm removes - part(s) of the input according to a searching criteria. -*/ - -namespace boost { - namespace algorithm { - -// erase_range -------------------------------------------------------// - - //! Erase range algorithm - /*! - Remove the given range from the input. The result is a modified copy of - the input. It is returned as a sequence or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input sequence - \param SearchRange A range in the input to be removed - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template - inline OutputIteratorT erase_range_copy( - OutputIteratorT Output, - const RangeT& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_const_iterator::type>& SearchRange ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase range algorithm - /*! - \overload - */ - template - inline SequenceT erase_range_copy( - const SequenceT& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_const_iterator::type>& SearchRange ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase range algorithm - /*! - Remove the given range from the input. - The input sequence is modified in-place. - - \param Input An input sequence - \param SearchRange A range in the input to be removed - */ - template - inline void erase_range( - SequenceT& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_iterator::type>& SearchRange ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_first --------------------------------------------------------// - - //! Erase first algorithm - /*! - Remove the first occurrence of the substring from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT erase_first_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase first algorithm - /*! - \overload - */ - template - inline SequenceT erase_first_copy( - const SequenceT& Input, - const RangeT& Search ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase first algorithm - /*! - Remove the first occurrence of the substring from the input. - The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for. - */ - template - inline void erase_first( - SequenceT& Input, - const RangeT& Search ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_first ( case insensitive ) ------------------------------------// - - //! Erase first algorithm ( case insensitive ) - /*! - Remove the first occurrence of the substring from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT ierase_first_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase first algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ierase_first_copy( - const SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase first algorithm ( case insensitive ) - /*! - Remove the first occurrence of the substring from the input. - The input sequence is modified in-place. Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Loc A locale used for case insensitive comparison - */ - template - inline void ierase_first( - SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_last --------------------------------------------------------// - - //! Erase last algorithm - /*! - Remove the last occurrence of the substring from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for. - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT erase_last_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase last algorithm - /*! - \overload - */ - template - inline SequenceT erase_last_copy( - const SequenceT& Input, - const RangeT& Search ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase last algorithm - /*! - Remove the last occurrence of the substring from the input. - The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for - */ - template - inline void erase_last( - SequenceT& Input, - const RangeT& Search ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_last ( case insensitive ) ------------------------------------// - - //! Erase last algorithm ( case insensitive ) - /*! - Remove the last occurrence of the substring from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT ierase_last_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase last algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ierase_last_copy( - const SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase last algorithm ( case insensitive ) - /*! - Remove the last occurrence of the substring from the input. - The input sequence is modified in-place. Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Loc A locale used for case insensitive comparison - */ - template - inline void ierase_last( - SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_nth --------------------------------------------------------------------// - - //! Erase nth algorithm - /*! - Remove the Nth occurrence of the substring in the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT erase_nth_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - int Nth ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase nth algorithm - /*! - \overload - */ - template - inline SequenceT erase_nth_copy( - const SequenceT& Input, - const RangeT& Search, - int Nth ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase nth algorithm - /*! - Remove the Nth occurrence of the substring in the input. - The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for. - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - */ - template - inline void erase_nth( - SequenceT& Input, - const RangeT& Search, - int Nth ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_nth ( case insensitive ) ---------------------------------------------// - - //! Erase nth algorithm ( case insensitive ) - /*! - Remove the Nth occurrence of the substring in the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for. - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT ierase_nth_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - int Nth, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase nth algorithm - /*! - \overload - */ - template - inline SequenceT ierase_nth_copy( - const SequenceT& Input, - const RangeT& Search, - int Nth, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc)), - empty_formatter(Input) ); - } - - //! Erase nth algorithm - /*! - Remove the Nth occurrence of the substring in the input. - The input sequence is modified in-place. Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for. - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Loc A locale used for case insensitive comparison - */ - template - inline void ierase_nth( - SequenceT& Input, - const RangeT& Search, - int Nth, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - -// erase_all --------------------------------------------------------// - - //! Erase all algorithm - /*! - Remove all the occurrences of the string from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - - \param Output An output iterator to which the result will be copied - \param Input An input sequence - \param Search A substring to be searched for. - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT erase_all_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase all algorithm - /*! - \overload - */ - template - inline SequenceT erase_all_copy( - const SequenceT& Input, - const RangeT& Search ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase all algorithm - /*! - Remove all the occurrences of the string from the input. - The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for. - */ - template - inline void erase_all( - SequenceT& Input, - const RangeT& Search ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_all ( case insensitive ) ------------------------------------// - - //! Erase all algorithm ( case insensitive ) - /*! - Remove all the occurrences of the string from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT ierase_all_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase all algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ierase_all_copy( - const SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - - //! Erase all algorithm ( case insensitive ) - /*! - Remove all the occurrences of the string from the input. - The input sequence is modified in-place. Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for. - \param Loc A locale used for case insensitive comparison - */ - template - inline void ierase_all( - SequenceT& Input, - const RangeT& Search, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::empty_formatter(Input) ); - } - -// erase_head --------------------------------------------------------------------// - - //! Erase head algorithm - /*! - Remove the head from the input. The head is a prefix of a sequence of given size. - If the sequence is shorter then required, the whole string is - considered to be the head. The result is a modified copy of the input. - It is returned as a sequence or copied to the output iterator. - - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param N Length of the head. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT> - inline OutputIteratorT erase_head_copy( - OutputIteratorT Output, - const RangeT& Input, - int N ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase head algorithm - /*! - \overload - */ - template - inline SequenceT erase_head_copy( - const SequenceT& Input, - int N ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase head algorithm - /*! - Remove the head from the input. The head is a prefix of a sequence of given size. - If the sequence is shorter then required, the whole string is - considered to be the head. The input sequence is modified in-place. - - \param Input An input string - \param N Length of the head - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - */ - template - inline void erase_head( - SequenceT& Input, - int N ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - -// erase_tail --------------------------------------------------------------------// - - //! Erase tail algorithm - /*! - Remove the tail from the input. The tail is a suffix of a sequence of given size. - If the sequence is shorter then required, the whole string is - considered to be the tail. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param N Length of the tail. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT> - inline OutputIteratorT erase_tail_copy( - OutputIteratorT Output, - const RangeT& Input, - int N ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase tail algorithm - /*! - \overload - */ - template - inline SequenceT erase_tail_copy( - const SequenceT& Input, - int N ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase tail algorithm - /*! - Remove the tail from the input. The tail is a suffix of a sequence of given size. - If the sequence is shorter then required, the whole string is - considered to be the tail. The input sequence is modified in-place. - - \param Input An input string - \param N Length of the tail - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - */ - template - inline void erase_tail( - SequenceT& Input, - int N ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::empty_formatter( Input ) ); - } - - } // namespace algorithm - - // pull names into the boost namespace - using algorithm::erase_range_copy; - using algorithm::erase_range; - using algorithm::erase_first_copy; - using algorithm::erase_first; - using algorithm::ierase_first_copy; - using algorithm::ierase_first; - using algorithm::erase_last_copy; - using algorithm::erase_last; - using algorithm::ierase_last_copy; - using algorithm::ierase_last; - using algorithm::erase_nth_copy; - using algorithm::erase_nth; - using algorithm::ierase_nth_copy; - using algorithm::ierase_nth; - using algorithm::erase_all_copy; - using algorithm::erase_all; - using algorithm::ierase_all_copy; - using algorithm::ierase_all; - using algorithm::erase_head_copy; - using algorithm::erase_head; - using algorithm::erase_tail_copy; - using algorithm::erase_tail; - -} // namespace boost - - -#endif // BOOST_ERASE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find.hpp deleted file mode 100644 index f2c2926b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find.hpp +++ /dev/null @@ -1,334 +0,0 @@ -// Boost string_algo library find.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_HPP -#define BOOST_STRING_FIND_HPP - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines a set of find algorithms. The algorithms are searching - for a substring of the input. The result is given as an \c iterator_range - delimiting the substring. -*/ - -namespace boost { - namespace algorithm { - -// Generic find -----------------------------------------------// - - //! Generic find algorithm - /*! - Search the input using the given finder. - - \param Input A string which will be searched. - \param Finder Finder object used for searching. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c RangeT::iterator or - \c RangeT::const_iterator, depending on the constness of - the input parameter. - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find( - RangeT& Input, - const FinderT& Finder) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - - return Finder(::boost::begin(lit_input),::boost::end(lit_input)); - } - -// find_first -----------------------------------------------// - - //! Find first algorithm - /*! - Search for the first occurrence of the substring in the input. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c RangeT::iterator or - \c RangeT::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_first( - Range1T& Input, - const Range2T& Search) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::first_finder(Search)); - } - - //! Find first algorithm ( case insensitive ) - /*! - Search for the first occurrence of the substring in the input. - Searching is case insensitive. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \param Loc A locale used for case insensitive comparison - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - ifind_first( - Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::first_finder(Search,is_iequal(Loc))); - } - -// find_last -----------------------------------------------// - - //! Find last algorithm - /*! - Search for the last occurrence of the substring in the input. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_last( - Range1T& Input, - const Range2T& Search) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::last_finder(Search)); - } - - //! Find last algorithm ( case insensitive ) - /*! - Search for the last match a string in the input. - Searching is case insensitive. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \param Loc A locale used for case insensitive comparison - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - ifind_last( - Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::last_finder(Search, is_iequal(Loc))); - } - -// find_nth ----------------------------------------------------------------------// - - //! Find n-th algorithm - /*! - Search for the n-th (zero-indexed) occurrence of the substring in the - input. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \param Nth An index (zero-indexed) of the match to be found. - For negative N, the matches are counted from the end of string. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_nth( - Range1T& Input, - const Range2T& Search, - int Nth) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::nth_finder(Search,Nth)); - } - - //! Find n-th algorithm ( case insensitive ). - /*! - Search for the n-th (zero-indexed) occurrence of the substring in the - input. Searching is case insensitive. - - \param Input A string which will be searched. - \param Search A substring to be searched for. - \param Nth An index (zero-indexed) of the match to be found. - For negative N, the matches are counted from the end of string. - \param Loc A locale used for case insensitive comparison - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - ifind_nth( - Range1T& Input, - const Range2T& Search, - int Nth, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::nth_finder(Search,Nth,is_iequal(Loc))); - } - -// find_head ----------------------------------------------------------------------// - - //! Find head algorithm - /*! - Get the head of the input. Head is a prefix of the string of the - given size. If the input is shorter then required, whole input is considered - to be the head. - - \param Input An input string - \param N Length of the head - For N>=0, at most N characters are extracted. - For N<0, at most size(Input)-|N| characters are extracted. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c Range1T::iterator or - \c Range1T::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_head( - RangeT& Input, - int N) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::head_finder(N)); - } - -// find_tail ----------------------------------------------------------------------// - - //! Find tail algorithm - /*! - Get the tail of the input. Tail is a suffix of the string of the - given size. If the input is shorter then required, whole input is considered - to be the tail. - - \param Input An input string - \param N Length of the tail. - For N>=0, at most N characters are extracted. - For N<0, at most size(Input)-|N| characters are extracted. - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c RangeT::iterator or - \c RangeT::const_iterator, depending on the constness of - the input parameter. - - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_tail( - RangeT& Input, - int N) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::tail_finder(N)); - } - -// find_token --------------------------------------------------------------------// - - //! Find token algorithm - /*! - Look for a given token in the string. Token is a character that matches the - given predicate. - If the "token compress mode" is enabled, adjacent tokens are considered to be one match. - - \param Input A input string. - \param Pred A unary predicate to identify a token - \param eCompress Enable/Disable compressing of adjacent tokens - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c RangeT::iterator or - \c RangeT::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type> - find_token( - RangeT& Input, - PredicateT Pred, - token_compress_mode_type eCompress=token_compress_off) - { - return ::boost::algorithm::find(Input, ::boost::algorithm::token_finder(Pred, eCompress)); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::find; - using algorithm::find_first; - using algorithm::ifind_first; - using algorithm::find_last; - using algorithm::ifind_last; - using algorithm::find_nth; - using algorithm::ifind_nth; - using algorithm::find_head; - using algorithm::find_tail; - using algorithm::find_token; - -} // namespace boost - - -#endif // BOOST_STRING_FIND_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_format.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_format.hpp deleted file mode 100644 index 0e84a4ee..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_format.hpp +++ /dev/null @@ -1,287 +0,0 @@ -// Boost string_algo library find_format.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_FORMAT_HPP -#define BOOST_STRING_FIND_FORMAT_HPP - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines generic replace algorithms. Each algorithm replaces - part(s) of the input. The part to be replaced is looked up using a Finder object. - Result of finding is then used by a Formatter object to generate the replacement. -*/ - -namespace boost { - namespace algorithm { - -// generic replace -----------------------------------------------------------------// - - //! Generic replace algorithm - /*! - Use the Finder to search for a substring. Use the Formatter to format - this substring and replace it in the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input sequence - \param Finder A Finder object used to search for a match to be replaced - \param Formatter A Formatter object used to format a match - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename FinderT, - typename FormatterT> - inline OutputIteratorT find_format_copy( - OutputIteratorT Output, - const RangeT& Input, - FinderT Finder, - FormatterT Formatter ) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - iterator_range::type> lit_input(::boost::as_literal(Input)); - - return detail::find_format_copy_impl( - Output, - lit_input, - Formatter, - Finder( ::boost::begin(lit_input), ::boost::end(lit_input) ) ); - } - - //! Generic replace algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename FinderT, - typename FormatterT> - inline SequenceT find_format_copy( - const SequenceT& Input, - FinderT Finder, - FormatterT Formatter ) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - return detail::find_format_copy_impl( - Input, - Formatter, - Finder(::boost::begin(Input), ::boost::end(Input))); - } - - //! Generic replace algorithm - /*! - Use the Finder to search for a substring. Use the Formatter to format - this substring and replace it in the input. The input is modified in-place. - - \param Input An input sequence - \param Finder A Finder object used to search for a match to be replaced - \param Formatter A Formatter object used to format a match - */ - template< - typename SequenceT, - typename FinderT, - typename FormatterT> - inline void find_format( - SequenceT& Input, - FinderT Finder, - FormatterT Formatter) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - detail::find_format_impl( - Input, - Formatter, - Finder(::boost::begin(Input), ::boost::end(Input))); - } - - -// find_format_all generic ----------------------------------------------------------------// - - //! Generic replace all algorithm - /*! - Use the Finder to search for a substring. Use the Formatter to format - this substring and replace it in the input. Repeat this for all matching - substrings. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input sequence - \param Finder A Finder object used to search for a match to be replaced - \param Formatter A Formatter object used to format a match - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename FinderT, - typename FormatterT> - inline OutputIteratorT find_format_all_copy( - OutputIteratorT Output, - const RangeT& Input, - FinderT Finder, - FormatterT Formatter) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - iterator_range::type> lit_input(::boost::as_literal(Input)); - - return detail::find_format_all_copy_impl( - Output, - lit_input, - Finder, - Formatter, - Finder(::boost::begin(lit_input), ::boost::end(lit_input))); - } - - //! Generic replace all algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename FinderT, - typename FormatterT > - inline SequenceT find_format_all_copy( - const SequenceT& Input, - FinderT Finder, - FormatterT Formatter ) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - return detail::find_format_all_copy_impl( - Input, - Finder, - Formatter, - Finder( ::boost::begin(Input), ::boost::end(Input) ) ); - } - - //! Generic replace all algorithm - /*! - Use the Finder to search for a substring. Use the Formatter to format - this substring and replace it in the input. Repeat this for all matching - substrings.The input is modified in-place. - - \param Input An input sequence - \param Finder A Finder object used to search for a match to be replaced - \param Formatter A Formatter object used to format a match - */ - template< - typename SequenceT, - typename FinderT, - typename FormatterT > - inline void find_format_all( - SequenceT& Input, - FinderT Finder, - FormatterT Formatter ) - { - // Concept check - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_const_iterator::type> - )); - BOOST_CONCEPT_ASSERT(( - FormatterConcept< - FormatterT, - FinderT,BOOST_STRING_TYPENAME range_const_iterator::type> - )); - - detail::find_format_all_impl( - Input, - Finder, - Formatter, - Finder(::boost::begin(Input), ::boost::end(Input))); - - } - - } // namespace algorithm - - // pull the names to the boost namespace - using algorithm::find_format_copy; - using algorithm::find_format; - using algorithm::find_format_all_copy; - using algorithm::find_format_all; - -} // namespace boost - - -#endif // BOOST_STRING_FIND_FORMAT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_iterator.hpp deleted file mode 100644 index 1502c7d9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/find_iterator.hpp +++ /dev/null @@ -1,383 +0,0 @@ -// Boost string_algo library find_iterator.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FIND_ITERATOR_HPP -#define BOOST_STRING_FIND_ITERATOR_HPP - -#include -#include -#include - -#include -#include -#include -#include -#include - -#include - -/*! \file - Defines find iterator classes. Find iterator repeatedly applies a Finder - to the specified input string to search for matches. Dereferencing - the iterator yields the current match or a range between the last and the current - match depending on the iterator used. -*/ - -namespace boost { - namespace algorithm { - -// find_iterator -----------------------------------------------// - - //! find_iterator - /*! - Find iterator encapsulates a Finder and allows - for incremental searching in a string. - Each increment moves the iterator to the next match. - - Find iterator is a readable forward traversal iterator. - - Dereferencing the iterator yields an iterator_range delimiting - the current match. - */ - template - class find_iterator : - public iterator_facade< - find_iterator, - const iterator_range, - forward_traversal_tag >, - private detail::find_iterator_base - { - private: - // facade support - friend class ::boost::iterator_core_access; - - private: - // typedefs - - typedef detail::find_iterator_base base_type; - typedef BOOST_STRING_TYPENAME - base_type::input_iterator_type input_iterator_type; - typedef BOOST_STRING_TYPENAME - base_type::match_type match_type; - - public: - //! Default constructor - /*! - Construct null iterator. All null iterators are equal. - - \post eof()==true - */ - find_iterator() {} - - //! Copy constructor - /*! - Construct a copy of the find_iterator - */ - find_iterator( const find_iterator& Other ) : - base_type(Other), - m_Match(Other.m_Match), - m_End(Other.m_End) {} - - //! Constructor - /*! - Construct new find_iterator for a given finder - and a range. - */ - template - find_iterator( - IteratorT Begin, - IteratorT End, - FinderT Finder ) : - detail::find_iterator_base(Finder,0), - m_Match(Begin,Begin), - m_End(End) - { - increment(); - } - - //! Constructor - /*! - Construct new find_iterator for a given finder - and a range. - */ - template - find_iterator( - RangeT& Col, - FinderT Finder ) : - detail::find_iterator_base(Finder,0) - { - iterator_range::type> lit_col(::boost::as_literal(Col)); - m_Match=::boost::make_iterator_range(::boost::begin(lit_col), ::boost::begin(lit_col)); - m_End=::boost::end(lit_col); - - increment(); - } - - private: - // iterator operations - - // dereference - const match_type& dereference() const - { - return m_Match; - } - - // increment - void increment() - { - m_Match=this->do_find(m_Match.end(),m_End); - } - - // comparison - bool equal( const find_iterator& Other ) const - { - bool bEof=eof(); - bool bOtherEof=Other.eof(); - - return bEof || bOtherEof ? bEof==bOtherEof : - ( - m_Match==Other.m_Match && - m_End==Other.m_End - ); - } - - public: - // operations - - //! Eof check - /*! - Check the eof condition. Eof condition means that - there is nothing more to be searched i.e. find_iterator - is after the last match. - */ - bool eof() const - { - return - this->is_null() || - ( - m_Match.begin() == m_End && - m_Match.end() == m_End - ); - } - - private: - // Attributes - match_type m_Match; - input_iterator_type m_End; - }; - - //! find iterator construction helper - /*! - * Construct a find iterator to iterate through the specified string - */ - template - inline find_iterator< - BOOST_STRING_TYPENAME range_iterator::type> - make_find_iterator( - RangeT& Collection, - FinderT Finder) - { - return find_iterator::type>( - Collection, Finder); - } - -// split iterator -----------------------------------------------// - - //! split_iterator - /*! - Split iterator encapsulates a Finder and allows - for incremental searching in a string. - Unlike the find iterator, split iterator iterates - through gaps between matches. - - Find iterator is a readable forward traversal iterator. - - Dereferencing the iterator yields an iterator_range delimiting - the current match. - */ - template - class split_iterator : - public iterator_facade< - split_iterator, - const iterator_range, - forward_traversal_tag >, - private detail::find_iterator_base - { - private: - // facade support - friend class ::boost::iterator_core_access; - - private: - // typedefs - - typedef detail::find_iterator_base base_type; - typedef BOOST_STRING_TYPENAME - base_type::input_iterator_type input_iterator_type; - typedef BOOST_STRING_TYPENAME - base_type::match_type match_type; - - public: - //! Default constructor - /*! - Construct null iterator. All null iterators are equal. - - \post eof()==true - */ - split_iterator() {} - //! Copy constructor - /*! - Construct a copy of the split_iterator - */ - split_iterator( const split_iterator& Other ) : - base_type(Other), - m_Match(Other.m_Match), - m_Next(Other.m_Next), - m_End(Other.m_End), - m_bEof(Other.m_bEof) - {} - - //! Constructor - /*! - Construct new split_iterator for a given finder - and a range. - */ - template - split_iterator( - IteratorT Begin, - IteratorT End, - FinderT Finder ) : - detail::find_iterator_base(Finder,0), - m_Match(Begin,Begin), - m_Next(Begin), - m_End(End), - m_bEof(false) - { - // force the correct behavior for empty sequences and yield at least one token - if(Begin!=End) - { - increment(); - } - } - //! Constructor - /*! - Construct new split_iterator for a given finder - and a collection. - */ - template - split_iterator( - RangeT& Col, - FinderT Finder ) : - detail::find_iterator_base(Finder,0), - m_bEof(false) - { - iterator_range::type> lit_col(::boost::as_literal(Col)); - m_Match=make_iterator_range(::boost::begin(lit_col), ::boost::begin(lit_col)); - m_Next=::boost::begin(lit_col); - m_End=::boost::end(lit_col); - - // force the correct behavior for empty sequences and yield at least one token - if(m_Next!=m_End) - { - increment(); - } - } - - - private: - // iterator operations - - // dereference - const match_type& dereference() const - { - return m_Match; - } - - // increment - void increment() - { - match_type FindMatch=this->do_find( m_Next, m_End ); - - if(FindMatch.begin()==m_End && FindMatch.end()==m_End) - { - if(m_Match.end()==m_End) - { - // Mark iterator as eof - m_bEof=true; - } - } - - m_Match=match_type( m_Next, FindMatch.begin() ); - m_Next=FindMatch.end(); - } - - // comparison - bool equal( const split_iterator& Other ) const - { - bool bEof=eof(); - bool bOtherEof=Other.eof(); - - return bEof || bOtherEof ? bEof==bOtherEof : - ( - m_Match==Other.m_Match && - m_Next==Other.m_Next && - m_End==Other.m_End - ); - } - - public: - // operations - - //! Eof check - /*! - Check the eof condition. Eof condition means that - there is nothing more to be searched i.e. find_iterator - is after the last match. - */ - bool eof() const - { - return this->is_null() || m_bEof; - } - - private: - // Attributes - match_type m_Match; - input_iterator_type m_Next; - input_iterator_type m_End; - bool m_bEof; - }; - - //! split iterator construction helper - /*! - * Construct a split iterator to iterate through the specified collection - */ - template - inline split_iterator< - BOOST_STRING_TYPENAME range_iterator::type> - make_split_iterator( - RangeT& Collection, - FinderT Finder) - { - return split_iterator::type>( - Collection, Finder); - } - - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::find_iterator; - using algorithm::make_find_iterator; - using algorithm::split_iterator; - using algorithm::make_split_iterator; - -} // namespace boost - - -#endif // BOOST_STRING_FIND_ITERATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/finder.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/finder.hpp deleted file mode 100644 index 93f7ec30..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/finder.hpp +++ /dev/null @@ -1,270 +0,0 @@ -// Boost string_algo library finder.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FINDER_HPP -#define BOOST_STRING_FINDER_HPP - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines Finder generators. Finder object is a functor which is able to - find a substring matching a specific criteria in the input. - Finders are used as a pluggable components for replace, find - and split facilities. This header contains generator functions - for finders provided in this library. -*/ - -namespace boost { - namespace algorithm { - -// Finder generators ------------------------------------------// - - //! "First" finder - /*! - Construct the \c first_finder. The finder searches for the first - occurrence of the string in a given input. - The result is given as an \c iterator_range delimiting the match. - - \param Search A substring to be searched for. - \param Comp An element comparison predicate - \return An instance of the \c first_finder object - */ - template - inline detail::first_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - is_equal> - first_finder( const RangeT& Search ) - { - return - detail::first_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - is_equal>( ::boost::as_literal(Search), is_equal() ) ; - } - - //! "First" finder - /*! - \overload - */ - template - inline detail::first_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - PredicateT> - first_finder( - const RangeT& Search, PredicateT Comp ) - { - return - detail::first_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - PredicateT>( ::boost::as_literal(Search), Comp ); - } - - //! "Last" finder - /*! - Construct the \c last_finder. The finder searches for the last - occurrence of the string in a given input. - The result is given as an \c iterator_range delimiting the match. - - \param Search A substring to be searched for. - \param Comp An element comparison predicate - \return An instance of the \c last_finder object - */ - template - inline detail::last_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - is_equal> - last_finder( const RangeT& Search ) - { - return - detail::last_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - is_equal>( ::boost::as_literal(Search), is_equal() ); - } - //! "Last" finder - /*! - \overload - */ - template - inline detail::last_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - PredicateT> - last_finder( const RangeT& Search, PredicateT Comp ) - { - return - detail::last_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - PredicateT>( ::boost::as_literal(Search), Comp ) ; - } - - //! "Nth" finder - /*! - Construct the \c nth_finder. The finder searches for the n-th (zero-indexed) - occurrence of the string in a given input. - The result is given as an \c iterator_range delimiting the match. - - \param Search A substring to be searched for. - \param Nth An index of the match to be find - \param Comp An element comparison predicate - \return An instance of the \c nth_finder object - */ - template - inline detail::nth_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - is_equal> - nth_finder( - const RangeT& Search, - int Nth) - { - return - detail::nth_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - is_equal>( ::boost::as_literal(Search), Nth, is_equal() ) ; - } - //! "Nth" finder - /*! - \overload - */ - template - inline detail::nth_finderF< - BOOST_STRING_TYPENAME range_const_iterator::type, - PredicateT> - nth_finder( - const RangeT& Search, - int Nth, - PredicateT Comp ) - { - return - detail::nth_finderF< - BOOST_STRING_TYPENAME - range_const_iterator::type, - PredicateT>( ::boost::as_literal(Search), Nth, Comp ); - } - - //! "Head" finder - /*! - Construct the \c head_finder. The finder returns a head of a given - input. The head is a prefix of a string up to n elements in - size. If an input has less then n elements, whole input is - considered a head. - The result is given as an \c iterator_range delimiting the match. - - \param N The size of the head - \return An instance of the \c head_finder object - */ - inline detail::head_finderF - head_finder( int N ) - { - return detail::head_finderF(N); - } - - //! "Tail" finder - /*! - Construct the \c tail_finder. The finder returns a tail of a given - input. The tail is a suffix of a string up to n elements in - size. If an input has less then n elements, whole input is - considered a head. - The result is given as an \c iterator_range delimiting the match. - - \param N The size of the head - \return An instance of the \c tail_finder object - */ - inline detail::tail_finderF - tail_finder( int N ) - { - return detail::tail_finderF(N); - } - - //! "Token" finder - /*! - Construct the \c token_finder. The finder searches for a token - specified by a predicate. It is similar to std::find_if - algorithm, with an exception that it return a range of - instead of a single iterator. - - If "compress token mode" is enabled, adjacent matching tokens are - concatenated into one match. Thus the finder can be used to - search for continuous segments of characters satisfying the - given predicate. - - The result is given as an \c iterator_range delimiting the match. - - \param Pred An element selection predicate - \param eCompress Compress flag - \return An instance of the \c token_finder object - */ - template< typename PredicateT > - inline detail::token_finderF - token_finder( - PredicateT Pred, - token_compress_mode_type eCompress=token_compress_off ) - { - return detail::token_finderF( Pred, eCompress ); - } - - //! "Range" finder - /*! - Construct the \c range_finder. The finder does not perform - any operation. It simply returns the given range for - any input. - - \param Begin Beginning of the range - \param End End of the range - \param Range The range. - \return An instance of the \c range_finger object - */ - template< typename ForwardIteratorT > - inline detail::range_finderF - range_finder( - ForwardIteratorT Begin, - ForwardIteratorT End ) - { - return detail::range_finderF( Begin, End ); - } - - //! "Range" finder - /*! - \overload - */ - template< typename ForwardIteratorT > - inline detail::range_finderF - range_finder( iterator_range Range ) - { - return detail::range_finderF( Range ); - } - - } // namespace algorithm - - // pull the names to the boost namespace - using algorithm::first_finder; - using algorithm::last_finder; - using algorithm::nth_finder; - using algorithm::head_finder; - using algorithm::tail_finder; - using algorithm::token_finder; - using algorithm::range_finder; - -} // namespace boost - - -#endif // BOOST_STRING_FINDER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/formatter.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/formatter.hpp deleted file mode 100644 index de8681bc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/formatter.hpp +++ /dev/null @@ -1,120 +0,0 @@ -// Boost string_algo library formatter.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_FORMATTER_HPP -#define BOOST_STRING_FORMATTER_HPP - -#include -#include -#include -#include - -#include - -/*! \file - Defines Formatter generators. Formatter is a functor which formats - a string according to given parameters. A Formatter works - in conjunction with a Finder. A Finder can provide additional information - for a specific Formatter. An example of such a cooperation is regex_finder - and regex_formatter. - - Formatters are used as pluggable components for replace facilities. - This header contains generator functions for the Formatters provided in this library. -*/ - -namespace boost { - namespace algorithm { - -// generic formatters ---------------------------------------------------------------// - - //! Constant formatter - /*! - Constructs a \c const_formatter. Const formatter always returns - the same value, regardless of the parameter. - - \param Format A predefined value used as a result for formatting - \return An instance of the \c const_formatter object. - */ - template - inline detail::const_formatF< - iterator_range< - BOOST_STRING_TYPENAME range_const_iterator::type> > - const_formatter(const RangeT& Format) - { - return detail::const_formatF< - iterator_range< - BOOST_STRING_TYPENAME range_const_iterator::type> >(::boost::as_literal(Format)); - } - - //! Identity formatter - /*! - Constructs an \c identity_formatter. Identity formatter always returns - the parameter. - - \return An instance of the \c identity_formatter object. - */ - template - inline detail::identity_formatF< - iterator_range< - BOOST_STRING_TYPENAME range_const_iterator::type> > - identity_formatter() - { - return detail::identity_formatF< - iterator_range< - BOOST_STRING_TYPENAME range_const_iterator::type> >(); - } - - //! Empty formatter - /*! - Constructs an \c empty_formatter. Empty formatter always returns an empty - sequence. - - \param Input container used to select a correct value_type for the - resulting empty_container<>. - \return An instance of the \c empty_formatter object. - */ - template - inline detail::empty_formatF< - BOOST_STRING_TYPENAME range_value::type> - empty_formatter(const RangeT&) - { - return detail::empty_formatF< - BOOST_STRING_TYPENAME range_value::type>(); - } - - //! Empty formatter - /*! - Constructs a \c dissect_formatter. Dissect formatter uses a specified finder - to extract a portion of the formatted sequence. The first finder's match is returned - as a result - - \param Finder a finder used to select a portion of the formatted sequence - \return An instance of the \c dissect_formatter object. - */ - template - inline detail::dissect_formatF< FinderT > - dissect_formatter(const FinderT& Finder) - { - return detail::dissect_formatF(Finder); - } - - - } // namespace algorithm - - // pull the names to the boost namespace - using algorithm::const_formatter; - using algorithm::identity_formatter; - using algorithm::empty_formatter; - using algorithm::dissect_formatter; - -} // namespace boost - - -#endif // BOOST_FORMATTER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/iter_find.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/iter_find.hpp deleted file mode 100644 index 10424abc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/iter_find.hpp +++ /dev/null @@ -1,193 +0,0 @@ -// Boost string_algo library iter_find.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_ITER_FIND_HPP -#define BOOST_STRING_ITER_FIND_HPP - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines generic split algorithms. Split algorithms can be - used to divide a sequence into several part according - to a given criteria. Result is given as a 'container - of containers' where elements are copies or references - to extracted parts. - - There are two algorithms provided. One iterates over matching - substrings, the other one over the gaps between these matches. -*/ - -namespace boost { - namespace algorithm { - -// iterate find ---------------------------------------------------// - - //! Iter find algorithm - /*! - This algorithm executes a given finder in iteration on the input, - until the end of input is reached, or no match is found. - Iteration is done using built-in find_iterator, so the real - searching is performed only when needed. - In each iteration new match is found and added to the result. - - \param Result A 'container container' to contain the result of search. - Both outer and inner container must have constructor taking a pair - of iterators as an argument. - Typical type of the result is - \c std::vector> - (each element of such a vector will container a range delimiting - a match). - \param Input A container which will be searched. - \param Finder A Finder object used for searching - \return A reference to the result - - \note Prior content of the result will be overwritten. - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename FinderT > - inline SequenceSequenceT& - iter_find( - SequenceSequenceT& Result, - RangeT& Input, - FinderT Finder ) - { - BOOST_CONCEPT_ASSERT(( - FinderConcept< - FinderT, - BOOST_STRING_TYPENAME range_iterator::type> - )); - - iterator_range::type> lit_input(::boost::as_literal(Input)); - - typedef BOOST_STRING_TYPENAME - range_iterator::type input_iterator_type; - typedef find_iterator find_iterator_type; - typedef detail::copy_iterator_rangeF< - BOOST_STRING_TYPENAME - range_value::type, - input_iterator_type> copy_range_type; - - input_iterator_type InputEnd=::boost::end(lit_input); - - typedef transform_iterator - transform_iter_type; - - transform_iter_type itBegin= - ::boost::make_transform_iterator( - find_iterator_type( ::boost::begin(lit_input), InputEnd, Finder ), - copy_range_type()); - - transform_iter_type itEnd= - ::boost::make_transform_iterator( - find_iterator_type(), - copy_range_type()); - - SequenceSequenceT Tmp(itBegin, itEnd); - - Result.swap(Tmp); - return Result; - } - -// iterate split ---------------------------------------------------// - - //! Split find algorithm - /*! - This algorithm executes a given finder in iteration on the input, - until the end of input is reached, or no match is found. - Iteration is done using built-in find_iterator, so the real - searching is performed only when needed. - Each match is used as a separator of segments. These segments are then - returned in the result. - - \param Result A 'container container' to contain the result of search. - Both outer and inner container must have constructor taking a pair - of iterators as an argument. - Typical type of the result is - \c std::vector> - (each element of such a vector will container a range delimiting - a match). - \param Input A container which will be searched. - \param Finder A finder object used for searching - \return A reference to the result - - \note Prior content of the result will be overwritten. - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename FinderT > - inline SequenceSequenceT& - iter_split( - SequenceSequenceT& Result, - RangeT& Input, - FinderT Finder ) - { - BOOST_CONCEPT_ASSERT(( - FinderConcept::type> - )); - - iterator_range::type> lit_input(::boost::as_literal(Input)); - - typedef BOOST_STRING_TYPENAME - range_iterator::type input_iterator_type; - typedef split_iterator find_iterator_type; - typedef detail::copy_iterator_rangeF< - BOOST_STRING_TYPENAME - range_value::type, - input_iterator_type> copy_range_type; - - input_iterator_type InputEnd=::boost::end(lit_input); - - typedef transform_iterator - transform_iter_type; - - transform_iter_type itBegin= - ::boost::make_transform_iterator( - find_iterator_type( ::boost::begin(lit_input), InputEnd, Finder ), - copy_range_type() ); - - transform_iter_type itEnd= - ::boost::make_transform_iterator( - find_iterator_type(), - copy_range_type() ); - - SequenceSequenceT Tmp(itBegin, itEnd); - - Result.swap(Tmp); - return Result; - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::iter_find; - using algorithm::iter_split; - -} // namespace boost - - -#endif // BOOST_STRING_ITER_FIND_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/join.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/join.hpp deleted file mode 100644 index b871eb44..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/join.hpp +++ /dev/null @@ -1,145 +0,0 @@ -// Boost string_algo library join.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_JOIN_HPP -#define BOOST_STRING_JOIN_HPP - -#include -#include -#include -#include - -/*! \file - Defines join algorithm. - - Join algorithm is a counterpart to split algorithms. - It joins strings from a 'list' by adding user defined separator. - Additionally there is a version that allows simple filtering - by providing a predicate. -*/ - -namespace boost { - namespace algorithm { - -// join --------------------------------------------------------------// - - //! Join algorithm - /*! - This algorithm joins all strings in a 'list' into one long string. - Segments are concatenated by given separator. - - \param Input A container that holds the input strings. It must be a container-of-containers. - \param Separator A string that will separate the joined segments. - \return Concatenated string. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T> - inline typename range_value::type - join( - const SequenceSequenceT& Input, - const Range1T& Separator) - { - // Define working types - typedef typename range_value::type ResultT; - typedef typename range_const_iterator::type InputIteratorT; - - // Parse input - InputIteratorT itBegin=::boost::begin(Input); - InputIteratorT itEnd=::boost::end(Input); - - // Construct container to hold the result - ResultT Result; - - // Append first element - if(itBegin!=itEnd) - { - detail::insert(Result, ::boost::end(Result), *itBegin); - ++itBegin; - } - - for(;itBegin!=itEnd; ++itBegin) - { - // Add separator - detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); - // Add element - detail::insert(Result, ::boost::end(Result), *itBegin); - } - - return Result; - } - -// join_if ----------------------------------------------------------// - - //! Conditional join algorithm - /*! - This algorithm joins all strings in a 'list' into one long string. - Segments are concatenated by given separator. Only segments that - satisfy the predicate will be added to the result. - - \param Input A container that holds the input strings. It must be a container-of-containers. - \param Separator A string that will separate the joined segments. - \param Pred A segment selection predicate - \return Concatenated string. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T, typename PredicateT> - inline typename range_value::type - join_if( - const SequenceSequenceT& Input, - const Range1T& Separator, - PredicateT Pred) - { - // Define working types - typedef typename range_value::type ResultT; - typedef typename range_const_iterator::type InputIteratorT; - - // Parse input - InputIteratorT itBegin=::boost::begin(Input); - InputIteratorT itEnd=::boost::end(Input); - - // Construct container to hold the result - ResultT Result; - - // Roll to the first element that will be added - while(itBegin!=itEnd && !Pred(*itBegin)) ++itBegin; - // Add this element - if(itBegin!=itEnd) - { - detail::insert(Result, ::boost::end(Result), *itBegin); - ++itBegin; - } - - for(;itBegin!=itEnd; ++itBegin) - { - if(Pred(*itBegin)) - { - // Add separator - detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); - // Add element - detail::insert(Result, ::boost::end(Result), *itBegin); - } - } - - return Result; - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::join; - using algorithm::join_if; - -} // namespace boost - - -#endif // BOOST_STRING_JOIN_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate.hpp deleted file mode 100644 index 0879829b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate.hpp +++ /dev/null @@ -1,475 +0,0 @@ -// Boost string_algo library predicate.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_PREDICATE_HPP -#define BOOST_STRING_PREDICATE_HPP - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file boost/algorithm/string/predicate.hpp - Defines string-related predicates. - The predicates determine whether a substring is contained in the input string - under various conditions: a string starts with the substring, ends with the - substring, simply contains the substring or if both strings are equal. - Additionaly the algorithm \c all() checks all elements of a container to satisfy a - condition. - - All predicates provide the strong exception guarantee. -*/ - -namespace boost { - namespace algorithm { - -// starts_with predicate -----------------------------------------------// - - //! 'Starts with' predicate - /*! - This predicate holds when the test string is a prefix of the Input. - In other words, if the input starts with the test. - When the optional predicate is specified, it is used for character-wise - comparison. - - \param Input An input sequence - \param Test A test sequence - \param Comp An element comparison predicate - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool starts_with( - const Range1T& Input, - const Range2T& Test, - PredicateT Comp) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - iterator_range::type> lit_test(::boost::as_literal(Test)); - - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator1T; - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator2T; - - Iterator1T InputEnd=::boost::end(lit_input); - Iterator2T TestEnd=::boost::end(lit_test); - - Iterator1T it=::boost::begin(lit_input); - Iterator2T pit=::boost::begin(lit_test); - for(; - it!=InputEnd && pit!=TestEnd; - ++it,++pit) - { - if( !(Comp(*it,*pit)) ) - return false; - } - - return pit==TestEnd; - } - - //! 'Starts with' predicate - /*! - \overload - */ - template - inline bool starts_with( - const Range1T& Input, - const Range2T& Test) - { - return ::boost::algorithm::starts_with(Input, Test, is_equal()); - } - - //! 'Starts with' predicate ( case insensitive ) - /*! - This predicate holds when the test string is a prefix of the Input. - In other words, if the input starts with the test. - Elements are compared case insensitively. - - \param Input An input sequence - \param Test A test sequence - \param Loc A locale used for case insensitive comparison - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool istarts_with( - const Range1T& Input, - const Range2T& Test, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::starts_with(Input, Test, is_iequal(Loc)); - } - - -// ends_with predicate -----------------------------------------------// - - //! 'Ends with' predicate - /*! - This predicate holds when the test string is a suffix of the Input. - In other words, if the input ends with the test. - When the optional predicate is specified, it is used for character-wise - comparison. - - - \param Input An input sequence - \param Test A test sequence - \param Comp An element comparison predicate - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool ends_with( - const Range1T& Input, - const Range2T& Test, - PredicateT Comp) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - iterator_range::type> lit_test(::boost::as_literal(Test)); - - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator1T; - typedef BOOST_STRING_TYPENAME boost::detail:: - iterator_traits::iterator_category category; - - return detail:: - ends_with_iter_select( - ::boost::begin(lit_input), - ::boost::end(lit_input), - ::boost::begin(lit_test), - ::boost::end(lit_test), - Comp, - category()); - } - - - //! 'Ends with' predicate - /*! - \overload - */ - template - inline bool ends_with( - const Range1T& Input, - const Range2T& Test) - { - return ::boost::algorithm::ends_with(Input, Test, is_equal()); - } - - //! 'Ends with' predicate ( case insensitive ) - /*! - This predicate holds when the test container is a suffix of the Input. - In other words, if the input ends with the test. - Elements are compared case insensitively. - - \param Input An input sequence - \param Test A test sequence - \param Loc A locale used for case insensitive comparison - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool iends_with( - const Range1T& Input, - const Range2T& Test, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::ends_with(Input, Test, is_iequal(Loc)); - } - -// contains predicate -----------------------------------------------// - - //! 'Contains' predicate - /*! - This predicate holds when the test container is contained in the Input. - When the optional predicate is specified, it is used for character-wise - comparison. - - \param Input An input sequence - \param Test A test sequence - \param Comp An element comparison predicate - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool contains( - const Range1T& Input, - const Range2T& Test, - PredicateT Comp) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - iterator_range::type> lit_test(::boost::as_literal(Test)); - - if (::boost::empty(lit_test)) - { - // Empty range is contained always - return true; - } - - // Use the temporary variable to make VACPP happy - bool bResult=(::boost::algorithm::first_finder(lit_test,Comp)(::boost::begin(lit_input), ::boost::end(lit_input))); - return bResult; - } - - //! 'Contains' predicate - /*! - \overload - */ - template - inline bool contains( - const Range1T& Input, - const Range2T& Test) - { - return ::boost::algorithm::contains(Input, Test, is_equal()); - } - - //! 'Contains' predicate ( case insensitive ) - /*! - This predicate holds when the test container is contained in the Input. - Elements are compared case insensitively. - - \param Input An input sequence - \param Test A test sequence - \param Loc A locale used for case insensitive comparison - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool icontains( - const Range1T& Input, - const Range2T& Test, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::contains(Input, Test, is_iequal(Loc)); - } - -// equals predicate -----------------------------------------------// - - //! 'Equals' predicate - /*! - This predicate holds when the test container is equal to the - input container i.e. all elements in both containers are same. - When the optional predicate is specified, it is used for character-wise - comparison. - - \param Input An input sequence - \param Test A test sequence - \param Comp An element comparison predicate - \return The result of the test - - \note This is a two-way version of \c std::equal algorithm - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool equals( - const Range1T& Input, - const Range2T& Test, - PredicateT Comp) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - iterator_range::type> lit_test(::boost::as_literal(Test)); - - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator1T; - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator2T; - - Iterator1T InputEnd=::boost::end(lit_input); - Iterator2T TestEnd=::boost::end(lit_test); - - Iterator1T it=::boost::begin(lit_input); - Iterator2T pit=::boost::begin(lit_test); - for(; - it!=InputEnd && pit!=TestEnd; - ++it,++pit) - { - if( !(Comp(*it,*pit)) ) - return false; - } - - return (pit==TestEnd) && (it==InputEnd); - } - - //! 'Equals' predicate - /*! - \overload - */ - template - inline bool equals( - const Range1T& Input, - const Range2T& Test) - { - return ::boost::algorithm::equals(Input, Test, is_equal()); - } - - //! 'Equals' predicate ( case insensitive ) - /*! - This predicate holds when the test container is equal to the - input container i.e. all elements in both containers are same. - Elements are compared case insensitively. - - \param Input An input sequence - \param Test A test sequence - \param Loc A locale used for case insensitive comparison - \return The result of the test - - \note This is a two-way version of \c std::equal algorithm - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool iequals( - const Range1T& Input, - const Range2T& Test, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::equals(Input, Test, is_iequal(Loc)); - } - -// lexicographical_compare predicate -----------------------------// - - //! Lexicographical compare predicate - /*! - This predicate is an overload of std::lexicographical_compare - for range arguments - - It check whether the first argument is lexicographically less - then the second one. - - If the optional predicate is specified, it is used for character-wise - comparison - - \param Arg1 First argument - \param Arg2 Second argument - \param Pred Comparison predicate - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool lexicographical_compare( - const Range1T& Arg1, - const Range2T& Arg2, - PredicateT Pred) - { - iterator_range::type> lit_arg1(::boost::as_literal(Arg1)); - iterator_range::type> lit_arg2(::boost::as_literal(Arg2)); - - return std::lexicographical_compare( - ::boost::begin(lit_arg1), - ::boost::end(lit_arg1), - ::boost::begin(lit_arg2), - ::boost::end(lit_arg2), - Pred); - } - - //! Lexicographical compare predicate - /*! - \overload - */ - template - inline bool lexicographical_compare( - const Range1T& Arg1, - const Range2T& Arg2) - { - return ::boost::algorithm::lexicographical_compare(Arg1, Arg2, is_less()); - } - - //! Lexicographical compare predicate (case-insensitive) - /*! - This predicate is an overload of std::lexicographical_compare - for range arguments. - It check whether the first argument is lexicographically less - then the second one. - Elements are compared case insensitively - - - \param Arg1 First argument - \param Arg2 Second argument - \param Loc A locale used for case insensitive comparison - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool ilexicographical_compare( - const Range1T& Arg1, - const Range2T& Arg2, - const std::locale& Loc=std::locale()) - { - return ::boost::algorithm::lexicographical_compare(Arg1, Arg2, is_iless(Loc)); - } - - -// all predicate -----------------------------------------------// - - //! 'All' predicate - /*! - This predicate holds it all its elements satisfy a given - condition, represented by the predicate. - - \param Input An input sequence - \param Pred A predicate - \return The result of the test - - \note This function provides the strong exception-safety guarantee - */ - template - inline bool all( - const RangeT& Input, - PredicateT Pred) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - - typedef BOOST_STRING_TYPENAME - range_const_iterator::type Iterator1T; - - Iterator1T InputEnd=::boost::end(lit_input); - for( Iterator1T It=::boost::begin(lit_input); It!=InputEnd; ++It) - { - if (!Pred(*It)) - return false; - } - - return true; - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::starts_with; - using algorithm::istarts_with; - using algorithm::ends_with; - using algorithm::iends_with; - using algorithm::contains; - using algorithm::icontains; - using algorithm::equals; - using algorithm::iequals; - using algorithm::all; - using algorithm::lexicographical_compare; - using algorithm::ilexicographical_compare; - -} // namespace boost - - -#endif // BOOST_STRING_PREDICATE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate_facade.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate_facade.hpp deleted file mode 100644 index a9753fc2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/predicate_facade.hpp +++ /dev/null @@ -1,42 +0,0 @@ -// Boost string_algo library predicate_facade.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_PREDICATE_FACADE_HPP -#define BOOST_STRING_PREDICATE_FACADE_HPP - -#include - -/* - \file boost/algorith/string/predicate_facade.hpp - This file contains predicate_facade definition. This template class is used - to identify classification predicates, so they can be combined using - composition operators. -*/ - -namespace boost { - namespace algorithm { - -// predicate facade ------------------------------------------------------// - - //! Predicate facade - /*! - This class allows to recognize classification - predicates, so that they can be combined using - composition operators. - Every classification predicate must be derived from this class. - */ - template - struct predicate_facade {}; - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_CLASSIFICATION_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex.hpp deleted file mode 100644 index a6c7c60a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex.hpp +++ /dev/null @@ -1,646 +0,0 @@ -// Boost string_algo library regex.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_REGEX_HPP -#define BOOST_STRING_REGEX_HPP - -#include -#include - -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -/*! \file - Defines regex variants of the algorithms. -*/ - -namespace boost { - namespace algorithm { - -// find_regex -----------------------------------------------// - - //! Find regex algorithm - /*! - Search for a substring matching the given regex in the input. - - \param Input A container which will be searched. - \param Rx A regular expression - \param Flags Regex options - \return - An \c iterator_range delimiting the match. - Returned iterator is either \c RangeT::iterator or - \c RangeT::const_iterator, depending on the constness of - the input parameter. - - \note This function provides the strong exception-safety guarantee - */ - template< - typename RangeT, - typename CharT, - typename RegexTraitsT> - inline iterator_range< - BOOST_STRING_TYPENAME range_iterator::type > - find_regex( - RangeT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - iterator_range::type> lit_input(::boost::as_literal(Input)); - - return ::boost::algorithm::regex_finder(Rx,Flags)( - ::boost::begin(lit_input), ::boost::end(lit_input) ); - } - -// replace_regex --------------------------------------------------------------------// - - //! Replace regex algorithm - /*! - Search for a substring matching given regex and format it with - the specified format. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Rx A regular expression - \param Format Regex format definition - \param Flags Regex options - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline OutputIteratorT replace_regex_copy( - OutputIteratorT Output, - const RangeT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - - //! Replace regex algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline SequenceT replace_regex_copy( - const SequenceT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - - //! Replace regex algorithm - /*! - Search for a substring matching given regex and format it with - the specified format. The input string is modified in-place. - - \param Input An input string - \param Rx A regular expression - \param Format Regex format definition - \param Flags Regex options - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline void replace_regex( - SequenceT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - -// replace_all_regex --------------------------------------------------------------------// - - //! Replace all regex algorithm - /*! - Format all substrings, matching given regex, with the specified format. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Rx A regular expression - \param Format Regex format definition - \param Flags Regex options - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline OutputIteratorT replace_all_regex_copy( - OutputIteratorT Output, - const RangeT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - - //! Replace all regex algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline SequenceT replace_all_regex_copy( - const SequenceT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - - //! Replace all regex algorithm - /*! - Format all substrings, matching given regex, with the specified format. - The input string is modified in-place. - - \param Input An input string - \param Rx A regular expression - \param Format Regex format definition - \param Flags Regex options - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT, - typename FormatStringTraitsT, typename FormatStringAllocatorT > - inline void replace_all_regex( - SequenceT& Input, - const basic_regex& Rx, - const std::basic_string& Format, - match_flag_type Flags=match_default | format_default ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::regex_formatter( Format, Flags ) ); - } - -// erase_regex --------------------------------------------------------------------// - - //! Erase regex algorithm - /*! - Remove a substring matching given regex from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Rx A regular expression - \param Flags Regex options - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename CharT, - typename RegexTraitsT > - inline OutputIteratorT erase_regex_copy( - OutputIteratorT Output, - const RangeT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase regex algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT > - inline SequenceT erase_regex_copy( - const SequenceT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase regex algorithm - /*! - Remove a substring matching given regex from the input. - The input string is modified in-place. - - \param Input An input string - \param Rx A regular expression - \param Flags Regex options - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT > - inline void erase_regex( - SequenceT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - -// erase_all_regex --------------------------------------------------------------------// - - //! Erase all regex algorithm - /*! - Erase all substrings, matching given regex, from the input. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Rx A regular expression - \param Flags Regex options - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename RangeT, - typename CharT, - typename RegexTraitsT > - inline OutputIteratorT erase_all_regex_copy( - OutputIteratorT Output, - const RangeT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase all regex algorithm - /*! - \overload - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT > - inline SequenceT erase_all_regex_copy( - const SequenceT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - - //! Erase all regex algorithm - /*! - Erase all substrings, matching given regex, from the input. - The input string is modified in-place. - - \param Input An input string - \param Rx A regular expression - \param Flags Regex options - */ - template< - typename SequenceT, - typename CharT, - typename RegexTraitsT> - inline void erase_all_regex( - SequenceT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::regex_finder( Rx, Flags ), - ::boost::algorithm::empty_formatter( Input ) ); - } - -// find_all_regex ------------------------------------------------------------------// - - //! Find all regex algorithm - /*! - This algorithm finds all substrings matching the give regex - in the input. - - Each part is copied and added as a new element to the output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> - - \param Result A container that can hold copies of references to the substrings. - \param Input A container which will be searched. - \param Rx A regular expression - \param Flags Regex options - \return A reference to the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename CharT, - typename RegexTraitsT > - inline SequenceSequenceT& find_all_regex( - SequenceSequenceT& Result, - const RangeT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::iter_find( - Result, - Input, - ::boost::algorithm::regex_finder(Rx,Flags) ); - } - -// split_regex ------------------------------------------------------------------// - - //! Split regex algorithm - /*! - Tokenize expression. This function is equivalent to C strtok. Input - sequence is split into tokens, separated by separators. Separator - is an every match of the given regex. - Each part is copied and added as a new element to the output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> - - \param Result A container that can hold copies of references to the substrings. - \param Input A container which will be searched. - \param Rx A regular expression - \param Flags Regex options - \return A reference to the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< - typename SequenceSequenceT, - typename RangeT, - typename CharT, - typename RegexTraitsT > - inline SequenceSequenceT& split_regex( - SequenceSequenceT& Result, - const RangeT& Input, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - return ::boost::algorithm::iter_split( - Result, - Input, - ::boost::algorithm::regex_finder(Rx,Flags) ); - } - -// join_if ------------------------------------------------------------------// - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - //! Conditional join algorithm - /*! - This algorithm joins all strings in a 'list' into one long string. - Segments are concatenated by given separator. Only segments that - match the given regular expression will be added to the result - - This is a specialization of join_if algorithm. - - \param Input A container that holds the input strings. It must be a container-of-containers. - \param Separator A string that will separate the joined segments. - \param Rx A regular expression - \param Flags Regex options - \return Concatenated string. - - \note This function provides the strong exception-safety guarantee - */ - template< - typename SequenceSequenceT, - typename Range1T, - typename CharT, - typename RegexTraitsT > - inline typename range_value::type - join_if( - const SequenceSequenceT& Input, - const Range1T& Separator, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - // Define working types - typedef typename range_value::type ResultT; - typedef typename range_const_iterator::type InputIteratorT; - - // Parse input - InputIteratorT itBegin=::boost::begin(Input); - InputIteratorT itEnd=::boost::end(Input); - - // Construct container to hold the result - ResultT Result; - - - // Roll to the first element that will be added - while( - itBegin!=itEnd && - !::boost::regex_match(::boost::begin(*itBegin), ::boost::end(*itBegin), Rx, Flags)) ++itBegin; - - // Add this element - if(itBegin!=itEnd) - { - detail::insert(Result, ::boost::end(Result), *itBegin); - ++itBegin; - } - - for(;itBegin!=itEnd; ++itBegin) - { - if(::boost::regex_match(::boost::begin(*itBegin), ::boost::end(*itBegin), Rx, Flags)) - { - // Add separator - detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); - // Add element - detail::insert(Result, ::boost::end(Result), *itBegin); - } - } - - return Result; - } - -#else // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - //! Conditional join algorithm - /*! - This algorithm joins all strings in a 'list' into one long string. - Segments are concatenated by given separator. Only segments that - match the given regular expression will be added to the result - - This is a specialization of join_if algorithm. - - \param Input A container that holds the input strings. It must be a container-of-containers. - \param Separator A string that will separate the joined segments. - \param Rx A regular expression - \param Flags Regex options - \return Concatenated string. - - \note This function provides the strong exception-safety guarantee - */ - template< - typename SequenceSequenceT, - typename Range1T, - typename CharT, - typename RegexTraitsT > - inline typename range_value::type - join_if_regex( - const SequenceSequenceT& Input, - const Range1T& Separator, - const basic_regex& Rx, - match_flag_type Flags=match_default ) - { - // Define working types - typedef typename range_value::type ResultT; - typedef typename range_const_iterator::type InputIteratorT; - - // Parse input - InputIteratorT itBegin=::boost::begin(Input); - InputIteratorT itEnd=::boost::end(Input); - - // Construct container to hold the result - ResultT Result; - - - // Roll to the first element that will be added - while( - itBegin!=itEnd && - !::boost::regex_match(::boost::begin(*itBegin), ::boost::end(*itBegin), Rx, Flags)) ++itBegin; - - // Add this element - if(itBegin!=itEnd) - { - detail::insert(Result, ::boost::end(Result), *itBegin); - ++itBegin; - } - - for(;itBegin!=itEnd; ++itBegin) - { - if(::boost::regex_match(::boost::begin(*itBegin), ::boost::end(*itBegin), Rx, Flags)) - { - // Add separator - detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); - // Add element - detail::insert(Result, ::boost::end(Result), *itBegin); - } - } - - return Result; - } - - -#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - } // namespace algorithm - - // pull names into the boost namespace - using algorithm::find_regex; - using algorithm::replace_regex; - using algorithm::replace_regex_copy; - using algorithm::replace_all_regex; - using algorithm::replace_all_regex_copy; - using algorithm::erase_regex; - using algorithm::erase_regex_copy; - using algorithm::erase_all_regex; - using algorithm::erase_all_regex_copy; - using algorithm::find_all_regex; - using algorithm::split_regex; - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - using algorithm::join_if; -#else // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - using algorithm::join_if_regex; -#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -} // namespace boost - - -#endif // BOOST_STRING_REGEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex_find_format.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex_find_format.hpp deleted file mode 100644 index 409afc2b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/regex_find_format.hpp +++ /dev/null @@ -1,90 +0,0 @@ -// Boost string_algo library regex_find_format.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_REGEX_FIND_FORMAT_HPP -#define BOOST_STRING_REGEX_FIND_FORMAT_HPP - -#include -#include -#include -#include - -/*! \file - Defines the \c regex_finder and \c regex_formatter generators. These two functors - are designed to work together. \c regex_formatter uses additional information - about a match contained in the regex_finder search result. -*/ - -namespace boost { - namespace algorithm { - -// regex_finder -----------------------------------------------// - - //! "Regex" finder - /*! - Construct the \c regex_finder. Finder uses the regex engine to search - for a match. - Result is given in \c regex_search_result. This is an extension - of the iterator_range. In addition it contains match results - from the \c regex_search algorithm. - - \param Rx A regular expression - \param MatchFlags Regex search options - \return An instance of the \c regex_finder object - */ - template< - typename CharT, - typename RegexTraitsT> - inline detail::find_regexF< basic_regex > - regex_finder( - const basic_regex& Rx, - match_flag_type MatchFlags=match_default ) - { - return detail:: - find_regexF< - basic_regex >( Rx, MatchFlags ); - } - -// regex_formater ---------------------------------------------// - - //! Regex formatter - /*! - Construct the \c regex_formatter. Regex formatter uses the regex engine to - format a match found by the \c regex_finder. - This formatted it designed to closely cooperate with \c regex_finder. - - \param Format Regex format definition - \param Flags Format flags - \return An instance of the \c regex_formatter functor - */ - template< - typename CharT, - typename TraitsT, typename AllocT > - inline detail::regex_formatF< std::basic_string< CharT, TraitsT, AllocT > > - regex_formatter( - const std::basic_string& Format, - match_flag_type Flags=format_default ) - { - return - detail::regex_formatF< std::basic_string >( - Format, - Flags ); - } - - } // namespace algorithm - - // pull the names to the boost namespace - using algorithm::regex_finder; - using algorithm::regex_formatter; - -} // namespace boost - - -#endif // BOOST_STRING_REGEX_FIND_FORMAT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/replace.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/replace.hpp deleted file mode 100644 index 0c04e47e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/replace.hpp +++ /dev/null @@ -1,928 +0,0 @@ -// Boost string_algo library replace.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_REPLACE_HPP -#define BOOST_STRING_REPLACE_HPP - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -/*! \file - Defines various replace algorithms. Each algorithm replaces - part(s) of the input according to set of searching and replace criteria. -*/ - -namespace boost { - namespace algorithm { - -// replace_range --------------------------------------------------------------------// - - //! Replace range algorithm - /*! - Replace the given range in the input string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param SearchRange A range in the input to be substituted - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT replace_range_copy( - OutputIteratorT Output, - const Range1T& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_const_iterator::type>& SearchRange, - const Range2T& Format) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::const_formatter(Format)); - } - - //! Replace range algorithm - /*! - \overload - */ - template - inline SequenceT replace_range_copy( - const SequenceT& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_const_iterator::type>& SearchRange, - const RangeT& Format) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::const_formatter(Format)); - } - - //! Replace range algorithm - /*! - Replace the given range in the input string. - The input sequence is modified in-place. - - \param Input An input string - \param SearchRange A range in the input to be substituted - \param Format A substitute string - */ - template - inline void replace_range( - SequenceT& Input, - const iterator_range< - BOOST_STRING_TYPENAME - range_iterator::type>& SearchRange, - const RangeT& Format) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::range_finder(SearchRange), - ::boost::algorithm::const_formatter(Format)); - } - -// replace_first --------------------------------------------------------------------// - - //! Replace first algorithm - /*! - Replace the first match of the search substring in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT replace_first_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace first algorithm - /*! - \overload - */ - template - inline SequenceT replace_first_copy( - const SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace first algorithm - /*! - replace the first match of the search substring in the input - with the format string. The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - */ - template - inline void replace_first( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_first ( case insensitive ) ---------------------------------------------// - - //! Replace first algorithm ( case insensitive ) - /*! - Replace the first match of the search substring in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT ireplace_first_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace first algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ireplace_first_copy( - const SequenceT& Input, - const Range2T& Search, - const Range1T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace first algorithm ( case insensitive ) - /*! - Replace the first match of the search substring in the input - with the format string. Input sequence is modified in-place. - Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - */ - template - inline void ireplace_first( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_last --------------------------------------------------------------------// - - //! Replace last algorithm - /*! - Replace the last match of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT replace_last_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace last algorithm - /*! - \overload - */ - template - inline SequenceT replace_last_copy( - const SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace last algorithm - /*! - Replace the last match of the search string in the input - with the format string. Input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - */ - template - inline void replace_last( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::last_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_last ( case insensitive ) -----------------------------------------------// - - //! Replace last algorithm ( case insensitive ) - /*! - Replace the last match of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT ireplace_last_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace last algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ireplace_last_copy( - const SequenceT& Input, - const Range1T& Search, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace last algorithm ( case insensitive ) - /*! - Replace the last match of the search string in the input - with the format string.The input sequence is modified in-place. - Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - \return A reference to the modified input - */ - template - inline void ireplace_last( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::last_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_nth --------------------------------------------------------------------// - - //! Replace nth algorithm - /*! - Replace an Nth (zero-indexed) match of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT replace_nth_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - int Nth, - const Range3T& Format ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace nth algorithm - /*! - \overload - */ - template - inline SequenceT replace_nth_copy( - const SequenceT& Input, - const Range1T& Search, - int Nth, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace nth algorithm - /*! - Replace an Nth (zero-indexed) match of the search string in the input - with the format string. Input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Format A substitute string - */ - template - inline void replace_nth( - SequenceT& Input, - const Range1T& Search, - int Nth, - const Range2T& Format ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::nth_finder(Search, Nth), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_nth ( case insensitive ) -----------------------------------------------// - - //! Replace nth algorithm ( case insensitive ) - /*! - Replace an Nth (zero-indexed) match of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT ireplace_nth_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - int Nth, - const Range3T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc) ), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace nth algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ireplace_nth_copy( - const SequenceT& Input, - const Range1T& Search, - int Nth, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace nth algorithm ( case insensitive ) - /*! - Replace an Nth (zero-indexed) match of the search string in the input - with the format string. Input sequence is modified in-place. - Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Nth An index of the match to be replaced. The index is 0-based. - For negative N, matches are counted from the end of string. - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - */ - template - inline void ireplace_nth( - SequenceT& Input, - const Range1T& Search, - int Nth, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::nth_finder(Search, Nth, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_all --------------------------------------------------------------------// - - //! Replace all algorithm - /*! - Replace all occurrences of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT replace_all_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace all algorithm - /*! - \overload - */ - template - inline SequenceT replace_all_copy( - const SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace all algorithm - /*! - Replace all occurrences of the search string in the input - with the format string. The input sequence is modified in-place. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \return A reference to the modified input - */ - template - inline void replace_all( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::first_finder(Search), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_all ( case insensitive ) -----------------------------------------------// - - //! Replace all algorithm ( case insensitive ) - /*! - Replace all occurrences of the search string in the input - with the format string. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - Searching is case insensitive. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T, - typename Range3T> - inline OutputIteratorT ireplace_all_copy( - OutputIteratorT Output, - const Range1T& Input, - const Range2T& Search, - const Range3T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_all_copy( - Output, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace all algorithm ( case insensitive ) - /*! - \overload - */ - template - inline SequenceT ireplace_all_copy( - const SequenceT& Input, - const Range1T& Search, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::find_format_all_copy( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace all algorithm ( case insensitive ) - /*! - Replace all occurrences of the search string in the input - with the format string.The input sequence is modified in-place. - Searching is case insensitive. - - \param Input An input string - \param Search A substring to be searched for - \param Format A substitute string - \param Loc A locale used for case insensitive comparison - */ - template - inline void ireplace_all( - SequenceT& Input, - const Range1T& Search, - const Range2T& Format, - const std::locale& Loc=std::locale() ) - { - ::boost::algorithm::find_format_all( - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc)), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_head --------------------------------------------------------------------// - - //! Replace head algorithm - /*! - Replace the head of the input with the given format string. - The head is a prefix of a string of given size. - If the sequence is shorter then required, whole string if - considered to be the head. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param N Length of the head. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT replace_head_copy( - OutputIteratorT Output, - const Range1T& Input, - int N, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace head algorithm - /*! - \overload - */ - template - inline SequenceT replace_head_copy( - const SequenceT& Input, - int N, - const RangeT& Format ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace head algorithm - /*! - Replace the head of the input with the given format string. - The head is a prefix of a string of given size. - If the sequence is shorter then required, the whole string is - considered to be the head. The input sequence is modified in-place. - - \param Input An input string - \param N Length of the head. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \param Format A substitute string - */ - template - inline void replace_head( - SequenceT& Input, - int N, - const RangeT& Format ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::head_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - -// replace_tail --------------------------------------------------------------------// - - //! Replace tail algorithm - /*! - Replace the tail of the input with the given format string. - The tail is a suffix of a string of given size. - If the sequence is shorter then required, whole string is - considered to be the tail. - The result is a modified copy of the input. It is returned as a sequence - or copied to the output iterator. - - \param Output An output iterator to which the result will be copied - \param Input An input string - \param N Length of the tail. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \param Format A substitute string - \return An output iterator pointing just after the last inserted character or - a modified copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template< - typename OutputIteratorT, - typename Range1T, - typename Range2T> - inline OutputIteratorT replace_tail_copy( - OutputIteratorT Output, - const Range1T& Input, - int N, - const Range2T& Format ) - { - return ::boost::algorithm::find_format_copy( - Output, - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace tail algorithm - /*! - \overload - */ - template - inline SequenceT replace_tail_copy( - const SequenceT& Input, - int N, - const RangeT& Format ) - { - return ::boost::algorithm::find_format_copy( - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - - //! Replace tail algorithm - /*! - Replace the tail of the input with the given format sequence. - The tail is a suffix of a string of given size. - If the sequence is shorter then required, the whole string is - considered to be the tail. The input sequence is modified in-place. - - \param Input An input string - \param N Length of the tail. - For N>=0, at most N characters are extracted. - For N<0, size(Input)-|N| characters are extracted. - \param Format A substitute string - */ - template - inline void replace_tail( - SequenceT& Input, - int N, - const RangeT& Format ) - { - ::boost::algorithm::find_format( - Input, - ::boost::algorithm::tail_finder(N), - ::boost::algorithm::const_formatter(Format) ); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::replace_range_copy; - using algorithm::replace_range; - using algorithm::replace_first_copy; - using algorithm::replace_first; - using algorithm::ireplace_first_copy; - using algorithm::ireplace_first; - using algorithm::replace_last_copy; - using algorithm::replace_last; - using algorithm::ireplace_last_copy; - using algorithm::ireplace_last; - using algorithm::replace_nth_copy; - using algorithm::replace_nth; - using algorithm::ireplace_nth_copy; - using algorithm::ireplace_nth; - using algorithm::replace_all_copy; - using algorithm::replace_all; - using algorithm::ireplace_all_copy; - using algorithm::ireplace_all; - using algorithm::replace_head_copy; - using algorithm::replace_head; - using algorithm::replace_tail_copy; - using algorithm::replace_tail; - -} // namespace boost - -#endif // BOOST_REPLACE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/sequence_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/sequence_traits.hpp deleted file mode 100644 index b1ac67e9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/sequence_traits.hpp +++ /dev/null @@ -1,193 +0,0 @@ -// Boost string_algo library sequence_traits.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_SEQUENCE_TRAITS_HPP -#define BOOST_STRING_SEQUENCE_TRAITS_HPP - -#include -#include -#include - -/*! \file - Traits defined in this header are used by various algorithms to achieve - better performance for specific containers. - Traits provide fail-safe defaults. If a container supports some of these - features, it is possible to specialize the specific trait for this container. - For lacking compilers, it is possible of define an override for a specific tester - function. - - Due to a language restriction, it is not currently possible to define specializations for - stl containers without including the corresponding header. To decrease the overhead - needed by this inclusion, user can selectively include a specialization - header for a specific container. They are located in boost/algorithm/string/stl - directory. Alternatively she can include boost/algorithm/string/std_collection_traits.hpp - header which contains specializations for all stl containers. -*/ - -namespace boost { - namespace algorithm { - -// sequence traits -----------------------------------------------// - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - //! Native replace tester - /*! - Declare an override of this tester function with return - type boost::string_algo::yes_type for a sequence with this property. - - \return yes_type if the container has basic_string like native replace - method. - */ - no_type has_native_replace_tester(...); - - //! Stable iterators tester - /*! - Declare an override of this tester function with return - type boost::string_algo::yes_type for a sequence with this property. - - \return yes_type if the sequence's insert/replace/erase methods do not invalidate - existing iterators. - */ - no_type has_stable_iterators_tester(...); - - //! const time insert tester - /*! - Declare an override of this tester function with return - type boost::string_algo::yes_type for a sequence with this property. - - \return yes_type if the sequence's insert method is working in constant time - */ - no_type has_const_time_insert_tester(...); - - //! const time erase tester - /*! - Declare an override of this tester function with return - type boost::string_algo::yes_type for a sequence with this property. - - \return yes_type if the sequence's erase method is working in constant time - */ - no_type has_const_time_erase_tester(...); - -#endif //BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - //! Native replace trait - /*! - This trait specifies that the sequence has \c std::string like replace method - */ - template< typename T > - class has_native_replace - { - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - private: - static T* t; - public: - BOOST_STATIC_CONSTANT(bool, value=( - sizeof(has_native_replace_tester(t))==sizeof(yes_type) ) ); -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - public: -# if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = false }; -# else - BOOST_STATIC_CONSTANT(bool, value=false); -# endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - - typedef mpl::bool_::value> type; - }; - - - //! Stable iterators trait - /*! - This trait specifies that the sequence has stable iterators. It means - that operations like insert/erase/replace do not invalidate iterators. - */ - template< typename T > - class has_stable_iterators - { -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - private: - static T* t; - public: - BOOST_STATIC_CONSTANT(bool, value=( - sizeof(has_stable_iterators_tester(t))==sizeof(yes_type) ) ); -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - public: -# if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = false }; -# else - BOOST_STATIC_CONSTANT(bool, value=false); -# endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - typedef mpl::bool_::value> type; - }; - - - //! Const time insert trait - /*! - This trait specifies that the sequence's insert method has - constant time complexity. - */ - template< typename T > - class has_const_time_insert - { -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - private: - static T* t; - public: - BOOST_STATIC_CONSTANT(bool, value=( - sizeof(has_const_time_insert_tester(t))==sizeof(yes_type) ) ); -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - public: -# if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = false }; -# else - BOOST_STATIC_CONSTANT(bool, value=false); -# endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - typedef mpl::bool_::value> type; - }; - - - //! Const time erase trait - /*! - This trait specifies that the sequence's erase method has - constant time complexity. - */ - template< typename T > - class has_const_time_erase - { -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - private: - static T* t; - public: - BOOST_STATIC_CONSTANT(bool, value=( - sizeof(has_const_time_erase_tester(t))==sizeof(yes_type) ) ); -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - public: -# if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = false }; -# else - BOOST_STATIC_CONSTANT(bool, value=false); -# endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - typedef mpl::bool_::value> type; - }; - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_SEQUENCE_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/split.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/split.hpp deleted file mode 100644 index cae712c0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/split.hpp +++ /dev/null @@ -1,163 +0,0 @@ -// Boost string_algo library split.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2006. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_SPLIT_HPP -#define BOOST_STRING_SPLIT_HPP - -#include - -#include -#include -#include - -/*! \file - Defines basic split algorithms. - Split algorithms can be used to divide a string - into several parts according to given criteria. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> -*/ - -namespace boost { - namespace algorithm { - -// find_all ------------------------------------------------------------// - - //! Find all algorithm - /*! - This algorithm finds all occurrences of the search string - in the input. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Search A substring to be searched for. - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T, typename Range2T > - inline SequenceSequenceT& find_all( - SequenceSequenceT& Result, - Range1T& Input, - const Range2T& Search) - { - return ::boost::algorithm::iter_find( - Result, - Input, - ::boost::algorithm::first_finder(Search) ); - } - - //! Find all algorithm ( case insensitive ) - /*! - This algorithm finds all occurrences of the search string - in the input. - Each part is copied and added as a new element to the - output container. Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> - - Searching is case insensitive. - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Search A substring to be searched for. - \param Loc A locale used for case insensitive comparison - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename Range1T, typename Range2T > - inline SequenceSequenceT& ifind_all( - SequenceSequenceT& Result, - Range1T& Input, - const Range2T& Search, - const std::locale& Loc=std::locale() ) - { - return ::boost::algorithm::iter_find( - Result, - Input, - ::boost::algorithm::first_finder(Search, is_iequal(Loc) ) ); - } - - -// tokenize -------------------------------------------------------------// - - //! Split algorithm - /*! - Tokenize expression. This function is equivalent to C strtok. Input - sequence is split into tokens, separated by separators. Separators - are given by means of the predicate. - - Each part is copied and added as a new element to the - output container. - Thus the result container must be able to hold copies - of the matches (in a compatible structure like std::string) or - a reference to it (e.g. using the iterator range class). - Examples of such a container are \c std::vector - or \c std::list> - - \param Result A container that can hold copies of references to the substrings - \param Input A container which will be searched. - \param Pred A predicate to identify separators. This predicate is - supposed to return true if a given element is a separator. - \param eCompress If eCompress argument is set to token_compress_on, adjacent - separators are merged together. Otherwise, every two separators - delimit a token. - \return A reference the result - - \note Prior content of the result will be overwritten. - - \note This function provides the strong exception-safety guarantee - */ - template< typename SequenceSequenceT, typename RangeT, typename PredicateT > - inline SequenceSequenceT& split( - SequenceSequenceT& Result, - RangeT& Input, - PredicateT Pred, - token_compress_mode_type eCompress=token_compress_off ) - { - return ::boost::algorithm::iter_split( - Result, - Input, - ::boost::algorithm::token_finder( Pred, eCompress ) ); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::find_all; - using algorithm::ifind_all; - using algorithm::split; - -} // namespace boost - - -#endif // BOOST_STRING_SPLIT_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/list_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/list_traits.hpp deleted file mode 100644 index ce2379d8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/list_traits.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// Boost string_algo library list_traits.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_STD_LIST_TRAITS_HPP -#define BOOST_STRING_STD_LIST_TRAITS_HPP - -#include -#include -#include - -namespace boost { - namespace algorithm { - -// std::list<> traits -----------------------------------------------// - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // stable iterators tester - template - yes_type has_stable_iterators_tester( const ::std::list* ); - - // const time insert tester - template - yes_type has_const_time_insert_tester( const ::std::list* ); - - // const time erase tester - template - yes_type has_const_time_erase_tester( const ::std::list* ); - - -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // stable iterators trait - template - class has_stable_iterators< ::std::list > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; - - // const time insert trait - template - class has_const_time_insert< ::std::list > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; - - // const time erase trait - template - class has_const_time_erase< ::std::list > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; -#endif - - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_STD_LIST_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/slist_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/slist_traits.hpp deleted file mode 100644 index 7b915a3d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/slist_traits.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// Boost string_algo library slist_traits.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_STD_SLIST_TRAITS_HPP -#define BOOST_STRING_STD_SLIST_TRAITS_HPP - -#include -#include -#include BOOST_SLIST_HEADER -#include - -namespace boost { - namespace algorithm { - -// SGI's std::slist<> traits -----------------------------------------------// - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // stable iterators tester - template - yes_type has_stable_iterators_tester( const BOOST_STD_EXTENSION_NAMESPACE::slist* ); - - // const time insert tester - template - yes_type has_const_time_insert_tester( const BOOST_STD_EXTENSION_NAMESPACE::slist* ); - - // const time erase tester - template - yes_type has_const_time_erase_tester( const BOOST_STD_EXTENSION_NAMESPACE::slist* ); - -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // stable iterators trait - template - class has_stable_iterators< BOOST_STD_EXTENSION_NAMESPACE::slist > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; - - // const time insert trait - template - class has_const_time_insert< BOOST_STD_EXTENSION_NAMESPACE::slist > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; - - // const time erase trait - template - class has_const_time_erase< BOOST_STD_EXTENSION_NAMESPACE::slist > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true }; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - typedef mpl::bool_::value> type; - }; -#endif - - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_STD_LIST_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/string_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/string_traits.hpp deleted file mode 100644 index c466d26b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std/string_traits.hpp +++ /dev/null @@ -1,52 +0,0 @@ -// Boost string_algo library string_traits.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_STD_STRING_TRAITS_HPP -#define BOOST_STRING_STD_STRING_TRAITS_HPP - -#include -#include -#include - -namespace boost { - namespace algorithm { - -// std::basic_string<> traits -----------------------------------------------// - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // native replace tester - template - yes_type has_native_replace_tester( const std::basic_string* ); - -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // native replace trait - template - class has_native_replace< std::basic_string > - { - public: -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - enum { value = true } ; -#else - BOOST_STATIC_CONSTANT(bool, value=true); -#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 ) - - typedef mpl::bool_::value> type; - }; - - -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_LIST_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std_containers_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std_containers_traits.hpp deleted file mode 100644 index 3f02246f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/std_containers_traits.hpp +++ /dev/null @@ -1,26 +0,0 @@ -// Boost string_algo library std_containers_traits.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_STD_CONTAINERS_TRAITS_HPP -#define BOOST_STRING_STD_CONTAINERS_TRAITS_HPP - -/*!\file - This file includes sequence traits for stl containers. -*/ - -#include -#include -#include - -#ifdef BOOST_HAS_SLIST -# include -#endif - -#endif // BOOST_STRING_STD_CONTAINERS_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/trim.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/trim.hpp deleted file mode 100644 index e740d57d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/trim.hpp +++ /dev/null @@ -1,398 +0,0 @@ -// Boost string_algo library trim.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_TRIM_HPP -#define BOOST_STRING_TRIM_HPP - -#include - -#include -#include -#include -#include -#include - -#include -#include -#include - -/*! \file - Defines trim algorithms. - Trim algorithms are used to remove trailing and leading spaces from a - sequence (string). Space is recognized using given locales. - - Parametric (\c _if) variants use a predicate (functor) to select which characters - are to be trimmed.. - Functions take a selection predicate as a parameter, which is used to determine - whether a character is a space. Common predicates are provided in classification.hpp header. - -*/ - -namespace boost { - namespace algorithm { - - // left trim -----------------------------------------------// - - - //! Left trim - parametric - /*! - Remove all leading spaces from the input. - The supplied predicate is used to determine which characters are considered spaces. - The result is a trimmed copy of the input. It is returned as a sequence - or copied to the output iterator - - \param Output An output iterator to which the result will be copied - \param Input An input range - \param IsSpace A unary predicate identifying spaces - \return - An output iterator pointing just after the last inserted character or - a copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template - inline OutputIteratorT trim_left_copy_if( - OutputIteratorT Output, - const RangeT& Input, - PredicateT IsSpace) - { - iterator_range::type> lit_range(::boost::as_literal(Input)); - - std::copy( - ::boost::algorithm::detail::trim_begin( - ::boost::begin(lit_range), - ::boost::end(lit_range), - IsSpace ), - ::boost::end(lit_range), - Output); - - return Output; - } - - //! Left trim - parametric - /*! - \overload - */ - template - inline SequenceT trim_left_copy_if(const SequenceT& Input, PredicateT IsSpace) - { - return SequenceT( - ::boost::algorithm::detail::trim_begin( - ::boost::begin(Input), - ::boost::end(Input), - IsSpace ), - ::boost::end(Input)); - } - - //! Left trim - parametric - /*! - Remove all leading spaces from the input. - The result is a trimmed copy of the input. - - \param Input An input sequence - \param Loc a locale used for 'space' classification - \return A trimmed copy of the input - - \note This function provides the strong exception-safety guarantee - */ - template - inline SequenceT trim_left_copy(const SequenceT& Input, const std::locale& Loc=std::locale()) - { - return - ::boost::algorithm::trim_left_copy_if( - Input, - is_space(Loc)); - } - - //! Left trim - /*! - Remove all leading spaces from the input. The supplied predicate is - used to determine which characters are considered spaces. - The input sequence is modified in-place. - - \param Input An input sequence - \param IsSpace A unary predicate identifying spaces - */ - template - inline void trim_left_if(SequenceT& Input, PredicateT IsSpace) - { - Input.erase( - ::boost::begin(Input), - ::boost::algorithm::detail::trim_begin( - ::boost::begin(Input), - ::boost::end(Input), - IsSpace)); - } - - //! Left trim - /*! - Remove all leading spaces from the input. - The Input sequence is modified in-place. - - \param Input An input sequence - \param Loc A locale used for 'space' classification - */ - template - inline void trim_left(SequenceT& Input, const std::locale& Loc=std::locale()) - { - ::boost::algorithm::trim_left_if( - Input, - is_space(Loc)); - } - - // right trim -----------------------------------------------// - - //! Right trim - parametric - /*! - Remove all trailing spaces from the input. - The supplied predicate is used to determine which characters are considered spaces. - The result is a trimmed copy of the input. It is returned as a sequence - or copied to the output iterator - - \param Output An output iterator to which the result will be copied - \param Input An input range - \param IsSpace A unary predicate identifying spaces - \return - An output iterator pointing just after the last inserted character or - a copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template - inline OutputIteratorT trim_right_copy_if( - OutputIteratorT Output, - const RangeT& Input, - PredicateT IsSpace ) - { - iterator_range::type> lit_range(::boost::as_literal(Input)); - - std::copy( - ::boost::begin(lit_range), - ::boost::algorithm::detail::trim_end( - ::boost::begin(lit_range), - ::boost::end(lit_range), - IsSpace ), - Output ); - - return Output; - } - - //! Right trim - parametric - /*! - \overload - */ - template - inline SequenceT trim_right_copy_if(const SequenceT& Input, PredicateT IsSpace) - { - return SequenceT( - ::boost::begin(Input), - ::boost::algorithm::detail::trim_end( - ::boost::begin(Input), - ::boost::end(Input), - IsSpace) - ); - } - - //! Right trim - /*! - Remove all trailing spaces from the input. - The result is a trimmed copy of the input - - \param Input An input sequence - \param Loc A locale used for 'space' classification - \return A trimmed copy of the input - - \note This function provides the strong exception-safety guarantee - */ - template - inline SequenceT trim_right_copy(const SequenceT& Input, const std::locale& Loc=std::locale()) - { - return - ::boost::algorithm::trim_right_copy_if( - Input, - is_space(Loc)); - } - - - //! Right trim - parametric - /*! - Remove all trailing spaces from the input. - The supplied predicate is used to determine which characters are considered spaces. - The input sequence is modified in-place. - - \param Input An input sequence - \param IsSpace A unary predicate identifying spaces - */ - template - inline void trim_right_if(SequenceT& Input, PredicateT IsSpace) - { - Input.erase( - ::boost::algorithm::detail::trim_end( - ::boost::begin(Input), - ::boost::end(Input), - IsSpace ), - ::boost::end(Input) - ); - } - - - //! Right trim - /*! - Remove all trailing spaces from the input. - The input sequence is modified in-place. - - \param Input An input sequence - \param Loc A locale used for 'space' classification - */ - template - inline void trim_right(SequenceT& Input, const std::locale& Loc=std::locale()) - { - ::boost::algorithm::trim_right_if( - Input, - is_space(Loc) ); - } - - // both side trim -----------------------------------------------// - - //! Trim - parametric - /*! - Remove all trailing and leading spaces from the input. - The supplied predicate is used to determine which characters are considered spaces. - The result is a trimmed copy of the input. It is returned as a sequence - or copied to the output iterator - - \param Output An output iterator to which the result will be copied - \param Input An input range - \param IsSpace A unary predicate identifying spaces - \return - An output iterator pointing just after the last inserted character or - a copy of the input - - \note The second variant of this function provides the strong exception-safety guarantee - */ - template - inline OutputIteratorT trim_copy_if( - OutputIteratorT Output, - const RangeT& Input, - PredicateT IsSpace) - { - iterator_range::type> lit_range(::boost::as_literal(Input)); - - BOOST_STRING_TYPENAME - range_const_iterator::type TrimEnd= - ::boost::algorithm::detail::trim_end( - ::boost::begin(lit_range), - ::boost::end(lit_range), - IsSpace); - - std::copy( - detail::trim_begin( - ::boost::begin(lit_range), TrimEnd, IsSpace), - TrimEnd, - Output - ); - - return Output; - } - - //! Trim - parametric - /*! - \overload - */ - template - inline SequenceT trim_copy_if(const SequenceT& Input, PredicateT IsSpace) - { - BOOST_STRING_TYPENAME - range_const_iterator::type TrimEnd= - ::boost::algorithm::detail::trim_end( - ::boost::begin(Input), - ::boost::end(Input), - IsSpace); - - return SequenceT( - detail::trim_begin( - ::boost::begin(Input), - TrimEnd, - IsSpace), - TrimEnd - ); - } - - //! Trim - /*! - Remove all leading and trailing spaces from the input. - The result is a trimmed copy of the input - - \param Input An input sequence - \param Loc A locale used for 'space' classification - \return A trimmed copy of the input - - \note This function provides the strong exception-safety guarantee - */ - template - inline SequenceT trim_copy( const SequenceT& Input, const std::locale& Loc=std::locale() ) - { - return - ::boost::algorithm::trim_copy_if( - Input, - is_space(Loc) ); - } - - //! Trim - /*! - Remove all leading and trailing spaces from the input. - The supplied predicate is used to determine which characters are considered spaces. - The input sequence is modified in-place. - - \param Input An input sequence - \param IsSpace A unary predicate identifying spaces - */ - template - inline void trim_if(SequenceT& Input, PredicateT IsSpace) - { - ::boost::algorithm::trim_right_if( Input, IsSpace ); - ::boost::algorithm::trim_left_if( Input, IsSpace ); - } - - //! Trim - /*! - Remove all leading and trailing spaces from the input. - The input sequence is modified in-place. - - \param Input An input sequence - \param Loc A locale used for 'space' classification - */ - template - inline void trim(SequenceT& Input, const std::locale& Loc=std::locale()) - { - ::boost::algorithm::trim_if( - Input, - is_space( Loc ) ); - } - - } // namespace algorithm - - // pull names to the boost namespace - using algorithm::trim_left; - using algorithm::trim_left_if; - using algorithm::trim_left_copy; - using algorithm::trim_left_copy_if; - using algorithm::trim_right; - using algorithm::trim_right_if; - using algorithm::trim_right_copy; - using algorithm::trim_right_copy_if; - using algorithm::trim; - using algorithm::trim_if; - using algorithm::trim_copy; - using algorithm::trim_copy_if; - -} // namespace boost - -#endif // BOOST_STRING_TRIM_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/yes_no_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/yes_no_type.hpp deleted file mode 100644 index b76cc6c1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string/yes_no_type.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// Boost string_algo library yes_no_type.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_YES_NO_TYPE_DETAIL_HPP -#define BOOST_STRING_YES_NO_TYPE_DETAIL_HPP - -namespace boost { - namespace algorithm { - - // taken from boost mailing-list - // when yes_no_type will become officially - // a part of boost distribution, this header - // will be deprecated - template struct size_descriptor - { - typedef char (& type)[I]; - }; - - typedef size_descriptor<1>::type yes_type; - typedef size_descriptor<2>::type no_type; - - } // namespace algorithm -} // namespace boost - - -#endif // BOOST_STRING_YES_NO_TYPE_DETAIL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string_regex.hpp b/third_party/ycmd/cpp/BoostParts/boost/algorithm/string_regex.hpp deleted file mode 100644 index 791aa184..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/algorithm/string_regex.hpp +++ /dev/null @@ -1,23 +0,0 @@ -// Boost string_algo library string_regex.hpp header file ---------------------------// - -// Copyright Pavol Droba 2002-2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for updates, documentation, and revision history. - -#ifndef BOOST_STRING_ALGO_REGEX_HPP -#define BOOST_STRING_ALGO_REGEX_HPP - -/*! \file - Cumulative include for string_algo library. - In addition to string.hpp contains also regex-related stuff. -*/ - -#include -#include -#include - -#endif // BOOST_STRING_ALGO_REGEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/aligned_storage.hpp b/third_party/ycmd/cpp/BoostParts/boost/aligned_storage.hpp deleted file mode 100644 index ce277ab7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/aligned_storage.hpp +++ /dev/null @@ -1,181 +0,0 @@ -//----------------------------------------------------------------------------- -// boost aligned_storage.hpp header file -// See http://www.boost.org for updates, documentation, and revision history. -//----------------------------------------------------------------------------- -// -// Copyright (c) 2002-2003 -// Eric Friedman, Itay Maman -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_ALIGNED_STORAGE_HPP -#define BOOST_ALIGNED_STORAGE_HPP - -#include // for std::size_t - -#include "boost/config.hpp" -#include "boost/detail/workaround.hpp" -#include "boost/type_traits/alignment_of.hpp" -#include "boost/type_traits/type_with_alignment.hpp" -#include "boost/type_traits/is_pod.hpp" - -#include "boost/mpl/eval_if.hpp" -#include "boost/mpl/identity.hpp" - -#include "boost/type_traits/detail/bool_trait_def.hpp" - -namespace boost { - -namespace detail { namespace aligned_storage { - -BOOST_STATIC_CONSTANT( - std::size_t - , alignment_of_max_align = ::boost::alignment_of::value - ); - -// -// To be TR1 conforming this must be a POD type: -// -template < - std::size_t size_ - , std::size_t alignment_ -> -struct aligned_storage_imp -{ - union data_t - { - char buf[size_]; - - typename mpl::eval_if_c< - alignment_ == std::size_t(-1) - , mpl::identity - , type_with_alignment - >::type align_; - } data_; - void* address() const { return const_cast(this); } -}; - -template< std::size_t alignment_ > -struct aligned_storage_imp<0u,alignment_> -{ - /* intentionally empty */ - void* address() const { return 0; } -}; - -}} // namespace detail::aligned_storage - -template < - std::size_t size_ - , std::size_t alignment_ = std::size_t(-1) -> -class aligned_storage : -#ifndef __BORLANDC__ - private -#else - public -#endif - detail::aligned_storage::aligned_storage_imp -{ - -public: // constants - - typedef detail::aligned_storage::aligned_storage_imp type; - - BOOST_STATIC_CONSTANT( - std::size_t - , size = size_ - ); - BOOST_STATIC_CONSTANT( - std::size_t - , alignment = ( - alignment_ == std::size_t(-1) - ? ::boost::detail::aligned_storage::alignment_of_max_align - : alignment_ - ) - ); - -#if defined(__GNUC__) &&\ - (__GNUC__ > 3) ||\ - (__GNUC__ == 3 && (__GNUC_MINOR__ > 2 ||\ - (__GNUC_MINOR__ == 2 && __GNUC_PATCHLEVEL__ >=3))) - -private: // noncopyable - - aligned_storage(const aligned_storage&); - aligned_storage& operator=(const aligned_storage&); - -#else // gcc less than 3.2.3 - -public: // _should_ be noncopyable, but GCC compiler emits error - - aligned_storage(const aligned_storage&); - aligned_storage& operator=(const aligned_storage&); - -#endif // gcc < 3.2.3 workaround - -public: // structors - - aligned_storage() - { - } - - ~aligned_storage() - { - } - -public: // accessors - - void* address() - { - return static_cast(this)->address(); - } - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) - - const void* address() const - { - return static_cast(this)->address(); - } - -#else // MSVC6 - - const void* address() const; - -#endif // MSVC6 workaround - -}; - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - -// MSVC6 seems not to like inline functions with const void* returns, so we -// declare the following here: - -template -const void* aligned_storage::address() const -{ - return const_cast< aligned_storage* >(this)->address(); -} - -#endif // MSVC6 workaround - -#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -// -// Make sure that is_pod recognises aligned_storage<>::type -// as a POD (Note that aligned_storage<> itself is not a POD): -// -template -struct is_pod > - BOOST_TT_AUX_BOOL_C_BASE(true) -{ - BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL(true) -}; -#endif - - -} // namespace boost - -#include "boost/type_traits/detail/bool_trait_undef.hpp" - -#endif // BOOST_ALIGNED_STORAGE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/add_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/add_facet.hpp deleted file mode 100644 index 6bafe9bd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/add_facet.hpp +++ /dev/null @@ -1,55 +0,0 @@ -#ifndef BOOST_ARCHIVE_ADD_FACET_HPP -#define BOOST_ARCHIVE_ADD_FACET_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// add_facet.hpp - -// (C) Copyright 2003 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include - -// does STLport uses native STL for locales? -#if (defined(__SGI_STL_PORT)&& defined(_STLP_NO_OWN_IOSTREAMS)) -// and this native STL lib is old Dinkumware (has not defined _CPPLIB_VER) -# if (defined(_YVALS) && !defined(__IBMCPP__)) || !defined(_CPPLIB_VER) -# define BOOST_ARCHIVE_OLD_DINKUMWARE_BENEATH_STLPORT -# endif -#endif - -namespace boost { -namespace archive { - -template -inline std::locale * -add_facet(const std::locale &l, Facet * f){ - return - #if defined BOOST_ARCHIVE_OLD_DINKUMWARE_BENEATH_STLPORT - // std namespace used for native locale - new std::locale(std::_Addfac(l, f)); - #elif BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) // old Dinkumwar - // std namespace used for native locale - new std::locale(std::_Addfac(l, f)); - #else - // standard compatible - new std::locale(l, f); - #endif -} - -} // namespace archive -} // namespace boost - -#undef BOOST_ARCHIVE_OLD_DINKUMWARE_BENEATH_STLPORT - -#endif // BOOST_ARCHIVE_ADD_FACET_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/archive_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/archive_exception.hpp deleted file mode 100644 index e27807bc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/archive_exception.hpp +++ /dev/null @@ -1,99 +0,0 @@ -#ifndef BOOST_ARCHIVE_ARCHIVE_EXCEPTION_HPP -#define BOOST_ARCHIVE_ARCHIVE_EXCEPTION_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// archive/archive_exception.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include - -#include -#include -#include - -// note: the only reason this is in here is that windows header -// includes #define exception_code _exception_code (arrrgghhhh!). -// the most expedient way to address this is be sure that this -// header is always included whenever this header file is included. -#if defined(BOOST_WINDOWS) -#include -#endif - -#include // must be the last header - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// exceptions thrown by archives -// -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) archive_exception : - public virtual std::exception -{ -protected: - char m_buffer[128]; -public: - typedef enum { - no_exception, // initialized without code - other_exception, // any excepton not listed below - unregistered_class, // attempt to serialize a pointer of an - // an unregistered class - invalid_signature, // first line of archive does not contain - // expected string - unsupported_version,// archive created with library version - // subsequent to this one - pointer_conflict, // an attempt has been made to directly - // serialize an object which has - // already been serialzed through a pointer. - // Were this permited, the archive load would result - // in the creation of an extra copy of the obect. - incompatible_native_format, // attempt to read native binary format - // on incompatible platform - array_size_too_short,// array being loaded doesn't fit in array allocated - input_stream_error, // error on input stream - invalid_class_name, // class name greater than the maximum permitted. - // most likely a corrupted archive or an attempt - // to insert virus via buffer overrun method. - unregistered_cast, // base - derived relationship not registered with - // void_cast_register - unsupported_class_version, // type saved with a version # greater than the - // one used by the program. This indicates that the proggram - // needs to be rebuilt. - multiple_code_instantiation, // code for implementing serialization for some - // type has been instantiated in more than one module. - output_stream_error // error on input stream - } exception_code; -public: - exception_code code; - archive_exception( - exception_code c, - const char * e1 = NULL, - const char * e2 = NULL - ); - virtual ~archive_exception() throw(); - virtual const char *what() const throw(); -protected: - unsigned int - append(unsigned int l, const char * a); - archive_exception(); -}; - -}// namespace archive -}// namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif //BOOST_ARCHIVE_ARCHIVE_EXCEPTION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_archive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_archive.hpp deleted file mode 100644 index c5ac8808..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_archive.hpp +++ /dev/null @@ -1,301 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_ARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_ARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_archive.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include // size_t -#include -#include - -#include -#include // must be the last header - -namespace boost { -namespace archive { - -#if defined(_MSC_VER) -#pragma warning( push ) -#pragma warning( disable : 4244 4267 ) -#endif - -/* NOTE : Warning : Warning : Warning : Warning : Warning - * Don't ever changes this. If you do, they previously created - * binary archives won't be readable !!! - */ -class library_version_type { -private: - typedef uint_least16_t base_type; - base_type t; -public: - library_version_type(): t(0) {}; - explicit library_version_type(const unsigned int & t_) : t(t_){ - BOOST_ASSERT(t_ <= boost::integer_traits::const_max); - } - library_version_type(const library_version_type & t_) : - t(t_.t) - {} - library_version_type & operator=(const library_version_type & rhs){ - t = rhs.t; - return *this; - } - // used for text output - operator base_type () const { - return t; - } - // used for text input - operator base_type & (){ - return t; - } - bool operator==(const library_version_type & rhs) const { - return t == rhs.t; - } - bool operator<(const library_version_type & rhs) const { - return t < rhs.t; - } -}; - -BOOST_ARCHIVE_DECL(library_version_type) -BOOST_ARCHIVE_VERSION(); - -class version_type { -private: - typedef uint_least32_t base_type; - base_type t; -public: - // should be private - but MPI fails if it's not!!! - version_type(): t(0) {}; - explicit version_type(const unsigned int & t_) : t(t_){ - BOOST_ASSERT(t_ <= boost::integer_traits::const_max); - } - version_type(const version_type & t_) : - t(t_.t) - {} - version_type & operator=(const version_type & rhs){ - t = rhs.t; - return *this; - } - // used for text output - operator base_type () const { - return t; - } - // used for text intput - operator base_type & (){ - return t; - } - bool operator==(const version_type & rhs) const { - return t == rhs.t; - } - bool operator<(const version_type & rhs) const { - return t < rhs.t; - } -}; - -class class_id_type { -private: - typedef int_least16_t base_type; - base_type t; -public: - // should be private - but then can't use BOOST_STRONG_TYPE below - class_id_type() : t(0) {}; - explicit class_id_type(const int t_) : t(t_){ - BOOST_ASSERT(t_ <= boost::integer_traits::const_max); - } - explicit class_id_type(const std::size_t t_) : t(t_){ - // BOOST_ASSERT(t_ <= boost::integer_traits::const_max); - } - class_id_type(const class_id_type & t_) : - t(t_.t) - {} - class_id_type & operator=(const class_id_type & rhs){ - t = rhs.t; - return *this; - } - - // used for text output - operator int () const { - return t; - } - // used for text input - operator int_least16_t &() { - return t; - } - bool operator==(const class_id_type & rhs) const { - return t == rhs.t; - } - bool operator<(const class_id_type & rhs) const { - return t < rhs.t; - } -}; - -#define NULL_POINTER_TAG boost::archive::class_id_type(-1) - -class object_id_type { -private: - typedef uint_least32_t base_type; - base_type t; -public: - object_id_type(): t(0) {}; - // note: presumes that size_t >= unsigned int. - explicit object_id_type(const std::size_t & t_) : t(t_){ - BOOST_ASSERT(t_ <= boost::integer_traits::const_max); - } - object_id_type(const object_id_type & t_) : - t(t_.t) - {} - object_id_type & operator=(const object_id_type & rhs){ - t = rhs.t; - return *this; - } - // used for text output - operator uint_least32_t () const { - return t; - } - // used for text input - operator uint_least32_t & () { - return t; - } - bool operator==(const object_id_type & rhs) const { - return t == rhs.t; - } - bool operator<(const object_id_type & rhs) const { - return t < rhs.t; - } -}; - -#if defined(_MSC_VER) -#pragma warning( pop ) -#endif - -struct tracking_type { - bool t; - explicit tracking_type(const bool t_ = false) - : t(t_) - {}; - tracking_type(const tracking_type & t_) - : t(t_.t) - {} - operator bool () const { - return t; - }; - operator bool & () { - return t; - }; - tracking_type & operator=(const bool t_){ - t = t_; - return *this; - } - bool operator==(const tracking_type & rhs) const { - return t == rhs.t; - } - bool operator==(const bool & rhs) const { - return t == rhs; - } - tracking_type & operator=(const tracking_type & rhs){ - t = rhs.t; - return *this; - } -}; - -struct class_name_type : - private boost::noncopyable -{ - char *t; - operator const char * & () const { - return const_cast(t); - } - operator char * () { - return t; - } - explicit class_name_type(const char *key_) - : t(const_cast(key_)){} - explicit class_name_type(char *key_) - : t(key_){} - class_name_type & operator=(const class_name_type & rhs){ - t = rhs.t; - return *this; - } -}; - -enum archive_flags { - no_header = 1, // suppress archive header info - no_codecvt = 2, // suppress alteration of codecvt facet - no_xml_tag_checking = 4, // suppress checking of xml tags - no_tracking = 8, // suppress ALL tracking - flags_last = 8 -}; - -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_SIGNATURE(); - -/* NOTE : Warning : Warning : Warning : Warning : Warning - * If any of these are changed to different sized types, - * binary_iarchive won't be able to read older archives - * unless you rev the library version and include conditional - * code based on the library version. There is nothing - * inherently wrong in doing this - but you have to be super - * careful because it's easy to get wrong and start breaking - * old archives !!! - */ - -#define BOOST_ARCHIVE_STRONG_TYPEDEF(T, D) \ - class D : public T { \ - public: \ - explicit D(const T tt) : T(tt){} \ - }; \ -/**/ - -BOOST_ARCHIVE_STRONG_TYPEDEF(class_id_type, class_id_reference_type) -BOOST_ARCHIVE_STRONG_TYPEDEF(class_id_type, class_id_optional_type) -BOOST_ARCHIVE_STRONG_TYPEDEF(object_id_type, object_reference_type) - -}// namespace archive -}// namespace boost - -#include // pops abi_suffix.hpp pragmas - -#include - -// set implementation level to primitive for all types -// used internally by the serialization library - -BOOST_CLASS_IMPLEMENTATION(boost::archive::library_version_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::version_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::class_id_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::class_id_reference_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::class_id_optional_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::class_name_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::object_id_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::object_reference_type, primitive_type) -BOOST_CLASS_IMPLEMENTATION(boost::archive::tracking_type, primitive_type) - -#include - -// set types used internally by the serialization library -// to be bitwise serializable - -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::library_version_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::version_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::class_id_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::class_id_reference_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::class_id_optional_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::class_name_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::object_id_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::object_reference_type) -BOOST_IS_BITWISE_SERIALIZABLE(boost::archive::tracking_type) - -#endif //BOOST_ARCHIVE_BASIC_ARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iarchive.hpp deleted file mode 100644 index d851dab4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iarchive.hpp +++ /dev/null @@ -1,222 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_BINARY_IARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_BINARY_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_iarchive.hpp -// -// archives stored as native binary - this should be the fastest way -// to archive the state of a group of obects. It makes no attempt to -// convert to any canonical form. - -// IN GENERAL, ARCHIVES CREATED WITH THIS CLASS WILL NOT BE READABLE -// ON PLATFORM APART FROM THE ONE THEY ARE CREATED ON - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -#include // must be the last header - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class basic_binary_iarchive - read serialized objects from a input binary stream -template -class basic_binary_iarchive : - public detail::common_iarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_iarchive; -#else - friend class detail::interface_iarchive; -#endif - // intermediate level to support override of operators - // fot templates in the absence of partial function - // template ordering. If we get here pass to base class - // note extra nonsense to sneak it pass the borland compiers - typedef detail::common_iarchive detail_common_iarchive; - template - void load_override(T & t, BOOST_PFTO int version){ - this->detail_common_iarchive::load_override(t, static_cast(version)); - } - - // include these to trap a change in binary format which - // isn't specifically handled - // upto 32K classes - BOOST_STATIC_ASSERT(sizeof(class_id_type) == sizeof(int_least16_t)); - BOOST_STATIC_ASSERT(sizeof(class_id_reference_type) == sizeof(int_least16_t)); - // upto 2G objects - BOOST_STATIC_ASSERT(sizeof(object_id_type) == sizeof(uint_least32_t)); - BOOST_STATIC_ASSERT(sizeof(object_reference_type) == sizeof(uint_least32_t)); - - // binary files don't include the optional information - void load_override(class_id_optional_type & /* t */, int){} - - void load_override(tracking_type & t, int /*version*/){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(6) < lvt){ - int_least8_t x=0; - * this->This() >> x; - t = boost::archive::tracking_type(x); - } - else{ - bool x=0; - * this->This() >> x; - t = boost::archive::tracking_type(x); - } - } - void load_override(class_id_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_iarchive::load_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - int_least16_t x=0; - * this->This() >> x; - t = boost::archive::class_id_type(x); - } - else{ - int x=0; - * this->This() >> x; - t = boost::archive::class_id_type(x); - } - } - void load_override(class_id_reference_type & t, int version){ - load_override(static_cast(t), version); - } -#if 0 - void load_override(class_id_reference_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_iarchive::load_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - int_least16_t x=0; - * this->This() >> x; - t = boost::archive::class_id_reference_type( - boost::archive::class_id_type(x) - ); - } - else{ - int x=0; - * this->This() >> x; - t = boost::archive::class_id_reference_type( - boost::archive::class_id_type(x) - ); - } - } -#endif - - void load_override(version_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_iarchive::load_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - uint_least8_t x=0; - * this->This() >> x; - t = boost::archive::version_type(x); - } - else - if(boost::archive::library_version_type(5) < lvt){ - uint_least16_t x=0; - * this->This() >> x; - t = boost::archive::version_type(x); - } - else - if(boost::archive::library_version_type(2) < lvt){ - // upto 255 versions - unsigned char x=0; - * this->This() >> x; - t = version_type(x); - } - else{ - unsigned int x=0; - * this->This() >> x; - t = boost::archive::version_type(x); - } - } - - void load_override(boost::serialization::item_version_type & t, int version){ - library_version_type lvt = this->get_library_version(); -// if(boost::archive::library_version_type(7) < lvt){ - if(boost::archive::library_version_type(6) < lvt){ - this->detail_common_iarchive::load_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - uint_least16_t x=0; - * this->This() >> x; - t = boost::serialization::item_version_type(x); - } - else{ - unsigned int x=0; - * this->This() >> x; - t = boost::serialization::item_version_type(x); - } - } - - void load_override(serialization::collection_size_type & t, int version){ - if(boost::archive::library_version_type(5) < this->get_library_version()){ - this->detail_common_iarchive::load_override(t, version); - } - else{ - unsigned int x=0; - * this->This() >> x; - t = serialization::collection_size_type(x); - } - } - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(class_name_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - - basic_binary_iarchive(unsigned int flags) : - detail::common_iarchive(flags) - {} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_BINARY_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iprimitive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iprimitive.hpp deleted file mode 100644 index fc27123d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_iprimitive.hpp +++ /dev/null @@ -1,190 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_IPRIMITIVE_HPP -#define BOOST_ARCHIVE_BINARY_IPRIMITIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#if defined(_MSC_VER) -#pragma warning( disable : 4800 ) -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_iprimitive.hpp -// -// archives stored as native binary - this should be the fastest way -// to archive the state of a group of obects. It makes no attempt to -// convert to any canonical form. - -// IN GENERAL, ARCHIVES CREATED WITH THIS CLASS WILL NOT BE READABLE -// ON PLATFORM APART FROM THE ONE THEY ARE CREATED ON - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include // std::memcpy -#include // std::size_t -#include // basic_streambuf -#include - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////////// -// class binary_iarchive - read serialized objects from a input binary stream -template -class basic_binary_iprimitive -{ -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS - friend class load_access; -protected: -#else -public: -#endif - std::basic_streambuf & m_sb; - // return a pointer to the most derived class - Archive * This(){ - return static_cast(this); - } - - #ifndef BOOST_NO_STD_LOCALE - boost::scoped_ptr archive_locale; - basic_streambuf_locale_saver locale_saver; - #endif - - // main template for serilization of primitive types - template - void load(T & t){ - load_binary(& t, sizeof(T)); - } - - ///////////////////////////////////////////////////////// - // fundamental types that need special treatment - - // trap usage of invalid uninitialized boolean - void load(bool & t){ - load_binary(& t, sizeof(t)); - int i = t; - BOOST_ASSERT(0 == i || 1 == i); - (void)i; // warning suppression for release builds. - } - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load(std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load(std::wstring &ws); - #endif - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load(char * t); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load(wchar_t * t); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_binary_iprimitive( - std::basic_streambuf & sb, - bool no_codecvt - ); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_binary_iprimitive(); -public: - // we provide an optimized load for all fundamental types - // typedef serialization::is_bitwise_serializable - // use_array_optimization; - struct use_array_optimization { - template - #if defined(BOOST_NO_DEPENDENT_NESTED_DERIVATIONS) - struct apply { - typedef BOOST_DEDUCED_TYPENAME boost::serialization::is_bitwise_serializable< T >::type type; - }; - #else - struct apply : public boost::serialization::is_bitwise_serializable< T > {}; - #endif - }; - - // the optimized load_array dispatches to load_binary - template - void load_array(serialization::array& a, unsigned int) - { - load_binary(a.address(),a.count()*sizeof(ValueType)); - } - - void - load_binary(void *address, std::size_t count); -}; - -template -inline void -basic_binary_iprimitive::load_binary( - void *address, - std::size_t count -){ - // note: an optimizer should eliminate the following for char files - BOOST_ASSERT( - static_cast(count / sizeof(Elem)) - <= boost::integer_traits::const_max - ); - std::streamsize s = static_cast(count / sizeof(Elem)); - std::streamsize scount = m_sb.sgetn( - static_cast(address), - s - ); - if(scount != s) - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - // note: an optimizer should eliminate the following for char files - BOOST_ASSERT(count % sizeof(Elem) <= boost::integer_traits::const_max); - s = static_cast(count % sizeof(Elem)); - if(0 < s){ -// if(is.fail()) -// boost::serialization::throw_exception( -// archive_exception(archive_exception::stream_error) -// ); - Elem t; - scount = m_sb.sgetn(& t, 1); - if(scount != 1) - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - std::memcpy(static_cast(address) + (count - s), &t, s); - } -} - -} // namespace archive -} // namespace boost - -#include // pop pragmas - -#endif // BOOST_ARCHIVE_BINARY_IPRIMITIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oarchive.hpp deleted file mode 100644 index 01622b9f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oarchive.hpp +++ /dev/null @@ -1,180 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_BINARY_OARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_BINARY_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as native binary - this should be the fastest way -// to archive the state of a group of obects. It makes no attempt to -// convert to any canonical form. - -// IN GENERAL, ARCHIVES CREATED WITH THIS CLASS WILL NOT BE READABLE -// ON PLATFORM APART FROM THE ONE THEY ARE CREATE ON - -#include -#include -#include -#include - -#include -#include - -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// class basic_binary_oarchive - write serialized objects to a binary output stream -// note: this archive has no pretensions to portability. Archive format -// may vary across machine architectures and compilers. About the only -// guarentee is that an archive created with this code will be readable -// by a program built with the same tools for the same machne. This class -// does have the virtue of buiding the smalles archive in the minimum amount -// of time. So under some circumstances it may be he right choice. -template -class basic_binary_oarchive : - public archive::detail::common_oarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_oarchive; -#else - friend class detail::interface_oarchive; -#endif - // any datatype not specifed below will be handled by base class - typedef detail::common_oarchive detail_common_oarchive; - template - void save_override(const T & t, BOOST_PFTO int version){ - this->detail_common_oarchive::save_override(t, static_cast(version)); - } - - // include these to trap a change in binary format which - // isn't specifically handled - BOOST_STATIC_ASSERT(sizeof(tracking_type) == sizeof(bool)); - // upto 32K classes - BOOST_STATIC_ASSERT(sizeof(class_id_type) == sizeof(int_least16_t)); - BOOST_STATIC_ASSERT(sizeof(class_id_reference_type) == sizeof(int_least16_t)); - // upto 2G objects - BOOST_STATIC_ASSERT(sizeof(object_id_type) == sizeof(uint_least32_t)); - BOOST_STATIC_ASSERT(sizeof(object_reference_type) == sizeof(uint_least32_t)); - - // binary files don't include the optional information - void save_override(const class_id_optional_type & /* t */, int){} - - // enable this if we decide to support generation of previous versions - #if 0 - void save_override(const boost::archive::version_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_oarchive::save_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - const boost::uint_least16_t x = t; - * this->This() << x; - } - else{ - const unsigned int x = t; - * this->This() << x; - } - } - void save_override(const boost::serialization::item_version_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_oarchive::save_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - const boost::uint_least16_t x = t; - * this->This() << x; - } - else{ - const unsigned int x = t; - * this->This() << x; - } - } - - void save_override(class_id_type & t, int version){ - library_version_type lvt = this->get_library_version(); - if(boost::archive::library_version_type(7) < lvt){ - this->detail_common_oarchive::save_override(t, version); - } - else - if(boost::archive::library_version_type(6) < lvt){ - const boost::int_least16_t x = t; - * this->This() << x; - } - else{ - const int x = t; - * this->This() << x; - } - } - void save_override(class_id_reference_type & t, int version){ - save_override(static_cast(t), version); - } - - #endif - - // explicitly convert to char * to avoid compile ambiguities - void save_override(const class_name_type & t, int){ - const std::string s(t); - * this->This() << s; - } - - #if 0 - void save_override(const serialization::collection_size_type & t, int){ - if (get_library_version() < boost::archive::library_version_type(6)){ - unsigned int x=0; - * this->This() >> x; - t = serialization::collection_size_type(x); - } - else{ - * this->This() >> t; - } - } - #endif - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - - basic_binary_oarchive(unsigned int flags) : - detail::common_oarchive(flags) - {} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_BINARY_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oprimitive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oprimitive.hpp deleted file mode 100644 index 53e44e4f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_binary_oprimitive.hpp +++ /dev/null @@ -1,184 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_BINARY_OPRIMITIVE_HPP -#define BOOST_ARCHIVE_BASIC_BINARY_OPRIMITIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_oprimitive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as native binary - this should be the fastest way -// to archive the state of a group of obects. It makes no attempt to -// convert to any canonical form. - -// IN GENERAL, ARCHIVES CREATED WITH THIS CLASS WILL NOT BE READABLE -// ON PLATFORM APART FROM THE ONE THEY ARE CREATE ON - -#include -#include -#include -#include // basic_streambuf -#include -#include // size_t - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class basic_binary_oprimitive - binary output of prmitives - -template -class basic_binary_oprimitive -{ -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS - friend class save_access; -protected: -#else -public: -#endif - std::basic_streambuf & m_sb; - // return a pointer to the most derived class - Archive * This(){ - return static_cast(this); - } - #ifndef BOOST_NO_STD_LOCALE - boost::scoped_ptr archive_locale; - basic_streambuf_locale_saver locale_saver; - #endif - // default saving of primitives. - template - void save(const T & t) - { - save_binary(& t, sizeof(T)); - } - - ///////////////////////////////////////////////////////// - // fundamental types that need special treatment - - // trap usage of invalid uninitialized boolean which would - // otherwise crash on load. - void save(const bool t){ - BOOST_ASSERT(0 == static_cast(t) || 1 == static_cast(t)); - save_binary(& t, sizeof(t)); - } - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save(const std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save(const std::wstring &ws); - #endif - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save(const char * t); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save(const wchar_t * t); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_binary_oprimitive( - std::basic_streambuf & sb, - bool no_codecvt - ); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_binary_oprimitive(); -public: - - // we provide an optimized save for all fundamental types - // typedef serialization::is_bitwise_serializable - // use_array_optimization; - // workaround without using mpl lambdas - struct use_array_optimization { - template - #if defined(BOOST_NO_DEPENDENT_NESTED_DERIVATIONS) - struct apply { - typedef BOOST_DEDUCED_TYPENAME boost::serialization::is_bitwise_serializable< T >::type type; - }; - #else - struct apply : public boost::serialization::is_bitwise_serializable< T > {}; - #endif - }; - - - // the optimized save_array dispatches to save_binary - template - void save_array(boost::serialization::array const& a, unsigned int) - { - save_binary(a.address(),a.count()*sizeof(ValueType)); - } - - void save_binary(const void *address, std::size_t count); -}; - -template -inline void -basic_binary_oprimitive::save_binary( - const void *address, - std::size_t count -){ - //BOOST_ASSERT( - // static_cast((std::numeric_limits::max)()) >= count - //); - // note: if the following assertions fail - // a likely cause is that the output stream is set to "text" - // mode where by cr characters recieve special treatment. - // be sure that the output stream is opened with ios::binary - //if(os.fail()) - // boost::serialization::throw_exception( - // archive_exception(archive_exception::output_stream_error) - // ); - // figure number of elements to output - round up - count = ( count + sizeof(Elem) - 1) - / sizeof(Elem); - BOOST_ASSERT(count <= std::size_t(boost::integer_traits::const_max)); - std::streamsize scount = m_sb.sputn( - static_cast(address), - static_cast(count) - ); - if(count != static_cast(scount)) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - //os.write( - // static_cast(address), - // count - //); - //BOOST_ASSERT(os.good()); -} - -} //namespace boost -} //namespace archive - -#include // pop pragmas - -#endif // BOOST_ARCHIVE_BASIC_BINARY_OPRIMITIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_streambuf_locale_saver.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_streambuf_locale_saver.hpp deleted file mode 100644 index ca764e10..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_streambuf_locale_saver.hpp +++ /dev/null @@ -1,73 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_STREAMBUF_LOCALE_SAVER_HPP -#define BOOST_ARCHIVE_BASIC_STREAMBUF_LOCALE_SAVER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_streambuf_local_saver.hpp - -// (C) Copyright 2005 Robert Ramey - http://www.rrsd.com - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// note derived from boost/io/ios_state.hpp -// Copyright 2002, 2005 Daryle Walker. Use, modification, and distribution -// are subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or a copy at .) - -// See for the library's home page. - -#ifndef BOOST_NO_STD_LOCALE - -#include // for std::locale -#include // for std::basic_streambuf - -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost{ -namespace archive{ - -template < typename Ch, class Tr > -class basic_streambuf_locale_saver : - private boost::noncopyable -{ -public: - typedef ::std::basic_streambuf state_type; - typedef ::std::locale aspect_type; - explicit basic_streambuf_locale_saver( state_type &s ) - : s_save_( s ), a_save_( s.getloc() ) - {} - basic_streambuf_locale_saver( state_type &s, aspect_type const &a ) - : s_save_( s ), a_save_( s.pubimbue(a) ) - {} - ~basic_streambuf_locale_saver() - { this->restore(); } - void restore() - { s_save_.pubimbue( a_save_ ); } -private: - state_type & s_save_; - aspect_type const a_save_; -}; - -} // archive -} // boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_NO_STD_LOCALE -#endif // BOOST_ARCHIVE_BASIC_STREAMBUF_LOCALE_SAVER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iarchive.hpp deleted file mode 100644 index 729d51aa..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iarchive.hpp +++ /dev/null @@ -1,91 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_TEXT_IARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_TEXT_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as text - note these ar templated on the basic -// stream templates to accommodate wide (and other?) kind of characters -// -// note the fact that on libraries without wide characters, ostream is -// is not a specialization of basic_ostream which in fact is not defined -// in such cases. So we can't use basic_ostream but rather -// use two template parameters - -#include -#include -#include - -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class basic_text_iarchive - read serialized objects from a input text stream -template -class basic_text_iarchive : - public detail::common_iarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_iarchive; -#else - friend class detail::interface_iarchive; -#endif - // intermediate level to support override of operators - // fot templates in the absence of partial function - // template ordering - typedef detail::common_iarchive detail_common_iarchive; - template - void load_override(T & t, BOOST_PFTO int){ - this->detail_common_iarchive::load_override(t, 0); - } - // text file don't include the optional information - void load_override(class_id_optional_type & /*t*/, int){} - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(class_name_type & t, int); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(void); - - basic_text_iarchive(unsigned int flags) : - detail::common_iarchive(flags) - {} - ~basic_text_iarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_TEXT_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iprimitive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iprimitive.hpp deleted file mode 100644 index b927ec91..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_iprimitive.hpp +++ /dev/null @@ -1,144 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_TEXT_IPRIMITIVE_HPP -#define BOOST_ARCHIVE_BASIC_TEXT_IPRIMITIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_iprimitive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as text - note these are templated on the basic -// stream templates to accommodate wide (and other?) kind of characters -// -// Note the fact that on libraries without wide characters, ostream is -// not a specialization of basic_ostream which in fact is not defined -// in such cases. So we can't use basic_ostream but rather -// use two template parameters - -#include -#include -#include // size_t - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; - #if ! defined(BOOST_DINKUMWARE_STDLIB) && ! defined(__SGI_STL_PORT) - using ::locale; - #endif -} // namespace std -#endif - -#include -#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) -#include -#endif - -#include -#include -#include -#include - -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class basic_text_iarchive - load serialized objects from a input text stream -#if defined(_MSC_VER) -#pragma warning( push ) -#pragma warning( disable : 4244 4267 ) -#endif - -template -class basic_text_iprimitive -{ -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -protected: -#else -public: -#endif - IStream &is; - io::ios_flags_saver flags_saver; - io::ios_precision_saver precision_saver; - - #ifndef BOOST_NO_STD_LOCALE - boost::scoped_ptr archive_locale; - basic_streambuf_locale_saver< - BOOST_DEDUCED_TYPENAME IStream::char_type, - BOOST_DEDUCED_TYPENAME IStream::traits_type - > locale_saver; - #endif - - template - void load(T & t) - { - if(! is.fail()){ - is >> t; - return; - } - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - } - - void load(char & t) - { - short int i; - load(i); - t = i; - } - void load(signed char & t) - { - short int i; - load(i); - t = i; - } - void load(unsigned char & t) - { - unsigned short int i; - load(i); - t = i; - } - - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - void load(wchar_t & t) - { - BOOST_STATIC_ASSERT(sizeof(wchar_t) <= sizeof(int)); - int i; - load(i); - t = i; - } - #endif - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_text_iprimitive(IStream &is, bool no_codecvt); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_text_iprimitive(); -public: - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_binary(void *address, std::size_t count); -}; - -#if defined(_MSC_VER) -#pragma warning( pop ) -#endif - -} // namespace archive -} // namespace boost - -#include // pop pragmas - -#endif // BOOST_ARCHIVE_BASIC_TEXT_IPRIMITIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oarchive.hpp deleted file mode 100644 index dd10f659..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oarchive.hpp +++ /dev/null @@ -1,116 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_TEXT_OARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_TEXT_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as text - note these ar templated on the basic -// stream templates to accommodate wide (and other?) kind of characters -// -// note the fact that on libraries without wide characters, ostream is -// is not a specialization of basic_ostream which in fact is not defined -// in such cases. So we can't use basic_ostream but rather -// use two template parameters - -#include -#include -#include -#include - -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class basic_text_oarchive -template -class basic_text_oarchive : - public detail::common_oarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \ -|| BOOST_WORKAROUND(__BORLANDC__,BOOST_TESTED_AT(0x560)) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_oarchive; -#else - friend class detail::interface_oarchive; -#endif - enum { - none, - eol, - space - } delimiter; - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - newtoken(); - - void newline(){ - delimiter = eol; - } - - // default processing - kick back to base class. Note the - // extra stuff to get it passed borland compilers - typedef detail::common_oarchive detail_common_oarchive; - template - void save_override(T & t, BOOST_PFTO int){ - this->detail_common_oarchive::save_override(t, 0); - } - - // start new objects on a new line - void save_override(const object_id_type & t, int){ - this->This()->newline(); - this->detail_common_oarchive::save_override(t, 0); - } - - // text file don't include the optional information - void save_override(const class_id_optional_type & /* t */, int){} - - void save_override(const class_name_type & t, int){ - const std::string s(t); - * this->This() << s; - } - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - - basic_text_oarchive(unsigned int flags) : - detail::common_oarchive(flags), - delimiter(none) - {} - ~basic_text_oarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_TEXT_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oprimitive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oprimitive.hpp deleted file mode 100644 index 06885ad3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_text_oprimitive.hpp +++ /dev/null @@ -1,173 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_TEXT_OPRIMITIVE_HPP -#define BOOST_ARCHIVE_BASIC_TEXT_OPRIMITIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_oprimitive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as text - note these ar templated on the basic -// stream templates to accommodate wide (and other?) kind of characters -// -// note the fact that on libraries without wide characters, ostream is -// is not a specialization of basic_ostream which in fact is not defined -// in such cases. So we can't use basic_ostream but rather -// use two template parameters - -#include -#include -#include // isnan -#include -#include // size_t - -#include -#include -#include -#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) -#include -#endif - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; - #if ! defined(BOOST_DINKUMWARE_STDLIB) && ! defined(__SGI_STL_PORT) - using ::locale; - #endif -} // namespace std -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace archive { - -class save_access; - -///////////////////////////////////////////////////////////////////////// -// class basic_text_oprimitive - output of prmitives to stream -template -class basic_text_oprimitive -{ -#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -protected: -#else -public: -#endif - OStream &os; - io::ios_flags_saver flags_saver; - io::ios_precision_saver precision_saver; - - #ifndef BOOST_NO_STD_LOCALE - boost::scoped_ptr archive_locale; - basic_streambuf_locale_saver< - BOOST_DEDUCED_TYPENAME OStream::char_type, - BOOST_DEDUCED_TYPENAME OStream::traits_type - > locale_saver; - #endif - - // default saving of primitives. - template - void save(const T &t){ - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - os << t; - } - - ///////////////////////////////////////////////////////// - // fundamental types that need special treatment - void save(const bool t){ - // trap usage of invalid uninitialized boolean which would - // otherwise crash on load. - BOOST_ASSERT(0 == static_cast(t) || 1 == static_cast(t)); - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - os << t; - } - void save(const signed char t) - { - save(static_cast(t)); - } - void save(const unsigned char t) - { - save(static_cast(t)); - } - void save(const char t) - { - save(static_cast(t)); - } - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - void save(const wchar_t t) - { - BOOST_STATIC_ASSERT(sizeof(wchar_t) <= sizeof(int)); - save(static_cast(t)); - } - #endif - void save(const float t) - { - // must be a user mistake - can't serialize un-initialized data - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - os << std::setprecision(std::numeric_limits::digits10 + 2); - os << t; - } - void save(const double t) - { - // must be a user mistake - can't serialize un-initialized data - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - os << std::setprecision(std::numeric_limits::digits10 + 2); - os << t; - } - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_text_oprimitive(OStream & os, bool no_codecvt); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_text_oprimitive(); -public: - // unformatted append of one character - void put(BOOST_DEDUCED_TYPENAME OStream::char_type c){ - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - os.put(c); - } - // unformatted append of null terminated string - void put(const char * s){ - while('\0' != *s) - os.put(*s++); - } - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_binary(const void *address, std::size_t count); -}; - -} //namespace boost -} //namespace archive - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_TEXT_OPRIMITIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_archive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_archive.hpp deleted file mode 100644 index c99d94fa..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_archive.hpp +++ /dev/null @@ -1,67 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_XML_TEXT_ARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_XML_TEXT_ARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_archive.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include // must be the last header - -namespace boost { -namespace archive { - -// constant strings used in xml i/o - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_OBJECT_ID(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_OBJECT_REFERENCE(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_CLASS_ID(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_CLASS_ID_REFERENCE(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_CLASS_NAME(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_TRACKING(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_VERSION(); - -extern -BOOST_ARCHIVE_DECL(const char *) -BOOST_ARCHIVE_XML_SIGNATURE(); - -}// namespace archive -}// namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_XML_TEXT_ARCHIVE_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_iarchive.hpp deleted file mode 100644 index d7b8bfd0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_iarchive.hpp +++ /dev/null @@ -1,127 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_XML_IARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_XML_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include - -#include - -#include -#include - -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -///////////////////////////////////////////////////////////////////////// -// class xml_iarchive - read serialized objects from a input text stream -template -class basic_xml_iarchive : - public detail::common_iarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_oarchive; -#else - friend class detail::interface_oarchive; -#endif - unsigned int depth; - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_start(const char *name); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_end(const char *name); - - // Anything not an attribute and not a name-value pair is an - // should be trapped here. - template - void load_override(T & t, BOOST_PFTO int) - { - // If your program fails to compile here, its most likely due to - // not specifying an nvp wrapper around the variable to - // be serialized. - BOOST_MPL_ASSERT((serialization::is_wrapper< T >)); - this->detail_common_iarchive::load_override(t, 0); - } - - // Anything not an attribute - see below - should be a name value - // pair and be processed here - typedef detail::common_iarchive detail_common_iarchive; - template - void load_override( - #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - const - #endif - boost::serialization::nvp< T > & t, - int - ){ - this->This()->load_start(t.name()); - this->detail_common_iarchive::load_override(t.value(), 0); - this->This()->load_end(t.name()); - } - - // specific overrides for attributes - handle as - // primitives. These are not name-value pairs - // so they have to be intercepted here and passed on to load. - // although the class_id is included in the xml text file in order - // to make the file self describing, it isn't used when loading - // an xml archive. So we can skip it here. Note: we MUST override - // it otherwise it will be loaded as a normal primitive w/o tag and - // leaving the archive in an undetermined state - void load_override(class_id_optional_type & /* t */, int){} - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(object_id_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(version_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(class_id_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - load_override(tracking_type & t, int); - // class_name_type can't be handled here as it depends upon the - // char type used by the stream. So require the derived implementation - // handle this. - // void load_override(class_name_type & t, int); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_xml_iarchive(unsigned int flags); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_xml_iarchive(); -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_XML_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_oarchive.hpp deleted file mode 100644 index b571372c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/basic_xml_oarchive.hpp +++ /dev/null @@ -1,145 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_XML_OARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_XML_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include - -#include -#include -#include - -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// class basic_xml_oarchive - write serialized objects to a xml output stream -template -class basic_xml_oarchive : - public detail::common_oarchive -{ -protected: -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -public: -#elif defined(BOOST_MSVC) - // for some inexplicable reason insertion of "class" generates compile erro - // on msvc 7.1 - friend detail::interface_oarchive; - friend class save_access; -#else - friend class detail::interface_oarchive; - friend class save_access; -#endif - // special stuff for xml output - unsigned int depth; - bool indent_next; - bool pending_preamble; - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - indent(); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - init(); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - write_attribute( - const char *attribute_name, - int t, - const char *conjunction = "=\"" - ); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - write_attribute( - const char *attribute_name, - const char *key - ); - // helpers used below - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_start(const char *name); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_end(const char *name); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - end_preamble(); - - // Anything not an attribute and not a name-value pair is an - // error and should be trapped here. - template - void save_override(T & t, BOOST_PFTO int) - { - // If your program fails to compile here, its most likely due to - // not specifying an nvp wrapper around the variable to - // be serialized. - BOOST_MPL_ASSERT((serialization::is_wrapper< T >)); - this->detail_common_oarchive::save_override(t, 0); - } - - // special treatment for name-value pairs. - typedef detail::common_oarchive detail_common_oarchive; - template - void save_override( - #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - const - #endif - ::boost::serialization::nvp< T > & t, - int - ){ - this->This()->save_start(t.name()); - this->detail_common_oarchive::save_override(t.const_value(), 0); - this->This()->save_end(t.name()); - } - - // specific overrides for attributes - not name value pairs so we - // want to trap them before the above "fall through" - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const object_id_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const object_reference_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const version_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const class_id_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const class_id_optional_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const class_id_reference_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const class_name_type & t, int); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) - save_override(const tracking_type & t, int); - - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - basic_xml_oarchive(unsigned int flags); - BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~basic_xml_oarchive(); -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_XML_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive.hpp deleted file mode 100644 index 638d9967..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive.hpp +++ /dev/null @@ -1,103 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_IARCHIVE_HPP -#define BOOST_ARCHIVE_BINARY_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -// do not derive from the classes below. If you want to extend this functionality -// via inhertance, derived from text_iarchive_impl instead. This will -// preserve correct static polymorphism. - -// same as binary_iarchive below - without the shared_ptr_helper -class naked_binary_iarchive : - public binary_iarchive_impl< - boost::archive::naked_binary_iarchive, - std::istream::char_type, - std::istream::traits_type - > -{ -public: - naked_binary_iarchive(std::istream & is, unsigned int flags = 0) : - binary_iarchive_impl< - naked_binary_iarchive, std::istream::char_type, std::istream::traits_type - >(is, flags) - {} - naked_binary_iarchive(std::streambuf & bsb, unsigned int flags = 0) : - binary_iarchive_impl< - naked_binary_iarchive, std::istream::char_type, std::istream::traits_type - >(bsb, flags) - {} -}; - -} // namespace archive -} // namespace boost - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -namespace boost { -namespace archive { - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from binary_iarchive_impl instead. This will -// preserve correct static polymorphism. -class binary_iarchive : - public binary_iarchive_impl< - boost::archive::binary_iarchive, - std::istream::char_type, - std::istream::traits_type - >, - public detail::shared_ptr_helper -{ -public: - binary_iarchive(std::istream & is, unsigned int flags = 0) : - binary_iarchive_impl< - binary_iarchive, std::istream::char_type, std::istream::traits_type - >(is, flags) - {} - binary_iarchive(std::streambuf & bsb, unsigned int flags = 0) : - binary_iarchive_impl< - binary_iarchive, std::istream::char_type, std::istream::traits_type - >(bsb, flags) - {} -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::binary_iarchive) -BOOST_SERIALIZATION_USE_ARRAY_OPTIMIZATION(boost::archive::binary_iarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_BINARY_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive_impl.hpp deleted file mode 100644 index 32c476d6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_iarchive_impl.hpp +++ /dev/null @@ -1,96 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_IARCHIVE_IMPL_HPP -#define BOOST_ARCHIVE_BINARY_IARCHIVE_IMPL_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_iarchive_impl.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class binary_iarchive_impl : - public basic_binary_iprimitive, - public basic_binary_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class basic_binary_iarchive; - friend class load_access; -protected: -#endif - // note: the following should not needed - but one compiler (vc 7.1) - // fails to compile one test (test_shared_ptr) without it !!! - // make this protected so it can be called from a derived archive - template - void load_override(T & t, BOOST_PFTO int){ - this->basic_binary_iarchive::load_override(t, 0L); - } - void init(unsigned int flags){ - if(0 != (flags & no_header)) - return; - #if ! defined(__MWERKS__) - this->basic_binary_iarchive::init(); - this->basic_binary_iprimitive::init(); - #else - basic_binary_iarchive::init(); - basic_binary_iprimitive::init(); - #endif - } - binary_iarchive_impl( - std::basic_streambuf & bsb, - unsigned int flags - ) : - basic_binary_iprimitive( - bsb, - 0 != (flags & no_codecvt) - ), - basic_binary_iarchive(flags) - { - init(flags); - } - binary_iarchive_impl( - std::basic_istream & is, - unsigned int flags - ) : - basic_binary_iprimitive( - * is.rdbuf(), - 0 != (flags & no_codecvt) - ), - basic_binary_iarchive(flags) - { - init(flags); - } -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_BINARY_IARCHIVE_IMPL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive.hpp deleted file mode 100644 index 2aac14f9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive.hpp +++ /dev/null @@ -1,66 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_OARCHIVE_HPP -#define BOOST_ARCHIVE_BINARY_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from binary_oarchive_impl instead. This will -// preserve correct static polymorphism. -class binary_oarchive : - public binary_oarchive_impl< - binary_oarchive, std::ostream::char_type, std::ostream::traits_type - > -{ -public: - binary_oarchive(std::ostream & os, unsigned int flags = 0) : - binary_oarchive_impl< - binary_oarchive, std::ostream::char_type, std::ostream::traits_type - >(os, flags) - {} - binary_oarchive(std::streambuf & bsb, unsigned int flags = 0) : - binary_oarchive_impl< - binary_oarchive, std::ostream::char_type, std::ostream::traits_type - >(bsb, flags) - {} -}; - -typedef binary_oarchive naked_binary_oarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::binary_oarchive) -BOOST_SERIALIZATION_USE_ARRAY_OPTIMIZATION(boost::archive::binary_oarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_BINARY_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive_impl.hpp deleted file mode 100644 index 7ca773b6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_oarchive_impl.hpp +++ /dev/null @@ -1,97 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_OARCHIVE_IMPL_HPP -#define BOOST_ARCHIVE_BINARY_OARCHIVE_IMPL_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_oarchive_impl.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class binary_oarchive_impl : - public basic_binary_oprimitive, - public basic_binary_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class basic_binary_oarchive; - friend class save_access; -protected: -#endif - // note: the following should not needed - but one compiler (vc 7.1) - // fails to compile one test (test_shared_ptr) without it !!! - // make this protected so it can be called from a derived archive - template - void save_override(T & t, BOOST_PFTO int){ - this->basic_binary_oarchive::save_override(t, 0L); - } - void init(unsigned int flags) { - if(0 != (flags & no_header)) - return; - #if ! defined(__MWERKS__) - this->basic_binary_oarchive::init(); - this->basic_binary_oprimitive::init(); - #else - basic_binary_oarchive::init(); - basic_binary_oprimitive::init(); - #endif - } - binary_oarchive_impl( - std::basic_streambuf & bsb, - unsigned int flags - ) : - basic_binary_oprimitive( - bsb, - 0 != (flags & no_codecvt) - ), - basic_binary_oarchive(flags) - { - init(flags); - } - binary_oarchive_impl( - std::basic_ostream & os, - unsigned int flags - ) : - basic_binary_oprimitive( - * os.rdbuf(), - 0 != (flags & no_codecvt) - ), - basic_binary_oarchive(flags) - { - init(flags); - } -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_BINARY_OARCHIVE_IMPL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_wiarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_wiarchive.hpp deleted file mode 100644 index b5f6a710..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_wiarchive.hpp +++ /dev/null @@ -1,93 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_WIARCHIVE_HPP -#define BOOST_ARCHIVE_BINARY_WIARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_wiarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include // wistream -#include -#include - -namespace boost { -namespace archive { - -// same as binary_wiarchive below - without the shared_ptr_helper -class naked_binary_wiarchive : - public binary_iarchive_impl< - boost::archive::naked_binary_wiarchive, - std::wistream::char_type, - std::wistream::traits_type - > -{ -public: - naked_binary_wiarchive(std::wistream & is, unsigned int flags = 0) : - binary_iarchive_impl< - naked_binary_wiarchive, - std::wistream::char_type, - std::wistream::traits_type - >(is, flags) - {} - naked_binary_wiarchive(std::wstreambuf & bsb, unsigned int flags = 0) : - binary_iarchive_impl< - naked_binary_wiarchive, - std::wistream::char_type, - std::wistream::traits_type - >(bsb, flags) - {} -}; - -} // namespace archive -} // namespace boost - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -namespace boost { -namespace archive { - -class binary_wiarchive : - public binary_iarchive_impl< - binary_wiarchive, std::wistream::char_type, std::wistream::traits_type - > -{ -public: - binary_wiarchive(std::wistream & is, unsigned int flags = 0) : - binary_iarchive_impl< - binary_wiarchive, std::wistream::char_type, std::wistream::traits_type - >(is, flags) - {} - binary_wiarchive(std::wstreambuf & bsb, unsigned int flags = 0) : - binary_iarchive_impl< - binary_wiarchive, std::wistream::char_type, std::wistream::traits_type - >(bsb, flags) - {} -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::binary_wiarchive) - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_BINARY_WIARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_woarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/binary_woarchive.hpp deleted file mode 100644 index 2075dac8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/binary_woarchive.hpp +++ /dev/null @@ -1,61 +0,0 @@ -#ifndef BOOST_ARCHIVE_BINARY_WOARCHIVE_HPP -#define BOOST_ARCHIVE_BINARY_WOARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_woarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include -#include -#include - -namespace boost { -namespace archive { - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from binary_oarchive_impl instead. This will -// preserve correct static polymorphism. -class binary_woarchive : - public binary_oarchive_impl< - binary_woarchive, std::wostream::char_type, std::wostream::traits_type - > -{ -public: - binary_woarchive(std::wostream & os, unsigned int flags = 0) : - binary_oarchive_impl< - binary_woarchive, std::wostream::char_type, std::wostream::traits_type - >(os, flags) - {} - binary_woarchive(std::wstreambuf & bsb, unsigned int flags = 0) : - binary_oarchive_impl< - binary_woarchive, std::wostream::char_type, std::wostream::traits_type - >(bsb, flags) - {} -}; - -typedef binary_woarchive naked_binary_woarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::binary_woarchive) - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_BINARY_WOARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/codecvt_null.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/codecvt_null.hpp deleted file mode 100644 index 910b2615..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/codecvt_null.hpp +++ /dev/null @@ -1,100 +0,0 @@ -#ifndef BOOST_ARCHIVE_CODECVT_NULL_HPP -#define BOOST_ARCHIVE_CODECVT_NULL_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// codecvt_null.hpp: - -// (C) Copyright 2004 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL, size_t -#include // for mbstate_t -#include -#include -#include // must be the last header - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std { -// For STLport on WinCE, BOOST_NO_STDC_NAMESPACE can get defined if STLport is putting symbols in its own namespace. -// In the case of codecvt, however, this does not mean that codecvt is in the global namespace (it will be in STLport's namespace) -# if !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - using ::codecvt; -# endif - using ::mbstate_t; - using ::size_t; -} // namespace -#endif - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class codecvt_null; - -template<> -class codecvt_null : public std::codecvt -{ - virtual bool do_always_noconv() const throw() { - return true; - } -public: - explicit codecvt_null(std::size_t no_locale_manage = 0) : - std::codecvt(no_locale_manage) - {} -}; - -template<> -class codecvt_null : public std::codecvt -{ - virtual BOOST_WARCHIVE_DECL(std::codecvt_base::result) - do_out( - std::mbstate_t & state, - const wchar_t * first1, - const wchar_t * last1, - const wchar_t * & next1, - char * first2, - char * last2, - char * & next2 - ) const; - virtual BOOST_WARCHIVE_DECL(std::codecvt_base::result) - do_in( - std::mbstate_t & state, - const char * first1, - const char * last1, - const char * & next1, - wchar_t * first2, - wchar_t * last2, - wchar_t * & next2 - ) const; - virtual int do_encoding( ) const throw( ){ - return sizeof(wchar_t) / sizeof(char); - } - virtual int do_max_length( ) const throw( ){ - return do_encoding(); - } -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif -#include // pop pragmas - -#endif //BOOST_ARCHIVE_CODECVT_NULL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_prefix.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_prefix.hpp deleted file mode 100644 index e39ef11f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_prefix.hpp +++ /dev/null @@ -1,20 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// abi_prefix.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // must be the last header -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4251 4231 4660 4275) -#endif - -#if defined( __BORLANDC__ ) -#pragma nopushoptwarn -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_suffix.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_suffix.hpp deleted file mode 100644 index a283b36c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/abi_suffix.hpp +++ /dev/null @@ -1,19 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// abi_suffix.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif -#include // pops abi_suffix.hpp pragmas - -#if defined( __BORLANDC__ ) -#pragma nopushoptwarn -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/archive_serializer_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/archive_serializer_map.hpp deleted file mode 100644 index 6d2eec4a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/archive_serializer_map.hpp +++ /dev/null @@ -1,55 +0,0 @@ -#ifndef BOOST_ARCHIVE_SERIALIZER_MAP_HPP -#define BOOST_ARCHIVE_SERIALIZER_MAP_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// archive_serializer_map.hpp: extenstion of type_info required for -// serialization. - -// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// note: this is nothing more than the thinest of wrappers around -// basic_serializer_map so we can have a one map / archive type. - -#include -#include -#include // must be the last header - -namespace boost { - -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { -namespace detail { - -class basic_serializer; - -template -class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -archive_serializer_map { -public: - static bool insert(const basic_serializer * bs); - static void erase(const basic_serializer * bs); - static const basic_serializer * find( - const boost::serialization::extended_type_info & type_ - ); -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#include // must be the last header - -#endif //BOOST_ARCHIVE_SERIALIZER_MAP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_archive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_archive.hpp deleted file mode 100644 index 05956f0e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_archive.hpp +++ /dev/null @@ -1,48 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_AUTO_LINK_ARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_AUTO_LINK_ARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// auto_link_archive.hpp -// -// (c) Copyright Robert Ramey 2004 -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See library home page at http://www.boost.org/libs/serialization - -//----------------------------------------------------------------------------// - -// This header implements separate compilation features as described in -// http://www.boost.org/more/separate_compilation.html - -// enable automatic library variant selection ------------------------------// - -#include - -#if !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_SERIALIZATION_NO_LIB) \ -&& !defined(BOOST_ARCHIVE_SOURCE) && !defined(BOOST_WARCHIVE_SOURCE) \ -&& !defined(BOOST_SERIALIZATION_SOURCE) - - // Set the name of our library, this will get undef'ed by auto_link.hpp - // once it's done with it: - // - #define BOOST_LIB_NAME boost_serialization - // - // If we're importing code from a dll, then tell auto_link.hpp about it: - // - #if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_SERIALIZATION_DYN_LINK) - # define BOOST_DYN_LINK - #endif - // - // And include the header that does the work: - // - #include -#endif // auto-linking disabled - -#endif // BOOST_ARCHIVE_DETAIL_AUTO_LINK_ARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_warchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_warchive.hpp deleted file mode 100644 index 4d4efcd4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/auto_link_warchive.hpp +++ /dev/null @@ -1,47 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_AUTO_LINK_WARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_AUTO_LINK_WARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// auto_link_warchive.hpp -// -// (c) Copyright Robert Ramey 2004 -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See library home page at http://www.boost.org/libs/serialization - -//----------------------------------------------------------------------------// - -// This header implements separate compilation features as described in -// http://www.boost.org/more/separate_compilation.html - -// enable automatic library variant selection ------------------------------// - -#include - -#if !defined(BOOST_WARCHIVE_SOURCE) \ -&& !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_SERIALIZATION_NO_LIB) - -// Set the name of our library, this will get undef'ed by auto_link.hpp -// once it's done with it: -// -#define BOOST_LIB_NAME boost_wserialization -// -// If we're importing code from a dll, then tell auto_link.hpp about it: -// -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_SERIALIZATION_DYN_LINK) -# define BOOST_DYN_LINK -#endif -// -// And include the header that does the work: -// -#include -#endif // auto-linking disabled - -#endif // ARCHIVE_DETAIL_AUTO_LINK_ARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iarchive.hpp deleted file mode 100644 index f62987ec..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iarchive.hpp +++ /dev/null @@ -1,110 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_BASIC_IARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_BASIC_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_iarchive.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// can't use this - much as I'd like to as borland doesn't support it -// #include - -#include -#include - -#include -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { -namespace detail { - -class basic_iarchive_impl; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iserializer; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_iserializer; -////////////////////////////////////////////////////////////////////// -// class basic_iarchive - read serialized objects from a input stream -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive : - private boost::noncopyable -{ - friend class basic_iarchive_impl; - // hide implementation of this class to minimize header conclusion - // in client code. I couldn't used scoped pointer with borland - // boost::scoped_ptr pimpl; - basic_iarchive_impl * pimpl; - - virtual void vload(version_type &t) = 0; - virtual void vload(object_id_type &t) = 0; - virtual void vload(class_id_type &t) = 0; - virtual void vload(class_id_optional_type &t) = 0; - virtual void vload(class_name_type &t) = 0; - virtual void vload(tracking_type &t) = 0; -protected: - basic_iarchive(unsigned int flags); - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_iarchive(); -public: - // note: NOT part of the public API. - void next_object_pointer(void *t); - void register_basic_serializer( - const basic_iserializer & bis - ); - void load_object( - void *t, - const basic_iserializer & bis - ); - const basic_pointer_iserializer * - load_pointer( - void * & t, - const basic_pointer_iserializer * bpis_ptr, - const basic_pointer_iserializer * (*finder)( - const boost::serialization::extended_type_info & eti - ) - - ); - // real public API starts here - void - set_library_version(library_version_type archive_library_version); - library_version_type - get_library_version() const; - unsigned int - get_flags() const; - void - reset_object_address(const void * new_address, const void * old_address); - void - delete_created_pointers(); -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -// required by smart_cast for compilers not implementing -// partial template specialization -BOOST_TT_BROKEN_COMPILER_SPEC( - boost::archive::detail::basic_iarchive -) - -#include // pops abi_suffix.hpp pragmas - -#endif //BOOST_ARCHIVE_DETAIL_BASIC_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iserializer.hpp deleted file mode 100644 index 2f4f6d81..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_iserializer.hpp +++ /dev/null @@ -1,95 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_BASIC_ISERIALIZER_HPP -#define BOOST_ARCHIVE_DETAIL_BASIC_ISERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_iserializer.hpp: extenstion of type_info required for serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // NULL -#include - -#include -#include -#include -#include -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -// forward declarations -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_iserializer; - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iserializer : - public basic_serializer -{ -private: - basic_pointer_iserializer *m_bpis; -protected: - explicit basic_iserializer( - const boost::serialization::extended_type_info & type - ); - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_iserializer(); -public: - bool serialized_as_pointer() const { - return m_bpis != NULL; - } - void set_bpis(basic_pointer_iserializer *bpis){ - m_bpis = bpis; - } - const basic_pointer_iserializer * get_bpis_ptr() const { - return m_bpis; - } - virtual void load_object_data( - basic_iarchive & ar, - void *x, - const unsigned int file_version - ) const = 0; - // returns true if class_info should be saved - virtual bool class_info() const = 0 ; - // returns true if objects should be tracked - virtual bool tracking(const unsigned int) const = 0 ; - // returns class version - virtual version_type version() const = 0 ; - // returns true if this class is polymorphic - virtual bool is_polymorphic() const = 0; - virtual void destroy(/*const*/ void *address) const = 0 ; -}; - -} // namespae detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_DETAIL_BASIC_ISERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oarchive.hpp deleted file mode 100644 index 402e569a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oarchive.hpp +++ /dev/null @@ -1,106 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_OARCHIVE_HPP -#define BOOST_ARCHIVE_BASIC_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_oarchive.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // NULL -#include -#include - -#include - -// can't use this - much as I'd like to as borland doesn't support it -// #include - -#include -#include - -#include // must be the last header - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { -namespace detail { - -class basic_oarchive_impl; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oserializer; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_oserializer; -////////////////////////////////////////////////////////////////////// -// class basic_oarchive - write serialized objects to an output stream -class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oarchive : - private boost::noncopyable -{ - friend class basic_oarchive_impl; - // hide implementation of this class to minimize header conclusion - // in client code. note: borland can't use scoped_ptr - //boost::scoped_ptr pimpl; - basic_oarchive_impl * pimpl; - - // overload these to bracket object attributes. Used to implement - // xml archives - virtual void vsave(const version_type t) = 0; - virtual void vsave(const object_id_type t) = 0; - virtual void vsave(const object_reference_type t) = 0; - virtual void vsave(const class_id_type t) = 0; - virtual void vsave(const class_id_optional_type t) = 0; - virtual void vsave(const class_id_reference_type t) = 0; - virtual void vsave(const class_name_type & t) = 0; - virtual void vsave(const tracking_type t) = 0; -protected: - basic_oarchive(unsigned int flags = 0); - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_oarchive(); -public: - // note: NOT part of the public interface - void register_basic_serializer( - const basic_oserializer & bos - ); - void save_object( - const void *x, - const basic_oserializer & bos - ); - void save_pointer( - const void * t, - const basic_pointer_oserializer * bpos_ptr - ); - void save_null_pointer(){ - vsave(NULL_POINTER_TAG); - } - // real public interface starts here - void end_preamble(); // default implementation does nothing - library_version_type get_library_version() const; - unsigned int get_flags() const; -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -// required by smart_cast for compilers not implementing -// partial template specialization -BOOST_TT_BROKEN_COMPILER_SPEC( - boost::archive::detail::basic_oarchive -) - -#include // pops abi_suffix.hpp pragmas - -#endif //BOOST_ARCHIVE_BASIC_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oserializer.hpp deleted file mode 100644 index 74af7e65..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_oserializer.hpp +++ /dev/null @@ -1,93 +0,0 @@ -#ifndef BOOST_SERIALIZATION_BASIC_OSERIALIZER_HPP -#define BOOST_SERIALIZATION_BASIC_OSERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_oserializer.hpp: extenstion of type_info required for serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // NULL -#include -#include - -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -// forward declarations -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oarchive; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_oserializer; - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oserializer : - public basic_serializer -{ -private: - basic_pointer_oserializer *m_bpos; -protected: - explicit basic_oserializer( - const boost::serialization::extended_type_info & type_ - ); - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_oserializer(); -public: - bool serialized_as_pointer() const { - return m_bpos != NULL; - } - void set_bpos(basic_pointer_oserializer *bpos){ - m_bpos = bpos; - } - const basic_pointer_oserializer * get_bpos() const { - return m_bpos; - } - virtual void save_object_data( - basic_oarchive & ar, const void * x - ) const = 0; - // returns true if class_info should be saved - virtual bool class_info() const = 0; - // returns true if objects should be tracked - virtual bool tracking(const unsigned int flags) const = 0; - // returns class version - virtual version_type version() const = 0; - // returns true if this class is polymorphic - virtual bool is_polymorphic() const = 0; -}; - -} // namespace detail -} // namespace serialization -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_SERIALIZATION_BASIC_OSERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_iserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_iserializer.hpp deleted file mode 100644 index d957b83e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_iserializer.hpp +++ /dev/null @@ -1,73 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_POINTER_ISERIALIZER_HPP -#define BOOST_ARCHIVE_BASIC_POINTER_ISERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_pointer_oserializer.hpp: extenstion of type_info required for -// serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -// forward declarations -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iserializer; - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_iserializer - : public basic_serializer { -protected: - explicit basic_pointer_iserializer( - const boost::serialization::extended_type_info & type_ - ); - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_pointer_iserializer(); -public: - virtual const basic_iserializer & get_basic_serializer() const = 0; - virtual void load_object_ptr( - basic_iarchive & ar, - void * & x, - const unsigned int file_version - ) const = 0; -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_POINTER_ISERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_oserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_oserializer.hpp deleted file mode 100644 index b0d3fb95..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_pointer_oserializer.hpp +++ /dev/null @@ -1,72 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_POINTER_OSERIALIZER_HPP -#define BOOST_ARCHIVE_BASIC_POINTER_OSERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_pointer_oserializer.hpp: extenstion of type_info required for -// serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oarchive; -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oserializer; - -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_oserializer : - public basic_serializer -{ -protected: - explicit basic_pointer_oserializer( - const boost::serialization::extended_type_info & type_ - ); -public: - // account for bogus gcc warning - #if defined(__GNUC__) - virtual - #endif - ~basic_pointer_oserializer(); - virtual const basic_oserializer & get_basic_serializer() const = 0; - virtual void save_object_ptr( - basic_oarchive & ar, - const void * x - ) const = 0; -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_BASIC_POINTER_OSERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer.hpp deleted file mode 100644 index 5dbd8865..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer.hpp +++ /dev/null @@ -1,79 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_SERIALIZER_HPP -#define BOOST_ARCHIVE_BASIC_SERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_serializer.hpp: extenstion of type_info required for serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL - -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { -namespace detail { - -class basic_serializer : - private boost::noncopyable -{ - const boost::serialization::extended_type_info * m_eti; -protected: - explicit basic_serializer( - const boost::serialization::extended_type_info & eti - ) : - m_eti(& eti) - { - BOOST_ASSERT(NULL != & eti); - } -public: - inline bool - operator<(const basic_serializer & rhs) const { - // can't compare address since there can be multiple eti records - // for the same type in different execution modules (that is, DLLS) - // leave this here as a reminder not to do this! - // return & lhs.get_eti() < & rhs.get_eti(); - return get_eti() < rhs.get_eti(); - } - const char * get_debug_info() const { - return m_eti->get_debug_info(); - } - const boost::serialization::extended_type_info & get_eti() const { - return * m_eti; - } -}; - -class basic_serializer_arg : public basic_serializer { -public: - basic_serializer_arg(const serialization::extended_type_info & eti) : - basic_serializer(eti) - {} -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_BASIC_SERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer_map.hpp deleted file mode 100644 index a991ea1d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/basic_serializer_map.hpp +++ /dev/null @@ -1,69 +0,0 @@ -#ifndef BOOST_SERIALIZER_MAP_HPP -#define BOOST_SERIALIZER_MAP_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_serializer_map.hpp: extenstion of type_info required for serialization. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include -#include - -#include // must be the last header - -namespace boost { -namespace serialization { - class extended_type_info; -} - -namespace archive { -namespace detail { - -class basic_serializer; - -class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_serializer_map : public - boost::noncopyable -{ - struct type_info_pointer_compare - { - bool operator()( - const basic_serializer * lhs, const basic_serializer * rhs - ) const ; - }; - typedef std::set< - const basic_serializer *, - type_info_pointer_compare - > map_type; - map_type m_map; -public: - bool insert(const basic_serializer * bs); - void erase(const basic_serializer * bs); - const basic_serializer * find( - const boost::serialization::extended_type_info & type_ - ) const; -private: - // cw 8.3 requires this - basic_serializer_map& operator=(basic_serializer_map const&); -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#include // must be the last header - -#endif // BOOST_SERIALIZER_MAP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/check.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/check.hpp deleted file mode 100644 index c9cba519..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/check.hpp +++ /dev/null @@ -1,169 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_CHECK_HPP -#define BOOST_ARCHIVE_DETAIL_CHECK_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#pragma inline_depth(511) -#pragma inline_recursion(on) -#endif - -#if defined(__MWERKS__) -#pragma inline_depth(511) -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// check.hpp: interface for serialization system. - -// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -namespace boost { -namespace archive { -namespace detail { - -// checks for objects - -template -inline void check_object_level(){ - typedef - BOOST_DEDUCED_TYPENAME mpl::greater_equal< - serialization::implementation_level< T >, - mpl::int_ - >::type typex; - - // trap attempts to serialize objects marked - // not_serializable - BOOST_STATIC_ASSERT(typex::value); -} - -template -inline void check_object_versioning(){ - typedef - BOOST_DEDUCED_TYPENAME mpl::or_< - BOOST_DEDUCED_TYPENAME mpl::greater< - serialization::implementation_level< T >, - mpl::int_ - >, - BOOST_DEDUCED_TYPENAME mpl::equal_to< - serialization::version< T >, - mpl::int_<0> - > - > typex; - // trap attempts to serialize with objects that don't - // save class information in the archive with versioning. - BOOST_STATIC_ASSERT(typex::value); -} - -template -inline void check_object_tracking(){ - // presume it has already been determined that - // T is not a const - BOOST_STATIC_ASSERT(! boost::is_const< T >::value); - typedef BOOST_DEDUCED_TYPENAME mpl::equal_to< - serialization::tracking_level< T >, - mpl::int_ - >::type typex; - // saving an non-const object of a type not marked "track_never) - - // may be an indicator of an error usage of the - // serialization library and should be double checked. - // See documentation on object tracking. Also, see the - // "rationale" section of the documenation - // for motivation for this checking. - - BOOST_STATIC_WARNING(typex::value); -} - -// checks for pointers - -template -inline void check_pointer_level(){ - // we should only invoke this once we KNOW that T - // has been used as a pointer!! - typedef - BOOST_DEDUCED_TYPENAME mpl::or_< - BOOST_DEDUCED_TYPENAME mpl::greater< - serialization::implementation_level< T >, - mpl::int_ - >, - BOOST_DEDUCED_TYPENAME mpl::not_< - BOOST_DEDUCED_TYPENAME mpl::equal_to< - serialization::tracking_level< T >, - mpl::int_ - > - > - > typex; - // Address the following when serializing to a pointer: - - // a) This type doesn't save class information in the - // archive. That is, the serialization trait implementation - // level <= object_serializable. - // b) Tracking for this type is set to "track selectively" - - // in this case, indication that an object is tracked is - // not stored in the archive itself - see level == object_serializable - // but rather the existence of the operation ar >> T * is used to - // infer that an object of this type should be tracked. So, if - // you save via a pointer but don't load via a pointer the operation - // will fail on load without given any valid reason for the failure. - - // So if your program traps here, consider changing the - // tracking or implementation level traits - or not - // serializing via a pointer. - BOOST_STATIC_WARNING(typex::value); -} - -template -void inline check_pointer_tracking(){ - typedef BOOST_DEDUCED_TYPENAME mpl::greater< - serialization::tracking_level< T >, - mpl::int_ - >::type typex; - // serializing an object of a type marked "track_never" through a pointer - // could result in creating more objects than were saved! - BOOST_STATIC_WARNING(typex::value); -} - -template -inline void check_const_loading(){ - typedef - BOOST_DEDUCED_TYPENAME mpl::or_< - BOOST_DEDUCED_TYPENAME boost::serialization::is_wrapper< T >, - BOOST_DEDUCED_TYPENAME mpl::not_< - BOOST_DEDUCED_TYPENAME boost::is_const< T > - > - >::type typex; - // cannot load data into a "const" object unless it's a - // wrapper around some other non-const object. - BOOST_STATIC_ASSERT(typex::value); -} - -} // detail -} // archive -} // boost - -#endif // BOOST_ARCHIVE_DETAIL_CHECK_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_iarchive.hpp deleted file mode 100644 index 54c07c39..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_iarchive.hpp +++ /dev/null @@ -1,88 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_COMMON_IARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_COMMON_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// common_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { -namespace detail { - -class extended_type_info; - -// note: referred to as Curiously Recurring Template Patter (CRTP) -template -class common_iarchive : - public basic_iarchive, - public interface_iarchive -{ - friend class interface_iarchive; -private: - virtual void vload(version_type & t){ - * this->This() >> t; - } - virtual void vload(object_id_type & t){ - * this->This() >> t; - } - virtual void vload(class_id_type & t){ - * this->This() >> t; - } - virtual void vload(class_id_optional_type & t){ - * this->This() >> t; - } - virtual void vload(tracking_type & t){ - * this->This() >> t; - } - virtual void vload(class_name_type &s){ - * this->This() >> s; - } -protected: - // default processing - invoke serialization library - template - void load_override(T & t, BOOST_PFTO int){ - archive::load(* this->This(), t); - } - // default implementations of functions which emit start/end tags for - // archive types that require them. - void load_start(const char * /*name*/){} - void load_end(const char * /*name*/){} - // default archive initialization - common_iarchive(unsigned int flags = 0) : - basic_iarchive(flags), - interface_iarchive() - {} -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_DETAIL_COMMON_IARCHIVE_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_oarchive.hpp deleted file mode 100644 index 7962063a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/common_oarchive.hpp +++ /dev/null @@ -1,87 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_COMMON_OARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_COMMON_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// common_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { -namespace detail { - -// note: referred to as Curiously Recurring Template Patter (CRTP) -template -class common_oarchive : - public basic_oarchive, - public interface_oarchive -{ - friend class interface_oarchive; -private: - virtual void vsave(const version_type t){ - * this->This() << t; - } - virtual void vsave(const object_id_type t){ - * this->This() << t; - } - virtual void vsave(const object_reference_type t){ - * this->This() << t; - } - virtual void vsave(const class_id_type t){ - * this->This() << t; - } - virtual void vsave(const class_id_reference_type t){ - * this->This() << t; - } - virtual void vsave(const class_id_optional_type t){ - * this->This() << t; - } - virtual void vsave(const class_name_type & t){ - * this->This() << t; - } - virtual void vsave(const tracking_type t){ - * this->This() << t; - } -protected: - // default processing - invoke serialization library - template - void save_override(T & t, BOOST_PFTO int){ - archive::save(* this->This(), t); - } - void save_start(const char * /*name*/){} - void save_end(const char * /*name*/){} - common_oarchive(unsigned int flags = 0) : - basic_oarchive(flags), - interface_oarchive() - {} -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_DETAIL_COMMON_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/decl.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/decl.hpp deleted file mode 100644 index 9695001a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/decl.hpp +++ /dev/null @@ -1,79 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_DECL_HPP -#define BOOST_ARCHIVE_DETAIL_DECL_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2///////// 3/////////4/////////5/////////6/////////7/////////8 -// decl.hpp -// -// (c) Copyright Robert Ramey 2004 -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See library home page at http://www.boost.org/libs/serialization - -//----------------------------------------------------------------------------// - -// This header implements separate compilation features as described in -// http://www.boost.org/more/separate_compilation.html - -#include -#include - -#if defined(BOOST_HAS_DECLSPEC) - #if (defined(BOOST_ALL_DYN_LINK) || defined(BOOST_SERIALIZATION_DYN_LINK)) - #if defined(BOOST_ARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_DECL(T) T __export - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __export - #else - #define BOOST_ARCHIVE_DECL(T) __declspec(dllexport) T - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllexport) T - #endif - #else - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_DECL(T) T __import - #else - #define BOOST_ARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif - #if defined(BOOST_WARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_WARCHIVE_DECL(T) T __export - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __export - #else - #define BOOST_WARCHIVE_DECL(T) __declspec(dllexport) T - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllexport) T - #endif - #else - #if defined(__BORLANDC__) - #define BOOST_WARCHIVE_DECL(T) T __import - #else - #define BOOST_WARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif - #if !defined(BOOST_WARCHIVE_SOURCE) && !defined(BOOST_ARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __import - #else - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif - #endif -#endif // BOOST_HAS_DECLSPEC - -#if ! defined(BOOST_ARCHIVE_DECL) - #define BOOST_ARCHIVE_DECL(T) T -#endif -#if ! defined(BOOST_WARCHIVE_DECL) - #define BOOST_WARCHIVE_DECL(T) T -#endif -#if ! defined(BOOST_ARCHIVE_OR_WARCHIVE_DECL) - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T -#endif - -#endif // BOOST_ARCHIVE_DETAIL_DECL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_iarchive.hpp deleted file mode 100644 index 06487521..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_iarchive.hpp +++ /dev/null @@ -1,77 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_INTERFACE_IARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_INTERFACE_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// interface_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include // NULL -#include -#include -#include -#include -#include -#include // must be the last header - -namespace boost { -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_iserializer; - -template -class interface_iarchive -{ -protected: - interface_iarchive(){}; -public: - ///////////////////////////////////////////////////////// - // archive public interface - typedef mpl::bool_ is_loading; - typedef mpl::bool_ is_saving; - - // return a pointer to the most derived class - Archive * This(){ - return static_cast(this); - } - - template - const basic_pointer_iserializer * - register_type(T * = NULL){ - const basic_pointer_iserializer & bpis = - boost::serialization::singleton< - pointer_iserializer - >::get_const_instance(); - this->This()->register_basic_serializer(bpis.get_basic_serializer()); - return & bpis; - } - template - Archive & operator>>(T & t){ - this->This()->load_override(t, 0); - return * this->This(); - } - - // the & operator - template - Archive & operator&(T & t){ - return *(this->This()) >> t; - } -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_DETAIL_INTERFACE_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_oarchive.hpp deleted file mode 100644 index e8db7a2b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/interface_oarchive.hpp +++ /dev/null @@ -1,84 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_INTERFACE_OARCHIVE_HPP -#define BOOST_ARCHIVE_DETAIL_INTERFACE_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// interface_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include // NULL -#include -#include - -#include -#include -#include // must be the last header - -#include - -namespace boost { -namespace archive { -namespace detail { - -class BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) basic_pointer_oserializer; - -template -class interface_oarchive -{ -protected: - interface_oarchive(){}; -public: - ///////////////////////////////////////////////////////// - // archive public interface - typedef mpl::bool_ is_loading; - typedef mpl::bool_ is_saving; - - // return a pointer to the most derived class - Archive * This(){ - return static_cast(this); - } - - template - const basic_pointer_oserializer * - register_type(const T * = NULL){ - const basic_pointer_oserializer & bpos = - boost::serialization::singleton< - pointer_oserializer - >::get_const_instance(); - this->This()->register_basic_serializer(bpos.get_basic_serializer()); - return & bpos; - } - - template - Archive & operator<<(T & t){ - this->This()->save_override(t, 0); - return * this->This(); - } - - // the & operator - template - Archive & operator&(T & t){ - #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - return * this->This() << const_cast(t); - #else - return * this->This() << t; - #endif - } -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_DETAIL_INTERFACE_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/iserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/iserializer.hpp deleted file mode 100644 index 53765af3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/iserializer.hpp +++ /dev/null @@ -1,632 +0,0 @@ -#ifndef BOOST_ARCHIVE_DETAIL_ISERIALIZER_HPP -#define BOOST_ARCHIVE_DETAIL_ISERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#pragma inline_depth(511) -#pragma inline_recursion(on) -#endif - -#if defined(__MWERKS__) -#pragma inline_depth(511) -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// iserializer.hpp: interface for serialization system. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // for placement new -#include // for auto_ptr -#include // size_t, NULL - -#include -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include - -#include -#include -#include -#include -#include -#include - -#ifndef BOOST_SERIALIZATION_DEFAULT_TYPE_INFO - #include -#endif -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include - -#define DONT_USE_HAS_NEW_OPERATOR ( \ - defined(__BORLANDC__) \ - || BOOST_WORKAROUND(__IBMCPP__, < 1210) \ - || defined(BOOST_MSVC) && (BOOST_MSVC <= 1300) \ - || defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x590) \ -) - -#if ! DONT_USE_HAS_NEW_OPERATOR -#include -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -// the following is need only for dynamic cast of polymorphic pointers -#include -#include -#include -#include -#include -#include - -namespace boost { - -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { - -// an accessor to permit friend access to archives. Needed because -// some compilers don't handle friend templates completely -class load_access { -public: - template - static void load_primitive(Archive &ar, T &t){ - ar.load(t); - } -}; - -namespace detail { - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -template -class iserializer : public basic_iserializer -{ -private: - virtual void destroy(/*const*/ void *address) const { - boost::serialization::access::destroy(static_cast(address)); - } -protected: - // protected constructor since it's always created by singleton - explicit iserializer() : - basic_iserializer( - boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance() - ) - {} -public: - virtual BOOST_DLLEXPORT void load_object_data( - basic_iarchive & ar, - void *x, - const unsigned int file_version - ) const BOOST_USED; - virtual bool class_info() const { - return boost::serialization::implementation_level< T >::value - >= boost::serialization::object_class_info; - } - virtual bool tracking(const unsigned int /* flags */) const { - return boost::serialization::tracking_level< T >::value - == boost::serialization::track_always - || ( boost::serialization::tracking_level< T >::value - == boost::serialization::track_selectively - && serialized_as_pointer()); - } - virtual version_type version() const { - return version_type(::boost::serialization::version< T >::value); - } - virtual bool is_polymorphic() const { - return boost::is_polymorphic< T >::value; - } - virtual ~iserializer(){}; -}; - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -template -BOOST_DLLEXPORT void iserializer::load_object_data( - basic_iarchive & ar, - void *x, - const unsigned int file_version -) const { - // note: we now comment this out. Before we permited archive - // version # to be very large. Now we don't. To permit - // readers of these old archives, we have to suppress this - // code. Perhaps in the future we might re-enable it but - // permit its suppression with a runtime switch. - #if 0 - // trap case where the program cannot handle the current version - if(file_version > static_cast(version())) - boost::serialization::throw_exception( - archive::archive_exception( - boost::archive::archive_exception::unsupported_class_version, - get_debug_info() - ) - ); - #endif - // make sure call is routed through the higest interface that might - // be specialized by the user. - boost::serialization::serialize_adl( - boost::serialization::smart_cast_reference(ar), - * static_cast(x), - file_version - ); -} - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -template -class pointer_iserializer : - public basic_pointer_iserializer -{ -private: - virtual const basic_iserializer & get_basic_serializer() const { - return boost::serialization::singleton< - iserializer - >::get_const_instance(); - } - BOOST_DLLEXPORT virtual void load_object_ptr( - basic_iarchive & ar, - void * & x, - const unsigned int file_version - ) const BOOST_USED; -protected: - // this should alway be a singleton so make the constructor protected - pointer_iserializer(); - ~pointer_iserializer(); -}; - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -// note trick to be sure that operator new is using class specific -// version if such exists. Due to Peter Dimov. -// note: the following fails if T has no default constructor. -// otherwise it would have been ideal -//struct heap_allocator : public T -//{ -// T * invoke(){ -// return ::new(sizeof(T)); -// } -//} - -template -struct heap_allocator -{ - // boost::has_new_operator< T > doesn't work on these compilers - #if DONT_USE_HAS_NEW_OPERATOR - // This doesn't handle operator new overload for class T - static T * invoke(){ - return static_cast(operator new(sizeof(T))); - } - #else - struct has_new_operator { - static T* invoke() { - return static_cast((T::operator new)(sizeof(T))); - } - }; - struct doesnt_have_new_operator { - static T* invoke() { - return static_cast(operator new(sizeof(T))); - } - }; - static T * invoke() { - typedef BOOST_DEDUCED_TYPENAME - mpl::eval_if< - boost::has_new_operator< T >, - mpl::identity, - mpl::identity - >::type typex; - return typex::invoke(); - } - #endif -}; - -// due to Martin Ecker -template -class auto_ptr_with_deleter -{ -public: - explicit auto_ptr_with_deleter(T* p) : - m_p(p) - {} - ~auto_ptr_with_deleter(){ - if (m_p) - boost::serialization::access::destroy(m_p); - } - T* get() const { - return m_p; - } - - T* release() { - T* p = m_p; - m_p = NULL; - return p; - } -private: - T* m_p; -}; - -// note: BOOST_DLLEXPORT is so that code for polymorphic class -// serialized only through base class won't get optimized out -template -BOOST_DLLEXPORT void pointer_iserializer::load_object_ptr( - basic_iarchive & ar, - void * & x, - const unsigned int file_version -) const -{ - Archive & ar_impl = - boost::serialization::smart_cast_reference(ar); - - auto_ptr_with_deleter< T > ap(heap_allocator< T >::invoke()); - if(NULL == ap.get()) - boost::serialization::throw_exception(std::bad_alloc()) ; - - T * t = ap.get(); - x = t; - - // catch exception during load_construct_data so that we don't - // automatically delete the t which is most likely not fully - // constructed - BOOST_TRY { - // this addresses an obscure situtation that occurs when - // load_constructor de-serializes something through a pointer. - ar.next_object_pointer(t); - boost::serialization::load_construct_data_adl( - ar_impl, - t, - file_version - ); - } - BOOST_CATCH(...){ - ap.release(); - BOOST_RETHROW; - } - BOOST_CATCH_END - - ar_impl >> boost::serialization::make_nvp(NULL, * t); - ap.release(); -} - -template -pointer_iserializer::pointer_iserializer() : - basic_pointer_iserializer( - boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance() - ) -{ - boost::serialization::singleton< - iserializer - >::get_mutable_instance().set_bpis(this); - archive_serializer_map::insert(this); -} - -template -pointer_iserializer::~pointer_iserializer(){ - archive_serializer_map::erase(this); -} - -template -struct load_non_pointer_type { - // note this bounces the call right back to the archive - // with no runtime overhead - struct load_primitive { - template - static void invoke(Archive & ar, T & t){ - load_access::load_primitive(ar, t); - } - }; - // note this bounces the call right back to the archive - // with no runtime overhead - struct load_only { - template - static void invoke(Archive & ar, const T & t){ - // short cut to user's serializer - // make sure call is routed through the higest interface that might - // be specialized by the user. - boost::serialization::serialize_adl( - ar, - const_cast(t), - boost::serialization::version< T >::value - ); - } - }; - - // note this save class information including version - // and serialization level to the archive - struct load_standard { - template - static void invoke(Archive &ar, const T & t){ - void * x = & const_cast(t); - ar.load_object( - x, - boost::serialization::singleton< - iserializer - >::get_const_instance() - ); - } - }; - - struct load_conditional { - template - static void invoke(Archive &ar, T &t){ - //if(0 == (ar.get_flags() & no_tracking)) - load_standard::invoke(ar, t); - //else - // load_only::invoke(ar, t); - } - }; - - template - static void invoke(Archive & ar, T &t){ - typedef BOOST_DEDUCED_TYPENAME mpl::eval_if< - // if its primitive - mpl::equal_to< - boost::serialization::implementation_level< T >, - mpl::int_ - >, - mpl::identity, - // else - BOOST_DEDUCED_TYPENAME mpl::eval_if< - // class info / version - mpl::greater_equal< - boost::serialization::implementation_level< T >, - mpl::int_ - >, - // do standard load - mpl::identity, - // else - BOOST_DEDUCED_TYPENAME mpl::eval_if< - // no tracking - mpl::equal_to< - boost::serialization::tracking_level< T >, - mpl::int_ - >, - // do a fast load - mpl::identity, - // else - // do a fast load only tracking is turned off - mpl::identity - > > >::type typex; - check_object_versioning< T >(); - check_object_level< T >(); - typex::invoke(ar, t); - } -}; - -template -struct load_pointer_type { - struct abstract - { - template - static const basic_pointer_iserializer * register_type(Archive & /* ar */){ - // it has? to be polymorphic - BOOST_STATIC_ASSERT(boost::is_polymorphic< T >::value); - return static_cast(NULL); - } - }; - - struct non_abstract - { - template - static const basic_pointer_iserializer * register_type(Archive & ar){ - return ar.register_type(static_cast(NULL)); - } - }; - - template - static const basic_pointer_iserializer * register_type(Archive &ar, const T & /*t*/){ - // there should never be any need to load an abstract polymorphic - // class pointer. Inhibiting code generation for this - // permits abstract base classes to be used - note: exception - // virtual serialize functions used for plug-ins - typedef BOOST_DEDUCED_TYPENAME - mpl::eval_if< - boost::serialization::is_abstract, - boost::mpl::identity, - boost::mpl::identity - >::type typex; - return typex::template register_type< T >(ar); - } - - template - static T * pointer_tweak( - const boost::serialization::extended_type_info & eti, - void const * const t, - const T & - ) { - // tweak the pointer back to the base class - return static_cast( - const_cast( - boost::serialization::void_upcast( - eti, - boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance(), - t - ) - ) - ); - } - - template - static void check_load(T & /* t */){ - check_pointer_level< T >(); - check_pointer_tracking< T >(); - } - - static const basic_pointer_iserializer * - find(const boost::serialization::extended_type_info & type){ - return static_cast( - archive_serializer_map::find(type) - ); - } - - template - static void invoke(Archive & ar, Tptr & t){ - check_load(*t); - const basic_pointer_iserializer * bpis_ptr = register_type(ar, *t); - const basic_pointer_iserializer * newbpis_ptr = ar.load_pointer( - // note major hack here !!! - // I tried every way to convert Tptr &t (where Tptr might - // include const) to void * &. This is the only way - // I could make it work. RR - (void * & )t, - bpis_ptr, - find - ); - // if the pointer isn't that of the base class - if(newbpis_ptr != bpis_ptr){ - t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); - } - } -}; - -template -struct load_enum_type { - template - static void invoke(Archive &ar, T &t){ - // convert integers to correct enum to load - int i; - ar >> boost::serialization::make_nvp(NULL, i); - t = static_cast< T >(i); - } -}; - -template -struct load_array_type { - template - static void invoke(Archive &ar, T &t){ - typedef BOOST_DEDUCED_TYPENAME remove_extent< T >::type value_type; - - // convert integers to correct enum to load - // determine number of elements in the array. Consider the - // fact that some machines will align elements on boundries - // other than characters. - std::size_t current_count = sizeof(t) / ( - static_cast(static_cast(&t[1])) - - static_cast(static_cast(&t[0])) - ); - boost::serialization::collection_size_type count; - ar >> BOOST_SERIALIZATION_NVP(count); - if(static_cast(count) > current_count) - boost::serialization::throw_exception( - archive::archive_exception( - boost::archive::archive_exception::array_size_too_short - ) - ); - ar >> serialization::make_array(static_cast(&t[0]),count); - } -}; - -} // detail - -template -inline void load(Archive & ar, T &t){ - // if this assertion trips. It means we're trying to load a - // const object with a compiler that doesn't have correct - // funtion template ordering. On other compilers, this is - // handled below. - detail::check_const_loading< T >(); - typedef - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity > - ,//else - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity > - ,//else - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity > - ,//else - mpl::identity > - > - > - >::type typex; - typex::invoke(ar, t); -} - -#if 0 - -// BORLAND -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x560)) -// borland has a couple of problems -// a) if function is partially specialized - see below -// const paramters are transformed to non-const ones -// b) implementation of base_object can't be made to work -// correctly which results in all base_object s being const. -// So, strip off the const for borland. This breaks the trap -// for loading const objects - but I see no alternative -template -inline void load(Archive &ar, const T & t){ - load(ar, const_cast(t)); -} -#endif - -// let wrappers through. -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline void load_wrapper(Archive &ar, const T&t, mpl::true_){ - boost::archive::load(ar, const_cast(t)); -} - -#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x560)) -template -inline void load(Archive &ar, const T&t){ - load_wrapper(ar,t,serialization::is_wrapper< T >()); -} -#endif -#endif - -#endif - -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_DETAIL_ISERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/oserializer.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/oserializer.hpp deleted file mode 100644 index 7d2694d7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/oserializer.hpp +++ /dev/null @@ -1,531 +0,0 @@ -#ifndef BOOST_ARCHIVE_OSERIALIZER_HPP -#define BOOST_ARCHIVE_OSERIALIZER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#pragma inline_depth(511) -#pragma inline_recursion(on) -#endif - -#if defined(__MWERKS__) -#pragma inline_depth(511) -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// oserializer.hpp: interface for serialization system. - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL - -#include -#include -#include - -#include -#include -#include -#include - -#ifndef BOOST_SERIALIZATION_DEFAULT_TYPE_INFO - #include -#endif -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -namespace boost { - -namespace serialization { - class extended_type_info; -} // namespace serialization - -namespace archive { - -// an accessor to permit friend access to archives. Needed because -// some compilers don't handle friend templates completely -class save_access { -public: - template - static void end_preamble(Archive & ar){ - ar.end_preamble(); - } - template - static void save_primitive(Archive & ar, const T & t){ - ar.end_preamble(); - ar.save(t); - } -}; - -namespace detail { - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -template -class oserializer : public basic_oserializer -{ -private: - // private constructor to inhibit any existence other than the - // static one -public: - explicit BOOST_DLLEXPORT oserializer() : - basic_oserializer( - boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance() - ) - {} - virtual BOOST_DLLEXPORT void save_object_data( - basic_oarchive & ar, - const void *x - ) const BOOST_USED; - virtual bool class_info() const { - return boost::serialization::implementation_level< T >::value - >= boost::serialization::object_class_info; - } - virtual bool tracking(const unsigned int /* flags */) const { - return boost::serialization::tracking_level< T >::value == boost::serialization::track_always - || (boost::serialization::tracking_level< T >::value == boost::serialization::track_selectively - && serialized_as_pointer()); - } - virtual version_type version() const { - return version_type(::boost::serialization::version< T >::value); - } - virtual bool is_polymorphic() const { - return boost::is_polymorphic< T >::value; - } - virtual ~oserializer(){} -}; - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -template -BOOST_DLLEXPORT void oserializer::save_object_data( - basic_oarchive & ar, - const void *x -) const { - // make sure call is routed through the highest interface that might - // be specialized by the user. - BOOST_STATIC_ASSERT(boost::is_const< T >::value == false); - boost::serialization::serialize_adl( - boost::serialization::smart_cast_reference(ar), - * static_cast(const_cast(x)), - version() - ); -} - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -template -class pointer_oserializer : - public basic_pointer_oserializer -{ -private: - const basic_oserializer & - get_basic_serializer() const { - return boost::serialization::singleton< - oserializer - >::get_const_instance(); - } - virtual BOOST_DLLEXPORT void save_object_ptr( - basic_oarchive & ar, - const void * x - ) const BOOST_USED; -public: - pointer_oserializer(); - ~pointer_oserializer(); -}; - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -template -BOOST_DLLEXPORT void pointer_oserializer::save_object_ptr( - basic_oarchive & ar, - const void * x -) const { - BOOST_ASSERT(NULL != x); - // make sure call is routed through the highest interface that might - // be specialized by the user. - T * t = static_cast(const_cast(x)); - const unsigned int file_version = boost::serialization::version< T >::value; - Archive & ar_impl - = boost::serialization::smart_cast_reference(ar); - boost::serialization::save_construct_data_adl( - ar_impl, - t, - file_version - ); - ar_impl << boost::serialization::make_nvp(NULL, * t); -} - -template -pointer_oserializer::pointer_oserializer() : - basic_pointer_oserializer( - boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance() - ) -{ - // make sure appropriate member function is instantiated - boost::serialization::singleton< - oserializer - >::get_mutable_instance().set_bpos(this); - archive_serializer_map::insert(this); -} - -template -pointer_oserializer::~pointer_oserializer(){ - archive_serializer_map::erase(this); -} - -template -struct save_non_pointer_type { - // note this bounces the call right back to the archive - // with no runtime overhead - struct save_primitive { - template - static void invoke(Archive & ar, const T & t){ - save_access::save_primitive(ar, t); - } - }; - // same as above but passes through serialization - struct save_only { - template - static void invoke(Archive & ar, const T & t){ - // make sure call is routed through the highest interface that might - // be specialized by the user. - boost::serialization::serialize_adl( - ar, - const_cast(t), - ::boost::serialization::version< T >::value - ); - } - }; - // adds class information to the archive. This includes - // serialization level and class version - struct save_standard { - template - static void invoke(Archive &ar, const T & t){ - ar.save_object( - & t, - boost::serialization::singleton< - oserializer - >::get_const_instance() - ); - } - }; - - // adds class information to the archive. This includes - // serialization level and class version - struct save_conditional { - template - static void invoke(Archive &ar, const T &t){ - //if(0 == (ar.get_flags() & no_tracking)) - save_standard::invoke(ar, t); - //else - // save_only::invoke(ar, t); - } - }; - - - template - static void invoke(Archive & ar, const T & t){ - typedef - BOOST_DEDUCED_TYPENAME mpl::eval_if< - // if its primitive - mpl::equal_to< - boost::serialization::implementation_level< T >, - mpl::int_ - >, - mpl::identity, - // else - BOOST_DEDUCED_TYPENAME mpl::eval_if< - // class info / version - mpl::greater_equal< - boost::serialization::implementation_level< T >, - mpl::int_ - >, - // do standard save - mpl::identity, - // else - BOOST_DEDUCED_TYPENAME mpl::eval_if< - // no tracking - mpl::equal_to< - boost::serialization::tracking_level< T >, - mpl::int_ - >, - // do a fast save - mpl::identity, - // else - // do a fast save only tracking is turned off - mpl::identity - > > >::type typex; - check_object_versioning< T >(); - typex::invoke(ar, t); - } - template - static void invoke(Archive & ar, T & t){ - check_object_level< T >(); - check_object_tracking< T >(); - invoke(ar, const_cast(t)); - } -}; - -template -struct save_pointer_type { - struct abstract - { - template - static const basic_pointer_oserializer * register_type(Archive & /* ar */){ - // it has? to be polymorphic - BOOST_STATIC_ASSERT(boost::is_polymorphic< T >::value); - return NULL; - } - }; - - struct non_abstract - { - template - static const basic_pointer_oserializer * register_type(Archive & ar){ - return ar.register_type(static_cast(NULL)); - } - }; - - template - static const basic_pointer_oserializer * register_type(Archive &ar, T & /*t*/){ - // there should never be any need to save an abstract polymorphic - // class pointer. Inhibiting code generation for this - // permits abstract base classes to be used - note: exception - // virtual serialize functions used for plug-ins - typedef - BOOST_DEDUCED_TYPENAME mpl::eval_if< - boost::serialization::is_abstract< T >, - mpl::identity, - mpl::identity - >::type typex; - return typex::template register_type< T >(ar); - } - - struct non_polymorphic - { - template - static void save( - Archive &ar, - T & t - ){ - const basic_pointer_oserializer & bpos = - boost::serialization::singleton< - pointer_oserializer - >::get_const_instance(); - // save the requested pointer type - ar.save_pointer(& t, & bpos); - } - }; - - struct polymorphic - { - template - static void save( - Archive &ar, - T & t - ){ - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type const - & i = boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance(); - - boost::serialization::extended_type_info const * const this_type = & i; - - // retrieve the true type of the object pointed to - // if this assertion fails its an error in this library - BOOST_ASSERT(NULL != this_type); - - const boost::serialization::extended_type_info * true_type = - i.get_derived_extended_type_info(t); - - // note:if this exception is thrown, be sure that derived pointer - // is either registered or exported. - if(NULL == true_type){ - boost::serialization::throw_exception( - archive_exception( - archive_exception::unregistered_class, - "derived class not registered or exported" - ) - ); - } - - // if its not a pointer to a more derived type - const void *vp = static_cast(&t); - if(*this_type == *true_type){ - const basic_pointer_oserializer * bpos = register_type(ar, t); - ar.save_pointer(vp, bpos); - return; - } - // convert pointer to more derived type. if this is thrown - // it means that the base/derived relationship hasn't be registered - vp = serialization::void_downcast( - *true_type, - *this_type, - static_cast(&t) - ); - if(NULL == vp){ - boost::serialization::throw_exception( - archive_exception( - archive_exception::unregistered_cast, - true_type->get_debug_info(), - this_type->get_debug_info() - ) - ); - } - - // since true_type is valid, and this only gets made if the - // pointer oserializer object has been created, this should never - // fail - const basic_pointer_oserializer * bpos - = static_cast( - boost::serialization::singleton< - archive_serializer_map - >::get_const_instance().find(*true_type) - ); - BOOST_ASSERT(NULL != bpos); - if(NULL == bpos) - boost::serialization::throw_exception( - archive_exception( - archive_exception::unregistered_class, - "derived class not registered or exported" - ) - ); - ar.save_pointer(vp, bpos); - } - }; - - template - static void save( - Archive & ar, - const T & t - ){ - check_pointer_level< T >(); - check_pointer_tracking< T >(); - typedef BOOST_DEDUCED_TYPENAME mpl::eval_if< - is_polymorphic< T >, - mpl::identity, - mpl::identity - >::type type; - type::save(ar, const_cast(t)); - } - - template - static void invoke(Archive &ar, const TPtr t){ - register_type(ar, * t); - if(NULL == t){ - basic_oarchive & boa - = boost::serialization::smart_cast_reference(ar); - boa.save_null_pointer(); - save_access::end_preamble(ar); - return; - } - save(ar, * t); - } -}; - -template -struct save_enum_type -{ - template - static void invoke(Archive &ar, const T &t){ - // convert enum to integers on save - const int i = static_cast(t); - ar << boost::serialization::make_nvp(NULL, i); - } -}; - -template -struct save_array_type -{ - template - static void invoke(Archive &ar, const T &t){ - typedef BOOST_DEDUCED_TYPENAME boost::remove_extent< T >::type value_type; - - save_access::end_preamble(ar); - // consider alignment - std::size_t c = sizeof(t) / ( - static_cast(static_cast(&t[1])) - - static_cast(static_cast(&t[0])) - ); - boost::serialization::collection_size_type count(c); - ar << BOOST_SERIALIZATION_NVP(count); - ar << serialization::make_array(static_cast(&t[0]),count); - } -}; - -} // detail - -template -inline void save(Archive & ar, /*const*/ T &t){ - typedef - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity >, - //else - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity >, - //else - BOOST_DEDUCED_TYPENAME mpl::eval_if, - mpl::identity >, - //else - mpl::identity > - > - > - >::type typex; - typex::invoke(ar, t); -} - -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_OSERIALIZER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/register_archive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/register_archive.hpp deleted file mode 100644 index e31ae46c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/register_archive.hpp +++ /dev/null @@ -1,91 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_ARCHIVE_DETAIL_REGISTER_ARCHIVE_DWA2006521_HPP -# define BOOST_ARCHIVE_DETAIL_REGISTER_ARCHIVE_DWA2006521_HPP - -namespace boost { namespace archive { namespace detail { - -// No instantiate_ptr_serialization overloads generated by -// BOOST_SERIALIZATION_REGISTER_ARCHIVE that lexically follow the call -// will be seen *unless* they are in an associated namespace of one of -// the arguments, so we pass one of these along to make sure this -// namespace is considered. See temp.dep.candidate (14.6.4.2) in the -// standard. -struct adl_tag {}; - -template -struct ptr_serialization_support; - -// We could've just used ptr_serialization_support, above, but using -// it with only a forward declaration causes vc6/7 to complain about a -// missing instantiate member, even if it has one. This is just a -// friendly layer of indirection. -template -struct _ptr_serialization_support - : ptr_serialization_support -{ - typedef int type; -}; - -#ifdef __SUNPRO_CC - -template -struct counter : counter {}; -template<> -struct counter<0> {}; - -template -void instantiate_ptr_serialization(Serializable* s, int, adl_tag) { - instantiate_ptr_serialization(s, counter<20>()); -} - -template -struct get_counter { - static const int value = sizeof(adjust_counter(counter<20>())); - typedef counter type; - typedef counter prior; - typedef char (&next)[value+1]; -}; - -char adjust_counter(counter<0>); -template -void instantiate_ptr_serialization(Serializable*, counter<0>) {} - -#define BOOST_SERIALIZATION_REGISTER_ARCHIVE(Archive) \ -namespace boost { namespace archive { namespace detail { \ - get_counter::next adjust_counter(get_counter::type);\ - template \ - void instantiate_ptr_serialization(Serializable* s, \ - get_counter::type) { \ - ptr_serialization_support x; \ - instantiate_ptr_serialization(s, get_counter::prior()); \ - }\ -}}} - - -#else - -// This function gets called, but its only purpose is to participate -// in overload resolution with the functions declared by -// BOOST_SERIALIZATION_REGISTER_ARCHIVE, below. -template -void instantiate_ptr_serialization(Serializable*, int, adl_tag ) {} - -// The function declaration generated by this macro never actually -// gets called, but its return type gets instantiated, and that's -// enough to cause registration of serialization functions between -// Archive and any exported Serializable type. See also: -// boost/serialization/export.hpp -# define BOOST_SERIALIZATION_REGISTER_ARCHIVE(Archive) \ -namespace boost { namespace archive { namespace detail { \ - \ -template \ -BOOST_DEDUCED_TYPENAME _ptr_serialization_support::type \ -instantiate_ptr_serialization( Serializable*, Archive*, adl_tag ); \ - \ -}}} -#endif -}}} // namespace boost::archive::detail - -#endif // BOOST_ARCHIVE_DETAIL_INSTANTIATE_SERIALIZE_DWA2006521_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/utf8_codecvt_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/detail/utf8_codecvt_facet.hpp deleted file mode 100644 index bd859ffe..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/detail/utf8_codecvt_facet.hpp +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright (c) 2001 Ronald Garcia, Indiana University (garcia@osl.iu.edu) -// Andrew Lumsdaine, Indiana University (lums@osl.iu.edu). -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP -#define BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP - -#define BOOST_UTF8_BEGIN_NAMESPACE \ - namespace boost { namespace archive { namespace detail { -#define BOOST_UTF8_DECL -#define BOOST_UTF8_END_NAMESPACE }}} - -#include - -#undef BOOST_UTF8_END_NAMESPACE -#undef BOOST_UTF8_DECL -#undef BOOST_UTF8_BEGIN_NAMESPACE - -#endif // BOOST_ARCHIVE_DETAIL_UTF8_CODECVT_FACET_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/dinkumware.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/dinkumware.hpp deleted file mode 100644 index bfa828d5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/dinkumware.hpp +++ /dev/null @@ -1,224 +0,0 @@ -#ifndef BOOST_ARCHIVE_DINKUMWARE_HPP -#define BOOST_ARCHIVE_DINKUMWARE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// dinkumware.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// this file adds a couple of things that are missing from the dinkumware -// implementation of the standard library. - -#include -#include - -#include -#include - -namespace std { - -// define i/o operators for 64 bit integers -template -basic_ostream & -operator<<(basic_ostream & os, boost::uint64_t t){ - // octal rendering of 64 bit number would be 22 octets + eos - CharType d[23]; - unsigned int radix; - - if(os.flags() & (int)std::ios_base::hex) - radix = 16; - else - if(os.flags() & (int)std::ios_base::oct) - radix = 8; - else - //if(s.flags() & (int)std::ios_base::dec) - radix = 10; - unsigned int i = 0; - do{ - unsigned int j = t % radix; - d[i++] = j + ((j < 10) ? '0' : ('a' - 10)); - t /= radix; - } - while(t > 0); - d[i--] = '\0'; - - // reverse digits - unsigned int j = 0; - while(j < i){ - CharType k = d[i]; - d[i] = d[j]; - d[j] = k; - --i;++j; - } - os << d; - return os; - -} - -template -basic_ostream & -operator<<(basic_ostream &os, boost::int64_t t){ - if(0 <= t){ - os << static_cast(t); - } - else{ - os.put('-'); - os << -t; - } - return os; -} - -template -basic_istream & -operator>>(basic_istream &is, boost::int64_t & t){ - CharType d; - do{ - d = is.get(); - } - while(::isspace(d)); - bool negative = (d == '-'); - if(negative) - d = is.get(); - unsigned int radix; - if(is.flags() & (int)std::ios_base::hex) - radix = 16; - else - if(is.flags() & (int)std::ios_base::oct) - radix = 8; - else - //if(s.flags() & (int)std::ios_base::dec) - radix = 10; - t = 0; - do{ - if('0' <= d && d <= '9') - t = t * radix + (d - '0'); - else - if('a' <= d && d <= 'f') - t = t * radix + (d - 'a' + 10); - else - break; - d = is.get(); - } - while(!is.fail()); - // restore the delimiter - is.putback(d); - is.clear(); - if(negative) - t = -t; - return is; -} - -template -basic_istream & -operator>>(basic_istream &is, boost::uint64_t & t){ - boost::int64_t it; - is >> it; - t = it; - return is; -} - -//#endif - -template<> -class back_insert_iterator > : public - iterator -{ -public: - typedef basic_string container_type; - typedef container_type::reference reference; - - explicit back_insert_iterator(container_type & s) - : container(& s) - {} // construct with container - - back_insert_iterator & operator=( - container_type::const_reference Val_ - ){ // push value into container - //container->push_back(Val_); - *container += Val_; - return (*this); - } - - back_insert_iterator & operator*(){ - return (*this); - } - - back_insert_iterator & operator++(){ - // pretend to preincrement - return (*this); - } - - back_insert_iterator operator++(int){ - // pretend to postincrement - return (*this); - } - -protected: - container_type *container; // pointer to container -}; - -template -inline back_insert_iterator > back_inserter( - basic_string & s -){ - return (std::back_insert_iterator >(s)); -} - -template<> -class back_insert_iterator > : public - iterator -{ -public: - typedef basic_string container_type; - typedef container_type::reference reference; - - explicit back_insert_iterator(container_type & s) - : container(& s) - {} // construct with container - - back_insert_iterator & operator=( - container_type::const_reference Val_ - ){ // push value into container - //container->push_back(Val_); - *container += Val_; - return (*this); - } - - back_insert_iterator & operator*(){ - return (*this); - } - - back_insert_iterator & operator++(){ - // pretend to preincrement - return (*this); - } - - back_insert_iterator operator++(int){ - // pretend to postincrement - return (*this); - } - -protected: - container_type *container; // pointer to container -}; - -template -inline back_insert_iterator > back_inserter( - basic_string & s -){ - return (std::back_insert_iterator >(s)); -} - -} // namespace std - -#endif //BOOST_ARCHIVE_DINKUMWARE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/archive_serializer_map.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/archive_serializer_map.ipp deleted file mode 100644 index c8ad96b3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/archive_serializer_map.ipp +++ /dev/null @@ -1,71 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// archive_serializer_map.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -////////////////////////////////////////////////////////////////////// -// implementation of basic_text_iprimitive overrides for the combination -// of template parameters used to implement a text_iprimitive - -#include -#include -#include -#include - -namespace boost { -namespace archive { -namespace detail { - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace extra_detail { // anon - template - class map : public basic_serializer_map - {}; -} - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(bool) -archive_serializer_map::insert(const basic_serializer * bs){ - return boost::serialization::singleton< - extra_detail::map - >::get_mutable_instance().insert(bs); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -archive_serializer_map::erase(const basic_serializer * bs){ - if(boost::serialization::singleton< - extra_detail::map - >::is_destroyed()) - return; - boost::serialization::singleton< - extra_detail::map - >::get_mutable_instance().erase(bs); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(const basic_serializer *) -archive_serializer_map::find( - const boost::serialization::extended_type_info & eti -) { - return boost::serialization::singleton< - extra_detail::map - >::get_const_instance().find(eti); -} - -} // namespace detail -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iarchive.ipp deleted file mode 100644 index 8ea39f70..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iarchive.ipp +++ /dev/null @@ -1,129 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_iarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include -#include - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; - using ::strlen; - using ::size_t; -} -#endif - -#include -#include - -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation of binary_binary_archive -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iarchive::load_override(class_name_type & t, int){ - std::string cn; - cn.reserve(BOOST_SERIALIZATION_MAX_KEY_SIZE); - load_override(cn, 0); - if(cn.size() > (BOOST_SERIALIZATION_MAX_KEY_SIZE - 1)) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_class_name) - ); - std::memcpy(t, cn.data(), cn.size()); - // borland tweak - t.t[cn.size()] = '\0'; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iarchive::init(){ - // read signature in an archive version independent manner - std::string file_signature; - try { - std::size_t l; - this->This()->load(l); - if(l == std::strlen(BOOST_ARCHIVE_SIGNATURE())) { - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != file_signature.data()) - #endif - file_signature.resize(l); - // note breaking a rule here - could be a problem on some platform - if(0 < l) - this->This()->load_binary(&(*file_signature.begin()), l); - } - } - catch(archive_exception const &) { // catch stream_error archive exceptions - // will cause invalid_signature archive exception to be thrown below - file_signature = ""; - } - if(file_signature != BOOST_ARCHIVE_SIGNATURE()) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_signature) - ); - - // make sure the version of the reading archive library can - // support the format of the archive being read - library_version_type input_library_version; - //* this->This() >> input_library_version; - { - int v = 0; - v = this->This()->m_sb.sbumpc(); - #if defined(BOOST_LITTLE_ENDIAN) - if(v < 6){ - ; - } - else - if(v < 7){ - // version 6 - next byte should be zero - this->This()->m_sb.sbumpc(); - } - else - if(v < 8){ - int x1; - // version 7 = might be followed by zero or some other byte - x1 = this->This()->m_sb.sgetc(); - // it's =a zero, push it back - if(0 == x1) - this->This()->m_sb.sbumpc(); - } - else{ - // version 8+ followed by a zero - this->This()->m_sb.sbumpc(); - } - #elif defined(BOOST_BIG_ENDIAN) - if(v == 0) - v = this->This()->m_sb.sbumpc(); - #endif - input_library_version = static_cast(v); - } - - #if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - this->set_library_version(input_library_version); - #else - #if ! BOOST_WORKAROUND(BOOST_MSVC, <= 1200) - detail:: - #endif - basic_iarchive::set_library_version(input_library_version); - #endif - - if(BOOST_ARCHIVE_VERSION() < input_library_version) - boost::serialization::throw_exception( - archive_exception(archive_exception::unsupported_version) - ); -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iprimitive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iprimitive.ipp deleted file mode 100644 index e0f5c2ea..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_iprimitive.ipp +++ /dev/null @@ -1,209 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_iprimitive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // size_t, NULL -#include // memcpy - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; - using ::memcpy; -} // namespace std -#endif - -#include // fixup for RogueWave - -#include -#include - -#include -#include -#include - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// implementation of basic_binary_iprimitive - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iprimitive::init() -{ - // Detect attempts to pass native binary archives across - // incompatible platforms. This is not fool proof but its - // better than nothing. - unsigned char size; - this->This()->load(size); - if(sizeof(int) != size) - boost::serialization::throw_exception( - archive_exception( - archive_exception::incompatible_native_format, - "size of int" - ) - ); - this->This()->load(size); - if(sizeof(long) != size) - boost::serialization::throw_exception( - archive_exception( - archive_exception::incompatible_native_format, - "size of long" - ) - ); - this->This()->load(size); - if(sizeof(float) != size) - boost::serialization::throw_exception( - archive_exception( - archive_exception::incompatible_native_format, - "size of float" - ) - ); - this->This()->load(size); - if(sizeof(double) != size) - boost::serialization::throw_exception( - archive_exception( - archive_exception::incompatible_native_format, - "size of double" - ) - ); - - // for checking endian - int i; - this->This()->load(i); - if(1 != i) - boost::serialization::throw_exception( - archive_exception( - archive_exception::incompatible_native_format, - "endian setting" - ) - ); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iprimitive::load(wchar_t * ws) -{ - std::size_t l; // number of wchar_t !!! - this->This()->load(l); - load_binary(ws, l * sizeof(wchar_t) / sizeof(char)); - ws[l] = L'\0'; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iprimitive::load(std::string & s) -{ - std::size_t l; - this->This()->load(l); - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != s.data()) - #endif - s.resize(l); - // note breaking a rule here - could be a problem on some platform - if(0 < l) - load_binary(&(*s.begin()), l); -} - -#ifndef BOOST_NO_CWCHAR -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iprimitive::load(char * s) -{ - std::size_t l; - this->This()->load(l); - load_binary(s, l); - s[l] = '\0'; -} -#endif - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_iprimitive::load(std::wstring & ws) -{ - std::size_t l; - this->This()->load(l); - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != ws.data()) - #endif - ws.resize(l); - // note breaking a rule here - is could be a problem on some platform - load_binary(const_cast(ws.data()), l * sizeof(wchar_t) / sizeof(char)); -} -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_binary_iprimitive::basic_binary_iprimitive( - std::basic_streambuf & sb, - bool no_codecvt -) : -#ifndef BOOST_NO_STD_LOCALE - m_sb(sb), - archive_locale(NULL), - locale_saver(m_sb) -{ - if(! no_codecvt){ - archive_locale.reset( - boost::archive::add_facet( - std::locale::classic(), - new codecvt_null - ) - ); - m_sb.pubimbue(* archive_locale); - } -} -#else - m_sb(sb) -{} -#endif - -// some libraries including stl and libcomo fail if the -// buffer isn't flushed before the code_cvt facet is changed. -// I think this is a bug. We explicity invoke sync to when -// we're done with the streambuf to work around this problem. -// Note that sync is a protected member of stream buff so we -// have to invoke it through a contrived derived class. -namespace detail { -// note: use "using" to get past msvc bug -using namespace std; -template -class input_streambuf_access : public std::basic_streambuf { - public: - virtual int sync(){ -#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3206)) - return this->basic_streambuf::sync(); -#else - return this->basic_streambuf::sync(); -#endif - } -}; -} // detail - -// scoped_ptr requires that archive_locale be a complete type at time of -// destruction so define destructor here rather than in the header -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_binary_iprimitive::~basic_binary_iprimitive(){ - // push back unread characters - //destructor can't throw ! - try{ - static_cast &>(m_sb).sync(); - } - catch(...){ - } -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oarchive.ipp deleted file mode 100644 index dec2cd77..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oarchive.ipp +++ /dev/null @@ -1,46 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_oarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include -#include - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; -} -#endif - -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation of binary_binary_oarchive - -template -#if !defined(__BORLANDC__) -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -#else -void -#endif -basic_binary_oarchive::init(){ - // write signature in an archive version independent manner - const std::string file_signature(BOOST_ARCHIVE_SIGNATURE()); - * this->This() << file_signature; - // write library version - const library_version_type v(BOOST_ARCHIVE_VERSION()); - * this->This() << v; -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oprimitive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oprimitive.ipp deleted file mode 100644 index 02b5ffab..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_binary_oprimitive.ipp +++ /dev/null @@ -1,160 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_binary_oprimitive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL -#include - -#include - -#if defined(BOOST_NO_STDC_NAMESPACE) && ! defined(__LIBCOMO__) -namespace std{ - using ::strlen; -} // namespace std -#endif - -#ifndef BOOST_NO_CWCHAR -#include -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std{ using ::wcslen; } -#endif -#endif - -#include - -#include -#include - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// implementation of basic_binary_oprimitive - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_oprimitive::init() -{ - // record native sizes of fundamental types - // this is to permit detection of attempts to pass - // native binary archives accross incompatible machines. - // This is not foolproof but its better than nothing. - this->This()->save(static_cast(sizeof(int))); - this->This()->save(static_cast(sizeof(long))); - this->This()->save(static_cast(sizeof(float))); - this->This()->save(static_cast(sizeof(double))); - // for checking endianness - this->This()->save(int(1)); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_oprimitive::save(const char * s) -{ - std::size_t l = std::strlen(s); - this->This()->save(l); - save_binary(s, l); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_oprimitive::save(const std::string &s) -{ - std::size_t l = static_cast(s.size()); - this->This()->save(l); - save_binary(s.data(), l); -} - -#ifndef BOOST_NO_CWCHAR -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_oprimitive::save(const wchar_t * ws) -{ - std::size_t l = std::wcslen(ws); - this->This()->save(l); - save_binary(ws, l * sizeof(wchar_t) / sizeof(char)); -} -#endif - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_binary_oprimitive::save(const std::wstring &ws) -{ - std::size_t l = ws.size(); - this->This()->save(l); - save_binary(ws.data(), l * sizeof(wchar_t) / sizeof(char)); -} -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_binary_oprimitive::basic_binary_oprimitive( - std::basic_streambuf & sb, - bool no_codecvt -) : -#ifndef BOOST_NO_STD_LOCALE - m_sb(sb), - archive_locale(NULL), - locale_saver(m_sb) -{ - if(! no_codecvt){ - archive_locale.reset( - add_facet( - std::locale::classic(), - new codecvt_null - ) - ); - m_sb.pubimbue(* archive_locale); - } -} -#else - m_sb(sb) -{} -#endif - -// some libraries including stl and libcomo fail if the -// buffer isn't flushed before the code_cvt facet is changed. -// I think this is a bug. We explicity invoke sync to when -// we're done with the streambuf to work around this problem. -// Note that sync is a protected member of stream buff so we -// have to invoke it through a contrived derived class. -namespace detail { -// note: use "using" to get past msvc bug -using namespace std; -template -class output_streambuf_access : public std::basic_streambuf { - public: - virtual int sync(){ -#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3206)) - return this->basic_streambuf::sync(); -#else - return this->basic_streambuf::sync(); -#endif - } -}; -} // detail - -// scoped_ptr requires that g be a complete type at time of -// destruction so define destructor here rather than in the header -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_binary_oprimitive::~basic_binary_oprimitive(){ - // flush buffer - //destructor can't throw - try{ - static_cast &>(m_sb).sync(); - } - catch(...){ - } -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iarchive.ipp deleted file mode 100644 index 0a246b76..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iarchive.ipp +++ /dev/null @@ -1,79 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_iarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; -} -#endif - -#include -#include -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation of text_text_archive - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_iarchive::load_override(class_name_type & t, int){ - std::string cn; - cn.reserve(BOOST_SERIALIZATION_MAX_KEY_SIZE); - load_override(cn, 0); - if(cn.size() > (BOOST_SERIALIZATION_MAX_KEY_SIZE - 1)) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_class_name) - ); - std::memcpy(t, cn.data(), cn.size()); - // borland tweak - t.t[cn.size()] = '\0'; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_iarchive::init(void){ - // read signature in an archive version independent manner - std::string file_signature; - * this->This() >> file_signature; - if(file_signature != BOOST_ARCHIVE_SIGNATURE()) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_signature) - ); - - // make sure the version of the reading archive library can - // support the format of the archive being read - library_version_type input_library_version; - * this->This() >> input_library_version; - - #if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - this->set_library_version(input_library_version); - #else - #if ! BOOST_WORKAROUND(BOOST_MSVC, <= 1200) - detail:: - #endif - basic_iarchive::set_library_version(input_library_version); - #endif - - // extra little .t is to get around borland quirk - if(BOOST_ARCHIVE_VERSION() < input_library_version) - boost::serialization::throw_exception( - archive_exception(archive_exception::unsupported_version) - ); -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iprimitive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iprimitive.ipp deleted file mode 100644 index 16378b84..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_iprimitive.ipp +++ /dev/null @@ -1,152 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_iprimitive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // size_t -#include // NULL - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include - -#include -#include -#include - -#include -#include -#include -#include - -namespace boost { -namespace archive { - -namespace { - template - bool is_whitespace(CharType c); - - template<> - bool is_whitespace(char t){ - return 0 != std::isspace(t); - } - - #ifndef BOOST_NO_CWCHAR - template<> - bool is_whitespace(wchar_t t){ - return 0 != std::iswspace(t); - } - #endif -} - -// translate base64 text into binary and copy into buffer -// until buffer is full. -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_iprimitive::load_binary( - void *address, - std::size_t count -){ - typedef BOOST_DEDUCED_TYPENAME IStream::char_type CharType; - - if(0 == count) - return; - - BOOST_ASSERT( - static_cast((std::numeric_limits::max)()) - > (count + sizeof(CharType) - 1)/sizeof(CharType) - ); - - if(is.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - // convert from base64 to binary - typedef BOOST_DEDUCED_TYPENAME - iterators::transform_width< - iterators::binary_from_base64< - iterators::remove_whitespace< - iterators::istream_iterator - > - ,CharType - > - ,8 - ,6 - ,CharType - > - binary; - - binary i = binary( - BOOST_MAKE_PFTO_WRAPPER( - iterators::istream_iterator(is) - ) - ); - - char * caddr = static_cast(address); - - // take care that we don't increment anymore than necessary - while(count-- > 0){ - *caddr++ = static_cast(*i++); - } - - // skip over any excess input - for(;;){ - BOOST_DEDUCED_TYPENAME IStream::int_type r; - r = is.get(); - if(is.eof()) - break; - if(is_whitespace(static_cast(r))) - break; - } -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_text_iprimitive::basic_text_iprimitive( - IStream &is_, - bool no_codecvt -) : -#ifndef BOOST_NO_STD_LOCALE - is(is_), - flags_saver(is_), - precision_saver(is_), - archive_locale(NULL), - locale_saver(* is_.rdbuf()) -{ - if(! no_codecvt){ - archive_locale.reset( - add_facet( - std::locale::classic(), - new codecvt_null - ) - ); - is.imbue(* archive_locale); - } - is >> std::noboolalpha; -} -#else - is(is_), - flags_saver(is_), - precision_saver(is_) -{} -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_text_iprimitive::~basic_text_iprimitive(){ - is.sync(); -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oarchive.ipp deleted file mode 100644 index 34e6995c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oarchive.ipp +++ /dev/null @@ -1,62 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_oarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. -#include -#include -#include - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; -} -#endif - -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation of basic_text_oarchive - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_oarchive::newtoken() -{ - switch(delimiter){ - default: - BOOST_ASSERT(false); - break; - case eol: - this->This()->put('\n'); - delimiter = space; - break; - case space: - this->This()->put(' '); - break; - case none: - delimiter = space; - break; - } -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_oarchive::init(){ - // write signature in an archive version independent manner - const std::string file_signature(BOOST_ARCHIVE_SIGNATURE()); - * this->This() << file_signature; - // write library version - const library_version_type v(BOOST_ARCHIVE_VERSION()); - * this->This() << v; -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oprimitive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oprimitive.ipp deleted file mode 100644 index 7e4315c0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_text_oprimitive.ipp +++ /dev/null @@ -1,114 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_text_oprimitive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // NULL -#include - -#include -#include -#include - -#include -#include -#include -#include - -namespace boost { -namespace archive { - -// translate to base64 and copy in to buffer. -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_text_oprimitive::save_binary( - const void *address, - std::size_t count -){ - typedef BOOST_DEDUCED_TYPENAME OStream::char_type CharType; - - if(0 == count) - return; - - if(os.fail()) - boost::serialization::throw_exception( - archive_exception(archive_exception::output_stream_error) - ); - - os.put('\n'); - - typedef - boost::archive::iterators::insert_linebreaks< - boost::archive::iterators::base64_from_binary< - boost::archive::iterators::transform_width< - const char *, - 6, - 8 - > - > - ,76 - ,const char // cwpro8 needs this - > - base64_text; - - boost::archive::iterators::ostream_iterator oi(os); - std::copy( - base64_text(BOOST_MAKE_PFTO_WRAPPER(static_cast(address))), - base64_text( - BOOST_MAKE_PFTO_WRAPPER(static_cast(address) + count) - ), - oi - ); - - std::size_t tail = count % 3; - if(tail > 0){ - *oi++ = '='; - if(tail < 2) - *oi = '='; - } -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_text_oprimitive::basic_text_oprimitive( - OStream & os_, - bool no_codecvt -) : -#ifndef BOOST_NO_STD_LOCALE - os(os_), - flags_saver(os_), - precision_saver(os_), - archive_locale(NULL), - locale_saver(* os_.rdbuf()) -{ - if(! no_codecvt){ - archive_locale.reset( - add_facet( - std::locale::classic(), - new codecvt_null - ) - ); - os.imbue(* archive_locale); - } - os << std::noboolalpha; -} -#else - os(os_), - flags_saver(os_), - precision_saver(os_) -{} -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_text_oprimitive::~basic_text_oprimitive(){ - os << std::endl; -} - -} //namespace boost -} //namespace archive diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_grammar.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_grammar.hpp deleted file mode 100644 index 807ed072..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_grammar.hpp +++ /dev/null @@ -1,178 +0,0 @@ -#ifndef BOOST_ARCHIVE_BASIC_XML_GRAMMAR_HPP -#define BOOST_ARCHIVE_BASIC_XML_GRAMMAR_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_grammar.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// this module is derived from simplexml.cpp - an example shipped as part of -// the spirit parser. This example contains the following notice: -/*============================================================================= - simplexml.cpp - - Spirit V1.3 - URL: http://spirit.sourceforge.net/ - - Copyright (c) 2001, Daniel C. Nuffer - - This software is provided 'as-is', without any express or implied - warranty. In no event will the copyright holder be held liable for - any damages arising from the use of this software. - - Permission is granted to anyone to use this software for any purpose, - including commercial applications, and to alter it and redistribute - it freely, subject to the following restrictions: - - 1. The origin of this software must not be misrepresented; you must - not claim that you wrote the original software. If you use this - software in a product, an acknowledgment in the product documentation - would be appreciated but is not required. - - 2. Altered source versions must be plainly marked as such, and must - not be misrepresented as being the original software. - - 3. This notice may not be removed or altered from any source - distribution. -=============================================================================*/ -#include - -#include -#include - -// supress noise -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1200) -# pragma warning (disable : 4786) // too long name, harmless warning -#endif - -#include -#include - -#include -#include -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// XML grammar parsing - -template -class basic_xml_grammar { -public: - // The following is not necessary according to DR45, but at least - // one compiler (Compaq C++ 6.5 in strict_ansi mode) chokes otherwise. - struct return_values; - friend struct return_values; - -private: - typedef BOOST_DEDUCED_TYPENAME std::basic_istream IStream; - typedef BOOST_DEDUCED_TYPENAME std::basic_string StringType; - typedef BOOST_DEDUCED_TYPENAME boost::spirit::classic::chset chset_t; - typedef BOOST_DEDUCED_TYPENAME boost::spirit::classic::chlit chlit_t; - typedef BOOST_DEDUCED_TYPENAME boost::spirit::classic::scanner< - BOOST_DEDUCED_TYPENAME std::basic_string::iterator - > scanner_t; - typedef BOOST_DEDUCED_TYPENAME boost::spirit::classic::rule rule_t; - // Start grammar definition - rule_t - Reference, - Eq, - STag, - ETag, - LetterOrUnderscoreOrColon, - AttValue, - CharRef1, - CharRef2, - CharRef, - AmpRef, - LTRef, - GTRef, - AposRef, - QuoteRef, - CharData, - CharDataChars, - content, - AmpName, - LTName, - GTName, - ClassNameChar, - ClassName, - Name, - XMLDecl, - XMLDeclChars, - DocTypeDecl, - DocTypeDeclChars, - ClassIDAttribute, - ObjectIDAttribute, - ClassNameAttribute, - TrackingAttribute, - VersionAttribute, - UnusedAttribute, - Attribute, - SignatureAttribute, - SerializationWrapper, - NameHead, - NameTail, - AttributeList, - S; - - // XML Character classes - chset_t - BaseChar, - Ideographic, - Char, - Letter, - Digit, - CombiningChar, - Extender, - Sch, - NameChar; - - void init_chset(); - - bool my_parse( - IStream & is, - const rule_t &rule_, - const CharType delimiter = L'>' - ) const ; -public: - struct return_values { - StringType object_name; - StringType contents; - //class_id_type class_id; - int_least16_t class_id; - //object_id_type object_id; - uint_least32_t object_id; - //version_type version; - unsigned int version; - tracking_type tracking_level; - StringType class_name; - return_values() : - version(0), - tracking_level(false) - {} - } rv; - bool parse_start_tag(IStream & is) /*const*/; - bool parse_end_tag(IStream & is) const; - bool parse_string(IStream & is, StringType & s) /*const*/; - void init(IStream & is); - void windup(IStream & is); - basic_xml_grammar(); -}; - -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_BASIC_XML_GRAMMAR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_iarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_iarchive.ipp deleted file mode 100644 index 52dfde1a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_iarchive.ipp +++ /dev/null @@ -1,114 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_iarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL -#include - -#include -#include -#include -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation of xml_text_archive - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_start(const char *name){ - // if there's no name - if(NULL == name) - return; - bool result = this->This()->gimpl->parse_start_tag(this->This()->get_is()); - if(true != result){ - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - } - // don't check start tag at highest level - ++depth; - return; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_end(const char *name){ - // if there's no name - if(NULL == name) - return; - bool result = this->This()->gimpl->parse_end_tag(this->This()->get_is()); - if(true != result){ - boost::serialization::throw_exception( - archive_exception(archive_exception::input_stream_error) - ); - } - - // don't check start tag at highest level - if(0 == --depth) - return; - - if(0 == (this->get_flags() & no_xml_tag_checking)){ - // double check that the tag matches what is expected - useful for debug - if(0 != name[this->This()->gimpl->rv.object_name.size()] - || ! std::equal( - this->This()->gimpl->rv.object_name.begin(), - this->This()->gimpl->rv.object_name.end(), - name - ) - ){ - boost::serialization::throw_exception( - xml_archive_exception( - xml_archive_exception::xml_archive_tag_mismatch, - name - ) - ); - } - } -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_override(object_id_type & t, int){ - t = object_id_type(this->This()->gimpl->rv.object_id); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_override(version_type & t, int){ - t = version_type(this->This()->gimpl->rv.version); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_override(class_id_type & t, int){ - t = class_id_type(this->This()->gimpl->rv.class_id); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_iarchive::load_override(tracking_type & t, int){ - t = this->This()->gimpl->rv.tracking_level; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_xml_iarchive::basic_xml_iarchive(unsigned int flags) : - detail::common_iarchive(flags), - depth(0) -{} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_xml_iarchive::~basic_xml_iarchive(){} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_oarchive.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_oarchive.ipp deleted file mode 100644 index e2cc8d4d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/basic_xml_oarchive.ipp +++ /dev/null @@ -1,275 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// basic_xml_oarchive.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL -#include -#if defined(BOOST_NO_STDC_NAMESPACE) && ! defined(__LIBCOMO__) -namespace std{ - using ::strlen; -} // namespace std -#endif - -#include -#include -#include -#include - -namespace boost { -namespace archive { - -namespace detail { -template -struct XML_name { - void operator()(CharType t) const{ - const unsigned char lookup_table[] = { - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0, // -. - 1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0, // 0-9 - 0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, // A- - 1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,1, // -Z _ - 0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, // a- - 1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0, // -z - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 - }; - if((unsigned)t > 127) - return; - if(0 == lookup_table[(unsigned)t]) - boost::serialization::throw_exception( - xml_archive_exception( - xml_archive_exception::xml_archive_tag_name_error - ) - ); - } -}; - -} // namespace detail - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implemenations of functions common to both types of xml output - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::write_attribute( - const char *attribute_name, - int t, - const char *conjunction -){ - this->This()->put(' '); - this->This()->put(attribute_name); - this->This()->put(conjunction); - this->This()->save(t); - this->This()->put('"'); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::write_attribute( - const char *attribute_name, - const char *key -){ - this->This()->put(' '); - this->This()->put(attribute_name); - this->This()->put("=\""); - this->This()->save(key); - this->This()->put('"'); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::indent(){ - int i; - for(i = depth; i-- > 0;) - this->This()->put('\t'); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_start(const char *name) -{ - if(NULL == name) - return; - - // be sure name has no invalid characters - std::for_each(name, name + std::strlen(name), detail::XML_name()); - - end_preamble(); - if(depth > 0){ - this->This()->put('\n'); - indent(); - } - ++depth; - this->This()->put('<'); - this->This()->save(name); - pending_preamble = true; - indent_next = false; -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_end(const char *name) -{ - if(NULL == name) - return; - - // be sure name has no invalid characters - std::for_each(name, name + std::strlen(name), detail::XML_name()); - - end_preamble(); - --depth; - if(indent_next){ - this->This()->put('\n'); - indent(); - } - indent_next = true; - this->This()->put("This()->save(name); - this->This()->put('>'); - if(0 == depth) - this->This()->put('\n'); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::end_preamble(){ - if(pending_preamble){ - this->This()->put('>'); - pending_preamble = false; - } -} -#if 0 -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const object_id_type & t, int) -{ - int i = t.t; // extra .t is for borland - write_attribute(BOOST_ARCHIVE_XML_OBJECT_ID(), i, "=\"_"); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override( - const object_reference_type & t, - int -){ - int i = t.t; // extra .t is for borland - write_attribute(BOOST_ARCHIVE_XML_OBJECT_REFERENCE(), i, "=\"_"); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const version_type & t, int) -{ - int i = t.t; // extra .t is for borland - write_attribute(BOOST_ARCHIVE_XML_VERSION(), i); -} -#endif - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const object_id_type & t, int) -{ - // borland doesn't do conversion of STRONG_TYPEDEFs very well - const unsigned int i = t; - write_attribute(BOOST_ARCHIVE_XML_OBJECT_ID(), i, "=\"_"); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override( - const object_reference_type & t, - int -){ - const unsigned int i = t; - write_attribute(BOOST_ARCHIVE_XML_OBJECT_REFERENCE(), i, "=\"_"); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const version_type & t, int) -{ - const unsigned int i = t; - write_attribute(BOOST_ARCHIVE_XML_VERSION(), i); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const class_id_type & t, int) -{ - write_attribute(BOOST_ARCHIVE_XML_CLASS_ID(), t); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override( - const class_id_reference_type & t, - int -){ - write_attribute(BOOST_ARCHIVE_XML_CLASS_ID_REFERENCE(), t); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override( - const class_id_optional_type & t, - int -){ - write_attribute(BOOST_ARCHIVE_XML_CLASS_ID(), t); -} -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const class_name_type & t, int) -{ - const char * key = t; - if(NULL == key) - return; - write_attribute(BOOST_ARCHIVE_XML_CLASS_NAME(), key); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::save_override(const tracking_type & t, int) -{ - write_attribute(BOOST_ARCHIVE_XML_TRACKING(), t.t); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(void) -basic_xml_oarchive::init(){ - // xml header - this->This()->put("\n"); - this->This()->put("\n"); - // xml document wrapper - outer root - this->This()->put("This()->put(">\n"); -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_xml_oarchive::basic_xml_oarchive(unsigned int flags) : - detail::common_oarchive(flags), - depth(0), - indent_next(false), - pending_preamble(false) -{ -} - -template -BOOST_ARCHIVE_OR_WARCHIVE_DECL(BOOST_PP_EMPTY()) -basic_xml_oarchive::~basic_xml_oarchive(){ - if(0 == (this->get_flags() & no_header)){ - BOOST_TRY{ - this->This()->put("\n"); - } - BOOST_CATCH(...){} - BOOST_CATCH_END - } -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_iarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_iarchive_impl.ipp deleted file mode 100644 index f14c0d8e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_iarchive_impl.ipp +++ /dev/null @@ -1,128 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_iarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -////////////////////////////////////////////////////////////////////// -// implementation of basic_text_iprimitive overrides for the combination -// of template parameters used to implement a text_iprimitive - -#include // size_t, NULL -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include // RogueWave - -#include - -namespace boost { -namespace archive { - -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::load(char *s) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - // Works on all tested platforms - is.read(s, size); - s[size] = '\0'; -} - -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::load(std::string &s) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != s.data()) - #endif - s.resize(size); - if(0 < size) - is.read(&(*s.begin()), size); -} - -#ifndef BOOST_NO_CWCHAR -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::load(wchar_t *ws) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - is.read((char *)ws, size * sizeof(wchar_t)/sizeof(char)); - ws[size] = L'\0'; -} -#endif // BOOST_NO_INTRINSIC_WCHAR_T - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::load(std::wstring &ws) -{ - std::size_t size; - * this->This() >> size; - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != ws.data()) - #endif - ws.resize(size); - // skip separating space - is.get(); - is.read((char *)ws.data(), size * sizeof(wchar_t)/sizeof(char)); -} - -#endif // BOOST_NO_STD_WSTRING -#endif // BOOST_NO_CWCHAR - -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::load_override(class_name_type & t, int){ - basic_text_iarchive::load_override(t, 0); -} - -template -BOOST_ARCHIVE_DECL(void) -text_iarchive_impl::init(){ - basic_text_iarchive::init(); -} - -template -BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) -text_iarchive_impl::text_iarchive_impl( - std::istream & is, - unsigned int flags -) : - basic_text_iprimitive( - is, - 0 != (flags & no_codecvt) - ), - basic_text_iarchive(flags) -{ - if(0 == (flags & no_header)) - #if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - this->init(); - #else - this->basic_text_iarchive::init(); - #endif -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_oarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_oarchive_impl.ipp deleted file mode 100644 index 2df0b460..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_oarchive_impl.ipp +++ /dev/null @@ -1,124 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_oarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include // size_t - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#ifndef BOOST_NO_CWCHAR -#include -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std{ using ::wcslen; } -#endif -#endif - -#include -#include - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// implementation of basic_text_oprimitive overrides for the combination -// of template parameters used to create a text_oprimitive - -template -BOOST_ARCHIVE_DECL(void) -text_oarchive_impl::save(const char * s) -{ - const std::size_t len = std::ostream::traits_type::length(s); - *this->This() << len; - this->This()->newtoken(); - os << s; -} - -template -BOOST_ARCHIVE_DECL(void) -text_oarchive_impl::save(const std::string &s) -{ - const std::size_t size = s.size(); - *this->This() << size; - this->This()->newtoken(); - os << s; -} - -#ifndef BOOST_NO_CWCHAR -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_ARCHIVE_DECL(void) -text_oarchive_impl::save(const wchar_t * ws) -{ - const std::size_t l = std::wcslen(ws); - * this->This() << l; - this->This()->newtoken(); - os.write((const char *)ws, l * sizeof(wchar_t)/sizeof(char)); -} -#endif - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_DECL(void) -text_oarchive_impl::save(const std::wstring &ws) -{ - const std::size_t l = ws.size(); - * this->This() << l; - this->This()->newtoken(); - os.write((const char *)(ws.data()), l * sizeof(wchar_t)/sizeof(char)); -} -#endif -#endif // BOOST_NO_CWCHAR - -template -BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) -text_oarchive_impl::text_oarchive_impl( - std::ostream & os, - unsigned int flags -) : - basic_text_oprimitive( - os, - 0 != (flags & no_codecvt) - ), - basic_text_oarchive(flags) -{ - if(0 == (flags & no_header)) - #if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - this->init(); - #else - this->basic_text_oarchive::init(); - #endif -} - -template -BOOST_ARCHIVE_DECL(void) -text_oarchive_impl::save_binary(const void *address, std::size_t count){ - put('\n'); - this->end_preamble(); - #if ! defined(__MWERKS__) - this->basic_text_oprimitive::save_binary( - #else - this->basic_text_oprimitive::save_binary( - #endif - address, - count - ); - this->delimiter = this->eol; -} - -} // namespace archive -} // namespace boost - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_wiarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_wiarchive_impl.ipp deleted file mode 100644 index 6938c226..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_wiarchive_impl.ipp +++ /dev/null @@ -1,118 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_text_wiarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // size_t, NULL - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include // fixup for RogueWave - -#ifndef BOOST_NO_STD_WSTREAMBUF -#include - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// implementation of wiprimtives functions -// -template -BOOST_WARCHIVE_DECL(void) -text_wiarchive_impl::load(char *s) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - while(size-- > 0){ - *s++ = is.narrow(is.get(), '\0'); - } - *s = '\0'; -} - -template -BOOST_WARCHIVE_DECL(void) -text_wiarchive_impl::load(std::string &s) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != s.data()) - #endif - s.resize(0); - s.reserve(size); - while(size-- > 0){ - int x = is.narrow(is.get(), '\0'); - s += x; - } -} - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_WARCHIVE_DECL(void) -text_wiarchive_impl::load(wchar_t *s) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - // Works on all tested platforms - is.read(s, size); - s[size] = L'\0'; -} -#endif - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_WARCHIVE_DECL(void) -text_wiarchive_impl::load(std::wstring &ws) -{ - std::size_t size; - * this->This() >> size; - // skip separating space - is.get(); - // borland complains about resize - // borland de-allocator fixup - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != ws.data()) - #endif - ws.resize(size); - // note breaking a rule here - is this a problem on some platform - is.read(const_cast(ws.data()), size); -} -#endif - -template -BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) -text_wiarchive_impl::text_wiarchive_impl( - std::wistream & is, - unsigned int flags -) : - basic_text_iprimitive( - is, - 0 != (flags & no_codecvt) - ), - basic_text_iarchive(flags) -{ - if(0 == (flags & no_header)) - basic_text_iarchive::init(); -} - -} // archive -} // boost - -#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_woarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_woarchive_impl.ipp deleted file mode 100644 index 6683f528..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/text_woarchive_impl.ipp +++ /dev/null @@ -1,85 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_woarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifndef BOOST_NO_STD_WSTREAMBUF - -#include -#include // size_t -#if defined(BOOST_NO_STDC_NAMESPACE) && ! defined(__LIBCOMO__) -namespace std{ - using ::strlen; - using ::size_t; -} // namespace std -#endif - -#include - -#include - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// implementation of woarchive functions -// -template -BOOST_WARCHIVE_DECL(void) -text_woarchive_impl::save(const char *s) -{ - // note: superfluous local variable fixes borland warning - const std::size_t size = std::strlen(s); - * this->This() << size; - this->This()->newtoken(); - while(*s != '\0') - os.put(os.widen(*s++)); -} - -template -BOOST_WARCHIVE_DECL(void) -text_woarchive_impl::save(const std::string &s) -{ - const std::size_t size = s.size(); - * this->This() << size; - this->This()->newtoken(); - const char * cptr = s.data(); - for(std::size_t i = size; i-- > 0;) - os.put(os.widen(*cptr++)); -} - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_WARCHIVE_DECL(void) -text_woarchive_impl::save(const wchar_t *ws) -{ - const std::size_t size = std::wostream::traits_type::length(ws); - * this->This() << size; - this->This()->newtoken(); - os.write(ws, size); -} -#endif - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_WARCHIVE_DECL(void) -text_woarchive_impl::save(const std::wstring &ws) -{ - const std::size_t size = ws.length(); - * this->This() << size; - this->This()->newtoken(); - os.write(ws.data(), size); -} -#endif - -} // namespace archive -} // namespace boost - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_iarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_iarchive_impl.ipp deleted file mode 100644 index c7cbc7fc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_iarchive_impl.ipp +++ /dev/null @@ -1,204 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_iarchive_impl.cpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // memcpy -#include // NULL -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; -} // namespace std -#endif - -#ifndef BOOST_NO_CWCHAR -#include // mbtowc -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::mbtowc; - } // namespace std -#endif -#endif // BOOST_NO_CWCHAR - -#include // RogueWave and Dinkumware -#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) -#include -#endif - -#include - -#include -#include -#include -#include - -#include "basic_xml_grammar.hpp" - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implemenations of functions specific to char archives - -// wide char stuff used by char archives - -#ifndef BOOST_NO_CWCHAR -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::load(std::wstring &ws){ - std::string s; - bool result = gimpl->parse_string(is, s); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != ws.data()) - #endif - ws.resize(0); - const char * start = s.data(); - const char * end = start + s.size(); - while(start < end){ - wchar_t wc; - int resultx = std::mbtowc(&wc, start, end - start); - if(0 < resultx){ - start += resultx; - ws += wc; - continue; - } - boost::serialization::throw_exception( - iterators::dataflow_exception( - iterators::dataflow_exception::invalid_conversion - ) - ); - } -} -#endif // BOOST_NO_STD_WSTRING - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::load(wchar_t * ws){ - std::string s; - bool result = gimpl->parse_string(is, s); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - - const char * start = s.data(); - const char * end = start + s.size(); - while(start < end){ - wchar_t wc; - int result = std::mbtowc(&wc, start, end - start); - if(0 < result){ - start += result; - *ws++ = wc; - continue; - } - boost::serialization::throw_exception( - iterators::dataflow_exception( - iterators::dataflow_exception::invalid_conversion - ) - ); - } - *ws = L'\0'; -} -#endif // BOOST_NO_INTRINSIC_WCHAR_T - -#endif // BOOST_NO_CWCHAR - -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::load(std::string &s){ - bool result = gimpl->parse_string(is, s); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); -} - -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::load(char * s){ - std::string tstring; - bool result = gimpl->parse_string(is, tstring); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - std::memcpy(s, tstring.data(), tstring.size()); - s[tstring.size()] = 0; -} - -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::load_override(class_name_type & t, int){ - const std::string & s = gimpl->rv.class_name; - if(s.size() > BOOST_SERIALIZATION_MAX_KEY_SIZE - 1) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_class_name) - ); - char * tptr = t; - std::memcpy(tptr, s.data(), s.size()); - tptr[s.size()] = '\0'; -} - -template -BOOST_ARCHIVE_DECL(void) -xml_iarchive_impl::init(){ - gimpl->init(is); - this->set_library_version( - library_version_type(gimpl->rv.version) - ); -} - -template -BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_iarchive_impl::xml_iarchive_impl( - std::istream &is_, - unsigned int flags -) : - basic_text_iprimitive( - is_, - 0 != (flags & no_codecvt) - ), - basic_xml_iarchive(flags), - gimpl(new xml_grammar()) -{ - if(0 == (flags & no_header)){ - BOOST_TRY{ - init(); - } - BOOST_CATCH(...){ - delete gimpl; - #ifndef BOOST_NO_EXCEPTIONS - throw; // re-throw - #endif - } - BOOST_CATCH_END - } -} - -template -BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_iarchive_impl::~xml_iarchive_impl(){ - if(0 == (this->get_flags() & no_header)){ - BOOST_TRY{ - gimpl->windup(is); - } - BOOST_CATCH(...){} - BOOST_CATCH_END - } - delete gimpl; -} -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_oarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_oarchive_impl.ipp deleted file mode 100644 index 8ab954f4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_oarchive_impl.ipp +++ /dev/null @@ -1,117 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_oarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include - -#include // strlen -#include // msvc 6.0 needs this to suppress warnings -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::strlen; -} // namespace std -#endif - -#include -#include - -#ifndef BOOST_NO_CWCHAR -#include -#include -#endif - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implemenations of functions specific to char archives - -// wide char stuff used by char archives -#ifndef BOOST_NO_CWCHAR -// copy chars to output escaping to xml and translating wide chars to mb chars -template -void save_iterator(std::ostream &os, InputIterator begin, InputIterator end){ - typedef boost::archive::iterators::mb_from_wchar< - boost::archive::iterators::xml_escape - > translator; - std::copy( - translator(BOOST_MAKE_PFTO_WRAPPER(begin)), - translator(BOOST_MAKE_PFTO_WRAPPER(end)), - boost::archive::iterators::ostream_iterator(os) - ); -} - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_ARCHIVE_DECL(void) -xml_oarchive_impl::save(const std::wstring & ws){ -// at least one library doesn't typedef value_type for strings -// so rather than using string directly make a pointer iterator out of it -// save_iterator(os, ws.data(), ws.data() + std::wcslen(ws.data())); - save_iterator(os, ws.data(), ws.data() + ws.size()); -} -#endif - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_ARCHIVE_DECL(void) -xml_oarchive_impl::save(const wchar_t * ws){ - save_iterator(os, ws, ws + std::wcslen(ws)); -} -#endif - -#endif // BOOST_NO_CWCHAR - -template -BOOST_ARCHIVE_DECL(void) -xml_oarchive_impl::save(const std::string & s){ -// at least one library doesn't typedef value_type for strings -// so rather than using string directly make a pointer iterator out of it - typedef boost::archive::iterators::xml_escape< - const char * - > xml_escape_translator; - std::copy( - xml_escape_translator(BOOST_MAKE_PFTO_WRAPPER(s.data())), - xml_escape_translator(BOOST_MAKE_PFTO_WRAPPER(s.data()+ s.size())), - boost::archive::iterators::ostream_iterator(os) - ); -} - -template -BOOST_ARCHIVE_DECL(void) -xml_oarchive_impl::save(const char * s){ - typedef boost::archive::iterators::xml_escape< - const char * - > xml_escape_translator; - std::copy( - xml_escape_translator(BOOST_MAKE_PFTO_WRAPPER(s)), - xml_escape_translator(BOOST_MAKE_PFTO_WRAPPER(s + std::strlen(s))), - boost::archive::iterators::ostream_iterator(os) - ); -} - -template -BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_oarchive_impl::xml_oarchive_impl( - std::ostream & os_, - unsigned int flags -) : - basic_text_oprimitive( - os_, - 0 != (flags & no_codecvt) - ), - basic_xml_oarchive(flags) -{ - if(0 == (flags & no_header)) - this->init(); -} - -} // namespace archive -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_wiarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_wiarchive_impl.ipp deleted file mode 100644 index 9dde66c8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_wiarchive_impl.ipp +++ /dev/null @@ -1,206 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_wiprimitive.cpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // for BOOST_DEDUCED_TYPENAME - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::memcpy; -} //std -#endif - -#include // msvc 6.0 needs this to suppress warnings -#ifndef BOOST_NO_STD_WSTREAMBUF - -#include -#include - -#include // Dinkumware and RogueWave -#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) -#include -#endif - -#include -#include -#include - -#include -#include -#include -#include - -#include - -#include -#include - -#include "basic_xml_grammar.hpp" - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implemenations of functions specific to wide char archives - -namespace { // anonymous - -void copy_to_ptr(char * s, const std::wstring & ws){ - std::copy( - iterators::mb_from_wchar( - BOOST_MAKE_PFTO_WRAPPER(ws.begin()) - ), - iterators::mb_from_wchar( - BOOST_MAKE_PFTO_WRAPPER(ws.end()) - ), - s - ); - s[ws.size()] = 0; -} - -} // anonymous - -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::load(std::string & s){ - std::wstring ws; - bool result = gimpl->parse_string(is, ws); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - #if BOOST_WORKAROUND(_RWSTD_VER, BOOST_TESTED_AT(20101)) - if(NULL != s.data()) - #endif - s.resize(0); - s.reserve(ws.size()); - std::copy( - iterators::mb_from_wchar( - BOOST_MAKE_PFTO_WRAPPER(ws.begin()) - ), - iterators::mb_from_wchar( - BOOST_MAKE_PFTO_WRAPPER(ws.end()) - ), - std::back_inserter(s) - ); -} - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::load(std::wstring & ws){ - bool result = gimpl->parse_string(is, ws); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); -} -#endif - -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::load(char * s){ - std::wstring ws; - bool result = gimpl->parse_string(is, ws); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - copy_to_ptr(s, ws); -} - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::load(wchar_t * ws){ - std::wstring twstring; - bool result = gimpl->parse_string(is, twstring); - if(! result) - boost::serialization::throw_exception( - xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) - ); - std::memcpy(ws, twstring.c_str(), twstring.size()); - ws[twstring.size()] = L'\0'; -} -#endif - -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::load_override(class_name_type & t, int){ - const std::wstring & ws = gimpl->rv.class_name; - if(ws.size() > BOOST_SERIALIZATION_MAX_KEY_SIZE - 1) - boost::serialization::throw_exception( - archive_exception(archive_exception::invalid_class_name) - ); - copy_to_ptr(t, ws); -} - -template -BOOST_WARCHIVE_DECL(void) -xml_wiarchive_impl::init(){ - gimpl->init(is); - this->set_library_version( - library_version_type(gimpl->rv.version) - ); -} - -template -BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_wiarchive_impl::xml_wiarchive_impl( - std::wistream &is_, - unsigned int flags -) : - basic_text_iprimitive( - is_, - true // don't change the codecvt - use the one below - ), - basic_xml_iarchive(flags), - gimpl(new xml_wgrammar()) -{ - if(0 == (flags & no_codecvt)){ - archive_locale.reset( - add_facet( - std::locale::classic(), - new boost::archive::detail::utf8_codecvt_facet - ) - ); - is.imbue(* archive_locale); - } - if(0 == (flags & no_header)){ - BOOST_TRY{ - this->init(); - } - BOOST_CATCH(...){ - delete gimpl; - #ifndef BOOST_NO_EXCEPTIONS - throw; // re-throw - #endif - } - BOOST_CATCH_END - } -} - -template -BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_wiarchive_impl::~xml_wiarchive_impl(){ - if(0 == (this->get_flags() & no_header)){ - BOOST_TRY{ - gimpl->windup(is); - } - BOOST_CATCH(...){} - BOOST_CATCH_END - } - delete gimpl; -} - -} // namespace archive -} // namespace boost - -#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_woarchive_impl.ipp b/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_woarchive_impl.ipp deleted file mode 100644 index 3bf42bda..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/impl/xml_woarchive_impl.ipp +++ /dev/null @@ -1,160 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_woarchive_impl.ipp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#ifndef BOOST_NO_STD_WSTREAMBUF - -#include -#include -#include -#include - -#include // msvc 6.0 needs this to suppress warnings - // for BOOST_DEDUCED_TYPENAME -#include // strlen -#include // mbtowc -#include // wcslen - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::strlen; - #if ! defined(BOOST_NO_INTRINSIC_WCHAR_T) - using ::mbtowc; - using ::wcslen; - #endif -} // namespace std -#endif - -#include -#include - -#include -#include -#include -#include - -#include -#include - -namespace boost { -namespace archive { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implemenations of functions specific to wide char archives - -// copy chars to output escaping to xml and widening characters as we go -template -void save_iterator(std::wostream &os, InputIterator begin, InputIterator end){ - typedef iterators::wchar_from_mb< - iterators::xml_escape - > xmbtows; - std::copy( - xmbtows(BOOST_MAKE_PFTO_WRAPPER(begin)), - xmbtows(BOOST_MAKE_PFTO_WRAPPER(end)), - boost::archive::iterators::ostream_iterator(os) - ); -} - -template -BOOST_WARCHIVE_DECL(void) -xml_woarchive_impl::save(const std::string & s){ - // note: we don't use s.begin() and s.end() because dinkumware - // doesn't have string::value_type defined. So use a wrapper - // around these values to implement the definitions. - const char * begin = s.data(); - const char * end = begin + s.size(); - save_iterator(os, begin, end); -} - -#ifndef BOOST_NO_STD_WSTRING -template -BOOST_WARCHIVE_DECL(void) -xml_woarchive_impl::save(const std::wstring & ws){ -#if 0 - typedef iterators::xml_escape xmbtows; - std::copy( - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws.begin())), - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws.end())), - boost::archive::iterators::ostream_iterator(os) - ); -#endif - typedef iterators::xml_escape xmbtows; - std::copy( - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws.data())), - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws.data() + ws.size())), - boost::archive::iterators::ostream_iterator(os) - ); -} -#endif //BOOST_NO_STD_WSTRING - -template -BOOST_WARCHIVE_DECL(void) -xml_woarchive_impl::save(const char * s){ - save_iterator(os, s, s + std::strlen(s)); -} - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template -BOOST_WARCHIVE_DECL(void) -xml_woarchive_impl::save(const wchar_t * ws){ - os << ws; - typedef iterators::xml_escape xmbtows; - std::copy( - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws)), - xmbtows(BOOST_MAKE_PFTO_WRAPPER(ws + std::wcslen(ws))), - boost::archive::iterators::ostream_iterator(os) - ); -} -#endif - -template -BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) -xml_woarchive_impl::xml_woarchive_impl( - std::wostream & os_, - unsigned int flags -) : - basic_text_oprimitive( - os_, - true // don't change the codecvt - use the one below - ), - basic_xml_oarchive(flags) -{ - // Standard behavior is that imbue can be called - // a) before output is invoked or - // b) after flush has been called. This prevents one-to-many - // transforms (such as one to many transforms from getting - // mixed up. Unfortunately, STLPort doesn't respect b) above - // so the restoration of the original archive locale done by - // the locale_saver doesn't get processed, - // before the current one is destroyed. - // so the codecvt doesn't get replaced with the orginal - // so closing the stream invokes codecvt::do_unshift - // so it crashes because the corresponding locale that contained - // the codecvt isn't around any more. - // we can hack around this by using a static codecvt that never - // gets destroyed. - if(0 == (flags & no_codecvt)){ - boost::archive::detail::utf8_codecvt_facet *pfacet; - #if defined(__SGI_STL_PORT) - static boost::archive::detail::utf8_codecvt_facet - facet(static_cast(1)); - pfacet = & facet; - #else - pfacet = new boost::archive::detail::utf8_codecvt_facet; - #endif - archive_locale.reset(add_facet(std::locale::classic(), pfacet)); - os.imbue(* archive_locale); - } - if(0 == (flags & no_header)) - this->init(); -} - -} // namespace archive -} // namespace boost - -#endif //BOOST_NO_STD_WSTREAMBUF diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/base64_from_binary.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/base64_from_binary.hpp deleted file mode 100644 index ecb916a0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/base64_from_binary.hpp +++ /dev/null @@ -1,112 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_BASE64_FROM_BINARY_HPP -#define BOOST_ARCHIVE_ITERATORS_BASE64_FROM_BINARY_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// base64_from_binary.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // size_t -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// convert binary integers to base64 characters - -namespace detail { - -template -struct from_6_bit { - typedef CharType result_type; - CharType operator()(CharType t) const{ - const char * lookup_table = - "ABCDEFGHIJKLMNOPQRSTUVWXYZ" - "abcdefghijklmnopqrstuvwxyz" - "0123456789" - "+/"; - BOOST_ASSERT(t < 64); - return lookup_table[static_cast(t)]; - } -}; - -} // namespace detail - -// note: what we would like to do is -// template -// typedef transform_iterator< -// from_6_bit, -// transform_width -// > base64_from_binary; -// but C++ won't accept this. Rather than using a "type generator" and -// using a different syntax, make a derivation which should be equivalent. -// -// Another issue addressed here is that the transform_iterator doesn't have -// a templated constructor. This makes it incompatible with the dataflow -// ideal. This is also addressed here. - -//template -template< - class Base, - class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value::type -> -class base64_from_binary : - public transform_iterator< - detail::from_6_bit, - Base - > -{ - friend class boost::iterator_core_access; - typedef transform_iterator< - BOOST_DEDUCED_TYPENAME detail::from_6_bit, - Base - > super_t; - -public: - // make composible buy using templated constructor - template - base64_from_binary(BOOST_PFTO_WRAPPER(T) start) : - super_t( - Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start))), - detail::from_6_bit() - ) - {} - // intel 7.1 doesn't like default copy constructor - base64_from_binary(const base64_from_binary & rhs) : - super_t( - Base(rhs.base_reference()), - detail::from_6_bit() - ) - {} -// base64_from_binary(){}; -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_BASE64_FROM_BINARY_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/binary_from_base64.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/binary_from_base64.hpp deleted file mode 100644 index 2fe8292f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/binary_from_base64.hpp +++ /dev/null @@ -1,120 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_BINARY_FROM_BASE64_HPP -#define BOOST_ARCHIVE_ITERATORS_BINARY_FROM_BASE64_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// binary_from_base64.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME -#include -#include -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// convert base64 characters to binary data - -namespace detail { - -template -struct to_6_bit { - typedef CharType result_type; - CharType operator()(CharType t) const{ - const signed char lookup_table[] = { - -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, - -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, - -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63, - 52,53,54,55,56,57,58,59,60,61,-1,-1,-1, 0,-1,-1, // render '=' as 0 - -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14, - 15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1, - -1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40, - 41,42,43,44,45,46,47,48,49,50,51,-1,-1,-1,-1,-1 - }; - // metrowerks trips this assertion - how come? - #if ! defined(__MWERKS__) - BOOST_STATIC_ASSERT(128 == sizeof(lookup_table)); - #endif - signed char value = -1; - if((unsigned)t <= 127) - value = lookup_table[(unsigned)t]; - if(-1 == value) - boost::serialization::throw_exception( - dataflow_exception(dataflow_exception::invalid_base64_character) - ); - return value; - } -}; - -} // namespace detail - -// note: what we would like to do is -// template -// typedef transform_iterator< -// from_6_bit, -// transform_width -// > base64_from_binary; -// but C++ won't accept this. Rather than using a "type generator" and -// using a different syntax, make a derivation which should be equivalent. -// -// Another issue addressed here is that the transform_iterator doesn't have -// a templated constructor. This makes it incompatible with the dataflow -// ideal. This is also addressed here. - -template< - class Base, - class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value::type -> -class binary_from_base64 : public - transform_iterator< - detail::to_6_bit, - Base - > -{ - friend class boost::iterator_core_access; - typedef transform_iterator< - detail::to_6_bit, - Base - > super_t; -public: - // make composible buy using templated constructor - template - binary_from_base64(BOOST_PFTO_WRAPPER(T) start) : - super_t( - Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start))), - detail::to_6_bit() - ) - {} - // intel 7.1 doesn't like default copy constructor - binary_from_base64(const binary_from_base64 & rhs) : - super_t( - Base(rhs.base_reference()), - detail::to_6_bit() - ) - {} -// binary_from_base64(){}; -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_BINARY_FROM_BASE64_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/dataflow_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/dataflow_exception.hpp deleted file mode 100644 index 1d655a1e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/dataflow_exception.hpp +++ /dev/null @@ -1,80 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_DATAFLOW_EXCEPTION_HPP -#define BOOST_ARCHIVE_ITERATORS_DATAFLOW_EXCEPTION_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// dataflow_exception.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifndef BOOST_NO_EXCEPTIONS -#include -#endif //BOOST_NO_EXCEPTIONS - -#include - -namespace boost { -namespace archive { -namespace iterators { - -////////////////////////////////////////////////////////////////////// -// exceptions thrown by dataflows -// -class dataflow_exception : public std::exception -{ -public: - typedef enum { - invalid_6_bitcode, - invalid_base64_character, - invalid_xml_escape_sequence, - comparison_not_permitted, - invalid_conversion, - other_exception - } exception_code; - exception_code code; - - dataflow_exception(exception_code c = other_exception) : code(c) - {} - - virtual const char *what( ) const throw( ) - { - const char *msg = "unknown exception code"; - switch(code){ - case invalid_6_bitcode: - msg = "attempt to encode a value > 6 bits"; - break; - case invalid_base64_character: - msg = "attempt to decode a value not in base64 char set"; - break; - case invalid_xml_escape_sequence: - msg = "invalid xml escape_sequence"; - break; - case comparison_not_permitted: - msg = "cannot invoke iterator comparison now"; - break; - case invalid_conversion: - msg = "invalid multbyte/wide char conversion"; - break; - default: - BOOST_ASSERT(false); - break; - } - return msg; - } -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif //BOOST_ARCHIVE_ITERATORS_DATAFLOW_EXCEPTION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/escape.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/escape.hpp deleted file mode 100644 index bb527d43..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/escape.hpp +++ /dev/null @@ -1,115 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_ESCAPE_HPP -#define BOOST_ARCHIVE_ITERATORS_ESCAPE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// escape.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // NULL - -#include // for BOOST_DEDUCED_TYPENAME -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// insert escapes into text - -template -class escape : - public boost::iterator_adaptor< - Derived, - Base, - BOOST_DEDUCED_TYPENAME boost::iterator_value::type, - single_pass_traversal_tag, - BOOST_DEDUCED_TYPENAME boost::iterator_value::type - > -{ - typedef BOOST_DEDUCED_TYPENAME boost::iterator_value::type base_value_type; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_reference::type reference_type; - friend class boost::iterator_core_access; - - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - Derived, - Base, - base_value_type, - single_pass_traversal_tag, - base_value_type - > super_t; - - typedef escape this_t; - - void dereference_impl() { - m_current_value = static_cast(this)->fill(m_bnext, m_bend); - m_full = true; - } - - //Access the value referred to - reference_type dereference() const { - if(!m_full) - const_cast(this)->dereference_impl(); - return m_current_value; - } - - bool equal(const this_t & rhs) const { - if(m_full){ - if(! rhs.m_full) - const_cast(& rhs)->dereference_impl(); - } - else{ - if(rhs.m_full) - const_cast(this)->dereference_impl(); - } - if(m_bnext != rhs.m_bnext) - return false; - if(this->base_reference() != rhs.base_reference()) - return false; - return true; - } - - void increment(){ - if(++m_bnext < m_bend){ - m_current_value = *m_bnext; - return; - } - ++(this->base_reference()); - m_bnext = NULL; - m_bend = NULL; - m_full = false; - } - - // buffer to handle pending characters - const base_value_type *m_bnext; - const base_value_type *m_bend; - bool m_full; - base_value_type m_current_value; -public: - escape(Base base) : - super_t(base), - m_bnext(NULL), - m_bend(NULL), - m_full(false) - { - } -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_ESCAPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/insert_linebreaks.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/insert_linebreaks.hpp deleted file mode 100644 index 5f826cac..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/insert_linebreaks.hpp +++ /dev/null @@ -1,101 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_INSERT_LINEBREAKS_HPP -#define BOOST_ARCHIVE_ITERATORS_INSERT_LINEBREAKS_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// insert_linebreaks.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ using ::memcpy; } -#endif - -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// insert line break every N characters -template< - class Base, - int N, - class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value::type -> -class insert_linebreaks : - public iterator_adaptor< - insert_linebreaks, - Base, - CharType, - single_pass_traversal_tag, - CharType - > -{ -private: - friend class boost::iterator_core_access; - typedef iterator_adaptor< - insert_linebreaks, - Base, - CharType, - single_pass_traversal_tag, - CharType - > super_t; - - bool equal(const insert_linebreaks & rhs) const { - return -// m_count == rhs.m_count -// && base_reference() == rhs.base_reference() - this->base_reference() == rhs.base_reference() - ; - } - - void increment() { - if(m_count == N){ - m_count = 0; - return; - } - ++m_count; - ++(this->base_reference()); - } - CharType dereference() const { - if(m_count == N) - return '\n'; - return * (this->base_reference()); - } - unsigned int m_count; -public: - // make composible buy using templated constructor - template - insert_linebreaks(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))), - m_count(0) - {} - // intel 7.1 doesn't like default copy constructor - insert_linebreaks(const insert_linebreaks & rhs) : - super_t(rhs.base_reference()), - m_count(rhs.m_count) - {} -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_INSERT_LINEBREAKS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/istream_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/istream_iterator.hpp deleted file mode 100644 index 478f112f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/istream_iterator.hpp +++ /dev/null @@ -1,107 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_ISTREAM_ITERATOR_HPP -#define BOOST_ARCHIVE_ITERATORS_ISTREAM_ITERATOR_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// istream_iterator.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// note: this is a custom version of the standard istream_iterator. -// This is necessary as the standard version doesn't work as expected -// for wchar_t based streams on systems for which wchar_t not a true -// type but rather a synonym for some integer type. - -#include // NULL -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -// given a type, make an input iterator based on a pointer to that type -template -class istream_iterator : - public boost::iterator_facade< - istream_iterator, - Elem, - std::input_iterator_tag, - Elem - > -{ - friend class boost::iterator_core_access; - typedef istream_iterator this_t ; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_facade< - istream_iterator, - Elem, - std::input_iterator_tag, - Elem - > super_t; - typedef BOOST_DEDUCED_TYPENAME std::basic_istream istream_type; - - bool equal(const this_t & rhs) const { - // note: only works for comparison against end of stream - return m_istream == rhs.m_istream; - } - -/* - //Access the value referred to - Elem dereference() const { - return m_current_value; - } - - void increment(){ - if(NULL != m_istream){ - m_current_value = static_cast(m_istream->get()); - if(! m_istream->good()){ - const_cast(this)->m_istream = NULL; - } - } - } -*/ - //Access the value referred to - Elem dereference() const { - return m_istream->peek(); - } - - void increment(){ - if(NULL != m_istream){ - m_istream->ignore(1); - } - } - - istream_type *m_istream; - Elem m_current_value; -public: - istream_iterator(istream_type & is) : - m_istream(& is) - { - //increment(); - } - - istream_iterator() : - m_istream(NULL) - {} - - istream_iterator(const istream_iterator & rhs) : - m_istream(rhs.m_istream), - m_current_value(rhs.m_current_value) - {} - -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_ISTREAM_ITERATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/mb_from_wchar.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/mb_from_wchar.hpp deleted file mode 100644 index d8f8a129..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/mb_from_wchar.hpp +++ /dev/null @@ -1,136 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_MB_FROM_WCHAR_HPP -#define BOOST_ARCHIVE_ITERATORS_MB_FROM_WCHAR_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// mb_from_wchar.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // size_t -#include // for wctomb() - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; - using ::wctomb; -} // namespace std -#endif - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// class used by text archives to translate wide strings and to char -// strings of the currently selected locale -template // the input iterator -class mb_from_wchar - : public boost::iterator_adaptor< - mb_from_wchar, - Base, - wchar_t, - single_pass_traversal_tag, - char - > -{ - friend class boost::iterator_core_access; - - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - mb_from_wchar, - Base, - wchar_t, - single_pass_traversal_tag, - char - > super_t; - - typedef mb_from_wchar this_t; - - char dereference_impl() { - if(! m_full){ - fill(); - m_full = true; - } - return m_buffer[m_bnext]; - } - char dereference() const { - return (const_cast(this))->dereference_impl(); - } - - // test for iterator equality - bool equal(const mb_from_wchar & rhs) const { - // once the value is filled, the base_reference has been incremented - // so don't permit comparison anymore. - return - 0 == m_bend - && 0 == m_bnext - && this->base_reference() == rhs.base_reference() - ; - } - - void fill(){ - wchar_t value = * this->base_reference(); - #if (defined(__MINGW32__) && ((__MINGW32_MAJOR_VERSION > 3) \ - || ((__MINGW32_MAJOR_VERSION == 3) && (__MINGW32_MINOR_VERSION >= 8)))) - m_bend = std::wcrtomb(m_buffer, value, 0); - #else - m_bend = std::wctomb(m_buffer, value); - #endif - BOOST_ASSERT(-1 != m_bend); - BOOST_ASSERT((std::size_t)m_bend <= sizeof(m_buffer)); - BOOST_ASSERT(m_bend > 0); - m_bnext = 0; - } - - void increment(){ - if(++m_bnext < m_bend) - return; - m_bend = - m_bnext = 0; - ++(this->base_reference()); - m_full = false; - } - - // buffer to handle pending characters - int m_bend; - int m_bnext; - char m_buffer[9]; - bool m_full; - -public: - // make composible buy using templated constructor - template - mb_from_wchar(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))), - m_bend(0), - m_bnext(0), - m_full(false) - {} - // intel 7.1 doesn't like default copy constructor - mb_from_wchar(const mb_from_wchar & rhs) : - super_t(rhs.base_reference()), - m_bend(rhs.m_bend), - m_bnext(rhs.m_bnext), - m_full(rhs.m_full) - {} -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_MB_FROM_WCHAR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/ostream_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/ostream_iterator.hpp deleted file mode 100644 index 7c3203f1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/ostream_iterator.hpp +++ /dev/null @@ -1,83 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_OSTREAM_ITERATOR_HPP -#define BOOST_ARCHIVE_ITERATORS_OSTREAM_ITERATOR_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// ostream_iterator.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// note: this is a custom version of the standard ostream_iterator. -// This is necessary as the standard version doesn't work as expected -// for wchar_t based streams on systems for which wchar_t not a true -// type but rather a synonym for some integer type. - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -// given a type, make an input iterator based on a pointer to that type -template -class ostream_iterator : - public boost::iterator_facade< - ostream_iterator, - Elem, - std::output_iterator_tag, - ostream_iterator & - > -{ - friend class boost::iterator_core_access; - typedef ostream_iterator this_t ; - typedef Elem char_type; - typedef std::basic_ostream ostream_type; - - //emulate the behavior of std::ostream - ostream_iterator & dereference() const { - return const_cast(*this); - } - bool equal(const this_t & rhs) const { - return m_ostream == rhs.m_ostream; - } - void increment(){} -protected: - ostream_type *m_ostream; - void put_val(char_type e){ - if(NULL != m_ostream){ - m_ostream->put(e); - if(! m_ostream->good()) - m_ostream = NULL; - } - } -public: - this_t & operator=(char_type c){ - put_val(c); - return *this; - } - ostream_iterator(ostream_type & os) : - m_ostream (& os) - {} - ostream_iterator() : - m_ostream (NULL) - {} - ostream_iterator(const ostream_iterator & rhs) : - m_ostream (rhs.m_ostream) - {} -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_OSTREAM_ITERATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/remove_whitespace.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/remove_whitespace.hpp deleted file mode 100644 index a01049fa..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/remove_whitespace.hpp +++ /dev/null @@ -1,176 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_REMOVE_WHITESPACE_HPP -#define BOOST_ARCHIVE_ITERATORS_REMOVE_WHITESPACE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// remove_whitespace.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME - -#include - -#include -#include -#include - -//#include -//#if ! BOOST_WORKAROUND(BOOST_MSVC, <=1300) - -// here is the default standard implementation of the functor used -// by the filter iterator to remove spaces. Unfortunately usage -// of this implementation in combination with spirit trips a bug -// VC 6.5. The only way I can find to work around it is to -// implement a special non-standard version for this platform - -#ifndef BOOST_NO_CWCTYPE -#include // iswspace -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ using ::iswspace; } -#endif -#endif - -#include // isspace -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ using ::isspace; } -#endif - -#if defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) -// this is required for the RW STL on Linux and Tru64. -#undef isspace -#undef iswspace -#endif - -//#endif // BOOST_WORKAROUND - -namespace { // anonymous - -template -struct remove_whitespace_predicate; - -template<> -struct remove_whitespace_predicate -{ - bool operator()(unsigned char t){ - return ! std::isspace(t); - } -}; - -#ifndef BOOST_NO_CWCHAR -template<> -struct remove_whitespace_predicate -{ - bool operator()(wchar_t t){ - return ! std::iswspace(t); - } -}; -#endif - -} // namespace anonymous - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// convert base64 file data (including whitespace and padding) to binary - -namespace boost { -namespace archive { -namespace iterators { - -// custom version of filter iterator which doesn't look ahead further than -// necessary - -template -class filter_iterator - : public boost::iterator_adaptor< - filter_iterator, - Base, - use_default, - single_pass_traversal_tag - > -{ - friend class boost::iterator_core_access; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - filter_iterator, - Base, - use_default, - single_pass_traversal_tag - > super_t; - typedef filter_iterator this_t; - typedef BOOST_DEDUCED_TYPENAME super_t::reference reference_type; - - reference_type dereference_impl(){ - if(! m_full){ - while(! m_predicate(* this->base_reference())) - ++(this->base_reference()); - m_full = true; - } - return * this->base_reference(); - } - - reference_type dereference() const { - return const_cast(this)->dereference_impl(); - } - - Predicate m_predicate; - bool m_full; -public: - // note: this function is public only because comeau compiler complained - // I don't know if this is because the compiler is wrong or what - void increment(){ - m_full = false; - ++(this->base_reference()); - } - filter_iterator(Base start) : - super_t(start), - m_full(false) - {} - filter_iterator(){} -}; - -template -class remove_whitespace : - public filter_iterator< - remove_whitespace_predicate< - BOOST_DEDUCED_TYPENAME boost::iterator_value::type - //BOOST_DEDUCED_TYPENAME Base::value_type - >, - Base - > -{ - friend class boost::iterator_core_access; - typedef filter_iterator< - remove_whitespace_predicate< - BOOST_DEDUCED_TYPENAME boost::iterator_value::type - //BOOST_DEDUCED_TYPENAME Base::value_type - >, - Base - > super_t; -public: -// remove_whitespace(){} // why is this needed? - // make composible buy using templated constructor - template - remove_whitespace(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))) - {} - // intel 7.1 doesn't like default copy constructor - remove_whitespace(const remove_whitespace & rhs) : - super_t(rhs.base_reference()) - {} -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_REMOVE_WHITESPACE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/transform_width.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/transform_width.hpp deleted file mode 100644 index 5a5c7b75..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/transform_width.hpp +++ /dev/null @@ -1,172 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_TRANSFORM_WIDTH_HPP -#define BOOST_ARCHIVE_ITERATORS_TRANSFORM_WIDTH_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// transform_width.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -// iterator which takes elements of x bits and returns elements of y bits. -// used to change streams of 8 bit characters into streams of 6 bit characters. -// and vice-versa for implementing base64 encodeing/decoding. Be very careful -// when using and end iterator. end is only reliable detected when the input -// stream length is some common multiple of x and y. E.G. Base64 6 bit -// character and 8 bit bytes. Lowest common multiple is 24 => 4 6 bit characters -// or 3 8 bit characters - -#include // for BOOST_DEDUCED_TYPENAME & PTFO -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// class used by text archives to translate char strings to wchar_t -// strings of the currently selected locale -template< - class Base, - int BitsOut, - int BitsIn, - class CharType = BOOST_DEDUCED_TYPENAME boost::iterator_value::type // output character -> -class transform_width : - public boost::iterator_adaptor< - transform_width, - Base, - CharType, - single_pass_traversal_tag, - CharType - > -{ - friend class boost::iterator_core_access; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - transform_width, - Base, - CharType, - single_pass_traversal_tag, - CharType - > super_t; - - typedef transform_width this_t; - typedef BOOST_DEDUCED_TYPENAME iterator_value::type base_value_type; - - void fill(); - - CharType dereference() const { - if(!m_buffer_out_full) - const_cast(this)->fill(); - return m_buffer_out; - } - - bool equal_impl(const this_t & rhs){ - if(BitsIn < BitsOut) // discard any left over bits - return this->base_reference() == rhs.base_reference(); - else{ - // BitsIn > BitsOut // zero fill - if(this->base_reference() == rhs.base_reference()){ - m_end_of_sequence = true; - return 0 == m_remaining_bits; - } - return false; - } - } - - // standard iterator interface - bool equal(const this_t & rhs) const { - return const_cast(this)->equal_impl(rhs); - } - - void increment(){ - m_buffer_out_full = false; - } - - bool m_buffer_out_full; - CharType m_buffer_out; - - // last read element from input - base_value_type m_buffer_in; - - // number of bits to left in the input buffer. - unsigned int m_remaining_bits; - - // flag to indicate we've reached end of data. - bool m_end_of_sequence; - -public: - // make composible buy using templated constructor - template - transform_width(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))), - m_buffer_out_full(false), - m_remaining_bits(0), - m_end_of_sequence(false) - {} - // intel 7.1 doesn't like default copy constructor - transform_width(const transform_width & rhs) : - super_t(rhs.base_reference()), - m_buffer_out_full(rhs.m_buffer_out_full), - m_remaining_bits(rhs.m_remaining_bits), - m_buffer_in(rhs.m_buffer_in), - m_end_of_sequence(false) - {} -}; - -template< - class Base, - int BitsOut, - int BitsIn, - class CharType -> -void transform_width::fill() { - unsigned int missing_bits = BitsOut; - m_buffer_out = 0; - do{ - if(0 == m_remaining_bits){ - if(m_end_of_sequence){ - m_buffer_in = 0; - m_remaining_bits = missing_bits; - } - else{ - m_buffer_in = * this->base_reference()++; - m_remaining_bits = BitsIn; - } - } - - // append these bits to the next output - // up to the size of the output - unsigned int i = std::min(missing_bits, m_remaining_bits); - // shift interesting bits to least significant position - base_value_type j = m_buffer_in >> (m_remaining_bits - i); - // and mask off the un interesting higher bits - // note presumption of twos complement notation - j &= (1 << i) - 1; - // append then interesting bits to the output value - m_buffer_out <<= i; - m_buffer_out |= j; - - // and update counters - missing_bits -= i; - m_remaining_bits -= i; - }while(0 < missing_bits); - m_buffer_out_full = true; -} - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_TRANSFORM_WIDTH_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/unescape.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/unescape.hpp deleted file mode 100644 index 9cbd3161..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/unescape.hpp +++ /dev/null @@ -1,91 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_UNESCAPE_HPP -#define BOOST_ARCHIVE_ITERATORS_UNESCAPE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// unescape.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME -#include -//#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// class used by text archives to translate char strings to wchar_t -// strings of the currently selected locale -template -class unescape - : public boost::iterator_adaptor< - unescape, - Base, - BOOST_DEDUCED_TYPENAME pointee::type, - single_pass_traversal_tag, - BOOST_DEDUCED_TYPENAME pointee::type - > -{ - friend class boost::iterator_core_access; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - unescape, - Base, - BOOST_DEDUCED_TYPENAME pointee::type, - single_pass_traversal_tag, - BOOST_DEDUCED_TYPENAME pointee::type - > super_t; - - typedef unescape this_t; -public: - typedef BOOST_DEDUCED_TYPENAME this_t::value_type value_type; - typedef BOOST_DEDUCED_TYPENAME this_t::reference reference; -private: - value_type dereference_impl() { - if(! m_full){ - m_current_value = static_cast(this)->drain(); - m_full = true; - } - return m_current_value; - } - - reference dereference() const { - return const_cast(this)->dereference_impl(); - } - - value_type m_current_value; - bool m_full; - - void increment(){ - ++(this->base_reference()); - dereference_impl(); - m_full = false; - }; - -public: - - unescape(Base base) : - super_t(base), - m_full(false) - {} - -}; - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_UNESCAPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/wchar_from_mb.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/wchar_from_mb.hpp deleted file mode 100644 index 4da81215..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/wchar_from_mb.hpp +++ /dev/null @@ -1,129 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_WCHAR_FROM_MB_HPP -#define BOOST_ARCHIVE_ITERATORS_WCHAR_FROM_MB_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// wchar_from_mb.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include // size_t -#include // mblen - -#include // for BOOST_DEDUCED_TYPENAME -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::mblen; - using ::mbtowc; -} // namespace std -#endif - -#include -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// class used by text archives to translate char strings to wchar_t -// strings of the currently selected locale -template -class wchar_from_mb - : public boost::iterator_adaptor< - wchar_from_mb, - Base, - wchar_t, - single_pass_traversal_tag, - wchar_t - > -{ - friend class boost::iterator_core_access; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_adaptor< - wchar_from_mb, - Base, - wchar_t, - single_pass_traversal_tag, - wchar_t - > super_t; - - typedef wchar_from_mb this_t; - - wchar_t drain(); - - wchar_t dereference_impl() { - if(! m_full){ - m_current_value = drain(); - m_full = true; - } - return m_current_value; - } - - wchar_t dereference() const { - return const_cast(this)->dereference_impl(); - } - - void increment(){ - dereference_impl(); - m_full = false; - ++(this->base_reference()); - }; - - wchar_t m_current_value; - bool m_full; - -public: - // make composible buy using templated constructor - template - wchar_from_mb(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))), - m_full(false) - {} - // intel 7.1 doesn't like default copy constructor - wchar_from_mb(const wchar_from_mb & rhs) : - super_t(rhs.base_reference()), - m_full(rhs.m_full) - {} -}; - -template -wchar_t wchar_from_mb::drain(){ - char buffer[9]; - char * bptr = buffer; - char val; - for(std::size_t i = 0; i++ < (unsigned)MB_CUR_MAX;){ - val = * this->base_reference(); - *bptr++ = val; - int result = std::mblen(buffer, i); - if(-1 != result) - break; - ++(this->base_reference()); - } - wchar_t retval; - int result = std::mbtowc(& retval, buffer, MB_CUR_MAX); - if(0 >= result) - boost::serialization::throw_exception(iterators::dataflow_exception( - iterators::dataflow_exception::invalid_conversion - )); - return retval; -} - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_WCHAR_FROM_MB_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_escape.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_escape.hpp deleted file mode 100644 index eadb96e8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_escape.hpp +++ /dev/null @@ -1,125 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_XML_ESCAPE_HPP -#define BOOST_ARCHIVE_ITERATORS_XML_ESCAPE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_escape.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME -#include - -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// insert escapes into xml text - -template -class xml_escape - : public escape, Base> -{ - friend class boost::iterator_core_access; - - typedef escape, Base> super_t; - -public: - char fill(const char * & bstart, const char * & bend); - wchar_t fill(const wchar_t * & bstart, const wchar_t * & bend); - - template - xml_escape(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))) - {} - // intel 7.1 doesn't like default copy constructor - xml_escape(const xml_escape & rhs) : - super_t(rhs.base_reference()) - {} -}; - -template -char xml_escape::fill( - const char * & bstart, - const char * & bend -){ - char current_value = * this->base_reference(); - switch(current_value){ - case '<': - bstart = "<"; - bend = bstart + 4; - break; - case '>': - bstart = ">"; - bend = bstart + 4; - break; - case '&': - bstart = "&"; - bend = bstart + 5; - break; - case '"': - bstart = """; - bend = bstart + 6; - break; - case '\'': - bstart = "'"; - bend = bstart + 6; - break; - default: - return current_value; - } - return *bstart; -} - -template -wchar_t xml_escape::fill( - const wchar_t * & bstart, - const wchar_t * & bend -){ - wchar_t current_value = * this->base_reference(); - switch(current_value){ - case '<': - bstart = L"<"; - bend = bstart + 4; - break; - case '>': - bstart = L">"; - bend = bstart + 4; - break; - case '&': - bstart = L"&"; - bend = bstart + 5; - break; - case '"': - bstart = L"""; - bend = bstart + 6; - break; - case '\'': - bstart = L"'"; - bend = bstart + 6; - break; - default: - return current_value; - } - return *bstart; -} - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_XML_ESCAPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_unescape.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_unescape.hpp deleted file mode 100644 index 3295adb3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/iterators/xml_unescape.hpp +++ /dev/null @@ -1,128 +0,0 @@ -#ifndef BOOST_ARCHIVE_ITERATORS_XML_UNESCAPE_HPP -#define BOOST_ARCHIVE_ITERATORS_XML_UNESCAPE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_unescape.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // for BOOST_DEDUCED_TYPENAME - -#include -#include - -#include -#include - -namespace boost { -namespace archive { -namespace iterators { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// replace &??? xml escape sequences with the corresponding characters -template -class xml_unescape - : public unescape, Base> -{ - friend class boost::iterator_core_access; - typedef xml_unescape this_t; - typedef unescape super_t; - typedef BOOST_DEDUCED_TYPENAME boost::iterator_reference reference_type; - - reference_type dereference() const { - return unescape, Base>::dereference(); - } -public: - // workaround msvc 7.1 ICU crash - #if defined(BOOST_MSVC) - typedef int value_type; - #else - typedef BOOST_DEDUCED_TYPENAME this_t::value_type value_type; - #endif - - void drain_residue(const char *literal); - value_type drain(); - - template - xml_unescape(BOOST_PFTO_WRAPPER(T) start) : - super_t(Base(BOOST_MAKE_PFTO_WRAPPER(static_cast< T >(start)))) - {} - // intel 7.1 doesn't like default copy constructor - xml_unescape(const xml_unescape & rhs) : - super_t(rhs.base_reference()) - {} -}; - -template -void xml_unescape::drain_residue(const char * literal){ - do{ - if(* literal != * ++(this->base_reference())) - boost::serialization::throw_exception( - dataflow_exception( - dataflow_exception::invalid_xml_escape_sequence - ) - ); - } - while('\0' != * ++literal); -} - -// note key constraint on this function is that can't "look ahead" any -// more than necessary into base iterator. Doing so would alter the base -// iterator refenence which would make subsequent iterator comparisons -// incorrect and thereby break the composiblity of iterators. -template -BOOST_DEDUCED_TYPENAME xml_unescape::value_type -//int -xml_unescape::drain(){ - value_type retval = * this->base_reference(); - if('&' != retval){ - return retval; - } - retval = * ++(this->base_reference()); - switch(retval){ - case 'l': // < - drain_residue("t;"); - retval = '<'; - break; - case 'g': // > - drain_residue("t;"); - retval = '>'; - break; - case 'a': - retval = * ++(this->base_reference()); - switch(retval){ - case 'p': // ' - drain_residue("os;"); - retval = '\''; - break; - case 'm': // & - drain_residue("p;"); - retval = '&'; - break; - } - break; - case 'q': - drain_residue("uot;"); - retval = '"'; - break; - } - return retval; -} - -} // namespace iterators -} // namespace archive -} // namespace boost - -#endif // BOOST_ARCHIVE_ITERATORS_XML_UNESCAPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_iarchive.hpp deleted file mode 100644 index 2f76cf26..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_iarchive.hpp +++ /dev/null @@ -1,181 +0,0 @@ -#ifndef BOOST_ARCHIVE_POLYMORPHIC_IARCHIVE_HPP -#define BOOST_ARCHIVE_POLYMORPHIC_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// polymorphic_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // std::size_t -#include // ULONG_MAX -#include - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include - -#include -#include -#include -#include -#include - -#include -#include // must be the last header - -namespace boost { -template -class shared_ptr; -namespace serialization { - class extended_type_info; -} // namespace serialization -namespace archive { -namespace detail { - class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive; - class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_iarchive; -} - -class polymorphic_iarchive; - -class polymorphic_iarchive_impl : - public detail::interface_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class load_access; -#endif - // primitive types the only ones permitted by polymorphic archives - virtual void load(bool & t) = 0; - - virtual void load(char & t) = 0; - virtual void load(signed char & t) = 0; - virtual void load(unsigned char & t) = 0; - #ifndef BOOST_NO_CWCHAR - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - virtual void load(wchar_t & t) = 0; - #endif - #endif - virtual void load(short & t) = 0; - virtual void load(unsigned short & t) = 0; - virtual void load(int & t) = 0; - virtual void load(unsigned int & t) = 0; - virtual void load(long & t) = 0; - virtual void load(unsigned long & t) = 0; - - #if defined(BOOST_HAS_LONG_LONG) - virtual void load(boost::long_long_type & t) = 0; - virtual void load(boost::ulong_long_type & t) = 0; - #elif defined(BOOST_HAS_MS_INT64) - virtual void load(__int64 & t) = 0; - virtual void load(unsigned __int64 & t) = 0; - #endif - - virtual void load(float & t) = 0; - virtual void load(double & t) = 0; - - // string types are treated as primitives - virtual void load(std::string & t) = 0; - #ifndef BOOST_NO_STD_WSTRING - virtual void load(std::wstring & t) = 0; - #endif - - // used for xml and other tagged formats - virtual void load_start(const char * name) = 0; - virtual void load_end(const char * name) = 0; - virtual void register_basic_serializer(const detail::basic_iserializer & bis) = 0; - - // msvc and borland won't automatically pass these to the base class so - // make it explicit here - template - void load_override(T & t, BOOST_PFTO int) - { - archive::load(* this->This(), t); - } - // special treatment for name-value pairs. - template - void load_override( - #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - const - #endif - boost::serialization::nvp< T > & t, - int - ){ - load_start(t.name()); - archive::load(* this->This(), t.value()); - load_end(t.name()); - } -protected: - virtual ~polymorphic_iarchive_impl(){}; -public: - // utility function implemented by all legal archives - virtual void set_library_version(library_version_type archive_library_version) = 0; - virtual library_version_type get_library_version() const = 0; - virtual unsigned int get_flags() const = 0; - virtual void delete_created_pointers() = 0; - virtual void reset_object_address( - const void * new_address, - const void * old_address - ) = 0; - - virtual void load_binary(void * t, std::size_t size) = 0; - - // these are used by the serialization library implementation. - virtual void load_object( - void *t, - const detail::basic_iserializer & bis - ) = 0; - virtual const detail::basic_pointer_iserializer * load_pointer( - void * & t, - const detail::basic_pointer_iserializer * bpis_ptr, - const detail::basic_pointer_iserializer * (*finder)( - const boost::serialization::extended_type_info & type - ) - ) = 0; -}; - -} // namespace archive -} // namespace boost - -#include // pops abi_suffix.hpp pragmas - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -namespace boost { -namespace archive { - -class polymorphic_iarchive : - public polymorphic_iarchive_impl, - public detail::shared_ptr_helper -{ -public: - virtual ~polymorphic_iarchive(){}; -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::polymorphic_iarchive) - -#endif // BOOST_ARCHIVE_POLYMORPHIC_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_oarchive.hpp deleted file mode 100644 index 420029b5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/polymorphic_oarchive.hpp +++ /dev/null @@ -1,159 +0,0 @@ -#ifndef BOOST_ARCHIVE_POLYMORPHIC_OARCHIVE_HPP -#define BOOST_ARCHIVE_POLYMORPHIC_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// polymorphic_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // size_t -#include // ULONG_MAX -#include - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include -#include - -#include -#include // must be the last header - -namespace boost { -template -class shared_ptr; -namespace serialization { - class extended_type_info; -} // namespace serialization -namespace archive { -namespace detail { - class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oarchive; - class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) basic_oserializer; -} - -class polymorphic_oarchive; - -class polymorphic_oarchive_impl : - public detail::interface_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class save_access; -#endif - // primitive types the only ones permitted by polymorphic archives - virtual void save(const bool t) = 0; - - virtual void save(const char t) = 0; - virtual void save(const signed char t) = 0; - virtual void save(const unsigned char t) = 0; - #ifndef BOOST_NO_CWCHAR - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - virtual void save(const wchar_t t) = 0; - #endif - #endif - virtual void save(const short t) = 0; - virtual void save(const unsigned short t) = 0; - virtual void save(const int t) = 0; - virtual void save(const unsigned int t) = 0; - virtual void save(const long t) = 0; - virtual void save(const unsigned long t) = 0; - - #if defined(BOOST_HAS_LONG_LONG) - virtual void save(const boost::long_long_type t) = 0; - virtual void save(const boost::ulong_long_type t) = 0; - #elif defined(BOOST_HAS_MS_INT64) - virtual void save(const __int64 t) = 0; - virtual void save(const unsigned __int64 t) = 0; - #endif - - virtual void save(const float t) = 0; - virtual void save(const double t) = 0; - - // string types are treated as primitives - virtual void save(const std::string & t) = 0; - #ifndef BOOST_NO_STD_WSTRING - virtual void save(const std::wstring & t) = 0; - #endif - - virtual void save_null_pointer() = 0; - // used for xml and other tagged formats - virtual void save_start(const char * name) = 0; - virtual void save_end(const char * name) = 0; - virtual void register_basic_serializer(const detail::basic_oserializer & bos) = 0; - - virtual void end_preamble() = 0; - - // msvc and borland won't automatically pass these to the base class so - // make it explicit here - template - void save_override(T & t, BOOST_PFTO int) - { - archive::save(* this->This(), t); - } - // special treatment for name-value pairs. - template - void save_override( - #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - const - #endif - ::boost::serialization::nvp< T > & t, int - ){ - save_start(t.name()); - archive::save(* this->This(), t.const_value()); - save_end(t.name()); - } -protected: - virtual ~polymorphic_oarchive_impl(){}; -public: - // utility functions implemented by all legal archives - virtual unsigned int get_flags() const = 0; - virtual library_version_type get_library_version() const = 0; - virtual void save_binary(const void * t, std::size_t size) = 0; - - virtual void save_object( - const void *x, - const detail::basic_oserializer & bos - ) = 0; - virtual void save_pointer( - const void * t, - const detail::basic_pointer_oserializer * bpos_ptr - ) = 0; -}; - -// note: preserve naming symmetry -class polymorphic_oarchive : - public polymorphic_oarchive_impl -{ -public: - virtual ~polymorphic_oarchive(){}; -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::polymorphic_oarchive) - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_POLYMORPHIC_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/shared_ptr_helper.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/shared_ptr_helper.hpp deleted file mode 100644 index 39e6eb82..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/shared_ptr_helper.hpp +++ /dev/null @@ -1,219 +0,0 @@ -#ifndef BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP -#define BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// shared_ptr_helper.hpp: serialization for boost shared pointern - -// (C) Copyright 2004-2009 Robert Ramey, Martin Ecker and Takatoshi Kondo -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include -#include -#include // NULL - -#include -#include - -#include -#include -#include -#include - -#include -#include - -#include // must be the last headern - -namespace boost_132 { - template class shared_ptr; -} -namespace boost { - template class shared_ptr; - namespace serialization { - class extended_type_info; - template - inline void load( - Archive & ar, - boost::shared_ptr< T > &t, - const unsigned int file_version - ); - } -namespace archive{ -namespace detail { - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// a common class for holding various types of shared pointers - -class shared_ptr_helper { - struct collection_type_compare { - bool operator()( - const shared_ptr &lhs, - const shared_ptr &rhs - )const{ - return lhs.get() < rhs.get(); - } - }; - typedef std::set< - boost::shared_ptr, - collection_type_compare - > collection_type; - typedef collection_type::const_iterator iterator_type; - // list of shared_pointers create accessable by raw pointer. This - // is used to "match up" shared pointers loaded at different - // points in the archive. Note, we delay construction until - // it is actually used since this is by default included as - // a "mix-in" even if shared_ptr isn't used. - collection_type * m_pointers; - - struct null_deleter { - void operator()(void const *) const {} - }; - - struct void_deleter { - const boost::serialization::extended_type_info * m_eti; - void_deleter(const boost::serialization::extended_type_info *eti) : - m_eti(eti) - {} - void operator()(void *vp) const { - m_eti->destroy(vp); - } - }; - -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - template - friend inline void boost::serialization::load( - Archive & ar, - boost::shared_ptr< T > &t, - const unsigned int file_version - ); -#endif - -// #ifdef BOOST_SERIALIZATION_SHARED_PTR_132_HPP - // list of loaded pointers. This is used to be sure that the pointers - // stay around long enough to be "matched" with other pointers loaded - // by the same archive. These are created with a "null_deleter" so that - // when this list is destroyed - the underlaying raw pointers are not - // destroyed. This has to be done because the pointers are also held by - // new system which is disjoint from this set. This is implemented - // by a change in load_construct_data below. It makes this file suitable - // only for loading pointers into a 1.33 or later boost system. - std::list > * m_pointers_132; -// #endif - - // returns pointer to object and an indicator whether this is a - // new entry (true) or a previous one (false) - BOOST_ARCHIVE_DECL(shared_ptr) - get_od( - const void * od, - const boost::serialization::extended_type_info * true_type, - const boost::serialization::extended_type_info * this_type - ); - - BOOST_ARCHIVE_DECL(void) - append(const boost::shared_ptr &); - - template - struct non_polymorphic { - static const boost::serialization::extended_type_info * - get_object_identifier(T &){ - return & boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance(); - } - }; - template - struct polymorphic { - static const boost::serialization::extended_type_info * - get_object_identifier(T & t){ - return boost::serialization::singleton< - BOOST_DEDUCED_TYPENAME - boost::serialization::type_info_implementation< T >::type - >::get_const_instance().get_derived_extended_type_info(t); - } - }; -public: - template - void reset(shared_ptr< T > & s, T * t){ - if(NULL == t){ - s.reset(); - return; - } - const boost::serialization::extended_type_info * this_type - = & boost::serialization::type_info_implementation< T >::type - ::get_const_instance(); - - // get pointer to the most derived object. This is effectively - // the object identifern - typedef BOOST_DEDUCED_TYPENAME mpl::eval_if< - is_polymorphic< T >, - mpl::identity >, - mpl::identity > - >::type type; - - const boost::serialization::extended_type_info * true_type - = type::get_object_identifier(*t); - - // note:if this exception is thrown, be sure that derived pointern - // is either registered or exported. - if(NULL == true_type) - boost::serialization::throw_exception( - archive_exception( - archive_exception::unregistered_class, - this_type->get_debug_info() - ) - ); - shared_ptr r = - get_od( - static_cast(t), - true_type, - this_type - ); - if(!r){ - s.reset(t); - const void * od = void_downcast( - *true_type, - *this_type, - static_cast(t) - ); - shared_ptr sp(s, od); - append(sp); - } - else{ - s = shared_ptr< T >( - r, - static_cast(r.get()) - ); - } - } - -// #ifdef BOOST_SERIALIZATION_SHARED_PTR_132_HPP - BOOST_ARCHIVE_DECL(void) - append(const boost_132::shared_ptr & t); -// #endif -public: - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - shared_ptr_helper(); - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - ~shared_ptr_helper(); -}; - -} // namespace detail -} // namespace archive -} // namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_SHARED_PTR_HELPER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/text_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/text_iarchive.hpp deleted file mode 100644 index 298928b3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/text_iarchive.hpp +++ /dev/null @@ -1,156 +0,0 @@ -#ifndef BOOST_ARCHIVE_TEXT_IARCHIVE_HPP -#define BOOST_ARCHIVE_TEXT_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class text_iarchive_impl : - public basic_text_iprimitive, - public basic_text_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class basic_text_iarchive; - friend class load_access; -protected: -#endif - template - void load(T & t){ - basic_text_iprimitive::load(t); - } - void load(version_type & t){ - unsigned int v; - load(v); - t = version_type(v); - } - void load(boost::serialization::item_version_type & t){ - unsigned int v; - load(v); - t = boost::serialization::item_version_type(v); - } - BOOST_ARCHIVE_DECL(void) - load(char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_ARCHIVE_DECL(void) - load(wchar_t * t); - #endif - BOOST_ARCHIVE_DECL(void) - load(std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_DECL(void) - load(std::wstring &ws); - #endif - // note: the following should not needed - but one compiler (vc 7.1) - // fails to compile one test (test_shared_ptr) without it !!! - // make this protected so it can be called from a derived archive - template - void load_override(T & t, BOOST_PFTO int){ - basic_text_iarchive::load_override(t, 0); - } - BOOST_ARCHIVE_DECL(void) - load_override(class_name_type & t, int); - BOOST_ARCHIVE_DECL(void) - init(); - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - text_iarchive_impl(std::istream & is, unsigned int flags); - // don't import inline definitions! leave this as a reminder. - //BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - ~text_iarchive_impl(){}; -}; - -// do not derive from the classes below. If you want to extend this functionality -// via inhertance, derived from text_iarchive_impl instead. This will -// preserve correct static polymorphism. - -// same as text_iarchive below - without the shared_ptr_helper -class naked_text_iarchive : - public text_iarchive_impl -{ -public: - naked_text_iarchive(std::istream & is_, unsigned int flags = 0) : - // note: added _ to suppress useless gcc warning - text_iarchive_impl(is_, flags) - {} - ~naked_text_iarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -class text_iarchive : - public text_iarchive_impl, - public detail::shared_ptr_helper -{ -public: - text_iarchive(std::istream & is_, unsigned int flags = 0) : - // note: added _ to suppress useless gcc warning - text_iarchive_impl(is_, flags) - {} - ~text_iarchive(){} -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::text_iarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_TEXT_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/text_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/text_oarchive.hpp deleted file mode 100644 index 2100d539..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/text_oarchive.hpp +++ /dev/null @@ -1,119 +0,0 @@ -#ifndef BOOST_ARCHIVE_TEXT_OARCHIVE_HPP -#define BOOST_ARCHIVE_TEXT_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include // std::size_t - -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class text_oarchive_impl : - /* protected ? */ public basic_text_oprimitive, - public basic_text_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class basic_text_oarchive; - friend class save_access; -protected: -#endif - template - void save(const T & t){ - this->newtoken(); - basic_text_oprimitive::save(t); - } - void save(const version_type & t){ - save(static_cast(t)); - } - void save(const boost::serialization::item_version_type & t){ - save(static_cast(t)); - } - BOOST_ARCHIVE_DECL(void) - save(const char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_ARCHIVE_DECL(void) - save(const wchar_t * t); - #endif - BOOST_ARCHIVE_DECL(void) - save(const std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_DECL(void) - save(const std::wstring &ws); - #endif - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - text_oarchive_impl(std::ostream & os, unsigned int flags); - // don't import inline definitions! leave this as a reminder. - //BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - ~text_oarchive_impl(){}; -public: - BOOST_ARCHIVE_DECL(void) - save_binary(const void *address, std::size_t count); -}; - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from text_oarchive_impl instead. This will -// preserve correct static polymorphism. -class text_oarchive : - public text_oarchive_impl -{ -public: - text_oarchive(std::ostream & os_, unsigned int flags = 0) : - // note: added _ to suppress useless gcc warning - text_oarchive_impl(os_, flags) - {} - ~text_oarchive(){} -}; - -typedef text_oarchive naked_text_oarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::text_oarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_TEXT_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/text_wiarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/text_wiarchive.hpp deleted file mode 100644 index 7451f3a6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/text_wiarchive.hpp +++ /dev/null @@ -1,152 +0,0 @@ -#ifndef BOOST_ARCHIVE_TEXT_WIARCHIVE_HPP -#define BOOST_ARCHIVE_TEXT_WIARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_wiarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include - -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class text_wiarchive_impl : - public basic_text_iprimitive, - public basic_text_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class basic_text_iarchive; - friend class load_access; -protected: -#endif - template - void load(T & t){ - basic_text_iprimitive::load(t); - } - void load(version_type & t){ - unsigned int v; - load(v); - t = version_type(v); - } - void load(boost::serialization::item_version_type & t){ - unsigned int v; - load(v); - t = boost::serialization::item_version_type(v); - } - BOOST_WARCHIVE_DECL(void) - load(char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_WARCHIVE_DECL(void) - load(wchar_t * t); - #endif - BOOST_WARCHIVE_DECL(void) - load(std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_WARCHIVE_DECL(void) - load(std::wstring &ws); - #endif - // note: the following should not needed - but one compiler (vc 7.1) - // fails to compile one test (test_shared_ptr) without it !!! - template - void load_override(T & t, BOOST_PFTO int){ - basic_text_iarchive::load_override(t, 0); - } - BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) - text_wiarchive_impl(std::wistream & is, unsigned int flags); - ~text_wiarchive_impl(){}; -}; - -// do not derive from the classes below. If you want to extend this functionality -// via inhertance, derived from text_iarchive_impl instead. This will -// preserve correct static polymorphism. - -// same as text_wiarchive below - without the shared_ptr_helper -class naked_text_wiarchive : - public text_wiarchive_impl -{ -public: - naked_text_wiarchive(std::wistream & is, unsigned int flags = 0) : - text_wiarchive_impl(is, flags) - {} - ~naked_text_wiarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -class text_wiarchive : - public text_wiarchive_impl, - public detail::shared_ptr_helper -{ -public: - text_wiarchive(std::wistream & is, unsigned int flags = 0) : - text_wiarchive_impl(is, flags) - {} - ~text_wiarchive(){} -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::text_wiarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_TEXT_WIARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/text_woarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/text_woarchive.hpp deleted file mode 100644 index 7ed0c820..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/text_woarchive.hpp +++ /dev/null @@ -1,145 +0,0 @@ -#ifndef BOOST_ARCHIVE_TEXT_WOARCHIVE_HPP -#define BOOST_ARCHIVE_TEXT_WOARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// text_woarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include -#include // size_t - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class text_woarchive_impl : - public basic_text_oprimitive, - public basic_text_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class basic_text_oarchive; - friend class save_access; -protected: -#endif - template - void save(const T & t){ - this->newtoken(); - basic_text_oprimitive::save(t); - } - void save(const version_type & t){ - save(static_cast(t)); - } - void save(const boost::serialization::item_version_type & t){ - save(static_cast(t)); - } - BOOST_WARCHIVE_DECL(void) - save(const char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_WARCHIVE_DECL(void) - save(const wchar_t * t); - #endif - BOOST_WARCHIVE_DECL(void) - save(const std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_WARCHIVE_DECL(void) - save(const std::wstring &ws); - #endif - text_woarchive_impl(std::wostream & os, unsigned int flags) : - basic_text_oprimitive( - os, - 0 != (flags & no_codecvt) - ), - basic_text_oarchive(flags) - { - if(0 == (flags & no_header)) - basic_text_oarchive::init(); - } -public: - void save_binary(const void *address, std::size_t count){ - put(static_cast('\n')); - this->end_preamble(); - #if ! defined(__MWERKS__) - this->basic_text_oprimitive::save_binary( - #else - this->basic_text_oprimitive::save_binary( - #endif - address, - count - ); - put(static_cast('\n')); - this->delimiter = this->none; - } - -}; - -// we use the following because we can't use -// typedef text_oarchive_impl > text_oarchive; - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from text_oarchive_impl instead. This will -// preserve correct static polymorphism. -class text_woarchive : - public text_woarchive_impl -{ -public: - text_woarchive(std::wostream & os, unsigned int flags = 0) : - text_woarchive_impl(os, flags) - {} - ~text_woarchive(){} -}; - -typedef text_woarchive naked_text_woarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::text_woarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_TEXT_WOARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/wcslen.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/wcslen.hpp deleted file mode 100644 index 5c14acff..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/wcslen.hpp +++ /dev/null @@ -1,56 +0,0 @@ -#ifndef BOOST_ARCHIVE_WCSLEN_HPP -#define BOOST_ARCHIVE_WCSLEN_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// wcslen.hpp: - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include // size_t -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#ifndef BOOST_NO_CWCHAR - -// a couple of libraries which include wchar_t don't include -// wcslen - -#if defined(BOOST_DINKUMWARE_STDLIB) && BOOST_DINKUMWARE_STDLIB < 306 \ -|| defined(__LIBCOMO__) - -namespace std { -inline std::size_t wcslen(const wchar_t * ws) -{ - const wchar_t * eows = ws; - while(* eows != 0) - ++eows; - return eows - ws; -} -} // namespace std - -#else - -#include -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std{ using ::wcslen; } -#endif - -#endif // wcslen - -#endif //BOOST_NO_CWCHAR - -#endif //BOOST_ARCHIVE_WCSLEN_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_archive_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/xml_archive_exception.hpp deleted file mode 100644 index 48e6cb32..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_archive_exception.hpp +++ /dev/null @@ -1,56 +0,0 @@ -#ifndef BOOST_ARCHIVE_XML_ARCHIVE_EXCEPTION_HPP -#define BOOST_ARCHIVE_XML_ARCHIVE_EXCEPTION_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_archive_exception.hpp: - -// (C) Copyright 2007 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#include - -#include -#include -#include -#include - -#include // must be the last header - -namespace boost { -namespace archive { - -////////////////////////////////////////////////////////////////////// -// exceptions thrown by xml archives -// -class BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) xml_archive_exception : - public virtual boost::archive::archive_exception -{ -public: - typedef enum { - xml_archive_parsing_error, // see save_register - xml_archive_tag_mismatch, - xml_archive_tag_name_error - } exception_code; - xml_archive_exception( - exception_code c, - const char * e1 = NULL, - const char * e2 = NULL - ); -}; - -}// namespace archive -}// namespace boost - -#include // pops abi_suffix.hpp pragmas - -#endif //BOOST_XML_ARCHIVE_ARCHIVE_EXCEPTION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_iarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/xml_iarchive.hpp deleted file mode 100644 index be6cfe49..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_iarchive.hpp +++ /dev/null @@ -1,164 +0,0 @@ -#ifndef BOOST_ARCHIVE_XML_IARCHIVE_HPP -#define BOOST_ARCHIVE_XML_IARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_iarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -//#include -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class basic_xml_grammar; -typedef basic_xml_grammar xml_grammar; - -template -class xml_iarchive_impl : - public basic_text_iprimitive, - public basic_xml_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class basic_xml_iarchive; - friend class load_access; -protected: -#endif - // instances of micro xml parser to parse start preambles - // scoped_ptr doesn't play nice with borland - so use a naked pointer - // scoped_ptr gimpl; - xml_grammar *gimpl; - - std::istream & get_is(){ - return is; - } - template - void load(T & t){ - basic_text_iprimitive::load(t); - } - void - load(version_type & t){ - unsigned int v; - load(v); - t = version_type(v); - } - void - load(boost::serialization::item_version_type & t){ - unsigned int v; - load(v); - t = boost::serialization::item_version_type(v); - } - BOOST_ARCHIVE_DECL(void) - load(char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_ARCHIVE_DECL(void) - load(wchar_t * t); - #endif - BOOST_ARCHIVE_DECL(void) - load(std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_DECL(void) - load(std::wstring &ws); - #endif - template - void load_override(T & t, BOOST_PFTO int){ - basic_xml_iarchive::load_override(t, 0); - } - BOOST_ARCHIVE_DECL(void) - load_override(class_name_type & t, int); - BOOST_ARCHIVE_DECL(void) - init(); - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - xml_iarchive_impl(std::istream & is, unsigned int flags); - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - ~xml_iarchive_impl(); -}; - -// do not derive from the classes below. If you want to extend this functionality -// via inhertance, derived from text_iarchive_impl instead. This will -// preserve correct static polymorphism. - -// same as xml_iarchive below - without the shared_ptr_helper -class naked_xml_iarchive : - public xml_iarchive_impl -{ -public: - naked_xml_iarchive(std::istream & is, unsigned int flags = 0) : - xml_iarchive_impl(is, flags) - {} - ~naked_xml_iarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -class xml_iarchive : - public xml_iarchive_impl, - public detail::shared_ptr_helper -{ -public: - xml_iarchive(std::istream & is, unsigned int flags = 0) : - xml_iarchive_impl(is, flags) - {} - ~xml_iarchive(){}; -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_iarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_ARCHIVE_XML_IARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_oarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/xml_oarchive.hpp deleted file mode 100644 index 167ba093..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_oarchive.hpp +++ /dev/null @@ -1,133 +0,0 @@ -#ifndef BOOST_ARCHIVE_XML_OARCHIVE_HPP -#define BOOST_ARCHIVE_XML_OARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_oarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include - -#include // size_t -#include -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class xml_oarchive_impl : - public basic_text_oprimitive, - public basic_xml_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class basic_xml_oarchive; - friend class save_access; -protected: -#endif - //void end_preamble(){ - // basic_xml_oarchive::end_preamble(); - //} - template - void save(const T & t){ - basic_text_oprimitive::save(t); - } - void - save(const version_type & t){ - save(static_cast(t)); - } - void - save(const boost::serialization::item_version_type & t){ - save(static_cast(t)); - } - BOOST_ARCHIVE_DECL(void) - save(const char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_ARCHIVE_DECL(void) - save(const wchar_t * t); - #endif - BOOST_ARCHIVE_DECL(void) - save(const std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_ARCHIVE_DECL(void) - save(const std::wstring &ws); - #endif - BOOST_ARCHIVE_DECL(BOOST_PP_EMPTY()) - xml_oarchive_impl(std::ostream & os, unsigned int flags); - ~xml_oarchive_impl(){} -public: - void save_binary(const void *address, std::size_t count){ - this->end_preamble(); - #if ! defined(__MWERKS__) - this->basic_text_oprimitive::save_binary( - #else - this->basic_text_oprimitive::save_binary( - #endif - address, - count - ); - this->indent_next = true; - } -}; - -// we use the following because we can't use -// typedef xml_oarchive_impl > xml_oarchive; - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from xml_oarchive_impl instead. This will -// preserve correct static polymorphism. -class xml_oarchive : - public xml_oarchive_impl -{ -public: - xml_oarchive(std::ostream & os, unsigned int flags = 0) : - xml_oarchive_impl(os, flags) - {} - ~xml_oarchive(){} -}; - -typedef xml_oarchive naked_xml_oarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_oarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_ARCHIVE_XML_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_wiarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/xml_wiarchive.hpp deleted file mode 100644 index 59ebbb5e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_wiarchive.hpp +++ /dev/null @@ -1,170 +0,0 @@ -#ifndef BOOST_ARCHIVE_XML_WIARCHIVE_HPP -#define BOOST_ARCHIVE_XML_WIARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_wiarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include - -//#include -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class basic_xml_grammar; -typedef basic_xml_grammar xml_wgrammar; - -template -class xml_wiarchive_impl : - public basic_text_iprimitive, - public basic_xml_iarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_iarchive; - friend class basic_xml_iarchive; - friend class load_access; -protected: -#endif - // instances of micro xml parser to parse start preambles - // scoped_ptr doesn't play nice with borland - so use a naked pointer - // scoped_ptr gimpl; - xml_wgrammar *gimpl; - std::wistream & get_is(){ - return is; - } - template - void - load(T & t){ - basic_text_iprimitive::load(t); - } - void - load(version_type & t){ - unsigned int v; - load(v); - t = version_type(v); - } - void - load(boost::serialization::item_version_type & t){ - unsigned int v; - load(v); - t = boost::serialization::item_version_type(v); - } - BOOST_WARCHIVE_DECL(void) - load(char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_WARCHIVE_DECL(void) - load(wchar_t * t); - #endif - BOOST_WARCHIVE_DECL(void) - load(std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_WARCHIVE_DECL(void) - load(std::wstring &ws); - #endif - template - void load_override(T & t, BOOST_PFTO int){ - basic_xml_iarchive::load_override(t, 0); - } - BOOST_WARCHIVE_DECL(void) - load_override(class_name_type & t, int); - BOOST_WARCHIVE_DECL(void) - init(); - BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) - xml_wiarchive_impl(std::wistream & is, unsigned int flags) ; - BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) - ~xml_wiarchive_impl(); -}; - -// do not derive from the classes below. If you want to extend this functionality -// via inhertance, derived from xml_wiarchive_impl instead. This will -// preserve correct static polymorphism. - -// same as xml_wiarchive below - without the shared_ptr_helper -class naked_xml_wiarchive : - public xml_wiarchive_impl -{ -public: - naked_xml_wiarchive(std::wistream & is, unsigned int flags = 0) : - xml_wiarchive_impl(is, flags) - {} - ~naked_xml_wiarchive(){} -}; - -} // namespace archive -} // namespace boost - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -// note special treatment of shared_ptr. This type needs a special -// structure associated with every archive. We created a "mix-in" -// class to provide this functionality. Since shared_ptr holds a -// special esteem in the boost library - we included it here by default. -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -class xml_wiarchive : - public xml_wiarchive_impl, - public detail::shared_ptr_helper -{ -public: - xml_wiarchive(std::wistream & is, unsigned int flags = 0) : - xml_wiarchive_impl(is, flags) - {} - ~xml_wiarchive(){} -}; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_wiarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_XML_WIARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_woarchive.hpp b/third_party/ycmd/cpp/BoostParts/boost/archive/xml_woarchive.hpp deleted file mode 100644 index 08c0fdc6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/archive/xml_woarchive.hpp +++ /dev/null @@ -1,140 +0,0 @@ -#ifndef BOOST_ARCHIVE_XML_WOARCHIVE_HPP -#define BOOST_ARCHIVE_XML_WOARCHIVE_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// xml_woarchive.hpp - -// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for updates, documentation, and revision history. - -#include -#ifdef BOOST_NO_STD_WSTREAMBUF -#error "wide char i/o not supported on this platform" -#else - -#include // size_t -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std{ - using ::size_t; -} // namespace std -#endif - -#include - -#include -#include -#include -#include -#include - -#include // must be the last header - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable : 4511 4512) -#endif - -namespace boost { -namespace archive { - -template -class xml_woarchive_impl : - public basic_text_oprimitive, - public basic_xml_oarchive -{ -#ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS -public: -#else - friend class detail::interface_oarchive; - friend class basic_xml_oarchive; - friend class save_access; -protected: -#endif - //void end_preamble(){ - // basic_xml_oarchive::end_preamble(); - //} - template - void - save(const T & t){ - basic_text_oprimitive::save(t); - } - void - save(const version_type & t){ - save(static_cast(t)); - } - void - save(const boost::serialization::item_version_type & t){ - save(static_cast(t)); - } - BOOST_WARCHIVE_DECL(void) - save(const char * t); - #ifndef BOOST_NO_INTRINSIC_WCHAR_T - BOOST_WARCHIVE_DECL(void) - save(const wchar_t * t); - #endif - BOOST_WARCHIVE_DECL(void) - save(const std::string &s); - #ifndef BOOST_NO_STD_WSTRING - BOOST_WARCHIVE_DECL(void) - save(const std::wstring &ws); - #endif - BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) - xml_woarchive_impl(std::wostream & os, unsigned int flags); - ~xml_woarchive_impl(){} -public: - void - save_binary(const void *address, std::size_t count){ - this->end_preamble(); - #if ! defined(__MWERKS__) - this->basic_text_oprimitive::save_binary( - #else - this->basic_text_oprimitive::save_binary( - #endif - address, - count - ); - this->indent_next = true; - } -}; - -// we use the following because we can't use -// typedef xml_woarchive_impl > xml_woarchive; - -// do not derive from this class. If you want to extend this functionality -// via inhertance, derived from xml_woarchive_impl instead. This will -// preserve correct static polymorphism. -class xml_woarchive : - public xml_woarchive_impl -{ -public: - xml_woarchive(std::wostream & os, unsigned int flags = 0) : - xml_woarchive_impl(os, flags) - {} - ~xml_woarchive(){} -}; - -typedef xml_woarchive naked_xml_woarchive; - -} // namespace archive -} // namespace boost - -// required by export -BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_woarchive) - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -#include // pops abi_suffix.hpp pragmas - -#endif // BOOST_NO_STD_WSTREAMBUF -#endif // BOOST_ARCHIVE_XML_OARCHIVE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/array.hpp b/third_party/ycmd/cpp/BoostParts/boost/array.hpp deleted file mode 100644 index fa06fa9a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/array.hpp +++ /dev/null @@ -1,446 +0,0 @@ -/* The following code declares class array, - * an STL container (as wrapper) for arrays of constant size. - * - * See - * http://www.boost.org/libs/array/ - * for documentation. - * - * The original author site is at: http://www.josuttis.com/ - * - * (C) Copyright Nicolai M. Josuttis 2001. - * - * Distributed under the Boost Software License, Version 1.0. (See - * accompanying file LICENSE_1_0.txt or copy at - * http://www.boost.org/LICENSE_1_0.txt) - * - * 14 Apr 2012 - (mtc) Added support for boost::hash - * 28 Dec 2010 - (mtc) Added cbegin and cend (and crbegin and crend) for C++Ox compatibility. - * 10 Mar 2010 - (mtc) fill method added, matching resolution of the standard library working group. - * See or Trac issue #3168 - * Eventually, we should remove "assign" which is now a synonym for "fill" (Marshall Clow) - * 10 Mar 2010 - added workaround for SUNCC and !STLPort [trac #3893] (Marshall Clow) - * 29 Jan 2004 - c_array() added, BOOST_NO_PRIVATE_IN_AGGREGATE removed (Nico Josuttis) - * 23 Aug 2002 - fix for Non-MSVC compilers combined with MSVC libraries. - * 05 Aug 2001 - minor update (Nico Josuttis) - * 20 Jan 2001 - STLport fix (Beman Dawes) - * 29 Sep 2000 - Initial Revision (Nico Josuttis) - * - * Jan 29, 2004 - */ -#ifndef BOOST_ARRAY_HPP -#define BOOST_ARRAY_HPP - -#include - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -# pragma warning(push) -# pragma warning(disable:4996) // 'std::equal': Function call with parameters that may be unsafe -# pragma warning(disable:4510) // boost::array' : default constructor could not be generated -# pragma warning(disable:4610) // warning C4610: class 'boost::array' can never be instantiated - user defined constructor required -#endif - -#include -#include -#include -#include - -// Handles broken standard libraries better than -#include -#include -#include -#include - -// FIXES for broken compilers -#include - - -namespace boost { - - template - class array { - public: - T elems[N]; // fixed-size array of elements of type T - - public: - // type definitions - typedef T value_type; - typedef T* iterator; - typedef const T* const_iterator; - typedef T& reference; - typedef const T& const_reference; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - // iterator support - iterator begin() { return elems; } - const_iterator begin() const { return elems; } - const_iterator cbegin() const { return elems; } - - iterator end() { return elems+N; } - const_iterator end() const { return elems+N; } - const_iterator cend() const { return elems+N; } - - // reverse iterator support -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_MSVC_STD_ITERATOR) && !defined(BOOST_NO_STD_ITERATOR_TRAITS) - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#elif defined(_MSC_VER) && (_MSC_VER == 1300) && defined(BOOST_DINKUMWARE_STDLIB) && (BOOST_DINKUMWARE_STDLIB == 310) - // workaround for broken reverse_iterator in VC7 - typedef std::reverse_iterator > reverse_iterator; - typedef std::reverse_iterator > const_reverse_iterator; -#elif defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#else - // workaround for broken reverse_iterator implementations - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#endif - - reverse_iterator rbegin() { return reverse_iterator(end()); } - const_reverse_iterator rbegin() const { - return const_reverse_iterator(end()); - } - const_reverse_iterator crbegin() const { - return const_reverse_iterator(end()); - } - - reverse_iterator rend() { return reverse_iterator(begin()); } - const_reverse_iterator rend() const { - return const_reverse_iterator(begin()); - } - const_reverse_iterator crend() const { - return const_reverse_iterator(begin()); - } - - // operator[] - reference operator[](size_type i) - { - BOOST_ASSERT_MSG( i < N, "out of range" ); - return elems[i]; - } - - const_reference operator[](size_type i) const - { - BOOST_ASSERT_MSG( i < N, "out of range" ); - return elems[i]; - } - - // at() with range check - reference at(size_type i) { rangecheck(i); return elems[i]; } - const_reference at(size_type i) const { rangecheck(i); return elems[i]; } - - // front() and back() - reference front() - { - return elems[0]; - } - - const_reference front() const - { - return elems[0]; - } - - reference back() - { - return elems[N-1]; - } - - const_reference back() const - { - return elems[N-1]; - } - - // size is constant - static size_type size() { return N; } - static bool empty() { return false; } - static size_type max_size() { return N; } - enum { static_size = N }; - - // swap (note: linear complexity) - void swap (array& y) { - for (size_type i = 0; i < N; ++i) - boost::swap(elems[i],y.elems[i]); - } - - // direct access to data (read-only) - const T* data() const { return elems; } - T* data() { return elems; } - - // use array as C array (direct read/write access to data) - T* c_array() { return elems; } - - // assignment with type conversion - template - array& operator= (const array& rhs) { - std::copy(rhs.begin(),rhs.end(), begin()); - return *this; - } - - // assign one value to all elements - void assign (const T& value) { fill ( value ); } // A synonym for fill - void fill (const T& value) - { - std::fill_n(begin(),size(),value); - } - - // check range (may be private because it is static) - static void rangecheck (size_type i) { - if (i >= size()) { - std::out_of_range e("array<>: index out of range"); - boost::throw_exception(e); - } - } - - }; - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - template< class T > - class array< T, 0 > { - - public: - // type definitions - typedef T value_type; - typedef T* iterator; - typedef const T* const_iterator; - typedef T& reference; - typedef const T& const_reference; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - // iterator support - iterator begin() { return iterator( reinterpret_cast< T * >( this ) ); } - const_iterator begin() const { return const_iterator( reinterpret_cast< const T * >( this ) ); } - const_iterator cbegin() const { return const_iterator( reinterpret_cast< const T * >( this ) ); } - - iterator end() { return begin(); } - const_iterator end() const { return begin(); } - const_iterator cend() const { return cbegin(); } - - // reverse iterator support -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_MSVC_STD_ITERATOR) && !defined(BOOST_NO_STD_ITERATOR_TRAITS) - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#elif defined(_MSC_VER) && (_MSC_VER == 1300) && defined(BOOST_DINKUMWARE_STDLIB) && (BOOST_DINKUMWARE_STDLIB == 310) - // workaround for broken reverse_iterator in VC7 - typedef std::reverse_iterator > reverse_iterator; - typedef std::reverse_iterator > const_reverse_iterator; -#elif defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#else - // workaround for broken reverse_iterator implementations - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; -#endif - - reverse_iterator rbegin() { return reverse_iterator(end()); } - const_reverse_iterator rbegin() const { - return const_reverse_iterator(end()); - } - const_reverse_iterator crbegin() const { - return const_reverse_iterator(end()); - } - - reverse_iterator rend() { return reverse_iterator(begin()); } - const_reverse_iterator rend() const { - return const_reverse_iterator(begin()); - } - const_reverse_iterator crend() const { - return const_reverse_iterator(begin()); - } - - // operator[] - reference operator[](size_type /*i*/) - { - return failed_rangecheck(); - } - - const_reference operator[](size_type /*i*/) const - { - return failed_rangecheck(); - } - - // at() with range check - reference at(size_type /*i*/) { return failed_rangecheck(); } - const_reference at(size_type /*i*/) const { return failed_rangecheck(); } - - // front() and back() - reference front() - { - return failed_rangecheck(); - } - - const_reference front() const - { - return failed_rangecheck(); - } - - reference back() - { - return failed_rangecheck(); - } - - const_reference back() const - { - return failed_rangecheck(); - } - - // size is constant - static size_type size() { return 0; } - static bool empty() { return true; } - static size_type max_size() { return 0; } - enum { static_size = 0 }; - - void swap (array& /*y*/) { - } - - // direct access to data (read-only) - const T* data() const { return 0; } - T* data() { return 0; } - - // use array as C array (direct read/write access to data) - T* c_array() { return 0; } - - // assignment with type conversion - template - array& operator= (const array& ) { - return *this; - } - - // assign one value to all elements - void assign (const T& value) { fill ( value ); } - void fill (const T& ) {} - - // check range (may be private because it is static) - static reference failed_rangecheck () { - std::out_of_range e("attempt to access element of an empty array"); - boost::throw_exception(e); -#if defined(BOOST_NO_EXCEPTIONS) || (!defined(BOOST_MSVC) && !defined(__PATHSCALE__)) - // - // We need to return something here to keep - // some compilers happy: however we will never - // actually get here.... - // - static T placeholder; - return placeholder; -#endif - } - }; -#endif - - // comparisons - template - bool operator== (const array& x, const array& y) { - return std::equal(x.begin(), x.end(), y.begin()); - } - template - bool operator< (const array& x, const array& y) { - return std::lexicographical_compare(x.begin(),x.end(),y.begin(),y.end()); - } - template - bool operator!= (const array& x, const array& y) { - return !(x==y); - } - template - bool operator> (const array& x, const array& y) { - return y - bool operator<= (const array& x, const array& y) { - return !(y - bool operator>= (const array& x, const array& y) { - return !(x - inline void swap (array& x, array& y) { - x.swap(y); - } - -#if defined(__SUNPRO_CC) -// Trac ticket #4757; the Sun Solaris compiler can't handle -// syntax like 'T(&get_c_array(boost::array& arg))[N]' -// -// We can't just use this for all compilers, because the -// borland compilers can't handle this form. - namespace detail { - template struct c_array - { - typedef T type[N]; - }; - } - - // Specific for boost::array: simply returns its elems data member. - template - typename detail::c_array::type& get_c_array(boost::array& arg) - { - return arg.elems; - } - - // Specific for boost::array: simply returns its elems data member. - template - typename const detail::c_array::type& get_c_array(const boost::array& arg) - { - return arg.elems; - } -#else -// Specific for boost::array: simply returns its elems data member. - template - T(&get_c_array(boost::array& arg))[N] - { - return arg.elems; - } - - // Const version. - template - const T(&get_c_array(const boost::array& arg))[N] - { - return arg.elems; - } -#endif - -#if 0 - // Overload for std::array, assuming that std::array will have - // explicit conversion functions as discussed at the WG21 meeting - // in Summit, March 2009. - template - T(&get_c_array(std::array& arg))[N] - { - return static_cast(arg); - } - - // Const version. - template - const T(&get_c_array(const std::array& arg))[N] - { - return static_cast(arg); - } -#endif - - - template - std::size_t hash_value(const array& arr) - { - return boost::hash_range(arr.begin(), arr.end()); - } - -} /* namespace boost */ - - -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -# pragma warning(pop) -#endif - -#endif /*BOOST_ARRAY_HPP*/ diff --git a/third_party/ycmd/cpp/BoostParts/boost/assert.hpp b/third_party/ycmd/cpp/BoostParts/boost/assert.hpp deleted file mode 100644 index ccc776a4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assert.hpp +++ /dev/null @@ -1,141 +0,0 @@ -// -// boost/assert.hpp - BOOST_ASSERT(expr) -// BOOST_ASSERT_MSG(expr, msg) -// BOOST_VERIFY(expr) -// -// Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2007 Peter Dimov -// Copyright (c) Beman Dawes 2011 -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Note: There are no include guards. This is intentional. -// -// See http://www.boost.org/libs/utility/assert.html for documentation. -// - -// -// Stop inspect complaining about use of 'assert': -// -// boostinspect:naassert_macro -// - -//--------------------------------------------------------------------------------------// -// BOOST_ASSERT // -//--------------------------------------------------------------------------------------// - -#undef BOOST_ASSERT - -#if defined(BOOST_DISABLE_ASSERTS) - -# define BOOST_ASSERT(expr) ((void)0) - -#elif defined(BOOST_ENABLE_ASSERT_HANDLER) - -#include -#include - -namespace boost -{ - void assertion_failed(char const * expr, - char const * function, char const * file, long line); // user defined -} // namespace boost - -#define BOOST_ASSERT(expr) (BOOST_LIKELY(!!(expr)) \ - ? ((void)0) \ - : ::boost::assertion_failed(#expr, BOOST_CURRENT_FUNCTION, __FILE__, __LINE__)) - -#else -# include // .h to support old libraries w/o - effect is the same -# define BOOST_ASSERT(expr) assert(expr) -#endif - -//--------------------------------------------------------------------------------------// -// BOOST_ASSERT_MSG // -//--------------------------------------------------------------------------------------// - -# undef BOOST_ASSERT_MSG - -#if defined(BOOST_DISABLE_ASSERTS) || defined(NDEBUG) - - #define BOOST_ASSERT_MSG(expr, msg) ((void)0) - -#elif defined(BOOST_ENABLE_ASSERT_HANDLER) - - #include - #include - - namespace boost - { - void assertion_failed_msg(char const * expr, char const * msg, - char const * function, char const * file, long line); // user defined - } // namespace boost - - #define BOOST_ASSERT_MSG(expr, msg) (BOOST_LIKELY(!!(expr)) \ - ? ((void)0) \ - : ::boost::assertion_failed_msg(#expr, msg, BOOST_CURRENT_FUNCTION, __FILE__, __LINE__)) - -#else - #ifndef BOOST_ASSERT_HPP - #define BOOST_ASSERT_HPP - #include - #include - #include - #include - - // IDE's like Visual Studio perform better if output goes to std::cout or - // some other stream, so allow user to configure output stream: - #ifndef BOOST_ASSERT_MSG_OSTREAM - # define BOOST_ASSERT_MSG_OSTREAM std::cerr - #endif - - namespace boost - { - namespace assertion - { - namespace detail - { - // Note: The template is needed to make the function non-inline and avoid linking errors - template< typename CharT > - BOOST_NOINLINE void assertion_failed_msg(CharT const * expr, char const * msg, char const * function, - char const * file, long line) - { - BOOST_ASSERT_MSG_OSTREAM - << "***** Internal Program Error - assertion (" << expr << ") failed in " - << function << ":\n" - << file << '(' << line << "): " << msg << std::endl; -#ifdef UNDER_CE - // The Windows CE CRT library does not have abort() so use exit(-1) instead. - std::exit(-1); -#else - std::abort(); -#endif - } - } // detail - } // assertion - } // detail - #endif - - #define BOOST_ASSERT_MSG(expr, msg) (BOOST_LIKELY(!!(expr)) \ - ? ((void)0) \ - : ::boost::assertion::detail::assertion_failed_msg(#expr, msg, \ - BOOST_CURRENT_FUNCTION, __FILE__, __LINE__)) -#endif - -//--------------------------------------------------------------------------------------// -// BOOST_VERIFY // -//--------------------------------------------------------------------------------------// - -#undef BOOST_VERIFY - -#if defined(BOOST_DISABLE_ASSERTS) || ( !defined(BOOST_ENABLE_ASSERT_HANDLER) && defined(NDEBUG) ) - -# define BOOST_VERIFY(expr) ((void)(expr)) - -#else - -# define BOOST_VERIFY(expr) BOOST_ASSERT(expr) - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign.hpp deleted file mode 100644 index d74a5660..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_HPP -#define BOOST_ASSIGN_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include -#include - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/assignment_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/assignment_exception.hpp deleted file mode 100644 index 5079c3a8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/assignment_exception.hpp +++ /dev/null @@ -1,43 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_ASSIGNMENT_EXCEPTION_HPP -#define BOOST_ASSIGN_ASSIGNMENT_EXCEPTION_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include - -namespace boost -{ - namespace assign - { - class assignment_exception : public std::exception - { - public: - assignment_exception( const char* _what ) - : what_( _what ) - { } - - virtual const char* what() const throw() - { - return what_; - } - - private: - const char* what_; - }; - } -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/list_inserter.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/list_inserter.hpp deleted file mode 100644 index e67a3c5f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/list_inserter.hpp +++ /dev/null @@ -1,400 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_LIST_INSERTER_HPP -#define BOOST_ASSIGN_LIST_INSERTER_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include - -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -namespace boost -{ -namespace assign_detail -{ - template< class T > - struct repeater - { - std::size_t sz; - T val; - - repeater( std::size_t sz_, T r ) : sz( sz_ ), val( r ) - { } - }; - - template< class Fun > - struct fun_repeater - { - std::size_t sz; - Fun val; - - fun_repeater( std::size_t sz_, Fun r ) : sz( sz_ ), val( r ) - { } - }; - - template< class C > - class call_push_back - { - C& c_; - public: - call_push_back( C& c ) : c_( c ) - { } - - template< class T > - void operator()( T r ) - { - c_.push_back( r ); - } - }; - - template< class C > - class call_push_front - { - C& c_; - public: - call_push_front( C& c ) : c_( c ) - { } - - template< class T > - void operator()( T r ) - { - c_.push_front( r ); - } - }; - - template< class C > - class call_push - { - C& c_; - public: - call_push( C& c ) : c_( c ) - { } - - template< class T > - void operator()( T r ) - { - c_.push( r ); - } - }; - - template< class C > - class call_insert - { - C& c_; - public: - call_insert( C& c ) : c_( c ) - { } - - template< class T > - void operator()( T r ) - { - c_.insert( r ); - } - }; - - template< class C > - class call_add_edge - { - C& c_; - public: - call_add_edge( C& c ) : c_(c) - { } - - template< class T > - void operator()( T l, T r ) - { - add_edge( l, r, c_ ); - } - - template< class T, class EP > - void operator()( T l, T r, const EP& ep ) - { - add_edge( l, r, ep, c_ ); - } - - }; - - struct forward_n_arguments {}; - -} // namespace 'assign_detail' - -namespace assign -{ - - template< class T > - inline assign_detail::repeater - repeat( std::size_t sz, T r ) - { - return assign_detail::repeater( sz, r ); - } - - template< class Function > - inline assign_detail::fun_repeater - repeat_fun( std::size_t sz, Function r ) - { - return assign_detail::fun_repeater( sz, r ); - } - - - template< class Function, class Argument = assign_detail::forward_n_arguments > - class list_inserter - { - struct single_arg_type {}; - struct n_arg_type {}; - - typedef BOOST_DEDUCED_TYPENAME mpl::if_c< is_same::value, - n_arg_type, - single_arg_type >::type arg_type; - - public: - - list_inserter( Function fun ) : insert_( fun ) - {} - - template< class Function2, class Arg > - list_inserter( const list_inserter& r ) - : insert_( r.fun_private() ) - {} - - list_inserter( const list_inserter& r ) : insert_( r.insert_ ) - {} - - list_inserter& operator()() - { - insert_( Argument() ); - return *this; - } - - template< class T > - list_inserter& operator=( const T& r ) - { - insert_( r ); - return *this; - } - - template< class T > - list_inserter& operator=( assign_detail::repeater r ) - { - return operator,( r ); - } - - template< class Nullary_function > - list_inserter& operator=( const assign_detail::fun_repeater& r ) - { - return operator,( r ); - } - - template< class T > - list_inserter& operator,( const T& r ) - { - insert_( r ); - return *this; - } - -#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - template< class T > - list_inserter& operator,( const assign_detail::repeater & r ) - { - return repeat( r.sz, r.val ); - } -#else - template< class T > - list_inserter& operator,( assign_detail::repeater r ) - { - return repeat( r.sz, r.val ); - } -#endif - - template< class Nullary_function > - list_inserter& operator,( const assign_detail::fun_repeater& r ) - { - return repeat_fun( r.sz, r.val ); - } - - template< class T > - list_inserter& repeat( std::size_t sz, T r ) - { - std::size_t i = 0; - while( i++ != sz ) - insert_( r ); - return *this; - } - - template< class Nullary_function > - list_inserter& repeat_fun( std::size_t sz, Nullary_function fun ) - { - std::size_t i = 0; - while( i++ != sz ) - insert_( fun() ); - return *this; - } - - template< class SinglePassIterator > - list_inserter& range( SinglePassIterator first, - SinglePassIterator last ) - { - for( ; first != last; ++first ) - insert_( *first ); - return *this; - } - - template< class SinglePassRange > - list_inserter& range( const SinglePassRange& r ) - { - return range( boost::begin(r), boost::end(r) ); - } - - template< class T > - list_inserter& operator()( const T& t ) - { - insert_( t ); - return *this; - } - -#ifndef BOOST_ASSIGN_MAX_PARAMS // use user's value -#define BOOST_ASSIGN_MAX_PARAMS 5 -#endif -#define BOOST_ASSIGN_MAX_PARAMETERS (BOOST_ASSIGN_MAX_PARAMS - 1) -#define BOOST_ASSIGN_PARAMS1(n) BOOST_PP_ENUM_PARAMS(n, class T) -#define BOOST_ASSIGN_PARAMS2(n) BOOST_PP_ENUM_BINARY_PARAMS(n, T, const& t) -#define BOOST_ASSIGN_PARAMS3(n) BOOST_PP_ENUM_PARAMS(n, t) - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, BOOST_ASSIGN_PARAMS1(n) > \ - list_inserter& operator()(T t, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - BOOST_PP_CAT(insert, BOOST_PP_INC(n))(t, BOOST_ASSIGN_PARAMS3(n), arg_type()); \ - return *this; \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, BOOST_ASSIGN_PARAMS1(n) > \ - void BOOST_PP_CAT(insert, BOOST_PP_INC(n))(T const& t, BOOST_ASSIGN_PARAMS2(n), single_arg_type) \ - { \ - insert_( Argument(t, BOOST_ASSIGN_PARAMS3(n) )); \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, BOOST_ASSIGN_PARAMS1(n) > \ - void BOOST_PP_CAT(insert, BOOST_PP_INC(n))(T const& t, BOOST_ASSIGN_PARAMS2(n), n_arg_type) \ - { \ - insert_(t, BOOST_ASSIGN_PARAMS3(n) ); \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - - Function fun_private() const - { - return insert_; - } - - private: - - list_inserter& operator=( const list_inserter& ); - Function insert_; - }; - - template< class Function > - inline list_inserter< Function > - make_list_inserter( Function fun ) - { - return list_inserter< Function >( fun ); - } - - template< class Function, class Argument > - inline list_inserter - make_list_inserter( Function fun, Argument* ) - { - return list_inserter( fun ); - } - - template< class C > - inline list_inserter< assign_detail::call_push_back, - BOOST_DEDUCED_TYPENAME C::value_type > - push_back( C& c ) - { - static BOOST_DEDUCED_TYPENAME C::value_type* p = 0; - return make_list_inserter( assign_detail::call_push_back( c ), - p ); - } - - template< class C > - inline list_inserter< assign_detail::call_push_front, - BOOST_DEDUCED_TYPENAME C::value_type > - push_front( C& c ) - { - static BOOST_DEDUCED_TYPENAME C::value_type* p = 0; - return make_list_inserter( assign_detail::call_push_front( c ), - p ); - } - - template< class C > - inline list_inserter< assign_detail::call_insert, - BOOST_DEDUCED_TYPENAME C::value_type > - insert( C& c ) - { - static BOOST_DEDUCED_TYPENAME C::value_type* p = 0; - return make_list_inserter( assign_detail::call_insert( c ), - p ); - } - - template< class C > - inline list_inserter< assign_detail::call_push, - BOOST_DEDUCED_TYPENAME C::value_type > - push( C& c ) - { - static BOOST_DEDUCED_TYPENAME C::value_type* p = 0; - return make_list_inserter( assign_detail::call_push( c ), - p ); - } - - template< class C > - inline list_inserter< assign_detail::call_add_edge > - add_edge( C& c ) - { - return make_list_inserter( assign_detail::call_add_edge( c ) ); - } - -} // namespace 'assign' -} // namespace 'boost' - -#undef BOOST_ASSIGN_PARAMS1 -#undef BOOST_ASSIGN_PARAMS2 -#undef BOOST_ASSIGN_PARAMS3 -#undef BOOST_ASSIGN_MAX_PARAMETERS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/list_of.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/list_of.hpp deleted file mode 100644 index 6da444bf..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/list_of.hpp +++ /dev/null @@ -1,681 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_LIST_OF_HPP -#define BOOST_ASSIGN_LIST_OF_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -// BCB requires full type definition for is_array<> to work correctly. -#include -#endif - -namespace boost -{ - -// this here is necessary to avoid compiler error in -#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - template< class T, std::size_t sz > - class array; -#endif - -namespace assign_detail -{ - ///////////////////////////////////////////////////////////////////////// - // Part 0: common conversion code - ///////////////////////////////////////////////////////////////////////// - - template< class T > - struct assign_decay - { - // - // Add constness to array parameters - // to support string literals properly - // - typedef BOOST_DEDUCED_TYPENAME mpl::eval_if< - ::boost::is_array, - ::boost::decay, - ::boost::decay >::type type; - }; - - template< class T, std::size_t sz > - type_traits::yes_type assign_is_array( const array* ); - type_traits::no_type assign_is_array( ... ); - template< class T, class U > - type_traits::yes_type assign_is_pair( const std::pair* ); - type_traits::no_type assign_is_pair( ... ); - - - - struct array_type_tag - { - #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - private: - char dummy_; // BCB would by default use 8 bytes - #endif - }; - struct adapter_type_tag - { - #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - private: - char dummy_; // BCB would by default use 8 bytes - #endif - }; - struct pair_type_tag - { - #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - private: - char dummy_; // BCB would by default use 8 bytes - #endif - }; - struct default_type_tag - { - #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - private: - char dummy_; // BCB would by default use 8 bytes - #endif - }; - - - - template< class DerivedTAssign, class Iterator > - class converter - { - public: // Range operations - typedef Iterator iterator; - typedef Iterator const_iterator; - - iterator begin() const - { - return static_cast(this)->begin(); - } - - iterator end() const - { - return static_cast(this)->end(); - } - - public: - - template< class Container > - Container convert_to_container() const - { - static Container* c = 0; - BOOST_STATIC_CONSTANT( bool, is_array_flag = sizeof( assign_detail::assign_is_array( c ) ) - == sizeof( type_traits::yes_type ) ); - - typedef BOOST_DEDUCED_TYPENAME mpl::if_c< is_array_flag, - array_type_tag, - default_type_tag >::type tag_type; - - return convert( c, tag_type() ); - } - - private: - - template< class Container > - Container convert( const Container*, default_type_tag ) const - { - -#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) -// old Dinkumware doesn't support iterator type as template - Container result; - iterator it = begin(), - e = end(); - while( it != e ) - { - result.insert( result.end(), *it ); - ++it; - } - return result; -#else - return Container( begin(), end() ); -#endif - } - - template< class Array > - Array convert( const Array*, array_type_tag ) const - { - typedef BOOST_DEDUCED_TYPENAME Array::value_type value_type; - -#if BOOST_WORKAROUND(BOOST_INTEL, <= 910 ) || BOOST_WORKAROUND(__SUNPRO_CC, <= 0x580 ) - BOOST_DEDUCED_TYPENAME remove_const::type ar; -#else - Array ar; -#endif - const std::size_t sz = ar.size(); - if( sz < static_cast(this)->size() ) - throw assign::assignment_exception( "array initialized with too many elements" ); - std::size_t n = 0; - iterator i = begin(), - e = end(); - for( ; i != e; ++i, ++n ) - ar[n] = *i; - for( ; n < sz; ++n ) - ar[n] = value_type(); - return ar; - } - - template< class Adapter > - Adapter convert_to_adapter( const Adapter* = 0 ) const - { - Adapter a; - iterator i = begin(), - e = end(); - for( ; i != e; ++i ) - a.push( *i ); - return a; - } - - private: - struct adapter_converter; - friend struct adapter_converter; - - struct adapter_converter - { - const converter& gl; - adapter_converter( const converter& this_ ) : gl( this_ ) - {} - - adapter_converter( const adapter_converter& r ) - : gl( r.gl ) - { } - - template< class Adapter > - operator Adapter() const - { - return gl.convert_to_adapter(); - } - }; - - public: - template< class Container > - Container to_container( Container& c ) const - { - return convert( &c, default_type_tag() ); - } - - adapter_converter to_adapter() const - { - return adapter_converter( *this ); - } - - template< class Adapter > - Adapter to_adapter( Adapter& a ) const - { - return this->convert_to_adapter( &a ); - } - - template< class Array > - Array to_array( Array& a ) const - { - return convert( &a, array_type_tag() ); - } - }; - - template< class T, class I, class Range > - inline bool operator==( const converter& l, const Range& r ) - { - return ::boost::iterator_range_detail::equal( l, r ); - } - - template< class T, class I, class Range > - inline bool operator==( const Range& l, const converter& r ) - { - return r == l; - } - - template< class T, class I, class Range > - inline bool operator!=( const converter& l, const Range& r ) - { - return !( l == r ); - } - - template< class T, class I, class Range > - inline bool operator!=( const Range& l, const converter& r ) - { - return !( l == r ); - } - - template< class T, class I, class Range > - inline bool operator<( const converter& l, const Range& r ) - { - return ::boost::iterator_range_detail::less_than( l, r ); - } - - template< class T, class I, class Range > - inline bool operator<( const Range& l, const converter& r ) - { - return ::boost::iterator_range_detail::less_than( l, r ); - } - - template< class T, class I, class Range > - inline bool operator>( const converter& l, const Range& r ) - { - return r < l; - } - - template< class T, class I, class Range > - inline bool operator>( const Range& l, const converter& r ) - { - return r < l; - } - - template< class T, class I, class Range > - inline bool operator<=( const converter& l, const Range& r ) - { - return !( l > r ); - } - - template< class T, class I, class Range > - inline bool operator<=( const Range& l, const converter& r ) - { - return !( l > r ); - } - - template< class T, class I, class Range > - inline bool operator>=( const converter& l, const Range& r ) - { - return !( l < r ); - } - - template< class T, class I, class Range > - inline bool operator>=( const Range& l, const converter& r ) - { - return !( l < r ); - } - - template< class T, class I, class Elem, class Traits > - inline std::basic_ostream& - operator<<( std::basic_ostream& Os, - const converter& r ) - { - return Os << ::boost::make_iterator_range( r.begin(), r.end() ); - } - - ///////////////////////////////////////////////////////////////////////// - // Part 1: flexible, but inefficient interface - ///////////////////////////////////////////////////////////////////////// - - template< class T > - class generic_list : - public converter< generic_list< BOOST_DEDUCED_TYPENAME assign_decay::type >, - BOOST_DEDUCED_TYPENAME std::deque::type>::iterator > - { - typedef BOOST_DEDUCED_TYPENAME assign_decay::type Ty; - typedef std::deque impl_type; - mutable impl_type values_; - - public: - typedef BOOST_DEDUCED_TYPENAME impl_type::iterator iterator; - typedef iterator const_iterator; - typedef BOOST_DEDUCED_TYPENAME impl_type::value_type value_type; - typedef BOOST_DEDUCED_TYPENAME impl_type::size_type size_type; - typedef BOOST_DEDUCED_TYPENAME impl_type::difference_type difference_type; - - public: - iterator begin() const { return values_.begin(); } - iterator end() const { return values_.end(); } - bool empty() const { return values_.empty(); } - size_type size() const { return values_.size(); } - - private: - void push_back( value_type r ) { values_.push_back( r ); } - - public: - generic_list& operator,( const Ty& u ) - { - this->push_back( u ); - return *this; - } - - generic_list& operator()() - { - this->push_back( Ty() ); - return *this; - } - - generic_list& operator()( const Ty& u ) - { - this->push_back( u ); - return *this; - } - - -#ifndef BOOST_ASSIGN_MAX_PARAMS // use user's value -#define BOOST_ASSIGN_MAX_PARAMS 5 -#endif -#define BOOST_ASSIGN_MAX_PARAMETERS (BOOST_ASSIGN_MAX_PARAMS - 1) -#define BOOST_ASSIGN_PARAMS1(n) BOOST_PP_ENUM_PARAMS(n, class U) -#define BOOST_ASSIGN_PARAMS2(n) BOOST_PP_ENUM_BINARY_PARAMS(n, U, const& u) -#define BOOST_ASSIGN_PARAMS3(n) BOOST_PP_ENUM_PARAMS(n, u) -#define BOOST_ASSIGN_PARAMS4(n) BOOST_PP_ENUM_PARAMS(n, U) -#define BOOST_ASSIGN_PARAMS2_NO_REF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, U, u) - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class U, BOOST_ASSIGN_PARAMS1(n) > \ - generic_list& operator()(U const& u, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - this->push_back( Ty(u, BOOST_ASSIGN_PARAMS3(n))); \ - return *this; \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - - template< class U > - generic_list& repeat( std::size_t sz, U u ) - { - std::size_t i = 0; - while( i++ != sz ) - this->push_back( u ); - return *this; - } - - template< class Nullary_function > - generic_list& repeat_fun( std::size_t sz, Nullary_function fun ) - { - std::size_t i = 0; - while( i++ != sz ) - this->push_back( fun() ); - return *this; - } - - template< class SinglePassIterator > - generic_list& range( SinglePassIterator first, - SinglePassIterator last ) - { - for( ; first != last; ++first ) - this->push_back( *first ); - return *this; - } - - template< class SinglePassRange > - generic_list& range( const SinglePassRange& r ) - { - return range( boost::begin(r), boost::end(r) ); - } - - template< class Container > - operator Container() const - { - return this-> BOOST_NESTED_TEMPLATE convert_to_container(); - } - }; - - ///////////////////////////////////////////////////////////////////////// - // Part 2: efficient, but inconvenient interface - ///////////////////////////////////////////////////////////////////////// - - template< class T > - struct assign_reference - { - assign_reference() - { /* intentionally empty */ } - - assign_reference( T& r ) : ref_(&r) - { } - - void operator=( T& r ) - { - ref_ = &r; - } - - operator T&() const - { - return *ref_; - } - - void swap( assign_reference& r ) - { - std::swap( *ref_, *r.ref_ ); - } - - T& get_ref() const - { - return *ref_; - } - - private: - T* ref_; - - }; - - template< class T > - inline bool operator<( const assign_reference& l, - const assign_reference& r ) - { - return l.get_ref() < r.get_ref(); - } - - template< class T > - inline bool operator>( const assign_reference& l, - const assign_reference& r ) - { - return l.get_ref() > r.get_ref(); - } - - template< class T > - inline void swap( assign_reference& l, - assign_reference& r ) - { - l.swap( r ); - } - - - - template< class T, int N > - struct static_generic_list : - public converter< static_generic_list, assign_reference* > - { - private: - typedef T internal_value_type; - - public: - typedef assign_reference value_type; - typedef value_type* iterator; - typedef value_type* const_iterator; - typedef std::size_t size_type; - typedef std::ptrdiff_t difference_type; - - - static_generic_list( T& r ) : - current_(1) - { - refs_[0] = r; - } - - static_generic_list& operator()( T& r ) - { - insert( r ); - return *this; - } - - iterator begin() const - { - return &refs_[0]; - } - - iterator end() const - { - return &refs_[current_]; - } - - size_type size() const - { - return static_cast( current_ ); - } - - bool empty() const - { - return false; - } - - template< class ForwardIterator > - static_generic_list& range( ForwardIterator first, - ForwardIterator last ) - { - for( ; first != last; ++first ) - this->insert( *first ); - return *this; - } - - template< class ForwardRange > - static_generic_list& range( ForwardRange& r ) - { - return range( boost::begin(r), boost::end(r) ); - } - - template< class ForwardRange > - static_generic_list& range( const ForwardRange& r ) - { - return range( boost::begin(r), boost::end(r) ); - } - - template< class Container > - operator Container() const - { - return this-> BOOST_NESTED_TEMPLATE convert_to_container(); - } - - private: - void insert( T& r ) - { - refs_[current_] = r; - ++current_; - } - - static_generic_list(); - - mutable assign_reference refs_[N]; - int current_; - }; - -} // namespace 'assign_detail' - -namespace assign -{ - template< class T > - inline assign_detail::generic_list - list_of() - { - return assign_detail::generic_list()( T() ); - } - - template< class T > - inline assign_detail::generic_list - list_of( const T& t ) - { - return assign_detail::generic_list()( t ); - } - - template< int N, class T > - inline assign_detail::static_generic_list< BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type,N> - ref_list_of( T& t ) - { - return assign_detail::static_generic_list::type,N>( t ); - } - - template< int N, class T > - inline assign_detail::static_generic_list::type,N> - cref_list_of( const T& t ) - { - return assign_detail::static_generic_list::type,N>( t ); - } - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, class U, BOOST_ASSIGN_PARAMS1(n) > \ - inline assign_detail::generic_list \ - list_of(U const& u, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - return assign_detail::generic_list()(u, BOOST_ASSIGN_PARAMS3(n)); \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class U, BOOST_ASSIGN_PARAMS1(n) > \ - inline assign_detail::generic_list< tuple > \ - tuple_list_of(U u, BOOST_ASSIGN_PARAMS2_NO_REF(n) ) \ - { \ - return assign_detail::generic_list< tuple >()( tuple( u, BOOST_ASSIGN_PARAMS3(n) )); \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - - template< class Key, class T > - inline assign_detail::generic_list< std::pair - < - BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type, - BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type - > > - map_list_of( const Key& k, const T& t ) - { - typedef BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type k_type; - typedef BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type t_type; - return assign_detail::generic_list< std::pair >()( k, t ); - } - - template< class F, class S > - inline assign_detail::generic_list< std::pair - < - BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type, - BOOST_DEDUCED_TYPENAME assign_detail::assign_decay::type - > > - pair_list_of( const F& f, const S& s ) - { - return map_list_of( f, s ); - } - - -} // namespace 'assign' -} // namespace 'boost' - - -#undef BOOST_ASSIGN_PARAMS1 -#undef BOOST_ASSIGN_PARAMS2 -#undef BOOST_ASSIGN_PARAMS3 -#undef BOOST_ASSIGN_PARAMS4 -#undef BOOST_ASSIGN_PARAMS2_NO_REF -#undef BOOST_ASSIGN_MAX_PARAMETERS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_inserter.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_inserter.hpp deleted file mode 100644 index c2ac3d8b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_inserter.hpp +++ /dev/null @@ -1,164 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2005. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_PTR_LIST_INSERTER_HPP -#define BOOST_ASSIGN_PTR_LIST_INSERTER_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ - -namespace assign -{ - template< class Function, class Obj > - class ptr_list_inserter - { - typedef BOOST_DEDUCED_TYPENAME - remove_pointer< BOOST_DEDUCED_TYPENAME - remove_reference::type >::type - obj_type; - public: - - ptr_list_inserter( Function fun ) : insert_( fun ) - {} - - template< class Function2, class Obj2 > - ptr_list_inserter( const ptr_list_inserter& r ) - : insert_( r.fun_private() ) - {} - - ptr_list_inserter( const ptr_list_inserter& r ) : insert_( r.insert_ ) - {} - - ptr_list_inserter& operator()() - { - insert_( new obj_type() ); - return *this; - } - - template< class T > - ptr_list_inserter& operator()( const T& t ) - { - insert_( new obj_type(t) ); - return *this; - } - -#ifndef BOOST_ASSIGN_MAX_PARAMS // use user's value -#define BOOST_ASSIGN_MAX_PARAMS 5 -#endif -#define BOOST_ASSIGN_MAX_PARAMETERS (BOOST_ASSIGN_MAX_PARAMS - 1) -#define BOOST_ASSIGN_PARAMS1(n) BOOST_PP_ENUM_PARAMS(n, class T) -#define BOOST_ASSIGN_PARAMS2(n) BOOST_PP_ENUM_BINARY_PARAMS(n, T, const& t) -#define BOOST_ASSIGN_PARAMS3(n) BOOST_PP_ENUM_PARAMS(n, t) - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, BOOST_ASSIGN_PARAMS1(n) > \ - ptr_list_inserter& operator()( const T& t, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - insert_( new obj_type(t, BOOST_ASSIGN_PARAMS3(n) )); \ - return *this; \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - private: - - ptr_list_inserter& operator=( const ptr_list_inserter& ); - Function insert_; - }; - - template< class Obj, class Function > - inline ptr_list_inserter< Function, Obj > - make_ptr_list_inserter( Function fun ) - { - return ptr_list_inserter< Function, Obj >( fun ); - } - - template< class C > - inline ptr_list_inserter< assign_detail::call_push_back, - BOOST_DEDUCED_TYPENAME C::reference > - ptr_push_back( C& c ) - { - return make_ptr_list_inserter - ( assign_detail::call_push_back( c ) ); - } - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - template< class T, class C > - inline ptr_list_inserter< assign_detail::call_push_back, T > - ptr_push_back( C& c ) - { - return make_ptr_list_inserter( - assign_detail::call_push_back( c ) ); - } - -#endif - - template< class C > - inline ptr_list_inserter< assign_detail::call_push_front, - BOOST_DEDUCED_TYPENAME C::reference > - ptr_push_front( C& c ) - { - return make_ptr_list_inserter - ( assign_detail::call_push_front( c ) ); - } - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - template< class T, class C > - inline ptr_list_inserter< assign_detail::call_push_front, T > - ptr_push_front( C& c ) - { - return make_ptr_list_inserter( - assign_detail::call_push_front( c ) ); - } - -#endif - - template< class C > - inline ptr_list_inserter< assign_detail::call_insert, - BOOST_DEDUCED_TYPENAME C::reference> - ptr_insert( C& c ) - { - return make_ptr_list_inserter - ( assign_detail::call_insert( c ) ); - } - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - template< class T, class C > - inline ptr_list_inserter< assign_detail::call_insert, T > - ptr_insert( C& c ) - { - return make_ptr_list_inserter( assign_detail::call_insert( c ) ); - } - -#endif - - -} // namespace 'assign' -} // namespace 'boost' - -#undef BOOST_ASSIGN_PARAMS1 -#undef BOOST_ASSIGN_PARAMS2 -#undef BOOST_ASSIGN_PARAMS3 -#undef BOOST_ASSIGN_MAX_PARAMETERS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_of.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_of.hpp deleted file mode 100644 index 3055ce79..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_list_of.hpp +++ /dev/null @@ -1,191 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2005. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_PTR_LIST_OF_HPP -#define BOOST_ASSIGN_PTR_LIST_OF_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -namespace boost -{ - -namespace assign_detail -{ - ///////////////////////////////////////////////////////////////////////// - // Part 1: flexible and efficient interface - ///////////////////////////////////////////////////////////////////////// - - template< class T > - class generic_ptr_list : - public converter< generic_ptr_list, - BOOST_DEDUCED_TYPENAME boost::ptr_vector::iterator > - { - protected: - typedef boost::ptr_vector impl_type; - typedef std::auto_ptr release_type; - mutable impl_type values_; - - public: - typedef BOOST_DEDUCED_TYPENAME impl_type::iterator iterator; - typedef iterator const_iterator; - typedef BOOST_DEDUCED_TYPENAME impl_type::value_type value_type; - typedef BOOST_DEDUCED_TYPENAME impl_type::size_type size_type; - typedef BOOST_DEDUCED_TYPENAME impl_type::difference_type difference_type; - public: - generic_ptr_list() : values_( 32u ) - { } - - generic_ptr_list( release_type r ) : values_(r) - { } - - release_type release() - { - return values_.release(); - } - - public: - iterator begin() const { return values_.begin(); } - iterator end() const { return values_.end(); } - bool empty() const { return values_.empty(); } - size_type size() const { return values_.size(); } - - public: - - operator impl_type() const - { - return values_; - } - - template< template class Seq, class U, - class CA, class A > - operator Seq() const - { - Seq result; - result.transfer( result.end(), values_ ); - BOOST_ASSERT( empty() ); - return result; - } - - template< class PtrContainer > - std::auto_ptr convert( const PtrContainer* c ) const - { - std::auto_ptr res( new PtrContainer() ); - while( !empty() ) - res->insert( res->end(), - values_.pop_back().release() ); - return res; - } - - template< class PtrContainer > - std::auto_ptr to_container( const PtrContainer& c ) const - { - return convert( &c ); - } - - protected: - void push_back( T* r ) { values_.push_back( r ); } - - public: - generic_ptr_list& operator()() - { - this->push_back( new T() ); - return *this; - } - - template< class U > - generic_ptr_list& operator()( const U& u ) - { - this->push_back( new T(u) ); - return *this; - } - - -#ifndef BOOST_ASSIGN_MAX_PARAMS // use user's value -#define BOOST_ASSIGN_MAX_PARAMS 5 -#endif -#define BOOST_ASSIGN_MAX_PARAMETERS (BOOST_ASSIGN_MAX_PARAMS - 1) -#define BOOST_ASSIGN_PARAMS1(n) BOOST_PP_ENUM_PARAMS(n, class U) -#define BOOST_ASSIGN_PARAMS2(n) BOOST_PP_ENUM_BINARY_PARAMS(n, U, const& u) -#define BOOST_ASSIGN_PARAMS3(n) BOOST_PP_ENUM_PARAMS(n, u) - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class U, BOOST_ASSIGN_PARAMS1(n) > \ - generic_ptr_list& operator()(U const& u, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - this->push_back( new T(u, BOOST_ASSIGN_PARAMS3(n))); \ - return *this; \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - }; // class 'generic_ptr_list' - -} // namespace 'assign_detail' - -namespace assign -{ - template< class T > - inline assign_detail::generic_ptr_list - ptr_list_of() - { - return assign_detail::generic_ptr_list()(); - } - - template< class T, class U > - inline assign_detail::generic_ptr_list - ptr_list_of( const U& t ) - { - return assign_detail::generic_ptr_list()( t ); - } - - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, class U, BOOST_ASSIGN_PARAMS1(n) > \ - inline assign_detail::generic_ptr_list \ - ptr_list_of(U const& u, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - return assign_detail::generic_ptr_list()(u, BOOST_ASSIGN_PARAMS3(n)); \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - -} // namespace 'assign' -} // namespace 'boost' - - -#undef BOOST_ASSIGN_PARAMS1 -#undef BOOST_ASSIGN_PARAMS2 -#undef BOOST_ASSIGN_PARAMS3 -#undef BOOST_ASSIGN_MAX_PARAMETERS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_map_inserter.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_map_inserter.hpp deleted file mode 100644 index c45aeb83..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/ptr_map_inserter.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2006. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_PTR_CONTAINER_PTR_MAP_INSERTER_HPP -#define BOOST_ASSIGN_PTR_CONTAINER_PTR_MAP_INSERTER_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ - -namespace assign -{ - template< class PtrMap, class Obj > - class ptr_map_inserter - { - typedef BOOST_DEDUCED_TYPENAME - remove_pointer< BOOST_DEDUCED_TYPENAME - remove_reference::type >::type - obj_type; - typedef BOOST_DEDUCED_TYPENAME PtrMap::key_type - key_type; - - public: - - ptr_map_inserter( PtrMap& m ) : m_( m ) - {} - - template< class Key > - ptr_map_inserter& operator()( const Key& t ) - { - key_type k(t); - m_.insert( k, new obj_type ); - return *this; - } - -#ifndef BOOST_ASSIGN_MAX_PARAMS // use user's value -#define BOOST_ASSIGN_MAX_PARAMS 6 -#endif -#define BOOST_ASSIGN_MAX_PARAMETERS (BOOST_ASSIGN_MAX_PARAMS - 1) -#define BOOST_ASSIGN_PARAMS1(n) BOOST_PP_ENUM_PARAMS(n, class T) -#define BOOST_ASSIGN_PARAMS2(n) BOOST_PP_ENUM_BINARY_PARAMS(n, T, const& t) -#define BOOST_ASSIGN_PARAMS3(n) BOOST_PP_ENUM_PARAMS(n, t) - -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_ASSIGN_MAX_PARAMETERS) -#define BOOST_PP_LOCAL_MACRO(n) \ - template< class T, BOOST_ASSIGN_PARAMS1(n) > \ - ptr_map_inserter& operator()( const T& t, BOOST_ASSIGN_PARAMS2(n) ) \ - { \ - key_type k(t); \ - m_.insert( k, new obj_type( BOOST_ASSIGN_PARAMS3(n) ) ); \ - return *this; \ - } \ - /**/ - -#include BOOST_PP_LOCAL_ITERATE() - - private: - - ptr_map_inserter& operator=( const ptr_map_inserter& ); - PtrMap& m_; - }; - - template< class PtrMap > - inline ptr_map_inserter< PtrMap, typename PtrMap::mapped_reference > - ptr_map_insert( PtrMap& m ) - { - return ptr_map_inserter< PtrMap, typename PtrMap::mapped_reference >( m ); - } - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - template< class T, class PtrMap > - inline ptr_map_inserter< PtrMap, T > - ptr_map_insert( PtrMap& m ) - { - return ptr_map_inserter< PtrMap, T >( m ); - } - -#endif - -} // namespace 'assign' -} // namespace 'boost' - -#undef BOOST_ASSIGN_PARAMS1 -#undef BOOST_ASSIGN_PARAMS2 -#undef BOOST_ASSIGN_PARAMS3 -#undef BOOST_ASSIGN_MAX_PARAMETERS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std.hpp deleted file mode 100644 index 2cdec96f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std.hpp +++ /dev/null @@ -1,27 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_STD_HPP -#define BOOST_ASSIGN_STD_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/deque.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/deque.hpp deleted file mode 100644 index 3546a0fc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/deque.hpp +++ /dev/null @@ -1,38 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_STD_DEQUE_HPP -#define BOOST_ASSIGN_STD_DEQUE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class V, class A, class V2 > - inline list_inserter< assign_detail::call_push_back< std::deque >, V > - operator+=( std::deque& c, V2 v ) - { - return push_back( c )( v ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/list.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/list.hpp deleted file mode 100644 index 2404b046..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/list.hpp +++ /dev/null @@ -1,38 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_STD_LIST_HPP -#define BOOST_ASSIGN_STD_LIST_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class V, class A, class V2 > - inline list_inserter< assign_detail::call_push_back< std::list >, V > - operator+=( std::list& c, V2 v ) - { - return push_back( c )( v ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/map.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/map.hpp deleted file mode 100644 index 4937492c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/map.hpp +++ /dev/null @@ -1,45 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_STD_MAP_HPP -#define BOOST_ASSIGN_STD_MAP_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class K, class V, class C, class A, class P > - inline list_inserter< assign_detail::call_insert< std::map >, P > - operator+=( std::map& m, const P& p ) - { - return insert( m )( p ); - } - - template< class K, class V, class C, class A, class P > - inline list_inserter< assign_detail::call_insert< std::multimap >, P > - operator+=( std::multimap& m, const P& p ) - { - return insert( m )( p ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/queue.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/queue.hpp deleted file mode 100644 index a9dea395..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/queue.hpp +++ /dev/null @@ -1,45 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_STD_QUEUE_HPP -#define BOOST_ASSIGN_STD_QUEUE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class V, class C, class V2 > - inline list_inserter< assign_detail::call_push< std::queue >, V > - operator+=( std::queue& c, V2 v ) - { - return push( c )( v ); - } - - template< class V, class C, class V2 > - inline list_inserter< assign_detail::call_push< std::priority_queue >, V > - operator+=( std::priority_queue& c, V2 v ) - { - return push( c )( v ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/set.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/set.hpp deleted file mode 100644 index 9ad79ef7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/set.hpp +++ /dev/null @@ -1,44 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - - -#ifndef BOOST_ASSIGN_STD_SET_HPP -#define BOOST_ASSIGN_STD_SET_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - template< class K, class C, class A, class K2 > - inline list_inserter< assign_detail::call_insert< std::set >, K > - operator+=( std::set& c, K2 k ) - { - return insert( c )( k ); - } - - template< class K, class C, class A, class K2 > - inline list_inserter< assign_detail::call_insert< std::multiset >, K > - operator+=( std::multiset& c, K2 k ) - { - return insert( c )( k ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/slist.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/slist.hpp deleted file mode 100644 index 6e20f78a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/slist.hpp +++ /dev/null @@ -1,45 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_STD_SLIST_HPP -#define BOOST_ASSIGN_STD_SLIST_HPP - -#include -#ifdef BOOST_HAS_SLIST - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#ifdef BOOST_SLIST_HEADER -# include BOOST_SLIST_HEADER -#else -# include -#endif - -namespace boost -{ -namespace assign -{ - - template< class V, class A, class V2 > - inline list_inserter< assign_detail::call_push_back< BOOST_STD_EXTENSION_NAMESPACE::slist >, V > - operator+=( BOOST_STD_EXTENSION_NAMESPACE::slist& c, V2 v ) - { - return push_back( c )( v ); - } - -} -} - -#endif // BOOST_HAS_SLIST - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/stack.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/stack.hpp deleted file mode 100644 index 89f58d96..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/stack.hpp +++ /dev/null @@ -1,37 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_STD_STACK_HPP -#define BOOST_ASSIGN_STD_STACK_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class V, class C, class V2 > - inline list_inserter< assign_detail::call_push< std::stack >, V > - operator+=( std::stack& c, V2 v ) - { - return push( c )( v ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/assign/std/vector.hpp b/third_party/ycmd/cpp/BoostParts/boost/assign/std/vector.hpp deleted file mode 100644 index e9f3b798..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/assign/std/vector.hpp +++ /dev/null @@ -1,37 +0,0 @@ -// Boost.Assign library -// -// Copyright Thorsten Ottosen 2003-2004. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org/libs/assign/ -// - -#ifndef BOOST_ASSIGN_STD_VECTOR_HPP -#define BOOST_ASSIGN_STD_VECTOR_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ -namespace assign -{ - - template< class V, class A, class V2 > - inline list_inserter< assign_detail::call_push_back< std::vector >, V > - operator+=( std::vector& c, V2 v ) - { - return push_back( c )( v ); - } - -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic.hpp deleted file mode 100644 index cc28b1ab..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic.hpp +++ /dev/null @@ -1,18 +0,0 @@ -#ifndef BOOST_ATOMIC_HPP -#define BOOST_ATOMIC_HPP - -// Copyright (c) 2011 Helge Bahmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// This header includes all Boost.Atomic public headers - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/atomic.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/atomic.hpp deleted file mode 100644 index dd3c0146..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/atomic.hpp +++ /dev/null @@ -1,232 +0,0 @@ -#ifndef BOOST_ATOMIC_ATOMIC_HPP -#define BOOST_ATOMIC_ATOMIC_HPP - -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include - -#include - -#include -#include -#include -#include -#if defined(BOOST_MSVC) && BOOST_MSVC < 1400 -#include -#include -#endif - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { - -#ifndef BOOST_ATOMIC_CHAR_LOCK_FREE -#define BOOST_ATOMIC_CHAR_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_CHAR16_T_LOCK_FREE -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_CHAR32_T_LOCK_FREE -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_WCHAR_T_LOCK_FREE -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_SHORT_LOCK_FREE -#define BOOST_ATOMIC_SHORT_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_INT_LOCK_FREE -#define BOOST_ATOMIC_INT_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_LONG_LOCK_FREE -#define BOOST_ATOMIC_LONG_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_LLONG_LOCK_FREE -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_INT128_LOCK_FREE -#define BOOST_ATOMIC_INT128_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_POINTER_LOCK_FREE -#define BOOST_ATOMIC_POINTER_LOCK_FREE 0 -#endif - -#define BOOST_ATOMIC_ADDRESS_LOCK_FREE BOOST_ATOMIC_POINTER_LOCK_FREE - -#ifndef BOOST_ATOMIC_BOOL_LOCK_FREE -#define BOOST_ATOMIC_BOOL_LOCK_FREE 0 -#endif - -#ifndef BOOST_ATOMIC_THREAD_FENCE -#define BOOST_ATOMIC_THREAD_FENCE 0 -inline void atomic_thread_fence(memory_order) -{ -} -#endif - -#ifndef BOOST_ATOMIC_SIGNAL_FENCE -#define BOOST_ATOMIC_SIGNAL_FENCE 0 -inline void atomic_signal_fence(memory_order order) -{ - atomic_thread_fence(order); -} -#endif - -template -class atomic : - public atomics::detail::base_atomic< - T, - typename atomics::detail::classify::type, - atomics::detail::storage_size_of::value, -#if !defined(BOOST_MSVC) || BOOST_MSVC >= 1400 - boost::is_signed::value -#else - // MSVC 2003 has problems instantiating is_signed on non-integral types - mpl::and_< boost::is_integral, boost::is_signed >::value -#endif - > -{ -private: - typedef T value_type; - typedef atomics::detail::base_atomic< - T, - typename atomics::detail::classify::type, - atomics::detail::storage_size_of::value, -#if !defined(BOOST_MSVC) || BOOST_MSVC >= 1400 - boost::is_signed::value -#else - // MSVC 2003 has problems instantiating is_signed on non-itegral types - mpl::and_< boost::is_integral, boost::is_signed >::value -#endif - > super; - typedef typename super::value_arg_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(atomic(void), BOOST_NOEXCEPT {}) - - // NOTE: The constructor is made explicit because gcc 4.7 complains that - // operator=(value_arg_type) is considered ambiguous with operator=(atomic const&) - // in assignment expressions, even though conversion to atomic<> is less preferred - // than conversion to value_arg_type. - explicit BOOST_CONSTEXPR atomic(value_arg_type v) BOOST_NOEXCEPT : super(v) {} - - value_type operator=(value_arg_type v) volatile BOOST_NOEXCEPT - { - this->store(v); - return v; - } - - operator value_type(void) volatile const BOOST_NOEXCEPT - { - return this->load(); - } - - BOOST_DELETED_FUNCTION(atomic(atomic const&)) - BOOST_DELETED_FUNCTION(atomic& operator=(atomic const&) volatile) -}; - -typedef atomic atomic_char; -typedef atomic atomic_uchar; -typedef atomic atomic_schar; -typedef atomic atomic_uint8_t; -typedef atomic atomic_int8_t; -typedef atomic atomic_ushort; -typedef atomic atomic_short; -typedef atomic atomic_uint16_t; -typedef atomic atomic_int16_t; -typedef atomic atomic_uint; -typedef atomic atomic_int; -typedef atomic atomic_uint32_t; -typedef atomic atomic_int32_t; -typedef atomic atomic_ulong; -typedef atomic atomic_long; -typedef atomic atomic_uint64_t; -typedef atomic atomic_int64_t; -#ifdef BOOST_HAS_LONG_LONG -typedef atomic atomic_ullong; -typedef atomic atomic_llong; -#endif -typedef atomic atomic_address; -typedef atomic atomic_bool; -typedef atomic atomic_wchar_t; -#if !defined(BOOST_NO_CXX11_CHAR16_T) -typedef atomic atomic_char16_t; -#endif -#if !defined(BOOST_NO_CXX11_CHAR32_T) -typedef atomic atomic_char32_t; -#endif - -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_intmax_t; -typedef atomic atomic_uintmax_t; - -typedef atomic atomic_size_t; -typedef atomic atomic_ptrdiff_t; - -#if defined(BOOST_HAS_INTPTR_T) -typedef atomic atomic_intptr_t; -typedef atomic atomic_uintptr_t; -#endif - -#ifndef BOOST_ATOMIC_FLAG_LOCK_FREE -#define BOOST_ATOMIC_FLAG_LOCK_FREE 0 -class atomic_flag -{ -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(false) {} - - bool - test_and_set(memory_order order = memory_order_seq_cst) BOOST_NOEXCEPT - { - return v_.exchange(true, order); - } - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v_.store(false, order); - } - - BOOST_DELETED_FUNCTION(atomic_flag(atomic_flag const&)) - BOOST_DELETED_FUNCTION(atomic_flag& operator=(atomic_flag const&)) - -private: - atomic v_; -}; -#endif - -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/base.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/base.hpp deleted file mode 100644 index eb105b9b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/base.hpp +++ /dev/null @@ -1,605 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_BASE_HPP -#define BOOST_ATOMIC_DETAIL_BASE_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Base class definition and fallback implementation. -// To be overridden (through partial specialization) by -// platform implementations. - -#include - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#define BOOST_ATOMIC_DECLARE_BASE_OPERATORS \ - bool \ - compare_exchange_strong( \ - value_type & expected, \ - value_type desired, \ - memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT \ - { \ - return compare_exchange_strong(expected, desired, order, calculate_failure_order(order)); \ - } \ - \ - bool \ - compare_exchange_weak( \ - value_type & expected, \ - value_type desired, \ - memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT \ - { \ - return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); \ - } \ - -#define BOOST_ATOMIC_DECLARE_ADDITIVE_OPERATORS \ - value_type \ - operator++(int) volatile BOOST_NOEXCEPT \ - { \ - return fetch_add(1); \ - } \ - \ - value_type \ - operator++(void) volatile BOOST_NOEXCEPT \ - { \ - return fetch_add(1) + 1; \ - } \ - \ - value_type \ - operator--(int) volatile BOOST_NOEXCEPT \ - { \ - return fetch_sub(1); \ - } \ - \ - value_type \ - operator--(void) volatile BOOST_NOEXCEPT \ - { \ - return fetch_sub(1) - 1; \ - } \ - \ - value_type \ - operator+=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return fetch_add(v) + v; \ - } \ - \ - value_type \ - operator-=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return fetch_sub(v) - v; \ - } \ - -#define BOOST_ATOMIC_DECLARE_VOID_POINTER_ADDITIVE_OPERATORS \ - value_type \ - operator++(int) volatile BOOST_NOEXCEPT \ - { \ - return fetch_add(1); \ - } \ - \ - value_type \ - operator++(void) volatile BOOST_NOEXCEPT \ - { \ - return (char*)fetch_add(1) + 1; \ - } \ - \ - value_type \ - operator--(int) volatile BOOST_NOEXCEPT \ - { \ - return fetch_sub(1); \ - } \ - \ - value_type \ - operator--(void) volatile BOOST_NOEXCEPT \ - { \ - return (char*)fetch_sub(1) - 1; \ - } \ - \ - value_type \ - operator+=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return (char*)fetch_add(v) + v; \ - } \ - \ - value_type \ - operator-=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return (char*)fetch_sub(v) - v; \ - } \ - -#define BOOST_ATOMIC_DECLARE_BIT_OPERATORS \ - value_type \ - operator&=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return fetch_and(v) & v; \ - } \ - \ - value_type \ - operator|=(difference_type v) volatile BOOST_NOEXCEPT \ - { \ - return fetch_or(v) | v; \ - } \ - \ - value_type \ - operator^=(difference_type v) volatile BOOST_NOEXCEPT\ - { \ - return fetch_xor(v) ^ v; \ - } \ - -#define BOOST_ATOMIC_DECLARE_POINTER_OPERATORS \ - BOOST_ATOMIC_DECLARE_BASE_OPERATORS \ - BOOST_ATOMIC_DECLARE_ADDITIVE_OPERATORS \ - -#define BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS \ - BOOST_ATOMIC_DECLARE_BASE_OPERATORS \ - BOOST_ATOMIC_DECLARE_VOID_POINTER_ADDITIVE_OPERATORS \ - -#define BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS \ - BOOST_ATOMIC_DECLARE_BASE_OPERATORS \ - BOOST_ATOMIC_DECLARE_ADDITIVE_OPERATORS \ - BOOST_ATOMIC_DECLARE_BIT_OPERATORS \ - -namespace boost { -namespace atomics { -namespace detail { - -inline memory_order -calculate_failure_order(memory_order order) -{ - switch(order) - { - case memory_order_acq_rel: - return memory_order_acquire; - case memory_order_release: - return memory_order_relaxed; - default: - return order; - } -} - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef lockpool::scoped_lock guard_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(v) - {} - - void - store(value_type const& v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - char * storage = storage_ptr(); - guard_type guard(storage); - - memcpy(storage, &v, sizeof(value_type)); - } - - value_type - load(memory_order /*order*/ = memory_order_seq_cst) volatile const BOOST_NOEXCEPT - { - char * storage = storage_ptr(); - guard_type guard(storage); - - value_type v; - memcpy(&v, storage, sizeof(value_type)); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order /*success_order*/, - memory_order /*failure_order*/) volatile BOOST_NOEXCEPT - { - char * storage = storage_ptr(); - guard_type guard(storage); - - if (memcmp(storage, &expected, sizeof(value_type)) == 0) { - memcpy(storage, &desired, sizeof(value_type)); - return true; - } else { - memcpy(&expected, storage, sizeof(value_type)); - return false; - } - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - exchange(value_type const& v, memory_order /*order*/=memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - char * storage = storage_ptr(); - guard_type guard(storage); - - value_type tmp; - memcpy(&tmp, storage, sizeof(value_type)); - - memcpy(storage, &v, sizeof(value_type)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return false; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - char * storage_ptr() volatile const BOOST_NOEXCEPT - { - return const_cast(&reinterpret_cast(v_)); - } - - T v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef lockpool::scoped_lock guard_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - v_ = v; - } - - value_type - load(memory_order /*order*/ = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type v = const_cast(v_); - return v; - } - - value_type - exchange(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ = v; - return old; - } - - bool - compare_exchange_strong(value_type & expected, value_type desired, - memory_order /*success_order*/, - memory_order /*failure_order*/) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - if (v_ == expected) { - v_ = desired; - return true; - } else { - expected = v_; - return false; - } - } - - bool - compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_add(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ += v; - return old; - } - - value_type - fetch_sub(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ -= v; - return old; - } - - value_type - fetch_and(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ &= v; - return old; - } - - value_type - fetch_or(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ |= v; - return old; - } - - value_type - fetch_xor(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ ^= v; - return old; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return false; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - typedef lockpool::scoped_lock guard_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - v_ = v; - } - - value_type - load(memory_order /*order*/ = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type v = const_cast(v_); - return v; - } - - value_type - exchange(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ = v; - return old; - } - - bool - compare_exchange_strong(value_type & expected, value_type desired, - memory_order /*success_order*/, - memory_order /*failure_order*/) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - if (v_ == expected) { - v_ = desired; - return true; - } else { - expected = v_; - return false; - } - } - - bool - compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type fetch_add(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ += v; - return old; - } - - value_type fetch_sub(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ -= v; - return old; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return false; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - typedef lockpool::scoped_lock guard_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - v_ = v; - } - - value_type - load(memory_order /*order*/ = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type v = const_cast(v_); - return v; - } - - value_type - exchange(value_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - v_ = v; - return old; - } - - bool - compare_exchange_strong(value_type & expected, value_type desired, - memory_order /*success_order*/, - memory_order /*failure_order*/) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - if (v_ == expected) { - v_ = desired; - return true; - } else { - expected = v_; - return false; - } - } - - bool - compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return false; - } - - value_type fetch_add(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - char * cv = reinterpret_cast(old); - cv += v; - v_ = cv; - return old; - } - - value_type fetch_sub(difference_type v, memory_order /*order*/ = memory_order_seq_cst) volatile - { - guard_type guard(const_cast(&v_)); - - value_type old = v_; - char * cv = reinterpret_cast(old); - cv -= v; - v_ = cv; - return old; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas128strong.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas128strong.hpp deleted file mode 100644 index dcb4d7d2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas128strong.hpp +++ /dev/null @@ -1,290 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CAS128STRONG_HPP -#define BOOST_ATOMIC_DETAIL_CAS128STRONG_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann, Andrey Semashev - -// Build 128-bit atomic operation on integers/UDTs from platform_cmpxchg128_strong -// primitive. It is assumed that 128-bit loads/stores are not -// atomic, so they are implemented through platform_load128/platform_store128. - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - platform_store128(v, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = platform_load128(&v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg128_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* generic types */ - -#if defined(BOOST_HAS_INT128) - -typedef boost::uint128_type storage128_type; - -#else // defined(BOOST_HAS_INT128) - -struct BOOST_ALIGNMENT(16) storage128_type -{ - uint64_t data[2]; -}; - -inline bool operator== (storage128_type const& left, storage128_type const& right) -{ - return left.data[0] == right.data[0] && left.data[1] == right.data[1]; -} -inline bool operator!= (storage128_type const& left, storage128_type const& right) -{ - return !(left == right); -} - -#endif // defined(BOOST_HAS_INT128) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef storage128_type storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT - { - memset(&v_, 0, sizeof(v_)); - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& value, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type value_s; - memset(&value_s, 0, sizeof(value_s)); - memcpy(&value_s, &value, sizeof(value_type)); - platform_fence_before_store(order); - platform_store128(value_s, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type value_s = platform_load128(&v_); - platform_fence_after_load(order); - value_type value; - memcpy(&value, &value_s, sizeof(value_type)); - return value; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memset(&expected_s, 0, sizeof(expected_s)); - memset(&desired_s, 0, sizeof(desired_s)); - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - bool success = platform_cmpxchg128_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32strong.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32strong.hpp deleted file mode 100644 index 27e79839..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32strong.hpp +++ /dev/null @@ -1,939 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CAS32STRONG_HPP -#define BOOST_ATOMIC_DETAIL_CAS32STRONG_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann - - -// Build 8-, 16- and 32-bit atomic operations from -// a platform_cmpxchg32_strong primitive. - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - storage_type expected_s = (storage_type) expected; - storage_type desired_s = (storage_type) desired; - - bool success = platform_cmpxchg32_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - expected = (value_type) expected_s; - } - - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - storage_type expected_s = (storage_type) expected; - storage_type desired_s = (storage_type) desired; - - bool success = platform_cmpxchg32_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - expected = (value_type) expected_s; - } - - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* pointer types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef void * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original - v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* generic types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) ) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) ) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) ) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) ) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - bool success = platform_cmpxchg32_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) ) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) ) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - bool success = platform_cmpxchg32_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - bool success = platform_cmpxchg32_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - is_lock_free(void) const volatile - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32weak.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32weak.hpp deleted file mode 100644 index d75215d8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas32weak.hpp +++ /dev/null @@ -1,1017 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CAS32WEAK_HPP -#define BOOST_ATOMIC_DETAIL_CAS32WEAK_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann - - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - storage_type expected_s = (storage_type) expected; - storage_type desired_s = (storage_type) desired; - - bool success = platform_cmpxchg32(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - expected = (value_type) expected_s; - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - storage_type expected_s = (storage_type) expected; - storage_type desired_s = (storage_type) desired; - - bool success = platform_cmpxchg32(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - expected = (value_type) expected_s; - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* pointer types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef void * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original - v, order, memory_order_relaxed)); - return original; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* generic types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before_store(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - - bool success = platform_cmpxchg32(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - while (true) - { - value_type tmp = expected; - if (compare_exchange_weak(tmp, desired, success_order, failure_order)) - return true; - if (tmp != expected) - { - expected = tmp; - return false; - } - } - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong-ptr.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong-ptr.hpp deleted file mode 100644 index 2f04112a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong-ptr.hpp +++ /dev/null @@ -1,247 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CAS64STRONG_PTR_HPP -#define BOOST_ATOMIC_DETAIL_CAS64STRONG_PTR_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann - -// Build 64-bit atomic operation on pointers from platform_cmpxchg64_strong -// primitive. It is assumed that 64-bit loads/stores are not -// atomic, so they are implemented through platform_load64/platform_store64. -// -// The reason for extracting pointer specializations to a separate header is -// that 64-bit CAS is available on some 32-bit platforms (notably, x86). -// On these platforms there is no need for 64-bit pointer specializations, -// since they will never be used. - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* pointer types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef void * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - platform_store64(v, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = platform_load64(&v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg64_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, (char*)original - v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - platform_store64(v, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = platform_load64(&v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg64_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong.hpp deleted file mode 100644 index c283f986..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/cas64strong.hpp +++ /dev/null @@ -1,264 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CAS64STRONG_HPP -#define BOOST_ATOMIC_DETAIL_CAS64STRONG_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann - -// Build 64-bit atomic operation on integers/UDTs from platform_cmpxchg64_strong -// primitive. It is assumed that 64-bit loads/stores are not -// atomic, so they are implemented through platform_load64/platform_store64. - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before_store(order); - platform_store64(v, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = platform_load64(&v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - - bool success = platform_cmpxchg64_strong(expected, desired, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - } - - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original + v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original - v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original & v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original | v, order, memory_order_relaxed)); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, original ^ v, order, memory_order_relaxed)); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* generic types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint64_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& value, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type value_s = 0; - memcpy(&value_s, &value, sizeof(value_type)); - platform_fence_before_store(order); - platform_store64(value_s, &v_); - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type value_s = platform_load64(&v_); - platform_fence_after_load(order); - value_type value; - memcpy(&value, &value_s, sizeof(value_type)); - return value; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original = load(memory_order_relaxed); - do { - } while (!compare_exchange_weak(original, v, order, memory_order_relaxed)); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - platform_fence_before(success_order); - bool success = platform_cmpxchg64_strong(expected_s, desired_s, &v_); - - if (success) { - platform_fence_after(success_order); - } else { - platform_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - } - - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/config.hpp deleted file mode 100644 index b1984e52..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/config.hpp +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_CONFIG_HPP -#define BOOST_ATOMIC_DETAIL_CONFIG_HPP - -// Copyright (c) 2012 Hartmut Kaiser -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-alpha.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-alpha.hpp deleted file mode 100644 index 27754997..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-alpha.hpp +++ /dev/null @@ -1,368 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_ALPHA_HPP -#define BOOST_ATOMIC_DETAIL_GCC_ALPHA_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -/* - Refer to http://h71000.www7.hp.com/doc/82final/5601/5601pro_004.html - (HP OpenVMS systems documentation) and the alpha reference manual. - */ - -/* - NB: The most natural thing would be to write the increment/decrement - operators along the following lines: - - __asm__ __volatile__( - "1: ldl_l %0,%1 \n" - "addl %0,1,%0 \n" - "stl_c %0,%1 \n" - "beq %0,1b\n" - : "=&b" (tmp) - : "m" (value) - : "cc" - ); - - However according to the comments on the HP website and matching - comments in the Linux kernel sources this defies branch prediction, - as the cpu assumes that backward branches are always taken; so - instead copy the trick from the Linux kernel, introduce a forward - branch and back again. - - I have, however, had a hard time measuring the difference between - the two versions in microbenchmarks -- I am leaving it in nevertheless - as it apparently does not hurt either. -*/ - -namespace boost { -namespace atomics { -namespace detail { - -inline void fence_before(memory_order order) -{ - switch(order) { - case memory_order_consume: - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("mb" ::: "memory"); - default:; - } -} - -inline void fence_after(memory_order order) -{ - switch(order) { - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("mb" ::: "memory"); - default:; - } -} - -template<> -inline void platform_atomic_thread_fence(memory_order order) -{ - switch(order) { - case memory_order_acquire: - case memory_order_consume: - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("mb" ::: "memory"); - default:; - } -} - -template -class atomic_alpha_32 -{ -public: - typedef T integral_type; - BOOST_CONSTEXPR atomic_alpha_32(T v) BOOST_NOEXCEPT: i(v) {} - atomic_alpha_32() {} - T load(memory_order order=memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - T v=*reinterpret_cast(&i); - fence_after(order); - return v; - } - void store(T v, memory_order order=memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - fence_before(order); - *reinterpret_cast(&i)=(int)v; - } - bool compare_exchange_weak( - T &expected, - T desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - fence_before(success_order); - int current, success; - __asm__ __volatile__( - "1: ldl_l %2, %4\n" - "cmpeq %2, %0, %3\n" - "mov %2, %0\n" - "beq %3, 3f\n" - "stl_c %1, %4\n" - "2:\n" - - ".subsection 2\n" - "3: mov %3, %1\n" - "br 2b\n" - ".previous\n" - - : "+&r" (expected), "+&r" (desired), "=&r"(current), "=&r"(success) - : "m" (i) - : - ); - if (desired) fence_after(success_order); - else fence_after(failure_order); - return desired; - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT {return true;} -protected: - inline T fetch_add_var(T c, memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - T original, modified; - __asm__ __volatile__( - "1: ldl_l %0, %2\n" - "addl %0, %3, %1\n" - "stl_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i), "r" (c) - : - ); - fence_after(order); - return original; - } - inline T fetch_inc(memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - int original, modified; - __asm__ __volatile__( - "1: ldl_l %0, %2\n" - "addl %0, 1, %1\n" - "stl_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i) - : - ); - fence_after(order); - return original; - } - inline T fetch_dec(memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - int original, modified; - __asm__ __volatile__( - "1: ldl_l %0, %2\n" - "subl %0, 1, %1\n" - "stl_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i) - : - ); - fence_after(order); - return original; - } -private: - T i; -}; - -template -class atomic_alpha_64 -{ -public: - typedef T integral_type; - BOOST_CONSTEXPR atomic_alpha_64(T v) BOOST_NOEXCEPT: i(v) {} - atomic_alpha_64() {} - T load(memory_order order=memory_order_seq_cst) const volatile - { - T v=*reinterpret_cast(&i); - fence_after(order); - return v; - } - void store(T v, memory_order order=memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - fence_before(order); - *reinterpret_cast(&i)=v; - } - bool compare_exchange_weak( - T &expected, - T desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - fence_before(success_order); - int current, success; - __asm__ __volatile__( - "1: ldq_l %2, %4\n" - "cmpeq %2, %0, %3\n" - "mov %2, %0\n" - "beq %3, 3f\n" - "stq_c %1, %4\n" - "2:\n" - - ".subsection 2\n" - "3: mov %3, %1\n" - "br 2b\n" - ".previous\n" - - : "+&r" (expected), "+&r" (desired), "=&r"(current), "=&r"(success) - : "m" (i) - : - ); - if (desired) fence_after(success_order); - else fence_after(failure_order); - return desired; - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT {return true;} -protected: - inline T fetch_add_var(T c, memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - T original, modified; - __asm__ __volatile__( - "1: ldq_l %0, %2\n" - "addq %0, %3, %1\n" - "stq_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i), "r" (c) - : - ); - fence_after(order); - return original; - } - inline T fetch_inc(memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - T original, modified; - __asm__ __volatile__( - "1: ldq_l %0, %2\n" - "addq %0, 1, %1\n" - "stq_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i) - : - ); - fence_after(order); - return original; - } - inline T fetch_dec(memory_order order) volatile BOOST_NOEXCEPT - { - fence_before(order); - T original, modified; - __asm__ __volatile__( - "1: ldq_l %0, %2\n" - "subq %0, 1, %1\n" - "stq_c %1, %2\n" - "beq %1, 2f\n" - - ".subsection 2\n" - "2: br 1b\n" - ".previous\n" - - : "=&r" (original), "=&r" (modified) - : "m" (i) - : - ); - fence_after(order); - return original; - } -private: - T i; -}; - -template -class platform_atomic_integral : - public build_atomic_from_typical > > -{ -public: - typedef build_atomic_from_typical > > super; - BOOST_CONSTEXPR platform_atomic_integral(T v) BOOST_NOEXCEPT: super(v) {} - platform_atomic_integral(void) {} -}; - -template -class platform_atomic_integral : - public build_atomic_from_typical > > -{ -public: - typedef build_atomic_from_typical > > super; - BOOST_CONSTEXPR platform_atomic_integral(T v) BOOST_NOEXCEPT: super(v) {} - platform_atomic_integral(void) {} -}; - -template -class platform_atomic_integral : - public build_atomic_from_larger_type, T> -{ -public: - typedef build_atomic_from_larger_type, T> super; - BOOST_CONSTEXPR platform_atomic_integral(T v) BOOST_NOEXCEPT: super(v) {} - platform_atomic_integral(void) {} -}; - -template -class platform_atomic_integral : - public build_atomic_from_larger_type, T> -{ -public: - typedef build_atomic_from_larger_type, T> super; - BOOST_CONSTEXPR platform_atomic_integral(T v) BOOST_NOEXCEPT: super(v) {} - platform_atomic_integral(void) {} -}; - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-armv6plus.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-armv6plus.hpp deleted file mode 100644 index cccd1111..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-armv6plus.hpp +++ /dev/null @@ -1,255 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_ARMV6PLUS_HPP -#define BOOST_ATOMIC_DETAIL_GCC_ARMV6PLUS_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2009 Phil Endecott -// Copyright (c) 2013 Tim Blechmann -// ARM Code by Phil Endecott, based on other architectures. - -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -// From the ARM Architecture Reference Manual for architecture v6: -// -// LDREX{} , [] -// Specifies the destination register for the memory word addressed by -// Specifies the register containing the address. -// -// STREX{} , , [] -// Specifies the destination register for the returned status value. -// 0 if the operation updates memory -// 1 if the operation fails to update memory -// Specifies the register containing the word to be stored to memory. -// Specifies the register containing the address. -// Rd must not be the same register as Rm or Rn. -// -// ARM v7 is like ARM v6 plus: -// There are half-word and byte versions of the LDREX and STREX instructions, -// LDREXH, LDREXB, STREXH and STREXB. -// There are also double-word versions, LDREXD and STREXD. -// (Actually it looks like these are available from version 6k onwards.) -// FIXME these are not yet used; should be mostly a matter of copy-and-paste. -// I think you can supply an immediate offset to the address. -// -// A memory barrier is effected using a "co-processor 15" instruction, -// though a separate assembler mnemonic is available for it in v7. - -namespace boost { -namespace atomics { -namespace detail { - -// "Thumb 1" is a subset of the ARM instruction set that uses a 16-bit encoding. It -// doesn't include all instructions and in particular it doesn't include the co-processor -// instruction used for the memory barrier or the load-locked/store-conditional -// instructions. So, if we're compiling in "Thumb 1" mode, we need to wrap all of our -// asm blocks with code to temporarily change to ARM mode. -// -// You can only change between ARM and Thumb modes when branching using the bx instruction. -// bx takes an address specified in a register. The least significant bit of the address -// indicates the mode, so 1 is added to indicate that the destination code is Thumb. -// A temporary register is needed for the address and is passed as an argument to these -// macros. It must be one of the "low" registers accessible to Thumb code, specified -// using the "l" attribute in the asm statement. -// -// Architecture v7 introduces "Thumb 2", which does include (almost?) all of the ARM -// instruction set. So in v7 we don't need to change to ARM mode; we can write "universal -// assembler" which will assemble to Thumb 2 or ARM code as appropriate. The only thing -// we need to do to make this "universal" assembler mode work is to insert "IT" instructions -// to annotate the conditional instructions. These are ignored in other modes (e.g. v6), -// so they can always be present. - -#if defined(__thumb__) && !defined(__thumb2__) -#define BOOST_ATOMIC_ARM_ASM_START(TMPREG) "adr " #TMPREG ", 1f\n" "bx " #TMPREG "\n" ".arm\n" ".align 4\n" "1: " -#define BOOST_ATOMIC_ARM_ASM_END(TMPREG) "adr " #TMPREG ", 1f + 1\n" "bx " #TMPREG "\n" ".thumb\n" ".align 2\n" "1: " -#else -// The tmpreg is wasted in this case, which is non-optimal. -#define BOOST_ATOMIC_ARM_ASM_START(TMPREG) -#define BOOST_ATOMIC_ARM_ASM_END(TMPREG) -#endif - -#if defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) || defined(__ARM_ARCH_7EM__) || defined(__ARM_ARCH_7S__) -#define BOOST_ATOMIC_ARM_DMB "dmb\n" -#else -#define BOOST_ATOMIC_ARM_DMB "mcr\tp15, 0, r0, c7, c10, 5\n" -#endif - -inline void -arm_barrier(void) BOOST_NOEXCEPT -{ - int brtmp; - __asm__ __volatile__ - ( - BOOST_ATOMIC_ARM_ASM_START(%0) - BOOST_ATOMIC_ARM_DMB - BOOST_ATOMIC_ARM_ASM_END(%0) - : "=&l" (brtmp) :: "memory" - ); -} - -inline void -platform_fence_before(memory_order order) BOOST_NOEXCEPT -{ - switch(order) - { - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - arm_barrier(); - case memory_order_consume: - default:; - } -} - -inline void -platform_fence_after(memory_order order) BOOST_NOEXCEPT -{ - switch(order) - { - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - arm_barrier(); - default:; - } -} - -inline void -platform_fence_before_store(memory_order order) BOOST_NOEXCEPT -{ - platform_fence_before(order); -} - -inline void -platform_fence_after_store(memory_order order) BOOST_NOEXCEPT -{ - if (order == memory_order_seq_cst) - arm_barrier(); -} - -inline void -platform_fence_after_load(memory_order order) BOOST_NOEXCEPT -{ - platform_fence_after(order); -} - -template -inline bool -platform_cmpxchg32(T & expected, T desired, volatile T * ptr) BOOST_NOEXCEPT -{ - int success; - int tmp; - __asm__ __volatile__ - ( - BOOST_ATOMIC_ARM_ASM_START(%2) - "mov %1, #0\n" // success = 0 - "ldrex %0, %3\n" // expected' = *(&i) - "teq %0, %4\n" // flags = expected'==expected - "ittt eq\n" - "strexeq %2, %5, %3\n" // if (flags.equal) *(&i) = desired, tmp = !OK - "teqeq %2, #0\n" // if (flags.equal) flags = tmp==0 - "moveq %1, #1\n" // if (flags.equal) success = 1 - BOOST_ATOMIC_ARM_ASM_END(%2) - : "=&r" (expected), // %0 - "=&r" (success), // %1 - "=&l" (tmp), // %2 - "+Q" (*ptr) // %3 - : "r" (expected), // %4 - "r" (desired) // %5 - : "cc" - ); - return success; -} - -} -} - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) - { - case memory_order_acquire: - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - atomics::detail::arm_barrier(); - default:; - } -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -inline void -atomic_signal_fence(memory_order) -{ - __asm__ __volatile__ ("" ::: "memory"); -} - -class atomic_flag -{ -private: - uint32_t v_; - -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before_store(order); - const_cast(v_) = 0; - atomics::detail::platform_fence_after_store(order); - } - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - uint32_t expected = v_; - do { - if (expected == 1) - break; - } while (!atomics::detail::platform_cmpxchg32(expected, (uint32_t)1, &v_)); - atomics::detail::platform_fence_after(order); - return expected; - } - - BOOST_DELETED_FUNCTION(atomic_flag(const atomic_flag &)) - BOOST_DELETED_FUNCTION(atomic_flag& operator=(const atomic_flag &)) -}; - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -} - -#undef BOOST_ATOMIC_ARM_ASM_START -#undef BOOST_ATOMIC_ARM_ASM_END - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -#include - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-atomic.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-atomic.hpp deleted file mode 100644 index 2f645cdb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-atomic.hpp +++ /dev/null @@ -1,1211 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_ATOMIC_HPP -#define BOOST_ATOMIC_DETAIL_GCC_ATOMIC_HPP - -// Copyright (c) 2013 Andrey Semashev -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -#if (defined(__i386__) && defined(__SSE2__)) || defined(__x86_64__) -#define BOOST_ATOMIC_X86_PAUSE() __asm__ __volatile__ ("pause\n") -#endif - -#if defined(__i386__) && defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_8) -#define BOOST_ATOMIC_X86_HAS_CMPXCHG8B 1 -#endif - -#if defined(__x86_64__) && defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_16) -#define BOOST_ATOMIC_X86_HAS_CMPXCHG16B 1 -#endif - -BOOST_FORCEINLINE BOOST_CONSTEXPR int convert_memory_order_to_gcc(memory_order order) BOOST_NOEXCEPT -{ - return (order == memory_order_relaxed ? __ATOMIC_RELAXED : (order == memory_order_consume ? __ATOMIC_CONSUME : - (order == memory_order_acquire ? __ATOMIC_ACQUIRE : (order == memory_order_release ? __ATOMIC_RELEASE : - (order == memory_order_acq_rel ? __ATOMIC_ACQ_REL : __ATOMIC_SEQ_CST))))); -} - -} // namespace detail -} // namespace atomics - -#if __GCC_ATOMIC_BOOL_LOCK_FREE == 2 - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - bool v_; - -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(false) {} - - bool test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_test_and_set(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - void clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_clear((bool*)&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } -}; - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -#endif // __GCC_ATOMIC_BOOL_LOCK_FREE == 2 - -} // namespace boost - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#if __GCC_ATOMIC_CHAR_LOCK_FREE == 2 -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_CHAR16_T_LOCK_FREE == 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_CHAR32_T_LOCK_FREE == 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_WCHAR_T_LOCK_FREE == 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_SHORT_LOCK_FREE == 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_INT_LOCK_FREE == 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_LONG_LOCK_FREE == 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_LLONG_LOCK_FREE == 2 -#define BOOST_ATOMIC_LLONG_LOCK_FREE 2 -#endif -#if defined(BOOST_ATOMIC_X86_HAS_CMPXCHG16B) && (defined(BOOST_HAS_INT128) || !defined(BOOST_NO_ALIGNMENT)) -#define BOOST_ATOMIC_INT128_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_POINTER_LOCK_FREE == 2 -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#endif -#if __GCC_ATOMIC_BOOL_LOCK_FREE == 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 -#endif - -namespace boost { - -#define BOOST_ATOMIC_THREAD_FENCE 2 -BOOST_FORCEINLINE void atomic_thread_fence(memory_order order) -{ - __atomic_thread_fence(atomics::detail::convert_memory_order_to_gcc(order)); -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -BOOST_FORCEINLINE void atomic_signal_fence(memory_order order) -{ - __atomic_signal_fence(atomics::detail::convert_memory_order_to_gcc(order)); -} - -namespace atomics { -namespace detail { - -#if defined(BOOST_ATOMIC_CHAR_LOCK_FREE) && BOOST_ATOMIC_CHAR_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - value_type fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_and(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_or(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint8_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : - v_(reinterpret_cast(v)) - { - } - - void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store(&v_, (storage_type*)&v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __atomic_load(&v_, (storage_type*)&v, atomics::detail::convert_memory_order_to_gcc(order)); - return v; - } - - value_type exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type r; - __atomic_exchange(&v_, (storage_type*)&v, (storage_type*)&r, atomics::detail::convert_memory_order_to_gcc(order)); - return r; - } - - bool compare_exchange_strong( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange(&v_, (storage_type*)&expected, (storage_type*)&desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange(&v_, (storage_type*)&expected, (storage_type*)&desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif // defined(BOOST_ATOMIC_CHAR_LOCK_FREE) && BOOST_ATOMIC_CHAR_LOCK_FREE > 0 - -#if defined(BOOST_ATOMIC_SHORT_LOCK_FREE) && BOOST_ATOMIC_SHORT_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - value_type fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_and(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_or(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint16_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : - v_(reinterpret_cast(v)) - { - } - - void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store(&v_, (storage_type*)&v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __atomic_load(&v_, (storage_type*)&v, atomics::detail::convert_memory_order_to_gcc(order)); - return v; - } - - value_type exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type r; - __atomic_exchange(&v_, (storage_type*)&v, (storage_type*)&r, atomics::detail::convert_memory_order_to_gcc(order)); - return r; - } - - bool compare_exchange_strong( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange(&v_, (storage_type*)&expected, (storage_type*)&desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange(&v_, (storage_type*)&expected, (storage_type*)&desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif // defined(BOOST_ATOMIC_SHORT_LOCK_FREE) && BOOST_ATOMIC_SHORT_LOCK_FREE > 0 - -#if defined(BOOST_ATOMIC_INT_LOCK_FREE) && BOOST_ATOMIC_INT_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - value_type fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_and(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_or(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - __atomic_store_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - tmp = __atomic_exchange_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool compare_exchange_strong( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool compare_exchange_weak( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif // defined(BOOST_ATOMIC_INT_LOCK_FREE) && BOOST_ATOMIC_INT_LOCK_FREE > 0 - -#if defined(BOOST_ATOMIC_LLONG_LOCK_FREE) && BOOST_ATOMIC_LLONG_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - value_type fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_and(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_or(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint64_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - __atomic_store_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - tmp = __atomic_exchange_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool compare_exchange_strong( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool compare_exchange_weak( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif // defined(BOOST_ATOMIC_LLONG_LOCK_FREE) && BOOST_ATOMIC_LLONG_LOCK_FREE > 0 - -#if defined(BOOST_ATOMIC_INT128_LOCK_FREE) && BOOST_ATOMIC_INT128_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - value_type fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_and(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_or(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#if defined(BOOST_HAS_INT128) - -typedef boost::uint128_type storage128_type; - -#else // defined(BOOST_HAS_INT128) - -struct BOOST_ALIGNMENT(16) storage128_type -{ - uint64_t data[2]; -}; - -inline bool operator== (storage128_type const& left, storage128_type const& right) -{ - return left.data[0] == right.data[0] && left.data[1] == right.data[1]; -} -inline bool operator!= (storage128_type const& left, storage128_type const& right) -{ - return !(left == right); -} - -#endif // defined(BOOST_HAS_INT128) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef storage128_type storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT - { - memset(&v_, 0, sizeof(v_)); - memcpy(&v_, &v, sizeof(value_type)); - } - - void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp; - memset(&tmp, 0, sizeof(tmp)); - memcpy(&tmp, &v, sizeof(value_type)); - __atomic_store_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp; - memset(&tmp, 0, sizeof(tmp)); - memcpy(&tmp, &v, sizeof(value_type)); - tmp = __atomic_exchange_n(&v_, tmp, atomics::detail::convert_memory_order_to_gcc(order)); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool compare_exchange_strong( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memset(&expected_s, 0, sizeof(expected_s)); - memset(&desired_s, 0, sizeof(desired_s)); - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool compare_exchange_weak( - value_type& expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memset(&expected_s, 0, sizeof(expected_s)); - memset(&desired_s, 0, sizeof(desired_s)); - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - const bool success = __atomic_compare_exchange_n(&v_, &expected_s, desired_s, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif // defined(BOOST_ATOMIC_INT128_LOCK_FREE) && BOOST_ATOMIC_INT128_LOCK_FREE > 0 - - -/* pointers */ - -#if defined(BOOST_ATOMIC_POINTER_LOCK_FREE) && BOOST_ATOMIC_POINTER_LOCK_FREE > 0 - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T* value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v * sizeof(T), atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v * sizeof(T), atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef void* value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - __atomic_store_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - return __atomic_load_n(&v_, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_add(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_fetch_sub(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return __atomic_exchange_n(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); - } - - bool compare_exchange_strong( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, false, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool compare_exchange_weak( - value_type& expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return __atomic_compare_exchange_n(&v_, &expected, desired, true, - atomics::detail::convert_memory_order_to_gcc(success_order), - atomics::detail::convert_memory_order_to_gcc(failure_order)); - } - - bool is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return __atomic_is_lock_free(sizeof(v_), &v_); - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#endif // defined(BOOST_ATOMIC_POINTER_LOCK_FREE) && BOOST_ATOMIC_POINTER_LOCK_FREE > 0 - -} // namespace detail -} // namespace atomics -} // namespace boost - -#endif // !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#endif // BOOST_ATOMIC_DETAIL_GCC_ATOMIC_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-cas.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-cas.hpp deleted file mode 100644 index 25626bd5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-cas.hpp +++ /dev/null @@ -1,160 +0,0 @@ -// Copyright (c) 2011 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Use the gnu builtin __sync_val_compare_and_swap to build -// atomic operations for 32 bit and smaller. - -#ifndef BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP -#define BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP - -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - break; - case memory_order_release: - case memory_order_consume: - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - __sync_synchronize(); - break; - } -} - -namespace atomics { -namespace detail { - -inline void -platform_fence_before(memory_order) -{ - /* empty, as compare_and_swap is synchronizing already */ -} - -inline void -platform_fence_after(memory_order) -{ - /* empty, as compare_and_swap is synchronizing already */ -} - -inline void -platform_fence_before_store(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_acquire: - case memory_order_consume: - break; - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - __sync_synchronize(); - break; - } -} - -inline void -platform_fence_after_store(memory_order order) -{ - if (order == memory_order_seq_cst) - __sync_synchronize(); -} - -inline void -platform_fence_after_load(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_release: - break; - case memory_order_consume: - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - __sync_synchronize(); - break; - } -} - -template -inline bool -platform_cmpxchg32_strong(T & expected, T desired, volatile T * ptr) -{ - T found = __sync_val_compare_and_swap(ptr, expected, desired); - bool success = (found == expected); - expected = found; - return success; -} - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before_store(order); - const_cast(v_) = 0; - atomics::detail::platform_fence_after_store(order); - } - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - uint32_t expected = v_; - do { - if (expected == 1) - break; - } while (!atomics::detail::platform_cmpxchg32(expected, (uint32_t)1, &v_)); - atomics::detail::platform_fence_after(order); - return expected; - } -}; - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -} -} -} - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE (sizeof(long) <= 4 ? 2 : 0) -#define BOOST_ATOMIC_LLONG_LOCK_FREE (sizeof(long long) <= 4 ? 2 : 0) -#define BOOST_ATOMIC_POINTER_LOCK_FREE (sizeof(void *) <= 4 ? 2 : 0) -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -#include - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-ppc.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-ppc.hpp deleted file mode 100644 index e6735dab..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-ppc.hpp +++ /dev/null @@ -1,2952 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_PPC_HPP -#define BOOST_ATOMIC_DETAIL_GCC_PPC_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -/* - Refer to: Motorola: "Programming Environments Manual for 32-Bit - Implementations of the PowerPC Architecture", Appendix E: - "Synchronization Programming Examples" for an explanation of what is - going on here (can be found on the web at various places by the - name "MPCFPE32B.pdf", Google is your friend...) - - Most of the atomic operations map to instructions in a relatively - straight-forward fashion, but "load"s may at first glance appear - a bit strange as they map to: - - lwz %rX, addr - cmpw %rX, %rX - bne- 1f - 1: - - That is, the CPU is forced to perform a branch that "formally" depends - on the value retrieved from memory. This scheme has an overhead of - about 1-2 clock cycles per load, but it allows to map "acquire" to - the "isync" instruction instead of "sync" uniformly and for all type - of atomic operations. Since "isync" has a cost of about 15 clock - cycles, while "sync" hast a cost of about 50 clock cycles, the small - penalty to atomic loads more than compensates for this. - - Byte- and halfword-sized atomic values are realized by encoding the - value to be represented into a word, performing sign/zero extension - as appropriate. This means that after add/sub operations the value - needs fixing up to accurately preserve the wrap-around semantic of - the smaller type. (Nothing special needs to be done for the bit-wise - and the "exchange type" operators as the compiler already sees to - it that values carried in registers are extended appropriately and - everything falls into place naturally). - - The register constraint "b" instructs gcc to use any register - except r0; this is sometimes required because the encoding for - r0 is used to signify "constant zero" in a number of instructions, - making r0 unusable in this place. For simplicity this constraint - is used everywhere since I am to lazy to look this up on a - per-instruction basis, and ppc has enough registers for this not - to pose a problem. -*/ - -namespace boost { -namespace atomics { -namespace detail { - -inline void -ppc_fence_before(memory_order order) -{ - switch(order) - { - case memory_order_release: - case memory_order_acq_rel: -#if defined(__powerpc64__) - __asm__ __volatile__ ("lwsync" ::: "memory"); - break; -#endif - case memory_order_seq_cst: - __asm__ __volatile__ ("sync" ::: "memory"); - default:; - } -} - -inline void -ppc_fence_after(memory_order order) -{ - switch(order) - { - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("isync"); - case memory_order_consume: - __asm__ __volatile__ ("" ::: "memory"); - default:; - } -} - -inline void -ppc_fence_after_store(memory_order order) -{ - switch(order) - { - case memory_order_seq_cst: - __asm__ __volatile__ ("sync"); - default:; - } -} - -} -} - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::ppc_fence_before(order); - const_cast(v_) = 0; - atomics::detail::ppc_fence_after_store(order); - } - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - uint32_t original; - atomics::detail::ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (1) - : "cr0" - ); - atomics::detail::ppc_fence_after(order); - return original; - } -}; - -} /* namespace boost */ - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#if defined(__powerpc64__) -#define BOOST_ATOMIC_LLONG_LOCK_FREE 2 -#else -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#endif -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -/* Would like to move the slow-path of failed compare_exchange -(that clears the "success" bit) out-of-line. gcc can in -principle do that using ".subsection"/".previous", but Apple's -binutils seemingly does not understand that. Therefore wrap -the "clear" of the flag in a macro and let it remain -in-line for Apple -*/ - -#if !defined(__APPLE__) - -#define BOOST_ATOMIC_ASM_SLOWPATH_CLEAR \ - "9:\n" \ - ".subsection 2\n" \ - "2: addi %1,0,0\n" \ - "b 9b\n" \ - ".previous\n" \ - -#else - -#define BOOST_ATOMIC_ASM_SLOWPATH_CLEAR \ - "b 9f\n" \ - "2: addi %1,0,0\n" \ - "9:\n" \ - -#endif - -namespace boost { -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef int32_t storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m"(v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=&r" (v) - : "m" (v_) - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "extsb %1, %1\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "extsb %1, %1\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "and %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "or %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "xor %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m"(v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=&r" (v) - : "m" (v_) - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "rlwinm %1, %1, 0, 0xff\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "rlwinm %1, %1, 0, 0xff\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "and %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "or %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "xor %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef int32_t storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m"(v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=&r" (v) - : "m" (v_) - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "extsh %1, %1\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "extsh %1, %1\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "and %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "or %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "xor %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m"(v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=&r" (v) - : "m" (v_) - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "rlwinm %1, %1, 0, 0xffff\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "rlwinm %1, %1, 0, 0xffff\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "and %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "or %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "xor %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - const_cast(v_) = v; - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - __asm__ __volatile__ ( - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "+b"(v) - : - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "and %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "or %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "xor %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#if defined(__powerpc64__) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - const_cast(v_) = v; - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - __asm__ __volatile__ ( - "cmpd %0, %0\n" - "bne- 1f\n" - "1:\n" - : "+b"(v) - : - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y1\n" - "stdcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "add %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "sub %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "and %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "or %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "xor %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#endif - -/* pointer types */ - -#if !defined(__powerpc64__) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m" (v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(v) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m" (v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(v) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "add %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y2\n" - "sub %1,%0,%3\n" - "stwcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#else - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "std %1, %0\n" - : "+m" (v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ ( - "ld %0, %1\n" - "cmpd %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(v) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y1\n" - "stdcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "add %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "sub %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - ppc_fence_before(order); - __asm__ ( - "std %1, %0\n" - : "+m" (v_) - : "r" (v) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v; - __asm__ ( - "ld %0, %1\n" - "cmpd %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(v) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type original; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y1\n" - "stdcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (v) - : "cr0" - ); - ppc_fence_after(order); - return original; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - int success; - ppc_fence_before(success_order); - __asm__( - "0: ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected), "=&b" (success), "+Z"(v_) - : "b" (expected), "b" (desired) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - return success; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "add %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - value_type original, tmp; - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y2\n" - "sub %1,%0,%3\n" - "stdcx. %1,%y2\n" - "bne- 1b\n" - : "=&b" (original), "=&b" (tmp), "+Z"(v_) - : "b" (v) - : "cc"); - ppc_fence_after(order); - return original; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#endif - -/* generic */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m" (v_) - : "r" (tmp) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(tmp) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0, original; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (tmp) - : "cr0" - ); - ppc_fence_after(order); - value_type res; - memcpy(&res, &original, sizeof(value_type)); - return res; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m" (v_) - : "r" (tmp) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(tmp) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0, original; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (tmp) - : "cr0" - ); - ppc_fence_after(order); - value_type res; - memcpy(&res, &original, sizeof(value_type)); - return res; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "stw %1, %0\n" - : "+m" (v_) - : "r" (tmp) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp; - __asm__ __volatile__ ( - "lwz %0, %1\n" - "cmpw %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(tmp) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0, original; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "1:\n" - "lwarx %0,%y1\n" - "stwcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (tmp) - : "cr0" - ); - ppc_fence_after(order); - value_type res; - memcpy(&res, &original, sizeof(value_type)); - return res; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "0: lwarx %0,%y2\n" - "cmpw %0, %3\n" - "bne- 2f\n" - "stwcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#if defined(__powerpc64__) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint64_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "std %1, %0\n" - : "+m" (v_) - : "r" (tmp) - ); - ppc_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp; - __asm__ __volatile__ ( - "ld %0, %1\n" - "cmpd %0, %0\n" - "bne- 1f\n" - "1:\n" - : "=r"(tmp) - : "m"(v_) - : "cr0" - ); - ppc_fence_after(order); - - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0, original; - memcpy(&tmp, &v, sizeof(value_type)); - ppc_fence_before(order); - __asm__ ( - "1:\n" - "ldarx %0,%y1\n" - "stdcx. %2,%y1\n" - "bne- 1b\n" - : "=&b" (original), "+Z"(v_) - : "b" (tmp) - : "cr0" - ); - ppc_fence_after(order); - value_type res; - memcpy(&res, &original, sizeof(value_type)); - return res; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 2f\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - - int success; - ppc_fence_before(success_order); - __asm__( - "0: ldarx %0,%y2\n" - "cmpd %0, %3\n" - "bne- 2f\n" - "stdcx. %4,%y2\n" - "bne- 0b\n" - "addi %1,0,1\n" - "1:" - - BOOST_ATOMIC_ASM_SLOWPATH_CLEAR - : "=&b" (expected_s), "=&b" (success), "+Z"(v_) - : "b" (expected_s), "b" (desired_s) - : "cr0" - ); - if (success) - ppc_fence_after(success_order); - else - ppc_fence_after(failure_order); - memcpy(&expected, &expected_s, sizeof(value_type)); - return success; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif - -} -} - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) - { - case memory_order_acquire: - __asm__ __volatile__ ("isync" ::: "memory"); - break; - case memory_order_release: -#if defined(__powerpc64__) - __asm__ __volatile__ ("lwsync" ::: "memory"); - break; -#endif - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("sync" ::: "memory"); - default:; - } -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -inline void -atomic_signal_fence(memory_order order) -{ - switch(order) - { - case memory_order_acquire: - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - break; - default:; - } -} - -} - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-sparcv9.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-sparcv9.hpp deleted file mode 100644 index b3fc7e6a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-sparcv9.hpp +++ /dev/null @@ -1,1333 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_SPARC_HPP -#define BOOST_ATOMIC_DETAIL_GCC_SPARC_HPP - -// Copyright (c) 2010 Helge Bahmann -// Copyright (c) 2013 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -inline void -platform_fence_before(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_acquire: - case memory_order_consume: - break; - case memory_order_release: - case memory_order_acq_rel: - __asm__ __volatile__ ("membar #StoreStore | #LoadStore" ::: "memory"); - /* release */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("membar #Sync" ::: "memory"); - /* seq */ - break; - } -} - -inline void -platform_fence_after(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_release: - break; - case memory_order_acquire: - case memory_order_acq_rel: - __asm__ __volatile__ ("membar #LoadLoad | #LoadStore" ::: "memory"); - /* acquire */ - break; - case memory_order_consume: - /* consume */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("membar #Sync" ::: "memory"); - /* seq */ - break; - default:; - } -} - -inline void -platform_fence_after_store(memory_order order) -{ - switch(order) - { - case memory_order_seq_cst: - __asm__ __volatile__ ("membar #Sync" ::: "memory"); - default:; - } -} - - -inline void -platform_fence_after_load(memory_order order) -{ - platform_fence_after(order); -} - -} -} - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - const_cast(v_) = 0; - atomics::detail::platform_fence_after_store(order); - } - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - uint32_t tmp = 1; - __asm__ ( - "cas [%1], %2, %0" - : "+r" (tmp) - : "r" (&v_), "r" (0) - : "memory" - ); - atomics::detail::platform_fence_after(order); - return tmp; - } -}; - -} /* namespace boost */ - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -namespace boost { - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - break; - case memory_order_release: - __asm__ __volatile__ ("membar #StoreStore | #LoadStore" ::: "memory"); - break; - case memory_order_acquire: - __asm__ __volatile__ ("membar #LoadLoad | #LoadStore" ::: "memory"); - break; - case memory_order_acq_rel: - __asm__ __volatile__ ("membar #LoadLoad | #LoadStore | #StoreStore" ::: "memory"); - break; - case memory_order_consume: - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("membar #Sync" ::: "memory"); - break; - default:; - } -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -inline void -atomic_signal_fence(memory_order) -{ - __asm__ __volatile__ ("" ::: "memory"); -} - -namespace atomics { -namespace detail { - -/* integral types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef int32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - storage_type desired_s = desired; - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" ((storage_type)expected) - : "memory" - ); - desired = desired_s; - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - storage_type desired_s = desired; - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" ((storage_type)expected) - : "memory" - ); - desired = desired_s; - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef int32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - storage_type desired_s = desired; - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" ((storage_type)expected) - : "memory" - ); - desired = desired_s; - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - typedef uint32_t storage_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - storage_type desired_s = desired; - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" ((storage_type)expected) - : "memory" - ); - desired = desired_s; - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired) - : "r" (&v_), "r" (expected) - : "memory" - ); - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* pointer types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired) - : "r" (&v_), "r" (expected) - : "memory" - ); - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - - bool compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, (char*)tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, (char*)tmp - v, order, memory_order_relaxed)); - return tmp; - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - const_cast(v_) = v; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired) - : "r" (&v_), "r" (expected) - : "memory" - ); - bool success = (desired == expected); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = desired; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp + v, order, memory_order_relaxed)); - return tmp; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, tmp - v, order, memory_order_relaxed)); - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -/* generic types */ - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" (expected_s) - : "memory" - ); - bool success = (desired_s == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &desired_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" (expected_s) - : "memory" - ); - bool success = (desired_s == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &desired_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - platform_fence_after_store(order); - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - do {} while(!compare_exchange_weak(tmp, v, order, memory_order_relaxed)); - return tmp; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); - __asm__ ( - "cas [%1], %2, %0" - : "+r" (desired_s) - : "r" (&v_), "r" (expected_s) - : "memory" - ); - bool success = (desired_s == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &desired_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-x86.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-x86.hpp deleted file mode 100644 index 284478de..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/gcc-x86.hpp +++ /dev/null @@ -1,2017 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GCC_X86_HPP -#define BOOST_ATOMIC_DETAIL_GCC_X86_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2012 Tim Blechmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -#if defined(__x86_64__) || defined(__SSE2__) -# define BOOST_ATOMIC_X86_FENCE_INSTR "mfence\n" -#else -# define BOOST_ATOMIC_X86_FENCE_INSTR "lock ; addl $0, (%%esp)\n" -#endif - -#define BOOST_ATOMIC_X86_PAUSE() __asm__ __volatile__ ("pause\n") - -#if defined(__i386__) &&\ - (\ - defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_8) ||\ - defined(__i586__) || defined(__i686__) || defined(__pentium4__) || defined(__nocona__) || defined(__core2__) || defined(__corei7__) ||\ - defined(__k6__) || defined(__athlon__) || defined(__k8__) || defined(__amdfam10__) || defined(__bdver1__) || defined(__bdver2__) || defined(__bdver3__) || defined(__btver1__) || defined(__btver2__)\ - ) -#define BOOST_ATOMIC_X86_HAS_CMPXCHG8B 1 -#endif - -#if defined(__x86_64__) && defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_16) -#define BOOST_ATOMIC_X86_HAS_CMPXCHG16B 1 -#endif - -inline void -platform_fence_before(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_acquire: - case memory_order_consume: - break; - case memory_order_release: - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - /* release */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - /* seq */ - break; - default:; - } -} - -inline void -platform_fence_after(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_release: - break; - case memory_order_acquire: - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - /* acquire */ - break; - case memory_order_consume: - /* consume */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - /* seq */ - break; - default:; - } -} - -inline void -platform_fence_after_load(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_release: - break; - case memory_order_acquire: - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - break; - case memory_order_consume: - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - break; - default:; - } -} - -inline void -platform_fence_before_store(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_acquire: - case memory_order_consume: - break; - case memory_order_release: - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - /* release */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - /* seq */ - break; - default:; - } -} - -inline void -platform_fence_after_store(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - case memory_order_release: - break; - case memory_order_acquire: - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - /* acquire */ - break; - case memory_order_consume: - /* consume */ - break; - case memory_order_seq_cst: - __asm__ __volatile__ ("" ::: "memory"); - /* seq */ - break; - default:; - } -} - -} -} - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - uint32_t v = 1; - atomics::detail::platform_fence_before(order); - __asm__ __volatile__ ( - "xchgl %0, %1" - : "+r" (v), "+m" (v_) - ); - atomics::detail::platform_fence_after(order); - return v; - } - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order == memory_order_seq_cst) { - uint32_t v = 0; - __asm__ __volatile__ ( - "xchgl %0, %1" - : "+r" (v), "+m" (v_) - ); - } else { - atomics::detail::platform_fence_before(order); - v_ = 0; - } - } -}; - -} /* namespace boost */ - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 - -#if defined(__x86_64__) || defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) -#define BOOST_ATOMIC_LLONG_LOCK_FREE 2 -#endif - -#if defined(BOOST_ATOMIC_X86_HAS_CMPXCHG16B) && (defined(BOOST_HAS_INT128) || !defined(BOOST_NO_ALIGNMENT)) -#define BOOST_ATOMIC_INT128_LOCK_FREE 2 -#endif - -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -namespace boost { - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) - { - case memory_order_relaxed: - break; - case memory_order_release: - __asm__ __volatile__ ("" ::: "memory"); - break; - case memory_order_acquire: - __asm__ __volatile__ ("" ::: "memory"); - break; - case memory_order_acq_rel: - __asm__ __volatile__ ("" ::: "memory"); - break; - case memory_order_consume: - break; - case memory_order_seq_cst: - __asm__ __volatile__ (BOOST_ATOMIC_X86_FENCE_INSTR ::: "memory"); - break; - default:; - } -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -inline void -atomic_signal_fence(memory_order) -{ - __asm__ __volatile__ ("" ::: "memory"); -} - -namespace atomics { -namespace detail { - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddb %0, %1" - : "+q" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgb %0, %1" - : "+q" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgb %3, %1\n\t" - "sete %2" - : "+a" (previous), "+m" (v_), "=q" (success) - : "q" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddw %0, %1" - : "+q" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgw %0, %1" - : "+q" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgw %3, %1\n\t" - "sete %2" - : "+a" (previous), "+m" (v_), "=q" (success) - : "q" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddl %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgl %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgl %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#if defined(__x86_64__) -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddq %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgq %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgq %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - value_type tmp = load(memory_order_relaxed); - while (!compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed)) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#endif - -/* pointers */ - -// NOTE: x32 target is still regarded to as x86_64 and can only be detected by the size of pointers -#if !defined(__x86_64__) || (defined(__SIZEOF_POINTER__) && __SIZEOF_POINTER__ == 4) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgl %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool compare_exchange_strong(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgl %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddl %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return reinterpret_cast(v); - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgl %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgl %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddl %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return reinterpret_cast(v); - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#else - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void * value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgq %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool compare_exchange_strong(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgq %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddq %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return reinterpret_cast(v); - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T * value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT : v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgq %0, %1" - : "+r" (v), "+m" (v_) - ); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgq %3, %1\n\t" - "sete %2" - : "+a,a" (previous), "+m,m" (v_), "=q,m" (success) - : "r,r" (desired) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = previous; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - platform_fence_before(order); - __asm__ __volatile__ - ( - "lock ; xaddq %0, %1" - : "+r" (v), "+m" (v_) - : - : "cc" - ); - platform_fence_after(order); - return reinterpret_cast(v); - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -#endif - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint8_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : - v_(reinterpret_cast(v)) - { - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgb %0, %1" - : "+q" (tmp), "+m" (v_) - ); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - storage_type previous_s = expected_s; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgb %3, %1\n\t" - "sete %2" - : "+a" (previous_s), "+m" (v_), "=q" (success) - : "q" (desired_s) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &previous_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint16_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : - v_(reinterpret_cast(v)) - { - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgw %0, %1" - : "+q" (tmp), "+m" (v_) - ); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s, desired_s; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - storage_type previous_s = expected_s; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgw %3, %1\n\t" - "sete %2" - : "+a" (previous_s), "+m" (v_), "=q" (success) - : "q" (desired_s) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &previous_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgl %0, %1" - : "+q" (tmp), "+m" (v_) - ); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - storage_type previous_s = expected_s; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgl %3, %1\n\t" - "sete %2" - : "+a,a" (previous_s), "+m,m" (v_), "=q,m" (success) - : "q,q" (desired_s) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &previous_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#if defined(__x86_64__) -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint64_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - __asm__ __volatile__ - ( - "xchgq %0, %1" - : "+q" (tmp), "+m" (v_) - ); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - storage_type previous_s = expected_s; - platform_fence_before(success_order); - bool success; - __asm__ __volatile__ - ( - "lock ; cmpxchgq %3, %1\n\t" - "sete %2" - : "+a,a" (previous_s), "+m,m" (v_), "=q,m" (success) - : "q,q" (desired_s) - : "cc" - ); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &previous_s, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; -#endif - -#if !defined(__x86_64__) && defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) - -template -inline bool -platform_cmpxchg64_strong(T & expected, T desired, volatile T * ptr) BOOST_NOEXCEPT -{ -#ifdef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 - const T oldval = __sync_val_compare_and_swap(ptr, expected, desired); - const bool result = (oldval == expected); - expected = oldval; - return result; -#else - uint32_t scratch; - /* Make sure ebx is saved and restored properly in case - this object is compiled as "position independent". Since - programmers on x86 tend to forget specifying -DPIC or - similar, always assume PIC. - - To make this work uniformly even in the non-PIC case, - setup register constraints such that ebx can not be - used by accident e.g. as base address for the variable - to be modified. Accessing "scratch" should always be okay, - as it can only be placed on the stack (and therefore - accessed through ebp or esp only). - - In theory, could push/pop ebx onto/off the stack, but movs - to a prepared stack slot turn out to be faster. */ - bool success; - __asm__ __volatile__ - ( - "movl %%ebx, %[scratch]\n\t" - "movl %[desired_lo], %%ebx\n\t" - "lock; cmpxchg8b %[dest]\n\t" - "movl %[scratch], %%ebx\n\t" - "sete %[success]" - : "+A,A,A,A,A,A" (expected), [dest] "+m,m,m,m,m,m" (*ptr), [scratch] "=m,m,m,m,m,m" (scratch), [success] "=q,m,q,m,q,m" (success) - : [desired_lo] "S,S,D,D,m,m" ((uint32_t)desired), "c,c,c,c,c,c" ((uint32_t)(desired >> 32)) - : "memory", "cc" - ); - return success; -#endif -} - -// Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 3A, 8.1.1. Guaranteed Atomic Operations: -// -// The Pentium processor (and newer processors since) guarantees that the following additional memory operations will always be carried out atomically: -// * Reading or writing a quadword aligned on a 64-bit boundary -// -// Luckily, the memory is almost always 8-byte aligned in our case because atomic<> uses 64 bit native types for storage and dynamic memory allocations -// have at least 8 byte alignment. The only unfortunate case is when atomic is placeod on the stack and it is not 8-byte aligned (like on 32 bit Windows). - -template -inline void -platform_store64(T value, volatile T * ptr) BOOST_NOEXCEPT -{ - if (((uint32_t)ptr & 0x00000007) == 0) - { -#if defined(__SSE2__) - __asm__ __volatile__ - ( - "movq %1, %%xmm4\n\t" - "movq %%xmm4, %0\n\t" - : "=m" (*ptr) - : "m" (value) - : "memory", "xmm4" - ); -#else - __asm__ __volatile__ - ( - "fildll %1\n\t" - "fistpll %0\n\t" - : "=m" (*ptr) - : "m" (value) - : "memory" - ); -#endif - } - else - { - uint32_t scratch; - __asm__ __volatile__ - ( - "movl %%ebx, %[scratch]\n\t" - "movl %[value_lo], %%ebx\n\t" - "movl 0(%[dest]), %%eax\n\t" - "movl 4(%[dest]), %%edx\n\t" - ".align 16\n\t" - "1: lock; cmpxchg8b 0(%[dest])\n\t" - "jne 1b\n\t" - "movl %[scratch], %%ebx" - : [scratch] "=m,m" (scratch) - : [value_lo] "a,a" ((uint32_t)value), "c,c" ((uint32_t)(value >> 32)), [dest] "D,S" (ptr) - : "memory", "cc", "edx" - ); - } -} - -template -inline T -platform_load64(const volatile T * ptr) BOOST_NOEXCEPT -{ - T value; - - if (((uint32_t)ptr & 0x00000007) == 0) - { -#if defined(__SSE2__) - __asm__ __volatile__ - ( - "movq %1, %%xmm4\n\t" - "movq %%xmm4, %0\n\t" - : "=m" (value) - : "m" (*ptr) - : "memory", "xmm4" - ); -#else - __asm__ __volatile__ - ( - "fildll %1\n\t" - "fistpll %0\n\t" - : "=m" (value) - : "m" (*ptr) - : "memory" - ); -#endif - } - else - { - // We don't care for comparison result here; the previous value will be stored into value anyway. - // Also we don't care for ebx and ecx values, they just have to be equal to eax and edx before cmpxchg8b. - __asm__ __volatile__ - ( - "movl %%ebx, %%eax\n\t" - "movl %%ecx, %%edx\n\t" - "lock; cmpxchg8b %[dest]" - : "=&A" (value) - : [dest] "m" (*ptr) - : "cc" - ); - } - - return value; -} - -#endif - -#if defined(BOOST_ATOMIC_INT128_LOCK_FREE) && BOOST_ATOMIC_INT128_LOCK_FREE > 0 - -template -inline bool -platform_cmpxchg128_strong(T& expected, T desired, volatile T* ptr) BOOST_NOEXCEPT -{ - uint64_t const* p_desired = (uint64_t const*)&desired; - bool success; - __asm__ __volatile__ - ( - "lock; cmpxchg16b %[dest]\n\t" - "sete %[success]" - : "+A,A" (expected), [dest] "+m,m" (*ptr), [success] "=q,m" (success) - : "b,b" (p_desired[0]), "c,c" (p_desired[1]) - : "memory", "cc" - ); - return success; -} - -template -inline void -platform_store128(T value, volatile T* ptr) BOOST_NOEXCEPT -{ - uint64_t const* p_value = (uint64_t const*)&value; - __asm__ __volatile__ - ( - "movq 0(%[dest]), %%rax\n\t" - "movq 8(%[dest]), %%rdx\n\t" - ".align 16\n\t" - "1: lock; cmpxchg16b 0(%[dest])\n\t" - "jne 1b" - : - : "b" (p_value[0]), "c" (p_value[1]), [dest] "r" (ptr) - : "memory", "cc", "rax", "rdx" - ); -} - -template -inline T -platform_load128(const volatile T* ptr) BOOST_NOEXCEPT -{ - T value; - - // We don't care for comparison result here; the previous value will be stored into value anyway. - // Also we don't care for rbx and rcx values, they just have to be equal to rax and rdx before cmpxchg16b. - __asm__ __volatile__ - ( - "movq %%rbx, %%rax\n\t" - "movq %%rcx, %%rdx\n\t" - "lock; cmpxchg16b %[dest]" - : "=&A" (value) - : [dest] "m" (*ptr) - : "cc" - ); - - return value; -} - -#endif // defined(BOOST_ATOMIC_INT128_LOCK_FREE) && BOOST_ATOMIC_INT128_LOCK_FREE > 0 - -} -} -} - -/* pull in 64-bit atomic type using cmpxchg8b above */ -#if !defined(__x86_64__) && defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) -#include -#endif - -/* pull in 128-bit atomic type using cmpxchg16b above */ -#if defined(BOOST_ATOMIC_INT128_LOCK_FREE) && BOOST_ATOMIC_INT128_LOCK_FREE > 0 -#include -#endif - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/generic-cas.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/generic-cas.hpp deleted file mode 100644 index cf4a3d79..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/generic-cas.hpp +++ /dev/null @@ -1,206 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP -#define BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP - -// Copyright (c) 2009 Helge Bahmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -/* fallback implementation for various compilation targets; -this is *not* efficient, particularly because all operations -are fully fenced (full memory barriers before and after -each operation) */ - -#if defined(__GNUC__) - namespace boost { namespace atomics { namespace detail { - inline int32_t - fenced_compare_exchange_strong_32(volatile int32_t *ptr, int32_t expected, int32_t desired) - { - return __sync_val_compare_and_swap_4(ptr, expected, desired); - } - #define BOOST_ATOMIC_HAVE_CAS32 1 - - #if defined(__amd64__) || defined(__i686__) - inline int64_t - fenced_compare_exchange_strong_64(int64_t *ptr, int64_t expected, int64_t desired) - { - return __sync_val_compare_and_swap_8(ptr, expected, desired); - } - #define BOOST_ATOMIC_HAVE_CAS64 1 - #endif - }}} - -#elif defined(__ICL) || defined(_MSC_VER) - - #if defined(_MSC_VER) - #include - #include - #endif - - namespace boost { namespace atomics { namespace detail { - inline int32_t - fenced_compare_exchange_strong(int32_t *ptr, int32_t expected, int32_t desired) - { - return _InterlockedCompareExchange(reinterpret_cast(ptr), desired, expected); - } - #define BOOST_ATOMIC_HAVE_CAS32 1 - #if defined(_WIN64) - inline int64_t - fenced_compare_exchange_strong(int64_t *ptr, int64_t expected, int64_t desired) - { - return _InterlockedCompareExchange64(ptr, desired, expected); - } - #define BOOST_ATOMIC_HAVE_CAS64 1 - #endif - }}} - -#elif (defined(__ICC) || defined(__ECC)) - namespace boost { namespace atomics { namespace detail { - inline int32_t - fenced_compare_exchange_strong_32(int32_t *ptr, int32_t expected, int32_t desired) - { - return _InterlockedCompareExchange((void*)ptr, desired, expected); - } - #define BOOST_ATOMIC_HAVE_CAS32 1 - #if defined(__x86_64) - inline int64_t - fenced_compare_exchange_strong(int64_t *ptr, int64_t expected, int64_t desired) - { - return cas64(ptr, expected, desired); - } - #define BOOST_ATOMIC_HAVE_CAS64 1 - #elif defined(__ECC) //IA-64 version - inline int64_t - fenced_compare_exchange_strong(int64_t *ptr, int64_t expected, int64_t desired) - { - return _InterlockedCompareExchange64((void*)ptr, desired, expected); - } - #define BOOST_ATOMIC_HAVE_CAS64 1 - #endif - }}} - -#elif (defined(__SUNPRO_CC) && defined(__sparc)) - #include - namespace boost { namespace atomics { namespace detail { - inline int32_t - fenced_compare_exchange_strong_32(int32_t *ptr, int32_t expected, int32_t desired) - { - return atomic_cas_32((volatile unsigned int*)ptr, expected, desired); - } - #define BOOST_ATOMIC_HAVE_CAS32 1 - - /* FIXME: check for 64 bit mode */ - inline int64_t - fenced_compare_exchange_strong_64(int64_t *ptr, int64_t expected, int64_t desired) - { - return atomic_cas_64((volatile unsigned long long*)ptr, expected, desired); - } - #define BOOST_ATOMIC_HAVE_CAS64 1 - }}} -#endif - - -namespace boost { -namespace atomics { -namespace detail { - -#ifdef BOOST_ATOMIC_HAVE_CAS32 -template -class atomic_generic_cas32 -{ -private: - typedef atomic_generic_cas32 this_type; -public: - explicit atomic_generic_cas32(T v) : i((int32_t)v) {} - atomic_generic_cas32() {} - T load(memory_order order=memory_order_seq_cst) const volatile - { - T expected=(T)i; - do { } while(!const_cast(this)->compare_exchange_weak(expected, expected, order, memory_order_relaxed)); - return expected; - } - void store(T v, memory_order order=memory_order_seq_cst) volatile - { - exchange(v); - } - bool compare_exchange_strong( - T &expected, - T desired, - memory_order success_order, - memory_order failure_order) volatile - { - T found; - found=(T)fenced_compare_exchange_strong_32(&i, (int32_t)expected, (int32_t)desired); - bool success=(found==expected); - expected=found; - return success; - } - bool compare_exchange_weak( - T &expected, - T desired, - memory_order success_order, - memory_order failure_order) volatile - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - T exchange(T r, memory_order order=memory_order_seq_cst) volatile - { - T expected=(T)i; - do { } while(!compare_exchange_weak(expected, r, order, memory_order_relaxed)); - return expected; - } - - bool is_lock_free(void) const volatile {return true;} - typedef T integral_type; -private: - mutable int32_t i; -}; - -template -class platform_atomic_integral : - public build_atomic_from_exchange > -{ -public: - typedef build_atomic_from_exchange > super; - explicit platform_atomic_integral(T v) : super(v) {} - platform_atomic_integral(void) {} -}; - -template -class platform_atomic_integral : - public build_atomic_from_larger_type, T> -{ -public: - typedef build_atomic_from_larger_type, T> super; - - explicit platform_atomic_integral(T v) : super(v) {} - platform_atomic_integral(void) {} -}; - -template -class platform_atomic_integral : - public build_atomic_from_larger_type, T> -{ -public: - typedef build_atomic_from_larger_type, T> super; - - explicit platform_atomic_integral(T v) : super(v) {} - platform_atomic_integral(void) {} -}; -#endif - -} } } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/interlocked.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/interlocked.hpp deleted file mode 100644 index ae8518df..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/interlocked.hpp +++ /dev/null @@ -1,203 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_INTERLOCKED_HPP -#define BOOST_ATOMIC_DETAIL_INTERLOCKED_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2012, 2013 Andrey Semashev -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#if defined(_WIN32_WCE) || (defined(_MSC_VER) && _MSC_VER < 1400) - -#include - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare) BOOST_INTERLOCKED_COMPARE_EXCHANGE((long*)(dest), exchange, compare) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval) BOOST_INTERLOCKED_EXCHANGE((long*)(dest), newval) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, addend) BOOST_INTERLOCKED_EXCHANGE_ADD((long*)(dest), addend) -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) BOOST_INTERLOCKED_EXCHANGE_POINTER(dest, newval) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_INTERLOCKED_EXCHANGE_ADD((long*)(dest), byte_offset)) - -#elif defined(_MSC_VER) && _MSC_VER >= 1400 - -#include - -#pragma intrinsic(_InterlockedCompareExchange) -#pragma intrinsic(_InterlockedExchangeAdd) -#pragma intrinsic(_InterlockedExchange) -#pragma intrinsic(_InterlockedAnd) -#pragma intrinsic(_InterlockedOr) -#pragma intrinsic(_InterlockedXor) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare) _InterlockedCompareExchange((long*)(dest), (long)(exchange), (long)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, addend) _InterlockedExchangeAdd((long*)(dest), (long)(addend)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval) _InterlockedExchange((long*)(dest), (long)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_AND(dest, arg) _InterlockedAnd((long*)(dest), (long)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_OR(dest, arg) _InterlockedOr((long*)(dest), (long)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_XOR(dest, arg) _InterlockedXor((long*)(dest), (long)(arg)) - -#if (defined(_M_IX86) && _M_IX86 >= 500) || defined(_M_AMD64) || defined(_M_IA64) -#pragma intrinsic(_InterlockedCompareExchange64) -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(dest, exchange, compare) _InterlockedCompareExchange64((__int64*)(dest), (__int64)(exchange), (__int64)(compare)) -#endif - -#if _MSC_VER >= 1600 - -// MSVC 2010 and later provide intrinsics for 8 and 16 bit integers. -// Note that for each bit count these macros must be either all defined or all not defined. -// Otherwise atomic<> operations will be implemented inconsistently. - -#pragma intrinsic(_InterlockedCompareExchange8) -#pragma intrinsic(_InterlockedExchangeAdd8) -#pragma intrinsic(_InterlockedExchange8) -#pragma intrinsic(_InterlockedAnd8) -#pragma intrinsic(_InterlockedOr8) -#pragma intrinsic(_InterlockedXor8) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8(dest, exchange, compare) _InterlockedCompareExchange8((char*)(dest), (char)(exchange), (char)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD8(dest, addend) _InterlockedExchangeAdd8((char*)(dest), (char)(addend)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE8(dest, newval) _InterlockedExchange8((char*)(dest), (char)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_AND8(dest, arg) _InterlockedAnd8((char*)(dest), (char)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_OR8(dest, arg) _InterlockedOr8((char*)(dest), (char)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_XOR8(dest, arg) _InterlockedXor8((char*)(dest), (char)(arg)) - -#pragma intrinsic(_InterlockedCompareExchange16) -#pragma intrinsic(_InterlockedExchangeAdd16) -#pragma intrinsic(_InterlockedExchange16) -#pragma intrinsic(_InterlockedAnd16) -#pragma intrinsic(_InterlockedOr16) -#pragma intrinsic(_InterlockedXor16) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16(dest, exchange, compare) _InterlockedCompareExchange16((short*)(dest), (short)(exchange), (short)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD16(dest, addend) _InterlockedExchangeAdd16((short*)(dest), (short)(addend)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE16(dest, newval) _InterlockedExchange16((short*)(dest), (short)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_AND16(dest, arg) _InterlockedAnd16((short*)(dest), (short)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_OR16(dest, arg) _InterlockedOr16((short*)(dest), (short)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_XOR16(dest, arg) _InterlockedXor16((short*)(dest), (short)(arg)) - -#endif // _MSC_VER >= 1600 - -#if defined(_M_AMD64) || defined(_M_IA64) - -#pragma intrinsic(_InterlockedExchangeAdd64) -#pragma intrinsic(_InterlockedExchange64) -#pragma intrinsic(_InterlockedAnd64) -#pragma intrinsic(_InterlockedOr64) -#pragma intrinsic(_InterlockedXor64) - -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(dest, addend) _InterlockedExchangeAdd64((__int64*)(dest), (__int64)(addend)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE64(dest, newval) _InterlockedExchange64((__int64*)(dest), (__int64)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_AND64(dest, arg) _InterlockedAnd64((__int64*)(dest), (__int64)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_OR64(dest, arg) _InterlockedOr64((__int64*)(dest), (__int64)(arg)) -#define BOOST_ATOMIC_INTERLOCKED_XOR64(dest, arg) _InterlockedXor64((__int64*)(dest), (__int64)(arg)) - -#pragma intrinsic(_InterlockedCompareExchangePointer) -#pragma intrinsic(_InterlockedExchangePointer) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) _InterlockedCompareExchangePointer((void**)(dest), (void*)(exchange), (void*)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) _InterlockedExchangePointer((void**)(dest), (void*)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64((long*)(dest), byte_offset)) - -#else // defined(_M_AMD64) || defined(_M_IA64) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) ((void*)_InterlockedCompareExchange((long*)(dest), (long)(exchange), (long)(compare))) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) ((void*)_InterlockedExchange((long*)(dest), (long)(newval))) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD((long*)(dest), byte_offset)) - -#endif // defined(_M_AMD64) || defined(_M_IA64) - -#else // defined(_MSC_VER) && _MSC_VER >= 1400 - -#if defined(BOOST_USE_WINDOWS_H) - -#include - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare) InterlockedCompareExchange((long*)(dest), (long)(exchange), (long)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval) InterlockedExchange((long*)(dest), (long)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, addend) InterlockedExchangeAdd((long*)(dest), (long)(addend)) - -#if defined(_WIN64) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(dest, exchange, compare) InterlockedCompareExchange64((__int64*)(dest), (__int64)(exchange), (__int64)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE64(dest, newval) InterlockedExchange64((__int64*)(dest), (__int64)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(dest, addend) InterlockedExchangeAdd64((__int64*)(dest), (__int64)(addend)) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) InterlockedCompareExchangePointer((void**)(dest), (void*)(exchange), (void*)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) InterlockedExchangePointer((void**)(dest), (void*)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(dest, byte_offset)) - -#else // defined(_WIN64) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) ((void*)BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, byte_offset)) - -#endif // defined(_WIN64) - -#else // defined(BOOST_USE_WINDOWS_H) - -#if defined(__MINGW64__) -#define BOOST_ATOMIC_INTERLOCKED_IMPORT -#else -#define BOOST_ATOMIC_INTERLOCKED_IMPORT __declspec(dllimport) -#endif - -namespace boost { -namespace atomics { -namespace detail { - -extern "C" { - -BOOST_ATOMIC_INTERLOCKED_IMPORT long __stdcall InterlockedCompareExchange(long volatile*, long, long); -BOOST_ATOMIC_INTERLOCKED_IMPORT long __stdcall InterlockedExchange(long volatile*, long); -BOOST_ATOMIC_INTERLOCKED_IMPORT long __stdcall InterlockedExchangeAdd(long volatile*, long); - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare) boost::atomics::detail::InterlockedCompareExchange((long*)(dest), (long)(exchange), (long)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval) boost::atomics::detail::InterlockedExchange((long*)(dest), (long)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, addend) boost::atomics::detail::InterlockedExchangeAdd((long*)(dest), (long)(addend)) - -#if defined(_WIN64) - -BOOST_ATOMIC_INTERLOCKED_IMPORT __int64 __stdcall InterlockedCompareExchange64(__int64 volatile*, __int64, __int64); -BOOST_ATOMIC_INTERLOCKED_IMPORT __int64 __stdcall InterlockedExchange64(__int64 volatile*, __int64); -BOOST_ATOMIC_INTERLOCKED_IMPORT __int64 __stdcall InterlockedExchangeAdd64(__int64 volatile*, __int64); - -BOOST_ATOMIC_INTERLOCKED_IMPORT void* __stdcall InterlockedCompareExchangePointer(void* volatile *, void*, void*); -BOOST_ATOMIC_INTERLOCKED_IMPORT void* __stdcall InterlockedExchangePointer(void* volatile *, void*); - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(dest, exchange, compare) boost::atomics::detail::InterlockedCompareExchange64((__int64*)(dest), (__int64)(exchange), (__int64)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE64(dest, newval) boost::atomics::detail::InterlockedExchange64((__int64*)(dest), (__int64)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(dest, addend) boost::atomics::detail::InterlockedExchangeAdd64((__int64*)(dest), (__int64)(addend)) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) boost::atomics::detail::InterlockedCompareExchangePointer((void**)(dest), (void*)(exchange), (void*)(compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) boost::atomics::detail::InterlockedExchangePointer((void**)(dest), (void*)(newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(dest, byte_offset)) - -#else // defined(_WIN64) - -#define BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest, exchange, compare) ((void*)BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(dest, exchange, compare)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(dest, newval) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE(dest, newval)) -#define BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(dest, byte_offset) ((void*)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(dest, byte_offset)) - -#endif // defined(_WIN64) - -} // extern "C" - -} // namespace detail -} // namespace atomics -} // namespace boost - -#undef BOOST_ATOMIC_INTERLOCKED_IMPORT - -#endif // defined(BOOST_USE_WINDOWS_H) - -#endif // defined(_MSC_VER) - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/link.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/link.hpp deleted file mode 100644 index 25a4caf2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/link.hpp +++ /dev/null @@ -1,50 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_LINK_HPP -#define BOOST_ATOMIC_DETAIL_LINK_HPP - -// Copyright (c) 2012 Hartmut Kaiser -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -/////////////////////////////////////////////////////////////////////////////// -// Set up dll import/export options -#if (defined(BOOST_ATOMIC_DYN_LINK) || defined(BOOST_ALL_DYN_LINK)) && \ - !defined(BOOST_ATOMIC_STATIC_LINK) - -#if defined(BOOST_ATOMIC_SOURCE) -#define BOOST_ATOMIC_DECL BOOST_SYMBOL_EXPORT -#define BOOST_ATOMIC_BUILD_DLL -#else -#define BOOST_ATOMIC_DECL BOOST_SYMBOL_IMPORT -#endif - -#endif // building a shared library - -#ifndef BOOST_ATOMIC_DECL -#define BOOST_ATOMIC_DECL -#endif - -/////////////////////////////////////////////////////////////////////////////// -// Auto library naming -#if !defined(BOOST_ATOMIC_SOURCE) && !defined(BOOST_ALL_NO_LIB) && \ - !defined(BOOST_ATOMIC_NO_LIB) - -#define BOOST_LIB_NAME boost_atomic - -// tell the auto-link code to select a dll when required: -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_ATOMIC_DYN_LINK) -#define BOOST_DYN_LINK -#endif - -#include - -#endif // auto-linking disabled - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/linux-arm.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/linux-arm.hpp deleted file mode 100644 index d39dcd0e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/linux-arm.hpp +++ /dev/null @@ -1,190 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_LINUX_ARM_HPP -#define BOOST_ATOMIC_DETAIL_LINUX_ARM_HPP - -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 2009, 2011 Helge Bahmann -// Copyright (c) 2009 Phil Endecott -// Copyright (c) 2013 Tim Blechmann -// Linux-specific code by Phil Endecott - -// Different ARM processors have different atomic instructions. In particular, -// architecture versions before v6 (which are still in widespread use, e.g. the -// Intel/Marvell XScale chips like the one in the NSLU2) have only atomic swap. -// On Linux the kernel provides some support that lets us abstract away from -// these differences: it provides emulated CAS and barrier functions at special -// addresses that are guaranteed not to be interrupted by the kernel. Using -// this facility is slightly slower than inline assembler would be, but much -// faster than a system call. -// -// While this emulated CAS is "strong" in the sense that it does not fail -// "spuriously" (i.e.: it never fails to perform the exchange when the value -// found equals the value expected), it does not return the found value on -// failure. To satisfy the atomic API, compare_exchange_{weak|strong} must -// return the found value on failure, and we have to manually load this value -// after the emulated CAS reports failure. This in turn introduces a race -// between the CAS failing (due to the "wrong" value being found) and subsequently -// loading (which might turn up the "right" value). From an application's -// point of view this looks like "spurious failure", and therefore the -// emulated CAS is only good enough to provide compare_exchange_weak -// semantics. - -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -inline void -arm_barrier(void) -{ - void (*kernel_dmb)(void) = (void (*)(void)) 0xffff0fa0; - kernel_dmb(); -} - -inline void -platform_fence_before(memory_order order) -{ - switch(order) { - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - arm_barrier(); - case memory_order_consume: - default:; - } -} - -inline void -platform_fence_after(memory_order order) -{ - switch(order) { - case memory_order_acquire: - case memory_order_acq_rel: - case memory_order_seq_cst: - arm_barrier(); - default:; - } -} - -inline void -platform_fence_before_store(memory_order order) -{ - platform_fence_before(order); -} - -inline void -platform_fence_after_store(memory_order order) -{ - if (order == memory_order_seq_cst) - arm_barrier(); -} - -inline void -platform_fence_after_load(memory_order order) -{ - platform_fence_after(order); -} - -template -inline bool -platform_cmpxchg32(T & expected, T desired, volatile T * ptr) -{ - typedef T (*kernel_cmpxchg32_t)(T oldval, T newval, volatile T * ptr); - - if (((kernel_cmpxchg32_t) 0xffff0fc0)(expected, desired, ptr) == 0) { - return true; - } else { - expected = *ptr; - return false; - } -} - -} -} - -#define BOOST_ATOMIC_THREAD_FENCE 2 -inline void -atomic_thread_fence(memory_order order) -{ - switch(order) { - case memory_order_acquire: - case memory_order_release: - case memory_order_acq_rel: - case memory_order_seq_cst: - atomics::detail::arm_barrier(); - default:; - } -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -inline void -atomic_signal_fence(memory_order) -{ - __asm__ __volatile__ ("" ::: "memory"); -} - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before_store(order); - const_cast(v_) = 0; - atomics::detail::platform_fence_after_store(order); - } - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - uint32_t expected = v_; - do { - if (expected == 1) - break; - } while (!atomics::detail::platform_cmpxchg32(expected, (uint32_t)1, &v_)); - atomics::detail::platform_fence_after(order); - return expected; - } -}; - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -} - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -#include - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/lockpool.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/lockpool.hpp deleted file mode 100644 index 42464866..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/lockpool.hpp +++ /dev/null @@ -1,91 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_LOCKPOOL_HPP -#define BOOST_ATOMIC_DETAIL_LOCKPOOL_HPP - -// Copyright (c) 2011 Helge Bahmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#ifndef BOOST_ATOMIC_FLAG_LOCK_FREE -#include -#endif - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -#ifndef BOOST_ATOMIC_FLAG_LOCK_FREE - -class lockpool -{ -public: - typedef boost::detail::lightweight_mutex lock_type; - class scoped_lock : - public lock_type::scoped_lock - { - typedef lock_type::scoped_lock base_type; - - public: - explicit scoped_lock(const volatile void * addr) : base_type(get_lock_for(addr)) - { - } - - BOOST_DELETED_FUNCTION(scoped_lock(scoped_lock const&)) - BOOST_DELETED_FUNCTION(scoped_lock& operator=(scoped_lock const&)) - }; - -private: - static BOOST_ATOMIC_DECL lock_type& get_lock_for(const volatile void * addr); -}; - -#else - -class lockpool -{ -public: - typedef atomic_flag lock_type; - - class scoped_lock - { - private: - atomic_flag& flag_; - - public: - explicit - scoped_lock(const volatile void * addr) : flag_(get_lock_for(addr)) - { - for (; flag_.test_and_set(memory_order_acquire);) - { -#if defined(BOOST_ATOMIC_X86_PAUSE) - BOOST_ATOMIC_X86_PAUSE(); -#endif - } - } - - ~scoped_lock(void) - { - flag_.clear(memory_order_release); - } - - BOOST_DELETED_FUNCTION(scoped_lock(const scoped_lock &)) - BOOST_DELETED_FUNCTION(scoped_lock& operator=(const scoped_lock &)) - }; - -private: - static BOOST_ATOMIC_DECL lock_type& get_lock_for(const volatile void * addr); -}; - -#endif - -} -} -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/platform.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/platform.hpp deleted file mode 100644 index 3dfb73d7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/platform.hpp +++ /dev/null @@ -1,71 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_PLATFORM_HPP -#define BOOST_ATOMIC_DETAIL_PLATFORM_HPP - -// Copyright (c) 2009 Helge Bahmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Platform selection file - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -// Intel compiler does not support __atomic* intrinsics properly, although defines them (tested with 13.0.1 and 13.1.1 on Linux) -#if (defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 407) && !defined(BOOST_INTEL_CXX_VERSION))\ - || (defined(BOOST_CLANG) && ((__clang_major__ * 100 + __clang_minor__) >= 302)) - - #include - -#elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) - - #include - -#elif 0 && defined(__GNUC__) && defined(__alpha__) /* currently does not work correctly */ - - #include - #include - -#elif defined(__GNUC__) && (defined(__POWERPC__) || defined(__PPC__)) - - #include - -// This list of ARM architecture versions comes from Apple's arm/arch.h header. -// I don't know how complete it is. -#elif defined(__GNUC__) && (defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) \ - || defined(__ARM_ARCH_6Z__) || defined(__ARM_ARCH_6ZK__) \ - || defined(__ARM_ARCH_6K__) \ - || defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) \ - || defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) \ - || defined(__ARM_ARCH_7EM__) || defined(__ARM_ARCH_7S__)) - - #include - -#elif defined(__linux__) && defined(__arm__) - - #include - -#elif defined(__GNUC__) && defined(__sparc_v9__) - - #include - -#elif defined(BOOST_WINDOWS) || defined(_WIN32_CE) - - #include - -#elif 0 && defined(__GNUC__) /* currently does not work correctly */ - - #include - #include - -#else - -#include - -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/type-classification.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/type-classification.hpp deleted file mode 100644 index 98bc3113..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/type-classification.hpp +++ /dev/null @@ -1,45 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_TYPE_CLASSIFICATION_HPP -#define BOOST_ATOMIC_DETAIL_TYPE_CLASSIFICATION_HPP - -// Copyright (c) 2011 Helge Bahmann -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace atomics { -namespace detail { - -template::value> -struct classify -{ - typedef void type; -}; - -template -struct classify {typedef int type;}; - -template -struct classify {typedef void* type;}; - -template -struct storage_size_of -{ - enum _ - { - size = sizeof(T), - value = (size == 3 ? 4 : (size >= 5 && size <= 7 ? 8 : (size >= 9 && size <= 15 ? 16 : size))) - }; -}; - -}}} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/windows.hpp b/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/windows.hpp deleted file mode 100644 index a8dc4f84..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/atomic/detail/windows.hpp +++ /dev/null @@ -1,1669 +0,0 @@ -#ifndef BOOST_ATOMIC_DETAIL_WINDOWS_HPP -#define BOOST_ATOMIC_DETAIL_WINDOWS_HPP - -// Copyright (c) 2009 Helge Bahmann -// Copyright (c) 2012 Andrey Semashev -// Copyright (c) 2013 Tim Blechmann, Andrey Semashev -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#ifdef _MSC_VER -#pragma warning(push) -// 'order' : unreferenced formal parameter -#pragma warning(disable: 4100) -#endif - -#if defined(_MSC_VER) && (defined(_M_AMD64) || defined(_M_IX86)) -extern "C" void _mm_pause(void); -#pragma intrinsic(_mm_pause) -#define BOOST_ATOMIC_X86_PAUSE() _mm_pause() -#else -#define BOOST_ATOMIC_X86_PAUSE() -#endif - -#if defined(_M_IX86) && _M_IX86 >= 500 -#define BOOST_ATOMIC_X86_HAS_CMPXCHG8B 1 -#endif - -// Define hardware barriers -#if defined(_MSC_VER) && (defined(_M_AMD64) || (defined(_M_IX86) && defined(_M_IX86_FP) && _M_IX86_FP >= 2)) -extern "C" void _mm_mfence(void); -#pragma intrinsic(_mm_mfence) -#endif - -// Define compiler barriers -#if defined(__INTEL_COMPILER) -#define BOOST_ATOMIC_COMPILER_BARRIER() __memory_barrier() -#elif defined(_MSC_VER) && _MSC_VER >= 1310 && !defined(_WIN32_WCE) -extern "C" void _ReadWriteBarrier(void); -#pragma intrinsic(_ReadWriteBarrier) -#define BOOST_ATOMIC_COMPILER_BARRIER() _ReadWriteBarrier() -#endif - -#ifndef BOOST_ATOMIC_COMPILER_BARRIER -#define BOOST_ATOMIC_COMPILER_BARRIER() -#endif - -namespace boost { -namespace atomics { -namespace detail { - -BOOST_FORCEINLINE void hardware_full_fence(void) -{ -#if defined(_MSC_VER) && (defined(_M_AMD64) || (defined(_M_IX86) && defined(_M_IX86_FP) && _M_IX86_FP >= 2)) - // Use mfence only if SSE2 is available - _mm_mfence(); -#else - long tmp; - BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&tmp, 0); -#endif -} - -BOOST_FORCEINLINE void -platform_fence_before(memory_order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); -} - -BOOST_FORCEINLINE void -platform_fence_after(memory_order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); -} - -BOOST_FORCEINLINE void -platform_fence_before_store(memory_order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); -} - -BOOST_FORCEINLINE void -platform_fence_after_store(memory_order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); -} - -BOOST_FORCEINLINE void -platform_fence_after_load(memory_order order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); - - // On x86 and x86_64 there is no need for a hardware barrier, - // even if seq_cst memory order is requested, because all - // seq_cst writes are implemented with lock-prefixed operations - // or xchg which has implied lock prefix. Therefore normal loads - // are already ordered with seq_cst stores on these architectures. - -#if !(defined(_MSC_VER) && (defined(_M_AMD64) || defined(_M_IX86))) - if (order == memory_order_seq_cst) - hardware_full_fence(); -#endif -} - -} // namespace detail -} // namespace atomics - -#define BOOST_ATOMIC_THREAD_FENCE 2 -BOOST_FORCEINLINE void -atomic_thread_fence(memory_order order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); - if (order == memory_order_seq_cst) - atomics::detail::hardware_full_fence(); -} - -#define BOOST_ATOMIC_SIGNAL_FENCE 2 -BOOST_FORCEINLINE void -atomic_signal_fence(memory_order) -{ - BOOST_ATOMIC_COMPILER_BARRIER(); -} - -#undef BOOST_ATOMIC_COMPILER_BARRIER - -class atomic_flag -{ -private: - atomic_flag(const atomic_flag &) /* = delete */ ; - atomic_flag & operator=(const atomic_flag &) /* = delete */ ; - uint32_t v_; -public: - BOOST_CONSTEXPR atomic_flag(void) BOOST_NOEXCEPT : v_(0) {} - - bool - test_and_set(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before(order); - const uint32_t old = (uint32_t)BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, 1); - atomics::detail::platform_fence_after(order); - return old != 0; - } - - void - clear(memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - atomics::detail::platform_fence_before_store(order); - BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, 0); - atomics::detail::platform_fence_after_store(order); - } -}; - -} // namespace boost - -#define BOOST_ATOMIC_FLAG_LOCK_FREE 2 - -#include - -#if !defined(BOOST_ATOMIC_FORCE_FALLBACK) - -#define BOOST_ATOMIC_CHAR_LOCK_FREE 2 -#define BOOST_ATOMIC_SHORT_LOCK_FREE 2 -#define BOOST_ATOMIC_INT_LOCK_FREE 2 -#define BOOST_ATOMIC_LONG_LOCK_FREE 2 -#if defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) || defined(_M_AMD64) || defined(_M_IA64) -#define BOOST_ATOMIC_LLONG_LOCK_FREE 2 -#else -#define BOOST_ATOMIC_LLONG_LOCK_FREE 0 -#endif -#define BOOST_ATOMIC_POINTER_LOCK_FREE 2 -#define BOOST_ATOMIC_BOOL_LOCK_FREE 2 - -namespace boost { -namespace atomics { -namespace detail { - -#if defined(_MSC_VER) -#pragma warning(push) -// 'char' : forcing value to bool 'true' or 'false' (performance warning) -#pragma warning(disable: 4800) -#endif - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8 - typedef value_type storage_type; -#else - typedef uint32_t storage_type; -#endif - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - v_ = static_cast< storage_type >(v); - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = static_cast< value_type >(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD8 - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD8(&v_, v)); -#else - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(&v_, v)); -#endif - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - typedef typename make_signed< value_type >::type signed_value_type; - return fetch_add(static_cast< value_type >(-static_cast< signed_value_type >(v)), order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE8 - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE8(&v_, v)); -#else - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, v)); -#endif - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8 - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8(&v_, desired, previous)); -#else - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired, previous)); -#endif - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_AND8 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND8(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_AND) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_OR8 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR8(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_OR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_XOR8 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR8(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_XOR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#if defined(_MSC_VER) -#pragma warning(pop) -#endif - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16 - typedef value_type storage_type; -#else - typedef uint32_t storage_type; -#endif - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - v_ = static_cast< storage_type >(v); - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = static_cast< value_type >(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD16 - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD16(&v_, v)); -#else - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(&v_, v)); -#endif - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - typedef typename make_signed< value_type >::type signed_value_type; - return fetch_add(static_cast< value_type >(-static_cast< signed_value_type >(v)), order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE16 - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE16(&v_, v)); -#else - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, v)); -#endif - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16 - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16(&v_, desired, previous)); -#else - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired, previous)); -#endif - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_AND16 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND16(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_AND) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_OR16 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR16(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_OR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#ifdef BOOST_ATOMIC_INTERLOCKED_XOR16 - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR16(&v_, v)); - platform_fence_after(order); - return v; -#elif defined(BOOST_ATOMIC_INTERLOCKED_XOR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef value_type storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - v_ = static_cast< storage_type >(v); - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = static_cast< value_type >(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD(&v_, v)); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - typedef typename make_signed< value_type >::type signed_value_type; - return fetch_add(static_cast< value_type >(-static_cast< signed_value_type >(v)), order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, v)); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired, previous)); - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_AND) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_OR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for(; !compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_XOR) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -// MSVC 2012 fails to recognize sizeof(T) as a constant expression in template specializations -enum msvc_sizeof_pointer_workaround { sizeof_pointer = sizeof(void*) }; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef std::ptrdiff_t difference_type; - typedef void* value_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = (value_type)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(&v_, v); - platform_fence_after(order); - return v; - } - - bool compare_exchange_strong(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - value_type oldval = (value_type)BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(&v_, desired, previous); - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool compare_exchange_weak(value_type & expected, value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - value_type res = (value_type)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(&v_, v); - platform_fence_after(order); - return res; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - BOOST_ATOMIC_DECLARE_VOID_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T* value_type; - typedef std::ptrdiff_t difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - const_cast(v_) = v; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - value_type v = const_cast(v_); - platform_fence_after_load(order); - return v; - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = (value_type)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_POINTER(&v_, v); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - value_type oldval = (value_type)BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE_POINTER(&v_, desired, previous); - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_add(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - v = v * sizeof(*v_); - platform_fence_before(order); - value_type res = (value_type)BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD_POINTER(&v_, v); - platform_fence_after(order); - return res; - } - - value_type - fetch_sub(difference_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - return fetch_add(-v, order); - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_POINTER_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - value_type v_; -}; - - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8 - typedef uint8_t storage_type; -#else - typedef uint32_t storage_type; -#endif - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8 - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(reinterpret_cast< storage_type const& >(v)) - { - } -#else - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } -#endif - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE8 - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE8(&v_, tmp)); -#else - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, tmp)); -#endif - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8 - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE8(&v_, desired_s, expected_s)); -#else - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired_s, expected_s)); -#endif - bool success = (oldval == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &oldval, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16 - typedef uint16_t storage_type; -#else - typedef uint32_t storage_type; -#endif - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16 - BOOST_CONSTEXPR explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(reinterpret_cast< storage_type const& >(v)) - { - } -#else - explicit base_atomic(value_type const& v) BOOST_NOEXCEPT : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } -#endif - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); -#ifdef BOOST_ATOMIC_INTERLOCKED_EXCHANGE16 - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE16(&v_, tmp)); -#else - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, tmp)); -#endif - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); -#ifdef BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16 - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE16(&v_, desired_s, expected_s)); -#else - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired_s, expected_s)); -#endif - bool success = (oldval == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &oldval, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint32_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE(&v_, tmp)); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE(&v_, desired_s, expected_s)); - bool success = (oldval == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &oldval, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void) const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#if defined(_M_AMD64) || defined(_M_IA64) - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef value_type storage_type; - typedef T difference_type; - -protected: - typedef value_type value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - BOOST_CONSTEXPR explicit base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} - - void - store(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - platform_fence_before(order); - v_ = static_cast< storage_type >(v); - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst) const volatile BOOST_NOEXCEPT - { - value_type v = static_cast< value_type >(v_); - platform_fence_after_load(order); - return v; - } - - value_type - fetch_add(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE_ADD64(&v_, v)); - platform_fence_after(order); - return v; - } - - value_type - fetch_sub(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - typedef typename make_signed< value_type >::type signed_value_type; - return fetch_add(static_cast< value_type >(-static_cast< signed_value_type >(v)), order); - } - - value_type - exchange(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE64(&v_, v)); - platform_fence_after(order); - return v; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - value_type previous = expected; - platform_fence_before(success_order); - value_type oldval = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(&v_, desired, previous)); - bool success = (previous == oldval); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - expected = oldval; - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - value_type - fetch_and(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_AND64) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_AND64(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp & v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_or(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_OR64) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_OR64(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp | v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - value_type - fetch_xor(value_type v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { -#if defined(BOOST_ATOMIC_INTERLOCKED_XOR64) - platform_fence_before(order); - v = static_cast< value_type >(BOOST_ATOMIC_INTERLOCKED_XOR64(&v_, v)); - platform_fence_after(order); - return v; -#else - value_type tmp = load(memory_order_relaxed); - for (; !compare_exchange_weak(tmp, tmp ^ v, order, memory_order_relaxed);) - { - BOOST_ATOMIC_X86_PAUSE(); - } - return tmp; -#endif - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_INTEGRAL_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -template -class base_atomic -{ -private: - typedef base_atomic this_type; - typedef T value_type; - typedef uint64_t storage_type; - -protected: - typedef value_type const& value_arg_type; - -public: - BOOST_DEFAULTED_FUNCTION(base_atomic(void), {}) - explicit base_atomic(value_type const& v) : v_(0) - { - memcpy(&v_, &v, sizeof(value_type)); - } - - void - store(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - if (order != memory_order_seq_cst) { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - const_cast(v_) = tmp; - } else { - exchange(v, order); - } - } - - value_type - load(memory_order order = memory_order_seq_cst)const volatile BOOST_NOEXCEPT - { - storage_type tmp = const_cast(v_); - platform_fence_after_load(order); - value_type v; - memcpy(&v, &tmp, sizeof(value_type)); - return v; - } - - value_type - exchange(value_type const& v, memory_order order = memory_order_seq_cst) volatile BOOST_NOEXCEPT - { - storage_type tmp = 0; - memcpy(&tmp, &v, sizeof(value_type)); - platform_fence_before(order); - tmp = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_EXCHANGE64(&v_, tmp)); - platform_fence_after(order); - value_type res; - memcpy(&res, &tmp, sizeof(value_type)); - return res; - } - - bool - compare_exchange_strong( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - storage_type expected_s = 0, desired_s = 0; - memcpy(&expected_s, &expected, sizeof(value_type)); - memcpy(&desired_s, &desired, sizeof(value_type)); - platform_fence_before(success_order); - storage_type oldval = static_cast< storage_type >(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(&v_, desired_s, expected_s)); - bool success = (oldval == expected_s); - if (success) - platform_fence_after(success_order); - else - platform_fence_after(failure_order); - memcpy(&expected, &oldval, sizeof(value_type)); - return success; - } - - bool - compare_exchange_weak( - value_type & expected, - value_type const& desired, - memory_order success_order, - memory_order failure_order) volatile BOOST_NOEXCEPT - { - return compare_exchange_strong(expected, desired, success_order, failure_order); - } - - bool - is_lock_free(void)const volatile BOOST_NOEXCEPT - { - return true; - } - - BOOST_ATOMIC_DECLARE_BASE_OPERATORS - - BOOST_DELETED_FUNCTION(base_atomic(base_atomic const&)) - BOOST_DELETED_FUNCTION(base_atomic& operator=(base_atomic const&)) - -private: - storage_type v_; -}; - -#elif defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) - -template -inline bool -platform_cmpxchg64_strong(T & expected, T desired, volatile T * p) BOOST_NOEXCEPT -{ -#if defined(BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64) - const T oldval = BOOST_ATOMIC_INTERLOCKED_COMPARE_EXCHANGE64(p, desired, expected); - const bool result = (oldval == expected); - expected = oldval; - return result; -#else - bool result; - __asm - { - mov edi, p - mov esi, expected - mov ebx, dword ptr [desired] - mov ecx, dword ptr [desired + 4] - mov eax, dword ptr [esi] - mov edx, dword ptr [esi + 4] - lock cmpxchg8b qword ptr [edi] - mov dword ptr [esi], eax - mov dword ptr [esi + 4], edx - sete result - }; - return result; -#endif -} - -// Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 3A, 8.1.1. Guaranteed Atomic Operations: -// -// The Pentium processor (and newer processors since) guarantees that the following additional memory operations will always be carried out atomically: -// * Reading or writing a quadword aligned on a 64-bit boundary -// -// Luckily, the memory is almost always 8-byte aligned in our case because atomic<> uses 64 bit native types for storage and dynamic memory allocations -// have at least 8 byte alignment. The only unfortunate case is when atomic is placeod on the stack and it is not 8-byte aligned (like on 32 bit Windows). - -template -inline void -platform_store64(T value, volatile T * p) BOOST_NOEXCEPT -{ - if (((uint32_t)p & 0x00000007) == 0) - { -#if defined(_M_IX86_FP) && _M_IX86_FP >= 2 - __asm - { - mov edx, p - movq xmm4, value - movq qword ptr [edx], xmm4 - }; -#else - __asm - { - mov edx, p - fild value - fistp qword ptr [edx] - }; -#endif - } - else - { - __asm - { - mov edi, p - mov ebx, dword ptr [value] - mov ecx, dword ptr [value + 4] - mov eax, dword ptr [edi] - mov edx, dword ptr [edi + 4] - align 16 -again: - lock cmpxchg8b qword ptr [edi] - jne again - }; - } -} - -template -inline T -platform_load64(const volatile T * p) BOOST_NOEXCEPT -{ - T value; - - if (((uint32_t)p & 0x00000007) == 0) - { -#if defined(_M_IX86_FP) && _M_IX86_FP >= 2 - __asm - { - mov edx, p - movq xmm4, qword ptr [edx] - movq value, xmm4 - }; -#else - __asm - { - mov edx, p - fild qword ptr [edx] - fistp value - }; -#endif - } - else - { - // We don't care for comparison result here; the previous value will be stored into value anyway. - // Also we don't care for ebx and ecx values, they just have to be equal to eax and edx before cmpxchg8b. - __asm - { - mov edi, p - mov eax, ebx - mov edx, ecx - lock cmpxchg8b qword ptr [edi] - mov dword ptr [value], eax - mov dword ptr [value + 4], edx - }; - } - - return value; -} - -#endif - -} // namespace detail -} // namespace atomics -} // namespace boost - -/* pull in 64-bit atomic type using cmpxchg8b above */ -#if defined(BOOST_ATOMIC_X86_HAS_CMPXCHG8B) -#include -#endif - -#endif /* !defined(BOOST_ATOMIC_FORCE_FALLBACK) */ - -#ifdef _MSC_VER -#pragma warning(pop) -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind.hpp deleted file mode 100644 index fd3421ea..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind.hpp +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef BOOST_BIND_HPP_INCLUDED -#define BOOST_BIND_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind.hpp - binds function objects to arguments -// -// Copyright (c) 2009 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include - -#endif // #ifndef BOOST_BIND_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/arg.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/arg.hpp deleted file mode 100644 index 0d5cd03a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/arg.hpp +++ /dev/null @@ -1,62 +0,0 @@ -#ifndef BOOST_BIND_ARG_HPP_INCLUDED -#define BOOST_BIND_ARG_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind/arg.hpp -// -// Copyright (c) 2002 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include -#include - -namespace boost -{ - -template< int I > struct arg -{ - arg() - { - } - - template< class T > arg( T const & /* t */ ) - { - // static assert I == is_placeholder::value - typedef char T_must_be_placeholder[ I == is_placeholder::value? 1: -1 ]; - } -}; - -template< int I > bool operator==( arg const &, arg const & ) -{ - return true; -} - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< int I > struct is_placeholder< arg > -{ - enum _vt { value = I }; -}; - -template< int I > struct is_placeholder< arg (*) () > -{ - enum _vt { value = I }; -}; - -#endif - -} // namespace boost - -#endif // #ifndef BOOST_BIND_ARG_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/bind.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/bind.hpp deleted file mode 100644 index fb670979..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/bind.hpp +++ /dev/null @@ -1,1751 +0,0 @@ -#ifndef BOOST_BIND_BIND_HPP_INCLUDED -#define BOOST_BIND_BIND_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind.hpp - binds function objects to arguments -// -// Copyright (c) 2001-2004 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2001 David Abrahams -// Copyright (c) 2005 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include -#include -#include -#include -#include -#include -#include -#include - -// Borland-specific bug, visit_each() silently fails to produce code - -#if defined(__BORLANDC__) -# define BOOST_BIND_VISIT_EACH boost::visit_each -#else -# define BOOST_BIND_VISIT_EACH visit_each -#endif - -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable: 4512) // assignment operator could not be generated -#endif - -namespace boost -{ - -template class weak_ptr; - -namespace _bi // implementation details -{ - -// result_traits - -template struct result_traits -{ - typedef R type; -}; - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -struct unspecified {}; - -template struct result_traits -{ - typedef typename F::result_type type; -}; - -template struct result_traits< unspecified, reference_wrapper > -{ - typedef typename F::result_type type; -}; - -#endif - -// ref_compare - -template bool ref_compare( T const & a, T const & b, long ) -{ - return a == b; -} - -template bool ref_compare( arg const &, arg const &, int ) -{ - return true; -} - -template bool ref_compare( arg (*) (), arg (*) (), int ) -{ - return true; -} - -template bool ref_compare( reference_wrapper const & a, reference_wrapper const & b, int ) -{ - return a.get_pointer() == b.get_pointer(); -} - -// bind_t forward declaration for listN - -template class bind_t; - -template bool ref_compare( bind_t const & a, bind_t const & b, int ) -{ - return a.compare( b ); -} - -// value - -template class value -{ -public: - - value(T const & t): t_(t) {} - - T & get() { return t_; } - T const & get() const { return t_; } - - bool operator==(value const & rhs) const - { - return t_ == rhs.t_; - } - -private: - - T t_; -}; - -// ref_compare for weak_ptr - -template bool ref_compare( value< weak_ptr > const & a, value< weak_ptr > const & b, int ) -{ - return !(a.get() < b.get()) && !(b.get() < a.get()); -} - -// type - -template class type {}; - -// unwrap - -template struct unwrapper -{ - static inline F & unwrap( F & f, long ) - { - return f; - } - - template static inline F2 & unwrap( reference_wrapper rf, int ) - { - return rf.get(); - } - - template static inline _mfi::dm unwrap( R T::* pm, int ) - { - return _mfi::dm( pm ); - } -}; - -// listN - -class list0 -{ -public: - - list0() {} - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A &, long) - { - return unwrapper::unwrap(f, 0)(); - } - - template R operator()(type, F const & f, A &, long) const - { - return unwrapper::unwrap(f, 0)(); - } - - template void operator()(type, F & f, A &, int) - { - unwrapper::unwrap(f, 0)(); - } - - template void operator()(type, F const & f, A &, int) const - { - unwrapper::unwrap(f, 0)(); - } - - template void accept(V &) const - { - } - - bool operator==(list0 const &) const - { - return true; - } -}; - -#ifdef BOOST_MSVC -// MSVC is bright enough to realise that the parameter rhs -// in operator==may be unused for some template argument types: -#pragma warning(push) -#pragma warning(disable:4100) -#endif - -template< class A1 > class list1: private storage1< A1 > -{ -private: - - typedef storage1< A1 > base_type; - -public: - - explicit list1( A1 a1 ): base_type( a1 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - - template T & operator[] ( _bi::value & v ) const { return v.get(); } - - template T const & operator[] ( _bi::value const & v ) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list1 const & rhs) const - { - return ref_compare(base_type::a1_, rhs.a1_, 0); - } -}; - -struct logical_and; -struct logical_or; - -template< class A1, class A2 > class list2: private storage2< A1, A2 > -{ -private: - - typedef storage2< A1, A2 > base_type; - -public: - - list2( A1 a1, A2 a2 ): base_type( a1, a2 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); - } - - template bool operator()( type, logical_and & /*f*/, A & a, int ) - { - return a[ base_type::a1_ ] && a[ base_type::a2_ ]; - } - - template bool operator()( type, logical_and const & /*f*/, A & a, int ) const - { - return a[ base_type::a1_ ] && a[ base_type::a2_ ]; - } - - template bool operator()( type, logical_or & /*f*/, A & a, int ) - { - return a[ base_type::a1_ ] || a[ base_type::a2_ ]; - } - - template bool operator()( type, logical_or const & /*f*/, A & a, int ) const - { - return a[ base_type::a1_ ] || a[ base_type::a2_ ]; - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list2 const & rhs) const - { - return ref_compare(base_type::a1_, rhs.a1_, 0) && ref_compare(base_type::a2_, rhs.a2_, 0); - } -}; - -template< class A1, class A2, class A3 > class list3: private storage3< A1, A2, A3 > -{ -private: - - typedef storage3< A1, A2, A3 > base_type; - -public: - - list3( A1 a1, A2 a2, A3 a3 ): base_type( a1, a2, a3 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list3 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4 > class list4: private storage4< A1, A2, A3, A4 > -{ -private: - - typedef storage4< A1, A2, A3, A4 > base_type; - -public: - - list4( A1 a1, A2 a2, A3 a3, A4 a4 ): base_type( a1, a2, a3, a4 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list4 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5 > class list5: private storage5< A1, A2, A3, A4, A5 > -{ -private: - - typedef storage5< A1, A2, A3, A4, A5 > base_type; - -public: - - list5( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5 ): base_type( a1, a2, a3, a4, a5 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list5 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ); - } -}; - -template class list6: private storage6< A1, A2, A3, A4, A5, A6 > -{ -private: - - typedef storage6< A1, A2, A3, A4, A5, A6 > base_type; - -public: - - list6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6 ): base_type( a1, a2, a3, a4, a5, a6 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list6 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ); - } -}; - -template class list7: private storage7< A1, A2, A3, A4, A5, A6, A7 > -{ -private: - - typedef storage7< A1, A2, A3, A4, A5, A6, A7 > base_type; - -public: - - list7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7 ): base_type( a1, a2, a3, a4, a5, a6, a7 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list7 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ); - } -}; - -template< class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8 > class list8: private storage8< A1, A2, A3, A4, A5, A6, A7, A8 > -{ -private: - - typedef storage8< A1, A2, A3, A4, A5, A6, A7, A8 > base_type; - -public: - - list8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8 ): base_type( a1, a2, a3, a4, a5, a6, a7, a8 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - A8 operator[] (boost::arg<8>) const { return base_type::a8_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - A8 operator[] (boost::arg<8> (*) ()) const { return base_type::a8_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list8 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ) && - ref_compare( base_type::a8_, rhs.a8_, 0 ); - } -}; - -template class list9: private storage9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > -{ -private: - - typedef storage9< A1, A2, A3, A4, A5, A6, A7, A8, A9 > base_type; - -public: - - list9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9 ): base_type( a1, a2, a3, a4, a5, a6, a7, a8, a9 ) {} - - A1 operator[] (boost::arg<1>) const { return base_type::a1_; } - A2 operator[] (boost::arg<2>) const { return base_type::a2_; } - A3 operator[] (boost::arg<3>) const { return base_type::a3_; } - A4 operator[] (boost::arg<4>) const { return base_type::a4_; } - A5 operator[] (boost::arg<5>) const { return base_type::a5_; } - A6 operator[] (boost::arg<6>) const { return base_type::a6_; } - A7 operator[] (boost::arg<7>) const { return base_type::a7_; } - A8 operator[] (boost::arg<8>) const { return base_type::a8_; } - A9 operator[] (boost::arg<9>) const { return base_type::a9_; } - - A1 operator[] (boost::arg<1> (*) ()) const { return base_type::a1_; } - A2 operator[] (boost::arg<2> (*) ()) const { return base_type::a2_; } - A3 operator[] (boost::arg<3> (*) ()) const { return base_type::a3_; } - A4 operator[] (boost::arg<4> (*) ()) const { return base_type::a4_; } - A5 operator[] (boost::arg<5> (*) ()) const { return base_type::a5_; } - A6 operator[] (boost::arg<6> (*) ()) const { return base_type::a6_; } - A7 operator[] (boost::arg<7> (*) ()) const { return base_type::a7_; } - A8 operator[] (boost::arg<8> (*) ()) const { return base_type::a8_; } - A9 operator[] (boost::arg<9> (*) ()) const { return base_type::a9_; } - - template T & operator[] (_bi::value & v) const { return v.get(); } - - template T const & operator[] (_bi::value const & v) const { return v.get(); } - - template T & operator[] (reference_wrapper const & v) const { return v.get(); } - - template typename result_traits::type operator[] (bind_t & b) const { return b.eval(*this); } - - template typename result_traits::type operator[] (bind_t const & b) const { return b.eval(*this); } - - template R operator()(type, F & f, A & a, long) - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template R operator()(type, F const & f, A & a, long) const - { - return unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template void operator()(type, F & f, A & a, int) - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template void operator()(type, F const & f, A & a, int) const - { - unwrapper::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_], a[base_type::a6_], a[base_type::a7_], a[base_type::a8_], a[base_type::a9_]); - } - - template void accept(V & v) const - { - base_type::accept(v); - } - - bool operator==(list9 const & rhs) const - { - return - - ref_compare( base_type::a1_, rhs.a1_, 0 ) && - ref_compare( base_type::a2_, rhs.a2_, 0 ) && - ref_compare( base_type::a3_, rhs.a3_, 0 ) && - ref_compare( base_type::a4_, rhs.a4_, 0 ) && - ref_compare( base_type::a5_, rhs.a5_, 0 ) && - ref_compare( base_type::a6_, rhs.a6_, 0 ) && - ref_compare( base_type::a7_, rhs.a7_, 0 ) && - ref_compare( base_type::a8_, rhs.a8_, 0 ) && - ref_compare( base_type::a9_, rhs.a9_, 0 ); - } -}; - -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - -// bind_t - -#ifndef BOOST_NO_VOID_RETURNS - -template class bind_t -{ -public: - - typedef bind_t this_type; - - bind_t(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN return -#include -#undef BOOST_BIND_RETURN - -}; - -#else - -template struct bind_t_generator -{ - -template class implementation -{ -public: - - typedef implementation this_type; - - implementation(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN return -#include -#undef BOOST_BIND_RETURN - -}; - -}; - -template<> struct bind_t_generator -{ - -template class implementation -{ -private: - - typedef void R; - -public: - - typedef implementation this_type; - - implementation(F f, L const & l): f_(f), l_(l) {} - -#define BOOST_BIND_RETURN -#include -#undef BOOST_BIND_RETURN - -}; - -}; - -template class bind_t: public bind_t_generator::BOOST_NESTED_TEMPLATE implementation -{ -public: - - bind_t(F f, L const & l): bind_t_generator::BOOST_NESTED_TEMPLATE implementation(f, l) {} - -}; - -#endif - -// function_equal - -#ifndef BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// put overloads in _bi, rely on ADL - -# ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -template bool function_equal( bind_t const & a, bind_t const & b ) -{ - return a.compare(b); -} - -# else - -template bool function_equal_impl( bind_t const & a, bind_t const & b, int ) -{ - return a.compare(b); -} - -# endif // #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -#else // BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// put overloads in boost - -} // namespace _bi - -# ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -template bool function_equal( _bi::bind_t const & a, _bi::bind_t const & b ) -{ - return a.compare(b); -} - -# else - -template bool function_equal_impl( _bi::bind_t const & a, _bi::bind_t const & b, int ) -{ - return a.compare(b); -} - -# endif // #ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING - -namespace _bi -{ - -#endif // BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP - -// add_value - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) || (__SUNPRO_CC >= 0x530) - -#if defined( __BORLANDC__ ) && BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x582) ) - -template struct add_value -{ - typedef _bi::value type; -}; - -#else - -template< class T, int I > struct add_value_2 -{ - typedef boost::arg type; -}; - -template< class T > struct add_value_2< T, 0 > -{ - typedef _bi::value< T > type; -}; - -template struct add_value -{ - typedef typename add_value_2< T, boost::is_placeholder< T >::value >::type type; -}; - -#endif - -template struct add_value< value > -{ - typedef _bi::value type; -}; - -template struct add_value< reference_wrapper > -{ - typedef reference_wrapper type; -}; - -template struct add_value< arg > -{ - typedef boost::arg type; -}; - -template struct add_value< arg (*) () > -{ - typedef boost::arg (*type) (); -}; - -template struct add_value< bind_t > -{ - typedef bind_t type; -}; - -#else - -template struct _avt_0; - -template<> struct _avt_0<1> -{ - template struct inner - { - typedef T type; - }; -}; - -template<> struct _avt_0<2> -{ - template struct inner - { - typedef value type; - }; -}; - -typedef char (&_avt_r1) [1]; -typedef char (&_avt_r2) [2]; - -template _avt_r1 _avt_f(value); -template _avt_r1 _avt_f(reference_wrapper); -template _avt_r1 _avt_f(arg); -template _avt_r1 _avt_f(arg (*) ()); -template _avt_r1 _avt_f(bind_t); - -_avt_r2 _avt_f(...); - -template struct add_value -{ - static T t(); - typedef typename _avt_0::template inner::type type; -}; - -#endif - -// list_av_N - -template struct list_av_1 -{ - typedef typename add_value::type B1; - typedef list1 type; -}; - -template struct list_av_2 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef list2 type; -}; - -template struct list_av_3 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef list3 type; -}; - -template struct list_av_4 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef list4 type; -}; - -template struct list_av_5 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef typename add_value::type B5; - typedef list5 type; -}; - -template struct list_av_6 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef typename add_value::type B5; - typedef typename add_value::type B6; - typedef list6 type; -}; - -template struct list_av_7 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef typename add_value::type B5; - typedef typename add_value::type B6; - typedef typename add_value::type B7; - typedef list7 type; -}; - -template struct list_av_8 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef typename add_value::type B5; - typedef typename add_value::type B6; - typedef typename add_value::type B7; - typedef typename add_value::type B8; - typedef list8 type; -}; - -template struct list_av_9 -{ - typedef typename add_value::type B1; - typedef typename add_value::type B2; - typedef typename add_value::type B3; - typedef typename add_value::type B4; - typedef typename add_value::type B5; - typedef typename add_value::type B6; - typedef typename add_value::type B7; - typedef typename add_value::type B8; - typedef typename add_value::type B9; - typedef list9 type; -}; - -// operator! - -struct logical_not -{ - template bool operator()(V const & v) const { return !v; } -}; - -template - bind_t< bool, logical_not, list1< bind_t > > - operator! (bind_t const & f) -{ - typedef list1< bind_t > list_type; - return bind_t ( logical_not(), list_type(f) ); -} - -// relational operators - -#define BOOST_BIND_OPERATOR( op, name ) \ -\ -struct name \ -{ \ - template bool operator()(V const & v, W const & w) const { return v op w; } \ -}; \ - \ -template \ - bind_t< bool, name, list2< bind_t, typename add_value::type > > \ - operator op (bind_t const & f, A2 a2) \ -{ \ - typedef typename add_value::type B2; \ - typedef list2< bind_t, B2> list_type; \ - return bind_t ( name(), list_type(f, a2) ); \ -} - -BOOST_BIND_OPERATOR( ==, equal ) -BOOST_BIND_OPERATOR( !=, not_equal ) - -BOOST_BIND_OPERATOR( <, less ) -BOOST_BIND_OPERATOR( <=, less_equal ) - -BOOST_BIND_OPERATOR( >, greater ) -BOOST_BIND_OPERATOR( >=, greater_equal ) - -BOOST_BIND_OPERATOR( &&, logical_and ) -BOOST_BIND_OPERATOR( ||, logical_or ) - -#undef BOOST_BIND_OPERATOR - -#if defined(__GNUC__) && BOOST_WORKAROUND(__GNUC__, < 3) - -// resolve ambiguity with rel_ops - -#define BOOST_BIND_OPERATOR( op, name ) \ -\ -template \ - bind_t< bool, name, list2< bind_t, bind_t > > \ - operator op (bind_t const & f, bind_t const & g) \ -{ \ - typedef list2< bind_t, bind_t > list_type; \ - return bind_t ( name(), list_type(f, g) ); \ -} - -BOOST_BIND_OPERATOR( !=, not_equal ) -BOOST_BIND_OPERATOR( <=, less_equal ) -BOOST_BIND_OPERATOR( >, greater ) -BOOST_BIND_OPERATOR( >=, greater_equal ) - -#endif - -// visit_each, ADL - -#if !defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) && !defined( __BORLANDC__ ) \ - && !(defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) - -template void visit_each( V & v, value const & t, int ) -{ - using boost::visit_each; - BOOST_BIND_VISIT_EACH( v, t.get(), 0 ); -} - -template void visit_each( V & v, bind_t const & t, int ) -{ - t.accept( v ); -} - -#endif - -} // namespace _bi - -// visit_each, no ADL - -#if defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) || defined( __BORLANDC__ ) \ - || (defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) - -template void visit_each( V & v, _bi::value const & t, int ) -{ - BOOST_BIND_VISIT_EACH( v, t.get(), 0 ); -} - -template void visit_each( V & v, _bi::bind_t const & t, int ) -{ - t.accept( v ); -} - -#endif - -// is_bind_expression - -template< class T > struct is_bind_expression -{ - enum _vt { value = 0 }; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template< class R, class F, class L > struct is_bind_expression< _bi::bind_t< R, F, L > > -{ - enum _vt { value = 1 }; -}; - -#endif - -// bind - -#ifndef BOOST_BIND -#define BOOST_BIND bind -#endif - -// generic function objects - -template - _bi::bind_t - BOOST_BIND(F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t (f, list_type()); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1) -{ - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t (f, list_type(a1)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t (f, list_type(a1, a2)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -// generic function objects, alternative syntax - -template - _bi::bind_t - BOOST_BIND(boost::type, F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t (f, list_type()); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1) -{ - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t (f, list_type(a1)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t (f, list_type(a1, a2)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t::type> - BOOST_BIND(boost::type, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -// adaptable function objects - -template - _bi::bind_t<_bi::unspecified, F, _bi::list0> - BOOST_BIND(F f) -{ - typedef _bi::list0 list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type()); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_1::type> - BOOST_BIND(F f, A1 a1) -{ - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_2::type> - BOOST_BIND(F f, A1 a1, A2 a2) -{ - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1, a2)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_3::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3) -{ - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_4::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_5::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_6::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_7::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_8::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_9::type> - BOOST_BIND(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -#endif // !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - -// function pointers - -#define BOOST_BIND_CC -#define BOOST_BIND_ST - -#include - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST - -#ifdef BOOST_BIND_ENABLE_STDCALL - -#define BOOST_BIND_CC __stdcall -#define BOOST_BIND_ST - -#include - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST - -#endif - -#ifdef BOOST_BIND_ENABLE_FASTCALL - -#define BOOST_BIND_CC __fastcall -#define BOOST_BIND_ST - -#include - -#undef BOOST_BIND_CC -#undef BOOST_BIND_ST - -#endif - -#ifdef BOOST_BIND_ENABLE_PASCAL - -#define BOOST_BIND_ST pascal -#define BOOST_BIND_CC - -#include - -#undef BOOST_BIND_ST -#undef BOOST_BIND_CC - -#endif - -// member function pointers - -#define BOOST_BIND_MF_NAME(X) X -#define BOOST_BIND_MF_CC - -#include -#include - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_BIND_MF_NAME(X) X##_cdecl -#define BOOST_BIND_MF_CC __cdecl - -#include -#include - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_BIND_MF_NAME(X) X##_stdcall -#define BOOST_BIND_MF_CC __stdcall - -#include -#include - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_BIND_MF_NAME(X) X##_fastcall -#define BOOST_BIND_MF_CC __fastcall - -#include -#include - -#undef BOOST_BIND_MF_NAME -#undef BOOST_BIND_MF_CC - -#endif - -// data member pointers - -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) || defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - || ( defined(__BORLANDC__) && BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x620 ) ) ) - -template -_bi::bind_t< R, _mfi::dm, typename _bi::list_av_1::type > - BOOST_BIND(R T::*f, A1 a1) -{ - typedef _mfi::dm F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t( F(f), list_type(a1) ); -} - -#else - -namespace _bi -{ - -template< class Pm, int I > struct add_cref; - -template< class M, class T > struct add_cref< M T::*, 0 > -{ - typedef M type; -}; - -template< class M, class T > struct add_cref< M T::*, 1 > -{ -#ifdef BOOST_MSVC -#pragma warning(push) -#pragma warning(disable:4180) -#endif - typedef M const & type; -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif -}; - -template< class R, class T > struct add_cref< R (T::*) (), 1 > -{ - typedef void type; -}; - -#if !defined(__IBMCPP__) || __IBMCPP_FUNC_CV_TMPL_ARG_DEDUCTION - -template< class R, class T > struct add_cref< R (T::*) () const, 1 > -{ - typedef void type; -}; - -#endif // __IBMCPP__ - -template struct isref -{ - enum value_type { value = 0 }; -}; - -template struct isref< R& > -{ - enum value_type { value = 1 }; -}; - -template struct isref< R* > -{ - enum value_type { value = 1 }; -}; - -template struct dm_result -{ - typedef typename add_cref< Pm, 1 >::type type; -}; - -template struct dm_result< Pm, bind_t > -{ - typedef typename bind_t::result_type result_type; - typedef typename add_cref< Pm, isref< result_type >::value >::type type; -}; - -} // namespace _bi - -template< class A1, class M, class T > - -_bi::bind_t< - typename _bi::dm_result< M T::*, A1 >::type, - _mfi::dm, - typename _bi::list_av_1::type -> - -BOOST_BIND( M T::*f, A1 a1 ) -{ - typedef typename _bi::dm_result< M T::*, A1 >::type result_type; - typedef _mfi::dm F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t< result_type, F, list_type >( F( f ), list_type( a1 ) ); -} - -#endif - -} // namespace boost - -#ifndef BOOST_BIND_NO_PLACEHOLDERS - -# include - -#endif - -#ifdef BOOST_MSVC -# pragma warning(default: 4512) // assignment operator could not be generated -# pragma warning(pop) -#endif - -#endif // #ifndef BOOST_BIND_BIND_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_cc.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/bind_cc.hpp deleted file mode 100644 index 35f8eceb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_cc.hpp +++ /dev/null @@ -1,117 +0,0 @@ -// -// bind/bind_cc.hpp - support for different calling conventions -// -// Do not include this header directly. -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -template - _bi::bind_t - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) ()) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (); - typedef _bi::list0 list_type; - return _bi::bind_t (f, list_type()); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1), A1 a1) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1); - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t (f, list_type(a1)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2), A1 a1, A2 a2) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2); - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t (f, list_type(a1, a2)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3), A1 a1, A2 a2, A3 a3) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3); - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4); - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4, B5); - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4, B5, B6); - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4, B5, B6, B7); - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4, B5, B6, B7, B8), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4, B5, B6, B7, B8); - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t::type> - BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2, B3, B4, B5, B6, B7, B8, B9), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef BOOST_BIND_ST R (BOOST_BIND_CC *F) (B1, B2, B3, B4, B5, B6, B7, B8, B9); - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf2_cc.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf2_cc.hpp deleted file mode 100644 index 66476bc1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf2_cc.hpp +++ /dev/null @@ -1,228 +0,0 @@ -// -// bind/bind_mf2_cc.hpp - member functions, type<> syntax -// -// Do not include this header directly. -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2008 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -// 0 - -template - _bi::bind_t, typename _bi::list_av_1::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (), A1 a1) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf0) F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t(F(f), list_type(a1)); -} - -template - _bi::bind_t, typename _bi::list_av_1::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) () const, A1 a1) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf0) F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t(F(f), list_type(a1)); -} - -// 1 - -template - _bi::bind_t, typename _bi::list_av_2::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1), A1 a1, A2 a2) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf1) F; - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2)); -} - -template - _bi::bind_t, typename _bi::list_av_2::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1) const, A1 a1, A2 a2) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf1) F; - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2)); -} - -// 2 - -template - _bi::bind_t, typename _bi::list_av_3::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2), A1 a1, A2 a2, A3 a3) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf2) F; - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3)); -} - -template - _bi::bind_t, typename _bi::list_av_3::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf2) F; - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3)); -} - -// 3 - -template - _bi::bind_t, typename _bi::list_av_4::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf3) F; - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t, typename _bi::list_av_4::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf3) F; - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4)); -} - -// 4 - -template - _bi::bind_t, typename _bi::list_av_5::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf4) F; - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t, typename _bi::list_av_5::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf4) F; - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5)); -} - -// 5 - -template - _bi::bind_t, typename _bi::list_av_6::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf5) F; - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t, typename _bi::list_av_6::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf5) F; - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6)); -} - -// 6 - -template - _bi::bind_t, typename _bi::list_av_7::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf6) F; - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t, typename _bi::list_av_7::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf6) F; - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -// 7 - -template - _bi::bind_t, typename _bi::list_av_8::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf7) F; - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t, typename _bi::list_av_8::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf7) F; - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -// 8 - -template - _bi::bind_t, typename _bi::list_av_9::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf8) F; - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -template - _bi::bind_t, typename _bi::list_av_9::type> - BOOST_BIND(boost::type, R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf8) F; - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf_cc.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf_cc.hpp deleted file mode 100644 index 88be8222..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_mf_cc.hpp +++ /dev/null @@ -1,227 +0,0 @@ -// -// bind/bind_mf_cc.hpp - support for different calling conventions -// -// Do not include this header directly. -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -// 0 - -template - _bi::bind_t, typename _bi::list_av_1::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (), A1 a1) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf0) F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t(F(f), list_type(a1)); -} - -template - _bi::bind_t, typename _bi::list_av_1::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) () const, A1 a1) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf0) F; - typedef typename _bi::list_av_1::type list_type; - return _bi::bind_t(F(f), list_type(a1)); -} - -// 1 - -template - _bi::bind_t, typename _bi::list_av_2::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1), A1 a1, A2 a2) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf1) F; - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2)); -} - -template - _bi::bind_t, typename _bi::list_av_2::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1) const, A1 a1, A2 a2) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf1) F; - typedef typename _bi::list_av_2::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2)); -} - -// 2 - -template - _bi::bind_t, typename _bi::list_av_3::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2), A1 a1, A2 a2, A3 a3) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf2) F; - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3)); -} - -template - _bi::bind_t, typename _bi::list_av_3::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf2) F; - typedef typename _bi::list_av_3::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3)); -} - -// 3 - -template - _bi::bind_t, typename _bi::list_av_4::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf3) F; - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4)); -} - -template - _bi::bind_t, typename _bi::list_av_4::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf3) F; - typedef typename _bi::list_av_4::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4)); -} - -// 4 - -template - _bi::bind_t, typename _bi::list_av_5::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf4) F; - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5)); -} - -template - _bi::bind_t, typename _bi::list_av_5::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf4) F; - typedef typename _bi::list_av_5::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5)); -} - -// 5 - -template - _bi::bind_t, typename _bi::list_av_6::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf5) F; - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6)); -} - -template - _bi::bind_t, typename _bi::list_av_6::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf5) F; - typedef typename _bi::list_av_6::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6)); -} - -// 6 - -template - _bi::bind_t, typename _bi::list_av_7::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf6) F; - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -template - _bi::bind_t, typename _bi::list_av_7::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf6) F; - typedef typename _bi::list_av_7::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); -} - -// 7 - -template - _bi::bind_t, typename _bi::list_av_8::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf7) F; - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -template - _bi::bind_t, typename _bi::list_av_8::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf7) F; - typedef typename _bi::list_av_8::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); -} - -// 8 - -template - _bi::bind_t, typename _bi::list_av_9::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef _mfi::BOOST_BIND_MF_NAME(mf8) F; - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} - -template - _bi::bind_t, typename _bi::list_av_9::type> - BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9) -{ - typedef _mfi::BOOST_BIND_MF_NAME(cmf8) F; - typedef typename _bi::list_av_9::type list_type; - return _bi::bind_t(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); -} diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_template.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/bind_template.hpp deleted file mode 100644 index 411d20c7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/bind_template.hpp +++ /dev/null @@ -1,345 +0,0 @@ -// -// bind/bind_template.hpp -// -// Do not include this header directly. -// -// Copyright (c) 2001-2004 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - - typedef typename result_traits::type result_type; - - result_type operator()() - { - list0 a; - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - result_type operator()() const - { - list0 a; - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1) - { - list1 a(a1); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1) const - { - list1 a(a1); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1) - { - list1 a(a1); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1) const - { - list1 a(a1); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2) - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2) const - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 & a2) - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 & a2) const - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - - template result_type operator()(A1 & a1, A2 const & a2) - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 const & a2) const - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - - template result_type operator()(A1 const & a1, A2 const & a2) - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2) const - { - list2 a(a1, a2); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3) - { - list3 a(a1, a2, a3); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3) const - { - list3 a(a1, a2, a3); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) - { - list3 a(a1, a2, a3); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) const - { - list3 a(a1, a2, a3); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) - { - list4 a(a1, a2, a3, a4); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) const - { - list4 a(a1, a2, a3, a4); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) - { - list4 a(a1, a2, a3, a4); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) const - { - list4 a(a1, a2, a3, a4); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) - { - list5 a(a1, a2, a3, a4, a5); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) const - { - list5 a(a1, a2, a3, a4, a5); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) - { - list5 a(a1, a2, a3, a4, a5); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) const - { - list5 a(a1, a2, a3, a4, a5); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) - { - list6 a(a1, a2, a3, a4, a5, a6); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) const - { - list6 a(a1, a2, a3, a4, a5, a6); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) - { - list6 a(a1, a2, a3, a4, a5, a6); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) const - { - list6 a(a1, a2, a3, a4, a5, a6); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) - { - list7 a(a1, a2, a3, a4, a5, a6, a7); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) const - { - list7 a(a1, a2, a3, a4, a5, a6, a7); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7) - { - list7 a(a1, a2, a3, a4, a5, a6, a7); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7) const - { - list7 a(a1, a2, a3, a4, a5, a6, a7); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) - { - list8 a(a1, a2, a3, a4, a5, a6, a7, a8); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) const - { - list8 a(a1, a2, a3, a4, a5, a6, a7, a8); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8) - { - list8 a(a1, a2, a3, a4, a5, a6, a7, a8); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8) const - { - list8 a(a1, a2, a3, a4, a5, a6, a7, a8); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) - { - list9 a(a1, a2, a3, a4, a5, a6, a7, a8, a9); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) const - { - list9 a(a1, a2, a3, a4, a5, a6, a7, a8, a9); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8, A9 const & a9) - { - list9 a(a1, a2, a3, a4, a5, a6, a7, a8, a9); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8, A9 const & a9) const - { - list9 a(a1, a2, a3, a4, a5, a6, a7, a8, a9); - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - -#endif - - template result_type eval(A & a) - { - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template result_type eval(A & a) const - { - BOOST_BIND_RETURN l_(type(), f_, a, 0); - } - - template void accept(V & v) const - { -#if !defined( BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP ) && !defined( __BORLANDC__ ) - - using boost::visit_each; - -#endif - BOOST_BIND_VISIT_EACH(v, f_, 0); - l_.accept(v); - } - - bool compare(this_type const & rhs) const - { - return ref_compare(f_, rhs.f_, 0) && l_ == rhs.l_; - } - -private: - - F f_; - L l_; diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn.hpp deleted file mode 100644 index 956e7d88..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn.hpp +++ /dev/null @@ -1,389 +0,0 @@ -#ifndef BOOST_BIND_MEM_FN_HPP_INCLUDED -#define BOOST_BIND_MEM_FN_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// mem_fn.hpp - a generalization of std::mem_fun[_ref] -// -// Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2001 David Abrahams -// Copyright (c) 2003-2005 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -#include -#include -#include - -namespace boost -{ - -#if defined(BOOST_NO_VOID_RETURNS) - -#define BOOST_MEM_FN_CLASS_F , class F -#define BOOST_MEM_FN_TYPEDEF(X) - -namespace _mfi // mem_fun_impl -{ - -template struct mf -{ - -#define BOOST_MEM_FN_RETURN return - -#define BOOST_MEM_FN_NAME(X) inner_##X -#define BOOST_MEM_FN_CC - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -}; // struct mf - -template<> struct mf -{ - -#define BOOST_MEM_FN_RETURN - -#define BOOST_MEM_FN_NAME(X) inner_##X -#define BOOST_MEM_FN_CC - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -}; // struct mf - -#undef BOOST_MEM_FN_CLASS_F -#undef BOOST_MEM_FN_TYPEDEF_F - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_NAME2(X) inner_##X -#define BOOST_MEM_FN_CC - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_NAME2(X) inner_##X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_NAME2(X) inner_##X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_NAME2(X) inner_##X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_NAME2 -#undef BOOST_MEM_FN_CC - -#endif - -} // namespace _mfi - -#else // #ifdef BOOST_NO_VOID_RETURNS - -#define BOOST_MEM_FN_CLASS_F -#define BOOST_MEM_FN_TYPEDEF(X) typedef X; - -namespace _mfi -{ - -#define BOOST_MEM_FN_RETURN return - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_CC - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include - -#undef BOOST_MEM_FN_CC -#undef BOOST_MEM_FN_NAME - -#endif - -#undef BOOST_MEM_FN_RETURN - -} // namespace _mfi - -#undef BOOST_MEM_FN_CLASS_F -#undef BOOST_MEM_FN_TYPEDEF - -#endif // #ifdef BOOST_NO_VOID_RETURNS - -#define BOOST_MEM_FN_NAME(X) X -#define BOOST_MEM_FN_CC - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC - -#ifdef BOOST_MEM_FN_ENABLE_CDECL - -#define BOOST_MEM_FN_NAME(X) X##_cdecl -#define BOOST_MEM_FN_CC __cdecl - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_STDCALL - -#define BOOST_MEM_FN_NAME(X) X##_stdcall -#define BOOST_MEM_FN_CC __stdcall - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC - -#endif - -#ifdef BOOST_MEM_FN_ENABLE_FASTCALL - -#define BOOST_MEM_FN_NAME(X) X##_fastcall -#define BOOST_MEM_FN_CC __fastcall - -#include - -#undef BOOST_MEM_FN_NAME -#undef BOOST_MEM_FN_CC - -#endif - -// data member support - -namespace _mfi -{ - -template class dm -{ -public: - - typedef R const & result_type; - typedef T const * argument_type; - -private: - - typedef R (T::*F); - F f_; - - template R const & call(U & u, T const *) const - { - return (u.*f_); - } - - template R const & call(U & u, void const *) const - { - return (get_pointer(u)->*f_); - } - -public: - - explicit dm(F f): f_(f) {} - - R & operator()(T * p) const - { - return (p->*f_); - } - - R const & operator()(T const * p) const - { - return (p->*f_); - } - - template R const & operator()(U const & u) const - { - return call(u, &u); - } - -#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300) && !BOOST_WORKAROUND(__MWERKS__, < 0x3200) - - R & operator()(T & t) const - { - return (t.*f_); - } - - R const & operator()(T const & t) const - { - return (t.*f_); - } - -#endif - - bool operator==(dm const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(dm const & rhs) const - { - return f_ != rhs.f_; - } -}; - -} // namespace _mfi - -template _mfi::dm mem_fn(R T::*f) -{ - return _mfi::dm(f); -} - -} // namespace boost - -#endif // #ifndef BOOST_BIND_MEM_FN_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_cc.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_cc.hpp deleted file mode 100644 index 8b6ea0ba..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_cc.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// -// bind/mem_fn_cc.hpp - support for different calling conventions -// -// Do not include this header directly. -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -template _mfi::BOOST_MEM_FN_NAME(mf0) mem_fn(R (BOOST_MEM_FN_CC T::*f) ()) -{ - return _mfi::BOOST_MEM_FN_NAME(mf0)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf0) mem_fn(R (BOOST_MEM_FN_CC T::*f) () const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf0)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf1) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf1)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf1) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf1)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf2) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf2)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf2) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf2)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf3) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf3)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf3) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf3)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf4) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf4)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf4) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf4)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf5) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf5)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf5) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf5)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf6) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf6)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf6) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf6)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf7) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf7)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf7) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf7)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(mf8) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7, A8)) -{ - return _mfi::BOOST_MEM_FN_NAME(mf8)(f); -} - -template _mfi::BOOST_MEM_FN_NAME(cmf8) mem_fn(R (BOOST_MEM_FN_CC T::*f) (A1, A2, A3, A4, A5, A6, A7, A8) const) -{ - return _mfi::BOOST_MEM_FN_NAME(cmf8)(f); -} diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_template.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_template.hpp deleted file mode 100644 index b26d585d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_template.hpp +++ /dev/null @@ -1,1047 +0,0 @@ -// -// bind/mem_fn_template.hpp -// -// Do not include this header directly -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) -# define BOOST_MEM_FN_ENABLE_CONST_OVERLOADS -#endif - -// mf0 - -template class BOOST_MEM_FN_NAME(mf0) -{ -public: - - typedef R result_type; - typedef T * argument_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) ()) - F f_; - - template R call(U & u, T const *) const - { - BOOST_MEM_FN_RETURN (u.*f_)(); - } - - template R call(U & u, void const *) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf0)(F f): f_(f) {} - - R operator()(T * p) const - { - BOOST_MEM_FN_RETURN (p->*f_)(); - } - - template R operator()(U & u) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p); - } - -#endif - - R operator()(T & t) const - { - BOOST_MEM_FN_RETURN (t.*f_)(); - } - - bool operator==(BOOST_MEM_FN_NAME(mf0) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf0) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf0 - -template class BOOST_MEM_FN_NAME(cmf0) -{ -public: - - typedef R result_type; - typedef T const * argument_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) () const) - F f_; - - template R call(U & u, T const *) const - { - BOOST_MEM_FN_RETURN (u.*f_)(); - } - - template R call(U & u, void const *) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf0)(F f): f_(f) {} - - template R operator()(U const & u) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p); - } - - R operator()(T const & t) const - { - BOOST_MEM_FN_RETURN (t.*f_)(); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf0) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf0) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf1 - -template class BOOST_MEM_FN_NAME(mf1) -{ -public: - - typedef R result_type; - typedef T * first_argument_type; - typedef A1 second_argument_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1)) - F f_; - - template R call(U & u, T const *, B1 & b1) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1); - } - - template R call(U & u, void const *, B1 & b1) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf1)(F f): f_(f) {} - - R operator()(T * p, A1 a1) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1); - } - - template R operator()(U & u, A1 a1) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1); - } - -#endif - - R operator()(T & t, A1 a1) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1); - } - - bool operator==(BOOST_MEM_FN_NAME(mf1) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf1) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf1 - -template class BOOST_MEM_FN_NAME(cmf1) -{ -public: - - typedef R result_type; - typedef T const * first_argument_type; - typedef A1 second_argument_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1) const) - F f_; - - template R call(U & u, T const *, B1 & b1) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1); - } - - template R call(U & u, void const *, B1 & b1) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf1)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1); - } - - R operator()(T const & t, A1 a1) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf1) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf1) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf2 - -template class BOOST_MEM_FN_NAME(mf2) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf2)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2); - } - - template R operator()(U & u, A1 a1, A2 a2) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2); - } - - bool operator==(BOOST_MEM_FN_NAME(mf2) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf2) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf2 - -template class BOOST_MEM_FN_NAME(cmf2) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf2)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2); - } - - R operator()(T const & t, A1 a1, A2 a2) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf2) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf2) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf3 - -template class BOOST_MEM_FN_NAME(mf3) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf3)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3); - } - - bool operator==(BOOST_MEM_FN_NAME(mf3) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf3) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf3 - -template class BOOST_MEM_FN_NAME(cmf3) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf3)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf3) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf3) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf4 - -template class BOOST_MEM_FN_NAME(mf4) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf4)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4); - } - - bool operator==(BOOST_MEM_FN_NAME(mf4) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf4) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf4 - -template class BOOST_MEM_FN_NAME(cmf4) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf4)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf4) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf4) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf5 - -template class BOOST_MEM_FN_NAME(mf5) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf5)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4, a5); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5); - } - - bool operator==(BOOST_MEM_FN_NAME(mf5) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf5) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf5 - -template class BOOST_MEM_FN_NAME(cmf5) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf5)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf5) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf5) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf6 - -template class BOOST_MEM_FN_NAME(mf6) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf6)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4, a5, a6); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6); - } - - bool operator==(BOOST_MEM_FN_NAME(mf6) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf6) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf6 - -template class BOOST_MEM_FN_NAME(cmf6) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf6)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf6) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf6) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf7 - -template class BOOST_MEM_FN_NAME(mf7) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6, b7); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf7)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4, a5, a6, a7); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6, a7); - } - - bool operator==(BOOST_MEM_FN_NAME(mf7) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf7) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf7 - -template class BOOST_MEM_FN_NAME(cmf7) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6, b7); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf7)(F f): f_(f) {} - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6, a7); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf7) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf7) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// mf8 - -template class BOOST_MEM_FN_NAME(mf8) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7, A8)) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6, b7, b8); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7, b8); - } - -public: - - explicit BOOST_MEM_FN_NAME(mf8)(F f): f_(f) {} - - R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4, a5, a6, a7, a8); - } - - template R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7, a8); - } - -#ifdef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7, a8); - } - -#endif - - R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6, a7, a8); - } - - bool operator==(BOOST_MEM_FN_NAME(mf8) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(mf8) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -// cmf8 - -template class BOOST_MEM_FN_NAME(cmf8) -{ -public: - - typedef R result_type; - -private: - - BOOST_MEM_FN_TYPEDEF(R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7, A8) const) - F f_; - - template R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const - { - BOOST_MEM_FN_RETURN (u.*f_)(b1, b2, b3, b4, b5, b6, b7, b8); - } - - template R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const - { - BOOST_MEM_FN_RETURN (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7, b8); - } - -public: - - explicit BOOST_MEM_FN_NAME(cmf8)(F f): f_(f) {} - - R operator()(T const * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - BOOST_MEM_FN_RETURN (p->*f_)(a1, a2, a3, a4, a5, a6, a7, a8); - } - - template R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - U const * p = 0; - BOOST_MEM_FN_RETURN call(u, p, a1, a2, a3, a4, a5, a6, a7, a8); - } - - R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const - { - BOOST_MEM_FN_RETURN (t.*f_)(a1, a2, a3, a4, a5, a6, a7, a8); - } - - bool operator==(BOOST_MEM_FN_NAME(cmf8) const & rhs) const - { - return f_ == rhs.f_; - } - - bool operator!=(BOOST_MEM_FN_NAME(cmf8) const & rhs) const - { - return f_ != rhs.f_; - } -}; - -#undef BOOST_MEM_FN_ENABLE_CONST_OVERLOADS diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_vw.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_vw.hpp deleted file mode 100644 index f3fc58db..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/mem_fn_vw.hpp +++ /dev/null @@ -1,130 +0,0 @@ -// -// bind/mem_fn_vw.hpp - void return helper wrappers -// -// Do not include this header directly -// -// Copyright (c) 2001 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/mem_fn.html for documentation. -// - -template struct BOOST_MEM_FN_NAME(mf0): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf0) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (); - explicit BOOST_MEM_FN_NAME(mf0)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf0)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf0): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf0) -{ - typedef R (BOOST_MEM_FN_CC T::*F) () const; - explicit BOOST_MEM_FN_NAME(cmf0)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf0)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf1): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf1) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1); - explicit BOOST_MEM_FN_NAME(mf1)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf1)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf1): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf1) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1) const; - explicit BOOST_MEM_FN_NAME(cmf1)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf1)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf2): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf2) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2); - explicit BOOST_MEM_FN_NAME(mf2)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf2)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf2): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf2) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2) const; - explicit BOOST_MEM_FN_NAME(cmf2)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf2)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf3): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf3) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3); - explicit BOOST_MEM_FN_NAME(mf3)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf3)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf3): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf3) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3) const; - explicit BOOST_MEM_FN_NAME(cmf3)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf3)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf4): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf4) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4); - explicit BOOST_MEM_FN_NAME(mf4)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf4)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf4): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf4) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4) const; - explicit BOOST_MEM_FN_NAME(cmf4)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf4)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf5): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf5) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5); - explicit BOOST_MEM_FN_NAME(mf5)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf5)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf5): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf5) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5) const; - explicit BOOST_MEM_FN_NAME(cmf5)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf5)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf6): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf6) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6); - explicit BOOST_MEM_FN_NAME(mf6)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf6)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf6): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf6) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6) const; - explicit BOOST_MEM_FN_NAME(cmf6)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf6)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf7): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf7) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7); - explicit BOOST_MEM_FN_NAME(mf7)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf7)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf7): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf7) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7) const; - explicit BOOST_MEM_FN_NAME(cmf7)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf7)(f) {} -}; - - -template struct BOOST_MEM_FN_NAME(mf8): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf8) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7, A8); - explicit BOOST_MEM_FN_NAME(mf8)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(mf8)(f) {} -}; - -template struct BOOST_MEM_FN_NAME(cmf8): public mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf8) -{ - typedef R (BOOST_MEM_FN_CC T::*F) (A1, A2, A3, A4, A5, A6, A7, A8) const; - explicit BOOST_MEM_FN_NAME(cmf8)(F f): mf::BOOST_NESTED_TEMPLATE BOOST_MEM_FN_NAME2(cmf8)(f) {} -}; - diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/placeholders.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/placeholders.hpp deleted file mode 100644 index 3b098b14..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/placeholders.hpp +++ /dev/null @@ -1,69 +0,0 @@ -#ifndef BOOST_BIND_PLACEHOLDERS_HPP_INCLUDED -#define BOOST_BIND_PLACEHOLDERS_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind/placeholders.hpp - _N definitions -// -// Copyright (c) 2002 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include -#include - -namespace -{ - -#if defined(__BORLANDC__) || defined(__GNUC__) && (__GNUC__ < 4) - -static inline boost::arg<1> _1() { return boost::arg<1>(); } -static inline boost::arg<2> _2() { return boost::arg<2>(); } -static inline boost::arg<3> _3() { return boost::arg<3>(); } -static inline boost::arg<4> _4() { return boost::arg<4>(); } -static inline boost::arg<5> _5() { return boost::arg<5>(); } -static inline boost::arg<6> _6() { return boost::arg<6>(); } -static inline boost::arg<7> _7() { return boost::arg<7>(); } -static inline boost::arg<8> _8() { return boost::arg<8>(); } -static inline boost::arg<9> _9() { return boost::arg<9>(); } - -#elif defined(BOOST_MSVC) || (defined(__DECCXX_VER) && __DECCXX_VER <= 60590031) || defined(__MWERKS__) || \ - defined(__GNUC__) && (__GNUC__ == 4 && __GNUC_MINOR__ < 2) - -static boost::arg<1> _1; -static boost::arg<2> _2; -static boost::arg<3> _3; -static boost::arg<4> _4; -static boost::arg<5> _5; -static boost::arg<6> _6; -static boost::arg<7> _7; -static boost::arg<8> _8; -static boost::arg<9> _9; - -#else - -boost::arg<1> _1; -boost::arg<2> _2; -boost::arg<3> _3; -boost::arg<4> _4; -boost::arg<5> _5; -boost::arg<6> _6; -boost::arg<7> _7; -boost::arg<8> _8; -boost::arg<9> _9; - -#endif - -} // unnamed namespace - -#endif // #ifndef BOOST_BIND_PLACEHOLDERS_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/protect.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/protect.hpp deleted file mode 100644 index 749e158c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/protect.hpp +++ /dev/null @@ -1,304 +0,0 @@ -#ifndef BOOST_BIND_PROTECT_HPP_INCLUDED -#define BOOST_BIND_PROTECT_HPP_INCLUDED - -// -// protect.hpp -// -// Copyright (c) 2002 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2009 Steven Watanabe -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// - -#include -#include - -namespace boost -{ - -namespace _bi -{ - -template class protected_bind_t -{ -public: - - typedef typename F::result_type result_type; - - explicit protected_bind_t(F f): f_(f) - { - } - - result_type operator()() - { - return f_(); - } - - result_type operator()() const - { - return f_(); - } - - template result_type operator()(A1 & a1) - { - return f_(a1); - } - - template result_type operator()(A1 & a1) const - { - return f_(a1); - } - - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(const A1 & a1) - { - return f_(a1); - } - - template result_type operator()(const A1 & a1) const - { - return f_(a1); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2) - { - return f_(a1, a2); - } - - template result_type operator()(A1 & a1, A2 & a2) const - { - return f_(a1, a2); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 & a2) - { - return f_(a1, a2); - } - - template result_type operator()(A1 const & a1, A2 & a2) const - { - return f_(a1, a2); - } - - template result_type operator()(A1 & a1, A2 const & a2) - { - return f_(a1, a2); - } - - template result_type operator()(A1 & a1, A2 const & a2) const - { - return f_(a1, a2); - } - - template result_type operator()(A1 const & a1, A2 const & a2) - { - return f_(a1, a2); - } - - template result_type operator()(A1 const & a1, A2 const & a2) const - { - return f_(a1, a2); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3) - { - return f_(a1, a2, a3); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3) const - { - return f_(a1, a2, a3); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) - { - return f_(a1, a2, a3); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) const - { - return f_(a1, a2, a3); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) - { - return f_(a1, a2, a3, a4); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) const - { - return f_(a1, a2, a3, a4); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) - { - return f_(a1, a2, a3, a4); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) const - { - return f_(a1, a2, a3, a4); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) - { - return f_(a1, a2, a3, a4, a5); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) const - { - return f_(a1, a2, a3, a4, a5); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) - { - return f_(a1, a2, a3, a4, a5); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) const - { - return f_(a1, a2, a3, a4, a5); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) - { - return f_(a1, a2, a3, a4, a5, a6); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) const - { - return f_(a1, a2, a3, a4, a5, a6); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) - { - return f_(a1, a2, a3, a4, a5, a6); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) const - { - return f_(a1, a2, a3, a4, a5, a6); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) - { - return f_(a1, a2, a3, a4, a5, a6, a7); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) const - { - return f_(a1, a2, a3, a4, a5, a6, a7); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7) - { - return f_(a1, a2, a3, a4, a5, a6, a7); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7) const - { - return f_(a1, a2, a3, a4, a5, a6, a7); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) const - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8) - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8) const - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8); - } - -#endif - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8, a9); - } - - template result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) const - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8, a9); - } - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) \ - && !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8, A9 const & a9) - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8, a9); - } - - template result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6, A7 const & a7, A8 const & a8, A9 const & a9) const - { - return f_(a1, a2, a3, a4, a5, a6, a7, a8, a9); - } - -#endif - -private: - - F f_; -}; - -} // namespace _bi - -template _bi::protected_bind_t protect(F f) -{ - return _bi::protected_bind_t(f); -} - -} // namespace boost - -#endif // #ifndef BOOST_BIND_PROTECT_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/bind/storage.hpp b/third_party/ycmd/cpp/BoostParts/boost/bind/storage.hpp deleted file mode 100644 index be490b0f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/bind/storage.hpp +++ /dev/null @@ -1,475 +0,0 @@ -#ifndef BOOST_BIND_STORAGE_HPP_INCLUDED -#define BOOST_BIND_STORAGE_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// bind/storage.hpp -// -// boost/bind.hpp support header, optimized storage -// -// Copyright (c) 2006 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// -// See http://www.boost.org/libs/bind/bind.html for documentation. -// - -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable: 4512) // assignment operator could not be generated -#endif - -namespace boost -{ - -namespace _bi -{ - -// 1 - -template struct storage1 -{ - explicit storage1( A1 a1 ): a1_( a1 ) {} - - template void accept(V & v) const - { - BOOST_BIND_VISIT_EACH(v, a1_, 0); - } - - A1 a1_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) && !defined( __BORLANDC__ ) - -template struct storage1< boost::arg > -{ - explicit storage1( boost::arg ) {} - - template void accept(V &) const { } - - static boost::arg a1_() { return boost::arg(); } -}; - -template struct storage1< boost::arg (*) () > -{ - explicit storage1( boost::arg (*) () ) {} - - template void accept(V &) const { } - - static boost::arg a1_() { return boost::arg(); } -}; - -#endif - -// 2 - -template struct storage2: public storage1 -{ - typedef storage1 inherited; - - storage2( A1 a1, A2 a2 ): storage1( a1 ), a2_( a2 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a2_, 0); - } - - A2 a2_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage2< A1, boost::arg >: public storage1 -{ - typedef storage1 inherited; - - storage2( A1 a1, boost::arg ): storage1( a1 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a2_() { return boost::arg(); } -}; - -template struct storage2< A1, boost::arg (*) () >: public storage1 -{ - typedef storage1 inherited; - - storage2( A1 a1, boost::arg (*) () ): storage1( a1 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a2_() { return boost::arg(); } -}; - -#endif - -// 3 - -template struct storage3: public storage2< A1, A2 > -{ - typedef storage2 inherited; - - storage3( A1 a1, A2 a2, A3 a3 ): storage2( a1, a2 ), a3_( a3 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a3_, 0); - } - - A3 a3_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage3< A1, A2, boost::arg >: public storage2< A1, A2 > -{ - typedef storage2 inherited; - - storage3( A1 a1, A2 a2, boost::arg ): storage2( a1, a2 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a3_() { return boost::arg(); } -}; - -template struct storage3< A1, A2, boost::arg (*) () >: public storage2< A1, A2 > -{ - typedef storage2 inherited; - - storage3( A1 a1, A2 a2, boost::arg (*) () ): storage2( a1, a2 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a3_() { return boost::arg(); } -}; - -#endif - -// 4 - -template struct storage4: public storage3< A1, A2, A3 > -{ - typedef storage3 inherited; - - storage4( A1 a1, A2 a2, A3 a3, A4 a4 ): storage3( a1, a2, a3 ), a4_( a4 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a4_, 0); - } - - A4 a4_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage4< A1, A2, A3, boost::arg >: public storage3< A1, A2, A3 > -{ - typedef storage3 inherited; - - storage4( A1 a1, A2 a2, A3 a3, boost::arg ): storage3( a1, a2, a3 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a4_() { return boost::arg(); } -}; - -template struct storage4< A1, A2, A3, boost::arg (*) () >: public storage3< A1, A2, A3 > -{ - typedef storage3 inherited; - - storage4( A1 a1, A2 a2, A3 a3, boost::arg (*) () ): storage3( a1, a2, a3 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a4_() { return boost::arg(); } -}; - -#endif - -// 5 - -template struct storage5: public storage4< A1, A2, A3, A4 > -{ - typedef storage4 inherited; - - storage5( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5 ): storage4( a1, a2, a3, a4 ), a5_( a5 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a5_, 0); - } - - A5 a5_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage5< A1, A2, A3, A4, boost::arg >: public storage4< A1, A2, A3, A4 > -{ - typedef storage4 inherited; - - storage5( A1 a1, A2 a2, A3 a3, A4 a4, boost::arg ): storage4( a1, a2, a3, a4 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a5_() { return boost::arg(); } -}; - -template struct storage5< A1, A2, A3, A4, boost::arg (*) () >: public storage4< A1, A2, A3, A4 > -{ - typedef storage4 inherited; - - storage5( A1 a1, A2 a2, A3 a3, A4 a4, boost::arg (*) () ): storage4( a1, a2, a3, a4 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a5_() { return boost::arg(); } -}; - -#endif - -// 6 - -template struct storage6: public storage5< A1, A2, A3, A4, A5 > -{ - typedef storage5 inherited; - - storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6 ): storage5( a1, a2, a3, a4, a5 ), a6_( a6 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a6_, 0); - } - - A6 a6_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage6< A1, A2, A3, A4, A5, boost::arg >: public storage5< A1, A2, A3, A4, A5 > -{ - typedef storage5 inherited; - - storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, boost::arg ): storage5( a1, a2, a3, a4, a5 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a6_() { return boost::arg(); } -}; - -template struct storage6< A1, A2, A3, A4, A5, boost::arg (*) () >: public storage5< A1, A2, A3, A4, A5 > -{ - typedef storage5 inherited; - - storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, boost::arg (*) () ): storage5( a1, a2, a3, a4, a5 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a6_() { return boost::arg(); } -}; - -#endif - -// 7 - -template struct storage7: public storage6< A1, A2, A3, A4, A5, A6 > -{ - typedef storage6 inherited; - - storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7 ): storage6( a1, a2, a3, a4, a5, a6 ), a7_( a7 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a7_, 0); - } - - A7 a7_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage7< A1, A2, A3, A4, A5, A6, boost::arg >: public storage6< A1, A2, A3, A4, A5, A6 > -{ - typedef storage6 inherited; - - storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, boost::arg ): storage6( a1, a2, a3, a4, a5, a6 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a7_() { return boost::arg(); } -}; - -template struct storage7< A1, A2, A3, A4, A5, A6, boost::arg (*) () >: public storage6< A1, A2, A3, A4, A5, A6 > -{ - typedef storage6 inherited; - - storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, boost::arg (*) () ): storage6( a1, a2, a3, a4, a5, a6 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a7_() { return boost::arg(); } -}; - -#endif - -// 8 - -template struct storage8: public storage7< A1, A2, A3, A4, A5, A6, A7 > -{ - typedef storage7 inherited; - - storage8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8 ): storage7( a1, a2, a3, a4, a5, a6, a7 ), a8_( a8 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a8_, 0); - } - - A8 a8_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage8< A1, A2, A3, A4, A5, A6, A7, boost::arg >: public storage7< A1, A2, A3, A4, A5, A6, A7 > -{ - typedef storage7 inherited; - - storage8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, boost::arg ): storage7( a1, a2, a3, a4, a5, a6, a7 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a8_() { return boost::arg(); } -}; - -template struct storage8< A1, A2, A3, A4, A5, A6, A7, boost::arg (*) () >: public storage7< A1, A2, A3, A4, A5, A6, A7 > -{ - typedef storage7 inherited; - - storage8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, boost::arg (*) () ): storage7( a1, a2, a3, a4, a5, a6, a7 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a8_() { return boost::arg(); } -}; - -#endif - -// 9 - -template struct storage9: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > -{ - typedef storage8 inherited; - - storage9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9 ): storage8( a1, a2, a3, a4, a5, a6, a7, a8 ), a9_( a9 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - BOOST_BIND_VISIT_EACH(v, a9_, 0); - } - - A9 a9_; -}; - -#if !defined( BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION ) - -template struct storage9< A1, A2, A3, A4, A5, A6, A7, A8, boost::arg >: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > -{ - typedef storage8 inherited; - - storage9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, boost::arg ): storage8( a1, a2, a3, a4, a5, a6, a7, a8 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a9_() { return boost::arg(); } -}; - -template struct storage9< A1, A2, A3, A4, A5, A6, A7, A8, boost::arg (*) () >: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > -{ - typedef storage8 inherited; - - storage9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, boost::arg (*) () ): storage8( a1, a2, a3, a4, a5, a6, a7, a8 ) {} - - template void accept(V & v) const - { - inherited::accept(v); - } - - static boost::arg a9_() { return boost::arg(); } -}; - -#endif - -} // namespace _bi - -} // namespace boost - -#ifdef BOOST_MSVC -# pragma warning(default: 4512) // assignment operator could not be generated -# pragma warning(pop) -#endif - -#endif // #ifndef BOOST_BIND_STORAGE_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/call_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/call_traits.hpp deleted file mode 100644 index 5253a6de..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/call_traits.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. - -// See boost/detail/call_traits.hpp and boost/detail/ob_call_traits.hpp -// for full copyright notices. - -#ifndef BOOST_CALL_TRAITS_HPP -#define BOOST_CALL_TRAITS_HPP - -#ifndef BOOST_CONFIG_HPP -#include -#endif - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -#include -#else -#include -#endif - -#endif // BOOST_CALL_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/cast.hpp b/third_party/ycmd/cpp/BoostParts/boost/cast.hpp deleted file mode 100644 index 2615d183..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/cast.hpp +++ /dev/null @@ -1,107 +0,0 @@ -// boost cast.hpp header file ----------------------------------------------// - -// (C) Copyright Kevlin Henney and Dave Abrahams 1999. -// Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/conversion for Documentation. - -// Revision History -// 23 JUn 05 numeric_cast removed and redirected to the new verion (Fernando Cacciola) -// 02 Apr 01 Removed BOOST_NO_LIMITS workarounds and included -// instead (the workaround did not -// actually compile when BOOST_NO_LIMITS was defined in -// any case, so we loose nothing). (John Maddock) -// 21 Jan 01 Undid a bug I introduced yesterday. numeric_cast<> never -// worked with stock GCC; trying to get it to do that broke -// vc-stlport. -// 20 Jan 01 Moved BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS to config.hpp. -// Removed unused BOOST_EXPLICIT_TARGET macro. Moved -// boost::detail::type to boost/type.hpp. Made it compile with -// stock gcc again (Dave Abrahams) -// 29 Nov 00 Remove nested namespace cast, cleanup spacing before Formal -// Review (Beman Dawes) -// 19 Oct 00 Fix numeric_cast for floating-point types (Dave Abrahams) -// 15 Jul 00 Suppress numeric_cast warnings for GCC, Borland and MSVC -// (Dave Abrahams) -// 30 Jun 00 More MSVC6 wordarounds. See comments below. (Dave Abrahams) -// 28 Jun 00 Removed implicit_cast<>. See comment below. (Beman Dawes) -// 27 Jun 00 More MSVC6 workarounds -// 15 Jun 00 Add workarounds for MSVC6 -// 2 Feb 00 Remove bad_numeric_cast ";" syntax error (Doncho Angelov) -// 26 Jan 00 Add missing throw() to bad_numeric_cast::what(0 (Adam Levar) -// 29 Dec 99 Change using declarations so usages in other namespaces work -// correctly (Dave Abrahams) -// 23 Sep 99 Change polymorphic_downcast assert to also detect M.I. errors -// as suggested Darin Adler and improved by Valentin Bonnard. -// 2 Sep 99 Remove controversial asserts, simplify, rename. -// 30 Aug 99 Move to cast.hpp, replace value_cast with numeric_cast, -// place in nested namespace. -// 3 Aug 99 Initial version - -#ifndef BOOST_CAST_HPP -#define BOOST_CAST_HPP - -# include -# include -# include -# include -# include -# include - -// It has been demonstrated numerous times that MSVC 6.0 fails silently at link -// time if you use a template function which has template parameters that don't -// appear in the function's argument list. -// -// TODO: Add this to config.hpp? -# if defined(BOOST_MSVC) && BOOST_MSVC < 1300 -# define BOOST_EXPLICIT_DEFAULT_TARGET , ::boost::type* = 0 -# else -# define BOOST_EXPLICIT_DEFAULT_TARGET -# endif - -namespace boost -{ -// See the documentation for descriptions of how to choose between -// static_cast<>, dynamic_cast<>, polymorphic_cast<> and polymorphic_downcast<> - -// polymorphic_cast --------------------------------------------------------// - - // Runtime checked polymorphic downcasts and crosscasts. - // Suggested in The C++ Programming Language, 3rd Ed, Bjarne Stroustrup, - // section 15.8 exercise 1, page 425. - - template - inline Target polymorphic_cast(Source* x BOOST_EXPLICIT_DEFAULT_TARGET) - { - Target tmp = dynamic_cast(x); - if ( tmp == 0 ) throw std::bad_cast(); - return tmp; - } - -// polymorphic_downcast ----------------------------------------------------// - - // BOOST_ASSERT() checked polymorphic downcast. Crosscasts prohibited. - - // WARNING: Because this cast uses BOOST_ASSERT(), it violates - // the One Definition Rule if used in multiple translation units - // where BOOST_DISABLE_ASSERTS, BOOST_ENABLE_ASSERT_HANDLER - // NDEBUG are defined inconsistently. - - // Contributed by Dave Abrahams - - template - inline Target polymorphic_downcast(Source* x BOOST_EXPLICIT_DEFAULT_TARGET) - { - BOOST_ASSERT( dynamic_cast(x) == x ); // detect logic error - return static_cast(x); - } - -# undef BOOST_EXPLICIT_DEFAULT_TARGET - -} // namespace boost - -# include - -#endif // BOOST_CAST_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/cerrno.hpp b/third_party/ycmd/cpp/BoostParts/boost/cerrno.hpp deleted file mode 100644 index 6f266984..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/cerrno.hpp +++ /dev/null @@ -1,331 +0,0 @@ -// Boost cerrno.hpp header -------------------------------------------------// - -// Copyright Beman Dawes 2005. -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See library home page at http://www.boost.org/libs/system - -#ifndef BOOST_CERRNO_HPP -#define BOOST_CERRNO_HPP - -#include - -// 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 // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/checked_delete.hpp b/third_party/ycmd/cpp/BoostParts/boost/checked_delete.hpp deleted file mode 100644 index 9bb84e8e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/checked_delete.hpp +++ /dev/null @@ -1,69 +0,0 @@ -#ifndef BOOST_CHECKED_DELETE_HPP_INCLUDED -#define BOOST_CHECKED_DELETE_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/checked_delete.hpp -// -// Copyright (c) 2002, 2003 Peter Dimov -// Copyright (c) 2003 Daniel Frey -// Copyright (c) 2003 Howard Hinnant -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/utility/checked_delete.html for documentation. -// - -namespace boost -{ - -// verify that types are complete for increased safety - -template inline void checked_delete(T * x) -{ - // intentionally complex - simplification causes regressions - typedef char type_must_be_complete[ sizeof(T)? 1: -1 ]; - (void) sizeof(type_must_be_complete); - delete x; -} - -template inline void checked_array_delete(T * x) -{ - typedef char type_must_be_complete[ sizeof(T)? 1: -1 ]; - (void) sizeof(type_must_be_complete); - delete [] x; -} - -template struct checked_deleter -{ - typedef void result_type; - typedef T * argument_type; - - void operator()(T * x) const - { - // boost:: disables ADL - boost::checked_delete(x); - } -}; - -template struct checked_array_deleter -{ - typedef void result_type; - typedef T * argument_type; - - void operator()(T * x) const - { - boost::checked_array_delete(x); - } -}; - -} // namespace boost - -#endif // #ifndef BOOST_CHECKED_DELETE_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/ceil.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/ceil.hpp deleted file mode 100644 index 7fbf9ddc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/ceil.hpp +++ /dev/null @@ -1,36 +0,0 @@ -// boost/chrono/round.hpp ------------------------------------------------------------// - -// (C) Copyright Howard Hinnant -// Copyright 2011 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/chrono for documentation. - -#ifndef BOOST_CHRONO_CEIL_HPP -#define BOOST_CHRONO_CEIL_HPP - -#include - -namespace boost -{ - namespace chrono - { - - /** - * rounds up - */ - template - To ceil(const duration& d) - { - To t = duration_cast(d); - if (t < d) - ++t; - return t; - } - - } // namespace chrono -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/chrono.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/chrono.hpp deleted file mode 100644 index ebc29d8d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/chrono.hpp +++ /dev/null @@ -1,15 +0,0 @@ -// chrono.hpp --------------------------------------------------------------// - -// Copyright 2009-2011 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -#ifndef BOOST_CHRONO_CHRONO_HPP -#define BOOST_CHRONO_CHRONO_HPP - -#include -#include -#include - -#endif // BOOST_CHRONO_CHRONO_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/clock_string.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/clock_string.hpp deleted file mode 100644 index af025f27..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/clock_string.hpp +++ /dev/null @@ -1,25 +0,0 @@ -// -// (C) Copyright 2010-2011 Vicente J. Botet Escriba -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// - -#ifndef BOOST_CHRONO_CLOCK_STRING_HPP -#define BOOST_CHRONO_CLOCK_STRING_HPP - -#include - -namespace boost -{ - namespace chrono - { - - template - struct clock_string; - - } // chrono - -} // boost - -#endif // BOOST_CHRONO_CLOCK_STRING_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/config.hpp deleted file mode 100644 index 301b8775..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/config.hpp +++ /dev/null @@ -1,220 +0,0 @@ -// boost/chrono/config.hpp -------------------------------------------------// - -// Copyright Beman Dawes 2003, 2006, 2008 -// Copyright 2009-2011 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/chrono for documentation. - -#ifndef BOOST_CHRONO_CONFIG_HPP -#define BOOST_CHRONO_CONFIG_HPP - -#include - -#if !defined BOOST_CHRONO_VERSION -#define BOOST_CHRONO_VERSION 1 -#else -#if BOOST_CHRONO_VERSION!=1 && BOOST_CHRONO_VERSION!=2 -#error "BOOST_CHRONO_VERSION must be 1 or 2" -#endif -#endif - -#if defined(BOOST_CHRONO_SOURCE) && !defined(BOOST_USE_WINDOWS_H) -#define BOOST_USE_WINDOWS_H -#endif - -#if ! defined BOOST_CHRONO_PROVIDES_DATE_IO_FOR_SYSTEM_CLOCK_TIME_POINT \ - && ! defined BOOST_CHRONO_DONT_PROVIDE_DATE_IO_FOR_SYSTEM_CLOCK_TIME_POINT - -# define BOOST_CHRONO_PROVIDES_DATE_IO_FOR_SYSTEM_CLOCK_TIME_POINT - -#endif - -// BOOST_CHRONO_POSIX_API, BOOST_CHRONO_MAC_API, or BOOST_CHRONO_WINDOWS_API -// can be defined by the user to specify which API should be used - -#if defined(BOOST_CHRONO_WINDOWS_API) -# warning Boost.Chrono will use the Windows API -#elif defined(BOOST_CHRONO_MAC_API) -# warning Boost.Chrono will use the Mac API -#elif defined(BOOST_CHRONO_POSIX_API) -# warning Boost.Chrono will use the POSIX API -#endif - -# if defined( BOOST_CHRONO_WINDOWS_API ) && defined( BOOST_CHRONO_POSIX_API ) -# error both BOOST_CHRONO_WINDOWS_API and BOOST_CHRONO_POSIX_API are defined -# elif defined( BOOST_CHRONO_WINDOWS_API ) && defined( BOOST_CHRONO_MAC_API ) -# error both BOOST_CHRONO_WINDOWS_API and BOOST_CHRONO_MAC_API are defined -# elif defined( BOOST_CHRONO_MAC_API ) && defined( BOOST_CHRONO_POSIX_API ) -# error both BOOST_CHRONO_MAC_API and BOOST_CHRONO_POSIX_API are defined -# elif !defined( BOOST_CHRONO_WINDOWS_API ) && !defined( BOOST_CHRONO_MAC_API ) && !defined( BOOST_CHRONO_POSIX_API ) -# if (defined(_WIN32) || defined(__WIN32__) || defined(WIN32)) -# define BOOST_CHRONO_WINDOWS_API -# elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__) -# define BOOST_CHRONO_MAC_API -# else -# define BOOST_CHRONO_POSIX_API -# endif -# endif - -# if defined( BOOST_CHRONO_WINDOWS_API ) -# ifndef UNDER_CE -# define BOOST_CHRONO_HAS_PROCESS_CLOCKS -# endif -# define BOOST_CHRONO_HAS_CLOCK_STEADY -# define BOOST_CHRONO_HAS_THREAD_CLOCK -# define BOOST_CHRONO_THREAD_CLOCK_IS_STEADY true -# endif - -# if defined( BOOST_CHRONO_MAC_API ) -# define BOOST_CHRONO_HAS_PROCESS_CLOCKS -# define BOOST_CHRONO_HAS_CLOCK_STEADY -# define BOOST_CHRONO_THREAD_CLOCK_IS_STEADY true -# endif - -# if defined( BOOST_CHRONO_POSIX_API ) -# define BOOST_CHRONO_HAS_PROCESS_CLOCKS -# include //to check for CLOCK_REALTIME and CLOCK_MONOTONIC and _POSIX_THREAD_CPUTIME -# if defined(CLOCK_MONOTONIC) -# define BOOST_CHRONO_HAS_CLOCK_STEADY -# endif -# if defined(_POSIX_THREAD_CPUTIME) && !defined(BOOST_DISABLE_THREADS) -# define BOOST_CHRONO_HAS_THREAD_CLOCK -# define BOOST_CHRONO_THREAD_CLOCK_IS_STEADY true -# endif -# if defined(CLOCK_THREAD_CPUTIME_ID) && !defined(BOOST_DISABLE_THREADS) -# define BOOST_CHRONO_HAS_THREAD_CLOCK -# define BOOST_CHRONO_THREAD_CLOCK_IS_STEADY true -# endif -# if defined(sun) || defined(__sun) -# undef BOOST_CHRONO_HAS_THREAD_CLOCK -# undef BOOST_CHRONO_THREAD_CLOCK_IS_STEADY -# endif -# if defined(__HP_aCC) && defined(__hpux) -# undef BOOST_CHRONO_HAS_THREAD_CLOCK -# undef BOOST_CHRONO_THREAD_CLOCK_IS_STEADY -# endif -# if defined(__VXWORKS__) -# undef BOOST_CHRONO_HAS_PROCESS_CLOCKS -# endif -# endif - -#if defined(BOOST_CHRONO_THREAD_DISABLED) && defined(BOOST_CHRONO_HAS_THREAD_CLOCK) -#undef BOOST_CHRONO_HAS_THREAD_CLOCK -#undef BOOST_CHRONO_THREAD_CLOCK_IS_STEADY -#endif - -//#undef BOOST_CHRONO_HAS_PROCESS_CLOCKS - -// unicode support ------------------------------// - -#if defined(BOOST_NO_CXX11_UNICODE_LITERALS) || defined(BOOST_NO_CXX11_CHAR16_T) || defined(BOOST_NO_CXX11_CHAR32_T) -//~ #define BOOST_CHRONO_HAS_UNICODE_SUPPORT -#else -#define BOOST_CHRONO_HAS_UNICODE_SUPPORT 1 -#endif - -#if ! defined BOOST_NOEXCEPT -#if defined(BOOST_NO_CXX11_NOEXCEPT) -#define BOOST_NOEXCEPT -#else -#define BOOST_NOEXCEPT noexcept -#endif -#endif - -#if defined( BOOST_NO_CXX11_NUMERIC_LIMITS ) -#define BOOST_CHRONO_LIB_CONSTEXPR -#elif defined(_LIBCPP_VERSION) && !defined(_LIBCPP_CONSTEXPR) - #define BOOST_CHRONO_LIB_CONSTEXPR -#else - #define BOOST_CHRONO_LIB_CONSTEXPR BOOST_CONSTEXPR -#endif - -#if defined( BOOST_NO_CXX11_NUMERIC_LIMITS ) -# define BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW throw() -#else -#ifdef BOOST_NO_CXX11_NOEXCEPT -# define BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW throw() -#else -# define BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW noexcept -#endif -#endif - - -#if defined BOOST_CHRONO_PROVIDE_HYBRID_ERROR_HANDLING \ - && defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -#error "BOOST_CHRONO_PROVIDE_HYBRID_ERROR_HANDLING && BOOST_CHRONO_PROVIDE_HYBRID_ERROR_HANDLING defined" -#endif - -#if defined BOOST_CHRONO_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 \ - && defined BOOST_CHRONO_DONT_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 -#error "BOOST_CHRONO_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 && BOOST_CHRONO_DONT_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 defined" -#endif - -#if ! defined BOOST_CHRONO_PROVIDE_HYBRID_ERROR_HANDLING \ - && ! defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -#define BOOST_CHRONO_PROVIDE_HYBRID_ERROR_HANDLING -#endif - -#if (BOOST_CHRONO_VERSION == 2) -#if ! defined BOOST_CHRONO_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 \ - && ! defined BOOST_CHRONO_DONT_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 -#define BOOST_CHRONO_DONT_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 -#endif -#endif - -#ifdef BOOST_CHRONO_HEADER_ONLY -#define BOOST_CHRONO_INLINE inline -#define BOOST_CHRONO_STATIC inline -#define BOOST_CHRONO_DECL - -#else -#define BOOST_CHRONO_INLINE -#define BOOST_CHRONO_STATIC static - -// enable dynamic linking on Windows ---------------------------------------// - -// we need to import/export our code only if the user has specifically -// asked for it by defining either BOOST_ALL_DYN_LINK if they want all boost -// libraries to be dynamically linked, or BOOST_CHRONO_DYN_LINK -// if they want just this one to be dynamically liked: -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_CHRONO_DYN_LINK) -// export if this is our own source, otherwise import: -#ifdef BOOST_CHRONO_SOURCE -# define BOOST_CHRONO_DECL BOOST_SYMBOL_EXPORT -#else -# define BOOST_CHRONO_DECL BOOST_SYMBOL_IMPORT -#endif // BOOST_CHRONO_SOURCE -#endif // DYN_LINK -// -// if BOOST_CHRONO_DECL isn't defined yet define it now: -#ifndef BOOST_CHRONO_DECL -#define BOOST_CHRONO_DECL -#endif - - - -// enable automatic library variant selection ------------------------------// - -#if !defined(BOOST_CHRONO_SOURCE) && !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_CHRONO_NO_LIB) -// -// Set the name of our library; this will get undef'ed by auto_link.hpp -// once it's done with it: -// -#define BOOST_LIB_NAME boost_chrono -// -// If we're importing code from a dll, then tell auto_link.hpp about it: -// -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_CHRONO_DYN_LINK) -# define BOOST_DYN_LINK -#endif -// -// And include the header that does the work: -// -#include -#endif // auto-linking disabled -#endif // BOOST_CHRONO_HEADER_ONLY -#endif // BOOST_CHRONO_CONFIG_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/chrono.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/chrono.hpp deleted file mode 100644 index 02788436..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/chrono.hpp +++ /dev/null @@ -1,44 +0,0 @@ -// chrono.cpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2008 -// Copyright Vicente J. Botet Escriba 2009 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -#ifndef BOOST_CHRONO_DETAIL_INLINED_CHRONO_HPP -#define BOOST_CHRONO_DETAIL_INLINED_CHRONO_HPP - -#include -#include -#include -#include -#include - -//----------------------------------------------------------------------------// -// // -// Platform-specific Implementations // -// // -//----------------------------------------------------------------------------// - -//----------------------------------------------------------------------------// -// Windows // -//----------------------------------------------------------------------------// -#if defined(BOOST_CHRONO_WINDOWS_API) -#include - -//----------------------------------------------------------------------------// -// Mac // -//----------------------------------------------------------------------------// -#elif defined(BOOST_CHRONO_MAC_API) -#include - -//----------------------------------------------------------------------------// -// POSIX // -//----------------------------------------------------------------------------// -#elif defined(BOOST_CHRONO_POSIX_API) -#include - -#endif // POSIX - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/mac/chrono.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/mac/chrono.hpp deleted file mode 100644 index bf20ae92..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/mac/chrono.hpp +++ /dev/null @@ -1,241 +0,0 @@ -// mac/chrono.cpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2008 -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -//----------------------------------------------------------------------------// -// Mac // -//----------------------------------------------------------------------------// - -#include //for gettimeofday and timeval -#include // mach_absolute_time, mach_timebase_info_data_t - -namespace boost -{ -namespace chrono -{ - -// system_clock - -// gettimeofday is the most precise "system time" available on this platform. -// It returns the number of microseconds since New Years 1970 in a struct called timeval -// which has a field for seconds and a field for microseconds. -// Fill in the timeval and then convert that to the time_point -system_clock::time_point -system_clock::now() BOOST_NOEXCEPT -{ - timeval tv; - gettimeofday(&tv, 0); - return time_point(seconds(tv.tv_sec) + microseconds(tv.tv_usec)); -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -system_clock::time_point -system_clock::now(system::error_code & ec) -{ - timeval tv; - gettimeofday(&tv, 0); - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return time_point(seconds(tv.tv_sec) + microseconds(tv.tv_usec)); -} -#endif -// Take advantage of the fact that on this platform time_t is nothing but -// an integral count of seconds since New Years 1970 (same epoch as timeval). -// Just get the duration out of the time_point and truncate it to seconds. -time_t -system_clock::to_time_t(const time_point& t) BOOST_NOEXCEPT -{ - return time_t(duration_cast(t.time_since_epoch()).count()); -} - -// Just turn the time_t into a count of seconds and construct a time_point with it. -system_clock::time_point -system_clock::from_time_t(time_t t) BOOST_NOEXCEPT -{ - return system_clock::time_point(seconds(t)); -} - -namespace chrono_detail -{ - -// steady_clock - -// Note, in this implementation steady_clock and high_resolution_clock -// are the same clock. They are both based on mach_absolute_time(). -// mach_absolute_time() * MachInfo.numer / MachInfo.denom is the number of -// nanoseconds since the computer booted up. MachInfo.numer and MachInfo.denom -// are run time constants supplied by the OS. This clock has no relationship -// to the Gregorian calendar. It's main use is as a high resolution timer. - -// MachInfo.numer / MachInfo.denom is often 1 on the latest equipment. Specialize -// for that case as an optimization. -BOOST_CHRONO_STATIC -steady_clock::rep -steady_simplified() -{ - return mach_absolute_time(); -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -BOOST_CHRONO_STATIC -steady_clock::rep -steady_simplified_ec(system::error_code & ec) -{ - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return mach_absolute_time(); -} -#endif - -BOOST_CHRONO_STATIC -double -compute_steady_factor(kern_return_t& err) -{ - mach_timebase_info_data_t MachInfo; - err = mach_timebase_info(&MachInfo); - if ( err != 0 ) { - return 0; - } - return static_cast(MachInfo.numer) / MachInfo.denom; -} - -BOOST_CHRONO_STATIC -steady_clock::rep -steady_full() -{ - static kern_return_t err; - static const double factor = chrono_detail::compute_steady_factor(err); - if (err != 0) - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - } - return static_cast(mach_absolute_time() * factor); -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -BOOST_CHRONO_STATIC -steady_clock::rep -steady_full_ec(system::error_code & ec) -{ - static kern_return_t err; - static const double factor = chrono_detail::compute_steady_factor(err); - if (err != 0) - { - if (BOOST_CHRONO_IS_THROWS(ec)) - { - boost::throw_exception( - system::system_error( - err, - BOOST_CHRONO_SYSTEM_CATEGORY, - "chrono::steady_clock" )); - } - else - { - ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY ); - return steady_clock::rep(); - } - } - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return static_cast(mach_absolute_time() * factor); -} -#endif - -typedef steady_clock::rep (*FP)(); -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -typedef steady_clock::rep (*FP_ec)(system::error_code &); -#endif - -BOOST_CHRONO_STATIC -FP -init_steady_clock(kern_return_t & err) -{ - mach_timebase_info_data_t MachInfo; - err = mach_timebase_info(&MachInfo); - if ( err != 0 ) - { - return 0; - } - - if (MachInfo.numer == MachInfo.denom) - { - return &chrono_detail::steady_simplified; - } - return &chrono_detail::steady_full; -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -BOOST_CHRONO_STATIC -FP_ec -init_steady_clock_ec(kern_return_t & err) -{ - mach_timebase_info_data_t MachInfo; - err = mach_timebase_info(&MachInfo); - if ( err != 0 ) - { - return 0; - } - - if (MachInfo.numer == MachInfo.denom) - { - return &chrono_detail::steady_simplified_ec; - } - return &chrono_detail::steady_full_ec; -} -#endif -} - -steady_clock::time_point -steady_clock::now() BOOST_NOEXCEPT -{ - static kern_return_t err; - static chrono_detail::FP fp = chrono_detail::init_steady_clock(err); - if ( err != 0 ) - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - } - return time_point(duration(fp())); -} - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING -steady_clock::time_point -steady_clock::now(system::error_code & ec) -{ - static kern_return_t err; - static chrono_detail::FP_ec fp = chrono_detail::init_steady_clock_ec(err); - if ( err != 0 ) - { - if (BOOST_CHRONO_IS_THROWS(ec)) - { - boost::throw_exception( - system::system_error( - err, - BOOST_CHRONO_SYSTEM_CATEGORY, - "chrono::steady_clock" )); - } - else - { - ec.assign( err, BOOST_CHRONO_SYSTEM_CATEGORY ); - return time_point(); - } - } - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return time_point(duration(fp(ec))); -} -#endif -} // namespace chrono -} // namespace boost diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/posix/chrono.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/posix/chrono.hpp deleted file mode 100644 index e35a7ce2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/posix/chrono.hpp +++ /dev/null @@ -1,120 +0,0 @@ -// posix/chrono.cpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2008 -// Copyright Vicente J. Botet Escriba 2009 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -//----------------------------------------------------------------------------// -// POSIX // -//----------------------------------------------------------------------------// - -#include // for clock_gettime - -namespace boost -{ -namespace chrono -{ - - system_clock::time_point system_clock::now() BOOST_NOEXCEPT - { - timespec ts; - if ( ::clock_gettime( CLOCK_REALTIME, &ts ) ) - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - } - - return time_point(duration( - static_cast( ts.tv_sec ) * 1000000000 + ts.tv_nsec)); - } - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - system_clock::time_point system_clock::now(system::error_code & ec) - { - timespec ts; - if ( ::clock_gettime( CLOCK_REALTIME, &ts ) ) - { - if (BOOST_CHRONO_IS_THROWS(ec)) - { - boost::throw_exception( - system::system_error( - errno, - BOOST_CHRONO_SYSTEM_CATEGORY, - "chrono::system_clock" )); - } - else - { - ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY ); - return time_point(); - } - } - - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return time_point(duration( - static_cast( ts.tv_sec ) * 1000000000 + ts.tv_nsec)); - } -#endif - - std::time_t system_clock::to_time_t(const system_clock::time_point& t) BOOST_NOEXCEPT - { - return static_cast( t.time_since_epoch().count() / 1000000000 ); - } - - system_clock::time_point system_clock::from_time_t(std::time_t t) BOOST_NOEXCEPT - { - return time_point(duration(static_cast(t) * 1000000000)); - } - -#ifdef BOOST_CHRONO_HAS_CLOCK_STEADY - - steady_clock::time_point steady_clock::now() BOOST_NOEXCEPT - { - timespec ts; - if ( ::clock_gettime( CLOCK_MONOTONIC, &ts ) ) - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - } - - return time_point(duration( - static_cast( ts.tv_sec ) * 1000000000 + ts.tv_nsec)); - } - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - steady_clock::time_point steady_clock::now(system::error_code & ec) - { - timespec ts; - if ( ::clock_gettime( CLOCK_MONOTONIC, &ts ) ) - { - if (BOOST_CHRONO_IS_THROWS(ec)) - { - boost::throw_exception( - system::system_error( - errno, - BOOST_CHRONO_SYSTEM_CATEGORY, - "chrono::steady_clock" )); - } - else - { - ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY ); - return time_point(); - } - } - - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return time_point(duration( - static_cast( ts.tv_sec ) * 1000000000 + ts.tv_nsec)); - } -#endif -#endif - -} // namespace chrono -} // namespace boost - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/win/chrono.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/win/chrono.hpp deleted file mode 100644 index fcb5b290..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/inlined/win/chrono.hpp +++ /dev/null @@ -1,139 +0,0 @@ -// win/chrono.cpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2008 -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -//----------------------------------------------------------------------------// -// Windows // -//----------------------------------------------------------------------------// -#ifndef BOOST_CHRONO_DETAIL_INLINED_WIN_CHRONO_HPP -#define BOOST_CHRONO_DETAIL_INLINED_WIN_CHRONO_HPP - -#include -#include -#include - -namespace boost -{ -namespace chrono -{ -namespace chrono_detail -{ - - BOOST_CHRONO_INLINE double get_nanosecs_per_tic() BOOST_NOEXCEPT - { - boost::detail::winapi::LARGE_INTEGER_ freq; - if ( !boost::detail::winapi::QueryPerformanceFrequency( &freq ) ) - return 0.0L; - return double(1000000000.0L / freq.QuadPart); - } - -} - - steady_clock::time_point steady_clock::now() BOOST_NOEXCEPT - { - static double nanosecs_per_tic = chrono_detail::get_nanosecs_per_tic(); - - boost::detail::winapi::LARGE_INTEGER_ pcount; - if ( (nanosecs_per_tic <= 0.0L) || - (!boost::detail::winapi::QueryPerformanceCounter( &pcount )) ) - { - BOOST_ASSERT(0 && "Boost::Chrono - Internal Error"); - return steady_clock::time_point(); - } - - return steady_clock::time_point(steady_clock::duration( - static_cast((nanosecs_per_tic) * pcount.QuadPart))); - } - - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - steady_clock::time_point steady_clock::now( system::error_code & ec ) - { - static double nanosecs_per_tic = chrono_detail::get_nanosecs_per_tic(); - - boost::detail::winapi::LARGE_INTEGER_ pcount; - if ( (nanosecs_per_tic <= 0.0L) - || (!boost::detail::winapi::QueryPerformanceCounter( &pcount )) ) - { - boost::detail::winapi::DWORD_ cause = - ((nanosecs_per_tic <= 0.0L) - ? ERROR_NOT_SUPPORTED - : boost::detail::winapi::GetLastError()); - if (BOOST_CHRONO_IS_THROWS(ec)) { - boost::throw_exception( - system::system_error( - cause, - BOOST_CHRONO_SYSTEM_CATEGORY, - "chrono::steady_clock" )); - } - else - { - ec.assign( cause, BOOST_CHRONO_SYSTEM_CATEGORY ); - return steady_clock::time_point(duration(0)); - } - } - - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return time_point(duration( - static_cast(nanosecs_per_tic * pcount.QuadPart))); - } -#endif - - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::now() BOOST_NOEXCEPT - { - boost::detail::winapi::FILETIME_ ft; - boost::detail::winapi::GetSystemTimeAsFileTime( &ft ); // never fails - return system_clock::time_point( - system_clock::duration( - ((static_cast<__int64>( ft.dwHighDateTime ) << 32) | ft.dwLowDateTime) - -116444736000000000LL - ) - ); - } - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::now( system::error_code & ec ) - { - boost::detail::winapi::FILETIME_ ft; - boost::detail::winapi::GetSystemTimeAsFileTime( &ft ); // never fails - if (!BOOST_CHRONO_IS_THROWS(ec)) - { - ec.clear(); - } - return system_clock::time_point( - system_clock::duration( - ((static_cast<__int64>( ft.dwHighDateTime ) << 32) | ft.dwLowDateTime) - -116444736000000000LL - )); - } -#endif - - BOOST_CHRONO_INLINE - std::time_t system_clock::to_time_t(const system_clock::time_point& t) BOOST_NOEXCEPT - { - __int64 temp = t.time_since_epoch().count(); - temp /= 10000000; - return static_cast( temp ); - } - - BOOST_CHRONO_INLINE - system_clock::time_point system_clock::from_time_t(std::time_t t) BOOST_NOEXCEPT - { - __int64 temp = t; - temp *= 10000000; - return time_point(duration(temp)); - } - -} // namespace chrono -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/is_evenly_divisible_by.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/is_evenly_divisible_by.hpp deleted file mode 100644 index 960a208a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/is_evenly_divisible_by.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// is_evenly_divisible_by.hpp --------------------------------------------------------------// - -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -#ifndef BOOST_CHRONO_DETAIL_IS_EVENLY_DIVISIBLE_BY_HPP -#define BOOST_CHRONO_DETAIL_IS_EVENLY_DIVISIBLE_BY_HPP - -#include - -#include -#include - -namespace boost { -namespace chrono { -namespace chrono_detail { - -// template -// struct is_evenly_divisible_by : public boost::mpl::bool_ < ratio_divide::type::den == 1 > -// {}; - template - struct is_evenly_divisible_by : public boost::ratio_detail::is_evenly_divisible_by - {}; - -} // namespace chrono_detail -} // namespace detail -} // namespace chrono - -#endif // BOOST_CHRONO_DETAIL_IS_EVENLY_DIVISIBLE_BY_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/static_assert.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/static_assert.hpp deleted file mode 100644 index 86151947..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/static_assert.hpp +++ /dev/null @@ -1,30 +0,0 @@ -// static_assert.hpp --------------------------------------------------------------// - -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -#ifndef BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP -#define BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP - -#include - -#ifndef BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) static_assert(CND,MSG) -#elif defined(BOOST_CHRONO_USES_STATIC_ASSERT) -#include -#define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) BOOST_STATIC_ASSERT(CND) -#elif defined(BOOST_CHRONO_USES_MPL_ASSERT) -#include -#include -#define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) \ - BOOST_MPL_ASSERT_MSG(boost::mpl::bool_< (CND) >::type::value, MSG, TYPES) -#else -//~ #elif defined(BOOST_CHRONO_USES_ARRAY_ASSERT) -#define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) static char BOOST_JOIN(boost_chrono_test_,__LINE__)[(CND)?1:-1] -//~ #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) -#endif - -#endif // BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/system.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/system.hpp deleted file mode 100644 index 0dcffe85..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/detail/system.hpp +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2009-2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -#ifndef BOOST_CHRONO_DETAIL_SYSTEM_HPP -#define BOOST_CHRONO_DETAIL_SYSTEM_HPP - -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - -#include -#include - -#if ((BOOST_VERSION / 100000) < 2) && ((BOOST_VERSION / 100 % 1000) < 44) -#define BOOST_CHRONO_SYSTEM_CATEGORY boost::system::system_category -#else -#define BOOST_CHRONO_SYSTEM_CATEGORY boost::system::system_category() -#endif - -#ifdef BOOST_SYSTEM_NO_DEPRECATED -#define BOOST_CHRONO_THROWS boost::throws() -#define BOOST_CHRONO_IS_THROWS(EC) (&EC==&boost::throws()) -#else -#define BOOST_CHRONO_THROWS boost::system::throws -#define BOOST_CHRONO_IS_THROWS(EC) (&EC==&boost::system::throws) -#endif - -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/duration.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/duration.hpp deleted file mode 100644 index 814adb0e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/duration.hpp +++ /dev/null @@ -1,794 +0,0 @@ -// duration.hpp --------------------------------------------------------------// - -// Copyright 2008 Howard Hinnant -// Copyright 2008 Beman Dawes -// Copyright 2009-2011 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -/* - -This code was derived by Beman Dawes from Howard Hinnant's time2_demo prototype. -Many thanks to Howard for making his code available under the Boost license. -The original code was modified to conform to Boost conventions and to section -20.9 Time utilities [time] of the C++ committee's working paper N2798. -See http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2798.pdf. - -time2_demo contained this comment: - - Much thanks to Andrei Alexandrescu, - Walter Brown, - Peter Dimov, - Jeff Garland, - Terry Golubiewski, - Daniel Krugler, - Anthony Williams. -*/ - - -#ifndef BOOST_CHRONO_DURATION_HPP -#define BOOST_CHRONO_DURATION_HPP - -#include -#include - -#include -#include - - -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -#if !defined(BOOST_NO_CXX11_STATIC_ASSERT) || !defined(BOOST_CHRONO_USES_MPL_ASSERT) -#define BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION "A duration representation can not be a duration" -#define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO "Second template parameter of duration must be a boost::ratio" -#define BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE "duration period must be positive" -#define BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION "Second template parameter of time_point must be a boost::chrono::duration" -#endif - -#ifndef BOOST_CHRONO_HEADER_ONLY -// this must occur after all of the includes and before any code appears: -#include // must be the last #include -#endif - -//----------------------------------------------------------------------------// -// // -// 20.9 Time utilities [time] // -// synopsis // -// // -//----------------------------------------------------------------------------// - -namespace boost { -namespace chrono { - - template > - class duration; - - namespace detail - { - template - struct is_duration - : boost::false_type {}; - - template - struct is_duration > - : boost::true_type {}; - - template ::value> - struct duration_divide_result - { - }; - - template ::type>::value)) - && ((boost::is_convertible::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 ::value> - struct duration_divide_result2 - { - }; - - template ::type>::value)) - && ((boost::is_convertible::type>::value)) - ) - > - struct duration_divide_imp2 - { - }; - - template - struct duration_divide_imp2, true> - { - //typedef typename common_type::type type; - typedef double type; - }; - - template - struct duration_divide_result2, false> - : duration_divide_imp2 > - { - }; - -/// - template ::value> - struct duration_modulo_result - { - }; - - template ::type>::value - //&& - boost::is_convertible::type>::value - ) - > - struct duration_modulo_imp - { - }; - - template - struct duration_modulo_imp, Rep2, true> - { - typedef duration::type, Period> type; - }; - - template - struct duration_modulo_result, Rep2, false> - : duration_modulo_imp, Rep2> - { - }; - -} // namespace detail -} // namespace chrono - - -// common_type trait specializations - -template -struct common_type, - chrono::duration >; - - -namespace chrono { - - // customization traits - template struct treat_as_floating_point; - template struct duration_values; - - // convenience typedefs - typedef duration nanoseconds; // at least 64 bits needed - typedef duration microseconds; // at least 55 bits needed - typedef duration milliseconds; // at least 45 bits needed - typedef duration seconds; // at least 35 bits needed - typedef duration > minutes; // at least 29 bits needed - typedef duration > hours; // at least 23 bits needed - -//----------------------------------------------------------------------------// -// duration helpers // -//----------------------------------------------------------------------------// - -namespace detail -{ - - // duration_cast - - // duration_cast is the heart of this whole prototype. It can convert any - // duration to any other. It is also (implicitly) used in converting - // time_points. The conversion is always exact if possible. And it is - // always as efficient as hand written code. If different representations - // are involved, care is taken to never require implicit conversions. - // Instead static_cast is used explicitly for every required conversion. - // If there are a mixture of integral and floating point representations, - // the use of common_type ensures that the most logical "intermediate" - // representation is used. - template - struct duration_cast_aux; - - // When the two periods are the same, all that is left to do is static_cast from - // the source representation to the target representation (which may be a no-op). - // This conversion is always exact as long as the static_cast from the source - // representation to the destination representation is exact. - template - struct duration_cast_aux - { - BOOST_CONSTEXPR ToDuration operator()(const FromDuration& fd) const - { - return ToDuration(static_cast(fd.count())); - } - }; - - // When the numerator of FromPeriod / ToPeriod is 1, then all we need to do is - // divide by the denominator of FromPeriod / ToPeriod. The common_type of - // the two representations is used for the intermediate computation before - // static_cast'ing to the destination. - // This conversion is generally not exact because of the division (but could be - // if you get lucky on the run time value of fd.count()). - template - struct duration_cast_aux - { - BOOST_CONSTEXPR ToDuration operator()(const FromDuration& fd) const - { - typedef typename common_type< - typename ToDuration::rep, - typename FromDuration::rep, - boost::intmax_t>::type C; - return ToDuration(static_cast( - static_cast(fd.count()) / static_cast(Period::den))); - } - }; - - // When the denominator of FromPeriod / ToPeriod is 1, then all we need to do is - // multiply by the numerator of FromPeriod / ToPeriod. The common_type of - // the two representations is used for the intermediate computation before - // static_cast'ing to the destination. - // This conversion is always exact as long as the static_cast's involved are exact. - template - struct duration_cast_aux - { - BOOST_CONSTEXPR ToDuration operator()(const FromDuration& fd) const - { - typedef typename common_type< - typename ToDuration::rep, - typename FromDuration::rep, - boost::intmax_t>::type C; - return ToDuration(static_cast( - static_cast(fd.count()) * static_cast(Period::num))); - } - }; - - // When neither the numerator or denominator of FromPeriod / ToPeriod is 1, then we need to - // multiply by the numerator and divide by the denominator of FromPeriod / ToPeriod. The - // common_type of the two representations is used for the intermediate computation before - // static_cast'ing to the destination. - // This conversion is generally not exact because of the division (but could be - // if you get lucky on the run time value of fd.count()). - template - struct duration_cast_aux - { - BOOST_CONSTEXPR ToDuration operator()(const FromDuration& fd) const - { - typedef typename common_type< - typename ToDuration::rep, - typename FromDuration::rep, - boost::intmax_t>::type C; - return ToDuration(static_cast( - static_cast(fd.count()) * static_cast(Period::num) - / static_cast(Period::den))); - } - }; - - template - struct duration_cast { - typedef typename ratio_divide::type Period; - typedef duration_cast_aux< - FromDuration, - ToDuration, - Period, - Period::num == 1, - Period::den == 1 - > Aux; - BOOST_CONSTEXPR ToDuration operator()(const FromDuration& fd) const - { - return Aux()(fd); - } - }; - -} // namespace detail - -//----------------------------------------------------------------------------// -// // -// 20.9.2 Time-related traits [time.traits] // -// // -//----------------------------------------------------------------------------// -//----------------------------------------------------------------------------// -// 20.9.2.1 treat_as_floating_point [time.traits.is_fp] // -// Probably should have been treat_as_floating_point. Editor notifed. // -//----------------------------------------------------------------------------// - - // Support bidirectional (non-exact) conversions for floating point rep types - // (or user defined rep types which specialize treat_as_floating_point). - template - struct treat_as_floating_point : boost::is_floating_point {}; - -//----------------------------------------------------------------------------// -// 20.9.2.2 duration_values [time.traits.duration_values] // -//----------------------------------------------------------------------------// - -namespace detail { - template ::value> - struct chrono_numeric_limits { - static BOOST_CHRONO_LIB_CONSTEXPR T lowest() BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW {return (std::numeric_limits::min) ();} - }; - - template - struct chrono_numeric_limits { - static BOOST_CHRONO_LIB_CONSTEXPR T lowest() BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW {return (std::numeric_limits::min) ();} - }; - - template <> - struct chrono_numeric_limits { - static BOOST_CHRONO_LIB_CONSTEXPR float lowest() BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW - { - return -(std::numeric_limits::max) (); - } - }; - - template <> - struct chrono_numeric_limits { - static BOOST_CHRONO_LIB_CONSTEXPR double lowest() BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW - { - return -(std::numeric_limits::max) (); - } - }; - - template <> - struct chrono_numeric_limits { - static BOOST_CHRONO_LIB_CONSTEXPR long double lowest() BOOST_CHRONO_LIB_NOEXCEPT_OR_THROW - { - return -(std::numeric_limits::max)(); - } - }; - - template - struct numeric_limits : chrono_numeric_limits::type> - {}; - -} -template -struct duration_values -{ - static BOOST_CONSTEXPR Rep zero() {return Rep(0);} - static BOOST_CHRONO_LIB_CONSTEXPR Rep max BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return (std::numeric_limits::max)(); - } - - static BOOST_CHRONO_LIB_CONSTEXPR Rep min BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return detail::numeric_limits::lowest(); - } -}; - -} // namespace chrono - -//----------------------------------------------------------------------------// -// 20.9.2.3 Specializations of common_type [time.traits.specializations] // -//----------------------------------------------------------------------------// - -template -struct common_type, - chrono::duration > -{ - typedef chrono::duration::type, - typename boost::ratio_gcd::type> type; -}; - - -//----------------------------------------------------------------------------// -// // -// 20.9.3 Class template duration [time.duration] // -// // -//----------------------------------------------------------------------------// - - -namespace chrono { - - template - class BOOST_SYMBOL_VISIBLE duration - { - //BOOST_CHRONO_STATIC_ASSERT(boost::is_integral::value, BOOST_CHRONO_A_DURATION_REPRESENTATION_MUST_BE_INTEGRAL, ()); - BOOST_CHRONO_STATIC_ASSERT(!boost::chrono::detail::is_duration::value, - BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION, ()); - BOOST_CHRONO_STATIC_ASSERT(boost::ratio_detail::is_ratio::value, - BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO, ()); - BOOST_CHRONO_STATIC_ASSERT(Period::num>0, - BOOST_CHRONO_DURATION_PERIOD_MUST_BE_POSITIVE, ()); - public: - typedef Rep rep; - typedef Period period; - private: - rep rep_; - public: - - BOOST_FORCEINLINE BOOST_CONSTEXPR - duration() : rep_(duration_values::zero()) { } - template - BOOST_SYMBOL_VISIBLE BOOST_FORCEINLINE BOOST_CONSTEXPR - explicit duration(const Rep2& r - , typename boost::enable_if < - mpl::and_ < - boost::is_convertible, - mpl::or_ < - treat_as_floating_point, - mpl::and_ < - mpl::not_ < treat_as_floating_point >, - mpl::not_ < treat_as_floating_point > - > - > - > - >::type* = 0 - ) : rep_(r) { } - //~duration() {} //= default; -// BOOST_CONSTEXPR duration(const duration& rhs) : rep_(rhs.rep_) {} // = default; - duration& operator=(const duration& rhs) // = default; - { - if (&rhs != this) rep_= rhs.rep_; - return *this; - } - - // conversions - template - BOOST_FORCEINLINE BOOST_CONSTEXPR - duration(const duration& d - , typename boost::enable_if < - mpl::or_ < - treat_as_floating_point, - mpl::and_ < - chrono_detail::is_evenly_divisible_by, - mpl::not_ < treat_as_floating_point > - > - > - >::type* = 0 - ) - : rep_(chrono::detail::duration_cast, duration>()(d).count()) {} - - // observer - - BOOST_CONSTEXPR - rep count() const {return rep_;} - - // arithmetic - - BOOST_CONSTEXPR - duration operator+() const {return duration(rep_);;} - BOOST_CONSTEXPR - duration operator-() const {return duration(-rep_);} - duration& operator++() {++rep_; return *this;} - duration operator++(int) {return duration(rep_++);} - duration& operator--() {--rep_; return *this;} - duration operator--(int) {return duration(rep_--);} - - duration& operator+=(const duration& d) - { - rep_ += d.count(); return *this; - } - duration& operator-=(const duration& d) - { - rep_ -= d.count(); return *this; - } - - duration& operator*=(const rep& rhs) {rep_ *= rhs; return *this;} - duration& operator/=(const rep& rhs) {rep_ /= rhs; return *this;} - duration& operator%=(const rep& rhs) {rep_ %= rhs; return *this;} - duration& operator%=(const duration& rhs) - { - rep_ %= rhs.count(); return *this; - } - // 20.9.3.4 duration special values [time.duration.special] - - static BOOST_CONSTEXPR duration zero() - { - return duration(duration_values::zero()); - } - static BOOST_CHRONO_LIB_CONSTEXPR duration min BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return duration((duration_values::min)()); - } - static BOOST_CHRONO_LIB_CONSTEXPR duration max BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return duration((duration_values::max)()); - } - }; - -//----------------------------------------------------------------------------// -// 20.9.3.5 duration non-member arithmetic [time.duration.nonmember] // -//----------------------------------------------------------------------------// - - // Duration + - - template - inline BOOST_CONSTEXPR - typename common_type, duration >::type - operator+(const duration& lhs, - const duration& rhs) - { - typedef typename common_type, - duration >::type CD; - return CD(CD(lhs).count()+CD(rhs).count()); - } - - // Duration - - - template - inline BOOST_CONSTEXPR - typename common_type, duration >::type - operator-(const duration& lhs, - const duration& rhs) - { - typedef typename common_type, - duration >::type CD; - return CD(CD(lhs).count()-CD(rhs).count()); - } - - // Duration * - - template - inline BOOST_CONSTEXPR - typename boost::enable_if < - mpl::and_ < - boost::is_convertible::type>, - boost::is_convertible::type> - >, - duration::type, Period> - >::type - operator*(const duration& d, const Rep2& s) - { - typedef typename common_type::type CR; - typedef duration CD; - return CD(CD(d).count()*static_cast(s)); - } - - template - inline BOOST_CONSTEXPR - typename boost::enable_if < - mpl::and_ < - boost::is_convertible::type>, - boost::is_convertible::type> - >, - duration::type, Period> - >::type - operator*(const Rep1& s, const duration& d) - { - return d * s; - } - - // Duration / - - template - inline BOOST_CONSTEXPR - typename boost::disable_if , - typename boost::chrono::detail::duration_divide_result< - duration, Rep2>::type - >::type - operator/(const duration& d, const Rep2& s) - { - typedef typename common_type::type CR; - typedef duration CD; - - return CD(CD(d).count()/static_cast(s)); - } - - template - inline BOOST_CONSTEXPR - typename common_type::type - operator/(const duration& lhs, const duration& rhs) - { - typedef typename common_type, - duration >::type CD; - return CD(lhs).count() / CD(rhs).count(); - } - - #ifdef BOOST_CHRONO_EXTENSIONS - template - inline BOOST_CONSTEXPR - typename boost::disable_if , - typename boost::chrono::detail::duration_divide_result2< - Rep1, duration >::type - >::type - operator/(const Rep1& s, const duration& d) - { - typedef typename common_type::type CR; - typedef duration CD; - - return static_cast(s)/CD(d).count(); - } - #endif - // Duration % - - template - inline BOOST_CONSTEXPR - typename boost::disable_if , - typename boost::chrono::detail::duration_modulo_result< - duration, Rep2>::type - >::type - operator%(const duration& d, const Rep2& s) - { - typedef typename common_type::type CR; - typedef duration CD; - - return CD(CD(d).count()%static_cast(s)); - } - - template - inline BOOST_CONSTEXPR - typename common_type, duration >::type - operator%(const duration& lhs, - const duration& rhs) { - typedef typename common_type, - duration >::type CD; - - return CD(CD(lhs).count()%CD(rhs).count()); - } - - -//----------------------------------------------------------------------------// -// 20.9.3.6 duration comparisons [time.duration.comparisons] // -//----------------------------------------------------------------------------// - -namespace detail -{ - template - struct duration_eq - { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const - { - typedef typename common_type::type CD; - return CD(lhs).count() == CD(rhs).count(); - } - }; - - template - struct duration_eq - { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const - { - return lhs.count() == rhs.count(); - } - }; - - template - struct duration_lt - { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const - { - typedef typename common_type::type CD; - return CD(lhs).count() < CD(rhs).count(); - } - }; - - template - struct duration_lt - { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const - { - return lhs.count() < rhs.count(); - } - }; - -} // namespace detail - - // Duration == - - template - inline BOOST_CONSTEXPR - bool - operator==(const duration& lhs, - const duration& rhs) - { - return boost::chrono::detail::duration_eq< - duration, duration >()(lhs, rhs); - } - - // Duration != - - template - inline BOOST_CONSTEXPR - bool - operator!=(const duration& lhs, - const duration& rhs) - { - return !(lhs == rhs); - } - - // Duration < - - template - inline BOOST_CONSTEXPR - bool - operator< (const duration& lhs, - const duration& rhs) - { - return boost::chrono::detail::duration_lt< - duration, duration >()(lhs, rhs); - } - - // Duration > - - template - inline BOOST_CONSTEXPR - bool - operator> (const duration& lhs, - const duration& rhs) - { - return rhs < lhs; - } - - // Duration <= - - template - inline BOOST_CONSTEXPR - bool - operator<=(const duration& lhs, - const duration& rhs) - { - return !(rhs < lhs); - } - - // Duration >= - - template - inline BOOST_CONSTEXPR - bool - operator>=(const duration& lhs, - const duration& rhs) - { - return !(lhs < rhs); - } - -//----------------------------------------------------------------------------// -// 20.9.3.7 duration_cast [time.duration.cast] // -//----------------------------------------------------------------------------// - - // Compile-time select the most efficient algorithm for the conversion... - template - inline BOOST_CONSTEXPR - typename boost::enable_if < - boost::chrono::detail::is_duration, ToDuration>::type - duration_cast(const duration& fd) - { - return boost::chrono::detail::duration_cast< - duration, ToDuration>()(fd); - } - -} // namespace chrono -} // namespace boost - -#ifndef BOOST_CHRONO_HEADER_ONLY -// the suffix header occurs after all of our code: -#include // pops abi_prefix.hpp pragmas -#endif - -#endif // BOOST_CHRONO_DURATION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/system_clocks.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/system_clocks.hpp deleted file mode 100644 index 5ba6a3b0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/system_clocks.hpp +++ /dev/null @@ -1,233 +0,0 @@ -// boost/chrono/system_clocks.hpp --------------------------------------------------------------// - -// Copyright 2008 Howard Hinnant -// Copyright 2008 Beman Dawes -// Copyright 2009-2011 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -/* - -This code was derived by Beman Dawes from Howard Hinnant's time2_demo prototype. -Many thanks to Howard for making his code available under the Boost license. -The original code was modified to conform to Boost conventions and to section -20.9 Time utilities [time] of the C++ committee's working paper N2798. -See http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2798.pdf. - -time2_demo contained this comment: - - Much thanks to Andrei Alexandrescu, - Walter Brown, - Peter Dimov, - Jeff Garland, - Terry Golubiewski, - Daniel Krugler, - Anthony Williams. -*/ - -/* - -TODO: - - * Fully implement error handling, with test cases. - * Consider issues raised by Michael Marcin: - - > In the past I've seen QueryPerformanceCounter give incorrect results, - > especially with SpeedStep processors on laptops. This was many years ago and - > might have been fixed by service packs and drivers. - > - > Typically you check the results of QPC against GetTickCount to see if the - > results are reasonable. - > http://support.microsoft.com/kb/274323 - > - > I've also heard of problems with QueryPerformanceCounter in multi-processor - > systems. - > - > I know some people SetThreadAffinityMask to 1 for the current thread call - > their QueryPerformance* functions then restore SetThreadAffinityMask. This - > seems horrible to me because it forces your program to jump to another - > physical processor if it isn't already on cpu0 but they claim it worked well - > in practice because they called the timing functions infrequently. - > - > In the past I have chosen to use timeGetTime with timeBeginPeriod(1) for - > high resolution timers to avoid these issues. - -*/ - -#ifndef BOOST_CHRONO_SYSTEM_CLOCKS_HPP -#define BOOST_CHRONO_SYSTEM_CLOCKS_HPP - -#include -#include -#include -#include -#include - -#include - -# if defined( BOOST_CHRONO_POSIX_API ) -# if ! defined(CLOCK_REALTIME) && ! defined (__hpux__) -# error does not supply CLOCK_REALTIME -# endif -# endif - -#ifdef BOOST_CHRONO_WINDOWS_API -// The system_clock tick is 100 nanoseconds -# define BOOST_SYSTEM_CLOCK_DURATION boost::chrono::duration > -#else -# define BOOST_SYSTEM_CLOCK_DURATION boost::chrono::nanoseconds -#endif - -// this must occur after all of the includes and before any code appears: -#ifndef BOOST_CHRONO_HEADER_ONLY -#include // must be the last #include -#endif - - -//----------------------------------------------------------------------------// -// // -// 20.9 Time utilities [time] // -// synopsis // -// // -//----------------------------------------------------------------------------// - -namespace boost { -namespace chrono { - - // Clocks - class BOOST_CHRONO_DECL system_clock; -#ifdef BOOST_CHRONO_HAS_CLOCK_STEADY - class BOOST_CHRONO_DECL steady_clock; -#endif - -#ifdef BOOST_CHRONO_HAS_CLOCK_STEADY - typedef steady_clock high_resolution_clock; // as permitted by [time.clock.hires] -#else - typedef system_clock high_resolution_clock; // as permitted by [time.clock.hires] -#endif - -//----------------------------------------------------------------------------// -// // -// 20.9.5 Clocks [time.clock] // -// // -//----------------------------------------------------------------------------// - -// If you're porting, clocks are the system-specific (non-portable) part. -// You'll need to know how to get the current time and implement that under now(). -// You'll need to know what units (tick period) and representation makes the most -// sense for your clock and set those accordingly. -// If you know how to map this clock to time_t (perhaps your clock is std::time, which -// makes that trivial), then you can fill out system_clock's to_time_t() and from_time_t(). - -//----------------------------------------------------------------------------// -// 20.9.5.1 Class system_clock [time.clock.system] // -//----------------------------------------------------------------------------// - - class BOOST_CHRONO_DECL system_clock - { - public: - typedef BOOST_SYSTEM_CLOCK_DURATION duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - BOOST_STATIC_CONSTEXPR bool is_steady = false; - - static BOOST_CHRONO_INLINE time_point now() BOOST_NOEXCEPT; -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - static BOOST_CHRONO_INLINE time_point now(system::error_code & ec); -#endif - - static BOOST_CHRONO_INLINE std::time_t to_time_t(const time_point& t) BOOST_NOEXCEPT; - static BOOST_CHRONO_INLINE time_point from_time_t(std::time_t t) BOOST_NOEXCEPT; - }; - -//----------------------------------------------------------------------------// -// 20.9.5.2 Class steady_clock [time.clock.steady] // -//----------------------------------------------------------------------------// - -// As permitted by [time.clock.steady] -// The class steady_clock is conditionally supported. - -#ifdef BOOST_CHRONO_HAS_CLOCK_STEADY - class BOOST_CHRONO_DECL steady_clock - { - public: - typedef nanoseconds duration; - typedef duration::rep rep; - typedef duration::period period; - typedef chrono::time_point time_point; - BOOST_STATIC_CONSTEXPR bool is_steady = true; - - static BOOST_CHRONO_INLINE time_point now() BOOST_NOEXCEPT; -#if !defined BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING - static BOOST_CHRONO_INLINE time_point now(system::error_code & ec); -#endif - }; -#endif -//----------------------------------------------------------------------------// -// 20.9.5.3 Class high_resolution_clock [time.clock.hires] // -//----------------------------------------------------------------------------// - -// As permitted, steady_clock or system_clock is a typedef for high_resolution_clock. -// See synopsis. - - - template - struct clock_string - { - static std::basic_string name() - { - static const CharT u[] = - { 's', 'y', 's', 't', 'e', 'm', '_', 'c', 'l', 'o', 'c', 'k' }; - static const std::basic_string str(u, u + sizeof(u) - / sizeof(u[0])); - return str; - } - static std::basic_string since() - { - static const CharT - u[] = - { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'J', 'a', 'n', ' ', '1', ',', ' ', '1', '9', '7', '0' }; - static const std::basic_string str(u, u + sizeof(u) - / sizeof(u[0])); - return str; - } - }; - -#ifdef BOOST_CHRONO_HAS_CLOCK_STEADY - - template - struct clock_string - { - static std::basic_string name() - { - static const CharT - u[] = - { 's', 't', 'e', 'a', 'd', 'y', '_', 'c', 'l', 'o', 'c', 'k' }; - static const std::basic_string str(u, u + sizeof(u) - / sizeof(u[0])); - return str; - } - static std::basic_string since() - { - const CharT u[] = - { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'b', 'o', 'o', 't' }; - const std::basic_string str(u, u + sizeof(u) / sizeof(u[0])); - return str; - } - }; - -#endif - -} // namespace chrono -} // namespace boost - -#ifndef BOOST_CHRONO_HEADER_ONLY -// the suffix header occurs after all of our code: -#include // pops abi_prefix.hpp pragmas -#else -#include -#endif - -#endif // BOOST_CHRONO_SYSTEM_CLOCKS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/chrono/time_point.hpp b/third_party/ycmd/cpp/BoostParts/boost/chrono/time_point.hpp deleted file mode 100644 index 6449fac6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/chrono/time_point.hpp +++ /dev/null @@ -1,380 +0,0 @@ -// duration.hpp --------------------------------------------------------------// - -// Copyright 2008 Howard Hinnant -// Copyright 2008 Beman Dawes -// Copyright 2009-2012 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -/* - -This code was derived by Beman Dawes from Howard Hinnant's time2_demo prototype. -Many thanks to Howard for making his code available under the Boost license. -The original code was modified to conform to Boost conventions and to section -20.9 Time utilities [time] of the C++ committee's working paper N2798. -See http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2798.pdf. - -time2_demo contained this comment: - - Much thanks to Andrei Alexandrescu, - Walter Brown, - Peter Dimov, - Jeff Garland, - Terry Golubiewski, - Daniel Krugler, - Anthony Williams. -*/ - - -#ifndef BOOST_CHRONO_TIME_POINT_HPP -#define BOOST_CHRONO_TIME_POINT_HPP - -#include -#include - -#ifndef BOOST_CHRONO_HEADER_ONLY -// this must occur after all of the includes and before any code appears: -#include // must be the last #include -#endif - -//----------------------------------------------------------------------------// -// // -// 20.9 Time utilities [time] // -// synopsis // -// // -//----------------------------------------------------------------------------// - -namespace boost { -namespace chrono { - - template - class time_point; - - -} // namespace chrono - - -// common_type trait specializations - -template - struct common_type, - chrono::time_point >; - - -//----------------------------------------------------------------------------// -// 20.9.2.3 Specializations of common_type [time.traits.specializations] // -//----------------------------------------------------------------------------// - - -template -struct common_type, - chrono::time_point > -{ - typedef chrono::time_point::type> type; -}; - - - -namespace chrono { - - // time_point arithmetic - template - inline BOOST_CONSTEXPR - time_point >::type> - operator+( - const time_point& lhs, - const duration& rhs); - template - inline BOOST_CONSTEXPR - time_point, Duration2>::type> - operator+( - const duration& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - time_point >::type> - operator-( - const time_point& lhs, - const duration& rhs); - template - inline BOOST_CONSTEXPR - typename common_type::type - operator-( - const time_point& lhs, - const time_point& rhs); - - // time_point comparisons - template - inline BOOST_CONSTEXPR - bool operator==( - const time_point& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - bool operator!=( - const time_point& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - bool operator< ( - const time_point& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - bool operator<=( - const time_point& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - bool operator> ( - const time_point& lhs, - const time_point& rhs); - template - inline BOOST_CONSTEXPR - bool operator>=( - const time_point& lhs, - const time_point& rhs); - - // time_point_cast - template - inline BOOST_CONSTEXPR - time_point time_point_cast(const time_point& t); - -//----------------------------------------------------------------------------// -// // -// 20.9.4 Class template time_point [time.point] // -// // -//----------------------------------------------------------------------------// - - template - class time_point - { - BOOST_CHRONO_STATIC_ASSERT(boost::chrono::detail::is_duration::value, - BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_TIME_POINT_MUST_BE_A_BOOST_CHRONO_DURATION, (Duration)); - public: - typedef Clock clock; - typedef Duration duration; - typedef typename duration::rep rep; - typedef typename duration::period period; - typedef Duration difference_type; - - private: - duration d_; - - public: - BOOST_FORCEINLINE BOOST_CONSTEXPR - time_point() : d_(duration::zero()) - {} - BOOST_FORCEINLINE BOOST_CONSTEXPR - explicit time_point(const duration& d) - : d_(d) - {} - - // conversions - template - BOOST_FORCEINLINE BOOST_CONSTEXPR - time_point(const time_point& t - , typename boost::enable_if - < - boost::is_convertible - >::type* = 0 - ) - : d_(t.time_since_epoch()) - { - } - // observer - - BOOST_CONSTEXPR - duration time_since_epoch() const - { - return d_; - } - - // arithmetic - -#ifdef BOOST_CHRONO_EXTENSIONS - BOOST_CONSTEXPR - time_point operator+() const {return *this;} - BOOST_CONSTEXPR - time_point operator-() const {return time_point(-d_);} - time_point& operator++() {++d_; return *this;} - time_point operator++(int) {return time_point(d_++);} - time_point& operator--() {--d_; return *this;} - time_point operator--(int) {return time_point(d_--);} - - time_point& operator+=(const rep& r) {d_ += duration(r); return *this;} - time_point& operator-=(const rep& r) {d_ -= duration(r); return *this;} - -#endif - - time_point& operator+=(const duration& d) {d_ += d; return *this;} - time_point& operator-=(const duration& d) {d_ -= d; return *this;} - - // special values - - static BOOST_CHRONO_LIB_CONSTEXPR time_point - min BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return time_point((duration::min)()); - } - static BOOST_CHRONO_LIB_CONSTEXPR time_point - max BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return time_point((duration::max)()); - } - }; - -//----------------------------------------------------------------------------// -// 20.9.4.5 time_point non-member arithmetic [time.point.nonmember] // -//----------------------------------------------------------------------------// - - // time_point operator+(time_point x, duration y); - - template - inline BOOST_CONSTEXPR - time_point >::type> - operator+(const time_point& lhs, - const duration& rhs) - { - typedef typename common_type >::type CDuration; - typedef time_point< - Clock, - CDuration - > TimeResult; - return TimeResult(lhs.time_since_epoch() + CDuration(rhs)); - } - - // time_point operator+(duration x, time_point y); - - template - inline BOOST_CONSTEXPR - time_point, Duration2>::type> - operator+(const duration& lhs, - const time_point& rhs) - { - return rhs + lhs; - } - - // time_point operator-(time_point x, duration y); - - template - inline BOOST_CONSTEXPR - time_point >::type> - operator-(const time_point& lhs, - const duration& rhs) - { - return lhs + (-rhs); - } - - // duration operator-(time_point x, time_point y); - - template - inline BOOST_CONSTEXPR - typename common_type::type - operator-(const time_point& lhs, - const time_point& rhs) - { - return lhs.time_since_epoch() - rhs.time_since_epoch(); - } - -//----------------------------------------------------------------------------// -// 20.9.4.6 time_point comparisons [time.point.comparisons] // -//----------------------------------------------------------------------------// - - // time_point == - - template - inline BOOST_CONSTEXPR - bool - operator==(const time_point& lhs, - const time_point& rhs) - { - return lhs.time_since_epoch() == rhs.time_since_epoch(); - } - - // time_point != - - template - inline BOOST_CONSTEXPR - bool - operator!=(const time_point& lhs, - const time_point& rhs) - { - return !(lhs == rhs); - } - - // time_point < - - template - inline BOOST_CONSTEXPR - bool - operator<(const time_point& lhs, - const time_point& rhs) - { - return lhs.time_since_epoch() < rhs.time_since_epoch(); - } - - // time_point > - - template - inline BOOST_CONSTEXPR - bool - operator>(const time_point& lhs, - const time_point& rhs) - { - return rhs < lhs; - } - - // time_point <= - - template - inline BOOST_CONSTEXPR - bool - operator<=(const time_point& lhs, - const time_point& rhs) - { - return !(rhs < lhs); - } - - // time_point >= - - template - inline BOOST_CONSTEXPR - bool - operator>=(const time_point& lhs, - const time_point& rhs) - { - return !(lhs < rhs); - } - -//----------------------------------------------------------------------------// -// 20.9.4.7 time_point_cast [time.point.cast] // -//----------------------------------------------------------------------------// - - template - inline BOOST_CONSTEXPR - time_point - time_point_cast(const time_point& t) - { - return time_point( - duration_cast(t.time_since_epoch())); - } - -} // namespace chrono -} // namespace boost - -#ifndef BOOST_CHRONO_HEADER_ONLY -// the suffix header occurs after all of our code: -#include // pops abi_prefix.hpp pragmas -#endif - -#endif // BOOST_CHRONO_TIME_POINT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer.hpp deleted file mode 100644 index 13cc94fe..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer.hpp +++ /dev/null @@ -1,74 +0,0 @@ -// Circular buffer library header file. - -// Copyright (c) 2003-2008 Jan Gaspar - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See www.boost.org/libs/circular_buffer for documentation. - -#if !defined(BOOST_CIRCULAR_BUFFER_HPP) -#define BOOST_CIRCULAR_BUFFER_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -#include -#include - -// BOOST_CB_ENABLE_DEBUG: Debug support control. -#if defined(NDEBUG) || defined(BOOST_CB_DISABLE_DEBUG) - #define BOOST_CB_ENABLE_DEBUG 0 -#else - #define BOOST_CB_ENABLE_DEBUG 1 -#endif - -// BOOST_CB_ASSERT: Runtime assertion. -#if BOOST_CB_ENABLE_DEBUG - #include - #define BOOST_CB_ASSERT(Expr) BOOST_ASSERT(Expr) -#else - #define BOOST_CB_ASSERT(Expr) ((void)0) -#endif - -// BOOST_CB_STATIC_ASSERT: Compile time assertion. -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - #define BOOST_CB_STATIC_ASSERT(Expr) ((void)0) -#else - #include - #define BOOST_CB_STATIC_ASSERT(Expr) BOOST_STATIC_ASSERT(Expr) -#endif - -// BOOST_CB_IS_CONVERTIBLE: Check if Iterator::value_type is convertible to Type. -#if BOOST_WORKAROUND(__BORLANDC__, <= 0x0550) || BOOST_WORKAROUND(__MWERKS__, <= 0x2407) || \ - BOOST_WORKAROUND(BOOST_MSVC, < 1300) - #define BOOST_CB_IS_CONVERTIBLE(Iterator, Type) ((void)0) -#else - #include - #include - #define BOOST_CB_IS_CONVERTIBLE(Iterator, Type) \ - BOOST_CB_STATIC_ASSERT((is_convertible::value_type, Type>::value)) -#endif - -// BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS: -// Check if the STL provides templated iterator constructors for its containers. -#if defined(BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS) - #define BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS BOOST_CB_STATIC_ASSERT(false); -#else - #define BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS ((void)0); -#endif - -#include -#include -#include -#include - -#undef BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS -#undef BOOST_CB_IS_CONVERTIBLE -#undef BOOST_CB_STATIC_ASSERT -#undef BOOST_CB_ASSERT -#undef BOOST_CB_ENABLE_DEBUG - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/base.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/base.hpp deleted file mode 100644 index eaad68d1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/base.hpp +++ /dev/null @@ -1,3173 +0,0 @@ -// Implementation of the base circular buffer. - -// Copyright (c) 2003-2008 Jan Gaspar -// Copyright (c) 2013 Paul A. Bristow // Doxygen comments changed. -// Copyright (c) 2013 Antony Polukhin // Move semantics implementation. - - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_CIRCULAR_BUFFER_BASE_HPP) -#define BOOST_CIRCULAR_BUFFER_BASE_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#if BOOST_CB_ENABLE_DEBUG - #include -#endif -#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - #include -#endif - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std { - using ::memset; -} -#endif - - - -namespace boost { - -/*! - \class circular_buffer - \brief Circular buffer - a STL compliant container. - \tparam T The type of the elements stored in the circular_buffer. - \par Type Requirements T - The T has to be - SGIAssignable (SGI STL defined combination of - Assignable and CopyConstructible). - Moreover T has to be - DefaultConstructible if supplied as a default parameter when invoking some of the - circular_buffer's methods e.g. - insert(iterator pos, const value_type& item = %value_type()). And - EqualityComparable and/or - LessThanComparable if the circular_buffer - will be compared with another container. - \tparam Alloc The allocator type used for all internal memory management. - \par Type Requirements Alloc - The Alloc has to meet the allocator requirements imposed by STL. - \par Default Alloc - std::allocator - - For detailed documentation of the circular_buffer visit: - http://www.boost.org/libs/circular_buffer/doc/circular_buffer.html -*/ -template -class circular_buffer -/*! \cond */ -#if BOOST_CB_ENABLE_DEBUG -: public cb_details::debug_iterator_registry -#endif -/*! \endcond */ -{ - - // Requirements - //BOOST_CLASS_REQUIRE(T, boost, SGIAssignableConcept); - - - //BOOST_CONCEPT_ASSERT((Assignable)); - //BOOST_CONCEPT_ASSERT((CopyConstructible)); - //BOOST_CONCEPT_ASSERT((DefaultConstructible)); - - // Required if the circular_buffer will be compared with anther container. - //BOOST_CONCEPT_ASSERT((EqualityComparable)); - //BOOST_CONCEPT_ASSERT((LessThanComparable)); - -public: -// Basic types - - //! The type of this circular_buffer. - typedef circular_buffer this_type; - - //! The type of elements stored in the circular_buffer. - typedef typename Alloc::value_type value_type; - - //! A pointer to an element. - typedef typename Alloc::pointer pointer; - - //! A const pointer to the element. - typedef typename Alloc::const_pointer const_pointer; - - //! A reference to an element. - typedef typename Alloc::reference reference; - - //! A const reference to an element. - typedef typename Alloc::const_reference const_reference; - - //! The distance type. - /*! - (A signed integral type used to represent the distance between two iterators.) - */ - typedef typename Alloc::difference_type difference_type; - - //! The size type. - /*! - (An unsigned integral type that can represent any non-negative value of the container's distance type.) - */ - typedef typename Alloc::size_type size_type; - - //! The type of an allocator used in the circular_buffer. - typedef Alloc allocator_type; - -// Iterators - - //! A const (random access) iterator used to iterate through the circular_buffer. - typedef cb_details::iterator< circular_buffer, cb_details::const_traits > const_iterator; - - //! A (random access) iterator used to iterate through the circular_buffer. - typedef cb_details::iterator< circular_buffer, cb_details::nonconst_traits > iterator; - - //! A const iterator used to iterate backwards through a circular_buffer. - typedef boost::reverse_iterator const_reverse_iterator; - - //! An iterator used to iterate backwards through a circular_buffer. - typedef boost::reverse_iterator reverse_iterator; - -// Container specific types - - //! An array range. - /*! - (A typedef for the std::pair where - its first element is a pointer to a beginning of an array and its second element represents - a size of the array.) - */ - typedef std::pair array_range; - - //! A range of a const array. - /*! - (A typedef for the std::pair where - its first element is a pointer to a beginning of a const array and its second element represents - a size of the const array.) - */ - typedef std::pair const_array_range; - - //! The capacity type. - /*! - (Same as size_type - defined for consistency with the __cbso class. - - */ - // circular_buffer_space_optimized.) - - typedef size_type capacity_type; - -// Helper types - - //! A type representing the "best" way to pass the value_type to a method. - typedef const value_type& param_value_type; - - //! A type representing rvalue from param type. - //! On compilers without rvalue references support this type is the Boost.Moves type used for emulation. - typedef BOOST_RV_REF(value_type) rvalue_type; - -private: - - // TODO: move to Boost.Move - /*! \cond */ - template - static inline typename boost::conditional< - ((boost::is_nothrow_move_constructible::value && boost::is_nothrow_move_assignable::value) || !boost::is_copy_constructible::value) -#if defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) && defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - && has_move_emulation_enabled::value -#endif - , - rvalue_type, - param_value_type - >::type move_if_noexcept(ValT& value) BOOST_NOEXCEPT { - return boost::move(value); - } - /*! \endcond */ - -// Member variables - - //! The internal buffer used for storing elements in the circular buffer. - pointer m_buff; - - //! The internal buffer's end (end of the storage space). - pointer m_end; - - //! The virtual beginning of the circular buffer. - pointer m_first; - - //! The virtual end of the circular buffer (one behind the last element). - pointer m_last; - - //! The number of items currently stored in the circular buffer. - size_type m_size; - - //! The allocator. - allocator_type m_alloc; - -// Friends -#if defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS) - friend iterator; - friend const_iterator; -#else - template friend struct cb_details::iterator; -#endif - -public: -// Allocator - - //! Get the allocator. - /*! - \return The allocator. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa get_allocator() for obtaining an allocator %reference. - */ - allocator_type get_allocator() const BOOST_NOEXCEPT { return m_alloc; } - - //! Get the allocator reference. - /*! - \return A reference to the allocator. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \note This method was added in order to optimize obtaining of the allocator with a state, - although use of stateful allocators in STL is discouraged. - \sa get_allocator() const - */ - allocator_type& get_allocator() BOOST_NOEXCEPT { return m_alloc; } - -// Element access - - //! Get the iterator pointing to the beginning of the circular_buffer. - /*! - \return A random access iterator pointing to the first element of the circular_buffer. If the - circular_buffer is empty it returns an iterator equal to the one returned by - end(). - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa end(), rbegin(), rend() - */ - iterator begin() BOOST_NOEXCEPT { return iterator(this, empty() ? 0 : m_first); } - - //! Get the iterator pointing to the end of the circular_buffer. - /*! - \return A random access iterator pointing to the element "one behind" the last element of the - circular_buffer. If the circular_buffer is empty it returns an iterator equal to - the one returned by begin(). - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa begin(), rbegin(), rend() - */ - iterator end() BOOST_NOEXCEPT { return iterator(this, 0); } - - //! Get the const iterator pointing to the beginning of the circular_buffer. - /*! - \return A const random access iterator pointing to the first element of the circular_buffer. If - the circular_buffer is empty it returns an iterator equal to the one returned by - end() const. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa end() const, rbegin() const, rend() const - */ - const_iterator begin() const BOOST_NOEXCEPT { return const_iterator(this, empty() ? 0 : m_first); } - - //! Get the const iterator pointing to the end of the circular_buffer. - /*! - \return A const random access iterator pointing to the element "one behind" the last element of the - circular_buffer. If the circular_buffer is empty it returns an iterator equal to - the one returned by begin() const const. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa begin() const, rbegin() const, rend() const - */ - const_iterator end() const BOOST_NOEXCEPT { return const_iterator(this, 0); } - - //! Get the iterator pointing to the beginning of the "reversed" circular_buffer. - /*! - \return A reverse random access iterator pointing to the last element of the circular_buffer. - If the circular_buffer is empty it returns an iterator equal to the one returned by - rend(). - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa rend(), begin(), end() - */ - reverse_iterator rbegin() BOOST_NOEXCEPT { return reverse_iterator(end()); } - - //! Get the iterator pointing to the end of the "reversed" circular_buffer. - /*! - \return A reverse random access iterator pointing to the element "one before" the first element of the - circular_buffer. If the circular_buffer is empty it returns an iterator equal to - the one returned by rbegin(). - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa rbegin(), begin(), end() - */ - reverse_iterator rend() BOOST_NOEXCEPT { return reverse_iterator(begin()); } - - //! Get the const iterator pointing to the beginning of the "reversed" circular_buffer. - /*! - \return A const reverse random access iterator pointing to the last element of the - circular_buffer. If the circular_buffer is empty it returns an iterator equal - to the one returned by rend() const. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa rend() const, begin() const, end() const - */ - const_reverse_iterator rbegin() const BOOST_NOEXCEPT { return const_reverse_iterator(end()); } - - //! Get the const iterator pointing to the end of the "reversed" circular_buffer. - /*! - \return A const reverse random access iterator pointing to the element "one before" the first element of the - circular_buffer. If the circular_buffer is empty it returns an iterator equal - to the one returned by rbegin() const. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa rbegin() const, begin() const, end() const - */ - const_reverse_iterator rend() const BOOST_NOEXCEPT { return const_reverse_iterator(begin()); } - - //! Get the element at the index position. - /*! - \pre 0 \<= index \&\& index \< size() - \param index The position of the element. - \return A reference to the element at the index position. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa at() - */ - reference operator [] (size_type index) { - BOOST_CB_ASSERT(index < size()); // check for invalid index - return *add(m_first, index); - } - - //! Get the element at the index position. - /*! - \pre 0 \<= index \&\& index \< size() - \param index The position of the element. - \return A const reference to the element at the index position. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link at(size_type)const at() const \endlink - */ - const_reference operator [] (size_type index) const { - BOOST_CB_ASSERT(index < size()); // check for invalid index - return *add(m_first, index); - } - - //! Get the element at the index position. - /*! - \param index The position of the element. - \return A reference to the element at the index position. - \throws std::out_of_range when the index is invalid (when - index >= size()). - \par Exception Safety - Strong. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link operator[](size_type) operator[] \endlink - */ - reference at(size_type index) { - check_position(index); - return (*this)[index]; - } - - //! Get the element at the index position. - /*! - \param index The position of the element. - \return A const reference to the element at the index position. - \throws std::out_of_range when the index is invalid (when - index >= size()). - \par Exception Safety - Strong. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link operator[](size_type)const operator[] const \endlink - */ - const_reference at(size_type index) const { - check_position(index); - return (*this)[index]; - } - - //! Get the first element. - /*! - \pre !empty() - \return A reference to the first element of the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa back() - */ - reference front() { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (front element not available) - return *m_first; - } - - //! Get the last element. - /*! - \pre !empty() - \return A reference to the last element of the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa front() - */ - reference back() { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (back element not available) - return *((m_last == m_buff ? m_end : m_last) - 1); - } - - //! Get the first element. - /*! - \pre !empty() - \return A const reference to the first element of the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa back() const - */ - const_reference front() const { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (front element not available) - return *m_first; - } - - //! Get the last element. - /*! - \pre !empty() - \return A const reference to the last element of the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa front() const - */ - const_reference back() const { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (back element not available) - return *((m_last == m_buff ? m_end : m_last) - 1); - } - - //! Get the first continuous array of the internal buffer. - /*! - This method in combination with array_two() can be useful when passing the stored data into - a legacy C API as an array. Suppose there is a circular_buffer of capacity 10, containing 7 - characters 'a', 'b', ..., 'g' where buff[0] == 'a', buff[1] == 'b', - ... and buff[6] == 'g':

- circular_buffer buff(10);

- The internal representation is often not linear and the state of the internal buffer may look like this:
-
- |e|f|g| | | |a|b|c|d|
- end ___^
- begin _______^


- - where |a|b|c|d| represents the "array one", |e|f|g| represents the "array two" and - | | | | is a free space.
- Now consider a typical C style function for writing data into a file:

- int write(int file_desc, char* buff, int num_bytes);

- There are two ways how to write the content of the circular_buffer into a file. Either relying - on array_one() and array_two() methods and calling the write function twice:

- array_range ar = buff.array_one();
- write(file_desc, ar.first, ar.second);
- ar = buff.array_two();
- write(file_desc, ar.first, ar.second);


- Or relying on the linearize() method:

- write(file_desc, buff.linearize(), buff.size());

- Since the complexity of array_one() and array_two() methods is constant the first - option is suitable when calling the write method is "cheap". On the other hand the second option is more - suitable when calling the write method is more "expensive" than calling the linearize() method - whose complexity is linear. - \return The array range of the first continuous array of the internal buffer. In the case the - circular_buffer is empty the size of the returned array is 0. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \warning In general invoking any method which modifies the internal state of the circular_buffer may - delinearize the internal buffer and invalidate the array ranges returned by array_one() - and array_two() (and their const versions). - \note In the case the internal buffer is linear e.g. |a|b|c|d|e|f|g| | | | the "array one" is - represented by |a|b|c|d|e|f|g| and the "array two" does not exist (the - array_two() method returns an array with the size 0). - \sa array_two(), linearize() - */ - array_range array_one() { - return array_range(m_first, (m_last <= m_first && !empty() ? m_end : m_last) - m_first); - } - - //! Get the second continuous array of the internal buffer. - /*! - This method in combination with array_one() can be useful when passing the stored data into - a legacy C API as an array. - \return The array range of the second continuous array of the internal buffer. In the case the internal buffer - is linear or the circular_buffer is empty the size of the returned array is - 0. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa array_one() - */ - array_range array_two() { - return array_range(m_buff, m_last <= m_first && !empty() ? m_last - m_buff : 0); - } - - //! Get the first continuous array of the internal buffer. - /*! - This method in combination with array_two() const can be useful when passing the stored data into - a legacy C API as an array. - \return The array range of the first continuous array of the internal buffer. In the case the - circular_buffer is empty the size of the returned array is 0. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa array_two() const; array_one() for more details how to pass data into a legacy C - API. - */ - const_array_range array_one() const { - return const_array_range(m_first, (m_last <= m_first && !empty() ? m_end : m_last) - m_first); - } - - //! Get the second continuous array of the internal buffer. - /*! - This method in combination with array_one() const can be useful when passing the stored data into - a legacy C API as an array. - \return The array range of the second continuous array of the internal buffer. In the case the internal buffer - is linear or the circular_buffer is empty the size of the returned array is - 0. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa array_one() const - */ - const_array_range array_two() const { - return const_array_range(m_buff, m_last <= m_first && !empty() ? m_last - m_buff : 0); - } - - //! Linearize the internal buffer into a continuous array. - /*! - This method can be useful when passing the stored data into a legacy C API as an array. - \post \&(*this)[0] \< \&(*this)[1] \< ... \< \&(*this)[size() - 1] - \return A pointer to the beginning of the array or 0 if empty. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()); does not invalidate any iterators if the postcondition (the Effect) is already - met prior calling this method. - \par Complexity - Linear (in the size of the circular_buffer); constant if the postcondition (the - Effect) is already met. - \warning In general invoking any method which modifies the internal state of the circular_buffer - may delinearize the internal buffer and invalidate the returned pointer. - \sa array_one() and array_two() for the other option how to pass data into a legacy - C API; is_linearized(), rotate(const_iterator) - */ - pointer linearize() { - if (empty()) - return 0; - if (m_first < m_last || m_last == m_buff) - return m_first; - pointer src = m_first; - pointer dest = m_buff; - size_type moved = 0; - size_type constructed = 0; - BOOST_TRY { - for (pointer first = m_first; dest < src; src = first) { - for (size_type ii = 0; src < m_end; ++src, ++dest, ++moved, ++ii) { - if (moved == size()) { - first = dest; - break; - } - if (dest == first) { - first += ii; - break; - } - if (is_uninitialized(dest)) { - ::new (dest) value_type(this_type::move_if_noexcept(*src)); - ++constructed; - } else { - value_type tmp = this_type::move_if_noexcept(*src); - replace(src, this_type::move_if_noexcept(*dest)); - replace(dest, boost::move(tmp)); - } - } - } - } BOOST_CATCH(...) { - m_last += constructed; - m_size += constructed; - BOOST_RETHROW - } - BOOST_CATCH_END - for (src = m_end - constructed; src < m_end; ++src) - destroy_item(src); - m_first = m_buff; - m_last = add(m_buff, size()); -#if BOOST_CB_ENABLE_DEBUG - invalidate_iterators_except(end()); -#endif - return m_buff; - } - - //! Is the circular_buffer linearized? - /*! - \return true if the internal buffer is linearized into a continuous array (i.e. the - circular_buffer meets a condition - \&(*this)[0] \< \&(*this)[1] \< ... \< \&(*this)[size() - 1]); - false otherwise. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa linearize(), array_one(), array_two() - */ - bool is_linearized() const BOOST_NOEXCEPT { return m_first < m_last || m_last == m_buff; } - - //! Rotate elements in the circular_buffer. - /*! - A more effective implementation of - std::rotate. - \pre new_begin is a valid iterator pointing to the circular_buffer except its - end. - \post Before calling the method suppose:

- m == std::distance(new_begin, end())
n == std::distance(begin(), new_begin) -
val_0 == *new_begin, val_1 == *(new_begin + 1), ... val_m == *(new_begin + m)
- val_r1 == *(new_begin - 1), val_r2 == *(new_begin - 2), ... val_rn == *(new_begin - n)
-
then after call to the method:

- val_0 == (*this)[0] \&\& val_1 == (*this)[1] \&\& ... \&\& val_m == (*this)[m - 1] \&\& val_r1 == - (*this)[m + n - 1] \&\& val_r2 == (*this)[m + n - 2] \&\& ... \&\& val_rn == (*this)[m] - \param new_begin The new beginning. - \throws See Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the circular_buffer is full or new_begin points to - begin() or if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - If m \< n invalidates iterators pointing to the last m elements - (including new_begin, but not iterators equal to end()) else invalidates - iterators pointing to the first n elements; does not invalidate any iterators if the - circular_buffer is full. - \par Complexity - Linear (in (std::min)(m, n)); constant if the circular_buffer is full. - \sa std::rotate - */ - void rotate(const_iterator new_begin) { - BOOST_CB_ASSERT(new_begin.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(new_begin.m_it != 0); // check for iterator pointing to end() - if (full()) { - m_first = m_last = const_cast(new_begin.m_it); - } else { - difference_type m = end() - new_begin; - difference_type n = new_begin - begin(); - if (m < n) { - for (; m > 0; --m) { - push_front(this_type::move_if_noexcept(back())); - pop_back(); - } - } else { - for (; n > 0; --n) { - push_back(this_type::move_if_noexcept(front())); - pop_front(); - } - } - } - } - -// Size and capacity - - //! Get the number of elements currently stored in the circular_buffer. - /*! - \return The number of elements stored in the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa capacity(), max_size(), reserve(), - \link resize() resize(size_type, const_reference)\endlink - */ - size_type size() const BOOST_NOEXCEPT { return m_size; } - - /*! \brief Get the largest possible size or capacity of the circular_buffer. (It depends on - allocator's %max_size()). - \return The maximum size/capacity the circular_buffer can be set to. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa size(), capacity(), reserve() - */ - size_type max_size() const BOOST_NOEXCEPT { - return (std::min)(m_alloc.max_size(), (std::numeric_limits::max)()); - } - - //! Is the circular_buffer empty? - /*! - \return true if there are no elements stored in the circular_buffer; - false otherwise. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa full() - */ - bool empty() const BOOST_NOEXCEPT { return size() == 0; } - - //! Is the circular_buffer full? - /*! - \return true if the number of elements stored in the circular_buffer - equals the capacity of the circular_buffer; false otherwise. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa empty() - */ - bool full() const BOOST_NOEXCEPT { return capacity() == size(); } - - /*! \brief Get the maximum number of elements which can be inserted into the circular_buffer without - overwriting any of already stored elements. - \return capacity() - size() - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa capacity(), size(), max_size() - */ - size_type reserve() const BOOST_NOEXCEPT { return capacity() - size(); } - - //! Get the capacity of the circular_buffer. - /*! - \return The maximum number of elements which can be stored in the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer). - \sa reserve(), size(), max_size(), - set_capacity(capacity_type) - */ - capacity_type capacity() const BOOST_NOEXCEPT { return m_end - m_buff; } - - //! Change the capacity of the circular_buffer. - /*! - \pre If T is a move only type, then compiler shall support noexcept modifiers - and move constructor of T must be marked with it (must not throw exceptions). - \post capacity() == new_capacity \&\& size() \<= new_capacity

- If the current number of elements stored in the circular_buffer is greater than the desired - new capacity then number of [size() - new_capacity] last elements will be removed and - the new size will be equal to new_capacity. - \param new_capacity The new capacity. - \throws "An allocation error" if memory is exhausted, (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()) if the new capacity is different from the original. - \par Complexity - Linear (in min[size(), new_capacity]). - \sa rset_capacity(capacity_type), - \link resize() resize(size_type, const_reference)\endlink - */ - void set_capacity(capacity_type new_capacity) { - if (new_capacity == capacity()) - return; - pointer buff = allocate(new_capacity); - iterator b = begin(); - BOOST_TRY { - reset(buff, - cb_details::uninitialized_move_if_noexcept(b, b + (std::min)(new_capacity, size()), buff), - new_capacity); - } BOOST_CATCH(...) { - deallocate(buff, new_capacity); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - //! Change the size of the circular_buffer. - /*! - \post size() == new_size \&\& capacity() >= new_size

- If the new size is greater than the current size, copies of item will be inserted at the - back of the of the circular_buffer in order to achieve the desired size. In the case - the resulting size exceeds the current capacity the capacity will be set to new_size.
- If the current number of elements stored in the circular_buffer is greater than the desired - new size then number of [size() - new_size] last elements will be removed. (The - capacity will remain unchanged.) - \param new_size The new size. - \param item The element the circular_buffer will be filled with in order to gain the requested - size. (See the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()) if the new size is greater than the current capacity. Invalidates iterators pointing - to the removed elements if the new size is lower that the original size. Otherwise it does not invalidate - any iterator. - \par Complexity - Linear (in the new size of the circular_buffer). - \sa \link rresize() rresize(size_type, const_reference)\endlink, - set_capacity(capacity_type) - */ - void resize(size_type new_size, param_value_type item = value_type()) { - if (new_size > size()) { - if (new_size > capacity()) - set_capacity(new_size); - insert(end(), new_size - size(), item); - } else { - iterator e = end(); - erase(e - (size() - new_size), e); - } - } - - //! Change the capacity of the circular_buffer. - /*! - \pre If T is a move only type, then compiler shall support noexcept modifiers - and move constructor of T must be marked with it (must not throw exceptions). - \post capacity() == new_capacity \&\& size() \<= new_capacity

- If the current number of elements stored in the circular_buffer is greater than the desired - new capacity then number of [size() - new_capacity] first elements will be removed - and the new size will be equal to new_capacity. - \param new_capacity The new capacity. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()) if the new capacity is different from the original. - \par Complexity - Linear (in min[size(), new_capacity]). - \sa set_capacity(capacity_type), - \link rresize() rresize(size_type, const_reference)\endlink - */ - void rset_capacity(capacity_type new_capacity) { - if (new_capacity == capacity()) - return; - pointer buff = allocate(new_capacity); - iterator e = end(); - BOOST_TRY { - reset(buff, cb_details::uninitialized_move_if_noexcept(e - (std::min)(new_capacity, size()), - e, buff), new_capacity); - } BOOST_CATCH(...) { - deallocate(buff, new_capacity); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - //! Change the size of the circular_buffer. - /*! - \post size() == new_size \&\& capacity() >= new_size

- If the new size is greater than the current size, copies of item will be inserted at the - front of the of the circular_buffer in order to achieve the desired size. In the case - the resulting size exceeds the current capacity the capacity will be set to new_size.
- If the current number of elements stored in the circular_buffer is greater than the desired - new size then number of [size() - new_size] first elements will be removed. (The - capacity will remain unchanged.) - \param new_size The new size. - \param item The element the circular_buffer will be filled with in order to gain the requested - size. (See the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()) if the new size is greater than the current capacity. Invalidates iterators pointing - to the removed elements if the new size is lower that the original size. Otherwise it does not invalidate - any iterator. - \par Complexity - Linear (in the new size of the circular_buffer). - \sa \link resize() resize(size_type, const_reference)\endlink, - rset_capacity(capacity_type) - */ - void rresize(size_type new_size, param_value_type item = value_type()) { - if (new_size > size()) { - if (new_size > capacity()) - set_capacity(new_size); - rinsert(begin(), new_size - size(), item); - } else { - rerase(begin(), end() - new_size); - } - } - -// Construction/Destruction - - //! Create an empty circular_buffer with zero capacity. - /*! - \post capacity() == 0 \&\& size() == 0 - \param alloc The allocator. - \throws Nothing. - \par Complexity - Constant. - \warning Since Boost version 1.36 the behaviour of this constructor has changed. Now the constructor does not - allocate any memory and both capacity and size are set to zero. Also note when inserting an element - into a circular_buffer with zero capacity (e.g. by - \link push_back() push_back(const_reference)\endlink or - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink) nothing - will be inserted and the size (as well as capacity) remains zero. - \note You can explicitly set the capacity by calling the set_capacity(capacity_type) method or you - can use the other constructor with the capacity specified. - \sa circular_buffer(capacity_type, const allocator_type& alloc), - set_capacity(capacity_type) - */ - explicit circular_buffer(const allocator_type& alloc = allocator_type()) BOOST_NOEXCEPT - : m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0), m_alloc(alloc) {} - - //! Create an empty circular_buffer with the specified capacity. - /*! - \post capacity() == buffer_capacity \&\& size() == 0 - \param buffer_capacity The maximum number of elements which can be stored in the circular_buffer. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Complexity - Constant. - */ - explicit circular_buffer(capacity_type buffer_capacity, const allocator_type& alloc = allocator_type()) - : m_size(0), m_alloc(alloc) { - initialize_buffer(buffer_capacity); - m_first = m_last = m_buff; - } - - /*! \brief Create a full circular_buffer with the specified capacity and filled with n - copies of item. - \post capacity() == n \&\& full() \&\& (*this)[0] == item \&\& (*this)[1] == item \&\& ... \&\& - (*this)[n - 1] == item - \param n The number of elements the created circular_buffer will be filled with. - \param item The element the created circular_buffer will be filled with. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the n). - */ - circular_buffer(size_type n, param_value_type item, const allocator_type& alloc = allocator_type()) - : m_size(n), m_alloc(alloc) { - initialize_buffer(n, item); - m_first = m_last = m_buff; - } - - /*! \brief Create a circular_buffer with the specified capacity and filled with n - copies of item. - \pre buffer_capacity >= n - \post capacity() == buffer_capacity \&\& size() == n \&\& (*this)[0] == item \&\& (*this)[1] == item - \&\& ... \&\& (*this)[n - 1] == item - \param buffer_capacity The capacity of the created circular_buffer. - \param n The number of elements the created circular_buffer will be filled with. - \param item The element the created circular_buffer will be filled with. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the n). - */ - circular_buffer(capacity_type buffer_capacity, size_type n, param_value_type item, - const allocator_type& alloc = allocator_type()) - : m_size(n), m_alloc(alloc) { - BOOST_CB_ASSERT(buffer_capacity >= size()); // check for capacity lower than size - initialize_buffer(buffer_capacity, item); - m_first = m_buff; - m_last = buffer_capacity == n ? m_buff : m_buff + n; - } - - //! The copy constructor. - /*! - Creates a copy of the specified circular_buffer. - \post *this == cb - \param cb The circular_buffer to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the size of cb). - */ - circular_buffer(const circular_buffer& cb) - : -#if BOOST_CB_ENABLE_DEBUG - debug_iterator_registry(), -#endif - m_size(cb.size()), m_alloc(cb.get_allocator()) { - initialize_buffer(cb.capacity()); - m_first = m_buff; - BOOST_TRY { - m_last = cb_details::uninitialized_copy(cb.begin(), cb.end(), m_buff); - } BOOST_CATCH(...) { - deallocate(m_buff, cb.capacity()); - BOOST_RETHROW - } - BOOST_CATCH_END - if (m_last == m_end) - m_last = m_buff; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - //! The move constructor. - /*! \brief Move constructs a circular_buffer from cb, leaving cb empty. - \pre C++ compiler with rvalue references support. - \post cb.empty() - \param cb circular_buffer to 'steal' value from. - \throws Nothing. - \par Constant. - */ - circular_buffer(circular_buffer&& cb) BOOST_NOEXCEPT - : m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0), m_alloc(cb.get_allocator()) { - cb.swap(*this); - } -#endif // BOOST_NO_CXX11_RVALUE_REFERENCES - - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - - /*! \cond */ - template - circular_buffer(InputIterator first, InputIterator last) - : m_alloc(allocator_type()) { - initialize(first, last, is_integral()); - } - - template - circular_buffer(capacity_type capacity, InputIterator first, InputIterator last) - : m_alloc(allocator_type()) { - initialize(capacity, first, last, is_integral()); - } - /*! \endcond */ - -#else - - //! Create a full circular_buffer filled with a copy of the range. - /*! - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == std::distance(first, last) \&\& full() \&\& (*this)[0]== *first \&\& - (*this)[1] == *(first + 1) \&\& ... \&\& (*this)[std::distance(first, last) - 1] == *(last - 1) - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the std::distance(first, last)). - */ - template - circular_buffer(InputIterator first, InputIterator last, const allocator_type& alloc = allocator_type()) - : m_alloc(alloc) { - initialize(first, last, is_integral()); - } - - //! Create a circular_buffer with the specified capacity and filled with a copy of the range. - /*! - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == buffer_capacity \&\& size() \<= std::distance(first, last) \&\& - (*this)[0]== *(last - buffer_capacity) \&\& (*this)[1] == *(last - buffer_capacity + 1) \&\& ... \&\& - (*this)[buffer_capacity - 1] == *(last - 1)

- If the number of items to be copied from the range [first, last) is greater than the - specified buffer_capacity then only elements from the range - [last - buffer_capacity, last) will be copied. - \param buffer_capacity The capacity of the created circular_buffer. - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in std::distance(first, last); in - min[capacity, std::distance(first, last)] if the InputIterator is a - RandomAccessIterator). - */ - template - circular_buffer(capacity_type buffer_capacity, InputIterator first, InputIterator last, - const allocator_type& alloc = allocator_type()) - : m_alloc(alloc) { - initialize(buffer_capacity, first, last, is_integral()); - } - -#endif // #if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - - //! The destructor. - /*! - Destroys the circular_buffer. - \throws Nothing. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (including iterators equal to - end()). - \par Complexity - Constant (in the size of the circular_buffer) for scalar types; linear for other types. - \sa clear() - */ - ~circular_buffer() BOOST_NOEXCEPT { - destroy(); -#if BOOST_CB_ENABLE_DEBUG - invalidate_all_iterators(); -#endif - } - -public: -// Assign methods - - //! The assign operator. - /*! - Makes this circular_buffer to become a copy of the specified circular_buffer. - \post *this == cb - \param cb The circular_buffer to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to this circular_buffer (except iterators equal to - end()). - \par Complexity - Linear (in the size of cb). - \sa \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - circular_buffer& operator = (const circular_buffer& cb) { - if (this == &cb) - return *this; - pointer buff = allocate(cb.capacity()); - BOOST_TRY { - reset(buff, cb_details::uninitialized_copy(cb.begin(), cb.end(), buff), cb.capacity()); - } BOOST_CATCH(...) { - deallocate(buff, cb.capacity()); - BOOST_RETHROW - } - BOOST_CATCH_END - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - /*! \brief Move assigns content of cb to *this, leaving cb empty. - \pre C++ compiler with rvalue references support. - \post cb.empty() - \param cb circular_buffer to 'steal' value from. - \throws Nothing. - \par Complexity - Constant. - */ - circular_buffer& operator = (circular_buffer&& cb) BOOST_NOEXCEPT { - cb.swap(*this); // now `this` holds `cb` - circular_buffer(get_allocator()) // temprary that holds initial `cb` allocator - .swap(cb); // makes `cb` empty - return *this; - } -#endif // BOOST_NO_CXX11_RVALUE_REFERENCES - - //! Assign n items into the circular_buffer. - /*! - The content of the circular_buffer will be removed and replaced with n copies of the - item. - \post capacity() == n \&\& size() == n \&\& (*this)[0] == item \&\& (*this)[1] == item \&\& ... \&\& - (*this) [n - 1] == item - \param n The number of elements the circular_buffer will be filled with. - \param item The element the circular_buffer will be filled with. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()). - \par Complexity - Linear (in the n). - \sa \link operator=(const circular_buffer&) operator=\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - void assign(size_type n, param_value_type item) { - assign_n(n, n, cb_details::assign_n(n, item, m_alloc)); - } - - //! Assign n items into the circular_buffer specifying the capacity. - /*! - The capacity of the circular_buffer will be set to the specified value and the content of the - circular_buffer will be removed and replaced with n copies of the item. - \pre capacity >= n - \post capacity() == buffer_capacity \&\& size() == n \&\& (*this)[0] == item \&\& (*this)[1] == item - \&\& ... \&\& (*this) [n - 1] == item - \param buffer_capacity The new capacity. - \param n The number of elements the circular_buffer will be filled with. - \param item The element the circular_buffer will be filled with. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()). - \par Complexity - Linear (in the n). - \sa \link operator=(const circular_buffer&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - void assign(capacity_type buffer_capacity, size_type n, param_value_type item) { - BOOST_CB_ASSERT(buffer_capacity >= n); // check for new capacity lower than n - assign_n(buffer_capacity, n, cb_details::assign_n(n, item, m_alloc)); - } - - //! Assign a copy of the range into the circular_buffer. - /*! - The content of the circular_buffer will be removed and replaced with copies of elements from the - specified range. - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == std::distance(first, last) \&\& size() == std::distance(first, last) \&\& - (*this)[0]== *first \&\& (*this)[1] == *(first + 1) \&\& ... \&\& (*this)[std::distance(first, last) - 1] - == *(last - 1) - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()). - \par Complexity - Linear (in the std::distance(first, last)). - \sa \link operator=(const circular_buffer&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(capacity_type, InputIterator, InputIterator) - */ - template - void assign(InputIterator first, InputIterator last) { - assign(first, last, is_integral()); - } - - //! Assign a copy of the range into the circular_buffer specifying the capacity. - /*! - The capacity of the circular_buffer will be set to the specified value and the content of the - circular_buffer will be removed and replaced with copies of elements from the specified range. - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == buffer_capacity \&\& size() \<= std::distance(first, last) \&\& - (*this)[0]== *(last - buffer_capacity) \&\& (*this)[1] == *(last - buffer_capacity + 1) \&\& ... \&\& - (*this)[buffer_capacity - 1] == *(last - 1)

- If the number of items to be copied from the range [first, last) is greater than the - specified buffer_capacity then only elements from the range - [last - buffer_capacity, last) will be copied. - \param buffer_capacity The new capacity. - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()). - \par Complexity - Linear (in std::distance(first, last); in - min[capacity, std::distance(first, last)] if the InputIterator is a - RandomAccessIterator). - \sa \link operator=(const circular_buffer&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator) - */ - template - void assign(capacity_type buffer_capacity, InputIterator first, InputIterator last) { - assign(buffer_capacity, first, last, is_integral()); - } - - //! Swap the contents of two circular_buffers. - /*! - \post this contains elements of cb and vice versa; the capacity of this - equals to the capacity of cb and vice versa. - \param cb The circular_buffer whose content will be swapped. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Invalidates all iterators of both circular_buffers. (On the other hand the iterators still - point to the same elements but within another container. If you want to rely on this feature you have to - turn the Debug Support off otherwise an assertion will report an error if such - invalidated iterator is used.) - \par Complexity - Constant (in the size of the circular_buffer). - \sa swap(circular_buffer&, circular_buffer&) - */ - void swap(circular_buffer& cb) BOOST_NOEXCEPT { - swap_allocator(cb, is_stateless()); - std::swap(m_buff, cb.m_buff); - std::swap(m_end, cb.m_end); - std::swap(m_first, cb.m_first); - std::swap(m_last, cb.m_last); - std::swap(m_size, cb.m_size); -#if BOOST_CB_ENABLE_DEBUG - invalidate_all_iterators(); - cb.invalidate_all_iterators(); -#endif - } - -// push and pop -private: - template - void push_back_impl(ValT item) { - if (full()) { - if (empty()) - return; - replace(m_last, static_cast(item)); - increment(m_last); - m_first = m_last; - } else { - ::new (m_last) value_type(static_cast(item)); - increment(m_last); - ++m_size; - } - } - - template - void push_front_impl(ValT item) { - BOOST_TRY { - if (full()) { - if (empty()) - return; - decrement(m_first); - replace(m_first, static_cast(item)); - m_last = m_first; - } else { - decrement(m_first); - ::new (m_first) value_type(static_cast(item)); - ++m_size; - } - } BOOST_CATCH(...) { - increment(m_first); - BOOST_RETHROW - } - BOOST_CATCH_END - } - -public: - //! Insert a new element at the end of the circular_buffer. - /*! - \post if capacity() > 0 then back() == item
- If the circular_buffer is full, the first element will be removed. If the capacity is - 0, nothing will be inserted. - \param item The element to be inserted. - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_front() push_front(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_back(param_value_type item) { - push_back_impl(item); - } - - //! Insert a new element at the end of the circular_buffer using rvalue references or rvalues references emulation. - /*! - \post if capacity() > 0 then back() == item
- If the circular_buffer is full, the first element will be removed. If the capacity is - 0, nothing will be inserted. - \param item The element to be inserted. - \throws Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_front() push_front(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_back(rvalue_type item) { - push_back_impl(boost::move(item)); - } - - //! Insert a new default-constructed element at the end of the circular_buffer. - /*! - \post if capacity() > 0 then back() == item
- If the circular_buffer is full, the first element will be removed. If the capacity is - 0, nothing will be inserted. - \throws Whatever T::T() throws. - Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_front() push_front(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_back() { - value_type temp; - push_back(boost::move(temp)); - } - - //! Insert a new element at the beginning of the circular_buffer. - /*! - \post if capacity() > 0 then front() == item
- If the circular_buffer is full, the last element will be removed. If the capacity is - 0, nothing will be inserted. - \param item The element to be inserted. - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_back() push_back(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_front(param_value_type item) { - push_front_impl(item); - } - - //! Insert a new element at the beginning of the circular_buffer using rvalue references or rvalues references emulation. - /*! - \post if capacity() > 0 then front() == item
- If the circular_buffer is full, the last element will be removed. If the capacity is - 0, nothing will be inserted. - \param item The element to be inserted. - \throws Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_back() push_back(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_front(rvalue_type item) { - push_front_impl(boost::move(item)); - } - - //! Insert a new default-constructed element at the beginning of the circular_buffer. - /*! - \post if capacity() > 0 then front() == item
- If the circular_buffer is full, the last element will be removed. If the capacity is - 0, nothing will be inserted. - \throws Whatever T::T() throws. - Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Does not invalidate any iterators with the exception of iterators pointing to the overwritten element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa \link push_back() push_back(const_reference)\endlink, - pop_back(), pop_front() - */ - void push_front() { - value_type temp; - push_front(boost::move(temp)); - } - - //! Remove the last element from the circular_buffer. - /*! - \pre !empty() - \post The last element is removed from the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Invalidates only iterators pointing to the removed element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa pop_front(), \link push_back() push_back(const_reference)\endlink, - \link push_front() push_front(const_reference)\endlink - */ - void pop_back() { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (back element not available) - decrement(m_last); - destroy_item(m_last); - --m_size; - } - - //! Remove the first element from the circular_buffer. - /*! - \pre !empty() - \post The first element is removed from the circular_buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Invalidates only iterators pointing to the removed element. - \par Complexity - Constant (in the size of the circular_buffer). - \sa pop_back(), \link push_back() push_back(const_reference)\endlink, - \link push_front() push_front(const_reference)\endlink - */ - void pop_front() { - BOOST_CB_ASSERT(!empty()); // check for empty buffer (front element not available) - destroy_item(m_first); - increment(m_first); - --m_size; - } -private: - template - iterator insert_impl(iterator pos, ValT item) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - iterator b = begin(); - if (full() && pos == b) - return b; - return insert_item(pos, static_cast(item)); - } - -public: -// Insert - - //! Insert an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted at the position pos.
- If the circular_buffer is full, the first element will be overwritten. If the - circular_buffer is full and the pos points to begin(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position where the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - Exceptions of move_if_noexcept(T&). - - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements at the insertion point (including pos) and - iterators behind the insertion point (towards the end; except iterators equal to end()). It - also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(pos, end())). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos, param_value_type item) { - return insert_impl(pos, item); - } - - //! Insert an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted at the position pos.
- If the circular_buffer is full, the first element will be overwritten. If the - circular_buffer is full and the pos points to begin(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position where the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements at the insertion point (including pos) and - iterators behind the insertion point (towards the end; except iterators equal to end()). It - also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(pos, end())). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos, rvalue_type item) { - return insert_impl(pos, boost::move(item)); - } - - //! Insert a default-constructed element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted at the position pos.
- If the circular_buffer is full, the first element will be overwritten. If the - circular_buffer is full and the pos points to begin(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position where the item will be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T() throws. - Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements at the insertion point (including pos) and - iterators behind the insertion point (towards the end; except iterators equal to end()). It - also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(pos, end())). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos) { - value_type temp; - return insert(pos, boost::move(temp)); - } - - //! Insert n copies of the item at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The number of min[n, (pos - begin()) + reserve()] elements will be inserted at the position - pos.
The number of min[pos - begin(), max[0, n - reserve()]] elements will - be overwritten at the beginning of the circular_buffer.
(See Example for the - explanation.) - \param pos An iterator specifying the position where the items will be inserted. - \param n The number of items the to be inserted. - \param item The element whose copies will be inserted. - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements at the insertion point (including pos) and - iterators behind the insertion point (towards the end; except iterators equal to end()). It - also invalidates iterators pointing to the overwritten elements. - \par Complexity - Linear (in min[capacity(), std::distance(pos, end()) + n]). - \par Example - Consider a circular_buffer with the capacity of 6 and the size of 4. Its internal buffer may - look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting 5 elements at the position p:

- insert(p, (size_t)5, 0);

actually only 4 elements get inserted and elements - 1 and 2 are overwritten. This is due to the fact the insert operation preserves - the capacity. After insertion the internal buffer looks like this:

|0|0|0|0|3|4|
-
For comparison if the capacity would not be preserved the internal buffer would then result in - |1|2|0|0|0|0|0|3|4|. - \sa \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - void insert(iterator pos, size_type n, param_value_type item) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - if (n == 0) - return; - size_type copy = capacity() - (end() - pos); - if (copy == 0) - return; - if (n > copy) - n = copy; - insert_n(pos, n, cb_details::item_wrapper(item)); - } - - //! Insert the range [first, last) at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end.
- Valid range [first, last) where first and last meet the - requirements of an InputIterator. - \post Elements from the range - [first + max[0, distance(first, last) - (pos - begin()) - reserve()], last) will be - inserted at the position pos.
The number of min[pos - begin(), max[0, - distance(first, last) - reserve()]] elements will be overwritten at the beginning of the - circular_buffer.
(See Example for the explanation.) - \param pos An iterator specifying the position where the range will be inserted. - \param first The beginning of the range to be inserted. - \param last The end of the range to be inserted. - \throws Whatever T::T(const T&) throws if the InputIterator is not a move iterator. - Whatever T::operator = (const T&) throws if the InputIterator is not a move iterator. - Whatever T::T(T&&) throws if the InputIterator is a move iterator. - Whatever T::operator = (T&&) throws if the InputIterator is a move iterator. - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements at the insertion point (including pos) and - iterators behind the insertion point (towards the end; except iterators equal to end()). It - also invalidates iterators pointing to the overwritten elements. - \par Complexity - Linear (in [std::distance(pos, end()) + std::distance(first, last)]; in - min[capacity(), std::distance(pos, end()) + std::distance(first, last)] if the - InputIterator is a - RandomAccessIterator). - \par Example - Consider a circular_buffer with the capacity of 6 and the size of 4. Its internal buffer may - look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting a range of elements at the position p:

- int array[] = { 5, 6, 7, 8, 9 };
insert(p, array, array + 5);

- actually only elements 6, 7, 8 and 9 from the - specified range get inserted and elements 1 and 2 are overwritten. This is due - to the fact the insert operation preserves the capacity. After insertion the internal buffer looks like - this:

|6|7|8|9|3|4|

For comparison if the capacity would not be preserved the - internal buffer would then result in |1|2|5|6|7|8|9|3|4|. - \sa \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, \link rinsert(iterator, param_value_type) - rinsert(iterator, value_type)\endlink, \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - template - void insert(iterator pos, InputIterator first, InputIterator last) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - insert(pos, first, last, is_integral()); - } - -private: - template - iterator rinsert_impl(iterator pos, ValT item) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - if (full() && pos.m_it == 0) - return end(); - if (pos == begin()) { - BOOST_TRY { - decrement(m_first); - construct_or_replace(!full(), m_first, static_cast(item)); - } BOOST_CATCH(...) { - increment(m_first); - BOOST_RETHROW - } - BOOST_CATCH_END - pos.m_it = m_first; - } else { - pointer src = m_first; - pointer dest = m_first; - decrement(dest); - pos.m_it = map_pointer(pos.m_it); - bool construct = !full(); - BOOST_TRY { - while (src != pos.m_it) { - construct_or_replace(construct, dest, this_type::move_if_noexcept(*src)); - increment(src); - increment(dest); - construct = false; - } - decrement(pos.m_it); - replace(pos.m_it, static_cast(item)); - } BOOST_CATCH(...) { - if (!construct && !full()) { - decrement(m_first); - ++m_size; - } - BOOST_RETHROW - } - BOOST_CATCH_END - decrement(m_first); - } - if (full()) - m_last = m_first; - else - ++m_size; - return iterator(this, pos.m_it); - } - -public: - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted before the position pos.
- If the circular_buffer is full, the last element will be overwritten. If the - circular_buffer is full and the pos points to end(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position before which the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements before the insertion point (towards the beginning and - excluding pos). It also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(begin(), pos)). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos, param_value_type item) { - return rinsert_impl(pos, item); - } - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted before the position pos.
- If the circular_buffer is full, the last element will be overwritten. If the - circular_buffer is full and the pos points to end(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position before which the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements before the insertion point (towards the beginning and - excluding pos). It also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(begin(), pos)). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos, rvalue_type item) { - return rinsert_impl(pos, boost::move(item)); - } - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The item will be inserted before the position pos.
- If the circular_buffer is full, the last element will be overwritten. If the - circular_buffer is full and the pos points to end(), then the - item will not be inserted. If the capacity is 0, nothing will be inserted. - \param pos An iterator specifying the position before which the item will be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws Whatever T::T() throws. - Whatever T::T(T&&) throws. - Whatever T::operator = (T&&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements before the insertion point (towards the beginning and - excluding pos). It also invalidates iterators pointing to the overwritten element. - \par Complexity - Linear (in std::distance(begin(), pos)). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos) { - value_type temp; - return rinsert(pos, boost::move(temp)); - } - - //! Insert n copies of the item before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end. - \post The number of min[n, (end() - pos) + reserve()] elements will be inserted before the - position pos.
The number of min[end() - pos, max[0, n - reserve()]] elements - will be overwritten at the end of the circular_buffer.
(See Example for the - explanation.) - \param pos An iterator specifying the position where the items will be inserted. - \param n The number of items the to be inserted. - \param item The element whose copies will be inserted. - \throws Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements before the insertion point (towards the beginning and - excluding pos). It also invalidates iterators pointing to the overwritten elements. - \par Complexity - Linear (in min[capacity(), std::distance(begin(), pos) + n]). - \par Example - Consider a circular_buffer with the capacity of 6 and the size of 4. Its internal buffer may - look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting 5 elements before the position p:

- rinsert(p, (size_t)5, 0);

actually only 4 elements get inserted and elements - 3 and 4 are overwritten. This is due to the fact the rinsert operation preserves - the capacity. After insertion the internal buffer looks like this:

|1|2|0|0|0|0|
-
For comparison if the capacity would not be preserved the internal buffer would then result in - |1|2|0|0|0|0|0|3|4|. - \sa \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - void rinsert(iterator pos, size_type n, param_value_type item) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - rinsert_n(pos, n, cb_details::item_wrapper(item)); - } - - //! Insert the range [first, last) before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer or its end.
- Valid range [first, last) where first and last meet the - requirements of an InputIterator. - \post Elements from the range - [first, last - max[0, distance(first, last) - (end() - pos) - reserve()]) will be inserted - before the position pos.
The number of min[end() - pos, max[0, - distance(first, last) - reserve()]] elements will be overwritten at the end of the - circular_buffer.
(See Example for the explanation.) - \param pos An iterator specifying the position where the range will be inserted. - \param first The beginning of the range to be inserted. - \param last The end of the range to be inserted. - \throws Whatever T::T(const T&) throws if the InputIterator is not a move iterator. - Whatever T::operator = (const T&) throws if the InputIterator is not a move iterator. - Whatever T::T(T&&) throws if the InputIterator is a move iterator. - Whatever T::operator = (T&&) throws if the InputIterator is a move iterator. - \par Exception Safety - Basic; no-throw if the operations in the Throws section do not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the elements before the insertion point (towards the beginning and - excluding pos). It also invalidates iterators pointing to the overwritten elements. - \par Complexity - Linear (in [std::distance(begin(), pos) + std::distance(first, last)]; in - min[capacity(), std::distance(begin(), pos) + std::distance(first, last)] if the - InputIterator is a - RandomAccessIterator). - \par Example - Consider a circular_buffer with the capacity of 6 and the size of 4. Its internal buffer may - look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting a range of elements before the position p:

- int array[] = { 5, 6, 7, 8, 9 };
insert(p, array, array + 5);

- actually only elements 5, 6, 7 and 8 from the - specified range get inserted and elements 3 and 4 are overwritten. This is due - to the fact the rinsert operation preserves the capacity. After insertion the internal buffer looks like - this:

|1|2|5|6|7|8|

For comparison if the capacity would not be preserved the - internal buffer would then result in |1|2|5|6|7|8|9|3|4|. - \sa \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, \link insert(iterator, param_value_type) - insert(iterator, value_type)\endlink, \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - template - void rinsert(iterator pos, InputIterator first, InputIterator last) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - rinsert(pos, first, last, is_integral()); - } - -// Erase - - //! Remove an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer (but not an - end()). - \post The element at the position pos is removed. - \param pos An iterator pointing at the element to be removed. - \return Iterator to the first element remaining beyond the removed element or end() if no such - element exists. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the erased element and iterators pointing to the elements behind - the erased element (towards the end; except iterators equal to end()). - \par Complexity - Linear (in std::distance(pos, end())). - \sa erase(iterator, iterator), rerase(iterator), - rerase(iterator, iterator), erase_begin(size_type), - erase_end(size_type), clear() - */ - iterator erase(iterator pos) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(pos.m_it != 0); // check for iterator pointing to end() - pointer next = pos.m_it; - increment(next); - for (pointer p = pos.m_it; next != m_last; p = next, increment(next)) - replace(p, this_type::move_if_noexcept(*next)); - decrement(m_last); - destroy_item(m_last); - --m_size; -#if BOOST_CB_ENABLE_DEBUG - return m_last == pos.m_it ? end() : iterator(this, pos.m_it); -#else - return m_last == pos.m_it ? end() : pos; -#endif - } - - //! Erase the range [first, last). - /*! - \pre Valid range [first, last). - \post The elements from the range [first, last) are removed. (If first == last - nothing is removed.) - \param first The beginning of the range to be removed. - \param last The end of the range to be removed. - \return Iterator to the first element remaining beyond the removed elements or end() if no such - element exists. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the erased elements and iterators pointing to the elements behind - the erased range (towards the end; except iterators equal to end()). - \par Complexity - Linear (in std::distance(first, end())). - \sa erase(iterator), rerase(iterator), rerase(iterator, iterator), - erase_begin(size_type), erase_end(size_type), clear() - */ - iterator erase(iterator first, iterator last) { - BOOST_CB_ASSERT(first.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(last.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(first <= last); // check for wrong range - if (first == last) - return first; - pointer p = first.m_it; - while (last.m_it != 0) - replace((first++).m_it, this_type::move_if_noexcept(*last++)); - do { - decrement(m_last); - destroy_item(m_last); - --m_size; - } while(m_last != first.m_it); - return m_last == p ? end() : iterator(this, p); - } - - //! Remove an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer (but not an - end()). - \post The element at the position pos is removed. - \param pos An iterator pointing at the element to be removed. - \return Iterator to the first element remaining in front of the removed element or begin() if no - such element exists. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the erased element and iterators pointing to the elements in front of - the erased element (towards the beginning). - \par Complexity - Linear (in std::distance(begin(), pos)). - \note This method is symetric to the erase(iterator) method and is more effective than - erase(iterator) if the iterator pos is close to the beginning of the - circular_buffer. (See the Complexity.) - \sa erase(iterator), erase(iterator, iterator), - rerase(iterator, iterator), erase_begin(size_type), - erase_end(size_type), clear() - */ - iterator rerase(iterator pos) { - BOOST_CB_ASSERT(pos.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(pos.m_it != 0); // check for iterator pointing to end() - pointer prev = pos.m_it; - pointer p = prev; - for (decrement(prev); p != m_first; p = prev, decrement(prev)) - replace(p, this_type::move_if_noexcept(*prev)); - destroy_item(m_first); - increment(m_first); - --m_size; -#if BOOST_CB_ENABLE_DEBUG - return p == pos.m_it ? begin() : iterator(this, pos.m_it); -#else - return p == pos.m_it ? begin() : pos; -#endif - } - - //! Erase the range [first, last). - /*! - \pre Valid range [first, last). - \post The elements from the range [first, last) are removed. (If first == last - nothing is removed.) - \param first The beginning of the range to be removed. - \param last The end of the range to be removed. - \return Iterator to the first element remaining in front of the removed elements or begin() if no - such element exists. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. - \par Iterator Invalidation - Invalidates iterators pointing to the erased elements and iterators pointing to the elements in front of - the erased range (towards the beginning). - \par Complexity - Linear (in std::distance(begin(), last)). - \note This method is symetric to the erase(iterator, iterator) method and is more effective than - erase(iterator, iterator) if std::distance(begin(), first) is lower that - std::distance(last, end()). - \sa erase(iterator), erase(iterator, iterator), rerase(iterator), - erase_begin(size_type), erase_end(size_type), clear() - */ - iterator rerase(iterator first, iterator last) { - BOOST_CB_ASSERT(first.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(last.is_valid(this)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(first <= last); // check for wrong range - if (first == last) - return first; - pointer p = map_pointer(last.m_it); - last.m_it = p; - while (first.m_it != m_first) { - decrement(first.m_it); - decrement(p); - replace(p, this_type::move_if_noexcept(*first.m_it)); - } - do { - destroy_item(m_first); - increment(m_first); - --m_size; - } while(m_first != p); - if (m_first == last.m_it) - return begin(); - decrement(last.m_it); - return iterator(this, last.m_it); - } - - //! Remove first n elements (with constant complexity for scalar types). - /*! - \pre n \<= size() - \post The n elements at the beginning of the circular_buffer will be removed. - \param n The number of elements to be removed. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. (I.e. no throw in - case of scalars.) - \par Iterator Invalidation - Invalidates iterators pointing to the first n erased elements. - \par Complexity - Constant (in n) for scalar types; linear for other types. - \note This method has been specially designed for types which do not require an explicit destructruction (e.g. - integer, float or a pointer). For these scalar types a call to a destructor is not required which makes - it possible to implement the "erase from beginning" operation with a constant complexity. For non-sacalar - types the complexity is linear (hence the explicit destruction is needed) and the implementation is - actually equivalent to - \link circular_buffer::rerase(iterator, iterator) rerase(begin(), begin() + n)\endlink. - \sa erase(iterator), erase(iterator, iterator), - rerase(iterator), rerase(iterator, iterator), - erase_end(size_type), clear() - */ - void erase_begin(size_type n) { - BOOST_CB_ASSERT(n <= size()); // check for n greater than size -#if BOOST_CB_ENABLE_DEBUG - erase_begin(n, false_type()); -#else - erase_begin(n, is_scalar()); -#endif - } - - //! Remove last n elements (with constant complexity for scalar types). - /*! - \pre n \<= size() - \post The n elements at the end of the circular_buffer will be removed. - \param n The number of elements to be removed. - \throws Exceptions of move_if_noexcept(T&). - \par Exception Safety - Basic; no-throw if the operation in the Throws section does not throw anything. (I.e. no throw in - case of scalars.) - \par Iterator Invalidation - Invalidates iterators pointing to the last n erased elements. - \par Complexity - Constant (in n) for scalar types; linear for other types. - \note This method has been specially designed for types which do not require an explicit destructruction (e.g. - integer, float or a pointer). For these scalar types a call to a destructor is not required which makes - it possible to implement the "erase from end" operation with a constant complexity. For non-sacalar - types the complexity is linear (hence the explicit destruction is needed) and the implementation is - actually equivalent to - \link circular_buffer::erase(iterator, iterator) erase(end() - n, end())\endlink. - \sa erase(iterator), erase(iterator, iterator), - rerase(iterator), rerase(iterator, iterator), - erase_begin(size_type), clear() - */ - void erase_end(size_type n) { - BOOST_CB_ASSERT(n <= size()); // check for n greater than size -#if BOOST_CB_ENABLE_DEBUG - erase_end(n, false_type()); -#else - erase_end(n, is_scalar()); -#endif - } - - //! Remove all stored elements from the circular_buffer. - /*! - \post size() == 0 - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer (except iterators equal to - end()). - \par Complexity - Constant (in the size of the circular_buffer) for scalar types; linear for other types. - \sa ~circular_buffer(), erase(iterator), erase(iterator, iterator), - rerase(iterator), rerase(iterator, iterator), - erase_begin(size_type), erase_end(size_type) - */ - void clear() BOOST_NOEXCEPT { - destroy_content(); - m_size = 0; - } - -private: -// Helper methods - - //! Check if the index is valid. - void check_position(size_type index) const { - if (index >= size()) - throw_exception(std::out_of_range("circular_buffer")); - } - - //! Increment the pointer. - template - void increment(Pointer& p) const { - if (++p == m_end) - p = m_buff; - } - - //! Decrement the pointer. - template - void decrement(Pointer& p) const { - if (p == m_buff) - p = m_end; - --p; - } - - //! Add n to the pointer. - template - Pointer add(Pointer p, difference_type n) const { - return p + (n < (m_end - p) ? n : n - capacity()); - } - - //! Subtract n from the pointer. - template - Pointer sub(Pointer p, difference_type n) const { - return p - (n > (p - m_buff) ? n - capacity() : n); - } - - //! Map the null pointer to virtual end of circular buffer. - pointer map_pointer(pointer p) const { return p == 0 ? m_last : p; } - - //! Allocate memory. - pointer allocate(size_type n) { - if (n > max_size()) - throw_exception(std::length_error("circular_buffer")); -#if BOOST_CB_ENABLE_DEBUG - pointer p = (n == 0) ? 0 : m_alloc.allocate(n, 0); - std::memset(p, cb_details::UNINITIALIZED, sizeof(value_type) * n); - return p; -#else - return (n == 0) ? 0 : m_alloc.allocate(n, 0); -#endif - } - - //! Deallocate memory. - void deallocate(pointer p, size_type n) { - if (p != 0) - m_alloc.deallocate(p, n); - } - - //! Does the pointer point to the uninitialized memory? - bool is_uninitialized(const_pointer p) const BOOST_NOEXCEPT { - return p >= m_last && (m_first < m_last || p < m_first); - } - - //! Replace an element. - void replace(pointer pos, param_value_type item) { - *pos = item; -#if BOOST_CB_ENABLE_DEBUG - invalidate_iterators(iterator(this, pos)); -#endif - } - - //! Replace an element. - void replace(pointer pos, rvalue_type item) { - *pos = boost::move(item); -#if BOOST_CB_ENABLE_DEBUG - invalidate_iterators(iterator(this, pos)); -#endif - } - - //! Construct or replace an element. - /*! - construct has to be set to true if and only if - pos points to an uninitialized memory. - */ - void construct_or_replace(bool construct, pointer pos, param_value_type item) { - if (construct) - ::new (pos) value_type(item); - else - replace(pos, item); - } - - //! Construct or replace an element. - /*! - construct has to be set to true if and only if - pos points to an uninitialized memory. - */ - void construct_or_replace(bool construct, pointer pos, rvalue_type item) { - if (construct) - ::new (pos) value_type(boost::move(item)); - else - replace(pos, boost::move(item)); - } - - //! Destroy an item. - void destroy_item(pointer p) { - m_alloc.destroy(p); -#if BOOST_CB_ENABLE_DEBUG - invalidate_iterators(iterator(this, p)); - std::memset(p, cb_details::UNINITIALIZED, sizeof(value_type)); -#endif - } - - //! Destroy an item only if it has been constructed. - void destroy_if_constructed(pointer pos) { - if (is_uninitialized(pos)) - destroy_item(pos); - } - - //! Destroy the whole content of the circular buffer. - void destroy_content() { -#if BOOST_CB_ENABLE_DEBUG - destroy_content(false_type()); -#else - destroy_content(is_scalar()); -#endif - } - - //! Specialized destroy_content method. - void destroy_content(const true_type&) { - m_first = add(m_first, size()); - } - - //! Specialized destroy_content method. - void destroy_content(const false_type&) { - for (size_type ii = 0; ii < size(); ++ii, increment(m_first)) - destroy_item(m_first); - } - - //! Destroy content and free allocated memory. - void destroy() BOOST_NOEXCEPT { - destroy_content(); - deallocate(m_buff, capacity()); -#if BOOST_CB_ENABLE_DEBUG - m_buff = 0; - m_first = 0; - m_last = 0; - m_end = 0; -#endif - } - - //! Initialize the internal buffer. - void initialize_buffer(capacity_type buffer_capacity) { - m_buff = allocate(buffer_capacity); - m_end = m_buff + buffer_capacity; - } - - //! Initialize the internal buffer. - void initialize_buffer(capacity_type buffer_capacity, param_value_type item) { - initialize_buffer(buffer_capacity); - BOOST_TRY { - cb_details::uninitialized_fill_n_with_alloc(m_buff, size(), item, m_alloc); - } BOOST_CATCH(...) { - deallocate(m_buff, size()); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - //! Specialized initialize method. - template - void initialize(IntegralType n, IntegralType item, const true_type&) { - m_size = static_cast(n); - initialize_buffer(size(), item); - m_first = m_last = m_buff; - } - - //! Specialized initialize method. - template - void initialize(Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - initialize(first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - initialize(first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized initialize method. - template - void initialize(InputIterator first, InputIterator last, const std::input_iterator_tag&) { - BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS // check if the STL provides templated iterator constructors - // for containers - std::deque tmp(first, last, m_alloc); - size_type distance = tmp.size(); - initialize(distance, boost::make_move_iterator(tmp.begin()), boost::make_move_iterator(tmp.end()), distance); - } - - //! Specialized initialize method. - template - void initialize(ForwardIterator first, ForwardIterator last, const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - size_type distance = std::distance(first, last); - initialize(distance, first, last, distance); - } - - //! Specialized initialize method. - template - void initialize(capacity_type buffer_capacity, IntegralType n, IntegralType item, const true_type&) { - BOOST_CB_ASSERT(buffer_capacity >= static_cast(n)); // check for capacity lower than n - m_size = static_cast(n); - initialize_buffer(buffer_capacity, item); - m_first = m_buff; - m_last = buffer_capacity == size() ? m_buff : m_buff + size(); - } - - //! Specialized initialize method. - template - void initialize(capacity_type buffer_capacity, Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - initialize(buffer_capacity, first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - initialize(buffer_capacity, first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized initialize method. - template - void initialize(capacity_type buffer_capacity, - InputIterator first, - InputIterator last, - const std::input_iterator_tag&) { - initialize_buffer(buffer_capacity); - m_first = m_last = m_buff; - m_size = 0; - if (buffer_capacity == 0) - return; - while (first != last && !full()) { - ::new (m_last) value_type(*first++); - increment(m_last); - ++m_size; - } - while (first != last) { - replace(m_last, *first++); - increment(m_last); - m_first = m_last; - } - } - - //! Specialized initialize method. - template - void initialize(capacity_type buffer_capacity, - ForwardIterator first, - ForwardIterator last, - const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - initialize(buffer_capacity, first, last, std::distance(first, last)); - } - - //! Initialize the circular buffer. - template - void initialize(capacity_type buffer_capacity, - ForwardIterator first, - ForwardIterator last, - size_type distance) { - initialize_buffer(buffer_capacity); - m_first = m_buff; - if (distance > buffer_capacity) { - std::advance(first, distance - buffer_capacity); - m_size = buffer_capacity; - } else { - m_size = distance; - } - BOOST_TRY { - m_last = cb_details::uninitialized_copy(first, last, m_buff); - } BOOST_CATCH(...) { - deallocate(m_buff, buffer_capacity); - BOOST_RETHROW - } - BOOST_CATCH_END - if (m_last == m_end) - m_last = m_buff; - } - - //! Reset the circular buffer. - void reset(pointer buff, pointer last, capacity_type new_capacity) { - destroy(); - m_size = last - buff; - m_first = m_buff = buff; - m_end = m_buff + new_capacity; - m_last = last == m_end ? m_buff : last; - } - - //! Specialized method for swapping the allocator. - void swap_allocator(circular_buffer&, const true_type&) { - // Swap is not needed because allocators have no state. - } - - //! Specialized method for swapping the allocator. - void swap_allocator(circular_buffer& cb, const false_type&) { - std::swap(m_alloc, cb.m_alloc); - } - - //! Specialized assign method. - template - void assign(IntegralType n, IntegralType item, const true_type&) { - assign(static_cast(n), static_cast(item)); - } - - //! Specialized assign method. - template - void assign(Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - assign(first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - assign(first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized assign method. - template - void assign(InputIterator first, InputIterator last, const std::input_iterator_tag&) { - BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS // check if the STL provides templated iterator constructors - // for containers - std::deque tmp(first, last, m_alloc); - size_type distance = tmp.size(); - assign_n(distance, distance, - cb_details::make_assign_range - (boost::make_move_iterator(tmp.begin()), boost::make_move_iterator(tmp.end()))); - } - - //! Specialized assign method. - template - void assign(ForwardIterator first, ForwardIterator last, const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - size_type distance = std::distance(first, last); - assign_n(distance, distance, cb_details::make_assign_range(first, last)); - } - - //! Specialized assign method. - template - void assign(capacity_type new_capacity, IntegralType n, IntegralType item, const true_type&) { - assign(new_capacity, static_cast(n), static_cast(item)); - } - - //! Specialized assign method. - template - void assign(capacity_type new_capacity, Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - assign(new_capacity, first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - assign(new_capacity, first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized assign method. - template - void assign(capacity_type new_capacity, InputIterator first, InputIterator last, const std::input_iterator_tag&) { - if (new_capacity == capacity()) { - clear(); - insert(begin(), first, last); - } else { -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - circular_buffer tmp(new_capacity, m_alloc); - tmp.insert(begin(), first, last); -#else - circular_buffer tmp(new_capacity, first, last, m_alloc); -#endif - tmp.swap(*this); - } - } - - //! Specialized assign method. - template - void assign(capacity_type new_capacity, ForwardIterator first, ForwardIterator last, - const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - size_type distance = std::distance(first, last); - if (distance > new_capacity) { - std::advance(first, distance - new_capacity); - distance = new_capacity; - } - assign_n(new_capacity, distance, - cb_details::make_assign_range(first, last)); - } - - //! Helper assign method. - template - void assign_n(capacity_type new_capacity, size_type n, const Functor& fnc) { - if (new_capacity == capacity()) { - destroy_content(); - BOOST_TRY { - fnc(m_buff); - } BOOST_CATCH(...) { - m_size = 0; - BOOST_RETHROW - } - BOOST_CATCH_END - } else { - pointer buff = allocate(new_capacity); - BOOST_TRY { - fnc(buff); - } BOOST_CATCH(...) { - deallocate(buff, new_capacity); - BOOST_RETHROW - } - BOOST_CATCH_END - destroy(); - m_buff = buff; - m_end = m_buff + new_capacity; - } - m_size = n; - m_first = m_buff; - m_last = add(m_buff, size()); - } - - //! Helper insert method. - template - iterator insert_item(const iterator& pos, ValT item) { - pointer p = pos.m_it; - if (p == 0) { - construct_or_replace(!full(), m_last, static_cast(item)); - p = m_last; - } else { - pointer src = m_last; - pointer dest = m_last; - bool construct = !full(); - BOOST_TRY { - while (src != p) { - decrement(src); - construct_or_replace(construct, dest, this_type::move_if_noexcept(*src)); - decrement(dest); - construct = false; - } - replace(p, static_cast(item)); - } BOOST_CATCH(...) { - if (!construct && !full()) { - increment(m_last); - ++m_size; - } - BOOST_RETHROW - } - BOOST_CATCH_END - } - increment(m_last); - if (full()) - m_first = m_last; - else - ++m_size; - return iterator(this, p); - } - - //! Specialized insert method. - template - void insert(const iterator& pos, IntegralType n, IntegralType item, const true_type&) { - insert(pos, static_cast(n), static_cast(item)); - } - - //! Specialized insert method. - template - void insert(const iterator& pos, Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - insert(pos, first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - insert(pos, first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized insert method. - template - void insert(iterator pos, InputIterator first, InputIterator last, const std::input_iterator_tag&) { - if (!full() || pos != begin()) { - for (;first != last; ++pos) - pos = insert(pos, *first++); - } - } - - //! Specialized insert method. - template - void insert(const iterator& pos, ForwardIterator first, ForwardIterator last, const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - size_type n = std::distance(first, last); - if (n == 0) - return; - size_type copy = capacity() - (end() - pos); - if (copy == 0) - return; - if (n > copy) { - std::advance(first, n - copy); - n = copy; - } - insert_n(pos, n, cb_details::iterator_wrapper(first)); - } - - //! Helper insert method. - template - void insert_n(const iterator& pos, size_type n, const Wrapper& wrapper) { - size_type construct = reserve(); - if (construct > n) - construct = n; - if (pos.m_it == 0) { - size_type ii = 0; - pointer p = m_last; - BOOST_TRY { - for (; ii < construct; ++ii, increment(p)) - ::new (p) value_type(*wrapper()); - for (;ii < n; ++ii, increment(p)) - replace(p, *wrapper()); - } BOOST_CATCH(...) { - size_type constructed = (std::min)(ii, construct); - m_last = add(m_last, constructed); - m_size += constructed; - BOOST_RETHROW - } - BOOST_CATCH_END - } else { - pointer src = m_last; - pointer dest = add(m_last, n - 1); - pointer p = pos.m_it; - size_type ii = 0; - BOOST_TRY { - while (src != pos.m_it) { - decrement(src); - construct_or_replace(is_uninitialized(dest), dest, *src); - decrement(dest); - } - for (; ii < n; ++ii, increment(p)) - construct_or_replace(is_uninitialized(p), p, *wrapper()); - } BOOST_CATCH(...) { - for (p = add(m_last, n - 1); p != dest; decrement(p)) - destroy_if_constructed(p); - for (n = 0, p = pos.m_it; n < ii; ++n, increment(p)) - destroy_if_constructed(p); - BOOST_RETHROW - } - BOOST_CATCH_END - } - m_last = add(m_last, n); - m_first = add(m_first, n - construct); - m_size += construct; - } - - //! Specialized rinsert method. - template - void rinsert(const iterator& pos, IntegralType n, IntegralType item, const true_type&) { - rinsert(pos, static_cast(n), static_cast(item)); - } - - //! Specialized rinsert method. - template - void rinsert(const iterator& pos, Iterator first, Iterator last, const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - rinsert(pos, first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - rinsert(pos, first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized insert method. - template - void rinsert(iterator pos, InputIterator first, InputIterator last, const std::input_iterator_tag&) { - if (!full() || pos.m_it != 0) { - for (;first != last; ++pos) { - pos = rinsert(pos, *first++); - if (pos.m_it == 0) - break; - } - } - } - - //! Specialized rinsert method. - template - void rinsert(const iterator& pos, ForwardIterator first, ForwardIterator last, const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - rinsert_n(pos, std::distance(first, last), cb_details::iterator_wrapper(first)); - } - - //! Helper rinsert method. - template - void rinsert_n(const iterator& pos, size_type n, const Wrapper& wrapper) { - if (n == 0) - return; - iterator b = begin(); - size_type copy = capacity() - (pos - b); - if (copy == 0) - return; - if (n > copy) - n = copy; - size_type construct = reserve(); - if (construct > n) - construct = n; - if (pos == b) { - pointer p = sub(m_first, n); - size_type ii = n; - BOOST_TRY { - for (;ii > construct; --ii, increment(p)) - replace(p, *wrapper()); - for (; ii > 0; --ii, increment(p)) - ::new (p) value_type(*wrapper()); - } BOOST_CATCH(...) { - size_type constructed = ii < construct ? construct - ii : 0; - m_last = add(m_last, constructed); - m_size += constructed; - BOOST_RETHROW - } - BOOST_CATCH_END - } else { - pointer src = m_first; - pointer dest = sub(m_first, n); - pointer p = map_pointer(pos.m_it); - BOOST_TRY { - while (src != p) { - construct_or_replace(is_uninitialized(dest), dest, *src); - increment(src); - increment(dest); - } - for (size_type ii = 0; ii < n; ++ii, increment(dest)) - construct_or_replace(is_uninitialized(dest), dest, *wrapper()); - } BOOST_CATCH(...) { - for (src = sub(m_first, n); src != dest; increment(src)) - destroy_if_constructed(src); - BOOST_RETHROW - } - BOOST_CATCH_END - } - m_first = sub(m_first, n); - m_last = sub(m_last, n - construct); - m_size += construct; - } - - //! Specialized erase_begin method. - void erase_begin(size_type n, const true_type&) { - m_first = add(m_first, n); - m_size -= n; - } - - //! Specialized erase_begin method. - void erase_begin(size_type n, const false_type&) { - iterator b = begin(); - rerase(b, b + n); - } - - //! Specialized erase_end method. - void erase_end(size_type n, const true_type&) { - m_last = sub(m_last, n); - m_size -= n; - } - - //! Specialized erase_end method. - void erase_end(size_type n, const false_type&) { - iterator e = end(); - erase(e - n, e); - } -}; - -// Non-member functions - -//! Compare two circular_buffers element-by-element to determine if they are equal. -/*! - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return lhs.\link circular_buffer::size() size()\endlink == rhs.\link circular_buffer::size() size()\endlink - && std::equal(lhs.\link circular_buffer::begin() - begin()\endlink, lhs.\link circular_buffer::end() end()\endlink, - rhs.\link circular_buffer::begin() begin()\endlink) - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. -*/ -template -inline bool operator == (const circular_buffer& lhs, const circular_buffer& rhs) { - return lhs.size() == rhs.size() && std::equal(lhs.begin(), lhs.end(), rhs.begin()); -} - -/*! - \brief Compare two circular_buffers element-by-element to determine if the left one is lesser than the - right one. - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return - std::lexicographical_compare(lhs.\link circular_buffer::begin() begin()\endlink, - lhs.\link circular_buffer::end() end()\endlink, rhs.\link circular_buffer::begin() begin()\endlink, - rhs.\link circular_buffer::end() end()\endlink) - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. -*/ -template -inline bool operator < (const circular_buffer& lhs, const circular_buffer& rhs) { - return std::lexicographical_compare(lhs.begin(), lhs.end(), rhs.begin(), rhs.end()); -} - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) || defined(BOOST_MSVC) - -//! Compare two circular_buffers element-by-element to determine if they are non-equal. -/*! - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return !(lhs == rhs) - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. - \sa operator==(const circular_buffer&, const circular_buffer&) -*/ -template -inline bool operator != (const circular_buffer& lhs, const circular_buffer& rhs) { - return !(lhs == rhs); -} - -/*! - \brief Compare two circular_buffers element-by-element to determine if the left one is greater than - the right one. - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return rhs \< lhs - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. - \sa operator<(const circular_buffer&, const circular_buffer&) -*/ -template -inline bool operator > (const circular_buffer& lhs, const circular_buffer& rhs) { - return rhs < lhs; -} - -/*! - \brief Compare two circular_buffers element-by-element to determine if the left one is lesser or equal - to the right one. - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return !(rhs \< lhs) - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. - \sa operator<(const circular_buffer&, const circular_buffer&) -*/ -template -inline bool operator <= (const circular_buffer& lhs, const circular_buffer& rhs) { - return !(rhs < lhs); -} - -/*! - \brief Compare two circular_buffers element-by-element to determine if the left one is greater or - equal to the right one. - \param lhs The circular_buffer to compare. - \param rhs The circular_buffer to compare. - \return !(lhs < rhs) - \throws Nothing. - \par Complexity - Linear (in the size of the circular_buffers). - \par Iterator Invalidation - Does not invalidate any iterators. - \sa operator<(const circular_buffer&, const circular_buffer&) -*/ -template -inline bool operator >= (const circular_buffer& lhs, const circular_buffer& rhs) { - return !(lhs < rhs); -} - -//! Swap the contents of two circular_buffers. -/*! - \post lhs contains elements of rhs and vice versa. - \param lhs The circular_buffer whose content will be swapped with rhs. - \param rhs The circular_buffer whose content will be swapped with lhs. - \throws Nothing. - \par Complexity - Constant (in the size of the circular_buffers). - \par Iterator Invalidation - Invalidates all iterators of both circular_buffers. (On the other hand the iterators still - point to the same elements but within another container. If you want to rely on this feature you have to - turn the Debug Support off otherwise an assertion will report an error if such - invalidated iterator is used.) - \sa \link circular_buffer::swap(circular_buffer&) swap(circular_buffer&)\endlink -*/ -template -inline void swap(circular_buffer& lhs, circular_buffer& rhs) BOOST_NOEXCEPT { - lhs.swap(rhs); -} - -#endif // #if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) || defined(BOOST_MSVC) - -} // namespace boost - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_BASE_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/debug.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/debug.hpp deleted file mode 100644 index 6eb45158..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/debug.hpp +++ /dev/null @@ -1,227 +0,0 @@ -// Debug support for the circular buffer library. - -// Copyright (c) 2003-2008 Jan Gaspar - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_CIRCULAR_BUFFER_DEBUG_HPP) -#define BOOST_CIRCULAR_BUFFER_DEBUG_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -namespace boost { - -namespace cb_details { - -#if BOOST_CB_ENABLE_DEBUG - -// The value the uninitialized memory is filled with. -const int UNINITIALIZED = 0xcc; - -class debug_iterator_registry; - -/*! - \class debug_iterator_base - \brief Registers/unregisters iterators into the registry of valid iterators. - - This class is intended to be a base class of an iterator. -*/ -class debug_iterator_base { - -private: -// Members - - //! Iterator registry. - mutable const debug_iterator_registry* m_registry; - - //! Next iterator in the iterator chain. - mutable const debug_iterator_base* m_next; - -public: -// Construction/destruction - - //! Default constructor. - debug_iterator_base(); - - //! Constructor taking the iterator registry as a parameter. - debug_iterator_base(const debug_iterator_registry* registry); - - //! Copy constructor. - debug_iterator_base(const debug_iterator_base& rhs); - - //! Destructor. - ~debug_iterator_base(); - -// Methods - - //! Assign operator. - debug_iterator_base& operator = (const debug_iterator_base& rhs); - - //! Is the iterator valid? - bool is_valid(const debug_iterator_registry* registry) const; - - //! Invalidate the iterator. - /*! - \note The method is const in order to invalidate const iterators, too. - */ - void invalidate() const; - - //! Return the next iterator in the iterator chain. - const debug_iterator_base* next() const; - - //! Set the next iterator in the iterator chain. - /*! - \note The method is const in order to set a next iterator to a const iterator, too. - */ - void set_next(const debug_iterator_base* it) const; - -private: -// Helpers - - //! Register self as a valid iterator. - void register_self(); - - //! Unregister self from valid iterators. - void unregister_self(); -}; - -/*! - \class debug_iterator_registry - \brief Registry of valid iterators. - - This class is intended to be a base class of a container. -*/ -class debug_iterator_registry { - - //! Pointer to the chain of valid iterators. - mutable const debug_iterator_base* m_iterators; - -public: -// Methods - - //! Default constructor. - debug_iterator_registry() : m_iterators(0) {} - - //! Register an iterator into the list of valid iterators. - /*! - \note The method is const in order to register iterators into const containers, too. - */ - void register_iterator(const debug_iterator_base* it) const { - it->set_next(m_iterators); - m_iterators = it; - } - - //! Unregister an iterator from the list of valid iterators. - /*! - \note The method is const in order to unregister iterators from const containers, too. - */ - void unregister_iterator(const debug_iterator_base* it) const { - const debug_iterator_base* previous = 0; - for (const debug_iterator_base* p = m_iterators; p != it; previous = p, p = p->next()) {} - remove(it, previous); - } - - //! Invalidate every iterator pointing to the same element as the iterator passed as a parameter. - template - void invalidate_iterators(const Iterator& it) { - const debug_iterator_base* previous = 0; - for (const debug_iterator_base* p = m_iterators; p != 0; p = p->next()) { - if (((Iterator*)p)->m_it == it.m_it) { - p->invalidate(); - remove(p, previous); - continue; - } - previous = p; - } - } - - //! Invalidate all iterators except an iterator poining to the same element as the iterator passed as a parameter. - template - void invalidate_iterators_except(const Iterator& it) { - const debug_iterator_base* previous = 0; - for (const debug_iterator_base* p = m_iterators; p != 0; p = p->next()) { - if (((Iterator*)p)->m_it != it.m_it) { - p->invalidate(); - remove(p, previous); - continue; - } - previous = p; - } - } - - //! Invalidate all iterators. - void invalidate_all_iterators() { - for (const debug_iterator_base* p = m_iterators; p != 0; p = p->next()) - p->invalidate(); - m_iterators = 0; - } - -private: -// Helpers - - //! Remove the current iterator from the iterator chain. - void remove(const debug_iterator_base* current, - const debug_iterator_base* previous) const { - if (previous == 0) - m_iterators = m_iterators->next(); - else - previous->set_next(current->next()); - } -}; - -// Implementation of the debug_iterator_base methods. - -inline debug_iterator_base::debug_iterator_base() : m_registry(0), m_next(0) {} - -inline debug_iterator_base::debug_iterator_base(const debug_iterator_registry* registry) -: m_registry(registry), m_next(0) { - register_self(); -} - -inline debug_iterator_base::debug_iterator_base(const debug_iterator_base& rhs) -: m_registry(rhs.m_registry), m_next(0) { - register_self(); -} - -inline debug_iterator_base::~debug_iterator_base() { unregister_self(); } - -inline debug_iterator_base& debug_iterator_base::operator = (const debug_iterator_base& rhs) { - if (m_registry == rhs.m_registry) - return *this; - unregister_self(); - m_registry = rhs.m_registry; - register_self(); - return *this; -} - -inline bool debug_iterator_base::is_valid(const debug_iterator_registry* registry) const { - return m_registry == registry; -} - -inline void debug_iterator_base::invalidate() const { m_registry = 0; } - -inline const debug_iterator_base* debug_iterator_base::next() const { return m_next; } - -inline void debug_iterator_base::set_next(const debug_iterator_base* it) const { m_next = it; } - -inline void debug_iterator_base::register_self() { - if (m_registry != 0) - m_registry->register_iterator(this); -} - -inline void debug_iterator_base::unregister_self() { - if (m_registry != 0) - m_registry->unregister_iterator(this); -} - -#endif // #if BOOST_CB_ENABLE_DEBUG - -} // namespace cb_details - -} // namespace boost - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_DEBUG_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/details.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/details.hpp deleted file mode 100644 index 9fdb2c78..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/details.hpp +++ /dev/null @@ -1,518 +0,0 @@ -// Helper classes and functions for the circular buffer. - -// Copyright (c) 2003-2008 Jan Gaspar - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_CIRCULAR_BUFFER_DETAILS_HPP) -#define BOOST_CIRCULAR_BUFFER_DETAILS_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -#include -#include -#include -#include -#include -#include - -// Silence MS /W4 warnings like C4913: -// "user defined binary operator ',' exists but no overload could convert all operands, default built-in binary operator ',' used" -// This might happen when previously including some boost headers that overload the coma operator. -#if defined(_MSC_VER) -# pragma warning(push) -# pragma warning(disable:4913) -#endif - -namespace boost { - -namespace cb_details { - -template struct nonconst_traits; - -template -void uninitialized_fill_n_with_alloc( - ForwardIterator first, Diff n, const T& item, Alloc& alloc); - -template -ForwardIterator uninitialized_copy(InputIterator first, InputIterator last, ForwardIterator dest); - -template -ForwardIterator uninitialized_move_if_noexcept(InputIterator first, InputIterator last, ForwardIterator dest); - -/*! - \struct const_traits - \brief Defines the data types for a const iterator. -*/ -template -struct const_traits { - // Basic types - typedef typename Traits::value_type value_type; - typedef typename Traits::const_pointer pointer; - typedef typename Traits::const_reference reference; - typedef typename Traits::size_type size_type; - typedef typename Traits::difference_type difference_type; - - // Non-const traits - typedef nonconst_traits nonconst_self; -}; - -/*! - \struct nonconst_traits - \brief Defines the data types for a non-const iterator. -*/ -template -struct nonconst_traits { - // Basic types - typedef typename Traits::value_type value_type; - typedef typename Traits::pointer pointer; - typedef typename Traits::reference reference; - typedef typename Traits::size_type size_type; - typedef typename Traits::difference_type difference_type; - - // Non-const traits - typedef nonconst_traits nonconst_self; -}; - -/*! - \struct iterator_wrapper - \brief Helper iterator dereference wrapper. -*/ -template -struct iterator_wrapper { - mutable Iterator m_it; - explicit iterator_wrapper(Iterator it) : m_it(it) {} - Iterator operator () () const { return m_it++; } -private: - iterator_wrapper& operator = (const iterator_wrapper&); // do not generate -}; - -/*! - \struct item_wrapper - \brief Helper item dereference wrapper. -*/ -template -struct item_wrapper { - Value m_item; - explicit item_wrapper(Value item) : m_item(item) {} - Pointer operator () () const { return &m_item; } -private: - item_wrapper& operator = (const item_wrapper&); // do not generate -}; - -/*! - \struct assign_n - \brief Helper functor for assigning n items. -*/ -template -struct assign_n { - typedef typename Alloc::size_type size_type; - size_type m_n; - Value m_item; - Alloc& m_alloc; - assign_n(size_type n, Value item, Alloc& alloc) : m_n(n), m_item(item), m_alloc(alloc) {} - template - void operator () (Pointer p) const { - uninitialized_fill_n_with_alloc(p, m_n, m_item, m_alloc); - } -private: - assign_n& operator = (const assign_n&); // do not generate -}; - -/*! - \struct assign_range - \brief Helper functor for assigning range of items. -*/ -template -struct assign_range { - Iterator m_first; - Iterator m_last; - - assign_range(const Iterator& first, const Iterator& last) BOOST_NOEXCEPT - : m_first(first), m_last(last) {} - - template - void operator () (Pointer p) const { - boost::cb_details::uninitialized_copy(m_first, m_last, p); - } -}; - -template -inline assign_range make_assign_range(const Iterator& first, const Iterator& last) { - return assign_range(first, last); -} - -/*! - \class capacity_control - \brief Capacity controller of the space optimized circular buffer. -*/ -template -class capacity_control { - - //! The capacity of the space-optimized circular buffer. - Size m_capacity; - - //! The lowest guaranteed or minimum capacity of the adapted space-optimized circular buffer. - Size m_min_capacity; - -public: - - //! Constructor. - capacity_control(Size buffer_capacity, Size min_buffer_capacity = 0) - : m_capacity(buffer_capacity), m_min_capacity(min_buffer_capacity) - { // Check for capacity lower than min_capacity. - BOOST_CB_ASSERT(buffer_capacity >= min_buffer_capacity); - } - - // Default copy constructor. - - // Default assign operator. - - //! Get the capacity of the space optimized circular buffer. - Size capacity() const { return m_capacity; } - - //! Get the minimal capacity of the space optimized circular buffer. - Size min_capacity() const { return m_min_capacity; } - - //! Size operator - returns the capacity of the space optimized circular buffer. - operator Size() const { return m_capacity; } -}; - -/*! - \struct iterator - \brief Random access iterator for the circular buffer. - \param Buff The type of the underlying circular buffer. - \param Traits Basic iterator types. - \note This iterator is not circular. It was designed - for iterating from begin() to end() of the circular buffer. -*/ -template -struct iterator : - public boost::iterator< - std::random_access_iterator_tag, - typename Traits::value_type, - typename Traits::difference_type, - typename Traits::pointer, - typename Traits::reference> -#if BOOST_CB_ENABLE_DEBUG - , public debug_iterator_base -#endif // #if BOOST_CB_ENABLE_DEBUG -{ -// Helper types - - //! Base iterator. - typedef boost::iterator< - std::random_access_iterator_tag, - typename Traits::value_type, - typename Traits::difference_type, - typename Traits::pointer, - typename Traits::reference> base_iterator; - - //! Non-const iterator. - typedef iterator nonconst_self; - -// Basic types - - //! The type of the elements stored in the circular buffer. - typedef typename base_iterator::value_type value_type; - - //! Pointer to the element. - typedef typename base_iterator::pointer pointer; - - //! Reference to the element. - typedef typename base_iterator::reference reference; - - //! Size type. - typedef typename Traits::size_type size_type; - - //! Difference type. - typedef typename base_iterator::difference_type difference_type; - -// Member variables - - //! The circular buffer where the iterator points to. - const Buff* m_buff; - - //! An internal iterator. - pointer m_it; - -// Construction & assignment - - // Default copy constructor. - - //! Default constructor. - iterator() : m_buff(0), m_it(0) {} - -#if BOOST_CB_ENABLE_DEBUG - - //! Copy constructor (used for converting from a non-const to a const iterator). - iterator(const nonconst_self& it) : debug_iterator_base(it), m_buff(it.m_buff), m_it(it.m_it) {} - - //! Internal constructor. - /*! - \note This constructor is not intended to be used directly by the user. - */ - iterator(const Buff* cb, const pointer p) : debug_iterator_base(cb), m_buff(cb), m_it(p) {} - -#else - - iterator(const nonconst_self& it) : m_buff(it.m_buff), m_it(it.m_it) {} - - iterator(const Buff* cb, const pointer p) : m_buff(cb), m_it(p) {} - -#endif // #if BOOST_CB_ENABLE_DEBUG - - //! Assign operator. - iterator& operator = (const iterator& it) { - if (this == &it) - return *this; -#if BOOST_CB_ENABLE_DEBUG - debug_iterator_base::operator =(it); -#endif // #if BOOST_CB_ENABLE_DEBUG - m_buff = it.m_buff; - m_it = it.m_it; - return *this; - } - -// Random access iterator methods - - //! Dereferencing operator. - reference operator * () const { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(m_it != 0); // check for iterator pointing to end() - return *m_it; - } - - //! Dereferencing operator. - pointer operator -> () const { return &(operator*()); } - - //! Difference operator. - template - difference_type operator - (const iterator& it) const { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(it.is_valid(m_buff)); // check for uninitialized or invalidated iterator - return linearize_pointer(*this) - linearize_pointer(it); - } - - //! Increment operator (prefix). - iterator& operator ++ () { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(m_it != 0); // check for iterator pointing to end() - m_buff->increment(m_it); - if (m_it == m_buff->m_last) - m_it = 0; - return *this; - } - - //! Increment operator (postfix). - iterator operator ++ (int) { - iterator tmp = *this; - ++*this; - return tmp; - } - - //! Decrement operator (prefix). - iterator& operator -- () { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(m_it != m_buff->m_first); // check for iterator pointing to begin() - if (m_it == 0) - m_it = m_buff->m_last; - m_buff->decrement(m_it); - return *this; - } - - //! Decrement operator (postfix). - iterator operator -- (int) { - iterator tmp = *this; - --*this; - return tmp; - } - - //! Iterator addition. - iterator& operator += (difference_type n) { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - if (n > 0) { - BOOST_CB_ASSERT(m_buff->end() - *this >= n); // check for too large n - m_it = m_buff->add(m_it, n); - if (m_it == m_buff->m_last) - m_it = 0; - } else if (n < 0) { - *this -= -n; - } - return *this; - } - - //! Iterator addition. - iterator operator + (difference_type n) const { return iterator(*this) += n; } - - //! Iterator subtraction. - iterator& operator -= (difference_type n) { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - if (n > 0) { - BOOST_CB_ASSERT(*this - m_buff->begin() >= n); // check for too large n - m_it = m_buff->sub(m_it == 0 ? m_buff->m_last : m_it, n); - } else if (n < 0) { - *this += -n; - } - return *this; - } - - //! Iterator subtraction. - iterator operator - (difference_type n) const { return iterator(*this) -= n; } - - //! Element access operator. - reference operator [] (difference_type n) const { return *(*this + n); } - -// Equality & comparison - - //! Equality. - template - bool operator == (const iterator& it) const { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(it.is_valid(m_buff)); // check for uninitialized or invalidated iterator - return m_it == it.m_it; - } - - //! Inequality. - template - bool operator != (const iterator& it) const { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(it.is_valid(m_buff)); // check for uninitialized or invalidated iterator - return m_it != it.m_it; - } - - //! Less. - template - bool operator < (const iterator& it) const { - BOOST_CB_ASSERT(is_valid(m_buff)); // check for uninitialized or invalidated iterator - BOOST_CB_ASSERT(it.is_valid(m_buff)); // check for uninitialized or invalidated iterator - return linearize_pointer(*this) < linearize_pointer(it); - } - - //! Greater. - template - bool operator > (const iterator& it) const { return it < *this; } - - //! Less or equal. - template - bool operator <= (const iterator& it) const { return !(it < *this); } - - //! Greater or equal. - template - bool operator >= (const iterator& it) const { return !(*this < it); } - -// Helpers - - //! Get a pointer which would point to the same element as the iterator in case the circular buffer is linearized. - template - typename Traits0::pointer linearize_pointer(const iterator& it) const { - return it.m_it == 0 ? m_buff->m_buff + m_buff->size() : - (it.m_it < m_buff->m_first ? it.m_it + (m_buff->m_end - m_buff->m_first) - : m_buff->m_buff + (it.m_it - m_buff->m_first)); - } -}; - -//! Iterator addition. -template -inline iterator -operator + (typename Traits::difference_type n, const iterator& it) { - return it + n; -} - -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_MSVC_STD_ITERATOR) - -//! Iterator category. -template -inline std::random_access_iterator_tag iterator_category(const iterator&) { - return std::random_access_iterator_tag(); -} - -//! The type of the elements stored in the circular buffer. -template -inline typename Traits::value_type* value_type(const iterator&) { return 0; } - -//! Distance type. -template -inline typename Traits::difference_type* distance_type(const iterator&) { return 0; } - -#endif // #if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_MSVC_STD_ITERATOR) - -/*! - \fn ForwardIterator uninitialized_copy(InputIterator first, InputIterator last, ForwardIterator dest) - \brief Equivalent of std::uninitialized_copy but with explicit specification of value type. -*/ -template -inline ForwardIterator uninitialized_copy(InputIterator first, InputIterator last, ForwardIterator dest) { - typedef ValueType value_type; - - // We do not use allocator.construct and allocator.destroy - // because C++03 requires to take parameter by const reference but - // Boost.move requires nonconst reference - ForwardIterator next = dest; - BOOST_TRY { - for (; first != last; ++first, ++dest) - ::new (dest) value_type(*first); - } BOOST_CATCH(...) { - for (; next != dest; ++next) - next->~value_type(); - BOOST_RETHROW - } - BOOST_CATCH_END - return dest; -} - -template -ForwardIterator uninitialized_move_if_noexcept_impl(InputIterator first, InputIterator last, ForwardIterator dest, - true_type) { - for (; first != last; ++first, ++dest) - ::new (dest) ValueType(boost::move(*first)); - return dest; -} - -template -ForwardIterator uninitialized_move_if_noexcept_impl(InputIterator first, InputIterator last, ForwardIterator dest, - false_type) { - return uninitialized_copy(first, last, dest); -} - -/*! - \fn ForwardIterator uninitialized_move_if_noexcept(InputIterator first, InputIterator last, ForwardIterator dest) - \brief Equivalent of std::uninitialized_copy but with explicit specification of value type and moves elements if they have noexcept move constructors. -*/ -template -ForwardIterator uninitialized_move_if_noexcept(InputIterator first, InputIterator last, ForwardIterator dest) { - typedef typename boost::is_nothrow_move_constructible::type tag_t; - return uninitialized_move_if_noexcept_impl(first, last, dest, tag_t()); -} - -/*! - \fn void uninitialized_fill_n_with_alloc(ForwardIterator first, Diff n, const T& item, Alloc& alloc) - \brief Equivalent of std::uninitialized_fill_n with allocator. -*/ -template -inline void uninitialized_fill_n_with_alloc(ForwardIterator first, Diff n, const T& item, Alloc& alloc) { - ForwardIterator next = first; - BOOST_TRY { - for (; n > 0; ++first, --n) - alloc.construct(first, item); - } BOOST_CATCH(...) { - for (; next != first; ++next) - alloc.destroy(next); - BOOST_RETHROW - } - BOOST_CATCH_END -} - -} // namespace cb_details - -} // namespace boost - -#if defined(_MSC_VER) -# pragma warning(pop) -#endif - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_DETAILS_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/space_optimized.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/space_optimized.hpp deleted file mode 100644 index 4518c99f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer/space_optimized.hpp +++ /dev/null @@ -1,1746 +0,0 @@ -// Implementation of the circular buffer adaptor. - -// Copyright (c) 2003-2008 Jan Gaspar -// Copyright (c) 2013 Paul A. Bristow // Doxygen comments changed for new version of documentation. -// Copyright (c) 2013 Antony Polukhin // Move semantics implementation. - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_CIRCULAR_BUFFER_SPACE_OPTIMIZED_HPP) -#define BOOST_CIRCULAR_BUFFER_SPACE_OPTIMIZED_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -#include -#include - -namespace boost { - -/*! - \class circular_buffer_space_optimized - \brief Space optimized circular buffer container adaptor. - T must be a copyable class or must have an noexcept move constructor - and move assignment operator. -*/ -template -class circular_buffer_space_optimized : -/*! \cond */ -#if BOOST_CB_ENABLE_DEBUG -public -#endif -/*! \endcond */ -circular_buffer { -public: -// Typedefs - - typedef typename circular_buffer::value_type value_type; - typedef typename circular_buffer::pointer pointer; - typedef typename circular_buffer::const_pointer const_pointer; - typedef typename circular_buffer::reference reference; - typedef typename circular_buffer::const_reference const_reference; - typedef typename circular_buffer::size_type size_type; - typedef typename circular_buffer::difference_type difference_type; - typedef typename circular_buffer::allocator_type allocator_type; - typedef typename circular_buffer::const_iterator const_iterator; - typedef typename circular_buffer::iterator iterator; - typedef typename circular_buffer::const_reverse_iterator const_reverse_iterator; - typedef typename circular_buffer::reverse_iterator reverse_iterator; - typedef typename circular_buffer::array_range array_range; - typedef typename circular_buffer::const_array_range const_array_range; - typedef typename circular_buffer::param_value_type param_value_type; - typedef typename circular_buffer::rvalue_type rvalue_type; - //typedef typename circular_buffer::return_value_type return_value_type; - -/*
 is not passed through to html or pdf. So 
is used in code section below. Ugly :-( -Ideally want a link to capacity_control, but this would require include details -and this would expose all the functions in details. -There must be a better way of doing this. -*/ - - /*! Capacity controller of the space optimized circular buffer. - - \see capacity_control in details.hpp. -

- -class capacity_control
-{
- size_type m_capacity; // Available capacity.
- size_type m_min_capacity; // Minimum capacity.
-public:
- capacity_control(size_type capacity, size_type min_capacity = 0)
- : m_capacity(capacity), m_min_capacity(min_capacity)
- {};
- size_type %capacity() const { return m_capacity; }
- size_type min_capacity() const { return m_min_capacity; }
- operator size_type() const { return m_capacity; }
-};
-
-

- - -

Always - capacity >= min_capacity. -

-

- The capacity() represents the capacity - of the circular_buffer_space_optimized and - the min_capacity() determines the minimal allocated size of its internal buffer. -

-

The converting constructor of the capacity_control allows implicit conversion from - size_type-like types which ensures compatibility of creating an instance of the - circular_buffer_space_optimized with other STL containers. - - On the other hand the operator %size_type() - provides implicit conversion to the size_type which allows to treat the - capacity of the circular_buffer_space_optimized the same way as in the - circular_buffer. -

- */ - typedef cb_details::capacity_control capacity_type; - -// Inherited - - using circular_buffer::get_allocator; - using circular_buffer::begin; - using circular_buffer::end; - using circular_buffer::rbegin; - using circular_buffer::rend; - using circular_buffer::at; - using circular_buffer::front; - using circular_buffer::back; - using circular_buffer::array_one; - using circular_buffer::array_two; - using circular_buffer::linearize; - using circular_buffer::is_linearized; - using circular_buffer::rotate; - using circular_buffer::size; - using circular_buffer::max_size; - using circular_buffer::empty; - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - reference operator [] (size_type n) { return circular_buffer::operator[](n); } - const_reference operator [] (size_type n) const { return circular_buffer::operator[](n); } -#else - using circular_buffer::operator[]; -#endif - -private: -// Member variables - - //! The capacity controller of the space optimized circular buffer. - capacity_type m_capacity_ctrl; - -public: -// Overridden - - //! Is the circular_buffer_space_optimized full? - /*! - \return true if the number of elements stored in the circular_buffer_space_optimized - equals the capacity of the circular_buffer_space_optimized; false otherwise. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer_space_optimized). - \sa empty() - */ - bool full() const BOOST_NOEXCEPT { return m_capacity_ctrl == size(); } - - /*! \brief Get the maximum number of elements which can be inserted into the - circular_buffer_space_optimized without overwriting any of already stored elements. - \return capacity().%capacity() - size() - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer_space_optimized). - \sa capacity(), size(), max_size() - */ - size_type reserve() const BOOST_NOEXCEPT { return m_capacity_ctrl - size(); } - - //! Get the capacity of the circular_buffer_space_optimized. - /*! - \return The capacity controller representing the maximum number of elements which can be stored in the - circular_buffer_space_optimized and the minimal allocated size of the internal buffer. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Does not invalidate any iterators. - \par Complexity - Constant (in the size of the circular_buffer_space_optimized). - \sa reserve(), size(), max_size(), - set_capacity(const capacity_type&) - */ - const capacity_type& capacity() const BOOST_NOEXCEPT { return m_capacity_ctrl; } - -#if defined(BOOST_CB_TEST) - - // Return the current capacity of the adapted circular buffer. - /* - \note This method is not intended to be used directly by the user. - It is defined only for testing purposes. - */ - size_type internal_capacity() const BOOST_NOEXCEPT { return circular_buffer::capacity(); } - -#endif // #if defined(BOOST_CB_TEST) - - /*! \brief Change the capacity (and the minimal guaranteed amount of allocated memory) of the - circular_buffer_space_optimized. - \post capacity() == capacity_ctrl \&\& size() \<= capacity_ctrl.capacity()

- If the current number of elements stored in the circular_buffer_space_optimized is greater - than the desired new capacity then number of [size() - capacity_ctrl.capacity()] last - elements will be removed and the new size will be equal to capacity_ctrl.capacity().

- If the current number of elements stored in the circular_buffer_space_optimized is lower - than the new capacity then the amount of allocated memory in the internal buffer may be accommodated as - necessary but it will never drop below capacity_ctrl.min_capacity(). - \param capacity_ctrl The new capacity controller. - \throws "An allocation error" if memory is exhausted, (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in min[size(), capacity_ctrl.%capacity()]). - \note To explicitly clear the extra allocated memory use the shrink-to-fit technique:

- %boost::%circular_buffer_space_optimized\ cb(1000);
- ...
- %boost::%circular_buffer_space_optimized\(cb).swap(cb);


- For more information about the shrink-to-fit technique in STL see - http://www.gotw.ca/gotw/054.htm. - \sa rset_capacity(const capacity_type&), - \link resize() resize(size_type, const_reference)\endlink - */ - void set_capacity(const capacity_type& capacity_ctrl) { - m_capacity_ctrl = capacity_ctrl; - if (capacity_ctrl < size()) { - iterator e = end(); - circular_buffer::erase(e - (size() - capacity_ctrl), e); - } - adjust_min_capacity(); - } - - //! Change the size of the circular_buffer_space_optimized. - /*! - \post size() == new_size \&\& capacity().%capacity() >= new_size

- If the new size is greater than the current size, copies of item will be inserted at the - back of the of the circular_buffer_space_optimized in order to achieve the desired - size. In the case the resulting size exceeds the current capacity the capacity will be set to - new_size.

- If the current number of elements stored in the circular_buffer_space_optimized is greater - than the desired new size then number of [size() - new_size] last elements will be - removed. (The capacity will remain unchanged.)

- The amount of allocated memory in the internal buffer may be accommodated as necessary. - \param new_size The new size. - \param item The element the circular_buffer_space_optimized will be filled with in order to gain - the requested size. (See the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the new size of the circular_buffer_space_optimized). - \sa \link rresize() rresize(size_type, const_reference)\endlink, - set_capacity(const capacity_type&) - */ - void resize(size_type new_size, param_value_type item = value_type()) { - if (new_size > size()) { - if (new_size > m_capacity_ctrl) - m_capacity_ctrl = capacity_type(new_size, m_capacity_ctrl.min_capacity()); - insert(end(), new_size - size(), item); - } else { - iterator e = end(); - erase(e - (size() - new_size), e); - } - } - - /*! \brief Change the capacity (and the minimal guaranteed amount of allocated memory) of the - circular_buffer_space_optimized. - \post capacity() == capacity_ctrl \&\& size() \<= capacity_ctrl

- If the current number of elements stored in the circular_buffer_space_optimized is greater - than the desired new capacity then number of [size() - capacity_ctrl.capacity()] - first elements will be removed and the new size will be equal to - capacity_ctrl.capacity().

- If the current number of elements stored in the circular_buffer_space_optimized is lower - than the new capacity then the amount of allocated memory in the internal buffer may be accommodated as - necessary but it will never drop below capacity_ctrl.min_capacity(). - \param capacity_ctrl The new capacity controller. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in min[size(), capacity_ctrl.%capacity()]). - \sa set_capacity(const capacity_type&), - \link rresize() rresize(size_type, const_reference)\endlink - */ - void rset_capacity(const capacity_type& capacity_ctrl) { - m_capacity_ctrl = capacity_ctrl; - if (capacity_ctrl < size()) { - iterator b = begin(); - circular_buffer::rerase(b, b + (size() - capacity_ctrl)); - } - adjust_min_capacity(); - } - - //! Change the size of the circular_buffer_space_optimized. - /*! - \post size() == new_size \&\& capacity().%capacity() >= new_size

- If the new size is greater than the current size, copies of item will be inserted at the - front of the of the circular_buffer_space_optimized in order to achieve the desired - size. In the case the resulting size exceeds the current capacity the capacity will be set to - new_size.

- If the current number of elements stored in the circular_buffer_space_optimized is greater - than the desired new size then number of [size() - new_size] first elements will be - removed. (The capacity will remain unchanged.)

- The amount of allocated memory in the internal buffer may be accommodated as necessary. - \param new_size The new size. - \param item The element the circular_buffer_space_optimized will be filled with in order to gain - the requested size. (See the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the new size of the circular_buffer_space_optimized). - \sa \link resize() resize(size_type, const_reference)\endlink, - rset_capacity(const capacity_type&) - */ - void rresize(size_type new_size, param_value_type item = value_type()) { - if (new_size > size()) { - if (new_size > m_capacity_ctrl) - m_capacity_ctrl = capacity_type(new_size, m_capacity_ctrl.min_capacity()); - rinsert(begin(), new_size - size(), item); - } else { - rerase(begin(), end() - new_size); - } - } - - //! Create an empty space optimized circular buffer with zero capacity. - /*! - \post capacity().%capacity() == 0 \&\& capacity().min_capacity() == 0 \&\& size() == 0 - \param alloc The allocator. - \throws Nothing. - \par Complexity - Constant. - \warning Since Boost version 1.36 the behaviour of this constructor has changed. Now it creates a space - optimized circular buffer with zero capacity. - */ - explicit circular_buffer_space_optimized(const allocator_type& alloc = allocator_type()) BOOST_NOEXCEPT - : circular_buffer(0, alloc) - , m_capacity_ctrl(0) {} - - //! Create an empty space optimized circular buffer with the specified capacity. - /*! - \post capacity() == capacity_ctrl \&\& size() == 0

- The amount of allocated memory in the internal buffer is capacity_ctrl.min_capacity(). - \param capacity_ctrl The capacity controller representing the maximum number of elements which can be stored in - the circular_buffer_space_optimized and the minimal allocated size of the - internal buffer. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Complexity - Constant. - */ - explicit circular_buffer_space_optimized(capacity_type capacity_ctrl, - const allocator_type& alloc = allocator_type()) - : circular_buffer(capacity_ctrl.min_capacity(), alloc) - , m_capacity_ctrl(capacity_ctrl) {} - - /*! \brief Create a full space optimized circular buffer with the specified capacity filled with - capacity_ctrl.%capacity() copies of item. - \post capacity() == capacity_ctrl \&\& full() \&\& (*this)[0] == item \&\& (*this)[1] == item \&\& ... - \&\& (*this) [capacity_ctrl.%capacity() - 1] == item

- The amount of allocated memory in the internal buffer is capacity_ctrl.capacity(). - \param capacity_ctrl The capacity controller representing the maximum number of elements which can be stored in - the circular_buffer_space_optimized and the minimal allocated size of the - internal buffer. - \param item The element the created circular_buffer_space_optimized will be filled with. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \throws Whatever T::T(const T&) throws. - \par Complexity - Linear (in the capacity_ctrl.%capacity()). - */ - circular_buffer_space_optimized(capacity_type capacity_ctrl, param_value_type item, - const allocator_type& alloc = allocator_type()) - : circular_buffer(capacity_ctrl.capacity(), item, alloc) - , m_capacity_ctrl(capacity_ctrl) {} - - /*! \brief Create a space optimized circular buffer with the specified capacity filled with n copies - of item. - \pre capacity_ctrl.%capacity() >= n - \post capacity() == capacity_ctrl \&\& size() == n \&\& (*this)[0] == item \&\& (*this)[1] == item - \&\& ... \&\& (*this)[n - 1] == item

- The amount of allocated memory in the internal buffer is - max[n, capacity_ctrl.min_capacity()]. - \param capacity_ctrl The capacity controller representing the maximum number of elements which can be stored in - the circular_buffer_space_optimized and the minimal allocated size of the - internal buffer. - \param n The number of elements the created circular_buffer_space_optimized will be filled with. - \param item The element the created circular_buffer_space_optimized will be filled with. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the n). - */ - circular_buffer_space_optimized(capacity_type capacity_ctrl, size_type n, param_value_type item, - const allocator_type& alloc = allocator_type()) - : circular_buffer(init_capacity(capacity_ctrl, n), n, item, alloc) - , m_capacity_ctrl(capacity_ctrl) {} - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - - /*! \cond */ - circular_buffer_space_optimized(const circular_buffer_space_optimized& cb) - : circular_buffer(cb.begin(), cb.end()) - , m_capacity_ctrl(cb.m_capacity_ctrl) {} - - template - circular_buffer_space_optimized(InputIterator first, InputIterator last) - : circular_buffer(first, last) - , m_capacity_ctrl(circular_buffer::capacity()) {} - - template - circular_buffer_space_optimized(capacity_type capacity_ctrl, InputIterator first, InputIterator last) - : circular_buffer( - init_capacity(capacity_ctrl, first, last, is_integral()), - first, last) - , m_capacity_ctrl(capacity_ctrl) { - reduce_capacity( - is_same< BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type, std::input_iterator_tag >()); - } - /*! \endcond */ - -#else - - //! The copy constructor. - /*! - Creates a copy of the specified circular_buffer_space_optimized. - \post *this == cb

- The amount of allocated memory in the internal buffer is cb.size(). - \param cb The circular_buffer_space_optimized to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in the size of cb). - */ - circular_buffer_space_optimized(const circular_buffer_space_optimized& cb) - : circular_buffer(cb.begin(), cb.end(), cb.get_allocator()) - , m_capacity_ctrl(cb.m_capacity_ctrl) {} - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - //! The move constructor. - /*! \brief Move constructs a circular_buffer_space_optimized from cb, - leaving cb empty. - \pre C++ compiler with rvalue references support. - \post cb.empty() - \param cb circular_buffer to 'steal' value from. - \throws Nothing. - \par Constant. - */ - circular_buffer_space_optimized(circular_buffer_space_optimized&& cb) BOOST_NOEXCEPT - : circular_buffer() - , m_capacity_ctrl(0) { - cb.swap(*this); - } -#endif // BOOST_NO_CXX11_RVALUE_REFERENCES - - //! Create a full space optimized circular buffer filled with a copy of the range. - /*! - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity().%capacity() == std::distance(first, last) \&\& capacity().min_capacity() == 0 \&\& - full() \&\& (*this)[0]== *first \&\& (*this)[1] == *(first + 1) \&\& ... \&\& - (*this)[std::distance(first, last) - 1] == *(last - 1)

- The amount of allocated memory in the internal buffer is std::distance(first, last). - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept - and InputIterator is a move iterator. - \par Complexity - Linear (in the std::distance(first, last)). - */ - template - circular_buffer_space_optimized(InputIterator first, InputIterator last, - const allocator_type& alloc = allocator_type()) - : circular_buffer(first, last, alloc) - , m_capacity_ctrl(circular_buffer::capacity()) {} - - /*! \brief Create a space optimized circular buffer with the specified capacity (and the minimal guaranteed amount - of allocated memory) filled with a copy of the range. - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == capacity_ctrl \&\& size() \<= std::distance(first, last) \&\& (*this)[0]== - *(last - capacity_ctrl.%capacity()) \&\& (*this)[1] == *(last - capacity_ctrl.%capacity() + 1) \&\& ... - \&\& (*this)[capacity_ctrl.%capacity() - 1] == *(last - 1)

- If the number of items to be copied from the range [first, last) is greater than the - specified capacity_ctrl.%capacity() then only elements from the range - [last - capacity_ctrl.%capacity(), last) will be copied.

- The amount of allocated memory in the internal buffer is max[capacity_ctrl.min_capacity(), - min[capacity_ctrl.%capacity(), std::distance(first, last)]]. - \param capacity_ctrl The capacity controller representing the maximum number of elements which can be stored in - the circular_buffer_space_optimized and the minimal allocated size of the - internal buffer. - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \param alloc The allocator. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Complexity - Linear (in std::distance(first, last); in - min[capacity_ctrl.%capacity(), std::distance(first, last)] if the InputIterator - is a RandomAccessIterator). - */ - template - circular_buffer_space_optimized(capacity_type capacity_ctrl, InputIterator first, InputIterator last, - const allocator_type& alloc = allocator_type()) - : circular_buffer( - init_capacity(capacity_ctrl, first, last, is_integral()), - first, last, alloc) - , m_capacity_ctrl(capacity_ctrl) { - reduce_capacity( - is_same< BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type, std::input_iterator_tag >()); - } - -#endif // #if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - -#if defined(BOOST_CB_NEVER_DEFINED) -// This section will never be compiled - the default destructor will be generated instead. -// Declared only for documentation purpose. - - //! The destructor. - /*! - Destroys the circular_buffer_space_optimized. - \throws Nothing. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (including - iterators equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa clear() - */ - ~circular_buffer_space_optimized(); - - //! no-comment - void erase_begin(size_type n); - - //! no-comment - void erase_end(size_type n); - -#endif // #if defined(BOOST_CB_NEVER_DEFINED) - - //! The assign operator. - /*! - Makes this circular_buffer_space_optimized to become a copy of the specified - circular_buffer_space_optimized. - \post *this == cb

- The amount of allocated memory in the internal buffer is cb.size(). - \param cb The circular_buffer_space_optimized to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \throws Whatever T::T(const T&) throws. - \par Exception Safety - Strong. - \par Iterator Invalidation - Invalidates all iterators pointing to this circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of cb). - \sa \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - circular_buffer_space_optimized& operator = (const circular_buffer_space_optimized& cb) { - if (this == &cb) - return *this; - circular_buffer::assign(cb.begin(), cb.end()); - m_capacity_ctrl = cb.m_capacity_ctrl; - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - /*! \brief Move assigns content of cb to *this, leaving cb empty. - \pre C++ compiler with rvalue references support. - \post cb.empty() - \param cb circular_buffer to 'steal' value from. - \throws Nothing. - \par Complexity - Constant. - */ - circular_buffer_space_optimized& operator = (circular_buffer_space_optimized&& cb) BOOST_NOEXCEPT { - cb.swap(*this); // now `this` holds `cb` - circular_buffer(get_allocator()) // temprary that holds initial `cb` allocator - .swap(cb); // makes `cb` empty - return *this; - } -#endif // BOOST_NO_CXX11_RVALUE_REFERENCES - - - //! Assign n items into the space optimized circular buffer. - /*! - The content of the circular_buffer_space_optimized will be removed and replaced with - n copies of the item. - \post capacity().%capacity() == n \&\& capacity().min_capacity() == 0 \&\& size() == n \&\& (*this)[0] == - item \&\& (*this)[1] == item \&\& ... \&\& (*this) [n - 1] == item

- The amount of allocated memory in the internal buffer is n. - \param n The number of elements the circular_buffer_space_optimized will be filled with. - \param item The element the circular_buffer_space_optimized will be filled with. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the n). - \sa \link operator=(const circular_buffer_space_optimized&) operator=\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - void assign(size_type n, param_value_type item) { - circular_buffer::assign(n, item); - m_capacity_ctrl = capacity_type(n); - } - - //! Assign n items into the space optimized circular buffer specifying the capacity. - /*! - The capacity of the circular_buffer_space_optimized will be set to the specified value and the - content of the circular_buffer_space_optimized will be removed and replaced with n - copies of the item. - \pre capacity_ctrl.%capacity() >= n - \post capacity() == capacity_ctrl \&\& size() == n \&\& (*this)[0] == item \&\& (*this)[1] == item - \&\& ... \&\& (*this) [n - 1] == item

- The amount of allocated memory will be max[n, capacity_ctrl.min_capacity()]. - \param capacity_ctrl The new capacity controller. - \param n The number of elements the circular_buffer_space_optimized will be filled with. - \param item The element the circular_buffer_space_optimized will be filled with. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the n). - \sa \link operator=(const circular_buffer_space_optimized&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - assign(InputIterator, InputIterator), - assign(capacity_type, InputIterator, InputIterator) - */ - void assign(capacity_type capacity_ctrl, size_type n, param_value_type item) { - BOOST_CB_ASSERT(capacity_ctrl.capacity() >= n); // check for new capacity lower than n - circular_buffer::assign((std::max)(capacity_ctrl.min_capacity(), n), n, item); - m_capacity_ctrl = capacity_ctrl; - } - - //! Assign a copy of the range into the space optimized circular buffer. - /*! - The content of the circular_buffer_space_optimized will be removed and replaced with copies of - elements from the specified range. - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity().%capacity() == std::distance(first, last) \&\& capacity().min_capacity() == 0 \&\& - size() == std::distance(first, last) \&\& (*this)[0]== *first \&\& (*this)[1] == *(first + 1) \&\& ... - \&\& (*this)[std::distance(first, last) - 1] == *(last - 1)

- The amount of allocated memory in the internal buffer is std::distance(first, last). - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept and - InputIterator is a move iterator. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the std::distance(first, last)). - \sa \link operator=(const circular_buffer_space_optimized&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(capacity_type, InputIterator, InputIterator) - */ - template - void assign(InputIterator first, InputIterator last) { - circular_buffer::assign(first, last); - m_capacity_ctrl = capacity_type(circular_buffer::capacity()); - } - - //! Assign a copy of the range into the space optimized circular buffer specifying the capacity. - /*! - The capacity of the circular_buffer_space_optimized will be set to the specified value and the - content of the circular_buffer_space_optimized will be removed and replaced with copies of - elements from the specified range. - \pre Valid range [first, last).
- first and last have to meet the requirements of - InputIterator. - \post capacity() == capacity_ctrl \&\& size() \<= std::distance(first, last) \&\& - (*this)[0]== *(last - capacity) \&\& (*this)[1] == *(last - capacity + 1) \&\& ... \&\& - (*this)[capacity - 1] == *(last - 1)

- If the number of items to be copied from the range [first, last) is greater than the - specified capacity then only elements from the range [last - capacity, last) - will be copied.

The amount of allocated memory in the internal buffer is - max[std::distance(first, last), capacity_ctrl.min_capacity()]. - \param capacity_ctrl The new capacity controller. - \param first The beginning of the range to be copied. - \param last The end of the range to be copied. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept and - InputIterator is a move iterator. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in std::distance(first, last); in - min[capacity_ctrl.%capacity(), std::distance(first, last)] if the InputIterator - is a RandomAccessIterator). - \sa \link operator=(const circular_buffer_space_optimized&) operator=\endlink, - \link assign(size_type, param_value_type) assign(size_type, const_reference)\endlink, - \link assign(capacity_type, size_type, param_value_type) - assign(capacity_type, size_type, const_reference)\endlink, - assign(InputIterator, InputIterator) - */ - template - void assign(capacity_type capacity_ctrl, InputIterator first, InputIterator last) { - m_capacity_ctrl = capacity_ctrl; - circular_buffer::assign(capacity_ctrl, first, last); - } - - //! Swap the contents of two space-optimized circular-buffers. - /*! - \post this contains elements of cb and vice versa; the capacity and the amount of - allocated memory in the internal buffer of this equal to the capacity and the amount of - allocated memory of cb and vice versa. - \param cb The circular_buffer_space_optimized whose content will be swapped. - \throws Nothing. - \par Exception Safety - No-throw. - \par Iterator Invalidation - Invalidates all iterators of both circular_buffer_space_optimized containers. (On the other - hand the iterators still point to the same elements but within another container. If you want to rely on - this feature you have to turn the __debug_support off by defining macro BOOST_CB_DISABLE_DEBUG, - otherwise an assertion will report an error if such invalidated iterator is used.) - \par Complexity - Constant (in the size of the circular_buffer_space_optimized). - \sa swap(circular_buffer&, circular_buffer&), - swap(circular_buffer_space_optimized&, circular_buffer_space_optimized&) - - - */ - // Note link does not work right. Asked on Doxygen forum for advice 23 May 2103. - - void swap(circular_buffer_space_optimized& cb) BOOST_NOEXCEPT { - std::swap(m_capacity_ctrl, cb.m_capacity_ctrl); - circular_buffer::swap(cb); - } - - //! Insert a new element at the end of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then back() == item
- If the circular_buffer_space_optimized is full, the first element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param item The element to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_front() push_front(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_back(param_value_type item) { - check_low_capacity(); - circular_buffer::push_back(item); - } - - //! Insert a new element at the end of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then back() == item
- If the circular_buffer_space_optimized is full, the first element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param item The element to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_front() push_front(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_back(rvalue_type item) { - check_low_capacity(); - circular_buffer::push_back(boost::move(item)); - } - - //! Insert a new element at the end of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then back() == item
- If the circular_buffer_space_optimized is full, the first element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T() throws. - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_front() push_front(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_back() { - check_low_capacity(); - circular_buffer::push_back(); - } - - //! Insert a new element at the beginning of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then front() == item
- If the circular_buffer_space_optimized is full, the last element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param item The element to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_back() push_back(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_front(param_value_type item) { - check_low_capacity(); - circular_buffer::push_front(item); - } - - //! Insert a new element at the beginning of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then front() == item
- If the circular_buffer_space_optimized is full, the last element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param item The element to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_back() push_back(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_front(rvalue_type item) { - check_low_capacity(); - circular_buffer::push_front(boost::move(item)); - } - - //! Insert a new element at the beginning of the space optimized circular buffer. - /*! - \post if capacity().%capacity() > 0 then front() == item
- If the circular_buffer_space_optimized is full, the last element will be removed. If the - capacity is 0, nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T() throws. - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link push_back() push_back(const_reference)\endlink, pop_back(), - pop_front() - */ - void push_front() { - check_low_capacity(); - circular_buffer::push_front(); - } - - //! Remove the last element from the space optimized circular buffer. - /*! - \pre !empty() - \post The last element is removed from the circular_buffer_space_optimized.

- The amount of allocated memory in the internal buffer may be predictively decreased. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa pop_front(), \link push_back() push_back(const_reference)\endlink, - \link push_front() push_front(const_reference)\endlink - */ - void pop_back() { - circular_buffer::pop_back(); - check_high_capacity(); - } - - //! Remove the first element from the space optimized circular buffer. - /*! - \pre !empty() - \post The first element is removed from the circular_buffer_space_optimized.

- The amount of allocated memory in the internal buffer may be predictively decreased. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa pop_back(), \link push_back() push_back(const_reference)\endlink, - \link push_front() push_front(const_reference)\endlink - */ - void pop_front() { - circular_buffer::pop_front(); - check_high_capacity(); - } - - //! Insert an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted at the position pos.
- If the circular_buffer_space_optimized is full, the first element will be overwritten. If - the circular_buffer_space_optimized is full and the pos points to - begin(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos, param_value_type item) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::insert(begin() + index, item); - } - - //! Insert an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted at the position pos.
- If the circular_buffer_space_optimized is full, the first element will be overwritten. If - the circular_buffer_space_optimized is full and the pos points to - begin(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos, rvalue_type item) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::insert(begin() + index, boost::move(item)); - } - - //! Insert an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted at the position pos.
- If the circular_buffer_space_optimized is full, the first element will be overwritten. If - the circular_buffer_space_optimized is full and the pos points to - begin(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the item will be inserted. - \return Iterator to the inserted element or begin() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T() throws. - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - iterator insert(iterator pos) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::insert(begin() + index); - } - - //! Insert n copies of the item at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The number of min[n, (pos - begin()) + reserve()] elements will be inserted at the position - pos.
The number of min[pos - begin(), max[0, n - reserve()]] elements will - be overwritten at the beginning of the circular_buffer_space_optimized.
(See - Example for the explanation.)

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the items will be inserted. - \param n The number of items the to be inserted. - \param item The element whose copies will be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in min[capacity().%capacity(), size() + n]). - \par Example - Consider a circular_buffer_space_optimized with the capacity of 6 and the size of 4. Its - internal buffer may look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting 5 elements at the position p:

- insert(p, (size_t)5, 0);

actually only 4 elements get inserted and elements - 1 and 2 are overwritten. This is due to the fact the insert operation preserves - the capacity. After insertion the internal buffer looks like this:

|0|0|0|0|3|4|
-
For comparison if the capacity would not be preserved the internal buffer would then result in - |1|2|0|0|0|0|0|3|4|. - \sa \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - insert(iterator, InputIterator, InputIterator), - \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - void insert(iterator pos, size_type n, param_value_type item) { - size_type index = pos - begin(); - check_low_capacity(n); - circular_buffer::insert(begin() + index, n, item); - } - - //! Insert the range [first, last) at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end.
Valid range [first, last) where first and last meet the - requirements of an InputIterator. - \post Elements from the range - [first + max[0, distance(first, last) - (pos - begin()) - reserve()], last) will be - inserted at the position pos.
The number of min[pos - begin(), max[0, - distance(first, last) - reserve()]] elements will be overwritten at the beginning of the - circular_buffer_space_optimized.
(See Example for the explanation.)

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the range will be inserted. - \param first The beginning of the range to be inserted. - \param last The end of the range to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in [size() + std::distance(first, last)]; in - min[capacity().%capacity(), size() + std::distance(first, last)] if the - InputIterator is a - RandomAccessIterator). - \par Example - Consider a circular_buffer_space_optimized with the capacity of 6 and the size of 4. Its - internal buffer may look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting a range of elements at the position p:

- int array[] = { 5, 6, 7, 8, 9 };
insert(p, array, array + 5);

- actually only elements 6, 7, 8 and 9 from the - specified range get inserted and elements 1 and 2 are overwritten. This is due - to the fact the insert operation preserves the capacity. After insertion the internal buffer looks like - this:

|6|7|8|9|3|4|

For comparison if the capacity would not be preserved the - internal buffer would then result in |1|2|5|6|7|8|9|3|4|. - \sa \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, \link rinsert(iterator, param_value_type) - rinsert(iterator, value_type)\endlink, \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator) - */ - template - void insert(iterator pos, InputIterator first, InputIterator last) { - insert(pos, first, last, is_integral()); - } - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted before the position pos.
- If the circular_buffer_space_optimized is full, the last element will be overwritten. If the - circular_buffer_space_optimized is full and the pos points to - end(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position before which the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos, param_value_type item) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::rinsert(begin() + index, item); - } - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted before the position pos.
- If the circular_buffer_space_optimized is full, the last element will be overwritten. If the - circular_buffer_space_optimized is full and the pos points to - end(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position before which the item will be inserted. - \param item The element to be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos, rvalue_type item) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::rinsert(begin() + index, boost::move(item)); - } - - //! Insert an element before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The item will be inserted before the position pos.
- If the circular_buffer_space_optimized is full, the last element will be overwritten. If the - circular_buffer_space_optimized is full and the pos points to - end(), then the item will not be inserted. If the capacity is 0, - nothing will be inserted.

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position before which the item will be inserted. - \return Iterator to the inserted element or end() if the item is not inserted. (See - the Effect.) - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T() throws. - Whatever T::T(const T&) throws or nothing if T::T(T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - iterator rinsert(iterator pos) { - size_type index = pos - begin(); - check_low_capacity(); - return circular_buffer::rinsert(begin() + index); - } - - //! Insert n copies of the item before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end. - \post The number of min[n, (end() - pos) + reserve()] elements will be inserted before the - position pos.
The number of min[end() - pos, max[0, n - reserve()]] elements - will be overwritten at the end of the circular_buffer_space_optimized.
(See - Example for the explanation.)

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the items will be inserted. - \param n The number of items the to be inserted. - \param item The element whose copies will be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in min[capacity().%capacity(), size() + n]). - \par Example - Consider a circular_buffer_space_optimized with the capacity of 6 and the size of 4. Its - internal buffer may look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting 5 elements before the position p:

- rinsert(p, (size_t)5, 0);

actually only 4 elements get inserted and elements - 3 and 4 are overwritten. This is due to the fact the rinsert operation preserves - the capacity. After insertion the internal buffer looks like this:

|1|2|0|0|0|0|
-
For comparison if the capacity would not be preserved the internal buffer would then result in - |1|2|0|0|0|0|0|3|4|. - \sa \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - rinsert(iterator, InputIterator, InputIterator), - \link insert(iterator, param_value_type) insert(iterator, value_type)\endlink, - \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - void rinsert(iterator pos, size_type n, param_value_type item) { - size_type index = pos - begin(); - check_low_capacity(n); - circular_buffer::rinsert(begin() + index, n, item); - } - - //! Insert the range [first, last) before the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized or its - end.
- Valid range [first, last) where first and last meet the - requirements of an InputIterator. - \post Elements from the range - [first, last - max[0, distance(first, last) - (end() - pos) - reserve()]) will be inserted - before the position pos.
The number of min[end() - pos, max[0, - distance(first, last) - reserve()]] elements will be overwritten at the end of the - circular_buffer.
(See Example for the explanation.)

- The amount of allocated memory in the internal buffer may be predictively increased. - \param pos An iterator specifying the position where the range will be inserted. - \param first The beginning of the range to be inserted. - \param last The end of the range to be inserted. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::T(const T&) throws. - Whatever T::operator = (const T&) throws. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in [size() + std::distance(first, last)]; in - min[capacity().%capacity(), size() + std::distance(first, last)] if the - InputIterator is a - RandomAccessIterator). - \par Example - Consider a circular_buffer_space_optimized with the capacity of 6 and the size of 4. Its - internal buffer may look like the one below.

- |1|2|3|4| | |
- p ___^

After inserting a range of elements before the position p:

- int array[] = { 5, 6, 7, 8, 9 };
insert(p, array, array + 5);

- actually only elements 5, 6, 7 and 8 from the - specified range get inserted and elements 3 and 4 are overwritten. This is due - to the fact the rinsert operation preserves the capacity. After insertion the internal buffer looks like - this:

|1|2|5|6|7|8|

For comparison if the capacity would not be preserved the - internal buffer would then result in |1|2|5|6|7|8|9|3|4|. - \sa \link rinsert(iterator, param_value_type) rinsert(iterator, value_type)\endlink, - \link rinsert(iterator, size_type, param_value_type) - rinsert(iterator, size_type, value_type)\endlink, \link insert(iterator, param_value_type) - insert(iterator, value_type)\endlink, \link insert(iterator, size_type, param_value_type) - insert(iterator, size_type, value_type)\endlink, - insert(iterator, InputIterator, InputIterator) - */ - template - void rinsert(iterator pos, InputIterator first, InputIterator last) { - rinsert(pos, first, last, is_integral()); - } - - //! Remove an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized (but not - an end()). - \post The element at the position pos is removed.

- The amount of allocated memory in the internal buffer may be predictively decreased. - \param pos An iterator pointing at the element to be removed. - \return Iterator to the first element remaining beyond the removed element or end() if no such - element exists. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::operator = (const T&) throws or - nothing if T::operator = (T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa erase(iterator, iterator), rerase(iterator), - rerase(iterator, iterator), clear() - */ - iterator erase(iterator pos) { - iterator it = circular_buffer::erase(pos); - size_type index = it - begin(); - check_high_capacity(); - return begin() + index; - } - - //! Erase the range [first, last). - /*! - \pre Valid range [first, last). - \post The elements from the range [first, last) are removed. (If first == last - nothing is removed.)

- The amount of allocated memory in the internal buffer may be predictively decreased. - \param first The beginning of the range to be removed. - \param last The end of the range to be removed. - \return Iterator to the first element remaining beyond the removed elements or end() if no such - element exists. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::operator = (const T&) throws or - nothing if T::operator = (T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa erase(iterator), rerase(iterator), rerase(iterator, iterator), - clear() - */ - iterator erase(iterator first, iterator last) { - iterator it = circular_buffer::erase(first, last); - size_type index = it - begin(); - check_high_capacity(); - return begin() + index; - } - - //! Remove an element at the specified position. - /*! - \pre pos is a valid iterator pointing to the circular_buffer_space_optimized (but not - an end()).

- The amount of allocated memory in the internal buffer may be predictively decreased. - \post The element at the position pos is removed. - \param pos An iterator pointing at the element to be removed. - \return Iterator to the first element remaining in front of the removed element or begin() if no - such element exists. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::operator = (const T&) throws or - nothing if T::operator = (T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \note Basically there is no difference between erase(iterator) and this method. It is implemented - only for consistency with the base circular_buffer. - \sa erase(iterator), erase(iterator, iterator), - rerase(iterator, iterator), clear() - */ - iterator rerase(iterator pos) { - iterator it = circular_buffer::rerase(pos); - size_type index = it - begin(); - check_high_capacity(); - return begin() + index; - } - - //! Erase the range [first, last). - /*! - \pre Valid range [first, last). - \post The elements from the range [first, last) are removed. (If first == last - nothing is removed.)

- The amount of allocated memory in the internal buffer may be predictively decreased. - \param first The beginning of the range to be removed. - \param last The end of the range to be removed. - \return Iterator to the first element remaining in front of the removed elements or begin() if no - such element exists. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - Whatever T::operator = (const T&) throws or - nothing if T::operator = (T&&) is noexcept. - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \note Basically there is no difference between erase(iterator, iterator) and this method. It is - implemented only for consistency with the base - . - \sa erase(iterator), erase(iterator, iterator), rerase(iterator), - clear() - */ - iterator rerase(iterator first, iterator last) { - iterator it = circular_buffer::rerase(first, last); - size_type index = it - begin(); - check_high_capacity(); - return begin() + index; - } - - //! Remove all stored elements from the space optimized circular buffer. - /*! - \post size() == 0

- The amount of allocated memory in the internal buffer may be predictively decreased. - \throws "An allocation error" if memory is exhausted (std::bad_alloc if the standard allocator is - used). - \par Exception Safety - Basic. - \par Iterator Invalidation - Invalidates all iterators pointing to the circular_buffer_space_optimized (except iterators - equal to end()). - \par Complexity - Linear (in the size of the circular_buffer_space_optimized). - \sa ~circular_buffer_space_optimized(), erase(iterator), - erase(iterator, iterator), rerase(iterator), - rerase(iterator, iterator) - */ - void clear() { erase(begin(), end()); } - -private: -// Helper methods - - //! Adjust the amount of allocated memory. - void adjust_min_capacity() { - if (m_capacity_ctrl.min_capacity() > circular_buffer::capacity()) - circular_buffer::set_capacity(m_capacity_ctrl.min_capacity()); - else - check_high_capacity(); - } - - //! Ensure the reserve for possible growth up. - size_type ensure_reserve(size_type new_capacity, size_type buffer_size) const { - if (buffer_size + new_capacity / 5 >= new_capacity) - new_capacity *= 2; // ensure at least 20% reserve - if (new_capacity > m_capacity_ctrl) - return m_capacity_ctrl; - return new_capacity; - } - - //! Check for low capacity. - /* - \post If the capacity is low it will be increased. - */ - void check_low_capacity(size_type n = 1) { - size_type new_size = size() + n; - size_type new_capacity = circular_buffer::capacity(); - if (new_size > new_capacity) { - if (new_capacity == 0) - new_capacity = 1; - for (; new_size > new_capacity; new_capacity *= 2) {} - circular_buffer::set_capacity( - ensure_reserve(new_capacity, new_size)); - } -#if BOOST_CB_ENABLE_DEBUG - this->invalidate_iterators_except(end()); -#endif - } - - //! Check for high capacity. - /* - \post If the capacity is high it will be decreased. - */ - void check_high_capacity() { - size_type new_capacity = circular_buffer::capacity(); - while (new_capacity / 3 >= size()) { // (new_capacity / 3) -> avoid oscillations - new_capacity /= 2; - if (new_capacity <= m_capacity_ctrl.min_capacity()) { - new_capacity = m_capacity_ctrl.min_capacity(); - break; - } - } - circular_buffer::set_capacity( - ensure_reserve(new_capacity, size())); -#if BOOST_CB_ENABLE_DEBUG - this->invalidate_iterators_except(end()); -#endif - } - - //! Specialized method for reducing the capacity. - void reduce_capacity(const true_type&) { - circular_buffer::set_capacity((std::max)(m_capacity_ctrl.min_capacity(), size())); - } - - //! Specialized method for reducing the capacity. - void reduce_capacity(const false_type&) {} - - //! Determine the initial capacity. - static size_type init_capacity(const capacity_type& capacity_ctrl, size_type n) { - BOOST_CB_ASSERT(capacity_ctrl.capacity() >= n); // check for capacity lower than n - return (std::max)(capacity_ctrl.min_capacity(), n); - } - - //! Specialized method for determining the initial capacity. - template - static size_type init_capacity(const capacity_type& capacity_ctrl, IntegralType n, IntegralType, - const true_type&) { - return init_capacity(capacity_ctrl, static_cast(n)); - } - - //! Specialized method for determining the initial capacity. - template - static size_type init_capacity(const capacity_type& capacity_ctrl, Iterator first, Iterator last, - const false_type&) { - BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581)) - return init_capacity(capacity_ctrl, first, last, BOOST_ITERATOR_CATEGORY::type()); -#else - return init_capacity( - capacity_ctrl, first, last, BOOST_DEDUCED_TYPENAME BOOST_ITERATOR_CATEGORY::type()); -#endif - } - - //! Specialized method for determining the initial capacity. - template - static size_type init_capacity(const capacity_type& capacity_ctrl, InputIterator, InputIterator, - const std::input_iterator_tag&) { - return capacity_ctrl.capacity(); - } - - //! Specialized method for determining the initial capacity. - template - static size_type init_capacity(const capacity_type& capacity_ctrl, ForwardIterator first, ForwardIterator last, - const std::forward_iterator_tag&) { - BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range - return (std::max)(capacity_ctrl.min_capacity(), - (std::min)(capacity_ctrl.capacity(), static_cast(std::distance(first, last)))); - } - - //! Specialized insert method. - template - void insert(const iterator& pos, IntegralType n, IntegralType item, const true_type&) { - insert(pos, static_cast(n), static_cast(item)); - } - - //! Specialized insert method. - template - void insert(const iterator& pos, Iterator first, Iterator last, const false_type&) { - size_type index = pos - begin(); - check_low_capacity(std::distance(first, last)); - circular_buffer::insert(begin() + index, first, last); - } - - //! Specialized rinsert method. - template - void rinsert(const iterator& pos, IntegralType n, IntegralType item, const true_type&) { - rinsert(pos, static_cast(n), static_cast(item)); - } - - //! Specialized rinsert method. - template - void rinsert(const iterator& pos, Iterator first, Iterator last, const false_type&) { - size_type index = pos - begin(); - check_low_capacity(std::distance(first, last)); - circular_buffer::rinsert(begin() + index, first, last); - } -}; - -// Non-member functions - -//! Test two space optimized circular buffers for equality. -template -inline bool operator == (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return lhs.size() == rhs.size() && - std::equal(lhs.begin(), lhs.end(), rhs.begin()); -} - -//! Lexicographical comparison. -template -inline bool operator < (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return std::lexicographical_compare( - lhs.begin(), lhs.end(), rhs.begin(), rhs.end()); -} - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) || BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1310)) - -//! Test two space optimized circular buffers for non-equality. -template -inline bool operator != (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return !(lhs == rhs); -} - -//! Lexicographical comparison. -template -inline bool operator > (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return rhs < lhs; -} - -//! Lexicographical comparison. -template -inline bool operator <= (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return !(rhs < lhs); -} - -//! Lexicographical comparison. -template -inline bool operator >= (const circular_buffer_space_optimized& lhs, - const circular_buffer_space_optimized& rhs) { - return !(lhs < rhs); -} - -//! Swap the contents of two space optimized circular buffers. -template -inline void swap(circular_buffer_space_optimized& lhs, - circular_buffer_space_optimized& rhs) BOOST_NOEXCEPT { - lhs.swap(rhs); -} - -#endif // #if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) || BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1310)) - -} // namespace boost - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_SPACE_OPTIMIZED_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/circular_buffer_fwd.hpp deleted file mode 100644 index 6fdb43e0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/circular_buffer_fwd.hpp +++ /dev/null @@ -1,43 +0,0 @@ -// Forward declaration of the circular buffer and its adaptor. - -// Copyright (c) 2003-2008 Jan Gaspar - -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See www.boost.org/libs/circular_buffer for documentation. - -#if !defined(BOOST_CIRCULAR_BUFFER_FWD_HPP) -#define BOOST_CIRCULAR_BUFFER_FWD_HPP - -#if defined(_MSC_VER) && _MSC_VER >= 1200 - #pragma once -#endif - -#include -#if !defined(BOOST_NO_STD_ALLOCATOR) - #include -#else - #include -#endif - -namespace boost { - -#if !defined(BOOST_NO_STD_ALLOCATOR) - #define BOOST_CB_DEFAULT_ALLOCATOR(T) std::allocator -#else - #define BOOST_CB_DEFAULT_ALLOCATOR(T) BOOST_DEDUCED_TYPENAME std::vector::allocator_type -#endif - -template -class circular_buffer; - -template -class circular_buffer_space_optimized; - -#undef BOOST_CB_DEFAULT_ALLOCATOR - -} // namespace boost - -#endif // #if !defined(BOOST_CIRCULAR_BUFFER_FWD_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/compressed_pair.hpp b/third_party/ycmd/cpp/BoostParts/boost/compressed_pair.hpp deleted file mode 100644 index e6cd6a07..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/compressed_pair.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. - -// See boost/detail/compressed_pair.hpp and boost/detail/ob_compressed_pair.hpp -// for full copyright notices. - -#ifndef BOOST_COMPRESSED_PAIR_HPP -#define BOOST_COMPRESSED_PAIR_HPP - -#ifndef BOOST_CONFIG_HPP -#include -#endif - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -#include -#else -#include -#endif - -#endif // BOOST_COMPRESSED_PAIR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/assert.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/assert.hpp deleted file mode 100644 index 80eca817..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/assert.hpp +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_ASSERT_DWA2006430_HPP -# define BOOST_CONCEPT_ASSERT_DWA2006430_HPP - -# include -# include - -// The old protocol used a constraints() member function in concept -// checking classes. If the compiler supports SFINAE, we can detect -// that function and seamlessly support the old concept checking -// classes. In this release, backward compatibility with the old -// concept checking classes is enabled by default, where available. -// The old protocol is deprecated, though, and backward compatibility -// will no longer be the default in the next release. - -# if !defined(BOOST_NO_OLD_CONCEPT_SUPPORT) \ - && !defined(BOOST_NO_SFINAE) \ - \ - && !(BOOST_WORKAROUND(__GNUC__, == 3) && BOOST_WORKAROUND(__GNUC_MINOR__, < 4)) \ - && !(BOOST_WORKAROUND(__GNUC__, == 2)) - -// Note: gcc-2.96 through 3.3.x have some SFINAE, but no ability to -// check for the presence of particularmember functions. - -# define BOOST_OLD_CONCEPT_SUPPORT - -# endif - -# ifdef BOOST_MSVC -# include -# elif BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -# include -# else -# include -# endif - - // Usage, in class or function context: - // - // BOOST_CONCEPT_ASSERT((UnaryFunctionConcept)); - // -# define BOOST_CONCEPT_ASSERT(ModelInParens) \ - BOOST_CONCEPT_ASSERT_FN(void(*)ModelInParens) - -#endif // BOOST_CONCEPT_ASSERT_DWA2006430_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/backward_compatibility.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/backward_compatibility.hpp deleted file mode 100644 index 66d573ef..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/backward_compatibility.hpp +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright David Abrahams 2009. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_BACKWARD_COMPATIBILITY_DWA200968_HPP -# define BOOST_CONCEPT_BACKWARD_COMPATIBILITY_DWA200968_HPP - -namespace boost -{ - namespace concepts {} - -# if defined(BOOST_HAS_CONCEPTS) && !defined(BOOST_CONCEPT_NO_BACKWARD_KEYWORD) - namespace concept = concepts; -# endif -} // namespace boost::concept - -#endif // BOOST_CONCEPT_BACKWARD_COMPATIBILITY_DWA200968_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/borland.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/borland.hpp deleted file mode 100644 index 300d5d40..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/borland.hpp +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_DETAIL_BORLAND_DWA2006429_HPP -# define BOOST_CONCEPT_DETAIL_BORLAND_DWA2006429_HPP - -# include -# include - -namespace boost { namespace concepts { - -template -struct require; - -template -struct require -{ - enum { instantiate = sizeof((((Model*)0)->~Model()), 3) }; -}; - -# define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ - enum \ - { \ - BOOST_PP_CAT(boost_concept_check,__LINE__) = \ - boost::concepts::require::instantiate \ - } - -}} // namespace boost::concept - -#endif // BOOST_CONCEPT_DETAIL_BORLAND_DWA2006429_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_def.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_def.hpp deleted file mode 100644 index 79f628e9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_def.hpp +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_DETAIL_CONCEPT_DEF_DWA200651_HPP -# define BOOST_CONCEPT_DETAIL_CONCEPT_DEF_DWA200651_HPP -# include -# include -# include -# include -#endif // BOOST_CONCEPT_DETAIL_CONCEPT_DEF_DWA200651_HPP - -// BOOST_concept(SomeName, (p1)(p2)...(pN)) -// -// Expands to "template struct SomeName" -// -// Also defines an equivalent SomeNameConcept for backward compatibility. -// Maybe in the next release we can kill off the "Concept" suffix for good. -#if BOOST_WORKAROUND(__GNUC__, <= 3) -# define BOOST_concept(name, params) \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct name; /* forward declaration */ \ - \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct BOOST_PP_CAT(name,Concept) \ - : name< BOOST_PP_SEQ_ENUM(params) > \ - { \ - /* at least 2.96 and 3.4.3 both need this */ \ - BOOST_PP_CAT(name,Concept)(); \ - }; \ - \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct name -#else -# define BOOST_concept(name, params) \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct name; /* forward declaration */ \ - \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct BOOST_PP_CAT(name,Concept) \ - : name< BOOST_PP_SEQ_ENUM(params) > \ - { \ - }; \ - \ - template < BOOST_PP_SEQ_FOR_EACH_I(BOOST_CONCEPT_typename,~,params) > \ - struct name -#endif - -// Helper for BOOST_concept, above. -# define BOOST_CONCEPT_typename(r, ignored, index, t) \ - BOOST_PP_COMMA_IF(index) typename t - diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_undef.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_undef.hpp deleted file mode 100644 index 713db891..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/concept_undef.hpp +++ /dev/null @@ -1,5 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -# undef BOOST_concept_typename -# undef BOOST_concept diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/general.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/general.hpp deleted file mode 100644 index e3014c1b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/general.hpp +++ /dev/null @@ -1,75 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_DETAIL_GENERAL_DWA2006429_HPP -# define BOOST_CONCEPT_DETAIL_GENERAL_DWA2006429_HPP - -# include -# include - -# ifdef BOOST_OLD_CONCEPT_SUPPORT -# include -# include -# endif - -// This implementation works on Comeau and GCC, all the way back to -// 2.95 -namespace boost { namespace concepts { - -template -struct requirement_; - -namespace detail -{ - template struct instantiate {}; -} - -template -struct requirement -{ - static void failed() { ((Model*)0)->~Model(); } -}; - -struct failed {}; - -template -struct requirement -{ - static void failed() { ((Model*)0)->~Model(); } -}; - -# ifdef BOOST_OLD_CONCEPT_SUPPORT - -template -struct constraint -{ - static void failed() { ((Model*)0)->constraints(); } -}; - -template -struct requirement_ - : mpl::if_< - concepts::not_satisfied - , constraint - , requirement - >::type -{}; - -# else - -// For GCC-2.x, these can't have exactly the same name -template -struct requirement_ - : requirement -{}; - -# endif - -# define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ - typedef ::boost::concepts::detail::instantiate< \ - &::boost::concepts::requirement_::failed> \ - BOOST_PP_CAT(boost_concept_check,__LINE__) - -}} - -#endif // BOOST_CONCEPT_DETAIL_GENERAL_DWA2006429_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/has_constraints.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/has_constraints.hpp deleted file mode 100644 index a309db3d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/has_constraints.hpp +++ /dev/null @@ -1,50 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_DETAIL_HAS_CONSTRAINTS_DWA2006429_HPP -# define BOOST_CONCEPT_DETAIL_HAS_CONSTRAINTS_DWA2006429_HPP - -# include -# include -# include - -namespace boost { namespace concepts { - -namespace detail -{ - -// Here we implement the metafunction that detects whether a -// constraints metafunction exists - typedef char yes; - typedef char (&no)[2]; - - template - struct wrap_constraints {}; - -#if BOOST_WORKAROUND(__SUNPRO_CC, <= 0x580) || defined(__CUDACC__) - // Work around the following bogus error in Sun Studio 11, by - // turning off the has_constraints function entirely: - // Error: complex expression not allowed in dependent template - // argument expression - inline no has_constraints_(...); -#else - template - inline yes has_constraints_(Model*, wrap_constraints* = 0); - inline no has_constraints_(...); -#endif -} - -// This would be called "detail::has_constraints," but it has a strong -// tendency to show up in error messages. -template -struct not_satisfied -{ - BOOST_STATIC_CONSTANT( - bool - , value = sizeof( detail::has_constraints_((Model*)0) ) == sizeof(detail::yes) ); - typedef mpl::bool_ type; -}; - -}} // namespace boost::concepts::detail - -#endif // BOOST_CONCEPT_DETAIL_HAS_CONSTRAINTS_DWA2006429_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/msvc.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/detail/msvc.hpp deleted file mode 100644 index 9fbd2505..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/detail/msvc.hpp +++ /dev/null @@ -1,114 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_CHECK_MSVC_DWA2006429_HPP -# define BOOST_CONCEPT_CHECK_MSVC_DWA2006429_HPP - -# include -# include - -# ifdef BOOST_OLD_CONCEPT_SUPPORT -# include -# include -# endif - - -namespace boost { namespace concepts { - - -template -struct check -{ - virtual void failed(Model* x) - { - x->~Model(); - } -}; - -# ifndef BOOST_NO_PARTIAL_SPECIALIZATION -struct failed {}; -template -struct check -{ - virtual void failed(Model* x) - { - x->~Model(); - } -}; -# endif - -# ifdef BOOST_OLD_CONCEPT_SUPPORT - -namespace detail -{ - // No need for a virtual function here, since evaluating - // not_satisfied below will have already instantiated the - // constraints() member. - struct constraint {}; -} - -template -struct require - : mpl::if_c< - not_satisfied::value - , detail::constraint -# ifndef BOOST_NO_PARTIAL_SPECIALIZATION - , check -# else - , check -# endif - >::type -{}; - -# else - -template -struct require -# ifndef BOOST_NO_PARTIAL_SPECIALIZATION - : check -# else - : check -# endif -{}; - -# endif - -# if BOOST_WORKAROUND(BOOST_MSVC, == 1310) - -// -// The iterator library sees some really strange errors unless we -// do things this way. -// -template -struct require -{ - virtual void failed(Model*) - { - require(); - } -}; - -# define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ -enum \ -{ \ - BOOST_PP_CAT(boost_concept_check,__LINE__) = \ - sizeof(::boost::concepts::require) \ -} - -# else // Not vc-7.1 - -template -require -require_(void(*)(Model)); - -# define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ -enum \ -{ \ - BOOST_PP_CAT(boost_concept_check,__LINE__) = \ - sizeof(::boost::concepts::require_((ModelFnPtr)0)) \ -} - -# endif -}} - -#endif // BOOST_CONCEPT_CHECK_MSVC_DWA2006429_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept/usage.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept/usage.hpp deleted file mode 100644 index 21547c31..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept/usage.hpp +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright David Abrahams 2006. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_CONCEPT_USAGE_DWA2006919_HPP -# define BOOST_CONCEPT_USAGE_DWA2006919_HPP - -# include -# include -# include - -namespace boost { namespace concepts { - -# if BOOST_WORKAROUND(__GNUC__, == 2) - -# define BOOST_CONCEPT_USAGE(model) ~model() - -# else - -template -struct usage_requirements -{ - ~usage_requirements() { ((Model*)0)->~Model(); } -}; - -# if BOOST_WORKAROUND(__GNUC__, <= 3) - -# define BOOST_CONCEPT_USAGE(model) \ - model(); /* at least 2.96 and 3.4.3 both need this :( */ \ - BOOST_CONCEPT_ASSERT((boost::concepts::usage_requirements)); \ - ~model() - -# else - -# define BOOST_CONCEPT_USAGE(model) \ - BOOST_CONCEPT_ASSERT((boost::concepts::usage_requirements)); \ - ~model() - -# endif - -# endif - -}} // namespace boost::concepts - -#endif // BOOST_CONCEPT_USAGE_DWA2006919_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept_archetype.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept_archetype.hpp deleted file mode 100644 index f21c8173..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept_archetype.hpp +++ /dev/null @@ -1,669 +0,0 @@ -// -// (C) Copyright Jeremy Siek 2000. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Revision History: -// -// 17 July 2001: Added const to some member functions. (Jeremy Siek) -// 05 May 2001: Removed static dummy_cons object. (Jeremy Siek) - -// See http://www.boost.org/libs/concept_check for documentation. - -#ifndef BOOST_CONCEPT_ARCHETYPES_HPP -#define BOOST_CONCEPT_ARCHETYPES_HPP - -#include -#include -#include -#include - -namespace boost { - - //=========================================================================== - // Basic Archetype Classes - - namespace detail { - class dummy_constructor { }; - } - - // A type that models no concept. The template parameter - // is only there so that null_archetype types can be created - // that have different type. - template - class null_archetype { - private: - null_archetype() { } - null_archetype(const null_archetype&) { } - null_archetype& operator=(const null_archetype&) { return *this; } - public: - null_archetype(detail::dummy_constructor) { } -#ifndef __MWERKS__ - template - friend void dummy_friend(); // just to avoid warnings -#endif - }; - - // This is a helper class that provides a way to get a reference to - // an object. The get() function will never be called at run-time - // (nothing in this file will) so this seemingly very bad function - // is really quite innocent. The name of this class needs to be - // changed. - template - class static_object - { - public: - static T& get() - { -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) - return *reinterpret_cast(0); -#else - static char d[sizeof(T)]; - return *reinterpret_cast(d); -#endif - } - }; - - template > - class default_constructible_archetype : public Base { - public: - default_constructible_archetype() - : Base(static_object::get()) { } - default_constructible_archetype(detail::dummy_constructor x) : Base(x) { } - }; - - template > - class assignable_archetype : public Base { - assignable_archetype() { } - assignable_archetype(const assignable_archetype&) { } - public: - assignable_archetype& operator=(const assignable_archetype&) { - return *this; - } - assignable_archetype(detail::dummy_constructor x) : Base(x) { } - }; - - template > - class copy_constructible_archetype : public Base { - public: - copy_constructible_archetype() - : Base(static_object::get()) { } - copy_constructible_archetype(const copy_constructible_archetype&) - : Base(static_object::get()) { } - copy_constructible_archetype(detail::dummy_constructor x) : Base(x) { } - }; - - template > - class sgi_assignable_archetype : public Base { - public: - sgi_assignable_archetype(const sgi_assignable_archetype&) - : Base(static_object::get()) { } - sgi_assignable_archetype& operator=(const sgi_assignable_archetype&) { - return *this; - } - sgi_assignable_archetype(const detail::dummy_constructor& x) : Base(x) { } - }; - - struct default_archetype_base { - default_archetype_base(detail::dummy_constructor) { } - }; - - // Careful, don't use same type for T and Base. That results in the - // conversion operator being invalid. Since T is often - // null_archetype, can't use null_archetype for Base. - template - class convertible_to_archetype : public Base { - private: - convertible_to_archetype() { } - convertible_to_archetype(const convertible_to_archetype& ) { } - convertible_to_archetype& operator=(const convertible_to_archetype&) - { return *this; } - public: - convertible_to_archetype(detail::dummy_constructor x) : Base(x) { } - operator const T&() const { return static_object::get(); } - }; - - template - class convertible_from_archetype : public Base { - private: - convertible_from_archetype() { } - convertible_from_archetype(const convertible_from_archetype& ) { } - convertible_from_archetype& operator=(const convertible_from_archetype&) - { return *this; } - public: - convertible_from_archetype(detail::dummy_constructor x) : Base(x) { } - convertible_from_archetype(const T&) { } - convertible_from_archetype& operator=(const T&) - { return *this; } - }; - - class boolean_archetype { - public: - boolean_archetype(const boolean_archetype&) { } - operator bool() const { return true; } - boolean_archetype(detail::dummy_constructor) { } - private: - boolean_archetype() { } - boolean_archetype& operator=(const boolean_archetype&) { return *this; } - }; - - template > - class equality_comparable_archetype : public Base { - public: - equality_comparable_archetype(detail::dummy_constructor x) : Base(x) { } - }; - template - boolean_archetype - operator==(const equality_comparable_archetype&, - const equality_comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - template - boolean_archetype - operator!=(const equality_comparable_archetype&, - const equality_comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - - - template > - class equality_comparable2_first_archetype : public Base { - public: - equality_comparable2_first_archetype(detail::dummy_constructor x) - : Base(x) { } - }; - template > - class equality_comparable2_second_archetype : public Base { - public: - equality_comparable2_second_archetype(detail::dummy_constructor x) - : Base(x) { } - }; - template - boolean_archetype - operator==(const equality_comparable2_first_archetype&, - const equality_comparable2_second_archetype&) - { - return boolean_archetype(static_object::get()); - } - template - boolean_archetype - operator!=(const equality_comparable2_first_archetype&, - const equality_comparable2_second_archetype&) - { - return boolean_archetype(static_object::get()); - } - - - template > - class less_than_comparable_archetype : public Base { - public: - less_than_comparable_archetype(detail::dummy_constructor x) : Base(x) { } - }; - template - boolean_archetype - operator<(const less_than_comparable_archetype&, - const less_than_comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - - - - template > - class comparable_archetype : public Base { - public: - comparable_archetype(detail::dummy_constructor x) : Base(x) { } - }; - template - boolean_archetype - operator<(const comparable_archetype&, - const comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - template - boolean_archetype - operator<=(const comparable_archetype&, - const comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - template - boolean_archetype - operator>(const comparable_archetype&, - const comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - template - boolean_archetype - operator>=(const comparable_archetype&, - const comparable_archetype&) - { - return boolean_archetype(static_object::get()); - } - - - // The purpose of the optags is so that one can specify - // exactly which types the operator< is defined between. - // This is useful for allowing the operations: - // - // A a; B b; - // a < b - // b < a - // - // without also allowing the combinations: - // - // a < a - // b < b - // - struct optag1 { }; - struct optag2 { }; - struct optag3 { }; - -#define BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(OP, NAME) \ - template , class Tag = optag1 > \ - class NAME##_first_archetype : public Base { \ - public: \ - NAME##_first_archetype(detail::dummy_constructor x) : Base(x) { } \ - }; \ - \ - template , class Tag = optag1 > \ - class NAME##_second_archetype : public Base { \ - public: \ - NAME##_second_archetype(detail::dummy_constructor x) : Base(x) { } \ - }; \ - \ - template \ - boolean_archetype \ - operator OP (const NAME##_first_archetype&, \ - const NAME##_second_archetype&) \ - { \ - return boolean_archetype(static_object::get()); \ - } - - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(==, equal_op) - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(!=, not_equal_op) - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(<, less_than_op) - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(<=, less_equal_op) - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(>, greater_than_op) - BOOST_DEFINE_BINARY_PREDICATE_ARCHETYPE(>=, greater_equal_op) - -#define BOOST_DEFINE_OPERATOR_ARCHETYPE(OP, NAME) \ - template > \ - class NAME##_archetype : public Base { \ - public: \ - NAME##_archetype(detail::dummy_constructor x) : Base(x) { } \ - NAME##_archetype(const NAME##_archetype&) \ - : Base(static_object::get()) { } \ - NAME##_archetype& operator=(const NAME##_archetype&) { return *this; } \ - }; \ - template \ - NAME##_archetype \ - operator OP (const NAME##_archetype&,\ - const NAME##_archetype&) \ - { \ - return \ - NAME##_archetype(static_object::get()); \ - } - - BOOST_DEFINE_OPERATOR_ARCHETYPE(+, addable) - BOOST_DEFINE_OPERATOR_ARCHETYPE(-, subtractable) - BOOST_DEFINE_OPERATOR_ARCHETYPE(*, multipliable) - BOOST_DEFINE_OPERATOR_ARCHETYPE(/, dividable) - BOOST_DEFINE_OPERATOR_ARCHETYPE(%, modable) - - // As is, these are useless because of the return type. - // Need to invent a better way... -#define BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(OP, NAME) \ - template > \ - class NAME##_first_archetype : public Base { \ - public: \ - NAME##_first_archetype(detail::dummy_constructor x) : Base(x) { } \ - }; \ - \ - template > \ - class NAME##_second_archetype : public Base { \ - public: \ - NAME##_second_archetype(detail::dummy_constructor x) : Base(x) { } \ - }; \ - \ - template \ - Return \ - operator OP (const NAME##_first_archetype&, \ - const NAME##_second_archetype&) \ - { \ - return Return(static_object::get()); \ - } - - BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(+, plus_op) - BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(*, time_op) - BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(/, divide_op) - BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(-, subtract_op) - BOOST_DEFINE_BINARY_OPERATOR_ARCHETYPE(%, mod_op) - - //=========================================================================== - // Function Object Archetype Classes - - template - class generator_archetype { - public: - const Return& operator()() { - return static_object::get(); - } - }; - - class void_generator_archetype { - public: - void operator()() { } - }; - - template - class unary_function_archetype { - private: - unary_function_archetype() { } - public: - unary_function_archetype(detail::dummy_constructor) { } - const Return& operator()(const Arg&) const { - return static_object::get(); - } - }; - - template - class binary_function_archetype { - private: - binary_function_archetype() { } - public: - binary_function_archetype(detail::dummy_constructor) { } - const Return& operator()(const Arg1&, const Arg2&) const { - return static_object::get(); - } - }; - - template - class unary_predicate_archetype { - typedef boolean_archetype Return; - unary_predicate_archetype() { } - public: - unary_predicate_archetype(detail::dummy_constructor) { } - const Return& operator()(const Arg&) const { - return static_object::get(); - } - }; - - template > - class binary_predicate_archetype { - typedef boolean_archetype Return; - binary_predicate_archetype() { } - public: - binary_predicate_archetype(detail::dummy_constructor) { } - const Return& operator()(const Arg1&, const Arg2&) const { - return static_object::get(); - } - }; - - //=========================================================================== - // Iterator Archetype Classes - - template - class input_iterator_archetype - { - private: - typedef input_iterator_archetype self; - public: - typedef std::input_iterator_tag iterator_category; - typedef T value_type; - struct reference { - operator const value_type&() const { return static_object::get(); } - }; - typedef const T* pointer; - typedef std::ptrdiff_t difference_type; - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return reference(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - }; - - template - class input_iterator_archetype_no_proxy - { - private: - typedef input_iterator_archetype_no_proxy self; - public: - typedef std::input_iterator_tag iterator_category; - typedef T value_type; - typedef const T& reference; - typedef const T* pointer; - typedef std::ptrdiff_t difference_type; - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - }; - - template - struct output_proxy { - output_proxy& operator=(const T&) { return *this; } - }; - - template - class output_iterator_archetype - { - public: - typedef output_iterator_archetype self; - public: - typedef std::output_iterator_tag iterator_category; - typedef output_proxy value_type; - typedef output_proxy reference; - typedef void pointer; - typedef void difference_type; - output_iterator_archetype(detail::dummy_constructor) { } - output_iterator_archetype(const self&) { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return output_proxy(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - private: - output_iterator_archetype() { } - }; - - template - class input_output_iterator_archetype - { - private: - typedef input_output_iterator_archetype self; - struct in_out_tag : public std::input_iterator_tag, public std::output_iterator_tag { }; - public: - typedef in_out_tag iterator_category; - typedef T value_type; - struct reference { - reference& operator=(const T&) { return *this; } - operator value_type() { return static_object::get(); } - }; - typedef const T* pointer; - typedef std::ptrdiff_t difference_type; - input_output_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return reference(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - }; - - template - class forward_iterator_archetype - { - public: - typedef forward_iterator_archetype self; - public: - typedef std::forward_iterator_tag iterator_category; - typedef T value_type; - typedef const T& reference; - typedef T const* pointer; - typedef std::ptrdiff_t difference_type; - forward_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - }; - - template - class mutable_forward_iterator_archetype - { - public: - typedef mutable_forward_iterator_archetype self; - public: - typedef std::forward_iterator_tag iterator_category; - typedef T value_type; - typedef T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - mutable_forward_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - }; - - template - class bidirectional_iterator_archetype - { - public: - typedef bidirectional_iterator_archetype self; - public: - typedef std::bidirectional_iterator_tag iterator_category; - typedef T value_type; - typedef const T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - bidirectional_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - self& operator--() { return *this; } - self operator--(int) { return *this; } - }; - - template - class mutable_bidirectional_iterator_archetype - { - public: - typedef mutable_bidirectional_iterator_archetype self; - public: - typedef std::bidirectional_iterator_tag iterator_category; - typedef T value_type; - typedef T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - mutable_bidirectional_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - self& operator--() { return *this; } - self operator--(int) { return *this; } - }; - - template - class random_access_iterator_archetype - { - public: - typedef random_access_iterator_archetype self; - public: - typedef std::random_access_iterator_tag iterator_category; - typedef T value_type; - typedef const T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - random_access_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - self& operator--() { return *this; } - self operator--(int) { return *this; } - reference operator[](difference_type) const - { return static_object::get(); } - self& operator+=(difference_type) { return *this; } - self& operator-=(difference_type) { return *this; } - difference_type operator-(const self&) const - { return difference_type(); } - self operator+(difference_type) const { return *this; } - self operator-(difference_type) const { return *this; } - bool operator<(const self&) const { return true; } - bool operator<=(const self&) const { return true; } - bool operator>(const self&) const { return true; } - bool operator>=(const self&) const { return true; } - }; - template - random_access_iterator_archetype - operator+(typename random_access_iterator_archetype::difference_type, - const random_access_iterator_archetype& x) - { return x; } - - - template - class mutable_random_access_iterator_archetype - { - public: - typedef mutable_random_access_iterator_archetype self; - public: - typedef std::random_access_iterator_tag iterator_category; - typedef T value_type; - typedef T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - mutable_random_access_iterator_archetype() { } - self& operator=(const self&) { return *this; } - bool operator==(const self&) const { return true; } - bool operator!=(const self&) const { return true; } - reference operator*() const { return static_object::get(); } - self& operator++() { return *this; } - self operator++(int) { return *this; } - self& operator--() { return *this; } - self operator--(int) { return *this; } - reference operator[](difference_type) const - { return static_object::get(); } - self& operator+=(difference_type) { return *this; } - self& operator-=(difference_type) { return *this; } - difference_type operator-(const self&) const - { return difference_type(); } - self operator+(difference_type) const { return *this; } - self operator-(difference_type) const { return *this; } - bool operator<(const self&) const { return true; } - bool operator<=(const self&) const { return true; } - bool operator>(const self&) const { return true; } - bool operator>=(const self&) const { return true; } - }; - template - mutable_random_access_iterator_archetype - operator+ - (typename mutable_random_access_iterator_archetype::difference_type, - const mutable_random_access_iterator_archetype& x) - { return x; } - -} // namespace boost - -#endif // BOOST_CONCEPT_ARCHETYPES_H diff --git a/third_party/ycmd/cpp/BoostParts/boost/concept_check.hpp b/third_party/ycmd/cpp/BoostParts/boost/concept_check.hpp deleted file mode 100644 index bf5a2af7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/concept_check.hpp +++ /dev/null @@ -1,1083 +0,0 @@ -// -// (C) Copyright Jeremy Siek 2000. -// Copyright 2002 The Trustees of Indiana University. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Revision History: -// 05 May 2001: Workarounds for HP aCC from Thomas Matelich. (Jeremy Siek) -// 02 April 2001: Removed limits header altogether. (Jeremy Siek) -// 01 April 2001: Modified to use new header. (JMaddock) -// - -// See http://www.boost.org/libs/concept_check for documentation. - -#ifndef BOOST_CONCEPT_CHECKS_HPP -# define BOOST_CONCEPT_CHECKS_HPP - -# include - -# include -# include -# include -# include -# include -# include -# include -# include -# include - -# include -# include - -namespace boost -{ - - // - // Backward compatibility - // - - template - inline void function_requires(Model* = 0) - { - BOOST_CONCEPT_ASSERT((Model)); - } - template inline void ignore_unused_variable_warning(T const&) {} - -# define BOOST_CLASS_REQUIRE(type_var, ns, concept) \ - BOOST_CONCEPT_ASSERT((ns::concept)) - -# define BOOST_CLASS_REQUIRE2(type_var1, type_var2, ns, concept) \ - BOOST_CONCEPT_ASSERT((ns::concept)) - -# define BOOST_CLASS_REQUIRE3(tv1, tv2, tv3, ns, concept) \ - BOOST_CONCEPT_ASSERT((ns::concept)) - -# define BOOST_CLASS_REQUIRE4(tv1, tv2, tv3, tv4, ns, concept) \ - BOOST_CONCEPT_ASSERT((ns::concept)) - - - // - // Begin concept definitions - // - BOOST_concept(Integer, (T)) - { - BOOST_CONCEPT_USAGE(Integer) - { - x.error_type_must_be_an_integer_type(); - } - private: - T x; - }; - - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; - template <> struct Integer {}; -# if defined(BOOST_HAS_LONG_LONG) - template <> struct Integer< ::boost::long_long_type> {}; - template <> struct Integer< ::boost::ulong_long_type> {}; -# elif defined(BOOST_HAS_MS_INT64) - template <> struct Integer<__int64> {}; - template <> struct Integer {}; -# endif - - BOOST_concept(SignedInteger,(T)) { - BOOST_CONCEPT_USAGE(SignedInteger) { - x.error_type_must_be_a_signed_integer_type(); - } - private: - T x; - }; - template <> struct SignedInteger { }; - template <> struct SignedInteger {}; - template <> struct SignedInteger {}; - template <> struct SignedInteger {}; -# if defined(BOOST_HAS_LONG_LONG) - template <> struct SignedInteger< ::boost::long_long_type> {}; -# elif defined(BOOST_HAS_MS_INT64) - template <> struct SignedInteger<__int64> {}; -# endif - - BOOST_concept(UnsignedInteger,(T)) { - BOOST_CONCEPT_USAGE(UnsignedInteger) { - x.error_type_must_be_an_unsigned_integer_type(); - } - private: - T x; - }; - - template <> struct UnsignedInteger {}; - template <> struct UnsignedInteger {}; - template <> struct UnsignedInteger {}; - template <> struct UnsignedInteger {}; -# if defined(BOOST_HAS_LONG_LONG) - template <> struct UnsignedInteger< ::boost::ulong_long_type> {}; -# elif defined(BOOST_HAS_MS_INT64) - template <> struct UnsignedInteger {}; -# endif - - //=========================================================================== - // Basic Concepts - - BOOST_concept(DefaultConstructible,(TT)) - { - BOOST_CONCEPT_USAGE(DefaultConstructible) { - TT a; // require default constructor - ignore_unused_variable_warning(a); - } - }; - - BOOST_concept(Assignable,(TT)) - { - BOOST_CONCEPT_USAGE(Assignable) { -#if !defined(_ITERATOR_) // back_insert_iterator broken for VC++ STL - a = b; // require assignment operator -#endif - const_constraints(b); - } - private: - void const_constraints(const TT& x) { -#if !defined(_ITERATOR_) // back_insert_iterator broken for VC++ STL - a = x; // const required for argument to assignment -#else - ignore_unused_variable_warning(x); -#endif - } - private: - TT a; - TT b; - }; - - - BOOST_concept(CopyConstructible,(TT)) - { - BOOST_CONCEPT_USAGE(CopyConstructible) { - TT a(b); // require copy constructor - TT* ptr = &a; // require address of operator - const_constraints(a); - ignore_unused_variable_warning(ptr); - } - private: - void const_constraints(const TT& a) { - TT c(a); // require const copy constructor - const TT* ptr = &a; // require const address of operator - ignore_unused_variable_warning(c); - ignore_unused_variable_warning(ptr); - } - TT b; - }; - -#if (defined _MSC_VER) -# pragma warning( push ) -# pragma warning( disable : 4510 ) // default constructor could not be generated -# pragma warning( disable : 4610 ) // object 'class' can never be instantiated - user-defined constructor required -#endif - // The SGI STL version of Assignable requires copy constructor and operator= - BOOST_concept(SGIAssignable,(TT)) - { - BOOST_CONCEPT_USAGE(SGIAssignable) { - TT c(a); -#if !defined(_ITERATOR_) // back_insert_iterator broken for VC++ STL - a = b; // require assignment operator -#endif - const_constraints(b); - ignore_unused_variable_warning(c); - } - private: - void const_constraints(const TT& x) { - TT c(x); -#if !defined(_ITERATOR_) // back_insert_iterator broken for VC++ STL - a = x; // const required for argument to assignment -#endif - ignore_unused_variable_warning(c); - } - TT a; - TT b; - }; -#if (defined _MSC_VER) -# pragma warning( pop ) -#endif - - BOOST_concept(Convertible,(X)(Y)) - { - BOOST_CONCEPT_USAGE(Convertible) { - Y y = x; - ignore_unused_variable_warning(y); - } - private: - X x; - }; - - // The C++ standard requirements for many concepts talk about return - // types that must be "convertible to bool". The problem with this - // requirement is that it leaves the door open for evil proxies that - // define things like operator|| with strange return types. Two - // possible solutions are: - // 1) require the return type to be exactly bool - // 2) stay with convertible to bool, and also - // specify stuff about all the logical operators. - // For now we just test for convertible to bool. - template - void require_boolean_expr(const TT& t) { - bool x = t; - ignore_unused_variable_warning(x); - } - - BOOST_concept(EqualityComparable,(TT)) - { - BOOST_CONCEPT_USAGE(EqualityComparable) { - require_boolean_expr(a == b); - require_boolean_expr(a != b); - } - private: - TT a, b; - }; - - BOOST_concept(LessThanComparable,(TT)) - { - BOOST_CONCEPT_USAGE(LessThanComparable) { - require_boolean_expr(a < b); - } - private: - TT a, b; - }; - - // This is equivalent to SGI STL's LessThanComparable. - BOOST_concept(Comparable,(TT)) - { - BOOST_CONCEPT_USAGE(Comparable) { - require_boolean_expr(a < b); - require_boolean_expr(a > b); - require_boolean_expr(a <= b); - require_boolean_expr(a >= b); - } - private: - TT a, b; - }; - -#define BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(OP,NAME) \ - BOOST_concept(NAME, (First)(Second)) \ - { \ - BOOST_CONCEPT_USAGE(NAME) { (void)constraints_(); } \ - private: \ - bool constraints_() { return a OP b; } \ - First a; \ - Second b; \ - } - -#define BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(OP,NAME) \ - BOOST_concept(NAME, (Ret)(First)(Second)) \ - { \ - BOOST_CONCEPT_USAGE(NAME) { (void)constraints_(); } \ - private: \ - Ret constraints_() { return a OP b; } \ - First a; \ - Second b; \ - } - - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(==, EqualOp); - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(!=, NotEqualOp); - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(<, LessThanOp); - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(<=, LessEqualOp); - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(>, GreaterThanOp); - BOOST_DEFINE_BINARY_PREDICATE_OP_CONSTRAINT(>=, GreaterEqualOp); - - BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(+, PlusOp); - BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(*, TimesOp); - BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(/, DivideOp); - BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(-, SubtractOp); - BOOST_DEFINE_BINARY_OPERATOR_CONSTRAINT(%, ModOp); - - //=========================================================================== - // Function Object Concepts - - BOOST_concept(Generator,(Func)(Return)) - { - BOOST_CONCEPT_USAGE(Generator) { test(is_void()); } - - private: - void test(boost::mpl::false_) - { - // Do we really want a reference here? - const Return& r = f(); - ignore_unused_variable_warning(r); - } - - void test(boost::mpl::true_) - { - f(); - } - - Func f; - }; - - BOOST_concept(UnaryFunction,(Func)(Return)(Arg)) - { - BOOST_CONCEPT_USAGE(UnaryFunction) { test(is_void()); } - - private: - void test(boost::mpl::false_) - { - f(arg); // "priming the pump" this way keeps msvc6 happy (ICE) - Return r = f(arg); - ignore_unused_variable_warning(r); - } - - void test(boost::mpl::true_) - { - f(arg); - } - -#if (BOOST_WORKAROUND(__GNUC__, BOOST_TESTED_AT(4) \ - && BOOST_WORKAROUND(__GNUC__, > 3))) - // Declare a dummy construktor to make gcc happy. - // It seems the compiler can not generate a sensible constructor when this is instantiated with a refence type. - // (warning: non-static reference "const double& boost::UnaryFunction::arg" - // in class without a constructor [-Wuninitialized]) - UnaryFunction(); -#endif - - Func f; - Arg arg; - }; - - BOOST_concept(BinaryFunction,(Func)(Return)(First)(Second)) - { - BOOST_CONCEPT_USAGE(BinaryFunction) { test(is_void()); } - private: - void test(boost::mpl::false_) - { - f(first,second); - Return r = f(first, second); // require operator() - (void)r; - } - - void test(boost::mpl::true_) - { - f(first,second); - } - -#if (BOOST_WORKAROUND(__GNUC__, BOOST_TESTED_AT(4) \ - && BOOST_WORKAROUND(__GNUC__, > 3))) - // Declare a dummy constructor to make gcc happy. - // It seems the compiler can not generate a sensible constructor when this is instantiated with a refence type. - // (warning: non-static reference "const double& boost::BinaryFunction::arg" - // in class without a constructor [-Wuninitialized]) - BinaryFunction(); -#endif - - Func f; - First first; - Second second; - }; - - BOOST_concept(UnaryPredicate,(Func)(Arg)) - { - BOOST_CONCEPT_USAGE(UnaryPredicate) { - require_boolean_expr(f(arg)); // require operator() returning bool - } - private: -#if (BOOST_WORKAROUND(__GNUC__, BOOST_TESTED_AT(4) \ - && BOOST_WORKAROUND(__GNUC__, > 3))) - // Declare a dummy constructor to make gcc happy. - // It seems the compiler can not generate a sensible constructor when this is instantiated with a refence type. - // (warning: non-static reference "const double& boost::UnaryPredicate::arg" - // in class without a constructor [-Wuninitialized]) - UnaryPredicate(); -#endif - - Func f; - Arg arg; - }; - - BOOST_concept(BinaryPredicate,(Func)(First)(Second)) - { - BOOST_CONCEPT_USAGE(BinaryPredicate) { - require_boolean_expr(f(a, b)); // require operator() returning bool - } - private: -#if (BOOST_WORKAROUND(__GNUC__, BOOST_TESTED_AT(4) \ - && BOOST_WORKAROUND(__GNUC__, > 3))) - // Declare a dummy constructor to make gcc happy. - // It seems the compiler can not generate a sensible constructor when this is instantiated with a refence type. - // (warning: non-static reference "const double& boost::BinaryPredicate::arg" - // in class without a constructor [-Wuninitialized]) - BinaryPredicate(); -#endif - Func f; - First a; - Second b; - }; - - // use this when functor is used inside a container class like std::set - BOOST_concept(Const_BinaryPredicate,(Func)(First)(Second)) - : BinaryPredicate - { - BOOST_CONCEPT_USAGE(Const_BinaryPredicate) { - const_constraints(f); - } - private: - void const_constraints(const Func& fun) { - // operator() must be a const member function - require_boolean_expr(fun(a, b)); - } -#if (BOOST_WORKAROUND(__GNUC__, BOOST_TESTED_AT(4) \ - && BOOST_WORKAROUND(__GNUC__, > 3))) - // Declare a dummy constructor to make gcc happy. - // It seems the compiler can not generate a sensible constructor when this is instantiated with a refence type. - // (warning: non-static reference "const double& boost::Const_BinaryPredicate::arg" - // in class without a constructor [-Wuninitialized]) - Const_BinaryPredicate(); -#endif - - Func f; - First a; - Second b; - }; - - BOOST_concept(AdaptableGenerator,(Func)(Return)) - : Generator - { - typedef typename Func::result_type result_type; - - BOOST_CONCEPT_USAGE(AdaptableGenerator) - { - BOOST_CONCEPT_ASSERT((Convertible)); - } - }; - - BOOST_concept(AdaptableUnaryFunction,(Func)(Return)(Arg)) - : UnaryFunction - { - typedef typename Func::argument_type argument_type; - typedef typename Func::result_type result_type; - - ~AdaptableUnaryFunction() - { - BOOST_CONCEPT_ASSERT((Convertible)); - BOOST_CONCEPT_ASSERT((Convertible)); - } - }; - - BOOST_concept(AdaptableBinaryFunction,(Func)(Return)(First)(Second)) - : BinaryFunction< - Func - , typename Func::result_type - , typename Func::first_argument_type - , typename Func::second_argument_type - > - { - typedef typename Func::first_argument_type first_argument_type; - typedef typename Func::second_argument_type second_argument_type; - typedef typename Func::result_type result_type; - - ~AdaptableBinaryFunction() - { - BOOST_CONCEPT_ASSERT((Convertible)); - BOOST_CONCEPT_ASSERT((Convertible)); - BOOST_CONCEPT_ASSERT((Convertible)); - } - }; - - BOOST_concept(AdaptablePredicate,(Func)(Arg)) - : UnaryPredicate - , AdaptableUnaryFunction - { - }; - - BOOST_concept(AdaptableBinaryPredicate,(Func)(First)(Second)) - : BinaryPredicate - , AdaptableBinaryFunction - { - }; - - //=========================================================================== - // Iterator Concepts - - BOOST_concept(InputIterator,(TT)) - : Assignable - , EqualityComparable - { - typedef typename boost::detail::iterator_traits::value_type value_type; - typedef typename boost::detail::iterator_traits::difference_type difference_type; - typedef typename boost::detail::iterator_traits::reference reference; - typedef typename boost::detail::iterator_traits::pointer pointer; - typedef typename boost::detail::iterator_traits::iterator_category iterator_category; - - BOOST_CONCEPT_USAGE(InputIterator) - { - BOOST_CONCEPT_ASSERT((SignedInteger)); - BOOST_CONCEPT_ASSERT((Convertible)); - - TT j(i); - (void)*i; // require dereference operator - ++j; // require preincrement operator - i++; // require postincrement operator - } - private: - TT i; - }; - - BOOST_concept(OutputIterator,(TT)(ValueT)) - : Assignable - { - BOOST_CONCEPT_USAGE(OutputIterator) { - - ++i; // require preincrement operator - i++; // require postincrement operator - *i++ = t; // require postincrement and assignment - } - private: - TT i, j; - ValueT t; - }; - - BOOST_concept(ForwardIterator,(TT)) - : InputIterator - { - BOOST_CONCEPT_USAGE(ForwardIterator) - { - BOOST_CONCEPT_ASSERT((Convertible< - BOOST_DEDUCED_TYPENAME ForwardIterator::iterator_category - , std::forward_iterator_tag - >)); - - typename InputIterator::reference r = *i; - ignore_unused_variable_warning(r); - } - - private: - TT i; - }; - - BOOST_concept(Mutable_ForwardIterator,(TT)) - : ForwardIterator - { - BOOST_CONCEPT_USAGE(Mutable_ForwardIterator) { - *i++ = *i; // require postincrement and assignment - } - private: - TT i; - }; - - BOOST_concept(BidirectionalIterator,(TT)) - : ForwardIterator - { - BOOST_CONCEPT_USAGE(BidirectionalIterator) - { - BOOST_CONCEPT_ASSERT((Convertible< - BOOST_DEDUCED_TYPENAME BidirectionalIterator::iterator_category - , std::bidirectional_iterator_tag - >)); - - --i; // require predecrement operator - i--; // require postdecrement operator - } - private: - TT i; - }; - - BOOST_concept(Mutable_BidirectionalIterator,(TT)) - : BidirectionalIterator - , Mutable_ForwardIterator - { - BOOST_CONCEPT_USAGE(Mutable_BidirectionalIterator) - { - *i-- = *i; // require postdecrement and assignment - } - private: - TT i; - }; - - BOOST_concept(RandomAccessIterator,(TT)) - : BidirectionalIterator - , Comparable - { - BOOST_CONCEPT_USAGE(RandomAccessIterator) - { - BOOST_CONCEPT_ASSERT((Convertible< - BOOST_DEDUCED_TYPENAME BidirectionalIterator::iterator_category - , std::random_access_iterator_tag - >)); - - i += n; // require assignment addition operator - i = i + n; i = n + i; // require addition with difference type - i -= n; // require assignment subtraction operator - i = i - n; // require subtraction with difference type - n = i - j; // require difference operator - (void)i[n]; // require element access operator - } - - private: - TT a, b; - TT i, j; - typename boost::detail::iterator_traits::difference_type n; - }; - - BOOST_concept(Mutable_RandomAccessIterator,(TT)) - : RandomAccessIterator - , Mutable_BidirectionalIterator - { - BOOST_CONCEPT_USAGE(Mutable_RandomAccessIterator) - { - i[n] = *i; // require element access and assignment - } - private: - TT i; - typename boost::detail::iterator_traits::difference_type n; - }; - - //=========================================================================== - // Container s - - BOOST_concept(Container,(C)) - : Assignable - { - typedef typename C::value_type value_type; - typedef typename C::difference_type difference_type; - typedef typename C::size_type size_type; - typedef typename C::const_reference const_reference; - typedef typename C::const_pointer const_pointer; - typedef typename C::const_iterator const_iterator; - - BOOST_CONCEPT_USAGE(Container) - { - BOOST_CONCEPT_ASSERT((InputIterator)); - const_constraints(c); - } - - private: - void const_constraints(const C& cc) { - i = cc.begin(); - i = cc.end(); - n = cc.size(); - n = cc.max_size(); - b = cc.empty(); - } - C c; - bool b; - const_iterator i; - size_type n; - }; - - BOOST_concept(Mutable_Container,(C)) - : Container - { - typedef typename C::reference reference; - typedef typename C::iterator iterator; - typedef typename C::pointer pointer; - - BOOST_CONCEPT_USAGE(Mutable_Container) - { - BOOST_CONCEPT_ASSERT(( - Assignable)); - - BOOST_CONCEPT_ASSERT((InputIterator)); - - i = c.begin(); - i = c.end(); - c.swap(c2); - } - - private: - iterator i; - C c, c2; - }; - - BOOST_concept(ForwardContainer,(C)) - : Container - { - BOOST_CONCEPT_USAGE(ForwardContainer) - { - BOOST_CONCEPT_ASSERT(( - ForwardIterator< - typename ForwardContainer::const_iterator - >)); - } - }; - - BOOST_concept(Mutable_ForwardContainer,(C)) - : ForwardContainer - , Mutable_Container - { - BOOST_CONCEPT_USAGE(Mutable_ForwardContainer) - { - BOOST_CONCEPT_ASSERT(( - Mutable_ForwardIterator< - typename Mutable_ForwardContainer::iterator - >)); - } - }; - - BOOST_concept(ReversibleContainer,(C)) - : ForwardContainer - { - typedef typename - C::const_reverse_iterator - const_reverse_iterator; - - BOOST_CONCEPT_USAGE(ReversibleContainer) - { - BOOST_CONCEPT_ASSERT(( - BidirectionalIterator< - typename ReversibleContainer::const_iterator>)); - - BOOST_CONCEPT_ASSERT((BidirectionalIterator)); - - const_constraints(c); - } - private: - void const_constraints(const C& cc) - { - const_reverse_iterator i = cc.rbegin(); - i = cc.rend(); - } - C c; - }; - - BOOST_concept(Mutable_ReversibleContainer,(C)) - : Mutable_ForwardContainer - , ReversibleContainer - { - typedef typename C::reverse_iterator reverse_iterator; - - BOOST_CONCEPT_USAGE(Mutable_ReversibleContainer) - { - typedef typename Mutable_ForwardContainer::iterator iterator; - BOOST_CONCEPT_ASSERT((Mutable_BidirectionalIterator)); - BOOST_CONCEPT_ASSERT((Mutable_BidirectionalIterator)); - - reverse_iterator i = c.rbegin(); - i = c.rend(); - } - private: - C c; - }; - - BOOST_concept(RandomAccessContainer,(C)) - : ReversibleContainer - { - typedef typename C::size_type size_type; - typedef typename C::const_reference const_reference; - - BOOST_CONCEPT_USAGE(RandomAccessContainer) - { - BOOST_CONCEPT_ASSERT(( - RandomAccessIterator< - typename RandomAccessContainer::const_iterator - >)); - - const_constraints(c); - } - private: - void const_constraints(const C& cc) - { - const_reference r = cc[n]; - ignore_unused_variable_warning(r); - } - - C c; - size_type n; - }; - - BOOST_concept(Mutable_RandomAccessContainer,(C)) - : Mutable_ReversibleContainer - , RandomAccessContainer - { - private: - typedef Mutable_RandomAccessContainer self; - public: - BOOST_CONCEPT_USAGE(Mutable_RandomAccessContainer) - { - BOOST_CONCEPT_ASSERT((Mutable_RandomAccessIterator)); - BOOST_CONCEPT_ASSERT((Mutable_RandomAccessIterator)); - - typename self::reference r = c[i]; - ignore_unused_variable_warning(r); - } - - private: - typename Mutable_ReversibleContainer::size_type i; - C c; - }; - - // A Sequence is inherently mutable - BOOST_concept(Sequence,(S)) - : Mutable_ForwardContainer - // Matt Austern's book puts DefaultConstructible here, the C++ - // standard places it in Container --JGS - // ... so why aren't we following the standard? --DWA - , DefaultConstructible - { - BOOST_CONCEPT_USAGE(Sequence) - { - S - c(n), - c2(n, t), - c3(first, last); - - c.insert(p, t); - c.insert(p, n, t); - c.insert(p, first, last); - - c.erase(p); - c.erase(p, q); - - typename Sequence::reference r = c.front(); - - ignore_unused_variable_warning(c); - ignore_unused_variable_warning(c2); - ignore_unused_variable_warning(c3); - ignore_unused_variable_warning(r); - const_constraints(c); - } - private: - void const_constraints(const S& c) { - typename Sequence::const_reference r = c.front(); - ignore_unused_variable_warning(r); - } - - typename S::value_type t; - typename S::size_type n; - typename S::value_type* first, *last; - typename S::iterator p, q; - }; - - BOOST_concept(FrontInsertionSequence,(S)) - : Sequence - { - BOOST_CONCEPT_USAGE(FrontInsertionSequence) - { - c.push_front(t); - c.pop_front(); - } - private: - S c; - typename S::value_type t; - }; - - BOOST_concept(BackInsertionSequence,(S)) - : Sequence - { - BOOST_CONCEPT_USAGE(BackInsertionSequence) - { - c.push_back(t); - c.pop_back(); - typename BackInsertionSequence::reference r = c.back(); - ignore_unused_variable_warning(r); - const_constraints(c); - } - private: - void const_constraints(const S& cc) { - typename BackInsertionSequence::const_reference - r = cc.back(); - ignore_unused_variable_warning(r); - }; - S c; - typename S::value_type t; - }; - - BOOST_concept(AssociativeContainer,(C)) - : ForwardContainer - , DefaultConstructible - { - typedef typename C::key_type key_type; - typedef typename C::key_compare key_compare; - typedef typename C::value_compare value_compare; - typedef typename C::iterator iterator; - - BOOST_CONCEPT_USAGE(AssociativeContainer) - { - i = c.find(k); - r = c.equal_range(k); - c.erase(k); - c.erase(i); - c.erase(r.first, r.second); - const_constraints(c); - BOOST_CONCEPT_ASSERT((BinaryPredicate)); - - typedef typename AssociativeContainer::value_type value_type_; - BOOST_CONCEPT_ASSERT((BinaryPredicate)); - } - - // Redundant with the base concept, but it helps below. - typedef typename C::const_iterator const_iterator; - private: - void const_constraints(const C& cc) - { - ci = cc.find(k); - n = cc.count(k); - cr = cc.equal_range(k); - } - - C c; - iterator i; - std::pair r; - const_iterator ci; - std::pair cr; - typename C::key_type k; - typename C::size_type n; - }; - - BOOST_concept(UniqueAssociativeContainer,(C)) - : AssociativeContainer - { - BOOST_CONCEPT_USAGE(UniqueAssociativeContainer) - { - C c(first, last); - - pos_flag = c.insert(t); - c.insert(first, last); - - ignore_unused_variable_warning(c); - } - private: - std::pair pos_flag; - typename C::value_type t; - typename C::value_type* first, *last; - }; - - BOOST_concept(MultipleAssociativeContainer,(C)) - : AssociativeContainer - { - BOOST_CONCEPT_USAGE(MultipleAssociativeContainer) - { - C c(first, last); - - pos = c.insert(t); - c.insert(first, last); - - ignore_unused_variable_warning(c); - ignore_unused_variable_warning(pos); - } - private: - typename C::iterator pos; - typename C::value_type t; - typename C::value_type* first, *last; - }; - - BOOST_concept(SimpleAssociativeContainer,(C)) - : AssociativeContainer - { - BOOST_CONCEPT_USAGE(SimpleAssociativeContainer) - { - typedef typename C::key_type key_type; - typedef typename C::value_type value_type; - BOOST_MPL_ASSERT((boost::is_same)); - } - }; - - BOOST_concept(PairAssociativeContainer,(C)) - : AssociativeContainer - { - BOOST_CONCEPT_USAGE(PairAssociativeContainer) - { - typedef typename C::key_type key_type; - typedef typename C::value_type value_type; - typedef typename C::mapped_type mapped_type; - typedef std::pair required_value_type; - BOOST_MPL_ASSERT((boost::is_same)); - } - }; - - BOOST_concept(SortedAssociativeContainer,(C)) - : AssociativeContainer - , ReversibleContainer - { - BOOST_CONCEPT_USAGE(SortedAssociativeContainer) - { - C - c(kc), - c2(first, last), - c3(first, last, kc); - - p = c.upper_bound(k); - p = c.lower_bound(k); - r = c.equal_range(k); - - c.insert(p, t); - - ignore_unused_variable_warning(c); - ignore_unused_variable_warning(c2); - ignore_unused_variable_warning(c3); - const_constraints(c); - } - - void const_constraints(const C& c) - { - kc = c.key_comp(); - vc = c.value_comp(); - - cp = c.upper_bound(k); - cp = c.lower_bound(k); - cr = c.equal_range(k); - } - - private: - typename C::key_compare kc; - typename C::value_compare vc; - typename C::value_type t; - typename C::key_type k; - typedef typename C::iterator iterator; - typedef typename C::const_iterator const_iterator; - - typedef SortedAssociativeContainer self; - iterator p; - const_iterator cp; - std::pair r; - std::pair cr; - typename C::value_type* first, *last; - }; - - // HashedAssociativeContainer - - BOOST_concept(Collection,(C)) - { - BOOST_CONCEPT_USAGE(Collection) - { - boost::function_requires >(); - boost::function_requires >(); - boost::function_requires >(); - const_constraints(c); - i = c.begin(); - i = c.end(); - c.swap(c); - } - - void const_constraints(const C& cc) { - ci = cc.begin(); - ci = cc.end(); - n = cc.size(); - b = cc.empty(); - } - - private: - typedef typename C::value_type value_type; - typedef typename C::iterator iterator; - typedef typename C::const_iterator const_iterator; - typedef typename C::reference reference; - typedef typename C::const_reference const_reference; - // typedef typename C::pointer pointer; - typedef typename C::difference_type difference_type; - typedef typename C::size_type size_type; - - C c; - bool b; - iterator i; - const_iterator ci; - size_type n; - }; -} // namespace boost - -# include - -#endif // BOOST_CONCEPT_CHECKS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/config.hpp deleted file mode 100644 index 6ec3645c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config.hpp +++ /dev/null @@ -1,63 +0,0 @@ -// Boost config.hpp configuration header file ------------------------------// - -// (C) Copyright John Maddock 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/config for most recent version. - -// Boost config.hpp policy and rationale documentation has been moved to -// http://www.boost.org/libs/config -// -// CAUTION: This file is intended to be completely stable - -// DO NOT MODIFY THIS FILE! -// - -#ifndef BOOST_CONFIG_HPP -#define BOOST_CONFIG_HPP - -// if we don't have a user config, then use the default location: -#if !defined(BOOST_USER_CONFIG) && !defined(BOOST_NO_USER_CONFIG) -# define BOOST_USER_CONFIG -#endif -// include it first: -#ifdef BOOST_USER_CONFIG -# include BOOST_USER_CONFIG -#endif - -// if we don't have a compiler config set, try and find one: -#if !defined(BOOST_COMPILER_CONFIG) && !defined(BOOST_NO_COMPILER_CONFIG) && !defined(BOOST_NO_CONFIG) -# include -#endif -// if we have a compiler config, include it now: -#ifdef BOOST_COMPILER_CONFIG -# include BOOST_COMPILER_CONFIG -#endif - -// if we don't have a std library config set, try and find one: -#if !defined(BOOST_STDLIB_CONFIG) && !defined(BOOST_NO_STDLIB_CONFIG) && !defined(BOOST_NO_CONFIG) && defined(__cplusplus) -# include -#endif -// if we have a std library config, include it now: -#ifdef BOOST_STDLIB_CONFIG -# include BOOST_STDLIB_CONFIG -#endif - -// if we don't have a platform config set, try and find one: -#if !defined(BOOST_PLATFORM_CONFIG) && !defined(BOOST_NO_PLATFORM_CONFIG) && !defined(BOOST_NO_CONFIG) -# include -#endif -// if we have a platform config, include it now: -#ifdef BOOST_PLATFORM_CONFIG -# include BOOST_PLATFORM_CONFIG -#endif - -// get config suffix code: -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#endif // BOOST_CONFIG_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_prefix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_prefix.hpp deleted file mode 100644 index 3a0e5ae2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_prefix.hpp +++ /dev/null @@ -1,27 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// for C++ Builder the following options effect the ABI: -// -// -b (on or off - effect emum sizes) -// -Vx (on or off - empty members) -// -Ve (on or off - empty base classes) -// -aX (alignment - 5 options). -// -pX (Calling convention - 4 options) -// -VmX (member pointer size and layout - 5 options) -// -VC (on or off, changes name mangling) -// -Vl (on or off, changes struct layout). - -// In addition the following warnings are sufficiently annoying (and -// unfixable) to have them turned off by default: -// -// 8027 - functions containing [for|while] loops are not expanded inline -// 8026 - functions taking class by value arguments are not expanded inline - -#pragma nopushoptwarn -# pragma option push -a8 -Vx- -Ve- -b- -pc -Vmv -VC- -Vl- -w-8027 -w-8026 - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_suffix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_suffix.hpp deleted file mode 100644 index 940535f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi/borland_suffix.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -# pragma option pop -#pragma nopushoptwarn - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_prefix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_prefix.hpp deleted file mode 100644 index 97f06cdc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_prefix.hpp +++ /dev/null @@ -1,22 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// -// Boost binaries are built with the compiler's default ABI settings, -// if the user changes their default alignment in the VS IDE then their -// code will no longer be binary compatible with the bjam built binaries -// unless this header is included to force Boost code into a consistent ABI. -// -// Note that inclusion of this header is only necessary for libraries with -// separate source, header only libraries DO NOT need this as long as all -// translation units are built with the same options. -// -#if defined(_M_X64) -# pragma pack(push,16) -#else -# pragma pack(push,8) -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_suffix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_suffix.hpp deleted file mode 100644 index a64d783e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi/msvc_suffix.hpp +++ /dev/null @@ -1,8 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#pragma pack(pop) - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi_prefix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi_prefix.hpp deleted file mode 100644 index 3b134749..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi_prefix.hpp +++ /dev/null @@ -1,25 +0,0 @@ -// abi_prefix header -------------------------------------------------------// - -// (c) Copyright John Maddock 2003 - -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). - -#ifndef BOOST_CONFIG_ABI_PREFIX_HPP -# define BOOST_CONFIG_ABI_PREFIX_HPP -#else -# error double inclusion of header boost/config/abi_prefix.hpp is an error -#endif - -#include - -// this must occur after all other includes and before any code appears: -#ifdef BOOST_HAS_ABI_HEADERS -# include BOOST_ABI_PREFIX -#endif - -#if defined( __BORLANDC__ ) -#pragma nopushoptwarn -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/abi_suffix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/abi_suffix.hpp deleted file mode 100644 index 93916166..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/abi_suffix.hpp +++ /dev/null @@ -1,27 +0,0 @@ -// abi_sufffix header -------------------------------------------------------// - -// (c) Copyright John Maddock 2003 - -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). - -// This header should be #included AFTER code that was preceded by a #include -// . - -#ifndef BOOST_CONFIG_ABI_PREFIX_HPP -# error Header boost/config/abi_suffix.hpp must only be used after boost/config/abi_prefix.hpp -#else -# undef BOOST_CONFIG_ABI_PREFIX_HPP -#endif - -// the suffix header occurs after all of our code: -#ifdef BOOST_HAS_ABI_HEADERS -# include BOOST_ABI_SUFFIX -#endif - -#if defined( __BORLANDC__ ) -#pragma nopushoptwarn -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/auto_link.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/auto_link.hpp deleted file mode 100644 index 13cbad43..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/auto_link.hpp +++ /dev/null @@ -1,429 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - /* - * LOCATION: see http://www.boost.org for most recent version. - * FILE auto_link.hpp - * VERSION see - * DESCRIPTION: Automatic library inclusion for Borland/Microsoft compilers. - */ - -/************************************************************************* - -USAGE: -~~~~~~ - -Before including this header you must define one or more of define the following macros: - -BOOST_LIB_NAME: Required: A string containing the basename of the library, - for example boost_regex. -BOOST_LIB_TOOLSET: Optional: the base name of the toolset. -BOOST_DYN_LINK: Optional: when set link to dll rather than static library. -BOOST_LIB_DIAGNOSTIC: Optional: when set the header will print out the name - of the library selected (useful for debugging). -BOOST_AUTO_LINK_NOMANGLE: Specifies that we should link to BOOST_LIB_NAME.lib, - rather than a mangled-name version. -BOOST_AUTO_LINK_TAGGED: Specifies that we link to libraries built with the --layout=tagged option. - This is essentially the same as the default name-mangled version, but without - the compiler name and version, or the Boost version. Just the build options. - -These macros will be undef'ed at the end of the header, further this header -has no include guards - so be sure to include it only once from your library! - -Algorithm: -~~~~~~~~~~ - -Libraries for Borland and Microsoft compilers are automatically -selected here, the name of the lib is selected according to the following -formula: - -BOOST_LIB_PREFIX - + BOOST_LIB_NAME - + "_" - + BOOST_LIB_TOOLSET - + BOOST_LIB_THREAD_OPT - + BOOST_LIB_RT_OPT - "-" - + BOOST_LIB_VERSION - -These are defined as: - -BOOST_LIB_PREFIX: "lib" for static libraries otherwise "". - -BOOST_LIB_NAME: The base name of the lib ( for example boost_regex). - -BOOST_LIB_TOOLSET: The compiler toolset name (vc6, vc7, bcb5 etc). - -BOOST_LIB_THREAD_OPT: "-mt" for multithread builds, otherwise nothing. - -BOOST_LIB_RT_OPT: A suffix that indicates the runtime library used, - contains one or more of the following letters after - a hyphen: - - s static runtime (dynamic if not present). - g debug/diagnostic runtime (release if not present). - y Python debug/diagnostic runtime (release if not present). - d debug build (release if not present). - p STLport build. - n STLport build without its IOStreams. - -BOOST_LIB_VERSION: The Boost version, in the form x_y, for Boost version x.y. - - -***************************************************************************/ - -#ifdef __cplusplus -# ifndef BOOST_CONFIG_HPP -# include -# endif -#elif defined(_MSC_VER) && !defined(__MWERKS__) && !defined(__EDG_VERSION__) -// -// C language compatability (no, honestly) -// -# define BOOST_MSVC _MSC_VER -# define BOOST_STRINGIZE(X) BOOST_DO_STRINGIZE(X) -# define BOOST_DO_STRINGIZE(X) #X -#endif -// -// Only include what follows for known and supported compilers: -// -#if defined(BOOST_MSVC) \ - || defined(__BORLANDC__) \ - || (defined(__MWERKS__) && defined(_WIN32) && (__MWERKS__ >= 0x3000)) \ - || (defined(__ICL) && defined(_MSC_EXTENSIONS) && (_MSC_VER >= 1200)) - -#ifndef BOOST_VERSION_HPP -# include -#endif - -#ifndef BOOST_LIB_NAME -# error "Macro BOOST_LIB_NAME not set (internal error)" -#endif - -// -// error check: -// -#if defined(__MSVC_RUNTIME_CHECKS) && !defined(_DEBUG) -# pragma message("Using the /RTC option without specifying a debug runtime will lead to linker errors") -# pragma message("Hint: go to the code generation options and switch to one of the debugging runtimes") -# error "Incompatible build options" -#endif -// -// select toolset if not defined already: -// -#ifndef BOOST_LIB_TOOLSET -# if defined(BOOST_MSVC) && (BOOST_MSVC < 1200) - // Note: no compilers before 1200 are supported -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1300) - -# ifdef UNDER_CE - // eVC4: -# define BOOST_LIB_TOOLSET "evc4" -# else - // vc6: -# define BOOST_LIB_TOOLSET "vc6" -# endif - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1310) - - // vc7: -# define BOOST_LIB_TOOLSET "vc7" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1400) - - // vc71: -# define BOOST_LIB_TOOLSET "vc71" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1500) - - // vc80: -# define BOOST_LIB_TOOLSET "vc80" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1600) - - // vc90: -# define BOOST_LIB_TOOLSET "vc90" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1700) - - // vc10: -# define BOOST_LIB_TOOLSET "vc100" - -# elif defined(BOOST_MSVC) && (BOOST_MSVC < 1800) - - // vc11: -# define BOOST_LIB_TOOLSET "vc110" - -# elif defined(BOOST_MSVC) - - // vc12: -# define BOOST_LIB_TOOLSET "vc120" - -# elif defined(__BORLANDC__) - - // CBuilder 6: -# define BOOST_LIB_TOOLSET "bcb" - -# elif defined(__ICL) - - // Intel C++, no version number: -# define BOOST_LIB_TOOLSET "iw" - -# elif defined(__MWERKS__) && (__MWERKS__ <= 0x31FF ) - - // Metrowerks CodeWarrior 8.x -# define BOOST_LIB_TOOLSET "cw8" - -# elif defined(__MWERKS__) && (__MWERKS__ <= 0x32FF ) - - // Metrowerks CodeWarrior 9.x -# define BOOST_LIB_TOOLSET "cw9" - -# endif -#endif // BOOST_LIB_TOOLSET - -// -// select thread opt: -// -#if defined(_MT) || defined(__MT__) -# define BOOST_LIB_THREAD_OPT "-mt" -#else -# define BOOST_LIB_THREAD_OPT -#endif - -#if defined(_MSC_VER) || defined(__MWERKS__) - -# ifdef _DLL - -# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS)) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydp" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-gdp" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gdp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-p" -# endif - -# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydpn" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-gdpn" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gydpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gdpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-pn" -# endif - -# else - -# if defined(_DEBUG) && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-gyd" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-gd" -# else -# define BOOST_LIB_RT_OPT -# endif - -# endif - -# else - -# if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS)) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydp" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-sgdp" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgdp" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-sp" -# endif - -# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) - -# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydpn" -# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG)) -# define BOOST_LIB_RT_OPT "-sgdpn" -# elif defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgydpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgdpn" -# pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG=1") -# error "Build options aren't compatible with pre-built libraries" -# else -# define BOOST_LIB_RT_OPT "-spn" -# endif - -# else - -# if defined(_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sgyd" -# elif defined(_DEBUG) -# define BOOST_LIB_RT_OPT "-sgd" -# else -# define BOOST_LIB_RT_OPT "-s" -# endif - -# endif - -# endif - -#elif defined(__BORLANDC__) - -// -// figure out whether we want the debug builds or not: -// -#if __BORLANDC__ > 0x561 -#pragma defineonoption BOOST_BORLAND_DEBUG -v -#endif -// -// sanity check: -// -#if defined(__STL_DEBUG) || defined(_STLP_DEBUG) -#error "Pre-built versions of the Boost libraries are not provided in STLport-debug form" -#endif - -# ifdef _RTLDLL - -# if defined(BOOST_BORLAND_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-yd" -# elif defined(BOOST_BORLAND_DEBUG) -# define BOOST_LIB_RT_OPT "-d" -# elif defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT -y -# else -# define BOOST_LIB_RT_OPT -# endif - -# else - -# if defined(BOOST_BORLAND_DEBUG)\ - && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-syd" -# elif defined(BOOST_BORLAND_DEBUG) -# define BOOST_LIB_RT_OPT "-sd" -# elif defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON) -# define BOOST_LIB_RT_OPT "-sy" -# else -# define BOOST_LIB_RT_OPT "-s" -# endif - -# endif - -#endif - -// -// select linkage opt: -// -#if (defined(_DLL) || defined(_RTLDLL)) && defined(BOOST_DYN_LINK) -# define BOOST_LIB_PREFIX -#elif defined(BOOST_DYN_LINK) -# error "Mixing a dll boost library with a static runtime is a really bad idea..." -#else -# define BOOST_LIB_PREFIX "lib" -#endif - -// -// now include the lib: -// -#if defined(BOOST_LIB_NAME) \ - && defined(BOOST_LIB_PREFIX) \ - && defined(BOOST_LIB_TOOLSET) \ - && defined(BOOST_LIB_THREAD_OPT) \ - && defined(BOOST_LIB_RT_OPT) \ - && defined(BOOST_LIB_VERSION) - -#ifdef BOOST_AUTO_LINK_TAGGED -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT ".lib") -# endif -#elif defined(BOOST_AUTO_LINK_NOMANGLE) -# pragma comment(lib, BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_STRINGIZE(BOOST_LIB_NAME) ".lib") -# endif -#else -# pragma comment(lib, BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT "-" BOOST_LIB_VERSION ".lib") -# ifdef BOOST_LIB_DIAGNOSTIC -# pragma message ("Linking to lib file: " BOOST_LIB_PREFIX BOOST_STRINGIZE(BOOST_LIB_NAME) "-" BOOST_LIB_TOOLSET BOOST_LIB_THREAD_OPT BOOST_LIB_RT_OPT "-" BOOST_LIB_VERSION ".lib") -# endif -#endif - -#else -# error "some required macros where not defined (internal logic error)." -#endif - - -#endif // _MSC_VER || __BORLANDC__ - -// -// finally undef any macros we may have set: -// -#ifdef BOOST_LIB_PREFIX -# undef BOOST_LIB_PREFIX -#endif -#if defined(BOOST_LIB_NAME) -# undef BOOST_LIB_NAME -#endif -// Don't undef this one: it can be set by the user and should be the -// same for all libraries: -//#if defined(BOOST_LIB_TOOLSET) -//# undef BOOST_LIB_TOOLSET -//#endif -#if defined(BOOST_LIB_THREAD_OPT) -# undef BOOST_LIB_THREAD_OPT -#endif -#if defined(BOOST_LIB_RT_OPT) -# undef BOOST_LIB_RT_OPT -#endif -#if defined(BOOST_LIB_LINK_OPT) -# undef BOOST_LIB_LINK_OPT -#endif -#if defined(BOOST_LIB_DEBUG_OPT) -# undef BOOST_LIB_DEBUG_OPT -#endif -#if defined(BOOST_DYN_LINK) -# undef BOOST_DYN_LINK -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/borland.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/borland.hpp deleted file mode 100644 index a8f5baae..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/borland.hpp +++ /dev/null @@ -1,287 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Borland C++ compiler setup: - -// -// versions check: -// we don't support Borland prior to version 5.4: -#if __BORLANDC__ < 0x540 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// last known compiler version: -#if (__BORLANDC__ > 0x613) -//# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -//# else -//# pragma message( "Unknown compiler version - please run the configure tests and report the results") -//# endif -#elif (__BORLANDC__ == 0x600) -# error "CBuilderX preview compiler is no longer supported" -#endif - -// -// Support macros to help with standard library detection -#if (__BORLANDC__ < 0x560) || defined(_USE_OLD_RW_STL) -# define BOOST_BCB_WITH_ROGUE_WAVE -#elif __BORLANDC__ < 0x570 -# define BOOST_BCB_WITH_STLPORT -#else -# define BOOST_BCB_WITH_DINKUMWARE -#endif - -// -// Version 5.0 and below: -# if __BORLANDC__ <= 0x0550 -// Borland C++Builder 4 and 5: -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# if __BORLANDC__ == 0x0550 -// Borland C++Builder 5, command-line compiler 5.5: -# define BOOST_NO_OPERATORS_IN_NAMESPACE -# endif -// Variadic macros do not exist for C++ Builder versions 5 and below -#define BOOST_NO_CXX11_VARIADIC_MACROS -# endif - -// Version 5.51 and below: -#if (__BORLANDC__ <= 0x551) -# define BOOST_NO_CV_SPECIALIZATIONS -# define BOOST_NO_CV_VOID_SPECIALIZATIONS -# define BOOST_NO_DEDUCED_TYPENAME -// workaround for missing WCHAR_MAX/WCHAR_MIN: -#ifdef __cplusplus -#include -#include -#else -#include -#include -#endif // __cplusplus -#ifndef WCHAR_MAX -# define WCHAR_MAX 0xffff -#endif -#ifndef WCHAR_MIN -# define WCHAR_MIN 0 -#endif -#endif - -// Borland C++ Builder 6 and below: -#if (__BORLANDC__ <= 0x564) - -# if defined(NDEBUG) && defined(__cplusplus) - // fix broken so that Boost.test works: -# include -# undef strcmp -# endif - // fix broken errno declaration: -# include -# ifndef errno -# define errno errno -# endif - -#endif - -// -// new bug in 5.61: -#if (__BORLANDC__ >= 0x561) && (__BORLANDC__ <= 0x580) - // this seems to be needed by the command line compiler, but not the IDE: -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -#endif - -// Borland C++ Builder 2006 Update 2 and below: -#if (__BORLANDC__ <= 0x582) -# define BOOST_NO_SFINAE -# define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -# define BOOST_NO_TEMPLATE_TEMPLATES - -# define BOOST_NO_PRIVATE_IN_AGGREGATE - -# ifdef _WIN32 -# define BOOST_NO_SWPRINTF -# elif defined(linux) || defined(__linux__) || defined(__linux) - // we should really be able to do without this - // but the wcs* functions aren't imported into std:: -# define BOOST_NO_STDC_NAMESPACE - // _CPPUNWIND doesn't get automatically set for some reason: -# pragma defineonoption BOOST_CPPUNWIND -x -# endif -#endif - -#if (__BORLANDC__ <= 0x613) // Beman has asked Alisdair for more info - // we shouldn't really need this - but too many things choke - // without it, this needs more investigation: -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_IS_ABSTRACT -# define BOOST_NO_FUNCTION_TYPE_SPECIALIZATIONS -# define BOOST_NO_USING_TEMPLATE -# define BOOST_SP_NO_SP_CONVERTIBLE - -// Temporary workaround -#define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS -#endif - -// Borland C++ Builder 2008 and below: -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE -# define BOOST_NO_NESTED_FRIENDSHIP -# define BOOST_NO_TYPENAME_WITH_CTOR -#if (__BORLANDC__ < 0x600) -# define BOOST_ILLEGAL_CV_REFERENCES -#endif - -// -// Positive Feature detection -// -// Borland C++ Builder 2008 and below: -#if (__BORLANDC__ >= 0x599) -# pragma defineonoption BOOST_CODEGEAR_0X_SUPPORT -Ax -#endif -// -// C++0x Macros: -// -#if !defined( BOOST_CODEGEAR_0X_SUPPORT ) || (__BORLANDC__ < 0x610) -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_CXX11_STATIC_ASSERT -#else -# define BOOST_HAS_ALIGNOF -# define BOOST_HAS_CHAR16_T -# define BOOST_HAS_CHAR32_T -# define BOOST_HAS_DECLTYPE -# define BOOST_HAS_EXPLICIT_CONVERSION_OPS -# define BOOST_HAS_REF_QUALIFIER -# define BOOST_HAS_RVALUE_REFS -# define BOOST_HAS_STATIC_ASSERT -#endif - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS // UTF-8 still not supported -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -#if __BORLANDC__ >= 0x590 -# define BOOST_HAS_TR1_HASH - -# define BOOST_HAS_MACRO_USE_FACET -#endif - -// -// Post 0x561 we have long long and stdint.h: -#if __BORLANDC__ >= 0x561 -# ifndef __NO_LONG_LONG -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif - // On non-Win32 platforms let the platform config figure this out: -# ifdef _WIN32 -# define BOOST_HAS_STDINT_H -# endif -#endif - -// Borland C++Builder 6 defaults to using STLPort. If _USE_OLD_RW_STL is -// defined, then we have 0x560 or greater with the Rogue Wave implementation -// which presumably has the std::DBL_MAX bug. -#if defined( BOOST_BCB_WITH_ROGUE_WAVE ) -// is partly broken, some macros define symbols that are really in -// namespace std, so you end up having to use illegal constructs like -// std::DBL_MAX, as a fix we'll just include float.h and have done with: -#include -#endif -// -// __int64: -// -#if (__BORLANDC__ >= 0x530) && !defined(__STRICT_ANSI__) -# define BOOST_HAS_MS_INT64 -#endif -// -// check for exception handling support: -// -#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif -// -// all versions have a : -// -#ifndef __STRICT_ANSI__ -# define BOOST_HAS_DIRENT_H -#endif -// -// all versions support __declspec: -// -#if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif -// -// ABI fixing headers: -// -#if __BORLANDC__ != 0x600 // not implemented for version 6 compiler yet -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp" -#endif -#endif -// -// Disable Win32 support in ANSI mode: -// -#if __BORLANDC__ < 0x600 -# pragma defineonoption BOOST_DISABLE_WIN32 -A -#elif defined(__STRICT_ANSI__) -# define BOOST_DISABLE_WIN32 -#endif -// -// MSVC compatibility mode does some nasty things: -// TODO: look up if this doesn't apply to the whole 12xx range -// -#if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -# define BOOST_NO_VOID_RETURNS -#endif - -// Borland did not implement value-initialization completely, as I reported -// in 2007, Borland Report 51854, "Value-initialization: POD struct should be -// zero-initialized", http://qc.embarcadero.com/wc/qcmain.aspx?d=51854 -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, April 2010) -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION - -#define BOOST_COMPILER "Borland C++ version " BOOST_STRINGIZE(__BORLANDC__) diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/clang.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/clang.hpp deleted file mode 100644 index b57e26c5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/clang.hpp +++ /dev/null @@ -1,180 +0,0 @@ -// (C) Copyright Douglas Gregor 2010 -// -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Clang compiler setup. - -#define BOOST_HAS_PRAGMA_ONCE - -#if !__has_feature(cxx_exceptions) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -#if !__has_feature(cxx_rtti) && !defined(BOOST_NO_TYPEID) -# define BOOST_NO_TYPEID -#endif - -#if defined(__int64) && !defined(__GNUC__) -# define BOOST_HAS_MS_INT64 -#endif - -#define BOOST_HAS_NRVO - -// Branch prediction hints -#if defined(__has_builtin) -#if __has_builtin(__builtin_expect) -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) -#endif -#endif - -// Clang supports "long long" in all compilation modes. -#define BOOST_HAS_LONG_LONG - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if !defined(_WIN32) && !defined(__WIN32__) && !defined(WIN32) -# define BOOST_SYMBOL_EXPORT __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) -#endif - -// -// The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through -// between switch labels. -// -#if __cplusplus >= 201103L && defined(__has_warning) -# if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") -# define BOOST_FALLTHROUGH [[clang::fallthrough]] -# endif -#endif - -#if !__has_feature(cxx_auto_type) -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif - -#if !(defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L) -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -#endif - -#if !__has_feature(cxx_constexpr) -# define BOOST_NO_CXX11_CONSTEXPR -#endif - -#if !__has_feature(cxx_decltype) -# define BOOST_NO_CXX11_DECLTYPE -#endif - -#if !__has_feature(cxx_decltype_incomplete_return_types) -# define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -#if !__has_feature(cxx_defaulted_functions) -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#endif - -#if !__has_feature(cxx_deleted_functions) -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -#endif - -#if !__has_feature(cxx_explicit_conversions) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif - -#if !__has_feature(cxx_default_function_template_args) -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#if !__has_feature(cxx_lambdas) -# define BOOST_NO_CXX11_LAMBDAS -#endif - -#if !__has_feature(cxx_local_type_template_args) -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif - -#if !__has_feature(cxx_noexcept) -# define BOOST_NO_CXX11_NOEXCEPT -#endif - -#if !__has_feature(cxx_nullptr) -# define BOOST_NO_CXX11_NULLPTR -#endif - -#if !__has_feature(cxx_range_for) -# define BOOST_NO_CXX11_RANGE_BASED_FOR -#endif - -#if !__has_feature(cxx_raw_string_literals) -# define BOOST_NO_CXX11_RAW_LITERALS -#endif - -#if !__has_feature(cxx_generalized_initializers) -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -#if !__has_feature(cxx_rvalue_references) -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif - -#if !__has_feature(cxx_strong_enums) -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -#if !__has_feature(cxx_static_assert) -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif - -#if !__has_feature(cxx_alias_templates) -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -#endif - -#if !__has_feature(cxx_unicode_literals) -# define BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -#if !__has_feature(cxx_variadic_templates) -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif - -#if !__has_feature(cxx_user_literals) -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#endif - -#if !(__has_feature(cxx_alignas) || __has_extension(cxx_alignas)) -# define BOOST_NO_CXX11_ALIGNAS -#endif - -#if !__has_feature(cxx_trailing_return) -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -#if !__has_feature(cxx_inline_namespaces) -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -// Clang always supports variadic macros -// Clang always supports extern templates - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "Clang version " __clang_version__ -#endif - -// Macro used to identify the Clang compiler. -#define BOOST_CLANG 1 - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/codegear.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/codegear.hpp deleted file mode 100644 index 00e0bb94..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/codegear.hpp +++ /dev/null @@ -1,189 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// CodeGear C++ compiler setup: - -#if !defined( BOOST_WITH_CODEGEAR_WARNINGS ) -// these warnings occur frequently in optimized template code -# pragma warn -8004 // var assigned value, but never used -# pragma warn -8008 // condition always true/false -# pragma warn -8066 // dead code can never execute -# pragma warn -8104 // static members with ctors not threadsafe -# pragma warn -8105 // reference member in class without ctors -#endif -// -// versions check: -// last known and checked version is 0x621 -#if (__CODEGEARC__ > 0x621) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# else -# pragma message( "Unknown compiler version - please run the configure tests and report the results") -# endif -#endif - -// CodeGear C++ Builder 2009 -#if (__CODEGEARC__ <= 0x613) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_PRIVATE_IN_AGGREGATE -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE - // we shouldn't really need this - but too many things choke - // without it, this needs more investigation: -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_SP_NO_SP_CONVERTIBLE -#endif - -// CodeGear C++ Builder 2010 -#if (__CODEGEARC__ <= 0x621) -# define BOOST_NO_TYPENAME_WITH_CTOR // Cannot use typename keyword when making temporaries of a dependant type -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_NESTED_FRIENDSHIP // TC1 gives nested classes access rights as any other member -# define BOOST_NO_USING_TEMPLATE -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -// Temporary hack, until specific MPL preprocessed headers are generated -# define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS - -// CodeGear has not yet completely implemented value-initialization, for -// example for array types, as I reported in 2010: Embarcadero Report 83751, -// "Value-initialization: arrays should have each element value-initialized", -// http://qc.embarcadero.com/wc/qcmain.aspx?d=83751 -// Last checked version: Embarcadero C++ 6.21 -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, April 2010) -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION - -# if defined(NDEBUG) && defined(__cplusplus) - // fix broken so that Boost.test works: -# include -# undef strcmp -# endif - // fix broken errno declaration: -# include -# ifndef errno -# define errno errno -# endif - -#endif - -// Reportedly, #pragma once is supported since C++ Builder 2010 -#if (__CODEGEARC__ >= 0x620) -# define BOOST_HAS_PRAGMA_ONCE -#endif - -// -// C++0x macros: -// -#if (__CODEGEARC__ <= 0x620) -#define BOOST_NO_CXX11_STATIC_ASSERT -#else -#define BOOST_HAS_STATIC_ASSERT -#endif -#define BOOST_HAS_CHAR16_T -#define BOOST_HAS_CHAR32_T -#define BOOST_HAS_LONG_LONG -// #define BOOST_HAS_ALIGNOF -#define BOOST_HAS_DECLTYPE -#define BOOST_HAS_EXPLICIT_CONVERSION_OPS -// #define BOOST_HAS_RVALUE_REFS -#define BOOST_HAS_SCOPED_ENUM -// #define BOOST_HAS_STATIC_ASSERT -#define BOOST_HAS_STD_TYPE_TRAITS - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -// -// TR1 macros: -// -#define BOOST_HAS_TR1_HASH -#define BOOST_HAS_TR1_TYPE_TRAITS -#define BOOST_HAS_TR1_UNORDERED_MAP -#define BOOST_HAS_TR1_UNORDERED_SET - -#define BOOST_HAS_MACRO_USE_FACET - -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST - -// On non-Win32 platforms let the platform config figure this out: -#ifdef _WIN32 -# define BOOST_HAS_STDINT_H -#endif - -// -// __int64: -// -#if !defined(__STRICT_ANSI__) -# define BOOST_HAS_MS_INT64 -#endif -// -// check for exception handling support: -// -#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif -// -// all versions have a : -// -#if !defined(__STRICT_ANSI__) -# define BOOST_HAS_DIRENT_H -#endif -// -// all versions support __declspec: -// -#if defined(__STRICT_ANSI__) -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif -// -// ABI fixing headers: -// -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp" -#endif -// -// Disable Win32 support in ANSI mode: -// -# pragma defineonoption BOOST_DISABLE_WIN32 -A -// -// MSVC compatibility mode does some nasty things: -// TODO: look up if this doesn't apply to the whole 12xx range -// -#if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -# define BOOST_NO_VOID_RETURNS -#endif - -#define BOOST_COMPILER "CodeGear C++ version " BOOST_STRINGIZE(__CODEGEARC__) - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/comeau.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/comeau.hpp deleted file mode 100644 index 278222dc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/comeau.hpp +++ /dev/null @@ -1,59 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Douglas Gregor 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Aleksey Gurtovoy 2003. -// (C) Copyright Beman Dawes 2003. -// (C) Copyright Jens Maurer 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Comeau C++ compiler setup: - -#include "boost/config/compiler/common_edg.hpp" - -#if (__COMO_VERSION__ <= 4245) - -# if defined(_MSC_VER) && _MSC_VER <= 1300 -# if _MSC_VER > 100 - // only set this in non-strict mode: -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -# endif -# endif - -// Void returns don't work when emulating VC 6 (Peter Dimov) -// TODO: look up if this doesn't apply to the whole 12xx range -# if defined(_MSC_VER) && (_MSC_VER < 1300) -# define BOOST_NO_VOID_RETURNS -# endif - -#endif // version 4245 - -// -// enable __int64 support in VC emulation mode -// -# if defined(_MSC_VER) && (_MSC_VER >= 1200) -# define BOOST_HAS_MS_INT64 -# endif - -#define BOOST_COMPILER "Comeau compiler version " BOOST_STRINGIZE(__COMO_VERSION__) - -// -// versions check: -// we don't know Comeau prior to version 4245: -#if __COMO_VERSION__ < 4245 -# error "Compiler not configured - please reconfigure" -#endif -// -// last known and checked version is 4245: -#if (__COMO_VERSION__ > 4245) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/common_edg.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/common_edg.hpp deleted file mode 100644 index 70e7efa2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/common_edg.hpp +++ /dev/null @@ -1,112 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright Markus Schoepflin 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// -// Options common to all edg based compilers. -// -// This is included from within the individual compiler mini-configs. - -#ifndef __EDG_VERSION__ -# error This file requires that __EDG_VERSION__ be defined. -#endif - -#if (__EDG_VERSION__ <= 238) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_SFINAE -#endif - -#if (__EDG_VERSION__ <= 240) -# define BOOST_NO_VOID_RETURNS -#endif - -#if (__EDG_VERSION__ <= 241) && !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP) -# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP -#endif - -#if (__EDG_VERSION__ <= 244) && !defined(BOOST_NO_TEMPLATE_TEMPLATES) -# define BOOST_NO_TEMPLATE_TEMPLATES -#endif - -#if (__EDG_VERSION__ < 300) && !defined(BOOST_NO_IS_ABSTRACT) -# define BOOST_NO_IS_ABSTRACT -#endif - -#if (__EDG_VERSION__ <= 303) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// See also kai.hpp which checks a Kai-specific symbol for EH -# if !defined(__KCC) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -# endif - -# if !defined(__NO_LONG_LONG) -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif - -// Not sure what version was the first to support #pragma once, but -// different EDG-based compilers (e.g. Intel) supported it for ages. -// Add a proper version check if it causes problems. -#define BOOST_HAS_PRAGMA_ONCE - -// -// C++0x features -// -// See above for BOOST_NO_LONG_LONG -// -#if (__EDG_VERSION__ < 310) -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if (__EDG_VERSION__ <= 310) -// No support for initializer lists -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif -#if (__EDG_VERSION__ < 400) -# define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -#ifdef c_plusplus -// EDG has "long long" in non-strict mode -// However, some libraries have insufficient "long long" support -// #define BOOST_HAS_LONG_LONG -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/compaq_cxx.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/compaq_cxx.hpp deleted file mode 100644 index b44486c6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/compaq_cxx.hpp +++ /dev/null @@ -1,19 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Tru64 C++ compiler setup (now HP): - -#define BOOST_COMPILER "HP Tru64 C++ " BOOST_STRINGIZE(__DECCXX_VER) - -#include "boost/config/compiler/common_edg.hpp" - -// -// versions check: -// Nothing to do here? - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/cray.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/cray.hpp deleted file mode 100644 index 3ce29f01..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/cray.hpp +++ /dev/null @@ -1,65 +0,0 @@ -// (C) Copyright John Maddock 2011. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Greenhills C compiler setup: - -#define BOOST_COMPILER "Cray C version " BOOST_STRINGIZE(_RELEASE) - -#if _RELEASE < 7 -# error "Boost is not configured for Cray compilers prior to version 7, please try the configure script." -#endif - -// -// Check this is a recent EDG based compiler, otherwise we don't support it here: -// -#ifndef __EDG_VERSION__ -# error "Unsupported Cray compiler, please try running the configure script." -#endif - -#include "boost/config/compiler/common_edg.hpp" - -// -// Cray peculiarities, probably version 7 specific: -// -#undef BOOST_NO_CXX11_AUTO_DECLARATIONS -#undef BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_HAS_NRVO -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_HAS_NRVO -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_ALIGNAS -//#define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -#define BOOST_MATH_DISABLE_STD_FPCLASSIFY -//#define BOOST_HAS_FPCLASSIFY - -#define BOOST_SP_USE_PTHREADS -#define BOOST_AC_USE_PTHREADS - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/digitalmars.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/digitalmars.hpp deleted file mode 100644 index 7de6adb1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/digitalmars.hpp +++ /dev/null @@ -1,93 +0,0 @@ -// Copyright (C) Christof Meerwald 2003 -// Copyright (C) Dan Watkins 2003 -// -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Digital Mars C++ compiler setup: -#define BOOST_COMPILER __DMC_VERSION_STRING__ - -#define BOOST_HAS_LONG_LONG -#define BOOST_HAS_PRAGMA_ONCE - -#if !defined(BOOST_STRICT_CONFIG) -#define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#define BOOST_NO_OPERATORS_IN_NAMESPACE -#define BOOST_NO_UNREACHABLE_RETURN_DETECTION -#define BOOST_NO_SFINAE -#define BOOST_NO_USING_TEMPLATE -#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// -// has macros: -#define BOOST_HAS_DIRENT_H -#define BOOST_HAS_STDINT_H -#define BOOST_HAS_WINTHREADS - -#if (__DMC__ >= 0x847) -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_LOG1P -#endif - -// -// Is this really the best way to detect whether the std lib is in namespace std? -// -#ifdef __cplusplus -#include -#endif -#if !defined(__STL_IMPORT_VENDOR_CSTD) && !defined(_STLP_IMPORT_VENDOR_CSTD) -# define BOOST_NO_STDC_NAMESPACE -#endif - - -// check for exception handling support: -#if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -// -// C++0x features -// -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -#if (__DMC__ <= 0x840) -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is ...: -#if (__DMC__ > 0x848) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc.hpp deleted file mode 100644 index aa628e5a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc.hpp +++ /dev/null @@ -1,261 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Jens Maurer 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Douglas Gregor 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Synge Todo 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// GNU C++ compiler setup. - -// -// Define BOOST_GCC so we know this is "real" GCC and not some pretender: -// -#if !defined(__CUDACC__) -#define BOOST_GCC (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) -#endif - -#if __GNUC__ == 3 -# if defined (__PATHSCALE__) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# define BOOST_NO_IS_ABSTRACT -# endif - -# if __GNUC_MINOR__ < 4 -# define BOOST_NO_IS_ABSTRACT -# endif -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if __GNUC__ < 4 -// -// All problems to gcc-3.x and earlier here: -// -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -# ifdef __OPEN64__ -# define BOOST_NO_IS_ABSTRACT -# endif -#endif - -// GCC prior to 3.4 had #pragma once too but it didn't work well with filesystem links -#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) -#define BOOST_HAS_PRAGMA_ONCE -#endif - -#if __GNUC__ < 4 || ( __GNUC__ == 4 && __GNUC_MINOR__ < 4 ) -// Previous versions of GCC did not completely implement value-initialization: -// GCC Bug 30111, "Value-initialization of POD base class doesn't initialize -// members", reported by Jonathan Wakely in 2006, -// http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30111 (fixed for GCC 4.4) -// GCC Bug 33916, "Default constructor fails to initialize array members", -// reported by Michael Elizabeth Chastain in 2007, -// http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33916 (fixed for GCC 4.2.4) -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -#define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#endif - -#if !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - - -// -// Threading support: Turn this on unconditionally here (except for -// those platforms where we can know for sure). It will get turned off again -// later if no threading API is detected. -// -#if !defined(__MINGW32__) && !defined(linux) && !defined(__linux) && !defined(__linux__) -# define BOOST_HAS_THREADS -#endif - -// -// gcc has "long long" -// -#define BOOST_HAS_LONG_LONG - -// -// gcc implements the named return value optimization since version 3.1 -// -#define BOOST_HAS_NRVO - -// Branch prediction hints -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if __GNUC__ >= 4 -# if (defined(_WIN32) || defined(__WIN32__) || defined(WIN32)) && !defined(__CYGWIN__) - // All Win32 development environments, including 64-bit Windows and MinGW, define - // _WIN32 or one of its variant spellings. Note that Cygwin is a POSIX environment, - // so does not define _WIN32 or its variants. -# define BOOST_HAS_DECLSPEC -# define BOOST_SYMBOL_EXPORT __attribute__((__dllexport__)) -# define BOOST_SYMBOL_IMPORT __attribute__((__dllimport__)) -# else -# define BOOST_SYMBOL_EXPORT __attribute__((__visibility__("default"))) -# define BOOST_SYMBOL_IMPORT -# endif -# define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) -#else -// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined -# define BOOST_SYMBOL_EXPORT -#endif - -// -// RTTI and typeinfo detection is possible post gcc-4.3: -// -#if __GNUC__ * 100 + __GNUC_MINOR__ >= 403 -# ifndef __GXX_RTTI -# ifndef BOOST_NO_TYPEID -# define BOOST_NO_TYPEID -# endif -# ifndef BOOST_NO_RTTI -# define BOOST_NO_RTTI -# endif -# endif -#endif - -// -// Recent GCC versions have __int128 when in 64-bit mode. -// -// We disable this if the compiler is really nvcc as it -// doesn't actually support __int128 as of CUDA_VERSION=5000 -// even though it defines __SIZEOF_INT128__. -// See https://svn.boost.org/trac/boost/ticket/8048 -// Only re-enable this for nvcc if you're absolutely sure -// of the circumstances under which it's supported: -// -#if defined(__SIZEOF_INT128__) && !defined(__CUDACC__) -# define BOOST_HAS_INT128 -#endif - -// C++0x features in 4.3.n and later -// -#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 2)) && defined(__GXX_EXPERIMENTAL_CXX0X__) -// C++0x features are only enabled when -std=c++0x or -std=gnu++0x are -// passed on the command line, which in turn defines -// __GXX_EXPERIMENTAL_CXX0X__. -# define BOOST_HAS_DECLTYPE -# define BOOST_HAS_RVALUE_REFS -# define BOOST_HAS_STATIC_ASSERT -# define BOOST_HAS_VARIADIC_TMPL -#else -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT - -// Variadic templates compiler: -// http://www.generic-programming.org/~dgregor/cpp/variadic-templates.html -# if defined(__VARIADIC_TEMPLATES) || (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4) && defined(__GXX_EXPERIMENTAL_CXX0X__)) -# define BOOST_HAS_VARIADIC_TMPL -# else -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# endif -#endif - -// C++0x features in 4.4.n and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 4) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif - -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) -# define BOOST_NO_SFINAE_EXPR -#endif - -// GCC 4.5 forbids declaration of defaulted functions in private or protected sections -#if !defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) && (__GNUC__ == 4 && __GNUC_MINOR__ <= 5) -# define BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS -#endif - -// C++0x features in 4.5.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_UNICODE_LITERALS -#endif - -// C++0x features in 4.5.1 and later -// -#if (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40501) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -// scoped enums have a serious bug in 4.4.0, so define BOOST_NO_CXX11_SCOPED_ENUMS before 4.5.1 -// See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38064 -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif - -// C++0x features in 4.6.n and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 6) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -// C++0x features in 4.7.n and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#endif - -// C++0x features in 4.8.n and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 8) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_ALIGNAS -#endif - -// C++0x features in 4.8.1 and later -// -#if (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40801) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_DECLTYPE_N3276 -#endif - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "GNU C++ version " __VERSION__ -#endif - -// ConceptGCC compiler: -// http://www.generic-programming.org/software/ConceptGCC/ -#ifdef __GXX_CONCEPTS__ -# define BOOST_HAS_CONCEPTS -# define BOOST_COMPILER "ConceptGCC version " __VERSION__ -#endif - -// versions check: -// we don't know gcc prior to version 3.30: -#if (__GNUC__ < 3) || (__GNUC__ == 3 && (__GNUC_MINOR__ < 3)) -# error "Compiler not configured - please reconfigure" -#endif -// -// last known and checked version is 4.6 (Pre-release): -#if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ > 6)) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# else -// we don't emit warnings here anymore since there are no defect macros defined for -// gcc post 3.4, so any failures are gcc regressions... -//# warning "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc_xml.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc_xml.hpp deleted file mode 100644 index d2e0c74f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/gcc_xml.hpp +++ /dev/null @@ -1,64 +0,0 @@ -// (C) Copyright John Maddock 2006. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// GCC-XML C++ compiler setup: - -# if !defined(__GCCXML_GNUC__) || ((__GCCXML_GNUC__ <= 3) && (__GCCXML_GNUC_MINOR__ <= 3)) -# define BOOST_NO_IS_ABSTRACT -# endif - -// -// Threading support: Turn this on unconditionally here (except for -// those platforms where we can know for sure). It will get turned off again -// later if no threading API is detected. -// -#if !defined(__MINGW32__) && !defined(_MSC_VER) && !defined(linux) && !defined(__linux) && !defined(__linux__) -# define BOOST_HAS_THREADS -#endif - -// -// gcc has "long long" -// -#define BOOST_HAS_LONG_LONG - -// C++0x features: -// -# define BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE_N3276 -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_VARIADIC_MACROS -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_SFINAE_EXPR -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_UNICODE_LITERALS -# define BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES - -#define BOOST_COMPILER "GCC-XML C++ version " __GCCXML__ - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/greenhills.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/greenhills.hpp deleted file mode 100644 index 038b6b2b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/greenhills.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Greenhills C++ compiler setup: - -#define BOOST_COMPILER "Greenhills C++ version " BOOST_STRINGIZE(__ghs) - -#include "boost/config/compiler/common_edg.hpp" - -// -// versions check: -// we don't support Greenhills prior to version 0: -#if __ghs < 0 -# error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 0: -#if (__ghs > 0) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/hp_acc.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/hp_acc.hpp deleted file mode 100644 index f08dca44..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/hp_acc.hpp +++ /dev/null @@ -1,144 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Toon Knapen 2003. -// (C) Copyright Boris Gubenko 2006 - 2007. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// HP aCC C++ compiler setup: - -#if defined(__EDG__) -#include "boost/config/compiler/common_edg.hpp" -#endif - -#if (__HP_aCC <= 33100) -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_OPERATORS_IN_NAMESPACE -# if !defined(_NAMESPACE_STD) -# define BOOST_NO_STD_LOCALE -# define BOOST_NO_STRINGSTREAM -# endif -#endif - -#if (__HP_aCC <= 33300) -// member templates are sufficiently broken that we disable them for now -# define BOOST_NO_MEMBER_TEMPLATES -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE -#endif - -#if (__HP_aCC <= 38000) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -#if (__HP_aCC > 50000) && (__HP_aCC < 60000) -# define BOOST_NO_UNREACHABLE_RETURN_DETECTION -# define BOOST_NO_TEMPLATE_TEMPLATES -# define BOOST_NO_SWPRINTF -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_IS_ABSTRACT -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#endif - -// optional features rather than defects: -#if (__HP_aCC >= 33900) -# define BOOST_HAS_LONG_LONG -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -#endif - -#if (__HP_aCC >= 50000 ) && (__HP_aCC <= 53800 ) || (__HP_aCC < 31300 ) -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -#endif - -// This macro should not be defined when compiling in strict ansi -// mode, but, currently, we don't have the ability to determine -// what standard mode we are compiling with. Some future version -// of aCC6 compiler will provide predefined macros reflecting the -// compilation options, including the standard mode. -#if (__HP_aCC >= 60000) || ((__HP_aCC > 38000) && defined(__hpxstd98)) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -#define BOOST_COMPILER "HP aCC version " BOOST_STRINGIZE(__HP_aCC) - -// -// versions check: -// we don't support HP aCC prior to version 33000: -#if __HP_aCC < 33000 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// -// Extended checks for supporting aCC on PA-RISC -#if __HP_aCC > 30000 && __HP_aCC < 50000 -# if __HP_aCC < 38000 - // versions prior to version A.03.80 not supported -# error "Compiler version not supported - version A.03.80 or higher is required" -# elif !defined(__hpxstd98) - // must compile using the option +hpxstd98 with version A.03.80 and above -# error "Compiler option '+hpxstd98' is required for proper support" -# endif //PA-RISC -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if !defined(__EDG__) - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -/* - See https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443331 and - https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443436 -*/ - -#if (__HP_aCC < 62500) || !defined(HP_CXX0x_SOURCE) - #define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#endif - -// -// last known and checked version for HP-UX/ia64 is 61300 -// last known and checked version for PA-RISC is 38000 -#if ((__HP_aCC > 61300) || ((__HP_aCC > 38000) && defined(__hpxstd98))) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/intel.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/intel.hpp deleted file mode 100644 index 3f0eaa18..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/intel.hpp +++ /dev/null @@ -1,323 +0,0 @@ -// (C) Copyright John Maddock 2001-8. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Aleksey Gurtovoy 2002 - 2003. -// (C) Copyright Guillaume Melquiond 2002 - 2003. -// (C) Copyright Beman Dawes 2003. -// (C) Copyright Martin Wille 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Intel compiler setup: - -#include "boost/config/compiler/common_edg.hpp" - -#if defined(__INTEL_COMPILER) -# define BOOST_INTEL_CXX_VERSION __INTEL_COMPILER -#elif defined(__ICL) -# define BOOST_INTEL_CXX_VERSION __ICL -#elif defined(__ICC) -# define BOOST_INTEL_CXX_VERSION __ICC -#elif defined(__ECC) -# define BOOST_INTEL_CXX_VERSION __ECC -#endif - -// Flags determined by comparing output of 'icpc -dM -E' with and without '-std=c++0x' -#if (!(defined(_WIN32) || defined(_WIN64)) && defined(__STDC_HOSTED__) && (__STDC_HOSTED__ && (BOOST_INTEL_CXX_VERSION <= 1200))) || defined(__GXX_EXPERIMENTAL_CPP0X__) || defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_INTEL_STDCXX0X -#endif -#if defined(_MSC_VER) && (_MSC_VER >= 1600) -# define BOOST_INTEL_STDCXX0X -#endif - -#ifdef BOOST_INTEL_STDCXX0X -#define BOOST_COMPILER "Intel C++ C++0x mode version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -#else -#define BOOST_COMPILER "Intel C++ version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION) -#endif -#define BOOST_INTEL BOOST_INTEL_CXX_VERSION - -#if defined(_WIN32) || defined(_WIN64) -# define BOOST_INTEL_WIN BOOST_INTEL -#else -# define BOOST_INTEL_LINUX BOOST_INTEL -#endif - -#if (BOOST_INTEL_CXX_VERSION <= 600) - -# if defined(_MSC_VER) && (_MSC_VER <= 1300) // added check for <= VC 7 (Peter Dimov) - -// Boost libraries assume strong standard conformance unless otherwise -// indicated by a config macro. As configured by Intel, the EDG front-end -// requires certain compiler options be set to achieve that strong conformance. -// Particularly /Qoption,c,--arg_dep_lookup (reported by Kirk Klobe & Thomas Witt) -// and /Zc:wchar_t,forScope. See boost-root/tools/build/intel-win32-tools.jam for -// details as they apply to particular versions of the compiler. When the -// compiler does not predefine a macro indicating if an option has been set, -// this config file simply assumes the option has been set. -// Thus BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP will not be defined, even if -// the compiler option is not enabled. - -# define BOOST_NO_SWPRINTF -# endif - -// Void returns, 64 bit integrals don't work when emulating VC 6 (Peter Dimov) - -# if defined(_MSC_VER) && (_MSC_VER <= 1200) -# define BOOST_NO_VOID_RETURNS -# define BOOST_NO_INTEGRAL_INT64_T -# endif - -#endif - -#if (BOOST_INTEL_CXX_VERSION <= 710) && defined(_WIN32) -# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS -#endif - -// See http://aspn.activestate.com/ASPN/Mail/Message/boost/1614864 -#if BOOST_INTEL_CXX_VERSION < 600 -# define BOOST_NO_INTRINSIC_WCHAR_T -#else -// We should test the macro _WCHAR_T_DEFINED to check if the compiler -// supports wchar_t natively. *BUT* there is a problem here: the standard -// headers define this macro if they typedef wchar_t. Anyway, we're lucky -// because they define it without a value, while Intel C++ defines it -// to 1. So we can check its value to see if the macro was defined natively -// or not. -// Under UNIX, the situation is exactly the same, but the macro _WCHAR_T -// is used instead. -# if ((_WCHAR_T_DEFINED + 0) == 0) && ((_WCHAR_T + 0) == 0) -# define BOOST_NO_INTRINSIC_WCHAR_T -# endif -#endif - -#if defined(__GNUC__) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -// -// Figure out when Intel is emulating this gcc bug -// (All Intel versions prior to 9.0.26, and versions -// later than that if they are set up to emulate gcc 3.2 -// or earlier): -// -# if ((__GNUC__ == 3) && (__GNUC_MINOR__ <= 2)) || (BOOST_INTEL < 900) || (__INTEL_COMPILER_BUILD_DATE < 20050912) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -# endif -#endif -#if (defined(__GNUC__) && (__GNUC__ < 4)) || (defined(_WIN32) && (BOOST_INTEL_CXX_VERSION <= 1200)) || (BOOST_INTEL_CXX_VERSION <= 1200) -// GCC or VC emulation: -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif -// -// Verify that we have actually got BOOST_NO_INTRINSIC_WCHAR_T -// set correctly, if we don't do this now, we will get errors later -// in type_traits code among other things, getting this correct -// for the Intel compiler is actually remarkably fragile and tricky: -// -#ifdef __cplusplus -#if defined(BOOST_NO_INTRINSIC_WCHAR_T) -#include -template< typename T > struct assert_no_intrinsic_wchar_t; -template<> struct assert_no_intrinsic_wchar_t { typedef void type; }; -// if you see an error here then you need to unset BOOST_NO_INTRINSIC_WCHAR_T -// where it is defined above: -typedef assert_no_intrinsic_wchar_t::type assert_no_intrinsic_wchar_t_; -#else -template< typename T > struct assert_intrinsic_wchar_t; -template<> struct assert_intrinsic_wchar_t {}; -// if you see an error here then define BOOST_NO_INTRINSIC_WCHAR_T on the command line: -template<> struct assert_intrinsic_wchar_t {}; -#endif -#endif - -#if defined(_MSC_VER) && (_MSC_VER+0 >= 1000) -# if _MSC_VER >= 1200 -# define BOOST_HAS_MS_INT64 -# endif -# define BOOST_NO_SWPRINTF -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#elif defined(_WIN32) -# define BOOST_DISABLE_WIN32 -#endif - -// I checked version 6.0 build 020312Z, it implements the NRVO. -// Correct this as you find out which version of the compiler -// implemented the NRVO first. (Daniel Frey) -#if (BOOST_INTEL_CXX_VERSION >= 600) -# define BOOST_HAS_NRVO -#endif - -// Branch prediction hints -// I'm not sure 8.0 was the first version to support these builtins, -// update the condition if the version is not accurate. (Andrey Semashev) -#if defined(__GNUC__) && BOOST_INTEL_CXX_VERSION >= 800 -#define BOOST_LIKELY(x) __builtin_expect(x, 1) -#define BOOST_UNLIKELY(x) __builtin_expect(x, 0) -#endif - -// -// versions check: -// we don't support Intel prior to version 6.0: -#if BOOST_INTEL_CXX_VERSION < 600 -# error "Compiler not supported or configured - please reconfigure" -#endif - -// Intel on MacOS requires -#if defined(__APPLE__) && defined(__INTEL_COMPILER) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -// Intel on Altix Itanium -#if defined(__itanium__) && defined(__INTEL_COMPILER) -# define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#endif - -// -// An attempt to value-initialize a pointer-to-member may trigger an -// internal error on Intel <= 11.1 (last checked version), as was -// reported by John Maddock, Intel support issue 589832, May 2010. -// Moreover, according to test results from Huang-Vista-x86_32_intel, -// intel-vc9-win-11.1 may leave a non-POD array uninitialized, in some -// cases when it should be value-initialized. -// (Niels Dekker, LKEB, May 2010) -// Apparently Intel 12.1 (compiler version number 9999 !!) has the same issue (compiler regression). -#if defined(__INTEL_COMPILER) -# if (__INTEL_COMPILER <= 1110) || (__INTEL_COMPILER == 9999) || (defined(_WIN32) && (__INTEL_COMPILER < 1500)) -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# endif -#endif - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -# define BOOST_SYMBOL_EXPORT __attribute__((visibility("default"))) -# define BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_VISIBLE __attribute__((visibility("default"))) -#endif -// -// C++0x features -// - ICC added static_assert in 11.0 (first version with C++0x support) -// -#if defined(BOOST_INTEL_STDCXX0X) -# undef BOOST_NO_CXX11_STATIC_ASSERT -// -// These pass our test cases, but aren't officially supported according to: -// http://software.intel.com/en-us/articles/c0x-features-supported-by-intel-c-compiler/ -// -//# undef BOOST_NO_CXX11_LAMBDAS -//# undef BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -//# undef BOOST_NO_CXX11_DECLTYPE -//# undef BOOST_NO_CXX11_AUTO_DECLARATIONS -//# undef BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif - -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION >= 1200) -//# undef BOOST_NO_CXX11_RVALUE_REFERENCES // Enabling this breaks Filesystem and Exception libraries -//# undef BOOST_NO_CXX11_SCOPED_ENUMS // doesn't really work!! -# undef BOOST_NO_CXX11_DELETED_FUNCTIONS -# undef BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# undef BOOST_NO_CXX11_LAMBDAS -# undef BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# undef BOOST_NO_CXX11_DECLTYPE -# undef BOOST_NO_CXX11_AUTO_DECLARATIONS -# undef BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# undef BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#endif - -// icl Version 12.1.0.233 Build 20110811 and possibly some other builds -// had an incorrect __INTEL_COMPILER value of 9999. Intel say this has been fixed. -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION > 1200) -# undef BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# undef BOOST_NO_CXX11_NULLPTR -# undef BOOST_NO_CXX11_RVALUE_REFERENCES -# undef BOOST_NO_SFINAE_EXPR -# undef BOOST_NO_CXX11_TEMPLATE_ALIASES -# undef BOOST_NO_CXX11_VARIADIC_TEMPLATES - -// http://software.intel.com/en-us/articles/c0x-features-supported-by-intel-c-compiler/ -// continues to list scoped enum support as "Partial" -//# undef BOOST_NO_CXX11_SCOPED_ENUMS -#endif -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION >= 1310) && !defined(_MSC_VER) -# undef BOOST_NO_CXX11_INLINE_NAMESPACES -# undef BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -// This one generates internal compiler errors in multiprecision, disabled for now: -//# undef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -// This one generates errors when used with conditional exception specifications, for example in multiprecision: -//# undef BOOST_NO_CXX11_NOEXCEPT -# undef BOOST_NO_CXX11_RANGE_BASED_FOR -# undef BOOST_NO_CXX11_SCOPED_ENUMS -# undef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif -#if (BOOST_INTEL_CXX_VERSION >= 1310) -# undef BOOST_NO_SFINAE_EXPR -#endif -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION >= 1400) && !defined(_MSC_VER) -# undef BOOST_NO_CXX11_UNICODE_LITERALS -# undef BOOST_NO_CXX11_RAW_LITERALS -// This one generates errors when used with conditional exception specifications, for example in multiprecision: -//# undef BOOST_NO_CXX11_NOEXCEPT -// This breaks multiprecision: -//# undef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# undef BOOST_NO_CXX11_HDR_THREAD -# undef BOOST_NO_CXX11_CHAR32_T -# undef BOOST_NO_CXX11_CHAR16_T -#endif - -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION <= 1310) -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION == 1400) -// A regression in Intel's compiler means that seems to be broken in this release as well as : -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -#if defined(_MSC_VER) && (_MSC_VER <= 1700) -// -// Although the Intel compiler is capable of supporting these, it appears not to in MSVC compatibility mode: -// -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# if(BOOST_INTEL_CXX_VERSION < 1310) -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# endif -#endif - -#if (BOOST_INTEL_CXX_VERSION < 1200) -// -// fenv.h appears not to work with Intel prior to 12.0: -// -# define BOOST_NO_FENV_H -#endif - -#if defined(_MSC_VER) && (_MSC_VER >= 1600) -# define BOOST_HAS_STDINT_H -#endif - -#if defined(__LP64__) && defined(__GNUC__) && (BOOST_INTEL_CXX_VERSION >= 1310) -# define BOOST_HAS_INT128 -#endif - -// -// last known and checked version: -#if (BOOST_INTEL_CXX_VERSION > 1310) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# elif defined(_MSC_VER) -// -// We don't emit this warning any more, since we have so few -// defect macros set anyway (just the one). -// -//# pragma message("Unknown compiler version - please run the configure tests and report the results") -# endif -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/kai.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/kai.hpp deleted file mode 100644 index 2337e6a8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/kai.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Kai C++ compiler setup: - -#include "boost/config/compiler/common_edg.hpp" - -# if (__KCC_VERSION <= 4001) || !defined(BOOST_STRICT_CONFIG) - // at least on Sun, the contents of is not in namespace std -# define BOOST_NO_STDC_NAMESPACE -# endif - -// see also common_edg.hpp which needs a special check for __KCC -# if !defined(_EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -# endif - -// -// last known and checked version is 4001: -#if (__KCC_VERSION > 4001) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/metrowerks.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/metrowerks.hpp deleted file mode 100644 index e1727860..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/metrowerks.hpp +++ /dev/null @@ -1,148 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright David Abrahams 2001 - 2002. -// (C) Copyright Beman Dawes 2001 - 2003. -// (C) Copyright Stefan Slapeta 2004. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Metrowerks C++ compiler setup: - -// locale support is disabled when linking with the dynamic runtime -# ifdef _MSL_NO_LOCALE -# define BOOST_NO_STD_LOCALE -# endif - -# if __MWERKS__ <= 0x2301 // 5.3 -# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# define BOOST_NO_POINTER_TO_MEMBER_CONST -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -# endif - -# if __MWERKS__ <= 0x2401 // 6.2 -//# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# endif - -# if(__MWERKS__ <= 0x2407) // 7.x -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -# define BOOST_NO_UNREACHABLE_RETURN_DETECTION -# endif - -# if(__MWERKS__ <= 0x3003) // 8.x -# define BOOST_NO_SFINAE -# endif - -// the "|| !defined(BOOST_STRICT_CONFIG)" part should apply to the last -// tested version *only*: -# if(__MWERKS__ <= 0x3207) || !defined(BOOST_STRICT_CONFIG) // 9.6 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_IS_ABSTRACT -# endif - -#if !__option(wchar_type) -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -#if !__option(exceptions) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -#if (__INTEL__ && _WIN32) || (__POWERPC__ && macintosh) -# if __MWERKS__ == 0x3000 -# define BOOST_COMPILER_VERSION 8.0 -# elif __MWERKS__ == 0x3001 -# define BOOST_COMPILER_VERSION 8.1 -# elif __MWERKS__ == 0x3002 -# define BOOST_COMPILER_VERSION 8.2 -# elif __MWERKS__ == 0x3003 -# define BOOST_COMPILER_VERSION 8.3 -# elif __MWERKS__ == 0x3200 -# define BOOST_COMPILER_VERSION 9.0 -# elif __MWERKS__ == 0x3201 -# define BOOST_COMPILER_VERSION 9.1 -# elif __MWERKS__ == 0x3202 -# define BOOST_COMPILER_VERSION 9.2 -# elif __MWERKS__ == 0x3204 -# define BOOST_COMPILER_VERSION 9.3 -# elif __MWERKS__ == 0x3205 -# define BOOST_COMPILER_VERSION 9.4 -# elif __MWERKS__ == 0x3206 -# define BOOST_COMPILER_VERSION 9.5 -# elif __MWERKS__ == 0x3207 -# define BOOST_COMPILER_VERSION 9.6 -# else -# define BOOST_COMPILER_VERSION __MWERKS__ -# endif -#else -# define BOOST_COMPILER_VERSION __MWERKS__ -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if __MWERKS__ > 0x3206 && __option(rvalue_refs) -# define BOOST_HAS_RVALUE_REFS -#else -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -#define BOOST_COMPILER "Metrowerks CodeWarrior C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) - -// -// versions check: -// we don't support Metrowerks prior to version 5.3: -#if __MWERKS__ < 0x2301 -# error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version: -#if (__MWERKS__ > 0x3205) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/mpw.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/mpw.hpp deleted file mode 100644 index 69104674..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/mpw.hpp +++ /dev/null @@ -1,90 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Aleksey Gurtovoy 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// MPW C++ compilers setup: - -# if defined(__SC__) -# define BOOST_COMPILER "MPW SCpp version " BOOST_STRINGIZE(__SC__) -# elif defined(__MRC__) -# define BOOST_COMPILER "MPW MrCpp version " BOOST_STRINGIZE(__MRC__) -# else -# error "Using MPW compiler configuration by mistake. Please update." -# endif - -// -// MPW 8.90: -// -#if (MPW_CPLUS <= 0x890) || !defined(BOOST_STRICT_CONFIG) -# define BOOST_NO_CV_SPECIALIZATIONS -# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS -# define BOOST_NO_DEPENDENT_TYPES_IN_TEMPLATE_VALUE_PARAMETERS -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_INTRINSIC_WCHAR_T -# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# define BOOST_NO_USING_TEMPLATE - -# define BOOST_NO_CWCHAR -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - -# define BOOST_NO_STD_ALLOCATOR /* actually a bug with const reference overloading */ - -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -// -// versions check: -// we don't support MPW prior to version 8.9: -#if MPW_CPLUS < 0x890 -# error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 0x890: -#if (MPW_CPLUS > 0x890) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/nvcc.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/nvcc.hpp deleted file mode 100644 index bbe81f6e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/nvcc.hpp +++ /dev/null @@ -1,16 +0,0 @@ -// (C) Copyright Eric Jourdanneau, Joel Falcou 2010 -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// NVIDIA CUDA C++ compiler setup - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "NVIDIA CUDA C++ Compiler" -#endif - -// NVIDIA Specific support -// BOOST_GPU_ENABLED : Flag a function or a method as being enabled on the host and device -#define BOOST_GPU_ENABLED __host__ __device__ diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pathscale.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pathscale.hpp deleted file mode 100644 index 567d83cc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pathscale.hpp +++ /dev/null @@ -1,83 +0,0 @@ -// (C) Copyright Bryce Lelbach 2011 - -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// PathScale EKOPath C++ Compiler - -#ifndef BOOST_COMPILER -# define BOOST_COMPILER "PathScale EKOPath C++ Compiler version " __PATHSCALE__ -#endif - -#if __PATHCC__ >= 4 -# define BOOST_MSVC6_MEMBER_TEMPLATES -# define BOOST_HAS_UNISTD_H -# define BOOST_HAS_STDINT_H -# define BOOST_HAS_SIGACTION -# define BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_THREADS -# define BOOST_HAS_PTHREADS -# define BOOST_HAS_PTHREAD_YIELD -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -# define BOOST_HAS_NRVO -# define BOOST_HAS_NL_TYPES_H -# define BOOST_HAS_NANOSLEEP -# define BOOST_HAS_LONG_LONG -# define BOOST_HAS_LOG1P -# define BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_EXPM1 -# define BOOST_HAS_DIRENT_H -# define BOOST_HAS_CLOCK_GETTIME -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_UNICODE_LITERALS -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_SFINAE_EXPR -# define BOOST_NO_CXX11_SCOPED_ENUMS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE_N3276 -# define BOOST_NO_CXX11_CONSTEXPR -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# define BOOST_NO_CXX11_CHAR32_T -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_USER_DEFINED_LITERALS -# define BOOST_NO_CXX11_ALIGNAS -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_INLINE_NAMESPACES -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pgi.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pgi.hpp deleted file mode 100644 index d50cbef8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/pgi.hpp +++ /dev/null @@ -1,125 +0,0 @@ -// (C) Copyright Noel Belcourt 2007. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// PGI C++ compiler setup: - -#define BOOST_COMPILER_VERSION __PGIC__##__PGIC_MINOR__ -#define BOOST_COMPILER "PGI compiler version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) - -// -// Threading support: -// Turn this on unconditionally here, it will get turned off again later -// if no threading API is detected. -// - -#if __PGIC__ >= 11 - -// options requested by configure --enable-test -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_THREADS -#define BOOST_HAS_PTHREAD_YIELD -#define BOOST_HAS_NRVO -#define BOOST_HAS_LONG_LONG - -// options --enable-test wants undefined -#undef BOOST_NO_STDC_NAMESPACE -#undef BOOST_NO_EXCEPTION_STD_NAMESPACE -#undef BOOST_DEDUCED_TYPENAME - -#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_AUTO_DECLARATIONS - -#elif __PGIC__ >= 10 - -// options requested by configure --enable-test -#define BOOST_HAS_THREADS -#define BOOST_HAS_NRVO -#define BOOST_HAS_LONG_LONG -#if defined(linux) || defined(__linux) || defined(__linux__) -# define BOOST_HAS_STDINT_H -#endif - -// options --enable-test wants undefined -#undef BOOST_NO_STDC_NAMESPACE -#undef BOOST_NO_EXCEPTION_STD_NAMESPACE -#undef BOOST_DEDUCED_TYPENAME - -#elif __PGIC__ >= 7 - -#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_NO_SWPRINTF -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_AUTO_DECLARATIONS - -#else - -# error "Pgi compiler not configured - please reconfigure" - -#endif -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_NUMERIC_LIMITS -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_SWPRINTF -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX - -#define BOOST_NO_CXX11_HDR_UNORDERED_SET -#define BOOST_NO_CXX11_HDR_UNORDERED_MAP -#define BOOST_NO_CXX11_HDR_TYPEINDEX -#define BOOST_NO_CXX11_HDR_TYPE_TRAITS -#define BOOST_NO_CXX11_HDR_TUPLE -#define BOOST_NO_CXX11_HDR_THREAD -#define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -#define BOOST_NO_CXX11_HDR_REGEX -#define BOOST_NO_CXX11_HDR_RATIO -#define BOOST_NO_CXX11_HDR_RANDOM -#define BOOST_NO_CXX11_HDR_MUTEX -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_HDR_FUTURE -#define BOOST_NO_CXX11_HDR_FORWARD_LIST -#define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -#define BOOST_NO_CXX11_HDR_CODECVT -#define BOOST_NO_CXX11_HDR_CHRONO -#define BOOST_NO_CXX11_HDR_ARRAY -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -// -// version check: -// probably nothing to do here? - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sgi_mipspro.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sgi_mipspro.hpp deleted file mode 100644 index 90688314..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sgi_mipspro.hpp +++ /dev/null @@ -1,29 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// SGI C++ compiler setup: - -#define BOOST_COMPILER "SGI Irix compiler version " BOOST_STRINGIZE(_COMPILER_VERSION) - -#include "boost/config/compiler/common_edg.hpp" - -// -// Threading support: -// Turn this on unconditionally here, it will get turned off again later -// if no threading API is detected. -// -#define BOOST_HAS_THREADS -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP - -#undef BOOST_NO_SWPRINTF -#undef BOOST_DEDUCED_TYPENAME - -// -// version check: -// probably nothing to do here? - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sunpro_cc.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sunpro_cc.hpp deleted file mode 100644 index 486d5c43..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/sunpro_cc.hpp +++ /dev/null @@ -1,153 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright Peter Dimov 2002. -// (C) Copyright Aleksey Gurtovoy 2002 - 2003. -// (C) Copyright David Abrahams 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Sun C++ compiler setup: - -# if __SUNPRO_CC <= 0x500 -# define BOOST_NO_MEMBER_TEMPLATES -# define BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# endif - -# if (__SUNPRO_CC <= 0x520) - // - // Sunpro 5.2 and earler: - // - // although sunpro 5.2 supports the syntax for - // inline initialization it often gets the value - // wrong, especially where the value is computed - // from other constants (J Maddock 6th May 2001) -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION - - // Although sunpro 5.2 supports the syntax for - // partial specialization, it often seems to - // bind to the wrong specialization. Better - // to disable it until suppport becomes more stable - // (J Maddock 6th May 2001). -# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# endif - -# if (__SUNPRO_CC <= 0x530) - // Requesting debug info (-g) with Boost.Python results - // in an internal compiler error for "static const" - // initialized in-class. - // >> Assertion: (../links/dbg_cstabs.cc, line 611) - // while processing ../test.cpp at line 0. - // (Jens Maurer according to Gottfried Ganssauge 04 Mar 2002) -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION - - // SunPro 5.3 has better support for partial specialization, - // but breaks when compiling std::less > - // (Jens Maurer 4 Nov 2001). - - // std::less specialization fixed as reported by George - // Heintzelman; partial specialization re-enabled - // (Peter Dimov 17 Jan 2002) - -//# define BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // integral constant expressions with 64 bit numbers fail -# define BOOST_NO_INTEGRAL_INT64_T -# endif - -# if (__SUNPRO_CC < 0x570) -# define BOOST_NO_TEMPLATE_TEMPLATES - // see http://lists.boost.org/MailArchives/boost/msg47184.php - // and http://lists.boost.org/MailArchives/boost/msg47220.php -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_SFINAE -# define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS -# endif -# if (__SUNPRO_CC <= 0x580) -# define BOOST_NO_IS_ABSTRACT -# endif - -# if (__SUNPRO_CC <= 0x5100) - // Sun 5.10 may not correctly value-initialize objects of - // some user defined types, as was reported in April 2010 - // (CR 6947016), and confirmed by Steve Clamage. - // (Niels Dekker, LKEB, May 2010). -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -# endif - -// -// Dynamic shared object (DSO) and dynamic-link library (DLL) support -// -#if __SUNPRO_CC > 0x500 -# define BOOST_SYMBOL_EXPORT __global -# define BOOST_SYMBOL_IMPORT __global -# define BOOST_SYMBOL_VISIBLE __global -#endif - - - -// -// Issues that effect all known versions: -// -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_NO_ADL_BARRIER - -// -// C++0x features -// -# define BOOST_HAS_LONG_LONG - -#define BOOST_NO_CXX11_AUTO_DECLARATIONS -#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_RVALUE_REFERENCES -#define BOOST_NO_CXX11_SCOPED_ENUMS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_STATIC_ASSERT -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#define BOOST_NO_CXX11_VARIADIC_MACROS -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -// -// Version -// - -#define BOOST_COMPILER "Sun compiler version " BOOST_STRINGIZE(__SUNPRO_CC) - -// -// versions check: -// we don't support sunpro prior to version 4: -#if __SUNPRO_CC < 0x400 -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 0x590: -#if (__SUNPRO_CC > 0x590) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/vacpp.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/vacpp.hpp deleted file mode 100644 index 17c02f91..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/vacpp.hpp +++ /dev/null @@ -1,131 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Toon Knapen 2001 - 2003. -// (C) Copyright Lie-Quan Lee 2001. -// (C) Copyright Markus Schoepflin 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Visual Age (IBM) C++ compiler setup: - -#if __IBMCPP__ <= 501 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -# define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS -#endif - -#if (__IBMCPP__ <= 502) -// Actually the compiler supports inclass member initialization but it -// requires a definition for the class member and it doesn't recognize -// it as an integral constant expression when used as a template argument. -# define BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_NO_INTEGRAL_INT64_T -# define BOOST_NO_MEMBER_TEMPLATE_KEYWORD -#endif - -#if (__IBMCPP__ <= 600) || !defined(BOOST_STRICT_CONFIG) -# define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS -#endif - -#if (__IBMCPP__ <= 1110) -// XL C++ V11.1 and earlier versions may not always value-initialize -// a temporary object T(), when T is a non-POD aggregate class type. -// Michael Wong (IBM Canada Ltd) has confirmed this issue and gave it -// high priority. -- Niels Dekker (LKEB), May 2010. -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION -#endif - -// -// On AIX thread support seems to be indicated by _THREAD_SAFE: -// -#ifdef _THREAD_SAFE -# define BOOST_HAS_THREADS -#endif - -#define BOOST_COMPILER "IBM Visual Age version " BOOST_STRINGIZE(__IBMCPP__) - -// -// versions check: -// we don't support Visual age prior to version 5: -#if __IBMCPP__ < 500 -#error "Compiler not supported or configured - please reconfigure" -#endif -// -// last known and checked version is 1210: -#if (__IBMCPP__ > 1210) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# endif -#endif - -// Some versions of the compiler have issues with default arguments on partial specializations -#if __IBMCPP__ <= 1010 -#define BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS -#endif - -// -// C++0x features -// -// See boost\config\suffix.hpp for BOOST_NO_LONG_LONG -// -#if ! __IBMCPP_AUTO_TYPEDEDUCTION -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -#endif -#if ! __IBMCPP_UTF_LITERAL__ -# define BOOST_NO_CXX11_CHAR16_T -# define BOOST_NO_CXX11_CHAR32_T -#endif -#if ! __IBMCPP_CONSTEXPR -# define BOOST_NO_CXX11_CONSTEXPR -#endif -#if ! __IBMCPP_DECLTYPE -# define BOOST_NO_CXX11_DECLTYPE -#else -# define BOOST_HAS_DECLTYPE -#endif -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -#define BOOST_NO_CXX11_DELETED_FUNCTIONS -#if ! __IBMCPP_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -#endif -#if ! __IBMCPP_EXTERN_TEMPLATE -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -#endif -#if ! __IBMCPP_VARIADIC_TEMPLATES -// not enabled separately at this time -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif -#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#define BOOST_NO_CXX11_LAMBDAS -#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_NULLPTR -#define BOOST_NO_CXX11_RANGE_BASED_FOR -#define BOOST_NO_CXX11_RAW_LITERALS -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#if ! __IBMCPP_RVALUE_REFERENCES -# define BOOST_NO_CXX11_RVALUE_REFERENCES -#endif -#if ! __IBMCPP_SCOPED_ENUM -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#if ! __IBMCPP_STATIC_ASSERT -# define BOOST_NO_CXX11_STATIC_ASSERT -#endif -#define BOOST_NO_CXX11_TEMPLATE_ALIASES -#define BOOST_NO_CXX11_UNICODE_LITERALS -#if ! __IBMCPP_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -#endif -#if ! __C99_MACRO_WITH_VA_ARGS -# define BOOST_NO_CXX11_VARIADIC_MACROS -#endif -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -#define BOOST_NO_CXX11_INLINE_NAMESPACES diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/visualc.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/compiler/visualc.hpp deleted file mode 100644 index 695fa943..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/compiler/visualc.hpp +++ /dev/null @@ -1,276 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright Aleksey Gurtovoy 2002. -// (C) Copyright David Abrahams 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. -// -// Microsoft Visual C++ compiler setup: -// -// We need to be careful with the checks in this file, as contrary -// to popular belief there are versions with _MSC_VER with the final -// digit non-zero (mainly the MIPS cross compiler). -// -// So we either test _MSC_VER >= XXXX or else _MSC_VER < XXXX. -// No other comparisons (==, >, or <=) are safe. -// - -#define BOOST_MSVC _MSC_VER - -// -// Helper macro BOOST_MSVC_FULL_VER for use in Boost code: -// -#if _MSC_FULL_VER > 100000000 -# define BOOST_MSVC_FULL_VER _MSC_FULL_VER -#else -# define BOOST_MSVC_FULL_VER (_MSC_FULL_VER * 10) -#endif - -// Attempt to suppress VC6 warnings about the length of decorated names (obsolete): -#pragma warning( disable : 4503 ) // warning: decorated name length exceeded - -#define BOOST_HAS_PRAGMA_ONCE - -// -// versions check: -// we don't support Visual C++ prior to version 7.1: -#if _MSC_VER < 1310 -# error "Compiler not supported or configured - please reconfigure" -#endif - -#if _MSC_FULL_VER < 180020827 -# define BOOST_NO_FENV_H -#endif - -#if _MSC_VER < 1400 -// although a conforming signature for swprint exists in VC7.1 -// it appears not to actually work: -# define BOOST_NO_SWPRINTF -// Our extern template tests also fail for this compiler: -# define BOOST_NO_CXX11_EXTERN_TEMPLATE -// Variadic macros do not exist for VC7.1 and lower -# define BOOST_NO_CXX11_VARIADIC_MACROS -#endif - -#if defined(UNDER_CE) -// Windows CE does not have a conforming signature for swprintf -# define BOOST_NO_SWPRINTF -#endif - -#if _MSC_VER < 1500 // 140X == VC++ 8.0 -# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS -#endif - -#if _MSC_VER < 1600 // 150X == VC++ 9.0 - // A bug in VC9: -# define BOOST_NO_ADL_BARRIER -#endif - - -// MSVC (including the latest checked version) has not yet completely -// implemented value-initialization, as is reported: -// "VC++ does not value-initialize members of derived classes without -// user-declared constructor", reported in 2009 by Sylvester Hesp: -// https://connect.microsoft.com/VisualStudio/feedback/details/484295 -// "Presence of copy constructor breaks member class initialization", -// reported in 2009 by Alex Vakulenko: -// https://connect.microsoft.com/VisualStudio/feedback/details/499606 -// "Value-initialization in new-expression", reported in 2005 by -// Pavel Kuznetsov (MetaCommunications Engineering): -// https://connect.microsoft.com/VisualStudio/feedback/details/100744 -// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues -// (Niels Dekker, LKEB, May 2010) -# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION - -#ifndef _NATIVE_WCHAR_T_DEFINED -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -#if defined(_WIN32_WCE) || defined(UNDER_CE) -# define BOOST_NO_SWPRINTF -#endif - -// we have ThreadEx or GetSystemTimeAsFileTime unless we're running WindowsCE -#if !defined(_WIN32_WCE) && !defined(UNDER_CE) -# define BOOST_HAS_THREADEX -# define BOOST_HAS_GETSYSTEMTIMEASFILETIME -#endif - -// -// check for exception handling support: -#if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS) -# define BOOST_NO_EXCEPTIONS -#endif - -// -// __int64 support: -// -#define BOOST_HAS_MS_INT64 -#if defined(_MSC_EXTENSIONS) || (_MSC_VER >= 1400) -# define BOOST_HAS_LONG_LONG -#else -# define BOOST_NO_LONG_LONG -#endif -#if (_MSC_VER >= 1400) && !defined(_DEBUG) -# define BOOST_HAS_NRVO -#endif -// -// disable Win32 API's if compiler extentions are -// turned off: -// -#if !defined(_MSC_EXTENSIONS) && !defined(BOOST_DISABLE_WIN32) -# define BOOST_DISABLE_WIN32 -#endif -#if !defined(_CPPRTTI) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -// -// TR1 features: -// -#if _MSC_VER >= 1700 -// # define BOOST_HAS_TR1_HASH // don't know if this is true yet. -// # define BOOST_HAS_TR1_TYPE_TRAITS // don't know if this is true yet. -# define BOOST_HAS_TR1_UNORDERED_MAP -# define BOOST_HAS_TR1_UNORDERED_SET -#endif - -// -// C++0x features -// -// See above for BOOST_NO_LONG_LONG - -// C++ features supported by VC++ 10 (aka 2010) -// -#if _MSC_VER < 1600 -# define BOOST_NO_CXX11_AUTO_DECLARATIONS -# define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -# define BOOST_NO_CXX11_LAMBDAS -# define BOOST_NO_CXX11_RVALUE_REFERENCES -# define BOOST_NO_CXX11_STATIC_ASSERT -# define BOOST_NO_CXX11_NULLPTR -# define BOOST_NO_CXX11_DECLTYPE -#endif // _MSC_VER < 1600 - -#if _MSC_VER >= 1600 -# define BOOST_HAS_STDINT_H -#endif - -// C++11 features supported by VC++ 11 (aka 2012) -// -#if _MSC_VER < 1700 -# define BOOST_NO_CXX11_RANGE_BASED_FOR -# define BOOST_NO_CXX11_SCOPED_ENUMS -#endif // _MSC_VER < 1700 - -// C++11 features supported by VC++ 12 (aka 2013). -// -#if _MSC_FULL_VER < 180020827 -# define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS -# define BOOST_NO_CXX11_DELETED_FUNCTIONS -# define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS -# define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS -# define BOOST_NO_CXX11_RAW_LITERALS -# define BOOST_NO_CXX11_TEMPLATE_ALIASES -# define BOOST_NO_CXX11_TRAILING_RESULT_TYPES -# define BOOST_NO_CXX11_VARIADIC_TEMPLATES -# define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX -#endif - -// C++11 features not supported by any versions -#define BOOST_NO_CXX11_CHAR16_T -#define BOOST_NO_CXX11_CHAR32_T -#define BOOST_NO_CXX11_CONSTEXPR -#define BOOST_NO_CXX11_DECLTYPE_N3276 -#define BOOST_NO_CXX11_NOEXCEPT -#define BOOST_NO_CXX11_UNICODE_LITERALS -#define BOOST_NO_SFINAE_EXPR -#define BOOST_NO_TWO_PHASE_NAME_LOOKUP -#define BOOST_NO_CXX11_USER_DEFINED_LITERALS -#define BOOST_NO_CXX11_ALIGNAS -#define BOOST_NO_CXX11_INLINE_NAMESPACES - -// -// prefix and suffix headers: -// -#ifndef BOOST_ABI_PREFIX -# define BOOST_ABI_PREFIX "boost/config/abi/msvc_prefix.hpp" -#endif -#ifndef BOOST_ABI_SUFFIX -# define BOOST_ABI_SUFFIX "boost/config/abi/msvc_suffix.hpp" -#endif - -#ifndef BOOST_COMPILER -// TODO: -// these things are mostly bogus. 1200 means version 12.0 of the compiler. The -// artificial versions assigned to them only refer to the versions of some IDE -// these compilers have been shipped with, and even that is not all of it. Some -// were shipped with freely downloadable SDKs, others as crosscompilers in eVC. -// IOW, you can't use these 'versions' in any sensible way. Sorry. -# if defined(UNDER_CE) -# if _MSC_VER < 1400 - // Note: I'm not aware of any CE compiler with version 13xx -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown EVC++ compiler version - please run the configure tests and report the results" -# else -# pragma message("Unknown EVC++ compiler version - please run the configure tests and report the results") -# endif -# elif _MSC_VER < 1500 -# define BOOST_COMPILER_VERSION evc8 -# elif _MSC_VER < 1600 -# define BOOST_COMPILER_VERSION evc9 -# elif _MSC_VER < 1700 -# define BOOST_COMPILER_VERSION evc10 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION evc11 -# elif _MSC_VER < 1900 -# define BOOST_COMPILER_VERSION evc12 -# else -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown EVC++ compiler version - please run the configure tests and report the results" -# else -# pragma message("Unknown EVC++ compiler version - please run the configure tests and report the results") -# endif -# endif -# else -# if _MSC_VER < 1310 - // Note: Versions up to 7.0 aren't supported. -# define BOOST_COMPILER_VERSION 5.0 -# elif _MSC_VER < 1300 -# define BOOST_COMPILER_VERSION 6.0 -# elif _MSC_VER < 1310 -# define BOOST_COMPILER_VERSION 7.0 -# elif _MSC_VER < 1400 -# define BOOST_COMPILER_VERSION 7.1 -# elif _MSC_VER < 1500 -# define BOOST_COMPILER_VERSION 8.0 -# elif _MSC_VER < 1600 -# define BOOST_COMPILER_VERSION 9.0 -# elif _MSC_VER < 1700 -# define BOOST_COMPILER_VERSION 10.0 -# elif _MSC_VER < 1800 -# define BOOST_COMPILER_VERSION 11.0 -# elif _MSC_VER < 1900 -# define BOOST_COMPILER_VERSION 12.0 -# else -# define BOOST_COMPILER_VERSION _MSC_VER -# endif -# endif - -# define BOOST_COMPILER "Microsoft Visual C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) -#endif - -// -// last known and checked version is 18.00.20827.3 (VC12 RC, aka 2013 RC): -#if (_MSC_VER > 1800 && _MSC_FULL_VER > 180020827) -# if defined(BOOST_ASSERT_CONFIG) -# error "Unknown compiler version - please run the configure tests and report the results" -# else -# pragma message("Unknown compiler version - please run the configure tests and report the results") -# endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/cmath.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/cmath.hpp deleted file mode 100644 index d8268d84..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/cmath.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2008. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// The aim of this header is just to include but to do -// so in a way that does not result in recursive inclusion of -// the Boost TR1 components if boost/tr1/tr1/cmath is in the -// include search path. We have to do this to avoid circular -// dependencies: -// - -#ifndef BOOST_CONFIG_CMATH -# define BOOST_CONFIG_CMATH - -# ifndef BOOST_TR1_NO_RECURSION -# define BOOST_TR1_NO_RECURSION -# define BOOST_CONFIG_NO_CMATH_RECURSION -# endif - -# include - -# ifdef BOOST_CONFIG_NO_CMATH_RECURSION -# undef BOOST_TR1_NO_RECURSION -# undef BOOST_CONFIG_NO_CMATH_RECURSION -# endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/complex.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/complex.hpp deleted file mode 100644 index ca200922..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/complex.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// The aim of this header is just to include but to do -// so in a way that does not result in recursive inclusion of -// the Boost TR1 components if boost/tr1/tr1/complex is in the -// include search path. We have to do this to avoid circular -// dependencies: -// - -#ifndef BOOST_CONFIG_COMPLEX -# define BOOST_CONFIG_COMPLEX - -# ifndef BOOST_TR1_NO_RECURSION -# define BOOST_TR1_NO_RECURSION -# define BOOST_CONFIG_NO_COMPLEX_RECURSION -# endif - -# include - -# ifdef BOOST_CONFIG_NO_COMPLEX_RECURSION -# undef BOOST_TR1_NO_RECURSION -# undef BOOST_CONFIG_NO_COMPLEX_RECURSION -# endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/functional.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/functional.hpp deleted file mode 100644 index e395efc1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/functional.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// The aim of this header is just to include but to do -// so in a way that does not result in recursive inclusion of -// the Boost TR1 components if boost/tr1/tr1/functional is in the -// include search path. We have to do this to avoid circular -// dependencies: -// - -#ifndef BOOST_CONFIG_FUNCTIONAL -# define BOOST_CONFIG_FUNCTIONAL - -# ifndef BOOST_TR1_NO_RECURSION -# define BOOST_TR1_NO_RECURSION -# define BOOST_CONFIG_NO_FUNCTIONAL_RECURSION -# endif - -# include - -# ifdef BOOST_CONFIG_NO_FUNCTIONAL_RECURSION -# undef BOOST_TR1_NO_RECURSION -# undef BOOST_CONFIG_NO_FUNCTIONAL_RECURSION -# endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/memory.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/memory.hpp deleted file mode 100644 index 2b5d2080..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/memory.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// The aim of this header is just to include but to do -// so in a way that does not result in recursive inclusion of -// the Boost TR1 components if boost/tr1/tr1/memory is in the -// include search path. We have to do this to avoid circular -// dependencies: -// - -#ifndef BOOST_CONFIG_MEMORY -# define BOOST_CONFIG_MEMORY - -# ifndef BOOST_TR1_NO_RECURSION -# define BOOST_TR1_NO_RECURSION -# define BOOST_CONFIG_NO_MEMORY_RECURSION -# endif - -# include - -# ifdef BOOST_CONFIG_NO_MEMORY_RECURSION -# undef BOOST_TR1_NO_RECURSION -# undef BOOST_CONFIG_NO_MEMORY_RECURSION -# endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/utility.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/utility.hpp deleted file mode 100644 index dea8f115..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/no_tr1/utility.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// The aim of this header is just to include but to do -// so in a way that does not result in recursive inclusion of -// the Boost TR1 components if boost/tr1/tr1/utility is in the -// include search path. We have to do this to avoid circular -// dependencies: -// - -#ifndef BOOST_CONFIG_UTILITY -# define BOOST_CONFIG_UTILITY - -# ifndef BOOST_TR1_NO_RECURSION -# define BOOST_TR1_NO_RECURSION -# define BOOST_CONFIG_NO_UTILITY_RECURSION -# endif - -# include - -# ifdef BOOST_CONFIG_NO_UTILITY_RECURSION -# undef BOOST_TR1_NO_RECURSION -# undef BOOST_CONFIG_NO_UTILITY_RECURSION -# endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/aix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/aix.hpp deleted file mode 100644 index 894ef42c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/aix.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// IBM/Aix specific config options: - -#define BOOST_PLATFORM "IBM Aix" - -#define BOOST_HAS_UNISTD_H -#define BOOST_HAS_NL_TYPES_H -#define BOOST_HAS_NANOSLEEP -#define BOOST_HAS_CLOCK_GETTIME - -// This needs support in "boost/cstdint.hpp" exactly like FreeBSD. -// This platform has header named which includes all -// the things needed. -#define BOOST_HAS_STDINT_H - -// Threading API's: -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_PTHREAD_DELAY_NP -#define BOOST_HAS_SCHED_YIELD -//#define BOOST_HAS_PTHREAD_YIELD - -// boilerplate code: -#include - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/amigaos.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/amigaos.hpp deleted file mode 100644 index 34bcf412..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/amigaos.hpp +++ /dev/null @@ -1,15 +0,0 @@ -// (C) Copyright John Maddock 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -#define BOOST_PLATFORM "AmigaOS" - -#define BOOST_DISABLE_THREADS -#define BOOST_NO_CWCHAR -#define BOOST_NO_STD_WSTRING -#define BOOST_NO_INTRINSIC_WCHAR_T - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/beos.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/beos.hpp deleted file mode 100644 index 48c3d8dc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/beos.hpp +++ /dev/null @@ -1,26 +0,0 @@ -// (C) Copyright John Maddock 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// BeOS specific config options: - -#define BOOST_PLATFORM "BeOS" - -#define BOOST_NO_CWCHAR -#define BOOST_NO_CWCTYPE -#define BOOST_HAS_UNISTD_H - -#define BOOST_HAS_BETHREADS - -#ifndef BOOST_DISABLE_THREADS -# define BOOST_HAS_THREADS -#endif - -// boilerplate code: -#include - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/bsd.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/bsd.hpp deleted file mode 100644 index a0142978..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/bsd.hpp +++ /dev/null @@ -1,86 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Douglas Gregor 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// generic BSD config options: - -#if !defined(__FreeBSD__) && !defined(__NetBSD__) && !defined(__OpenBSD__) && !defined(__DragonFly__) -#error "This platform is not BSD" -#endif - -#ifdef __FreeBSD__ -#define BOOST_PLATFORM "FreeBSD " BOOST_STRINGIZE(__FreeBSD__) -#elif defined(__NetBSD__) -#define BOOST_PLATFORM "NetBSD " BOOST_STRINGIZE(__NetBSD__) -#elif defined(__OpenBSD__) -#define BOOST_PLATFORM "OpenBSD " BOOST_STRINGIZE(__OpenBSD__) -#elif defined(__DragonFly__) -#define BOOST_PLATFORM "DragonFly " BOOST_STRINGIZE(__DragonFly__) -#endif - -// -// is this the correct version check? -// FreeBSD has but does not -// advertise the fact in : -// -#if (defined(__FreeBSD__) && (__FreeBSD__ >= 3)) || defined(__DragonFly__) -# define BOOST_HAS_NL_TYPES_H -#endif - -// -// FreeBSD 3.x has pthreads support, but defines _POSIX_THREADS in -// and not in -// -#if (defined(__FreeBSD__) && (__FreeBSD__ <= 3))\ - || defined(__OpenBSD__) || defined(__DragonFly__) -# define BOOST_HAS_PTHREADS -#endif - -// -// No wide character support in the BSD header files: -// -#if defined(__NetBSD__) -#define __NetBSD_GCC__ (__GNUC__ * 1000000 \ - + __GNUC_MINOR__ * 1000 \ - + __GNUC_PATCHLEVEL__) -// XXX - the following is required until c++config.h -// defines _GLIBCXX_HAVE_SWPRINTF and friends -// or the preprocessor conditionals are removed -// from the cwchar header. -#define _GLIBCXX_HAVE_SWPRINTF 1 -#endif - -#if !((defined(__FreeBSD__) && (__FreeBSD__ >= 5)) \ - || (defined(__NetBSD_GCC__) && (__NetBSD_GCC__ >= 2095003)) || defined(__DragonFly__)) -# define BOOST_NO_CWCHAR -#endif -// -// The BSD has macros only, no functions: -// -#if !defined(__OpenBSD__) || defined(__DragonFly__) -# define BOOST_NO_CTYPE_FUNCTIONS -#endif - -// -// thread API's not auto detected: -// -#define BOOST_HAS_SCHED_YIELD -#define BOOST_HAS_NANOSLEEP -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -#define BOOST_HAS_SIGACTION - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/cray.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/cray.hpp deleted file mode 100644 index 5c476e41..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/cray.hpp +++ /dev/null @@ -1,18 +0,0 @@ -// (C) Copyright John Maddock 2011. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -// See http://www.boost.org for most recent version. - -// SGI Irix specific config options: - -#define BOOST_PLATFORM "Cray" - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/cygwin.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/cygwin.hpp deleted file mode 100644 index b7ef572f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/cygwin.hpp +++ /dev/null @@ -1,58 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// cygwin specific config options: - -#define BOOST_PLATFORM "Cygwin" -#define BOOST_HAS_DIRENT_H -#define BOOST_HAS_LOG1P -#define BOOST_HAS_EXPM1 - -// -// Threading API: -// See if we have POSIX threads, if we do use them, otherwise -// revert to native Win threads. -#define BOOST_HAS_UNISTD_H -#include -#if defined(_POSIX_THREADS) && (_POSIX_THREADS+0 >= 0) && !defined(BOOST_HAS_WINTHREADS) -# define BOOST_HAS_PTHREADS -# define BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_SIGACTION -#else -# if !defined(BOOST_HAS_WINTHREADS) -# define BOOST_HAS_WINTHREADS -# endif -# define BOOST_HAS_FTIME -#endif - -// -// find out if we have a stdint.h, there should be a better way to do this: -// -#include -#ifdef _STDINT_H -#define BOOST_HAS_STDINT_H -#endif - -/// Cygwin has no fenv.h -#define BOOST_NO_FENV_H - -// boilerplate code: -#include - -// -// Cygwin lies about XSI conformance, there is no nl_types.h: -// -#ifdef BOOST_HAS_NL_TYPES_H -# undef BOOST_HAS_NL_TYPES_H -#endif - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/hpux.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/hpux.hpp deleted file mode 100644 index 19ce68e5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/hpux.hpp +++ /dev/null @@ -1,87 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Toon Knapen 2003. -// (C) Copyright Boris Gubenko 2006 - 2007. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// hpux specific config options: - -#define BOOST_PLATFORM "HP-UX" - -// In principle, HP-UX has a nice under the name -// However, it has the following problem: -// Use of UINT32_C(0) results in "0u l" for the preprocessed source -// (verifyable with gcc 2.95.3) -#if (defined(__GNUC__) && (__GNUC__ >= 3)) || defined(__HP_aCC) -# define BOOST_HAS_STDINT_H -#endif - -#if !(defined(__HP_aCC) || !defined(_INCLUDE__STDC_A1_SOURCE)) -# define BOOST_NO_SWPRINTF -#endif -#if defined(__HP_aCC) && !defined(_INCLUDE__STDC_A1_SOURCE) -# define BOOST_NO_CWCTYPE -#endif - -#if defined(__GNUC__) -# if (__GNUC__ < 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ < 3)) - // GNU C on HP-UX does not support threads (checked up to gcc 3.3) -# define BOOST_DISABLE_THREADS -# elif !defined(BOOST_DISABLE_THREADS) - // threads supported from gcc-3.3 onwards: -# define BOOST_HAS_THREADS -# define BOOST_HAS_PTHREADS -# endif -#elif defined(__HP_aCC) && !defined(BOOST_DISABLE_THREADS) -# define BOOST_HAS_PTHREADS -#endif - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include - -// the following are always available: -#ifndef BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_GETTIMEOFDAY -#endif -#ifndef BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_SCHED_YIELD -#endif -#ifndef BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -#endif -#ifndef BOOST_HAS_NL_TYPES_H -# define BOOST_HAS_NL_TYPES_H -#endif -#ifndef BOOST_HAS_NANOSLEEP -# define BOOST_HAS_NANOSLEEP -#endif -#ifndef BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_GETTIMEOFDAY -#endif -#ifndef BOOST_HAS_DIRENT_H -# define BOOST_HAS_DIRENT_H -#endif -#ifndef BOOST_HAS_CLOCK_GETTIME -# define BOOST_HAS_CLOCK_GETTIME -#endif -#ifndef BOOST_HAS_SIGACTION -# define BOOST_HAS_SIGACTION -#endif -#ifndef BOOST_HAS_NRVO -# ifndef __parisc -# define BOOST_HAS_NRVO -# endif -#endif -#ifndef BOOST_HAS_LOG1P -# define BOOST_HAS_LOG1P -#endif -#ifndef BOOST_HAS_EXPM1 -# define BOOST_HAS_EXPM1 -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/irix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/irix.hpp deleted file mode 100644 index aeae49c8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/irix.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -// See http://www.boost.org for most recent version. - -// SGI Irix specific config options: - -#define BOOST_PLATFORM "SGI Irix" - -#define BOOST_NO_SWPRINTF -// -// these are not auto detected by POSIX feature tests: -// -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE - -#ifdef __GNUC__ - // GNU C on IRIX does not support threads (checked up to gcc 3.3) -# define BOOST_DISABLE_THREADS -#endif - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/linux.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/linux.hpp deleted file mode 100644 index a02aff78..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/linux.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// linux specific config options: - -#define BOOST_PLATFORM "linux" - -// make sure we have __GLIBC_PREREQ if available at all -#ifdef __cplusplus -#include -#else -#include -#endif - -// -// added to glibc 2.1.1 -// We can only test for 2.1 though: -// -#if defined(__GLIBC__) && ((__GLIBC__ > 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ >= 1))) - // defines int64_t unconditionally, but defines - // int64_t only if __GNUC__. Thus, assume a fully usable - // only when using GCC. -# if defined __GNUC__ -# define BOOST_HAS_STDINT_H -# endif -#endif - -#if defined(__LIBCOMO__) - // - // como on linux doesn't have std:: c functions: - // NOTE: versions of libcomo prior to beta28 have octal version numbering, - // e.g. version 25 is 21 (dec) - // -# if __LIBCOMO_VERSION__ <= 20 -# define BOOST_NO_STDC_NAMESPACE -# endif - -# if __LIBCOMO_VERSION__ <= 21 -# define BOOST_NO_SWPRINTF -# endif - -#endif - -// -// If glibc is past version 2 then we definitely have -// gettimeofday, earlier versions may or may not have it: -// -#if defined(__GLIBC__) && (__GLIBC__ >= 2) -# define BOOST_HAS_GETTIMEOFDAY -#endif - -#ifdef __USE_POSIX199309 -# define BOOST_HAS_NANOSLEEP -#endif - -#if defined(__GLIBC__) && defined(__GLIBC_PREREQ) -// __GLIBC_PREREQ is available since 2.1.2 - - // swprintf is available since glibc 2.2.0 -# if !__GLIBC_PREREQ(2,2) || (!defined(__USE_ISOC99) && !defined(__USE_UNIX98)) -# define BOOST_NO_SWPRINTF -# endif -#else -# define BOOST_NO_SWPRINTF -#endif - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include -#define BOOST_HAS_PTHREAD_YIELD - -#ifndef __GNUC__ -// -// if the compiler is not gcc we still need to be able to parse -// the GNU system headers, some of which (mainly ) -// use GNU specific extensions: -// -# ifndef __extension__ -# define __extension__ -# endif -# ifndef __const__ -# define __const__ const -# endif -# ifndef __volatile__ -# define __volatile__ volatile -# endif -# ifndef __signed__ -# define __signed__ signed -# endif -# ifndef __typeof__ -# define __typeof__ typeof -# endif -# ifndef __inline__ -# define __inline__ inline -# endif -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/macos.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/macos.hpp deleted file mode 100644 index 6d876b12..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/macos.hpp +++ /dev/null @@ -1,87 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001 - 2002. -// (C) Copyright Bill Kempf 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Mac OS specific config options: - -#define BOOST_PLATFORM "Mac OS" - -#if __MACH__ && !defined(_MSL_USING_MSL_C) - -// Using the Mac OS X system BSD-style C library. - -# ifndef BOOST_HAS_UNISTD_H -# define BOOST_HAS_UNISTD_H -# endif -// -// Begin by including our boilerplate code for POSIX -// feature detection, this is safe even when using -// the MSL as Metrowerks supply their own -// to replace the platform-native BSD one. G++ users -// should also always be able to do this on MaxOS X. -// -# include -# ifndef BOOST_HAS_STDINT_H -# define BOOST_HAS_STDINT_H -# endif - -// -// BSD runtime has pthreads, sigaction, sched_yield and gettimeofday, -// of these only pthreads are advertised in , so set the -// other options explicitly: -// -# define BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_SIGACTION - -# if (__GNUC__ < 3) && !defined( __APPLE_CC__) - -// GCC strange "ignore std" mode works better if you pretend everything -// is in the std namespace, for the most part. - -# define BOOST_NO_STDC_NAMESPACE -# endif - -# if (__GNUC__ == 4) - -// Both gcc and intel require these. -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_NANOSLEEP - -# endif - -#else - -// Using the MSL C library. - -// We will eventually support threads in non-Carbon builds, but we do -// not support this yet. -# if ( defined(TARGET_API_MAC_CARBON) && TARGET_API_MAC_CARBON ) || ( defined(TARGET_CARBON) && TARGET_CARBON ) - -# if !defined(BOOST_HAS_PTHREADS) -// MPTasks support is deprecated/removed from Boost: -//# define BOOST_HAS_MPTASKS -# elif ( __dest_os == __mac_os_x ) -// We are doing a Carbon/Mach-O/MSL build which has pthreads, but only the -// gettimeofday and no posix. -# define BOOST_HAS_GETTIMEOFDAY -# endif - -#ifdef BOOST_HAS_PTHREADS -# define BOOST_HAS_THREADS -#endif - -// The remote call manager depends on this. -# define BOOST_BIND_ENABLE_PASCAL - -# endif - -#endif - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/qnxnto.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/qnxnto.hpp deleted file mode 100644 index b1377c8d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/qnxnto.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// (C) Copyright Jim Douglas 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// QNX specific config options: - -#define BOOST_PLATFORM "QNX" - -#define BOOST_HAS_UNISTD_H -#include - -// QNX claims XOpen version 5 compatibility, but doesn't have an nl_types.h -// or log1p and expm1: -#undef BOOST_HAS_NL_TYPES_H -#undef BOOST_HAS_LOG1P -#undef BOOST_HAS_EXPM1 - -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE - -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_CLOCK_GETTIME -#define BOOST_HAS_NANOSLEEP - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/solaris.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/solaris.hpp deleted file mode 100644 index 9f925666..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/solaris.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// sun specific config options: - -#define BOOST_PLATFORM "Sun Solaris" - -#define BOOST_HAS_GETTIMEOFDAY - -// boilerplate code: -#define BOOST_HAS_UNISTD_H -#include - -// -// pthreads don't actually work with gcc unless _PTHREADS is defined: -// -#if defined(__GNUC__) && defined(_POSIX_THREADS) && !defined(_PTHREADS) -# undef BOOST_HAS_PTHREADS -#endif - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/symbian.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/symbian.hpp deleted file mode 100644 index e02a7782..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/symbian.hpp +++ /dev/null @@ -1,97 +0,0 @@ -// (C) Copyright Yuriy Krasnoschek 2009. -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// symbian specific config options: - - -#define BOOST_PLATFORM "Symbian" -#define BOOST_SYMBIAN 1 - - -#if defined(__S60_3X__) -// Open C / C++ plugin was introdused in this SDK, earlier versions don't have CRT / STL -# define BOOST_S60_3rd_EDITION_FP2_OR_LATER_SDK -// make sure we have __GLIBC_PREREQ if available at all -#ifdef __cplusplus -#include -#else -#include -#endif// boilerplate code: -# define BOOST_HAS_UNISTD_H -# include -// S60 SDK defines _POSIX_VERSION as POSIX.1 -# ifndef BOOST_HAS_STDINT_H -# define BOOST_HAS_STDINT_H -# endif -# ifndef BOOST_HAS_GETTIMEOFDAY -# define BOOST_HAS_GETTIMEOFDAY -# endif -# ifndef BOOST_HAS_DIRENT_H -# define BOOST_HAS_DIRENT_H -# endif -# ifndef BOOST_HAS_SIGACTION -# define BOOST_HAS_SIGACTION -# endif -# ifndef BOOST_HAS_PTHREADS -# define BOOST_HAS_PTHREADS -# endif -# ifndef BOOST_HAS_NANOSLEEP -# define BOOST_HAS_NANOSLEEP -# endif -# ifndef BOOST_HAS_SCHED_YIELD -# define BOOST_HAS_SCHED_YIELD -# endif -# ifndef BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# endif -# ifndef BOOST_HAS_LOG1P -# define BOOST_HAS_LOG1P -# endif -# ifndef BOOST_HAS_EXPM1 -# define BOOST_HAS_EXPM1 -# endif -# ifndef BOOST_POSIX_API -# define BOOST_POSIX_API -# endif -// endianess support -# include -// Symbian SDK provides _BYTE_ORDER instead of __BYTE_ORDER -# ifndef __LITTLE_ENDIAN -# ifdef _LITTLE_ENDIAN -# define __LITTLE_ENDIAN _LITTLE_ENDIAN -# else -# define __LITTLE_ENDIAN 1234 -# endif -# endif -# ifndef __BIG_ENDIAN -# ifdef _BIG_ENDIAN -# define __BIG_ENDIAN _BIG_ENDIAN -# else -# define __BIG_ENDIAN 4321 -# endif -# endif -# ifndef __BYTE_ORDER -# define __BYTE_ORDER __LITTLE_ENDIAN // Symbian is LE -# endif -// Known limitations -# define BOOST_ASIO_DISABLE_SERIAL_PORT -# define BOOST_DATE_TIME_NO_LOCALE -# define BOOST_NO_STD_WSTRING -# define BOOST_EXCEPTION_DISABLE -# define BOOST_NO_EXCEPTIONS - -#else // TODO: More platform support e.g. UIQ -# error "Unsuppoted Symbian SDK" -#endif - -#if defined(__WINSCW__) && !defined(BOOST_DISABLE_WIN32) -# define BOOST_DISABLE_WIN32 // winscw defines WIN32 macro -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/vms.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/vms.hpp deleted file mode 100644 index f70efcfb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/vms.hpp +++ /dev/null @@ -1,25 +0,0 @@ -// (C) Copyright Artyom Beilis 2010. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_CONFIG_PLATFORM_VMS_HPP -#define BOOST_CONFIG_PLATFORM_VMS_HPP - -#define BOOST_PLATFORM "OpenVMS" - -#undef BOOST_HAS_STDINT_H -#define BOOST_HAS_UNISTD_H -#define BOOST_HAS_NL_TYPES_H -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_DIRENT_H -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_NANOSLEEP -#define BOOST_HAS_CLOCK_GETTIME -#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -#define BOOST_HAS_LOG1P -#define BOOST_HAS_EXPM1 -#define BOOST_HAS_THREADS -#undef BOOST_HAS_SCHED_YIELD - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/vxworks.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/vxworks.hpp deleted file mode 100644 index cdda0158..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/vxworks.hpp +++ /dev/null @@ -1,369 +0,0 @@ -// (C) Copyright Dustin Spicuzza 2009. -// Adapted to vxWorks 6.9 by Peter Brockamp 2012. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Since WRS does not yet properly support boost under vxWorks -// and this file was badly outdated, but I was keen on using it, -// I patched boost myself to make things work. This has been tested -// and adapted by me for vxWorks 6.9 *only*, as I'm lacking access -// to earlier 6.X versions! The only thing I know for sure is that -// very old versions of vxWorks (namely everything below 6.x) are -// absolutely unable to use boost. This is mainly due to the completely -// outdated libraries and ancient compiler (GCC 2.96 or worse). Do -// not even think of getting this to work, a miserable failure will -// be guaranteed! -// Equally, this file has been tested for RTPs (Real Time Processes) -// only, not for DKMs (Downloadable Kernel Modules). These two types -// of executables differ largely in the available functionality of -// the C-library, STL, and so on. A DKM uses a library similar to those -// of vxWorks 5.X - with all its limitations and incompatibilities -// with respect to ANSI C++ and STL. So probably there might be problems -// with the usage of boost from DKMs. WRS or any voluteers are free to -// prove the opposite! - -// ==================================================================== -// -// Some important information regarding the usage of POSIX semaphores: -// ------------------------------------------------------------------- -// -// VxWorks as a real time operating system handles threads somewhat -// different from what "normal" OSes do, regarding their scheduling! -// This could lead to a scenario called "priority inversion" when using -// semaphores, see http://en.wikipedia.org/wiki/Priority_inversion. -// -// Now, VxWorks POSIX-semaphores for DKM's default to the usage of -// priority inverting semaphores, which is fine. On the other hand, -// for RTP's it defaults to using non priority inverting semaphores, -// which could easily pose a serious problem for a real time process, -// i.e. deadlocks! To overcome this two possibilities do exist: -// -// a) Patch every piece of boost that uses semaphores to instanciate -// the proper type of semaphores. This is non-intrusive with respect -// to the OS and could relatively easy been done by giving all -// semaphores attributes deviating from the default (for in-depth -// information see the POSIX functions pthread_mutexattr_init() -// and pthread_mutexattr_setprotocol()). However this breaks all -// too easily, as with every new version some boost library could -// all in a sudden start using semaphores, resurrecting the very -// same, hard to locate problem over and over again! -// -// b) We could change the default properties for POSIX-semaphores -// that VxWorks uses for RTP's and this is being suggested here, -// as it will more or less seamlessly integrate with boost. I got -// the following information from WRS how to do this, compare -// Wind River TSR# 1209768: -// -// Instructions for changing the default properties of POSIX- -// semaphores for RTP's in VxWorks 6.9: -// - Edit the file /vxworks-6.9/target/usr/src/posix/pthreadLib.c -// in the root of your Workbench-installation. -// - Around line 917 there should be the definition of the default -// mutex attributes: -// -// LOCAL pthread_mutexattr_t defaultMutexAttr = -// { -// PTHREAD_INITIALIZED_OBJ, PTHREAD_PRIO_NONE, 0, -// PTHREAD_MUTEX_DEFAULT -// }; -// -// Here, replace PTHREAD_PRIO_NONE by PTHREAD_PRIO_INHERIT. -// - Around line 1236 there should be a definition for the function -// pthread_mutexattr_init(). A couple of lines below you should -// find a block of code like this: -// -// pAttr->mutexAttrStatus = PTHREAD_INITIALIZED_OBJ; -// pAttr->mutexAttrProtocol = PTHREAD_PRIO_NONE; -// pAttr->mutexAttrPrioceiling = 0; -// pAttr->mutexAttrType = PTHREAD_MUTEX_DEFAULT; -// -// Here again, replace PTHREAD_PRIO_NONE by PTHREAD_PRIO_INHERIT. -// - Finally, rebuild your VSB. This will create a new VxWorks kernel -// with the changed properties. That's it! Now, using boost should -// no longer cause any problems with task deadlocks! -// -// And here's another useful piece of information concerning VxWorks' -// POSIX-functionality in general: -// VxWorks is not a genuine POSIX-OS in itself, rather it is using a -// kind of compatibility layer (sort of a wrapper) to emulate the -// POSIX-functionality by using its own resources and functions. -// At the time a task (thread) calls it's first POSIX-function during -// runtime it is being transformed by the OS into a POSIX-thread. -// This transformation does include a call to malloc() to allocate the -// memory required for the housekeeping of POSIX-threads. In a high -// priority RTP this malloc() call may be highly undesirable, as its -// timing is more or less unpredictable (depending on what your actual -// heap looks like). You can circumvent this problem by calling the -// function thread_self() at a well defined point in the code of the -// task, e.g. shortly after the task spawns up. Thereby you are able -// to define the time when the task-transformation will take place and -// you could shift it to an uncritical point where a malloc() call is -// tolerable. So, if this could pose a problem for your code, remember -// to call thread_self() from the affected task at an early stage. -// -// ==================================================================== - -// Block out all versions before vxWorks 6.x, as these don't work: -// Include header with the vxWorks version information and query them -#include -#if !defined(_WRS_VXWORKS_MAJOR) || (_WRS_VXWORKS_MAJOR < 6) -# error "The vxWorks version you're using is so badly outdated,\ - it doesn't work at all with boost, sorry, no chance!" -#endif - -// Handle versions above 5.X but below 6.9 -#if (_WRS_VXWORKS_MAJOR == 6) && (_WRS_VXWORKS_MINOR < 9) -// TODO: Starting from what version does vxWorks work with boost? -// We can't reasonably insert a #warning "" as a user hint here, -// as this will show up with every file including some boost header, -// badly bugging the user... So for the time being we just leave it. -#endif - -// vxWorks specific config options: -// -------------------------------- -#define BOOST_PLATFORM "vxWorks" - -// Special behaviour for DKMs: -#ifdef _WRS_KERNEL - // DKMs do not have the -header, - // but apparently they do have an intrinsic wchar_t meanwhile! -# define BOOST_NO_CWCHAR - - // Lots of wide-functions and -headers are unavailable for DKMs as well: -# define BOOST_NO_CWCTYPE -# define BOOST_NO_SWPRINTF -# define BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTREAMBUF -#endif - -// Generally available headers: -#define BOOST_HAS_UNISTD_H -#define BOOST_HAS_STDINT_H -#define BOOST_HAS_DIRENT_H -#define BOOST_HAS_SLIST - -// vxWorks does not have installed an iconv-library by default, -// so unfortunately no Unicode support from scratch is available! -// Thus, instead it is suggested to switch to ICU, as this seems -// to be the most complete and portable option... -#define BOOST_LOCALE_WITH_ICU - -// Generally available functionality: -#define BOOST_HAS_THREADS -#define BOOST_HAS_NANOSLEEP -#define BOOST_HAS_GETTIMEOFDAY -#define BOOST_HAS_CLOCK_GETTIME -#define BOOST_HAS_MACRO_USE_FACET - -// Generally unavailable functionality, delivered by boost's test function: -//#define BOOST_NO_DEDUCED_TYPENAME // Commented this out, boost's test gives an errorneous result! -#define BOOST_NO_CXX11_EXTERN_TEMPLATE -#define BOOST_NO_CXX11_VARIADIC_MACROS - -// Generally available threading API's: -#define BOOST_HAS_PTHREADS -#define BOOST_HAS_SCHED_YIELD -#define BOOST_HAS_SIGACTION - -// Functionality available for RTPs only: -#ifdef __RTP__ -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# define BOOST_HAS_LOG1P -# define BOOST_HAS_EXPM1 -#endif - -// Functionality available for DKMs only: -#ifdef _WRS_KERNEL - // Luckily, at the moment there seems to be none! -#endif - -// These #defines allow posix_features to work, since vxWorks doesn't -// #define them itself for DKMs (for RTPs on the contrary it does): -#ifdef _WRS_KERNEL -# ifndef _POSIX_TIMERS -# define _POSIX_TIMERS 1 -# endif -# ifndef _POSIX_THREADS -# define _POSIX_THREADS 1 -# endif -#endif - -// vxWorks doesn't work with asio serial ports: -#define BOOST_ASIO_DISABLE_SERIAL_PORT -// TODO: The problem here seems to bee that vxWorks uses its own, very specific -// ways to handle serial ports, incompatible with POSIX or anything... -// Maybe a specific implementation would be possible, but until the -// straight need arises... This implementation would presumably consist -// of some vxWorks specific ioctl-calls, etc. Any voluteers? - -// vxWorks-around: #defines CLOCKS_PER_SEC as sysClkRateGet() but -// miserably fails to #include the required to make -// sysClkRateGet() available! So we manually include it here. -#ifdef __RTP__ -# include -# include -#endif - -// vxWorks-around: In the macros INT32_C(), UINT32_C(), INT64_C() and -// UINT64_C() are defined errorneously, yielding not a signed/ -// unsigned long/long long type, but a signed/unsigned int/long -// type. Eventually this leads to compile errors in ratio_fwd.hpp, -// when trying to define several constants which do not fit into a -// long type! We correct them here by redefining. -#include - -// Some macro-magic to do the job -#define VX_JOIN(X, Y) VX_DO_JOIN(X, Y) -#define VX_DO_JOIN(X, Y) VX_DO_JOIN2(X, Y) -#define VX_DO_JOIN2(X, Y) X##Y - -// Correctly setup the macros -#undef INT32_C -#undef UINT32_C -#undef INT64_C -#undef UINT64_C -#define INT32_C(x) VX_JOIN(x, L) -#define UINT32_C(x) VX_JOIN(x, UL) -#define INT64_C(x) VX_JOIN(x, LL) -#define UINT64_C(x) VX_JOIN(x, ULL) - -// #include Libraries required for the following function adaption -#include -#include -#include - -// Use C-linkage for the following helper functions -extern "C" { - -// vxWorks-around: The required functions getrlimit() and getrlimit() are missing. -// But we have the similar functions getprlimit() and setprlimit(), -// which may serve the purpose. -// Problem: The vxWorks-documentation regarding these functions -// doesn't deserve its name! It isn't documented what the first two -// parameters idtype and id mean, so we must fall back to an educated -// guess - null, argh... :-/ - -// TODO: getprlimit() and setprlimit() do exist for RTPs only, for whatever reason. -// Thus for DKMs there would have to be another implementation. -#ifdef __RTP__ - inline int getrlimit(int resource, struct rlimit *rlp){ - return getprlimit(0, 0, resource, rlp); - } - - inline int setrlimit(int resource, const struct rlimit *rlp){ - return setprlimit(0, 0, resource, const_cast(rlp)); - } -#endif - -// vxWorks has ftruncate() only, so we do simulate truncate(): -inline int truncate(const char *p, off_t l){ - int fd = open(p, O_WRONLY); - if (fd == -1){ - errno = EACCES; - return -1; - } - if (ftruncate(fd, l) == -1){ - close(fd); - errno = EACCES; - return -1; - } - return close(fd); -} - -// Fake symlink handling by dummy functions: -inline int symlink(const char*, const char*){ - // vxWorks has no symlinks -> always return an error! - errno = EACCES; - return -1; -} - -inline ssize_t readlink(const char*, char*, size_t){ - // vxWorks has no symlinks -> always return an error! - errno = EACCES; - return -1; -} - -// vxWorks claims to implement gettimeofday in sys/time.h -// but nevertheless does not provide it! See -// https://support.windriver.com/olsPortal/faces/maintenance/techtipDetail_noHeader.jspx?docId=16442&contentId=WR_TECHTIP_006256 -// We implement a surrogate version here via clock_gettime: -inline int gettimeofday(struct timeval *tv, void * /*tzv*/) { - struct timespec ts; - clock_gettime(CLOCK_MONOTONIC, &ts); - tv->tv_sec = ts.tv_sec; - tv->tv_usec = ts.tv_nsec / 1000; - return 0; -} - -// vxWorks does provide neither struct tms nor function times()! -// We implement an empty dummy-function, simply setting the user -// and system time to the half of thew actual system ticks-value -// and the child user and system time to 0. -// Rather ugly but at least it suppresses compiler errors... -// Unfortunately, this of course *does* have an severe impact on -// dependant libraries, actually this is chrono only! Here it will -// not be possible to correctly use user and system times! But -// as vxWorks is lacking the ability to calculate user and system -// process times there seems to be no other possible solution. -struct tms{ - clock_t tms_utime; // User CPU time - clock_t tms_stime; // System CPU time - clock_t tms_cutime; // User CPU time of terminated child processes - clock_t tms_cstime; // System CPU time of terminated child processes -}; - -inline clock_t times(struct tms *t){ - struct timespec ts; - clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts); - clock_t ticks(static_cast(static_cast(ts.tv_sec) * CLOCKS_PER_SEC + - static_cast(ts.tv_nsec) * CLOCKS_PER_SEC / 1000000.0)); - t->tms_utime = ticks/2U; - t->tms_stime = ticks/2U; - t->tms_cutime = 0; // vxWorks is lacking the concept of a child process! - t->tms_cstime = 0; // -> Set the wait times for childs to 0 - return ticks; -} - -} // extern "C" - -// Put the selfmade functions into the std-namespace, just in case -namespace std { -# ifdef __RTP__ - using ::getrlimit; - using ::setrlimit; -# endif - using ::truncate; - using ::symlink; - using ::readlink; - using ::times; - using ::gettimeofday; -} - -// Some more macro-magic: -// vxWorks-around: Some functions are not present or broken in vxWorks -// but may be patched to life via helper macros... - -// Include signal.h which might contain a typo to be corrected here -#include - -#define getpagesize() sysconf(_SC_PAGESIZE) // getpagesize is deprecated anyway! -#ifndef S_ISSOCK -# define S_ISSOCK(mode) ((mode & S_IFMT) == S_IFSOCK) // Is file a socket? -#endif -#define lstat(p, b) stat(p, b) // lstat() == stat(), as vxWorks has no symlinks! -#ifndef FPE_FLTINV -# define FPE_FLTINV (FPE_FLTSUB+1) // vxWorks has no FPE_FLTINV, so define one as a dummy -#endif -#if !defined(BUS_ADRALN) && defined(BUS_ADRALNR) -# define BUS_ADRALN BUS_ADRALNR // Correct a supposed typo in vxWorks' -#endif -//typedef int locale_t; // locale_t is a POSIX-extension, currently unpresent in vxWorks! - -// #include boilerplate code: -#include - -// vxWorks lies about XSI conformance, there is no nl_types.h: -#undef BOOST_HAS_NL_TYPES_H diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/platform/win32.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/platform/win32.hpp deleted file mode 100644 index 6ab59f4e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/platform/win32.hpp +++ /dev/null @@ -1,73 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Bill Kempf 2001. -// (C) Copyright Aleksey Gurtovoy 2003. -// (C) Copyright Rene Rivera 2005. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Win32 specific config options: - -#define BOOST_PLATFORM "Win32" - -// Get the information about the MinGW runtime, i.e. __MINGW32_*VERSION. -#if defined(__MINGW32__) -# include <_mingw.h> -#endif - -#if defined(__GNUC__) && !defined(BOOST_NO_SWPRINTF) -# define BOOST_NO_SWPRINTF -#endif - -// Default defines for BOOST_SYMBOL_EXPORT and BOOST_SYMBOL_IMPORT -// If a compiler doesn't support __declspec(dllexport)/__declspec(dllimport), -// its boost/config/compiler/ file must define BOOST_SYMBOL_EXPORT and -// BOOST_SYMBOL_IMPORT -#ifndef BOOST_SYMBOL_EXPORT -# define BOOST_HAS_DECLSPEC -# define BOOST_SYMBOL_EXPORT __declspec(dllexport) -# define BOOST_SYMBOL_IMPORT __declspec(dllimport) -#endif - -#if defined(__MINGW32__) && ((__MINGW32_MAJOR_VERSION > 2) || ((__MINGW32_MAJOR_VERSION == 2) && (__MINGW32_MINOR_VERSION >= 0))) -# define BOOST_HAS_STDINT_H -# ifndef __STDC_LIMIT_MACROS -# define __STDC_LIMIT_MACROS -# endif -# define BOOST_HAS_DIRENT_H -# define BOOST_HAS_UNISTD_H -#endif - -#if defined(__MINGW32__) && (__GNUC__ >= 4) -# define BOOST_HAS_EXPM1 -# define BOOST_HAS_LOG1P -# define BOOST_HAS_GETTIMEOFDAY -#endif -// -// Win32 will normally be using native Win32 threads, -// but there is a pthread library avaliable as an option, -// we used to disable this when BOOST_DISABLE_WIN32 was -// defined but no longer - this should allow some -// files to be compiled in strict mode - while maintaining -// a consistent setting of BOOST_HAS_THREADS across -// all translation units (needed for shared_ptr etc). -// - -#ifdef _WIN32_WCE -# define BOOST_NO_ANSI_APIS -#else -# define BOOST_HAS_GETSYSTEMTIMEASFILETIME -#endif - -#ifndef BOOST_HAS_PTHREADS -# define BOOST_HAS_WINTHREADS -#endif - -#ifndef BOOST_DISABLE_WIN32 -// WEK: Added -#define BOOST_HAS_FTIME -#define BOOST_WINDOWS 1 - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/posix_features.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/posix_features.hpp deleted file mode 100644 index d1295479..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/posix_features.hpp +++ /dev/null @@ -1,95 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -// See http://www.boost.org for most recent version. - -// All POSIX feature tests go in this file, -// Note that we test _POSIX_C_SOURCE and _XOPEN_SOURCE as well -// _POSIX_VERSION and _XOPEN_VERSION: on some systems POSIX API's -// may be present but none-functional unless _POSIX_C_SOURCE and -// _XOPEN_SOURCE have been defined to the right value (it's up -// to the user to do this *before* including any header, although -// in most cases the compiler will do this for you). - -# if defined(BOOST_HAS_UNISTD_H) -# include - - // XOpen has , but is this the correct version check? -# if defined(_XOPEN_VERSION) && (_XOPEN_VERSION >= 3) -# define BOOST_HAS_NL_TYPES_H -# endif - - // POSIX version 6 requires -# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 200100) -# define BOOST_HAS_STDINT_H -# endif - - // POSIX version 2 requires -# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 199009L) -# define BOOST_HAS_DIRENT_H -# endif - - // POSIX version 3 requires to have sigaction: -# if defined(_POSIX_VERSION) && (_POSIX_VERSION >= 199506L) -# define BOOST_HAS_SIGACTION -# endif - // POSIX defines _POSIX_THREADS > 0 for pthread support, - // however some platforms define _POSIX_THREADS without - // a value, hence the (_POSIX_THREADS+0 >= 0) check. - // Strictly speaking this may catch platforms with a - // non-functioning stub , but such occurrences should - // occur very rarely if at all. -# if defined(_POSIX_THREADS) && (_POSIX_THREADS+0 >= 0) && !defined(BOOST_HAS_WINTHREADS) && !defined(BOOST_HAS_MPTASKS) -# define BOOST_HAS_PTHREADS -# endif - - // BOOST_HAS_NANOSLEEP: - // This is predicated on _POSIX_TIMERS or _XOPEN_REALTIME: -# if (defined(_POSIX_TIMERS) && (_POSIX_TIMERS+0 >= 0)) \ - || (defined(_XOPEN_REALTIME) && (_XOPEN_REALTIME+0 >= 0)) -# define BOOST_HAS_NANOSLEEP -# endif - - // BOOST_HAS_CLOCK_GETTIME: - // This is predicated on _POSIX_TIMERS (also on _XOPEN_REALTIME - // but at least one platform - linux - defines that flag without - // defining clock_gettime): -# if (defined(_POSIX_TIMERS) && (_POSIX_TIMERS+0 >= 0)) -# define BOOST_HAS_CLOCK_GETTIME -# endif - - // BOOST_HAS_SCHED_YIELD: - // This is predicated on _POSIX_PRIORITY_SCHEDULING or - // on _POSIX_THREAD_PRIORITY_SCHEDULING or on _XOPEN_REALTIME. -# if defined(_POSIX_PRIORITY_SCHEDULING) && (_POSIX_PRIORITY_SCHEDULING+0 > 0)\ - || (defined(_POSIX_THREAD_PRIORITY_SCHEDULING) && (_POSIX_THREAD_PRIORITY_SCHEDULING+0 > 0))\ - || (defined(_XOPEN_REALTIME) && (_XOPEN_REALTIME+0 >= 0)) -# define BOOST_HAS_SCHED_YIELD -# endif - - // BOOST_HAS_GETTIMEOFDAY: - // BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE: - // These are predicated on _XOPEN_VERSION, and appears to be first released - // in issue 4, version 2 (_XOPEN_VERSION > 500). - // Likewise for the functions log1p and expm1. -# if defined(_XOPEN_VERSION) && (_XOPEN_VERSION+0 >= 500) -# define BOOST_HAS_GETTIMEOFDAY -# if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE+0 >= 500) -# define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# endif -# ifndef BOOST_HAS_LOG1P -# define BOOST_HAS_LOG1P -# endif -# ifndef BOOST_HAS_EXPM1 -# define BOOST_HAS_EXPM1 -# endif -# endif - -# endif - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/requires_threads.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/requires_threads.hpp deleted file mode 100644 index cfaff230..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/requires_threads.hpp +++ /dev/null @@ -1,92 +0,0 @@ -// (C) Copyright John Maddock 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -#ifndef BOOST_CONFIG_REQUIRES_THREADS_HPP -#define BOOST_CONFIG_REQUIRES_THREADS_HPP - -#ifndef BOOST_CONFIG_HPP -# include -#endif - -#if defined(BOOST_DISABLE_THREADS) - -// -// special case to handle versions of gcc which don't currently support threads: -// -#if defined(__GNUC__) && ((__GNUC__ < 3) || (__GNUC_MINOR__ <= 3) || !defined(BOOST_STRICT_CONFIG)) -// -// this is checked up to gcc 3.3: -// -#if defined(__sgi) || defined(__hpux) -# error "Multi-threaded programs are not supported by gcc on HPUX or Irix (last checked with gcc 3.3)" -#endif - -#endif - -# error "Threading support unavaliable: it has been explicitly disabled with BOOST_DISABLE_THREADS" - -#elif !defined(BOOST_HAS_THREADS) - -# if defined __COMO__ -// Comeau C++ -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_MT (Windows) or -D_REENTRANT (Unix)" - -#elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC) -// Intel -#ifdef _WIN32 -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd" -#else -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -openmp" -#endif - -# elif defined __GNUC__ -// GNU C++: -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread (Linux), -pthreads (Solaris) or -mthreads (Mingw32)" - -#elif defined __sgi -// SGI MIPSpro C++ -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_SGI_MP_SOURCE" - -#elif defined __DECCXX -// Compaq Tru64 Unix cxx -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread" - -#elif defined __BORLANDC__ -// Borland -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -tWM" - -#elif defined __MWERKS__ -// Metrowerks CodeWarrior -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either -runtime sm, -runtime smd, -runtime dm, or -runtime dmd" - -#elif defined __SUNPRO_CC -// Sun Workshop Compiler C++ -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt" - -#elif defined __HP_aCC -// HP aCC -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt" - -#elif defined(__IBMCPP__) -// IBM Visual Age -# error "Compiler threading support is not turned on. Please compile the code with the xlC_r compiler" - -#elif defined _MSC_VER -// Microsoft Visual C++ -// -// Must remain the last #elif since some other vendors (Metrowerks, for -// example) also #define _MSC_VER -# error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd" - -#else - -# error "Compiler threading support is not turned on. Please consult your compiler's documentation for the appropriate options to use" - -#endif // compilers - -#endif // BOOST_HAS_THREADS - -#endif // BOOST_CONFIG_REQUIRES_THREADS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/select_compiler_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/select_compiler_config.hpp deleted file mode 100644 index 0eeb7ad3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/select_compiler_config.hpp +++ /dev/null @@ -1,114 +0,0 @@ -// Boost compiler configuration selection header file - -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Martin Wille 2003. -// (C) Copyright Guillaume Melquiond 2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for most recent version. - -// locate which compiler we are using and define -// BOOST_COMPILER_CONFIG as needed: - -#if defined __CUDACC__ -// NVIDIA CUDA C++ compiler for GPU -# include "boost/config/compiler/nvcc.hpp" - -#endif - -#if defined(__GCCXML__) -// GCC-XML emulates other compilers, it has to appear first here! -# define BOOST_COMPILER_CONFIG "boost/config/compiler/gcc_xml.hpp" - -#elif defined(_CRAYC) -// EDG based Cray compiler: -# define BOOST_COMPILER_CONFIG "boost/config/compiler/cray.hpp" - -#elif defined __COMO__ -// Comeau C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/comeau.hpp" - -#elif defined(__PATHSCALE__) && (__PATHCC__ >= 4) -// PathScale EKOPath compiler (has to come before clang and gcc) -# define BOOST_COMPILER_CONFIG "boost/config/compiler/pathscale.hpp" - -#elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC) -// Intel -# define BOOST_COMPILER_CONFIG "boost/config/compiler/intel.hpp" - -#elif defined __clang__ -// Clang C++ emulates GCC, so it has to appear early. -# define BOOST_COMPILER_CONFIG "boost/config/compiler/clang.hpp" - -#elif defined __DMC__ -// Digital Mars C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/digitalmars.hpp" - -# elif defined __GNUC__ -// GNU C++: -# define BOOST_COMPILER_CONFIG "boost/config/compiler/gcc.hpp" - -#elif defined __KCC -// Kai C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/kai.hpp" - -#elif defined __sgi -// SGI MIPSpro C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/sgi_mipspro.hpp" - -#elif defined __DECCXX -// Compaq Tru64 Unix cxx -# define BOOST_COMPILER_CONFIG "boost/config/compiler/compaq_cxx.hpp" - -#elif defined __ghs -// Greenhills C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/greenhills.hpp" - -#elif defined __CODEGEARC__ -// CodeGear - must be checked for before Borland -# define BOOST_COMPILER_CONFIG "boost/config/compiler/codegear.hpp" - -#elif defined __BORLANDC__ -// Borland -# define BOOST_COMPILER_CONFIG "boost/config/compiler/borland.hpp" - -#elif defined __MWERKS__ -// Metrowerks CodeWarrior -# define BOOST_COMPILER_CONFIG "boost/config/compiler/metrowerks.hpp" - -#elif defined __SUNPRO_CC -// Sun Workshop Compiler C++ -# define BOOST_COMPILER_CONFIG "boost/config/compiler/sunpro_cc.hpp" - -#elif defined __HP_aCC -// HP aCC -# define BOOST_COMPILER_CONFIG "boost/config/compiler/hp_acc.hpp" - -#elif defined(__MRC__) || defined(__SC__) -// MPW MrCpp or SCpp -# define BOOST_COMPILER_CONFIG "boost/config/compiler/mpw.hpp" - -#elif defined(__IBMCPP__) -// IBM Visual Age -# define BOOST_COMPILER_CONFIG "boost/config/compiler/vacpp.hpp" - -#elif defined(__PGI) -// Portland Group Inc. -# define BOOST_COMPILER_CONFIG "boost/config/compiler/pgi.hpp" - -#elif defined _MSC_VER -// Microsoft Visual C++ -// -// Must remain the last #elif since some other vendors (Metrowerks, for -// example) also #define _MSC_VER -# define BOOST_COMPILER_CONFIG "boost/config/compiler/visualc.hpp" - -#elif defined (BOOST_ASSERT_CONFIG) -// this must come last - generate an error if we don't -// recognise the compiler: -# error "Unknown compiler - please configure (http://www.boost.org/libs/config/config.htm#configuring) and report the results to the main boost mailing list (http://www.boost.org/more/mailing_lists.htm#main)" - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/select_platform_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/select_platform_config.hpp deleted file mode 100644 index 2af61d2d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/select_platform_config.hpp +++ /dev/null @@ -1,105 +0,0 @@ -// Boost compiler configuration selection header file - -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// locate which platform we are on and define BOOST_PLATFORM_CONFIG as needed. -// Note that we define the headers to include using "header_name" not -// in order to prevent macro expansion within the header -// name (for example "linux" is a macro on linux systems). - -#if (defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)) && !defined(_CRAYC) -// linux, also other platforms (Hurd etc) that use GLIBC, should these really have their own config headers though? -# define BOOST_PLATFORM_CONFIG "boost/config/platform/linux.hpp" - -#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) -// BSD: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/bsd.hpp" - -#elif defined(sun) || defined(__sun) -// solaris: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/solaris.hpp" - -#elif defined(__sgi) -// SGI Irix: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/irix.hpp" - -#elif defined(__hpux) -// hp unix: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/hpux.hpp" - -#elif defined(__CYGWIN__) -// cygwin is not win32: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/cygwin.hpp" - -#elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32) -// win32: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/win32.hpp" - -#elif defined(__BEOS__) -// BeOS -# define BOOST_PLATFORM_CONFIG "boost/config/platform/beos.hpp" - -#elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__) -// MacOS -# define BOOST_PLATFORM_CONFIG "boost/config/platform/macos.hpp" - -#elif defined(__IBMCPP__) || defined(_AIX) -// IBM -# define BOOST_PLATFORM_CONFIG "boost/config/platform/aix.hpp" - -#elif defined(__amigaos__) -// AmigaOS -# define BOOST_PLATFORM_CONFIG "boost/config/platform/amigaos.hpp" - -#elif defined(__QNXNTO__) -// QNX: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/qnxnto.hpp" - -#elif defined(__VXWORKS__) -// vxWorks: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/vxworks.hpp" - -#elif defined(__SYMBIAN32__) -// Symbian: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/symbian.hpp" - -#elif defined(_CRAYC) -// Cray: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/cray.hpp" - -#elif defined(__VMS) -// VMS: -# define BOOST_PLATFORM_CONFIG "boost/config/platform/vms.hpp" -#else - -# if defined(unix) \ - || defined(__unix) \ - || defined(_XOPEN_SOURCE) \ - || defined(_POSIX_SOURCE) - - // generic unix platform: - -# ifndef BOOST_HAS_UNISTD_H -# define BOOST_HAS_UNISTD_H -# endif - -# include - -# endif - -# if defined (BOOST_ASSERT_CONFIG) - // this must come last - generate an error if we don't - // recognise the platform: -# error "Unknown platform - please configure and report the results to boost.org" -# endif - -#endif - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/select_stdlib_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/select_stdlib_config.hpp deleted file mode 100644 index 96ede002..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/select_stdlib_config.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// Boost compiler configuration selection header file - -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001 - 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -// See http://www.boost.org for most recent version. - -// locate which std lib we are using and define BOOST_STDLIB_CONFIG as needed: - -// First include to determine if some version of STLport is in use as the std lib -// (do not rely on this header being included since users can short-circuit this header -// if they know whose std lib they are using.) -#ifdef __cplusplus -# include -#else -# include -#endif - -#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -// STLPort library; this _must_ come first, otherwise since -// STLport typically sits on top of some other library, we -// can end up detecting that first rather than STLport: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/stlport.hpp" - -#else - -// If our std lib was not some version of STLport, then include as it is about -// the smallest of the std lib headers that includes real C++ stuff. (Some std libs do not -// include their C++-related macros in so this additional include makes sure -// we get those definitions) -// (again do not rely on this header being included since users can short-circuit this -// header if they know whose std lib they are using.) -#include - -#if defined(__LIBCOMO__) -// Comeau STL: -#define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcomo.hpp" - -#elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) -// Rogue Wave library: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/roguewave.hpp" - -#elif defined(_LIBCPP_VERSION) -// libc++ -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcpp.hpp" - -#elif defined(__GLIBCPP__) || defined(__GLIBCXX__) -// GNU libstdc++ 3 -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libstdcpp3.hpp" - -#elif defined(__STL_CONFIG_H) -// generic SGI STL -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/sgi.hpp" - -#elif defined(__MSL_CPP__) -// MSL standard lib: -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/msl.hpp" - -#elif defined(__IBMCPP__) -// take the default VACPP std lib -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/vacpp.hpp" - -#elif defined(MSIPL_COMPILE_H) -// Modena C++ standard library -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/modena.hpp" - -#elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER) -// Dinkumware Library (this has to appear after any possible replacement libraries): -# define BOOST_STDLIB_CONFIG "boost/config/stdlib/dinkumware.hpp" - -#elif defined (BOOST_ASSERT_CONFIG) -// this must come last - generate an error if we don't -// recognise the library: -# error "Unknown standard library - please configure and report the results to boost.org" - -#endif - -#endif - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/dinkumware.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/dinkumware.hpp deleted file mode 100644 index a8b68be7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/dinkumware.hpp +++ /dev/null @@ -1,157 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright Peter Dimov 2001. -// (C) Copyright David Abrahams 2002. -// (C) Copyright Guillaume Melquiond 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Dinkumware standard library config: - -#if !defined(_YVALS) && !defined(_CPPLIB_VER) -#include -#if !defined(_YVALS) && !defined(_CPPLIB_VER) -#error This is not the Dinkumware lib! -#endif -#endif - - -#if defined(_CPPLIB_VER) && (_CPPLIB_VER >= 306) - // full dinkumware 3.06 and above - // fully conforming provided the compiler supports it: -# if !(defined(_GLOBAL_USING) && (_GLOBAL_USING+0 > 0)) && !defined(__BORLANDC__) && !defined(_STD) && !(defined(__ICC) && (__ICC >= 700)) // can be defined in yvals.h -# define BOOST_NO_STDC_NAMESPACE -# endif -# if !(defined(_HAS_MEMBER_TEMPLATES_REBIND) && (_HAS_MEMBER_TEMPLATES_REBIND+0 > 0)) && !(defined(_MSC_VER) && (_MSC_VER > 1300)) && defined(BOOST_MSVC) -# define BOOST_NO_STD_ALLOCATOR -# endif -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -# if defined(BOOST_MSVC) && (BOOST_MSVC < 1300) - // if this lib version is set up for vc6 then there is no std::use_facet: -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET - // C lib functions aren't in namespace std either: -# define BOOST_NO_STDC_NAMESPACE - // and nor is -# define BOOST_NO_EXCEPTION_STD_NAMESPACE -# endif -// There's no numeric_limits support unless _LONGLONG is defined: -# if !defined(_LONGLONG) && (_CPPLIB_VER <= 310) -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# endif -// 3.06 appears to have (non-sgi versions of) & , -// and no at all -#else -# define BOOST_MSVC_STD_ITERATOR 1 -# define BOOST_NO_STD_ITERATOR -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -# define BOOST_NO_STDC_NAMESPACE -# define BOOST_NO_STD_USE_FACET -# define BOOST_NO_STD_OUTPUT_ITERATOR_ASSIGN -# define BOOST_HAS_MACRO_USE_FACET -# ifndef _CPPLIB_VER - // Updated Dinkum library defines this, and provides - // its own min and max definitions, as does MTA version. -# ifndef __MTA__ -# define BOOST_NO_STD_MIN_MAX -# endif -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# endif -#endif - -// -// std extension namespace is stdext for vc7.1 and later, -// the same applies to other compilers that sit on top -// of vc7.1 (Intel and Comeau): -// -#if defined(_MSC_VER) && (_MSC_VER >= 1310) && !defined(__BORLANDC__) -# define BOOST_STD_EXTENSION_NAMESPACE stdext -#endif - - -#if (defined(_MSC_VER) && (_MSC_VER <= 1300) && !defined(__BORLANDC__)) || !defined(_CPPLIB_VER) || (_CPPLIB_VER < 306) - // if we're using a dinkum lib that's - // been configured for VC6/7 then there is - // no iterator traits (true even for icl) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -#if defined(__ICL) && (__ICL < 800) && defined(_CPPLIB_VER) && (_CPPLIB_VER <= 310) -// Intel C++ chokes over any non-trivial use of -// this may be an overly restrictive define, but regex fails without it: -# define BOOST_NO_STD_LOCALE -#endif - -#include -#if ( (!_HAS_EXCEPTIONS && !defined(__ghs__)) || (!_HAS_NAMESPACE && defined(__ghs__)) ) && !defined(__TI_COMPILER_VERSION__) -# define BOOST_NO_STD_TYPEINFO -#endif - -// C++0x headers implemented in 520 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 520 -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_SMART_PTR -#endif - -#if ((!defined(_HAS_TR1_IMPORTS) || (_HAS_TR1_IMPORTS+0 == 0)) && !defined(BOOST_NO_CXX11_HDR_TUPLE)) \ - && (!defined(_CPPLIB_VER) || _CPPLIB_VER < 610) -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -// C++0x headers implemented in 540 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 540 -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -#endif - -// C++0x headers implemented in 610 (as shipped by Microsoft) -// -#if !defined(_CPPLIB_VER) || _CPPLIB_VER < 610 -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -#endif - -#ifdef _CPPLIB_VER -# define BOOST_DINKUMWARE_STDLIB _CPPLIB_VER -#else -# define BOOST_DINKUMWARE_STDLIB 1 -#endif - -#ifdef _CPPLIB_VER -# define BOOST_STDLIB "Dinkumware standard library version " BOOST_STRINGIZE(_CPPLIB_VER) -#else -# define BOOST_STDLIB "Dinkumware standard library version 1.x" -#endif - - - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcomo.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcomo.hpp deleted file mode 100644 index 29490f1b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcomo.hpp +++ /dev/null @@ -1,72 +0,0 @@ -// (C) Copyright John Maddock 2002 - 2003. -// (C) Copyright Jens Maurer 2002 - 2003. -// (C) Copyright Beman Dawes 2002 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Comeau STL: - -#if !defined(__LIBCOMO__) -# include -# if !defined(__LIBCOMO__) -# error "This is not the Comeau STL!" -# endif -#endif - -// -// std::streambuf is non-standard -// NOTE: versions of libcomo prior to beta28 have octal version numbering, -// e.g. version 25 is 21 (dec) -#if __LIBCOMO_VERSION__ <= 22 -# define BOOST_NO_STD_WSTREAMBUF -#endif - -#if (__LIBCOMO_VERSION__ <= 31) && defined(_WIN32) -#define BOOST_NO_SWPRINTF -#endif - -#if __LIBCOMO_VERSION__ >= 31 -# define BOOST_HAS_HASH -# define BOOST_HAS_SLIST -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -// -// Intrinsic type_traits support. -// The SGI STL has it's own __type_traits class, which -// has intrinsic compiler support with SGI's compilers. -// Whatever map SGI style type traits to boost equivalents: -// -#define BOOST_HAS_SGI_TYPE_TRAITS - -#define BOOST_STDLIB "Comeau standard library " BOOST_STRINGIZE(__LIBCOMO_VERSION__) - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcpp.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcpp.hpp deleted file mode 100644 index 3d574407..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libcpp.hpp +++ /dev/null @@ -1,37 +0,0 @@ -// (C) Copyright Christopher Jefferson 2011. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// config for libc++ -// Might need more in here later. - -#if !defined(_LIBCPP_VERSION) -# include -# if !defined(_LIBCPP_VERSION) -# error "This is not libc++!" -# endif -#endif - -#define BOOST_STDLIB "libc++ version " BOOST_STRINGIZE(_LIBCPP_VERSION) - -#define BOOST_HAS_THREADS - -#ifdef _LIBCPP_HAS_NO_VARIADICS -# define BOOST_NO_CXX11_HDR_TUPLE -#endif - -// -// These appear to be unusable/incomplete so far: -// -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR - -// libc++ uses a non-standard messages_base -#define BOOST_NO_STD_MESSAGES - -// --- end --- diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libstdcpp3.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libstdcpp3.hpp deleted file mode 100644 index 976ab76b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/libstdcpp3.hpp +++ /dev/null @@ -1,166 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// config for libstdc++ v3 -// not much to go in here: - -#define BOOST_GNU_STDLIB 1 - -#ifdef __GLIBCXX__ -#define BOOST_STDLIB "GNU libstdc++ version " BOOST_STRINGIZE(__GLIBCXX__) -#else -#define BOOST_STDLIB "GNU libstdc++ version " BOOST_STRINGIZE(__GLIBCPP__) -#endif - -#if !defined(_GLIBCPP_USE_WCHAR_T) && !defined(_GLIBCXX_USE_WCHAR_T) -# define BOOST_NO_CWCHAR -# define BOOST_NO_CWCTYPE -# define BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTREAMBUF -#endif - -#if defined(__osf__) && !defined(_REENTRANT) \ - && ( defined(_GLIBCXX_HAVE_GTHR_DEFAULT) || defined(_GLIBCPP_HAVE_GTHR_DEFAULT) ) -// GCC 3 on Tru64 forces the definition of _REENTRANT when any std lib header -// file is included, therefore for consistency we define it here as well. -# define _REENTRANT -#endif - -#ifdef __GLIBCXX__ // gcc 3.4 and greater: -# if defined(_GLIBCXX_HAVE_GTHR_DEFAULT) \ - || defined(_GLIBCXX__PTHREADS) \ - || defined(_GLIBCXX_HAS_GTHREADS) \ - || defined(_WIN32) \ - || defined(_AIX) - // - // If the std lib has thread support turned on, then turn it on in Boost - // as well. We do this because some gcc-3.4 std lib headers define _REENTANT - // while others do not... - // -# define BOOST_HAS_THREADS -# else -# define BOOST_DISABLE_THREADS -# endif -#elif defined(__GLIBCPP__) \ - && !defined(_GLIBCPP_HAVE_GTHR_DEFAULT) \ - && !defined(_GLIBCPP__PTHREADS) - // disable thread support if the std lib was built single threaded: -# define BOOST_DISABLE_THREADS -#endif - -#if (defined(linux) || defined(__linux) || defined(__linux__)) && defined(__arm__) && defined(_GLIBCPP_HAVE_GTHR_DEFAULT) -// linux on arm apparently doesn't define _REENTRANT -// so just turn on threading support whenever the std lib is thread safe: -# define BOOST_HAS_THREADS -#endif - -#if !defined(_GLIBCPP_USE_LONG_LONG) \ - && !defined(_GLIBCXX_USE_LONG_LONG)\ - && defined(BOOST_HAS_LONG_LONG) -// May have been set by compiler/*.hpp, but "long long" without library -// support is useless. -# undef BOOST_HAS_LONG_LONG -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include -#endif - -#if defined(__GLIBCXX__) || (defined(__GLIBCPP__) && __GLIBCPP__>=20020514) // GCC >= 3.1.0 -# define BOOST_STD_EXTENSION_NAMESPACE __gnu_cxx -# define BOOST_HAS_SLIST -# define BOOST_HAS_HASH -# define BOOST_SLIST_HEADER -# if !defined(__GNUC__) || __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 3) -# define BOOST_HASH_SET_HEADER -# define BOOST_HASH_MAP_HEADER -# else -# define BOOST_HASH_SET_HEADER -# define BOOST_HASH_MAP_HEADER -# endif -#endif - -// stdlibc++ C++0x support is detected via __GNUC__, __GNUC_MINOR__, and possibly -// __GNUC_PATCHLEVEL__ at the suggestion of Jonathan Wakely, one of the stdlibc++ -// developers. He also commented: -// -// "I'm not sure how useful __GLIBCXX__ is for your purposes, for instance in -// GCC 4.2.4 it is set to 20080519 but in GCC 4.3.0 it is set to 20080305. -// Although 4.3.0 was released earlier than 4.2.4, it has better C++0x support -// than any release in the 4.2 series." -// -// Another resource for understanding stdlibc++ features is: -// http://gcc.gnu.org/onlinedocs/libstdc++/manual/status.html#manual.intro.status.standard.200x - -// C++0x headers in GCC 4.3.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 3) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_HDR_FUNCTIONAL -#endif - -// C++0x headers in GCC 4.4.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 4) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_SMART_PTR -#else -# define BOOST_HAS_TR1_COMPLEX_INVERSE_TRIG -# define BOOST_HAS_TR1_COMPLEX_OVERLOADS -#endif - -#if (!defined(_GLIBCXX_HAS_GTHREADS) || !defined(_GLIBCXX_USE_C99_STDINT_TR1)) && (!defined(BOOST_NO_CXX11_HDR_CONDITION_VARIABLE) || !defined(BOOST_NO_CXX11_HDR_MUTEX)) -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_MUTEX -#endif - -// C++0x features in GCC 4.5.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_RANDOM -#endif - -// C++0x features in GCC 4.6.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 6) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -# define BOOST_NO_CXX11_HDR_TYPEINDEX -#endif - -// C++0x features in GCC 4.7.0 and later -// -#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7) || !defined(__GXX_EXPERIMENTAL_CXX0X__) -// Note that although existed prior to 4.7, "stead_clock" is spelled "monotonic_clock" -// so 4.7.0 is the first truely conforming one. -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_ALLOCATOR -#endif -// C++0x headers not yet (fully!) implemented -// -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR - -// --- end --- diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/modena.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/modena.hpp deleted file mode 100644 index b483b6e0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/modena.hpp +++ /dev/null @@ -1,56 +0,0 @@ -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Modena C++ standard library (comes with KAI C++) - -#if !defined(MSIPL_COMPILE_H) -# include -# if !defined(__MSIPL_COMPILE_H) -# error "This is not the Modena C++ library!" -# endif -#endif - -#ifndef MSIPL_NL_TYPES -#define BOOST_NO_STD_MESSAGES -#endif - -#ifndef MSIPL_WCHART -#define BOOST_NO_STD_WSTRING -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -#define BOOST_STDLIB "Modena C++ standard library" - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/msl.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/msl.hpp deleted file mode 100644 index 4f9a2da6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/msl.hpp +++ /dev/null @@ -1,84 +0,0 @@ -// (C) Copyright John Maddock 2001. -// (C) Copyright Darin Adler 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Metrowerks standard library: - -#ifndef __MSL_CPP__ -# include -# ifndef __MSL_CPP__ -# error This is not the MSL standard library! -# endif -#endif - -#if __MSL_CPP__ >= 0x6000 // Pro 6 -# define BOOST_HAS_HASH -# define BOOST_STD_EXTENSION_NAMESPACE Metrowerks -#endif -#define BOOST_HAS_SLIST - -#if __MSL_CPP__ < 0x6209 -# define BOOST_NO_STD_MESSAGES -#endif - -// check C lib version for -#include - -#if defined(__MSL__) && (__MSL__ >= 0x5000) -# define BOOST_HAS_STDINT_H -# if !defined(__PALMOS_TRAPS__) -# define BOOST_HAS_UNISTD_H -# endif - // boilerplate code: -# include -#endif - -#if defined(_MWMT) || _MSL_THREADSAFE -# define BOOST_HAS_THREADS -#endif - -#ifdef _MSL_NO_EXPLICIT_FUNC_TEMPLATE_ARG -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -#define BOOST_STDLIB "Metrowerks Standard Library version " BOOST_STRINGIZE(__MSL_CPP__) - - - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/roguewave.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/roguewave.hpp deleted file mode 100644 index cb80f570..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/roguewave.hpp +++ /dev/null @@ -1,186 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Jens Maurer 2001. -// (C) Copyright David Abrahams 2003. -// (C) Copyright Boris Gubenko 2007. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// Rogue Wave std lib: - -#define BOOST_RW_STDLIB 1 - -#if !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER) -# include -# if !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER) -# error This is not the Rogue Wave standard library -# endif -#endif -// -// figure out a consistent version number: -// -#ifndef _RWSTD_VER -# define BOOST_RWSTD_VER 0x010000 -#elif _RWSTD_VER < 0x010000 -# define BOOST_RWSTD_VER (_RWSTD_VER << 8) -#else -# define BOOST_RWSTD_VER _RWSTD_VER -#endif - -#ifndef _RWSTD_VER -# define BOOST_STDLIB "Rogue Wave standard library version (Unknown version)" -#elif _RWSTD_VER < 0x04010200 - # define BOOST_STDLIB "Rogue Wave standard library version " BOOST_STRINGIZE(_RWSTD_VER) -#else -# ifdef _RWSTD_VER_STR -# define BOOST_STDLIB "Apache STDCXX standard library version " _RWSTD_VER_STR -# else -# define BOOST_STDLIB "Apache STDCXX standard library version " BOOST_STRINGIZE(_RWSTD_VER) -# endif -#endif - -// -// Prior to version 2.2.0 the primary template for std::numeric_limits -// does not have compile time constants, even though specializations of that -// template do: -// -#if BOOST_RWSTD_VER < 0x020200 -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -#endif - -// Sun CC 5.5 patch 113817-07 adds long long specialization, but does not change the -// library version number (http://sunsolve6.sun.com/search/document.do?assetkey=1-21-113817): -#if BOOST_RWSTD_VER <= 0x020101 && (!defined(__SUNPRO_CC) || (__SUNPRO_CC < 0x550)) -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -# endif - -// -// Borland version of numeric_limits lacks __int64 specialisation: -// -#ifdef __BORLANDC__ -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -#endif - -// -// No std::iterator if it can't figure out default template args: -// -#if defined(_RWSTD_NO_SIMPLE_DEFAULT_TEMPLATES) || defined(RWSTD_NO_SIMPLE_DEFAULT_TEMPLATES) || (BOOST_RWSTD_VER < 0x020000) -# define BOOST_NO_STD_ITERATOR -#endif - -// -// No iterator traits without partial specialization: -// -#if defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) || defined(RWSTD_NO_CLASS_PARTIAL_SPEC) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// Prior to version 2.0, std::auto_ptr was buggy, and there were no -// new-style iostreams, and no conformant std::allocator: -// -#if (BOOST_RWSTD_VER < 0x020000) -# define BOOST_NO_AUTO_PTR -# define BOOST_NO_STRINGSTREAM -# define BOOST_NO_STD_ALLOCATOR -# define BOOST_NO_STD_LOCALE -#endif - -// -// No template iterator constructors without member template support: -// -#if defined(RWSTD_NO_MEMBER_TEMPLATES) || defined(_RWSTD_NO_MEMBER_TEMPLATES) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -#endif - -// -// RW defines _RWSTD_ALLOCATOR if the allocator is conformant and in use -// (the or _HPACC_ part is a hack - the library seems to define _RWSTD_ALLOCATOR -// on HP aCC systems even though the allocator is in fact broken): -// -#if !defined(_RWSTD_ALLOCATOR) || (defined(__HP_aCC) && __HP_aCC <= 33100) -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// If we have a std::locale, we still may not have std::use_facet: -// -#if defined(_RWSTD_NO_TEMPLATE_ON_RETURN_TYPE) && !defined(BOOST_NO_STD_LOCALE) -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_TWO_ARG_USE_FACET -#endif - -// -// There's no std::distance prior to version 2, or without -// partial specialization support: -// -#if (BOOST_RWSTD_VER < 0x020000) || defined(_RWSTD_NO_CLASS_PARTIAL_SPEC) - #define BOOST_NO_STD_DISTANCE -#endif - -// -// Some versions of the rogue wave library don't have assignable -// OutputIterators: -// -#if BOOST_RWSTD_VER < 0x020100 -# define BOOST_NO_STD_OUTPUT_ITERATOR_ASSIGN -#endif - -// -// Disable BOOST_HAS_LONG_LONG when the library has no support for it. -// -#if !defined(_RWSTD_LONG_LONG) && defined(BOOST_HAS_LONG_LONG) -# undef BOOST_HAS_LONG_LONG -#endif - -// -// check that on HP-UX, the proper RW library is used -// -#if defined(__HP_aCC) && !defined(_HP_NAMESPACE_STD) -# error "Boost requires Standard RW library. Please compile and link with -AA" -#endif - -// -// Define macros specific to RW V2.2 on HP-UX -// -#if defined(__HP_aCC) && (BOOST_RWSTD_VER == 0x02020100) -# ifndef __HP_TC1_MAKE_PAIR -# define __HP_TC1_MAKE_PAIR -# endif -# ifndef _HP_INSTANTIATE_STD2_VL -# define _HP_INSTANTIATE_STD2_VL -# endif -#endif - -#if _RWSTD_VER < 0x05000000 -# define BOOST_NO_CXX11_HDR_ARRAY -#endif -// type_traits header is incomplete: -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -// -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/sgi.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/sgi.hpp deleted file mode 100644 index ae9b6ad9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/sgi.hpp +++ /dev/null @@ -1,148 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2003. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Jens Maurer 2001 - 2003. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// generic SGI STL: - -#if !defined(__STL_CONFIG_H) -# include -# if !defined(__STL_CONFIG_H) -# error "This is not the SGI STL!" -# endif -#endif - -// -// No std::iterator traits without partial specialisation: -// -#if !defined(__STL_CLASS_PARTIAL_SPECIALIZATION) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// No std::stringstream with gcc < 3 -// -#if defined(__GNUC__) && (__GNUC__ < 3) && \ - ((__GNUC_MINOR__ < 95) || (__GNUC_MINOR__ == 96)) && \ - !defined(__STL_USE_NEW_IOSTREAMS) || \ - defined(__APPLE_CC__) - // Note that we only set this for GNU C++ prior to 2.95 since the - // latest patches for that release do contain a minimal - // If you are running a 2.95 release prior to 2.95.3 then this will need - // setting, but there is no way to detect that automatically (other - // than by running the configure script). - // Also, the unofficial GNU C++ 2.96 included in RedHat 7.1 doesn't - // have . -# define BOOST_NO_STRINGSTREAM -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include -#endif - - -// -// Assume no std::locale without own iostreams (this may be an -// incorrect assumption in some cases): -// -#if !defined(__SGI_STL_OWN_IOSTREAMS) && !defined(__STL_USE_NEW_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -#endif - -// -// Original native SGI streams have non-standard std::messages facet: -// -#if defined(__sgi) && (_COMPILER_VERSION <= 650) && !defined(__SGI_STL_OWN_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -#endif - -// -// SGI's new iostreams have missing "const" in messages<>::open -// -#if defined(__sgi) && (_COMPILER_VERSION <= 740) && defined(__STL_USE_NEW_IOSTREAMS) -# define BOOST_NO_STD_MESSAGES -#endif - -// -// No template iterator constructors, or std::allocator -// without member templates: -// -#if !defined(__STL_MEMBER_TEMPLATES) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// We always have SGI style hash_set, hash_map, and slist: -// -#define BOOST_HAS_HASH -#define BOOST_HAS_SLIST - -// -// If this is GNU libstdc++2, then no and no std::wstring: -// -#if (defined(__GNUC__) && (__GNUC__ < 3)) -# include -# if defined(__BASTRING__) -# define BOOST_NO_LIMITS -// Note: will provide compile-time constants -# undef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_STD_WSTRING -# endif -#endif - -// -// There is no standard iterator unless we have namespace support: -// -#if !defined(__STL_USE_NAMESPACES) -# define BOOST_NO_STD_ITERATOR -#endif - -// -// Intrinsic type_traits support. -// The SGI STL has it's own __type_traits class, which -// has intrinsic compiler support with SGI's compilers. -// Whatever map SGI style type traits to boost equivalents: -// -#define BOOST_HAS_SGI_TYPE_TRAITS - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -#define BOOST_STDLIB "SGI standard library" - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/stlport.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/stlport.hpp deleted file mode 100644 index bcc30b99..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/stlport.hpp +++ /dev/null @@ -1,243 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// (C) Copyright Darin Adler 2001. -// (C) Copyright Jens Maurer 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -// STLPort standard library config: - -#if !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -# include -# if !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -# error "This is not STLPort!" -# endif -#endif - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include -#endif - -// -// __STL_STATIC_CONST_INIT_BUG implies BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -// for versions prior to 4.1(beta) -// -#if (defined(__STL_STATIC_CONST_INIT_BUG) || defined(_STLP_STATIC_CONST_INIT_BUG)) && (__SGI_STL_PORT <= 0x400) -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -#endif - -// -// If STLport thinks that there is no partial specialisation, then there is no -// std::iterator traits: -// -#if !(defined(_STLP_CLASS_PARTIAL_SPECIALIZATION) || defined(__STL_CLASS_PARTIAL_SPECIALIZATION)) -# define BOOST_NO_STD_ITERATOR_TRAITS -#endif - -// -// No new style iostreams on GCC without STLport's iostreams enabled: -// -#if (defined(__GNUC__) && (__GNUC__ < 3)) && !(defined(__SGI_STL_OWN_IOSTREAMS) || defined(_STLP_OWN_IOSTREAMS)) -# define BOOST_NO_STRINGSTREAM -#endif - -// -// No new iostreams implies no std::locale, and no std::stringstream: -// -#if defined(__STL_NO_IOSTREAMS) || defined(__STL_NO_NEW_IOSTREAMS) || defined(_STLP_NO_IOSTREAMS) || defined(_STLP_NO_NEW_IOSTREAMS) -# define BOOST_NO_STD_LOCALE -# define BOOST_NO_STRINGSTREAM -#endif - -// -// If the streams are not native, and we have a "using ::x" compiler bug -// then the io stream facets are not available in namespace std:: -// -#ifdef _STLPORT_VERSION -# if !(_STLPORT_VERSION >= 0x500) && !defined(_STLP_OWN_IOSTREAMS) && defined(_STLP_USE_NAMESPACES) && defined(BOOST_NO_USING_TEMPLATE) && !defined(__BORLANDC__) -# define BOOST_NO_STD_LOCALE -# endif -#else -# if !defined(__SGI_STL_OWN_IOSTREAMS) && defined(__STL_USE_NAMESPACES) && defined(BOOST_NO_USING_TEMPLATE) && !defined(__BORLANDC__) -# define BOOST_NO_STD_LOCALE -# endif -#endif - -#if defined(_STLPORT_VERSION) && (_STLPORT_VERSION >= 0x520) -# define BOOST_HAS_TR1_UNORDERED_SET -# define BOOST_HAS_TR1_UNORDERED_MAP -#endif -// -// Without member template support enabled, their are no template -// iterate constructors, and no std::allocator: -// -#if !(defined(__STL_MEMBER_TEMPLATES) || defined(_STLP_MEMBER_TEMPLATES)) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# define BOOST_NO_STD_ALLOCATOR -#endif -// -// however we always have at least a partial allocator: -// -#define BOOST_HAS_PARTIAL_STD_ALLOCATOR - -#if !defined(_STLP_MEMBER_TEMPLATE_CLASSES) || defined(_STLP_DONT_SUPPORT_REBIND_MEMBER_TEMPLATE) -# define BOOST_NO_STD_ALLOCATOR -#endif - -#if defined(_STLP_NO_MEMBER_TEMPLATE_KEYWORD) && defined(BOOST_MSVC) && (BOOST_MSVC <= 1300) -# define BOOST_NO_STD_ALLOCATOR -#endif - -// -// If STLport thinks there is no wchar_t at all, then we have to disable -// the support for the relevant specilazations of std:: templates. -// -#if !defined(_STLP_HAS_WCHAR_T) && !defined(_STLP_WCHAR_T_IS_USHORT) -# ifndef BOOST_NO_STD_WSTRING -# define BOOST_NO_STD_WSTRING -# endif -# ifndef BOOST_NO_STD_WSTREAMBUF -# define BOOST_NO_STD_WSTREAMBUF -# endif -#endif - -// -// We always have SGI style hash_set, hash_map, and slist: -// -#ifndef _STLP_NO_EXTENSIONS -#define BOOST_HAS_HASH -#define BOOST_HAS_SLIST -#endif - -// -// STLport does a good job of importing names into namespace std::, -// but doesn't always get them all, define BOOST_NO_STDC_NAMESPACE, since our -// workaround does not conflict with STLports: -// -// -// Harold Howe says: -// Borland switched to STLport in BCB6. Defining BOOST_NO_STDC_NAMESPACE with -// BCB6 does cause problems. If we detect C++ Builder, then don't define -// BOOST_NO_STDC_NAMESPACE -// -#if !defined(__BORLANDC__) && !defined(__DMC__) -// -// If STLport is using it's own namespace, and the real names are in -// the global namespace, then we duplicate STLport's using declarations -// (by defining BOOST_NO_STDC_NAMESPACE), we do this because STLport doesn't -// necessarily import all the names we need into namespace std:: -// -# if (defined(__STL_IMPORT_VENDOR_CSTD) \ - || defined(__STL_USE_OWN_NAMESPACE) \ - || defined(_STLP_IMPORT_VENDOR_CSTD) \ - || defined(_STLP_USE_OWN_NAMESPACE)) \ - && (defined(__STL_VENDOR_GLOBAL_CSTD) || defined (_STLP_VENDOR_GLOBAL_CSTD)) -# define BOOST_NO_STDC_NAMESPACE -# define BOOST_NO_EXCEPTION_STD_NAMESPACE -# endif -#elif defined(__BORLANDC__) && __BORLANDC__ < 0x560 -// STLport doesn't import std::abs correctly: -#include -namespace std { using ::abs; } -// and strcmp/strcpy don't get imported either ('cos they are macros) -#include -#ifdef strcpy -# undef strcpy -#endif -#ifdef strcmp -# undef strcmp -#endif -#ifdef _STLP_VENDOR_CSTD -namespace std{ using _STLP_VENDOR_CSTD::strcmp; using _STLP_VENDOR_CSTD::strcpy; } -#endif -#endif - -// -// std::use_facet may be non-standard, uses a class instead: -// -#if defined(__STL_NO_EXPLICIT_FUNCTION_TMPL_ARGS) || defined(_STLP_NO_EXPLICIT_FUNCTION_TMPL_ARGS) -# define BOOST_NO_STD_USE_FACET -# define BOOST_HAS_STLP_USE_FACET -#endif - -// -// If STLport thinks there are no wide functions, etc. is not working; but -// only if BOOST_NO_STDC_NAMESPACE is not defined (if it is then we do the import -// into std:: ourselves). -// -#if defined(_STLP_NO_NATIVE_WIDE_FUNCTIONS) && !defined(BOOST_NO_STDC_NAMESPACE) -# define BOOST_NO_CWCHAR -# define BOOST_NO_CWCTYPE -#endif - -// -// If STLport for some reason was configured so that it thinks that wchar_t -// is not an intrinsic type, then we have to disable the support for it as -// well (we would be missing required specializations otherwise). -// -#if !defined( _STLP_HAS_WCHAR_T) || defined(_STLP_WCHAR_T_IS_USHORT) -# undef BOOST_NO_INTRINSIC_WCHAR_T -# define BOOST_NO_INTRINSIC_WCHAR_T -#endif - -// -// Borland ships a version of STLport with C++ Builder 6 that lacks -// hashtables and the like: -// -#if defined(__BORLANDC__) && (__BORLANDC__ == 0x560) -# undef BOOST_HAS_HASH -#endif - -// -// gcc-2.95.3/STLPort does not like the using declarations we use to get ADL with std::min/max -// -#if defined(__GNUC__) && (__GNUC__ < 3) -# include // for std::min and std::max -# define BOOST_USING_STD_MIN() ((void)0) -# define BOOST_USING_STD_MAX() ((void)0) -namespace boost { using std::min; using std::max; } -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -#define BOOST_STDLIB "STLPort standard library version " BOOST_STRINGIZE(__SGI_STL_PORT) - - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/vacpp.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/vacpp.hpp deleted file mode 100644 index 9d169465..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/stdlib/vacpp.hpp +++ /dev/null @@ -1,54 +0,0 @@ -// (C) Copyright John Maddock 2001 - 2002. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org for most recent version. - -#if __IBMCPP__ <= 501 -# define BOOST_NO_STD_ALLOCATOR -#endif - -#define BOOST_HAS_MACRO_USE_FACET -#define BOOST_NO_STD_MESSAGES - -// Apple doesn't seem to reliably defined a *unix* macro -#if !defined(CYGWIN) && ( defined(__unix__) \ - || defined(__unix) \ - || defined(unix) \ - || defined(__APPLE__) \ - || defined(__APPLE) \ - || defined(APPLE)) -# include -#endif - -// C++0x headers not yet implemented -// -# define BOOST_NO_CXX11_HDR_ARRAY -# define BOOST_NO_CXX11_HDR_CHRONO -# define BOOST_NO_CXX11_HDR_CODECVT -# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE -# define BOOST_NO_CXX11_HDR_FORWARD_LIST -# define BOOST_NO_CXX11_HDR_FUTURE -# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# define BOOST_NO_CXX11_HDR_MUTEX -# define BOOST_NO_CXX11_HDR_RANDOM -# define BOOST_NO_CXX11_HDR_RATIO -# define BOOST_NO_CXX11_HDR_REGEX -# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR -# define BOOST_NO_CXX11_HDR_THREAD -# define BOOST_NO_CXX11_HDR_TUPLE -# define BOOST_NO_CXX11_HDR_TYPE_TRAITS -# define BOOST_NO_CXX11_HDR_TYPEINDEX -# define BOOST_NO_CXX11_HDR_UNORDERED_MAP -# define BOOST_NO_CXX11_HDR_UNORDERED_SET -# define BOOST_NO_CXX11_NUMERIC_LIMITS -# define BOOST_NO_CXX11_ALLOCATOR -# define BOOST_NO_CXX11_ATOMIC_SMART_PTR -# define BOOST_NO_CXX11_SMART_PTR -# define BOOST_NO_CXX11_HDR_FUNCTIONAL - -#define BOOST_STDLIB "Visual Age default standard library" - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/suffix.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/suffix.hpp deleted file mode 100644 index c55579ea..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/suffix.hpp +++ /dev/null @@ -1,941 +0,0 @@ -// Boost config.hpp configuration header file ------------------------------// -// boostinspect:ndprecated_macros -- tell the inspect tool to ignore this file - -// Copyright (c) 2001-2003 John Maddock -// Copyright (c) 2001 Darin Adler -// Copyright (c) 2001 Peter Dimov -// Copyright (c) 2002 Bill Kempf -// Copyright (c) 2002 Jens Maurer -// Copyright (c) 2002-2003 David Abrahams -// Copyright (c) 2003 Gennaro Prota -// Copyright (c) 2003 Eric Friedman -// Copyright (c) 2010 Eric Jourdanneau, Joel Falcou -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/ for most recent version. - -// Boost config.hpp policy and rationale documentation has been moved to -// http://www.boost.org/libs/config/ -// -// This file is intended to be stable, and relatively unchanging. -// It should contain boilerplate code only - no compiler specific -// code unless it is unavoidable - no changes unless unavoidable. - -#ifndef BOOST_CONFIG_SUFFIX_HPP -#define BOOST_CONFIG_SUFFIX_HPP - -#if defined(__GNUC__) && (__GNUC__ >= 4) -// -// Some GCC-4.x versions issue warnings even when __extension__ is used, -// so use this as a workaround: -// -#pragma GCC system_header -#endif - -// -// ensure that visibility macros are always defined, thus symplifying use -// -#ifndef BOOST_SYMBOL_EXPORT -# define BOOST_SYMBOL_EXPORT -#endif -#ifndef BOOST_SYMBOL_IMPORT -# define BOOST_SYMBOL_IMPORT -#endif -#ifndef BOOST_SYMBOL_VISIBLE -# define BOOST_SYMBOL_VISIBLE -#endif - -// -// look for long long by looking for the appropriate macros in . -// Note that we use limits.h rather than climits for maximal portability, -// remember that since these just declare a bunch of macros, there should be -// no namespace issues from this. -// -#if !defined(BOOST_HAS_LONG_LONG) && !defined(BOOST_NO_LONG_LONG) \ - && !defined(BOOST_MSVC) && !defined(__BORLANDC__) -# include -# if (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX)) -# define BOOST_HAS_LONG_LONG -# else -# define BOOST_NO_LONG_LONG -# endif -#endif - -// GCC 3.x will clean up all of those nasty macro definitions that -// BOOST_NO_CTYPE_FUNCTIONS is intended to help work around, so undefine -// it under GCC 3.x. -#if defined(__GNUC__) && (__GNUC__ >= 3) && defined(BOOST_NO_CTYPE_FUNCTIONS) -# undef BOOST_NO_CTYPE_FUNCTIONS -#endif - -// -// Assume any extensions are in namespace std:: unless stated otherwise: -// -# ifndef BOOST_STD_EXTENSION_NAMESPACE -# define BOOST_STD_EXTENSION_NAMESPACE std -# endif - -// -// If cv-qualified specializations are not allowed, then neither are cv-void ones: -// -# if defined(BOOST_NO_CV_SPECIALIZATIONS) \ - && !defined(BOOST_NO_CV_VOID_SPECIALIZATIONS) -# define BOOST_NO_CV_VOID_SPECIALIZATIONS -# endif - -// -// If there is no numeric_limits template, then it can't have any compile time -// constants either! -// -# if defined(BOOST_NO_LIMITS) \ - && !defined(BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS) -# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -# endif - -// -// if there is no long long then there is no specialisation -// for numeric_limits either: -// -#if !defined(BOOST_HAS_LONG_LONG) && !defined(BOOST_NO_LONG_LONG_NUMERIC_LIMITS) -# define BOOST_NO_LONG_LONG_NUMERIC_LIMITS -#endif - -// -// if there is no __int64 then there is no specialisation -// for numeric_limits<__int64> either: -// -#if !defined(BOOST_HAS_MS_INT64) && !defined(BOOST_NO_MS_INT64_NUMERIC_LIMITS) -# define BOOST_NO_MS_INT64_NUMERIC_LIMITS -#endif - -// -// if member templates are supported then so is the -// VC6 subset of member templates: -// -# if !defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) -# define BOOST_MSVC6_MEMBER_TEMPLATES -# endif - -// -// Without partial specialization, can't test for partial specialisation bugs: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_BCB_PARTIAL_SPECIALIZATION_BUG) -# define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG -# endif - -// -// Without partial specialization, we can't have array-type partial specialisations: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS) -# define BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS -# endif - -// -// Without partial specialization, std::iterator_traits can't work: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_STD_ITERATOR_TRAITS) -# define BOOST_NO_STD_ITERATOR_TRAITS -# endif - -// -// Without partial specialization, partial -// specialization with default args won't work either: -// -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS) -# define BOOST_NO_PARTIAL_SPECIALIZATION_IMPLICIT_DEFAULT_ARGS -# endif - -// -// Without member template support, we can't have template constructors -// in the standard library either: -// -# if defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) \ - && !defined(BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS) -# define BOOST_NO_TEMPLATED_ITERATOR_CONSTRUCTORS -# endif - -// -// Without member template support, we can't have a conforming -// std::allocator template either: -// -# if defined(BOOST_NO_MEMBER_TEMPLATES) \ - && !defined(BOOST_MSVC6_MEMBER_TEMPLATES) \ - && !defined(BOOST_NO_STD_ALLOCATOR) -# define BOOST_NO_STD_ALLOCATOR -# endif - -// -// without ADL support then using declarations will break ADL as well: -// -#if defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL) -# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL -#endif - -// -// Without typeid support we have no dynamic RTTI either: -// -#if defined(BOOST_NO_TYPEID) && !defined(BOOST_NO_RTTI) -# define BOOST_NO_RTTI -#endif - -// -// If we have a standard allocator, then we have a partial one as well: -// -#if !defined(BOOST_NO_STD_ALLOCATOR) -# define BOOST_HAS_PARTIAL_STD_ALLOCATOR -#endif - -// -// We can't have a working std::use_facet if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_USE_FACET) -# define BOOST_NO_STD_USE_FACET -# endif - -// -// We can't have a std::messages facet if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_MESSAGES) -# define BOOST_NO_STD_MESSAGES -# endif - -// -// We can't have a working std::wstreambuf if there is no std::locale: -// -# if defined(BOOST_NO_STD_LOCALE) && !defined(BOOST_NO_STD_WSTREAMBUF) -# define BOOST_NO_STD_WSTREAMBUF -# endif - -// -// We can't have a if there is no : -// -# if defined(BOOST_NO_CWCHAR) && !defined(BOOST_NO_CWCTYPE) -# define BOOST_NO_CWCTYPE -# endif - -// -// We can't have a swprintf if there is no : -// -# if defined(BOOST_NO_CWCHAR) && !defined(BOOST_NO_SWPRINTF) -# define BOOST_NO_SWPRINTF -# endif - -// -// If Win32 support is turned off, then we must turn off -// threading support also, unless there is some other -// thread API enabled: -// -#if defined(BOOST_DISABLE_WIN32) && defined(_WIN32) \ - && !defined(BOOST_DISABLE_THREADS) && !defined(BOOST_HAS_PTHREADS) -# define BOOST_DISABLE_THREADS -#endif - -// -// Turn on threading support if the compiler thinks that it's in -// multithreaded mode. We put this here because there are only a -// limited number of macros that identify this (if there's any missing -// from here then add to the appropriate compiler section): -// -#if (defined(__MT__) || defined(_MT) || defined(_REENTRANT) \ - || defined(_PTHREADS) || defined(__APPLE__) || defined(__DragonFly__)) \ - && !defined(BOOST_HAS_THREADS) -# define BOOST_HAS_THREADS -#endif - -// -// Turn threading support off if BOOST_DISABLE_THREADS is defined: -// -#if defined(BOOST_DISABLE_THREADS) && defined(BOOST_HAS_THREADS) -# undef BOOST_HAS_THREADS -#endif - -// -// Turn threading support off if we don't recognise the threading API: -// -#if defined(BOOST_HAS_THREADS) && !defined(BOOST_HAS_PTHREADS)\ - && !defined(BOOST_HAS_WINTHREADS) && !defined(BOOST_HAS_BETHREADS)\ - && !defined(BOOST_HAS_MPTASKS) -# undef BOOST_HAS_THREADS -#endif - -// -// Turn threading detail macros off if we don't (want to) use threading -// -#ifndef BOOST_HAS_THREADS -# undef BOOST_HAS_PTHREADS -# undef BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE -# undef BOOST_HAS_PTHREAD_YIELD -# undef BOOST_HAS_PTHREAD_DELAY_NP -# undef BOOST_HAS_WINTHREADS -# undef BOOST_HAS_BETHREADS -# undef BOOST_HAS_MPTASKS -#endif - -// -// If the compiler claims to be C99 conformant, then it had better -// have a : -// -# if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901) -# define BOOST_HAS_STDINT_H -# ifndef BOOST_HAS_LOG1P -# define BOOST_HAS_LOG1P -# endif -# ifndef BOOST_HAS_EXPM1 -# define BOOST_HAS_EXPM1 -# endif -# endif - -// -// Define BOOST_NO_SLIST and BOOST_NO_HASH if required. -// Note that this is for backwards compatibility only. -// -# if !defined(BOOST_HAS_SLIST) && !defined(BOOST_NO_SLIST) -# define BOOST_NO_SLIST -# endif - -# if !defined(BOOST_HAS_HASH) && !defined(BOOST_NO_HASH) -# define BOOST_NO_HASH -# endif - -// -// Set BOOST_SLIST_HEADER if not set already: -// -#if defined(BOOST_HAS_SLIST) && !defined(BOOST_SLIST_HEADER) -# define BOOST_SLIST_HEADER -#endif - -// -// Set BOOST_HASH_SET_HEADER if not set already: -// -#if defined(BOOST_HAS_HASH) && !defined(BOOST_HASH_SET_HEADER) -# define BOOST_HASH_SET_HEADER -#endif - -// -// Set BOOST_HASH_MAP_HEADER if not set already: -// -#if defined(BOOST_HAS_HASH) && !defined(BOOST_HASH_MAP_HEADER) -# define BOOST_HASH_MAP_HEADER -#endif - -// BOOST_HAS_ABI_HEADERS -// This macro gets set if we have headers that fix the ABI, -// and prevent ODR violations when linking to external libraries: -#if defined(BOOST_ABI_PREFIX) && defined(BOOST_ABI_SUFFIX) && !defined(BOOST_HAS_ABI_HEADERS) -# define BOOST_HAS_ABI_HEADERS -#endif - -#if defined(BOOST_HAS_ABI_HEADERS) && defined(BOOST_DISABLE_ABI_HEADERS) -# undef BOOST_HAS_ABI_HEADERS -#endif - -// BOOST_NO_STDC_NAMESPACE workaround --------------------------------------// -// Because std::size_t usage is so common, even in boost headers which do not -// otherwise use the C library, the workaround is included here so -// that ugly workaround code need not appear in many other boost headers. -// NOTE WELL: This is a workaround for non-conforming compilers; -// must still be #included in the usual places so that inclusion -// works as expected with standard conforming compilers. The resulting -// double inclusion of is harmless. - -# if defined(BOOST_NO_STDC_NAMESPACE) && defined(__cplusplus) -# include - namespace std { using ::ptrdiff_t; using ::size_t; } -# endif - -// Workaround for the unfortunate min/max macros defined by some platform headers - -#define BOOST_PREVENT_MACRO_SUBSTITUTION - -#ifndef BOOST_USING_STD_MIN -# define BOOST_USING_STD_MIN() using std::min -#endif - -#ifndef BOOST_USING_STD_MAX -# define BOOST_USING_STD_MAX() using std::max -#endif - -// BOOST_NO_STD_MIN_MAX workaround -----------------------------------------// - -# if defined(BOOST_NO_STD_MIN_MAX) && defined(__cplusplus) - -namespace std { - template - inline const _Tp& min BOOST_PREVENT_MACRO_SUBSTITUTION (const _Tp& __a, const _Tp& __b) { - return __b < __a ? __b : __a; - } - template - inline const _Tp& max BOOST_PREVENT_MACRO_SUBSTITUTION (const _Tp& __a, const _Tp& __b) { - return __a < __b ? __b : __a; - } -} - -# endif - -// BOOST_STATIC_CONSTANT workaround --------------------------------------- // -// On compilers which don't allow in-class initialization of static integral -// constant members, we must use enums as a workaround if we want the constants -// to be available at compile-time. This macro gives us a convenient way to -// declare such constants. - -# ifdef BOOST_NO_INCLASS_MEMBER_INITIALIZATION -# define BOOST_STATIC_CONSTANT(type, assignment) enum { assignment } -# else -# define BOOST_STATIC_CONSTANT(type, assignment) static const type assignment -# endif - -// BOOST_USE_FACET / HAS_FACET workaround ----------------------------------// -// When the standard library does not have a conforming std::use_facet there -// are various workarounds available, but they differ from library to library. -// The same problem occurs with has_facet. -// These macros provide a consistent way to access a locale's facets. -// Usage: -// replace -// std::use_facet(loc); -// with -// BOOST_USE_FACET(Type, loc); -// Note do not add a std:: prefix to the front of BOOST_USE_FACET! -// Use for BOOST_HAS_FACET is analogous. - -#if defined(BOOST_NO_STD_USE_FACET) -# ifdef BOOST_HAS_TWO_ARG_USE_FACET -# define BOOST_USE_FACET(Type, loc) std::use_facet(loc, static_cast(0)) -# define BOOST_HAS_FACET(Type, loc) std::has_facet(loc, static_cast(0)) -# elif defined(BOOST_HAS_MACRO_USE_FACET) -# define BOOST_USE_FACET(Type, loc) std::_USE(loc, Type) -# define BOOST_HAS_FACET(Type, loc) std::_HAS(loc, Type) -# elif defined(BOOST_HAS_STLP_USE_FACET) -# define BOOST_USE_FACET(Type, loc) (*std::_Use_facet(loc)) -# define BOOST_HAS_FACET(Type, loc) std::has_facet< Type >(loc) -# endif -#else -# define BOOST_USE_FACET(Type, loc) std::use_facet< Type >(loc) -# define BOOST_HAS_FACET(Type, loc) std::has_facet< Type >(loc) -#endif - -// BOOST_NESTED_TEMPLATE workaround ------------------------------------------// -// Member templates are supported by some compilers even though they can't use -// the A::template member syntax, as a workaround replace: -// -// typedef typename A::template rebind binder; -// -// with: -// -// typedef typename A::BOOST_NESTED_TEMPLATE rebind binder; - -#ifndef BOOST_NO_MEMBER_TEMPLATE_KEYWORD -# define BOOST_NESTED_TEMPLATE template -#else -# define BOOST_NESTED_TEMPLATE -#endif - -// BOOST_UNREACHABLE_RETURN(x) workaround -------------------------------------// -// Normally evaluates to nothing, unless BOOST_NO_UNREACHABLE_RETURN_DETECTION -// is defined, in which case it evaluates to return x; Use when you have a return -// statement that can never be reached. - -#ifdef BOOST_NO_UNREACHABLE_RETURN_DETECTION -# define BOOST_UNREACHABLE_RETURN(x) return x; -#else -# define BOOST_UNREACHABLE_RETURN(x) -#endif - -// BOOST_DEDUCED_TYPENAME workaround ------------------------------------------// -// -// Some compilers don't support the use of `typename' for dependent -// types in deduced contexts, e.g. -// -// template void f(T, typename T::type); -// ^^^^^^^^ -// Replace these declarations with: -// -// template void f(T, BOOST_DEDUCED_TYPENAME T::type); - -#ifndef BOOST_NO_DEDUCED_TYPENAME -# define BOOST_DEDUCED_TYPENAME typename -#else -# define BOOST_DEDUCED_TYPENAME -#endif - -#ifndef BOOST_NO_TYPENAME_WITH_CTOR -# define BOOST_CTOR_TYPENAME typename -#else -# define BOOST_CTOR_TYPENAME -#endif - -// long long workaround ------------------------------------------// -// On gcc (and maybe other compilers?) long long is alway supported -// but it's use may generate either warnings (with -ansi), or errors -// (with -pedantic -ansi) unless it's use is prefixed by __extension__ -// -#if defined(BOOST_HAS_LONG_LONG) && defined(__cplusplus) -namespace boost{ -# ifdef __GNUC__ - __extension__ typedef long long long_long_type; - __extension__ typedef unsigned long long ulong_long_type; -# else - typedef long long long_long_type; - typedef unsigned long long ulong_long_type; -# endif -} -#endif -// same again for __int128: -#if defined(BOOST_HAS_INT128) && defined(__cplusplus) -namespace boost{ -# ifdef __GNUC__ - __extension__ typedef __int128 int128_type; - __extension__ typedef unsigned __int128 uint128_type; -# else - typedef __int128 int128_type; - typedef unsigned __int128 uint128_type; -# endif -} -#endif - -// BOOST_[APPEND_]EXPLICIT_TEMPLATE_[NON_]TYPE macros --------------------------// - -// These macros are obsolete. Port away and remove. - -# define BOOST_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -# define BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE(t) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE_SPEC(t) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_NON_TYPE(t, v) -# define BOOST_APPEND_EXPLICIT_TEMPLATE_NON_TYPE_SPEC(t, v) - -// When BOOST_NO_STD_TYPEINFO is defined, we can just import -// the global definition into std namespace: -#if defined(BOOST_NO_STD_TYPEINFO) && defined(__cplusplus) -#include -namespace std{ using ::type_info; } -#endif - -// ---------------------------------------------------------------------------// - -// -// Helper macro BOOST_STRINGIZE: -// Converts the parameter X to a string after macro replacement -// on X has been performed. -// -#define BOOST_STRINGIZE(X) BOOST_DO_STRINGIZE(X) -#define BOOST_DO_STRINGIZE(X) #X - -// -// Helper macro BOOST_JOIN: -// The following piece of macro magic joins the two -// arguments together, even when one of the arguments is -// itself a macro (see 16.3.1 in C++ standard). The key -// is that macro expansion of macro arguments does not -// occur in BOOST_DO_JOIN2 but does in BOOST_DO_JOIN. -// -#define BOOST_JOIN( X, Y ) BOOST_DO_JOIN( X, Y ) -#define BOOST_DO_JOIN( X, Y ) BOOST_DO_JOIN2(X,Y) -#define BOOST_DO_JOIN2( X, Y ) X##Y - -// -// Set some default values for compiler/library/platform names. -// These are for debugging config setup only: -// -# ifndef BOOST_COMPILER -# define BOOST_COMPILER "Unknown ISO C++ Compiler" -# endif -# ifndef BOOST_STDLIB -# define BOOST_STDLIB "Unknown ISO standard library" -# endif -# ifndef BOOST_PLATFORM -# if defined(unix) || defined(__unix) || defined(_XOPEN_SOURCE) \ - || defined(_POSIX_SOURCE) -# define BOOST_PLATFORM "Generic Unix" -# else -# define BOOST_PLATFORM "Unknown" -# endif -# endif - -// -// Set some default values GPU support -// -# ifndef BOOST_GPU_ENABLED -# define BOOST_GPU_ENABLED -# endif - -// BOOST_FORCEINLINE ---------------------------------------------// -// Macro to use in place of 'inline' to force a function to be inline -#if !defined(BOOST_FORCEINLINE) -# if defined(_MSC_VER) -# define BOOST_FORCEINLINE __forceinline -# elif defined(__GNUC__) && __GNUC__ > 3 - // Clang also defines __GNUC__ (as 4) -# define BOOST_FORCEINLINE inline __attribute__ ((__always_inline__)) -# else -# define BOOST_FORCEINLINE inline -# endif -#endif - -// BOOST_NOINLINE ---------------------------------------------// -// Macro to use in place of 'inline' to prevent a function to be inlined -#if !defined(BOOST_NOINLINE) -# if defined(_MSC_VER) -# define BOOST_NOINLINE __declspec(noinline) -# elif defined(__GNUC__) && __GNUC__ > 3 - // Clang also defines __GNUC__ (as 4) -# define BOOST_NOINLINE __attribute__ ((__noinline__)) -# else -# define BOOST_NOINLINE -# endif -#endif - -// Branch prediction hints -// These macros are intended to wrap conditional expressions that yield true or false -// -// if (BOOST_LIKELY(var == 10)) -// { -// // the most probable code here -// } -// -#if !defined(BOOST_LIKELY) -# define BOOST_LIKELY(x) x -#endif -#if !defined(BOOST_UNLIKELY) -# define BOOST_UNLIKELY(x) x -#endif - -// Type and data alignment specification -// -#if !defined(BOOST_NO_CXX11_ALIGNAS) -# define BOOST_ALIGNMENT(x) alignas(x) -#elif defined(_MSC_VER) -# define BOOST_ALIGNMENT(x) __declspec(align(x)) -#elif defined(__GNUC__) -# define BOOST_ALIGNMENT(x) __attribute__ ((__aligned__(x))) -#else -# define BOOST_NO_ALIGNMENT -# define BOOST_ALIGNMENT(x) -#endif - -// Defaulted and deleted function declaration helpers -// These macros are intended to be inside a class definition. -// BOOST_DEFAULTED_FUNCTION accepts the function declaration and its -// body, which will be used if the compiler doesn't support defaulted functions. -// BOOST_DELETED_FUNCTION only accepts the function declaration. It -// will expand to a private function declaration, if the compiler doesn't support -// deleted functions. Because of this it is recommended to use BOOST_DELETED_FUNCTION -// in the end of the class definition. -// -// class my_class -// { -// public: -// // Default-constructible -// BOOST_DEFAULTED_FUNCTION(my_class(), {}) -// // Copying prohibited -// BOOST_DELETED_FUNCTION(my_class(my_class const&)) -// BOOST_DELETED_FUNCTION(my_class& operator= (my_class const&)) -// }; -// -#if !(defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) || defined(BOOST_NO_CXX11_NON_PUBLIC_DEFAULTED_FUNCTIONS)) -# define BOOST_DEFAULTED_FUNCTION(fun, body) fun = default; -#else -# define BOOST_DEFAULTED_FUNCTION(fun, body) fun body -#endif - -#if !defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) -# define BOOST_DELETED_FUNCTION(fun) fun = delete; -#else -# define BOOST_DELETED_FUNCTION(fun) private: fun; -#endif - -// -// Set BOOST_NO_DECLTYPE_N3276 when BOOST_NO_DECLTYPE is defined -// -#if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_CXX11_DECLTYPE_N3276) -#define BOOST_NO_CXX11_DECLTYPE_N3276 BOOST_NO_CXX11_DECLTYPE -#endif - -// -------------------- Deprecated macros for 1.50 --------------------------- -// These will go away in a future release - -// Use BOOST_NO_CXX11_HDR_UNORDERED_SET or BOOST_NO_CXX11_HDR_UNORDERED_MAP -// instead of BOOST_NO_STD_UNORDERED -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_MAP) || defined (BOOST_NO_CXX11_HDR_UNORDERED_SET) -# ifndef BOOST_NO_CXX11_STD_UNORDERED -# define BOOST_NO_CXX11_STD_UNORDERED -# endif -#endif - -// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST instead of BOOST_NO_INITIALIZER_LISTS -#if defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) && !defined(BOOST_NO_INITIALIZER_LISTS) -# define BOOST_NO_INITIALIZER_LISTS -#endif - -// Use BOOST_NO_CXX11_HDR_ARRAY instead of BOOST_NO_0X_HDR_ARRAY -#if defined(BOOST_NO_CXX11_HDR_ARRAY) && !defined(BOOST_NO_0X_HDR_ARRAY) -# define BOOST_NO_0X_HDR_ARRAY -#endif -// Use BOOST_NO_CXX11_HDR_CHRONO instead of BOOST_NO_0X_HDR_CHRONO -#if defined(BOOST_NO_CXX11_HDR_CHRONO) && !defined(BOOST_NO_0X_HDR_CHRONO) -# define BOOST_NO_0X_HDR_CHRONO -#endif -// Use BOOST_NO_CXX11_HDR_CODECVT instead of BOOST_NO_0X_HDR_CODECVT -#if defined(BOOST_NO_CXX11_HDR_CODECVT) && !defined(BOOST_NO_0X_HDR_CODECVT) -# define BOOST_NO_0X_HDR_CODECVT -#endif -// Use BOOST_NO_CXX11_HDR_CONDITION_VARIABLE instead of BOOST_NO_0X_HDR_CONDITION_VARIABLE -#if defined(BOOST_NO_CXX11_HDR_CONDITION_VARIABLE) && !defined(BOOST_NO_0X_HDR_CONDITION_VARIABLE) -# define BOOST_NO_0X_HDR_CONDITION_VARIABLE -#endif -// Use BOOST_NO_CXX11_HDR_FORWARD_LIST instead of BOOST_NO_0X_HDR_FORWARD_LIST -#if defined(BOOST_NO_CXX11_HDR_FORWARD_LIST) && !defined(BOOST_NO_0X_HDR_FORWARD_LIST) -# define BOOST_NO_0X_HDR_FORWARD_LIST -#endif -// Use BOOST_NO_CXX11_HDR_FUTURE instead of BOOST_NO_0X_HDR_FUTURE -#if defined(BOOST_NO_CXX11_HDR_FUTURE) && !defined(BOOST_NO_0X_HDR_FUTURE) -# define BOOST_NO_0X_HDR_FUTURE -#endif - -// Use BOOST_NO_CXX11_HDR_INITIALIZER_LIST -// instead of BOOST_NO_0X_HDR_INITIALIZER_LIST or BOOST_NO_INITIALIZER_LISTS -#ifdef BOOST_NO_CXX11_HDR_INITIALIZER_LIST -# ifndef BOOST_NO_0X_HDR_INITIALIZER_LIST -# define BOOST_NO_0X_HDR_INITIALIZER_LIST -# endif -# ifndef BOOST_NO_INITIALIZER_LISTS -# define BOOST_NO_INITIALIZER_LISTS -# endif -#endif - -// Use BOOST_NO_CXX11_HDR_MUTEX instead of BOOST_NO_0X_HDR_MUTEX -#if defined(BOOST_NO_CXX11_HDR_MUTEX) && !defined(BOOST_NO_0X_HDR_MUTEX) -# define BOOST_NO_0X_HDR_MUTEX -#endif -// Use BOOST_NO_CXX11_HDR_RANDOM instead of BOOST_NO_0X_HDR_RANDOM -#if defined(BOOST_NO_CXX11_HDR_RANDOM) && !defined(BOOST_NO_0X_HDR_RANDOM) -# define BOOST_NO_0X_HDR_RANDOM -#endif -// Use BOOST_NO_CXX11_HDR_RATIO instead of BOOST_NO_0X_HDR_RATIO -#if defined(BOOST_NO_CXX11_HDR_RATIO) && !defined(BOOST_NO_0X_HDR_RATIO) -# define BOOST_NO_0X_HDR_RATIO -#endif -// Use BOOST_NO_CXX11_HDR_REGEX instead of BOOST_NO_0X_HDR_REGEX -#if defined(BOOST_NO_CXX11_HDR_REGEX) && !defined(BOOST_NO_0X_HDR_REGEX) -# define BOOST_NO_0X_HDR_REGEX -#endif -// Use BOOST_NO_CXX11_HDR_SYSTEM_ERROR instead of BOOST_NO_0X_HDR_SYSTEM_ERROR -#if defined(BOOST_NO_CXX11_HDR_SYSTEM_ERROR) && !defined(BOOST_NO_0X_HDR_SYSTEM_ERROR) -# define BOOST_NO_0X_HDR_SYSTEM_ERROR -#endif -// Use BOOST_NO_CXX11_HDR_THREAD instead of BOOST_NO_0X_HDR_THREAD -#if defined(BOOST_NO_CXX11_HDR_THREAD) && !defined(BOOST_NO_0X_HDR_THREAD) -# define BOOST_NO_0X_HDR_THREAD -#endif -// Use BOOST_NO_CXX11_HDR_TUPLE instead of BOOST_NO_0X_HDR_TUPLE -#if defined(BOOST_NO_CXX11_HDR_TUPLE) && !defined(BOOST_NO_0X_HDR_TUPLE) -# define BOOST_NO_0X_HDR_TUPLE -#endif -// Use BOOST_NO_CXX11_HDR_TYPE_TRAITS instead of BOOST_NO_0X_HDR_TYPE_TRAITS -#if defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS) && !defined(BOOST_NO_0X_HDR_TYPE_TRAITS) -# define BOOST_NO_0X_HDR_TYPE_TRAITS -#endif -// Use BOOST_NO_CXX11_HDR_TYPEINDEX instead of BOOST_NO_0X_HDR_TYPEINDEX -#if defined(BOOST_NO_CXX11_HDR_TYPEINDEX) && !defined(BOOST_NO_0X_HDR_TYPEINDEX) -# define BOOST_NO_0X_HDR_TYPEINDEX -#endif -// Use BOOST_NO_CXX11_HDR_UNORDERED_MAP instead of BOOST_NO_0X_HDR_UNORDERED_MAP -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_MAP) && !defined(BOOST_NO_0X_HDR_UNORDERED_MAP) -# define BOOST_NO_0X_HDR_UNORDERED_MAP -#endif -// Use BOOST_NO_CXX11_HDR_UNORDERED_SET instead of BOOST_NO_0X_HDR_UNORDERED_SET -#if defined(BOOST_NO_CXX11_HDR_UNORDERED_SET) && !defined(BOOST_NO_0X_HDR_UNORDERED_SET) -# define BOOST_NO_0X_HDR_UNORDERED_SET -#endif - -// ------------------ End of deprecated macros for 1.50 --------------------------- - -// -------------------- Deprecated macros for 1.51 --------------------------- -// These will go away in a future release - -// Use BOOST_NO_CXX11_AUTO_DECLARATIONS instead of BOOST_NO_AUTO_DECLARATIONS -#if defined(BOOST_NO_CXX11_AUTO_DECLARATIONS) && !defined(BOOST_NO_AUTO_DECLARATIONS) -# define BOOST_NO_AUTO_DECLARATIONS -#endif -// Use BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS instead of BOOST_NO_AUTO_MULTIDECLARATIONS -#if defined(BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS) && !defined(BOOST_NO_AUTO_MULTIDECLARATIONS) -# define BOOST_NO_AUTO_MULTIDECLARATIONS -#endif -// Use BOOST_NO_CXX11_CHAR16_T instead of BOOST_NO_CHAR16_T -#if defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CHAR16_T) -# define BOOST_NO_CHAR16_T -#endif -// Use BOOST_NO_CXX11_CHAR32_T instead of BOOST_NO_CHAR32_T -#if defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CHAR32_T) -# define BOOST_NO_CHAR32_T -#endif -// Use BOOST_NO_CXX11_TEMPLATE_ALIASES instead of BOOST_NO_TEMPLATE_ALIASES -#if defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) && !defined(BOOST_NO_TEMPLATE_ALIASES) -# define BOOST_NO_TEMPLATE_ALIASES -#endif -// Use BOOST_NO_CXX11_CONSTEXPR instead of BOOST_NO_CONSTEXPR -#if defined(BOOST_NO_CXX11_CONSTEXPR) && !defined(BOOST_NO_CONSTEXPR) -# define BOOST_NO_CONSTEXPR -#endif -// Use BOOST_NO_CXX11_DECLTYPE_N3276 instead of BOOST_NO_DECLTYPE_N3276 -#if defined(BOOST_NO_CXX11_DECLTYPE_N3276) && !defined(BOOST_NO_DECLTYPE_N3276) -# define BOOST_NO_DECLTYPE_N3276 -#endif -// Use BOOST_NO_CXX11_DECLTYPE instead of BOOST_NO_DECLTYPE -#if defined(BOOST_NO_CXX11_DECLTYPE) && !defined(BOOST_NO_DECLTYPE) -# define BOOST_NO_DECLTYPE -#endif -// Use BOOST_NO_CXX11_DEFAULTED_FUNCTIONS instead of BOOST_NO_DEFAULTED_FUNCTIONS -#if defined(BOOST_NO_CXX11_DEFAULTED_FUNCTIONS) && !defined(BOOST_NO_DEFAULTED_FUNCTIONS) -# define BOOST_NO_DEFAULTED_FUNCTIONS -#endif -// Use BOOST_NO_CXX11_DELETED_FUNCTIONS instead of BOOST_NO_DELETED_FUNCTIONS -#if defined(BOOST_NO_CXX11_DELETED_FUNCTIONS) && !defined(BOOST_NO_DELETED_FUNCTIONS) -# define BOOST_NO_DELETED_FUNCTIONS -#endif -// Use BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS instead of BOOST_NO_EXPLICIT_CONVERSION_OPERATORS -#if defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) && !defined(BOOST_NO_EXPLICIT_CONVERSION_OPERATORS) -# define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS -#endif -// Use BOOST_NO_CXX11_EXTERN_TEMPLATE instead of BOOST_NO_EXTERN_TEMPLATE -#if defined(BOOST_NO_CXX11_EXTERN_TEMPLATE) && !defined(BOOST_NO_EXTERN_TEMPLATE) -# define BOOST_NO_EXTERN_TEMPLATE -#endif -// Use BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS instead of BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS -#if defined(BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS) && !defined(BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS) -# define BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS -#endif -// Use BOOST_NO_CXX11_LAMBDAS instead of BOOST_NO_LAMBDAS -#if defined(BOOST_NO_CXX11_LAMBDAS) && !defined(BOOST_NO_LAMBDAS) -# define BOOST_NO_LAMBDAS -#endif -// Use BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS instead of BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS -#if defined(BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS) && !defined(BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS) -# define BOOST_NO_LOCAL_CLASS_TEMPLATE_PARAMETERS -#endif -// Use BOOST_NO_CXX11_NOEXCEPT instead of BOOST_NO_NOEXCEPT -#if defined(BOOST_NO_CXX11_NOEXCEPT) && !defined(BOOST_NO_NOEXCEPT) -# define BOOST_NO_NOEXCEPT -#endif -// Use BOOST_NO_CXX11_NULLPTR instead of BOOST_NO_NULLPTR -#if defined(BOOST_NO_CXX11_NULLPTR) && !defined(BOOST_NO_NULLPTR) -# define BOOST_NO_NULLPTR -#endif -// Use BOOST_NO_CXX11_RAW_LITERALS instead of BOOST_NO_RAW_LITERALS -#if defined(BOOST_NO_CXX11_RAW_LITERALS) && !defined(BOOST_NO_RAW_LITERALS) -# define BOOST_NO_RAW_LITERALS -#endif -// Use BOOST_NO_CXX11_RVALUE_REFERENCES instead of BOOST_NO_RVALUE_REFERENCES -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_RVALUE_REFERENCES) -# define BOOST_NO_RVALUE_REFERENCES -#endif -// Use BOOST_NO_CXX11_SCOPED_ENUMS instead of BOOST_NO_SCOPED_ENUMS -#if defined(BOOST_NO_CXX11_SCOPED_ENUMS) && !defined(BOOST_NO_SCOPED_ENUMS) -# define BOOST_NO_SCOPED_ENUMS -#endif -// Use BOOST_NO_CXX11_STATIC_ASSERT instead of BOOST_NO_STATIC_ASSERT -#if defined(BOOST_NO_CXX11_STATIC_ASSERT) && !defined(BOOST_NO_STATIC_ASSERT) -# define BOOST_NO_STATIC_ASSERT -#endif -// Use BOOST_NO_CXX11_STD_UNORDERED instead of BOOST_NO_STD_UNORDERED -#if defined(BOOST_NO_CXX11_STD_UNORDERED) && !defined(BOOST_NO_STD_UNORDERED) -# define BOOST_NO_STD_UNORDERED -#endif -// Use BOOST_NO_CXX11_UNICODE_LITERALS instead of BOOST_NO_UNICODE_LITERALS -#if defined(BOOST_NO_CXX11_UNICODE_LITERALS) && !defined(BOOST_NO_UNICODE_LITERALS) -# define BOOST_NO_UNICODE_LITERALS -#endif -// Use BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX instead of BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX -#if defined(BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX) && !defined(BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX) -# define BOOST_NO_UNIFIED_INITIALIZATION_SYNTAX -#endif -// Use BOOST_NO_CXX11_VARIADIC_TEMPLATES instead of BOOST_NO_VARIADIC_TEMPLATES -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_VARIADIC_TEMPLATES) -# define BOOST_NO_VARIADIC_TEMPLATES -#endif -// Use BOOST_NO_CXX11_VARIADIC_MACROS instead of BOOST_NO_VARIADIC_MACROS -#if defined(BOOST_NO_CXX11_VARIADIC_MACROS) && !defined(BOOST_NO_VARIADIC_MACROS) -# define BOOST_NO_VARIADIC_MACROS -#endif -// Use BOOST_NO_CXX11_NUMERIC_LIMITS instead of BOOST_NO_NUMERIC_LIMITS_LOWEST -#if defined(BOOST_NO_CXX11_NUMERIC_LIMITS) && !defined(BOOST_NO_NUMERIC_LIMITS_LOWEST) -# define BOOST_NO_NUMERIC_LIMITS_LOWEST -#endif -// ------------------ End of deprecated macros for 1.51 --------------------------- - - - -// -// Helper macros BOOST_NOEXCEPT, BOOST_NOEXCEPT_IF, BOOST_NOEXCEPT_EXPR -// These aid the transition to C++11 while still supporting C++03 compilers -// -#ifdef BOOST_NO_CXX11_NOEXCEPT -# define BOOST_NOEXCEPT -# define BOOST_NOEXCEPT_OR_NOTHROW throw() -# define BOOST_NOEXCEPT_IF(Predicate) -# define BOOST_NOEXCEPT_EXPR(Expression) false -#else -# define BOOST_NOEXCEPT noexcept -# define BOOST_NOEXCEPT_OR_NOTHROW noexcept -# define BOOST_NOEXCEPT_IF(Predicate) noexcept((Predicate)) -# define BOOST_NOEXCEPT_EXPR(Expression) noexcept((Expression)) -#endif -// -// Helper macro BOOST_FALLTHROUGH -// Fallback definition of BOOST_FALLTHROUGH macro used to mark intended -// fall-through between case labels in a switch statement. We use a definition -// that requires a semicolon after it to avoid at least one type of misuse even -// on unsupported compilers. -// -#ifndef BOOST_FALLTHROUGH -# define BOOST_FALLTHROUGH ((void)0) -#endif - -// -// constexpr workarounds -// -#if defined(BOOST_NO_CXX11_CONSTEXPR) -#define BOOST_CONSTEXPR -#define BOOST_CONSTEXPR_OR_CONST const -#else -#define BOOST_CONSTEXPR constexpr -#define BOOST_CONSTEXPR_OR_CONST constexpr -#endif - -#define BOOST_STATIC_CONSTEXPR static BOOST_CONSTEXPR_OR_CONST - -// -// Set BOOST_HAS_STATIC_ASSERT when BOOST_NO_CXX11_STATIC_ASSERT is not defined -// -#if !defined(BOOST_NO_CXX11_STATIC_ASSERT) && !defined(BOOST_HAS_STATIC_ASSERT) -# define BOOST_HAS_STATIC_ASSERT -#endif - -// -// Set BOOST_HAS_RVALUE_REFS when BOOST_NO_CXX11_RVALUE_REFERENCES is not defined -// -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_HAS_RVALUE_REFS) -#define BOOST_HAS_RVALUE_REFS -#endif - -// -// Set BOOST_HAS_VARIADIC_TMPL when BOOST_NO_CXX11_VARIADIC_TEMPLATES is not defined -// -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_HAS_VARIADIC_TMPL) -#define BOOST_HAS_VARIADIC_TMPL -#endif - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/user.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/user.hpp deleted file mode 100644 index 5a4a9d47..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/user.hpp +++ /dev/null @@ -1,124 +0,0 @@ -// boost/config/user.hpp ---------------------------------------------------// - -// (C) Copyright John Maddock 2001. -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Do not check in modified versions of this file, -// This file may be customized by the end user, but not by boost. - -// -// Use this file to define a site and compiler specific -// configuration policy: -// - -// define this to locate a compiler config file: -// #define BOOST_COMPILER_CONFIG - -// define this to locate a stdlib config file: -// #define BOOST_STDLIB_CONFIG - -// define this to locate a platform config file: -// #define BOOST_PLATFORM_CONFIG - -// define this to disable compiler config, -// use if your compiler config has nothing to set: -// #define BOOST_NO_COMPILER_CONFIG - -// define this to disable stdlib config, -// use if your stdlib config has nothing to set: -// #define BOOST_NO_STDLIB_CONFIG - -// define this to disable platform config, -// use if your platform config has nothing to set: -// #define BOOST_NO_PLATFORM_CONFIG - -// define this to disable all config options, -// excluding the user config. Use if your -// setup is fully ISO compliant, and has no -// useful extensions, or for autoconf generated -// setups: -// #define BOOST_NO_CONFIG - -// define this to make the config "optimistic" -// about unknown compiler versions. Normally -// unknown compiler versions are assumed to have -// all the defects of the last known version, however -// setting this flag, causes the config to assume -// that unknown compiler versions are fully conformant -// with the standard: -// #define BOOST_STRICT_CONFIG - -// define this to cause the config to halt compilation -// with an #error if it encounters anything unknown -- -// either an unknown compiler version or an unknown -// compiler/platform/library: -// #define BOOST_ASSERT_CONFIG - - -// define if you want to disable threading support, even -// when available: -// #define BOOST_DISABLE_THREADS - -// define when you want to disable Win32 specific features -// even when available: -// #define BOOST_DISABLE_WIN32 - -// BOOST_DISABLE_ABI_HEADERS: Stops boost headers from including any -// prefix/suffix headers that normally control things like struct -// packing and alignment. -// #define BOOST_DISABLE_ABI_HEADERS - -// BOOST_ABI_PREFIX: A prefix header to include in place of whatever -// boost.config would normally select, any replacement should set up -// struct packing and alignment options as required. -// #define BOOST_ABI_PREFIX my-header-name - -// BOOST_ABI_SUFFIX: A suffix header to include in place of whatever -// boost.config would normally select, any replacement should undo -// the effects of the prefix header. -// #define BOOST_ABI_SUFFIX my-header-name - -// BOOST_ALL_DYN_LINK: Forces all libraries that have separate source, -// to be linked as dll's rather than static libraries on Microsoft Windows -// (this macro is used to turn on __declspec(dllimport) modifiers, so that -// the compiler knows which symbols to look for in a dll rather than in a -// static library). Note that there may be some libraries that can only -// be statically linked (Boost.Test for example) and others which may only -// be dynamically linked (Boost.Threads for example), in these cases this -// macro has no effect. -// #define BOOST_ALL_DYN_LINK - -// BOOST_WHATEVER_DYN_LINK: Forces library "whatever" to be linked as a dll -// rather than a static library on Microsoft Windows: replace the WHATEVER -// part of the macro name with the name of the library that you want to -// dynamically link to, for example use BOOST_DATE_TIME_DYN_LINK or -// BOOST_REGEX_DYN_LINK etc (this macro is used to turn on __declspec(dllimport) -// modifiers, so that the compiler knows which symbols to look for in a dll -// rather than in a static library). -// Note that there may be some libraries that can only be statically linked -// (Boost.Test for example) and others which may only be dynamically linked -// (Boost.Threads for example), in these cases this macro is unsupported. -// #define BOOST_WHATEVER_DYN_LINK - -// BOOST_ALL_NO_LIB: Tells the config system not to automatically select -// which libraries to link against. -// Normally if a compiler supports #pragma lib, then the correct library -// build variant will be automatically selected and linked against, -// simply by the act of including one of that library's headers. -// This macro turns that feature off. -// #define BOOST_ALL_NO_LIB - -// BOOST_WHATEVER_NO_LIB: Tells the config system not to automatically -// select which library to link against for library "whatever", -// replace WHATEVER in the macro name with the name of the library; -// for example BOOST_DATE_TIME_NO_LIB or BOOST_REGEX_NO_LIB. -// Normally if a compiler supports #pragma lib, then the correct library -// build variant will be automatically selected and linked against, simply -// by the act of including one of that library's headers. This macro turns -// that feature off. -// #define BOOST_WHATEVER_NO_LIB - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/config/warning_disable.hpp b/third_party/ycmd/cpp/BoostParts/boost/config/warning_disable.hpp deleted file mode 100644 index fea8e829..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/config/warning_disable.hpp +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright John Maddock 2008 -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// This file exists to turn off some overly-pedantic warning emitted -// by certain compilers. You should include this header only in: -// -// * A test case, before any other headers, or, -// * A library source file before any other headers. -// -// IT SHOULD NOT BE INCLUDED BY ANY BOOST HEADER. -// -// YOU SHOULD NOT INCLUDE IT IF YOU CAN REASONABLY FIX THE WARNING. -// -// The only warnings disabled here are those that are: -// -// * Quite unreasonably pedantic. -// * Generally only emitted by a single compiler. -// * Can't easily be fixed: for example if the vendors own std lib -// code emits these warnings! -// -// Note that THIS HEADER MUST NOT INCLUDE ANY OTHER HEADERS: -// not even std library ones! Doing so may turn the warning -// off too late to be of any use. For example the VC++ C4996 -// warning can be emitted from if that header is included -// before or by this one :-( -// - -#ifndef BOOST_CONFIG_WARNING_DISABLE_HPP -#define BOOST_CONFIG_WARNING_DISABLE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1400) - // Error 'function': was declared deprecated - // http://msdn2.microsoft.com/en-us/library/ttcz0bys(VS.80).aspx - // This error is emitted when you use some perfectly conforming - // std lib functions in a perfectly correct way, and also by - // some of Microsoft's own std lib code ! -# pragma warning(disable:4996) -#endif -#if defined(__INTEL_COMPILER) || defined(__ICL) - // As above: gives warning when a "deprecated" - // std library function is encountered. -# pragma warning(disable:1786) -#endif - -#endif // BOOST_CONFIG_WARNING_DISABLE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/allocator_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/allocator_traits.hpp deleted file mode 100644 index aa8194a4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/allocator_traits.hpp +++ /dev/null @@ -1,405 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Pablo Halpern 2009. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP -#define BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include //numeric_limits<>::max() -#include //placement new -#include //std::allocator - -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -#include -#endif - -///@cond - -namespace boost { -namespace container { -namespace container_detail { - -//workaround needed for C++03 compilers with no construct() -//supporting rvalue references -template -struct is_std_allocator -{ static const bool value = false; }; - -template -struct is_std_allocator< std::allocator > -{ static const bool value = true; }; - -} //namespace container_detail { - -///@endcond - -//! The class template allocator_traits supplies a uniform interface to all allocator types. -//! This class is a C++03-compatible implementation of std::allocator_traits -template -struct allocator_traits -{ - //allocator_type - typedef Alloc allocator_type; - //value_type - typedef typename Alloc::value_type value_type; - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! Alloc::pointer if such a type exists; otherwise, value_type* - //! - typedef unspecified pointer; - //! Alloc::const_pointer if such a type exists ; otherwise, pointer_traits::rebind::rebind. - //! - typedef see_documentation void_pointer; - //! Alloc::const_void_pointer if such a type exists ; otherwis e, pointer_traits::rebind::difference_type. - //! - typedef see_documentation difference_type; - //! Alloc::size_type if such a type exists ; otherwise, make_unsigned::type - //! - typedef see_documentation size_type; - //! Alloc::propagate_on_container_copy_assignment if such a type exists, otherwise an integral_constant - //! type with internal constant static member `value` == false. - typedef see_documentation propagate_on_container_copy_assignment; - //! Alloc::propagate_on_container_move_assignment if such a type exists, otherwise an integral_constant - //! type with internal constant static member `value` == false. - typedef see_documentation propagate_on_container_move_assignment; - //! Alloc::propagate_on_container_swap if such a type exists, otherwise an integral_constant - //! type with internal constant static member `value` == false. - typedef see_documentation propagate_on_container_swap; - //! Defines an allocator: Alloc::rebind::other if such a type exists; otherwise, Alloc - //! if Alloc is a class template instantiation of the form Alloc, where Args is zero or - //! more type arguments ; otherwise, the instantiation of rebind_alloc is ill-formed. - //! - //! In C++03 compilers `rebind_alloc` is a struct derived from an allocator - //! deduced by previously detailed rules. - template using rebind_alloc = see_documentation; - - //! In C++03 compilers `rebind_traits` is a struct derived from - //! `allocator_traits`, where `OtherAlloc` is - //! the allocator deduced by rules explained in `rebind_alloc`. - template using rebind_traits = allocator_traits >; - - //! Non-standard extension: Portable allocator rebind for C++03 and C++11 compilers. - //! `type` is an allocator related to Alloc deduced deduced by rules explained in `rebind_alloc`. - template - struct portable_rebind_alloc - { typedef see_documentation type; }; - #else - //pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - pointer, value_type*) - pointer; - //const_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::container_detail::, Alloc, - const_pointer, typename boost::intrusive::pointer_traits::template - rebind_pointer) - const_pointer; - //reference - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - reference, typename container_detail::unvoid::type&) - reference; - //const_reference - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - const_reference, const typename container_detail::unvoid::type&) - const_reference; - //void_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::container_detail::, Alloc, - void_pointer, typename boost::intrusive::pointer_traits::template - rebind_pointer) - void_pointer; - //const_void_pointer - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(boost::container::container_detail::, Alloc, - const_void_pointer, typename boost::intrusive::pointer_traits::template - rebind_pointer) - const_void_pointer; - //difference_type - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - difference_type, std::ptrdiff_t) - difference_type; - //size_type - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - size_type, std::size_t) - size_type; - //propagate_on_container_copy_assignment - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - propagate_on_container_copy_assignment, boost::false_type) - propagate_on_container_copy_assignment; - //propagate_on_container_move_assignment - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - propagate_on_container_move_assignment, boost::false_type) - propagate_on_container_move_assignment; - //propagate_on_container_swap - typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(boost::container::container_detail::, Alloc, - propagate_on_container_swap, boost::false_type) - propagate_on_container_swap; - - #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - //C++11 - template using rebind_alloc = typename boost::intrusive::detail::type_rebinder::type; - template using rebind_traits = allocator_traits< rebind_alloc >; - #else // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - //Some workaround for C++03 or C++11 compilers with no template aliases - template - struct rebind_alloc : boost::intrusive::detail::type_rebinder::type - { - typedef typename boost::intrusive::detail::type_rebinder::type Base; - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template - rebind_alloc(BOOST_FWD_REF(Args)... args) - : Base(boost::forward(args)...) - {} - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - #define BOOST_PP_LOCAL_MACRO(n) \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - rebind_alloc(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - : Base(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)) \ - {} \ - // - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - }; - - template - struct rebind_traits - : allocator_traits::type> - {}; - #endif // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) - template - struct portable_rebind_alloc - { typedef typename boost::intrusive::detail::type_rebinder::type type; }; - #endif //BOOST_CONTAINER_DOXYGEN_INVOKED - - //! Returns: `a.allocate(n)` - //! - static pointer allocate(Alloc &a, size_type n) - { return a.allocate(n); } - - //! Returns: `a.deallocate(p, n)` - //! - //! Throws: Nothing - static void deallocate(Alloc &a, pointer p, size_type n) - { a.deallocate(p, n); } - - //! Effects: calls `a.allocate(n, p)` if that call is well-formed; - //! otherwise, invokes `a.allocate(n)` - static pointer allocate(Alloc &a, size_type n, const_void_pointer p) - { - const bool value = boost::container::container_detail:: - has_member_function_callable_with_allocate - ::value; - ::boost::integral_constant flag; - return allocator_traits::priv_allocate(flag, a, n, p); - } - - //! Effects: calls `a.destroy(p)` if that call is well-formed; - //! otherwise, invokes `p->~T()`. - template - static void destroy(Alloc &a, T*p) - { - typedef T* destroy_pointer; - const bool value = boost::container::container_detail:: - has_member_function_callable_with_destroy - ::value; - ::boost::integral_constant flag; - allocator_traits::priv_destroy(flag, a, p); - } - - //! Returns: `a.max_size()` if that expression is well-formed; otherwise, - //! `numeric_limits::max()`. - static size_type max_size(const Alloc &a) - { - const bool value = boost::container::container_detail:: - has_member_function_callable_with_max_size - ::value; - ::boost::integral_constant flag; - return allocator_traits::priv_max_size(flag, a); - } - - //! Returns: `a.select_on_container_copy_construction()` if that expression is well-formed; - //! otherwise, a. - static - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - typename container_detail::if_c - < boost::container::container_detail:: - has_member_function_callable_with_select_on_container_copy_construction - ::value - , Alloc - , const Alloc & - >::type - #else - Alloc - #endif - select_on_container_copy_construction(const Alloc &a) - { - const bool value = boost::container::container_detail:: - has_member_function_callable_with_select_on_container_copy_construction - ::value; - ::boost::integral_constant flag; - return allocator_traits::priv_select_on_container_copy_construction(flag, a); - } - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! Effects: calls `a.construct(p, std::forward(args)...)` if that call is well-formed; - //! otherwise, invokes `::new (static_cast(p)) T(std::forward(args)...)` - template - static void construct(Alloc & a, T* p, BOOST_FWD_REF(Args)... args) - { - ::boost::integral_constant::value> flag; - allocator_traits::priv_construct(flag, a, p, ::boost::forward(args)...); - } - #endif - ///@cond - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - private: - static pointer priv_allocate(boost::true_type, Alloc &a, size_type n, const_void_pointer p) - { return a.allocate(n, p); } - - static pointer priv_allocate(boost::false_type, Alloc &a, size_type n, const_void_pointer) - { return allocator_traits::allocate(a, n); } - - template - static void priv_destroy(boost::true_type, Alloc &a, T* p) - { a.destroy(p); } - - template - static void priv_destroy(boost::false_type, Alloc &, T* p) - { p->~T(); (void)p; } - - static size_type priv_max_size(boost::true_type, const Alloc &a) - { return a.max_size(); } - - static size_type priv_max_size(boost::false_type, const Alloc &) - { return (std::numeric_limits::max)(); } - - static Alloc priv_select_on_container_copy_construction(boost::true_type, const Alloc &a) - { return a.select_on_container_copy_construction(); } - - static const Alloc &priv_select_on_container_copy_construction(boost::false_type, const Alloc &a) - { return a; } - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template - static void priv_construct(boost::false_type, Alloc &a, T *p, BOOST_FWD_REF(Args) ...args) - { - const bool value = boost::container::container_detail:: - has_member_function_callable_with_construct - < Alloc, T*, Args... >::value; - ::boost::integral_constant flag; - priv_construct_dispatch2(flag, a, p, ::boost::forward(args)...); - } - - template - static void priv_construct(boost::true_type, Alloc &a, T *p, BOOST_FWD_REF(Args) ...args) - { - priv_construct_dispatch2(boost::false_type(), a, p, ::boost::forward(args)...); - } - - template - static void priv_construct_dispatch2(boost::true_type, Alloc &a, T *p, BOOST_FWD_REF(Args) ...args) - { a.construct( p, ::boost::forward(args)...); } - - template - static void priv_construct_dispatch2(boost::false_type, Alloc &, T *p, BOOST_FWD_REF(Args) ...args) - { ::new((void*)p) T(::boost::forward(args)...); } - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - public: - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - static void construct(Alloc &a, T *p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - ::boost::integral_constant::value> flag; \ - allocator_traits::priv_construct(flag, a, p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ - } \ - // - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - private: - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - static void priv_construct(boost::false_type, Alloc &a, T *p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST,_)) \ - { \ - const bool value = \ - boost::container::container_detail::has_member_function_callable_with_construct \ - < Alloc, T* BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_FWD_TYPE, _) >::value; \ - ::boost::integral_constant flag; \ - priv_construct_dispatch2(flag, a, p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _) ); \ - } \ - \ - template \ - static void priv_construct(boost::true_type, Alloc &a, T *p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST,_)) \ - { \ - priv_construct_dispatch2(boost::false_type(), a, p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _) ); \ - } \ - \ - template \ - static void priv_construct_dispatch2(boost::true_type, Alloc &a, T *p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST,_)) \ - { a.construct( p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _) ); } \ - \ - template \ - static void priv_construct_dispatch2(boost::false_type, Alloc &, T *p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _) ) \ - { ::new((void*)p) T(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); } \ - // - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template - static void priv_construct_dispatch2(boost::false_type, Alloc &, T *p, ::boost::container::default_init_t) - { ::new((void*)p) T; } - #endif //#if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - ///@endcond -}; - -} //namespace container { -} //namespace boost { - -#include - -#endif // ! defined(BOOST_CONTAINER_ALLOCATOR_ALLOCATOR_TRAITS_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/container_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/container_fwd.hpp deleted file mode 100644 index 271cc8b1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/container_fwd.hpp +++ /dev/null @@ -1,182 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_FWD_HPP -#define BOOST_CONTAINER_CONTAINER_FWD_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -////////////////////////////////////////////////////////////////////////////// -// Standard predeclarations -////////////////////////////////////////////////////////////////////////////// - -/// @cond - -namespace boost{ -namespace intrusive{ - //Create namespace to avoid compilation errors -}} - -namespace boost{ namespace container{ namespace container_detail{ - -namespace bi = boost::intrusive; - -}}} - -#include -#include -#include -#include -#include - -/// @endcond - -////////////////////////////////////////////////////////////////////////////// -// Containers -////////////////////////////////////////////////////////////////////////////// - -namespace boost { -namespace container { - -//vector class -template > -class vector; - -//vector class -template > -class stable_vector; - -//vector class -template > -class deque; - -//list class -template > -class list; - -//slist class -template > -class slist; - -//set class -template - ,class Allocator = std::allocator > -class set; - -//multiset class -template - ,class Allocator = std::allocator > -class multiset; - -//map class -template - ,class Allocator = std::allocator > > -class map; - -//multimap class -template - ,class Allocator = std::allocator > > -class multimap; - -//flat_set class -template - ,class Allocator = std::allocator > -class flat_set; - -//flat_multiset class -template - ,class Allocator = std::allocator > -class flat_multiset; - -//flat_map class -template - ,class Allocator = std::allocator > > -class flat_map; - -//flat_multimap class -template - ,class Allocator = std::allocator > > -class flat_multimap; - -//basic_string class -template - ,class Allocator = std::allocator > -class basic_string; - -//! Type used to tag that the input range is -//! guaranteed to be ordered -struct ordered_range_t -{}; - -//! Value used to tag that the input range is -//! guaranteed to be ordered -static const ordered_range_t ordered_range = ordered_range_t(); - -//! Type used to tag that the input range is -//! guaranteed to be ordered and unique -struct ordered_unique_range_t - : public ordered_range_t -{}; - -//! Value used to tag that the input range is -//! guaranteed to be ordered and unique -static const ordered_unique_range_t ordered_unique_range = ordered_unique_range_t(); - -//! Type used to tag that the input range is -//! guaranteed to be ordered and unique -struct default_init_t -{}; - -//! Value used to tag that the input range is -//! guaranteed to be ordered and unique -static const default_init_t default_init = default_init_t(); -/// @cond - -namespace detail_really_deep_namespace { - -//Otherwise, gcc issues a warning of previously defined -//anonymous_instance and unique_instance -struct dummy -{ - dummy() - { - (void)ordered_range; - (void)ordered_unique_range; - (void)default_init; - } -}; - -} //detail_really_deep_namespace { - -/// @endcond - -}} //namespace boost { namespace container { - -#endif //#ifndef BOOST_CONTAINER_CONTAINER_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/algorithms.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/algorithms.hpp deleted file mode 100644 index 7a4a8684..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/algorithms.hpp +++ /dev/null @@ -1,90 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_ALGORITHMS_HPP -#define BOOST_CONTAINER_DETAIL_ALGORITHMS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include - -#include -#include -#include - -#include -#include -#include - - -#include - -namespace boost { -namespace container { - -template -struct is_value_init_construct_iterator -{ - static const bool value = false; -}; - -template -struct is_value_init_construct_iterator > -{ - static const bool value = true; -}; - -template -struct is_emplace_iterator -{ - static const bool value = false; -}; - -template -struct is_emplace_iterator > -{ - static const bool value = true; -}; - -template -inline void construct_in_place(A &a, T* dest, InpIt source) -{ boost::container::allocator_traits::construct(a, dest, *source); } -//#endif - -template -inline void construct_in_place(A &a, T *dest, value_init_construct_iterator) -{ - boost::container::allocator_traits::construct(a, dest); -} - -template -inline void construct_in_place(A &a, T *dest, default_init_construct_iterator) -{ - boost::container::allocator_traits::construct(a, dest, default_init); -} - -template -inline void construct_in_place(A &a, T *dest, emplace_iterator ei) -{ - ei.construct_in_place(a, dest); -} - -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_ALGORITHMS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocation_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocation_type.hpp deleted file mode 100644 index 59ae9226..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocation_type.hpp +++ /dev/null @@ -1,54 +0,0 @@ -/////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -/////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_ALLOCATION_TYPE_HPP -#define BOOST_CONTAINER_ALLOCATION_TYPE_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include - -namespace boost { -namespace container { - -/// @cond -enum allocation_type_v -{ - // constants for allocation commands - allocate_new_v = 0x01, - expand_fwd_v = 0x02, - expand_bwd_v = 0x04, -// expand_both = expand_fwd | expand_bwd, -// expand_or_new = allocate_new | expand_both, - shrink_in_place_v = 0x08, - nothrow_allocation_v = 0x10, - zero_memory_v = 0x20, - try_shrink_in_place_v = 0x40 -}; - -typedef int allocation_type; -/// @endcond -static const allocation_type allocate_new = (allocation_type)allocate_new_v; -static const allocation_type expand_fwd = (allocation_type)expand_fwd_v; -static const allocation_type expand_bwd = (allocation_type)expand_bwd_v; -static const allocation_type shrink_in_place = (allocation_type)shrink_in_place_v; -static const allocation_type try_shrink_in_place= (allocation_type)try_shrink_in_place_v; -static const allocation_type nothrow_allocation = (allocation_type)nothrow_allocation_v; -static const allocation_type zero_memory = (allocation_type)zero_memory_v; - -} //namespace container { -} //namespace boost { - -#include - -#endif //BOOST_CONTAINER_ALLOCATION_TYPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocator_version_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocator_version_traits.hpp deleted file mode 100644 index 6df79da8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/allocator_version_traits.hpp +++ /dev/null @@ -1,167 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_ALLOCATOR_VERSION_TRAITS_HPP -#define BOOST_CONTAINER_DETAIL_ALLOCATOR_VERSION_TRAITS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include -#include //allocator_traits -#include -#include //multiallocation_chain -#include //version_type -#include //allocation_type -#include //integral_constant -#include //pointer_traits -#include //pair -#include //BOOST_TRY - -namespace boost { -namespace container { -namespace container_detail { - -template::value> -struct allocator_version_traits -{ - typedef ::boost::container::container_detail::integral_constant - alloc_version; - - typedef typename Allocator::multiallocation_chain multiallocation_chain; - - typedef typename boost::container::allocator_traits::pointer pointer; - typedef typename boost::container::allocator_traits::size_type size_type; - - //Node allocation interface - static pointer allocate_one(Allocator &a) - { return a.allocate_one(); } - - static void deallocate_one(Allocator &a, const pointer &p) - { a.deallocate_one(p); } - - static void allocate_individual(Allocator &a, size_type n, multiallocation_chain &m) - { return a.allocate_individual(n, m); } - - static void deallocate_individual(Allocator &a, multiallocation_chain &holder) - { a.deallocate_individual(holder); } - - static std::pair - allocation_command(Allocator &a, allocation_type command, - size_type limit_size, size_type preferred_size, - size_type &received_size, const pointer &reuse) - { - return a.allocation_command - (command, limit_size, preferred_size, received_size, reuse); - } -}; - -template -struct allocator_version_traits -{ - typedef ::boost::container::container_detail::integral_constant - alloc_version; - - typedef typename boost::container::allocator_traits::pointer pointer; - typedef typename boost::container::allocator_traits::size_type size_type; - typedef typename boost::container::allocator_traits::value_type value_type; - - typedef typename boost::intrusive::pointer_traits:: - template rebind_pointer::type void_ptr; - typedef container_detail::basic_multiallocation_chain - multialloc_cached_counted; - typedef boost::container::container_detail:: - transform_multiallocation_chain - < multialloc_cached_counted, value_type> multiallocation_chain; - - //Node allocation interface - static pointer allocate_one(Allocator &a) - { return a.allocate(1); } - - static void deallocate_one(Allocator &a, const pointer &p) - { a.deallocate(p, 1); } - - static void deallocate_individual(Allocator &a, multiallocation_chain &holder) - { - size_type n = holder.size(); - typename multiallocation_chain::iterator it = holder.begin(); - while(n--){ - pointer p = boost::intrusive::pointer_traits::pointer_to(*it); - ++it; - a.deallocate(p, 1); - } - } - - struct allocate_individual_rollback - { - allocate_individual_rollback(Allocator &a, multiallocation_chain &chain) - : mr_a(a), mp_chain(&chain) - {} - - ~allocate_individual_rollback() - { - if(mp_chain) - allocator_version_traits::deallocate_individual(mr_a, *mp_chain); - } - - void release() - { - mp_chain = 0; - } - - Allocator &mr_a; - multiallocation_chain * mp_chain; - }; - - static void allocate_individual(Allocator &a, size_type n, multiallocation_chain &m) - { - allocate_individual_rollback rollback(a, m); - while(n--){ - m.push_front(a.allocate(1)); - } - rollback.release(); - } - - static std::pair - allocation_command(Allocator &a, allocation_type command, - size_type, size_type preferred_size, - size_type &received_size, const pointer &) - { - std::pair ret(pointer(), false); - if(!(command & allocate_new)){ - if(!(command & nothrow_allocation)){ - throw_logic_error("version 1 allocator without allocate_new flag"); - } - } - else{ - received_size = preferred_size; - BOOST_TRY{ - ret.first = a.allocate(received_size); - } - BOOST_CATCH(...){ - if(!(command & nothrow_allocation)){ - BOOST_RETHROW - } - } - BOOST_CATCH_END - } - return ret; - } -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif // ! defined(BOOST_CONTAINER_DETAIL_ALLOCATOR_VERSION_TRAITS_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_begin.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_begin.hpp deleted file mode 100644 index 664f0927..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_begin.hpp +++ /dev/null @@ -1,50 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_CONFIG_INCLUDED -#define BOOST_CONTAINER_CONTAINER_DETAIL_CONFIG_INCLUDED -#include - -#endif //BOOST_CONTAINER_CONTAINER_DETAIL_CONFIG_INCLUDED - -#ifdef BOOST_MSVC - #ifndef _CRT_SECURE_NO_DEPRECATE - #define BOOST_CONTAINER_DETAIL_CRT_SECURE_NO_DEPRECATE - #define _CRT_SECURE_NO_DEPRECATE - #endif - #pragma warning (push) - #pragma warning (disable : 4702) // unreachable code - #pragma warning (disable : 4706) // assignment within conditional expression - #pragma warning (disable : 4127) // conditional expression is constant - #pragma warning (disable : 4146) // unary minus operator applied to unsigned type, result still unsigned - #pragma warning (disable : 4284) // odd return type for operator-> - #pragma warning (disable : 4244) // possible loss of data - #pragma warning (disable : 4251) // "identifier" : class "type" needs to have dll-interface to be used by clients of class "type2" - #pragma warning (disable : 4267) // conversion from "X" to "Y", possible loss of data - #pragma warning (disable : 4275) // non DLL-interface classkey "identifier" used as base for DLL-interface classkey "identifier" - #pragma warning (disable : 4355) // "this" : used in base member initializer list - #pragma warning (disable : 4503) // "identifier" : decorated name length exceeded, name was truncated - #pragma warning (disable : 4511) // copy constructor could not be generated - #pragma warning (disable : 4512) // assignment operator could not be generated - #pragma warning (disable : 4514) // unreferenced inline removed - #pragma warning (disable : 4521) // Disable "multiple copy constructors specified" - #pragma warning (disable : 4522) // "class" : multiple assignment operators specified - #pragma warning (disable : 4675) // "method" should be declared "static" and have exactly one parameter - #pragma warning (disable : 4710) // function not inlined - #pragma warning (disable : 4711) // function selected for automatic inline expansion - #pragma warning (disable : 4786) // identifier truncated in debug info - #pragma warning (disable : 4996) // "function": was declared deprecated - #pragma warning (disable : 4197) // top-level volatile in cast is ignored - #pragma warning (disable : 4541) // 'typeid' used on polymorphic type 'boost::exception' - // with /GR-; unpredictable behavior may result - #pragma warning (disable : 4673) // throwing '' the following types will not be considered at the catch site - #pragma warning (disable : 4671) // the copy constructor is inaccessible - #pragma warning (disable : 4584) // X is already a base-class of Y - #pragma warning (disable : 4510) // default constructor could not be generated -#endif //BOOST_MSVC diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_end.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_end.hpp deleted file mode 100644 index 34513718..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/config_end.hpp +++ /dev/null @@ -1,17 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#if defined BOOST_MSVC - #pragma warning (pop) - #ifdef BOOST_CONTAINER_DETAIL_CRT_SECURE_NO_DEPRECATE - #undef BOOST_CONTAINER_DETAIL_CRT_SECURE_NO_DEPRECATE - #undef _CRT_SECURE_NO_DEPRECATE - #endif -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/destroyers.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/destroyers.hpp deleted file mode 100644 index fef8aa04..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/destroyers.hpp +++ /dev/null @@ -1,376 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DESTROYERS_HPP -#define BOOST_CONTAINER_DESTROYERS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include -#include -#include -#include - -namespace boost { -namespace container { -namespace container_detail { - -//!A deleter for scoped_ptr that deallocates the memory -//!allocated for an object using a STL allocator. -template -struct scoped_deallocator -{ - typedef allocator_traits allocator_traits_type; - typedef typename allocator_traits_type::pointer pointer; - typedef container_detail::integral_constant::value> alloc_version; - typedef container_detail::integral_constant allocator_v1; - typedef container_detail::integral_constant allocator_v2; - - private: - void priv_deallocate(allocator_v1) - { m_alloc.deallocate(m_ptr, 1); } - - void priv_deallocate(allocator_v2) - { m_alloc.deallocate_one(m_ptr); } - - BOOST_MOVABLE_BUT_NOT_COPYABLE(scoped_deallocator) - - public: - - pointer m_ptr; - A& m_alloc; - - scoped_deallocator(pointer p, A& a) - : m_ptr(p), m_alloc(a) - {} - - ~scoped_deallocator() - { if (m_ptr)priv_deallocate(alloc_version()); } - - scoped_deallocator(BOOST_RV_REF(scoped_deallocator) o) - : m_ptr(o.m_ptr), m_alloc(o.m_alloc) - { o.release(); } - - pointer get() const - { return m_ptr; } - - void set(const pointer &p) - { m_ptr = p; } - - void release() - { m_ptr = 0; } -}; - -template -struct null_scoped_deallocator -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::size_type size_type; - - null_scoped_deallocator(pointer, Allocator&, size_type) - {} - - void release() - {} - - pointer get() const - { return pointer(); } - - void set(const pointer &) - {} -}; - -//!A deleter for scoped_ptr that deallocates the memory -//!allocated for an array of objects using a STL allocator. -template -struct scoped_array_deallocator -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::size_type size_type; - - scoped_array_deallocator(pointer p, Allocator& a, size_type length) - : m_ptr(p), m_alloc(a), m_length(length) {} - - ~scoped_array_deallocator() - { if (m_ptr) m_alloc.deallocate(m_ptr, m_length); } - - void release() - { m_ptr = 0; } - - private: - pointer m_ptr; - Allocator& m_alloc; - size_type m_length; -}; - -template -struct null_scoped_array_deallocator -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::size_type size_type; - - null_scoped_array_deallocator(pointer, Allocator&, size_type) - {} - - void release() - {} -}; - -template -struct scoped_destroy_deallocator -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::size_type size_type; - typedef container_detail::integral_constant::value> alloc_version; - typedef container_detail::integral_constant allocator_v1; - typedef container_detail::integral_constant allocator_v2; - - scoped_destroy_deallocator(pointer p, Allocator& a) - : m_ptr(p), m_alloc(a) {} - - ~scoped_destroy_deallocator() - { - if(m_ptr){ - AllocTraits::destroy(m_alloc, container_detail::to_raw_pointer(m_ptr)); - priv_deallocate(m_ptr, alloc_version()); - } - } - - void release() - { m_ptr = 0; } - - private: - - void priv_deallocate(const pointer &p, allocator_v1) - { AllocTraits::deallocate(m_alloc, p, 1); } - - void priv_deallocate(const pointer &p, allocator_v2) - { m_alloc.deallocate_one(p); } - - pointer m_ptr; - Allocator& m_alloc; -}; - - -//!A deleter for scoped_ptr that destroys -//!an object using a STL allocator. -template -struct scoped_destructor_n -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::value_type value_type; - typedef typename AllocTraits::size_type size_type; - - scoped_destructor_n(pointer p, Allocator& a, size_type n) - : m_p(p), m_a(a), m_n(n) - {} - - void release() - { m_p = 0; } - - void increment_size(size_type inc) - { m_n += inc; } - - void increment_size_backwards(size_type inc) - { m_n += inc; m_p -= inc; } - - void shrink_forward(size_type inc) - { m_n -= inc; m_p += inc; } - - ~scoped_destructor_n() - { - if(!m_p) return; - value_type *raw_ptr = container_detail::to_raw_pointer(m_p); - while(m_n--){ - AllocTraits::destroy(m_a, raw_ptr); - } - } - - private: - pointer m_p; - Allocator & m_a; - size_type m_n; -}; - -//!A deleter for scoped_ptr that destroys -//!an object using a STL allocator. -template -struct null_scoped_destructor_n -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::pointer pointer; - typedef typename AllocTraits::size_type size_type; - - null_scoped_destructor_n(pointer, Allocator&, size_type) - {} - - void increment_size(size_type) - {} - - void increment_size_backwards(size_type) - {} - - void release() - {} -}; - -template -class scoped_destructor -{ - typedef boost::container::allocator_traits AllocTraits; - public: - typedef typename A::value_type value_type; - scoped_destructor(A &a, value_type *pv) - : pv_(pv), a_(a) - {} - - ~scoped_destructor() - { - if(pv_){ - AllocTraits::destroy(a_, pv_); - } - } - - void release() - { pv_ = 0; } - - - void set(value_type *ptr) { pv_ = ptr; } - - value_type *get() const { return pv_; } - - private: - value_type *pv_; - A &a_; -}; - - -template -class value_destructor -{ - typedef boost::container::allocator_traits AllocTraits; - public: - typedef typename A::value_type value_type; - value_destructor(A &a, value_type &rv) - : rv_(rv), a_(a) - {} - - ~value_destructor() - { - AllocTraits::destroy(a_, &rv_); - } - - private: - value_type &rv_; - A &a_; -}; - -template -class allocator_destroyer -{ - typedef boost::container::allocator_traits AllocTraits; - typedef typename AllocTraits::value_type value_type; - typedef typename AllocTraits::pointer pointer; - typedef container_detail::integral_constant::value> alloc_version; - typedef container_detail::integral_constant allocator_v1; - typedef container_detail::integral_constant allocator_v2; - - private: - Allocator & a_; - - private: - void priv_deallocate(const pointer &p, allocator_v1) - { AllocTraits::deallocate(a_,p, 1); } - - void priv_deallocate(const pointer &p, allocator_v2) - { a_.deallocate_one(p); } - - public: - allocator_destroyer(Allocator &a) - : a_(a) - {} - - void operator()(const pointer &p) - { - AllocTraits::destroy(a_, container_detail::to_raw_pointer(p)); - this->priv_deallocate(p, alloc_version()); - } -}; - -template -class allocator_destroyer_and_chain_builder -{ - typedef allocator_traits allocator_traits_type; - typedef typename allocator_traits_type::value_type value_type; - typedef typename A::multiallocation_chain multiallocation_chain; - - A & a_; - multiallocation_chain &c_; - - public: - allocator_destroyer_and_chain_builder(A &a, multiallocation_chain &c) - : a_(a), c_(c) - {} - - void operator()(const typename A::pointer &p) - { - allocator_traits::destroy(a_, container_detail::to_raw_pointer(p)); - c_.push_back(p); - } -}; - -template -class allocator_multialloc_chain_node_deallocator -{ - typedef allocator_traits allocator_traits_type; - typedef typename allocator_traits_type::value_type value_type; - typedef typename A::multiallocation_chain multiallocation_chain; - typedef allocator_destroyer_and_chain_builder chain_builder; - - A & a_; - multiallocation_chain c_; - - public: - allocator_multialloc_chain_node_deallocator(A &a) - : a_(a), c_() - {} - - chain_builder get_chain_builder() - { return chain_builder(a_, c_); } - - ~allocator_multialloc_chain_node_deallocator() - { - a_.deallocate_individual(c_); - } -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DESTROYERS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/iterators.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/iterators.hpp deleted file mode 100644 index 5766a7c2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/iterators.hpp +++ /dev/null @@ -1,812 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// (C) Copyright Gennaro Prota 2003 - 2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_ITERATORS_HPP -#define BOOST_CONTAINER_DETAIL_ITERATORS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include -#include -#include -#include -#include - -#ifdef BOOST_CONTAINER_PERFECT_FORWARDING -#include -#else -#include -#endif - -#include - -namespace boost { -namespace container { - -template -class constant_iterator - : public std::iterator - -{ - typedef constant_iterator this_type; - - public: - explicit constant_iterator(const T &ref, Difference range_size) - : m_ptr(&ref), m_num(range_size){} - - //Constructors - constant_iterator() - : m_ptr(0), m_num(0){} - - constant_iterator& operator++() - { increment(); return *this; } - - constant_iterator operator++(int) - { - constant_iterator result (*this); - increment(); - return result; - } - - constant_iterator& operator--() - { decrement(); return *this; } - - constant_iterator operator--(int) - { - constant_iterator result (*this); - decrement(); - return result; - } - - friend bool operator== (const constant_iterator& i, const constant_iterator& i2) - { return i.equal(i2); } - - friend bool operator!= (const constant_iterator& i, const constant_iterator& i2) - { return !(i == i2); } - - friend bool operator< (const constant_iterator& i, const constant_iterator& i2) - { return i.less(i2); } - - friend bool operator> (const constant_iterator& i, const constant_iterator& i2) - { return i2 < i; } - - friend bool operator<= (const constant_iterator& i, const constant_iterator& i2) - { return !(i > i2); } - - friend bool operator>= (const constant_iterator& i, const constant_iterator& i2) - { return !(i < i2); } - - friend Difference operator- (const constant_iterator& i, const constant_iterator& i2) - { return i2.distance_to(i); } - - //Arithmetic - constant_iterator& operator+=(Difference off) - { this->advance(off); return *this; } - - constant_iterator operator+(Difference off) const - { - constant_iterator other(*this); - other.advance(off); - return other; - } - - friend constant_iterator operator+(Difference off, const constant_iterator& right) - { return right + off; } - - constant_iterator& operator-=(Difference off) - { this->advance(-off); return *this; } - - constant_iterator operator-(Difference off) const - { return *this + (-off); } - - const T& operator*() const - { return dereference(); } - - const T& operator[] (Difference ) const - { return dereference(); } - - const T* operator->() const - { return &(dereference()); } - - private: - const T * m_ptr; - Difference m_num; - - void increment() - { --m_num; } - - void decrement() - { ++m_num; } - - bool equal(const this_type &other) const - { return m_num == other.m_num; } - - bool less(const this_type &other) const - { return other.m_num < m_num; } - - const T & dereference() const - { return *m_ptr; } - - void advance(Difference n) - { m_num -= n; } - - Difference distance_to(const this_type &other)const - { return m_num - other.m_num; } -}; - -template -class value_init_construct_iterator - : public std::iterator - -{ - typedef value_init_construct_iterator this_type; - - public: - explicit value_init_construct_iterator(Difference range_size) - : m_num(range_size){} - - //Constructors - value_init_construct_iterator() - : m_num(0){} - - value_init_construct_iterator& operator++() - { increment(); return *this; } - - value_init_construct_iterator operator++(int) - { - value_init_construct_iterator result (*this); - increment(); - return result; - } - - value_init_construct_iterator& operator--() - { decrement(); return *this; } - - value_init_construct_iterator operator--(int) - { - value_init_construct_iterator result (*this); - decrement(); - return result; - } - - friend bool operator== (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return i.equal(i2); } - - friend bool operator!= (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return !(i == i2); } - - friend bool operator< (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return i.less(i2); } - - friend bool operator> (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return i2 < i; } - - friend bool operator<= (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return !(i > i2); } - - friend bool operator>= (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return !(i < i2); } - - friend Difference operator- (const value_init_construct_iterator& i, const value_init_construct_iterator& i2) - { return i2.distance_to(i); } - - //Arithmetic - value_init_construct_iterator& operator+=(Difference off) - { this->advance(off); return *this; } - - value_init_construct_iterator operator+(Difference off) const - { - value_init_construct_iterator other(*this); - other.advance(off); - return other; - } - - friend value_init_construct_iterator operator+(Difference off, const value_init_construct_iterator& right) - { return right + off; } - - value_init_construct_iterator& operator-=(Difference off) - { this->advance(-off); return *this; } - - value_init_construct_iterator operator-(Difference off) const - { return *this + (-off); } - - //This pseudo-iterator's dereference operations have no sense since value is not - //constructed until ::boost::container::construct_in_place is called. - //So comment them to catch bad uses - //const T& operator*() const; - //const T& operator[](difference_type) const; - //const T* operator->() const; - - private: - Difference m_num; - - void increment() - { --m_num; } - - void decrement() - { ++m_num; } - - bool equal(const this_type &other) const - { return m_num == other.m_num; } - - bool less(const this_type &other) const - { return other.m_num < m_num; } - - const T & dereference() const - { - static T dummy; - return dummy; - } - - void advance(Difference n) - { m_num -= n; } - - Difference distance_to(const this_type &other)const - { return m_num - other.m_num; } -}; - -template -class default_init_construct_iterator - : public std::iterator - -{ - typedef default_init_construct_iterator this_type; - - public: - explicit default_init_construct_iterator(Difference range_size) - : m_num(range_size){} - - //Constructors - default_init_construct_iterator() - : m_num(0){} - - default_init_construct_iterator& operator++() - { increment(); return *this; } - - default_init_construct_iterator operator++(int) - { - default_init_construct_iterator result (*this); - increment(); - return result; - } - - default_init_construct_iterator& operator--() - { decrement(); return *this; } - - default_init_construct_iterator operator--(int) - { - default_init_construct_iterator result (*this); - decrement(); - return result; - } - - friend bool operator== (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return i.equal(i2); } - - friend bool operator!= (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return !(i == i2); } - - friend bool operator< (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return i.less(i2); } - - friend bool operator> (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return i2 < i; } - - friend bool operator<= (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return !(i > i2); } - - friend bool operator>= (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return !(i < i2); } - - friend Difference operator- (const default_init_construct_iterator& i, const default_init_construct_iterator& i2) - { return i2.distance_to(i); } - - //Arithmetic - default_init_construct_iterator& operator+=(Difference off) - { this->advance(off); return *this; } - - default_init_construct_iterator operator+(Difference off) const - { - default_init_construct_iterator other(*this); - other.advance(off); - return other; - } - - friend default_init_construct_iterator operator+(Difference off, const default_init_construct_iterator& right) - { return right + off; } - - default_init_construct_iterator& operator-=(Difference off) - { this->advance(-off); return *this; } - - default_init_construct_iterator operator-(Difference off) const - { return *this + (-off); } - - //This pseudo-iterator's dereference operations have no sense since value is not - //constructed until ::boost::container::construct_in_place is called. - //So comment them to catch bad uses - //const T& operator*() const; - //const T& operator[](difference_type) const; - //const T* operator->() const; - - private: - Difference m_num; - - void increment() - { --m_num; } - - void decrement() - { ++m_num; } - - bool equal(const this_type &other) const - { return m_num == other.m_num; } - - bool less(const this_type &other) const - { return other.m_num < m_num; } - - const T & dereference() const - { - static T dummy; - return dummy; - } - - void advance(Difference n) - { m_num -= n; } - - Difference distance_to(const this_type &other)const - { return m_num - other.m_num; } -}; - - -template -class repeat_iterator - : public std::iterator - -{ - typedef repeat_iterator this_type; - public: - explicit repeat_iterator(T &ref, Difference range_size) - : m_ptr(&ref), m_num(range_size){} - - //Constructors - repeat_iterator() - : m_ptr(0), m_num(0){} - - this_type& operator++() - { increment(); return *this; } - - this_type operator++(int) - { - this_type result (*this); - increment(); - return result; - } - - this_type& operator--() - { increment(); return *this; } - - this_type operator--(int) - { - this_type result (*this); - increment(); - return result; - } - - friend bool operator== (const this_type& i, const this_type& i2) - { return i.equal(i2); } - - friend bool operator!= (const this_type& i, const this_type& i2) - { return !(i == i2); } - - friend bool operator< (const this_type& i, const this_type& i2) - { return i.less(i2); } - - friend bool operator> (const this_type& i, const this_type& i2) - { return i2 < i; } - - friend bool operator<= (const this_type& i, const this_type& i2) - { return !(i > i2); } - - friend bool operator>= (const this_type& i, const this_type& i2) - { return !(i < i2); } - - friend Difference operator- (const this_type& i, const this_type& i2) - { return i2.distance_to(i); } - - //Arithmetic - this_type& operator+=(Difference off) - { this->advance(off); return *this; } - - this_type operator+(Difference off) const - { - this_type other(*this); - other.advance(off); - return other; - } - - friend this_type operator+(Difference off, const this_type& right) - { return right + off; } - - this_type& operator-=(Difference off) - { this->advance(-off); return *this; } - - this_type operator-(Difference off) const - { return *this + (-off); } - - T& operator*() const - { return dereference(); } - - T& operator[] (Difference ) const - { return dereference(); } - - T *operator->() const - { return &(dereference()); } - - private: - T * m_ptr; - Difference m_num; - - void increment() - { --m_num; } - - void decrement() - { ++m_num; } - - bool equal(const this_type &other) const - { return m_num == other.m_num; } - - bool less(const this_type &other) const - { return other.m_num < m_num; } - - T & dereference() const - { return *m_ptr; } - - void advance(Difference n) - { m_num -= n; } - - Difference distance_to(const this_type &other)const - { return m_num - other.m_num; } -}; - -template -class emplace_iterator - : public std::iterator - -{ - typedef emplace_iterator this_type; - - public: - typedef Difference difference_type; - explicit emplace_iterator(EmplaceFunctor&e) - : m_num(1), m_pe(&e){} - - emplace_iterator() - : m_num(0), m_pe(0){} - - this_type& operator++() - { increment(); return *this; } - - this_type operator++(int) - { - this_type result (*this); - increment(); - return result; - } - - this_type& operator--() - { decrement(); return *this; } - - this_type operator--(int) - { - this_type result (*this); - decrement(); - return result; - } - - friend bool operator== (const this_type& i, const this_type& i2) - { return i.equal(i2); } - - friend bool operator!= (const this_type& i, const this_type& i2) - { return !(i == i2); } - - friend bool operator< (const this_type& i, const this_type& i2) - { return i.less(i2); } - - friend bool operator> (const this_type& i, const this_type& i2) - { return i2 < i; } - - friend bool operator<= (const this_type& i, const this_type& i2) - { return !(i > i2); } - - friend bool operator>= (const this_type& i, const this_type& i2) - { return !(i < i2); } - - friend difference_type operator- (const this_type& i, const this_type& i2) - { return i2.distance_to(i); } - - //Arithmetic - this_type& operator+=(difference_type off) - { this->advance(off); return *this; } - - this_type operator+(difference_type off) const - { - this_type other(*this); - other.advance(off); - return other; - } - - friend this_type operator+(difference_type off, const this_type& right) - { return right + off; } - - this_type& operator-=(difference_type off) - { this->advance(-off); return *this; } - - this_type operator-(difference_type off) const - { return *this + (-off); } - - //This pseudo-iterator's dereference operations have no sense since value is not - //constructed until ::boost::container::construct_in_place is called. - //So comment them to catch bad uses - //const T& operator*() const; - //const T& operator[](difference_type) const; - //const T* operator->() const; - - template - void construct_in_place(A &a, T* ptr) - { (*m_pe)(a, ptr); } - - private: - difference_type m_num; - EmplaceFunctor * m_pe; - - void increment() - { --m_num; } - - void decrement() - { ++m_num; } - - bool equal(const this_type &other) const - { return m_num == other.m_num; } - - bool less(const this_type &other) const - { return other.m_num < m_num; } - - const T & dereference() const - { - static T dummy; - return dummy; - } - - void advance(difference_type n) - { m_num -= n; } - - difference_type distance_to(const this_type &other)const - { return difference_type(m_num - other.m_num); } -}; - -#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - -template -struct emplace_functor -{ - typedef typename container_detail::build_number_seq::type index_tuple_t; - - emplace_functor(Args&&... args) - : args_(args...) - {} - - template - void operator()(A &a, T *ptr) - { emplace_functor::inplace_impl(a, ptr, index_tuple_t()); } - - template - void inplace_impl(A &a, T* ptr, const container_detail::index_tuple&) - { - allocator_traits::construct - (a, ptr, ::boost::forward(container_detail::get(args_))...); - } - - container_detail::tuple args_; -}; - -#else //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - -#define BOOST_PP_LOCAL_MACRO(n) \ - BOOST_PP_EXPR_IF(n, template <) \ - BOOST_PP_ENUM_PARAMS(n, class P) \ - BOOST_PP_EXPR_IF(n, >) \ - struct BOOST_PP_CAT(BOOST_PP_CAT(emplace_functor, n), arg) \ - { \ - BOOST_PP_CAT(BOOST_PP_CAT(emplace_functor, n), arg) \ - ( BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _) ) \ - BOOST_PP_EXPR_IF(n, :) BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_INIT, _){} \ - \ - template \ - void operator()(A &a, T *ptr) \ - { \ - allocator_traits::construct \ - (a, ptr BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_MEMBER_FORWARD, _) ); \ - } \ - BOOST_PP_REPEAT(n, BOOST_CONTAINER_PP_PARAM_DEFINE, _) \ - }; \ - //! -#define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) -#include BOOST_PP_LOCAL_ITERATE() - -#endif - -namespace container_detail { - -template -struct has_iterator_category -{ - template - static char test(int, typename X::iterator_category*); - - template - static int test(int, ...); - - static const bool value = (1 == sizeof(test(0, 0))); -}; - - -template::value > -struct is_input_iterator -{ - static const bool value = is_same::value; -}; - -template -struct is_input_iterator -{ - static const bool value = false; -}; - -template::value > -struct is_forward_iterator -{ - static const bool value = is_same::value; -}; - -template -struct is_forward_iterator -{ - static const bool value = false; -}; - -template::value > -struct is_bidirectional_iterator -{ - static const bool value = is_same::value; -}; - -template -struct is_bidirectional_iterator -{ - static const bool value = false; -}; - -template -struct iiterator_types -{ - typedef typename IIterator::value_type it_value_type; - typedef typename it_value_type::value_type value_type; - typedef typename std::iterator_traits::pointer it_pointer; - typedef typename std::iterator_traits::difference_type difference_type; - typedef typename ::boost::intrusive::pointer_traits:: - template rebind_pointer::type pointer; - typedef typename ::boost::intrusive::pointer_traits:: - template rebind_pointer::type const_pointer; - typedef typename ::boost::intrusive:: - pointer_traits::reference reference; - typedef typename ::boost::intrusive:: - pointer_traits::reference const_reference; - typedef typename IIterator::iterator_category iterator_category; -}; - -template -struct std_iterator -{ - typedef typename std::iterator - < typename iiterator_types::iterator_category - , typename iiterator_types::value_type - , typename iiterator_types::difference_type - , typename iiterator_types::const_pointer - , typename iiterator_types::const_reference> type; -}; - -template -struct std_iterator -{ - typedef typename std::iterator - < typename iiterator_types::iterator_category - , typename iiterator_types::value_type - , typename iiterator_types::difference_type - , typename iiterator_types::pointer - , typename iiterator_types::reference> type; -}; - -template -class iterator - : public std_iterator::type -{ - typedef typename std_iterator::type types_t; - - public: - typedef typename types_t::value_type value_type; - typedef typename types_t::pointer pointer; - typedef typename types_t::reference reference; - - iterator() - {} - - explicit iterator(IIterator iit) BOOST_CONTAINER_NOEXCEPT - : m_iit(iit) - {} - - iterator(iterator const& other) BOOST_CONTAINER_NOEXCEPT - : m_iit(other.get()) - {} - - iterator& operator++() BOOST_CONTAINER_NOEXCEPT - { ++this->m_iit; return *this; } - - iterator operator++(int) BOOST_CONTAINER_NOEXCEPT - { - iterator result (*this); - ++this->m_iit; - return result; - } - - iterator& operator--() BOOST_CONTAINER_NOEXCEPT - { - //If the iterator is not a bidirectional iterator, operator-- should not exist - BOOST_STATIC_ASSERT((is_bidirectional_iterator::value)); - --this->m_iit; return *this; - } - - iterator operator--(int) BOOST_CONTAINER_NOEXCEPT - { - iterator result (*this); - --this->m_iit; - return result; - } - - friend bool operator== (const iterator& l, const iterator& r) BOOST_CONTAINER_NOEXCEPT - { return l.m_iit == r.m_iit; } - - friend bool operator!= (const iterator& l, const iterator& r) BOOST_CONTAINER_NOEXCEPT - { return !(l == r); } - - reference operator*() const BOOST_CONTAINER_NOEXCEPT - { return (*this->m_iit).get_data(); } - - pointer operator->() const BOOST_CONTAINER_NOEXCEPT - { return ::boost::intrusive::pointer_traits::pointer_to(this->operator*()); } - - const IIterator &get() const BOOST_CONTAINER_NOEXCEPT - { return this->m_iit; } - - private: - IIterator m_iit; -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_ITERATORS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/memory_util.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/memory_util.hpp deleted file mode 100644 index ed899548..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/memory_util.hpp +++ /dev/null @@ -1,83 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_ALLOCATOR_MEMORY_UTIL_HPP -#define BOOST_CONTAINER_ALLOCATOR_MEMORY_UTIL_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include -#include -#include - - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME allocate -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 2, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME destroy -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 3, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME max_size -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 0, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME select_on_container_copy_construction -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 0, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME construct -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS+1, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME swap -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace container { namespace container_detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 1, )) -#include BOOST_PP_ITERATE() - -namespace boost { -namespace container { -namespace container_detail { - - -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(const_pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(reference) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(const_reference) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(void_pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(const_void_pointer) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(size_type) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_copy_assignment) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_move_assignment) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(propagate_on_container_swap) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(difference_type) - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif // ! defined(BOOST_CONTAINER_ALLOCATOR_MEMORY_UTIL_HPP) diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/mpl.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/mpl.hpp deleted file mode 100644 index 08f3eae5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/mpl.hpp +++ /dev/null @@ -1,160 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP -#define BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include - -namespace boost { -namespace container { -namespace container_detail { - -template -struct integral_constant -{ - static const T value = val; - typedef integral_constant type; -}; - -template< bool C_ > -struct bool_ : integral_constant -{ - static const bool value = C_; - operator bool() const { return bool_::value; } -}; - -typedef bool_ true_; -typedef bool_ false_; - -typedef true_ true_type; -typedef false_ false_type; - -typedef char yes_type; -struct no_type -{ - char padding[8]; -}; - -template -struct enable_if_c { - typedef T type; -}; - -template -struct enable_if_c {}; - -template -struct enable_if : public enable_if_c {}; - -template -struct disable_if : public enable_if_c {}; - -template -struct disable_if_c : public enable_if_c {}; - -template -class is_convertible -{ - typedef char true_t; - class false_t { char dummy[2]; }; - static true_t dispatch(U); - static false_t dispatch(...); - static T trigger(); - public: - enum { value = sizeof(dispatch(trigger())) == sizeof(true_t) }; -}; - -template< - bool C - , typename T1 - , typename T2 - > -struct if_c -{ - typedef T1 type; -}; - -template< - typename T1 - , typename T2 - > -struct if_c -{ - typedef T2 type; -}; - -template< - typename T1 - , typename T2 - , typename T3 - > -struct if_ -{ - typedef typename if_c<0 != T1::value, T2, T3>::type type; -}; - - -template -struct select1st -// : public std::unary_function -{ - template - const typename Pair::first_type& operator()(const OtherPair& x) const - { return x.first; } - - const typename Pair::first_type& operator()(const typename Pair::first_type& x) const - { return x; } -}; - -// identity is an extension: it is not part of the standard. -template -struct identity -// : public std::unary_function -{ - typedef T type; - const T& operator()(const T& x) const - { return x; } -}; - -template -struct ls_zeros -{ - static const std::size_t value = (S & std::size_t(1)) ? 0 : (1u + ls_zeros<(S >> 1u)>::value); -}; - -template<> -struct ls_zeros<0> -{ - static const std::size_t value = 0; -}; - -template<> -struct ls_zeros<1> -{ - static const std::size_t value = 0; -}; - -template struct unvoid { typedef T type; }; -template <> struct unvoid { struct type { }; }; -template <> struct unvoid { struct type { }; }; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#endif //#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_MPL_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/multiallocation_chain.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/multiallocation_chain.hpp deleted file mode 100644 index bc9945ac..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/multiallocation_chain.hpp +++ /dev/null @@ -1,286 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_MULTIALLOCATION_CHAIN_HPP -#define BOOST_CONTAINER_DETAIL_MULTIALLOCATION_CHAIN_HPP - -#include "config_begin.hpp" -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace container { -namespace container_detail { - -template -class basic_multiallocation_chain -{ - private: - typedef bi::slist_base_hook - ,bi::link_mode - > node; - - typedef typename boost::intrusive::pointer_traits - ::template rebind_pointer::type char_ptr; - typedef typename boost::intrusive:: - pointer_traits::difference_type difference_type; - - typedef bi::slist< node - , bi::linear - , bi::cache_last - , bi::size_type::type> - > slist_impl_t; - slist_impl_t slist_impl_; - - typedef typename boost::intrusive::pointer_traits - ::template rebind_pointer::type node_ptr; - typedef typename boost::intrusive:: - pointer_traits node_ptr_traits; - - static node & to_node(const VoidPointer &p) - { return *static_cast(static_cast(container_detail::to_raw_pointer(p))); } - - static VoidPointer from_node(node &n) - { return node_ptr_traits::pointer_to(n); } - - static node_ptr to_node_ptr(const VoidPointer &p) - { return node_ptr_traits::static_cast_from(p); } - - BOOST_MOVABLE_BUT_NOT_COPYABLE(basic_multiallocation_chain) - - public: - - typedef VoidPointer void_pointer; - typedef typename slist_impl_t::iterator iterator; - typedef typename slist_impl_t::size_type size_type; - - basic_multiallocation_chain() - : slist_impl_() - {} - - basic_multiallocation_chain(const void_pointer &b, const void_pointer &before_e, size_type n) - : slist_impl_(to_node_ptr(b), to_node_ptr(before_e), n) - {} - - basic_multiallocation_chain(BOOST_RV_REF(basic_multiallocation_chain) other) - : slist_impl_(::boost::move(other.slist_impl_)) - {} - - basic_multiallocation_chain& operator=(BOOST_RV_REF(basic_multiallocation_chain) other) - { - slist_impl_ = ::boost::move(other.slist_impl_); - return *this; - } - - bool empty() const - { return slist_impl_.empty(); } - - size_type size() const - { return slist_impl_.size(); } - - iterator before_begin() - { return slist_impl_.before_begin(); } - - iterator begin() - { return slist_impl_.begin(); } - - iterator end() - { return slist_impl_.end(); } - - iterator last() - { return slist_impl_.last(); } - - void clear() - { slist_impl_.clear(); } - - iterator insert_after(iterator it, void_pointer m) - { return slist_impl_.insert_after(it, to_node(m)); } - - void push_front(const void_pointer &m) - { return slist_impl_.push_front(to_node(m)); } - - void push_back(const void_pointer &m) - { return slist_impl_.push_back(to_node(m)); } - - void_pointer pop_front() - { - node & n = slist_impl_.front(); - void_pointer ret = from_node(n); - slist_impl_.pop_front(); - return ret; - } - - void splice_after(iterator after_this, basic_multiallocation_chain &x, iterator before_b, iterator before_e, size_type n) - { slist_impl_.splice_after(after_this, x.slist_impl_, before_b, before_e, n); } - - void splice_after(iterator after_this, basic_multiallocation_chain &x) - { slist_impl_.splice_after(after_this, x.slist_impl_); } - - void erase_after(iterator before_b, iterator e, size_type n) - { slist_impl_.erase_after(before_b, e, n); } - - void_pointer incorporate_after(iterator after_this, const void_pointer &b, size_type unit_bytes, size_type num_units) - { - typedef typename boost::intrusive::pointer_traits char_pointer_traits; - char_ptr elem = char_pointer_traits::static_cast_from(b); - if(num_units){ - char_ptr prev_elem = elem; - elem += unit_bytes; - for(size_type i = 0; i != num_units-1; ++i, elem += unit_bytes){ - ::new (container_detail::to_raw_pointer(prev_elem)) void_pointer(elem); - prev_elem = elem; - } - slist_impl_.incorporate_after(after_this, to_node_ptr(b), to_node_ptr(prev_elem), num_units); - } - return elem; - } - - void incorporate_after(iterator after_this, void_pointer b, void_pointer before_e, size_type n) - { slist_impl_.incorporate_after(after_this, to_node_ptr(b), to_node_ptr(before_e), n); } - - void swap(basic_multiallocation_chain &x) - { slist_impl_.swap(x.slist_impl_); } - - static iterator iterator_to(const void_pointer &p) - { return slist_impl_t::s_iterator_to(to_node(p)); } - - std::pair extract_data() - { - std::pair ret - (slist_impl_.begin().operator->() - ,slist_impl_.last().operator->()); - slist_impl_.clear(); - return ret; - } -}; - -template -struct cast_functor -{ - typedef typename container_detail::add_reference::type result_type; - template - result_type operator()(U &ptr) const - { return *static_cast(static_cast(&ptr)); } -}; - -template -class transform_multiallocation_chain - : public MultiallocationChain -{ - private: - BOOST_MOVABLE_BUT_NOT_COPYABLE(transform_multiallocation_chain) - //transform_multiallocation_chain(const transform_multiallocation_chain &); - //transform_multiallocation_chain & operator=(const transform_multiallocation_chain &); - - typedef typename MultiallocationChain::void_pointer void_pointer; - typedef typename boost::intrusive::pointer_traits - void_pointer_traits; - typedef typename void_pointer_traits::template - rebind_pointer::type pointer; - typedef typename boost::intrusive::pointer_traits - pointer_traits; - - static pointer cast(const void_pointer &p) - { return pointer_traits::static_cast_from(p); } - - public: - typedef transform_iterator - < typename MultiallocationChain::iterator - , container_detail::cast_functor > iterator; - typedef typename MultiallocationChain::size_type size_type; - - transform_multiallocation_chain() - : MultiallocationChain() - {} - - transform_multiallocation_chain(BOOST_RV_REF(transform_multiallocation_chain) other) - : MultiallocationChain(::boost::move(static_cast(other))) - {} - - transform_multiallocation_chain(BOOST_RV_REF(MultiallocationChain) other) - : MultiallocationChain(::boost::move(static_cast(other))) - {} - - transform_multiallocation_chain& operator=(BOOST_RV_REF(transform_multiallocation_chain) other) - { - return static_cast - (this->MultiallocationChain::operator=(::boost::move(static_cast(other)))); - } -/* - void push_front(const pointer &mem) - { holder_.push_front(mem); } - - void push_back(const pointer &mem) - { return holder_.push_back(mem); } - - void swap(transform_multiallocation_chain &other_chain) - { holder_.swap(other_chain.holder_); } - - void splice_after(iterator after_this, transform_multiallocation_chain &x, iterator before_b, iterator before_e, size_type n) - { holder_.splice_after(after_this.base(), x.holder_, before_b.base(), before_e.base(), n); } - - void incorporate_after(iterator after_this, pointer b, pointer before_e, size_type n) - { holder_.incorporate_after(after_this.base(), b, before_e, n); } -*/ - pointer pop_front() - { return cast(this->MultiallocationChain::pop_front()); } -/* - bool empty() const - { return holder_.empty(); } - - iterator before_begin() - { return iterator(holder_.before_begin()); } -*/ - iterator begin() - { return iterator(this->MultiallocationChain::begin()); } -/* - iterator end() - { return iterator(holder_.end()); } - - iterator last() - { return iterator(holder_.last()); } - - size_type size() const - { return holder_.size(); } - - void clear() - { holder_.clear(); } -*/ - iterator insert_after(iterator it, pointer m) - { return iterator(this->MultiallocationChain::insert_after(it.base(), m)); } - - static iterator iterator_to(const pointer &p) - { return iterator(MultiallocationChain::iterator_to(p)); } - - std::pair extract_data() - { - std::pair data(this->MultiallocationChain::extract_data()); - return std::pair(cast(data.first), cast(data.second)); - } -/* - MultiallocationChain &extract_multiallocation_chain() - { return holder_; }*/ -}; - -}}} - -// namespace container_detail { -// namespace container { -// namespace boost { - -#include - -#endif //BOOST_CONTAINER_DETAIL_MULTIALLOCATION_CHAIN_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/node_alloc_holder.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/node_alloc_holder.hpp deleted file mode 100644 index d94c2e9f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/node_alloc_holder.hpp +++ /dev/null @@ -1,387 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_NODE_ALLOC_HPP_ -#define BOOST_CONTAINER_DETAIL_NODE_ALLOC_HPP_ - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include - -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#ifndef BOOST_CONTAINER_PERFECT_FORWARDING -#include -#endif - -#include -#include - - -namespace boost { -namespace container { -namespace container_detail { - -template -struct node_compare - : private ValueCompare -{ - typedef typename ValueCompare::key_type key_type; - typedef typename ValueCompare::value_type value_type; - typedef typename ValueCompare::key_of_value key_of_value; - - explicit node_compare(const ValueCompare &pred) - : ValueCompare(pred) - {} - - node_compare() - : ValueCompare() - {} - - ValueCompare &value_comp() - { return static_cast(*this); } - - ValueCompare &value_comp() const - { return static_cast(*this); } - - bool operator()(const Node &a, const Node &b) const - { return ValueCompare::operator()(a.get_data(), b.get_data()); } -}; - -template -struct node_alloc_holder -{ - typedef allocator_traits allocator_traits_type; - typedef typename allocator_traits_type::value_type value_type; - typedef typename ICont::value_type Node; - typedef typename allocator_traits_type::template - portable_rebind_alloc::type NodeAlloc; - typedef allocator_traits node_allocator_traits_type; - typedef container_detail::allocator_version_traits node_allocator_version_traits_type; - typedef A ValAlloc; - typedef typename node_allocator_traits_type::pointer NodePtr; - typedef container_detail::scoped_deallocator Deallocator; - typedef typename node_allocator_traits_type::size_type size_type; - typedef typename node_allocator_traits_type::difference_type difference_type; - typedef container_detail::integral_constant allocator_v1; - typedef container_detail::integral_constant allocator_v2; - typedef container_detail::integral_constant::value> alloc_version; - typedef typename ICont::iterator icont_iterator; - typedef typename ICont::const_iterator icont_citerator; - typedef allocator_destroyer Destroyer; - typedef allocator_traits NodeAllocTraits; - typedef allocator_version_traits AllocVersionTraits; - - private: - BOOST_COPYABLE_AND_MOVABLE(node_alloc_holder) - - public: - - //Constructors for sequence containers - node_alloc_holder() - : members_() - {} - - explicit node_alloc_holder(const ValAlloc &a) - : members_(a) - {} - - explicit node_alloc_holder(const node_alloc_holder &x) - : members_(NodeAllocTraits::select_on_container_copy_construction(x.node_alloc())) - {} - - explicit node_alloc_holder(BOOST_RV_REF(node_alloc_holder) x) - : members_(boost::move(x.node_alloc())) - { this->icont().swap(x.icont()); } - - //Constructors for associative containers - explicit node_alloc_holder(const ValAlloc &a, const ValPred &c) - : members_(a, c) - {} - - explicit node_alloc_holder(const node_alloc_holder &x, const ValPred &c) - : members_(NodeAllocTraits::select_on_container_copy_construction(x.node_alloc()), c) - {} - - explicit node_alloc_holder(const ValPred &c) - : members_(c) - {} - - //helpers for move assignments - explicit node_alloc_holder(BOOST_RV_REF(node_alloc_holder) x, const ValPred &c) - : members_(boost::move(x.node_alloc()), c) - { this->icont().swap(x.icont()); } - - void copy_assign_alloc(const node_alloc_holder &x) - { - container_detail::bool_ flag; - container_detail::assign_alloc( static_cast(this->members_) - , static_cast(x.members_), flag); - } - - void move_assign_alloc( node_alloc_holder &x) - { - container_detail::bool_ flag; - container_detail::move_alloc( static_cast(this->members_) - , static_cast(x.members_), flag); - } - - ~node_alloc_holder() - { this->clear(alloc_version()); } - - size_type max_size() const - { return allocator_traits_type::max_size(this->node_alloc()); } - - NodePtr allocate_one() - { return AllocVersionTraits::allocate_one(this->node_alloc()); } - - void deallocate_one(const NodePtr &p) - { AllocVersionTraits::deallocate_one(this->node_alloc(), p); } - - #ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - template - NodePtr create_node(Args &&...args) - { - NodePtr p = this->allocate_one(); - Deallocator node_deallocator(p, this->node_alloc()); - allocator_traits::construct - ( this->node_alloc() - , container_detail::addressof(p->m_data), boost::forward(args)...); - node_deallocator.release(); - //This does not throw - typedef typename Node::hook_type hook_type; - ::new(static_cast(container_detail::to_raw_pointer(p))) hook_type; - return (p); - } - - #else //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - #define BOOST_PP_LOCAL_MACRO(n) \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - NodePtr create_node(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - NodePtr p = this->allocate_one(); \ - Deallocator node_deallocator(p, this->node_alloc()); \ - allocator_traits::construct \ - (this->node_alloc(), container_detail::addressof(p->m_data) \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ - node_deallocator.release(); \ - typedef typename Node::hook_type hook_type; \ - ::new(static_cast(container_detail::to_raw_pointer(p))) hook_type; \ - return (p); \ - } \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - template - NodePtr create_node_from_it(const It &it) - { - NodePtr p = this->allocate_one(); - Deallocator node_deallocator(p, this->node_alloc()); - ::boost::container::construct_in_place(this->node_alloc(), container_detail::addressof(p->m_data), it); - node_deallocator.release(); - //This does not throw - typedef typename Node::hook_type hook_type; - ::new(static_cast(container_detail::to_raw_pointer(p))) hook_type; - return (p); - } - - void destroy_node(const NodePtr &nodep) - { - allocator_traits::destroy(this->node_alloc(), container_detail::to_raw_pointer(nodep)); - this->deallocate_one(nodep); - } - - void swap(node_alloc_holder &x) - { - this->icont().swap(x.icont()); - container_detail::bool_ flag; - container_detail::swap_alloc(this->node_alloc(), x.node_alloc(), flag); - } - - template - void allocate_many_and_construct - (FwdIterator beg, difference_type n, Inserter inserter) - { - if(n){ - typedef typename node_allocator_version_traits_type::multiallocation_chain multiallocation_chain; - - //Try to allocate memory in a single block - typedef typename multiallocation_chain::iterator multialloc_iterator; - multiallocation_chain mem; - NodeAlloc &nalloc = this->node_alloc(); - node_allocator_version_traits_type::allocate_individual(nalloc, n, mem); - multialloc_iterator itbeg(mem.begin()), itlast(mem.last()); - mem.clear(); - Node *p = 0; - BOOST_TRY{ - Deallocator node_deallocator(NodePtr(), nalloc); - container_detail::scoped_destructor sdestructor(nalloc, 0); - while(n--){ - p = container_detail::to_raw_pointer(&*itbeg); - node_deallocator.set(p); - ++itbeg; - //This can throw - boost::container::construct_in_place(nalloc, container_detail::addressof(p->m_data), beg); - sdestructor.set(p); - ++beg; - //This does not throw - typedef typename Node::hook_type hook_type; - ::new(static_cast(p)) hook_type; - //This can throw in some containers (predicate might throw). - //(sdestructor will destruct the node and node_deallocator will deallocate it in case of exception) - inserter(*p); - sdestructor.set(0); - } - sdestructor.release(); - node_deallocator.release(); - } - BOOST_CATCH(...){ - mem.incorporate_after(mem.last(), &*itbeg, &*itlast, n); - node_allocator_version_traits_type::deallocate_individual(this->node_alloc(), mem); - BOOST_RETHROW - } - BOOST_CATCH_END - } - } - - void clear(allocator_v1) - { this->icont().clear_and_dispose(Destroyer(this->node_alloc())); } - - void clear(allocator_v2) - { - typename NodeAlloc::multiallocation_chain chain; - allocator_destroyer_and_chain_builder builder(this->node_alloc(), chain); - this->icont().clear_and_dispose(builder); - //BOOST_STATIC_ASSERT((::boost::has_move_emulation_enabled::value == true)); - if(!chain.empty()) - this->node_alloc().deallocate_individual(chain); - } - - icont_iterator erase_range(const icont_iterator &first, const icont_iterator &last, allocator_v1) - { return this->icont().erase_and_dispose(first, last, Destroyer(this->node_alloc())); } - - icont_iterator erase_range(const icont_iterator &first, const icont_iterator &last, allocator_v2) - { - typedef typename NodeAlloc::multiallocation_chain multiallocation_chain; - NodeAlloc & nalloc = this->node_alloc(); - multiallocation_chain chain; - allocator_destroyer_and_chain_builder chain_builder(nalloc, chain); - icont_iterator ret_it = this->icont().erase_and_dispose(first, last, chain_builder); - nalloc.deallocate_individual(chain); - return ret_it; - } - - template - size_type erase_key(const Key& k, const Comparator &comp, allocator_v1) - { return this->icont().erase_and_dispose(k, comp, Destroyer(this->node_alloc())); } - - template - size_type erase_key(const Key& k, const Comparator &comp, allocator_v2) - { - allocator_multialloc_chain_node_deallocator chain_holder(this->node_alloc()); - return this->icont().erase_and_dispose(k, comp, chain_holder.get_chain_builder()); - } - - protected: - struct cloner - { - cloner(node_alloc_holder &holder) - : m_holder(holder) - {} - - NodePtr operator()(const Node &other) const - { return m_holder.create_node(other.get_data()); } - - node_alloc_holder &m_holder; - }; - - struct members_holder - : public NodeAlloc - { - private: - members_holder(const members_holder&); - members_holder & operator=(const members_holder&); - - public: - members_holder() - : NodeAlloc(), m_icont() - {} - - template - explicit members_holder(BOOST_FWD_REF(ConvertibleToAlloc) c2alloc) - : NodeAlloc(boost::forward(c2alloc)) - , m_icont() - {} - - template - members_holder(BOOST_FWD_REF(ConvertibleToAlloc) c2alloc, const ValPred &c) - : NodeAlloc(boost::forward(c2alloc)) - , m_icont(typename ICont::value_compare(c)) - {} - - explicit members_holder(const ValPred &c) - : NodeAlloc() - , m_icont(typename ICont::value_compare(c)) - {} - - //The intrusive container - ICont m_icont; - }; - - ICont &non_const_icont() const - { return const_cast(this->members_.m_icont); } - - ICont &icont() - { return this->members_.m_icont; } - - const ICont &icont() const - { return this->members_.m_icont; } - - NodeAlloc &node_alloc() - { return static_cast(this->members_); } - - const NodeAlloc &node_alloc() const - { return static_cast(this->members_); } - - members_holder members_; -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif // BOOST_CONTAINER_DETAIL_NODE_ALLOC_HPP_ diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/pair.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/pair.hpp deleted file mode 100644 index bfe7978c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/pair.hpp +++ /dev/null @@ -1,354 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_PAIR_HPP -#define BOOST_CONTAINER_CONTAINER_DETAIL_PAIR_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include - -#include -#include -#include -#include - -#include //std::pair -#include //std::swap - -#include -#include - -#ifndef BOOST_CONTAINER_PERFECT_FORWARDING -#include -#endif - -namespace boost { -namespace container { -namespace container_detail { - -template -struct pair; - -template -struct is_pair -{ - static const bool value = false; -}; - -template -struct is_pair< pair > -{ - static const bool value = true; -}; - -template -struct is_pair< std::pair > -{ - static const bool value = true; -}; - -struct pair_nat; - -struct piecewise_construct_t { }; -static const piecewise_construct_t piecewise_construct = piecewise_construct_t(); - -/* -template -struct pair -{ - template pair(pair&& p); - template - pair(piecewise_construct_t, tuple first_args, - tuple second_args); - - template pair& operator=(const pair& p); - pair& operator=(pair&& p) noexcept(is_nothrow_move_assignable::value && - is_nothrow_move_assignable::value); - template pair& operator=(pair&& p); - - void swap(pair& p) noexcept(noexcept(swap(first, p.first)) && - noexcept(swap(second, p.second))); -}; - -template bool operator==(const pair&, const pair&); -template bool operator!=(const pair&, const pair&); -template bool operator< (const pair&, const pair&); -template bool operator> (const pair&, const pair&); -template bool operator>=(const pair&, const pair&); -template bool operator<=(const pair&, const pair&); -*/ - - -template -struct pair -{ - private: - BOOST_COPYABLE_AND_MOVABLE(pair) - - public: - typedef T1 first_type; - typedef T2 second_type; - - T1 first; - T2 second; - - //Default constructor - pair() - : first(), second() - {} - - //pair copy assignment - pair(const pair& x) - : first(x.first), second(x.second) - {} - - //pair move constructor - pair(BOOST_RV_REF(pair) p) - : first(::boost::move(p.first)), second(::boost::move(p.second)) - {} - - template - pair(const pair &p) - : first(p.first), second(p.second) - {} - - template - pair(BOOST_RV_REF_BEG pair BOOST_RV_REF_END p) - : first(::boost::move(p.first)), second(::boost::move(p.second)) - {} - - //pair from two values - pair(const T1 &t1, const T2 &t2) - : first(t1) - , second(t2) - {} - - template - pair(BOOST_FWD_REF(U) u, BOOST_FWD_REF(V) v) - : first(::boost::forward(u)) - , second(::boost::forward(v)) - {} - - //And now compatibility with std::pair - pair(const std::pair& x) - : first(x.first), second(x.second) - {} - - template - pair(const std::pair& p) - : first(p.first), second(p.second) - {} - - pair(BOOST_RV_REF_BEG std::pair BOOST_RV_REF_END p) - : first(::boost::move(p.first)), second(::boost::move(p.second)) - {} - - template - pair(BOOST_RV_REF_BEG std::pair BOOST_RV_REF_END p) - : first(::boost::move(p.first)), second(::boost::move(p.second)) - {} - - //piecewise_construct missing - //template pair(pair&& p); - //template - // pair(piecewise_construct_t, tuple first_args, - // tuple second_args); -/* - //Variadic versions - template - pair(BOOST_CONTAINER_PP_PARAM(U, u), typename container_detail::disable_if - < container_detail::is_pair< typename container_detail::remove_ref_const::type >, pair_nat>::type* = 0) - : first(::boost::forward(u)) - , second() - {} - - #ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - template - pair(U &&u, V &&v) - : first(::boost::forward(u)) - , second(::boost::forward(v), ::boost::forward(args)...) - {} - - #else - - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - pair(BOOST_CONTAINER_PP_PARAM(U, u) \ - ,BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - : first(::boost::forward(u)) \ - , second(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)) \ - {} \ - //! - #define BOOST_PP_LOCAL_LIMITS (1, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - #endif -*/ - //pair copy assignment - pair& operator=(BOOST_COPY_ASSIGN_REF(pair) p) - { - first = p.first; - second = p.second; - return *this; - } - - //pair move assignment - pair& operator=(BOOST_RV_REF(pair) p) - { - first = ::boost::move(p.first); - second = ::boost::move(p.second); - return *this; - } - - template - typename ::boost::container::container_detail::enable_if_c - < !(::boost::container::container_detail::is_same::value && - ::boost::container::container_detail::is_same::value) - , pair &>::type - operator=(const pair&p) - { - first = p.first; - second = p.second; - return *this; - } - - template - typename ::boost::container::container_detail::enable_if_c - < !(::boost::container::container_detail::is_same::value && - ::boost::container::container_detail::is_same::value) - , pair &>::type - operator=(BOOST_RV_REF_BEG pair BOOST_RV_REF_END p) - { - first = ::boost::move(p.first); - second = ::boost::move(p.second); - return *this; - } - - //std::pair copy assignment - pair& operator=(const std::pair &p) - { - first = p.first; - second = p.second; - return *this; - } - - template - pair& operator=(const std::pair &p) - { - first = ::boost::move(p.first); - second = ::boost::move(p.second); - return *this; - } - - //std::pair move assignment - pair& operator=(BOOST_RV_REF_BEG std::pair BOOST_RV_REF_END p) - { - first = ::boost::move(p.first); - second = ::boost::move(p.second); - return *this; - } - - template - pair& operator=(BOOST_RV_REF_BEG std::pair BOOST_RV_REF_END p) - { - first = ::boost::move(p.first); - second = ::boost::move(p.second); - return *this; - } - - //swap - void swap(pair& p) - { - using std::swap; - swap(this->first, p.first); - swap(this->second, p.second); - } -}; - -template -inline bool operator==(const pair& x, const pair& y) -{ return static_cast(x.first == y.first && x.second == y.second); } - -template -inline bool operator< (const pair& x, const pair& y) -{ return static_cast(x.first < y.first || - (!(y.first < x.first) && x.second < y.second)); } - -template -inline bool operator!=(const pair& x, const pair& y) -{ return static_cast(!(x == y)); } - -template -inline bool operator> (const pair& x, const pair& y) -{ return y < x; } - -template -inline bool operator>=(const pair& x, const pair& y) -{ return static_cast(!(x < y)); } - -template -inline bool operator<=(const pair& x, const pair& y) -{ return static_cast(!(y < x)); } - -template -inline pair make_pair(T1 x, T2 y) -{ return pair(x, y); } - -template -inline void swap(pair& x, pair& y) -{ - swap(x.first, y.first); - swap(x.second, y.second); -} - -} //namespace container_detail { -} //namespace container { - - -//Without this specialization recursive flat_(multi)map instantiation fails -//because is_enum needs to instantiate the recursive pair, leading to a compilation error). -//This breaks the cycle clearly stating that pair is not an enum avoiding any instantiation. -template -struct is_enum; - -template -struct is_enum< ::boost::container::container_detail::pair > -{ - static const bool value = false; -}; - -//This specialization is needed to avoid instantiation of pair in -//is_class, and allow recursive maps. -template -struct is_class< ::boost::container::container_detail::pair > - : public ::boost::true_type -{}; - -#ifdef BOOST_NO_CXX11_RVALUE_REFERENCES - -template -struct has_move_emulation_enabled< ::boost::container::container_detail::pair > - : ::boost::true_type -{}; - -#endif - - -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_PAIR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/preprocessor.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/preprocessor.hpp deleted file mode 100644 index 41d1f553..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/preprocessor.hpp +++ /dev/null @@ -1,232 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_PREPROCESSOR_HPP -#define BOOST_CONTAINER_DETAIL_PREPROCESSOR_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include -#include - -#ifdef BOOST_CONTAINER_PERFECT_FORWARDING -//#error "This file is not needed when perfect forwarding is available" -#endif //BOOST_CONTAINER_PERFECT_FORWARDING - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS 10 - -//Note: -//We define template parameters as const references to -//be able to bind temporaries. After that we will un-const them. -//This cast is ugly but it is necessary until "perfect forwarding" -//is achieved in C++0x. Meanwhile, if we want to be able to -//bind rvalues with non-const references, we have to be ugly -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - #define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \ - BOOST_PP_CAT(P, n) && BOOST_PP_CAT(p, n) \ - //! -#else - #define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \ - const BOOST_PP_CAT(P, n) & BOOST_PP_CAT(p, n) \ - //! -#endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - -#define BOOST_CONTAINER_PP_CONST_REF_PARAM_LIST_Q(z, n, Data) \ -const BOOST_PP_CAT(Q, n) & BOOST_PP_CAT(q, n) \ -//! - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - #define BOOST_CONTAINER_PP_PARAM(U, u) \ - U && u \ - //! -#else - #define BOOST_CONTAINER_PP_PARAM(U, u) \ - const U & u \ - //! -#endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - - #define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \ - BOOST_PP_CAT(m_p, n) (::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) )) \ - //! - -#else //BOOST_NO_CXX11_RVALUE_REFERENCES - - #define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \ - BOOST_PP_CAT(m_p, n) (const_cast(BOOST_PP_CAT(p, n))) \ - //! -#endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - - #if defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - - namespace boost { - namespace container { - namespace container_detail { - template - struct ref_holder; - - template - struct ref_holder - { - explicit ref_holder(T &t) - : t_(t) - {} - T &t_; - T & get() { return t_; } - }; - - template - struct ref_holder - { - explicit ref_holder(const T &t) - : t_(t) - {} - const T &t_; - const T & get() { return t_; } - }; - - template - struct ref_holder - { - explicit ref_holder(const T &t) - : t_(t) - {} - const T &t_; - const T & get() { return t_; } - }; - - template - struct ref_holder - { - explicit ref_holder(T &&t) - : t_(t) - {} - T &t_; - T && get() { return ::boost::move(t_); } - }; - - template - struct ref_holder - { - explicit ref_holder(T &&t) - : t_(t) - {} - T &t_; - T && get() { return ::boost::move(t_); } - }; - - } //namespace container_detail { - } //namespace container { - } //namespace boost { - - #define BOOST_CONTAINER_PP_PARAM_DEFINE(z, n, data) \ - ::boost::container::container_detail::ref_holder BOOST_PP_CAT(m_p, n); \ - //! - - #else //BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG - - #define BOOST_CONTAINER_PP_PARAM_DEFINE(z, n, data) \ - BOOST_PP_CAT(P, n) && BOOST_PP_CAT(m_p, n); \ - //! - - #endif //defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - -#else //BOOST_NO_CXX11_RVALUE_REFERENCES - - #define BOOST_CONTAINER_PP_PARAM_DEFINE(z, n, data) \ - BOOST_PP_CAT(P, n) & BOOST_PP_CAT(m_p, n); \ - //! -#endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - - #define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) BOOST_PP_CAT(this->m_p, n).get() \ - //! - -#else //!defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - - #define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) \ - ::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(this->m_p, n) ) \ - //! - -#endif //!defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - -#define BOOST_CONTAINER_PP_PARAM_INC(z, n, data) \ - BOOST_PP_CAT(++this->m_p, n) \ -//! - -#define BOOST_CONTAINER_PP_IDENTITY(z, n, data) data - - -#define BOOST_CONTAINER_PP_PARAM_FORWARD(z, n, data) \ -::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) ) \ -//! - -#define BOOST_CONTAINER_PP_DECLVAL(z, n, data) \ -::boost::move_detail::declval< BOOST_PP_CAT(P, n) >() \ -//! - -#define BOOST_CONTAINER_PP_MEMBER_IT_FORWARD(z, n, data) \ -BOOST_PP_CAT(*this->m_p, n) \ -//! - -#define BOOST_CONTAINER_PP_TEMPLATE_PARAM_VOID_DEFAULT(z, n, data) \ - BOOST_PP_CAT(class P, n) = void \ -//! - -#define BOOST_CONTAINER_PP_TEMPLATE_PARAM_WITH_DEFAULT(z, n, default_type) \ - BOOST_PP_CAT(class P, n) = default_type \ -//! - -#define BOOST_CONTAINER_PP_STATIC_PARAM_REF_DECLARE(z, n, data) \ - static BOOST_PP_CAT(P, n) & BOOST_PP_CAT(p, n); \ -//! - -#define BOOST_CONTAINER_PP_PARAM_PASS(z, n, data) \ - BOOST_PP_CAT(p, n) \ -//! - -#define BOOST_CONTAINER_PP_FWD_TYPE(z, n, data) \ - typename ::boost::move_detail::forward_type< BOOST_PP_CAT(P, n) >::type \ -//! - -#include - -//#else - -//#ifdef BOOST_CONTAINER_PERFECT_FORWARDING -//#error "This file is not needed when perfect forwarding is available" -//#endif //BOOST_CONTAINER_PERFECT_FORWARDING - -#endif //#ifndef BOOST_CONTAINER_DETAIL_PREPROCESSOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/transform_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/transform_iterator.hpp deleted file mode 100644 index c40ecc6b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/transform_iterator.hpp +++ /dev/null @@ -1,176 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// (C) Copyright Gennaro Prota 2003 - 2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_TRANSFORM_ITERATORS_HPP -#define BOOST_CONTAINER_DETAIL_TRANSFORM_ITERATORS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include -#include -#include - -namespace boost { -namespace container { - -template -struct operator_arrow_proxy -{ - operator_arrow_proxy(const PseudoReference &px) - : m_value(px) - {} - - PseudoReference* operator->() const { return &m_value; } - // This function is needed for MWCW and BCC, which won't call operator-> - // again automatically per 13.3.1.2 para 8 -// operator T*() const { return &m_value; } - mutable PseudoReference m_value; -}; - -template -struct operator_arrow_proxy -{ - operator_arrow_proxy(T &px) - : m_value(px) - {} - - T* operator->() const { return const_cast(&m_value); } - // This function is needed for MWCW and BCC, which won't call operator-> - // again automatically per 13.3.1.2 para 8 -// operator T*() const { return &m_value; } - T &m_value; -}; - -template -class transform_iterator - : public UnaryFunction - , public std::iterator - < typename Iterator::iterator_category - , typename container_detail::remove_reference::type - , typename Iterator::difference_type - , operator_arrow_proxy - , typename UnaryFunction::result_type> -{ - public: - explicit transform_iterator(const Iterator &it, const UnaryFunction &f = UnaryFunction()) - : UnaryFunction(f), m_it(it) - {} - - explicit transform_iterator() - : UnaryFunction(), m_it() - {} - - //Constructors - transform_iterator& operator++() - { increment(); return *this; } - - transform_iterator operator++(int) - { - transform_iterator result (*this); - increment(); - return result; - } - - friend bool operator== (const transform_iterator& i, const transform_iterator& i2) - { return i.equal(i2); } - - friend bool operator!= (const transform_iterator& i, const transform_iterator& i2) - { return !(i == i2); } - -/* - friend bool operator> (const transform_iterator& i, const transform_iterator& i2) - { return i2 < i; } - - friend bool operator<= (const transform_iterator& i, const transform_iterator& i2) - { return !(i > i2); } - - friend bool operator>= (const transform_iterator& i, const transform_iterator& i2) - { return !(i < i2); } -*/ - friend typename Iterator::difference_type operator- (const transform_iterator& i, const transform_iterator& i2) - { return i2.distance_to(i); } - - //Arithmetic - transform_iterator& operator+=(typename Iterator::difference_type off) - { this->advance(off); return *this; } - - transform_iterator operator+(typename Iterator::difference_type off) const - { - transform_iterator other(*this); - other.advance(off); - return other; - } - - friend transform_iterator operator+(typename Iterator::difference_type off, const transform_iterator& right) - { return right + off; } - - transform_iterator& operator-=(typename Iterator::difference_type off) - { this->advance(-off); return *this; } - - transform_iterator operator-(typename Iterator::difference_type off) const - { return *this + (-off); } - - typename UnaryFunction::result_type operator*() const - { return dereference(); } - - operator_arrow_proxy - operator->() const - { return operator_arrow_proxy(dereference()); } - - Iterator & base() - { return m_it; } - - const Iterator & base() const - { return m_it; } - - private: - Iterator m_it; - - void increment() - { ++m_it; } - - void decrement() - { --m_it; } - - bool equal(const transform_iterator &other) const - { return m_it == other.m_it; } - - bool less(const transform_iterator &other) const - { return other.m_it < m_it; } - - typename UnaryFunction::result_type dereference() const - { return UnaryFunction::operator()(*m_it); } - - void advance(typename Iterator::difference_type n) - { std::advance(m_it, n); } - - typename Iterator::difference_type distance_to(const transform_iterator &other)const - { return std::distance(other.m_it, m_it); } -}; - -template -transform_iterator -make_transform_iterator(Iterator it, UnaryFunc fun) -{ - return transform_iterator(it, fun); -} - -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_TRANSFORM_ITERATORS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/tree.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/tree.hpp deleted file mode 100644 index 7400a1a8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/tree.hpp +++ /dev/null @@ -1,1085 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_TREE_HPP -#define BOOST_CONTAINER_TREE_HPP - -#include "config_begin.hpp" -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef BOOST_CONTAINER_PERFECT_FORWARDING -#include -#endif - -#include //std::pair -#include -#include - -namespace boost { -namespace container { -namespace container_detail { - -template -struct tree_value_compare - : public KeyCompare -{ - typedef Value value_type; - typedef KeyCompare key_compare; - typedef KeyOfValue key_of_value; - typedef Key key_type; - - explicit tree_value_compare(const key_compare &kcomp) - : KeyCompare(kcomp) - {} - - tree_value_compare() - : KeyCompare() - {} - - const key_compare &key_comp() const - { return static_cast(*this); } - - key_compare &key_comp() - { return static_cast(*this); } - - template - struct is_key - { - static const bool value = is_same::value; - }; - - template - typename enable_if_c::value, const key_type &>::type - key_forward(const T &key) const - { return key; } - - template - typename enable_if_c::value, const key_type &>::type - key_forward(const T &key) const - { return KeyOfValue()(key); } - - template - bool operator()(const KeyType &key1, const KeyType2 &key2) const - { return key_compare::operator()(this->key_forward(key1), this->key_forward(key2)); } -}; - -template -struct rbtree_hook -{ - typedef typename container_detail::bi::make_set_base_hook - < container_detail::bi::void_pointer - , container_detail::bi::link_mode - , container_detail::bi::optimize_size - >::type type; -}; - -//This trait is used to type-pun std::pair because in C++03 -//compilers std::pair is useless for C++11 features -template -struct rbtree_internal_data_type -{ - typedef T type; -}; - -template -struct rbtree_internal_data_type< std::pair > -{ - typedef pair type; -}; - - -//The node to be store in the tree -template -struct rbtree_node - : public rbtree_hook::type -{ - private: - //BOOST_COPYABLE_AND_MOVABLE(rbtree_node) - rbtree_node(); - - public: - typedef typename rbtree_hook::type hook_type; - - typedef T value_type; - typedef typename rbtree_internal_data_type::type internal_type; - - typedef rbtree_node node_type; - - T &get_data() - { - T* ptr = reinterpret_cast(&this->m_data); - return *ptr; - } - - const T &get_data() const - { - const T* ptr = reinterpret_cast(&this->m_data); - return *ptr; - } - - internal_type m_data; - - template - void do_assign(const std::pair &p) - { - const_cast(m_data.first) = p.first; - m_data.second = p.second; - } - - template - void do_assign(const pair &p) - { - const_cast(m_data.first) = p.first; - m_data.second = p.second; - } - - template - void do_assign(const V &v) - { m_data = v; } - - template - void do_move_assign(std::pair &p) - { - const_cast(m_data.first) = ::boost::move(p.first); - m_data.second = ::boost::move(p.second); - } - - template - void do_move_assign(pair &p) - { - const_cast(m_data.first) = ::boost::move(p.first); - m_data.second = ::boost::move(p.second); - } - - template - void do_move_assign(V &v) - { m_data = ::boost::move(v); } -}; - -template -class insert_equal_end_hint_functor -{ - Icont &icont_; - - public: - insert_equal_end_hint_functor(Icont &icont) - : icont_(icont) - {} - - void operator()(Node &n) - { this->icont_.insert_equal(this->icont_.cend(), n); } -}; - -template -class push_back_functor -{ - Icont &icont_; - - public: - push_back_functor(Icont &icont) - : icont_(icont) - {} - - void operator()(Node &n) - { this->icont_.push_back(n); } -}; - -}//namespace container_detail { - -namespace container_detail { - -template -struct intrusive_rbtree_type -{ - typedef typename boost::container:: - allocator_traits::value_type value_type; - typedef typename boost::container:: - allocator_traits::void_pointer void_pointer; - typedef typename boost::container:: - allocator_traits::size_type size_type; - typedef typename container_detail::rbtree_node - node_type; - typedef node_compare node_compare_type; - typedef typename container_detail::bi::make_rbtree - - ,container_detail::bi::base_hook::type> - ,container_detail::bi::constant_time_size - ,container_detail::bi::size_type - >::type container_type; - typedef container_type type ; -}; - -} //namespace container_detail { - -namespace container_detail { - -template -class rbtree - : protected container_detail::node_alloc_holder - < A - , typename container_detail::intrusive_rbtree_type - - >::type - , tree_value_compare - > -{ - typedef tree_value_compare - ValComp; - typedef typename container_detail::intrusive_rbtree_type - < A, ValComp>::type Icont; - typedef container_detail::node_alloc_holder - AllocHolder; - typedef typename AllocHolder::NodePtr NodePtr; - typedef rbtree < Key, Value, KeyOfValue - , KeyCompare, A> ThisType; - typedef typename AllocHolder::NodeAlloc NodeAlloc; - typedef typename AllocHolder::ValAlloc ValAlloc; - typedef typename AllocHolder::Node Node; - typedef typename Icont::iterator iiterator; - typedef typename Icont::const_iterator iconst_iterator; - typedef container_detail::allocator_destroyer Destroyer; - typedef typename AllocHolder::allocator_v1 allocator_v1; - typedef typename AllocHolder::allocator_v2 allocator_v2; - typedef typename AllocHolder::alloc_version alloc_version; - - class RecyclingCloner; - friend class RecyclingCloner; - - class RecyclingCloner - { - public: - RecyclingCloner(AllocHolder &holder, Icont &irbtree) - : m_holder(holder), m_icont(irbtree) - {} - - NodePtr operator()(const Node &other) const - { - if(NodePtr p = m_icont.unlink_leftmost_without_rebalance()){ - //First recycle a node (this can't throw) - BOOST_TRY{ - //This can throw - p->do_assign(other.m_data); - return p; - } - BOOST_CATCH(...){ - //If there is an exception destroy the whole source - m_holder.destroy_node(p); - while((p = m_icont.unlink_leftmost_without_rebalance())){ - m_holder.destroy_node(p); - } - BOOST_RETHROW - } - BOOST_CATCH_END - } - else{ - return m_holder.create_node(other.m_data); - } - } - - AllocHolder &m_holder; - Icont &m_icont; - }; - - class RecyclingMoveCloner; - friend class RecyclingMoveCloner; - - class RecyclingMoveCloner - { - public: - RecyclingMoveCloner(AllocHolder &holder, Icont &irbtree) - : m_holder(holder), m_icont(irbtree) - {} - - NodePtr operator()(const Node &other) const - { - if(NodePtr p = m_icont.unlink_leftmost_without_rebalance()){ - //First recycle a node (this can't throw) - BOOST_TRY{ - //This can throw - p->do_move_assign(const_cast(other).m_data); - return p; - } - BOOST_CATCH(...){ - //If there is an exception destroy the whole source - m_holder.destroy_node(p); - while((p = m_icont.unlink_leftmost_without_rebalance())){ - m_holder.destroy_node(p); - } - BOOST_RETHROW - } - BOOST_CATCH_END - } - else{ - return m_holder.create_node(other.m_data); - } - } - - AllocHolder &m_holder; - Icont &m_icont; - }; - - BOOST_COPYABLE_AND_MOVABLE(rbtree) - - public: - - typedef Key key_type; - typedef Value value_type; - typedef A allocator_type; - typedef KeyCompare key_compare; - typedef ValComp value_compare; - typedef typename boost::container:: - allocator_traits::pointer pointer; - typedef typename boost::container:: - allocator_traits::const_pointer const_pointer; - typedef typename boost::container:: - allocator_traits::reference reference; - typedef typename boost::container:: - allocator_traits::const_reference const_reference; - typedef typename boost::container:: - allocator_traits::size_type size_type; - typedef typename boost::container:: - allocator_traits::difference_type difference_type; - typedef difference_type rbtree_difference_type; - typedef pointer rbtree_pointer; - typedef const_pointer rbtree_const_pointer; - typedef reference rbtree_reference; - typedef const_reference rbtree_const_reference; - typedef NodeAlloc stored_allocator_type; - - private: - - template - struct key_node_compare - : private KeyValueCompare - { - key_node_compare(const KeyValueCompare &comp) - : KeyValueCompare(comp) - {} - - template - struct is_node - { - static const bool value = is_same::value; - }; - - template - typename enable_if_c::value, const value_type &>::type - key_forward(const T &node) const - { return node.get_data(); } - - template - typename enable_if_c::value, const T &>::type - key_forward(const T &key) const - { return key; } - - template - bool operator()(const KeyType &key1, const KeyType2 &key2) const - { return KeyValueCompare::operator()(this->key_forward(key1), this->key_forward(key2)); } - }; - - typedef key_node_compare KeyNodeCompare; - - public: - typedef container_detail::iterator iterator; - typedef container_detail::iterator const_iterator; - typedef std::reverse_iterator reverse_iterator; - typedef std::reverse_iterator const_reverse_iterator; - - rbtree() - : AllocHolder(ValComp(key_compare())) - {} - - explicit rbtree(const key_compare& comp, const allocator_type& a = allocator_type()) - : AllocHolder(a, ValComp(comp)) - {} - - explicit rbtree(const allocator_type& a) - : AllocHolder(a) - {} - - template - rbtree(bool unique_insertion, InputIterator first, InputIterator last, const key_compare& comp, - const allocator_type& a - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename container_detail::enable_if_c - < container_detail::is_input_iterator::value - || container_detail::is_same::value - >::type * = 0 - #endif - ) - : AllocHolder(a, value_compare(comp)) - { - //Use cend() as hint to achieve linear time for - //ordered ranges as required by the standard - //for the constructor - const const_iterator end_it(this->cend()); - if(unique_insertion){ - for ( ; first != last; ++first){ - this->insert_unique(end_it, *first); - } - } - else{ - for ( ; first != last; ++first){ - this->insert_equal(end_it, *first); - } - } - } - - template - rbtree(bool unique_insertion, InputIterator first, InputIterator last, const key_compare& comp, - const allocator_type& a - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename container_detail::enable_if_c - < !(container_detail::is_input_iterator::value - || container_detail::is_same::value) - >::type * = 0 - #endif - ) - : AllocHolder(a, value_compare(comp)) - { - if(unique_insertion){ - //Use cend() as hint to achieve linear time for - //ordered ranges as required by the standard - //for the constructor - const const_iterator end_it(this->cend()); - for ( ; first != last; ++first){ - this->insert_unique(end_it, *first); - } - } - else{ - //Optimized allocation and construction - this->allocate_many_and_construct - ( first, std::distance(first, last) - , insert_equal_end_hint_functor(this->icont())); - } - } - - template - rbtree( ordered_range_t, InputIterator first, InputIterator last - , const key_compare& comp = key_compare(), const allocator_type& a = allocator_type() - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename container_detail::enable_if_c - < container_detail::is_input_iterator::value - || container_detail::is_same::value - >::type * = 0 - #endif - ) - : AllocHolder(a, value_compare(comp)) - { - for ( ; first != last; ++first){ - this->push_back_impl(*first); - } - } - - template - rbtree( ordered_range_t, InputIterator first, InputIterator last - , const key_compare& comp = key_compare(), const allocator_type& a = allocator_type() - #if !defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , typename container_detail::enable_if_c - < !(container_detail::is_input_iterator::value - || container_detail::is_same::value) - >::type * = 0 - #endif - ) - : AllocHolder(a, value_compare(comp)) - { - //Optimized allocation and construction - this->allocate_many_and_construct - ( first, std::distance(first, last) - , container_detail::push_back_functor(this->icont())); - } - - rbtree(const rbtree& x) - : AllocHolder(x, x.value_comp()) - { - this->icont().clone_from - (x.icont(), typename AllocHolder::cloner(*this), Destroyer(this->node_alloc())); - } - - rbtree(BOOST_RV_REF(rbtree) x) - : AllocHolder(::boost::move(static_cast(x)), x.value_comp()) - {} - - rbtree(const rbtree& x, const allocator_type &a) - : AllocHolder(a, x.value_comp()) - { - this->icont().clone_from - (x.icont(), typename AllocHolder::cloner(*this), Destroyer(this->node_alloc())); - } - - rbtree(BOOST_RV_REF(rbtree) x, const allocator_type &a) - : AllocHolder(a, x.value_comp()) - { - if(this->node_alloc() == x.node_alloc()){ - this->icont().swap(x.icont()); - } - else{ - this->icont().clone_from - (x.icont(), typename AllocHolder::cloner(*this), Destroyer(this->node_alloc())); - } - } - - ~rbtree() - {} //AllocHolder clears the tree - - rbtree& operator=(BOOST_COPY_ASSIGN_REF(rbtree) x) - { - if (&x != this){ - NodeAlloc &this_alloc = this->get_stored_allocator(); - const NodeAlloc &x_alloc = x.get_stored_allocator(); - container_detail::bool_:: - propagate_on_container_copy_assignment::value> flag; - if(flag && this_alloc != x_alloc){ - this->clear(); - } - this->AllocHolder::copy_assign_alloc(x); - //Transfer all the nodes to a temporary tree - //If anything goes wrong, all the nodes will be destroyed - //automatically - Icont other_tree(::boost::move(this->icont())); - - //Now recreate the source tree reusing nodes stored by other_tree - this->icont().clone_from - (x.icont() - , RecyclingCloner(*this, other_tree) - , Destroyer(this->node_alloc())); - - //If there are remaining nodes, destroy them - NodePtr p; - while((p = other_tree.unlink_leftmost_without_rebalance())){ - AllocHolder::destroy_node(p); - } - } - return *this; - } - - rbtree& operator=(BOOST_RV_REF(rbtree) x) - { - if (&x != this){ - NodeAlloc &this_alloc = this->get_stored_allocator(); - const NodeAlloc &x_alloc = x.get_stored_allocator(); - //If allocators are equal we can just swap pointers - if(this_alloc == x_alloc){ - //Destroy and swap pointers - this->clear(); - this->icont() = ::boost::move(x.icont()); - //Move allocator if needed - this->AllocHolder::move_assign_alloc(x); - } - //If unequal allocators, then do a one by one move - else{ - //Transfer all the nodes to a temporary tree - //If anything goes wrong, all the nodes will be destroyed - //automatically - Icont other_tree(::boost::move(this->icont())); - - //Now recreate the source tree reusing nodes stored by other_tree - this->icont().clone_from - (x.icont() - , RecyclingMoveCloner(*this, other_tree) - , Destroyer(this->node_alloc())); - - //If there are remaining nodes, destroy them - NodePtr p; - while((p = other_tree.unlink_leftmost_without_rebalance())){ - AllocHolder::destroy_node(p); - } - } - } - return *this; - } - - public: - // accessors: - value_compare value_comp() const - { return this->icont().value_comp().value_comp(); } - - key_compare key_comp() const - { return this->icont().value_comp().value_comp().key_comp(); } - - allocator_type get_allocator() const - { return allocator_type(this->node_alloc()); } - - const stored_allocator_type &get_stored_allocator() const - { return this->node_alloc(); } - - stored_allocator_type &get_stored_allocator() - { return this->node_alloc(); } - - iterator begin() - { return iterator(this->icont().begin()); } - - const_iterator begin() const - { return this->cbegin(); } - - iterator end() - { return iterator(this->icont().end()); } - - const_iterator end() const - { return this->cend(); } - - reverse_iterator rbegin() - { return reverse_iterator(end()); } - - const_reverse_iterator rbegin() const - { return this->crbegin(); } - - reverse_iterator rend() - { return reverse_iterator(begin()); } - - const_reverse_iterator rend() const - { return this->crend(); } - - //! Effects: Returns a const_iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cbegin() const - { return const_iterator(this->non_const_icont().begin()); } - - //! Effects: Returns a const_iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cend() const - { return const_iterator(this->non_const_icont().end()); } - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crbegin() const - { return const_reverse_iterator(cend()); } - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crend() const - { return const_reverse_iterator(cbegin()); } - - bool empty() const - { return !this->size(); } - - size_type size() const - { return this->icont().size(); } - - size_type max_size() const - { return AllocHolder::max_size(); } - - void swap(ThisType& x) - { AllocHolder::swap(x); } - - public: - - typedef typename Icont::insert_commit_data insert_commit_data; - - // insert/erase - std::pair insert_unique_check - (const key_type& key, insert_commit_data &data) - { - std::pair ret = - this->icont().insert_unique_check(key, KeyNodeCompare(value_comp()), data); - return std::pair(iterator(ret.first), ret.second); - } - - std::pair insert_unique_check - (const_iterator hint, const key_type& key, insert_commit_data &data) - { - std::pair ret = - this->icont().insert_unique_check(hint.get(), key, KeyNodeCompare(value_comp()), data); - return std::pair(iterator(ret.first), ret.second); - } - - iterator insert_unique_commit(const value_type& v, insert_commit_data &data) - { - NodePtr tmp = AllocHolder::create_node(v); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_unique_commit(*tmp, data)); - destroy_deallocator.release(); - return ret; - } - - template - iterator insert_unique_commit - (BOOST_FWD_REF(MovableConvertible) mv, insert_commit_data &data) - { - NodePtr tmp = AllocHolder::create_node(boost::forward(mv)); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_unique_commit(*tmp, data)); - destroy_deallocator.release(); - return ret; - } - - std::pair insert_unique(const value_type& v) - { - insert_commit_data data; - std::pair ret = - this->insert_unique_check(KeyOfValue()(v), data); - if(ret.second){ - ret.first = this->insert_unique_commit(v, data); - } - return ret; - } - - template - std::pair insert_unique(BOOST_FWD_REF(MovableConvertible) mv) - { - insert_commit_data data; - std::pair ret = - this->insert_unique_check(KeyOfValue()(mv), data); - if(ret.second){ - ret.first = this->insert_unique_commit(boost::forward(mv), data); - } - return ret; - } - - private: - - template - void push_back_impl(BOOST_FWD_REF(MovableConvertible) mv) - { - NodePtr tmp(AllocHolder::create_node(boost::forward(mv))); - //push_back has no-throw guarantee so avoid any deallocator/destroyer - this->icont().push_back(*tmp); - } - - std::pair emplace_unique_impl(NodePtr p) - { - value_type &v = p->get_data(); - insert_commit_data data; - scoped_destroy_deallocator destroy_deallocator(p, this->node_alloc()); - std::pair ret = - this->insert_unique_check(KeyOfValue()(v), data); - if(!ret.second){ - return ret; - } - //No throw insertion part, release rollback - destroy_deallocator.release(); - return std::pair - ( iterator(iiterator(this->icont().insert_unique_commit(*p, data))) - , true ); - } - - iterator emplace_unique_hint_impl(const_iterator hint, NodePtr p) - { - value_type &v = p->get_data(); - insert_commit_data data; - std::pair ret = - this->insert_unique_check(hint, KeyOfValue()(v), data); - if(!ret.second){ - Destroyer(this->node_alloc())(p); - return ret.first; - } - return iterator(iiterator(this->icont().insert_unique_commit(*p, data))); - } - - public: - - #ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - template - std::pair emplace_unique(Args&&... args) - { return this->emplace_unique_impl(AllocHolder::create_node(boost::forward(args)...)); } - - template - iterator emplace_hint_unique(const_iterator hint, Args&&... args) - { return this->emplace_unique_hint_impl(hint, AllocHolder::create_node(boost::forward(args)...)); } - - template - iterator emplace_equal(Args&&... args) - { - NodePtr tmp(AllocHolder::create_node(boost::forward(args)...)); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(this->icont().end(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - template - iterator emplace_hint_equal(const_iterator hint, Args&&... args) - { - NodePtr tmp(AllocHolder::create_node(boost::forward(args)...)); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(hint.get(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - #else //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - #define BOOST_PP_LOCAL_MACRO(n) \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - std::pair emplace_unique(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - return this->emplace_unique_impl \ - (AllocHolder::create_node(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _))); \ - } \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace_hint_unique(const_iterator hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - return this->emplace_unique_hint_impl \ - (hint, AllocHolder::create_node(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _))); \ - } \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace_equal(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - NodePtr tmp(AllocHolder::create_node(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _))); \ - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); \ - iterator ret(this->icont().insert_equal(this->icont().end(), *tmp)); \ - destroy_deallocator.release(); \ - return ret; \ - } \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace_hint_equal(const_iterator hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - NodePtr tmp(AllocHolder::create_node(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _))); \ - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); \ - iterator ret(this->icont().insert_equal(hint.get(), *tmp)); \ - destroy_deallocator.release(); \ - return ret; \ - } \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - iterator insert_unique(const_iterator hint, const value_type& v) - { - insert_commit_data data; - std::pair ret = - this->insert_unique_check(hint, KeyOfValue()(v), data); - if(!ret.second) - return ret.first; - return this->insert_unique_commit(v, data); - } - - template - iterator insert_unique(const_iterator hint, BOOST_FWD_REF(MovableConvertible) mv) - { - insert_commit_data data; - std::pair ret = - this->insert_unique_check(hint, KeyOfValue()(mv), data); - if(!ret.second) - return ret.first; - return this->insert_unique_commit(boost::forward(mv), data); - } - - template - void insert_unique(InputIterator first, InputIterator last) - { - for( ; first != last; ++first) - this->insert_unique(*first); - } - - iterator insert_equal(const value_type& v) - { - NodePtr tmp(AllocHolder::create_node(v)); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(this->icont().end(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - template - iterator insert_equal(BOOST_FWD_REF(MovableConvertible) mv) - { - NodePtr tmp(AllocHolder::create_node(boost::forward(mv))); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(this->icont().end(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - iterator insert_equal(const_iterator hint, const value_type& v) - { - NodePtr tmp(AllocHolder::create_node(v)); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(hint.get(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - template - iterator insert_equal(const_iterator hint, BOOST_FWD_REF(MovableConvertible) mv) - { - NodePtr tmp(AllocHolder::create_node(boost::forward(mv))); - scoped_destroy_deallocator destroy_deallocator(tmp, this->node_alloc()); - iterator ret(this->icont().insert_equal(hint.get(), *tmp)); - destroy_deallocator.release(); - return ret; - } - - template - void insert_equal(InputIterator first, InputIterator last) - { - for( ; first != last; ++first) - this->insert_equal(*first); - } - - iterator erase(const_iterator position) - { return iterator(this->icont().erase_and_dispose(position.get(), Destroyer(this->node_alloc()))); } - - size_type erase(const key_type& k) - { return AllocHolder::erase_key(k, KeyNodeCompare(value_comp()), alloc_version()); } - - iterator erase(const_iterator first, const_iterator last) - { return iterator(AllocHolder::erase_range(first.get(), last.get(), alloc_version())); } - - void clear() - { AllocHolder::clear(alloc_version()); } - - // set operations: - iterator find(const key_type& k) - { return iterator(this->icont().find(k, KeyNodeCompare(value_comp()))); } - - const_iterator find(const key_type& k) const - { return const_iterator(this->non_const_icont().find(k, KeyNodeCompare(value_comp()))); } - - size_type count(const key_type& k) const - { return size_type(this->icont().count(k, KeyNodeCompare(value_comp()))); } - - iterator lower_bound(const key_type& k) - { return iterator(this->icont().lower_bound(k, KeyNodeCompare(value_comp()))); } - - const_iterator lower_bound(const key_type& k) const - { return const_iterator(this->non_const_icont().lower_bound(k, KeyNodeCompare(value_comp()))); } - - iterator upper_bound(const key_type& k) - { return iterator(this->icont().upper_bound(k, KeyNodeCompare(value_comp()))); } - - const_iterator upper_bound(const key_type& k) const - { return const_iterator(this->non_const_icont().upper_bound(k, KeyNodeCompare(value_comp()))); } - - std::pair equal_range(const key_type& k) - { - std::pair ret = - this->icont().equal_range(k, KeyNodeCompare(value_comp())); - return std::pair(iterator(ret.first), iterator(ret.second)); - } - - std::pair equal_range(const key_type& k) const - { - std::pair ret = - this->non_const_icont().equal_range(k, KeyNodeCompare(value_comp())); - return std::pair - (const_iterator(ret.first), const_iterator(ret.second)); - } -}; - -template -inline bool -operator==(const rbtree& x, - const rbtree& y) -{ - return x.size() == y.size() && - std::equal(x.begin(), x.end(), y.begin()); -} - -template -inline bool -operator<(const rbtree& x, - const rbtree& y) -{ - return std::lexicographical_compare(x.begin(), x.end(), - y.begin(), y.end()); -} - -template -inline bool -operator!=(const rbtree& x, - const rbtree& y) { - return !(x == y); -} - -template -inline bool -operator>(const rbtree& x, - const rbtree& y) { - return y < x; -} - -template -inline bool -operator<=(const rbtree& x, - const rbtree& y) { - return !(y < x); -} - -template -inline bool -operator>=(const rbtree& x, - const rbtree& y) { - return !(x < y); -} - - -template -inline void -swap(rbtree& x, - rbtree& y) -{ - x.swap(y); -} - -} //namespace container_detail { -} //namespace container { -/* -//!has_trivial_destructor_after_move<> == true_type -//!specialization for optimizations -template -struct has_trivial_destructor_after_move - > -{ - static const bool value = has_trivial_destructor_after_move::value && has_trivial_destructor_after_move::value; -}; -*/ -} //namespace boost { - -#include - -#endif //BOOST_CONTAINER_TREE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/type_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/type_traits.hpp deleted file mode 100644 index 8dbd1826..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/type_traits.hpp +++ /dev/null @@ -1,210 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// (C) Copyright John Maddock 2000. -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -// The alignment_of implementation comes from John Maddock's boost::alignment_of code -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_TYPE_TRAITS_HPP -#define BOOST_CONTAINER_CONTAINER_DETAIL_TYPE_TRAITS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" - -#include - -namespace boost { -namespace container { -namespace container_detail { - -struct nat{}; - -template -struct LowPriorityConversion -{ - // Convertible from T with user-defined-conversion rank. - LowPriorityConversion(const U&) { } -}; - -//boost::alignment_of yields to 10K lines of preprocessed code, so we -//need an alternative -template struct alignment_of; - -template -struct alignment_of_hack -{ - char c; - T t; - alignment_of_hack(); -}; - -template -struct alignment_logic -{ - enum{ value = A < S ? A : S }; -}; - -template< typename T > -struct alignment_of -{ - enum{ value = alignment_logic - < sizeof(alignment_of_hack) - sizeof(T) - , sizeof(T)>::value }; -}; - -//This is not standard, but should work with all compilers -union max_align -{ - char char_; - short short_; - int int_; - long long_; - #ifdef BOOST_HAS_LONG_LONG - long long long_long_; - #endif - float float_; - double double_; - long double long_double_; - void * void_ptr_; -}; - -template -struct remove_reference -{ - typedef T type; -}; - -template -struct remove_reference -{ - typedef T type; -}; - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - -template -struct remove_reference -{ - typedef T type; -}; - -#else - -template -struct remove_reference< ::boost::rv > -{ - typedef T type; -}; - -#endif - -template -struct is_reference -{ - enum { value = false }; -}; - -template -struct is_reference -{ - enum { value = true }; -}; - -template -struct is_pointer -{ - enum { value = false }; -}; - -template -struct is_pointer -{ - enum { value = true }; -}; - -template -struct add_reference -{ - typedef T& type; -}; - -template -struct add_reference -{ - typedef T& type; -}; - -template<> -struct add_reference -{ - typedef nat &type; -}; - -template<> -struct add_reference -{ - typedef const nat &type; -}; - -template -struct add_const_reference -{ typedef const T &type; }; - -template -struct add_const_reference -{ typedef T& type; }; - -template -struct is_same -{ - typedef char yes_type; - struct no_type - { - char padding[8]; - }; - - template - static yes_type is_same_tester(V*, V*); - static no_type is_same_tester(...); - - static T *t; - static U *u; - - static const bool value = sizeof(yes_type) == sizeof(is_same_tester(t,u)); -}; - -template -struct remove_const -{ - typedef T type; -}; - -template -struct remove_const< const T> -{ - typedef T type; -}; - -template -struct remove_ref_const -{ - typedef typename remove_const< typename remove_reference::type >::type type; -}; - -} // namespace container_detail -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_CONTAINER_DETAIL_TYPE_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/utilities.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/utilities.hpp deleted file mode 100644 index c42087c2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/utilities.hpp +++ /dev/null @@ -1,1180 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_UTILITIES_HPP -#define BOOST_CONTAINER_DETAIL_UTILITIES_HPP - -#include "config_begin.hpp" -#include "workaround.hpp" -#include -#include //for ::memcpy -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include //std::distance - -namespace boost { -namespace container { - -////////////////////////////////////////////////////////////////////////////// -// -// swap -// -////////////////////////////////////////////////////////////////////////////// - -namespace container_swap { - -template::value > -struct has_member_swap -{ - static const bool value = boost::container::container_detail:: - has_member_function_callable_with_swap::value; -}; - -template -struct has_member_swap -{ - static const bool value = false; -}; - -} //namespace container_swap { - -template inline -typename container_detail::enable_if_c - ::value, void>::type -swap_dispatch(T &left, T &right) //swap using member swap -{ - left.swap(right); // may throw -} - -template inline -typename container_detail::enable_if_c - ::value && boost::has_move_emulation_enabled::value, void>::type - swap_dispatch(T &left, T &right) -{ - T temp(boost::move(left)); // may throw - left = boost::move(right); // may throw - right = boost::move(temp); // may throw -} - -template inline -typename container_detail::enable_if_c - ::value && !boost::has_move_emulation_enabled::value, void>::type - swap_dispatch(T &left, T &right) -{ - using std::swap; - swap(left, right); // may throw -} - -namespace container_detail { - -template -inline T* addressof(T& obj) -{ - return static_cast( - static_cast( - const_cast( - &reinterpret_cast(obj) - ))); -} - -template -const T &max_value(const T &a, const T &b) -{ return a > b ? a : b; } - -template -const T &min_value(const T &a, const T &b) -{ return a < b ? a : b; } - -template -SizeType - get_next_capacity(const SizeType max_size - ,const SizeType capacity - ,const SizeType n) -{ -// if (n > max_size - capacity) -// throw std::length_error("get_next_capacity"); - - const SizeType m3 = max_size/3; - - if (capacity < m3) - return capacity + max_value(3*(capacity+1)/5, n); - - if (capacity < m3*2) - return capacity + max_value((capacity+1)/2, n); - - return max_size; -} - -template -inline T* to_raw_pointer(T* p) -{ return p; } - -template -inline typename Pointer::element_type* - to_raw_pointer(const Pointer &p) -{ return boost::container::container_detail::to_raw_pointer(p.operator->()); } - - -template -inline void swap_alloc(AllocatorType &, AllocatorType &, container_detail::false_type) - BOOST_CONTAINER_NOEXCEPT -{} - -template -inline void swap_alloc(AllocatorType &l, AllocatorType &r, container_detail::true_type) -{ boost::container::swap_dispatch(l, r); } - -template -inline void assign_alloc(AllocatorType &, const AllocatorType &, container_detail::false_type) - BOOST_CONTAINER_NOEXCEPT -{} - -template -inline void assign_alloc(AllocatorType &l, const AllocatorType &r, container_detail::true_type) -{ l = r; } - -template -inline void move_alloc(AllocatorType &, AllocatorType &, container_detail::false_type) - BOOST_CONTAINER_NOEXCEPT -{} - -template -inline void move_alloc(AllocatorType &l, AllocatorType &r, container_detail::true_type) -{ l = ::boost::move(r); } - -//Rounds "orig_size" by excess to round_to bytes -template -inline SizeType get_rounded_size(SizeType orig_size, SizeType round_to) -{ - return ((orig_size-1)/round_to+1)*round_to; -} - -template -struct ct_rounded_size -{ - enum { value = ((OrigSize-1)/RoundTo+1)*RoundTo }; -}; - -template -struct are_elements_contiguous -{ - static const bool value = false; -}; - -///////////////////////// -// raw pointers -///////////////////////// - -template -struct are_elements_contiguous -{ - static const bool value = true; -}; - -///////////////////////// -// predeclarations -///////////////////////// - -#ifndef BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER - -template -class vector_iterator; - -template -class vector_const_iterator; - -#endif //BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER - -} //namespace container_detail { -} //namespace container { - -namespace interprocess { - -template -class offset_ptr; - -} //namespace interprocess { - -namespace container { - -namespace container_detail { - -///////////////////////// -//vector_[const_]iterator -///////////////////////// - -#ifndef BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER - -template -struct are_elements_contiguous > -{ - static const bool value = true; -}; - -template -struct are_elements_contiguous > -{ - static const bool value = true; -}; - -#endif //BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER - -///////////////////////// -// offset_ptr -///////////////////////// - -template -struct are_elements_contiguous< ::boost::interprocess::offset_ptr > -{ - static const bool value = true; -}; - -template -struct are_contiguous_and_same -{ - static const bool is_same_io = - is_same< typename remove_const< typename ::std::iterator_traits::value_type >::type - , typename ::std::iterator_traits::value_type - >::value; - static const bool value = is_same_io && - are_elements_contiguous::value && - are_elements_contiguous::value; -}; - -template -struct is_memcpy_copy_assignable -{ - static const bool value = are_contiguous_and_same::value && - boost::has_trivial_assign< typename ::std::iterator_traits::value_type >::value; -}; - -template -struct is_memcpy_copy_constructible -{ - static const bool value = are_contiguous_and_same::value && - boost::has_trivial_copy< typename ::std::iterator_traits::value_type >::value; -}; - -template -struct enable_if_memcpy_copy_constructible - : public enable_if_c::value, R> -{}; - -template -struct disable_if_memcpy_copy_constructible - : public enable_if_c::value, R> -{}; - -template -struct enable_if_memcpy_copy_assignable - : public enable_if_c::value, R> -{}; - -template -struct disable_if_memcpy_copy_assignable - : public enable_if_c::value, R> -{}; - -template - // F models ForwardIterator -inline F memcpy(I f, I l, F r) BOOST_CONTAINER_NOEXCEPT -{ - typedef typename std::iterator_traits::value_type value_type; - typename std::iterator_traits::difference_type n = std::distance(f, l); - ::memcpy(container_detail::addressof(*r), container_detail::addressof(*f), sizeof(value_type)*n); - std::advance(r, n); - return r; -} - -template - // F models ForwardIterator -F memcpy_n(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ - typedef typename std::iterator_traits::value_type value_type; - ::memcpy(container_detail::addressof(*r), container_detail::addressof(*f), sizeof(value_type)*n); - std::advance(r, n); - return r; -} - -template - // F models ForwardIterator -I memcpy_n_source(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ - typedef typename std::iterator_traits::value_type value_type; - ::memcpy(container_detail::addressof(*r), container_detail::addressof(*f), sizeof(value_type)*n); - std::advance(f, n); - return f; -} - -template - // F models ForwardIterator -I memcpy_n_source_dest(I f, typename std::iterator_traits::difference_type n, F &r) BOOST_CONTAINER_NOEXCEPT -{ - typedef typename std::iterator_traits::value_type value_type; - ::memcpy(container_detail::addressof(*r), container_detail::addressof(*f), sizeof(value_type)*n); - std::advance(f, n); - std::advance(r, n); - return f; -} - - -} //namespace container_detail { - - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_move_alloc -// -////////////////////////////////////////////////////////////////////////////// - - -//! Effects: -//! \code -//! for (; f != l; ++r, ++f) -//! allocator_traits::construct(a, &*r, boost::move(*f)); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_move_alloc(A &a, I f, I l, F r) -{ - F back = r; - BOOST_TRY{ - while (f != l) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), boost::move(*f)); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_move_alloc(A &, I f, I l, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy(f, l, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_move_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r, boost::move(*f)); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_move_alloc_n(A &a, I f, typename std::iterator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), boost::move(*f)); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_move_alloc_n(A &, I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_move_alloc_n_source -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r, boost::move(*f)); -//! \endcode -//! -//! Returns: f (after incremented) -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_move_alloc_n_source(A &a, I f, typename std::iterator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), boost::move(*f)); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_move_alloc_n_source(A &, I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_copy_alloc -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; f != l; ++r, ++f) -//! allocator_traits::construct(a, &*r, *f); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc(A &a, I f, I l, F r) -{ - F back = r; - BOOST_TRY{ - while (f != l) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), *f); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc(A &, I f, I l, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy(f, l, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_copy_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r, *f); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc_n(A &a, I f, typename std::iterator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), *f); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc_n(A &, I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_copy_alloc_n_source -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r, *f); -//! \endcode -//! -//! Returns: f (after incremented) -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc_n_source(A &a, I f, typename std::iterator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), *f); - ++f; ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_constructible::type - uninitialized_copy_alloc_n_source(A &, I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_value_init_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline F uninitialized_value_init_alloc_n(A &a, typename allocator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r)); - ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_default_init_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline F uninitialized_default_init_alloc_n(A &a, typename allocator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), default_init); - ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_fill_alloc -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; f != l; ++r, ++f) -//! allocator_traits::construct(a, &*r, *f); -//! \endcode -//! -//! Returns: r -template - -inline void uninitialized_fill_alloc(A &a, F f, F l, const T &t) -{ - F back = f; - BOOST_TRY{ - while (f != l) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*f), t); - ++f; - } - } - BOOST_CATCH(...){ - for (; back != l; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END -} - - -////////////////////////////////////////////////////////////////////////////// -// -// uninitialized_fill_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -//! Effects: -//! \code -//! for (; n--; ++r, ++f) -//! allocator_traits::construct(a, &*r, v); -//! \endcode -//! -//! Returns: r -template - // F models ForwardIterator -inline F uninitialized_fill_alloc_n(A &a, const T &v, typename allocator_traits::difference_type n, F r) -{ - F back = r; - BOOST_TRY{ - while (n--) { - allocator_traits::construct(a, container_detail::to_raw_pointer(&*r), v); - ++r; - } - } - BOOST_CATCH(...){ - for (; back != r; ++back){ - allocator_traits::destroy(a, container_detail::to_raw_pointer(&*back)); - } - BOOST_RETHROW; - } - BOOST_CATCH_END - return r; -} - -////////////////////////////////////////////////////////////////////////////// -// -// copy -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - copy(I f, I l, F r) -{ - while (f != l) { - *r = *f; - ++f; ++r; - } - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - copy(I f, I l, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy(f, l, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// copy_n -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - copy_n(I f, typename std::iterator_traits::difference_type n, F r) -{ - while (n--) { - *r = *f; - ++f; ++r; - } - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - copy_n(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// copy_n_source -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - copy_n_source(I f, typename std::iterator_traits::difference_type n, F r) -{ - while (n--) { - *r = *f; - ++f; ++r; - } - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - copy_n_source(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// copy_n_source_dest -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - copy_n_source_dest(I f, typename std::iterator_traits::difference_type n, F &r) -{ - while (n--) { - *r = *f; - ++f; ++r; - } - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - copy_n_source_dest(I f, typename std::iterator_traits::difference_type n, F &r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source_dest(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// move -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - move(I f, I l, F r) -{ - while (f != l) { - *r = ::boost::move(*f); - ++f; ++r; - } - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - move(I f, I l, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy(f, l, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// move_n -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - move_n(I f, typename std::iterator_traits::difference_type n, F r) -{ - while (n--) { - *r = ::boost::move(*f); - ++f; ++r; - } - return r; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - move_n(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// move_n_source -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - move_n_source(I f, typename std::iterator_traits::difference_type n, F r) -{ - while (n--) { - *r = ::boost::move(*f); - ++f; ++r; - } - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - move_n_source(I f, typename std::iterator_traits::difference_type n, F r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// move_n_source_dest -// -////////////////////////////////////////////////////////////////////////////// - -template - // F models ForwardIterator -inline typename container_detail::disable_if_memcpy_copy_assignable::type - move_n_source_dest(I f, typename std::iterator_traits::difference_type n, F &r) -{ - while (n--) { - *r = ::boost::move(*f); - ++f; ++r; - } - return f; -} - -template - // F models ForwardIterator -inline typename container_detail::enable_if_memcpy_copy_assignable::type - move_n_source_dest(I f, typename std::iterator_traits::difference_type n, F &r) BOOST_CONTAINER_NOEXCEPT -{ return container_detail::memcpy_n_source_dest(f, n, r); } - -////////////////////////////////////////////////////////////////////////////// -// -// destroy_n -// -////////////////////////////////////////////////////////////////////////////// - -template - // I models InputIterator -inline void destroy_alloc_n(A &a, I f, typename std::iterator_traits::difference_type n - ,typename boost::container::container_detail::enable_if_c - < !boost::has_trivial_destructor::value_type>::value >::type* = 0) -{ - while(n--){ - allocator_traits::destroy(a, container_detail::addressof(*f++)); - } -} - -template - // I models InputIterator -inline void destroy_alloc_n(A &, I, typename std::iterator_traits::difference_type - ,typename boost::container::container_detail::enable_if_c - < boost::has_trivial_destructor::value_type>::value >::type* = 0) -{} - -////////////////////////////////////////////////////////////////////////////// -// -// deep_swap_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -template - -inline typename container_detail::disable_if_memcpy_copy_assignable::type - deep_swap_alloc_n( A &a, F short_range_f, typename allocator_traits::size_type n_i - , G large_range_f, typename allocator_traits::size_type n_j) -{ - typename allocator_traits::size_type n = 0; - for (; n != n_i ; ++short_range_f, ++large_range_f, ++n){ - boost::container::swap_dispatch(*short_range_f, *large_range_f); - } - boost::container::uninitialized_move_alloc_n(a, large_range_f, n_j - n_i, short_range_f); // may throw - boost::container::destroy_alloc_n(a, large_range_f, n_j - n_i); -} - -static const std::size_t DeepSwapAllocNMaxStorage = std::size_t(1) << std::size_t(11); //2K bytes - -template - -inline typename container_detail::enable_if_c - < container_detail::is_memcpy_copy_assignable::value && (MaxTmpBytes <= DeepSwapAllocNMaxStorage) && false - , void>::type - deep_swap_alloc_n( A &a, F short_range_f, typename allocator_traits::size_type n_i - , G large_range_f, typename allocator_traits::size_type n_j) -{ - typedef typename allocator_traits::value_type value_type; - typedef typename boost::aligned_storage - ::value>::type storage_type; - storage_type storage; - - const std::size_t n_i_bytes = sizeof(value_type)*n_i; - unsigned char *const large_ptr = static_cast(static_cast(container_detail::addressof(*large_range_f))); - unsigned char *const short_ptr = static_cast(static_cast(container_detail::addressof(*short_range_f))); - unsigned char *const stora_ptr = static_cast(static_cast(container_detail::addressof(storage))); - ::memcpy(stora_ptr, large_ptr, n_i_bytes); - ::memcpy(large_ptr, short_ptr, n_i_bytes); - ::memcpy(short_ptr, stora_ptr, n_i_bytes); - std::advance(large_range_f, n_i); - std::advance(short_range_f, n_i); - boost::container::uninitialized_move_alloc_n(a, large_range_f, n_j - n_i, short_range_f); // may throw - boost::container::destroy_alloc_n(a, large_range_f, n_j - n_i); -} - -template - -inline typename container_detail::enable_if_c - < container_detail::is_memcpy_copy_assignable::value && true//(MaxTmpBytes > DeepSwapAllocNMaxStorage) - , void>::type - deep_swap_alloc_n( A &a, F short_range_f, typename allocator_traits::size_type n_i - , G large_range_f, typename allocator_traits::size_type n_j) -{ - typedef typename allocator_traits::value_type value_type; - typedef typename boost::aligned_storage - ::value>::type storage_type; - storage_type storage; - const std::size_t sizeof_storage = sizeof(storage); - - std::size_t n_i_bytes = sizeof(value_type)*n_i; - char *large_ptr = static_cast(static_cast(container_detail::addressof(*large_range_f))); - char *short_ptr = static_cast(static_cast(container_detail::addressof(*short_range_f))); - char *stora_ptr = static_cast(static_cast(container_detail::addressof(storage))); - - std::size_t szt_times = n_i_bytes/sizeof_storage; - const std::size_t szt_rem = n_i_bytes%sizeof_storage; - - //Loop unrolling using Duff's device, as it seems it helps on some architectures - const std::size_t Unroll = 4; - std::size_t n = (szt_times + (Unroll-1))/Unroll; - const std::size_t branch_number = ((!szt_times)*Unroll) + (szt_times % Unroll); - switch(branch_number){ - case 4: - break; - case 0: do{ - ::memcpy(stora_ptr, large_ptr, sizeof_storage); - ::memcpy(large_ptr, short_ptr, sizeof_storage); - ::memcpy(short_ptr, stora_ptr, sizeof_storage); - large_ptr += sizeof_storage; - short_ptr += sizeof_storage; - BOOST_CONTAINER_FALLTHOUGH - case 3: - ::memcpy(stora_ptr, large_ptr, sizeof_storage); - ::memcpy(large_ptr, short_ptr, sizeof_storage); - ::memcpy(short_ptr, stora_ptr, sizeof_storage); - large_ptr += sizeof_storage; - short_ptr += sizeof_storage; - BOOST_CONTAINER_FALLTHOUGH - case 2: - ::memcpy(stora_ptr, large_ptr, sizeof_storage); - ::memcpy(large_ptr, short_ptr, sizeof_storage); - ::memcpy(short_ptr, stora_ptr, sizeof_storage); - large_ptr += sizeof_storage; - short_ptr += sizeof_storage; - BOOST_CONTAINER_FALLTHOUGH - case 1: - ::memcpy(stora_ptr, large_ptr, sizeof_storage); - ::memcpy(large_ptr, short_ptr, sizeof_storage); - ::memcpy(short_ptr, stora_ptr, sizeof_storage); - large_ptr += sizeof_storage; - short_ptr += sizeof_storage; - } while(--n); - } - ::memcpy(stora_ptr, large_ptr, szt_rem); - ::memcpy(large_ptr, short_ptr, szt_rem); - ::memcpy(short_ptr, stora_ptr, szt_rem); - std::advance(large_range_f, n_i); - std::advance(short_range_f, n_i); - boost::container::uninitialized_move_alloc_n(a, large_range_f, n_j - n_i, short_range_f); // may throw - boost::container::destroy_alloc_n(a, large_range_f, n_j - n_i); -} - - -////////////////////////////////////////////////////////////////////////////// -// -// copy_assign_range_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -template - -void copy_assign_range_alloc_n( A &a, I inp_start, typename allocator_traits::size_type n_i - , O out_start, typename allocator_traits::size_type n_o ) -{ - if (n_o < n_i){ - inp_start = boost::container::copy_n_source_dest(inp_start, n_o, out_start); // may throw - boost::container::uninitialized_copy_alloc_n(a, inp_start, n_i - n_o, out_start);// may throw - } - else{ - out_start = boost::container::copy_n(inp_start, n_i, out_start); // may throw - boost::container::destroy_alloc_n(a, out_start, n_o - n_i); - } -} - -////////////////////////////////////////////////////////////////////////////// -// -// move_assign_range_alloc_n -// -////////////////////////////////////////////////////////////////////////////// - -template - -void move_assign_range_alloc_n( A &a, I inp_start, typename allocator_traits::size_type n_i - , O out_start, typename allocator_traits::size_type n_o ) -{ - if (n_o < n_i){ - inp_start = boost::container::move_n_source_dest(inp_start, n_o, out_start); // may throw - boost::container::uninitialized_move_alloc_n(a, inp_start, n_i - n_o, out_start); // may throw - } - else{ - out_start = boost::container::move_n(inp_start, n_i, out_start); // may throw - boost::container::destroy_alloc_n(a, out_start, n_o - n_i); - } -} - -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_UTILITIES_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/value_init.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/value_init.hpp deleted file mode 100644 index afe5b15a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/value_init.hpp +++ /dev/null @@ -1,45 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_VALUE_INIT_HPP -#define BOOST_CONTAINER_DETAIL_VALUE_INIT_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include - -namespace boost { -namespace container { -namespace container_detail { - -template -struct value_init -{ - value_init() - : m_t() - {} - - operator T &() { return m_t; } - - T m_t; -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_VALUE_INIT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/variadic_templates_tools.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/variadic_templates_tools.hpp deleted file mode 100644 index cce7fede..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/variadic_templates_tools.hpp +++ /dev/null @@ -1,153 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP -#define BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include "config_begin.hpp" -#include -#include -#include //std::size_t - -namespace boost { -namespace container { -namespace container_detail { - -template -class tuple; - -template<> class tuple<> -{}; - -template -class tuple - : private tuple -{ - typedef tuple inherited; - - public: - tuple() { } - - // implicit copy-constructor is okay - // Construct tuple from separate arguments. - tuple(typename add_const_reference::type v, - typename add_const_reference::type... vtail) - : inherited(vtail...), m_head(v) - {} - - // Construct tuple from another tuple. - template - tuple(const tuple& other) - : m_head(other.head()), inherited(other.tail()) - {} - - template - tuple& operator=(const tuple& other) - { - m_head = other.head(); - tail() = other.tail(); - return this; - } - - typename add_reference::type head() { return m_head; } - typename add_reference::type head() const { return m_head; } - - inherited& tail() { return *this; } - const inherited& tail() const { return *this; } - - protected: - Head m_head; -}; - - -template -tuple tie_forward(Values&&... values) -{ return tuple(values...); } - -template -struct tuple_element; - -template -struct tuple_element > -{ - typedef typename tuple_element >::type type; -}; - -template -struct tuple_element<0, tuple > -{ - typedef Head type; -}; - -template -class get_impl; - -template -class get_impl > -{ - typedef typename tuple_element >::type Element; - typedef get_impl > Next; - - public: - typedef typename add_reference::type type; - typedef typename add_const_reference::type const_type; - static type get(tuple& t) { return Next::get(t.tail()); } - static const_type get(const tuple& t) { return Next::get(t.tail()); } -}; - -template -class get_impl<0, tuple > -{ - public: - typedef typename add_reference::type type; - typedef typename add_const_reference::type const_type; - static type get(tuple& t) { return t.head(); } - static const_type get(const tuple& t){ return t.head(); } -}; - -template -typename get_impl >::type get(tuple& t) -{ return get_impl >::get(t); } - -template -typename get_impl >::const_type get(const tuple& t) -{ return get_impl >::get(t); } - -//////////////////////////////////////////////////// -// Builds an index_tuple<0, 1, 2, ..., Num-1>, that will -// be used to "unpack" into comma-separated values -// in a function call. -//////////////////////////////////////////////////// - -template -struct index_tuple{}; - -template > -struct build_number_seq; - -template -struct build_number_seq > - : build_number_seq > -{}; - -template -struct build_number_seq<0, index_tuple > -{ typedef index_tuple type; }; - - -}}} //namespace boost { namespace container { namespace container_detail { - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/version_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/version_type.hpp deleted file mode 100644 index e47ba26f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/version_type.hpp +++ /dev/null @@ -1,92 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// This code comes from N1953 document by Howard E. Hinnant -// -////////////////////////////////////////////////////////////////////////////// - - -#ifndef BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP -#define BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP - -#include "config_begin.hpp" - -#include -#include - -namespace boost{ -namespace container { -namespace container_detail { - -//using namespace boost; - -template -struct version_type - : public container_detail::integral_constant -{ - typedef T type; - - version_type(const version_type&); -}; - -namespace impl{ - -template , typename T::version>::value> -struct extract_version -{ - static const unsigned value = 1; -}; - -template -struct extract_version -{ - static const unsigned value = T::version::value; -}; - -template -struct has_version -{ - private: - struct two {char _[2];}; - template static two test(...); - template static char test(const typename U::version*); - public: - static const bool value = sizeof(test(0)) == 1; - void dummy(){} -}; - -template ::value> -struct version -{ - static const unsigned value = 1; -}; - -template -struct version -{ - static const unsigned value = extract_version::value; -}; - -} //namespace impl - -template -struct version - : public container_detail::integral_constant::value> -{ -}; - -} //namespace container_detail { -} //namespace container { -} //namespace boost{ - -#include "config_end.hpp" - -#endif //#define BOOST_CONTAINER_DETAIL_VERSION_TYPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/detail/workaround.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/detail/workaround.hpp deleted file mode 100644 index 49fe284b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/detail/workaround.hpp +++ /dev/null @@ -1,50 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_DETAIL_WORKAROUND_HPP -#define BOOST_CONTAINER_DETAIL_WORKAROUND_HPP - -#include - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)\ - && !defined(BOOST_INTERPROCESS_DISABLE_VARIADIC_TMPL) - #define BOOST_CONTAINER_PERFECT_FORWARDING -#endif - -#if defined(BOOST_NO_CXX11_NOEXCEPT) - #if defined(BOOST_MSVC) - #define BOOST_CONTAINER_NOEXCEPT throw() - #else - #define BOOST_CONTAINER_NOEXCEPT - #endif - #define BOOST_CONTAINER_NOEXCEPT_IF(x) -#else - #define BOOST_CONTAINER_NOEXCEPT noexcept - #define BOOST_CONTAINER_NOEXCEPT_IF(x) noexcept(x) -#endif - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && defined(__GXX_EXPERIMENTAL_CXX0X__)\ - && (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40700) - #define BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST -#endif - -#if !defined(BOOST_FALLTHOUGH) - #define BOOST_CONTAINER_FALLTHOUGH -#else - #define BOOST_CONTAINER_FALLTHOUGH BOOST_FALLTHOUGH; -#endif - -//Macros for documentation purposes. For code, expands to the argument -#define BOOST_CONTAINER_IMPDEF(TYPE) TYPE -#define BOOST_CONTAINER_SEEDOC(TYPE) TYPE - -#include - -#endif //#ifndef BOOST_CONTAINER_DETAIL_WORKAROUND_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/map.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/map.hpp deleted file mode 100644 index f4776e88..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/map.hpp +++ /dev/null @@ -1,1532 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_MAP_HPP -#define BOOST_CONTAINER_MAP_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace container { - -/// @cond -// Forward declarations of operators == and <, needed for friend declarations. -template -inline bool operator==(const map& x, - const map& y); - -template -inline bool operator<(const map& x, - const map& y); -/// @endcond - -//! A map is a kind of associative container that supports unique keys (contains at -//! most one of each key value) and provides for fast retrieval of values of another -//! type T based on the keys. The map class supports bidirectional iterators. -//! -//! A map satisfies all of the requirements of a container and of a reversible -//! container and of an associative container. For a -//! map the key_type is Key and the value_type is std::pair. -//! -//! Compare is the ordering function for Keys (e.g. std::less). -//! -//! Allocator is the allocator to allocate the value_types -//! (e.g. allocator< std::pair > ). -#ifdef BOOST_CONTAINER_DOXYGEN_INVOKED -template , class Allocator = std::allocator< std::pair< const Key, T> > > -#else -template -#endif -class map -{ - /// @cond - private: - BOOST_COPYABLE_AND_MOVABLE(map) - - typedef std::pair value_type_impl; - typedef container_detail::rbtree - , Compare, Allocator> tree_t; - typedef container_detail::pair movable_value_type_impl; - typedef container_detail::tree_value_compare - < Key, value_type_impl, Compare, container_detail::select1st - > value_compare_impl; - tree_t m_tree; // red-black tree representing map - /// @endcond - - public: - ////////////////////////////////////////////// - // - // types - // - ////////////////////////////////////////////// - - typedef Key key_type; - typedef T mapped_type; - typedef std::pair value_type; - typedef typename boost::container::allocator_traits::pointer pointer; - typedef typename boost::container::allocator_traits::const_pointer const_pointer; - typedef typename boost::container::allocator_traits::reference reference; - typedef typename boost::container::allocator_traits::const_reference const_reference; - typedef typename boost::container::allocator_traits::size_type size_type; - typedef typename boost::container::allocator_traits::difference_type difference_type; - typedef Allocator allocator_type; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::stored_allocator_type) stored_allocator_type; - typedef BOOST_CONTAINER_IMPDEF(value_compare_impl) value_compare; - typedef Compare key_compare; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::iterator) iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::const_iterator) const_iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::reverse_iterator) reverse_iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::const_reverse_iterator) const_reverse_iterator; - typedef std::pair nonconst_value_type; - typedef BOOST_CONTAINER_IMPDEF(movable_value_type_impl) movable_value_type; - - ////////////////////////////////////////////// - // - // construct/copy/destroy - // - ////////////////////////////////////////////// - - //! Effects: Default constructs an empty map. - //! - //! Complexity: Constant. - map() - : m_tree() - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty map using the specified comparison object - //! and allocator. - //! - //! Complexity: Constant. - explicit map(const Compare& comp, - const allocator_type& a = allocator_type()) - : m_tree(comp, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty map using the specified allocator. - //! - //! Complexity: Constant. - explicit map(const allocator_type& a) - : m_tree(a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty map using the specified comparison object and - //! allocator, and inserts elements from the range [first ,last ). - //! - //! Complexity: Linear in N if the range [first ,last ) is already sorted using - //! comp and otherwise N logN, where N is last - first. - template - map(InputIterator first, InputIterator last, const Compare& comp = Compare(), - const allocator_type& a = allocator_type()) - : m_tree(true, first, last, comp, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty map using the specified comparison object and - //! allocator, and inserts elements from the ordered unique range [first ,last). This function - //! is more efficient than the normal range creation for ordered ranges. - //! - //! Requires: [first ,last) must be ordered according to the predicate and must be - //! unique values. - //! - //! Complexity: Linear in N. - //! - //! Note: Non-standard extension. - template - map( ordered_unique_range_t, InputIterator first, InputIterator last - , const Compare& comp = Compare(), const allocator_type& a = allocator_type()) - : m_tree(ordered_range, first, last, comp, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Copy constructs a map. - //! - //! Complexity: Linear in x.size(). - map(const map& x) - : m_tree(x.m_tree) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Move constructs a map. Constructs *this using x's resources. - //! - //! Complexity: Constant. - //! - //! Postcondition: x is emptied. - map(BOOST_RV_REF(map) x) - : m_tree(boost::move(x.m_tree)) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Copy constructs a map using the specified allocator. - //! - //! Complexity: Linear in x.size(). - map(const map& x, const allocator_type &a) - : m_tree(x.m_tree, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Move constructs a map using the specified allocator. - //! Constructs *this using x's resources. - //! - //! Complexity: Constant if x == x.get_allocator(), linear otherwise. - //! - //! Postcondition: x is emptied. - map(BOOST_RV_REF(map) x, const allocator_type &a) - : m_tree(boost::move(x.m_tree), a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Makes *this a copy of x. - //! - //! Complexity: Linear in x.size(). - map& operator=(BOOST_COPY_ASSIGN_REF(map) x) - { m_tree = x.m_tree; return *this; } - - //! Effects: this->swap(x.get()). - //! - //! Complexity: Constant. - map& operator=(BOOST_RV_REF(map) x) - { m_tree = boost::move(x.m_tree); return *this; } - - //! Effects: Returns a copy of the Allocator that - //! was passed to the object's constructor. - //! - //! Complexity: Constant. - allocator_type get_allocator() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_allocator(); } - - //! Effects: Returns a reference to the internal allocator. - //! - //! Throws: Nothing - //! - //! Complexity: Constant. - //! - //! Note: Non-standard extension. - stored_allocator_type &get_stored_allocator() BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_stored_allocator(); } - - //! Effects: Returns a reference to the internal allocator. - //! - //! Throws: Nothing - //! - //! Complexity: Constant. - //! - //! Note: Non-standard extension. - const stored_allocator_type &get_stored_allocator() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_stored_allocator(); } - - ////////////////////////////////////////////// - // - // iterators - // - ////////////////////////////////////////////// - - //! Effects: Returns an iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - iterator begin() BOOST_CONTAINER_NOEXCEPT - { return m_tree.begin(); } - - //! Effects: Returns a const_iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator begin() const BOOST_CONTAINER_NOEXCEPT - { return this->cbegin(); } - - //! Effects: Returns an iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - iterator end() BOOST_CONTAINER_NOEXCEPT - { return m_tree.end(); } - - //! Effects: Returns a const_iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator end() const BOOST_CONTAINER_NOEXCEPT - { return this->cend(); } - - //! Effects: Returns a reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - reverse_iterator rbegin() BOOST_CONTAINER_NOEXCEPT - { return m_tree.rbegin(); } - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator rbegin() const BOOST_CONTAINER_NOEXCEPT - { return this->crbegin(); } - - //! Effects: Returns a reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - reverse_iterator rend() BOOST_CONTAINER_NOEXCEPT - { return m_tree.rend(); } - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator rend() const BOOST_CONTAINER_NOEXCEPT - { return this->crend(); } - - //! Effects: Returns a const_iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cbegin() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.begin(); } - - //! Effects: Returns a const_iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cend() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.end(); } - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crbegin() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.rbegin(); } - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crend() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.rend(); } - - ////////////////////////////////////////////// - // - // capacity - // - ////////////////////////////////////////////// - - //! Effects: Returns true if the container contains no elements. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - bool empty() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.empty(); } - - //! Effects: Returns the number of the elements contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - size_type size() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.size(); } - - //! Effects: Returns the largest possible size of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - size_type max_size() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.max_size(); } - - ////////////////////////////////////////////// - // - // element access - // - ////////////////////////////////////////////// - - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - //! Effects: If there is no key equivalent to x in the map, inserts - //! value_type(x, T()) into the map. - //! - //! Returns: Allocator reference to the mapped_type corresponding to x in *this. - //! - //! Complexity: Logarithmic. - mapped_type& operator[](const key_type &k); - - //! Effects: If there is no key equivalent to x in the map, inserts - //! value_type(boost::move(x), T()) into the map (the key is move-constructed) - //! - //! Returns: Allocator reference to the mapped_type corresponding to x in *this. - //! - //! Complexity: Logarithmic. - mapped_type& operator[](key_type &&k); - #else - BOOST_MOVE_CONVERSION_AWARE_CATCH( operator[] , key_type, mapped_type&, this->priv_subscript) - #endif - - //! Returns: Allocator reference to the element whose key is equivalent to x. - //! Throws: An exception object of type out_of_range if no such element is present. - //! Complexity: logarithmic. - T& at(const key_type& k) - { - iterator i = this->find(k); - if(i == this->end()){ - throw_out_of_range("map::at key not found"); - } - return i->second; - } - - //! Returns: Allocator reference to the element whose key is equivalent to x. - //! Throws: An exception object of type out_of_range if no such element is present. - //! Complexity: logarithmic. - const T& at(const key_type& k) const - { - const_iterator i = this->find(k); - if(i == this->end()){ - throw_out_of_range("map::at key not found"); - } - return i->second; - } - - ////////////////////////////////////////////// - // - // modifiers - // - ////////////////////////////////////////////// - - //! Effects: Inserts x if and only if there is no element in the container - //! with key equivalent to the key of x. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - std::pair insert(const value_type& x) - { return m_tree.insert_unique(x); } - - //! Effects: Inserts a new value_type created from the pair if and only if - //! there is no element in the container with key equivalent to the key of x. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - std::pair insert(const nonconst_value_type& x) - { return m_tree.insert_unique(x); } - - //! Effects: Inserts a new value_type move constructed from the pair if and - //! only if there is no element in the container with key equivalent to the key of x. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - std::pair insert(BOOST_RV_REF(nonconst_value_type) x) - { return m_tree.insert_unique(boost::move(x)); } - - //! Effects: Inserts a new value_type move constructed from the pair if and - //! only if there is no element in the container with key equivalent to the key of x. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - std::pair insert(BOOST_RV_REF(movable_value_type) x) - { return m_tree.insert_unique(boost::move(x)); } - - //! Effects: Move constructs a new value from x if and only if there is - //! no element in the container with key equivalent to the key of x. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - std::pair insert(BOOST_RV_REF(value_type) x) - { return m_tree.insert_unique(boost::move(x)); } - - //! Effects: Inserts a copy of x in the container if and only if there is - //! no element in the container with key equivalent to the key of x. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, const value_type& x) - { return m_tree.insert_unique(position, x); } - - //! Effects: Move constructs a new value from x if and only if there is - //! no element in the container with key equivalent to the key of x. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, BOOST_RV_REF(nonconst_value_type) x) - { return m_tree.insert_unique(position, boost::move(x)); } - - //! Effects: Move constructs a new value from x if and only if there is - //! no element in the container with key equivalent to the key of x. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, BOOST_RV_REF(movable_value_type) x) - { return m_tree.insert_unique(position, boost::move(x)); } - - //! Effects: Inserts a copy of x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - iterator insert(const_iterator position, const nonconst_value_type& x) - { return m_tree.insert_unique(position, x); } - - //! Effects: Inserts an element move constructed from x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic. - iterator insert(const_iterator position, BOOST_RV_REF(value_type) x) - { return m_tree.insert_unique(position, boost::move(x)); } - - //! Requires: first, last are not iterators into *this. - //! - //! Effects: inserts each element from the range [first,last) if and only - //! if there is no element with key equivalent to the key of that element. - //! - //! Complexity: At most N log(size()+N) (N is the distance from first to last) - template - void insert(InputIterator first, InputIterator last) - { m_tree.insert_unique(first, last); } - - #if defined(BOOST_CONTAINER_PERFECT_FORWARDING) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! Effects: Inserts an object x of type T constructed with - //! std::forward(args)... in the container if and only if there is - //! no element in the container with an equivalent key. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: The bool component of the returned pair is true if and only - //! if the insertion takes place, and the iterator component of the pair - //! points to the element with key equivalent to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - template - std::pair emplace(Args&&... args) - { return m_tree.emplace_unique(boost::forward(args)...); } - - //! Effects: Inserts an object of type T constructed with - //! std::forward(args)... in the container if and only if there is - //! no element in the container with an equivalent key. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - template - iterator emplace_hint(const_iterator hint, Args&&... args) - { return m_tree.emplace_hint_unique(hint, boost::forward(args)...); } - - #else //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - #define BOOST_PP_LOCAL_MACRO(n) \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - std::pair emplace(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { return m_tree.emplace_unique(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); } \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace_hint(const_iterator hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { return m_tree.emplace_hint_unique(hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _));} \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - //! Effects: Erases the element pointed to by position. - //! - //! Returns: Returns an iterator pointing to the element immediately - //! following q prior to the element being erased. If no such element exists, - //! returns end(). - //! - //! Complexity: Amortized constant time - iterator erase(const_iterator position) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(position); } - - //! Effects: Erases all elements in the container with key equivalent to x. - //! - //! Returns: Returns the number of erased elements. - //! - //! Complexity: log(size()) + count(k) - size_type erase(const key_type& x) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(x); } - - //! Effects: Erases all the elements in the range [first, last). - //! - //! Returns: Returns last. - //! - //! Complexity: log(size())+N where N is the distance from first to last. - iterator erase(const_iterator first, const_iterator last) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(first, last); } - - //! Effects: Swaps the contents of *this and x. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - void swap(map& x) - { m_tree.swap(x.m_tree); } - - //! Effects: erase(a.begin(),a.end()). - //! - //! Postcondition: size() == 0. - //! - //! Complexity: linear in size(). - void clear() BOOST_CONTAINER_NOEXCEPT - { m_tree.clear(); } - - ////////////////////////////////////////////// - // - // observers - // - ////////////////////////////////////////////// - - //! Effects: Returns the comparison object out - //! of which a was constructed. - //! - //! Complexity: Constant. - key_compare key_comp() const - { return m_tree.key_comp(); } - - //! Effects: Returns an object of value_compare constructed out - //! of the comparison object. - //! - //! Complexity: Constant. - value_compare value_comp() const - { return value_compare(m_tree.key_comp()); } - - ////////////////////////////////////////////// - // - // map operations - // - ////////////////////////////////////////////// - - //! Returns: An iterator pointing to an element with the key - //! equivalent to x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic. - iterator find(const key_type& x) - { return m_tree.find(x); } - - //! Returns: Allocator const_iterator pointing to an element with the key - //! equivalent to x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic. - const_iterator find(const key_type& x) const - { return m_tree.find(x); } - - //! Returns: The number of elements with key equivalent to x. - //! - //! Complexity: log(size())+count(k) - size_type count(const key_type& x) const - { return static_cast(m_tree.find(x) != m_tree.end()); } - - //! Returns: An iterator pointing to the first element with key not less - //! than k, or a.end() if such an element is not found. - //! - //! Complexity: Logarithmic - iterator lower_bound(const key_type& x) - { return m_tree.lower_bound(x); } - - //! Returns: Allocator const iterator pointing to the first element with key not - //! less than k, or a.end() if such an element is not found. - //! - //! Complexity: Logarithmic - const_iterator lower_bound(const key_type& x) const - { return m_tree.lower_bound(x); } - - //! Returns: An iterator pointing to the first element with key not less - //! than x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic - iterator upper_bound(const key_type& x) - { return m_tree.upper_bound(x); } - - //! Returns: Allocator const iterator pointing to the first element with key not - //! less than x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic - const_iterator upper_bound(const key_type& x) const - { return m_tree.upper_bound(x); } - - //! Effects: Equivalent to std::make_pair(this->lower_bound(k), this->upper_bound(k)). - //! - //! Complexity: Logarithmic - std::pair equal_range(const key_type& x) - { return m_tree.equal_range(x); } - - //! Effects: Equivalent to std::make_pair(this->lower_bound(k), this->upper_bound(k)). - //! - //! Complexity: Logarithmic - std::pair equal_range(const key_type& x) const - { return m_tree.equal_range(x); } - - /// @cond - template - friend bool operator== (const map&, - const map&); - template - friend bool operator< (const map&, - const map&); - private: - mapped_type& priv_subscript(const key_type &k) - { - //we can optimize this - iterator i = lower_bound(k); - // i->first is greater than or equivalent to k. - if (i == end() || key_comp()(k, (*i).first)){ - container_detail::value_init m; - movable_value_type val(k, boost::move(m.m_t)); - i = insert(i, boost::move(val)); - } - return (*i).second; - } - - mapped_type& priv_subscript(BOOST_RV_REF(key_type) mk) - { - key_type &k = mk; - //we can optimize this - iterator i = lower_bound(k); - // i->first is greater than or equivalent to k. - if (i == end() || key_comp()(k, (*i).first)){ - container_detail::value_init m; - movable_value_type val(boost::move(k), boost::move(m.m_t)); - i = insert(i, boost::move(val)); - } - return (*i).second; - } - - /// @endcond -}; - -template -inline bool operator==(const map& x, - const map& y) - { return x.m_tree == y.m_tree; } - -template -inline bool operator<(const map& x, - const map& y) - { return x.m_tree < y.m_tree; } - -template -inline bool operator!=(const map& x, - const map& y) - { return !(x == y); } - -template -inline bool operator>(const map& x, - const map& y) - { return y < x; } - -template -inline bool operator<=(const map& x, - const map& y) - { return !(y < x); } - -template -inline bool operator>=(const map& x, - const map& y) - { return !(x < y); } - -template -inline void swap(map& x, map& y) - { x.swap(y); } - -/// @cond - -// Forward declaration of operators < and ==, needed for friend declaration. - -template -inline bool operator==(const multimap& x, - const multimap& y); - -template -inline bool operator<(const multimap& x, - const multimap& y); - -} //namespace container { - -//!has_trivial_destructor_after_move<> == true_type -//!specialization for optimizations -template -struct has_trivial_destructor_after_move > -{ - static const bool value = has_trivial_destructor_after_move::value && has_trivial_destructor_after_move::value; -}; - -namespace container { - -/// @endcond - -//! A multimap is a kind of associative container that supports equivalent keys -//! (possibly containing multiple copies of the same key value) and provides for -//! fast retrieval of values of another type T based on the keys. The multimap class -//! supports bidirectional iterators. -//! -//! A multimap satisfies all of the requirements of a container and of a reversible -//! container and of an associative container. For a -//! map the key_type is Key and the value_type is std::pair. -//! -//! Compare is the ordering function for Keys (e.g. std::less). -//! -//! Allocator is the allocator to allocate the value_types -//!(e.g. allocator< std::pair<const Key, T> >). -#ifdef BOOST_CONTAINER_DOXYGEN_INVOKED -template , class Allocator = std::allocator< std::pair< const Key, T> > > -#else -template -#endif -class multimap -{ - /// @cond - private: - BOOST_COPYABLE_AND_MOVABLE(multimap) - - typedef std::pair value_type_impl; - typedef container_detail::rbtree - , Compare, Allocator> tree_t; - typedef container_detail::pair movable_value_type_impl; - typedef container_detail::tree_value_compare - < Key, value_type_impl, Compare, container_detail::select1st - > value_compare_impl; - tree_t m_tree; // red-black tree representing map - /// @endcond - - public: - ////////////////////////////////////////////// - // - // types - // - ////////////////////////////////////////////// - - typedef Key key_type; - typedef T mapped_type; - typedef std::pair value_type; - typedef typename boost::container::allocator_traits::pointer pointer; - typedef typename boost::container::allocator_traits::const_pointer const_pointer; - typedef typename boost::container::allocator_traits::reference reference; - typedef typename boost::container::allocator_traits::const_reference const_reference; - typedef typename boost::container::allocator_traits::size_type size_type; - typedef typename boost::container::allocator_traits::difference_type difference_type; - typedef Allocator allocator_type; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::stored_allocator_type) stored_allocator_type; - typedef BOOST_CONTAINER_IMPDEF(value_compare_impl) value_compare; - typedef Compare key_compare; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::iterator) iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::const_iterator) const_iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::reverse_iterator) reverse_iterator; - typedef typename BOOST_CONTAINER_IMPDEF(tree_t::const_reverse_iterator) const_reverse_iterator; - typedef std::pair nonconst_value_type; - typedef BOOST_CONTAINER_IMPDEF(movable_value_type_impl) movable_value_type; - - ////////////////////////////////////////////// - // - // construct/copy/destroy - // - ////////////////////////////////////////////// - - //! Effects: Default constructs an empty multimap. - //! - //! Complexity: Constant. - multimap() - : m_tree() - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty multimap using the specified allocator. - //! - //! Complexity: Constant. - explicit multimap(const Compare& comp, const allocator_type& a = allocator_type()) - : m_tree(comp, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty multimap using the specified comparison - //! object and allocator. - //! - //! Complexity: Constant. - explicit multimap(const allocator_type& a) - : m_tree(a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty multimap using the specified comparison object - //! and allocator, and inserts elements from the range [first ,last ). - //! - //! Complexity: Linear in N if the range [first ,last ) is already sorted using - //! comp and otherwise N logN, where N is last - first. - template - multimap(InputIterator first, InputIterator last, - const Compare& comp = Compare(), - const allocator_type& a = allocator_type()) - : m_tree(false, first, last, comp, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Constructs an empty multimap using the specified comparison object and - //! allocator, and inserts elements from the ordered range [first ,last). This function - //! is more efficient than the normal range creation for ordered ranges. - //! - //! Requires: [first ,last) must be ordered according to the predicate. - //! - //! Complexity: Linear in N. - //! - //! Note: Non-standard extension. - template - multimap(ordered_range_t, InputIterator first, InputIterator last, const Compare& comp = Compare(), - const allocator_type& a = allocator_type()) - : m_tree(ordered_range, first, last, comp, a) - {} - - //! Effects: Copy constructs a multimap. - //! - //! Complexity: Linear in x.size(). - multimap(const multimap& x) - : m_tree(x.m_tree) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Move constructs a multimap. Constructs *this using x's resources. - //! - //! Complexity: Constant. - //! - //! Postcondition: x is emptied. - multimap(BOOST_RV_REF(multimap) x) - : m_tree(boost::move(x.m_tree)) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Copy constructs a multimap. - //! - //! Complexity: Linear in x.size(). - multimap(const multimap& x, const allocator_type &a) - : m_tree(x.m_tree, a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Move constructs a multimap using the specified allocator. - //! Constructs *this using x's resources. - //! Complexity: Constant if a == x.get_allocator(), linear otherwise. - //! - //! Postcondition: x is emptied. - multimap(BOOST_RV_REF(multimap) x, const allocator_type &a) - : m_tree(boost::move(x.m_tree), a) - { - //Allocator type must be std::pair - BOOST_STATIC_ASSERT((container_detail::is_same, typename Allocator::value_type>::value)); - } - - //! Effects: Makes *this a copy of x. - //! - //! Complexity: Linear in x.size(). - multimap& operator=(BOOST_COPY_ASSIGN_REF(multimap) x) - { m_tree = x.m_tree; return *this; } - - //! Effects: this->swap(x.get()). - //! - //! Complexity: Constant. - multimap& operator=(BOOST_RV_REF(multimap) x) - { m_tree = boost::move(x.m_tree); return *this; } - - //! Effects: Returns a copy of the Allocator that - //! was passed to the object's constructor. - //! - //! Complexity: Constant. - allocator_type get_allocator() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_allocator(); } - - //! Effects: Returns a reference to the internal allocator. - //! - //! Throws: Nothing - //! - //! Complexity: Constant. - //! - //! Note: Non-standard extension. - stored_allocator_type &get_stored_allocator() BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_stored_allocator(); } - - //! Effects: Returns a reference to the internal allocator. - //! - //! Throws: Nothing - //! - //! Complexity: Constant. - //! - //! Note: Non-standard extension. - const stored_allocator_type &get_stored_allocator() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.get_stored_allocator(); } - - ////////////////////////////////////////////// - // - // iterators - // - ////////////////////////////////////////////// - - //! Effects: Returns an iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - iterator begin() BOOST_CONTAINER_NOEXCEPT - { return m_tree.begin(); } - - //! Effects: Returns a const_iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator begin() const BOOST_CONTAINER_NOEXCEPT - { return this->cbegin(); } - - //! Effects: Returns an iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - iterator end() BOOST_CONTAINER_NOEXCEPT - { return m_tree.end(); } - - //! Effects: Returns a const_iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator end() const BOOST_CONTAINER_NOEXCEPT - { return this->cend(); } - - //! Effects: Returns a reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - reverse_iterator rbegin() BOOST_CONTAINER_NOEXCEPT - { return m_tree.rbegin(); } - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator rbegin() const BOOST_CONTAINER_NOEXCEPT - { return this->crbegin(); } - - //! Effects: Returns a reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - reverse_iterator rend() BOOST_CONTAINER_NOEXCEPT - { return m_tree.rend(); } - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator rend() const BOOST_CONTAINER_NOEXCEPT - { return this->crend(); } - - //! Effects: Returns a const_iterator to the first element contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cbegin() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.begin(); } - - //! Effects: Returns a const_iterator to the end of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_iterator cend() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.end(); } - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crbegin() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.rbegin(); } - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - const_reverse_iterator crend() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.rend(); } - - ////////////////////////////////////////////// - // - // capacity - // - ////////////////////////////////////////////// - - //! Effects: Returns true if the container contains no elements. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - bool empty() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.empty(); } - - //! Effects: Returns the number of the elements contained in the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - size_type size() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.size(); } - - //! Effects: Returns the largest possible size of the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - size_type max_size() const BOOST_CONTAINER_NOEXCEPT - { return m_tree.max_size(); } - - ////////////////////////////////////////////// - // - // modifiers - // - ////////////////////////////////////////////// - - #if defined(BOOST_CONTAINER_PERFECT_FORWARDING) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! Effects: Inserts an object of type T constructed with - //! std::forward(args)... in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - template - iterator emplace(Args&&... args) - { return m_tree.emplace_equal(boost::forward(args)...); } - - //! Effects: Inserts an object of type T constructed with - //! std::forward(args)... in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - template - iterator emplace_hint(const_iterator hint, Args&&... args) - { return m_tree.emplace_hint_equal(hint, boost::forward(args)...); } - - #else //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - #define BOOST_PP_LOCAL_MACRO(n) \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { return m_tree.emplace_equal(BOOST_PP_ENUM(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); } \ - \ - BOOST_PP_EXPR_IF(n, template<) BOOST_PP_ENUM_PARAMS(n, class P) BOOST_PP_EXPR_IF(n, >) \ - iterator emplace_hint(const_iterator hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { return m_tree.emplace_hint_equal(hint \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _));} \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif //#ifdef BOOST_CONTAINER_PERFECT_FORWARDING - - //! Effects: Inserts x and returns the iterator pointing to the - //! newly inserted element. - //! - //! Complexity: Logarithmic. - iterator insert(const value_type& x) - { return m_tree.insert_equal(x); } - - //! Effects: Inserts a new value constructed from x and returns - //! the iterator pointing to the newly inserted element. - //! - //! Complexity: Logarithmic. - iterator insert(const nonconst_value_type& x) - { return m_tree.insert_equal(x); } - - //! Effects: Inserts a new value move-constructed from x and returns - //! the iterator pointing to the newly inserted element. - //! - //! Complexity: Logarithmic. - iterator insert(BOOST_RV_REF(nonconst_value_type) x) - { return m_tree.insert_equal(boost::move(x)); } - - //! Effects: Inserts a new value move-constructed from x and returns - //! the iterator pointing to the newly inserted element. - //! - //! Complexity: Logarithmic. - iterator insert(BOOST_RV_REF(movable_value_type) x) - { return m_tree.insert_equal(boost::move(x)); } - - //! Effects: Inserts a copy of x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, const value_type& x) - { return m_tree.insert_equal(position, x); } - - //! Effects: Inserts a new value constructed from x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, const nonconst_value_type& x) - { return m_tree.insert_equal(position, x); } - - //! Effects: Inserts a new value move constructed from x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, BOOST_RV_REF(nonconst_value_type) x) - { return m_tree.insert_equal(position, boost::move(x)); } - - //! Effects: Inserts a new value move constructed from x in the container. - //! p is a hint pointing to where the insert should start to search. - //! - //! Returns: An iterator pointing to the element with key equivalent - //! to the key of x. - //! - //! Complexity: Logarithmic in general, but amortized constant if t - //! is inserted right before p. - iterator insert(const_iterator position, BOOST_RV_REF(movable_value_type) x) - { return m_tree.insert_equal(position, boost::move(x)); } - - //! Requires: first, last are not iterators into *this. - //! - //! Effects: inserts each element from the range [first,last) . - //! - //! Complexity: At most N log(size()+N) (N is the distance from first to last) - template - void insert(InputIterator first, InputIterator last) - { m_tree.insert_equal(first, last); } - - //! Effects: Erases the element pointed to by position. - //! - //! Returns: Returns an iterator pointing to the element immediately - //! following q prior to the element being erased. If no such element exists, - //! returns end(). - //! - //! Complexity: Amortized constant time - iterator erase(const_iterator position) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(position); } - - //! Effects: Erases all elements in the container with key equivalent to x. - //! - //! Returns: Returns the number of erased elements. - //! - //! Complexity: log(size()) + count(k) - size_type erase(const key_type& x) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(x); } - - //! Effects: Erases all the elements in the range [first, last). - //! - //! Returns: Returns last. - //! - //! Complexity: log(size())+N where N is the distance from first to last. - iterator erase(const_iterator first, const_iterator last) BOOST_CONTAINER_NOEXCEPT - { return m_tree.erase(first, last); } - - //! Effects: Swaps the contents of *this and x. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - void swap(multimap& x) - { m_tree.swap(x.m_tree); } - - //! Effects: erase(a.begin(),a.end()). - //! - //! Postcondition: size() == 0. - //! - //! Complexity: linear in size(). - void clear() BOOST_CONTAINER_NOEXCEPT - { m_tree.clear(); } - - ////////////////////////////////////////////// - // - // observers - // - ////////////////////////////////////////////// - - //! Effects: Returns the comparison object out - //! of which a was constructed. - //! - //! Complexity: Constant. - key_compare key_comp() const - { return m_tree.key_comp(); } - - //! Effects: Returns an object of value_compare constructed out - //! of the comparison object. - //! - //! Complexity: Constant. - value_compare value_comp() const - { return value_compare(m_tree.key_comp()); } - - ////////////////////////////////////////////// - // - // map operations - // - ////////////////////////////////////////////// - - //! Returns: An iterator pointing to an element with the key - //! equivalent to x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic. - iterator find(const key_type& x) - { return m_tree.find(x); } - - //! Returns: Allocator const iterator pointing to an element with the key - //! equivalent to x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic. - const_iterator find(const key_type& x) const - { return m_tree.find(x); } - - //! Returns: The number of elements with key equivalent to x. - //! - //! Complexity: log(size())+count(k) - size_type count(const key_type& x) const - { return m_tree.count(x); } - - //! Returns: An iterator pointing to the first element with key not less - //! than k, or a.end() if such an element is not found. - //! - //! Complexity: Logarithmic - iterator lower_bound(const key_type& x) - {return m_tree.lower_bound(x); } - - //! Returns: Allocator const iterator pointing to the first element with key not - //! less than k, or a.end() if such an element is not found. - //! - //! Complexity: Logarithmic - const_iterator lower_bound(const key_type& x) const - { return m_tree.lower_bound(x); } - - //! Returns: An iterator pointing to the first element with key not less - //! than x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic - iterator upper_bound(const key_type& x) - { return m_tree.upper_bound(x); } - - //! Returns: Allocator const iterator pointing to the first element with key not - //! less than x, or end() if such an element is not found. - //! - //! Complexity: Logarithmic - const_iterator upper_bound(const key_type& x) const - { return m_tree.upper_bound(x); } - - //! Effects: Equivalent to std::make_pair(this->lower_bound(k), this->upper_bound(k)). - //! - //! Complexity: Logarithmic - std::pair equal_range(const key_type& x) - { return m_tree.equal_range(x); } - - //! Effects: Equivalent to std::make_pair(this->lower_bound(k), this->upper_bound(k)). - //! - //! Complexity: Logarithmic - std::pair equal_range(const key_type& x) const - { return m_tree.equal_range(x); } - - /// @cond - template - friend bool operator== (const multimap& x, - const multimap& y); - - template - friend bool operator< (const multimap& x, - const multimap& y); - /// @endcond -}; - -template -inline bool operator==(const multimap& x, - const multimap& y) -{ return x.m_tree == y.m_tree; } - -template -inline bool operator<(const multimap& x, - const multimap& y) -{ return x.m_tree < y.m_tree; } - -template -inline bool operator!=(const multimap& x, - const multimap& y) -{ return !(x == y); } - -template -inline bool operator>(const multimap& x, - const multimap& y) -{ return y < x; } - -template -inline bool operator<=(const multimap& x, - const multimap& y) -{ return !(y < x); } - -template -inline bool operator>=(const multimap& x, - const multimap& y) -{ return !(x < y); } - -template -inline void swap(multimap& x, multimap& y) -{ x.swap(y); } - -/// @cond - -} //namespace container { - -//!has_trivial_destructor_after_move<> == true_type -//!specialization for optimizations -template -struct has_trivial_destructor_after_move > -{ - static const bool value = has_trivial_destructor_after_move::value && has_trivial_destructor_after_move::value; -}; - -namespace container { - -/// @endcond - -}} - -#include - -#endif /* BOOST_CONTAINER_MAP_HPP */ - diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator.hpp deleted file mode 100644 index d16ac37f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator.hpp +++ /dev/null @@ -1,1534 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Pablo Halpern 2009. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_HPP -#define BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_HPP - -#if defined (_MSC_VER) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { namespace container { - -//! Remark: if a specialization is derived from true_type, indicates that T may be constructed -//! with an allocator as its last constructor argument. Ideally, all constructors of T (including the -//! copy and move constructors) should have a variant that accepts a final argument of -//! allocator_type. -//! -//! Requires: if a specialization is derived from true_type, T must have a nested type, -//! allocator_type and at least one constructor for which allocator_type is the last -//! parameter. If not all constructors of T can be called with a final allocator_type argument, -//! and if T is used in a context where a container must call such a constructor, then the program is -//! ill-formed. -//! -//! [Example: -//! template > -//! class Z { -//! public: -//! typedef Allocator allocator_type; -//! -//! // Default constructor with optional allocator suffix -//! Z(const allocator_type& a = allocator_type()); -//! -//! // Copy constructor and allocator-extended copy constructor -//! Z(const Z& zz); -//! Z(const Z& zz, const allocator_type& a); -//! }; -//! -//! // Specialize trait for class template Z -//! template > -//! struct constructible_with_allocator_suffix > -//! : ::boost::true_type { }; -//! -- end example] -//! -//! Note: This trait is a workaround inspired by "N2554: The Scoped Allocator Model (Rev 2)" -//! (Pablo Halpern, 2008-02-29) to backport the scoped allocator model to C++03, as -//! in C++03 there is no mechanism to detect if a type can be constructed from arbitrary arguments. -//! Applications aiming portability with several compilers should always define this trait. -//! -//! In conforming C++11 compilers or compilers supporting SFINAE expressions -//! (when BOOST_NO_SFINAE_EXPR is NOT defined), this trait is ignored and C++11 rules will be used -//! to detect if a type should be constructed with suffix or prefix allocator arguments. -template -struct constructible_with_allocator_suffix - : ::boost::false_type -{}; - -//! Remark: if a specialization is derived from true_type, indicates that T may be constructed -//! with allocator_arg and T::allocator_type as its first two constructor arguments. -//! Ideally, all constructors of T (including the copy and move constructors) should have a variant -//! that accepts these two initial arguments. -//! -//! Requires: if a specialization is derived from true_type, T must have a nested type, -//! allocator_type and at least one constructor for which allocator_arg_t is the first -//! parameter and allocator_type is the second parameter. If not all constructors of T can be -//! called with these initial arguments, and if T is used in a context where a container must call such -//! a constructor, then the program is ill-formed. -//! -//! [Example: -//! template > -//! class Y { -//! public: -//! typedef Allocator allocator_type; -//! -//! // Default constructor with and allocator-extended default constructor -//! Y(); -//! Y(allocator_arg_t, const allocator_type& a); -//! -//! // Copy constructor and allocator-extended copy constructor -//! Y(const Y& yy); -//! Y(allocator_arg_t, const allocator_type& a, const Y& yy); -//! -//! // Variadic constructor and allocator-extended variadic constructor -//! template Y(Args&& args...); -//! template -//! Y(allocator_arg_t, const allocator_type& a, Args&&... args); -//! }; -//! -//! // Specialize trait for class template Y -//! template > -//! struct constructible_with_allocator_prefix > -//! : ::boost::true_type { }; -//! -//! -- end example] -//! -//! Note: This trait is a workaround inspired by "N2554: The Scoped Allocator Model (Rev 2)" -//! (Pablo Halpern, 2008-02-29) to backport the scoped allocator model to C++03, as -//! in C++03 there is no mechanism to detect if a type can be constructed from arbitrary arguments. -//! Applications aiming portability with several compilers should always define this trait. -//! -//! In conforming C++11 compilers or compilers supporting SFINAE expressions -//! (when BOOST_NO_SFINAE_EXPR is NOT defined), this trait is ignored and C++11 rules will be used -//! to detect if a type should be constructed with suffix or prefix allocator arguments. -template -struct constructible_with_allocator_prefix - : ::boost::false_type -{}; - -///@cond - -namespace container_detail { - -template -struct uses_allocator_imp -{ - // Use SFINAE (Substitution Failure Is Not An Error) to detect the - // presence of an 'allocator_type' nested type convertilble from Alloc. - - private: - // Match this function if TypeT::allocator_type exists and is - // implicitly convertible from Alloc - template - static char test(int, typename U::allocator_type); - - // Match this function if TypeT::allocator_type does not exist or is - // not convertible from Alloc. - template - static int test(LowPriorityConversion, LowPriorityConversion); - - static Alloc alloc; // Declared but not defined - - public: - enum { value = sizeof(test(0, alloc)) == sizeof(char) }; -}; - -} //namespace container_detail { - -///@endcond - -//! Remark: Automatically detects if T has a nested allocator_type that is convertible from -//! Alloc. Meets the BinaryTypeTrait requirements ([meta.rqmts] 20.4.1). A program may -//! specialize this type to derive from true_type for a T of user-defined type if T does not -//! have a nested allocator_type but is nonetheless constructible using the specified Alloc. -//! -//! Result: derived from true_type if Convertible and -//! derived from false_type otherwise. -template -struct uses_allocator - : boost::integral_constant::value> -{}; - -///@cond - -namespace container_detail { - -template -struct is_scoped_allocator_imp -{ - template - static char test(int, typename T::outer_allocator_type*); - - template - static int test(LowPriorityConversion, void*); - - static const bool value = (sizeof(char) == sizeof(test(0, 0))); -}; - -template::value > -struct outermost_allocator_type_impl -{ - typedef typename MaybeScopedAlloc::outer_allocator_type outer_type; - typedef typename outermost_allocator_type_impl::type type; -}; - -template -struct outermost_allocator_type_impl -{ - typedef MaybeScopedAlloc type; -}; - -template::value > -struct outermost_allocator_imp -{ - typedef MaybeScopedAlloc type; - - static type &get(MaybeScopedAlloc &a) - { return a; } - - static const type &get(const MaybeScopedAlloc &a) - { return a; } -}; - -template -struct outermost_allocator_imp -{ - typedef typename MaybeScopedAlloc::outer_allocator_type outer_type; - typedef typename outermost_allocator_type_impl::type type; - - static type &get(MaybeScopedAlloc &a) - { return outermost_allocator_imp::get(a.outer_allocator()); } - - static const type &get(const MaybeScopedAlloc &a) - { return outermost_allocator_imp::get(a.outer_allocator()); } -}; - -} //namespace container_detail { - -template -struct is_scoped_allocator - : boost::integral_constant::value> -{}; - -template -struct outermost_allocator - : container_detail::outermost_allocator_imp -{}; - -template -typename container_detail::outermost_allocator_imp::type & - get_outermost_allocator(Alloc &a) -{ return container_detail::outermost_allocator_imp::get(a); } - -template -const typename container_detail::outermost_allocator_imp::type & - get_outermost_allocator(const Alloc &a) -{ return container_detail::outermost_allocator_imp::get(a); } - -namespace container_detail { - -// Check if we can detect is_convertible using advanced SFINAE expressions -#if !defined(BOOST_NO_SFINAE_EXPR) - - //! Code inspired by Mathias Gaunard's is_convertible.cpp found in the Boost mailing list - //! http://boost.2283326.n4.nabble.com/type-traits-is-constructible-when-decltype-is-supported-td3575452.html - //! Thanks Mathias! - - //With variadic templates, we need a single class to implement the trait - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template - struct is_constructible_impl - { - typedef char yes_type; - struct no_type - { char padding[2]; }; - - template - struct dummy; - - template - static yes_type test(dummy()...))>*); - - template - static no_type test(...); - - static const bool value = sizeof(test(0)) == sizeof(yes_type); - }; - - template - struct is_constructible - : boost::integral_constant::value> - {}; - - template - struct is_constructible_with_allocator_prefix - : is_constructible - {}; - - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - //Without variadic templates, we need to use de preprocessor to generate - //some specializations. - - #define BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS \ - BOOST_PP_ADD(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, 3) - //! - - //Generate N+1 template parameters so that we can specialize N - template - struct is_constructible_impl; - - //Generate N specializations, from 0 to - //BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS parameters - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - struct is_constructible_impl \ - \ - { \ - typedef char yes_type; \ - struct no_type \ - { char padding[2]; }; \ - \ - template \ - struct dummy; \ - \ - template \ - static yes_type test(dummy*); \ - \ - template \ - static no_type test(...); \ - \ - static const bool value = sizeof(test(0)) == sizeof(yes_type); \ - }; \ - //! - - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - //Finally just inherit from the implementation to define he trait - template< class T - BOOST_PP_ENUM_TRAILING( BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS - , BOOST_CONTAINER_PP_TEMPLATE_PARAM_WITH_DEFAULT - , void) - > - struct is_constructible - : boost::integral_constant - < bool - , is_constructible_impl - < T - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS, P) - , void>::value - > - {}; - - //Finally just inherit from the implementation to define he trait - template - struct is_constructible_with_allocator_prefix - : is_constructible - < T, allocator_arg_t, InnerAlloc - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_PP_SUB(BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS, 2), P) - > - {}; -/* - template - struct is_constructible_with_allocator_suffix - : is_constructible - < T - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_PP_SUB(BOOST_CONTAINER_MAX_IS_CONSTRUCTIBLE_PARAMETERS, 1), P) - , InnerAlloc - > - {};*/ - - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#else // #if !defined(BOOST_NO_SFINAE_EXPR) - - //Without advanced SFINAE expressions, we can't use is_constructible - //so backup to constructible_with_allocator_xxx - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template < class T, class InnerAlloc, class ...Args> - struct is_constructible_with_allocator_prefix - : constructible_with_allocator_prefix - {}; -/* - template < class T, class InnerAlloc, class ...Args> - struct is_constructible_with_allocator_suffix - : constructible_with_allocator_suffix - {};*/ - - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template < class T - , class InnerAlloc - BOOST_PP_ENUM_TRAILING( BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS - , BOOST_CONTAINER_PP_TEMPLATE_PARAM_WITH_DEFAULT - , void) - > - struct is_constructible_with_allocator_prefix - : constructible_with_allocator_prefix - {}; -/* - template < class T - , class InnerAlloc - BOOST_PP_ENUM_TRAILING( BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS - , BOOST_CONTAINER_PP_TEMPLATE_PARAM_WITH_DEFAULT - , void) - > - struct is_constructible_with_allocator_suffix - : constructible_with_allocator_suffix - {};*/ - - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#endif // #if !defined(BOOST_NO_SFINAE_EXPR) - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -template < typename OutermostAlloc - , typename InnerAlloc - , typename T - , class ...Args - > -inline void dispatch_allocator_prefix_suffix - ( boost::true_type use_alloc_prefix, OutermostAlloc& outermost_alloc - , InnerAlloc& inner_alloc, T* p, BOOST_FWD_REF(Args) ...args) -{ - (void)use_alloc_prefix; - allocator_traits::construct - ( outermost_alloc, p, allocator_arg, inner_alloc, ::boost::forward(args)...); -} - -template < typename OutermostAlloc - , typename InnerAlloc - , typename T - , class ...Args - > -inline void dispatch_allocator_prefix_suffix - ( boost::false_type use_alloc_prefix, OutermostAlloc& outermost_alloc - , InnerAlloc &inner_alloc, T* p, BOOST_FWD_REF(Args)...args) -{ - (void)use_alloc_prefix; - allocator_traits::construct - (outermost_alloc, p, ::boost::forward(args)..., inner_alloc); -} - -template < typename OutermostAlloc - , typename InnerAlloc - , typename T - , class ...Args - > -inline void dispatch_uses_allocator - ( boost::true_type uses_allocator, OutermostAlloc& outermost_alloc - , InnerAlloc& inner_alloc, T* p, BOOST_FWD_REF(Args)...args) -{ - (void)uses_allocator; - //BOOST_STATIC_ASSERT((is_constructible_with_allocator_prefix::value || - // is_constructible_with_allocator_suffix::value )); - dispatch_allocator_prefix_suffix - ( is_constructible_with_allocator_prefix() - , outermost_alloc, inner_alloc, p, ::boost::forward(args)...); -} - -template < typename OutermostAlloc - , typename InnerAlloc - , typename T - , class ...Args - > -inline void dispatch_uses_allocator - ( boost::false_type uses_allocator, OutermostAlloc & outermost_alloc - , InnerAlloc & inner_alloc - ,T* p, BOOST_FWD_REF(Args)...args) -{ - (void)uses_allocator; (void)inner_alloc; - allocator_traits::construct - (outermost_alloc, p, ::boost::forward(args)...); -} - -#else //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#define BOOST_PP_LOCAL_MACRO(n) \ -template < typename OutermostAlloc \ - , typename InnerAlloc \ - , typename T \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, class P) \ - > \ -inline void dispatch_allocator_prefix_suffix( \ - boost::true_type use_alloc_prefix, \ - OutermostAlloc& outermost_alloc, \ - InnerAlloc& inner_alloc, \ - T* p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ -{ \ - (void)use_alloc_prefix, \ - allocator_traits::construct \ - (outermost_alloc, p, allocator_arg, inner_alloc \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ -} \ - \ -template < typename OutermostAlloc \ - , typename InnerAlloc \ - , typename T \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, class P) \ - > \ -inline void dispatch_allocator_prefix_suffix( \ - boost::false_type use_alloc_prefix, \ - OutermostAlloc& outermost_alloc, \ - InnerAlloc& inner_alloc, \ - T* p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ -{ \ - (void)use_alloc_prefix; \ - allocator_traits::construct \ - (outermost_alloc, p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _) \ - , inner_alloc); \ -} \ - \ -template < typename OutermostAlloc \ - , typename InnerAlloc \ - , typename T \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, class P) \ - > \ -inline void dispatch_uses_allocator(boost::true_type uses_allocator, \ - OutermostAlloc& outermost_alloc, \ - InnerAlloc& inner_alloc, \ - T* p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ -{ \ - (void)uses_allocator; \ - dispatch_allocator_prefix_suffix \ - (is_constructible_with_allocator_prefix \ - < T, InnerAlloc BOOST_PP_ENUM_TRAILING_PARAMS(n, P)>() \ - , outermost_alloc, inner_alloc, p \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ -} \ - \ -template < typename OutermostAlloc \ - , typename InnerAlloc \ - , typename T \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, class P) \ - > \ -inline void dispatch_uses_allocator(boost::false_type uses_allocator \ - ,OutermostAlloc & outermost_alloc \ - ,InnerAlloc & inner_alloc \ - ,T* p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ -{ \ - (void)uses_allocator; (void)inner_alloc; \ - allocator_traits::construct \ - (outermost_alloc, p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ -} \ -//! -#define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) -#include BOOST_PP_LOCAL_ITERATE() - -#endif //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -template -class scoped_allocator_adaptor_base - : public OuterAlloc -{ - typedef allocator_traits outer_traits_type; - BOOST_COPYABLE_AND_MOVABLE(scoped_allocator_adaptor_base) - - public: - template - struct rebind_base - { - typedef scoped_allocator_adaptor_base other; - }; - - typedef OuterAlloc outer_allocator_type; - typedef scoped_allocator_adaptor inner_allocator_type; - typedef allocator_traits inner_traits_type; - typedef scoped_allocator_adaptor - scoped_allocator_type; - typedef boost::integral_constant< - bool, - outer_traits_type::propagate_on_container_copy_assignment::value || - inner_allocator_type::propagate_on_container_copy_assignment::value - > propagate_on_container_copy_assignment; - typedef boost::integral_constant< - bool, - outer_traits_type::propagate_on_container_move_assignment::value || - inner_allocator_type::propagate_on_container_move_assignment::value - > propagate_on_container_move_assignment; - typedef boost::integral_constant< - bool, - outer_traits_type::propagate_on_container_swap::value || - inner_allocator_type::propagate_on_container_swap::value - > propagate_on_container_swap; - - scoped_allocator_adaptor_base() - {} - - template - scoped_allocator_adaptor_base(BOOST_FWD_REF(OuterA2) outerAlloc, const InnerAllocs &...args) - : outer_allocator_type(::boost::forward(outerAlloc)) - , m_inner(args...) - {} - - scoped_allocator_adaptor_base(const scoped_allocator_adaptor_base& other) - : outer_allocator_type(other.outer_allocator()) - , m_inner(other.inner_allocator()) - {} - - scoped_allocator_adaptor_base(BOOST_RV_REF(scoped_allocator_adaptor_base) other) - : outer_allocator_type(::boost::move(other.outer_allocator())) - , m_inner(::boost::move(other.inner_allocator())) - {} - - template - scoped_allocator_adaptor_base - (const scoped_allocator_adaptor_base& other) - : outer_allocator_type(other.outer_allocator()) - , m_inner(other.inner_allocator()) - {} - - template - scoped_allocator_adaptor_base - (BOOST_RV_REF_BEG scoped_allocator_adaptor_base - BOOST_RV_REF_END other) - : outer_allocator_type(other.outer_allocator()) - , m_inner(other.inner_allocator()) - {} - - public: - struct internal_type_t{}; - - template - scoped_allocator_adaptor_base - ( internal_type_t - , BOOST_FWD_REF(OuterA2) outerAlloc - , const inner_allocator_type &inner) - : outer_allocator_type(::boost::forward(outerAlloc)) - , m_inner(inner) - {} - - public: - - scoped_allocator_adaptor_base &operator= - (BOOST_COPY_ASSIGN_REF(scoped_allocator_adaptor_base) other) - { - outer_allocator_type::operator=(other.outer_allocator()); - m_inner = other.inner_allocator(); - return *this; - } - - scoped_allocator_adaptor_base &operator=(BOOST_RV_REF(scoped_allocator_adaptor_base) other) - { - outer_allocator_type::operator=(boost::move(other.outer_allocator())); - m_inner = ::boost::move(other.inner_allocator()); - return *this; - } - - void swap(scoped_allocator_adaptor_base &r) - { - boost::container::swap_dispatch(this->outer_allocator(), r.outer_allocator()); - boost::container::swap_dispatch(this->m_inner, r.inner_allocator()); - } - - friend void swap(scoped_allocator_adaptor_base &l, scoped_allocator_adaptor_base &r) - { l.swap(r); } - - inner_allocator_type& inner_allocator() - { return m_inner; } - - inner_allocator_type const& inner_allocator() const - { return m_inner; } - - outer_allocator_type & outer_allocator() - { return static_cast(*this); } - - const outer_allocator_type &outer_allocator() const - { return static_cast(*this); } - - scoped_allocator_type select_on_container_copy_construction() const - { - return scoped_allocator_type - (internal_type_t() - ,outer_traits_type::select_on_container_copy_construction(this->outer_allocator()) - ,inner_traits_type::select_on_container_copy_construction(this->inner_allocator()) - ); - } - - private: - inner_allocator_type m_inner; -}; - -#else //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -//Let's add a dummy first template parameter to allow creating -//specializations up to maximum InnerAlloc count -template < - typename OuterAlloc - , bool Dummy - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q) - > -class scoped_allocator_adaptor_base; - -//Specializations for the adaptor with InnerAlloc allocators - -#define BOOST_PP_LOCAL_MACRO(n) \ -template \ -class scoped_allocator_adaptor_base \ - : public OuterAlloc \ -{ \ - typedef allocator_traits outer_traits_type; \ - BOOST_COPYABLE_AND_MOVABLE(scoped_allocator_adaptor_base) \ - \ - public: \ - template \ - struct rebind_base \ - { \ - typedef scoped_allocator_adaptor_base other; \ - }; \ - \ - typedef OuterAlloc outer_allocator_type; \ - typedef scoped_allocator_adaptor inner_allocator_type; \ - typedef scoped_allocator_adaptor scoped_allocator_type; \ - typedef allocator_traits inner_traits_type; \ - typedef boost::integral_constant< \ - bool, \ - outer_traits_type::propagate_on_container_copy_assignment::value || \ - inner_allocator_type::propagate_on_container_copy_assignment::value \ - > propagate_on_container_copy_assignment; \ - typedef boost::integral_constant< \ - bool, \ - outer_traits_type::propagate_on_container_move_assignment::value || \ - inner_allocator_type::propagate_on_container_move_assignment::value \ - > propagate_on_container_move_assignment; \ - typedef boost::integral_constant< \ - bool, \ - outer_traits_type::propagate_on_container_swap::value || \ - inner_allocator_type::propagate_on_container_swap::value \ - > propagate_on_container_swap; \ - \ - scoped_allocator_adaptor_base() \ - {} \ - \ - template \ - scoped_allocator_adaptor_base(BOOST_FWD_REF(OuterA2) outerAlloc \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_CONST_REF_PARAM_LIST_Q, _)) \ - : outer_allocator_type(::boost::forward(outerAlloc)) \ - , m_inner(BOOST_PP_ENUM_PARAMS(n, q)) \ - {} \ - \ - scoped_allocator_adaptor_base(const scoped_allocator_adaptor_base& other) \ - : outer_allocator_type(other.outer_allocator()) \ - , m_inner(other.inner_allocator()) \ - {} \ - \ - scoped_allocator_adaptor_base(BOOST_RV_REF(scoped_allocator_adaptor_base) other) \ - : outer_allocator_type(::boost::move(other.outer_allocator())) \ - , m_inner(::boost::move(other.inner_allocator())) \ - {} \ - \ - template \ - scoped_allocator_adaptor_base(const scoped_allocator_adaptor_base& other) \ - : outer_allocator_type(other.outer_allocator()) \ - , m_inner(other.inner_allocator()) \ - {} \ - \ - template \ - scoped_allocator_adaptor_base \ - (BOOST_RV_REF_BEG scoped_allocator_adaptor_base BOOST_RV_REF_END other) \ - : outer_allocator_type(other.outer_allocator()) \ - , m_inner(other.inner_allocator()) \ - {} \ - \ - public: \ - struct internal_type_t{}; \ - \ - template \ - scoped_allocator_adaptor_base \ - ( internal_type_t \ - , BOOST_FWD_REF(OuterA2) outerAlloc \ - , const inner_allocator_type &inner) \ - : outer_allocator_type(::boost::forward(outerAlloc)) \ - , m_inner(inner) \ - {} \ - \ - public: \ - scoped_allocator_adaptor_base &operator= \ - (BOOST_COPY_ASSIGN_REF(scoped_allocator_adaptor_base) other) \ - { \ - outer_allocator_type::operator=(other.outer_allocator()); \ - m_inner = other.inner_allocator(); \ - return *this; \ - } \ - \ - scoped_allocator_adaptor_base &operator=(BOOST_RV_REF(scoped_allocator_adaptor_base) other) \ - { \ - outer_allocator_type::operator=(boost::move(other.outer_allocator())); \ - m_inner = ::boost::move(other.inner_allocator()); \ - return *this; \ - } \ - \ - void swap(scoped_allocator_adaptor_base &r) \ - { \ - boost::container::swap_dispatch(this->outer_allocator(), r.outer_allocator()); \ - boost::container::swap_dispatch(this->m_inner, r.inner_allocator()); \ - } \ - \ - friend void swap(scoped_allocator_adaptor_base &l, scoped_allocator_adaptor_base &r) \ - { l.swap(r); } \ - \ - inner_allocator_type& inner_allocator() \ - { return m_inner; } \ - \ - inner_allocator_type const& inner_allocator() const \ - { return m_inner; } \ - \ - outer_allocator_type & outer_allocator() \ - { return static_cast(*this); } \ - \ - const outer_allocator_type &outer_allocator() const \ - { return static_cast(*this); } \ - \ - scoped_allocator_type select_on_container_copy_construction() const \ - { \ - return scoped_allocator_type \ - (internal_type_t() \ - ,outer_traits_type::select_on_container_copy_construction(this->outer_allocator()) \ - ,inner_traits_type::select_on_container_copy_construction(this->inner_allocator()) \ - ); \ - } \ - private: \ - inner_allocator_type m_inner; \ -}; \ -//! -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) -#include BOOST_PP_LOCAL_ITERATE() - -#endif //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -//Specialization for adaptor without any InnerAlloc -template -class scoped_allocator_adaptor_base - < OuterAlloc - #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - , true - BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, nat) - #endif - > - : public OuterAlloc -{ - BOOST_COPYABLE_AND_MOVABLE(scoped_allocator_adaptor_base) - public: - - template - struct rebind_base - { - typedef scoped_allocator_adaptor_base - ::template portable_rebind_alloc::type - #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - , true - BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) - #endif - > other; - }; - - typedef OuterAlloc outer_allocator_type; - typedef allocator_traits outer_traits_type; - typedef scoped_allocator_adaptor inner_allocator_type; - typedef inner_allocator_type scoped_allocator_type; - typedef allocator_traits inner_traits_type; - typedef typename outer_traits_type:: - propagate_on_container_copy_assignment propagate_on_container_copy_assignment; - typedef typename outer_traits_type:: - propagate_on_container_move_assignment propagate_on_container_move_assignment; - typedef typename outer_traits_type:: - propagate_on_container_swap propagate_on_container_swap; - - scoped_allocator_adaptor_base() - {} - - template - scoped_allocator_adaptor_base(BOOST_FWD_REF(OuterA2) outerAlloc) - : outer_allocator_type(::boost::forward(outerAlloc)) - {} - - scoped_allocator_adaptor_base(const scoped_allocator_adaptor_base& other) - : outer_allocator_type(other.outer_allocator()) - {} - - scoped_allocator_adaptor_base(BOOST_RV_REF(scoped_allocator_adaptor_base) other) - : outer_allocator_type(::boost::move(other.outer_allocator())) - {} - - template - scoped_allocator_adaptor_base - (const scoped_allocator_adaptor_base< - OuterA2 - #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - , true - BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) - #endif - >& other) - : outer_allocator_type(other.outer_allocator()) - {} - - template - scoped_allocator_adaptor_base - (BOOST_RV_REF_BEG scoped_allocator_adaptor_base< - OuterA2 - #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - , true - BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) - #endif - > BOOST_RV_REF_END other) - : outer_allocator_type(other.outer_allocator()) - {} - - public: - struct internal_type_t{}; - - template - scoped_allocator_adaptor_base(internal_type_t, BOOST_FWD_REF(OuterA2) outerAlloc, const inner_allocator_type &) - : outer_allocator_type(::boost::forward(outerAlloc)) - {} - - public: - scoped_allocator_adaptor_base &operator=(BOOST_COPY_ASSIGN_REF(scoped_allocator_adaptor_base) other) - { - outer_allocator_type::operator=(other.outer_allocator()); - return *this; - } - - scoped_allocator_adaptor_base &operator=(BOOST_RV_REF(scoped_allocator_adaptor_base) other) - { - outer_allocator_type::operator=(boost::move(other.outer_allocator())); - return *this; - } - - void swap(scoped_allocator_adaptor_base &r) - { - boost::container::swap_dispatch(this->outer_allocator(), r.outer_allocator()); - } - - friend void swap(scoped_allocator_adaptor_base &l, scoped_allocator_adaptor_base &r) - { l.swap(r); } - - inner_allocator_type& inner_allocator() - { return static_cast(*this); } - - inner_allocator_type const& inner_allocator() const - { return static_cast(*this); } - - outer_allocator_type & outer_allocator() - { return static_cast(*this); } - - const outer_allocator_type &outer_allocator() const - { return static_cast(*this); } - - scoped_allocator_type select_on_container_copy_construction() const - { - return scoped_allocator_type - (internal_type_t() - ,outer_traits_type::select_on_container_copy_construction(this->outer_allocator()) - //Don't use inner_traits_type::select_on_container_copy_construction(this->inner_allocator()) - //as inner_allocator() is equal to *this and that would trigger an infinite loop - , this->inner_allocator() - ); - } -}; - -} //namespace container_detail { - -///@endcond - -//Scoped allocator -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - - //! This class is a C++03-compatible implementation of std::scoped_allocator_adaptor. - //! The class template scoped_allocator_adaptor is an allocator template that specifies - //! the memory resource (the outer allocator) to be used by a container (as any other - //! allocator does) and also specifies an inner allocator resource to be passed to - //! the constructor of every element within the container. - //! - //! This adaptor is - //! instantiated with one outer and zero or more inner allocator types. If - //! instantiated with only one allocator type, the inner allocator becomes the - //! scoped_allocator_adaptor itself, thus using the same allocator resource for the - //! container and every element within the container and, if the elements themselves - //! are containers, each of their elements recursively. If instantiated with more than - //! one allocator, the first allocator is the outer allocator for use by the container, - //! the second allocator is passed to the constructors of the container's elements, - //! and, if the elements themselves are containers, the third allocator is passed to - //! the elements' elements, and so on. If containers are nested to a depth greater - //! than the number of allocators, the last allocator is used repeatedly, as in the - //! single-allocator case, for any remaining recursions. - //! - //! [Note: The - //! scoped_allocator_adaptor is derived from the outer allocator type so it can be - //! substituted for the outer allocator type in most expressions. -end note] - //! - //! In the construct member functions, `OUTERMOST(x)` is x if x does not have - //! an `outer_allocator()` member function and - //! `OUTERMOST(x.outer_allocator())` otherwise; `OUTERMOST_ALLOC_TRAITS(x)` is - //! `allocator_traits`. - //! - //! [Note: `OUTERMOST(x)` and - //! `OUTERMOST_ALLOC_TRAITS(x)` are recursive operations. It is incumbent upon - //! the definition of `outer_allocator()` to ensure that the recursion terminates. - //! It will terminate for all instantiations of scoped_allocator_adaptor. -end note] - template - class scoped_allocator_adaptor - - #else // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - - template - class scoped_allocator_adaptor - - #endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - -#else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - -template -class scoped_allocator_adaptor -#endif - : public container_detail::scoped_allocator_adaptor_base - -{ - BOOST_COPYABLE_AND_MOVABLE(scoped_allocator_adaptor) - - public: - /// @cond - typedef container_detail::scoped_allocator_adaptor_base - base_type; - typedef typename base_type::internal_type_t internal_type_t; - /// @endcond - typedef OuterAlloc outer_allocator_type; - //! Type: For exposition only - //! - typedef allocator_traits outer_traits_type; - //! Type: `scoped_allocator_adaptor` if `sizeof...(InnerAllocs)` is zero; otherwise, - //! `scoped_allocator_adaptor`. - typedef typename base_type::inner_allocator_type inner_allocator_type; - typedef allocator_traits inner_traits_type; - typedef typename outer_traits_type::value_type value_type; - typedef typename outer_traits_type::size_type size_type; - typedef typename outer_traits_type::difference_type difference_type; - typedef typename outer_traits_type::pointer pointer; - typedef typename outer_traits_type::const_pointer const_pointer; - typedef typename outer_traits_type::void_pointer void_pointer; - typedef typename outer_traits_type::const_void_pointer const_void_pointer; - //! Type: `true_type` if `allocator_traits::propagate_on_container_copy_assignment::value` is - //! true for any `Allocator` in the set of `OuterAlloc` and `InnerAllocs...`; otherwise, false_type. - typedef typename base_type:: - propagate_on_container_copy_assignment propagate_on_container_copy_assignment; - //! Type: `true_type` if `allocator_traits::propagate_on_container_move_assignment::value` is - //! true for any `Allocator` in the set of `OuterAlloc` and `InnerAllocs...`; otherwise, false_type. - typedef typename base_type:: - propagate_on_container_move_assignment propagate_on_container_move_assignment; - //! Type: `true_type` if `allocator_traits::propagate_on_container_swap::value` is true for any - //! `Allocator` in the set of `OuterAlloc` and `InnerAllocs...`; otherwise, false_type. - typedef typename base_type:: - propagate_on_container_swap propagate_on_container_swap; - - //! Type: Rebinds scoped allocator to - //! `typedef scoped_allocator_adaptor - //! < typename outer_traits_type::template portable_rebind_alloc::type - //! , InnerAllocs... >` - template - struct rebind - { - typedef scoped_allocator_adaptor - < typename outer_traits_type::template portable_rebind_alloc::type - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - , InnerAllocs... - #else - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) - #endif - > other; - }; - - //! Effects: value-initializes the OuterAlloc base class - //! and the inner allocator object. - scoped_allocator_adaptor() - {} - - ~scoped_allocator_adaptor() - {} - - //! Effects: initializes each allocator within the adaptor with - //! the corresponding allocator from other. - scoped_allocator_adaptor(const scoped_allocator_adaptor& other) - : base_type(other.base()) - {} - - //! Effects: move constructs each allocator within the adaptor with - //! the corresponding allocator from other. - scoped_allocator_adaptor(BOOST_RV_REF(scoped_allocator_adaptor) other) - : base_type(::boost::move(other.base())) - {} - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! Requires: OuterAlloc shall be constructible from OuterA2. - //! - //! Effects: initializes the OuterAlloc base class with boost::forward(outerAlloc) and inner - //! with innerAllocs...(hence recursively initializing each allocator within the adaptor with the - //! corresponding allocator from the argument list). - template - scoped_allocator_adaptor(BOOST_FWD_REF(OuterA2) outerAlloc, const InnerAllocs & ...innerAllocs) - : base_type(::boost::forward(outerAlloc), innerAllocs...) - {} - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - scoped_allocator_adaptor(BOOST_FWD_REF(OuterA2) outerAlloc \ - BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_CONST_REF_PARAM_LIST_Q, _)) \ - : base_type(::boost::forward(outerAlloc) \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, q) \ - ) \ - {} \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! Requires: OuterAlloc shall be constructible from OuterA2. - //! - //! Effects: initializes each allocator within the adaptor with the corresponding allocator from other. - template - scoped_allocator_adaptor(const scoped_allocator_adaptor &other) - : base_type(other.base()) - {} - - //! Requires: OuterAlloc shall be constructible from OuterA2. - //! - //! Effects: initializes each allocator within the adaptor with the corresponding allocator - //! rvalue from other. - template - scoped_allocator_adaptor(BOOST_RV_REF_BEG scoped_allocator_adaptor BOOST_RV_REF_END other) - : base_type(::boost::move(other.base())) - {} - - scoped_allocator_adaptor &operator=(BOOST_COPY_ASSIGN_REF(scoped_allocator_adaptor) other) - { return static_cast(base_type::operator=(static_cast(other))); } - - scoped_allocator_adaptor &operator=(BOOST_RV_REF(scoped_allocator_adaptor) other) - { return static_cast(base_type::operator=(boost::move(static_cast(other)))); } - - #ifdef BOOST_CONTAINER_DOXYGEN_INVOKED - //! Effects: swaps *this with r. - //! - void swap(scoped_allocator_adaptor &r); - - //! Effects: swaps *this with r. - //! - friend void swap(scoped_allocator_adaptor &l, scoped_allocator_adaptor &r); - - //! Returns: - //! `static_cast(*this)`. - outer_allocator_type & outer_allocator(); - - //! Returns: - //! `static_cast(*this)`. - const outer_allocator_type &outer_allocator() const; - - //! Returns: - //! *this if `sizeof...(InnerAllocs)` is zero; otherwise, inner. - inner_allocator_type& inner_allocator(); - - //! Returns: - //! *this if `sizeof...(InnerAllocs)` is zero; otherwise, inner. - inner_allocator_type const& inner_allocator() const; - - #endif //BOOST_CONTAINER_DOXYGEN_INVOKED - - //! Returns: - //! `allocator_traits::max_size(outer_allocator())`. - size_type max_size() const - { - return outer_traits_type::max_size(this->outer_allocator()); - } - - //! Effects: - //! calls `OUTERMOST_ALLOC_TRAITS(*this)::destroy(OUTERMOST(*this), p)`. - template - void destroy(T* p) - { - allocator_traits::type> - ::destroy(get_outermost_allocator(this->outer_allocator()), p); - } - - //! Returns: - //! `allocator_traits::allocate(outer_allocator(), n)`. - pointer allocate(size_type n) - { - return outer_traits_type::allocate(this->outer_allocator(), n); - } - - //! Returns: - //! `allocator_traits::allocate(outer_allocator(), n, hint)`. - pointer allocate(size_type n, const_void_pointer hint) - { - return outer_traits_type::allocate(this->outer_allocator(), n, hint); - } - - //! Effects: - //! `allocator_traits::deallocate(outer_allocator(), p, n)`. - void deallocate(pointer p, size_type n) - { - outer_traits_type::deallocate(this->outer_allocator(), p, n); - } - - #ifdef BOOST_CONTAINER_DOXYGEN_INVOKED - //! Returns: Allocator new scoped_allocator_adaptor object where each allocator - //! A in the adaptor is initialized from the result of calling - //! `allocator_traits::select_on_container_copy_construction()` on - //! the corresponding allocator in *this. - scoped_allocator_adaptor select_on_container_copy_construction() const; - #endif //BOOST_CONTAINER_DOXYGEN_INVOKED - - /// @cond - base_type &base() { return *this; } - - const base_type &base() const { return *this; } - /// @endcond - - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //! Effects: - //! 1) If `uses_allocator::value` is false calls - //! `OUTERMOST_ALLOC_TRAITS(*this)::construct - //! (OUTERMOST(*this), p, std::forward(args)...)`. - //! - //! 2) Otherwise, if `uses_allocator::value` is true and - //! `is_constructible::value` is true, calls - //! `OUTERMOST_ALLOC_TRAITS(*this)::construct(OUTERMOST(*this), p, allocator_arg, - //! inner_allocator(), std::forward(args)...)`. - //! - //! [Note: In compilers without advanced decltype SFINAE support, `is_constructible` can't - //! be implemented so that condition will be replaced by - //! constructible_with_allocator_prefix::value. -end note] - //! - //! 3) Otherwise, if uses_allocator::value is true and - //! `is_constructible::value` is true, calls - //! `OUTERMOST_ALLOC_TRAITS(*this)::construct(OUTERMOST(*this), p, - //! std::forward(args)..., inner_allocator())`. - //! - //! [Note: In compilers without advanced decltype SFINAE support, `is_constructible` can't be - //! implemented so that condition will be replaced by - //! `constructible_with_allocator_suffix::value`. -end note] - //! - //! 4) Otherwise, the program is ill-formed. - //! - //! [Note: An error will result if `uses_allocator` evaluates - //! to true but the specific constructor does not take an allocator. This definition prevents a silent - //! failure to pass an inner allocator to a contained element. -end note] - template < typename T, class ...Args> - #if defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - void - #else - typename container_detail::enable_if_c::value, void>::type - #endif - construct(T* p, BOOST_FWD_REF(Args)...args) - { - container_detail::dispatch_uses_allocator - ( uses_allocator() - , get_outermost_allocator(this->outer_allocator()) - , this->inner_allocator() - , p, ::boost::forward(args)...); - } - - #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - //Disable this overload if the first argument is pair as some compilers have - //overload selection problems when the first parameter is a pair. - #define BOOST_PP_LOCAL_MACRO(n) \ - template < typename T \ - BOOST_PP_ENUM_TRAILING_PARAMS(n, class P) \ - > \ - typename container_detail::enable_if_c::value, void>::type \ - construct(T* p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_LIST, _)) \ - { \ - container_detail::dispatch_uses_allocator \ - ( uses_allocator() \ - , get_outermost_allocator(this->outer_allocator()) \ - , this->inner_allocator() \ - , p BOOST_PP_ENUM_TRAILING(n, BOOST_CONTAINER_PP_PARAM_FORWARD, _)); \ - } \ - //! - #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) - #include BOOST_PP_LOCAL_ITERATE() - - #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - - template - void construct(std::pair* p) - { this->construct_pair(p); } - - template - void construct(container_detail::pair* p) - { this->construct_pair(p); } - - template - void construct(std::pair* p, BOOST_FWD_REF(U) x, BOOST_FWD_REF(V) y) - { this->construct_pair(p, ::boost::forward(x), ::boost::forward(y)); } - - template - void construct(container_detail::pair* p, BOOST_FWD_REF(U) x, BOOST_FWD_REF(V) y) - { this->construct_pair(p, ::boost::forward(x), ::boost::forward(y)); } - - template - void construct(std::pair* p, const std::pair& x) - { this->construct_pair(p, x); } - - template - void construct( container_detail::pair* p - , const container_detail::pair& x) - { this->construct_pair(p, x); } - - template - void construct( std::pair* p - , BOOST_RV_REF_BEG std::pair BOOST_RV_REF_END x) - { this->construct_pair(p, x); } - - template - void construct( container_detail::pair* p - , BOOST_RV_REF_BEG container_detail::pair BOOST_RV_REF_END x) - { this->construct_pair(p, x); } - - /// @cond - private: - template - void construct_pair(Pair* p) - { - this->construct(container_detail::addressof(p->first)); - BOOST_TRY{ - this->construct(container_detail::addressof(p->second)); - } - BOOST_CATCH(...){ - this->destroy(container_detail::addressof(p->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - template - void construct_pair(Pair* p, BOOST_FWD_REF(U) x, BOOST_FWD_REF(V) y) - { - this->construct(container_detail::addressof(p->first), ::boost::forward(x)); - BOOST_TRY{ - this->construct(container_detail::addressof(p->second), ::boost::forward(y)); - } - BOOST_CATCH(...){ - this->destroy(container_detail::addressof(p->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - template - void construct_pair(Pair* p, const Pair2& pr) - { - this->construct(container_detail::addressof(p->first), pr.first); - BOOST_TRY{ - this->construct(container_detail::addressof(p->second), pr.second); - } - BOOST_CATCH(...){ - this->destroy(container_detail::addressof(p->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - template - void construct_pair(Pair* p, BOOST_RV_REF(Pair2) pr) - { - this->construct(container_detail::addressof(p->first), ::boost::move(pr.first)); - BOOST_TRY{ - this->construct(container_detail::addressof(p->second), ::boost::move(pr.second)); - } - BOOST_CATCH(...){ - this->destroy(container_detail::addressof(p->first)); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - //template - //void construct(pair* p, piecewise_construct_t, tuple x, tuple y); - - public: - //Internal function - template - scoped_allocator_adaptor(internal_type_t, BOOST_FWD_REF(OuterA2) outer, const inner_allocator_type& inner) - : base_type(internal_type_t(), ::boost::forward(outer), inner) - {} - - /// @endcond -}; - -template -inline bool operator==( - const scoped_allocator_adaptor& a, - const scoped_allocator_adaptor& b) -{ - #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) - const bool has_zero_inner = sizeof...(InnerAllocs) == 0u; - #else - const bool has_zero_inner = - boost::container::container_detail::is_same - ::value; - #endif - - return a.outer_allocator() == b.outer_allocator() - && (has_zero_inner || a.inner_allocator() == b.inner_allocator()); -} - -template -inline bool operator!=( - const scoped_allocator_adaptor& a, - const scoped_allocator_adaptor& b) -{ - return ! (a == b); -} - -}} // namespace boost { namespace container { - -#include - -#endif // BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator_fwd.hpp deleted file mode 100644 index 4c066b0a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/scoped_allocator_fwd.hpp +++ /dev/null @@ -1,83 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_FWD_HPP -#define BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_FWD_HPP - -#if defined(_MSC_VER) -# pragma once -#endif - -#include -#include - -#if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) -#include -#include -#endif - -namespace boost { namespace container { - -///@cond - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - - template - class scoped_allocator_adaptor; - - #else // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - - template - class scoped_allocator_adaptor; - - template - class scoped_allocator_adaptor; - - #endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) - - -#else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - -template -class scoped_allocator_adaptor; - -#endif - -///@endcond - -//! The allocator_arg_t struct is an empty structure type used as a unique type to -//! disambiguate constructor and function overloading. Specifically, several types -//! have constructors with allocator_arg_t as the first argument, immediately followed -//! by an argument of a type that satisfies the Allocator requirements -struct allocator_arg_t{}; - -//! A instance of type allocator_arg_t -//! -static const allocator_arg_t allocator_arg = allocator_arg_t(); - -template -struct constructible_with_allocator_suffix; - -template -struct constructible_with_allocator_prefix; - -template -struct uses_allocator; - -}} // namespace boost { namespace container { - -#include - -#endif // BOOST_CONTAINER_ALLOCATOR_SCOPED_ALLOCATOR_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/container/throw_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/container/throw_exception.hpp deleted file mode 100644 index 7c821c0b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/container/throw_exception.hpp +++ /dev/null @@ -1,110 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/container for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_CONTAINER_THROW_EXCEPTION_HPP -#define BOOST_CONTAINER_THROW_EXCEPTION_HPP - -#include -#include - -#if defined(_MSC_VER) -# pragma once -#endif - -#ifndef BOOST_NO_EXCEPTIONS - #include //for std exception types - #include //for std::bad_alloc -#else - #include - #include //for std::abort -#endif - -namespace boost { -namespace container { - -#if defined(BOOST_CONTAINER_USER_DEFINED_THROW_CALLBACKS) - //The user must provide definitions for the following functions - - void throw_bad_alloc(); - - void throw_out_of_range(const char* str); - - void throw_length_error(const char* str); - - void throw_logic_error(const char* str); - - void throw_runtime_error(const char* str); - -#elif defined(BOOST_NO_EXCEPTIONS) - - inline void throw_bad_alloc() - { - BOOST_ASSERT(!"boost::container bad_alloc thrown"); - std::abort(); - } - - inline void throw_out_of_range(const char* str) - { - BOOST_ASSERT_MSG(!"boost::container out_of_range thrown", str); - std::abort(); - } - - inline void throw_length_error(const char* str) - { - BOOST_ASSERT_MSG(!"boost::container length_error thrown", str); - std::abort(); - } - - inline void throw_logic_error(const char* str) - { - BOOST_ASSERT_MSG(!"boost::container logic_error thrown", str); - std::abort(); - } - - inline void throw_runtime_error(const char* str) - { - BOOST_ASSERT_MSG(!"boost::container runtime_error thrown", str); - std::abort(); - } - -#else //defined(BOOST_NO_EXCEPTIONS) - - inline void throw_bad_alloc() - { - throw std::bad_alloc(); - } - - inline void throw_out_of_range(const char* str) - { - throw std::out_of_range(str); - } - - inline void throw_length_error(const char* str) - { - throw std::length_error(str); - } - - inline void throw_logic_error(const char* str) - { - throw std::logic_error(str); - } - - inline void throw_runtime_error(const char* str) - { - throw std::runtime_error(str); - } - -#endif - -}} //namespace boost { namespace container { - -#include - -#endif //#ifndef BOOST_CONTAINER_THROW_EXCEPTION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/cregex.hpp b/third_party/ycmd/cpp/BoostParts/boost/cregex.hpp deleted file mode 100644 index b7a918eb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/cregex.hpp +++ /dev/null @@ -1,39 +0,0 @@ -/* - * - * Copyright (c) 1998-2002 - * John Maddock - * - * Use, modification and distribution are subject to the - * Boost Software License, Version 1.0. (See accompanying file - * LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - * - */ - - /* - * LOCATION: see http://www.boost.org/libs/regex for most recent version. - * FILE cregex.cpp - * VERSION see - * DESCRIPTION: Declares POSIX API functions - * + boost::RegEx high level wrapper. - */ - -#ifndef BOOST_RE_CREGEX_HPP -#define BOOST_RE_CREGEX_HPP - -#ifndef BOOST_REGEX_CONFIG_HPP -#include -#endif - -#include - -#endif /* include guard */ - - - - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/cstdint.hpp b/third_party/ycmd/cpp/BoostParts/boost/cstdint.hpp deleted file mode 100644 index 98faeae0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/cstdint.hpp +++ /dev/null @@ -1,545 +0,0 @@ -// boost cstdint.hpp header file ------------------------------------------// - -// (C) Copyright Beman Dawes 1999. -// (C) Copyright Jens Mauer 2001 -// (C) Copyright John Maddock 2001 -// Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/integer for documentation. - -// Revision History -// 31 Oct 01 use BOOST_HAS_LONG_LONG to check for "long long" (Jens M.) -// 16 Apr 01 check LONGLONG_MAX when looking for "long long" (Jens Maurer) -// 23 Jan 01 prefer "long" over "int" for int32_t and intmax_t (Jens Maurer) -// 12 Nov 00 Merged (Jens Maurer) -// 23 Sep 00 Added INTXX_C macro support (John Maddock). -// 22 Sep 00 Better 64-bit support (John Maddock) -// 29 Jun 00 Reimplement to avoid including stdint.h within namespace boost -// 8 Aug 99 Initial version (Beman Dawes) - - -#ifndef BOOST_CSTDINT_HPP -#define BOOST_CSTDINT_HPP - -// -// Since we always define the INT#_C macros as per C++0x, -// define __STDC_CONSTANT_MACROS so that does the right -// thing if possible, and so that the user knows that the macros -// are actually defined as per C99. -// -#ifndef __STDC_CONSTANT_MACROS -# define __STDC_CONSTANT_MACROS -#endif - -#include - -// -// Note that GLIBC is a bit inconsistent about whether int64_t is defined or not -// depending upon what headers happen to have been included first... -// so we disable use of stdint.h when GLIBC does not define __GLIBC_HAVE_LONG_LONG. -// See https://svn.boost.org/trac/boost/ticket/3548 and http://sources.redhat.com/bugzilla/show_bug.cgi?id=10990 -// -#if defined(BOOST_HAS_STDINT_H) \ - && (!defined(__GLIBC__) \ - || defined(__GLIBC_HAVE_LONG_LONG) \ - || (defined(__GLIBC__) && ((__GLIBC__ > 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ >= 17))))) - -// The following #include is an implementation artifact; not part of interface. -# ifdef __hpux -// HP-UX has a vaguely nice in a non-standard location -# include -# ifdef __STDC_32_MODE__ - // this is triggered with GCC, because it defines __cplusplus < 199707L -# define BOOST_NO_INT64_T -# endif -# elif defined(__FreeBSD__) || defined(__IBMCPP__) || defined(_AIX) -# include -# else -# include - -// There is a bug in Cygwin two _C macros -# if defined(__STDC_CONSTANT_MACROS) && defined(__CYGWIN__) -# undef INTMAX_C -# undef UINTMAX_C -# define INTMAX_C(c) c##LL -# define UINTMAX_C(c) c##ULL -# endif - -# endif - -#ifdef __QNX__ - -// QNX (Dinkumware stdlib) defines these as non-standard names. -// Reflect to the standard names. - -typedef ::intleast8_t int_least8_t; -typedef ::intfast8_t int_fast8_t; -typedef ::uintleast8_t uint_least8_t; -typedef ::uintfast8_t uint_fast8_t; - -typedef ::intleast16_t int_least16_t; -typedef ::intfast16_t int_fast16_t; -typedef ::uintleast16_t uint_least16_t; -typedef ::uintfast16_t uint_fast16_t; - -typedef ::intleast32_t int_least32_t; -typedef ::intfast32_t int_fast32_t; -typedef ::uintleast32_t uint_least32_t; -typedef ::uintfast32_t uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - -typedef ::intleast64_t int_least64_t; -typedef ::intfast64_t int_fast64_t; -typedef ::uintleast64_t uint_least64_t; -typedef ::uintfast64_t uint_fast64_t; - -# endif - -#endif - -namespace boost -{ - - using ::int8_t; - using ::int_least8_t; - using ::int_fast8_t; - using ::uint8_t; - using ::uint_least8_t; - using ::uint_fast8_t; - - using ::int16_t; - using ::int_least16_t; - using ::int_fast16_t; - using ::uint16_t; - using ::uint_least16_t; - using ::uint_fast16_t; - - using ::int32_t; - using ::int_least32_t; - using ::int_fast32_t; - using ::uint32_t; - using ::uint_least32_t; - using ::uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - - using ::int64_t; - using ::int_least64_t; - using ::int_fast64_t; - using ::uint64_t; - using ::uint_least64_t; - using ::uint_fast64_t; - -# endif - - using ::intmax_t; - using ::uintmax_t; - -} // namespace boost - -#elif defined(__FreeBSD__) && (__FreeBSD__ <= 4) || defined(__osf__) || defined(__VMS) -// FreeBSD and Tru64 have an that contains much of what we need. -# include - -namespace boost { - - using ::int8_t; - typedef int8_t int_least8_t; - typedef int8_t int_fast8_t; - using ::uint8_t; - typedef uint8_t uint_least8_t; - typedef uint8_t uint_fast8_t; - - using ::int16_t; - typedef int16_t int_least16_t; - typedef int16_t int_fast16_t; - using ::uint16_t; - typedef uint16_t uint_least16_t; - typedef uint16_t uint_fast16_t; - - using ::int32_t; - typedef int32_t int_least32_t; - typedef int32_t int_fast32_t; - using ::uint32_t; - typedef uint32_t uint_least32_t; - typedef uint32_t uint_fast32_t; - -# ifndef BOOST_NO_INT64_T - - using ::int64_t; - typedef int64_t int_least64_t; - typedef int64_t int_fast64_t; - using ::uint64_t; - typedef uint64_t uint_least64_t; - typedef uint64_t uint_fast64_t; - - typedef int64_t intmax_t; - typedef uint64_t uintmax_t; - -# else - - typedef int32_t intmax_t; - typedef uint32_t uintmax_t; - -# endif - -} // namespace boost - -#else // BOOST_HAS_STDINT_H - -# include // implementation artifact; not part of interface -# include // needed for limits macros - - -namespace boost -{ - -// These are fairly safe guesses for some 16-bit, and most 32-bit and 64-bit -// platforms. For other systems, they will have to be hand tailored. -// -// Because the fast types are assumed to be the same as the undecorated types, -// it may be possible to hand tailor a more efficient implementation. Such -// an optimization may be illusionary; on the Intel x86-family 386 on, for -// example, byte arithmetic and load/stores are as fast as "int" sized ones. - -// 8-bit types ------------------------------------------------------------// - -# if UCHAR_MAX == 0xff - typedef signed char int8_t; - typedef signed char int_least8_t; - typedef signed char int_fast8_t; - typedef unsigned char uint8_t; - typedef unsigned char uint_least8_t; - typedef unsigned char uint_fast8_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 16-bit types -----------------------------------------------------------// - -# if USHRT_MAX == 0xffff -# if defined(__crayx1) - // The Cray X1 has a 16-bit short, however it is not recommend - // for use in performance critical code. - typedef short int16_t; - typedef short int_least16_t; - typedef int int_fast16_t; - typedef unsigned short uint16_t; - typedef unsigned short uint_least16_t; - typedef unsigned int uint_fast16_t; -# else - typedef short int16_t; - typedef short int_least16_t; - typedef short int_fast16_t; - typedef unsigned short uint16_t; - typedef unsigned short uint_least16_t; - typedef unsigned short uint_fast16_t; -# endif -# elif (USHRT_MAX == 0xffffffff) && defined(__MTA__) - // On MTA / XMT short is 32 bits unless the -short16 compiler flag is specified - // MTA / XMT does support the following non-standard integer types - typedef __short16 int16_t; - typedef __short16 int_least16_t; - typedef __short16 int_fast16_t; - typedef unsigned __short16 uint16_t; - typedef unsigned __short16 uint_least16_t; - typedef unsigned __short16 uint_fast16_t; -# elif (USHRT_MAX == 0xffffffff) && defined(CRAY) - // no 16-bit types on Cray: - typedef short int_least16_t; - typedef short int_fast16_t; - typedef unsigned short uint_least16_t; - typedef unsigned short uint_fast16_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 32-bit types -----------------------------------------------------------// - -# if UINT_MAX == 0xffffffff - typedef int int32_t; - typedef int int_least32_t; - typedef int int_fast32_t; - typedef unsigned int uint32_t; - typedef unsigned int uint_least32_t; - typedef unsigned int uint_fast32_t; -# elif (USHRT_MAX == 0xffffffff) - typedef short int32_t; - typedef short int_least32_t; - typedef short int_fast32_t; - typedef unsigned short uint32_t; - typedef unsigned short uint_least32_t; - typedef unsigned short uint_fast32_t; -# elif ULONG_MAX == 0xffffffff - typedef long int32_t; - typedef long int_least32_t; - typedef long int_fast32_t; - typedef unsigned long uint32_t; - typedef unsigned long uint_least32_t; - typedef unsigned long uint_fast32_t; -# elif (UINT_MAX == 0xffffffffffffffff) && defined(__MTA__) - // Integers are 64 bits on the MTA / XMT - typedef __int32 int32_t; - typedef __int32 int_least32_t; - typedef __int32 int_fast32_t; - typedef unsigned __int32 uint32_t; - typedef unsigned __int32 uint_least32_t; - typedef unsigned __int32 uint_fast32_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -// 64-bit types + intmax_t and uintmax_t ----------------------------------// - -# if defined(BOOST_HAS_LONG_LONG) && \ - !defined(BOOST_MSVC) && !defined(__BORLANDC__) && \ - (!defined(__GLIBCPP__) || defined(_GLIBCPP_USE_LONG_LONG)) && \ - (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX)) -# if defined(__hpux) - // HP-UX's value of ULONG_LONG_MAX is unusable in preprocessor expressions -# elif (defined(ULLONG_MAX) && ULLONG_MAX == 18446744073709551615ULL) || (defined(ULONG_LONG_MAX) && ULONG_LONG_MAX == 18446744073709551615ULL) || (defined(ULONGLONG_MAX) && ULONGLONG_MAX == 18446744073709551615ULL) - // 2**64 - 1 -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - - typedef ::boost::long_long_type intmax_t; - typedef ::boost::ulong_long_type uintmax_t; - typedef ::boost::long_long_type int64_t; - typedef ::boost::long_long_type int_least64_t; - typedef ::boost::long_long_type int_fast64_t; - typedef ::boost::ulong_long_type uint64_t; - typedef ::boost::ulong_long_type uint_least64_t; - typedef ::boost::ulong_long_type uint_fast64_t; - -# elif ULONG_MAX != 0xffffffff - -# if ULONG_MAX == 18446744073709551615 // 2**64 - 1 - typedef long intmax_t; - typedef unsigned long uintmax_t; - typedef long int64_t; - typedef long int_least64_t; - typedef long int_fast64_t; - typedef unsigned long uint64_t; - typedef unsigned long uint_least64_t; - typedef unsigned long uint_fast64_t; -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif defined(__GNUC__) && defined(BOOST_HAS_LONG_LONG) - __extension__ typedef long long intmax_t; - __extension__ typedef unsigned long long uintmax_t; - __extension__ typedef long long int64_t; - __extension__ typedef long long int_least64_t; - __extension__ typedef long long int_fast64_t; - __extension__ typedef unsigned long long uint64_t; - __extension__ typedef unsigned long long uint_least64_t; - __extension__ typedef unsigned long long uint_fast64_t; -# elif defined(BOOST_HAS_MS_INT64) - // - // we have Borland/Intel/Microsoft __int64: - // - typedef __int64 intmax_t; - typedef unsigned __int64 uintmax_t; - typedef __int64 int64_t; - typedef __int64 int_least64_t; - typedef __int64 int_fast64_t; - typedef unsigned __int64 uint64_t; - typedef unsigned __int64 uint_least64_t; - typedef unsigned __int64 uint_fast64_t; -# else // assume no 64-bit integers -# define BOOST_NO_INT64_T - typedef int32_t intmax_t; - typedef uint32_t uintmax_t; -# endif - -} // namespace boost - - -#endif // BOOST_HAS_STDINT_H - -// intptr_t/uintptr_t are defined separately because they are optional and not universally available -#if defined(BOOST_WINDOWS) && !defined(_WIN32_WCE) && !defined(BOOST_HAS_STDINT_H) -// Older MSVC don't have stdint.h and have intptr_t/uintptr_t defined in stddef.h -#include -#endif - -// PGI seems to not support intptr_t/uintptr_t properly. BOOST_HAS_STDINT_H is not defined for this compiler by Boost.Config. -#if !defined(__PGIC__) - -#if (defined(BOOST_WINDOWS) && !defined(_WIN32_WCE)) \ - || (defined(_XOPEN_UNIX) && (_XOPEN_UNIX+0 > 0) && !defined(__UCLIBC__)) \ - || defined(__CYGWIN__) \ - || defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__) \ - || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) - -namespace boost { - using ::intptr_t; - using ::uintptr_t; -} -#define BOOST_HAS_INTPTR_T - -// Clang pretends to be GCC, so it'll match this condition -#elif defined(__GNUC__) && defined(__INTPTR_TYPE__) && defined(__UINTPTR_TYPE__) - -namespace boost { - typedef __INTPTR_TYPE__ intptr_t; - typedef __UINTPTR_TYPE__ uintptr_t; -} -#define BOOST_HAS_INTPTR_T - -#endif - -#endif // !defined(__PGIC__) - -#endif // BOOST_CSTDINT_HPP - - -/**************************************************** - -Macro definition section: - -Added 23rd September 2000 (John Maddock). -Modified 11th September 2001 to be excluded when -BOOST_HAS_STDINT_H is defined (John Maddock). -Modified 11th Dec 2009 to always define the -INT#_C macros if they're not already defined (John Maddock). - -******************************************************/ - -#if !defined(BOOST__STDC_CONSTANT_MACROS_DEFINED) && \ - (!defined(INT8_C) || !defined(INT16_C) || !defined(INT32_C) || !defined(INT64_C)) -// -// For the following code we get several warnings along the lines of: -// -// boost/cstdint.hpp:428:35: error: use of C99 long long integer constant -// -// So we declare this a system header to suppress these warnings. -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -#pragma GCC system_header -#endif - -#include -# define BOOST__STDC_CONSTANT_MACROS_DEFINED -# if defined(BOOST_HAS_MS_INT64) -// -// Borland/Intel/Microsoft compilers have width specific suffixes: -// -#ifndef INT8_C -# define INT8_C(value) value##i8 -#endif -#ifndef INT16_C -# define INT16_C(value) value##i16 -#endif -#ifndef INT32_C -# define INT32_C(value) value##i32 -#endif -#ifndef INT64_C -# define INT64_C(value) value##i64 -#endif -# ifdef __BORLANDC__ - // Borland bug: appending ui8 makes the type a signed char -# define UINT8_C(value) static_cast(value##u) -# else -# define UINT8_C(value) value##ui8 -# endif -#ifndef UINT16_C -# define UINT16_C(value) value##ui16 -#endif -#ifndef UINT32_C -# define UINT32_C(value) value##ui32 -#endif -#ifndef UINT64_C -# define UINT64_C(value) value##ui64 -#endif -#ifndef INTMAX_C -# define INTMAX_C(value) value##i64 -# define UINTMAX_C(value) value##ui64 -#endif - -# else -// do it the old fashioned way: - -// 8-bit types ------------------------------------------------------------// - -# if (UCHAR_MAX == 0xff) && !defined(INT8_C) -# define INT8_C(value) static_cast(value) -# define UINT8_C(value) static_cast(value##u) -# endif - -// 16-bit types -----------------------------------------------------------// - -# if (USHRT_MAX == 0xffff) && !defined(INT16_C) -# define INT16_C(value) static_cast(value) -# define UINT16_C(value) static_cast(value##u) -# endif - -// 32-bit types -----------------------------------------------------------// -#ifndef INT32_C -# if (UINT_MAX == 0xffffffff) -# define INT32_C(value) value -# define UINT32_C(value) value##u -# elif ULONG_MAX == 0xffffffff -# define INT32_C(value) value##L -# define UINT32_C(value) value##uL -# endif -#endif - -// 64-bit types + intmax_t and uintmax_t ----------------------------------// -#ifndef INT64_C -# if defined(BOOST_HAS_LONG_LONG) && \ - (defined(ULLONG_MAX) || defined(ULONG_LONG_MAX) || defined(ULONGLONG_MAX) || defined(_LLONG_MAX)) - -# if defined(__hpux) - // HP-UX's value of ULONG_LONG_MAX is unusable in preprocessor expressions -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# elif (defined(ULLONG_MAX) && ULLONG_MAX == 18446744073709551615ULL) || \ - (defined(ULONG_LONG_MAX) && ULONG_LONG_MAX == 18446744073709551615ULL) || \ - (defined(ULONGLONG_MAX) && ULONGLONG_MAX == 18446744073709551615ULL) || \ - (defined(_LLONG_MAX) && _LLONG_MAX == 18446744073709551615ULL) - -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif ULONG_MAX != 0xffffffff - -# if ULONG_MAX == 18446744073709551615U // 2**64 - 1 -# define INT64_C(value) value##L -# define UINT64_C(value) value##uL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# elif defined(BOOST_HAS_LONG_LONG) - // Usual macros not defined, work things out for ourselves: -# if(~0uLL == 18446744073709551615ULL) -# define INT64_C(value) value##LL -# define UINT64_C(value) value##uLL -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif -# else -# error defaults not correct; you must hand modify boost/cstdint.hpp -# endif - -# ifdef BOOST_NO_INT64_T -# define INTMAX_C(value) INT32_C(value) -# define UINTMAX_C(value) UINT32_C(value) -# else -# define INTMAX_C(value) INT64_C(value) -# define UINTMAX_C(value) UINT64_C(value) -# endif -#endif -# endif // Borland/Microsoft specific width suffixes - -#endif // INT#_C macros. - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/cstdlib.hpp b/third_party/ycmd/cpp/BoostParts/boost/cstdlib.hpp deleted file mode 100644 index 63221463..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/cstdlib.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// boost/cstdlib.hpp header ------------------------------------------------// - -// Copyright Beman Dawes 2001. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/utility/cstdlib.html for documentation. - -// Revision History -// 26 Feb 01 Initial version (Beman Dawes) - -#ifndef BOOST_CSTDLIB_HPP -#define BOOST_CSTDLIB_HPP - -#include - -namespace boost -{ - // The intent is to propose the following for addition to namespace std - // in the C++ Standard Library, and to then deprecate EXIT_SUCCESS and - // EXIT_FAILURE. As an implementation detail, this header defines the - // new constants in terms of EXIT_SUCCESS and EXIT_FAILURE. In a new - // standard, the constants would be implementation-defined, although it - // might be worthwhile to "suggest" (which a standard is allowed to do) - // values of 0 and 1 respectively. - - // Rationale for having multiple failure values: some environments may - // wish to distinguish between different classes of errors. - // Rationale for choice of values: programs often use values < 100 for - // their own error reporting. Values > 255 are sometimes reserved for - // system detected errors. 200/201 were suggested to minimize conflict. - - const int exit_success = EXIT_SUCCESS; // implementation-defined value - const int exit_failure = EXIT_FAILURE; // implementation-defined value - const int exit_exception_failure = 200; // otherwise uncaught exception - const int exit_test_failure = 201; // report_error or - // report_critical_error called. -} - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/current_function.hpp b/third_party/ycmd/cpp/BoostParts/boost/current_function.hpp deleted file mode 100644 index cb36e35c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/current_function.hpp +++ /dev/null @@ -1,68 +0,0 @@ -#ifndef BOOST_CURRENT_FUNCTION_HPP_INCLUDED -#define BOOST_CURRENT_FUNCTION_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/current_function.hpp - BOOST_CURRENT_FUNCTION -// -// Copyright (c) 2002 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// http://www.boost.org/libs/utility/current_function.html -// - -namespace boost -{ - -namespace detail -{ - -inline void current_function_helper() -{ - -#if defined(__GNUC__) || (defined(__MWERKS__) && (__MWERKS__ >= 0x3000)) || (defined(__ICC) && (__ICC >= 600)) || defined(__ghs__) - -# define BOOST_CURRENT_FUNCTION __PRETTY_FUNCTION__ - -#elif defined(__DMC__) && (__DMC__ >= 0x810) - -# define BOOST_CURRENT_FUNCTION __PRETTY_FUNCTION__ - -#elif defined(__FUNCSIG__) - -# define BOOST_CURRENT_FUNCTION __FUNCSIG__ - -#elif (defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 600)) || (defined(__IBMCPP__) && (__IBMCPP__ >= 500)) - -# define BOOST_CURRENT_FUNCTION __FUNCTION__ - -#elif defined(__BORLANDC__) && (__BORLANDC__ >= 0x550) - -# define BOOST_CURRENT_FUNCTION __FUNC__ - -#elif defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901) - -# define BOOST_CURRENT_FUNCTION __func__ - -#else - -# define BOOST_CURRENT_FUNCTION "(unknown)" - -#endif - -} - -} // namespace detail - -} // namespace boost - -#endif // #ifndef BOOST_CURRENT_FUNCTION_HPP_INCLUDED - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/adjust_functors.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/adjust_functors.hpp deleted file mode 100644 index dde8ca85..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/adjust_functors.hpp +++ /dev/null @@ -1,178 +0,0 @@ -#ifndef _DATE_TIME_ADJUST_FUNCTORS_HPP___ -#define _DATE_TIME_ADJUST_FUNCTORS_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/date.hpp" -#include "boost/date_time/wrapping_int.hpp" - -namespace boost { -namespace date_time { - - - //! Functor to iterate a fixed number of days - template - class day_functor - { - public: - typedef typename date_type::duration_type duration_type; - day_functor(int f) : f_(f) {} - duration_type get_offset(const date_type& d) const - { - // why is 'd' a parameter??? - // fix compiler warnings - d.year(); - return duration_type(f_); - } - duration_type get_neg_offset(const date_type& d) const - { - // fix compiler warnings - d.year(); - return duration_type(-f_); - } - private: - int f_; - }; - - - //! Provides calculation to find next nth month given a date - /*! This adjustment function provides the logic for 'month-based' - * advancement on a ymd based calendar. The policy it uses - * to handle the non existant end of month days is to back - * up to the last day of the month. Also, if the starting - * date is the last day of a month, this functor will attempt - * to adjust to the end of the month. - - */ - template - class month_functor - { - public: - typedef typename date_type::duration_type duration_type; - typedef typename date_type::calendar_type cal_type; - typedef typename cal_type::ymd_type ymd_type; - typedef typename cal_type::day_type day_type; - - month_functor(int f) : f_(f), origDayOfMonth_(0) {} - duration_type get_offset(const date_type& d) const - { - ymd_type ymd(d.year_month_day()); - if (origDayOfMonth_ == 0) { - origDayOfMonth_ = ymd.day; - day_type endOfMonthDay(cal_type::end_of_month_day(ymd.year,ymd.month)); - if (endOfMonthDay == ymd.day) { - origDayOfMonth_ = -1; //force the value to the end of month - } - } - typedef date_time::wrapping_int2 wrap_int2; - typedef typename wrap_int2::int_type int_type; - wrap_int2 wi(ymd.month); - //calc the year wrap around, add() returns 0 or 1 if wrapped - int_type year = wi.add(static_cast(f_)); - year = static_cast(year + ymd.year); //calculate resulting year -// std::cout << "trace wi: " << wi.as_int() << std::endl; -// std::cout << "trace year: " << year << std::endl; - //find the last day for the new month - day_type resultingEndOfMonthDay(cal_type::end_of_month_day(year, wi.as_int())); - //original was the end of month -- force to last day of month - if (origDayOfMonth_ == -1) { - return date_type(year, wi.as_int(), resultingEndOfMonthDay) - d; - } - day_type dayOfMonth = origDayOfMonth_; - if (dayOfMonth > resultingEndOfMonthDay) { - dayOfMonth = resultingEndOfMonthDay; - } - return date_type(year, wi.as_int(), dayOfMonth) - d; - } - //! Returns a negative duration_type - duration_type get_neg_offset(const date_type& d) const - { - ymd_type ymd(d.year_month_day()); - if (origDayOfMonth_ == 0) { - origDayOfMonth_ = ymd.day; - day_type endOfMonthDay(cal_type::end_of_month_day(ymd.year,ymd.month)); - if (endOfMonthDay == ymd.day) { - origDayOfMonth_ = -1; //force the value to the end of month - } - } - typedef date_time::wrapping_int2 wrap_int2; - typedef typename wrap_int2::int_type int_type; - wrap_int2 wi(ymd.month); - //calc the year wrap around, add() returns 0 or 1 if wrapped - int_type year = wi.subtract(static_cast(f_)); - year = static_cast(year + ymd.year); //calculate resulting year - //find the last day for the new month - day_type resultingEndOfMonthDay(cal_type::end_of_month_day(year, wi.as_int())); - //original was the end of month -- force to last day of month - if (origDayOfMonth_ == -1) { - return date_type(year, wi.as_int(), resultingEndOfMonthDay) - d; - } - day_type dayOfMonth = origDayOfMonth_; - if (dayOfMonth > resultingEndOfMonthDay) { - dayOfMonth = resultingEndOfMonthDay; - } - return date_type(year, wi.as_int(), dayOfMonth) - d; - } - private: - int f_; - mutable short origDayOfMonth_; - }; - - - //! Functor to iterate a over weeks - template - class week_functor - { - public: - typedef typename date_type::duration_type duration_type; - typedef typename date_type::calendar_type calendar_type; - week_functor(int f) : f_(f) {} - duration_type get_offset(const date_type& d) const - { - // why is 'd' a parameter??? - // fix compiler warnings - d.year(); - return duration_type(f_*calendar_type::days_in_week()); - } - duration_type get_neg_offset(const date_type& d) const - { - // fix compiler warnings - d.year(); - return duration_type(-f_*calendar_type::days_in_week()); - } - private: - int f_; - }; - - //! Functor to iterate by a year adjusting for leap years - template - class year_functor - { - public: - //typedef typename date_type::year_type year_type; - typedef typename date_type::duration_type duration_type; - year_functor(int f) : _mf(f * 12) {} - duration_type get_offset(const date_type& d) const - { - return _mf.get_offset(d); - } - duration_type get_neg_offset(const date_type& d) const - { - return _mf.get_neg_offset(d); - } - private: - month_functor _mf; - }; - - -} }//namespace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/c_time.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/c_time.hpp deleted file mode 100644 index f7e116b2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/c_time.hpp +++ /dev/null @@ -1,123 +0,0 @@ -#ifndef DATE_TIME_C_TIME_HPP___ -#define DATE_TIME_C_TIME_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 09:04:10 -0700 (Sat, 22 Sep 2012) $ - */ - - -/*! @file c_time.hpp - Provide workarounds related to the ctime header -*/ - -#include -#include // to be able to convert from string literals to exceptions -#include -#include -#include - -//Work around libraries that don't put time_t and time in namespace std -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std { using ::time_t; using ::time; using ::localtime; - using ::tm; using ::gmtime; } -#endif // BOOST_NO_STDC_NAMESPACE - -//The following is used to support high precision time clocks -#ifdef BOOST_HAS_GETTIMEOFDAY -#include -#endif - -#ifdef BOOST_HAS_FTIME -#include -#endif - -namespace boost { -namespace date_time { - //! Provides a uniform interface to some 'ctime' functions - /*! Provides a uniform interface to some ctime functions and - * their '_r' counterparts. The '_r' functions require a pointer to a - * user created std::tm struct whereas the regular functions use a - * staticly created struct and return a pointer to that. These wrapper - * functions require the user to create a std::tm struct and send in a - * pointer to it. This struct may be used to store the resulting time. - * The returned pointer may or may not point to this struct, however, - * it will point to the result of the corresponding function. - * All functions do proper checking of the C function results and throw - * exceptions on error. Therefore the functions will never return NULL. - */ - struct c_time { - public: -#if defined(BOOST_DATE_TIME_HAS_REENTRANT_STD_FUNCTIONS) - //! requires a pointer to a user created std::tm struct - inline - static std::tm* localtime(const std::time_t* t, std::tm* result) - { - // localtime_r() not in namespace std??? - #if defined(__VMS) && __INITIAL_POINTER_SIZE == 64 - std::tm tmp; - if(!localtime_r(t,&tmp)) - result = 0; - else - *result = tmp; - #else - result = localtime_r(t, result); - #endif - if (!result) - boost::throw_exception(std::runtime_error("could not convert calendar time to local time")); - return result; - } - //! requires a pointer to a user created std::tm struct - inline - static std::tm* gmtime(const std::time_t* t, std::tm* result) - { - // gmtime_r() not in namespace std??? - #if defined(__VMS) && __INITIAL_POINTER_SIZE == 64 - std::tm tmp; - if(!gmtime_r(t,&tmp)) - result = 0; - else - *result = tmp; - #else - result = gmtime_r(t, result); - #endif - if (!result) - boost::throw_exception(std::runtime_error("could not convert calendar time to UTC time")); - return result; - } -#else // BOOST_HAS_THREADS - -#if (defined(_MSC_VER) && (_MSC_VER >= 1400)) -#pragma warning(push) // preserve warning settings -#pragma warning(disable : 4996) // disable depricated localtime/gmtime warning on vc8 -#endif // _MSC_VER >= 1400 - //! requires a pointer to a user created std::tm struct - inline - static std::tm* localtime(const std::time_t* t, std::tm* result) - { - result = std::localtime(t); - if (!result) - boost::throw_exception(std::runtime_error("could not convert calendar time to local time")); - return result; - } - //! requires a pointer to a user created std::tm struct - inline - static std::tm* gmtime(const std::time_t* t, std::tm* result) - { - result = std::gmtime(t); - if (!result) - boost::throw_exception(std::runtime_error("could not convert calendar time to UTC time")); - return result; - } -#if (defined(_MSC_VER) && (_MSC_VER >= 1400)) -#pragma warning(pop) // restore warnings to previous state -#endif // _MSC_VER >= 1400 - -#endif // BOOST_HAS_THREADS - }; -}} // namespaces - -#endif // DATE_TIME_C_TIME_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/compiler_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/compiler_config.hpp deleted file mode 100644 index 1aa1330f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/compiler_config.hpp +++ /dev/null @@ -1,169 +0,0 @@ -#ifndef DATE_TIME_COMPILER_CONFIG_HPP___ -#define DATE_TIME_COMPILER_CONFIG_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Subject to the Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2011-07-26 10:40:21 -0700 (Tue, 26 Jul 2011) $ - */ - -#include -#include -#include - -// With boost release 1.33, date_time will be using a different, -// more flexible, IO system. This new system is not compatible with -// old compilers. The original date_time IO system remains for those -// compilers. They must define this macro to use the legacy IO. -// (defined(__BORLANDC__) && (__BORLANDC__ <= 0x0581) ) ) && - #if( BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x581) ) \ - || BOOST_WORKAROUND( __GNUC__, < 3) \ - || (BOOST_WORKAROUND( _MSC_VER, <= 1300) ) \ - ) \ - && !defined(USE_DATE_TIME_PRE_1_33_FACET_IO) -# define USE_DATE_TIME_PRE_1_33_FACET_IO -#endif - - -// This file performs some local compiler configurations - -#include //set up locale configurations - -//Set up a configuration parameter for platforms that have -//GetTimeOfDay -#if defined(BOOST_HAS_GETTIMEOFDAY) || defined(BOOST_HAS_FTIME) -#define BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK -#endif - -// To Force no default constructors for date & ptime, un-comment following -//#define DATE_TIME_NO_DEFAULT_CONSTRUCTOR - -// Include extensions to date_duration - comment out to remove this feature -#define BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES -// these extensions are known to cause problems with gcc295 -#if defined(__GNUC__) && (__GNUC__ < 3) -#undef BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES -#endif - -#if (defined(BOOST_NO_INCLASS_MEMBER_INITIALIZATION) || BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x581) ) ) -#define BOOST_DATE_TIME_NO_MEMBER_INIT -#endif - -// include these types before we try to re-define them -#include - -//Define INT64_C for compilers that don't have it -#if (!defined(INT64_C)) -#define INT64_C(value) int64_t(value) -#endif - - -/* Workaround for Borland iterator error. Error was "Cannot convert 'istream *' to 'wistream *' in function istream_iterator<>::istream_iterator() */ -#if defined(__BORLANDC__) && defined(BOOST_BCB_WITH_RW_LIB) -#define BOOST_DATE_TIME_NO_WISTREAM_ITERATOR -#endif - - -// Borland v5.64 does not have the following in std namespace; v5.5.1 does -#if defined(__BORLANDC__) && defined(BOOST_BCB_WITH_STLPORT) -#include -namespace std { - using stlport::tolower; - using stlport::ctype; - using stlport::use_facet; -} -#endif - -// workaround for errors associated with output for date classes -// modifications and input streaming for time classes. -// Compilers affected are: -// gcc295, msvc (neither with STLPort), any borland -// -#if (((defined(__GNUC__) && (__GNUC__ < 3)) || \ - (defined(_MSC_VER) && (_MSC_VER < 1300)) ) && \ - !defined(_STLP_OWN_IOSTREAMS) ) || \ - BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x581) ) -#define BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS -#endif - -// The macro marks up places where compiler complains for missing return statement or -// uninitialized variables after calling to boost::throw_exception. -// BOOST_UNREACHABLE_RETURN doesn't work since even compilers that support -// unreachable statements detection emit such warnings. -#if defined(_MSC_VER) -// Use special MSVC extension to markup unreachable code -# define BOOST_DATE_TIME_UNREACHABLE_EXPRESSION(x) __assume(false) -#elif !defined(BOOST_NO_UNREACHABLE_RETURN_DETECTION) -// Call to a non-returning function should suppress the warning -# if defined(BOOST_NO_STDC_NAMESPACE) -namespace std { - using ::abort; -} -# endif // defined(BOOST_NO_STDC_NAMESPACE) -# define BOOST_DATE_TIME_UNREACHABLE_EXPRESSION(x) std::abort() -#else -// For other poor compilers the specified expression is compiled. Usually, this would be a return statement. -# define BOOST_DATE_TIME_UNREACHABLE_EXPRESSION(x) x -#endif - -/* The following handles the definition of the necessary macros - * for dll building on Win32 platforms. - * - * For code that will be placed in the date_time .dll, - * it must be properly prefixed with BOOST_DATE_TIME_DECL. - * The corresponding .cpp file must have BOOST_DATE_TIME_SOURCE - * defined before including its header. For examples see: - * greg_month.hpp & greg_month.cpp - * - */ - -// we need to import/export our code only if the user has specifically -// asked for it by defining either BOOST_ALL_DYN_LINK if they want all boost -// libraries to be dynamically linked, or BOOST_DATE_TIME_DYN_LINK -// if they want just this one to be dynamically liked: -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_DATE_TIME_DYN_LINK) - // export if this is our own source, otherwise import: -# ifdef BOOST_DATE_TIME_SOURCE -# define BOOST_DATE_TIME_DECL BOOST_SYMBOL_EXPORT -# else -# define BOOST_DATE_TIME_DECL BOOST_SYMBOL_IMPORT -# endif // BOOST_DATE_TIME_SOURCE -#endif // DYN_LINK -// -// if BOOST_WHATEVER_DECL isn't defined yet define it now: -#ifndef BOOST_DATE_TIME_DECL -# define BOOST_DATE_TIME_DECL -#endif - -// -// Automatically link to the correct build variant where possible. -// -#if !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_DATE_TIME_NO_LIB) && !defined(BOOST_DATE_TIME_SOURCE) -// -// Set the name of our library, this will get undef'ed by auto_link.hpp -// once it's done with it: -// -#define BOOST_LIB_NAME boost_date_time -// -// If we're importing code from a dll, then tell auto_link.hpp about it: -// -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_DATE_TIME_DYN_LINK) -# define BOOST_DYN_LINK -#endif -// -// And include the header that does the work: -// -#include -#endif // auto-linking disabled - -#if defined(BOOST_HAS_THREADS) -# if defined(_MSC_VER) || defined(__MWERKS__) || defined(__MINGW32__) || defined(__BORLANDC__) - //no reentrant posix functions (eg: localtime_r) -# elif (!defined(__hpux) || (defined(__hpux) && defined(_REENTRANT))) -# define BOOST_DATE_TIME_HAS_REENTRANT_STD_FUNCTIONS -# endif -#endif - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/constrained_value.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/constrained_value.hpp deleted file mode 100644 index 7338105e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/constrained_value.hpp +++ /dev/null @@ -1,121 +0,0 @@ -#ifndef CONSTRAINED_VALUE_HPP___ -#define CONSTRAINED_VALUE_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include -#include -#include -#include -#include -#include - -namespace boost { - -//! Namespace containing constrained_value template and types -namespace CV { - //! Represent a min or max violation type - enum violation_enum {min_violation, max_violation}; - - //! A template to specify a constrained basic value type - /*! This template provides a quick way to generate - * an integer type with a constrained range. The type - * provides for the ability to specify the min, max, and - * and error handling policy. - * - * value policies - * A class that provides the range limits via the min and - * max functions as well as a function on_error that - * determines how errors are handled. A common strategy - * would be to assert or throw and exception. The on_error - * is passed both the current value and the new value that - * is in error. - * - */ - template - class constrained_value { - public: - typedef typename value_policies::value_type value_type; - // typedef except_type exception_type; - constrained_value(value_type value) : value_((min)()) - { - assign(value); - } - constrained_value& operator=(value_type v) - { - assign(v); - return *this; - } - //! Return the max allowed value (traits method) - static value_type max BOOST_PREVENT_MACRO_SUBSTITUTION () {return (value_policies::max)();} - //! Return the min allowed value (traits method) - static value_type min BOOST_PREVENT_MACRO_SUBSTITUTION () {return (value_policies::min)();} - //! Coerce into the representation type - operator value_type() const {return value_;} - protected: - value_type value_; - private: - void assign(value_type value) - { - //adding 1 below gets rid of a compiler warning which occurs when the - //min_value is 0 and the type is unsigned.... - if (value+1 < (min)()+1) { - value_policies::on_error(value_, value, min_violation); - return; - } - if (value > (max)()) { - value_policies::on_error(value_, value, max_violation); - return; - } - value_ = value; - } -}; - - //! Template to shortcut the constrained_value policy creation process - template - class simple_exception_policy - { - struct exception_wrapper : public exception_type - { - // In order to support throw_exception mechanism in the BOOST_NO_EXCEPTIONS mode, - // we'll have to provide a way to acquire std::exception from the exception being thrown. - // However, we cannot derive from it, since it would make it interceptable by this class, - // which might not be what the user wanted. - operator std::out_of_range () const - { - // TODO: Make the message more descriptive by using arguments to on_error - return std::out_of_range("constrained value boundary has been violated"); - } - }; - - typedef typename mpl::if_< - is_base_of< std::exception, exception_type >, - exception_type, - exception_wrapper - >::type actual_exception_type; - - public: - typedef rep_type value_type; - static rep_type min BOOST_PREVENT_MACRO_SUBSTITUTION () { return min_value; } - static rep_type max BOOST_PREVENT_MACRO_SUBSTITUTION () { return max_value; } - static void on_error(rep_type, rep_type, violation_enum) - { - boost::throw_exception(actual_exception_type()); - } - }; - - - -} } //namespace CV - - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date.hpp deleted file mode 100644 index f77ae29d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date.hpp +++ /dev/null @@ -1,208 +0,0 @@ -#ifndef DATE_TIME_DATE_HPP___ -#define DATE_TIME_DATE_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - -#include -#include -#include - -namespace boost { -namespace date_time { - - //!Representation of timepoint at the one day level resolution. - /*! - The date template represents an interface shell for a date class - that is based on a year-month-day system such as the gregorian - or iso systems. It provides basic operations to enable calculation - and comparisons. - - Theory - - This date representation fundamentally departs from the C tm struct - approach. The goal for this type is to provide efficient date - operations (add, subtract) and storage (minimize space to represent) - in a concrete class. Thus, the date uses a count internally to - represent a particular date. The calendar parameter defines - the policies for converting the the year-month-day and internal - counted form here. Applications that need to perform heavy - formatting of the same date repeatedly will perform better - by using the year-month-day representation. - - Internally the date uses a day number to represent the date. - This is a monotonic time representation. This representation - allows for fast comparison as well as simplifying - the creation of writing numeric operations. Essentially, the - internal day number is like adjusted julian day. The adjustment - is determined by the Epoch date which is represented as day 1 of - the calendar. Day 0 is reserved for negative infinity so that - any actual date is automatically greater than negative infinity. - When a date is constructed from a date or formatted for output, - the appropriate conversions are applied to create the year, month, - day representations. - */ - - - template - class date : private - boost::less_than_comparable > - { - public: - typedef T date_type; - typedef calendar calendar_type; - typedef typename calendar::date_traits_type traits_type; - typedef duration_type_ duration_type; - typedef typename calendar::year_type year_type; - typedef typename calendar::month_type month_type; - typedef typename calendar::day_type day_type; - typedef typename calendar::ymd_type ymd_type; - typedef typename calendar::date_rep_type date_rep_type; - typedef typename calendar::date_int_type date_int_type; - typedef typename calendar::day_of_week_type day_of_week_type; - date(year_type y, month_type m, day_type d) - : days_(calendar::day_number(ymd_type(y, m, d))) - {} - date(const ymd_type& ymd) - : days_(calendar::day_number(ymd)) - {} - //let the compiler write copy, assignment, and destructor - year_type year() const - { - ymd_type ymd = calendar::from_day_number(days_); - return ymd.year; - } - month_type month() const - { - ymd_type ymd = calendar::from_day_number(days_); - return ymd.month; - } - day_type day() const - { - ymd_type ymd = calendar::from_day_number(days_); - return ymd.day; - } - day_of_week_type day_of_week() const - { - ymd_type ymd = calendar::from_day_number(days_); - return calendar::day_of_week(ymd); - } - ymd_type year_month_day() const - { - return calendar::from_day_number(days_); - } - bool operator<(const date_type& rhs) const - { - return days_ < rhs.days_; - } - bool operator==(const date_type& rhs) const - { - return days_ == rhs.days_; - } - //! check to see if date is a special value - bool is_special()const - { - return(is_not_a_date() || is_infinity()); - } - //! check to see if date is not a value - bool is_not_a_date() const - { - return traits_type::is_not_a_number(days_); - } - //! check to see if date is one of the infinity values - bool is_infinity() const - { - return traits_type::is_inf(days_); - } - //! check to see if date is greater than all possible dates - bool is_pos_infinity() const - { - return traits_type::is_pos_inf(days_); - } - //! check to see if date is greater than all possible dates - bool is_neg_infinity() const - { - return traits_type::is_neg_inf(days_); - } - //! return as a special value or a not_special if a normal date - special_values as_special() const - { - return traits_type::to_special(days_); - } - duration_type operator-(const date_type& d) const - { - if (!this->is_special() && !d.is_special()) - { - // The duration underlying type may be wider than the date underlying type. - // Thus we calculate the difference in terms of two durations from some common fixed base date. - typedef typename duration_type::duration_rep_type duration_rep_type; - return duration_type(static_cast< duration_rep_type >(days_) - static_cast< duration_rep_type >(d.days_)); - } - else - { - // In this case the difference will be a special value, too - date_rep_type val = date_rep_type(days_) - date_rep_type(d.days_); - return duration_type(val.as_special()); - } - } - - date_type operator-(const duration_type& dd) const - { - if(dd.is_special()) - { - return date_type(date_rep_type(days_) - dd.get_rep()); - } - return date_type(date_rep_type(days_) - dd.days()); - } - date_type operator-=(const duration_type& dd) - { - *this = *this - dd; - return date_type(days_); - } - date_rep_type day_count() const - { - return days_; - } - //allow internal access from operators - date_type operator+(const duration_type& dd) const - { - if(dd.is_special()) - { - return date_type(date_rep_type(days_) + dd.get_rep()); - } - return date_type(date_rep_type(days_) + dd.days()); - } - date_type operator+=(const duration_type& dd) - { - *this = *this + dd; - return date_type(days_); - } - - //see reference - protected: - /*! This is a private constructor which allows for the creation of new - dates. It is not exposed to users since that would require class - users to understand the inner workings of the date class. - */ - explicit date(date_int_type days) : days_(days) {} - explicit date(date_rep_type days) : days_(days.as_number()) {} - date_int_type days_; - - }; - - - - -} } // namespace date_time - - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_clock_device.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_clock_device.hpp deleted file mode 100644 index 6202f6c5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_clock_device.hpp +++ /dev/null @@ -1,77 +0,0 @@ -#ifndef DATE_CLOCK_DEVICE_HPP___ -#define DATE_CLOCK_DEVICE_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/c_time.hpp" - - -namespace boost { -namespace date_time { - - //! A clock providing day level services based on C time_t capabilities - /*! This clock uses Posix interfaces as its implementation and hence - * uses the timezone settings of the operating system. Incorrect - * user settings will result in incorrect results for the calls - * to local_day. - */ - template - class day_clock - { - public: - typedef typename date_type::ymd_type ymd_type; - //! Get the local day as a date type - static date_type local_day() - { - return date_type(local_day_ymd()); - } - //! Get the local day as a ymd_type - static typename date_type::ymd_type local_day_ymd() - { - ::std::tm result; - ::std::tm* curr = get_local_time(result); - return ymd_type(curr->tm_year + 1900, - curr->tm_mon + 1, - curr->tm_mday); - } - //! Get the current day in universal date as a ymd_type - static typename date_type::ymd_type universal_day_ymd() - { - ::std::tm result; - ::std::tm* curr = get_universal_time(result); - return ymd_type(curr->tm_year + 1900, - curr->tm_mon + 1, - curr->tm_mday); - } - //! Get the UTC day as a date type - static date_type universal_day() - { - return date_type(universal_day_ymd()); - } - - private: - static ::std::tm* get_local_time(std::tm& result) - { - ::std::time_t t; - ::std::time(&t); - return c_time::localtime(&t, &result); - } - static ::std::tm* get_universal_time(std::tm& result) - { - ::std::time_t t; - ::std::time(&t); - return c_time::gmtime(&t, &result); - } - - }; - -} } //namespace date_time - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_defs.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_defs.hpp deleted file mode 100644 index ae7e4c5a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_defs.hpp +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef DATE_TIME_DATE_DEFS_HPP -#define DATE_TIME_DATE_DEFS_HPP - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - - -namespace boost { -namespace date_time { - - //! An enumeration of weekday names - enum weekdays {Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday}; - - //! Simple enum to allow for nice programming with Jan, Feb, etc - enum months_of_year {Jan=1,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec,NotAMonth,NumMonths}; - -} } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration.hpp deleted file mode 100644 index c5739445..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration.hpp +++ /dev/null @@ -1,146 +0,0 @@ -#ifndef DATE_TIME_DATE_DURATION__ -#define DATE_TIME_DATE_DURATION__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - - -#include -#include - -namespace boost { -namespace date_time { - - - //! Duration type with date level resolution - template - class date_duration : private - boost::less_than_comparable1< date_duration< duration_rep_traits > - , boost::equality_comparable1< date_duration< duration_rep_traits > - , boost::addable1< date_duration< duration_rep_traits > - , boost::subtractable1< date_duration< duration_rep_traits > - , boost::dividable2< date_duration< duration_rep_traits >, int - > > > > > - { - public: - typedef typename duration_rep_traits::int_type duration_rep_type; - typedef typename duration_rep_traits::impl_type duration_rep; - - //! Construct from a day count - explicit date_duration(duration_rep day_count) : days_(day_count) {} - - /*! construct from special_values - only works when - * instantiated with duration_traits_adapted */ - date_duration(special_values sv) : - days_(duration_rep::from_special(sv)) - {} - - // copy constructor required for addable<> & subtractable<> - //! Construct from another date_duration (Copy Constructor) - date_duration(const date_duration& other) : - days_(other.days_) - {} - - //! returns days_ as it's instantiated type - used for streaming - duration_rep get_rep()const - { - return days_; - } - bool is_special()const - { - return days_.is_special(); - } - //! returns days as value, not object. - duration_rep_type days() const - { - return duration_rep_traits::as_number(days_); - } - //! Returns the smallest duration -- used by to calculate 'end' - static date_duration unit() - { - return date_duration(1); - } - //! Equality - bool operator==(const date_duration& rhs) const - { - return days_ == rhs.days_; - } - //! Less - bool operator<(const date_duration& rhs) const - { - return days_ < rhs.days_; - } - - /* For shortcut operators (+=, -=, etc) simply using - * "days_ += days_" may not work. If instantiated with - * an int_adapter, shortcut operators are not present, - * so this will not compile */ - - //! Subtract another duration -- result is signed - date_duration& operator-=(const date_duration& rhs) - { - //days_ -= rhs.days_; - days_ = days_ - rhs.days_; - return *this; - } - //! Add a duration -- result is signed - date_duration& operator+=(const date_duration& rhs) - { - days_ = days_ + rhs.days_; - return *this; - } - - //! unary- Allows for dd = -date_duration(2); -> dd == -2 - date_duration operator-() const - { - return date_duration(get_rep() * (-1)); - } - //! Division operations on a duration with an integer. - date_duration& operator/=(int divisor) - { - days_ = days_ / divisor; - return *this; - } - - //! return sign information - bool is_negative() const - { - return days_ < 0; - } - - private: - duration_rep days_; - }; - - - /*! Struct for instantiating date_duration with NO special values - * functionality. Allows for transparent implementation of either - * date_duration or date_duration > */ - struct duration_traits_long - { - typedef long int_type; - typedef long impl_type; - static int_type as_number(impl_type i) { return i; } - }; - - /*! Struct for instantiating date_duration WITH special values - * functionality. Allows for transparent implementation of either - * date_duration or date_duration > */ - struct duration_traits_adapted - { - typedef long int_type; - typedef boost::date_time::int_adapter impl_type; - static int_type as_number(impl_type i) { return i.as_number(); } - }; - - -} } //namspace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration_types.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration_types.hpp deleted file mode 100644 index e44c59ff..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_duration_types.hpp +++ /dev/null @@ -1,269 +0,0 @@ -#ifndef DATE_DURATION_TYPES_HPP___ -#define DATE_DURATION_TYPES_HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Subject to the Boost Software License, Version 1.0. - * (See accompanying file LICENSE_1_0.txt or - * http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include -#include -#include - -namespace boost { -namespace date_time { - - - //! Additional duration type that represents a number of n*7 days - template - class weeks_duration : public date_duration { - public: - weeks_duration(typename duration_config::impl_type w) - : date_duration(w * 7) {} - weeks_duration(special_values sv) - : date_duration(sv) {} - }; - - // predeclare - template - class years_duration; - - //! additional duration type that represents a logical month - /*! A logical month enables things like: "date(2002,Mar,2) + months(2) -> - * 2002-May2". If the date is a last day-of-the-month, the result will - * also be a last-day-of-the-month. - */ - template - class months_duration - { - private: - typedef typename base_config::int_rep int_rep; - typedef typename int_rep::int_type int_type; - typedef typename base_config::date_type date_type; - typedef typename date_type::duration_type duration_type; - typedef typename base_config::month_adjustor_type month_adjustor_type; - typedef months_duration months_type; - typedef years_duration years_type; - public: - months_duration(int_rep num) : _m(num) {} - months_duration(special_values sv) : _m(sv) - { - _m = int_rep::from_special(sv); - } - int_rep number_of_months() const { return _m; } - //! returns a negative duration - duration_type get_neg_offset(const date_type& d) const - { - month_adjustor_type m_adj(_m.as_number()); - return duration_type(m_adj.get_neg_offset(d)); - } - duration_type get_offset(const date_type& d) const - { - month_adjustor_type m_adj(_m.as_number()); - return duration_type(m_adj.get_offset(d)); - } - bool operator==(const months_type& rhs) const - { - return(_m == rhs._m); - } - bool operator!=(const months_type& rhs) const - { - return(_m != rhs._m); - } - months_type operator+(const months_type& rhs)const - { - return months_type(_m + rhs._m); - } - months_type& operator+=(const months_type& rhs) - { - _m = _m + rhs._m; - return *this; - } - months_type operator-(const months_type& rhs)const - { - return months_type(_m - rhs._m); - } - months_type& operator-=(const months_type& rhs) - { - _m = _m - rhs._m; - return *this; - } - months_type operator*(const int_type rhs)const - { - return months_type(_m * rhs); - } - months_type& operator*=(const int_type rhs) - { - _m = _m * rhs; - return *this; - } - months_type operator/(const int_type rhs)const - { - return months_type(_m / rhs); - } - months_type& operator/=(const int_type rhs) - { - _m = _m / rhs; - return *this; - } - months_type operator+(const years_type& y)const - { - return months_type(y.number_of_years() * 12 + _m); - } - months_type& operator+=(const years_type& y) - { - _m = y.number_of_years() * 12 + _m; - return *this; - } - months_type operator-(const years_type& y) const - { - return months_type(_m - y.number_of_years() * 12); - } - months_type& operator-=(const years_type& y) - { - _m = _m - y.number_of_years() * 12; - return *this; - } - - // - friend date_type operator+(const date_type& d, const months_type& m) - { - return d + m.get_offset(d); - } - friend date_type operator+=(date_type& d, const months_type& m) - { - return d += m.get_offset(d); - } - friend date_type operator-(const date_type& d, const months_type& m) - { - // get_neg_offset returns a negative duration, so we add - return d + m.get_neg_offset(d); - } - friend date_type operator-=(date_type& d, const months_type& m) - { - // get_neg_offset returns a negative duration, so we add - return d += m.get_neg_offset(d); - } - - private: - int_rep _m; - }; - - //! additional duration type that represents a logical year - /*! A logical year enables things like: "date(2002,Mar,2) + years(2) -> - * 2004-Mar-2". If the date is a last day-of-the-month, the result will - * also be a last-day-of-the-month (ie date(2001-Feb-28) + years(3) -> - * 2004-Feb-29). - */ - template - class years_duration - { - private: - typedef typename base_config::int_rep int_rep; - typedef typename int_rep::int_type int_type; - typedef typename base_config::date_type date_type; - typedef typename date_type::duration_type duration_type; - typedef typename base_config::month_adjustor_type month_adjustor_type; - typedef years_duration years_type; - typedef months_duration months_type; - public: - years_duration(int_rep num) : _y(num) {} - years_duration(special_values sv) : _y(sv) - { - _y = int_rep::from_special(sv); - } - int_rep number_of_years() const { return _y; } - //! returns a negative duration - duration_type get_neg_offset(const date_type& d) const - { - month_adjustor_type m_adj(_y.as_number() * 12); - return duration_type(m_adj.get_neg_offset(d)); - } - duration_type get_offset(const date_type& d) const - { - month_adjustor_type m_adj(_y.as_number() * 12); - return duration_type(m_adj.get_offset(d)); - } - bool operator==(const years_type& rhs) const - { - return(_y == rhs._y); - } - bool operator!=(const years_type& rhs) const - { - return(_y != rhs._y); - } - years_type operator+(const years_type& rhs)const - { - return years_type(_y + rhs._y); - } - years_type& operator+=(const years_type& rhs) - { - _y = _y + rhs._y; - return *this; - } - years_type operator-(const years_type& rhs)const - { - return years_type(_y - rhs._y); - } - years_type& operator-=(const years_type& rhs) - { - _y = _y - rhs._y; - return *this; - } - years_type operator*(const int_type rhs)const - { - return years_type(_y * rhs); - } - years_type& operator*=(const int_type rhs) - { - _y = _y * rhs; - return *this; - } - years_type operator/(const int_type rhs)const - { - return years_type(_y / rhs); - } - years_type& operator/=(const int_type rhs) - { - _y = _y / rhs; - return *this; - } - months_type operator+(const months_type& m) const - { - return(months_type(_y * 12 + m.number_of_months())); - } - months_type operator-(const months_type& m) const - { - return(months_type(_y * 12 - m.number_of_months())); - } - - // - friend date_type operator+(const date_type& d, const years_type& y) - { - return d + y.get_offset(d); - } - friend date_type operator+=(date_type& d, const years_type& y) - { - return d += y.get_offset(d); - } - friend date_type operator-(const date_type& d, const years_type& y) - { - // get_neg_offset returns a negative duration, so we add - return d + y.get_neg_offset(d); - } - friend date_type operator-=(date_type& d, const years_type& y) - { - // get_neg_offset returns a negative duration, so we add - return d += y.get_neg_offset(d); - } - - private: - int_rep _y; - }; - -}} // namespace boost::date_time - -#endif // DATE_DURATION_TYPES_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_facet.hpp deleted file mode 100644 index fc2ddc24..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_facet.hpp +++ /dev/null @@ -1,767 +0,0 @@ -#ifndef _DATE_TIME_DATE_FACET__HPP___ -#define _DATE_TIME_DATE_FACET__HPP___ - -/* Copyright (c) 2004-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Martin Andrian, Jeff Garland, Bart Garst - * $Date: 2012-09-30 16:25:22 -0700 (Sun, 30 Sep 2012) $ - */ - -#include -#include -#include -#include // ostreambuf_iterator -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { namespace date_time { - - - /*! Class that provides format based I/O facet for date types. - * - * This class allows the formatting of dates by using format string. - * Format strings are: - * - * - %A => long_weekday_format - Full name Ex: Tuesday - * - %a => short_weekday_format - Three letter abbreviation Ex: Tue - * - %B => long_month_format - Full name Ex: October - * - %b => short_month_format - Three letter abbreviation Ex: Oct - * - %x => standard_format_specifier - defined by the locale - * - %Y-%b-%d => default_date_format - YYYY-Mon-dd - * - * Default month format == %b - * Default weekday format == %a - */ - template > > - class date_facet : public std::locale::facet { - public: - typedef typename date_type::duration_type duration_type; - // greg_weekday is gregorian_calendar::day_of_week_type - typedef typename date_type::day_of_week_type day_of_week_type; - typedef typename date_type::day_type day_type; - typedef typename date_type::month_type month_type; - typedef boost::date_time::period period_type; - typedef std::basic_string string_type; - typedef CharT char_type; - typedef boost::date_time::period_formatter period_formatter_type; - typedef boost::date_time::special_values_formatter special_values_formatter_type; - typedef std::vector > input_collection_type; - // used for the output of the date_generators - typedef date_generator_formatter date_gen_formatter_type; - typedef partial_date partial_date_type; - typedef nth_kday_of_month nth_kday_type; - typedef first_kday_of_month first_kday_type; - typedef last_kday_of_month last_kday_type; - typedef first_kday_after kday_after_type; - typedef first_kday_before kday_before_type; - static const char_type long_weekday_format[3]; - static const char_type short_weekday_format[3]; - static const char_type long_month_format[3]; - static const char_type short_month_format[3]; - static const char_type default_period_separator[4]; - static const char_type standard_format_specifier[3]; - static const char_type iso_format_specifier[7]; - static const char_type iso_format_extended_specifier[9]; - static const char_type default_date_format[9]; // YYYY-Mon-DD - static std::locale::id id; - -#if defined (__SUNPRO_CC) && defined (_RWSTD_VER) - std::locale::id& __get_id (void) const { return id; } -#endif - - explicit date_facet(::size_t a_ref = 0) - : std::locale::facet(a_ref), - //m_format(standard_format_specifier) - m_format(default_date_format), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format) - {} - - explicit date_facet(const char_type* format_str, - const input_collection_type& short_names, - ::size_t ref_count = 0) - : std::locale::facet(ref_count), - m_format(format_str), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format), - m_month_short_names(short_names) - {} - - - explicit date_facet(const char_type* format_str, - period_formatter_type per_formatter = period_formatter_type(), - special_values_formatter_type sv_formatter = special_values_formatter_type(), - date_gen_formatter_type dg_formatter = date_gen_formatter_type(), - ::size_t ref_count = 0) - : std::locale::facet(ref_count), - m_format(format_str), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format), - m_period_formatter(per_formatter), - m_date_gen_formatter(dg_formatter), - m_special_values_formatter(sv_formatter) - {} - void format(const char_type* const format_str) { - m_format = format_str; - } - virtual void set_iso_format() - { - m_format = iso_format_specifier; - } - virtual void set_iso_extended_format() - { - m_format = iso_format_extended_specifier; - } - void month_format(const char_type* const format_str) { - m_month_format = format_str; - } - void weekday_format(const char_type* const format_str) { - m_weekday_format = format_str; - } - - void period_formatter(period_formatter_type per_formatter) { - m_period_formatter= per_formatter; - } - void special_values_formatter(const special_values_formatter_type& svf) - { - m_special_values_formatter = svf; - } - void short_weekday_names(const input_collection_type& short_names) - { - m_weekday_short_names = short_names; - } - void long_weekday_names(const input_collection_type& long_names) - { - m_weekday_long_names = long_names; - } - - void short_month_names(const input_collection_type& short_names) - { - m_month_short_names = short_names; - } - - void long_month_names(const input_collection_type& long_names) - { - m_month_long_names = long_names; - } - - void date_gen_phrase_strings(const input_collection_type& new_strings, - typename date_gen_formatter_type::phrase_elements beg_pos=date_gen_formatter_type::first) - { - m_date_gen_formatter.elements(new_strings, beg_pos); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const date_type& d) const - { - if (d.is_special()) { - return do_put_special(next, a_ios, fill_char, d.as_special()); - } - //The following line of code required the date to support a to_tm function - return do_put_tm(next, a_ios, fill_char, to_tm(d), m_format); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const duration_type& dd) const - { - if (dd.is_special()) { - return do_put_special(next, a_ios, fill_char, dd.get_rep().as_special()); - } - - typedef std::num_put num_put; - if (std::has_facet(a_ios.getloc())) { - return std::use_facet(a_ios.getloc()).put(next, a_ios, fill_char, dd.get_rep().as_number()); - } - else { - num_put* f = new num_put(); - std::locale l = std::locale(a_ios.getloc(), f); - a_ios.imbue(l); - return f->put(next, a_ios, fill_char, dd.get_rep().as_number()); - } - - } - - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const month_type& m) const - { - //if (d.is_special()) { - // return do_put_special(next, a_ios, fill_char, d.as_special()); - //} - //The following line of code required the date to support a to_tm function - std::tm dtm; - std::memset(&dtm, 0, sizeof(dtm)); - dtm.tm_mon = m - 1; - return do_put_tm(next, a_ios, fill_char, dtm, m_month_format); - } - - //! puts the day of month - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const day_type& day) const - { - std::tm dtm; - std::memset(&dtm, 0, sizeof(dtm)); - dtm.tm_mday = day.as_number(); - char_type tmp[3] = {'%','d'}; - string_type temp_format(tmp); - return do_put_tm(next, a_ios, fill_char, dtm, temp_format); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const day_of_week_type& dow) const - { - //if (d.is_special()) { - // return do_put_special(next, a_ios, fill_char, d.as_special()); - //} - //The following line of code required the date to support a to_tm function - std::tm dtm; - std::memset(&dtm, 0, sizeof(dtm)); - dtm.tm_wday = dow; - return do_put_tm(next, a_ios, fill_char, dtm, m_weekday_format); - } - - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const period_type& p) const - { - return m_period_formatter.put_period(next, a_ios, fill_char, p, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const partial_date_type& pd) const - { - return m_date_gen_formatter.put_partial_date(next, a_ios, fill_char, pd, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const nth_kday_type& nkd) const - { - return m_date_gen_formatter.put_nth_kday(next, a_ios, fill_char, nkd, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const first_kday_type& fkd) const - { - return m_date_gen_formatter.put_first_kday(next, a_ios, fill_char, fkd, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const last_kday_type& lkd) const - { - return m_date_gen_formatter.put_last_kday(next, a_ios, fill_char, lkd, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const kday_before_type& fkb) const - { - return m_date_gen_formatter.put_kday_before(next, a_ios, fill_char, fkb, *this); - } - - OutItrT put(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const kday_after_type& fka) const - { - return m_date_gen_formatter.put_kday_after(next, a_ios, fill_char, fka, *this); - } - - protected: - virtual OutItrT do_put_special(OutItrT next, - std::ios_base& /*a_ios*/, - char_type /*fill_char*/, - const boost::date_time::special_values sv) const - { - m_special_values_formatter.put_special(next, sv); - return next; - } - virtual OutItrT do_put_tm(OutItrT next, - std::ios_base& a_ios, - char_type fill_char, - const tm& tm_value, - string_type a_format) const - { - // update format string with custom names - if (m_weekday_long_names.size()) { - boost::algorithm::replace_all(a_format, - long_weekday_format, - m_weekday_long_names[tm_value.tm_wday]); - } - if (m_weekday_short_names.size()) { - boost::algorithm::replace_all(a_format, - short_weekday_format, - m_weekday_short_names[tm_value.tm_wday]); - - } - if (m_month_long_names.size()) { - boost::algorithm::replace_all(a_format, - long_month_format, - m_month_long_names[tm_value.tm_mon]); - } - if (m_month_short_names.size()) { - boost::algorithm::replace_all(a_format, - short_month_format, - m_month_short_names[tm_value.tm_mon]); - } - // use time_put facet to create final string - const char_type* p_format = a_format.c_str(); - return std::use_facet >(a_ios.getloc()).put(next, a_ios, - fill_char, - &tm_value, - p_format, - p_format + a_format.size()); - } - protected: - string_type m_format; - string_type m_month_format; - string_type m_weekday_format; - period_formatter_type m_period_formatter; - date_gen_formatter_type m_date_gen_formatter; - special_values_formatter_type m_special_values_formatter; - input_collection_type m_month_short_names; - input_collection_type m_month_long_names; - input_collection_type m_weekday_short_names; - input_collection_type m_weekday_long_names; - private: - }; - - template - std::locale::id date_facet::id; - - template - const typename date_facet::char_type - date_facet::long_weekday_format[3] = {'%','A'}; - - template - const typename date_facet::char_type - date_facet::short_weekday_format[3] = {'%','a'}; - - template - const typename date_facet::char_type - date_facet::long_month_format[3] = {'%','B'}; - - template - const typename date_facet::char_type - date_facet::short_month_format[3] = {'%','b'}; - - template - const typename date_facet::char_type - date_facet::default_period_separator[4] = { ' ', '/', ' '}; - - template - const typename date_facet::char_type - date_facet::standard_format_specifier[3] = - {'%', 'x' }; - - template - const typename date_facet::char_type - date_facet::iso_format_specifier[7] = - {'%', 'Y', '%', 'm', '%', 'd' }; - - template - const typename date_facet::char_type - date_facet::iso_format_extended_specifier[9] = - {'%', 'Y', '-', '%', 'm', '-', '%', 'd' }; - - template - const typename date_facet::char_type - date_facet::default_date_format[9] = - {'%','Y','-','%','b','-','%','d'}; - - - - //! Input facet - template > > - class date_input_facet : public std::locale::facet { - public: - typedef typename date_type::duration_type duration_type; - // greg_weekday is gregorian_calendar::day_of_week_type - typedef typename date_type::day_of_week_type day_of_week_type; - typedef typename date_type::day_type day_type; - typedef typename date_type::month_type month_type; - typedef typename date_type::year_type year_type; - typedef boost::date_time::period period_type; - typedef std::basic_string string_type; - typedef CharT char_type; - typedef boost::date_time::period_parser period_parser_type; - typedef boost::date_time::special_values_parser special_values_parser_type; - typedef std::vector > input_collection_type; - typedef format_date_parser format_date_parser_type; - // date_generators stuff goes here - typedef date_generator_parser date_gen_parser_type; - typedef partial_date partial_date_type; - typedef nth_kday_of_month nth_kday_type; - typedef first_kday_of_month first_kday_type; - typedef last_kday_of_month last_kday_type; - typedef first_kday_after kday_after_type; - typedef first_kday_before kday_before_type; - - static const char_type long_weekday_format[3]; - static const char_type short_weekday_format[3]; - static const char_type long_month_format[3]; - static const char_type short_month_format[3]; - static const char_type four_digit_year_format[3]; - static const char_type two_digit_year_format[3]; - static const char_type default_period_separator[4]; - static const char_type standard_format_specifier[3]; - static const char_type iso_format_specifier[7]; - static const char_type iso_format_extended_specifier[9]; - static const char_type default_date_format[9]; // YYYY-Mon-DD - static std::locale::id id; - - explicit date_input_facet(::size_t a_ref = 0) - : std::locale::facet(a_ref), - m_format(default_date_format), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format), - m_year_format(four_digit_year_format), - m_parser(m_format, std::locale::classic()) - // default period_parser & special_values_parser used - {} - - explicit date_input_facet(const string_type& format_str, - ::size_t a_ref = 0) - : std::locale::facet(a_ref), - m_format(format_str), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format), - m_year_format(four_digit_year_format), - m_parser(m_format, std::locale::classic()) - // default period_parser & special_values_parser used - {} - - explicit date_input_facet(const string_type& format_str, - const format_date_parser_type& date_parser, - const special_values_parser_type& sv_parser, - const period_parser_type& per_parser, - const date_gen_parser_type& date_gen_parser, - ::size_t ref_count = 0) - : std::locale::facet(ref_count), - m_format(format_str), - m_month_format(short_month_format), - m_weekday_format(short_weekday_format), - m_year_format(four_digit_year_format), - m_parser(date_parser), - m_date_gen_parser(date_gen_parser), - m_period_parser(per_parser), - m_sv_parser(sv_parser) - {} - - - void format(const char_type* const format_str) { - m_format = format_str; - } - virtual void set_iso_format() - { - m_format = iso_format_specifier; - } - virtual void set_iso_extended_format() - { - m_format = iso_format_extended_specifier; - } - void month_format(const char_type* const format_str) { - m_month_format = format_str; - } - void weekday_format(const char_type* const format_str) { - m_weekday_format = format_str; - } - void year_format(const char_type* const format_str) { - m_year_format = format_str; - } - - void period_parser(period_parser_type per_parser) { - m_period_parser = per_parser; - } - void short_weekday_names(const input_collection_type& weekday_names) - { - m_parser.short_weekday_names(weekday_names); - } - void long_weekday_names(const input_collection_type& weekday_names) - { - m_parser.long_weekday_names(weekday_names); - } - - void short_month_names(const input_collection_type& month_names) - { - m_parser.short_month_names(month_names); - } - - void long_month_names(const input_collection_type& month_names) - { - m_parser.long_month_names(month_names); - } - - void date_gen_element_strings(const input_collection_type& col) - { - m_date_gen_parser.element_strings(col); - } - void date_gen_element_strings(const string_type& first, - const string_type& second, - const string_type& third, - const string_type& fourth, - const string_type& fifth, - const string_type& last, - const string_type& before, - const string_type& after, - const string_type& of) - - { - m_date_gen_parser.element_strings(first,second,third,fourth,fifth,last,before,after,of); - } - - void special_values_parser(special_values_parser_type sv_parser) - { - m_sv_parser = sv_parser; - } - - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& /*a_ios*/, - date_type& d) const - { - d = m_parser.parse_date(from, to, m_format, m_sv_parser); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& /*a_ios*/, - month_type& m) const - { - m = m_parser.parse_month(from, to, m_month_format); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& /*a_ios*/, - day_of_week_type& wd) const - { - wd = m_parser.parse_weekday(from, to, m_weekday_format); - return from; - } - //! Expects 1 or 2 digit day range: 1-31 - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& /*a_ios*/, - day_type& d) const - { - d = m_parser.parse_var_day_of_month(from, to); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& /*a_ios*/, - year_type& y) const - { - y = m_parser.parse_year(from, to, m_year_format); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - duration_type& dd) const - { - // skip leading whitespace - while(std::isspace(*from) && from != to) { ++from; } - - /* num_get.get() will always consume the first character if it - * is a sign indicator (+/-). Special value strings may begin - * with one of these signs so we'll need a copy of it - * in case num_get.get() fails. */ - char_type c = '\0'; - // TODO Are these characters somewhere in the locale? - if(*from == '-' || *from == '+') { - c = *from; - } - typedef std::num_get num_get; - typename duration_type::duration_rep_type val = 0; - std::ios_base::iostate err = std::ios_base::goodbit; - - if (std::has_facet(a_ios.getloc())) { - from = std::use_facet(a_ios.getloc()).get(from, to, a_ios, err, val); - } - else { - num_get* ng = new num_get(); - std::locale l = std::locale(a_ios.getloc(), ng); - a_ios.imbue(l); - from = ng->get(from, to, a_ios, err, val); - } - if(err & std::ios_base::failbit){ - typedef typename special_values_parser_type::match_results match_results; - match_results mr; - if(c == '-' || c == '+') { // was the first character consumed? - mr.cache += c; - } - m_sv_parser.match(from, to, mr); - if(mr.current_match == match_results::PARSE_ERROR) { - boost::throw_exception(std::ios_base::failure("Parse failed. No match found for '" + mr.cache + "'")); - BOOST_DATE_TIME_UNREACHABLE_EXPRESSION(return from); // should never reach - } - dd = duration_type(static_cast(mr.current_match)); - } - else { - dd = duration_type(val); - } - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - period_type& p) const - { - p = m_period_parser.get_period(from, to, a_ios, p, duration_type::unit(), *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - nth_kday_type& nkd) const - { - nkd = m_date_gen_parser.get_nth_kday_type(from, to, a_ios, *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - partial_date_type& pd) const - { - - pd = m_date_gen_parser.get_partial_date_type(from, to, a_ios, *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - first_kday_type& fkd) const - { - fkd = m_date_gen_parser.get_first_kday_type(from, to, a_ios, *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - last_kday_type& lkd) const - { - lkd = m_date_gen_parser.get_last_kday_type(from, to, a_ios, *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - kday_before_type& fkb) const - { - fkb = m_date_gen_parser.get_kday_before_type(from, to, a_ios, *this); - return from; - } - InItrT get(InItrT& from, - InItrT& to, - std::ios_base& a_ios, - kday_after_type& fka) const - { - fka = m_date_gen_parser.get_kday_after_type(from, to, a_ios, *this); - return from; - } - - protected: - string_type m_format; - string_type m_month_format; - string_type m_weekday_format; - string_type m_year_format; - format_date_parser_type m_parser; - date_gen_parser_type m_date_gen_parser; - period_parser_type m_period_parser; - special_values_parser_type m_sv_parser; - private: - }; - - - template - std::locale::id date_input_facet::id; - - template - const typename date_input_facet::char_type - date_input_facet::long_weekday_format[3] = {'%','A'}; - - template - const typename date_input_facet::char_type - date_input_facet::short_weekday_format[3] = {'%','a'}; - - template - const typename date_input_facet::char_type - date_input_facet::long_month_format[3] = {'%','B'}; - - template - const typename date_input_facet::char_type - date_input_facet::short_month_format[3] = {'%','b'}; - - template - const typename date_input_facet::char_type - date_input_facet::four_digit_year_format[3] = {'%','Y'}; - - template - const typename date_input_facet::char_type - date_input_facet::two_digit_year_format[3] = {'%','y'}; - - template - const typename date_input_facet::char_type - date_input_facet::default_period_separator[4] = { ' ', '/', ' '}; - - template - const typename date_input_facet::char_type - date_input_facet::standard_format_specifier[3] = - {'%', 'x' }; - - template - const typename date_input_facet::char_type - date_input_facet::iso_format_specifier[7] = - {'%', 'Y', '%', 'm', '%', 'd' }; - - template - const typename date_input_facet::char_type - date_input_facet::iso_format_extended_specifier[9] = - {'%', 'Y', '-', '%', 'm', '-', '%', 'd' }; - - template - const typename date_input_facet::char_type - date_input_facet::default_date_format[9] = - {'%','Y','-','%','b','-','%','d'}; - -} } // namespaces - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_format_simple.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_format_simple.hpp deleted file mode 100644 index 05119c44..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_format_simple.hpp +++ /dev/null @@ -1,159 +0,0 @@ -#ifndef DATE_TIME_SIMPLE_FORMAT_HPP___ -#define DATE_TIME_SIMPLE_FORMAT_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/parse_format_base.hpp" - -namespace boost { -namespace date_time { - -//! Class to provide simple basic formatting rules -template -class simple_format { -public: - - //! String used printed is date is invalid - static const charT* not_a_date() - { - return "not-a-date-time"; - } - //! String used to for positive infinity value - static const charT* pos_infinity() - { - return "+infinity"; - } - //! String used to for positive infinity value - static const charT* neg_infinity() - { - return "-infinity"; - } - //! Describe month format - static month_format_spec month_format() - { - return month_as_short_string; - } - static ymd_order_spec date_order() - { - return ymd_order_iso; //YYYY-MM-DD - } - //! This format uses '-' to separate date elements - static bool has_date_sep_chars() - { - return true; - } - //! Char to sep? - static charT year_sep_char() - { - return '-'; - } - //! char between year-month - static charT month_sep_char() - { - return '-'; - } - //! Char to separate month-day - static charT day_sep_char() - { - return '-'; - } - //! char between date-hours - static charT hour_sep_char() - { - return ' '; - } - //! char between hour and minute - static charT minute_sep_char() - { - return ':'; - } - //! char for second - static charT second_sep_char() - { - return ':'; - } - -}; - -#ifndef BOOST_NO_STD_WSTRING - -//! Specialization of formmating rules for wchar_t -template<> -class simple_format { -public: - - //! String used printed is date is invalid - static const wchar_t* not_a_date() - { - return L"not-a-date-time"; - } - //! String used to for positive infinity value - static const wchar_t* pos_infinity() - { - return L"+infinity"; - } - //! String used to for positive infinity value - static const wchar_t* neg_infinity() - { - return L"-infinity"; - } - //! Describe month format - static month_format_spec month_format() - { - return month_as_short_string; - } - static ymd_order_spec date_order() - { - return ymd_order_iso; //YYYY-MM-DD - } - //! This format uses '-' to separate date elements - static bool has_date_sep_chars() - { - return true; - } - //! Char to sep? - static wchar_t year_sep_char() - { - return '-'; - } - //! char between year-month - static wchar_t month_sep_char() - { - return '-'; - } - //! Char to separate month-day - static wchar_t day_sep_char() - { - return '-'; - } - //! char between date-hours - static wchar_t hour_sep_char() - { - return ' '; - } - //! char between hour and minute - static wchar_t minute_sep_char() - { - return ':'; - } - //! char for second - static wchar_t second_sep_char() - { - return ':'; - } - -}; - -#endif // BOOST_NO_STD_WSTRING -} } //namespace date_time - - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting.hpp deleted file mode 100644 index 06709bc5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting.hpp +++ /dev/null @@ -1,135 +0,0 @@ -#ifndef DATE_TIME_DATE_FORMATTING_HPP___ -#define DATE_TIME_DATE_FORMATTING_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-30 16:25:22 -0700 (Sun, 30 Sep 2012) $ - */ - -#include "boost/date_time/iso_format.hpp" -#include "boost/date_time/compiler_config.hpp" -#include -#include -#include - -/* NOTE: "formatter" code for older compilers, ones that define - * BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS, is located in - * date_formatting_limited.hpp - */ - -namespace boost { -namespace date_time { - - //! Formats a month as as string into an ostream - template - class month_formatter - { - typedef std::basic_ostream ostream_type; - public: - //! Formats a month as as string into an ostream - /*! This function demands that month_type provide - * functions for converting to short and long strings - * if that capability is used. - */ - static ostream_type& format_month(const month_type& month, - ostream_type &os) - { - switch (format_type::month_format()) - { - case month_as_short_string: - { - os << month.as_short_string(); - break; - } - case month_as_long_string: - { - os << month.as_long_string(); - break; - } - case month_as_integer: - { - os << std::setw(2) << std::setfill(os.widen('0')) << month.as_number(); - break; - } - default: - break; - - } - return os; - } // format_month - }; - - - //! Convert ymd to a standard string formatting policies - template - class ymd_formatter - { - public: - //! Convert ymd to a standard string formatting policies - /*! This is standard code for handling date formatting with - * year-month-day based date information. This function - * uses the format_type to control whether the string will - * contain separator characters, and if so what the character - * will be. In addtion, it can format the month as either - * an integer or a string as controled by the formatting - * policy - */ - static std::basic_string ymd_to_string(ymd_type ymd) - { - typedef typename ymd_type::month_type month_type; - std::basic_ostringstream ss; - - // Temporarily switch to classic locale to prevent possible formatting - // of year with comma or other character (for example 2,008). - ss.imbue(std::locale::classic()); - ss << ymd.year; - ss.imbue(std::locale()); - - if (format_type::has_date_sep_chars()) { - ss << format_type::month_sep_char(); - } - //this name is a bit ugly, oh well.... - month_formatter::format_month(ymd.month, ss); - if (format_type::has_date_sep_chars()) { - ss << format_type::day_sep_char(); - } - ss << std::setw(2) << std::setfill(ss.widen('0')) - << ymd.day; - return ss.str(); - } - }; - - - //! Convert a date to string using format policies - template - class date_formatter - { - public: - typedef std::basic_string string_type; - //! Convert to a date to standard string using format policies - static string_type date_to_string(date_type d) - { - typedef typename date_type::ymd_type ymd_type; - if (d.is_not_a_date()) { - return string_type(format_type::not_a_date()); - } - if (d.is_neg_infinity()) { - return string_type(format_type::neg_infinity()); - } - if (d.is_pos_infinity()) { - return string_type(format_type::pos_infinity()); - } - ymd_type ymd = d.year_month_day(); - return ymd_formatter::ymd_to_string(ymd); - } - }; - - -} } //namespace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_limited.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_limited.hpp deleted file mode 100644 index 5721473b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_limited.hpp +++ /dev/null @@ -1,121 +0,0 @@ -#ifndef DATE_TIME_DATE_FORMATTING_LIMITED_HPP___ -#define DATE_TIME_DATE_FORMATTING_LIMITED_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/iso_format.hpp" -#include "boost/date_time/compiler_config.hpp" -#include -#include -#include - - -namespace boost { -namespace date_time { - - //! Formats a month as as string into an ostream - template - class month_formatter - { - public: - //! Formats a month as as string into an ostream - /*! This function demands that month_type provide - * functions for converting to short and long strings - * if that capability is used. - */ - static std::ostream& format_month(const month_type& month, - std::ostream& os) - { - switch (format_type::month_format()) - { - case month_as_short_string: - { - os << month.as_short_string(); - break; - } - case month_as_long_string: - { - os << month.as_long_string(); - break; - } - case month_as_integer: - { - os << std::setw(2) << std::setfill('0') << month.as_number(); - break; - } - - } - return os; - } // format_month - }; - - - //! Convert ymd to a standard string formatting policies - template - class ymd_formatter - { - public: - //! Convert ymd to a standard string formatting policies - /*! This is standard code for handling date formatting with - * year-month-day based date information. This function - * uses the format_type to control whether the string will - * contain separator characters, and if so what the character - * will be. In addtion, it can format the month as either - * an integer or a string as controled by the formatting - * policy - */ - static std::string ymd_to_string(ymd_type ymd) - { - typedef typename ymd_type::month_type month_type; - std::ostringstream ss; - ss << ymd.year; - if (format_type::has_date_sep_chars()) { - ss << format_type::month_sep_char(); - } - //this name is a bit ugly, oh well.... - month_formatter::format_month(ymd.month, ss); - if (format_type::has_date_sep_chars()) { - ss << format_type::day_sep_char(); - } - ss << std::setw(2) << std::setfill('0') - << ymd.day; - return ss.str(); - } - }; - - - //! Convert a date to string using format policies - template - class date_formatter - { - public: - //! Convert to a date to standard string using format policies - static std::string date_to_string(date_type d) - { - typedef typename date_type::ymd_type ymd_type; - if (d.is_not_a_date()) { - return format_type::not_a_date(); - } - if (d.is_neg_infinity()) { - return format_type::neg_infinity(); - } - if (d.is_pos_infinity()) { - return format_type::pos_infinity(); - } - ymd_type ymd = d.year_month_day(); - return ymd_formatter::ymd_to_string(ymd); - } - }; - - -} } //namespace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_locales.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_locales.hpp deleted file mode 100644 index e3aec496..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_formatting_locales.hpp +++ /dev/null @@ -1,233 +0,0 @@ -#ifndef DATE_TIME_DATE_FORMATTING_LOCALES_HPP___ -#define DATE_TIME_DATE_FORMATTING_LOCALES_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - - -#include "boost/date_time/locale_config.hpp" // set BOOST_DATE_TIME_NO_LOCALE - -#ifndef BOOST_DATE_TIME_NO_LOCALE - -#include "boost/date_time/iso_format.hpp" -#include "boost/date_time/date_names_put.hpp" -#include "boost/date_time/parse_format_base.hpp" -//#include -#include -#include - - -namespace boost { -namespace date_time { - - //! Formats a month as as string into an ostream - template - class ostream_month_formatter - { - public: - typedef typename facet_type::month_type month_type; - typedef std::basic_ostream ostream_type; - - //! Formats a month as as string into an output iterator - static void format_month(const month_type& month, - ostream_type& os, - const facet_type& f) - { - - switch (f.month_format()) - { - case month_as_short_string: - { - std::ostreambuf_iterator oitr(os); - f.put_month_short(oitr, month.as_enum()); - break; - } - case month_as_long_string: - { - std::ostreambuf_iterator oitr(os); - f.put_month_long(oitr, month.as_enum()); - break; - } - case month_as_integer: - { - charT fill_char = '0'; - os << std::setw(2) << std::setfill(fill_char) << month.as_number(); - break; - } - - } - } // format_month - - }; - - - //! Formats a weekday - template - class ostream_weekday_formatter - { - public: - typedef typename facet_type::month_type month_type; - typedef std::basic_ostream ostream_type; - - //! Formats a month as as string into an output iterator - static void format_weekday(const weekday_type& wd, - ostream_type& os, - const facet_type& f, - bool as_long_string) - { - - std::ostreambuf_iterator oitr(os); - if (as_long_string) { - f.put_weekday_long(oitr, wd.as_enum()); - } - else { - f.put_weekday_short(oitr, wd.as_enum()); - } - - } // format_weekday - - }; - - - //! Convert ymd to a standard string formatting policies - template - class ostream_ymd_formatter - { - public: - typedef typename ymd_type::month_type month_type; - typedef ostream_month_formatter month_formatter_type; - typedef std::basic_ostream ostream_type; - typedef std::basic_string foo_type; - - //! Convert ymd to a standard string formatting policies - /*! This is standard code for handling date formatting with - * year-month-day based date information. This function - * uses the format_type to control whether the string will - * contain separator characters, and if so what the character - * will be. In addtion, it can format the month as either - * an integer or a string as controled by the formatting - * policy - */ - // static string_type ymd_to_string(ymd_type ymd) -// { -// std::ostringstream ss; -// facet_type dnp; -// ymd_put(ymd, ss, dnp); -// return ss.str(); -// } - - - // Put ymd to ostream -- part of ostream refactor - static void ymd_put(ymd_type ymd, - ostream_type& os, - const facet_type& f) - { - std::ostreambuf_iterator oitr(os); - charT fill_char = '0'; - switch (f.date_order()) { - case ymd_order_iso: { - os << ymd.year; - if (f.has_date_sep_chars()) { - f.month_sep_char(oitr); - } - month_formatter_type::format_month(ymd.month, os, f); - if (f.has_date_sep_chars()) { - f.day_sep_char(oitr); - } - os << std::setw(2) << std::setfill(fill_char) - << ymd.day; - break; - } - case ymd_order_us: { - month_formatter_type::format_month(ymd.month, os, f); - if (f.has_date_sep_chars()) { - f.day_sep_char(oitr); - } - os << std::setw(2) << std::setfill(fill_char) - << ymd.day; - if (f.has_date_sep_chars()) { - f.month_sep_char(oitr); - } - os << ymd.year; - break; - } - case ymd_order_dmy: { - os << std::setw(2) << std::setfill(fill_char) - << ymd.day; - if (f.has_date_sep_chars()) { - f.day_sep_char(oitr); - } - month_formatter_type::format_month(ymd.month, os, f); - if (f.has_date_sep_chars()) { - f.month_sep_char(oitr); - } - os << ymd.year; - break; - } - } - } - }; - - - //! Convert a date to string using format policies - template - class ostream_date_formatter - { - public: - typedef std::basic_ostream ostream_type; - typedef typename date_type::ymd_type ymd_type; - - //! Put date into an ostream - static void date_put(const date_type& d, - ostream_type& os, - const facet_type& f) - { - special_values sv = d.as_special(); - if (sv == not_special) { - ymd_type ymd = d.year_month_day(); - ostream_ymd_formatter::ymd_put(ymd, os, f); - } - else { // output a special value - std::ostreambuf_iterator coi(os); - f.put_special_value(coi, sv); - } - } - - - //! Put date into an ostream - static void date_put(const date_type& d, - ostream_type& os) - { - //retrieve the local from the ostream - std::locale locale = os.getloc(); - if (std::has_facet(locale)) { - const facet_type& f = std::use_facet(locale); - date_put(d, os, f); - } - else { - //default to something sensible if no facet installed - facet_type default_facet; - date_put(d, os, default_facet); - } - } // date_to_ostream - }; //class date_formatter - - -} } //namespace date_time - -#endif - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_formatter.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_formatter.hpp deleted file mode 100644 index 159cf36e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_formatter.hpp +++ /dev/null @@ -1,265 +0,0 @@ -#ifndef _DATE_TIME_DATE_GENERATOR_FORMATTER__HPP___ -#define _DATE_TIME_DATE_GENERATOR_FORMATTER__HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-13 11:05:31 -0800 (Thu, 13 Nov 2008) $ - */ - -#include -#include -#include -#include -#include "boost/date_time/date_generators.hpp" - -namespace boost { -namespace date_time { - - //! Formats date_generators for output - /*! Formatting of date_generators follows specific orders for the - * various types of date_generators. - * - partial_date => "dd Month" - * - nth_day_of_the_week_in_month => "nth weekday of month" - * - first_day_of_the_week_in_month => "first weekday of month" - * - last_day_of_the_week_in_month => "last weekday of month" - * - first_day_of_the_week_after => "weekday after" - * - first_day_of_the_week_before => "weekday before" - * While the order of the elements in these phrases cannot be changed, - * the elements themselves can be. Weekday and Month get their formats - * and names from the date_facet. The remaining elements are stored in - * the date_generator_formatter and can be customized upon construction - * or via a member function. The default elements are those shown in the - * examples above. - */ - template > > - class date_generator_formatter { - public: - typedef partial_date partial_date_type; - typedef nth_kday_of_month nth_kday_type; - typedef first_kday_of_month first_kday_type; - typedef last_kday_of_month last_kday_type; - typedef first_kday_after kday_after_type; - typedef first_kday_before kday_before_type; - - typedef CharT char_type; - typedef std::basic_string string_type; - typedef std::vector collection_type; - static const char_type first_string[6]; - static const char_type second_string[7]; - static const char_type third_string[6]; - static const char_type fourth_string[7]; - static const char_type fifth_string[6]; - static const char_type last_string[5]; - static const char_type before_string[8]; - static const char_type after_string[6]; - static const char_type of_string[3]; - - enum phrase_elements {first=0, second, third, fourth, fifth, last, - before, after, of, number_of_phrase_elements}; - - //! Default format elements used - date_generator_formatter() - { - phrase_strings.reserve(number_of_phrase_elements); - phrase_strings.push_back(string_type(first_string)); - phrase_strings.push_back(string_type(second_string)); - phrase_strings.push_back(string_type(third_string)); - phrase_strings.push_back(string_type(fourth_string)); - phrase_strings.push_back(string_type(fifth_string)); - phrase_strings.push_back(string_type(last_string)); - phrase_strings.push_back(string_type(before_string)); - phrase_strings.push_back(string_type(after_string)); - phrase_strings.push_back(string_type(of_string)); - } - - //! Constructor that allows for a custom set of phrase elements - date_generator_formatter(const string_type& first_str, - const string_type& second_str, - const string_type& third_str, - const string_type& fourth_str, - const string_type& fifth_str, - const string_type& last_str, - const string_type& before_str, - const string_type& after_str, - const string_type& of_str) - { - phrase_strings.reserve(number_of_phrase_elements); - phrase_strings.push_back(first_str); - phrase_strings.push_back(second_str); - phrase_strings.push_back(third_str); - phrase_strings.push_back(fourth_str); - phrase_strings.push_back(fifth_str); - phrase_strings.push_back(last_str); - phrase_strings.push_back(before_str); - phrase_strings.push_back(after_str); - phrase_strings.push_back(of_str); - } - - //! Replace the set of phrase elements with those contained in new_strings - /*! The order of the strings in the given collection is important. - * They must follow: - * - first, second, third, fourth, fifth, last, before, after, of. - * - * It is not necessary to send in a complete set if only a few - * elements are to be replaced as long as the correct beg_pos is used. - * - * Ex: To keep the default first through fifth elements, but replace - * the rest with a collection of: - * - "final", "prior", "following", "in". - * The beg_pos of date_generator_formatter::last would be used. - */ - void elements(const collection_type& new_strings, - phrase_elements beg_pos=first) - { - if(beg_pos < number_of_phrase_elements) { - typename collection_type::iterator itr = phrase_strings.begin(); - itr += beg_pos; - std::copy(new_strings.begin(), new_strings.end(), - itr); - //phrase_strings.begin()); - } - } - - //!Put a partial_date => "dd Month" - template - OutItrT put_partial_date(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const partial_date_type& pd, - const facet_type& facet) const - { - facet.put(next, a_ios, a_fill, pd.day()); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, pd.month()); - return next; - } - - //! Put an nth_day_of_the_week_in_month => "nth weekday of month" - template - OutItrT put_nth_kday(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const nth_kday_type& nkd, - const facet_type& facet) const - { - put_string(next, phrase_strings[nkd.nth_week() -1]); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, nkd.day_of_week()); - next = a_fill; //TODO change this ??? - put_string(next, string_type(of_string)); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, nkd.month()); - return next; - } - - //! Put a first_day_of_the_week_in_month => "first weekday of month" - template - OutItrT put_first_kday(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const first_kday_type& fkd, - const facet_type& facet) const - { - put_string(next, phrase_strings[first]); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, fkd.day_of_week()); - next = a_fill; //TODO change this ??? - put_string(next, string_type(of_string)); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, fkd.month()); - return next; - } - - //! Put a last_day_of_the_week_in_month => "last weekday of month" - template - OutItrT put_last_kday(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const last_kday_type& lkd, - const facet_type& facet) const - { - put_string(next, phrase_strings[last]); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, lkd.day_of_week()); - next = a_fill; //TODO change this ??? - put_string(next, string_type(of_string)); - next = a_fill; //TODO change this ??? - facet.put(next, a_ios, a_fill, lkd.month()); - return next; - } - - //! Put a first_day_of_the_week_before => "weekday before" - template - OutItrT put_kday_before(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const kday_before_type& fkb, - const facet_type& facet) const - { - facet.put(next, a_ios, a_fill, fkb.day_of_week()); - next = a_fill; //TODO change this ??? - put_string(next, phrase_strings[before]); - return next; - } - - //! Put a first_day_of_the_week_after => "weekday after" - template - OutItrT put_kday_after(OutItrT next, std::ios_base& a_ios, - CharT a_fill, const kday_after_type& fka, - const facet_type& facet) const - { - facet.put(next, a_ios, a_fill, fka.day_of_week()); - next = a_fill; //TODO change this ??? - put_string(next, phrase_strings[after]); - return next; - } - - - private: - collection_type phrase_strings; - - //! helper function to put the various member string into stream - OutItrT put_string(OutItrT next, const string_type& str) const - { - typename string_type::const_iterator itr = str.begin(); - while(itr != str.end()) { - *next = *itr; - ++itr; - ++next; - } - return next; - } - }; - - template - const typename date_generator_formatter::char_type - date_generator_formatter::first_string[6] = - {'f','i','r','s','t'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::second_string[7] = - {'s','e','c','o','n','d'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::third_string[6] = - {'t','h','i','r','d'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::fourth_string[7] = - {'f','o','u','r','t','h'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::fifth_string[6] = - {'f','i','f','t','h'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::last_string[5] = - {'l','a','s','t'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::before_string[8] = - {'b','e','f','o','r','e'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::after_string[6] = - {'a','f','t','e','r'}; - template - const typename date_generator_formatter::char_type - date_generator_formatter::of_string[3] = - {'o','f'}; -} } // namespaces - -#endif // _DATE_TIME_DATE_GENERATOR_FORMATTER__HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_parser.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_parser.hpp deleted file mode 100644 index 7cff9ca3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generator_parser.hpp +++ /dev/null @@ -1,330 +0,0 @@ - -#ifndef DATE_TIME_DATE_GENERATOR_PARSER_HPP__ -#define DATE_TIME_DATE_GENERATOR_PARSER_HPP__ - -/* Copyright (c) 2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include -#include -#include // istreambuf_iterator -#include -#include -#include -#include -#include - -namespace boost { namespace date_time { - - //! Class for date_generator parsing - /*! The elements of a date_generator "phrase" are parsed from the input stream in a - * particular order. All elements are required and the order in which they appear - * cannot change, however, the elements themselves can be changed. The default - * elements and their order are as follows: - * - * - partial_date => "dd Month" - * - nth_day_of_the_week_in_month => "nth weekday of month" - * - first_day_of_the_week_in_month => "first weekday of month" - * - last_day_of_the_week_in_month => "last weekday of month" - * - first_day_of_the_week_after => "weekday after" - * - first_day_of_the_week_before => "weekday before" - * - * Weekday and Month names and formats are handled via the date_input_facet. - * - */ - template - class date_generator_parser - { - public: - typedef std::basic_string string_type; - typedef std::istreambuf_iterator stream_itr_type; - - typedef typename date_type::month_type month_type; - typedef typename date_type::day_of_week_type day_of_week_type; - typedef typename date_type::day_type day_type; - - typedef string_parse_tree parse_tree_type; - typedef typename parse_tree_type::parse_match_result_type match_results; - typedef std::vector > collection_type; - - typedef partial_date partial_date_type; - typedef nth_kday_of_month nth_kday_type; - typedef first_kday_of_month first_kday_type; - typedef last_kday_of_month last_kday_type; - typedef first_kday_after kday_after_type; - typedef first_kday_before kday_before_type; - - typedef charT char_type; - static const char_type first_string[6]; - static const char_type second_string[7]; - static const char_type third_string[6]; - static const char_type fourth_string[7]; - static const char_type fifth_string[6]; - static const char_type last_string[5]; - static const char_type before_string[8]; - static const char_type after_string[6]; - static const char_type of_string[3]; - - enum phrase_elements {first=0, second, third, fourth, fifth, last, - before, after, of, number_of_phrase_elements}; - - //! Creates a date_generator_parser with the default set of "element_strings" - date_generator_parser() - { - element_strings(string_type(first_string), - string_type(second_string), - string_type(third_string), - string_type(fourth_string), - string_type(fifth_string), - string_type(last_string), - string_type(before_string), - string_type(after_string), - string_type(of_string)); - } - - //! Creates a date_generator_parser using a user defined set of element strings - date_generator_parser(const string_type& first_str, - const string_type& second_str, - const string_type& third_str, - const string_type& fourth_str, - const string_type& fifth_str, - const string_type& last_str, - const string_type& before_str, - const string_type& after_str, - const string_type& of_str) - { - element_strings(first_str, second_str, third_str, fourth_str, fifth_str, - last_str, before_str, after_str, of_str); - } - - //! Replace strings that determine nth week for generator - void element_strings(const string_type& first_str, - const string_type& second_str, - const string_type& third_str, - const string_type& fourth_str, - const string_type& fifth_str, - const string_type& last_str, - const string_type& before_str, - const string_type& after_str, - const string_type& of_str) - { - collection_type phrases; - phrases.push_back(first_str); - phrases.push_back(second_str); - phrases.push_back(third_str); - phrases.push_back(fourth_str); - phrases.push_back(fifth_str); - phrases.push_back(last_str); - phrases.push_back(before_str); - phrases.push_back(after_str); - phrases.push_back(of_str); - m_element_strings = parse_tree_type(phrases, this->first); // enum first - } - - void element_strings(const collection_type& col) - { - m_element_strings = parse_tree_type(col, this->first); // enum first - } - - //! returns partial_date parsed from stream - template - partial_date_type - get_partial_date_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - day_type d(1); - month_type m(1); - facet.get(sitr, stream_end, a_ios, d); - facet.get(sitr, stream_end, a_ios, m); - - return partial_date_type(d,m); - } - - //! returns nth_kday_of_week parsed from stream - template - nth_kday_type - get_nth_kday_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - typename nth_kday_type::week_num wn; - day_of_week_type wd(0); // no default constructor - month_type m(1); // no default constructor - - match_results mr = m_element_strings.match(sitr, stream_end); - switch(mr.current_match) { - case first : { wn = nth_kday_type::first; break; } - case second : { wn = nth_kday_type::second; break; } - case third : { wn = nth_kday_type::third; break; } - case fourth : { wn = nth_kday_type::fourth; break; } - case fifth : { wn = nth_kday_type::fifth; break; } - default: - { - boost::throw_exception(std::ios_base::failure("Parse failed. No match found for '" + mr.cache + "'")); - BOOST_DATE_TIME_UNREACHABLE_EXPRESSION(wn = nth_kday_type::first); - } - } // week num - facet.get(sitr, stream_end, a_ios, wd); // day_of_week - extract_element(sitr, stream_end, of); // "of" element - facet.get(sitr, stream_end, a_ios, m); // month - - return nth_kday_type(wn, wd, m); - } - - //! returns first_kday_of_week parsed from stream - template - first_kday_type - get_first_kday_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - day_of_week_type wd(0); // no default constructor - month_type m(1); // no default constructor - - extract_element(sitr, stream_end, first); // "first" element - facet.get(sitr, stream_end, a_ios, wd); // day_of_week - extract_element(sitr, stream_end, of); // "of" element - facet.get(sitr, stream_end, a_ios, m); // month - - - return first_kday_type(wd, m); - } - - //! returns last_kday_of_week parsed from stream - template - last_kday_type - get_last_kday_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - day_of_week_type wd(0); // no default constructor - month_type m(1); // no default constructor - - extract_element(sitr, stream_end, last); // "last" element - facet.get(sitr, stream_end, a_ios, wd); // day_of_week - extract_element(sitr, stream_end, of); // "of" element - facet.get(sitr, stream_end, a_ios, m); // month - - - return last_kday_type(wd, m); - } - - //! returns first_kday_of_week parsed from stream - template - kday_before_type - get_kday_before_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - day_of_week_type wd(0); // no default constructor - - facet.get(sitr, stream_end, a_ios, wd); // day_of_week - extract_element(sitr, stream_end, before);// "before" element - - return kday_before_type(wd); - } - - //! returns first_kday_of_week parsed from stream - template - kday_after_type - get_kday_after_type(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - day_of_week_type wd(0); // no default constructor - - facet.get(sitr, stream_end, a_ios, wd); // day_of_week - extract_element(sitr, stream_end, after); // "after" element - - return kday_after_type(wd); - } - - private: - parse_tree_type m_element_strings; - - //! Extracts phrase element from input. Throws ios_base::failure on error. - void extract_element(stream_itr_type& sitr, - stream_itr_type& stream_end, - typename date_generator_parser::phrase_elements ele) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - match_results mr = m_element_strings.match(sitr, stream_end); - if(mr.current_match != ele) { - boost::throw_exception(std::ios_base::failure("Parse failed. No match found for '" + mr.cache + "'")); - } - } - - }; - - template - const typename date_generator_parser::char_type - date_generator_parser::first_string[6] = - {'f','i','r','s','t'}; - template - const typename date_generator_parser::char_type - date_generator_parser::second_string[7] = - {'s','e','c','o','n','d'}; - template - const typename date_generator_parser::char_type - date_generator_parser::third_string[6] = - {'t','h','i','r','d'}; - template - const typename date_generator_parser::char_type - date_generator_parser::fourth_string[7] = - {'f','o','u','r','t','h'}; - template - const typename date_generator_parser::char_type - date_generator_parser::fifth_string[6] = - {'f','i','f','t','h'}; - template - const typename date_generator_parser::char_type - date_generator_parser::last_string[5] = - {'l','a','s','t'}; - template - const typename date_generator_parser::char_type - date_generator_parser::before_string[8] = - {'b','e','f','o','r','e'}; - template - const typename date_generator_parser::char_type - date_generator_parser::after_string[6] = - {'a','f','t','e','r'}; - template - const typename date_generator_parser::char_type - date_generator_parser::of_string[3] = - {'o','f'}; - -} } //namespace - -#endif // DATE_TIME_DATE_GENERATOR_PARSER_HPP__ - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generators.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generators.hpp deleted file mode 100644 index 6d3a4ac0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_generators.hpp +++ /dev/null @@ -1,509 +0,0 @@ -#ifndef DATE_TIME_DATE_GENERATORS_HPP__ -#define DATE_TIME_DATE_GENERATORS_HPP__ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - -/*! @file date_generators.hpp - Definition and implementation of date algorithm templates -*/ - -#include -#include -#include -#include -#include - -namespace boost { -namespace date_time { - - //! Base class for all generators that take a year and produce a date. - /*! This class is a base class for polymorphic function objects that take - a year and produce a concrete date. - @param date_type The type representing a date. This type must - export a calender_type which defines a year_type. - */ - template - class year_based_generator - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::year_type year_type; - year_based_generator() {} - virtual ~year_based_generator() {} - virtual date_type get_date(year_type y) const = 0; - //! Returns a string for use in a POSIX time_zone string - virtual std::string to_string() const =0; - }; - - //! Generates a date by applying the year to the given month and day. - /*! - Example usage: - @code - partial_date pd(1, Jan); - partial_date pd2(70); - date d = pd.get_date(2002); //2002-Jan-01 - date d2 = pd2.get_date(2002); //2002-Mar-10 - @endcode - \ingroup date_alg - */ - template - class partial_date : public year_based_generator - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_type day_type; - typedef typename calendar_type::month_type month_type; - typedef typename calendar_type::year_type year_type; - typedef typename date_type::duration_type duration_type; - typedef typename duration_type::duration_rep duration_rep; - partial_date(day_type d, month_type m) : - day_(d), - month_(m) - {} - //! Partial date created from number of days into year. Range 1-366 - /*! Allowable values range from 1 to 366. 1=Jan1, 366=Dec31. If argument - * exceeds range, partial_date will be created with closest in-range value. - * 60 will always be Feb29, if get_date() is called with a non-leap year - * an exception will be thrown */ - partial_date(duration_rep days) : - day_(1), // default values - month_(1) - { - date_type d1(2000,1,1); - if(days > 1) { - if(days > 366) // prevents wrapping - { - days = 366; - } - days = days - 1; - duration_type dd(days); - d1 = d1 + dd; - } - day_ = d1.day(); - month_ = d1.month(); - } - //! Return a concrete date when provided with a year specific year. - /*! Will throw an 'invalid_argument' exception if a partial_date object, - * instantiated with Feb-29, has get_date called with a non-leap year. - * Example: - * @code - * partial_date pd(29, Feb); - * pd.get_date(2003); // throws invalid_argument exception - * pg.get_date(2000); // returns 2000-2-29 - * @endcode - */ - date_type get_date(year_type y) const - { - if((day_ == 29) && (month_ == 2) && !(calendar_type::is_leap_year(y))) { - std::ostringstream ss; - ss << "No Feb 29th in given year of " << y << "."; - boost::throw_exception(std::invalid_argument(ss.str())); - } - return date_type(y, month_, day_); - } - date_type operator()(year_type y) const - { - return get_date(y); - //return date_type(y, month_, day_); - } - bool operator==(const partial_date& rhs) const - { - return (month_ == rhs.month_) && (day_ == rhs.day_); - } - bool operator<(const partial_date& rhs) const - { - if (month_ < rhs.month_) return true; - if (month_ > rhs.month_) return false; - //months are equal - return (day_ < rhs.day_); - } - - // added for streaming purposes - month_type month() const - { - return month_; - } - day_type day() const - { - return day_; - } - - //! Returns string suitable for use in POSIX time zone string - /*! Returns string formatted with up to 3 digits: - * Jan-01 == "0" - * Feb-29 == "58" - * Dec-31 == "365" */ - virtual std::string to_string() const - { - std::ostringstream ss; - date_type d(2004, month_, day_); - unsigned short c = d.day_of_year(); - c--; // numbered 0-365 while day_of_year is 1 based... - ss << c; - return ss.str(); - } - private: - day_type day_; - month_type month_; - }; - - - //! Returns nth arg as string. 1 -> "first", 2 -> "second", max is 5. - BOOST_DATE_TIME_DECL const char* nth_as_str(int n); - - //! Useful generator functor for finding holidays - /*! Based on the idea in Cal. Calc. for finding holidays that are - * the 'first Monday of September'. When instantiated with - * 'fifth' kday of month, the result will be the last kday of month - * which can be the fourth or fifth depending on the structure of - * the month. - * - * The algorithm here basically guesses for the first - * day of the month. Then finds the first day of the correct - * type. That is, if the first of the month is a Tuesday - * and it needs Wenesday then we simply increment by a day - * and then we can add the length of a week until we get - * to the 'nth kday'. There are probably more efficient - * algorithms based on using a mod 7, but this one works - * reasonably well for basic applications. - * \ingroup date_alg - */ - template - class nth_kday_of_month : public year_based_generator - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_of_week_type day_of_week_type; - typedef typename calendar_type::month_type month_type; - typedef typename calendar_type::year_type year_type; - typedef typename date_type::duration_type duration_type; - enum week_num {first=1, second, third, fourth, fifth}; - nth_kday_of_month(week_num week_no, - day_of_week_type dow, - month_type m) : - month_(m), - wn_(week_no), - dow_(dow) - {} - //! Return a concrete date when provided with a year specific year. - date_type get_date(year_type y) const - { - date_type d(y, month_, 1); //first day of month - duration_type one_day(1); - duration_type one_week(7); - while (dow_ != d.day_of_week()) { - d = d + one_day; - } - int week = 1; - while (week < wn_) { - d = d + one_week; - week++; - } - // remove wrapping to next month behavior - if(d.month() != month_) { - d = d - one_week; - } - return d; - } - // added for streaming - month_type month() const - { - return month_; - } - week_num nth_week() const - { - return wn_; - } - day_of_week_type day_of_week() const - { - return dow_; - } - const char* nth_week_as_str() const - { - return nth_as_str(wn_); - } - //! Returns string suitable for use in POSIX time zone string - /*! Returns a string formatted as "M4.3.0" ==> 3rd Sunday in April. */ - virtual std::string to_string() const - { - std::ostringstream ss; - ss << 'M' - << static_cast(month_) << '.' - << static_cast(wn_) << '.' - << static_cast(dow_); - return ss.str(); - } - private: - month_type month_; - week_num wn_; - day_of_week_type dow_; - }; - - //! Useful generator functor for finding holidays and daylight savings - /*! Similar to nth_kday_of_month, but requires less paramters - * \ingroup date_alg - */ - template - class first_kday_of_month : public year_based_generator - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_of_week_type day_of_week_type; - typedef typename calendar_type::month_type month_type; - typedef typename calendar_type::year_type year_type; - typedef typename date_type::duration_type duration_type; - //!Specify the first 'Sunday' in 'April' spec - /*!@param dow The day of week, eg: Sunday, Monday, etc - * @param m The month of the year, eg: Jan, Feb, Mar, etc - */ - first_kday_of_month(day_of_week_type dow, month_type m) : - month_(m), - dow_(dow) - {} - //! Return a concrete date when provided with a year specific year. - date_type get_date(year_type year) const - { - date_type d(year, month_,1); - duration_type one_day(1); - while (dow_ != d.day_of_week()) { - d = d + one_day; - } - return d; - } - // added for streaming - month_type month() const - { - return month_; - } - day_of_week_type day_of_week() const - { - return dow_; - } - //! Returns string suitable for use in POSIX time zone string - /*! Returns a string formatted as "M4.1.0" ==> 1st Sunday in April. */ - virtual std::string to_string() const - { - std::ostringstream ss; - ss << 'M' - << static_cast(month_) << '.' - << 1 << '.' - << static_cast(dow_); - return ss.str(); - } - private: - month_type month_; - day_of_week_type dow_; - }; - - - - //! Calculate something like Last Sunday of January - /*! Useful generator functor for finding holidays and daylight savings - * Get the last day of the month and then calculate the difference - * to the last previous day. - * @param date_type A date class that exports day_of_week, month_type, etc. - * \ingroup date_alg - */ - template - class last_kday_of_month : public year_based_generator - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_of_week_type day_of_week_type; - typedef typename calendar_type::month_type month_type; - typedef typename calendar_type::year_type year_type; - typedef typename date_type::duration_type duration_type; - //!Specify the date spec like last 'Sunday' in 'April' spec - /*!@param dow The day of week, eg: Sunday, Monday, etc - * @param m The month of the year, eg: Jan, Feb, Mar, etc - */ - last_kday_of_month(day_of_week_type dow, month_type m) : - month_(m), - dow_(dow) - {} - //! Return a concrete date when provided with a year specific year. - date_type get_date(year_type year) const - { - date_type d(year, month_, calendar_type::end_of_month_day(year,month_)); - duration_type one_day(1); - while (dow_ != d.day_of_week()) { - d = d - one_day; - } - return d; - } - // added for streaming - month_type month() const - { - return month_; - } - day_of_week_type day_of_week() const - { - return dow_; - } - //! Returns string suitable for use in POSIX time zone string - /*! Returns a string formatted as "M4.5.0" ==> last Sunday in April. */ - virtual std::string to_string() const - { - std::ostringstream ss; - ss << 'M' - << static_cast(month_) << '.' - << 5 << '.' - << static_cast(dow_); - return ss.str(); - } - private: - month_type month_; - day_of_week_type dow_; - }; - - - //! Calculate something like "First Sunday after Jan 1,2002 - /*! Date generator that takes a date and finds kday after - *@code - typedef boost::date_time::first_kday_after firstkdayafter; - firstkdayafter fkaf(Monday); - fkaf.get_date(date(2002,Feb,1)); - @endcode - * \ingroup date_alg - */ - template - class first_kday_after - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_of_week_type day_of_week_type; - typedef typename date_type::duration_type duration_type; - first_kday_after(day_of_week_type dow) : - dow_(dow) - {} - //! Return next kday given. - date_type get_date(date_type start_day) const - { - duration_type one_day(1); - date_type d = start_day + one_day; - while (dow_ != d.day_of_week()) { - d = d + one_day; - } - return d; - } - // added for streaming - day_of_week_type day_of_week() const - { - return dow_; - } - private: - day_of_week_type dow_; - }; - - //! Calculate something like "First Sunday before Jan 1,2002 - /*! Date generator that takes a date and finds kday after - *@code - typedef boost::date_time::first_kday_before firstkdaybefore; - firstkdaybefore fkbf(Monday); - fkbf.get_date(date(2002,Feb,1)); - @endcode - * \ingroup date_alg - */ - template - class first_kday_before - { - public: - typedef typename date_type::calendar_type calendar_type; - typedef typename calendar_type::day_of_week_type day_of_week_type; - typedef typename date_type::duration_type duration_type; - first_kday_before(day_of_week_type dow) : - dow_(dow) - {} - //! Return next kday given. - date_type get_date(date_type start_day) const - { - duration_type one_day(1); - date_type d = start_day - one_day; - while (dow_ != d.day_of_week()) { - d = d - one_day; - } - return d; - } - // added for streaming - day_of_week_type day_of_week() const - { - return dow_; - } - private: - day_of_week_type dow_; - }; - - //! Calculates the number of days until the next weekday - /*! Calculates the number of days until the next weekday. - * If the date given falls on a Sunday and the given weekday - * is Tuesday the result will be 2 days */ - template - inline - typename date_type::duration_type days_until_weekday(const date_type& d, const weekday_type& wd) - { - typedef typename date_type::duration_type duration_type; - duration_type wks(0); - duration_type dd(wd.as_number() - d.day_of_week().as_number()); - if(dd.is_negative()){ - wks = duration_type(7); - } - return dd + wks; - } - - //! Calculates the number of days since the previous weekday - /*! Calculates the number of days since the previous weekday - * If the date given falls on a Sunday and the given weekday - * is Tuesday the result will be 5 days. The answer will be a positive - * number because Tuesday is 5 days before Sunday, not -5 days before. */ - template - inline - typename date_type::duration_type days_before_weekday(const date_type& d, const weekday_type& wd) - { - typedef typename date_type::duration_type duration_type; - duration_type wks(0); - duration_type dd(wd.as_number() - d.day_of_week().as_number()); - if(dd.days() > 0){ - wks = duration_type(7); - } - // we want a number of days, not an offset. The value returned must - // be zero or larger. - return (-dd + wks); - } - - //! Generates a date object representing the date of the following weekday from the given date - /*! Generates a date object representing the date of the following - * weekday from the given date. If the date given is 2004-May-9 - * (a Sunday) and the given weekday is Tuesday then the resulting date - * will be 2004-May-11. */ - template - inline - date_type next_weekday(const date_type& d, const weekday_type& wd) - { - return d + days_until_weekday(d, wd); - } - - //! Generates a date object representing the date of the previous weekday from the given date - /*! Generates a date object representing the date of the previous - * weekday from the given date. If the date given is 2004-May-9 - * (a Sunday) and the given weekday is Tuesday then the resulting date - * will be 2004-May-4. */ - template - inline - date_type previous_weekday(const date_type& d, const weekday_type& wd) - { - return d - days_before_weekday(d, wd); - } - -} } //namespace date_time - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_iterator.hpp deleted file mode 100644 index c8ec50ee..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_iterator.hpp +++ /dev/null @@ -1,101 +0,0 @@ -#ifndef DATE_ITERATOR_HPP___ -#define DATE_ITERATOR_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - -#include - -namespace boost { -namespace date_time { - //! An iterator over dates with varying resolution (day, week, month, year, etc) - enum date_resolutions {day, week, months, year, decade, century, NumDateResolutions}; - - //! Base date iterator type - /*! This class provides the skeleton for the creation of iterators. - * New and interesting interators can be created by plugging in a new - * function that derives the next value from the current state. - * generation of various types of -based information. - * - * Template Parameters - * - * date_type - * - * The date_type is a concrete date_type. The date_type must - * define a duration_type and a calendar_type. - */ - template - class date_itr_base { - // works, but benefit unclear at the moment - // class date_itr_base : public std::iterator{ - public: - typedef typename date_type::duration_type duration_type; - typedef date_type value_type; - typedef std::input_iterator_tag iterator_category; - - date_itr_base(date_type d) : current_(d) {} - virtual ~date_itr_base() {} - date_itr_base& operator++() - { - current_ = current_ + get_offset(current_); - return *this; - } - date_itr_base& operator--() - { - current_ = current_ + get_neg_offset(current_); - return *this; - } - virtual duration_type get_offset(const date_type& current) const=0; - virtual duration_type get_neg_offset(const date_type& current) const=0; - date_type operator*() {return current_;} - date_type* operator->() {return ¤t_;} - bool operator< (const date_type& d) {return current_ < d;} - bool operator<= (const date_type& d) {return current_ <= d;} - bool operator> (const date_type& d) {return current_ > d;} - bool operator>= (const date_type& d) {return current_ >= d;} - bool operator== (const date_type& d) {return current_ == d;} - bool operator!= (const date_type& d) {return current_ != d;} - private: - date_type current_; - }; - - //! Overrides the base date iterator providing hook for functors - /* - * offset_functor - * - * The offset functor must define a get_offset function that takes the - * current point in time and calculates and offset. - * - */ - template - class date_itr : public date_itr_base { - public: - typedef typename date_type::duration_type duration_type; - date_itr(date_type d, int factor=1) : - date_itr_base(d), - of_(factor) - {} - private: - virtual duration_type get_offset(const date_type& current) const - { - return of_.get_offset(current); - } - virtual duration_type get_neg_offset(const date_type& current) const - { - return of_.get_neg_offset(current); - } - offset_functor of_; - }; - - - -} } //namespace date_time - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_names_put.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_names_put.hpp deleted file mode 100644 index 32aeb36f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_names_put.hpp +++ /dev/null @@ -1,320 +0,0 @@ -#ifndef DATE_TIME_DATE_NAMES_PUT_HPP___ -#define DATE_TIME_DATE_NAMES_PUT_HPP___ - -/* Copyright (c) 2002-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - - -#include "boost/date_time/locale_config.hpp" // set BOOST_DATE_TIME_NO_LOCALE - -#ifndef BOOST_DATE_TIME_NO_LOCALE - -#include "boost/date_time/special_defs.hpp" -#include "boost/date_time/date_defs.hpp" -#include "boost/date_time/parse_format_base.hpp" -#include "boost/lexical_cast.hpp" -#include - - -namespace boost { -namespace date_time { - - //! Output facet base class for gregorian dates. - /*! This class is a base class for date facets used to localize the - * names of months and the names of days in the week. - * - * Requirements of Config - * - define an enumeration month_enum that enumerates the months. - * The enumeration should be '1' based eg: Jan==1 - * - define as_short_string and as_long_string - * - * (see langer & kreft p334). - * - */ - template > - class date_names_put : public std::locale::facet - { - public: - date_names_put() {} - typedef OutputIterator iter_type; - typedef typename Config::month_type month_type; - typedef typename Config::month_enum month_enum; - typedef typename Config::weekday_enum weekday_enum; - typedef typename Config::special_value_enum special_value_enum; - //typedef typename Config::format_type format_type; - typedef std::basic_string string_type; - typedef charT char_type; - static const char_type default_special_value_names[3][17]; - static const char_type separator[2]; - - static std::locale::id id; - -#if defined (__SUNPRO_CC) && defined (_RWSTD_VER) - std::locale::id& __get_id (void) const { return id; } -#endif - - void put_special_value(iter_type& oitr, special_value_enum sv) const - { - do_put_special_value(oitr, sv); - } - void put_month_short(iter_type& oitr, month_enum moy) const - { - do_put_month_short(oitr, moy); - } - void put_month_long(iter_type& oitr, month_enum moy) const - { - do_put_month_long(oitr, moy); - } - void put_weekday_short(iter_type& oitr, weekday_enum wd) const - { - do_put_weekday_short(oitr, wd); - } - void put_weekday_long(iter_type& oitr, weekday_enum wd) const - { - do_put_weekday_long(oitr, wd); - } - bool has_date_sep_chars() const - { - return do_has_date_sep_chars(); - } - void year_sep_char(iter_type& oitr) const - { - do_year_sep_char(oitr); - } - //! char between year-month - void month_sep_char(iter_type& oitr) const - { - do_month_sep_char(oitr); - } - //! Char to separate month-day - void day_sep_char(iter_type& oitr) const - { - do_day_sep_char(oitr); - } - //! Determines the order to put the date elements - ymd_order_spec date_order() const - { - return do_date_order(); - } - //! Determines if month is displayed as integer, short or long string - month_format_spec month_format() const - { - return do_month_format(); - } - - protected: - //! Default facet implementation uses month_type defaults - virtual void do_put_month_short(iter_type& oitr, month_enum moy) const - { - month_type gm(moy); - charT c = '\0'; - put_string(oitr, gm.as_short_string(c)); - } - //! Default facet implementation uses month_type defaults - virtual void do_put_month_long(iter_type& oitr, - month_enum moy) const - { - month_type gm(moy); - charT c = '\0'; - put_string(oitr, gm.as_long_string(c)); - } - //! Default facet implementation for special value types - virtual void do_put_special_value(iter_type& oitr, special_value_enum sv) const - { - if(sv <= 2) { // only output not_a_date_time, neg_infin, or pos_infin - string_type s(default_special_value_names[sv]); - put_string(oitr, s); - } - } - virtual void do_put_weekday_short(iter_type&, weekday_enum) const - { - } - virtual void do_put_weekday_long(iter_type&, weekday_enum) const - { - } - virtual bool do_has_date_sep_chars() const - { - return true; - } - virtual void do_year_sep_char(iter_type& oitr) const - { - string_type s(separator); - put_string(oitr, s); - } - //! char between year-month - virtual void do_month_sep_char(iter_type& oitr) const - { - string_type s(separator); - put_string(oitr, s); - } - //! Char to separate month-day - virtual void do_day_sep_char(iter_type& oitr) const - { - string_type s(separator); //put in '-' - put_string(oitr, s); - } - //! Default for date order - virtual ymd_order_spec do_date_order() const - { - return ymd_order_iso; - } - //! Default month format - virtual month_format_spec do_month_format() const - { - return month_as_short_string; - } - void put_string(iter_type& oi, const charT* const s) const - { - string_type s1(boost::lexical_cast(s)); - typename string_type::iterator si,end; - for (si=s1.begin(), end=s1.end(); si!=end; si++, oi++) { - *oi = *si; - } - } - void put_string(iter_type& oi, const string_type& s1) const - { - typename string_type::const_iterator si,end; - for (si=s1.begin(), end=s1.end(); si!=end; si++, oi++) { - *oi = *si; - } - } - }; - - template - const typename date_names_put::char_type - date_names_put::default_special_value_names[3][17] = { - {'n','o','t','-','a','-','d','a','t','e','-','t','i','m','e'}, - {'-','i','n','f','i','n','i','t','y'}, - {'+','i','n','f','i','n','i','t','y'} }; - - template - const typename date_names_put::char_type - date_names_put::separator[2] = - {'-', '\0'} ; - - - //! Generate storage location for a std::locale::id - template - std::locale::id date_names_put::id; - - //! A date name output facet that takes an array of char* to define strings - template > - class all_date_names_put : public date_names_put - { - public: - all_date_names_put(const charT* const month_short_names[], - const charT* const month_long_names[], - const charT* const special_value_names[], - const charT* const weekday_short_names[], - const charT* const weekday_long_names[], - charT separator_char = '-', - ymd_order_spec order_spec = ymd_order_iso, - month_format_spec month_format = month_as_short_string) : - month_short_names_(month_short_names), - month_long_names_(month_long_names), - special_value_names_(special_value_names), - weekday_short_names_(weekday_short_names), - weekday_long_names_(weekday_long_names), - order_spec_(order_spec), - month_format_spec_(month_format) - { - separator_char_[0] = separator_char; - separator_char_[1] = '\0'; - - } - typedef OutputIterator iter_type; - typedef typename Config::month_enum month_enum; - typedef typename Config::weekday_enum weekday_enum; - typedef typename Config::special_value_enum special_value_enum; - - const charT* const* get_short_month_names() const - { - return month_short_names_; - } - const charT* const* get_long_month_names() const - { - return month_long_names_; - } - const charT* const* get_special_value_names() const - { - return special_value_names_; - } - const charT* const* get_short_weekday_names()const - { - return weekday_short_names_; - } - const charT* const* get_long_weekday_names()const - { - return weekday_long_names_; - } - - protected: - //! Generic facet that takes array of chars - virtual void do_put_month_short(iter_type& oitr, month_enum moy) const - { - this->put_string(oitr, month_short_names_[moy-1]); - } - //! Long month names - virtual void do_put_month_long(iter_type& oitr, month_enum moy) const - { - this->put_string(oitr, month_long_names_[moy-1]); - } - //! Special values names - virtual void do_put_special_value(iter_type& oitr, special_value_enum sv) const - { - this->put_string(oitr, special_value_names_[sv]); - } - virtual void do_put_weekday_short(iter_type& oitr, weekday_enum wd) const - { - this->put_string(oitr, weekday_short_names_[wd]); - } - virtual void do_put_weekday_long(iter_type& oitr, weekday_enum wd) const - { - this->put_string(oitr, weekday_long_names_[wd]); - } - //! char between year-month - virtual void do_month_sep_char(iter_type& oitr) const - { - this->put_string(oitr, separator_char_); - } - //! Char to separate month-day - virtual void do_day_sep_char(iter_type& oitr) const - { - this->put_string(oitr, separator_char_); - } - //! Set the date ordering - virtual ymd_order_spec do_date_order() const - { - return order_spec_; - } - //! Set the date ordering - virtual month_format_spec do_month_format() const - { - return month_format_spec_; - } - - private: - const charT* const* month_short_names_; - const charT* const* month_long_names_; - const charT* const* special_value_names_; - const charT* const* weekday_short_names_; - const charT* const* weekday_long_names_; - charT separator_char_[2]; - ymd_order_spec order_spec_; - month_format_spec month_format_spec_; - }; - -} } //namespace boost::date_time - -#endif //BOOST_NO_STD_LOCALE - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_parsing.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/date_parsing.hpp deleted file mode 100644 index 35ec8e43..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/date_parsing.hpp +++ /dev/null @@ -1,318 +0,0 @@ -#ifndef _DATE_TIME_DATE_PARSING_HPP___ -#define _DATE_TIME_DATE_PARSING_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-30 16:25:22 -0700 (Sun, 30 Sep 2012) $ - */ - -#include -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_DATE_TIME_NO_LOCALE) -#include // ::tolower(int) -#else -#include // std::tolower(char, locale) -#endif - -namespace boost { -namespace date_time { - - //! A function to replace the std::transform( , , ,tolower) construct - /*! This function simply takes a string, and changes all the characters - * in that string to lowercase (according to the default system locale). - * In the event that a compiler does not support locales, the old - * C style tolower() is used. - */ - inline - std::string - convert_to_lower(std::string inp) - { -#if !defined(BOOST_DATE_TIME_NO_LOCALE) - const std::locale loc(std::locale::classic()); -#endif - std::string::size_type i = 0, n = inp.length(); - for (; i < n; ++i) { - inp[i] = -#if defined(BOOST_DATE_TIME_NO_LOCALE) - static_cast(std::tolower(inp[i])); -#else - // tolower and others were brought in to std for borland >= v564 - // in compiler_config.hpp - std::tolower(inp[i], loc); -#endif - } - return inp; - } - - //! Helper function for parse_date. - /* Used by-value parameter because we change the string and may - * want to preserve the original argument */ - template - inline unsigned short - month_str_to_ushort(std::string const& s) { - if((s.at(0) >= '0') && (s.at(0) <= '9')) { - return boost::lexical_cast(s); - } - else { - std::string str = convert_to_lower(s); - typename month_type::month_map_ptr_type ptr = month_type::get_month_map_ptr(); - typename month_type::month_map_type::iterator iter = ptr->find(str); - if(iter != ptr->end()) { // required for STLport - return iter->second; - } - } - return 13; // intentionally out of range - name not found - } - - //! Find index of a string in either of 2 arrays - /*! find_match searches both arrays for a match to 's'. Both arrays - * must contain 'size' elements. The index of the match is returned. - * If no match is found, 'size' is returned. - * Ex. "Jan" returns 0, "Dec" returns 11, "Tue" returns 2. - * 'size' can be sent in with: (greg_month::max)() (which 12), - * (greg_weekday::max)() + 1 (which is 7) or date_time::NumSpecialValues */ - template - short find_match(const charT* const* short_names, - const charT* const* long_names, - short size, - const std::basic_string& s) { - for(short i = 0; i < size; ++i){ - if(short_names[i] == s || long_names[i] == s){ - return i; - } - } - return size; // not-found, return a value out of range - } - - //! Generic function to parse a delimited date (eg: 2002-02-10) - /*! Accepted formats are: "2003-02-10" or " 2003-Feb-10" or - * "2003-Feburary-10" - * The order in which the Month, Day, & Year appear in the argument - * string can be accomodated by passing in the appropriate ymd_order_spec - */ - template - date_type - parse_date(const std::string& s, int order_spec = ymd_order_iso) { - std::string spec_str; - if(order_spec == ymd_order_iso) { - spec_str = "ymd"; - } - else if(order_spec == ymd_order_dmy) { - spec_str = "dmy"; - } - else { // (order_spec == ymd_order_us) - spec_str = "mdy"; - } - - typedef typename date_type::year_type year_type; - typedef typename date_type::month_type month_type; - unsigned pos = 0; - unsigned short year(0), month(0), day(0); - typedef typename std::basic_string::traits_type traits_type; - typedef boost::char_separator char_separator_type; - typedef boost::tokenizer::const_iterator, - std::basic_string > tokenizer; - typedef boost::tokenizer::const_iterator, - std::basic_string >::iterator tokenizer_iterator; - // may need more delimiters, these work for the regression tests - const char sep_char[] = {',','-','.',' ','/','\0'}; - char_separator_type sep(sep_char); - tokenizer tok(s,sep); - for(tokenizer_iterator beg=tok.begin(); - beg!=tok.end() && pos < spec_str.size(); - ++beg, ++pos) { - switch(spec_str.at(pos)) { - case 'y': - { - year = boost::lexical_cast(*beg); - break; - } - case 'm': - { - month = month_str_to_ushort(*beg); - break; - } - case 'd': - { - day = boost::lexical_cast(*beg); - break; - } - default: break; - } //switch - } - return date_type(year, month, day); - } - - //! Generic function to parse undelimited date (eg: 20020201) - template - date_type - parse_undelimited_date(const std::string& s) { - int offsets[] = {4,2,2}; - int pos = 0; - typedef typename date_type::year_type year_type; - //typename date_type::ymd_type ymd((year_type::min)(),1,1); - unsigned short y = 0, m = 0, d = 0; - - /* The two bool arguments state that parsing will not wrap - * (only the first 8 characters will be parsed) and partial - * strings will not be parsed. - * Ex: - * "2005121" will parse 2005 & 12, but not the "1" */ - boost::offset_separator osf(offsets, offsets+3, false, false); - - typedef typename boost::tokenizer::const_iterator, - std::basic_string > tokenizer_type; - tokenizer_type tok(s, osf); - for(typename tokenizer_type::iterator ti=tok.begin(); ti!=tok.end();++ti) { - unsigned short i = boost::lexical_cast(*ti); - switch(pos) { - case 0: y = i; break; - case 1: m = i; break; - case 2: d = i; break; - default: break; - } - pos++; - } - return date_type(y,m,d); - } - - //! Helper function for 'date gregorian::from_stream()' - /*! Creates a string from the iterators that reference the - * begining & end of a char[] or string. All elements are - * used in output string */ - template - inline - date_type - from_stream_type(iterator_type& beg, - iterator_type const& end, - char) - { - std::ostringstream ss; - while(beg != end) { - ss << *beg++; - } - return parse_date(ss.str()); - } - - //! Helper function for 'date gregorian::from_stream()' - /*! Returns the first string found in the stream referenced by the - * begining & end iterators */ - template - inline - date_type - from_stream_type(iterator_type& beg, - iterator_type const& /* end */, - std::string const&) - { - return parse_date(*beg); - } - - /* I believe the wchar stuff would be best elsewhere, perhaps in - * parse_date<>()? In the mean time this gets us started... */ - //! Helper function for 'date gregorian::from_stream()' - /*! Creates a string from the iterators that reference the - * begining & end of a wstring. All elements are - * used in output string */ - template - inline - date_type from_stream_type(iterator_type& beg, - iterator_type const& end, - wchar_t) - { - std::ostringstream ss; -#if !defined(BOOST_DATE_TIME_NO_LOCALE) - std::locale loc; - std::ctype const& fac = std::use_facet >(loc); - while(beg != end) { - ss << fac.narrow(*beg++, 'X'); // 'X' will cause exception to be thrown - } -#else - while(beg != end) { - char c = 'X'; // 'X' will cause exception to be thrown - const wchar_t wc = *beg++; - if (wc >= 0 && wc <= 127) - c = static_cast< char >(wc); - ss << c; - } -#endif - return parse_date(ss.str()); - } -#ifndef BOOST_NO_STD_WSTRING - //! Helper function for 'date gregorian::from_stream()' - /*! Creates a string from the first wstring found in the stream - * referenced by the begining & end iterators */ - template - inline - date_type - from_stream_type(iterator_type& beg, - iterator_type const& /* end */, - std::wstring const&) { - std::wstring ws = *beg; - std::ostringstream ss; - std::wstring::iterator wsb = ws.begin(), wse = ws.end(); -#if !defined(BOOST_DATE_TIME_NO_LOCALE) - std::locale loc; - std::ctype const& fac = std::use_facet >(loc); - while(wsb != wse) { - ss << fac.narrow(*wsb++, 'X'); // 'X' will cause exception to be thrown - } -#else - while(wsb != wse) { - char c = 'X'; // 'X' will cause exception to be thrown - const wchar_t wc = *wsb++; - if (wc >= 0 && wc <= 127) - c = static_cast< char >(wc); - ss << c; - } -#endif - return parse_date(ss.str()); - } -#endif // BOOST_NO_STD_WSTRING -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - // This function cannot be compiled with MSVC 6.0 due to internal compiler shorcomings -#else - //! function called by wrapper functions: date_period_from_(w)string() - template - period - from_simple_string_type(const std::basic_string& s){ - typedef typename std::basic_string::traits_type traits_type; - typedef typename boost::char_separator char_separator; - typedef typename boost::tokenizer::const_iterator, - std::basic_string > tokenizer; - const charT sep_list[4] = {'[','/',']','\0'}; - char_separator sep(sep_list); - tokenizer tokens(s, sep); - typename tokenizer::iterator tok_it = tokens.begin(); - std::basic_string date_string = *tok_it; - // get 2 string iterators and generate a date from them - typename std::basic_string::iterator date_string_start = date_string.begin(), - date_string_end = date_string.end(); - typedef typename std::iterator_traits::iterator>::value_type value_type; - date_type d1 = from_stream_type(date_string_start, date_string_end, value_type()); - date_string = *(++tok_it); // next token - date_string_start = date_string.begin(), date_string_end = date_string.end(); - date_type d2 = from_stream_type(date_string_start, date_string_end, value_type()); - return period(d1, d2); - } -#endif - -} } //namespace date_time - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/dst_rules.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/dst_rules.hpp deleted file mode 100644 index cf65c162..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/dst_rules.hpp +++ /dev/null @@ -1,391 +0,0 @@ -#ifndef DATE_TIME_DST_RULES_HPP__ -#define DATE_TIME_DST_RULES_HPP__ - -/* Copyright (c) 2002,2003, 2007 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-30 16:25:22 -0700 (Sun, 30 Sep 2012) $ - */ - -/*! @file dst_rules.hpp - Contains template class to provide static dst rule calculations -*/ - -#include "boost/date_time/date_generators.hpp" -#include "boost/date_time/period.hpp" -#include "boost/date_time/date_defs.hpp" -#include - -namespace boost { - namespace date_time { - - enum time_is_dst_result {is_not_in_dst, is_in_dst, - ambiguous, invalid_time_label}; - - - //! Dynamic class used to caluclate dst transition information - template - class dst_calculator - { - public: - typedef time_duration_type_ time_duration_type; - typedef date_type_ date_type; - - //! Check the local time offset when on dst start day - /*! On this dst transition, the time label between - * the transition boundary and the boudary + the offset - * are invalid times. If before the boundary then still - * not in dst. - *@param time_of_day Time offset in the day for the local time - *@param dst_start_offset_minutes Local day offset for start of dst - *@param dst_length_minutes Number of minutes to adjust clock forward - *@retval status of time label w.r.t. dst - */ - static time_is_dst_result - process_local_dst_start_day(const time_duration_type& time_of_day, - unsigned int dst_start_offset_minutes, - long dst_length_minutes) - { - //std::cout << "here" << std::endl; - if (time_of_day < time_duration_type(0,dst_start_offset_minutes,0)) { - return is_not_in_dst; - } - long offset = dst_start_offset_minutes + dst_length_minutes; - if (time_of_day >= time_duration_type(0,offset,0)) { - return is_in_dst; - } - return invalid_time_label; - } - - //! Check the local time offset when on the last day of dst - /*! This is the calculation for the DST end day. On that day times - * prior to the conversion time - dst_length (1 am in US) are still - * in dst. Times between the above and the switch time are - * ambiguous. Times after the start_offset are not in dst. - *@param time_of_day Time offset in the day for the local time - *@param dst_end_offset_minutes Local time of day for end of dst - *@retval status of time label w.r.t. dst - */ - static time_is_dst_result - process_local_dst_end_day(const time_duration_type& time_of_day, - unsigned int dst_end_offset_minutes, - long dst_length_minutes) - { - //in US this will be 60 so offset in day is 1,0,0 - int offset = dst_end_offset_minutes-dst_length_minutes; - if (time_of_day < time_duration_type(0,offset,0)) { - return is_in_dst; - } - if (time_of_day >= time_duration_type(0,dst_end_offset_minutes,0)) { - return is_not_in_dst; - } - return ambiguous; - } - - //! Calculates if the given local time is dst or not - /*! Determines if the time is really in DST or not. Also checks for - * invalid and ambiguous. - * @param current_day The day to check for dst - * @param time_of_day Time offset within the day to check - * @param dst_start_day Starting day of dst for the given locality - * @param dst_start_offset Time offset within day for dst boundary - * @param dst_end_day Ending day of dst for the given locality - * @param dst_end_offset Time offset within day given in dst for dst boundary - * @param dst_length lenght of dst adjusment - * @retval The time is either ambiguous, invalid, in dst, or not in dst - */ - static time_is_dst_result - local_is_dst(const date_type& current_day, - const time_duration_type& time_of_day, - const date_type& dst_start_day, - const time_duration_type& dst_start_offset, - const date_type& dst_end_day, - const time_duration_type& dst_end_offset, - const time_duration_type& dst_length_minutes) - { - unsigned int start_minutes = - dst_start_offset.hours() * 60 + dst_start_offset.minutes(); - unsigned int end_minutes = - dst_end_offset.hours() * 60 + dst_end_offset.minutes(); - long length_minutes = - dst_length_minutes.hours() * 60 + dst_length_minutes.minutes(); - - return local_is_dst(current_day, time_of_day, - dst_start_day, start_minutes, - dst_end_day, end_minutes, - length_minutes); - } - - //! Calculates if the given local time is dst or not - /*! Determines if the time is really in DST or not. Also checks for - * invalid and ambiguous. - * @param current_day The day to check for dst - * @param time_of_day Time offset within the day to check - * @param dst_start_day Starting day of dst for the given locality - * @param dst_start_offset_minutes Offset within day for dst - * boundary (eg 120 for US which is 02:00:00) - * @param dst_end_day Ending day of dst for the given locality - * @param dst_end_offset_minutes Offset within day given in dst for dst - * boundary (eg 120 for US which is 02:00:00) - * @param dst_length_minutes Length of dst adjusment (eg: 60 for US) - * @retval The time is either ambiguous, invalid, in dst, or not in dst - */ - static time_is_dst_result - local_is_dst(const date_type& current_day, - const time_duration_type& time_of_day, - const date_type& dst_start_day, - unsigned int dst_start_offset_minutes, - const date_type& dst_end_day, - unsigned int dst_end_offset_minutes, - long dst_length_minutes) - { - //in northern hemisphere dst is in the middle of the year - if (dst_start_day < dst_end_day) { - if ((current_day > dst_start_day) && (current_day < dst_end_day)) { - return is_in_dst; - } - if ((current_day < dst_start_day) || (current_day > dst_end_day)) { - return is_not_in_dst; - } - } - else {//southern hemisphere dst is at begining /end of year - if ((current_day < dst_start_day) && (current_day > dst_end_day)) { - return is_not_in_dst; - } - if ((current_day > dst_start_day) || (current_day < dst_end_day)) { - return is_in_dst; - } - } - - if (current_day == dst_start_day) { - return process_local_dst_start_day(time_of_day, - dst_start_offset_minutes, - dst_length_minutes); - } - - if (current_day == dst_end_day) { - return process_local_dst_end_day(time_of_day, - dst_end_offset_minutes, - dst_length_minutes); - } - //you should never reach this statement - return invalid_time_label; - } - - }; - - - //! Compile-time configurable daylight savings time calculation engine - /* This template provides the ability to configure a daylight savings - * calculation at compile time covering all the cases. Unfortunately - * because of the number of dimensions related to daylight savings - * calculation the number of parameters is high. In addition, the - * start and end transition rules are complex types that specify - * an algorithm for calculation of the starting day and ending - * day of daylight savings time including the month and day - * specifications (eg: last sunday in October). - * - * @param date_type A type that represents dates, typically gregorian::date - * @param time_duration_type Used for the offset in the day calculations - * @param dst_traits A set of traits that define the rules of dst - * calculation. The dst_trait must include the following: - * start_rule_functor - Rule to calculate the starting date of a - * dst transition (eg: last_kday_of_month). - * start_day - static function that returns month of dst start for - * start_rule_functor - * start_month -static function that returns day or day of week for - * dst start of dst - * end_rule_functor - Rule to calculate the end of dst day. - * end_day - static fucntion that returns end day for end_rule_functor - * end_month - static function that returns end month for end_rule_functor - * dst_start_offset_minutes - number of minutes from start of day to transition to dst -- 120 (or 2:00 am) is typical for the U.S. and E.U. - * dst_start_offset_minutes - number of minutes from start of day to transition off of dst -- 180 (or 3:00 am) is typical for E.U. - * dst_length_minutes - number of minutes that dst shifts clock - */ - template - class dst_calc_engine - { - public: - typedef typename date_type::year_type year_type; - typedef typename date_type::calendar_type calendar_type; - typedef dst_calculator dstcalc; - - //! Calculates if the given local time is dst or not - /*! Determines if the time is really in DST or not. Also checks for - * invalid and ambiguous. - * @retval The time is either ambiguous, invalid, in dst, or not in dst - */ - static time_is_dst_result local_is_dst(const date_type& d, - const time_duration_type& td) - { - - year_type y = d.year(); - date_type dst_start = local_dst_start_day(y); - date_type dst_end = local_dst_end_day(y); - return dstcalc::local_is_dst(d,td, - dst_start, - dst_traits::dst_start_offset_minutes(), - dst_end, - dst_traits::dst_end_offset_minutes(), - dst_traits::dst_shift_length_minutes()); - - } - - static bool is_dst_boundary_day(date_type d) - { - year_type y = d.year(); - return ((d == local_dst_start_day(y)) || - (d == local_dst_end_day(y))); - } - - //! The time of day for the dst transition (eg: typically 01:00:00 or 02:00:00) - static time_duration_type dst_offset() - { - return time_duration_type(0,dst_traits::dst_shift_length_minutes(),0); - } - - static date_type local_dst_start_day(year_type year) - { - return dst_traits::local_dst_start_day(year); - } - - static date_type local_dst_end_day(year_type year) - { - return dst_traits::local_dst_end_day(year); - } - - - }; - - //! Depricated: Class to calculate dst boundaries for US time zones - /* Use dst_calc_engine instead. - * In 2007 US/Canada DST rules changed - * (http://en.wikipedia.org/wiki/Energy_Policy_Act_of_2005#Change_to_daylight_saving_time). - */ - template //1 hour == 60 min in US - class us_dst_rules - { - public: - typedef time_duration_type_ time_duration_type; - typedef date_type_ date_type; - typedef typename date_type::year_type year_type; - typedef typename date_type::calendar_type calendar_type; - typedef date_time::last_kday_of_month lkday; - typedef date_time::first_kday_of_month fkday; - typedef date_time::nth_kday_of_month nkday; - typedef dst_calculator dstcalc; - - //! Calculates if the given local time is dst or not - /*! Determines if the time is really in DST or not. Also checks for - * invalid and ambiguous. - * @retval The time is either ambiguous, invalid, in dst, or not in dst - */ - static time_is_dst_result local_is_dst(const date_type& d, - const time_duration_type& td) - { - - year_type y = d.year(); - date_type dst_start = local_dst_start_day(y); - date_type dst_end = local_dst_end_day(y); - return dstcalc::local_is_dst(d,td, - dst_start,dst_start_offset_minutes, - dst_end, dst_start_offset_minutes, - dst_length_minutes); - - } - - - static bool is_dst_boundary_day(date_type d) - { - year_type y = d.year(); - return ((d == local_dst_start_day(y)) || - (d == local_dst_end_day(y))); - } - - static date_type local_dst_start_day(year_type year) - { - if (year >= year_type(2007)) { - //second sunday in march - nkday ssim(nkday::second, Sunday, gregorian::Mar); - return ssim.get_date(year); - } else { - //first sunday in april - fkday fsia(Sunday, gregorian::Apr); - return fsia.get_date(year); - } - } - - static date_type local_dst_end_day(year_type year) - { - if (year >= year_type(2007)) { - //first sunday in november - fkday fsin(Sunday, gregorian::Nov); - return fsin.get_date(year); - } else { - //last sunday in october - lkday lsio(Sunday, gregorian::Oct); - return lsio.get_date(year); - } - } - - static time_duration_type dst_offset() - { - return time_duration_type(0,dst_length_minutes,0); - } - - private: - - - }; - - //! Used for local time adjustments in places that don't use dst - template - class null_dst_rules - { - public: - typedef time_duration_type_ time_duration_type; - typedef date_type_ date_type; - - - //! Calculates if the given local time is dst or not - /*! @retval Always is_not_in_dst since this is for zones without dst - */ - static time_is_dst_result local_is_dst(const date_type&, - const time_duration_type&) - { - return is_not_in_dst; - } - - //! Calculates if the given utc time is in dst - static time_is_dst_result utc_is_dst(const date_type&, - const time_duration_type&) - { - return is_not_in_dst; - } - - static bool is_dst_boundary_day(date_type /*d*/) - { - return false; - } - - static time_duration_type dst_offset() - { - return time_duration_type(0,0,0); - } - - }; - - - } } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/filetime_functions.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/filetime_functions.hpp deleted file mode 100644 index 3c7f13f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/filetime_functions.hpp +++ /dev/null @@ -1,170 +0,0 @@ -#ifndef DATE_TIME_FILETIME_FUNCTIONS_HPP__ -#define DATE_TIME_FILETIME_FUNCTIONS_HPP__ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 09:04:10 -0700 (Sat, 22 Sep 2012) $ - */ - -/*! @file filetime_functions.hpp - * Function(s) for converting between a FILETIME structure and a - * time object. This file is only available on systems that have - * BOOST_HAS_FTIME defined. - */ - -#include - -#if defined(BOOST_HAS_FTIME) // skip this file if no FILETIME - -#if defined(BOOST_USE_WINDOWS_H) -# include -#endif - -#include -#include -#include - -namespace boost { - -namespace date_time { - -namespace winapi { - -#if !defined(BOOST_USE_WINDOWS_H) - - extern "C" { - - struct FILETIME - { - boost::uint32_t dwLowDateTime; - boost::uint32_t dwHighDateTime; - }; - struct SYSTEMTIME - { - boost::uint16_t wYear; - boost::uint16_t wMonth; - boost::uint16_t wDayOfWeek; - boost::uint16_t wDay; - boost::uint16_t wHour; - boost::uint16_t wMinute; - boost::uint16_t wSecond; - boost::uint16_t wMilliseconds; - }; - - __declspec(dllimport) void __stdcall GetSystemTimeAsFileTime(FILETIME* lpFileTime); - __declspec(dllimport) int __stdcall FileTimeToLocalFileTime(const FILETIME* lpFileTime, FILETIME* lpLocalFileTime); - __declspec(dllimport) void __stdcall GetSystemTime(SYSTEMTIME* lpSystemTime); - __declspec(dllimport) int __stdcall SystemTimeToFileTime(const SYSTEMTIME* lpSystemTime, FILETIME* lpFileTime); - - } // extern "C" - -#endif // defined(BOOST_USE_WINDOWS_H) - - typedef FILETIME file_time; - typedef SYSTEMTIME system_time; - - inline void get_system_time_as_file_time(file_time& ft) - { -#if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) - // Some runtime library implementations expect local times as the norm for ctime. - file_time ft_utc; - GetSystemTimeAsFileTime(&ft_utc); - FileTimeToLocalFileTime(&ft_utc, &ft); -#elif defined(BOOST_HAS_GETSYSTEMTIMEASFILETIME) - GetSystemTimeAsFileTime(&ft); -#else - system_time st; - GetSystemTime(&st); - SystemTimeToFileTime(&st, &ft); -#endif - } - - /*! - * The function converts file_time into number of microseconds elapsed since 1970-Jan-01 - * - * \note Only dates after 1970-Jan-01 are supported. Dates before will be wrapped. - * - * \note The function is templated on the FILETIME type, so that - * it can be used with both native FILETIME and the ad-hoc - * boost::date_time::winapi::file_time type. - */ - template< typename FileTimeT > - inline boost::uint64_t file_time_to_microseconds(FileTimeT const& ft) - { - /* shift is difference between 1970-Jan-01 & 1601-Jan-01 - * in 100-nanosecond intervals */ - const uint64_t shift = 116444736000000000ULL; // (27111902 << 32) + 3577643008 - - union { - FileTimeT as_file_time; - uint64_t as_integer; // 100-nanos since 1601-Jan-01 - } caster; - caster.as_file_time = ft; - - caster.as_integer -= shift; // filetime is now 100-nanos since 1970-Jan-01 - return (caster.as_integer / 10); // truncate to microseconds - } - -} // namespace winapi - -//! Create a time object from an initialized FILETIME struct. -/*! - * Create a time object from an initialized FILETIME struct. - * A FILETIME struct holds 100-nanosecond units (0.0000001). When - * built with microsecond resolution the file_time's sub second value - * will be truncated. Nanosecond resolution has no truncation. - * - * \note The function is templated on the FILETIME type, so that - * it can be used with both native FILETIME and the ad-hoc - * boost::date_time::winapi::file_time type. - */ -template< typename TimeT, typename FileTimeT > -inline -TimeT time_from_ftime(const FileTimeT& ft) -{ - typedef typename TimeT::date_type date_type; - typedef typename TimeT::date_duration_type date_duration_type; - typedef typename TimeT::time_duration_type time_duration_type; - - // https://svn.boost.org/trac/boost/ticket/2523 - // Since this function can be called with arbitrary times, including ones that - // are before 1970-Jan-01, we'll have to cast the time a bit differently, - // than it is done in the file_time_to_microseconds function. This allows to - // avoid integer wrapping for dates before 1970-Jan-01. - union { - FileTimeT as_file_time; - uint64_t as_integer; // 100-nanos since 1601-Jan-01 - } caster; - caster.as_file_time = ft; - - uint64_t sec = caster.as_integer / 10000000UL; - uint32_t sub_sec = (caster.as_integer % 10000000UL) // 100-nanoseconds since the last second -#if !defined(BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG) - / 10; // microseconds since the last second -#else - * 100; // nanoseconds since the last second -#endif - - // split sec into usable chunks: days, hours, minutes, & seconds - const uint32_t sec_per_day = 86400; // seconds per day - uint32_t days = static_cast< uint32_t >(sec / sec_per_day); - uint32_t tmp = static_cast< uint32_t >(sec % sec_per_day); - uint32_t hours = tmp / 3600; // sec_per_hour - tmp %= 3600; - uint32_t minutes = tmp / 60; // sec_per_min - tmp %= 60; - uint32_t seconds = tmp; // seconds - - date_duration_type dd(days); - date_type d = date_type(1601, Jan, 01) + dd; - return TimeT(d, time_duration_type(hours, minutes, seconds, sub_sec)); -} - -}} // boost::date_time - -#endif // BOOST_HAS_FTIME - -#endif // DATE_TIME_FILETIME_FUNCTIONS_HPP__ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/format_date_parser.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/format_date_parser.hpp deleted file mode 100644 index 1a69055c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/format_date_parser.hpp +++ /dev/null @@ -1,731 +0,0 @@ - -#ifndef DATE_TIME_FORMAT_DATE_PARSER_HPP__ -#define DATE_TIME_FORMAT_DATE_PARSER_HPP__ - -/* Copyright (c) 2004-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2013-10-15 08:22:02 -0700 (Tue, 15 Oct 2013) $ - */ - - -#include "boost/lexical_cast.hpp" -#include "boost/date_time/string_parse_tree.hpp" -#include "boost/date_time/strings_from_facet.hpp" -#include "boost/date_time/special_values_parser.hpp" -#include -#include -#include -#include -#ifndef BOOST_NO_STDC_NAMESPACE -# include -#else -# include -#endif - -#ifdef BOOST_NO_STDC_NAMESPACE -namespace std { - using ::isspace; - using ::isdigit; -} -#endif -namespace boost { namespace date_time { - -//! Helper function for parsing fixed length strings into integers -/*! Will consume 'length' number of characters from stream. Consumed - * character are transfered to parse_match_result struct. - * Returns '-1' if no number can be parsed or incorrect number of - * digits in stream. */ -template -inline -int_type -fixed_string_to_int(std::istreambuf_iterator& itr, - std::istreambuf_iterator& stream_end, - parse_match_result& mr, - unsigned int length, - const charT& fill_char) -{ - //typedef std::basic_string string_type; - unsigned int j = 0; - //string_type s; - while (j < length && itr != stream_end && - (std::isdigit(*itr) || *itr == fill_char)) { - if(*itr == fill_char) { - /* Since a fill_char can be anything, we convert it to a zero. - * lexical_cast will behave predictably when zero is used as fill. */ - mr.cache += ('0'); - } - else { - mr.cache += (*itr); - } - itr++; - j++; - } - int_type i = -1; - // mr.cache will hold leading zeros. size() tells us when input is too short. - if(mr.cache.size() < length) { - return i; - } - try { - i = boost::lexical_cast(mr.cache); - }catch(bad_lexical_cast&){ - // we want to return -1 if the cast fails so nothing to do here - } - return i; -} - -//! Helper function for parsing fixed length strings into integers -/*! Will consume 'length' number of characters from stream. Consumed - * character are transfered to parse_match_result struct. - * Returns '-1' if no number can be parsed or incorrect number of - * digits in stream. */ -template -inline -int_type -fixed_string_to_int(std::istreambuf_iterator& itr, - std::istreambuf_iterator& stream_end, - parse_match_result& mr, - unsigned int length) -{ - return fixed_string_to_int(itr, stream_end, mr, length, '0'); -} - -//! Helper function for parsing varied length strings into integers -/*! Will consume 'max_length' characters from stream only if those - * characters are digits. Returns '-1' if no number can be parsed. - * Will not parse a number preceeded by a '+' or '-'. */ -template -inline -int_type -var_string_to_int(std::istreambuf_iterator& itr, - const std::istreambuf_iterator& stream_end, - unsigned int max_length) -{ - typedef std::basic_string string_type; - unsigned int j = 0; - string_type s; - while (itr != stream_end && (j < max_length) && std::isdigit(*itr)) { - s += (*itr); - ++itr; - ++j; - } - int_type i = -1; - if(!s.empty()) { - i = boost::lexical_cast(s); - } - return i; -} - - -//! Class with generic date parsing using a format string -/*! The following is the set of recognized format specifiers - - %a - Short weekday name - - %A - Long weekday name - - %b - Abbreviated month name - - %B - Full month name - - %d - Day of the month as decimal 01 to 31 - - %j - Day of year as decimal from 001 to 366 - - %m - Month name as a decimal 01 to 12 - - %U - Week number 00 to 53 with first Sunday as the first day of week 1? - - %w - Weekday as decimal number 0 to 6 where Sunday == 0 - - %W - Week number 00 to 53 where Monday is first day of week 1 - - %x - facet default date representation - - %y - Year without the century - eg: 04 for 2004 - - %Y - Year with century - - The weekday specifiers (%a and %A) do not add to the date construction, - but they provide a way to skip over the weekday names for formats that - provide them. - - todo -- Another interesting feature that this approach could provide is - an option to fill in any missing fields with the current values - from the clock. So if you have %m-%d the parser would detect - the missing year value and fill it in using the clock. - - todo -- What to do with the %x. %x in the classic facet is just bad... - - */ -template -class format_date_parser -{ - public: - typedef std::basic_string string_type; - typedef std::basic_istringstream stringstream_type; - typedef std::istreambuf_iterator stream_itr_type; - typedef typename string_type::const_iterator const_itr; - typedef typename date_type::year_type year_type; - typedef typename date_type::month_type month_type; - typedef typename date_type::day_type day_type; - typedef typename date_type::duration_type duration_type; - typedef typename date_type::day_of_week_type day_of_week_type; - typedef typename date_type::day_of_year_type day_of_year_type; - typedef string_parse_tree parse_tree_type; - typedef typename parse_tree_type::parse_match_result_type match_results; - typedef std::vector > input_collection_type; - - // TODO sv_parser uses its default constructor - write the others - - format_date_parser(const string_type& format_str, - const input_collection_type& month_short_names, - const input_collection_type& month_long_names, - const input_collection_type& weekday_short_names, - const input_collection_type& weekday_long_names) : - m_format(format_str), - m_month_short_names(month_short_names, 1), - m_month_long_names(month_long_names, 1), - m_weekday_short_names(weekday_short_names), - m_weekday_long_names(weekday_long_names) - {} - - format_date_parser(const string_type& format_str, - const std::locale& locale) : - m_format(format_str), - m_month_short_names(gather_month_strings(locale), 1), - m_month_long_names(gather_month_strings(locale, false), 1), - m_weekday_short_names(gather_weekday_strings(locale)), - m_weekday_long_names(gather_weekday_strings(locale, false)) - {} - - format_date_parser(const format_date_parser& fdp) - { - this->m_format = fdp.m_format; - this->m_month_short_names = fdp.m_month_short_names; - this->m_month_long_names = fdp.m_month_long_names; - this->m_weekday_short_names = fdp.m_weekday_short_names; - this->m_weekday_long_names = fdp.m_weekday_long_names; - } - - string_type format() const - { - return m_format; - } - - void format(string_type format_str) - { - m_format = format_str; - } - - void short_month_names(const input_collection_type& month_names) - { - m_month_short_names = parse_tree_type(month_names, 1); - } - void long_month_names(const input_collection_type& month_names) - { - m_month_long_names = parse_tree_type(month_names, 1); - } - void short_weekday_names(const input_collection_type& weekday_names) - { - m_weekday_short_names = parse_tree_type(weekday_names); - } - void long_weekday_names(const input_collection_type& weekday_names) - { - m_weekday_long_names = parse_tree_type(weekday_names); - } - - date_type - parse_date(const string_type& value, - const string_type& format_str, - const special_values_parser& sv_parser) const - { - stringstream_type ss(value); - stream_itr_type sitr(ss); - stream_itr_type stream_end; - return parse_date(sitr, stream_end, format_str, sv_parser); - } - - date_type - parse_date(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - const special_values_parser& sv_parser) const - { - return parse_date(sitr, stream_end, m_format, sv_parser); - } - - /*! Of all the objects that the format_date_parser can parse, only a - * date can be a special value. Therefore, only parse_date checks - * for special_values. */ - date_type - parse_date(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str, - const special_values_parser& sv_parser) const - { - bool use_current_char = false; - - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - short year(0), month(0), day(0), day_of_year(0);// wkday(0); - /* Initialized the following to their minimum values. These intermediate - * objects are used so we get specific exceptions when part of the input - * is unparsable. - * Ex: "205-Jan-15" will throw a bad_year, "2005-Jsn-15"- bad_month, etc.*/ - year_type t_year(1400); - month_type t_month(1); - day_type t_day(1); - day_of_week_type wkday(0); - - - const_itr itr(format_str.begin()); - while (itr != format_str.end() && (sitr != stream_end)) { - if (*itr == '%') { - if ( ++itr == format_str.end()) - break; - if (*itr != '%') { - switch(*itr) { - case 'a': - { - //this value is just throw away. It could be used for - //error checking potentially, but it isn't helpful in - //actually constructing the date - we just need to get it - //out of the stream - match_results mr = m_weekday_short_names.match(sitr, stream_end); - if(mr.current_match == match_results::PARSE_ERROR) { - // check special_values - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - wkday = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'A': - { - //this value is just throw away. It could be used for - //error checking potentially, but it isn't helpful in - //actually constructing the date - we just need to get it - //out of the stream - match_results mr = m_weekday_long_names.match(sitr, stream_end); - if(mr.current_match == match_results::PARSE_ERROR) { - // check special_values - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - wkday = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'b': - { - match_results mr = m_month_short_names.match(sitr, stream_end); - if(mr.current_match == match_results::PARSE_ERROR) { - // check special_values - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_month = month_type(mr.current_match); - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'B': - { - match_results mr = m_month_long_names.match(sitr, stream_end); - if(mr.current_match == match_results::PARSE_ERROR) { - // check special_values - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_month = month_type(mr.current_match); - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'd': - { - match_results mr; - day = fixed_string_to_int(sitr, stream_end, mr, 2); - if(day == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_day = day_type(day); - break; - } - case 'e': - { - match_results mr; - day = fixed_string_to_int(sitr, stream_end, mr, 2, ' '); - if(day == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_day = day_type(day); - break; - } - case 'j': - { - match_results mr; - day_of_year = fixed_string_to_int(sitr, stream_end, mr, 3); - if(day_of_year == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - // these next two lines are so we get an exception with bad input - day_of_year_type t_day_of_year(1); - t_day_of_year = day_of_year_type(day_of_year); - break; - } - case 'm': - { - match_results mr; - month = fixed_string_to_int(sitr, stream_end, mr, 2); - if(month == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_month = month_type(month); - break; - } - case 'Y': - { - match_results mr; - year = fixed_string_to_int(sitr, stream_end, mr, 4); - if(year == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - t_year = year_type(year); - break; - } - case 'y': - { - match_results mr; - year = fixed_string_to_int(sitr, stream_end, mr, 2); - if(year == -1) { - if(sv_parser.match(sitr, stream_end, mr)) { - return date_type(static_cast(mr.current_match)); - } - } - year += 2000; //make 2 digit years in this century - t_year = year_type(year); - break; - } - default: - {} //ignore those we don't understand - - }//switch - - } - else { // itr == '%', second consecutive - sitr++; - } - - itr++; //advance past format specifier - } - else { //skip past chars in format and in buffer - itr++; - if (use_current_char) { - use_current_char = false; - } - else { - sitr++; - } - } - } - - if (day_of_year > 0) { - date_type d(static_cast(year-1),12,31); //end of prior year - return d + duration_type(day_of_year); - } - - return date_type(t_year, t_month, t_day); // exceptions were thrown earlier - // if input was no good - } - - //! Throws bad_month if unable to parse - month_type - parse_month(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str) const - { - match_results mr; - return parse_month(sitr, stream_end, format_str, mr); - } - - //! Throws bad_month if unable to parse - month_type - parse_month(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str, - match_results& mr) const - { - bool use_current_char = false; - - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - short month(0); - - const_itr itr(format_str.begin()); - while (itr != format_str.end() && (sitr != stream_end)) { - if (*itr == '%') { - if ( ++itr == format_str.end()) - break; - if (*itr != '%') { - switch(*itr) { - case 'b': - { - mr = m_month_short_names.match(sitr, stream_end); - month = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'B': - { - mr = m_month_long_names.match(sitr, stream_end); - month = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'm': - { - month = var_string_to_int(sitr, stream_end, 2); - // var_string_to_int returns -1 if parse failed. That will - // cause a bad_month exception to be thrown so we do nothing here - break; - } - default: - {} //ignore those we don't understand - - }//switch - - } - else { // itr == '%', second consecutive - sitr++; - } - - itr++; //advance past format specifier - } - else { //skip past chars in format and in buffer - itr++; - if (use_current_char) { - use_current_char = false; - } - else { - sitr++; - } - } - } - - return month_type(month); // throws bad_month exception when values are zero - } - - //! Expects 1 or 2 digits 1-31. Throws bad_day_of_month if unable to parse - day_type - parse_var_day_of_month(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - return day_type(var_string_to_int(sitr, stream_end, 2)); - } - //! Expects 2 digits 01-31. Throws bad_day_of_month if unable to parse - day_type - parse_day_of_month(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - //return day_type(var_string_to_int(sitr, stream_end, 2)); - match_results mr; - return day_type(fixed_string_to_int(sitr, stream_end, mr, 2)); - } - - day_of_week_type - parse_weekday(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str) const - { - match_results mr; - return parse_weekday(sitr, stream_end, format_str, mr); - } - day_of_week_type - parse_weekday(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str, - match_results& mr) const - { - bool use_current_char = false; - - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - short wkday(0); - - const_itr itr(format_str.begin()); - while (itr != format_str.end() && (sitr != stream_end)) { - if (*itr == '%') { - if ( ++itr == format_str.end()) - break; - if (*itr != '%') { - switch(*itr) { - case 'a': - { - //this value is just throw away. It could be used for - //error checking potentially, but it isn't helpful in - //actually constructing the date - we just need to get it - //out of the stream - mr = m_weekday_short_names.match(sitr, stream_end); - wkday = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'A': - { - //this value is just throw away. It could be used for - //error checking potentially, but it isn't helpful in - //actually constructing the date - we just need to get it - //out of the stream - mr = m_weekday_long_names.match(sitr, stream_end); - wkday = mr.current_match; - if (mr.has_remaining()) { - use_current_char = true; - } - break; - } - case 'w': - { - // weekday as number 0-6, Sunday == 0 - wkday = var_string_to_int(sitr, stream_end, 2); - break; - } - default: - {} //ignore those we don't understand - - }//switch - - } - else { // itr == '%', second consecutive - sitr++; - } - - itr++; //advance past format specifier - } - else { //skip past chars in format and in buffer - itr++; - if (use_current_char) { - use_current_char = false; - } - else { - sitr++; - } - } - } - - return day_of_week_type(wkday); // throws bad_day_of_month exception - // when values are zero - } - - //! throws bad_year if unable to parse - year_type - parse_year(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str) const - { - match_results mr; - return parse_year(sitr, stream_end, format_str, mr); - } - - //! throws bad_year if unable to parse - year_type - parse_year(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - string_type format_str, - match_results& mr) const - { - bool use_current_char = false; - - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - unsigned short year(0); - - const_itr itr(format_str.begin()); - while (itr != format_str.end() && (sitr != stream_end)) { - if (*itr == '%') { - if ( ++itr == format_str.end()) - break; - if (*itr != '%') { - //match_results mr; - switch(*itr) { - case 'Y': - { - // year from 4 digit string - year = fixed_string_to_int(sitr, stream_end, mr, 4); - break; - } - case 'y': - { - // year from 2 digit string (no century) - year = fixed_string_to_int(sitr, stream_end, mr, 2); - year += 2000; //make 2 digit years in this century - break; - } - default: - {} //ignore those we don't understand - - }//switch - - } - else { // itr == '%', second consecutive - sitr++; - } - - itr++; //advance past format specifier - } - else { //skip past chars in format and in buffer - itr++; - if (use_current_char) { - use_current_char = false; - } - else { - sitr++; - } - } - } - - return year_type(year); // throws bad_year exception when values are zero - } - - - private: - string_type m_format; - parse_tree_type m_month_short_names; - parse_tree_type m_month_long_names; - parse_tree_type m_weekday_short_names; - parse_tree_type m_weekday_long_names; - -}; - -} } //namespace - -#endif - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/conversion.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/conversion.hpp deleted file mode 100644 index 33f6856b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/conversion.hpp +++ /dev/null @@ -1,68 +0,0 @@ -#ifndef _GREGORIAN__CONVERSION_HPP___ -#define _GREGORIAN__CONVERSION_HPP___ - -/* Copyright (c) 2004-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2010-06-09 11:10:13 -0700 (Wed, 09 Jun 2010) $ - */ - -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - -namespace gregorian { - - //! Converts a date to a tm struct. Throws out_of_range exception if date is a special value - inline - std::tm to_tm(const date& d) - { - if (d.is_special()) - { - std::string s = "tm unable to handle "; - switch (d.as_special()) - { - case date_time::not_a_date_time: - s += "not-a-date-time value"; break; - case date_time::neg_infin: - s += "-infinity date value"; break; - case date_time::pos_infin: - s += "+infinity date value"; break; - default: - s += "a special date value"; break; - } - boost::throw_exception(std::out_of_range(s)); - } - - std::tm datetm; - std::memset(&datetm, 0, sizeof(datetm)); - boost::gregorian::date::ymd_type ymd = d.year_month_day(); - datetm.tm_year = ymd.year - 1900; - datetm.tm_mon = ymd.month - 1; - datetm.tm_mday = ymd.day; - datetm.tm_wday = d.day_of_week(); - datetm.tm_yday = d.day_of_year() - 1; - datetm.tm_isdst = -1; // negative because not enough info to set tm_isdst - return datetm; - } - - //! Converts a tm structure into a date dropping the any time values. - inline - date date_from_tm(const std::tm& datetm) - { - return date(static_cast(datetm.tm_year+1900), - static_cast(datetm.tm_mon+1), - static_cast(datetm.tm_mday)); - } - -} } //namespace boost::gregorian - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters.hpp deleted file mode 100644 index eda7dc34..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters.hpp +++ /dev/null @@ -1,162 +0,0 @@ -#ifndef GREGORIAN_FORMATTERS_HPP___ -#define GREGORIAN_FORMATTERS_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/compiler_config.hpp" -#include "boost/date_time/gregorian/gregorian_types.hpp" -#if defined(BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS) -#include "boost/date_time/date_formatting_limited.hpp" -#else -#include "boost/date_time/date_formatting.hpp" -#endif -#include "boost/date_time/iso_format.hpp" -#include "boost/date_time/date_format_simple.hpp" - -/* NOTE: "to_*_string" code for older compilers, ones that define - * BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS, is located in - * formatters_limited.hpp - */ - -namespace boost { -namespace gregorian { - - // wrapper function for to_simple_(w)string(date) - template - inline - std::basic_string to_simple_string_type(const date& d) { - return date_time::date_formatter,charT>::date_to_string(d); - } - //! To YYYY-mmm-DD string where mmm 3 char month name. Example: 2002-Jan-01 - /*!\ingroup date_format - */ - inline std::string to_simple_string(const date& d) { - return to_simple_string_type(d); - } - - - // wrapper function for to_simple_(w)string(date_period) - template - inline std::basic_string to_simple_string_type(const date_period& d) { - typedef std::basic_string string_type; - charT b = '[', m = '/', e=']'; - - string_type d1(date_time::date_formatter,charT>::date_to_string(d.begin())); - string_type d2(date_time::date_formatter,charT>::date_to_string(d.last())); - return string_type(b + d1 + m + d2 + e); - } - //! Convert date period to simple string. Example: [2002-Jan-01/2002-Jan-02] - /*!\ingroup date_format - */ - inline std::string to_simple_string(const date_period& d) { - return to_simple_string_type(d); - } - - // wrapper function for to_iso_(w)string(date_period) - template - inline std::basic_string to_iso_string_type(const date_period& d) { - charT sep = '/'; - std::basic_string s(date_time::date_formatter,charT>::date_to_string(d.begin())); - return s + sep + date_time::date_formatter,charT>::date_to_string(d.last()); - } - //! Date period to iso standard format CCYYMMDD/CCYYMMDD. Example: 20021225/20021231 - /*!\ingroup date_format - */ - inline std::string to_iso_string(const date_period& d) { - return to_iso_string_type(d); - } - - - // wrapper function for to_iso_extended_(w)string(date) - template - inline std::basic_string to_iso_extended_string_type(const date& d) { - return date_time::date_formatter,charT>::date_to_string(d); - } - //! Convert to iso extended format string CCYY-MM-DD. Example 2002-12-31 - /*!\ingroup date_format - */ - inline std::string to_iso_extended_string(const date& d) { - return to_iso_extended_string_type(d); - } - - // wrapper function for to_iso_(w)string(date) - template - inline std::basic_string to_iso_string_type(const date& d) { - return date_time::date_formatter,charT>::date_to_string(d); - } - //! Convert to iso standard string YYYYMMDD. Example: 20021231 - /*!\ingroup date_format - */ - inline std::string to_iso_string(const date& d) { - return to_iso_string_type(d); - } - - - - - // wrapper function for to_sql_(w)string(date) - template - inline std::basic_string to_sql_string_type(const date& d) - { - date::ymd_type ymd = d.year_month_day(); - std::basic_ostringstream ss; - ss << ymd.year << "-" - << std::setw(2) << std::setfill(ss.widen('0')) - << ymd.month.as_number() //solves problem with gcc 3.1 hanging - << "-" - << std::setw(2) << std::setfill(ss.widen('0')) - << ymd.day; - return ss.str(); - } - inline std::string to_sql_string(const date& d) { - return to_sql_string_type(d); - } - - -#if !defined(BOOST_NO_STD_WSTRING) - //! Convert date period to simple string. Example: [2002-Jan-01/2002-Jan-02] - /*!\ingroup date_format - */ - inline std::wstring to_simple_wstring(const date_period& d) { - return to_simple_string_type(d); - } - //! To YYYY-mmm-DD string where mmm 3 char month name. Example: 2002-Jan-01 - /*!\ingroup date_format - */ - inline std::wstring to_simple_wstring(const date& d) { - return to_simple_string_type(d); - } - //! Date period to iso standard format CCYYMMDD/CCYYMMDD. Example: 20021225/20021231 - /*!\ingroup date_format - */ - inline std::wstring to_iso_wstring(const date_period& d) { - return to_iso_string_type(d); - } - //! Convert to iso extended format string CCYY-MM-DD. Example 2002-12-31 - /*!\ingroup date_format - */ - inline std::wstring to_iso_extended_wstring(const date& d) { - return to_iso_extended_string_type(d); - } - //! Convert to iso standard string YYYYMMDD. Example: 20021231 - /*!\ingroup date_format - */ - inline std::wstring to_iso_wstring(const date& d) { - return to_iso_string_type(d); - } - inline std::wstring to_sql_wstring(const date& d) { - return to_sql_string_type(d); - } -#endif // BOOST_NO_STD_WSTRING - -} } //namespace gregorian - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters_limited.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters_limited.hpp deleted file mode 100644 index 8dfd2d0c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/formatters_limited.hpp +++ /dev/null @@ -1,81 +0,0 @@ -#ifndef GREGORIAN_FORMATTERS_LIMITED_HPP___ -#define GREGORIAN_FORMATTERS_LIMITED_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/gregorian/gregorian_types.hpp" -#include "boost/date_time/date_formatting_limited.hpp" -#include "boost/date_time/iso_format.hpp" -#include "boost/date_time/date_format_simple.hpp" -#include "boost/date_time/compiler_config.hpp" - -namespace boost { -namespace gregorian { - - //! To YYYY-mmm-DD string where mmm 3 char month name. Example: 2002-Jan-01 - /*!\ingroup date_format - */ - inline std::string to_simple_string(const date& d) { - return date_time::date_formatter >::date_to_string(d); - } - - //! Convert date period to simple string. Example: [2002-Jan-01/2002-Jan-02] - /*!\ingroup date_format - */ - inline std::string to_simple_string(const date_period& d) { - std::string s("["); - std::string d1(date_time::date_formatter >::date_to_string(d.begin())); - std::string d2(date_time::date_formatter >::date_to_string(d.last())); - return std::string("[" + d1 + "/" + d2 + "]"); - } - - //! Date period to iso standard format CCYYMMDD/CCYYMMDD. Example: 20021225/20021231 - /*!\ingroup date_format - */ - inline std::string to_iso_string(const date_period& d) { - std::string s(date_time::date_formatter >::date_to_string(d.begin())); - return s + "/" + date_time::date_formatter >::date_to_string(d.last()); - } - - - //! Convert to iso extended format string CCYY-MM-DD. Example 2002-12-31 - /*!\ingroup date_format - */ - inline std::string to_iso_extended_string(const date& d) { - return date_time::date_formatter >::date_to_string(d); - } - - //! Convert to iso standard string YYYYMMDD. Example: 20021231 - /*!\ingroup date_format - */ - inline std::string to_iso_string(const date& d) { - return date_time::date_formatter >::date_to_string(d); - } - - - - inline std::string to_sql_string(const date& d) - { - date::ymd_type ymd = d.year_month_day(); - std::ostringstream ss; - ss << ymd.year << "-" - << std::setw(2) << std::setfill('0') - << ymd.month.as_number() //solves problem with gcc 3.1 hanging - << "-" - << std::setw(2) << std::setfill('0') - << ymd.day; - return ss.str(); - } - - -} } //namespace gregorian - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_calendar.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_calendar.hpp deleted file mode 100644 index e9c1852e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_calendar.hpp +++ /dev/null @@ -1,48 +0,0 @@ -#ifndef GREGORIAN_GREGORIAN_CALENDAR_HPP__ -#define GREGORIAN_GREGORIAN_CALENDAR_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2010-01-10 11:17:23 -0800 (Sun, 10 Jan 2010) $ - */ - -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace gregorian { - - //!An internal date representation that includes infinities, not a date - typedef date_time::int_adapter fancy_date_rep; - - //! Gregorian calendar for this implementation, hard work in the base - class gregorian_calendar : - public date_time::gregorian_calendar_base { - public: - //! Type to hold a weekday (eg: Sunday, Monday,...) - typedef greg_weekday day_of_week_type; - //! Counter type from 1 to 366 for gregorian dates. - typedef greg_day_of_year_rep day_of_year_type; - //! Internal date representation that handles infinity, not a date - typedef fancy_date_rep date_rep_type; - //! Date rep implements the traits stuff as well - typedef fancy_date_rep date_traits_type; - - - private: - }; - -} } //namespace gregorian - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_date.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_date.hpp deleted file mode 100644 index 860a407c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_date.hpp +++ /dev/null @@ -1,136 +0,0 @@ -#ifndef GREG_DATE_HPP___ -#define GREG_DATE_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2010-01-10 11:17:23 -0800 (Sun, 10 Jan 2010) $ - */ - -#include -#include -#include -#include -#include - -namespace boost { -namespace gregorian { - - //bring special enum values into the namespace - using date_time::special_values; - using date_time::not_special; - using date_time::neg_infin; - using date_time::pos_infin; - using date_time::not_a_date_time; - using date_time::max_date_time; - using date_time::min_date_time; - - //! A date type based on gregorian_calendar - /*! This class is the primary interface for programming with - greogorian dates. The is a lightweight type that can be - freely passed by value. All comparison operators are - supported. - \ingroup date_basics - */ - class date : public date_time::date - { - public: - typedef gregorian_calendar::year_type year_type; - typedef gregorian_calendar::month_type month_type; - typedef gregorian_calendar::day_type day_type; - typedef gregorian_calendar::day_of_year_type day_of_year_type; - typedef gregorian_calendar::ymd_type ymd_type; - typedef gregorian_calendar::date_rep_type date_rep_type; - typedef gregorian_calendar::date_int_type date_int_type; - typedef date_duration duration_type; -#if !defined(DATE_TIME_NO_DEFAULT_CONSTRUCTOR) - //! Default constructor constructs with not_a_date_time - date(): - date_time::date(date_rep_type::from_special(not_a_date_time)) - {} -#endif // DATE_TIME_NO_DEFAULT_CONSTRUCTOR - //! Main constructor with year, month, day - date(year_type y, month_type m, day_type d) - : date_time::date(y, m, d) - { - if (gregorian_calendar::end_of_month_day(y, m) < d) { - boost::throw_exception(bad_day_of_month(std::string("Day of month is not valid for year"))); - } - } - //! Constructor from a ymd_type structure - explicit date(const ymd_type& ymd) - : date_time::date(ymd) - {} - //! Needed copy constructor - explicit date(const date_int_type& rhs): - date_time::date(rhs) - {} - //! Needed copy constructor - explicit date(date_rep_type rhs): - date_time::date(rhs) - {} - //! Constructor for infinities, not a date, max and min date - explicit date(special_values sv): - date_time::date(date_rep_type::from_special(sv)) - { - if (sv == min_date_time) - { - *this = date(1400, 1, 1); - } - if (sv == max_date_time) - { - *this = date(9999, 12, 31); - } - - } - //!Return the Julian Day number for the date. - date_int_type julian_day() const - { - ymd_type ymd = year_month_day(); - return gregorian_calendar::julian_day_number(ymd); - } - //!Return the day of year 1..365 or 1..366 (for leap year) - day_of_year_type day_of_year() const - { - date start_of_year(year(), 1, 1); - unsigned short doy = static_cast((*this-start_of_year).days() + 1); - return day_of_year_type(doy); - } - //!Return the Modified Julian Day number for the date. - date_int_type modjulian_day() const - { - ymd_type ymd = year_month_day(); - return gregorian_calendar::modjulian_day_number(ymd); - } - //!Return the iso 8601 week number 1..53 - int week_number() const - { - ymd_type ymd = year_month_day(); - return gregorian_calendar::week_number(ymd); - } - //! Return the day number from the calendar - date_int_type day_number() const - { - return days_; - } - //! Return the last day of the current month - date end_of_month() const - { - ymd_type ymd = year_month_day(); - short eom_day = gregorian_calendar::end_of_month_day(ymd.year, ymd.month); - return date(ymd.year, ymd.month, eom_day); - } - - private: - - }; - - - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day.hpp deleted file mode 100644 index 4ea829fb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day.hpp +++ /dev/null @@ -1,57 +0,0 @@ -#ifndef GREG_DAY_HPP___ -#define GREG_DAY_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/constrained_value.hpp" -#include -#include - -namespace boost { -namespace gregorian { - - //! Exception type for gregorian day of month (1..31) - struct bad_day_of_month : public std::out_of_range - { - bad_day_of_month() : - std::out_of_range(std::string("Day of month value is out of range 1..31")) - {} - //! Allow other classes to throw with unique string for bad day like Feb 29 - bad_day_of_month(const std::string& s) : - std::out_of_range(s) - {} - }; - //! Policy class that declares error handling and day of month ranges - typedef CV::simple_exception_policy greg_day_policies; - - //! Generated represetation for gregorian day of month - typedef CV::constrained_value greg_day_rep; - - //! Represent a day of the month (range 1 - 31) - /*! This small class allows for simple conversion an integer value into - a day of the month for a standard gregorian calendar. The type - is automatically range checked so values outside of the range 1-31 - will cause a bad_day_of_month exception - */ - class greg_day : public greg_day_rep { - public: - greg_day(unsigned short day_of_month) : greg_day_rep(day_of_month) {} - unsigned short as_number() const {return value_;} - operator unsigned short() const {return value_;} - private: - - }; - - - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day_of_year.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day_of_year.hpp deleted file mode 100644 index 2f8874d2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_day_of_year.hpp +++ /dev/null @@ -1,38 +0,0 @@ -#ifndef GREG_DAY_OF_YEAR_HPP___ -#define GREG_DAY_OF_YEAR_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/constrained_value.hpp" -#include -#include - -namespace boost { -namespace gregorian { - - //! Exception type for day of year (1..366) - struct bad_day_of_year : public std::out_of_range - { - bad_day_of_year() : - std::out_of_range(std::string("Day of year value is out of range 1..366")) - {} - }; - - //! A day of the year range (1..366) - typedef CV::simple_exception_policy greg_day_of_year_policies; - - //! Define a range representation type for the day of the year 1..366 - typedef CV::constrained_value greg_day_of_year_rep; - - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration.hpp deleted file mode 100644 index a9c0c171..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration.hpp +++ /dev/null @@ -1,134 +0,0 @@ -#ifndef GREG_DURATION_HPP___ -#define GREG_DURATION_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include -#include -#include - -namespace boost { -namespace gregorian { - - //!An internal date representation that includes infinities, not a date - typedef boost::date_time::duration_traits_adapted date_duration_rep; - - //! Durations in days for gregorian system - /*! \ingroup date_basics - */ - class date_duration : - public boost::date_time::date_duration< date_duration_rep > - { - typedef boost::date_time::date_duration< date_duration_rep > base_type; - - public: - typedef base_type::duration_rep duration_rep; - - //! Construct from a day count - explicit date_duration(duration_rep day_count = 0) : base_type(day_count) {} - - //! construct from special_values - date_duration(date_time::special_values sv) : base_type(sv) {} - - //! Copy constructor - date_duration(const date_duration& other) : base_type(static_cast< base_type const& >(other)) - {} - - //! Construct from another date_duration - date_duration(const base_type& other) : base_type(other) - {} - - // Relational operators - // NOTE: Because of date_time::date_duration< T > design choice we don't use Boost.Operators here, - // because we need the class to be a direct base. Either lose EBO, or define operators by hand. - // The latter is more effecient. - bool operator== (const date_duration& rhs) const - { - return base_type::operator== (rhs); - } - bool operator!= (const date_duration& rhs) const - { - return !operator== (rhs); - } - bool operator< (const date_duration& rhs) const - { - return base_type::operator< (rhs); - } - bool operator> (const date_duration& rhs) const - { - return !(base_type::operator< (rhs) || base_type::operator== (rhs)); - } - bool operator<= (const date_duration& rhs) const - { - return (base_type::operator< (rhs) || base_type::operator== (rhs)); - } - bool operator>= (const date_duration& rhs) const - { - return !base_type::operator< (rhs); - } - - //! Subtract another duration -- result is signed - date_duration& operator-= (const date_duration& rhs) - { - base_type::operator-= (rhs); - return *this; - } - friend date_duration operator- (date_duration rhs, date_duration const& lhs) - { - rhs -= lhs; - return rhs; - } - - //! Add a duration -- result is signed - date_duration& operator+= (const date_duration& rhs) - { - base_type::operator+= (rhs); - return *this; - } - friend date_duration operator+ (date_duration rhs, date_duration const& lhs) - { - rhs += lhs; - return rhs; - } - - //! unary- Allows for dd = -date_duration(2); -> dd == -2 - date_duration operator- ()const - { - return date_duration(get_rep() * (-1)); - } - - //! Division operations on a duration with an integer. - date_duration& operator/= (int divisor) - { - base_type::operator/= (divisor); - return *this; - } - friend date_duration operator/ (date_duration rhs, int lhs) - { - rhs /= lhs; - return rhs; - } - - //! Returns the smallest duration -- used by to calculate 'end' - static date_duration unit() - { - return date_duration(base_type::unit().get_rep()); - } - }; - - //! Shorthand for date_duration - typedef date_duration days; - -} } //namespace gregorian - -#if defined(BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES) -#include -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration_types.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration_types.hpp deleted file mode 100644 index 8328ca30..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_duration_types.hpp +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef GREG_DURATION_TYPES_HPP___ -#define GREG_DURATION_TYPES_HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Subject to Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - - -#include -#include -#include -#include -#include - -namespace boost { -namespace gregorian { - - //! config struct for additional duration types (ie months_duration<> & years_duration<>) - struct greg_durations_config { - typedef date date_type; - typedef date_time::int_adapter int_rep; - typedef date_time::month_functor month_adjustor_type; - }; - - typedef date_time::months_duration months; - typedef date_time::years_duration years; - - class weeks_duration : public date_duration { - public: - weeks_duration(duration_rep w) - : date_duration(w * 7) {} - weeks_duration(date_time::special_values sv) - : date_duration(sv) {} - }; - - typedef weeks_duration weeks; - -}} // namespace boost::gregorian - -#endif // GREG_DURATION_TYPES_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_facet.hpp deleted file mode 100644 index 9efc6195..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_facet.hpp +++ /dev/null @@ -1,354 +0,0 @@ -#ifndef GREGORIAN_FACET_HPP___ -#define GREGORIAN_FACET_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-23 03:13:35 -0800 (Sun, 23 Nov 2008) $ - */ - -#include "boost/date_time/gregorian/gregorian_types.hpp" -#include "boost/date_time/date_formatting_locales.hpp" // sets BOOST_DATE_TIME_NO_LOCALE -#include "boost/date_time/gregorian/parsers.hpp" - -//This file is basically commented out if locales are not supported -#ifndef BOOST_DATE_TIME_NO_LOCALE - -#include -#include -#include -#include -#include - -namespace boost { -namespace gregorian { - - //! Configuration of the output facet template - struct greg_facet_config - { - typedef boost::gregorian::greg_month month_type; - typedef boost::date_time::special_values special_value_enum; - typedef boost::gregorian::months_of_year month_enum; - typedef boost::date_time::weekdays weekday_enum; - }; - -#if defined(USE_DATE_TIME_PRE_1_33_FACET_IO) - //! Create the base facet type for gregorian::date - typedef boost::date_time::date_names_put greg_base_facet; - - //! ostream operator for gregorian::date - /*! Uses the date facet to determine various output parameters including: - * - string values for the month (eg: Jan, Feb, Mar) (default: English) - * - string values for special values (eg: not-a-date-time) (default: English) - * - selection of long, short strings, or numerical month representation (default: short string) - * - month day year order (default yyyy-mmm-dd) - */ - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const date& d) - { - typedef boost::date_time::date_names_put facet_def; - typedef boost::date_time::ostream_date_formatter greg_ostream_formatter; - greg_ostream_formatter::date_put(d, os); - return os; - } - - //! operator<< for gregorian::greg_month typically streaming: Jan, Feb, Mar... - /*! Uses the date facet to determine output string as well as selection of long or short strings. - * Default if no facet is installed is to output a 2 wide numeric value for the month - * eg: 01 == Jan, 02 == Feb, ... 12 == Dec. - */ - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const greg_month& m) - { - typedef boost::date_time::date_names_put facet_def; - typedef boost::date_time::ostream_month_formatter greg_month_formatter; - std::locale locale = os.getloc(); - if (std::has_facet(locale)) { - const facet_def& f = std::use_facet(locale); - greg_month_formatter::format_month(m, os, f); - - } - else { //default to numeric - charT fill_char = '0'; - os << std::setw(2) << std::setfill(fill_char) << m.as_number(); - } - - return os; - } - - //! operator<< for gregorian::greg_weekday typically streaming: Sun, Mon, Tue, ... - /*! Uses the date facet to determine output string as well as selection of long or short string. - * Default if no facet is installed is to output a 3 char english string for the - * day of the week. - */ - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const greg_weekday& wd) - { - typedef boost::date_time::date_names_put facet_def; - typedef boost::date_time::ostream_weekday_formatter greg_weekday_formatter; - std::locale locale = os.getloc(); - if (std::has_facet(locale)) { - const facet_def& f = std::use_facet(locale); - greg_weekday_formatter::format_weekday(wd.as_enum(), os, f, true); - } - else { //default to short English string eg: Sun, Mon, Tue, Wed... - os << wd.as_short_string(); - } - - return os; - } - - //! operator<< for gregorian::date_period typical output: [2002-Jan-01/2002-Jan-31] - /*! Uses the date facet to determine output string as well as selection of long - * or short string fr dates. - * Default if no facet is installed is to output a 3 char english string for the - * day of the week. - */ - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const date_period& dp) - { - os << '['; //TODO: facet or manipulator for periods? - os << dp.begin(); - os << '/'; //TODO: facet or manipulator for periods? - os << dp.last(); - os << ']'; - return os; - } - - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const date_duration& dd) - { - //os << dd.days(); - os << dd.get_rep(); - return os; - } - - //! operator<< for gregorian::partial_date. Output: "Jan 1" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const partial_date& pd) - { - os << std::setw(2) << std::setfill('0') << pd.day() << ' ' - << pd.month().as_short_string() ; - return os; - } - - //! operator<< for gregorian::nth_kday_of_month. Output: "first Mon of Jun" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, - const nth_kday_of_month& nkd) - { - os << nkd.nth_week_as_str() << ' ' - << nkd.day_of_week() << " of " - << nkd.month().as_short_string() ; - return os; - } - - //! operator<< for gregorian::first_kday_of_month. Output: "first Mon of Jun" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, - const first_kday_of_month& fkd) - { - os << "first " << fkd.day_of_week() << " of " - << fkd.month().as_short_string() ; - return os; - } - - //! operator<< for gregorian::last_kday_of_month. Output: "last Mon of Jun" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, - const last_kday_of_month& lkd) - { - os << "last " << lkd.day_of_week() << " of " - << lkd.month().as_short_string() ; - return os; - } - - //! operator<< for gregorian::first_kday_after. Output: "first Mon after" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, - const first_kday_after& fka) - { - os << fka.day_of_week() << " after"; - return os; - } - - //! operator<< for gregorian::first_kday_before. Output: "first Mon before" - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, - const first_kday_before& fkb) - { - os << fkb.day_of_week() << " before"; - return os; - } -#endif // USE_DATE_TIME_PRE_1_33_FACET_IO - /**************** Input Streaming ******************/ - -#if !defined(BOOST_NO_STD_ITERATOR_TRAITS) - //! operator>> for gregorian::date - template - inline - std::basic_istream& operator>>(std::basic_istream& is, date& d) - { - std::istream_iterator, charT> beg(is), eos; - - typedef boost::date_time::all_date_names_put facet_def; - d = from_stream(beg, eos); - return is; - } -#endif // BOOST_NO_STD_ITERATOR_TRAITS - - //! operator>> for gregorian::date_duration - template - inline - std::basic_istream& operator>>(std::basic_istream& is, - date_duration& dd) - { - long v; - is >> v; - dd = date_duration(v); - return is; - } - - //! operator>> for gregorian::date_period - template - inline - std::basic_istream& operator>>(std::basic_istream& is, - date_period& dp) - { - std::basic_string s; - is >> s; - dp = date_time::from_simple_string_type(s); - return is; - } - - //! generates a locale with the set of gregorian name-strings of type char* - BOOST_DATE_TIME_DECL std::locale generate_locale(std::locale& loc, char type); - - //! Returns a pointer to a facet with a default set of names (English) - /* Necessary in the event an exception is thrown from op>> for - * weekday or month. See comments in those functions for more info */ - BOOST_DATE_TIME_DECL boost::date_time::all_date_names_put* create_facet_def(char type); - -#ifndef BOOST_NO_STD_WSTRING - //! generates a locale with the set of gregorian name-strings of type wchar_t* - BOOST_DATE_TIME_DECL std::locale generate_locale(std::locale& loc, wchar_t type); - //! Returns a pointer to a facet with a default set of names (English) - /* Necessary in the event an exception is thrown from op>> for - * weekday or month. See comments in those functions for more info */ - BOOST_DATE_TIME_DECL boost::date_time::all_date_names_put* create_facet_def(wchar_t type); -#endif // BOOST_NO_STD_WSTRING - - //! operator>> for gregorian::greg_month - throws exception if invalid month given - template - inline - std::basic_istream& operator>>(std::basic_istream& is,greg_month& m) - { - typedef boost::date_time::all_date_names_put facet_def; - - std::basic_string s; - is >> s; - - if(!std::has_facet(is.getloc())) { - std::locale loc = is.getloc(); - charT a = '\0'; - is.imbue(generate_locale(loc, a)); - } - - short num = 0; - - try{ - const facet_def& f = std::use_facet(is.getloc()); - num = date_time::find_match(f.get_short_month_names(), - f.get_long_month_names(), - (greg_month::max)(), s); // greg_month spans 1..12, so max returns the array size, - // which is needed by find_match - } - /* bad_cast will be thrown if the desired facet is not accessible - * so we can generate the facet. This has the drawback of using english - * names as a default. */ - catch(std::bad_cast&){ - charT a = '\0'; - std::auto_ptr< const facet_def > f(create_facet_def(a)); - num = date_time::find_match(f->get_short_month_names(), - f->get_long_month_names(), - (greg_month::max)(), s); // greg_month spans 1..12, so max returns the array size, - // which is needed by find_match - } - - ++num; // months numbered 1-12 - m = greg_month(num); - - return is; - } - - //! operator>> for gregorian::greg_weekday - throws exception if invalid weekday given - template - inline - std::basic_istream& operator>>(std::basic_istream& is,greg_weekday& wd) - { - typedef boost::date_time::all_date_names_put facet_def; - - std::basic_string s; - is >> s; - - if(!std::has_facet(is.getloc())) { - std::locale loc = is.getloc(); - charT a = '\0'; - is.imbue(generate_locale(loc, a)); - } - - short num = 0; - try{ - const facet_def& f = std::use_facet(is.getloc()); - num = date_time::find_match(f.get_short_weekday_names(), - f.get_long_weekday_names(), - (greg_weekday::max)() + 1, s); // greg_weekday spans 0..6, so increment is needed - // to form the array size which is needed by find_match - } - /* bad_cast will be thrown if the desired facet is not accessible - * so we can generate the facet. This has the drawback of using english - * names as a default. */ - catch(std::bad_cast&){ - charT a = '\0'; - std::auto_ptr< const facet_def > f(create_facet_def(a)); - num = date_time::find_match(f->get_short_weekday_names(), - f->get_long_weekday_names(), - (greg_weekday::max)() + 1, s); // greg_weekday spans 0..6, so increment is needed - // to form the array size which is needed by find_match - } - - wd = greg_weekday(num); // weekdays numbered 0-6 - return is; - } - -} } //namespace gregorian - -#endif - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_month.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_month.hpp deleted file mode 100644 index b48a8a89..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_month.hpp +++ /dev/null @@ -1,105 +0,0 @@ -#ifndef GREG_MONTH_HPP___ -#define GREG_MONTH_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/constrained_value.hpp" -#include "boost/date_time/date_defs.hpp" -#include "boost/shared_ptr.hpp" -#include "boost/date_time/compiler_config.hpp" -#include -#include -#include -#include -#include - -namespace boost { -namespace gregorian { - - typedef date_time::months_of_year months_of_year; - - //bring enum values into the namespace - using date_time::Jan; - using date_time::Feb; - using date_time::Mar; - using date_time::Apr; - using date_time::May; - using date_time::Jun; - using date_time::Jul; - using date_time::Aug; - using date_time::Sep; - using date_time::Oct; - using date_time::Nov; - using date_time::Dec; - using date_time::NotAMonth; - using date_time::NumMonths; - - //! Exception thrown if a greg_month is constructed with a value out of range - struct bad_month : public std::out_of_range - { - bad_month() : std::out_of_range(std::string("Month number is out of range 1..12")) {} - }; - //! Build a policy class for the greg_month_rep - typedef CV::simple_exception_policy greg_month_policies; - //! A constrained range that implements the gregorian_month rules - typedef CV::constrained_value greg_month_rep; - - - //! Wrapper class to represent months in gregorian based calendar - class BOOST_DATE_TIME_DECL greg_month : public greg_month_rep { - public: - typedef date_time::months_of_year month_enum; - typedef std::map month_map_type; - typedef boost::shared_ptr month_map_ptr_type; - //! Construct a month from the months_of_year enumeration - greg_month(month_enum theMonth) : - greg_month_rep(static_cast(theMonth)) {} - //! Construct from a short value - greg_month(unsigned short theMonth) : greg_month_rep(theMonth) {} - //! Convert the value back to a short - operator unsigned short() const {return value_;} - //! Returns month as number from 1 to 12 - unsigned short as_number() const {return value_;} - month_enum as_enum() const {return static_cast(value_);} - const char* as_short_string() const; - const char* as_long_string() const; -#ifndef BOOST_NO_STD_WSTRING - const wchar_t* as_short_wstring() const; - const wchar_t* as_long_wstring() const; -#endif // BOOST_NO_STD_WSTRING - //! Shared pointer to a map of Month strings (Names & Abbrev) & numbers - static month_map_ptr_type get_month_map_ptr(); - - /* parameterized as_*_string functions are intended to be called - * from a template function: "... as_short_string(charT c='\0');" */ - const char* as_short_string(char) const - { - return as_short_string(); - } - const char* as_long_string(char) const - { - return as_long_string(); - } -#ifndef BOOST_NO_STD_WSTRING - const wchar_t* as_short_string(wchar_t) const - { - return as_short_wstring(); - } - const wchar_t* as_long_string(wchar_t) const - { - return as_long_wstring(); - } -#endif // BOOST_NO_STD_WSTRING - }; - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_weekday.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_weekday.hpp deleted file mode 100644 index ab68fcd1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_weekday.hpp +++ /dev/null @@ -1,66 +0,0 @@ -#ifndef GREG_WEEKDAY_HPP___ -#define GREG_WEEKDAY_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include "boost/date_time/constrained_value.hpp" -#include "boost/date_time/date_defs.hpp" -#include "boost/date_time/compiler_config.hpp" -#include -#include - -namespace boost { -namespace gregorian { - - //bring enum values into the namespace - using date_time::Sunday; - using date_time::Monday; - using date_time::Tuesday; - using date_time::Wednesday; - using date_time::Thursday; - using date_time::Friday; - using date_time::Saturday; - - - //! Exception that flags that a weekday number is incorrect - struct bad_weekday : public std::out_of_range - { - bad_weekday() : std::out_of_range(std::string("Weekday is out of range 0..6")) {} - }; - typedef CV::simple_exception_policy greg_weekday_policies; - typedef CV::constrained_value greg_weekday_rep; - - - //! Represent a day within a week (range 0==Sun to 6==Sat) - class BOOST_DATE_TIME_DECL greg_weekday : public greg_weekday_rep { - public: - typedef boost::date_time::weekdays weekday_enum; - greg_weekday(unsigned short day_of_week_num) : - greg_weekday_rep(day_of_week_num) - {} - - unsigned short as_number() const {return value_;} - const char* as_short_string() const; - const char* as_long_string() const; -#ifndef BOOST_NO_STD_WSTRING - const wchar_t* as_short_wstring() const; - const wchar_t* as_long_wstring() const; -#endif // BOOST_NO_STD_WSTRING - weekday_enum as_enum() const {return static_cast(value_);} - - - }; - - - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_year.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_year.hpp deleted file mode 100644 index 322f40d0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_year.hpp +++ /dev/null @@ -1,53 +0,0 @@ -#ifndef GREG_YEAR_HPP___ -#define GREG_YEAR_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/constrained_value.hpp" -#include -#include - -namespace boost { -namespace gregorian { - - //! Exception type for gregorian year - struct bad_year : public std::out_of_range - { - bad_year() : - std::out_of_range(std::string("Year is out of valid range: 1400..10000")) - {} - }; - //! Policy class that declares error handling gregorian year type - typedef CV::simple_exception_policy greg_year_policies; - - //! Generated representation for gregorian year - typedef CV::constrained_value greg_year_rep; - - //! Represent a day of the month (range 1900 - 10000) - /*! This small class allows for simple conversion an integer value into - a year for the gregorian calendar. This currently only allows a - range of 1900 to 10000. Both ends of the range are a bit arbitrary - at the moment, but they are the limits of current testing of the - library. As such they may be increased in the future. - */ - class greg_year : public greg_year_rep { - public: - greg_year(unsigned short year) : greg_year_rep(year) {} - operator unsigned short() const {return value_;} - private: - - }; - - - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_ymd.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_ymd.hpp deleted file mode 100644 index e7d441ef..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/greg_ymd.hpp +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef DATE_TIME_GREG_YMD_HPP__ -#define DATE_TIME_GREG_YMD_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/year_month_day.hpp" -#include "boost/date_time/special_defs.hpp" -#include "boost/date_time/gregorian/greg_day.hpp" -#include "boost/date_time/gregorian/greg_year.hpp" -#include "boost/date_time/gregorian/greg_month.hpp" - -namespace boost { -namespace gregorian { - - typedef date_time::year_month_day_base greg_year_month_day; - - - -} } //namespace gregorian - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian.hpp deleted file mode 100644 index becbc068..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian.hpp +++ /dev/null @@ -1,38 +0,0 @@ -#ifndef GREGORIAN_HPP__ -#define GREGORIAN_HPP__ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -/*! @file gregorian.hpp - Single file header that provides overall include for all elements of - the gregorian date-time system. This includes the various types - defined, but also other functions for formatting and parsing. -*/ - - -#include "boost/date_time/compiler_config.hpp" -#include "boost/date_time/gregorian/gregorian_types.hpp" -#include "boost/date_time/gregorian/conversion.hpp" -#if defined(BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS) -#include "boost/date_time/gregorian/formatters_limited.hpp" -#else -#include "boost/date_time/gregorian/formatters.hpp" -#endif - -#if defined(USE_DATE_TIME_PRE_1_33_FACET_IO) -#include "boost/date_time/gregorian/greg_facet.hpp" -#else -#include "boost/date_time/gregorian/gregorian_io.hpp" -#endif // USE_DATE_TIME_PRE_1_33_FACET_IO - -#include "boost/date_time/gregorian/parsers.hpp" - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_io.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_io.hpp deleted file mode 100644 index e6ba01fe..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_io.hpp +++ /dev/null @@ -1,784 +0,0 @@ -#ifndef DATE_TIME_GREGORIAN_IO_HPP__ -#define DATE_TIME_GREGORIAN_IO_HPP__ - -/* Copyright (c) 2004-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include -#include -#include // i/ostreambuf_iterator -#include -#include -#include -#include -#include -#include -#include -#include // to_tm will be needed in the facets - -namespace boost { -namespace gregorian { - - - typedef boost::date_time::period_formatter wperiod_formatter; - typedef boost::date_time::period_formatter period_formatter; - - typedef boost::date_time::date_facet wdate_facet; - typedef boost::date_time::date_facet date_facet; - - typedef boost::date_time::period_parser period_parser; - typedef boost::date_time::period_parser wperiod_parser; - - typedef boost::date_time::special_values_formatter special_values_formatter; - typedef boost::date_time::special_values_formatter wspecial_values_formatter; - - typedef boost::date_time::special_values_parser special_values_parser; - typedef boost::date_time::special_values_parser wspecial_values_parser; - - typedef boost::date_time::date_input_facet date_input_facet; - typedef boost::date_time::date_input_facet wdate_input_facet; - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::date& d) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), d); - else { - //instantiate a custom facet for dealing with dates since the user - //has not put one in the stream so far. This is for efficiency - //since we would always need to reconstruct for every date - //if the locale did not already exist. Of course this will be overridden - //if the user imbues at some later point. With the default settings - //for the facet the resulting format will be the same as the - //std::time_facet settings. - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), d); - } - return os; - } - - //! input operator for date - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, date& d) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, d); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, d); - } - } - catch(...) { - // mask tells us what exceptions are turned on - std::ios_base::iostate exception_mask = is.exceptions(); - // if the user wants exceptions on failbit, we'll rethrow our - // date_time exception & set the failbit - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} // ignore this one - throw; // rethrow original exception - } - else { - // if the user want's to fail quietly, we simply set the failbit - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::date_duration& dd) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), dd); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), dd); - - } - return os; - } - - //! input operator for date_duration - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, date_duration& dd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, dd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, dd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::date_period& dp) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), dp); - else { - //instantiate a custom facet for dealing with date periods since the user - //has not put one in the stream so far. This is for efficiency - //since we would always need to reconstruct for every time period - //if the local did not already exist. Of course this will be overridden - //if the user imbues at some later point. With the default settings - //for the facet the resulting format will be the same as the - //std::time_facet settings. - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), dp); - - } - return os; - } - - //! input operator for date_period - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, date_period& dp) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, dp); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, dp); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - /********** small gregorian types **********/ - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::greg_month& gm) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), gm); - else { - custom_date_facet* f = new custom_date_facet();//-> 10/1074199752/32 because year & day not initialized in put(...) - //custom_date_facet* f = new custom_date_facet("%B"); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), gm); - } - return os; - } - - //! input operator for greg_month - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, greg_month& m) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, m); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, m); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::greg_weekday& gw) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), gw); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), gw); - } - return os; - } - - //! input operator for greg_weekday - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, greg_weekday& wd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, wd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, wd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - //NOTE: output operator for greg_day was not necessary - - //! input operator for greg_day - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, greg_day& gd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, gd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, gd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - //NOTE: output operator for greg_year was not necessary - - //! input operator for greg_year - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, greg_year& gy) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, gy); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, gy); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - /********** date generator types **********/ - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::partial_date& pd) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), pd); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), pd); - } - return os; - } - - //! input operator for partial_date - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, partial_date& pd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, pd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, pd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::nth_day_of_the_week_in_month& nkd) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), nkd); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), nkd); - } - return os; - } - - //! input operator for nth_day_of_the_week_in_month - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, - nth_day_of_the_week_in_month& nday) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, nday); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, nday); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::first_day_of_the_week_in_month& fkd) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), fkd); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), fkd); - } - return os; - } - - //! input operator for first_day_of_the_week_in_month - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, - first_day_of_the_week_in_month& fkd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, fkd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, fkd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::last_day_of_the_week_in_month& lkd) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), lkd); - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), lkd); - } - return os; - } - - //! input operator for last_day_of_the_week_in_month - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, - last_day_of_the_week_in_month& lkd) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, lkd); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, lkd); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::first_day_of_the_week_after& fda) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) { - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), fda); - } - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), fda); - } - return os; - } - - //! input operator for first_day_of_the_week_after - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, - first_day_of_the_week_after& fka) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, fka); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, fka); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const boost::gregorian::first_day_of_the_week_before& fdb) { - boost::io::ios_flags_saver iflags(os); - typedef boost::date_time::date_facet custom_date_facet; - std::ostreambuf_iterator output_itr(os); - if (std::has_facet(os.getloc())) { - std::use_facet(os.getloc()).put(output_itr, os, os.fill(), fdb); - } - else { - custom_date_facet* f = new custom_date_facet(); - std::locale l = std::locale(os.getloc(), f); - os.imbue(l); - f->put(output_itr, os, os.fill(), fdb); - } - return os; - } - - //! input operator for first_day_of_the_week_before - template - inline - std::basic_istream& - operator>>(std::basic_istream& is, - first_day_of_the_week_before& fkb) - { - boost::io::ios_flags_saver iflags(is); - typename std::basic_istream::sentry strm_sentry(is, false); - if (strm_sentry) { - try { - typedef typename date_time::date_input_facet date_input_facet; - - std::istreambuf_iterator sit(is), str_end; - if(std::has_facet(is.getloc())) { - std::use_facet(is.getloc()).get(sit, str_end, is, fkb); - } - else { - date_input_facet* f = new date_input_facet(); - std::locale l = std::locale(is.getloc(), f); - is.imbue(l); - f->get(sit, str_end, is, fkb); - } - } - catch(...) { - std::ios_base::iostate exception_mask = is.exceptions(); - if(std::ios_base::failbit & exception_mask) { - try { is.setstate(std::ios_base::failbit); } - catch(std::ios_base::failure&) {} - throw; // rethrow original exception - } - else { - is.setstate(std::ios_base::failbit); - } - - } - } - return is; - } - - -} } // namespaces - -#endif // DATE_TIME_GREGORIAN_IO_HPP__ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_types.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_types.hpp deleted file mode 100644 index 3f4b92fd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/gregorian_types.hpp +++ /dev/null @@ -1,109 +0,0 @@ -#ifndef _GREGORIAN_TYPES_HPP__ -#define _GREGORIAN_TYPES_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -/*! @file gregorian_types.hpp - Single file header that defines most of the types for the gregorian - date-time system. -*/ - -#include "boost/date_time/date.hpp" -#include "boost/date_time/period.hpp" -#include "boost/date_time/gregorian/greg_calendar.hpp" -#include "boost/date_time/gregorian/greg_duration.hpp" -#if defined(BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES) -#include "boost/date_time/gregorian/greg_duration_types.hpp" -#endif -#include "boost/date_time/gregorian/greg_date.hpp" -#include "boost/date_time/date_generators.hpp" -#include "boost/date_time/date_clock_device.hpp" -#include "boost/date_time/date_iterator.hpp" -#include "boost/date_time/adjust_functors.hpp" - -namespace boost { - -//! Gregorian date system based on date_time components -/*! This date system defines a full complement of types including - * a date, date_duration, date_period, day_clock, and a - * day_iterator. - */ -namespace gregorian { - //! Date periods for the gregorian system - /*!\ingroup date_basics - */ - typedef date_time::period date_period; - - //! A unifying date_generator base type - /*! A unifying date_generator base type for: - * partial_date, nth_day_of_the_week_in_month, - * first_day_of_the_week_in_month, and last_day_of_the_week_in_month - */ - typedef date_time::year_based_generator year_based_generator; - - //! A date generation object type - typedef date_time::partial_date partial_date; - - typedef date_time::nth_kday_of_month nth_kday_of_month; - typedef nth_kday_of_month nth_day_of_the_week_in_month; - - typedef date_time::first_kday_of_month first_kday_of_month; - typedef first_kday_of_month first_day_of_the_week_in_month; - - typedef date_time::last_kday_of_month last_kday_of_month; - typedef last_kday_of_month last_day_of_the_week_in_month; - - typedef date_time::first_kday_after first_kday_after; - typedef first_kday_after first_day_of_the_week_after; - - typedef date_time::first_kday_before first_kday_before; - typedef first_kday_before first_day_of_the_week_before; - - //! A clock to get the current day from the local computer - /*!\ingroup date_basics - */ - typedef date_time::day_clock day_clock; - - //! Base date_iterator type for gregorian types. - /*!\ingroup date_basics - */ - typedef date_time::date_itr_base date_iterator; - - //! A day level iterator - /*!\ingroup date_basics - */ - typedef date_time::date_itr, - date> day_iterator; - //! A week level iterator - /*!\ingroup date_basics - */ - typedef date_time::date_itr, - date> week_iterator; - //! A month level iterator - /*!\ingroup date_basics - */ - typedef date_time::date_itr, - date> month_iterator; - //! A year level iterator - /*!\ingroup date_basics - */ - typedef date_time::date_itr, - date> year_iterator; - - // bring in these date_generator functions from date_time namespace - using date_time::days_until_weekday; - using date_time::days_before_weekday; - using date_time::next_weekday; - using date_time::previous_weekday; - -} } //namespace gregorian - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/parsers.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/parsers.hpp deleted file mode 100644 index a2fa4e1d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian/parsers.hpp +++ /dev/null @@ -1,91 +0,0 @@ -#ifndef GREGORIAN_PARSERS_HPP___ -#define GREGORIAN_PARSERS_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/gregorian/gregorian_types.hpp" -#include "boost/date_time/date_parsing.hpp" -#include "boost/date_time/compiler_config.hpp" -#include "boost/date_time/parse_format_base.hpp" -#include -#include - -namespace boost { -namespace gregorian { - - //! Return special_value from string argument - /*! Return special_value from string argument. If argument is - * not one of the special value names (defined in src/gregorian/names.hpp), - * return 'not_special' */ - BOOST_DATE_TIME_DECL special_values special_value_from_string(const std::string& s); - - //! Deprecated: Use from_simple_string - inline date from_string(std::string s) { - return date_time::parse_date(s); - } - - //! From delimited date string where with order year-month-day eg: 2002-1-25 or 2003-Jan-25 (full month name is also accepted) - inline date from_simple_string(std::string s) { - return date_time::parse_date(s, date_time::ymd_order_iso); - } - - //! From delimited date string where with order year-month-day eg: 1-25-2003 or Jan-25-2003 (full month name is also accepted) - inline date from_us_string(std::string s) { - return date_time::parse_date(s, date_time::ymd_order_us); - } - - //! From delimited date string where with order day-month-year eg: 25-1-2002 or 25-Jan-2003 (full month name is also accepted) - inline date from_uk_string(std::string s) { - return date_time::parse_date(s, date_time::ymd_order_dmy); - } - - //! From iso type date string where with order year-month-day eg: 20020125 - inline date from_undelimited_string(std::string s) { - return date_time::parse_undelimited_date(s); - } - - //! From iso type date string where with order year-month-day eg: 20020125 - inline date date_from_iso_string(const std::string& s) { - return date_time::parse_undelimited_date(s); - } - -#if !(defined(BOOST_NO_STD_ITERATOR_TRAITS)) - //! Stream should hold a date in the form of: 2002-1-25. Month number, abbrev, or name are accepted - /* Arguments passed in by-value for convertability of char[] - * to iterator_type. Calls to from_stream_type are by-reference - * since conversion is already done */ - template - inline date from_stream(iterator_type beg, iterator_type end) { - if(beg == end) - { - return date(not_a_date_time); - } - typedef typename std::iterator_traits::value_type value_type; - return date_time::from_stream_type(beg, end, value_type()); - } -#endif //BOOST_NO_STD_ITERATOR_TRAITS - -#if (defined(_MSC_VER) && (_MSC_VER < 1300)) - // This function cannot be compiled with MSVC 6.0 due to internal compiler shorcomings -#else - //! Function to parse a date_period from a string (eg: [2003-Oct-31/2003-Dec-25]) - inline date_period date_period_from_string(const std::string& s){ - return date_time::from_simple_string_type(s); - } -# if !defined(BOOST_NO_STD_WSTRING) - //! Function to parse a date_period from a wstring (eg: [2003-Oct-31/2003-Dec-25]) - inline date_period date_period_from_wstring(const std::wstring& s){ - return date_time::from_simple_string_type(s); - } -# endif // BOOST_NO_STD_WSTRING -#endif - -} } //namespace gregorian - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.hpp deleted file mode 100644 index b645aa49..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.hpp +++ /dev/null @@ -1,70 +0,0 @@ -#ifndef DATE_TIME_GREGORIAN_CALENDAR_HPP__ -#define DATE_TIME_GREGORIAN_CALENDAR_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2010-01-10 11:17:23 -0800 (Sun, 10 Jan 2010) $ - */ - - -namespace boost { -namespace date_time { - - - //! An implementation of the Gregorian calendar - /*! This is a parameterized implementation of a proleptic Gregorian Calendar that - can be used in the creation of date systems or just to perform calculations. - All the methods of this class are static functions, so the intent is to - never create instances of this class. - @param ymd_type_ Struct type representing the year, month, day. The ymd_type must - define a of types for the year, month, and day. These types need to be - arithmetic types. - @param date_int_type_ Underlying type for the date count. Must be an arithmetic type. - */ - template - class gregorian_calendar_base { - public: - //! define a type a date split into components - typedef ymd_type_ ymd_type; - //! define a type for representing months - typedef typename ymd_type::month_type month_type; - //! define a type for representing days - typedef typename ymd_type::day_type day_type; - //! Type to hold a stand alone year value (eg: 2002) - typedef typename ymd_type::year_type year_type; - //! Define the integer type to use for internal calculations - typedef date_int_type_ date_int_type; - - - static unsigned short day_of_week(const ymd_type& ymd); - static int week_number(const ymd_type&ymd); - //static unsigned short day_of_year(date_int_type); - static date_int_type day_number(const ymd_type& ymd); - static date_int_type julian_day_number(const ymd_type& ymd); - static date_int_type modjulian_day_number(const ymd_type& ymd); - static ymd_type from_day_number(date_int_type); - static ymd_type from_julian_day_number(date_int_type); - static ymd_type from_modjulian_day_number(date_int_type); - static bool is_leap_year(year_type); - static unsigned short end_of_month_day(year_type y, month_type m); - static ymd_type epoch(); - static unsigned short days_in_week(); - - }; - - - -} } //namespace - -#ifndef NO_BOOST_DATE_TIME_INLINE -#include "boost/date_time/gregorian_calendar.ipp" -#endif - - - -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.ipp b/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.ipp deleted file mode 100644 index af19394f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/gregorian_calendar.ipp +++ /dev/null @@ -1,219 +0,0 @@ -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 09:04:10 -0700 (Sat, 22 Sep 2012) $ - */ - -#ifndef NO_BOOST_DATE_TIME_INLINE - #undef BOOST_DATE_TIME_INLINE - #define BOOST_DATE_TIME_INLINE inline -#endif - -namespace boost { -namespace date_time { - //! Return the day of the week (0==Sunday, 1==Monday, etc) - /*! Converts a year-month-day into a day of the week number - */ - template - BOOST_DATE_TIME_INLINE - unsigned short - gregorian_calendar_base::day_of_week(const ymd_type& ymd) { - unsigned short a = static_cast((14-ymd.month)/12); - unsigned short y = static_cast(ymd.year - a); - unsigned short m = static_cast(ymd.month + 12*a - 2); - unsigned short d = static_cast((ymd.day + y + (y/4) - (y/100) + (y/400) + (31*m)/12) % 7); - //std::cout << year << "-" << month << "-" << day << " is day: " << d << "\n"; - return d; - } - - //!Return the iso week number for the date - /*!Implements the rules associated with the iso 8601 week number. - Basically the rule is that Week 1 of the year is the week that contains - January 4th or the week that contains the first Thursday in January. - Reference for this algorithm is the Calendar FAQ by Claus Tondering, April 2000. - */ - template - BOOST_DATE_TIME_INLINE - int - gregorian_calendar_base::week_number(const ymd_type& ymd) { - unsigned long julianbegin = julian_day_number(ymd_type(ymd.year,1,1)); - unsigned long juliantoday = julian_day_number(ymd); - unsigned long day = (julianbegin + 3) % 7; - unsigned long week = (juliantoday + day - julianbegin + 4)/7; - - if ((week >= 1) && (week <= 52)) { - return week; - } - - if (week == 53) { - if((day==6) ||(day == 5 && is_leap_year(ymd.year))) { - return week; //under these circumstances week == 53. - } else { - return 1; //monday - wednesday is in week 1 of next year - } - } - //if the week is not in current year recalculate using the previous year as the beginning year - else if (week == 0) { - julianbegin = julian_day_number(ymd_type(static_cast(ymd.year-1),1,1)); - juliantoday = julian_day_number(ymd); - day = (julianbegin + 3) % 7; - week = (juliantoday + day - julianbegin + 4)/7; - return week; - } - - return week; //not reachable -- well except if day == 5 and is_leap_year != true - - } - - //! Convert a ymd_type into a day number - /*! The day number is an absolute number of days since the start of count - */ - template - BOOST_DATE_TIME_INLINE - date_int_type_ - gregorian_calendar_base::day_number(const ymd_type& ymd) - { - unsigned short a = static_cast((14-ymd.month)/12); - unsigned short y = static_cast(ymd.year + 4800 - a); - unsigned short m = static_cast(ymd.month + 12*a - 3); - unsigned long d = ymd.day + ((153*m + 2)/5) + 365*y + (y/4) - (y/100) + (y/400) - 32045; - return d; - } - - //! Convert a year-month-day into the julian day number - /*! Since this implementation uses julian day internally, this is the same as the day_number. - */ - template - BOOST_DATE_TIME_INLINE - date_int_type_ - gregorian_calendar_base::julian_day_number(const ymd_type& ymd) - { - return day_number(ymd); - } - - //! Convert year-month-day into a modified julian day number - /*! The day number is an absolute number of days. - * MJD 0 thus started on 17 Nov 1858(Gregorian) at 00:00:00 UTC - */ - template - BOOST_DATE_TIME_INLINE - date_int_type_ - gregorian_calendar_base::modjulian_day_number(const ymd_type& ymd) - { - return julian_day_number(ymd)-2400001; //prerounded - } - - //! Change a day number into a year-month-day - template - BOOST_DATE_TIME_INLINE - ymd_type_ - gregorian_calendar_base::from_day_number(date_int_type dayNumber) - { - date_int_type a = dayNumber + 32044; - date_int_type b = (4*a + 3)/146097; - date_int_type c = a-((146097*b)/4); - date_int_type d = (4*c + 3)/1461; - date_int_type e = c - (1461*d)/4; - date_int_type m = (5*e + 2)/153; - unsigned short day = static_cast(e - ((153*m + 2)/5) + 1); - unsigned short month = static_cast(m + 3 - 12 * (m/10)); - year_type year = static_cast(100*b + d - 4800 + (m/10)); - //std::cout << year << "-" << month << "-" << day << "\n"; - - return ymd_type(static_cast(year),month,day); - } - - //! Change a day number into a year-month-day - template - BOOST_DATE_TIME_INLINE - ymd_type_ - gregorian_calendar_base::from_julian_day_number(date_int_type dayNumber) - { - date_int_type a = dayNumber + 32044; - date_int_type b = (4*a+3)/146097; - date_int_type c = a - ((146097*b)/4); - date_int_type d = (4*c + 3)/1461; - date_int_type e = c - ((1461*d)/4); - date_int_type m = (5*e + 2)/153; - unsigned short day = static_cast(e - ((153*m + 2)/5) + 1); - unsigned short month = static_cast(m + 3 - 12 * (m/10)); - year_type year = static_cast(100*b + d - 4800 + (m/10)); - //std::cout << year << "-" << month << "-" << day << "\n"; - - return ymd_type(year,month,day); - } - - //! Change a modified julian day number into a year-month-day - template - BOOST_DATE_TIME_INLINE - ymd_type_ - gregorian_calendar_base::from_modjulian_day_number(date_int_type dayNumber) { - date_int_type jd = dayNumber + 2400001; //is 2400000.5 prerounded - return from_julian_day_number(jd); - } - - //! Determine if the provided year is a leap year - /*! - *@return true if year is a leap year, false otherwise - */ - template - BOOST_DATE_TIME_INLINE - bool - gregorian_calendar_base::is_leap_year(year_type year) - { - //divisible by 4, not if divisible by 100, but true if divisible by 400 - return (!(year % 4)) && ((year % 100) || (!(year % 400))); - } - - //! Calculate the last day of the month - /*! Find the day which is the end of the month given year and month - * No error checking is performed. - */ - template - BOOST_DATE_TIME_INLINE - unsigned short - gregorian_calendar_base::end_of_month_day(year_type year, - month_type month) - { - switch (month) { - case 2: - if (is_leap_year(year)) { - return 29; - } else { - return 28; - }; - case 4: - case 6: - case 9: - case 11: - return 30; - default: - return 31; - }; - - } - - //! Provide the ymd_type specification for the calandar start - template - BOOST_DATE_TIME_INLINE - ymd_type_ - gregorian_calendar_base::epoch() - { - return ymd_type(1400,1,1); - } - - //! Defines length of a week for week calculations - template - BOOST_DATE_TIME_INLINE - unsigned short - gregorian_calendar_base::days_in_week() - { - return 7; - } - - -} } //namespace gregorian - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/int_adapter.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/int_adapter.hpp deleted file mode 100644 index d1246e7b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/int_adapter.hpp +++ /dev/null @@ -1,509 +0,0 @@ -#ifndef _DATE_TIME_INT_ADAPTER_HPP__ -#define _DATE_TIME_INT_ADAPTER_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - - -#include "boost/config.hpp" -#include "boost/limits.hpp" //work around compilers without limits -#include "boost/date_time/special_defs.hpp" -#include "boost/date_time/locale_config.hpp" -#ifndef BOOST_DATE_TIME_NO_LOCALE -# include -#endif - -namespace boost { -namespace date_time { - - -//! Adapter to create integer types with +-infinity, and not a value -/*! This class is used internally in counted date/time representations. - * It adds the floating point like features of infinities and - * not a number. It also provides mathmatical operations with - * consideration to special values following these rules: - *@code - * +infinity - infinity == Not A Number (NAN) - * infinity * non-zero == infinity - * infinity * zero == NAN - * +infinity * -integer == -infinity - * infinity / infinity == NAN - * infinity * infinity == infinity - *@endcode - */ -template -class int_adapter { -public: - typedef int_type_ int_type; - int_adapter(int_type v) : - value_(v) - {} - static bool has_infinity() - { - return true; - } - static const int_adapter pos_infinity() - { - return (::std::numeric_limits::max)(); - } - static const int_adapter neg_infinity() - { - return (::std::numeric_limits::min)(); - } - static const int_adapter not_a_number() - { - return (::std::numeric_limits::max)()-1; - } - static int_adapter max BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return (::std::numeric_limits::max)()-2; - } - static int_adapter min BOOST_PREVENT_MACRO_SUBSTITUTION () - { - return (::std::numeric_limits::min)()+1; - } - static int_adapter from_special(special_values sv) - { - switch (sv) { - case not_a_date_time: return not_a_number(); - case neg_infin: return neg_infinity(); - case pos_infin: return pos_infinity(); - case max_date_time: return (max)(); - case min_date_time: return (min)(); - default: return not_a_number(); - } - } - static bool is_inf(int_type v) - { - return (v == neg_infinity().as_number() || - v == pos_infinity().as_number()); - } - static bool is_neg_inf(int_type v) - { - return (v == neg_infinity().as_number()); - } - static bool is_pos_inf(int_type v) - { - return (v == pos_infinity().as_number()); - } - static bool is_not_a_number(int_type v) - { - return (v == not_a_number().as_number()); - } - //! Returns either special value type or is_not_special - static special_values to_special(int_type v) - { - if (is_not_a_number(v)) return not_a_date_time; - if (is_neg_inf(v)) return neg_infin; - if (is_pos_inf(v)) return pos_infin; - return not_special; - } - - //-3 leaves room for representations of infinity and not a date - static int_type maxcount() - { - return (::std::numeric_limits::max)()-3; - } - bool is_infinity() const - { - return (value_ == neg_infinity().as_number() || - value_ == pos_infinity().as_number()); - } - bool is_pos_infinity()const - { - return(value_ == pos_infinity().as_number()); - } - bool is_neg_infinity()const - { - return(value_ == neg_infinity().as_number()); - } - bool is_nan() const - { - return (value_ == not_a_number().as_number()); - } - bool is_special() const - { - return(is_infinity() || is_nan()); - } - bool operator==(const int_adapter& rhs) const - { - return (compare(rhs) == 0); - } - bool operator==(const int& rhs) const - { - // quiets compiler warnings - bool is_signed = std::numeric_limits::is_signed; - if(!is_signed) - { - if(is_neg_inf(value_) && rhs == 0) - { - return false; - } - } - return (compare(rhs) == 0); - } - bool operator!=(const int_adapter& rhs) const - { - return (compare(rhs) != 0); - } - bool operator!=(const int& rhs) const - { - // quiets compiler warnings - bool is_signed = std::numeric_limits::is_signed; - if(!is_signed) - { - if(is_neg_inf(value_) && rhs == 0) - { - return true; - } - } - return (compare(rhs) != 0); - } - bool operator<(const int_adapter& rhs) const - { - return (compare(rhs) == -1); - } - bool operator<(const int& rhs) const - { - // quiets compiler warnings - bool is_signed = std::numeric_limits::is_signed; - if(!is_signed) - { - if(is_neg_inf(value_) && rhs == 0) - { - return true; - } - } - return (compare(rhs) == -1); - } - bool operator>(const int_adapter& rhs) const - { - return (compare(rhs) == 1); - } - int_type as_number() const - { - return value_; - } - //! Returns either special value type or is_not_special - special_values as_special() const - { - return int_adapter::to_special(value_); - } - //creates nasty ambiguities -// operator int_type() const -// { -// return value_; -// } - - /*! Operator allows for adding dissimilar int_adapter types. - * The return type will match that of the the calling object's type */ - template - inline - int_adapter operator+(const int_adapter& rhs) const - { - if(is_special() || rhs.is_special()) - { - if (is_nan() || rhs.is_nan()) - { - return int_adapter::not_a_number(); - } - if((is_pos_inf(value_) && rhs.is_neg_inf(rhs.as_number())) || - (is_neg_inf(value_) && rhs.is_pos_inf(rhs.as_number())) ) - { - return int_adapter::not_a_number(); - } - if (is_infinity()) - { - return *this; - } - if (rhs.is_pos_inf(rhs.as_number())) - { - return int_adapter::pos_infinity(); - } - if (rhs.is_neg_inf(rhs.as_number())) - { - return int_adapter::neg_infinity(); - } - } - return int_adapter(value_ + rhs.as_number()); - } - - int_adapter operator+(const int_type rhs) const - { - if(is_special()) - { - if (is_nan()) - { - return int_adapter(not_a_number()); - } - if (is_infinity()) - { - return *this; - } - } - return int_adapter(value_ + rhs); - } - - /*! Operator allows for subtracting dissimilar int_adapter types. - * The return type will match that of the the calling object's type */ - template - inline - int_adapter operator-(const int_adapter& rhs)const - { - if(is_special() || rhs.is_special()) - { - if (is_nan() || rhs.is_nan()) - { - return int_adapter::not_a_number(); - } - if((is_pos_inf(value_) && rhs.is_pos_inf(rhs.as_number())) || - (is_neg_inf(value_) && rhs.is_neg_inf(rhs.as_number())) ) - { - return int_adapter::not_a_number(); - } - if (is_infinity()) - { - return *this; - } - if (rhs.is_pos_inf(rhs.as_number())) - { - return int_adapter::neg_infinity(); - } - if (rhs.is_neg_inf(rhs.as_number())) - { - return int_adapter::pos_infinity(); - } - } - return int_adapter(value_ - rhs.as_number()); - } - int_adapter operator-(const int_type rhs) const - { - if(is_special()) - { - if (is_nan()) - { - return int_adapter(not_a_number()); - } - if (is_infinity()) - { - return *this; - } - } - return int_adapter(value_ - rhs); - } - - // should templatize this to be consistant with op +- - int_adapter operator*(const int_adapter& rhs)const - { - if(this->is_special() || rhs.is_special()) - { - return mult_div_specials(rhs); - } - return int_adapter(value_ * rhs.value_); - } - /*! Provided for cases when automatic conversion from - * 'int' to 'int_adapter' causes incorrect results. */ - int_adapter operator*(const int rhs) const - { - if(is_special()) - { - return mult_div_specials(rhs); - } - return int_adapter(value_ * rhs); - } - - // should templatize this to be consistant with op +- - int_adapter operator/(const int_adapter& rhs)const - { - if(this->is_special() || rhs.is_special()) - { - if(is_infinity() && rhs.is_infinity()) - { - return int_adapter(not_a_number()); - } - if(rhs != 0) - { - return mult_div_specials(rhs); - } - else { // let divide by zero blow itself up - return int_adapter(value_ / rhs.value_); - } - } - return int_adapter(value_ / rhs.value_); - } - /*! Provided for cases when automatic conversion from - * 'int' to 'int_adapter' causes incorrect results. */ - int_adapter operator/(const int rhs) const - { - if(is_special() && rhs != 0) - { - return mult_div_specials(rhs); - } - return int_adapter(value_ / rhs); - } - - // should templatize this to be consistant with op +- - int_adapter operator%(const int_adapter& rhs)const - { - if(this->is_special() || rhs.is_special()) - { - if(is_infinity() && rhs.is_infinity()) - { - return int_adapter(not_a_number()); - } - if(rhs != 0) - { - return mult_div_specials(rhs); - } - else { // let divide by zero blow itself up - return int_adapter(value_ % rhs.value_); - } - } - return int_adapter(value_ % rhs.value_); - } - /*! Provided for cases when automatic conversion from - * 'int' to 'int_adapter' causes incorrect results. */ - int_adapter operator%(const int rhs) const - { - if(is_special() && rhs != 0) - { - return mult_div_specials(rhs); - } - return int_adapter(value_ % rhs); - } -private: - int_type value_; - - //! returns -1, 0, 1, or 2 if 'this' is <, ==, >, or 'nan comparison' rhs - int compare(const int_adapter& rhs)const - { - if(this->is_special() || rhs.is_special()) - { - if(this->is_nan() || rhs.is_nan()) { - if(this->is_nan() && rhs.is_nan()) { - return 0; // equal - } - else { - return 2; // nan - } - } - if((is_neg_inf(value_) && !is_neg_inf(rhs.value_)) || - (is_pos_inf(rhs.value_) && !is_pos_inf(value_)) ) - { - return -1; // less than - } - if((is_pos_inf(value_) && !is_pos_inf(rhs.value_)) || - (is_neg_inf(rhs.value_) && !is_neg_inf(value_)) ) { - return 1; // greater than - } - } - if(value_ < rhs.value_) return -1; - if(value_ > rhs.value_) return 1; - // implied-> if(value_ == rhs.value_) - return 0; - } - /* When multiplying and dividing with at least 1 special value - * very simmilar rules apply. In those cases where the rules - * are different, they are handled in the respective operator - * function. */ - //! Assumes at least 'this' or 'rhs' is a special value - int_adapter mult_div_specials(const int_adapter& rhs)const - { - int min_value; - // quiets compiler warnings - bool is_signed = std::numeric_limits::is_signed; - if(is_signed) { - min_value = 0; - } - else { - min_value = 1;// there is no zero with unsigned - } - if(this->is_nan() || rhs.is_nan()) { - return int_adapter(not_a_number()); - } - if((*this > 0 && rhs > 0) || (*this < min_value && rhs < min_value)) { - return int_adapter(pos_infinity()); - } - if((*this > 0 && rhs < min_value) || (*this < min_value && rhs > 0)) { - return int_adapter(neg_infinity()); - } - //implied -> if(this->value_ == 0 || rhs.value_ == 0) - return int_adapter(not_a_number()); - } - /* Overloaded function necessary because of special - * situation where int_adapter is instantiated with - * 'unsigned' and func is called with negative int. - * It would produce incorrect results since 'unsigned' - * wraps around when initialized with a negative value */ - //! Assumes 'this' is a special value - int_adapter mult_div_specials(const int& rhs) const - { - int min_value; - // quiets compiler warnings - bool is_signed = std::numeric_limits::is_signed; - if(is_signed) { - min_value = 0; - } - else { - min_value = 1;// there is no zero with unsigned - } - if(this->is_nan()) { - return int_adapter(not_a_number()); - } - if((*this > 0 && rhs > 0) || (*this < min_value && rhs < 0)) { - return int_adapter(pos_infinity()); - } - if((*this > 0 && rhs < 0) || (*this < min_value && rhs > 0)) { - return int_adapter(neg_infinity()); - } - //implied -> if(this->value_ == 0 || rhs.value_ == 0) - return int_adapter(not_a_number()); - } - -}; - -#ifndef BOOST_DATE_TIME_NO_LOCALE - /*! Expected output is either a numeric representation - * or a special values representation.
- * Ex. "12", "+infinity", "not-a-number", etc. */ - //template, typename int_type> - template - inline - std::basic_ostream& - operator<<(std::basic_ostream& os, const int_adapter& ia) - { - if(ia.is_special()) { - // switch copied from date_names_put.hpp - switch(ia.as_special()) - { - case not_a_date_time: - os << "not-a-number"; - break; - case pos_infin: - os << "+infinity"; - break; - case neg_infin: - os << "-infinity"; - break; - default: - os << ""; - } - } - else { - os << ia.as_number(); - } - return os; - } -#endif - - -} } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/iso_format.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/iso_format.hpp deleted file mode 100644 index 1f9e73d6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/iso_format.hpp +++ /dev/null @@ -1,303 +0,0 @@ -#ifndef ISO_FORMAT_HPP___ -#define ISO_FORMAT_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/parse_format_base.hpp" - -namespace boost { -namespace date_time { - -//! Class to provide common iso formatting spec -template -class iso_format_base { -public: - //! Describe month format -- its an integer in iso format - static month_format_spec month_format() - { - return month_as_integer; - } - - //! String used printed is date is invalid - static const charT* not_a_date() - { - return "not-a-date-time"; - } - //! String used to for positive infinity value - static const charT* pos_infinity() - { - return "+infinity"; - } - //! String used to for positive infinity value - static const charT* neg_infinity() - { - return "-infinity"; - } - - //! ISO char for a year -- used in durations - static charT year_sep_char() - { - return 'Y'; - } - //! ISO char for a month - static charT month_sep_char() - { - return '-'; - } - //! ISO char for a day - static charT day_sep_char() - { - return '-'; - } - //! char for minute - static charT hour_sep_char() - { - return ':'; - } - //! char for minute - static charT minute_sep_char() - { - return ':'; - } - //! char for second - static charT second_sep_char() - { - return ':'; - } - //! ISO char for a period - static charT period_start_char() - { - return 'P'; - } - //! Used in time in mixed strings to set start of time - static charT time_start_char() - { - return 'T'; - } - - //! Used in mixed strings to identify start of a week number - static charT week_start_char() - { - return 'W'; - } - - //! Separators for periods - static charT period_sep_char() - { - return '/'; - } - //! Separator for hh:mm:ss - static charT time_sep_char() - { - return ':'; - } - //! Preferred Separator for hh:mm:ss,decimal_fraction - static charT fractional_time_sep_char() - { - return ','; - } - - static bool is_component_sep(charT sep) - { - switch(sep) { - case 'H': - case 'M': - case 'S': - case 'W': - case 'T': - case 'Y': - case 'D':return true; - default: - return false; - } - } - - static bool is_fractional_time_sep(charT sep) - { - switch(sep) { - case ',': - case '.': return true; - default: return false; - } - } - static bool is_timezone_sep(charT sep) - { - switch(sep) { - case '+': - case '-': return true; - default: return false; - } - } - static charT element_sep_char() - { - return '-'; - } - -}; - -#ifndef BOOST_NO_STD_WSTRING - -//! Class to provide common iso formatting spec -template<> -class iso_format_base { -public: - //! Describe month format -- its an integer in iso format - static month_format_spec month_format() - { - return month_as_integer; - } - - //! String used printed is date is invalid - static const wchar_t* not_a_date() - { - return L"not-a-date-time"; - } - //! String used to for positive infinity value - static const wchar_t* pos_infinity() - { - return L"+infinity"; - } - //! String used to for positive infinity value - static const wchar_t* neg_infinity() - { - return L"-infinity"; - } - - //! ISO char for a year -- used in durations - static wchar_t year_sep_char() - { - return 'Y'; - } - //! ISO char for a month - static wchar_t month_sep_char() - { - return '-'; - } - //! ISO char for a day - static wchar_t day_sep_char() - { - return '-'; - } - //! char for minute - static wchar_t hour_sep_char() - { - return ':'; - } - //! char for minute - static wchar_t minute_sep_char() - { - return ':'; - } - //! char for second - static wchar_t second_sep_char() - { - return ':'; - } - //! ISO char for a period - static wchar_t period_start_char() - { - return 'P'; - } - //! Used in time in mixed strings to set start of time - static wchar_t time_start_char() - { - return 'T'; - } - - //! Used in mixed strings to identify start of a week number - static wchar_t week_start_char() - { - return 'W'; - } - - //! Separators for periods - static wchar_t period_sep_char() - { - return '/'; - } - //! Separator for hh:mm:ss - static wchar_t time_sep_char() - { - return ':'; - } - //! Preferred Separator for hh:mm:ss,decimal_fraction - static wchar_t fractional_time_sep_char() - { - return ','; - } - - static bool is_component_sep(wchar_t sep) - { - switch(sep) { - case 'H': - case 'M': - case 'S': - case 'W': - case 'T': - case 'Y': - case 'D':return true; - default: - return false; - } - } - - static bool is_fractional_time_sep(wchar_t sep) - { - switch(sep) { - case ',': - case '.': return true; - default: return false; - } - } - static bool is_timezone_sep(wchar_t sep) - { - switch(sep) { - case '+': - case '-': return true; - default: return false; - } - } - static wchar_t element_sep_char() - { - return '-'; - } - -}; - -#endif // BOOST_NO_STD_WSTRING - -//! Format description for iso normal YYYYMMDD -template -class iso_format : public iso_format_base { -public: - //! The ios standard format doesn't use char separators - static bool has_date_sep_chars() - { - return false; - } -}; - -//! Extended format uses seperators YYYY-MM-DD -template -class iso_extended_format : public iso_format_base { -public: - //! Extended format needs char separators - static bool has_date_sep_chars() - { - return true; - } - -}; - -} } //namespace date_time - - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/locale_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/locale_config.hpp deleted file mode 100644 index 194d5dd3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/locale_config.hpp +++ /dev/null @@ -1,31 +0,0 @@ -#ifndef DATE_TIME_LOCALE_CONFIG_HPP___ -#define DATE_TIME_LOCALE_CONFIG_HPP___ - -/* Copyright (c) 2002-2006 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -// This file configures whether the library will support locales and hence -// iostream based i/o. Even if a compiler has some support for locales, -// any failure to be compatible gets the compiler on the exclusion list. -// -// At the moment this is defined for MSVC 6 and any compiler that -// defines BOOST_NO_STD_LOCALE (gcc 2.95.x) - -#include "boost/config.hpp" //sets BOOST_NO_STD_LOCALE -#include "boost/detail/workaround.hpp" - -//This file basically becomes a noop if locales are not properly supported -#if (defined(BOOST_NO_STD_LOCALE) \ - || (BOOST_WORKAROUND( BOOST_MSVC, < 1300)) \ - || (BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x581 )) ) ) -#define BOOST_DATE_TIME_NO_LOCALE -#endif - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/microsec_time_clock.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/microsec_time_clock.hpp deleted file mode 100644 index 177811ee..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/microsec_time_clock.hpp +++ /dev/null @@ -1,127 +0,0 @@ -#ifndef DATE_TIME_HIGHRES_TIME_CLOCK_HPP___ -#define DATE_TIME_HIGHRES_TIME_CLOCK_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2010-05-10 02:15:48 -0700 (Mon, 10 May 2010) $ - */ - - -/*! @file microsec_time_clock.hpp - This file contains a high resolution time clock implementation. -*/ - -#include -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK - -namespace boost { -namespace date_time { - - //! A clock providing microsecond level resolution - /*! A high precision clock that measures the local time - * at a resolution up to microseconds and adjusts to the - * resolution of the time system. For example, for the - * a library configuration with nano second resolution, - * the last 3 places of the fractional seconds will always - * be 000 since there are 1000 nano-seconds in a micro second. - */ - template - class microsec_clock - { - private: - //! Type for the function used to convert time_t to tm - typedef std::tm* (*time_converter)(const std::time_t*, std::tm*); - - public: - typedef typename time_type::date_type date_type; - typedef typename time_type::time_duration_type time_duration_type; - typedef typename time_duration_type::rep_type resolution_traits_type; - - //! return a local time object for the given zone, based on computer clock - //JKG -- looks like we could rewrite this against universal_time - template - static time_type local_time(shared_ptr tz_ptr) - { - typedef typename time_type::utc_time_type utc_time_type; - typedef second_clock second_clock; - // we'll need to know the utc_offset this machine has - // in order to get a utc_time_type set to utc - utc_time_type utc_time = second_clock::universal_time(); - time_duration_type utc_offset = second_clock::local_time() - utc_time; - // use micro clock to get a local time with sub seconds - // and adjust it to get a true utc time reading with sub seconds - utc_time = microsec_clock::local_time() - utc_offset; - return time_type(utc_time, tz_ptr); - } - - //! Returns the local time based on computer clock settings - static time_type local_time() - { - return create_time(&c_time::localtime); - } - - //! Returns the UTC time based on computer settings - static time_type universal_time() - { - return create_time(&c_time::gmtime); - } - - private: - static time_type create_time(time_converter converter) - { -#ifdef BOOST_HAS_GETTIMEOFDAY - timeval tv; - gettimeofday(&tv, 0); //gettimeofday does not support TZ adjust on Linux. - std::time_t t = tv.tv_sec; - boost::uint32_t sub_sec = tv.tv_usec; -#elif defined(BOOST_HAS_FTIME) - winapi::file_time ft; - winapi::get_system_time_as_file_time(ft); - uint64_t micros = winapi::file_time_to_microseconds(ft); // it will not wrap, since ft is the current time - // and cannot be before 1970-Jan-01 - std::time_t t = static_cast(micros / 1000000UL); // seconds since epoch - // microseconds -- static casts supress warnings - boost::uint32_t sub_sec = static_cast(micros % 1000000UL); -#else -#error Internal Boost.DateTime error: BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK is defined, however neither gettimeofday nor FILETIME support is detected. -#endif - - std::tm curr; - std::tm* curr_ptr = converter(&t, &curr); - date_type d(static_cast< typename date_type::year_type::value_type >(curr_ptr->tm_year + 1900), - static_cast< typename date_type::month_type::value_type >(curr_ptr->tm_mon + 1), - static_cast< typename date_type::day_type::value_type >(curr_ptr->tm_mday)); - - //The following line will adjust the fractional second tick in terms - //of the current time system. For example, if the time system - //doesn't support fractional seconds then res_adjust returns 0 - //and all the fractional seconds return 0. - int adjust = static_cast< int >(resolution_traits_type::res_adjust() / 1000000); - - time_duration_type td(static_cast< typename time_duration_type::hour_type >(curr_ptr->tm_hour), - static_cast< typename time_duration_type::min_type >(curr_ptr->tm_min), - static_cast< typename time_duration_type::sec_type >(curr_ptr->tm_sec), - sub_sec * adjust); - - return time_type(d,td); - } - }; - - -} } //namespace date_time - -#endif //BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/parse_format_base.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/parse_format_base.hpp deleted file mode 100644 index 087baf95..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/parse_format_base.hpp +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef DATE_TIME_PARSE_FORMAT_BASE__ -#define DATE_TIME_PARSE_FORMAT_BASE__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -namespace boost { -namespace date_time { - - //! Enum for distinguishing parsing and formatting options - enum month_format_spec {month_as_integer, month_as_short_string, - month_as_long_string}; - - //! Enum for distinguishing the order of Month, Day, & Year. - /*! Enum for distinguishing the order in which Month, Day, & Year - * will appear in a date string */ - enum ymd_order_spec {ymd_order_iso, //order is year-month-day - ymd_order_dmy, //day-month-year - ymd_order_us}; //order is month-day-year - - -} }//namespace date_time - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/period.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/period.hpp deleted file mode 100644 index 3e34def3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/period.hpp +++ /dev/null @@ -1,377 +0,0 @@ -#ifndef DATE_TIME_PERIOD_HPP___ -#define DATE_TIME_PERIOD_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -/*! \file period.hpp - This file contain the implementation of the period abstraction. This is - basically the same idea as a range. Although this class is intended for - use in the time library, it is pretty close to general enough for other - numeric uses. - -*/ - -#include "boost/operators.hpp" - - -namespace boost { -namespace date_time { - //!Provides generalized period type useful in date-time systems - /*!This template uses a class to represent a time point within the period - and another class to represent a duration. As a result, this class is - not appropriate for use when the number and duration representation - are the same (eg: in the regular number domain). - - A period can be specified by providing either the begining point and - a duration or the begining point and the end point( end is NOT part - of the period but 1 unit past it. A period will be "invalid" if either - end_point <= begin_point or the given duration is <= 0. Any valid period - will return false for is_null(). - - Zero length periods are also considered invalid. Zero length periods are - periods where the begining and end points are the same, or, the given - duration is zero. For a zero length period, the last point will be one - unit less than the begining point. - - In the case that the begin and last are the same, the period has a - length of one unit. - - The best way to handle periods is usually to provide a begining point and - a duration. So, day1 + 7 days is a week period which includes all of the - first day and 6 more days (eg: Sun to Sat). - - */ - template - class period : private - boost::less_than_comparable - , boost::equality_comparable< period - > > - { - public: - typedef point_rep point_type; - typedef duration_rep duration_type; - - period(point_rep first_point, point_rep end_point); - period(point_rep first_point, duration_rep len); - point_rep begin() const; - point_rep end() const; - point_rep last() const; - duration_rep length() const; - bool is_null() const; - bool operator==(const period& rhs) const; - bool operator<(const period& rhs) const; - void shift(const duration_rep& d); - void expand(const duration_rep& d); - bool contains(const point_rep& point) const; - bool contains(const period& other) const; - bool intersects(const period& other) const; - bool is_adjacent(const period& other) const; - bool is_before(const point_rep& point) const; - bool is_after(const point_rep& point) const; - period intersection(const period& other) const; - period merge(const period& other) const; - period span(const period& other) const; - private: - point_rep begin_; - point_rep last_; - }; - - //! create a period from begin to last eg: [begin,end) - /*! If end <= begin then the period will be invalid - */ - template - inline - period::period(point_rep first_point, - point_rep end_point) : - begin_(first_point), - last_(end_point - duration_rep::unit()) - {} - - //! create a period as [begin, begin+len) - /*! If len is <= 0 then the period will be invalid - */ - template - inline - period::period(point_rep first_point, duration_rep len) : - begin_(first_point), - last_(first_point + len-duration_rep::unit()) - { } - - - //! Return the first element in the period - template - inline - point_rep period::begin() const - { - return begin_; - } - - //! Return one past the last element - template - inline - point_rep period::end() const - { - return last_ + duration_rep::unit(); - } - - //! Return the last item in the period - template - inline - point_rep period::last() const - { - return last_; - } - - //! True if period is ill formed (length is zero or less) - template - inline - bool period::is_null() const - { - return end() <= begin_; - } - - //! Return the length of the period - template - inline - duration_rep period::length() const - { - if(last_ < begin_){ // invalid period - return last_+duration_rep::unit() - begin_; - } - else{ - return end() - begin_; // normal case - } - } - - //! Equality operator - template - inline - bool period::operator==(const period& rhs) const - { - return ((begin_ == rhs.begin_) && - (last_ == rhs.last_)); - } - - //! Strict as defined by rhs.last <= lhs.last - template - inline - bool period::operator<(const period& rhs) const - { - return (last_ < rhs.begin_); - } - - - //! Shift the start and end by the specified amount - template - inline - void period::shift(const duration_rep& d) - { - begin_ = begin_ + d; - last_ = last_ + d; - } - - /** Expands the size of the period by the duration on both ends. - * - *So before expand - *@code - * - * [-------] - * ^ ^ ^ ^ ^ ^ ^ - * 1 2 3 4 5 6 7 - * - *@endcode - * After expand(2) - *@code - * - * [----------------------] - * ^ ^ ^ ^ ^ ^ ^ - * 1 2 3 4 5 6 7 - * - *@endcode - */ - template - inline - void period::expand(const duration_rep& d) - { - begin_ = begin_ - d; - last_ = last_ + d; - } - - //! True if the point is inside the period, zero length periods contain no points - template - inline - bool period::contains(const point_rep& point) const - { - return ((point >= begin_) && - (point <= last_)); - } - - - //! True if this period fully contains (or equals) the other period - template - inline - bool period::contains(const period& other) const - { - return ((begin_ <= other.begin_) && (last_ >= other.last_)); - } - - - //! True if periods are next to each other without a gap. - /* In the example below, p1 and p2 are adjacent, but p3 is not adjacent - * with either of p1 or p2. - *@code - * [-p1-) - * [-p2-) - * [-p3-) - *@endcode - */ - template - inline - bool - period::is_adjacent(const period& other) const - { - return (other.begin() == end() || - begin_ == other.end()); - } - - - //! True if all of the period is prior or t < start - /* In the example below only point 1 would evaluate to true. - *@code - * [---------]) - * ^ ^ ^ ^ ^ - * 1 2 3 4 5 - * - *@endcode - */ - template - inline - bool - period::is_after(const point_rep& t) const - { - if (is_null()) - { - return false; //null period isn't after - } - - return t < begin_; - } - - //! True if all of the period is prior to the passed point or end <= t - /* In the example below points 4 and 5 return true. - *@code - * [---------]) - * ^ ^ ^ ^ ^ - * 1 2 3 4 5 - * - *@endcode - */ - template - inline - bool - period::is_before(const point_rep& t) const - { - if (is_null()) - { - return false; //null period isn't before anything - } - - return last_ < t; - } - - - //! True if the periods overlap in any way - /* In the example below p1 intersects with p2, p4, and p6. - *@code - * [---p1---) - * [---p2---) - * [---p3---) - * [---p4---) - * [-p5-) - * [-p6-) - *@endcode - */ - template - inline - bool period::intersects(const period& other) const - { - return ( contains(other.begin_) || - other.contains(begin_) || - ((other.begin_ < begin_) && (other.last_ >= begin_))); - } - - //! Returns the period of intersection or invalid range no intersection - template - inline - period - period::intersection(const period& other) const - { - if (begin_ > other.begin_) { - if (last_ <= other.last_) { //case2 - return *this; - } - //case 1 - return period(begin_, other.end()); - } - else { - if (last_ <= other.last_) { //case3 - return period(other.begin_, this->end()); - } - //case4 - return other; - } - //unreachable - } - - //! Returns the union of intersecting periods -- or null period - /*! - */ - template - inline - period - period::merge(const period& other) const - { - if (this->intersects(other)) { - if (begin_ < other.begin_) { - return period(begin_, last_ > other.last_ ? this->end() : other.end()); - } - - return period(other.begin_, last_ > other.last_ ? this->end() : other.end()); - - } - return period(begin_,begin_); // no intersect return null - } - - //! Combine two periods with earliest start and latest end. - /*! Combines two periods and any gap between them such that - * start = min(p1.start, p2.start) - * end = max(p1.end , p2.end) - *@code - * [---p1---) - * [---p2---) - * result: - * [-----------p3----------) - *@endcode - */ - template - inline - period - period::span(const period& other) const - { - point_rep start((begin_ < other.begin_) ? begin() : other.begin()); - point_rep newend((last_ < other.last_) ? other.end() : this->end()); - return period(start, newend); - } - - -} } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/period_formatter.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/period_formatter.hpp deleted file mode 100644 index b6ddc821..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/period_formatter.hpp +++ /dev/null @@ -1,196 +0,0 @@ - -#ifndef DATETIME_PERIOD_FORMATTER_HPP___ -#define DATETIME_PERIOD_FORMATTER_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - - - -namespace boost { namespace date_time { - - - //! Not a facet, but a class used to specify and control period formats - /*! Provides settings for the following: - * - period_separator -- default '/' - * - period_open_start_delimeter -- default '[' - * - period_open_range_end_delimeter -- default ')' - * - period_closed_range_end_delimeter -- default ']' - * - display_as_open_range, display_as_closed_range -- default closed_range - * - * Thus the default formatting for a period is as follows: - *@code - * [period.start()/period.last()] - *@endcode - * So for a typical date_period this would be - *@code - * [2004-Jan-04/2004-Feb-01] - *@endcode - * where the date formatting is controlled by the date facet - */ - template > > - class period_formatter { - public: - typedef std::basic_string string_type; - typedef CharT char_type; - typedef typename std::basic_string::const_iterator const_itr_type; - typedef std::vector > collection_type; - - static const char_type default_period_separator[2]; - static const char_type default_period_start_delimeter[2]; - static const char_type default_period_open_range_end_delimeter[2]; - static const char_type default_period_closed_range_end_delimeter[2]; - - enum range_display_options { AS_OPEN_RANGE, AS_CLOSED_RANGE }; - - //! Constructor that sets up period formatter options -- default should suffice most cases. - period_formatter(range_display_options range_option_in = AS_CLOSED_RANGE, - const char_type* const period_separator = default_period_separator, - const char_type* const period_start_delimeter = default_period_start_delimeter, - const char_type* const period_open_range_end_delimeter = default_period_open_range_end_delimeter, - const char_type* const period_closed_range_end_delimeter = default_period_closed_range_end_delimeter) : - m_range_option(range_option_in), - m_period_separator(period_separator), - m_period_start_delimeter(period_start_delimeter), - m_open_range_end_delimeter(period_open_range_end_delimeter), - m_closed_range_end_delimeter(period_closed_range_end_delimeter) - {} - - //! Puts the characters between period elements into stream -- default is / - OutItrT put_period_separator(OutItrT& oitr) const - { - const_itr_type ci = m_period_separator.begin(); - while (ci != m_period_separator.end()) { - *oitr = *ci; - ci++; - } - return oitr; - } - - //! Puts the period start characters into stream -- default is [ - OutItrT put_period_start_delimeter(OutItrT& oitr) const - { - const_itr_type ci = m_period_start_delimeter.begin(); - while (ci != m_period_start_delimeter.end()) { - *oitr = *ci; - ci++; - } - return oitr; - } - - //! Puts the period end characters into stream as controled by open/closed range setting. - OutItrT put_period_end_delimeter(OutItrT& oitr) const - { - - const_itr_type ci, end; - if (m_range_option == AS_OPEN_RANGE) { - ci = m_open_range_end_delimeter.begin(); - end = m_open_range_end_delimeter.end(); - } - else { - ci = m_closed_range_end_delimeter.begin(); - end = m_closed_range_end_delimeter.end(); - } - while (ci != end) { - *oitr = *ci; - ci++; - } - return oitr; - } - - range_display_options range_option() const - { - return m_range_option; - } - - //! Reset the range_option control - void - range_option(range_display_options option) const - { - m_range_option = option; - } - void delimiter_strings(const string_type& , - const string_type& , - const string_type& , - const string_type& ) - { - m_period_separator; - m_period_start_delimeter; - m_open_range_end_delimeter; - m_closed_range_end_delimeter; - } - - - //! Generic code to output a period -- no matter the period type. - /*! This generic code will output any period using a facet to - * to output the 'elements'. For example, in the case of a date_period - * the elements will be instances of a date which will be formatted - * according the to setup in the passed facet parameter. - * - * The steps for formatting a period are always the same: - * - put the start delimiter - * - put start element - * - put the separator - * - put either last or end element depending on range settings - * - put end delimeter depending on range settings - * - * Thus for a typical date period the result might look like this: - *@code - * - * [March 01, 2004/June 07, 2004] <-- closed range - * [March 01, 2004/June 08, 2004) <-- open range - * - *@endcode - */ - template - OutItrT put_period(OutItrT next, - std::ios_base& a_ios, - char_type a_fill, - const period_type& p, - const facet_type& facet) const { - put_period_start_delimeter(next); - next = facet.put(next, a_ios, a_fill, p.begin()); - put_period_separator(next); - if (m_range_option == AS_CLOSED_RANGE) { - facet.put(next, a_ios, a_fill, p.last()); - } - else { - facet.put(next, a_ios, a_fill, p.end()); - } - put_period_end_delimeter(next); - return next; - } - - - private: - range_display_options m_range_option; - string_type m_period_separator; - string_type m_period_start_delimeter; - string_type m_open_range_end_delimeter; - string_type m_closed_range_end_delimeter; - }; - - template - const typename period_formatter::char_type - period_formatter::default_period_separator[2] = {'/'}; - - template - const typename period_formatter::char_type - period_formatter::default_period_start_delimeter[2] = {'['}; - - template - const typename period_formatter::char_type - period_formatter::default_period_open_range_end_delimeter[2] = {')'}; - - template - const typename period_formatter::char_type - period_formatter::default_period_closed_range_end_delimeter[2] = {']'}; - - } } //namespace boost::date_time - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/period_parser.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/period_parser.hpp deleted file mode 100644 index 84b9d137..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/period_parser.hpp +++ /dev/null @@ -1,198 +0,0 @@ - -#ifndef DATETIME_PERIOD_PARSER_HPP___ -#define DATETIME_PERIOD_PARSER_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-13 12:10:23 -0800 (Thu, 13 Nov 2008) $ - */ - -#include -#include -#include - - -namespace boost { namespace date_time { - - - //! Not a facet, but a class used to specify and control period parsing - /*! Provides settings for the following: - * - period_separator -- default '/' - * - period_open_start_delimeter -- default '[' - * - period_open_range_end_delimeter -- default ')' - * - period_closed_range_end_delimeter -- default ']' - * - display_as_open_range, display_as_closed_range -- default closed_range - * - * For a typical date_period, the contents of the input stream would be - *@code - * [2004-Jan-04/2004-Feb-01] - *@endcode - * where the date format is controlled by the date facet - */ - template - class period_parser { - public: - typedef std::basic_string string_type; - typedef CharT char_type; - //typedef typename std::basic_string::const_iterator const_itr_type; - typedef std::istreambuf_iterator stream_itr_type; - typedef string_parse_tree parse_tree_type; - typedef typename parse_tree_type::parse_match_result_type match_results; - typedef std::vector > collection_type; - - static const char_type default_period_separator[2]; - static const char_type default_period_start_delimeter[2]; - static const char_type default_period_open_range_end_delimeter[2]; - static const char_type default_period_closed_range_end_delimeter[2]; - - enum period_range_option { AS_OPEN_RANGE, AS_CLOSED_RANGE }; - - //! Constructor that sets up period parser options - period_parser(period_range_option range_opt = AS_CLOSED_RANGE, - const char_type* const period_separator = default_period_separator, - const char_type* const period_start_delimeter = default_period_start_delimeter, - const char_type* const period_open_range_end_delimeter = default_period_open_range_end_delimeter, - const char_type* const period_closed_range_end_delimeter = default_period_closed_range_end_delimeter) - : m_range_option(range_opt) - { - delimiters.push_back(string_type(period_separator)); - delimiters.push_back(string_type(period_start_delimeter)); - delimiters.push_back(string_type(period_open_range_end_delimeter)); - delimiters.push_back(string_type(period_closed_range_end_delimeter)); - } - - period_parser(const period_parser& p_parser) - { - this->delimiters = p_parser.delimiters; - this->m_range_option = p_parser.m_range_option; - } - - period_range_option range_option() const - { - return m_range_option; - } - void range_option(period_range_option option) - { - m_range_option = option; - } - collection_type delimiter_strings() const - { - return delimiters; - } - void delimiter_strings(const string_type& separator, - const string_type& start_delim, - const string_type& open_end_delim, - const string_type& closed_end_delim) - { - delimiters.clear(); - delimiters.push_back(separator); - delimiters.push_back(start_delim); - delimiters.push_back(open_end_delim); - delimiters.push_back(closed_end_delim); - } - - //! Generic code to parse a period -- no matter the period type. - /*! This generic code will parse any period using a facet to - * to get the 'elements'. For example, in the case of a date_period - * the elements will be instances of a date which will be parsed - * according the to setup in the passed facet parameter. - * - * The steps for parsing a period are always the same: - * - consume the start delimiter - * - get start element - * - consume the separator - * - get either last or end element depending on range settings - * - consume the end delimeter depending on range settings - * - * Thus for a typical date period the contents of the input stream - * might look like this: - *@code - * - * [March 01, 2004/June 07, 2004] <-- closed range - * [March 01, 2004/June 08, 2004) <-- open range - * - *@endcode - */ - template - period_type get_period(stream_itr_type& sitr, - stream_itr_type& stream_end, - std::ios_base& a_ios, - const period_type& /* p */, - const duration_type& dur_unit, - const facet_type& facet) const - { - // skip leading whitespace - while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } - - typedef typename period_type::point_type point_type; - point_type p1(not_a_date_time), p2(not_a_date_time); - - - consume_delim(sitr, stream_end, delimiters[START]); // start delim - facet.get(sitr, stream_end, a_ios, p1); // first point - consume_delim(sitr, stream_end, delimiters[SEPARATOR]); // separator - facet.get(sitr, stream_end, a_ios, p2); // second point - - // period construction parameters are always open range [begin, end) - if (m_range_option == AS_CLOSED_RANGE) { - consume_delim(sitr, stream_end, delimiters[CLOSED_END]);// end delim - // add 1 duration unit to p2 to make range open - p2 += dur_unit; - } - else { - consume_delim(sitr, stream_end, delimiters[OPEN_END]); // end delim - } - - return period_type(p1, p2); - } - - private: - collection_type delimiters; - period_range_option m_range_option; - - enum delim_ids { SEPARATOR, START, OPEN_END, CLOSED_END }; - - //! throws ios_base::failure if delimiter and parsed data do not match - void consume_delim(stream_itr_type& sitr, - stream_itr_type& stream_end, - const string_type& delim) const - { - /* string_parse_tree will not parse a string of punctuation characters - * without knowing exactly how many characters to process - * Ex [2000. Will not parse out the '[' string without knowing - * to process only one character. By using length of the delimiter - * string we can safely iterate past it. */ - string_type s; - for(unsigned int i = 0; i < delim.length() && sitr != stream_end; ++i) { - s += *sitr; - ++sitr; - } - if(s != delim) { - boost::throw_exception(std::ios_base::failure("Parse failed. Expected '" - + convert_string_type(delim) + "' but found '" + convert_string_type(s) + "'")); - } - } - }; - - template - const typename period_parser::char_type - period_parser::default_period_separator[2] = {'/'}; - - template - const typename period_parser::char_type - period_parser::default_period_start_delimeter[2] = {'['}; - - template - const typename period_parser::char_type - period_parser::default_period_open_range_end_delimeter[2] = {')'}; - - template - const typename period_parser::char_type - period_parser::default_period_closed_range_end_delimeter[2] = {']'}; - - } } //namespace boost::date_time - -#endif // DATETIME_PERIOD_PARSER_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/conversion.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/conversion.hpp deleted file mode 100644 index 83ccf600..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/conversion.hpp +++ /dev/null @@ -1,94 +0,0 @@ -#ifndef POSIX_TIME_CONVERSION_HPP___ -#define POSIX_TIME_CONVERSION_HPP___ - -/* Copyright (c) 2002-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2010-06-09 11:10:13 -0700 (Wed, 09 Jun 2010) $ - */ - -#include -#include -#include -#include -#include -#include // absolute_value -#include - -namespace boost { - -namespace posix_time { - - - //! Function that converts a time_t into a ptime. - inline - ptime from_time_t(std::time_t t) - { - ptime start(gregorian::date(1970,1,1)); - return start + seconds(static_cast(t)); - } - - //! Convert a time to a tm structure truncating any fractional seconds - inline - std::tm to_tm(const boost::posix_time::ptime& t) { - std::tm timetm = boost::gregorian::to_tm(t.date()); - boost::posix_time::time_duration td = t.time_of_day(); - timetm.tm_hour = td.hours(); - timetm.tm_min = td.minutes(); - timetm.tm_sec = td.seconds(); - timetm.tm_isdst = -1; // -1 used when dst info is unknown - return timetm; - } - //! Convert a time_duration to a tm structure truncating any fractional seconds and zeroing fields for date components - inline - std::tm to_tm(const boost::posix_time::time_duration& td) { - std::tm timetm; - std::memset(&timetm, 0, sizeof(timetm)); - timetm.tm_hour = date_time::absolute_value(td.hours()); - timetm.tm_min = date_time::absolute_value(td.minutes()); - timetm.tm_sec = date_time::absolute_value(td.seconds()); - timetm.tm_isdst = -1; // -1 used when dst info is unknown - return timetm; - } - - //! Convert a tm struct to a ptime ignoring is_dst flag - inline - ptime ptime_from_tm(const std::tm& timetm) { - boost::gregorian::date d = boost::gregorian::date_from_tm(timetm); - return ptime(d, time_duration(timetm.tm_hour, timetm.tm_min, timetm.tm_sec)); - } - - -#if defined(BOOST_HAS_FTIME) - - //! Function to create a time object from an initialized FILETIME struct. - /*! Function to create a time object from an initialized FILETIME struct. - * A FILETIME struct holds 100-nanosecond units (0.0000001). When - * built with microsecond resolution the FILETIME's sub second value - * will be truncated. Nanosecond resolution has no truncation. - * - * \note FILETIME is part of the Win32 API, so it is not portable to non-windows - * platforms. - * - * \note The function is templated on the FILETIME type, so that - * it can be used with both native FILETIME and the ad-hoc - * boost::date_time::winapi::file_time type. - */ - template< typename TimeT, typename FileTimeT > - inline - TimeT from_ftime(const FileTimeT& ft) - { - return boost::date_time::time_from_ftime(ft); - } - -#endif // BOOST_HAS_FTIME - -} } //namespace boost::posix_time - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/date_duration_operators.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/date_duration_operators.hpp deleted file mode 100644 index 6846a778..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/date_duration_operators.hpp +++ /dev/null @@ -1,114 +0,0 @@ -#ifndef DATE_DURATION_OPERATORS_HPP___ -#define DATE_DURATION_OPERATORS_HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Subject to the Boost Software License, Version 1.0. - * (See accompanying file LICENSE_1_0.txt or - * http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/gregorian/greg_duration_types.hpp" -#include "boost/date_time/posix_time/ptime.hpp" - -namespace boost { -namespace posix_time { - - /*!@file date_duration_operators.hpp Operators for ptime and - * optional gregorian types. Operators use snap-to-end-of-month behavior. - * Further details on this behavior can be found in reference for - * date_time/date_duration_types.hpp and documentation for - * month and year iterators. - */ - - - /*! Adds a months object and a ptime. Result will be same - * day-of-month as ptime unless original day was the last day of month. - * see date_time::months_duration for more details */ - inline - ptime - operator+(const ptime& t, const boost::gregorian::months& m) - { - return t + m.get_offset(t.date()); - } - - /*! Adds a months object to a ptime. Result will be same - * day-of-month as ptime unless original day was the last day of month. - * see date_time::months_duration for more details */ - inline - ptime - operator+=(ptime& t, const boost::gregorian::months& m) - { - // get_neg_offset returns a negative duration, so we add - return t += m.get_offset(t.date()); - } - - /*! Subtracts a months object and a ptime. Result will be same - * day-of-month as ptime unless original day was the last day of month. - * see date_time::months_duration for more details */ - inline - ptime - operator-(const ptime& t, const boost::gregorian::months& m) - { - // get_neg_offset returns a negative duration, so we add - return t + m.get_neg_offset(t.date()); - } - - /*! Subtracts a months object from a ptime. Result will be same - * day-of-month as ptime unless original day was the last day of month. - * see date_time::months_duration for more details */ - inline - ptime - operator-=(ptime& t, const boost::gregorian::months& m) - { - return t += m.get_neg_offset(t.date()); - } - - // ptime & years - - /*! Adds a years object and a ptime. Result will be same - * month and day-of-month as ptime unless original day was the - * last day of month. see date_time::years_duration for more details */ - inline - ptime - operator+(const ptime& t, const boost::gregorian::years& y) - { - return t + y.get_offset(t.date()); - } - - /*! Adds a years object to a ptime. Result will be same - * month and day-of-month as ptime unless original day was the - * last day of month. see date_time::years_duration for more details */ - inline - ptime - operator+=(ptime& t, const boost::gregorian::years& y) - { - return t += y.get_offset(t.date()); - } - - /*! Subtracts a years object and a ptime. Result will be same - * month and day-of-month as ptime unless original day was the - * last day of month. see date_time::years_duration for more details */ - inline - ptime - operator-(const ptime& t, const boost::gregorian::years& y) - { - // get_neg_offset returns a negative duration, so we add - return t + y.get_neg_offset(t.date()); - } - - /*! Subtracts a years object from a ptime. Result will be same - * month and day-of-month as ptime unless original day was the - * last day of month. see date_time::years_duration for more details */ - inline - ptime - operator-=(ptime& t, const boost::gregorian::years& y) - { - // get_neg_offset returns a negative duration, so we add - return t += y.get_neg_offset(t.date()); - } - -}} // namespaces - -#endif // DATE_DURATION_OPERATORS_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_config.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_config.hpp deleted file mode 100644 index d0b76536..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_config.hpp +++ /dev/null @@ -1,178 +0,0 @@ -#ifndef POSIX_TIME_CONFIG_HPP___ -#define POSIX_TIME_CONFIG_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-10-10 12:05:03 -0700 (Wed, 10 Oct 2012) $ - */ - -#include //for MCW 7.2 std::abs(long long) -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace posix_time { - -//Remove the following line if you want 64 bit millisecond resolution time -//#define BOOST_GDTL_POSIX_TIME_STD_CONFIG - -#ifdef BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG - // set up conditional test compilations -#define BOOST_DATE_TIME_HAS_MILLISECONDS -#define BOOST_DATE_TIME_HAS_MICROSECONDS -#define BOOST_DATE_TIME_HAS_NANOSECONDS - typedef date_time::time_resolution_traits time_res_traits; -#else - // set up conditional test compilations -#define BOOST_DATE_TIME_HAS_MILLISECONDS -#define BOOST_DATE_TIME_HAS_MICROSECONDS -#undef BOOST_DATE_TIME_HAS_NANOSECONDS - typedef date_time::time_resolution_traits< - boost::date_time::time_resolution_traits_adapted64_impl, boost::date_time::micro, - 1000000, 6 > time_res_traits; - - -// #undef BOOST_DATE_TIME_HAS_MILLISECONDS -// #undef BOOST_DATE_TIME_HAS_MICROSECONDS -// #undef BOOST_DATE_TIME_HAS_NANOSECONDS -// typedef date_time::time_resolution_traits time_res_traits; - -#endif - - - //! Base time duration type - /*! \ingroup time_basics - */ - class time_duration : - public date_time::time_duration - { - public: - typedef time_res_traits rep_type; - typedef time_res_traits::day_type day_type; - typedef time_res_traits::hour_type hour_type; - typedef time_res_traits::min_type min_type; - typedef time_res_traits::sec_type sec_type; - typedef time_res_traits::fractional_seconds_type fractional_seconds_type; - typedef time_res_traits::tick_type tick_type; - typedef time_res_traits::impl_type impl_type; - time_duration(hour_type hour, - min_type min, - sec_type sec, - fractional_seconds_type fs=0) : - date_time::time_duration(hour,min,sec,fs) - {} - time_duration() : - date_time::time_duration(0,0,0) - {} - //! Construct from special_values - time_duration(boost::date_time::special_values sv) : - date_time::time_duration(sv) - {} - //Give duration access to ticks constructor -- hide from users - friend class date_time::time_duration; - protected: - explicit time_duration(impl_type tick_count) : - date_time::time_duration(tick_count) - {} - }; - -#ifdef BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG - - //! Simple implementation for the time rep - struct simple_time_rep - { - typedef gregorian::date date_type; - typedef time_duration time_duration_type; - simple_time_rep(date_type d, time_duration_type tod) : - day(d), - time_of_day(tod) - { - // make sure we have sane values for date & time - if(!day.is_special() && !time_of_day.is_special()){ - if(time_of_day >= time_duration_type(24,0,0)) { - while(time_of_day >= time_duration_type(24,0,0)) { - day += date_type::duration_type(1); - time_of_day -= time_duration_type(24,0,0); - } - } - else if(time_of_day.is_negative()) { - while(time_of_day.is_negative()) { - day -= date_type::duration_type(1); - time_of_day += time_duration_type(24,0,0); - } - } - } - } - date_type day; - time_duration_type time_of_day; - bool is_special()const - { - return(is_pos_infinity() || is_neg_infinity() || is_not_a_date_time()); - } - bool is_pos_infinity()const - { - return(day.is_pos_infinity() || time_of_day.is_pos_infinity()); - } - bool is_neg_infinity()const - { - return(day.is_neg_infinity() || time_of_day.is_neg_infinity()); - } - bool is_not_a_date_time()const - { - return(day.is_not_a_date() || time_of_day.is_not_a_date_time()); - } - }; - - class posix_time_system_config - { - public: - typedef simple_time_rep time_rep_type; - typedef gregorian::date date_type; - typedef gregorian::date_duration date_duration_type; - typedef time_duration time_duration_type; - typedef time_res_traits::tick_type int_type; - typedef time_res_traits resolution_traits; -#if (defined(BOOST_DATE_TIME_NO_MEMBER_INIT)) //help bad compilers -#else - BOOST_STATIC_CONSTANT(boost::int64_t, tick_per_second = 1000000000); -#endif - }; - -#else - - class millisec_posix_time_system_config - { - public: - typedef boost::int64_t time_rep_type; - //typedef time_res_traits::tick_type time_rep_type; - typedef gregorian::date date_type; - typedef gregorian::date_duration date_duration_type; - typedef time_duration time_duration_type; - typedef time_res_traits::tick_type int_type; - typedef time_res_traits::impl_type impl_type; - typedef time_res_traits resolution_traits; -#if (defined(BOOST_DATE_TIME_NO_MEMBER_INIT)) //help bad compilers -#else - BOOST_STATIC_CONSTANT(boost::int64_t, tick_per_second = 1000000); -#endif - }; - -#endif - -} }//namespace posix_time - - -#endif - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_duration.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_duration.hpp deleted file mode 100644 index 9778fd7f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_duration.hpp +++ /dev/null @@ -1,82 +0,0 @@ -#ifndef POSIX_TIME_DURATION_HPP___ -#define POSIX_TIME_DURATION_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/posix_time/posix_time_config.hpp" - -namespace boost { -namespace posix_time { - - //! Allows expression of durations as an hour count - /*! \ingroup time_basics - */ - class hours : public time_duration - { - public: - explicit hours(long h) : - time_duration(h,0,0) - {} - }; - - //! Allows expression of durations as a minute count - /*! \ingroup time_basics - */ - class minutes : public time_duration - { - public: - explicit minutes(long m) : - time_duration(0,m,0) - {} - }; - - //! Allows expression of durations as a seconds count - /*! \ingroup time_basics - */ - class seconds : public time_duration - { - public: - explicit seconds(long s) : - time_duration(0,0,s) - {} - }; - - - //! Allows expression of durations as milli seconds - /*! \ingroup time_basics - */ - typedef date_time::subsecond_duration millisec; - typedef date_time::subsecond_duration milliseconds; - - //! Allows expression of durations as micro seconds - /*! \ingroup time_basics - */ - typedef date_time::subsecond_duration microsec; - typedef date_time::subsecond_duration microseconds; - - //This is probably not needed anymore... -#if defined(BOOST_DATE_TIME_HAS_NANOSECONDS) - - //! Allows expression of durations as nano seconds - /*! \ingroup time_basics - */ - typedef date_time::subsecond_duration nanosec; - typedef date_time::subsecond_duration nanoseconds; - - -#endif - - - - -} }//namespace posix_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_system.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_system.hpp deleted file mode 100644 index 13626e9b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_system.hpp +++ /dev/null @@ -1,68 +0,0 @@ -#ifndef POSIX_TIME_SYSTEM_HPP___ -#define POSIX_TIME_SYSTEM_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - - -#include "boost/date_time/posix_time/posix_time_config.hpp" -#include "boost/date_time/time_system_split.hpp" -#include "boost/date_time/time_system_counted.hpp" -#include "boost/date_time/compiler_config.hpp" - - -namespace boost { -namespace posix_time { - -#ifdef BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG - -#if (defined(BOOST_DATE_TIME_NO_MEMBER_INIT)) //help bad compilers - typedef date_time::split_timedate_system posix_time_system; -#else - typedef date_time::split_timedate_system posix_time_system; -#endif - -#else - - typedef date_time::counted_time_rep int64_time_rep; - typedef date_time::counted_time_system posix_time_system; - -#endif - -} }//namespace posix_time - - -#endif - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_types.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_types.hpp deleted file mode 100644 index f2488f8b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/posix_time_types.hpp +++ /dev/null @@ -1,55 +0,0 @@ -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - */ -#ifndef POSIX_TIME_TYPES_HPP___ -#define POSIX_TIME_TYPES_HPP___ - -#include "boost/date_time/time_clock.hpp" -#include "boost/date_time/microsec_time_clock.hpp" -#include "boost/date_time/posix_time/ptime.hpp" -#if defined(BOOST_DATE_TIME_OPTIONAL_GREGORIAN_TYPES) -#include "boost/date_time/posix_time/date_duration_operators.hpp" -#endif -#include "boost/date_time/posix_time/posix_time_duration.hpp" -#include "boost/date_time/posix_time/posix_time_system.hpp" -#include "boost/date_time/posix_time/time_period.hpp" -#include "boost/date_time/time_iterator.hpp" -#include "boost/date_time/dst_rules.hpp" - -namespace boost { - -//!Defines a non-adjusted time system with nano-second resolution and stable calculation properties -namespace posix_time { - - //! Iterator over a defined time duration - /*! \ingroup time_basics - */ - typedef date_time::time_itr time_iterator; - //! A time clock that has a resolution of one second - /*! \ingroup time_basics - */ - typedef date_time::second_clock second_clock; - -#ifdef BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK - //! A time clock that has a resolution of one microsecond - /*! \ingroup time_basics - */ - typedef date_time::microsec_clock microsec_clock; -#endif - - //! Define a dst null dst rule for the posix_time system - typedef date_time::null_dst_rules no_dst; - //! Define US dst rule calculator for the posix_time system - typedef date_time::us_dst_rules us_dst; - - -} } //namespace posix_time - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/ptime.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/ptime.hpp deleted file mode 100644 index 3f1cb047..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/ptime.hpp +++ /dev/null @@ -1,65 +0,0 @@ -#ifndef POSIX_PTIME_HPP___ -#define POSIX_PTIME_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/posix_time/posix_time_system.hpp" -#include "boost/date_time/time.hpp" - -namespace boost { - -namespace posix_time { - - //bring special enum values into the namespace - using date_time::special_values; - using date_time::not_special; - using date_time::neg_infin; - using date_time::pos_infin; - using date_time::not_a_date_time; - using date_time::max_date_time; - using date_time::min_date_time; - - //! Time type with no timezone or other adjustments - /*! \ingroup time_basics - */ - class ptime : public date_time::base_time - { - public: - typedef posix_time_system time_system_type; - typedef time_system_type::time_rep_type time_rep_type; - typedef time_system_type::time_duration_type time_duration_type; - typedef ptime time_type; - //! Construct with date and offset in day - ptime(gregorian::date d,time_duration_type td) : date_time::base_time(d,td) - {} - //! Construct a time at start of the given day (midnight) - explicit ptime(gregorian::date d) : date_time::base_time(d,time_duration_type(0,0,0)) - {} - //! Copy from time_rep - ptime(const time_rep_type& rhs): - date_time::base_time(rhs) - {} - //! Construct from special value - ptime(const special_values sv) : date_time::base_time(sv) - {} -#if !defined(DATE_TIME_NO_DEFAULT_CONSTRUCTOR) - // Default constructor constructs to not_a_date_time - ptime() : date_time::base_time(gregorian::date(not_a_date_time), time_duration_type(not_a_date_time)) - {} -#endif // DATE_TIME_NO_DEFAULT_CONSTRUCTOR - - }; - - - -} }//namespace posix_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_formatters.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_formatters.hpp deleted file mode 100644 index 534b9525..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_formatters.hpp +++ /dev/null @@ -1,289 +0,0 @@ -#ifndef POSIXTIME_FORMATTERS_HPP___ -#define POSIXTIME_FORMATTERS_HPP___ - -/* Copyright (c) 2002-2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2010-01-10 11:17:23 -0800 (Sun, 10 Jan 2010) $ - */ - -#include -#include -#include -#include -#include -#include -#include // absolute_value -#include - -/* NOTE: The "to_*_string" code for older compilers, ones that define - * BOOST_DATE_TIME_INCLUDE_LIMITED_HEADERS, is located in - * formatters_limited.hpp - */ - -namespace boost { - -namespace posix_time { - - // template function called by wrapper functions: - // to_*_string(time_duration) & to_*_wstring(time_duration) - template - inline std::basic_string to_simple_string_type(time_duration td) { - std::basic_ostringstream ss; - if(td.is_special()) { - /* simply using 'ss << td.get_rep()' won't work on compilers - * that don't support locales. This way does. */ - // switch copied from date_names_put.hpp - switch(td.get_rep().as_special()) - { - case not_a_date_time: - //ss << "not-a-number"; - ss << "not-a-date-time"; - break; - case pos_infin: - ss << "+infinity"; - break; - case neg_infin: - ss << "-infinity"; - break; - default: - ss << ""; - } - } - else { - charT fill_char = '0'; - if(td.is_negative()) { - ss << '-'; - } - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.hours()) << ":"; - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.minutes()) << ":"; - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.seconds()); - //TODO the following is totally non-generic, yelling FIXME -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - boost::int64_t frac_sec = - date_time::absolute_value(td.fractional_seconds()); - // JDG [7/6/02 VC++ compatibility] - charT buff[32]; - _i64toa(frac_sec, buff, 10); -#else - time_duration::fractional_seconds_type frac_sec = - date_time::absolute_value(td.fractional_seconds()); -#endif - if (frac_sec != 0) { - ss << "." << std::setw(time_duration::num_fractional_digits()) - << std::setfill(fill_char) - - // JDG [7/6/02 VC++ compatibility] -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - << buff; -#else - << frac_sec; -#endif - } - }// else - return ss.str(); - } - //! Time duration to string -hh::mm::ss.fffffff. Example: 10:09:03.0123456 - /*!\ingroup time_format - */ - inline std::string to_simple_string(time_duration td) { - return to_simple_string_type(td); - } - - - // template function called by wrapper functions: - // to_*_string(time_duration) & to_*_wstring(time_duration) - template - inline std::basic_string to_iso_string_type(time_duration td) - { - std::basic_ostringstream ss; - if(td.is_special()) { - /* simply using 'ss << td.get_rep()' won't work on compilers - * that don't support locales. This way does. */ - // switch copied from date_names_put.hpp - switch(td.get_rep().as_special()) { - case not_a_date_time: - //ss << "not-a-number"; - ss << "not-a-date-time"; - break; - case pos_infin: - ss << "+infinity"; - break; - case neg_infin: - ss << "-infinity"; - break; - default: - ss << ""; - } - } - else { - charT fill_char = '0'; - if(td.is_negative()) { - ss << '-'; - } - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.hours()); - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.minutes()); - ss << std::setw(2) << std::setfill(fill_char) - << date_time::absolute_value(td.seconds()); - //TODO the following is totally non-generic, yelling FIXME -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - boost::int64_t frac_sec = - date_time::absolute_value(td.fractional_seconds()); - // JDG [7/6/02 VC++ compatibility] - charT buff[32]; - _i64toa(frac_sec, buff, 10); -#else - time_duration::fractional_seconds_type frac_sec = - date_time::absolute_value(td.fractional_seconds()); -#endif - if (frac_sec != 0) { - ss << "." << std::setw(time_duration::num_fractional_digits()) - << std::setfill(fill_char) - - // JDG [7/6/02 VC++ compatibility] -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - << buff; -#else - << frac_sec; -#endif - } - }// else - return ss.str(); - } - //! Time duration in iso format -hhmmss,fffffff Example: 10:09:03,0123456 - /*!\ingroup time_format - */ - inline std::string to_iso_string(time_duration td){ - return to_iso_string_type(td); - } - - //! Time to simple format CCYY-mmm-dd hh:mm:ss.fffffff - /*!\ingroup time_format - */ - template - inline std::basic_string to_simple_string_type(ptime t) - { - // can't use this w/gcc295, no to_simple_string_type<>(td) available - std::basic_string ts = gregorian::to_simple_string_type(t.date());// + " "; - if(!t.time_of_day().is_special()) { - charT space = ' '; - return ts + space + to_simple_string_type(t.time_of_day()); - } - else { - return ts; - } - } - inline std::string to_simple_string(ptime t){ - return to_simple_string_type(t); - } - - // function called by wrapper functions to_*_string(time_period) - // & to_*_wstring(time_period) - template - inline std::basic_string to_simple_string_type(time_period tp) - { - charT beg = '[', mid = '/', end = ']'; - std::basic_string d1(to_simple_string_type(tp.begin())); - std::basic_string d2(to_simple_string_type(tp.last())); - return std::basic_string(beg + d1 + mid + d2 + end); - } - //! Convert to string of form [YYYY-mmm-DD HH:MM::SS.ffffff/YYYY-mmm-DD HH:MM::SS.fffffff] - /*!\ingroup time_format - */ - inline std::string to_simple_string(time_period tp){ - return to_simple_string_type(tp); - } - - // function called by wrapper functions to_*_string(time_period) - // & to_*_wstring(time_period) - template - inline std::basic_string to_iso_string_type(ptime t) - { - std::basic_string ts = gregorian::to_iso_string_type(t.date());// + "T"; - if(!t.time_of_day().is_special()) { - charT sep = 'T'; - return ts + sep + to_iso_string_type(t.time_of_day()); - } - else { - return ts; - } - } - //! Convert iso short form YYYYMMDDTHHMMSS where T is the date-time separator - /*!\ingroup time_format - */ - inline std::string to_iso_string(ptime t){ - return to_iso_string_type(t); - } - - - // function called by wrapper functions to_*_string(time_period) - // & to_*_wstring(time_period) - template - inline std::basic_string to_iso_extended_string_type(ptime t) - { - std::basic_string ts = gregorian::to_iso_extended_string_type(t.date());// + "T"; - if(!t.time_of_day().is_special()) { - charT sep = 'T'; - return ts + sep + to_simple_string_type(t.time_of_day()); - } - else { - return ts; - } - } - //! Convert to form YYYY-MM-DDTHH:MM:SS where T is the date-time separator - /*!\ingroup time_format - */ - inline std::string to_iso_extended_string(ptime t){ - return to_iso_extended_string_type(t); - } - -#if !defined(BOOST_NO_STD_WSTRING) - //! Time duration to wstring -hh::mm::ss.fffffff. Example: 10:09:03.0123456 - /*!\ingroup time_format - */ - inline std::wstring to_simple_wstring(time_duration td) { - return to_simple_string_type(td); - } - //! Time duration in iso format -hhmmss,fffffff Example: 10:09:03,0123456 - /*!\ingroup time_format - */ - inline std::wstring to_iso_wstring(time_duration td){ - return to_iso_string_type(td); - } - inline std::wstring to_simple_wstring(ptime t){ - return to_simple_string_type(t); - } - //! Convert to wstring of form [YYYY-mmm-DD HH:MM::SS.ffffff/YYYY-mmm-DD HH:MM::SS.fffffff] - /*!\ingroup time_format - */ - inline std::wstring to_simple_wstring(time_period tp){ - return to_simple_string_type(tp); - } - //! Convert iso short form YYYYMMDDTHHMMSS where T is the date-time separator - /*!\ingroup time_format - */ - inline std::wstring to_iso_wstring(ptime t){ - return to_iso_string_type(t); - } - //! Convert to form YYYY-MM-DDTHH:MM:SS where T is the date-time separator - /*!\ingroup time_format - */ - inline std::wstring to_iso_extended_wstring(ptime t){ - return to_iso_extended_string_type(t); - } - -#endif // BOOST_NO_STD_WSTRING - - -} } //namespace posix_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_period.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_period.hpp deleted file mode 100644 index 11f81207..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/posix_time/time_period.hpp +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef POSIX_TIME_PERIOD_HPP___ -#define POSIX_TIME_PERIOD_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/period.hpp" -#include "boost/date_time/posix_time/posix_time_duration.hpp" -#include "boost/date_time/posix_time/ptime.hpp" - -namespace boost { -namespace posix_time { - - //! Time period type - /*! \ingroup time_basics - */ - typedef date_time::period time_period; - - -} }//namespace posix_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_defs.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/special_defs.hpp deleted file mode 100644 index 661814ec..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_defs.hpp +++ /dev/null @@ -1,25 +0,0 @@ -#ifndef DATE_TIME_SPECIAL_DEFS_HPP__ -#define DATE_TIME_SPECIAL_DEFS_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -namespace boost { -namespace date_time { - - enum special_values {not_a_date_time, - neg_infin, pos_infin, - min_date_time, max_date_time, - not_special, NumSpecialValues}; - - -} } //namespace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_formatter.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_formatter.hpp deleted file mode 100644 index 53fe9845..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_formatter.hpp +++ /dev/null @@ -1,96 +0,0 @@ - -#ifndef DATETIME_SPECIAL_VALUE_FORMATTER_HPP___ -#define DATETIME_SPECIAL_VALUE_FORMATTER_HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include -#include -#include "boost/date_time/special_defs.hpp" - -namespace boost { namespace date_time { - - - //! Class that provides generic formmatting ostream formatting for special values - /*! This class provides for the formmating of special values to an output stream. - * In particular, it produces strings for the values of negative and positive - * infinity as well as not_a_date_time. - * - * While not a facet, this class is used by the date and time facets for formatting - * special value types. - * - */ - template > > - class special_values_formatter - { - public: - typedef std::basic_string string_type; - typedef CharT char_type; - typedef std::vector collection_type; - static const char_type default_special_value_names[3][17]; - - //! Construct special values formatter using default strings. - /*! Default strings are not-a-date-time -infinity +infinity - */ - special_values_formatter() - { - std::copy(&default_special_value_names[0], - &default_special_value_names[3], - std::back_inserter(m_special_value_names)); - } - - //! Construct special values formatter from array of strings - /*! This constructor will take pair of iterators from an array of strings - * that represent the special values and copy them for use in formatting - * special values. - *@code - * const char* const special_value_names[]={"nadt","-inf","+inf" }; - * - * special_value_formatter svf(&special_value_names[0], &special_value_names[3]); - *@endcode - */ - special_values_formatter(const char_type* const* begin, const char_type* const* end) - { - std::copy(begin, end, std::back_inserter(m_special_value_names)); - } - special_values_formatter(typename collection_type::iterator beg, typename collection_type::iterator end) - { - std::copy(beg, end, std::back_inserter(m_special_value_names)); - } - - OutItrT put_special(OutItrT next, - const boost::date_time::special_values& value) const - { - - unsigned int index = value; - if (index < m_special_value_names.size()) { - std::copy(m_special_value_names[index].begin(), - m_special_value_names[index].end(), - next); - } - return next; - } - protected: - collection_type m_special_value_names; - }; - - //! Storage for the strings used to indicate special values - /* using c_strings to initialize these worked fine in testing, however, - * a project that compiled its objects separately, then linked in a separate - * step wound up with redefinition errors for the values in this array. - * Initializing individual characters eliminated this problem */ - template - const typename special_values_formatter::char_type special_values_formatter::default_special_value_names[3][17] = { - {'n','o','t','-','a','-','d','a','t','e','-','t','i','m','e'}, - {'-','i','n','f','i','n','i','t','y'}, - {'+','i','n','f','i','n','i','t','y'} }; - - } } //namespace boost::date_time - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_parser.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_parser.hpp deleted file mode 100644 index e48ec5fd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/special_values_parser.hpp +++ /dev/null @@ -1,159 +0,0 @@ - -#ifndef DATE_TIME_SPECIAL_VALUES_PARSER_HPP__ -#define DATE_TIME_SPECIAL_VALUES_PARSER_HPP__ - -/* Copyright (c) 2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: - */ - - -#include "boost/date_time/string_parse_tree.hpp" -#include "boost/date_time/special_defs.hpp" -#include -#include - -namespace boost { namespace date_time { - - //! Class for special_value parsing - /*! - * TODO: add doc-comments for which elements can be changed - * Parses input stream for strings representing special_values. - * Special values parsed are: - * - not_a_date_time - * - neg_infin - * - pod_infin - * - min_date_time - * - max_date_time - */ - template - class special_values_parser - { - public: - typedef std::basic_string string_type; - //typedef std::basic_stringstream stringstream_type; - typedef std::istreambuf_iterator stream_itr_type; - //typedef typename string_type::const_iterator const_itr; - //typedef typename date_type::year_type year_type; - //typedef typename date_type::month_type month_type; - typedef typename date_type::duration_type duration_type; - //typedef typename date_type::day_of_week_type day_of_week_type; - //typedef typename date_type::day_type day_type; - typedef string_parse_tree parse_tree_type; - typedef typename parse_tree_type::parse_match_result_type match_results; - typedef std::vector > collection_type; - - typedef charT char_type; - static const char_type nadt_string[16]; - static const char_type neg_inf_string[10]; - static const char_type pos_inf_string[10]; - static const char_type min_date_time_string[18]; - static const char_type max_date_time_string[18]; - - //! Creates a special_values_parser with the default set of "sv_strings" - special_values_parser() - { - sv_strings(string_type(nadt_string), - string_type(neg_inf_string), - string_type(pos_inf_string), - string_type(min_date_time_string), - string_type(max_date_time_string)); - } - - //! Creates a special_values_parser using a user defined set of element strings - special_values_parser(const string_type& nadt_str, - const string_type& neg_inf_str, - const string_type& pos_inf_str, - const string_type& min_dt_str, - const string_type& max_dt_str) - { - sv_strings(nadt_str, neg_inf_str, pos_inf_str, min_dt_str, max_dt_str); - } - - special_values_parser(typename collection_type::iterator beg, typename collection_type::iterator end) - { - collection_type phrases; - std::copy(beg, end, std::back_inserter(phrases)); - m_sv_strings = parse_tree_type(phrases, static_cast(not_a_date_time)); - } - - special_values_parser(const special_values_parser& svp) - { - this->m_sv_strings = svp.m_sv_strings; - } - - //! Replace special value strings - void sv_strings(const string_type& nadt_str, - const string_type& neg_inf_str, - const string_type& pos_inf_str, - const string_type& min_dt_str, - const string_type& max_dt_str) - { - collection_type phrases; - phrases.push_back(nadt_str); - phrases.push_back(neg_inf_str); - phrases.push_back(pos_inf_str); - phrases.push_back(min_dt_str); - phrases.push_back(max_dt_str); - m_sv_strings = parse_tree_type(phrases, static_cast(not_a_date_time)); - } - - /* Does not return a special_value because if the parsing fails, - * the return value will always be not_a_date_time - * (mr.current_match retains its default value of -1 on a failed - * parse and that casts to not_a_date_time). */ - //! Sets match_results.current_match to the corresponding special_value or -1 - bool match(stream_itr_type& sitr, - stream_itr_type& str_end, - match_results& mr) const - { - unsigned int level = 0; - m_sv_strings.match(sitr, str_end, mr, level); - return (mr.current_match != match_results::PARSE_ERROR); - } - /*special_values match(stream_itr_type& sitr, - stream_itr_type& str_end, - match_results& mr) const - { - unsigned int level = 0; - m_sv_strings.match(sitr, str_end, mr, level); - if(mr.current_match == match_results::PARSE_ERROR) { - throw std::ios_base::failure("Parse failed. No match found for '" + mr.cache + "'"); - } - return static_cast(mr.current_match); - }*/ - - - private: - parse_tree_type m_sv_strings; - - }; - - template - const typename special_values_parser::char_type - special_values_parser::nadt_string[16] = - {'n','o','t','-','a','-','d','a','t','e','-','t','i','m','e'}; - template - const typename special_values_parser::char_type - special_values_parser::neg_inf_string[10] = - {'-','i','n','f','i','n','i','t','y'}; - template - const typename special_values_parser::char_type - special_values_parser::pos_inf_string[10] = - {'+','i','n','f','i','n','i','t','y'}; - template - const typename special_values_parser::char_type - special_values_parser::min_date_time_string[18] = - {'m','i','n','i','m','u','m','-','d','a','t','e','-','t','i','m','e'}; - template - const typename special_values_parser::char_type - special_values_parser::max_date_time_string[18] = - {'m','a','x','i','m','u','m','-','d','a','t','e','-','t','i','m','e'}; - -} } //namespace - -#endif // DATE_TIME_SPECIAL_VALUES_PARSER_HPP__ - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/string_convert.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/string_convert.hpp deleted file mode 100644 index a3cc86c2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/string_convert.hpp +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef _STRING_CONVERT_HPP___ -#define _STRING_CONVERT_HPP___ - -/* Copyright (c) 2005 CrystalClear Software, Inc. - * Subject to the Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -#include "boost/date_time/compiler_config.hpp" -#include - -namespace boost { -namespace date_time { - - //! Converts a string from one value_type to another - /*! Converts a wstring to a string (or a string to wstring). If both template parameters - * are of same type, a copy of the input string is returned. */ - template - inline - std::basic_string convert_string_type(const std::basic_string& inp_str) - { - typedef std::basic_string input_type; - typedef std::basic_string output_type; - output_type result; - result.insert(result.begin(), inp_str.begin(), inp_str.end()); - return result; - } - -}} // namespace boost::date_time - -#endif // _STRING_CONVERT_HPP___ diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/string_parse_tree.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/string_parse_tree.hpp deleted file mode 100644 index d67bf6b7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/string_parse_tree.hpp +++ /dev/null @@ -1,278 +0,0 @@ -#ifndef BOOST_DATE_TIME_STRING_PARSE_TREE___HPP__ -#define BOOST_DATE_TIME_STRING_PARSE_TREE___HPP__ - -/* Copyright (c) 2004-2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - - -#include "boost/lexical_cast.hpp" //error without? -#include "boost/algorithm/string/case_conv.hpp" -#include -#include -#include -#include - -namespace boost { namespace date_time { - - -template -struct parse_match_result -{ - parse_match_result() : - match_depth(0), - current_match(-1)// -1 is match_not-found value - {} - typedef std::basic_string string_type; - string_type remaining() const - { - if (match_depth == cache.size()) { - return string_type(); - } - if (current_match == -1) { - return cache; - } - //some of the cache was used return the rest - return string_type(cache, match_depth); - } - charT last_char() const - { - return cache[cache.size()-1]; - } - //! Returns true if more characters were parsed than was necessary - /*! Should be used in conjunction with last_char() - * to get the remaining character. - */ - bool has_remaining() const - { - return (cache.size() > match_depth); - } - - // cache will hold characters that have been read from the stream - string_type cache; - unsigned short match_depth; - short current_match; - enum PARSE_STATE { PARSE_ERROR= -1 }; -}; - - //for debug -- really only char streams... -template -std::basic_ostream& -operator<<(std::basic_ostream& os, parse_match_result& mr) -{ - os << "cm: " << mr.current_match - << " C: '" << mr.cache - << "' md: " << mr.match_depth - << " R: " << mr.remaining(); - return os; -} - - - -//! Recursive data structure to allow efficient parsing of various strings -/*! This class provides a quick lookup by building what amounts to a - * tree data structure. It also features a match function which can - * can handle nasty input interators by caching values as it recurses - * the tree so that it can backtrack as needed. - */ -template -struct string_parse_tree -{ -#if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0x581) ) - typedef std::multimap > ptree_coll; -#else - typedef std::multimap ptree_coll; -#endif - typedef typename ptree_coll::value_type value_type; - typedef typename ptree_coll::iterator iterator; - typedef typename ptree_coll::const_iterator const_iterator; - typedef std::basic_string string_type; - typedef std::vector > collection_type; - typedef parse_match_result parse_match_result_type; - - /*! Parameter "starting_point" designates where the numbering begins. - * A starting_point of zero will start the numbering at zero - * (Sun=0, Mon=1, ...) were a starting_point of one starts the - * numbering at one (Jan=1, Feb=2, ...). The default is zero, - * negative vaules are not allowed */ - string_parse_tree(collection_type names, unsigned int starting_point=0) - { - // iterate thru all the elements and build the tree - unsigned short index = 0; - while (index != names.size() ) { - string_type s = boost::algorithm::to_lower_copy(names[index]); - insert(s, static_cast(index + starting_point)); - index++; - } - //set the last tree node = index+1 indicating a value - index++; - } - - - string_parse_tree(short value = -1) : - m_value(value) - {} - ptree_coll m_next_chars; - short m_value; - - void insert(const string_type& s, unsigned short value) - { - unsigned int i = 0; - iterator ti; - while(i < s.size()) { - if (i==0) { - if (i == (s.size()-1)) { - ti = m_next_chars.insert(value_type(s[i], - string_parse_tree(value))); - } - else { - ti = m_next_chars.insert(value_type(s[i], - string_parse_tree())); - } - } - else { - if (i == (s.size()-1)) { - ti = ti->second.m_next_chars.insert(value_type(s[i], - string_parse_tree(value))); - } - - else { - ti = ti->second.m_next_chars.insert(value_type(s[i], - string_parse_tree())); - } - - } - i++; - } - } - - - //! Recursive function that finds a matching string in the tree. - /*! Must check match_results::has_remaining() after match() is - * called. This is required so the user can determine if - * stream iterator is already pointing to the expected - * character or not (match() might advance sitr to next char in stream). - * - * A parse_match_result that has been returned from a failed match - * attempt can be sent in to the match function of a different - * string_parse_tree to attempt a match there. Use the iterators - * for the partially consumed stream, the parse_match_result object, - * and '0' for the level parameter. */ - short - match(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end, - parse_match_result_type& result, - unsigned int& level) const - { - - level++; - charT c; - // if we conditionally advance sitr, we won't have - // to consume the next character past the input - bool adv_itr = true; - if (level > result.cache.size()) { - if (sitr == stream_end) return 0; //bail - input exhausted - c = static_cast(std::tolower(*sitr)); - //result.cache += c; - //sitr++; - } - else { - // if we're looking for characters from the cache, - // we don't want to increment sitr - adv_itr = false; - c = static_cast(std::tolower(result.cache[level-1])); - } - const_iterator litr = m_next_chars.lower_bound(c); - const_iterator uitr = m_next_chars.upper_bound(c); - while (litr != uitr) { // equal if not found - if(adv_itr) { - sitr++; - result.cache += c; - } - if (litr->second.m_value != -1) { // -1 is default value - if (result.match_depth < level) { - result.current_match = litr->second.m_value; - result.match_depth = static_cast(level); - } - litr->second.match(sitr, stream_end, - result, level); - level--; - } - else { - litr->second.match(sitr, stream_end, - result, level); - level--; - } - - if(level <= result.cache.size()) { - adv_itr = false; - } - - litr++; - } - return result.current_match; - - } - - /*! Must check match_results::has_remaining() after match() is - * called. This is required so the user can determine if - * stream iterator is already pointing to the expected - * character or not (match() might advance sitr to next char in stream). - */ - parse_match_result_type - match(std::istreambuf_iterator& sitr, - std::istreambuf_iterator& stream_end) const - { - // lookup to_lower of char in tree. - unsigned int level = 0; - // string_type cache; - parse_match_result_type result; - match(sitr, stream_end, result, level); - return result; - } - - void printme(std::ostream& os, int& level) - { - level++; - iterator itr = m_next_chars.begin(); - iterator end = m_next_chars.end(); - // os << "starting level: " << level << std::endl; - while (itr != end) { - os << "level: " << level - << " node: " << itr->first - << " value: " << itr->second.m_value - << std::endl; - itr->second.printme(os, level); - itr++; - } - level--; - } - - void print(std::ostream& os) - { - int level = 0; - printme(os, level); - } - - void printmatch(std::ostream& os, charT c) - { - iterator litr = m_next_chars.lower_bound(c); - iterator uitr = m_next_chars.upper_bound(c); - os << "matches for: " << c << std::endl; - while (litr != uitr) { - os << " node: " << litr->first - << " value: " << litr->second.m_value - << std::endl; - litr++; - } - } - -}; - - -} } //namespace -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/strings_from_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/strings_from_facet.hpp deleted file mode 100644 index ccc78ef0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/strings_from_facet.hpp +++ /dev/null @@ -1,127 +0,0 @@ -#ifndef DATE_TIME_STRINGS_FROM_FACET__HPP___ -#define DATE_TIME_STRINGS_FROM_FACET__HPP___ - -/* Copyright (c) 2004 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2013-09-21 13:17:00 -0700 (Sat, 21 Sep 2013) $ - */ - -#include -#include -#include -#include - -namespace boost { namespace date_time { - -//! This function gathers up all the month strings from a std::locale -/*! Using the time_put facet, this function creates a collection of - * all the month strings from a locale. This is handy when building - * custom date parsers or formatters that need to be localized. - * - *@param charT The type of char to use when gathering typically char - * or wchar_t. - *@param locale The locale to use when gathering the strings - *@param short_strings True(default) to gather short strings, - * false for long strings. - *@return A vector of strings containing the strings in order. eg: - * Jan, Feb, Mar, etc. - */ -template -std::vector > -gather_month_strings(const std::locale& locale, bool short_strings=true) -{ - typedef std::basic_string string_type; - typedef std::vector collection_type; - typedef std::basic_ostringstream ostream_type; - typedef std::ostreambuf_iterator ostream_iter_type; - typedef std::basic_ostringstream stringstream_type; - typedef std::time_put time_put_facet_type; - charT short_fmt[3] = { '%', 'b' }; - charT long_fmt[3] = { '%', 'B' }; - collection_type months; - string_type outfmt(short_fmt); - if (!short_strings) { - outfmt = long_fmt; - } - { - //grab the needed strings by using the locale to - //output each month - const charT* p_outfmt = outfmt.c_str(), *p_outfmt_end = p_outfmt + outfmt.size(); - tm tm_value; - memset(&tm_value, 0, sizeof(tm_value)); - for (int m=0; m < 12; m++) { - tm_value.tm_mon = m; - stringstream_type ss; - ostream_iter_type oitr(ss); - std::use_facet(locale).put(oitr, ss, ss.fill(), - &tm_value, - p_outfmt, - p_outfmt_end); - months.push_back(ss.str()); - } - } - return months; -} - -//! This function gathers up all the weekday strings from a std::locale -/*! Using the time_put facet, this function creates a collection of - * all the weekday strings from a locale starting with the string for - * 'Sunday'. This is handy when building custom date parsers or - * formatters that need to be localized. - * - *@param charT The type of char to use when gathering typically char - * or wchar_t. - *@param locale The locale to use when gathering the strings - *@param short_strings True(default) to gather short strings, - * false for long strings. - *@return A vector of strings containing the weekdays in order. eg: - * Sun, Mon, Tue, Wed, Thu, Fri, Sat - */ -template -std::vector > -gather_weekday_strings(const std::locale& locale, bool short_strings=true) -{ - typedef std::basic_string string_type; - typedef std::vector collection_type; - typedef std::basic_ostringstream ostream_type; - typedef std::ostreambuf_iterator ostream_iter_type; - typedef std::basic_ostringstream stringstream_type; - typedef std::time_put time_put_facet_type; - charT short_fmt[3] = { '%', 'a' }; - charT long_fmt[3] = { '%', 'A' }; - - collection_type weekdays; - - - string_type outfmt(short_fmt); - if (!short_strings) { - outfmt = long_fmt; - } - { - //grab the needed strings by using the locale to - //output each month / weekday - const charT* p_outfmt = outfmt.c_str(), *p_outfmt_end = p_outfmt + outfmt.size(); - tm tm_value; - memset(&tm_value, 0, sizeof(tm_value)); - for (int i=0; i < 7; i++) { - tm_value.tm_wday = i; - stringstream_type ss; - ostream_iter_type oitr(ss); - std::use_facet(locale).put(oitr, ss, ss.fill(), - &tm_value, - p_outfmt, - p_outfmt_end); - - weekdays.push_back(ss.str()); - } - } - return weekdays; -} - -} } //namespace - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time.hpp deleted file mode 100644 index 8b21144b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time.hpp +++ /dev/null @@ -1,191 +0,0 @@ -#ifndef DATE_TIME_TIME_HPP___ -#define DATE_TIME_TIME_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - - -/*! @file time.hpp - This file contains the interface for the time associated classes. -*/ -#include -#include -#include -#include - -namespace boost { -namespace date_time { - - //! Representation of a precise moment in time, including the date. - /*! - This class is a skeleton for the interface of a temporal type - with a resolution that is higher than a day. It is intended that - this class be the base class and that the actual time - class be derived using the BN pattern. In this way, the derived - class can make decisions such as 'should there be a default constructor' - and what should it set its value to, should there be optional constructors - say allowing only an time_durations that generate a time from a clock,etc. - So, in fact multiple time types can be created for a time_system with - different construction policies, and all of them can perform basic - operations by only writing a copy constructor. Finally, compiler - errors are also shorter. - - The real behavior of the time class is provided by the time_system - template parameter. This class must provide all the logic - for addition, subtraction, as well as define all the interface - types. - - */ - - template - class base_time : private - boost::less_than_comparable > - { - public: - typedef T time_type; - typedef typename time_system::time_rep_type time_rep_type; - typedef typename time_system::date_type date_type; - typedef typename time_system::date_duration_type date_duration_type; - typedef typename time_system::time_duration_type time_duration_type; - //typedef typename time_system::hms_type hms_type; - - base_time(const date_type& day, - const time_duration_type& td, - dst_flags dst=not_dst) : - time_(time_system::get_time_rep(day, td, dst)) - {} - base_time(special_values sv) : - time_(time_system::get_time_rep(sv)) - {} - base_time(const time_rep_type& rhs) : - time_(rhs) - {} - date_type date() const - { - return time_system::get_date(time_); - } - time_duration_type time_of_day() const - { - return time_system::get_time_of_day(time_); - } - /*! Optional bool parameter will return time zone as an offset - * (ie "+07:00"). Empty string is returned for classes that do - * not use a time_zone */ - std::string zone_name(bool /*as_offset*/=false) const - { - return time_system::zone_name(time_); - } - /*! Optional bool parameter will return time zone as an offset - * (ie "+07:00"). Empty string is returned for classes that do - * not use a time_zone */ - std::string zone_abbrev(bool /*as_offset*/=false) const - { - return time_system::zone_name(time_); - } - //! An empty string is returned for classes that do not use a time_zone - std::string zone_as_posix_string() const - { - return std::string(); - } - - //! check to see if date is not a value - bool is_not_a_date_time() const - { - return time_.is_not_a_date_time(); - } - //! check to see if date is one of the infinity values - bool is_infinity() const - { - return (is_pos_infinity() || is_neg_infinity()); - } - //! check to see if date is greater than all possible dates - bool is_pos_infinity() const - { - return time_.is_pos_infinity(); - } - //! check to see if date is greater than all possible dates - bool is_neg_infinity() const - { - return time_.is_neg_infinity(); - } - //! check to see if time is a special value - bool is_special() const - { - return(is_not_a_date_time() || is_infinity()); - } - //!Equality operator -- others generated by boost::equality_comparable - bool operator==(const time_type& rhs) const - { - return time_system::is_equal(time_,rhs.time_); - } - //!Equality operator -- others generated by boost::less_than_comparable - bool operator<(const time_type& rhs) const - { - return time_system::is_less(time_,rhs.time_); - } - //! difference between two times - time_duration_type operator-(const time_type& rhs) const - { - return time_system::subtract_times(time_, rhs.time_); - } - //! add date durations - time_type operator+(const date_duration_type& dd) const - { - return time_system::add_days(time_, dd); - } - time_type operator+=(const date_duration_type& dd) - { - time_ = (time_system::get_time_rep(date() + dd, time_of_day())); - return time_type(time_); - } - //! subtract date durations - time_type operator-(const date_duration_type& dd) const - { - return time_system::subtract_days(time_, dd); - } - time_type operator-=(const date_duration_type& dd) - { - time_ = (time_system::get_time_rep(date() - dd, time_of_day())); - return time_type(time_); - } - //! add time durations - time_type operator+(const time_duration_type& td) const - { - return time_type(time_system::add_time_duration(time_, td)); - } - time_type operator+=(const time_duration_type& td) - { - time_ = (time_system::get_time_rep(date(), time_of_day() + td)); - return time_type(time_); - } - //! subtract time durations - time_type operator-(const time_duration_type& rhs) const - { - return time_system::subtract_time_duration(time_, rhs); - } - time_type operator-=(const time_duration_type& td) - { - time_ = (time_system::get_time_rep(date(), time_of_day() - td)); - return time_type(time_); - } - - protected: - time_rep_type time_; - }; - - - - - -} } //namespace date_time::boost - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_clock.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_clock.hpp deleted file mode 100644 index 9aa2ff0e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_clock.hpp +++ /dev/null @@ -1,83 +0,0 @@ -#ifndef DATE_TIME_TIME_CLOCK_HPP___ -#define DATE_TIME_TIME_CLOCK_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -/*! @file time_clock.hpp - This file contains the interface for clock devices. -*/ - -#include "boost/date_time/c_time.hpp" -#include "boost/shared_ptr.hpp" - -namespace boost { -namespace date_time { - - - //! A clock providing time level services based on C time_t capabilities - /*! This clock provides resolution to the 1 second level - */ - template - class second_clock - { - public: - typedef typename time_type::date_type date_type; - typedef typename time_type::time_duration_type time_duration_type; - - static time_type local_time() - { - ::std::time_t t; - ::std::time(&t); - ::std::tm curr, *curr_ptr; - //curr_ptr = ::std::localtime(&t); - curr_ptr = c_time::localtime(&t, &curr); - return create_time(curr_ptr); - } - - - //! Get the current day in universal date as a ymd_type - static time_type universal_time() - { - - ::std::time_t t; - ::std::time(&t); - ::std::tm curr, *curr_ptr; - //curr_ptr = ::std::gmtime(&t); - curr_ptr = c_time::gmtime(&t, &curr); - return create_time(curr_ptr); - } - - template - static time_type local_time(boost::shared_ptr tz_ptr) - { - typedef typename time_type::utc_time_type utc_time_type; - utc_time_type utc_time = second_clock::universal_time(); - return time_type(utc_time, tz_ptr); - } - - - private: - static time_type create_time(::std::tm* current) - { - date_type d(static_cast(current->tm_year + 1900), - static_cast(current->tm_mon + 1), - static_cast(current->tm_mday)); - time_duration_type td(current->tm_hour, - current->tm_min, - current->tm_sec); - return time_type(d,td); - } - - }; - - -} } //namespace date_time - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_defs.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_defs.hpp deleted file mode 100644 index d74631d5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_defs.hpp +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef DATE_TIME_TIME_PRECISION_LIMITS_HPP -#define DATE_TIME_TIME_PRECISION_LIMITS_HPP - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - - - -/*! \file time_defs.hpp - This file contains nice definitions for handling the resoluion of various time - reprsentations. -*/ - -namespace boost { -namespace date_time { - - //!Defines some nice types for handling time level resolutions - enum time_resolutions { - sec, - tenth, - hundreth, // deprecated misspelled version of hundredth - hundredth = hundreth, - milli, - ten_thousandth, - micro, - nano, - NumResolutions - }; - - //! Flags for daylight savings or summer time - enum dst_flags {not_dst, is_dst, calculate}; - - -} } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_duration.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_duration.hpp deleted file mode 100644 index fc3660b7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_duration.hpp +++ /dev/null @@ -1,293 +0,0 @@ -#ifndef DATE_TIME_TIME_DURATION_HPP___ -#define DATE_TIME_TIME_DURATION_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-10-10 12:05:03 -0700 (Wed, 10 Oct 2012) $ - */ - -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace date_time { - - - //! Represents some amount of elapsed time measure to a given resolution - /*! This class represents a standard set of capabilities for all - counted time durations. Time duration implementations should derive - from this class passing their type as the first template parameter. - This design allows the subclass duration types to provide custom - construction policies or other custom features not provided here. - - @param T The subclass type - @param rep_type The time resolution traits for this duration type. - */ - template - class time_duration : private - boost::less_than_comparable > - /* dividable, addable, and subtractable operator templates - * won't work with this class (MSVC++ 6.0). return type - * from '+=' is different than expected return type - * from '+'. multipliable probably wont work - * either (haven't tried) */ - { - public: - typedef T duration_type; //the subclass - typedef rep_type traits_type; - typedef typename rep_type::day_type day_type; - typedef typename rep_type::hour_type hour_type; - typedef typename rep_type::min_type min_type; - typedef typename rep_type::sec_type sec_type; - typedef typename rep_type::fractional_seconds_type fractional_seconds_type; - typedef typename rep_type::tick_type tick_type; - typedef typename rep_type::impl_type impl_type; - - time_duration() : ticks_(0) {} - time_duration(hour_type hours_in, - min_type minutes_in, - sec_type seconds_in=0, - fractional_seconds_type frac_sec_in = 0) : - ticks_(rep_type::to_tick_count(hours_in,minutes_in,seconds_in,frac_sec_in)) - {} - // copy constructor required for dividable<> - //! Construct from another time_duration (Copy constructor) - time_duration(const time_duration& other) - : ticks_(other.ticks_) - {} - //! Construct from special_values - time_duration(special_values sv) : ticks_(impl_type::from_special(sv)) - {} - //! Returns smallest representable duration - static duration_type unit() - { - return duration_type(0,0,0,1); - } - //! Return the number of ticks in a second - static tick_type ticks_per_second() - { - return rep_type::res_adjust(); - } - //! Provide the resolution of this duration type - static time_resolutions resolution() - { - return rep_type::resolution(); - } - //! Returns number of hours in the duration - hour_type hours() const - { - return static_cast(ticks() / (3600*ticks_per_second())); - } - //! Returns normalized number of minutes - min_type minutes() const - { - return static_cast((ticks() / (60*ticks_per_second())) % 60); - } - //! Returns normalized number of seconds (0..60) - sec_type seconds() const - { - return static_cast((ticks()/ticks_per_second()) % 60); - } - //! Returns total number of seconds truncating any fractional seconds - sec_type total_seconds() const - { - return static_cast(ticks() / ticks_per_second()); - } - //! Returns total number of milliseconds truncating any fractional seconds - tick_type total_milliseconds() const - { - if (ticks_per_second() < 1000) { - return ticks() * (static_cast(1000) / ticks_per_second()); - } - return ticks() / (ticks_per_second() / static_cast(1000)) ; - } - //! Returns total number of nanoseconds truncating any sub millisecond values - tick_type total_nanoseconds() const - { - if (ticks_per_second() < 1000000000) { - return ticks() * (static_cast(1000000000) / ticks_per_second()); - } - return ticks() / (ticks_per_second() / static_cast(1000000000)) ; - } - //! Returns total number of microseconds truncating any sub microsecond values - tick_type total_microseconds() const - { - if (ticks_per_second() < 1000000) { - return ticks() * (static_cast(1000000) / ticks_per_second()); - } - return ticks() / (ticks_per_second() / static_cast(1000000)) ; - } - //! Returns count of fractional seconds at given resolution - fractional_seconds_type fractional_seconds() const - { - return (ticks() % ticks_per_second()); - } - //! Returns number of possible digits in fractional seconds - static unsigned short num_fractional_digits() - { - return rep_type::num_fractional_digits(); - } - duration_type invert_sign() const - { - return duration_type(ticks_ * (-1)); - } - bool is_negative() const - { - return ticks_ < 0; - } - bool operator<(const time_duration& rhs) const - { - return ticks_ < rhs.ticks_; - } - bool operator==(const time_duration& rhs) const - { - return ticks_ == rhs.ticks_; - } - //! unary- Allows for time_duration td = -td1 - duration_type operator-()const - { - return duration_type(ticks_ * (-1)); - } - duration_type operator-(const duration_type& d) const - { - return duration_type(ticks_ - d.ticks_); - } - duration_type operator+(const duration_type& d) const - { - return duration_type(ticks_ + d.ticks_); - } - duration_type operator/(int divisor) const - { - return duration_type(ticks_ / divisor); - } - duration_type operator-=(const duration_type& d) - { - ticks_ = ticks_ - d.ticks_; - return duration_type(ticks_); - } - duration_type operator+=(const duration_type& d) - { - ticks_ = ticks_ + d.ticks_; - return duration_type(ticks_); - } - //! Division operations on a duration with an integer. - duration_type operator/=(int divisor) - { - ticks_ = ticks_ / divisor; - return duration_type(ticks_); - } - //! Multiplication operations an a duration with an integer - duration_type operator*(int rhs) const - { - return duration_type(ticks_ * rhs); - } - duration_type operator*=(int divisor) - { - ticks_ = ticks_ * divisor; - return duration_type(ticks_); - } - tick_type ticks() const - { - return traits_type::as_number(ticks_); - } - - //! Is ticks_ a special value? - bool is_special()const - { - if(traits_type::is_adapted()) - { - return ticks_.is_special(); - } - else{ - return false; - } - } - //! Is duration pos-infinity - bool is_pos_infinity()const - { - if(traits_type::is_adapted()) - { - return ticks_.is_pos_infinity(); - } - else{ - return false; - } - } - //! Is duration neg-infinity - bool is_neg_infinity()const - { - if(traits_type::is_adapted()) - { - return ticks_.is_neg_infinity(); - } - else{ - return false; - } - } - //! Is duration not-a-date-time - bool is_not_a_date_time()const - { - if(traits_type::is_adapted()) - { - return ticks_.is_nan(); - } - else{ - return false; - } - } - - //! Used for special_values output - impl_type get_rep()const - { - return ticks_; - } - - protected: - explicit time_duration(impl_type in) : ticks_(in) {} - impl_type ticks_; - }; - - - - //! Template for instantiating derived adjusting durations - /* These templates are designed to work with multiples of - * 10 for frac_of_second and resoultion adjustment - */ - template - class subsecond_duration : public base_duration - { - public: - typedef typename base_duration::impl_type impl_type; - typedef typename base_duration::traits_type traits_type; - - private: - // To avoid integer overflow we precompute the duration resolution conversion coefficient (ticket #3471) - BOOST_STATIC_ASSERT_MSG((traits_type::ticks_per_second >= frac_of_second ? traits_type::ticks_per_second % frac_of_second : frac_of_second % traits_type::ticks_per_second) == 0,\ - "The base duration resolution must be a multiple of the subsecond duration resolution"); - BOOST_STATIC_CONSTANT(boost::int64_t, adjustment_ratio = (traits_type::ticks_per_second >= frac_of_second ? traits_type::ticks_per_second / frac_of_second : frac_of_second / traits_type::ticks_per_second)); - - public: - explicit subsecond_duration(boost::int64_t ss) : - base_duration(impl_type(traits_type::ticks_per_second >= frac_of_second ? ss * adjustment_ratio : ss / adjustment_ratio)) - { - } - }; - - - -} } //namespace date_time - - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_formatting_streams.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_formatting_streams.hpp deleted file mode 100644 index 2d07d344..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_formatting_streams.hpp +++ /dev/null @@ -1,122 +0,0 @@ -#ifndef DATE_TIME_TIME_FORMATTING_STREAMS_HPP___ -#define DATE_TIME_TIME_FORMATTING_STREAMS_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-12 11:37:53 -0800 (Wed, 12 Nov 2008) $ - */ - -#include - -#ifndef BOOST_DATE_TIME_NO_LOCALE - -#include -#include -#include -#include -#include - -namespace boost { -namespace date_time { - - - //! Put a time type into a stream using appropriate facets - template - class ostream_time_duration_formatter - { - public: - typedef std::basic_ostream ostream_type; - typedef typename time_duration_type::fractional_seconds_type fractional_seconds_type; - - //! Put time into an ostream - static void duration_put(const time_duration_type& td, - ostream_type& os) - { - if(td.is_special()) { - os << td.get_rep(); - } - else { - charT fill_char = '0'; - if(td.is_negative()) { - os << '-'; - } - os << std::setw(2) << std::setfill(fill_char) - << absolute_value(td.hours()) << ":"; - os << std::setw(2) << std::setfill(fill_char) - << absolute_value(td.minutes()) << ":"; - os << std::setw(2) << std::setfill(fill_char) - << absolute_value(td.seconds()); - fractional_seconds_type frac_sec = - absolute_value(td.fractional_seconds()); - if (frac_sec != 0) { - os << "." - << std::setw(time_duration_type::num_fractional_digits()) - << std::setfill(fill_char) - << frac_sec; - } - } // else - } // duration_put - }; //class ostream_time_duration_formatter - - //! Put a time type into a stream using appropriate facets - template - class ostream_time_formatter - { - public: - typedef std::basic_ostream ostream_type; - typedef typename time_type::date_type date_type; - typedef typename time_type::time_duration_type time_duration_type; - typedef ostream_time_duration_formatter duration_formatter; - - //! Put time into an ostream - static void time_put(const time_type& t, - ostream_type& os) - { - date_type d = t.date(); - os << d; - if(!d.is_infinity() && !d.is_not_a_date()) - { - os << " "; //TODO: fix the separator here. - duration_formatter::duration_put(t.time_of_day(), os); - } - - } // time_to_ostream - }; //class ostream_time_formatter - - - //! Put a time period into a stream using appropriate facets - template - class ostream_time_period_formatter - { - public: - typedef std::basic_ostream ostream_type; - typedef typename time_period_type::point_type time_type; - typedef ostream_time_formatter time_formatter; - - //! Put time into an ostream - static void period_put(const time_period_type& tp, - ostream_type& os) - { - os << '['; //TODO: facet or manipulator for periods? - time_formatter::time_put(tp.begin(), os); - os << '/'; //TODO: facet or manipulator for periods? - time_formatter::time_put(tp.last(), os); - os << ']'; - - } // period_put - - }; //class ostream_time_period_formatter - - - -} } //namespace date_time - -#endif //BOOST_DATE_TIME_NO_LOCALE - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_iterator.hpp deleted file mode 100644 index 4c33f39e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_iterator.hpp +++ /dev/null @@ -1,52 +0,0 @@ -#ifndef DATE_TIME_TIME_ITERATOR_HPP___ -#define DATE_TIME_TIME_ITERATOR_HPP___ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - - -namespace boost { -namespace date_time { - - - //! Simple time iterator skeleton class - template - class time_itr { - public: - typedef typename time_type::time_duration_type time_duration_type; - time_itr(time_type t, time_duration_type d) : current_(t), offset_(d) {} - time_itr& operator++() - { - current_ = current_ + offset_; - return *this; - } - time_itr& operator--() - { - current_ = current_ - offset_; - return *this; - } - time_type operator*() {return current_;} - time_type* operator->() {return ¤t_;} - bool operator< (const time_type& t) {return current_ < t;} - bool operator<= (const time_type& t) {return current_ <= t;} - bool operator!= (const time_type& t) {return current_ != t;} - bool operator== (const time_type& t) {return current_ == t;} - bool operator> (const time_type& t) {return current_ > t;} - bool operator>= (const time_type& t) {return current_ >= t;} - - private: - time_type current_; - time_duration_type offset_; - }; - - - -} }//namespace date_time - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_parsing.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_parsing.hpp deleted file mode 100644 index 7b71de0d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_parsing.hpp +++ /dev/null @@ -1,324 +0,0 @@ -#ifndef _DATE_TIME_TIME_PARSING_HPP___ -#define _DATE_TIME_TIME_PARSING_HPP___ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-10-10 12:05:03 -0700 (Wed, 10 Oct 2012) $ - */ - -#include "boost/tokenizer.hpp" -#include "boost/lexical_cast.hpp" -#include "boost/date_time/date_parsing.hpp" -#include "boost/cstdint.hpp" -#include - -namespace boost { -namespace date_time { - - //! computes exponential math like 2^8 => 256, only works with positive integers - //Not general purpose, but needed b/c std::pow is not available - //everywehere. Hasn't been tested with negatives and zeros - template - inline - int_type power(int_type base, int_type exponent) - { - int_type result = 1; - for(int i = 0; i < exponent; ++i){ - result *= base; - } - return result; - } - - //! Creates a time_duration object from a delimited string - /*! Expected format for string is "[-]h[h][:mm][:ss][.fff]". - * If the number of fractional digits provided is greater than the - * precision of the time duration type then the extra digits are - * truncated. - * - * A negative duration will be created if the first character in - * string is a '-', all other '-' will be treated as delimiters. - * Accepted delimiters are "-:,.". - */ - template - inline - time_duration - str_from_delimited_time_duration(const std::basic_string& s) - { - unsigned short min=0, sec =0; - int hour =0; - bool is_neg = (s.at(0) == '-'); - boost::int64_t fs=0; - int pos = 0; - - typedef typename std::basic_string::traits_type traits_type; - typedef boost::char_separator char_separator_type; - typedef boost::tokenizer::const_iterator, - std::basic_string > tokenizer; - typedef typename boost::tokenizer::const_iterator, - typename std::basic_string >::iterator tokenizer_iterator; - - char_type sep_chars[5] = {'-',':',',','.'}; - char_separator_type sep(sep_chars); - tokenizer tok(s,sep); - for(tokenizer_iterator beg=tok.begin(); beg!=tok.end();++beg){ - switch(pos) { - case 0: { - hour = boost::lexical_cast(*beg); - break; - } - case 1: { - min = boost::lexical_cast(*beg); - break; - } - case 2: { - sec = boost::lexical_cast(*beg); - break; - }; - case 3: { - int digits = static_cast(beg->length()); - //Works around a bug in MSVC 6 library that does not support - //operator>> thus meaning lexical_cast will fail to compile. -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - // msvc wouldn't compile 'time_duration::num_fractional_digits()' - // (required template argument list) as a workaround a temp - // time_duration object was used - time_duration td(hour,min,sec,fs); - int precision = td.num_fractional_digits(); - // _atoi64 is an MS specific function - if(digits >= precision) { - // drop excess digits - fs = _atoi64(beg->substr(0, precision).c_str()); - } - else { - fs = _atoi64(beg->c_str()); - } -#else - int precision = time_duration::num_fractional_digits(); - if(digits >= precision) { - // drop excess digits - fs = boost::lexical_cast(beg->substr(0, precision)); - } - else { - fs = boost::lexical_cast(*beg); - } -#endif - if(digits < precision){ - // trailing zeros get dropped from the string, - // "1:01:01.1" would yield .000001 instead of .100000 - // the power() compensates for the missing decimal places - fs *= power(10, precision - digits); - } - - break; - } - default: break; - }//switch - pos++; - } - if(is_neg) { - return -time_duration(hour, min, sec, fs); - } - else { - return time_duration(hour, min, sec, fs); - } - } - - //! Creates a time_duration object from a delimited string - /*! Expected format for string is "[-]h[h][:mm][:ss][.fff]". - * If the number of fractional digits provided is greater than the - * precision of the time duration type then the extra digits are - * truncated. - * - * A negative duration will be created if the first character in - * string is a '-', all other '-' will be treated as delimiters. - * Accepted delimiters are "-:,.". - */ - template - inline - time_duration - parse_delimited_time_duration(const std::string& s) - { - return str_from_delimited_time_duration(s); - } - - //! Utility function to split appart string - inline - bool - split(const std::string& s, - char sep, - std::string& first, - std::string& second) - { - std::string::size_type sep_pos = s.find(sep); - first = s.substr(0,sep_pos); - if (sep_pos!=std::string::npos) - second = s.substr(sep_pos+1); - return true; - } - - - template - inline - time_type - parse_delimited_time(const std::string& s, char sep) - { - typedef typename time_type::time_duration_type time_duration; - typedef typename time_type::date_type date_type; - - //split date/time on a unique delimiter char such as ' ' or 'T' - std::string date_string, tod_string; - split(s, sep, date_string, tod_string); - //call parse_date with first string - date_type d = parse_date(date_string); - //call parse_time_duration with remaining string - time_duration td = parse_delimited_time_duration(tod_string); - //construct a time - return time_type(d, td); - - } - - //! Parse time duration part of an iso time of form: [-]hhmmss[.fff...] (eg: 120259.123 is 12 hours, 2 min, 59 seconds, 123000 microseconds) - template - inline - time_duration - parse_undelimited_time_duration(const std::string& s) - { - int precision = 0; - { - // msvc wouldn't compile 'time_duration::num_fractional_digits()' - // (required template argument list) as a workaround, a temp - // time_duration object was used - time_duration tmp(0,0,0,1); - precision = tmp.num_fractional_digits(); - } - // 'precision+1' is so we grab all digits, plus the decimal - int offsets[] = {2,2,2, precision+1}; - int pos = 0, sign = 0; - int hours = 0; - short min=0, sec=0; - boost::int64_t fs=0; - // increment one position if the string was "signed" - if(s.at(sign) == '-') - { - ++sign; - } - // stlport choked when passing s.substr() to tokenizer - // using a new string fixed the error - std::string remain = s.substr(sign); - /* We do not want the offset_separator to wrap the offsets, we - * will never want to process more than: - * 2 char, 2 char, 2 char, frac_sec length. - * We *do* want the offset_separator to give us a partial for the - * last characters if there were not enough provided in the input string. */ - bool wrap_off = false; - bool ret_part = true; - boost::offset_separator osf(offsets, offsets+4, wrap_off, ret_part); - typedef boost::tokenizer::const_iterator, - std::basic_string > tokenizer; - typedef boost::tokenizer::const_iterator, - std::basic_string >::iterator tokenizer_iterator; - tokenizer tok(remain, osf); - for(tokenizer_iterator ti=tok.begin(); ti!=tok.end();++ti){ - switch(pos) { - case 0: - { - hours = boost::lexical_cast(*ti); - break; - } - case 1: - { - min = boost::lexical_cast(*ti); - break; - } - case 2: - { - sec = boost::lexical_cast(*ti); - break; - } - case 3: - { - std::string char_digits(ti->substr(1)); // digits w/no decimal - int digits = static_cast(char_digits.length()); - - //Works around a bug in MSVC 6 library that does not support - //operator>> thus meaning lexical_cast will fail to compile. -#if (defined(BOOST_MSVC) && (_MSC_VER <= 1200)) // 1200 == VC++ 6.0 - // _atoi64 is an MS specific function - if(digits >= precision) { - // drop excess digits - fs = _atoi64(char_digits.substr(0, precision).c_str()); - } - else if(digits == 0) { - fs = 0; // just in case _atoi64 doesn't like an empty string - } - else { - fs = _atoi64(char_digits.c_str()); - } -#else - if(digits >= precision) { - // drop excess digits - fs = boost::lexical_cast(char_digits.substr(0, precision)); - } - else if(digits == 0) { - fs = 0; // lexical_cast doesn't like empty strings - } - else { - fs = boost::lexical_cast(char_digits); - } -#endif - if(digits < precision){ - // trailing zeros get dropped from the string, - // "1:01:01.1" would yield .000001 instead of .100000 - // the power() compensates for the missing decimal places - fs *= power(10, precision - digits); - } - - break; - } - default: break; - }; - pos++; - } - if(sign) { - return -time_duration(hours, min, sec, fs); - } - else { - return time_duration(hours, min, sec, fs); - } - } - - //! Parse time string of form YYYYMMDDThhmmss where T is delimeter between date and time - template - inline - time_type - parse_iso_time(const std::string& s, char sep) - { - typedef typename time_type::time_duration_type time_duration; - typedef typename time_type::date_type date_type; - - //split date/time on a unique delimiter char such as ' ' or 'T' - std::string date_string, tod_string; - split(s, sep, date_string, tod_string); - //call parse_date with first string - date_type d = parse_undelimited_date(date_string); - //call parse_time_duration with remaining string - time_duration td = parse_undelimited_time_duration(tod_string); - //construct a time - return time_type(d, td); - } - - - -} }//namespace date_time - - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_resolution_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_resolution_traits.hpp deleted file mode 100644 index 903830c7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_resolution_traits.hpp +++ /dev/null @@ -1,144 +0,0 @@ -#ifndef DATE_TIME_TIME_RESOLUTION_TRAITS_HPP -#define DATE_TIME_TIME_RESOLUTION_TRAITS_HPP - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2009-06-06 04:25:55 -0700 (Sat, 06 Jun 2009) $ - */ - - -#include -#include -#include -#include - -namespace boost { -namespace date_time { - - //! Simple function to calculate absolute value of a numeric type - template - // JDG [7/6/02 made a template], - // moved here from time_duration.hpp 2003-Sept-4. - inline T absolute_value(T x) - { - return x < 0 ? -x : x; - } - - //! traits struct for time_resolution_traits implementation type - struct time_resolution_traits_bi32_impl { - typedef boost::int32_t int_type; - typedef boost::int32_t impl_type; - static int_type as_number(impl_type i){ return i;} - //! Used to determine if implemented type is int_adapter or int - static bool is_adapted() { return false;} - }; - //! traits struct for time_resolution_traits implementation type - struct time_resolution_traits_adapted32_impl { - typedef boost::int32_t int_type; - typedef boost::date_time::int_adapter impl_type; - static int_type as_number(impl_type i){ return i.as_number();} - //! Used to determine if implemented type is int_adapter or int - static bool is_adapted() { return true;} - }; - //! traits struct for time_resolution_traits implementation type - struct time_resolution_traits_bi64_impl { - typedef boost::int64_t int_type; - typedef boost::int64_t impl_type; - static int_type as_number(impl_type i){ return i;} - //! Used to determine if implemented type is int_adapter or int - static bool is_adapted() { return false;} - }; - //! traits struct for time_resolution_traits implementation type - struct time_resolution_traits_adapted64_impl { - typedef boost::int64_t int_type; - typedef boost::date_time::int_adapter impl_type; - static int_type as_number(impl_type i){ return i.as_number();} - //! Used to determine if implemented type is int_adapter or int - static bool is_adapted() { return true;} - }; - - template - class time_resolution_traits { - public: - typedef typename frac_sec_type::int_type fractional_seconds_type; - typedef typename frac_sec_type::int_type tick_type; - typedef typename frac_sec_type::impl_type impl_type; - typedef v_type day_type; - typedef v_type hour_type; - typedef v_type min_type; - typedef v_type sec_type; - - // bring in function from frac_sec_type traits structs - static fractional_seconds_type as_number(impl_type i) - { - return frac_sec_type::as_number(i); - } - static bool is_adapted() - { - return frac_sec_type::is_adapted(); - } - - //Would like this to be frac_sec_type, but some compilers complain -#if (defined(BOOST_MSVC) && (_MSC_VER < 1300)) - BOOST_STATIC_CONSTANT(boost::int64_t, ticks_per_second = resolution_adjust); -#else - BOOST_STATIC_CONSTANT(fractional_seconds_type, ticks_per_second = resolution_adjust); -#endif - - static time_resolutions resolution() - { - return res; - } - static unsigned short num_fractional_digits() - { - return frac_digits; - } - static fractional_seconds_type res_adjust() - { - return resolution_adjust; - } - //! Any negative argument results in a negative tick_count - static tick_type to_tick_count(hour_type hours, - min_type minutes, - sec_type seconds, - fractional_seconds_type fs) - { - if(hours < 0 || minutes < 0 || seconds < 0 || fs < 0) - { - hours = absolute_value(hours); - minutes = absolute_value(minutes); - seconds = absolute_value(seconds); - fs = absolute_value(fs); - return (((((fractional_seconds_type(hours)*3600) - + (fractional_seconds_type(minutes)*60) - + seconds)*res_adjust()) + fs) * -1); - } - - return (((fractional_seconds_type(hours)*3600) - + (fractional_seconds_type(minutes)*60) - + seconds)*res_adjust()) + fs; - } - - }; - - typedef time_resolution_traits milli_res; - typedef time_resolution_traits micro_res; - typedef time_resolution_traits nano_res; - - -} } //namespace date_time - - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_counted.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_counted.hpp deleted file mode 100644 index 5425f62a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_counted.hpp +++ /dev/null @@ -1,254 +0,0 @@ -#ifndef DATE_TIME_TIME_SYSTEM_COUNTED_HPP -#define DATE_TIME_TIME_SYSTEM_COUNTED_HPP - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - - - -#include "boost/date_time/time_defs.hpp" -#include - - -namespace boost { -namespace date_time { - - //! Time representation that uses a single integer count - template - struct counted_time_rep - { - typedef typename config::int_type int_type; - typedef typename config::date_type date_type; - typedef typename config::impl_type impl_type; - typedef typename date_type::duration_type date_duration_type; - typedef typename date_type::calendar_type calendar_type; - typedef typename date_type::ymd_type ymd_type; - typedef typename config::time_duration_type time_duration_type; - typedef typename config::resolution_traits resolution_traits; - - counted_time_rep(const date_type& d, const time_duration_type& time_of_day) - : time_count_(1) - { - if(d.is_infinity() || d.is_not_a_date() || time_of_day.is_special()) { - time_count_ = time_of_day.get_rep() + d.day_count(); - //std::cout << time_count_ << std::endl; - } - else { - time_count_ = (d.day_number() * frac_sec_per_day()) + time_of_day.ticks(); - } - } - explicit counted_time_rep(int_type count) : - time_count_(count) - {} - explicit counted_time_rep(impl_type count) : - time_count_(count) - {} - date_type date() const - { - if(time_count_.is_special()) { - return date_type(time_count_.as_special()); - } - else { - typename calendar_type::date_int_type dc = day_count(); - //std::cout << "time_rep here:" << dc << std::endl; - ymd_type ymd = calendar_type::from_day_number(dc); - return date_type(ymd); - } - } - //int_type day_count() const - unsigned long day_count() const - { - /* resolution_traits::as_number returns a boost::int64_t & - * frac_sec_per_day is also a boost::int64_t so, naturally, - * the division operation returns a boost::int64_t. - * The static_cast to an unsigned long is ok (results in no data loss) - * because frac_sec_per_day is either the number of - * microseconds per day, or the number of nanoseconds per day. - * Worst case scenario: resolution_traits::as_number returns the - * maximum value an int64_t can hold and frac_sec_per_day - * is microseconds per day (lowest possible value). - * The division operation will then return a value of 106751991 - - * easily fitting in an unsigned long. - */ - return static_cast(resolution_traits::as_number(time_count_) / frac_sec_per_day()); - } - int_type time_count() const - { - return resolution_traits::as_number(time_count_); - } - int_type tod() const - { - return resolution_traits::as_number(time_count_) % frac_sec_per_day(); - } - static int_type frac_sec_per_day() - { - int_type seconds_per_day = 60*60*24; - int_type fractional_sec_per_sec(resolution_traits::res_adjust()); - return seconds_per_day*fractional_sec_per_sec; - } - bool is_pos_infinity()const - { - return impl_type::is_pos_inf(time_count_.as_number()); - } - bool is_neg_infinity()const - { - return impl_type::is_neg_inf(time_count_.as_number()); - } - bool is_not_a_date_time()const - { - return impl_type::is_not_a_number(time_count_.as_number()); - } - bool is_special()const - { - return time_count_.is_special(); - } - impl_type get_rep()const - { - return time_count_; - } - private: - impl_type time_count_; - }; - - //! An unadjusted time system implementation. - template - class counted_time_system - { - public: - typedef time_rep time_rep_type; - typedef typename time_rep_type::impl_type impl_type; - typedef typename time_rep_type::time_duration_type time_duration_type; - typedef typename time_duration_type::fractional_seconds_type fractional_seconds_type; - typedef typename time_rep_type::date_type date_type; - typedef typename time_rep_type::date_duration_type date_duration_type; - - - template static void unused_var(const T&) {} - - static time_rep_type get_time_rep(const date_type& day, - const time_duration_type& tod, - date_time::dst_flags dst=not_dst) - { - unused_var(dst); - return time_rep_type(day, tod); - } - - static time_rep_type get_time_rep(special_values sv) - { - switch (sv) { - case not_a_date_time: - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - case pos_infin: - return time_rep_type(date_type(pos_infin), - time_duration_type(pos_infin)); - case neg_infin: - return time_rep_type(date_type(neg_infin), - time_duration_type(neg_infin)); - case max_date_time: { - time_duration_type td = time_duration_type(24,0,0,0) - time_duration_type(0,0,0,1); - return time_rep_type(date_type(max_date_time), td); - } - case min_date_time: - return time_rep_type(date_type(min_date_time), time_duration_type(0,0,0,0)); - - default: - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - - } - - } - - static date_type get_date(const time_rep_type& val) - { - return val.date(); - } - static time_duration_type get_time_of_day(const time_rep_type& val) - { - if(val.is_special()) { - return time_duration_type(val.get_rep().as_special()); - } - else{ - return time_duration_type(0,0,0,val.tod()); - } - } - static std::string zone_name(const time_rep_type&) - { - return ""; - } - static bool is_equal(const time_rep_type& lhs, const time_rep_type& rhs) - { - return (lhs.time_count() == rhs.time_count()); - } - static bool is_less(const time_rep_type& lhs, const time_rep_type& rhs) - { - return (lhs.time_count() < rhs.time_count()); - } - static time_rep_type add_days(const time_rep_type& base, - const date_duration_type& dd) - { - if(base.is_special() || dd.is_special()) { - return(time_rep_type(base.get_rep() + dd.get_rep())); - } - else { - return time_rep_type(base.time_count() + (dd.days() * time_rep_type::frac_sec_per_day())); - } - } - static time_rep_type subtract_days(const time_rep_type& base, - const date_duration_type& dd) - { - if(base.is_special() || dd.is_special()) { - return(time_rep_type(base.get_rep() - dd.get_rep())); - } - else{ - return time_rep_type(base.time_count() - (dd.days() * time_rep_type::frac_sec_per_day())); - } - } - static time_rep_type subtract_time_duration(const time_rep_type& base, - const time_duration_type& td) - { - if(base.is_special() || td.is_special()) { - return(time_rep_type(base.get_rep() - td.get_rep())); - } - else { - return time_rep_type(base.time_count() - td.ticks()); - } - } - static time_rep_type add_time_duration(const time_rep_type& base, - time_duration_type td) - { - if(base.is_special() || td.is_special()) { - return(time_rep_type(base.get_rep() + td.get_rep())); - } - else { - return time_rep_type(base.time_count() + td.ticks()); - } - } - static time_duration_type subtract_times(const time_rep_type& lhs, - const time_rep_type& rhs) - { - if(lhs.is_special() || rhs.is_special()) { - return(time_duration_type( - impl_type::to_special((lhs.get_rep() - rhs.get_rep()).as_number()))); - } - else { - fractional_seconds_type fs = lhs.time_count() - rhs.time_count(); - return time_duration_type(0,0,0,fs); - } - } - - }; - - -} } //namespace date_time - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_split.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_split.hpp deleted file mode 100644 index 6fc4a336..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/time_system_split.hpp +++ /dev/null @@ -1,207 +0,0 @@ -#ifndef DATE_TIME_TIME_SYSTEM_SPLIT_HPP -#define DATE_TIME_TIME_SYSTEM_SPLIT_HPP - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2008-11-13 12:10:23 -0800 (Thu, 13 Nov 2008) $ - */ - - -#include -#include "boost/date_time/compiler_config.hpp" -#include "boost/date_time/special_defs.hpp" - -namespace boost { -namespace date_time { - - //! An unadjusted time system implementation. -#if (defined(BOOST_DATE_TIME_NO_MEMBER_INIT)) - template -#else - template -#endif - class split_timedate_system - { - public: - typedef typename config::time_rep_type time_rep_type; - typedef typename config::date_type date_type; - typedef typename config::time_duration_type time_duration_type; - typedef typename config::date_duration_type date_duration_type; - typedef typename config::int_type int_type; - typedef typename config::resolution_traits resolution_traits; - - //86400 is number of seconds in a day... -#if (defined(BOOST_DATE_TIME_NO_MEMBER_INIT)) - typedef date_time::wrapping_int wrap_int_type; -#else - private: - BOOST_STATIC_CONSTANT(int_type, ticks_per_day = INT64_C(86400) * config::tick_per_second); - public: -# if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT(0X581) ) - typedef date_time::wrapping_int< split_timedate_system::int_type, split_timedate_system::ticks_per_day> wrap_int_type; -# else - typedef date_time::wrapping_int wrap_int_type; -#endif -#endif - - static time_rep_type get_time_rep(special_values sv) - { - switch (sv) { - case not_a_date_time: - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - case pos_infin: - return time_rep_type(date_type(pos_infin), - time_duration_type(pos_infin)); - case neg_infin: - return time_rep_type(date_type(neg_infin), - time_duration_type(neg_infin)); - case max_date_time: { - time_duration_type td = time_duration_type(24,0,0,0) - time_duration_type(0,0,0,1); - return time_rep_type(date_type(max_date_time), td); - } - case min_date_time: - return time_rep_type(date_type(min_date_time), time_duration_type(0,0,0,0)); - - default: - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - - } - - } - - static time_rep_type get_time_rep(const date_type& day, - const time_duration_type& tod, - date_time::dst_flags /* dst */ = not_dst) - { - if(day.is_special() || tod.is_special()) { - if(day.is_not_a_date() || tod.is_not_a_date_time()) { - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - } - else if(day.is_pos_infinity()) { - if(tod.is_neg_infinity()) { - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - } - else { - return time_rep_type(day, time_duration_type(pos_infin)); - } - } - else if(day.is_neg_infinity()) { - if(tod.is_pos_infinity()) { - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - } - else { - return time_rep_type(day, time_duration_type(neg_infin)); - } - } - else if(tod.is_pos_infinity()) { - if(day.is_neg_infinity()) { - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - } - else { - return time_rep_type(date_type(pos_infin), tod); - } - } - else if(tod.is_neg_infinity()) { - if(day.is_pos_infinity()) { - return time_rep_type(date_type(not_a_date_time), - time_duration_type(not_a_date_time)); - } - else { - return time_rep_type(date_type(neg_infin), tod); - } - } - } - return time_rep_type(day, tod); - } - static date_type get_date(const time_rep_type& val) - { - return date_type(val.day); - } - static time_duration_type get_time_of_day(const time_rep_type& val) - { - return time_duration_type(val.time_of_day); - } - static std::string zone_name(const time_rep_type&) - { - return std::string(); - } - static bool is_equal(const time_rep_type& lhs, const time_rep_type& rhs) - { - return ((lhs.day == rhs.day) && (lhs.time_of_day == rhs.time_of_day)); - } - static bool is_less(const time_rep_type& lhs, const time_rep_type& rhs) - { - if (lhs.day < rhs.day) return true; - if (lhs.day > rhs.day) return false; - return (lhs.time_of_day < rhs.time_of_day); - } - static time_rep_type add_days(const time_rep_type& base, - const date_duration_type& dd) - { - return time_rep_type(base.day+dd, base.time_of_day); - } - static time_rep_type subtract_days(const time_rep_type& base, - const date_duration_type& dd) - { - return split_timedate_system::get_time_rep(base.day-dd, base.time_of_day); - } - static time_rep_type subtract_time_duration(const time_rep_type& base, - const time_duration_type& td) - { - if(base.day.is_special() || td.is_special()) - { - return split_timedate_system::get_time_rep(base.day, -td); - } - if (td.is_negative()) { - time_duration_type td1 = td.invert_sign(); - return add_time_duration(base,td1); - } - - wrap_int_type day_offset(base.time_of_day.ticks()); - date_duration_type day_overflow(static_cast(day_offset.subtract(td.ticks()))); - - return time_rep_type(base.day-day_overflow, - time_duration_type(0,0,0,day_offset.as_int())); - } - static time_rep_type add_time_duration(const time_rep_type& base, - time_duration_type td) - { - if(base.day.is_special() || td.is_special()) { - return split_timedate_system::get_time_rep(base.day, td); - } - if (td.is_negative()) { - time_duration_type td1 = td.invert_sign(); - return subtract_time_duration(base,td1); - } - - wrap_int_type day_offset(base.time_of_day.ticks()); - date_duration_type day_overflow(static_cast< typename date_duration_type::duration_rep_type >(day_offset.add(td.ticks()))); - - return time_rep_type(base.day+day_overflow, - time_duration_type(0,0,0,day_offset.as_int())); - } - static time_duration_type subtract_times(const time_rep_type& lhs, - const time_rep_type& rhs) - { - date_duration_type dd = lhs.day - rhs.day; - time_duration_type td(dd.days()*24,0,0); //days * 24 hours - time_duration_type td2 = lhs.time_of_day - rhs.time_of_day; - return td+td2; - // return time_rep_type(base.day-dd, base.time_of_day); - } - - }; - -} } //namespace date_time - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/wrapping_int.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/wrapping_int.hpp deleted file mode 100644 index e6f87d52..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/wrapping_int.hpp +++ /dev/null @@ -1,169 +0,0 @@ -#ifndef _DATE_TIME_WRAPPING_INT_HPP__ -#define _DATE_TIME_WRAPPING_INT_HPP__ - -/* Copyright (c) 2002,2003,2005 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland, Bart Garst - * $Date: 2012-09-22 15:33:33 -0700 (Sat, 22 Sep 2012) $ - */ - - -namespace boost { -namespace date_time { - -//! A wrapping integer used to support time durations (WARNING: only instantiate with a signed type) -/*! In composite date and time types this type is used to - * wrap at the day boundary. - * Ex: - * A wrapping_int will roll over after nine, and - * roll under below zero. This gives a range of [0,9] - * - * NOTE: it is strongly recommended that wrapping_int2 be used - * instead of wrapping_int as wrapping_int is to be depricated - * at some point soon. - * - * Also Note that warnings will occur if instantiated with an - * unsigned type. Only a signed type should be used! - */ -template -class wrapping_int { -public: - typedef int_type_ int_type; - //typedef overflow_type_ overflow_type; - static int_type wrap_value() {return wrap_val;} - //!Add, return true if wrapped - wrapping_int(int_type v) : value_(v) {} - //! Explicit converion method - int_type as_int() const {return value_;} - operator int_type() const {return value_;} - //!Add, return number of wraps performed - /*! The sign of the returned value will indicate which direction the - * wraps went. Ex: add a negative number and wrapping under could occur, - * this would be indicated by a negative return value. If wrapping over - * took place, a positive value would be returned */ - template< typename IntT > - IntT add(IntT v) - { - int_type remainder = static_cast(v % (wrap_val)); - IntT overflow = static_cast(v / (wrap_val)); - value_ = static_cast(value_ + remainder); - return calculate_wrap(overflow); - } - //! Subtract will return '+d' if wrapping under took place ('d' is the number of wraps) - /*! The sign of the returned value will indicate which direction the - * wraps went (positive indicates wrap under, negative indicates wrap over). - * Ex: subtract a negative number and wrapping over could - * occur, this would be indicated by a negative return value. If - * wrapping under took place, a positive value would be returned. */ - template< typename IntT > - IntT subtract(IntT v) - { - int_type remainder = static_cast(v % (wrap_val)); - IntT underflow = static_cast(-(v / (wrap_val))); - value_ = static_cast(value_ - remainder); - return calculate_wrap(underflow) * -1; - } -private: - int_type value_; - - template< typename IntT > - IntT calculate_wrap(IntT wrap) - { - if ((value_) >= wrap_val) - { - ++wrap; - value_ -= (wrap_val); - } - else if(value_ < 0) - { - --wrap; - value_ += (wrap_val); - } - return wrap; - } - -}; - - -//! A wrapping integer used to wrap around at the top (WARNING: only instantiate with a signed type) -/*! Bad name, quick impl to fix a bug -- fix later!! - * This allows the wrap to restart at a value other than 0. - */ -template -class wrapping_int2 { -public: - typedef int_type_ int_type; - static int_type wrap_value() {return wrap_max;} - static int_type min_value() {return wrap_min;} - /*! If initializing value is out of range of [wrap_min, wrap_max], - * value will be initialized to closest of min or max */ - wrapping_int2(int_type v) : value_(v) { - if(value_ < wrap_min) - { - value_ = wrap_min; - } - if(value_ > wrap_max) - { - value_ = wrap_max; - } - } - //! Explicit converion method - int_type as_int() const {return value_;} - operator int_type() const {return value_;} - //!Add, return number of wraps performed - /*! The sign of the returned value will indicate which direction the - * wraps went. Ex: add a negative number and wrapping under could occur, - * this would be indicated by a negative return value. If wrapping over - * took place, a positive value would be returned */ - template< typename IntT > - IntT add(IntT v) - { - int_type remainder = static_cast(v % (wrap_max - wrap_min + 1)); - IntT overflow = static_cast(v / (wrap_max - wrap_min + 1)); - value_ = static_cast(value_ + remainder); - return calculate_wrap(overflow); - } - //! Subtract will return '-d' if wrapping under took place ('d' is the number of wraps) - /*! The sign of the returned value will indicate which direction the - * wraps went. Ex: subtract a negative number and wrapping over could - * occur, this would be indicated by a positive return value. If - * wrapping under took place, a negative value would be returned */ - template< typename IntT > - IntT subtract(IntT v) - { - int_type remainder = static_cast(v % (wrap_max - wrap_min + 1)); - IntT underflow = static_cast(-(v / (wrap_max - wrap_min + 1))); - value_ = static_cast(value_ - remainder); - return calculate_wrap(underflow); - } - -private: - int_type value_; - - template< typename IntT > - IntT calculate_wrap(IntT wrap) - { - if ((value_) > wrap_max) - { - ++wrap; - value_ -= (wrap_max - wrap_min + 1); - } - else if((value_) < wrap_min) - { - --wrap; - value_ += (wrap_max - wrap_min + 1); - } - return wrap; - } -}; - - - -} } //namespace date_time - - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/date_time/year_month_day.hpp b/third_party/ycmd/cpp/BoostParts/boost/date_time/year_month_day.hpp deleted file mode 100644 index 9340e53f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/date_time/year_month_day.hpp +++ /dev/null @@ -1,45 +0,0 @@ -#ifndef YearMonthDayBase_HPP__ -#define YearMonthDayBase_HPP__ - -/* Copyright (c) 2002,2003 CrystalClear Software, Inc. - * Use, modification and distribution is subject to the - * Boost Software License, Version 1.0. (See accompanying - * file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - * Author: Jeff Garland - * $Date: 2008-02-27 12:00:24 -0800 (Wed, 27 Feb 2008) $ - */ - -namespace boost { -namespace date_time { - - //! Allow rapid creation of ymd triples of different types - template - struct year_month_day_base { - year_month_day_base(YearType year, - MonthType month, - DayType day); - YearType year; - MonthType month; - DayType day; - typedef YearType year_type; - typedef MonthType month_type; - typedef DayType day_type; - }; - - - //! A basic constructor - template - inline - year_month_day_base::year_month_day_base(YearType y, - MonthType m, - DayType d) : - year(y), - month(m), - day(d) - {} - -} }//namespace date_time - - -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/allocator_utilities.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/allocator_utilities.hpp deleted file mode 100644 index 5d6ef48b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/allocator_utilities.hpp +++ /dev/null @@ -1,212 +0,0 @@ -/* Copyright 2003-2009 Joaquin M Lopez Munoz. - * Distributed under the Boost Software License, Version 1.0. - * (See accompanying file LICENSE_1_0.txt or copy at - * http://www.boost.org/LICENSE_1_0.txt) - * - * See Boost website at http://www.boost.org/ - */ - -#ifndef BOOST_DETAIL_ALLOCATOR_UTILITIES_HPP -#define BOOST_DETAIL_ALLOCATOR_UTILITIES_HPP - -#include /* keep it first to prevent nasty warns in MSVC */ -#include -#include -#include -#include -#include -#include -#include - -namespace boost{ - -namespace detail{ - -/* Allocator adaption layer. Some stdlibs provide allocators without rebind - * and template ctors. These facilities are simulated with the external - * template class rebind_to and the aid of partial_std_allocator_wrapper. - */ - -namespace allocator{ - -/* partial_std_allocator_wrapper inherits the functionality of a std - * allocator while providing a templatized ctor and other bits missing - * in some stdlib implementation or another. - */ - -template -class partial_std_allocator_wrapper:public std::allocator -{ -public: - /* Oddly enough, STLport does not define std::allocator::value_type - * when configured to work without partial template specialization. - * No harm in supplying the definition here unconditionally. - */ - - typedef Type value_type; - - partial_std_allocator_wrapper(){}; - - template - partial_std_allocator_wrapper(const partial_std_allocator_wrapper&){} - - partial_std_allocator_wrapper(const std::allocator& x): - std::allocator(x) - { - }; - -#if defined(BOOST_DINKUMWARE_STDLIB) - /* Dinkumware guys didn't provide a means to call allocate() without - * supplying a hint, in disagreement with the standard. - */ - - Type* allocate(std::size_t n,const void* hint=0) - { - std::allocator& a=*this; - return a.allocate(n,hint); - } -#endif - -}; - -/* Detects whether a given allocator belongs to a defective stdlib not - * having the required member templates. - * Note that it does not suffice to check the Boost.Config stdlib - * macros, as the user might have passed a custom, compliant allocator. - * The checks also considers partial_std_allocator_wrapper to be - * a standard defective allocator. - */ - -#if defined(BOOST_NO_STD_ALLOCATOR)&&\ - (defined(BOOST_HAS_PARTIAL_STD_ALLOCATOR)||defined(BOOST_DINKUMWARE_STDLIB)) - -template -struct is_partial_std_allocator -{ - BOOST_STATIC_CONSTANT(bool, - value= - (is_same< - std::allocator, - Allocator - >::value)|| - (is_same< - partial_std_allocator_wrapper< - BOOST_DEDUCED_TYPENAME Allocator::value_type>, - Allocator - >::value)); -}; - -#else - -template -struct is_partial_std_allocator -{ - BOOST_STATIC_CONSTANT(bool,value=false); -}; - -#endif - -/* rebind operations for defective std allocators */ - -template -struct partial_std_allocator_rebind_to -{ - typedef partial_std_allocator_wrapper type; -}; - -/* rebind operation in all other cases */ - -#if BOOST_WORKAROUND(BOOST_MSVC,<1300) -/* Workaround for a problem in MSVC with dependent template typedefs - * when doing rebinding of allocators. - * Modeled after (thanks, Aleksey!) - */ - -template -struct rebinder -{ - template struct fake_allocator:Allocator{}; - template<> struct fake_allocator - { - template struct rebind{}; - }; - - template - struct result: - fake_allocator::value>:: - template rebind - { - }; -}; -#else -template -struct rebinder -{ - template - struct result - { - typedef typename Allocator::BOOST_NESTED_TEMPLATE - rebind::other other; - }; -}; -#endif - -template -struct compliant_allocator_rebind_to -{ - typedef typename rebinder:: - BOOST_NESTED_TEMPLATE result::other type; -}; - -/* rebind front-end */ - -template -struct rebind_to: - mpl::eval_if_c< - is_partial_std_allocator::value, - partial_std_allocator_rebind_to, - compliant_allocator_rebind_to - > -{ -}; - -/* allocator-independent versions of construct and destroy */ - -template -void construct(void* p,const Type& t) -{ - new (p) Type(t); -} - -#if BOOST_WORKAROUND(BOOST_MSVC,BOOST_TESTED_AT(1500)) -/* MSVC++ issues spurious warnings about unreferencend formal parameters - * in destroy when Type is a class with trivial dtor. - */ - -#pragma warning(push) -#pragma warning(disable:4100) -#endif - -template -void destroy(const Type* p) -{ - -#if BOOST_WORKAROUND(__SUNPRO_CC,BOOST_TESTED_AT(0x590)) - const_cast(p)->~Type(); -#else - p->~Type(); -#endif - -} - -#if BOOST_WORKAROUND(BOOST_MSVC,BOOST_TESTED_AT(1500)) -#pragma warning(pop) -#endif - -} /* namespace boost::detail::allocator */ - -} /* namespace boost::detail */ - -} /* namespace boost */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_count.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_count.hpp deleted file mode 100644 index 5411c7ae..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_count.hpp +++ /dev/null @@ -1,21 +0,0 @@ -#ifndef BOOST_DETAIL_ATOMIC_COUNT_HPP_INCLUDED -#define BOOST_DETAIL_ATOMIC_COUNT_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/detail/atomic_count.hpp - thread/SMP safe reference counter -// -// Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt - -#include - -#endif // #ifndef BOOST_DETAIL_ATOMIC_COUNT_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_redef_macros.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_redef_macros.hpp deleted file mode 100644 index dfd15f5c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_redef_macros.hpp +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright (C) 2013 Vicente J. Botet Escriba -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -#if defined(BOOST_INTEL) - -#pragma pop_macro("atomic_compare_exchange") -#pragma pop_macro("atomic_compare_exchange_explicit") -#pragma pop_macro("atomic_exchange") -#pragma pop_macro("atomic_exchange_explicit") -#pragma pop_macro("atomic_is_lock_free") -#pragma pop_macro("atomic_load") -#pragma pop_macro("atomic_load_explicit") -#pragma pop_macro("atomic_store") -#pragma pop_macro("atomic_store_explicit") - -#endif // #if defined(BOOST_INTEL) diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_undef_macros.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_undef_macros.hpp deleted file mode 100644 index 18d840a7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/atomic_undef_macros.hpp +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright (C) 2013 Vicente J. Botet Escriba -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - - -#if defined(BOOST_INTEL) - -#pragma push_macro("atomic_compare_exchange") -#undef atomic_compare_exchange - -#pragma push_macro("atomic_compare_exchange_explicit") -#undef atomic_compare_exchange_explicit - -#pragma push_macro("atomic_exchange") -#undef atomic_exchange - -#pragma push_macro("atomic_exchange_explicit") -#undef atomic_exchange_explicit - -#pragma push_macro("atomic_is_lock_free") -#undef atomic_is_lock_free - -#pragma push_macro("atomic_load") -#undef atomic_load - -#pragma push_macro("atomic_load_explicit") -#undef atomic_load_explicit - -#pragma push_macro("atomic_store") -#undef atomic_store - -#pragma push_macro("atomic_store_explicit") -#undef atomic_store_explicit - - -#endif // #if defined(BOOST_INTEL) - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/binary_search.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/binary_search.hpp deleted file mode 100644 index 3dca9b65..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/binary_search.hpp +++ /dev/null @@ -1,216 +0,0 @@ -// Copyright (c) 2000 David Abrahams. -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Copyright (c) 1994 -// Hewlett-Packard Company -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. Hewlett-Packard Company makes no -// representations about the suitability of this software for any -// purpose. It is provided "as is" without express or implied warranty. -// -// Copyright (c) 1996 -// Silicon Graphics Computer Systems, Inc. -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. Silicon Graphics makes no -// representations about the suitability of this software for any -// purpose. It is provided "as is" without express or implied warranty. -// -#ifndef BINARY_SEARCH_DWA_122600_H_ -# define BINARY_SEARCH_DWA_122600_H_ - -# include -# include - -namespace boost { namespace detail { - -template -ForwardIter lower_bound(ForwardIter first, ForwardIter last, - const Tp& val) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (*middle < val) { - first = middle; - ++first; - len = len - half - 1; - } - else - len = half; - } - return first; -} - -template -ForwardIter lower_bound(ForwardIter first, ForwardIter last, - const Tp& val, Compare comp) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (comp(*middle, val)) { - first = middle; - ++first; - len = len - half - 1; - } - else - len = half; - } - return first; -} - -template -ForwardIter upper_bound(ForwardIter first, ForwardIter last, - const Tp& val) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (val < *middle) - len = half; - else { - first = middle; - ++first; - len = len - half - 1; - } - } - return first; -} - -template -ForwardIter upper_bound(ForwardIter first, ForwardIter last, - const Tp& val, Compare comp) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (comp(val, *middle)) - len = half; - else { - first = middle; - ++first; - len = len - half - 1; - } - } - return first; -} - -template -std::pair -equal_range(ForwardIter first, ForwardIter last, const Tp& val) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle, left, right; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (*middle < val) { - first = middle; - ++first; - len = len - half - 1; - } - else if (val < *middle) - len = half; - else { - left = boost::detail::lower_bound(first, middle, val); - std::advance(first, len); - right = boost::detail::upper_bound(++middle, first, val); - return std::pair(left, right); - } - } - return std::pair(first, first); -} - -template -std::pair -equal_range(ForwardIter first, ForwardIter last, const Tp& val, - Compare comp) -{ - typedef detail::iterator_traits traits; - - typename traits::difference_type len = boost::detail::distance(first, last); - typename traits::difference_type half; - ForwardIter middle, left, right; - - while (len > 0) { - half = len >> 1; - middle = first; - std::advance(middle, half); - if (comp(*middle, val)) { - first = middle; - ++first; - len = len - half - 1; - } - else if (comp(val, *middle)) - len = half; - else { - left = boost::detail::lower_bound(first, middle, val, comp); - std::advance(first, len); - right = boost::detail::upper_bound(++middle, first, val, comp); - return std::pair(left, right); - } - } - return std::pair(first, first); -} - -template -bool binary_search(ForwardIter first, ForwardIter last, - const Tp& val) { - ForwardIter i = boost::detail::lower_bound(first, last, val); - return i != last && !(val < *i); -} - -template -bool binary_search(ForwardIter first, ForwardIter last, - const Tp& val, - Compare comp) { - ForwardIter i = boost::detail::lower_bound(first, last, val, comp); - return i != last && !comp(val, *i); -} - -}} // namespace boost::detail - -#endif // BINARY_SEARCH_DWA_122600_H_ diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/bitmask.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/bitmask.hpp deleted file mode 100644 index c6714a11..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/bitmask.hpp +++ /dev/null @@ -1,47 +0,0 @@ -// boost/detail/bitmask.hpp ------------------------------------------------// - -// Copyright Beman Dawes 2006 - -// Distributed under the Boost Software License, Version 1.0 -// http://www.boost.org/LICENSE_1_0.txt - -// Usage: enum foo { a=1, b=2, c=4 }; -// BOOST_BITMASK( foo ); -// -// void f( foo arg ); -// ... -// f( a | c ); - -#ifndef BOOST_BITMASK_HPP -#define BOOST_BITMASK_HPP - -#include - -#define BOOST_BITMASK(Bitmask) \ - \ - inline Bitmask operator| (Bitmask x , Bitmask y ) \ - { return static_cast( static_cast(x) \ - | static_cast(y)); } \ - \ - inline Bitmask operator& (Bitmask x , Bitmask y ) \ - { return static_cast( static_cast(x) \ - & static_cast(y)); } \ - \ - inline Bitmask operator^ (Bitmask x , Bitmask y ) \ - { return static_cast( static_cast(x) \ - ^ static_cast(y)); } \ - \ - inline Bitmask operator~ (Bitmask x ) \ - { return static_cast(~static_cast(x)); } \ - \ - inline Bitmask & operator&=(Bitmask & x , Bitmask y) \ - { x = x & y ; return x ; } \ - \ - inline Bitmask & operator|=(Bitmask & x , Bitmask y) \ - { x = x | y ; return x ; } \ - \ - inline Bitmask & operator^=(Bitmask & x , Bitmask y) \ - { x = x ^ y ; return x ; } - -#endif // BOOST_BITMASK_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/call_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/call_traits.hpp deleted file mode 100644 index 36dea000..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/call_traits.hpp +++ /dev/null @@ -1,172 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. - -// call_traits: defines typedefs for function usage -// (see libs/utility/call_traits.htm) - -/* Release notes: - 23rd July 2000: - Fixed array specialization. (JM) - Added Borland specific fixes for reference types - (issue raised by Steve Cleary). -*/ - -#ifndef BOOST_DETAIL_CALL_TRAITS_HPP -#define BOOST_DETAIL_CALL_TRAITS_HPP - -#ifndef BOOST_CONFIG_HPP -#include -#endif -#include - -#include -#include -#include -#include - -namespace boost{ - -namespace detail{ - -template -struct ct_imp2 -{ - typedef const T& param_type; -}; - -template -struct ct_imp2 -{ - typedef const T param_type; -}; - -template -struct ct_imp -{ - typedef const T& param_type; -}; - -template -struct ct_imp -{ - typedef typename ct_imp2::param_type param_type; -}; - -template -struct ct_imp -{ - typedef typename ct_imp2::param_type param_type; -}; - -template -struct ct_imp -{ - typedef const T param_type; -}; - -} - -template -struct call_traits -{ -public: - typedef T value_type; - typedef T& reference; - typedef const T& const_reference; - // - // C++ Builder workaround: we should be able to define a compile time - // constant and pass that as a single template parameter to ct_imp, - // however compiler bugs prevent this - instead pass three bool's to - // ct_imp and add an extra partial specialisation - // of ct_imp to handle the logic. (JM) - typedef typename boost::detail::ct_imp< - T, - ::boost::is_pointer::value, - ::boost::is_arithmetic::value, - ::boost::is_enum::value - >::param_type param_type; -}; - -template -struct call_traits -{ - typedef T& value_type; - typedef T& reference; - typedef const T& const_reference; - typedef T& param_type; // hh removed const -}; - -#if BOOST_WORKAROUND( __BORLANDC__, < 0x5A0 ) -// these are illegal specialisations; cv-qualifies applied to -// references have no effect according to [8.3.2p1], -// C++ Builder requires them though as it treats cv-qualified -// references as distinct types... -template -struct call_traits -{ - typedef T& value_type; - typedef T& reference; - typedef const T& const_reference; - typedef T& param_type; // hh removed const -}; -template -struct call_traits -{ - typedef T& value_type; - typedef T& reference; - typedef const T& const_reference; - typedef T& param_type; // hh removed const -}; -template -struct call_traits -{ - typedef T& value_type; - typedef T& reference; - typedef const T& const_reference; - typedef T& param_type; // hh removed const -}; - -template -struct call_traits< T * > -{ - typedef T * value_type; - typedef T * & reference; - typedef T * const & const_reference; - typedef T * const param_type; // hh removed const -}; -#endif -#if !defined(BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS) -template -struct call_traits -{ -private: - typedef T array_type[N]; -public: - // degrades array to pointer: - typedef const T* value_type; - typedef array_type& reference; - typedef const array_type& const_reference; - typedef const T* const param_type; -}; - -template -struct call_traits -{ -private: - typedef const T array_type[N]; -public: - // degrades array to pointer: - typedef const T* value_type; - typedef array_type& reference; - typedef const array_type& const_reference; - typedef const T* const param_type; -}; -#endif - -} - -#endif // BOOST_DETAIL_CALL_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/compressed_pair.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/compressed_pair.hpp deleted file mode 100644 index 3f326456..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/compressed_pair.hpp +++ /dev/null @@ -1,443 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. - -// compressed_pair: pair that "compresses" empty members -// (see libs/utility/compressed_pair.htm) -// -// JM changes 25 Jan 2004: -// For the case where T1 == T2 and both are empty, then first() and second() -// should return different objects. -// JM changes 25 Jan 2000: -// Removed default arguments from compressed_pair_switch to get -// C++ Builder 4 to accept them -// rewriten swap to get gcc and C++ builder to compile. -// added partial specialisations for case T1 == T2 to avoid duplicate constructor defs. - -#ifndef BOOST_DETAIL_COMPRESSED_PAIR_HPP -#define BOOST_DETAIL_COMPRESSED_PAIR_HPP - -#include - -#include -#include -#include -#include - -#ifdef BOOST_MSVC -# pragma warning(push) -# pragma warning(disable:4512) -#endif -namespace boost -{ - -template -class compressed_pair; - - -// compressed_pair - -namespace details -{ - // JM altered 26 Jan 2000: - template - struct compressed_pair_switch; - - template - struct compressed_pair_switch - {static const int value = 0;}; - - template - struct compressed_pair_switch - {static const int value = 3;}; - - template - struct compressed_pair_switch - {static const int value = 1;}; - - template - struct compressed_pair_switch - {static const int value = 2;}; - - template - struct compressed_pair_switch - {static const int value = 4;}; - - template - struct compressed_pair_switch - {static const int value = 5;}; - - template class compressed_pair_imp; - -#ifdef __GNUC__ - // workaround for GCC (JM): - using std::swap; -#endif - // - // can't call unqualified swap from within classname::swap - // as Koenig lookup rules will find only the classname::swap - // member function not the global declaration, so use cp_swap - // as a forwarding function (JM): - template - inline void cp_swap(T& t1, T& t2) - { -#ifndef __GNUC__ - using std::swap; -#endif - swap(t1, t2); - } - - // 0 derive from neither - - template - class compressed_pair_imp - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : first_(x), second_(y) {} - - compressed_pair_imp(first_param_type x) - : first_(x) {} - - compressed_pair_imp(second_param_type y) - : second_(y) {} - - first_reference first() {return first_;} - first_const_reference first() const {return first_;} - - second_reference second() {return second_;} - second_const_reference second() const {return second_;} - - void swap(::boost::compressed_pair& y) - { - cp_swap(first_, y.first()); - cp_swap(second_, y.second()); - } - private: - first_type first_; - second_type second_; - }; - - // 1 derive from T1 - - template - class compressed_pair_imp - : protected ::boost::remove_cv::type - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : first_type(x), second_(y) {} - - compressed_pair_imp(first_param_type x) - : first_type(x) {} - - compressed_pair_imp(second_param_type y) - : second_(y) {} - - first_reference first() {return *this;} - first_const_reference first() const {return *this;} - - second_reference second() {return second_;} - second_const_reference second() const {return second_;} - - void swap(::boost::compressed_pair& y) - { - // no need to swap empty base class: - cp_swap(second_, y.second()); - } - private: - second_type second_; - }; - - // 2 derive from T2 - - template - class compressed_pair_imp - : protected ::boost::remove_cv::type - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : second_type(y), first_(x) {} - - compressed_pair_imp(first_param_type x) - : first_(x) {} - - compressed_pair_imp(second_param_type y) - : second_type(y) {} - - first_reference first() {return first_;} - first_const_reference first() const {return first_;} - - second_reference second() {return *this;} - second_const_reference second() const {return *this;} - - void swap(::boost::compressed_pair& y) - { - // no need to swap empty base class: - cp_swap(first_, y.first()); - } - - private: - first_type first_; - }; - - // 3 derive from T1 and T2 - - template - class compressed_pair_imp - : protected ::boost::remove_cv::type, - protected ::boost::remove_cv::type - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : first_type(x), second_type(y) {} - - compressed_pair_imp(first_param_type x) - : first_type(x) {} - - compressed_pair_imp(second_param_type y) - : second_type(y) {} - - first_reference first() {return *this;} - first_const_reference first() const {return *this;} - - second_reference second() {return *this;} - second_const_reference second() const {return *this;} - // - // no need to swap empty bases: - void swap(::boost::compressed_pair&) {} - }; - - // JM - // 4 T1 == T2, T1 and T2 both empty - // Originally this did not store an instance of T2 at all - // but that led to problems beause it meant &x.first() == &x.second() - // which is not true for any other kind of pair, so now we store an instance - // of T2 just in case the user is relying on first() and second() returning - // different objects (albeit both empty). - template - class compressed_pair_imp - : protected ::boost::remove_cv::type - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : first_type(x), m_second(y) {} - - compressed_pair_imp(first_param_type x) - : first_type(x), m_second(x) {} - - first_reference first() {return *this;} - first_const_reference first() const {return *this;} - - second_reference second() {return m_second;} - second_const_reference second() const {return m_second;} - - void swap(::boost::compressed_pair&) {} - private: - T2 m_second; - }; - - // 5 T1 == T2 and are not empty: //JM - - template - class compressed_pair_imp - { - public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_imp() {} - - compressed_pair_imp(first_param_type x, second_param_type y) - : first_(x), second_(y) {} - - compressed_pair_imp(first_param_type x) - : first_(x), second_(x) {} - - first_reference first() {return first_;} - first_const_reference first() const {return first_;} - - second_reference second() {return second_;} - second_const_reference second() const {return second_;} - - void swap(::boost::compressed_pair& y) - { - cp_swap(first_, y.first()); - cp_swap(second_, y.second()); - } - private: - first_type first_; - second_type second_; - }; - -} // details - -template -class compressed_pair - : private ::boost::details::compressed_pair_imp::type, typename remove_cv::type>::value, - ::boost::is_empty::value, - ::boost::is_empty::value>::value> -{ -private: - typedef details::compressed_pair_imp::type, typename remove_cv::type>::value, - ::boost::is_empty::value, - ::boost::is_empty::value>::value> base; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair() : base() {} - compressed_pair(first_param_type x, second_param_type y) : base(x, y) {} - explicit compressed_pair(first_param_type x) : base(x) {} - explicit compressed_pair(second_param_type y) : base(y) {} - - first_reference first() {return base::first();} - first_const_reference first() const {return base::first();} - - second_reference second() {return base::second();} - second_const_reference second() const {return base::second();} - - void swap(compressed_pair& y) { base::swap(y); } -}; - -// JM -// Partial specialisation for case where T1 == T2: -// -template -class compressed_pair - : private details::compressed_pair_imp::type, typename remove_cv::type>::value, - ::boost::is_empty::value, - ::boost::is_empty::value>::value> -{ -private: - typedef details::compressed_pair_imp::type, typename remove_cv::type>::value, - ::boost::is_empty::value, - ::boost::is_empty::value>::value> base; -public: - typedef T first_type; - typedef T second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair() : base() {} - compressed_pair(first_param_type x, second_param_type y) : base(x, y) {} -#if !(defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x530)) - explicit -#endif - compressed_pair(first_param_type x) : base(x) {} - - first_reference first() {return base::first();} - first_const_reference first() const {return base::first();} - - second_reference second() {return base::second();} - second_const_reference second() const {return base::second();} - - void swap(::boost::compressed_pair& y) { base::swap(y); } -}; - -template -inline -void -swap(compressed_pair& x, compressed_pair& y) -{ - x.swap(y); -} - -} // boost - -#ifdef BOOST_MSVC -# pragma warning(pop) -#endif - -#endif // BOOST_DETAIL_COMPRESSED_PAIR_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/container_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/container_fwd.hpp deleted file mode 100644 index ef174980..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/container_fwd.hpp +++ /dev/null @@ -1,162 +0,0 @@ - -// Copyright 2005-2011 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Note: if you change this include guard, you also need to change -// container_fwd_compile_fail.cpp -#if !defined(BOOST_DETAIL_CONTAINER_FWD_HPP) -#define BOOST_DETAIL_CONTAINER_FWD_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) && \ - !defined(BOOST_DETAIL_TEST_CONFIG_ONLY) -# pragma once -#endif - -#include -#include - -//////////////////////////////////////////////////////////////////////////////// -// // -// Define BOOST_DETAIL_NO_CONTAINER_FWD if you don't want this header to // -// forward declare standard containers. // -// // -// BOOST_DETAIL_CONTAINER_FWD to make it foward declare containers even if it // -// normally doesn't. // -// // -// BOOST_DETAIL_NO_CONTAINER_FWD overrides BOOST_DETAIL_CONTAINER_FWD. // -// // -//////////////////////////////////////////////////////////////////////////////// - -#if !defined(BOOST_DETAIL_NO_CONTAINER_FWD) -# if defined(BOOST_DETAIL_CONTAINER_FWD) - // Force forward declarations. -# elif defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) - // STLport -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif defined(__LIBCOMO__) - // Comeau STL: -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) - // Rogue Wave library: -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif defined(_LIBCPP_VERSION) - // libc++ -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif defined(__GLIBCPP__) || defined(__GLIBCXX__) - // GNU libstdc++ 3 - // - // Disable forwarding for all recent versions, as the library has a - // versioned namespace mode, and I don't know how to detect it. -# if __GLIBCXX__ >= 20070513 \ - || defined(_GLIBCXX_DEBUG) \ - || defined(_GLIBCXX_PARALLEL) \ - || defined(_GLIBCXX_PROFILE) -# define BOOST_DETAIL_NO_CONTAINER_FWD -# else -# if defined(__GLIBCXX__) && __GLIBCXX__ >= 20040530 -# define BOOST_CONTAINER_FWD_COMPLEX_STRUCT -# endif -# endif -# elif defined(__STL_CONFIG_H) - // generic SGI STL - // - // Forward declaration seems to be okay, but it has a couple of odd - // implementations. -# define BOOST_CONTAINER_FWD_BAD_BITSET -# if !defined(__STL_NON_TYPE_TMPL_PARAM_BUG) -# define BOOST_CONTAINER_FWD_BAD_DEQUE -# endif -# elif defined(__MSL_CPP__) - // MSL standard lib: -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif defined(__IBMCPP__) - // The default VACPP std lib, forward declaration seems to be fine. -# elif defined(MSIPL_COMPILE_H) - // Modena C++ standard library -# define BOOST_DETAIL_NO_CONTAINER_FWD -# elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER) - // Dinkumware Library (this has to appear after any possible replacement - // libraries) -# else -# define BOOST_DETAIL_NO_CONTAINER_FWD -# endif -#endif - -#if !defined(BOOST_DETAIL_TEST_CONFIG_ONLY) - -#if defined(BOOST_DETAIL_NO_CONTAINER_FWD) && \ - !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD) - -#include -#include -#include -#include -#include -#include -#include -#include - -#else - -#include - -#if defined(BOOST_CONTAINER_FWD_BAD_DEQUE) -#include -#endif - -#if defined(BOOST_CONTAINER_FWD_BAD_BITSET) -#include -#endif - -#if defined(BOOST_MSVC) -#pragma warning(push) -#pragma warning(disable:4099) // struct/class mismatch in fwd declarations -#endif - -namespace std -{ - template class allocator; - template class basic_string; - -#if BOOST_WORKAROUND(__GNUC__, < 3) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - - template struct string_char_traits; -#else - template struct char_traits; -#endif - -#if defined(BOOST_CONTAINER_FWD_COMPLEX_STRUCT) - template struct complex; -#else - template class complex; -#endif - -#if !defined(BOOST_CONTAINER_FWD_BAD_DEQUE) - template class deque; -#endif - - template class list; - template class vector; - template class map; - template - class multimap; - template class set; - template class multiset; - -#if !defined(BOOST_CONTAINER_FWD_BAD_BITSET) - template class bitset; -#endif - template struct pair; -} - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#endif // BOOST_DETAIL_NO_CONTAINER_FWD && - // !defined(BOOST_DETAIL_TEST_FORCE_CONTAINER_FWD) - -#endif // BOOST_DETAIL_TEST_CONFIG_ONLY - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/dynamic_bitset.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/dynamic_bitset.hpp deleted file mode 100644 index 281aa55c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/dynamic_bitset.hpp +++ /dev/null @@ -1,229 +0,0 @@ -// ----------------------------------------------------------- -// -// Copyright (c) 2001-2002 Chuck Allison and Jeremy Siek -// Copyright (c) 2003-2006, 2008 Gennaro Prota -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// ----------------------------------------------------------- - -#ifndef BOOST_DETAIL_DYNAMIC_BITSET_HPP -#define BOOST_DETAIL_DYNAMIC_BITSET_HPP - -#include -#include "boost/config.hpp" -#include "boost/detail/workaround.hpp" - - -namespace boost { - - namespace detail { - namespace dynamic_bitset_impl { - - // Gives (read-)access to the object representation - // of an object of type T (3.9p4). CANNOT be used - // on a base sub-object - // - template - inline const unsigned char * object_representation (T* p) - { - return static_cast(static_cast(p)); - } - - template - struct shifter - { - static void left_shift(T & v) { - amount >= width ? (v = 0) - : (v >>= BOOST_DYNAMIC_BITSET_WRAP_CONSTANT(amount)); - } - }; - - // ------- count function implementation -------------- - - typedef unsigned char byte_type; - - // These two entities - // - // enum mode { access_by_bytes, access_by_blocks }; - // template struct mode_to_type {}; - // - // were removed, since the regression logs (as of 24 Aug 2008) - // showed that several compilers had troubles with recognizing - // - // const mode m = access_by_bytes - // - // as a constant expression - // - // * So, we'll use bool, instead of enum *. - // - template - struct value_to_type - { - value_to_type() {} - }; - const bool access_by_bytes = true; - const bool access_by_blocks = false; - - - // the table: wrapped in a class template, so - // that it is only instantiated if/when needed - // - template - struct count_table { static const byte_type table[]; }; - - template <> - struct count_table { /* no table */ }; - - - const unsigned int table_width = 8; - template - const byte_type count_table::table[] = - { - // Automatically generated by GPTableGen.exe v.1.0 - // - 0, 1, 1, 2, 1, 2, 2, 3, 1, 2, 2, 3, 2, 3, 3, 4, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, - 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, - 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, - 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, - 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, - 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, - 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, - 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 5, 6, 6, 7, 4, 5, 5, 6, 5, 6, 6, 7, 5, 6, 6, 7, 6, 7, 7, 8 - }; - - - // overload for access by bytes - // - - template - inline std::size_t do_count(Iterator first, std::size_t length, - int /*dummy param*/, - value_to_type* ) - { - std::size_t num = 0; - if (length) - { - const byte_type * p = object_representation(&*first); - length *= sizeof(*first); - - do { - num += count_table<>::table[*p]; - ++p; - --length; - - } while (length); - } - - return num; - } - - - // overload for access by blocks - // - template - inline std::size_t do_count(Iterator first, std::size_t length, ValueType, - value_to_type*) - { - std::size_t num = 0; - while (length){ - - ValueType value = *first; - while (value) { - num += count_table<>::table[value & ((1u<>= table_width; - } - - ++first; - --length; - } - - return num; - } - - // ------------------------------------------------------- - - - // Some library implementations simply return a dummy - // value such as - // - // size_type(-1) / sizeof(T) - // - // from vector<>::max_size. This tries to get more - // meaningful info. - // - template - typename T::size_type vector_max_size_workaround(const T & v) { - - typedef typename T::allocator_type allocator_type; - - const typename allocator_type::size_type alloc_max = - v.get_allocator().max_size(); - const typename T::size_type container_max = v.max_size(); - - return alloc_max < container_max? - alloc_max : - container_max; - } - - // for static_asserts - template - struct allowed_block_type { - enum { value = T(-1) > 0 }; // ensure T has no sign - }; - - template <> - struct allowed_block_type { - enum { value = false }; - }; - - - template - struct is_numeric { - enum { value = false }; - }; - -# define BOOST_dynamic_bitset_is_numeric(x) \ - template<> \ - struct is_numeric< x > { \ - enum { value = true }; \ - } /**/ - - BOOST_dynamic_bitset_is_numeric(bool); - BOOST_dynamic_bitset_is_numeric(char); - -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) - BOOST_dynamic_bitset_is_numeric(wchar_t); -#endif - - BOOST_dynamic_bitset_is_numeric(signed char); - BOOST_dynamic_bitset_is_numeric(short int); - BOOST_dynamic_bitset_is_numeric(int); - BOOST_dynamic_bitset_is_numeric(long int); - - BOOST_dynamic_bitset_is_numeric(unsigned char); - BOOST_dynamic_bitset_is_numeric(unsigned short); - BOOST_dynamic_bitset_is_numeric(unsigned int); - BOOST_dynamic_bitset_is_numeric(unsigned long); - -#if defined(BOOST_HAS_LONG_LONG) - BOOST_dynamic_bitset_is_numeric(::boost::long_long_type); - BOOST_dynamic_bitset_is_numeric(::boost::ulong_long_type); -#endif - - // intentionally omitted - //BOOST_dynamic_bitset_is_numeric(float); - //BOOST_dynamic_bitset_is_numeric(double); - //BOOST_dynamic_bitset_is_numeric(long double); - -#undef BOOST_dynamic_bitset_is_numeric - - } // dynamic_bitset_impl - } // namespace detail - -} // namespace boost - -#endif // include guard - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/endian.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/endian.hpp deleted file mode 100644 index 3e37db93..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/endian.hpp +++ /dev/null @@ -1,11 +0,0 @@ -// Copyright 2013 Redshift Software Inc -// Distributed under the Boost Software License, Version 1.0. (See accompany- -// ing file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_DETAIL_ENDIAN_HPP -#define BOOST_DETAIL_ENDIAN_HPP - -// Use the Predef library for the detection of endianess. -#include - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/fenv.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/fenv.hpp deleted file mode 100644 index f0487064..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/fenv.hpp +++ /dev/null @@ -1,74 +0,0 @@ -/*============================================================================= - Copyright (c) 2010 Bryce Lelbach - - Distributed under the Boost Software License, Version 1.0. (See accompanying - file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -=============================================================================*/ - -#include - -#if defined(BOOST_NO_FENV_H) - #error This platform does not have a floating point environment -#endif - -#if !defined(BOOST_DETAIL_FENV_HPP) -#define BOOST_DETAIL_FENV_HPP - -/* If we're using clang + glibc, we have to get hacky. - * See http://llvm.org/bugs/show_bug.cgi?id=6907 */ -#if defined(__clang__) && (__clang_major__ < 3) && \ - defined(__GNU_LIBRARY__) && /* up to version 5 */ \ - defined(__GLIBC__) && /* version 6 + */ \ - !defined(_FENV_H) - #define _FENV_H - - #include - #include - - extern "C" { - extern int fegetexceptflag (fexcept_t*, int) __THROW; - extern int fesetexceptflag (__const fexcept_t*, int) __THROW; - extern int feclearexcept (int) __THROW; - extern int feraiseexcept (int) __THROW; - extern int fetestexcept (int) __THROW; - extern int fegetround (void) __THROW; - extern int fesetround (int) __THROW; - extern int fegetenv (fenv_t*) __THROW; - extern int fesetenv (__const fenv_t*) __THROW; - extern int feupdateenv (__const fenv_t*) __THROW; - extern int feholdexcept (fenv_t*) __THROW; - - #ifdef __USE_GNU - extern int feenableexcept (int) __THROW; - extern int fedisableexcept (int) __THROW; - extern int fegetexcept (void) __THROW; - #endif - } - - namespace std { namespace tr1 { - using ::fenv_t; - using ::fexcept_t; - using ::fegetexceptflag; - using ::fesetexceptflag; - using ::feclearexcept; - using ::feraiseexcept; - using ::fetestexcept; - using ::fegetround; - using ::fesetround; - using ::fegetenv; - using ::fesetenv; - using ::feupdateenv; - using ::feholdexcept; - } } - -#else /* if we're not using GNU's C stdlib, fenv.h should work with clang */ - #if defined(__SUNPRO_CC) /* lol suncc */ - #include - #endif - - #include - -#endif - -#endif /* BOOST_DETAIL_FENV_HPP */ - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/indirect_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/indirect_traits.hpp deleted file mode 100644 index f9c0cd6a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/indirect_traits.hpp +++ /dev/null @@ -1,487 +0,0 @@ -// Copyright David Abrahams 2002. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -#ifndef INDIRECT_TRAITS_DWA2002131_HPP -# define INDIRECT_TRAITS_DWA2002131_HPP -# include -# include -# include -# include -# include -# include -# include -# include -# include -# include -# include - -# include -# include - -# include -# include -# include -# include -# include -# include - -# ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# include -# endif - -namespace boost { namespace detail { - -namespace indirect_traits { - -# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -template -struct is_reference_to_const : mpl::false_ -{ -}; - -template -struct is_reference_to_const : mpl::true_ -{ -}; - -# if defined(BOOST_MSVC) && _MSC_FULL_VER <= 13102140 // vc7.01 alpha workaround -template -struct is_reference_to_const : mpl::true_ -{ -}; -# endif - -template -struct is_reference_to_function : mpl::false_ -{ -}; - -template -struct is_reference_to_function : is_function -{ -}; - -template -struct is_pointer_to_function : mpl::false_ -{ -}; - -// There's no such thing as a pointer-to-cv-function, so we don't need -// specializations for those -template -struct is_pointer_to_function : is_function -{ -}; - -template -struct is_reference_to_member_function_pointer_impl : mpl::false_ -{ -}; - -template -struct is_reference_to_member_function_pointer_impl - : is_member_function_pointer::type> -{ -}; - - -template -struct is_reference_to_member_function_pointer - : is_reference_to_member_function_pointer_impl -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_member_function_pointer,(T)) -}; - -template -struct is_reference_to_function_pointer_aux - : mpl::and_< - is_reference - , is_pointer_to_function< - typename remove_cv< - typename remove_reference::type - >::type - > - > -{ - // There's no such thing as a pointer-to-cv-function, so we don't need specializations for those -}; - -template -struct is_reference_to_function_pointer - : mpl::if_< - is_reference_to_function - , mpl::false_ - , is_reference_to_function_pointer_aux - >::type -{ -}; - -template -struct is_reference_to_non_const - : mpl::and_< - is_reference - , mpl::not_< - is_reference_to_const - > - > -{ -}; - -template -struct is_reference_to_volatile : mpl::false_ -{ -}; - -template -struct is_reference_to_volatile : mpl::true_ -{ -}; - -# if defined(BOOST_MSVC) && _MSC_FULL_VER <= 13102140 // vc7.01 alpha workaround -template -struct is_reference_to_volatile : mpl::true_ -{ -}; -# endif - - -template -struct is_reference_to_pointer : mpl::false_ -{ -}; - -template -struct is_reference_to_pointer : mpl::true_ -{ -}; - -template -struct is_reference_to_pointer : mpl::true_ -{ -}; - -template -struct is_reference_to_pointer : mpl::true_ -{ -}; - -template -struct is_reference_to_pointer : mpl::true_ -{ -}; - -template -struct is_reference_to_class - : mpl::and_< - is_reference - , is_class< - typename remove_cv< - typename remove_reference::type - >::type - > - > -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_class,(T)) -}; - -template -struct is_pointer_to_class - : mpl::and_< - is_pointer - , is_class< - typename remove_cv< - typename remove_pointer::type - >::type - > - > -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_pointer_to_class,(T)) -}; - -# else - -using namespace boost::detail::is_function_ref_tester_; - -typedef char (&inner_yes_type)[3]; -typedef char (&inner_no_type)[2]; -typedef char (&outer_no_type)[1]; - -template -struct is_const_help -{ - typedef typename mpl::if_< - is_const - , inner_yes_type - , inner_no_type - >::type type; -}; - -template -struct is_volatile_help -{ - typedef typename mpl::if_< - is_volatile - , inner_yes_type - , inner_no_type - >::type type; -}; - -template -struct is_pointer_help -{ - typedef typename mpl::if_< - is_pointer - , inner_yes_type - , inner_no_type - >::type type; -}; - -template -struct is_class_help -{ - typedef typename mpl::if_< - is_class - , inner_yes_type - , inner_no_type - >::type type; -}; - -template -struct is_reference_to_function_aux -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value = sizeof(detail::is_function_ref_tester(t,0)) == sizeof(::boost::type_traits::yes_type)); - typedef mpl::bool_ type; - }; - -template -struct is_reference_to_function - : mpl::if_, is_reference_to_function_aux, mpl::bool_ >::type -{ -}; - -template -struct is_pointer_to_function_aux -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = sizeof(::boost::type_traits::is_function_ptr_tester(t)) == sizeof(::boost::type_traits::yes_type)); - typedef mpl::bool_ type; -}; - -template -struct is_pointer_to_function - : mpl::if_, is_pointer_to_function_aux, mpl::bool_ >::type -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_pointer_to_function,(T)) -}; - -struct false_helper1 -{ - template - struct apply : mpl::false_ - { - }; -}; - -template -typename is_const_help::type reference_to_const_helper(V&); -outer_no_type -reference_to_const_helper(...); - -struct true_helper1 -{ - template - struct apply - { - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = sizeof(reference_to_const_helper(t)) == sizeof(inner_yes_type)); - typedef mpl::bool_ type; - }; -}; - -template -struct is_reference_to_const_helper1 : true_helper1 -{ -}; - -template <> -struct is_reference_to_const_helper1 : false_helper1 -{ -}; - - -template -struct is_reference_to_const - : is_reference_to_const_helper1::value>::template apply -{ -}; - - -template -struct is_reference_to_non_const_helper1 -{ - template - struct apply - { - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = sizeof(reference_to_const_helper(t)) == sizeof(inner_no_type)); - - typedef mpl::bool_ type; - }; -}; - -template <> -struct is_reference_to_non_const_helper1 : false_helper1 -{ -}; - - -template -struct is_reference_to_non_const - : is_reference_to_non_const_helper1::value>::template apply -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_non_const,(T)) -}; - - -template -typename is_volatile_help::type reference_to_volatile_helper(V&); -outer_no_type -reference_to_volatile_helper(...); - -template -struct is_reference_to_volatile_helper1 -{ - template - struct apply - { - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = sizeof(reference_to_volatile_helper(t)) == sizeof(inner_yes_type)); - typedef mpl::bool_ type; - }; -}; - -template <> -struct is_reference_to_volatile_helper1 : false_helper1 -{ -}; - - -template -struct is_reference_to_volatile - : is_reference_to_volatile_helper1::value>::template apply -{ -}; - -template -typename is_pointer_help::type reference_to_pointer_helper(V&); -outer_no_type reference_to_pointer_helper(...); - -template -struct reference_to_pointer_impl -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = (sizeof((reference_to_pointer_helper)(t)) == sizeof(inner_yes_type)) - ); - - typedef mpl::bool_ type; -}; - -template -struct is_reference_to_pointer - : mpl::eval_if, reference_to_pointer_impl, mpl::false_>::type -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_pointer,(T)) -}; - -template -struct is_reference_to_function_pointer - : mpl::eval_if, is_pointer_to_function_aux, mpl::false_>::type -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_function_pointer,(T)) -}; - - -template -struct is_member_function_pointer_help - : mpl::if_, inner_yes_type, inner_no_type> -{}; - -template -typename is_member_function_pointer_help::type member_function_pointer_helper(V&); -outer_no_type member_function_pointer_helper(...); - -template -struct is_pointer_to_member_function_aux -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = sizeof((member_function_pointer_helper)(t)) == sizeof(inner_yes_type)); - typedef mpl::bool_ type; -}; - -template -struct is_reference_to_member_function_pointer - : mpl::if_< - is_reference - , is_pointer_to_member_function_aux - , mpl::bool_ - >::type -{ - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_member_function_pointer,(T)) -}; - -template -typename is_class_help::type reference_to_class_helper(V const volatile&); -outer_no_type reference_to_class_helper(...); - -template -struct is_reference_to_class -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = (is_reference::value - & (sizeof(reference_to_class_helper(t)) == sizeof(inner_yes_type))) - ); - typedef mpl::bool_ type; - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_reference_to_class,(T)) -}; - -template -typename is_class_help::type pointer_to_class_helper(V const volatile*); -outer_no_type pointer_to_class_helper(...); - -template -struct is_pointer_to_class -{ - static T t; - BOOST_STATIC_CONSTANT( - bool, value - = (is_pointer::value - && sizeof(pointer_to_class_helper(t)) == sizeof(inner_yes_type)) - ); - typedef mpl::bool_ type; -}; -# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -} - -using namespace indirect_traits; - -}} // namespace boost::python::detail - -#endif // INDIRECT_TRAITS_DWA2002131_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/interlocked.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/interlocked.hpp deleted file mode 100644 index 1152f710..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/interlocked.hpp +++ /dev/null @@ -1,210 +0,0 @@ -#ifndef BOOST_DETAIL_INTERLOCKED_HPP_INCLUDED -#define BOOST_DETAIL_INTERLOCKED_HPP_INCLUDED - -// -// boost/detail/interlocked.hpp -// -// Copyright 2005 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// - -#include - -// MS compatible compilers support #pragma once -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -#if defined( BOOST_USE_WINDOWS_H ) - -# include - -# define BOOST_INTERLOCKED_INCREMENT InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD InterlockedExchangeAdd -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER InterlockedCompareExchangePointer -# define BOOST_INTERLOCKED_EXCHANGE_POINTER InterlockedExchangePointer - -#elif defined( BOOST_USE_INTRIN_H ) - -#include - -# define BOOST_INTERLOCKED_INCREMENT _InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT _InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE _InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE _InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD _InterlockedExchangeAdd - -# if defined(_M_IA64) || defined(_M_AMD64) || defined(__x86_64__) || defined(__x86_64) - -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER _InterlockedCompareExchangePointer -# define BOOST_INTERLOCKED_EXCHANGE_POINTER _InterlockedExchangePointer - -# else - -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest,exchange,compare) \ - ((void*)BOOST_INTERLOCKED_COMPARE_EXCHANGE((long volatile*)(dest),(long)(exchange),(long)(compare))) -# define BOOST_INTERLOCKED_EXCHANGE_POINTER(dest,exchange) \ - ((void*)BOOST_INTERLOCKED_EXCHANGE((long volatile*)(dest),(long)(exchange))) - -# endif - -#elif defined(_WIN32_WCE) - -#if _WIN32_WCE >= 0x600 - -extern "C" long __cdecl _InterlockedIncrement( long volatile * ); -extern "C" long __cdecl _InterlockedDecrement( long volatile * ); -extern "C" long __cdecl _InterlockedCompareExchange( long volatile *, long, long ); -extern "C" long __cdecl _InterlockedExchange( long volatile *, long ); -extern "C" long __cdecl _InterlockedExchangeAdd( long volatile *, long ); - -# define BOOST_INTERLOCKED_INCREMENT _InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT _InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE _InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE _InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD _InterlockedExchangeAdd - -#else -// under Windows CE we still have old-style Interlocked* functions - -extern "C" long __cdecl InterlockedIncrement( long* ); -extern "C" long __cdecl InterlockedDecrement( long* ); -extern "C" long __cdecl InterlockedCompareExchange( long*, long, long ); -extern "C" long __cdecl InterlockedExchange( long*, long ); -extern "C" long __cdecl InterlockedExchangeAdd( long*, long ); - -# define BOOST_INTERLOCKED_INCREMENT InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD InterlockedExchangeAdd - -#endif - -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest,exchange,compare) \ - ((void*)BOOST_INTERLOCKED_COMPARE_EXCHANGE((long*)(dest),(long)(exchange),(long)(compare))) -# define BOOST_INTERLOCKED_EXCHANGE_POINTER(dest,exchange) \ - ((void*)BOOST_INTERLOCKED_EXCHANGE((long*)(dest),(long)(exchange))) - -#elif defined( BOOST_MSVC ) || defined( BOOST_INTEL_WIN ) - -#if defined( BOOST_MSVC ) && BOOST_MSVC >= 1500 - -#include - -#elif defined( __CLRCALL_PURE_OR_CDECL ) - -extern "C" long __CLRCALL_PURE_OR_CDECL _InterlockedIncrement( long volatile * ); -extern "C" long __CLRCALL_PURE_OR_CDECL _InterlockedDecrement( long volatile * ); -extern "C" long __CLRCALL_PURE_OR_CDECL _InterlockedCompareExchange( long volatile *, long, long ); -extern "C" long __CLRCALL_PURE_OR_CDECL _InterlockedExchange( long volatile *, long ); -extern "C" long __CLRCALL_PURE_OR_CDECL _InterlockedExchangeAdd( long volatile *, long ); - -#else - -extern "C" long __cdecl _InterlockedIncrement( long volatile * ); -extern "C" long __cdecl _InterlockedDecrement( long volatile * ); -extern "C" long __cdecl _InterlockedCompareExchange( long volatile *, long, long ); -extern "C" long __cdecl _InterlockedExchange( long volatile *, long ); -extern "C" long __cdecl _InterlockedExchangeAdd( long volatile *, long ); - -#endif - -# if defined(_M_IA64) || defined(_M_AMD64) - -extern "C" void* __cdecl _InterlockedCompareExchangePointer( void* volatile *, void*, void* ); -extern "C" void* __cdecl _InterlockedExchangePointer( void* volatile *, void* ); - -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER _InterlockedCompareExchangePointer -# define BOOST_INTERLOCKED_EXCHANGE_POINTER _InterlockedExchangePointer - -# else - -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest,exchange,compare) \ - ((void*)BOOST_INTERLOCKED_COMPARE_EXCHANGE((long volatile*)(dest),(long)(exchange),(long)(compare))) -# define BOOST_INTERLOCKED_EXCHANGE_POINTER(dest,exchange) \ - ((void*)BOOST_INTERLOCKED_EXCHANGE((long volatile*)(dest),(long)(exchange))) - -# endif - -# define BOOST_INTERLOCKED_INCREMENT _InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT _InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE _InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE _InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD _InterlockedExchangeAdd - -// Unlike __MINGW64__, __MINGW64_VERSION_MAJOR is defined by MinGW-w64 for both 32 and 64-bit targets. -#elif defined(__MINGW64_VERSION_MAJOR) - -// MinGW-w64 provides intrin.h for both 32 and 64-bit targets. -#include - -# define BOOST_INTERLOCKED_INCREMENT _InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT _InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE _InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE _InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD _InterlockedExchangeAdd -# if defined(__x86_64__) || defined(__x86_64) -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER _InterlockedCompareExchangePointer -# define BOOST_INTERLOCKED_EXCHANGE_POINTER _InterlockedExchangePointer -# else -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest,exchange,compare) \ - ((void*)BOOST_INTERLOCKED_COMPARE_EXCHANGE((long volatile*)(dest),(long)(exchange),(long)(compare))) -# define BOOST_INTERLOCKED_EXCHANGE_POINTER(dest,exchange) \ - ((void*)BOOST_INTERLOCKED_EXCHANGE((long volatile*)(dest),(long)(exchange))) -# endif - -#elif defined( WIN32 ) || defined( _WIN32 ) || defined( __WIN32__ ) || defined( __CYGWIN__ ) - -#define BOOST_INTERLOCKED_IMPORT __declspec(dllimport) - -namespace boost -{ - -namespace detail -{ - -extern "C" BOOST_INTERLOCKED_IMPORT long __stdcall InterlockedIncrement( long volatile * ); -extern "C" BOOST_INTERLOCKED_IMPORT long __stdcall InterlockedDecrement( long volatile * ); -extern "C" BOOST_INTERLOCKED_IMPORT long __stdcall InterlockedCompareExchange( long volatile *, long, long ); -extern "C" BOOST_INTERLOCKED_IMPORT long __stdcall InterlockedExchange( long volatile *, long ); -extern "C" BOOST_INTERLOCKED_IMPORT long __stdcall InterlockedExchangeAdd( long volatile *, long ); - -# if defined(_M_IA64) || defined(_M_AMD64) -extern "C" BOOST_INTERLOCKED_IMPORT void* __stdcall InterlockedCompareExchangePointer( void* volatile *, void*, void* ); -extern "C" BOOST_INTERLOCKED_IMPORT void* __stdcall InterlockedExchangePointer( void* volatile *, void* ); -# endif - -} // namespace detail - -} // namespace boost - -# define BOOST_INTERLOCKED_INCREMENT ::boost::detail::InterlockedIncrement -# define BOOST_INTERLOCKED_DECREMENT ::boost::detail::InterlockedDecrement -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE ::boost::detail::InterlockedCompareExchange -# define BOOST_INTERLOCKED_EXCHANGE ::boost::detail::InterlockedExchange -# define BOOST_INTERLOCKED_EXCHANGE_ADD ::boost::detail::InterlockedExchangeAdd - -# if defined(_M_IA64) || defined(_M_AMD64) -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER ::boost::detail::InterlockedCompareExchangePointer -# define BOOST_INTERLOCKED_EXCHANGE_POINTER ::boost::detail::InterlockedExchangePointer -# else -# define BOOST_INTERLOCKED_COMPARE_EXCHANGE_POINTER(dest,exchange,compare) \ - ((void*)BOOST_INTERLOCKED_COMPARE_EXCHANGE((long volatile*)(dest),(long)(exchange),(long)(compare))) -# define BOOST_INTERLOCKED_EXCHANGE_POINTER(dest,exchange) \ - ((void*)BOOST_INTERLOCKED_EXCHANGE((long volatile*)(dest),(long)(exchange))) -# endif - -#else - -# error "Interlocked intrinsics not available" - -#endif - -#endif // #ifndef BOOST_DETAIL_INTERLOCKED_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/is_function_ref_tester.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/is_function_ref_tester.hpp deleted file mode 100644 index 8e7d1d77..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/is_function_ref_tester.hpp +++ /dev/null @@ -1,136 +0,0 @@ - -// (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, -// Aleksey Gurtovoy, Howard Hinnant & John Maddock 2000. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_PP_IS_ITERATING) - -///// header body - -#ifndef BOOST_DETAIL_IS_FUNCTION_REF_TESTER_HPP_INCLUDED -#define BOOST_DETAIL_IS_FUNCTION_REF_TESTER_HPP_INCLUDED - -#include "boost/type_traits/detail/yes_no_type.hpp" -#include "boost/type_traits/config.hpp" - -#if defined(BOOST_TT_PREPROCESSING_MODE) -# include "boost/preprocessor/iterate.hpp" -# include "boost/preprocessor/enum_params.hpp" -# include "boost/preprocessor/comma_if.hpp" -#endif - -namespace boost { -namespace detail { -namespace is_function_ref_tester_ { - -template -boost::type_traits::no_type BOOST_TT_DECL is_function_ref_tester(T& ...); - -#if !defined(BOOST_TT_PREPROCESSING_MODE) -// preprocessor-generated part, don't edit by hand! - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22,T23), int); - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22,T23,T24), int); - -#else - -#define BOOST_PP_ITERATION_PARAMS_1 \ - (3, (0, 25, "boost/detail/is_function_ref_tester.hpp")) -#include BOOST_PP_ITERATE() - -#endif // BOOST_TT_PREPROCESSING_MODE - -} // namespace detail -} // namespace python -} // namespace boost - -#endif // BOOST_DETAIL_IS_FUNCTION_REF_TESTER_HPP_INCLUDED - -///// iteration - -#else -#define i BOOST_PP_FRAME_ITERATION(1) - -template -boost::type_traits::yes_type is_function_ref_tester(R (&)(BOOST_PP_ENUM_PARAMS(i,T)), int); - -#undef i -#endif // BOOST_PP_IS_ITERATING - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/is_incrementable.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/is_incrementable.hpp deleted file mode 100644 index e7ef9dc6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/is_incrementable.hpp +++ /dev/null @@ -1,134 +0,0 @@ -// Copyright David Abrahams 2004. Use, modification and distribution is -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef IS_INCREMENTABLE_DWA200415_HPP -# define IS_INCREMENTABLE_DWA200415_HPP - -# include -# include -# include -# include -# include - -// Must be the last include -# include - -namespace boost { namespace detail { - -// is_incrementable metafunction -// -// Requires: Given x of type T&, if the expression ++x is well-formed -// it must have complete type; otherwise, it must neither be ambiguous -// nor violate access. - -// This namespace ensures that ADL doesn't mess things up. -namespace is_incrementable_ -{ - // a type returned from operator++ when no increment is found in the - // type's own namespace - struct tag {}; - - // any soaks up implicit conversions and makes the following - // operator++ less-preferred than any other such operator that - // might be found via ADL. - struct any { template any(T const&); }; - - // This is a last-resort operator++ for when none other is found -# if BOOST_WORKAROUND(__GNUC__, == 4) && __GNUC_MINOR__ == 0 && __GNUC_PATCHLEVEL__ == 2 - -} - -namespace is_incrementable_2 -{ - is_incrementable_::tag operator++(is_incrementable_::any const&); - is_incrementable_::tag operator++(is_incrementable_::any const&,int); -} -using namespace is_incrementable_2; - -namespace is_incrementable_ -{ - -# else - - tag operator++(any const&); - tag operator++(any const&,int); - -# endif - -# if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3202)) \ - || BOOST_WORKAROUND(BOOST_MSVC, <= 1300) -# define BOOST_comma(a,b) (a) -# else - // In case an operator++ is found that returns void, we'll use ++x,0 - tag operator,(tag,int); -# define BOOST_comma(a,b) (a,b) -# endif - -# if defined(BOOST_MSVC) -# pragma warning(push) -# pragma warning(disable:4913) // Warning about operator, -# endif - - // two check overloads help us identify which operator++ was picked - char (& check_(tag) )[2]; - - template - char check_(T const&); - - - template - struct impl - { - static typename boost::remove_cv::type& x; - - BOOST_STATIC_CONSTANT( - bool - , value = sizeof(is_incrementable_::check_(BOOST_comma(++x,0))) == 1 - ); - }; - - template - struct postfix_impl - { - static typename boost::remove_cv::type& x; - - BOOST_STATIC_CONSTANT( - bool - , value = sizeof(is_incrementable_::check_(BOOST_comma(x++,0))) == 1 - ); - }; - -# if defined(BOOST_MSVC) -# pragma warning(pop) -# endif - -} - -# undef BOOST_comma - -template -struct is_incrementable -BOOST_TT_AUX_BOOL_C_BASE(::boost::detail::is_incrementable_::impl::value) -{ - BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL(::boost::detail::is_incrementable_::impl::value) - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_incrementable,(T)) -}; - -template -struct is_postfix_incrementable -BOOST_TT_AUX_BOOL_C_BASE(::boost::detail::is_incrementable_::impl::value) -{ - BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL(::boost::detail::is_incrementable_::postfix_impl::value) - BOOST_MPL_AUX_LAMBDA_SUPPORT(1,is_postfix_incrementable,(T)) -}; - -} // namespace detail - -BOOST_TT_AUX_TEMPLATE_ARITY_SPEC(1, ::boost::detail::is_incrementable) -BOOST_TT_AUX_TEMPLATE_ARITY_SPEC(1, ::boost::detail::is_postfix_incrementable) - -} // namespace boost - -# include - -#endif // IS_INCREMENTABLE_DWA200415_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/is_xxx.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/is_xxx.hpp deleted file mode 100644 index cb64fb32..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/is_xxx.hpp +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright David Abrahams 2005. Distributed under the Boost -// Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#ifndef BOOST_DETAIL_IS_XXX_DWA20051011_HPP -# define BOOST_DETAIL_IS_XXX_DWA20051011_HPP - -# include -# include -# include - -# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -# include -# include - -# define BOOST_DETAIL_IS_XXX_DEF(name, qualified_name, nargs) \ -template \ -struct is_##name \ -{ \ - typedef char yes; \ - typedef char (&no)[2]; \ - \ - static typename add_reference::type dummy; \ - \ - struct helpers \ - { \ - template < BOOST_PP_ENUM_PARAMS_Z(1, nargs, class U) > \ - static yes test( \ - qualified_name< BOOST_PP_ENUM_PARAMS_Z(1, nargs, U) >&, int \ - ); \ - \ - template \ - static no test(U&, ...); \ - }; \ - \ - BOOST_STATIC_CONSTANT( \ - bool, value \ - = !is_reference::value \ - & (sizeof(helpers::test(dummy, 0)) == sizeof(yes))); \ - \ - typedef mpl::bool_ type; \ -}; - -# else - -# define BOOST_DETAIL_IS_XXX_DEF(name, qualified_name, nargs) \ -template \ -struct is_##name : mpl::false_ \ -{ \ -}; \ - \ -template < BOOST_PP_ENUM_PARAMS_Z(1, nargs, class T) > \ -struct is_##name< \ - qualified_name< BOOST_PP_ENUM_PARAMS_Z(1, nargs, T) > \ -> \ - : mpl::true_ \ -{ \ -}; - -# endif - -#endif // BOOST_DETAIL_IS_XXX_DWA20051011_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/iterator.hpp deleted file mode 100644 index 5bb9c626..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/iterator.hpp +++ /dev/null @@ -1,494 +0,0 @@ -// (C) Copyright David Abrahams 2002. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Boost versions of -// -// std::iterator_traits<>::iterator_category -// std::iterator_traits<>::difference_type -// std::distance() -// -// ...for all compilers and iterators -// -// Additionally, if X is a pointer -// std::iterator_traits::pointer - -// Otherwise, if partial specialization is supported or X is not a pointer -// std::iterator_traits::value_type -// std::iterator_traits::pointer -// std::iterator_traits::reference -// -// See http://www.boost.org for most recent version including documentation. - -// Revision History -// 04 Mar 2001 - More attempted fixes for Intel C++ (David Abrahams) -// 03 Mar 2001 - Put all implementation into namespace -// boost::detail::iterator_traits_. Some progress made on fixes -// for Intel compiler. (David Abrahams) -// 02 Mar 2001 - Changed BOOST_MSVC to BOOST_MSVC_STD_ITERATOR in a few -// places. (Jeremy Siek) -// 19 Feb 2001 - Improved workarounds for stock MSVC6; use yes_type and -// no_type from type_traits.hpp; stopped trying to remove_cv -// before detecting is_pointer, in honor of the new type_traits -// semantics. (David Abrahams) -// 13 Feb 2001 - Make it work with nearly all standard-conforming iterators -// under raw VC6. The one category remaining which will fail is -// that of iterators derived from std::iterator but not -// boost::iterator and which redefine difference_type. -// 11 Feb 2001 - Clean away code which can never be used (David Abrahams) -// 09 Feb 2001 - Always have a definition for each traits member, even if it -// can't be properly deduced. These will be incomplete types in -// some cases (undefined), but it helps suppress MSVC errors -// elsewhere (David Abrahams) -// 07 Feb 2001 - Support for more of the traits members where possible, making -// this useful as a replacement for std::iterator_traits when -// used as a default template parameter. -// 06 Feb 2001 - Removed useless #includes of standard library headers -// (David Abrahams) - -#ifndef ITERATOR_DWA122600_HPP_ -# define ITERATOR_DWA122600_HPP_ - -# include -# include - -// STLPort 4.0 and betas have a bug when debugging is enabled and there is no -// partial specialization: instead of an iterator_category typedef, the standard -// container iterators have _Iterator_category. -// -// Also, whether debugging is enabled or not, there is a broken specialization -// of std::iterator which has no -// typedefs but iterator_category. -# if defined(__SGI_STL_PORT) - -# if (__SGI_STL_PORT <= 0x410) && !defined(__STL_CLASS_PARTIAL_SPECIALIZATION) && defined(__STL_DEBUG) -# define BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF -# endif - -# define BOOST_BAD_OUTPUT_ITERATOR_SPECIALIZATION - -# endif // STLPort <= 4.1b4 && no partial specialization - -# if !defined(BOOST_NO_STD_ITERATOR_TRAITS) \ - && !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_MSVC_STD_ITERATOR) - -namespace boost { namespace detail { - -// Define a new template so it can be specialized -template -struct iterator_traits - : std::iterator_traits -{}; -using std::distance; - -}} // namespace boost::detail - -# else - -# if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - && !defined(BOOST_MSVC_STD_ITERATOR) - -// This is the case where everything conforms except BOOST_NO_STD_ITERATOR_TRAITS - -namespace boost { namespace detail { - -// Rogue Wave Standard Library fools itself into thinking partial -// specialization is missing on some platforms (e.g. Sun), so fails to -// supply iterator_traits! -template -struct iterator_traits -{ - typedef typename Iterator::value_type value_type; - typedef typename Iterator::reference reference; - typedef typename Iterator::pointer pointer; - typedef typename Iterator::difference_type difference_type; - typedef typename Iterator::iterator_category iterator_category; -}; - -template -struct iterator_traits -{ - typedef T value_type; - typedef T& reference; - typedef T* pointer; - typedef std::ptrdiff_t difference_type; - typedef std::random_access_iterator_tag iterator_category; -}; - -template -struct iterator_traits -{ - typedef T value_type; - typedef T const& reference; - typedef T const* pointer; - typedef std::ptrdiff_t difference_type; - typedef std::random_access_iterator_tag iterator_category; -}; - -}} // namespace boost::detail - -# else - -# include -# include -# include - -# ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -# include -# include -# endif -# ifdef BOOST_BAD_OUTPUT_ITERATOR_SPECIALIZATION -# include -# endif - -# include -# include -# include - -// should be the last #include -# include "boost/type_traits/detail/bool_trait_def.hpp" - -namespace boost { namespace detail { - -BOOST_MPL_HAS_XXX_TRAIT_DEF(value_type) -BOOST_MPL_HAS_XXX_TRAIT_DEF(reference) -BOOST_MPL_HAS_XXX_TRAIT_DEF(pointer) -BOOST_MPL_HAS_XXX_TRAIT_DEF(difference_type) -BOOST_MPL_HAS_XXX_TRAIT_DEF(iterator_category) - -// is_mutable_iterator -- -// -// A metafunction returning true iff T is a mutable iterator type -// with a nested value_type. Will only work portably with iterators -// whose operator* returns a reference, but that seems to be OK for -// the iterators supplied by Dinkumware. Some input iterators may -// compile-time if they arrive here, and if the compiler is strict -// about not taking the address of an rvalue. - -// This one detects ordinary mutable iterators - the result of -// operator* is convertible to the value_type. -template -type_traits::yes_type is_mutable_iterator_helper(T const*, BOOST_DEDUCED_TYPENAME T::value_type*); - -// Since you can't take the address of an rvalue, the guts of -// is_mutable_iterator_impl will fail if we use &*t directly. This -// makes sure we can still work with non-lvalue iterators. -template T* mutable_iterator_lvalue_helper(T& x); -int mutable_iterator_lvalue_helper(...); - - -// This one detects output iterators such as ostream_iterator which -// return references to themselves. -template -type_traits::yes_type is_mutable_iterator_helper(T const*, T const*); - -type_traits::no_type is_mutable_iterator_helper(...); - -template -struct is_mutable_iterator_impl -{ - static T t; - - BOOST_STATIC_CONSTANT( - bool, value = sizeof( - detail::is_mutable_iterator_helper( - (T*)0 - , mutable_iterator_lvalue_helper(*t) // like &*t - )) - == sizeof(type_traits::yes_type) - ); -}; - -BOOST_TT_AUX_BOOL_TRAIT_DEF1( - is_mutable_iterator,T,::boost::detail::is_mutable_iterator_impl::value) - - -// is_full_iterator_traits -- -// -// A metafunction returning true iff T has all the requisite nested -// types to satisfy the requirements for a fully-conforming -// iterator_traits implementation. -template -struct is_full_iterator_traits_impl -{ - enum { value = - has_value_type::value - & has_reference::value - & has_pointer::value - & has_difference_type::value - & has_iterator_category::value - }; -}; - -BOOST_TT_AUX_BOOL_TRAIT_DEF1( - is_full_iterator_traits,T,::boost::detail::is_full_iterator_traits_impl::value) - - -# ifdef BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF -BOOST_MPL_HAS_XXX_TRAIT_DEF(_Iterator_category) - -// is_stlport_40_debug_iterator -- -// -// A metafunction returning true iff T has all the requisite nested -// types to satisfy the requirements of an STLPort 4.0 debug iterator -// iterator_traits implementation. -template -struct is_stlport_40_debug_iterator_impl -{ - enum { value = - has_value_type::value - & has_reference::value - & has_pointer::value - & has_difference_type::value - & has__Iterator_category::value - }; -}; - -BOOST_TT_AUX_BOOL_TRAIT_DEF1( - is_stlport_40_debug_iterator,T,::boost::detail::is_stlport_40_debug_iterator_impl::value) - -template -struct stlport_40_debug_iterator_traits -{ - typedef typename T::value_type value_type; - typedef typename T::reference reference; - typedef typename T::pointer pointer; - typedef typename T::difference_type difference_type; - typedef typename T::_Iterator_category iterator_category; -}; -# endif // BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF - -template struct pointer_iterator_traits; - -# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -template -struct pointer_iterator_traits -{ - typedef typename remove_const::type value_type; - typedef T* pointer; - typedef T& reference; - typedef std::random_access_iterator_tag iterator_category; - typedef std::ptrdiff_t difference_type; -}; -# else - -// In case of no template partial specialization, and if T is a -// pointer, iterator_traits::value_type can still be computed. For -// some basic types, remove_pointer is manually defined in -// type_traits/broken_compiler_spec.hpp. For others, do it yourself. - -template class please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee; - -template -struct pointer_value_type - : mpl::if_< - is_same::type> - , please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee

- , typename remove_const< - typename remove_pointer

::type - >::type - > -{ -}; - - -template -struct pointer_reference - : mpl::if_< - is_same::type> - , please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee

- , typename remove_pointer

::type provides the type of *p. -// -// http://www.boost.org/libs/iterator/doc/pointee.html -// - -# include -# include -# include -# include -# include - -namespace boost { - -namespace detail -{ - template - struct smart_ptr_reference - { - typedef typename boost::pointee

::type& type; - }; -} - -template -struct indirect_reference - : mpl::eval_if< - detail::is_incrementable

- , iterator_reference

- , detail::smart_ptr_reference

- > -{ -}; - -} // namespace boost - -#endif // INDIRECT_REFERENCE_DWA200415_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/integer.hpp b/third_party/ycmd/cpp/BoostParts/boost/integer.hpp deleted file mode 100644 index 35a1e109..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/integer.hpp +++ /dev/null @@ -1,261 +0,0 @@ -// boost integer.hpp header file -------------------------------------------// - -// Copyright Beman Dawes and Daryle Walker 1999. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/integer for documentation. - -// Revision History -// 22 Sep 01 Added value-based integer templates. (Daryle Walker) -// 01 Apr 01 Modified to use new header. (John Maddock) -// 30 Jul 00 Add typename syntax fix (Jens Maurer) -// 28 Aug 99 Initial version - -#ifndef BOOST_INTEGER_HPP -#define BOOST_INTEGER_HPP - -#include // self include - -#include // for boost::::boost::integer_traits -#include // for ::std::numeric_limits -#include // for boost::int64_t and BOOST_NO_INTEGRAL_INT64_T -#include - -// -// We simply cannot include this header on gcc without getting copious warnings of the kind: -// -// boost/integer.hpp:77:30: warning: use of C99 long long integer constant -// -// And yet there is no other reasonable implementation, so we declare this a system header -// to suppress these warnings. -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -#pragma GCC system_header -#endif - -namespace boost -{ - - // Helper templates ------------------------------------------------------// - - // fast integers from least integers - // int_fast_t<> works correctly for unsigned too, in spite of the name. - template< typename LeastInt > - struct int_fast_t - { - typedef LeastInt fast; - typedef fast type; - }; // imps may specialize - - namespace detail{ - - // convert category to type - template< int Category > struct int_least_helper {}; // default is empty - template< int Category > struct uint_least_helper {}; // default is empty - - // specializatons: 1=long, 2=int, 3=short, 4=signed char, - // 6=unsigned long, 7=unsigned int, 8=unsigned short, 9=unsigned char - // no specializations for 0 and 5: requests for a type > long are in error -#ifdef BOOST_HAS_LONG_LONG - template<> struct int_least_helper<1> { typedef boost::long_long_type least; }; -#elif defined(BOOST_HAS_MS_INT64) - template<> struct int_least_helper<1> { typedef __int64 least; }; -#endif - template<> struct int_least_helper<2> { typedef long least; }; - template<> struct int_least_helper<3> { typedef int least; }; - template<> struct int_least_helper<4> { typedef short least; }; - template<> struct int_least_helper<5> { typedef signed char least; }; -#ifdef BOOST_HAS_LONG_LONG - template<> struct uint_least_helper<1> { typedef boost::ulong_long_type least; }; -#elif defined(BOOST_HAS_MS_INT64) - template<> struct uint_least_helper<1> { typedef unsigned __int64 least; }; -#endif - template<> struct uint_least_helper<2> { typedef unsigned long least; }; - template<> struct uint_least_helper<3> { typedef unsigned int least; }; - template<> struct uint_least_helper<4> { typedef unsigned short least; }; - template<> struct uint_least_helper<5> { typedef unsigned char least; }; - - template - struct exact_signed_base_helper{}; - template - struct exact_unsigned_base_helper{}; - - template <> struct exact_signed_base_helper { typedef signed char exact; }; - template <> struct exact_unsigned_base_helper { typedef unsigned char exact; }; -#if USHRT_MAX != UCHAR_MAX - template <> struct exact_signed_base_helper { typedef short exact; }; - template <> struct exact_unsigned_base_helper { typedef unsigned short exact; }; -#endif -#if UINT_MAX != USHRT_MAX - template <> struct exact_signed_base_helper { typedef int exact; }; - template <> struct exact_unsigned_base_helper { typedef unsigned int exact; }; -#endif -#if ULONG_MAX != UINT_MAX - template <> struct exact_signed_base_helper { typedef long exact; }; - template <> struct exact_unsigned_base_helper { typedef unsigned long exact; }; -#endif -#if defined(BOOST_HAS_LONG_LONG) &&\ - ((defined(ULLONG_MAX) && (ULLONG_MAX != ULONG_MAX)) ||\ - (defined(ULONG_LONG_MAX) && (ULONG_LONG_MAX != ULONG_MAX)) ||\ - (defined(ULONGLONG_MAX) && (ULONGLONG_MAX != ULONG_MAX)) ||\ - (defined(_ULLONG_MAX) && (_ULLONG_MAX != ULONG_MAX))) - template <> struct exact_signed_base_helper { typedef boost::long_long_type exact; }; - template <> struct exact_unsigned_base_helper { typedef boost::ulong_long_type exact; }; -#endif - - - } // namespace detail - - // integer templates specifying number of bits ---------------------------// - - // signed - template< int Bits > // bits (including sign) required - struct int_t : public detail::exact_signed_base_helper - { - BOOST_STATIC_ASSERT_MSG(Bits <= (int)(sizeof(boost::intmax_t) * CHAR_BIT), - "No suitable signed integer type with the requested number of bits is available."); - typedef typename detail::int_least_helper - < -#ifdef BOOST_HAS_LONG_LONG - (Bits <= (int)(sizeof(boost::long_long_type) * CHAR_BIT)) + -#else - 1 + -#endif - (Bits-1 <= ::std::numeric_limits::digits) + - (Bits-1 <= ::std::numeric_limits::digits) + - (Bits-1 <= ::std::numeric_limits::digits) + - (Bits-1 <= ::std::numeric_limits::digits) - >::least least; - typedef typename int_fast_t::type fast; - }; - - // unsigned - template< int Bits > // bits required - struct uint_t : public detail::exact_unsigned_base_helper - { - BOOST_STATIC_ASSERT_MSG(Bits <= (int)(sizeof(boost::uintmax_t) * CHAR_BIT), - "No suitable unsigned integer type with the requested number of bits is available."); -#if (defined(__BORLANDC__) || defined(__CODEGEAR__)) && defined(BOOST_NO_INTEGRAL_INT64_T) - // It's really not clear why this workaround should be needed... shrug I guess! JM - BOOST_STATIC_CONSTANT(int, s = - 6 + - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits)); - typedef typename detail::int_least_helper< ::boost::uint_t::s>::least least; -#else - typedef typename detail::uint_least_helper - < -#ifdef BOOST_HAS_LONG_LONG - (Bits <= (int)(sizeof(boost::long_long_type) * CHAR_BIT)) + -#else - 1 + -#endif - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits) + - (Bits <= ::std::numeric_limits::digits) - >::least least; -#endif - typedef typename int_fast_t::type fast; - // int_fast_t<> works correctly for unsigned too, in spite of the name. - }; - - // integer templates specifying extreme value ----------------------------// - - // signed -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::long_long_type MaxValue > // maximum value to require support -#else - template< long MaxValue > // maximum value to require support -#endif - struct int_max_value_t - { - typedef typename detail::int_least_helper - < -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - (MaxValue <= ::boost::integer_traits::const_max) + -#else - 1 + -#endif - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) - >::least least; - typedef typename int_fast_t::type fast; - }; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::long_long_type MinValue > // minimum value to require support -#else - template< long MinValue > // minimum value to require support -#endif - struct int_min_value_t - { - typedef typename detail::int_least_helper - < -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - (MinValue >= ::boost::integer_traits::const_min) + -#else - 1 + -#endif - (MinValue >= ::boost::integer_traits::const_min) + - (MinValue >= ::boost::integer_traits::const_min) + - (MinValue >= ::boost::integer_traits::const_min) + - (MinValue >= ::boost::integer_traits::const_min) - >::least least; - typedef typename int_fast_t::type fast; - }; - - // unsigned -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::ulong_long_type MaxValue > // minimum value to require support -#else - template< unsigned long MaxValue > // minimum value to require support -#endif - struct uint_value_t - { -#if (defined(__BORLANDC__) || defined(__CODEGEAR__)) - // It's really not clear why this workaround should be needed... shrug I guess! JM -#if defined(BOOST_NO_INTEGRAL_INT64_T) - BOOST_STATIC_CONSTANT(unsigned, which = - 1 + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max)); - typedef typename detail::int_least_helper< ::boost::uint_value_t::which>::least least; -#else // BOOST_NO_INTEGRAL_INT64_T - BOOST_STATIC_CONSTANT(unsigned, which = - 1 + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max)); - typedef typename detail::uint_least_helper< ::boost::uint_value_t::which>::least least; -#endif // BOOST_NO_INTEGRAL_INT64_T -#else - typedef typename detail::uint_least_helper - < -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - (MaxValue <= ::boost::integer_traits::const_max) + -#else - 1 + -#endif - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) + - (MaxValue <= ::boost::integer_traits::const_max) - >::least least; -#endif - typedef typename int_fast_t::type fast; - }; - - -} // namespace boost - -#endif // BOOST_INTEGER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/integer/static_log2.hpp b/third_party/ycmd/cpp/BoostParts/boost/integer/static_log2.hpp deleted file mode 100644 index 56c7a001..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/integer/static_log2.hpp +++ /dev/null @@ -1,127 +0,0 @@ -// -------------- Boost static_log2.hpp header file ----------------------- // -// -// Copyright (C) 2001 Daryle Walker. -// Copyright (C) 2003 Vesa Karvonen. -// Copyright (C) 2003 Gennaro Prota. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// --------------------------------------------------- -// See http://www.boost.org/libs/integer for documentation. -// ------------------------------------------------------------------------- // - - -#ifndef BOOST_INTEGER_STATIC_LOG2_HPP -#define BOOST_INTEGER_STATIC_LOG2_HPP - -#include "boost/integer_fwd.hpp" // for boost::intmax_t - -namespace boost { - - namespace detail { - - namespace static_log2_impl { - - // choose_initial_n<> - // - // Recursively doubles its integer argument, until it - // becomes >= of the "width" (C99, 6.2.6.2p4) of - // static_log2_argument_type. - // - // Used to get the maximum power of two less then the width. - // - // Example: if on your platform argument_type has 48 value - // bits it yields n=32. - // - // It's easy to prove that, starting from such a value - // of n, the core algorithm works correctly for any width - // of static_log2_argument_type and that recursion always - // terminates with x = 1 and n = 0 (see the algorithm's - // invariant). - - typedef boost::static_log2_argument_type argument_type; - typedef boost::static_log2_result_type result_type; - - template - struct choose_initial_n { - - BOOST_STATIC_CONSTANT(bool, c = (argument_type(1) << n << n) != 0); - BOOST_STATIC_CONSTANT( - result_type, - value = !c*n + choose_initial_n<2*c*n>::value - ); - - }; - - template <> - struct choose_initial_n<0> { - BOOST_STATIC_CONSTANT(result_type, value = 0); - }; - - - - // start computing from n_zero - must be a power of two - const result_type n_zero = 16; - const result_type initial_n = choose_initial_n::value; - - // static_log2_impl<> - // - // * Invariant: - // 2n - // 1 <= x && x < 2 at the start of each recursion - // (see also choose_initial_n<>) - // - // * Type requirements: - // - // argument_type maybe any unsigned type with at least n_zero + 1 - // value bits. (Note: If larger types will be standardized -e.g. - // unsigned long long- then the argument_type typedef can be - // changed without affecting the rest of the code.) - // - - template - struct static_log2_impl { - - BOOST_STATIC_CONSTANT(bool, c = (x >> n) > 0); // x >= 2**n ? - BOOST_STATIC_CONSTANT( - result_type, - value = c*n + (static_log2_impl< (x>>c*n), n/2 >::value) - ); - - }; - - template <> - struct static_log2_impl<1, 0> { - BOOST_STATIC_CONSTANT(result_type, value = 0); - }; - - } - } // detail - - - - // -------------------------------------- - // static_log2 - // ---------------------------------------- - - template - struct static_log2 { - - BOOST_STATIC_CONSTANT( - static_log2_result_type, - value = detail::static_log2_impl::static_log2_impl::value - ); - - }; - - - template <> - struct static_log2<0> { }; - -} - - - -#endif // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/integer_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/integer_fwd.hpp deleted file mode 100644 index 20eff2bc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/integer_fwd.hpp +++ /dev/null @@ -1,164 +0,0 @@ -// Boost integer_fwd.hpp header file ---------------------------------------// - -// (C) Copyright Dave Abrahams and Daryle Walker 2001. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/integer for documentation. - -#ifndef BOOST_INTEGER_FWD_HPP -#define BOOST_INTEGER_FWD_HPP - -#include // for UCHAR_MAX, etc. -#include // for std::size_t - -#include // for BOOST_NO_INTRINSIC_WCHAR_T -#include // for std::numeric_limits -#include // For intmax_t - - -namespace boost -{ - -#ifdef BOOST_NO_INTEGRAL_INT64_T - typedef unsigned long static_log2_argument_type; - typedef int static_log2_result_type; - typedef long static_min_max_signed_type; - typedef unsigned long static_min_max_unsigned_type; -#else - typedef boost::uintmax_t static_min_max_unsigned_type; - typedef boost::intmax_t static_min_max_signed_type; - typedef boost::uintmax_t static_log2_argument_type; - typedef int static_log2_result_type; -#endif - -// From ------------------------------------------------// - -// Only has typedefs or using statements, with #conditionals - - -// From -----------------------------------------// - -template < class T > - class integer_traits; - -template < > - class integer_traits< bool >; - -template < > - class integer_traits< char >; - -template < > - class integer_traits< signed char >; - -template < > - class integer_traits< unsigned char >; - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template < > - class integer_traits< wchar_t >; -#endif - -template < > - class integer_traits< short >; - -template < > - class integer_traits< unsigned short >; - -template < > - class integer_traits< int >; - -template < > - class integer_traits< unsigned int >; - -template < > - class integer_traits< long >; - -template < > - class integer_traits< unsigned long >; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && !defined(BOOST_NO_INT64_T) && defined(BOOST_HAS_LONG_LONG) -template < > -class integer_traits< ::boost::long_long_type>; - -template < > -class integer_traits< ::boost::ulong_long_type >; -#elif !defined(BOOST_NO_INTEGRAL_INT64_T) && !defined(BOOST_NO_INT64_T) && defined(BOOST_HAS_MS_INT64) -template < > -class integer_traits<__int64>; - -template < > -class integer_traits; -#endif - - -// From ------------------------------------------------// - -template < typename LeastInt > - struct int_fast_t; - -template< int Bits > - struct int_t; - -template< int Bits > - struct uint_t; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::long_long_type MaxValue > // maximum value to require support -#else - template< long MaxValue > // maximum value to require support -#endif - struct int_max_value_t; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::long_long_type MinValue > // minimum value to require support -#else - template< long MinValue > // minimum value to require support -#endif - struct int_min_value_t; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && defined(BOOST_HAS_LONG_LONG) - template< boost::ulong_long_type MaxValue > // maximum value to require support -#else - template< unsigned long MaxValue > // maximum value to require support -#endif - struct uint_value_t; - - -// From -----------------------------------// - -template < std::size_t Bit > - struct high_bit_mask_t; - -template < std::size_t Bits > - struct low_bits_mask_t; - -template < > - struct low_bits_mask_t< ::std::numeric_limits::digits >; - -// From ------------------------------------// - -template - struct static_log2; - -template <> struct static_log2<0u>; - - -// From ---------------------------------// - -template - struct static_signed_min; - -template - struct static_signed_max; - -template - struct static_unsigned_min; - -template - struct static_unsigned_max; - -} // namespace boost - - -#endif // BOOST_INTEGER_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/integer_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/integer_traits.hpp deleted file mode 100644 index d896e46e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/integer_traits.hpp +++ /dev/null @@ -1,261 +0,0 @@ -/* boost integer_traits.hpp header file - * - * Copyright Jens Maurer 2000 - * Distributed under the Boost Software License, Version 1.0. (See - * accompanying file LICENSE_1_0.txt or copy at - * http://www.boost.org/LICENSE_1_0.txt) - * - * $Id: integer_traits.hpp 85813 2013-09-21 20:17:00Z jewillco $ - * - * Idea by Beman Dawes, Ed Brey, Steve Cleary, and Nathan Myers - */ - -// See http://www.boost.org/libs/integer for documentation. - - -#ifndef BOOST_INTEGER_TRAITS_HPP -#define BOOST_INTEGER_TRAITS_HPP - -#include -#include - -// These are an implementation detail and not part of the interface -#include -// we need wchar.h for WCHAR_MAX/MIN but not all platforms provide it, -// and some may have but not ... -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) && (!defined(BOOST_NO_CWCHAR) || defined(sun) || defined(__sun) || defined(__QNX__)) -#include -#endif - -// -// We simply cannot include this header on gcc without getting copious warnings of the kind: -// -// ../../../boost/integer_traits.hpp:164:66: warning: use of C99 long long integer constant -// -// And yet there is no other reasonable implementation, so we declare this a system header -// to suppress these warnings. -// -#if defined(__GNUC__) && (__GNUC__ >= 4) -#pragma GCC system_header -#endif - -namespace boost { -template -class integer_traits : public std::numeric_limits -{ -public: - BOOST_STATIC_CONSTANT(bool, is_integral = false); -}; - -namespace detail { -template -class integer_traits_base -{ -public: - BOOST_STATIC_CONSTANT(bool, is_integral = true); - BOOST_STATIC_CONSTANT(T, const_min = min_val); - BOOST_STATIC_CONSTANT(T, const_max = max_val); -}; - -#ifndef BOOST_NO_INCLASS_MEMBER_INITIALIZATION -// A definition is required even for integral static constants -template -const bool integer_traits_base::is_integral; - -template -const T integer_traits_base::const_min; - -template -const T integer_traits_base::const_max; -#endif - -} // namespace detail - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -#ifndef BOOST_NO_INTRINSIC_WCHAR_T -template<> -class integer_traits - : public std::numeric_limits, - // Don't trust WCHAR_MIN and WCHAR_MAX with Mac OS X's native - // library: they are wrong! -#if defined(WCHAR_MIN) && defined(WCHAR_MAX) && !defined(__APPLE__) - public detail::integer_traits_base -#elif defined(__BORLANDC__) || defined(__CYGWIN__) || defined(__MINGW32__) || (defined(__BEOS__) && defined(__GNUC__)) - // No WCHAR_MIN and WCHAR_MAX, whar_t is short and unsigned: - public detail::integer_traits_base -#elif (defined(__sgi) && (!defined(__SGI_STL_PORT) || __SGI_STL_PORT < 0x400))\ - || (defined __APPLE__)\ - || (defined(__OpenBSD__) && defined(__GNUC__))\ - || (defined(__NetBSD__) && defined(__GNUC__))\ - || (defined(__FreeBSD__) && defined(__GNUC__))\ - || (defined(__DragonFly__) && defined(__GNUC__))\ - || (defined(__hpux) && defined(__GNUC__) && (__GNUC__ == 3) && !defined(__SGI_STL_PORT)) - // No WCHAR_MIN and WCHAR_MAX, wchar_t has the same range as int. - // - SGI MIPSpro with native library - // - gcc 3.x on HP-UX - // - Mac OS X with native library - // - gcc on FreeBSD, OpenBSD and NetBSD - public detail::integer_traits_base -#elif defined(__hpux) && defined(__GNUC__) && (__GNUC__ == 2) && !defined(__SGI_STL_PORT) - // No WCHAR_MIN and WCHAR_MAX, wchar_t has the same range as unsigned int. - // - gcc 2.95.x on HP-UX - // (also, std::numeric_limits appears to return the wrong values). - public detail::integer_traits_base -#else -#error No WCHAR_MIN and WCHAR_MAX present, please adjust integer_traits<> for your compiler. -#endif -{ }; -#endif // BOOST_NO_INTRINSIC_WCHAR_T - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -template<> -class integer_traits - : public std::numeric_limits, - public detail::integer_traits_base -{ }; - -#if !defined(BOOST_NO_INTEGRAL_INT64_T) && !defined(BOOST_NO_INT64_T) -#if defined(ULLONG_MAX) && defined(BOOST_HAS_LONG_LONG) - -template<> -class integer_traits< ::boost::long_long_type> - : public std::numeric_limits< ::boost::long_long_type>, - public detail::integer_traits_base< ::boost::long_long_type, LLONG_MIN, LLONG_MAX> -{ }; - -template<> -class integer_traits< ::boost::ulong_long_type> - : public std::numeric_limits< ::boost::ulong_long_type>, - public detail::integer_traits_base< ::boost::ulong_long_type, 0, ULLONG_MAX> -{ }; - -#elif defined(ULONG_LONG_MAX) && defined(BOOST_HAS_LONG_LONG) - -template<> -class integer_traits< ::boost::long_long_type> : public std::numeric_limits< ::boost::long_long_type>, public detail::integer_traits_base< ::boost::long_long_type, LONG_LONG_MIN, LONG_LONG_MAX>{ }; -template<> -class integer_traits< ::boost::ulong_long_type> - : public std::numeric_limits< ::boost::ulong_long_type>, - public detail::integer_traits_base< ::boost::ulong_long_type, 0, ULONG_LONG_MAX> -{ }; - -#elif defined(ULONGLONG_MAX) && defined(BOOST_HAS_LONG_LONG) - -template<> -class integer_traits< ::boost::long_long_type> - : public std::numeric_limits< ::boost::long_long_type>, - public detail::integer_traits_base< ::boost::long_long_type, LONGLONG_MIN, LONGLONG_MAX> -{ }; - -template<> -class integer_traits< ::boost::ulong_long_type> - : public std::numeric_limits< ::boost::ulong_long_type>, - public detail::integer_traits_base< ::boost::ulong_long_type, 0, ULONGLONG_MAX> -{ }; - -#elif defined(_LLONG_MAX) && defined(_C2) && defined(BOOST_HAS_LONG_LONG) - -template<> -class integer_traits< ::boost::long_long_type> - : public std::numeric_limits< ::boost::long_long_type>, - public detail::integer_traits_base< ::boost::long_long_type, -_LLONG_MAX - _C2, _LLONG_MAX> -{ }; - -template<> -class integer_traits< ::boost::ulong_long_type> - : public std::numeric_limits< ::boost::ulong_long_type>, - public detail::integer_traits_base< ::boost::ulong_long_type, 0, _ULLONG_MAX> -{ }; - -#elif defined(BOOST_HAS_LONG_LONG) -// -// we have long long but no constants, this happens for example with gcc in -ansi mode, -// we'll just have to work out the values for ourselves (assumes 2's compliment representation): -// -template<> -class integer_traits< ::boost::long_long_type> - : public std::numeric_limits< ::boost::long_long_type>, - public detail::integer_traits_base< ::boost::long_long_type, (1LL << (sizeof(::boost::long_long_type) * CHAR_BIT - 1)), ~(1LL << (sizeof(::boost::long_long_type) * CHAR_BIT - 1))> -{ }; - -template<> -class integer_traits< ::boost::ulong_long_type> - : public std::numeric_limits< ::boost::ulong_long_type>, - public detail::integer_traits_base< ::boost::ulong_long_type, 0, ~0uLL> -{ }; - -#elif defined(BOOST_HAS_MS_INT64) - -template<> -class integer_traits< __int64> - : public std::numeric_limits< __int64>, - public detail::integer_traits_base< __int64, _I64_MIN, _I64_MAX> -{ }; - -template<> -class integer_traits< unsigned __int64> - : public std::numeric_limits< unsigned __int64>, - public detail::integer_traits_base< unsigned __int64, 0, _UI64_MAX> -{ }; - -#endif -#endif - -} // namespace boost - -#endif /* BOOST_INTEGER_TRAITS_HPP */ - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/allocator.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/allocator.hpp deleted file mode 100644 index 497cbd44..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/allocator.hpp +++ /dev/null @@ -1,306 +0,0 @@ -/////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -/////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_ALLOCATOR_HPP -#define BOOST_INTERPROCESS_ALLOCATOR_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -//!\file -//!Describes an allocator that allocates portions of fixed size -//!memory buffer (shared memory, mapped file...) - -namespace boost { -namespace interprocess { - - -//!An STL compatible allocator that uses a segment manager as -//!memory source. The internal pointer type will of the same type (raw, smart) as -//!"typename SegmentManager::void_pointer" type. This allows -//!placing the allocator in shared memory, memory mapped-files, etc... -template -class allocator -{ - public: - //Segment manager - typedef SegmentManager segment_manager; - typedef typename SegmentManager::void_pointer void_pointer; - - /// @cond - private: - - //Self type - typedef allocator self_t; - - //Pointer to void - typedef typename segment_manager::void_pointer aux_pointer_t; - - //Typedef to const void pointer - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type cvoid_ptr; - - //Pointer to the allocator - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type alloc_ptr_t; - - //Not assignable from related allocator - template - allocator& operator=(const allocator&); - - //Not assignable from other allocator - allocator& operator=(const allocator&); - - //Pointer to the allocator - alloc_ptr_t mp_mngr; - /// @endcond - - public: - typedef T value_type; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type const_pointer; - typedef typename ipcdetail::add_reference - ::type reference; - typedef typename ipcdetail::add_reference - ::type const_reference; - typedef typename segment_manager::size_type size_type; - typedef typename segment_manager::difference_type difference_type; - - typedef boost::interprocess::version_type version; - - /// @cond - - //Experimental. Don't use. - typedef boost::container::container_detail::transform_multiallocation_chain - multiallocation_chain; - /// @endcond - - //!Obtains an allocator that allocates - //!objects of type T2 - template - struct rebind - { - typedef allocator other; - }; - - //!Returns the segment manager. - //!Never throws - segment_manager* get_segment_manager()const - { return ipcdetail::to_raw_pointer(mp_mngr); } - - //!Constructor from the segment manager. - //!Never throws - allocator(segment_manager *segment_mngr) - : mp_mngr(segment_mngr) { } - - //!Constructor from other allocator. - //!Never throws - allocator(const allocator &other) - : mp_mngr(other.get_segment_manager()){ } - - //!Constructor from related allocator. - //!Never throws - template - allocator(const allocator &other) - : mp_mngr(other.get_segment_manager()){} - - //!Allocates memory for an array of count elements. - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate(size_type count, cvoid_ptr hint = 0) - { - (void)hint; - if(size_overflows(count)){ - throw bad_alloc(); - } - return pointer(static_cast(mp_mngr->allocate(count*sizeof(T)))); - } - - //!Deallocates memory previously allocated. - //!Never throws - void deallocate(const pointer &ptr, size_type) - { mp_mngr->deallocate((void*)ipcdetail::to_raw_pointer(ptr)); } - - //!Returns the number of elements that could be allocated. - //!Never throws - size_type max_size() const - { return mp_mngr->get_size()/sizeof(T); } - - //!Swap segment manager. Does not throw. If each allocator is placed in - //!different memory segments, the result is undefined. - friend void swap(self_t &alloc1, self_t &alloc2) - { ipcdetail::do_swap(alloc1.mp_mngr, alloc2.mp_mngr); } - - //!Returns maximum the number of objects the previously allocated memory - //!pointed by p can hold. This size only works for memory allocated with - //!allocate, allocation_command and allocate_many. - size_type size(const pointer &p) const - { - return (size_type)mp_mngr->size(ipcdetail::to_raw_pointer(p))/sizeof(T); - } - - std::pair - allocation_command(boost::interprocess::allocation_type command, - size_type limit_size, - size_type preferred_size, - size_type &received_size, const pointer &reuse = 0) - { - return mp_mngr->allocation_command - (command, limit_size, preferred_size, received_size, ipcdetail::to_raw_pointer(reuse)); - } - - //!Allocates many elements of size elem_size in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. The elements must be deallocated - //!with deallocate(...) - void allocate_many(size_type elem_size, size_type num_elements, multiallocation_chain &chain) - { - if(size_overflows(elem_size)){ - throw bad_alloc(); - } - mp_mngr->allocate_many(elem_size*sizeof(T), num_elements, chain); - } - - //!Allocates n_elements elements, each one of size elem_sizes[i]in a - //!contiguous block - //!of memory. The elements must be deallocated - void allocate_many(const size_type *elem_sizes, size_type n_elements, multiallocation_chain &chain) - { - mp_mngr->allocate_many(elem_sizes, n_elements, sizeof(T), chain); - } - - //!Allocates many elements of size elem_size in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. The elements must be deallocated - //!with deallocate(...) - void deallocate_many(multiallocation_chain &chain) - { mp_mngr->deallocate_many(chain); } - - //!Allocates just one object. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate_one() - { return this->allocate(1); } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void allocate_individual(size_type num_elements, multiallocation_chain &chain) - { this->allocate_many(1, num_elements, chain); } - - //!Deallocates memory previously allocated with allocate_one(). - //!You should never use deallocate_one to deallocate memory allocated - //!with other functions different from allocate_one(). Never throws - void deallocate_one(const pointer &p) - { return this->deallocate(p, 1); } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void deallocate_individual(multiallocation_chain &chain) - { this->deallocate_many(chain); } - - //!Returns address of mutable object. - //!Never throws - pointer address(reference value) const - { return pointer(boost::addressof(value)); } - - //!Returns address of non mutable object. - //!Never throws - const_pointer address(const_reference value) const - { return const_pointer(boost::addressof(value)); } - - //!Constructs an object - //!Throws if T's constructor throws - //!For backwards compatibility with libraries using C++03 allocators - template - void construct(const pointer &ptr, BOOST_FWD_REF(P) p) - { ::new((void*)ipcdetail::to_raw_pointer(ptr)) value_type(::boost::forward

(p)); } - - //!Destroys object. Throws if object's - //!destructor throws - void destroy(const pointer &ptr) - { BOOST_ASSERT(ptr != 0); (*ptr).~value_type(); } - -}; - -//!Equality test for same type -//!of allocator -template inline -bool operator==(const allocator &alloc1, - const allocator &alloc2) - { return alloc1.get_segment_manager() == alloc2.get_segment_manager(); } - -//!Inequality test for same type -//!of allocator -template inline -bool operator!=(const allocator &alloc1, - const allocator &alloc2) - { return alloc1.get_segment_manager() != alloc2.get_segment_manager(); } - -} //namespace interprocess { - -/// @cond - -template -struct has_trivial_destructor; - -template -struct has_trivial_destructor - > -{ - static const bool value = true; -}; -/// @endcond - -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_ALLOCATOR_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/detail/allocator_common.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/detail/allocator_common.hpp deleted file mode 100644 index f2b54a8a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/allocators/detail/allocator_common.hpp +++ /dev/null @@ -1,850 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_ALLOCATOR_DETAIL_ALLOCATOR_COMMON_HPP -#define BOOST_INTERPROCESS_ALLOCATOR_DETAIL_ALLOCATOR_COMMON_HPP - -#include -#include - -#include - -#include -#include //to_raw_pointer -#include //boost::addressof -#include //BOOST_ASSERT -#include //bad_alloc -#include //scoped_lock -#include //boost::interprocess::allocation_type -#include -#include -#include -#include -#include -#include -#include //std::swap -#include //std::pair -#include - -namespace boost { -namespace interprocess { - -template -struct sizeof_value -{ - static const std::size_t value = sizeof(T); -}; - -template <> -struct sizeof_value -{ - static const std::size_t value = sizeof(void*); -}; - -template <> -struct sizeof_value -{ - static const std::size_t value = sizeof(void*); -}; - -template <> -struct sizeof_value -{ - static const std::size_t value = sizeof(void*); -}; - -template <> -struct sizeof_value -{ - static const std::size_t value = sizeof(void*); -}; - -namespace ipcdetail { - -//!Object function that creates the node allocator if it is not created and -//!increments reference count if it is already created -template -struct get_or_create_node_pool_func -{ - - //!This connects or constructs the unique instance of node_pool_t - //!Can throw boost::interprocess::bad_alloc - void operator()() - { - //Find or create the node_pool_t - mp_node_pool = mp_segment_manager->template find_or_construct - (boost::interprocess::unique_instance)(mp_segment_manager); - //If valid, increment link count - if(mp_node_pool != 0) - mp_node_pool->inc_ref_count(); - } - - //!Constructor. Initializes function - //!object parameters - get_or_create_node_pool_func(typename NodePool::segment_manager *mngr) - : mp_segment_manager(mngr){} - - NodePool *mp_node_pool; - typename NodePool::segment_manager *mp_segment_manager; -}; - -template -inline NodePool *get_or_create_node_pool(typename NodePool::segment_manager *mgnr) -{ - ipcdetail::get_or_create_node_pool_func func(mgnr); - mgnr->atomic_func(func); - return func.mp_node_pool; -} - -//!Object function that decrements the reference count. If the count -//!reaches to zero destroys the node allocator from memory. -//!Never throws -template -struct destroy_if_last_link_func -{ - //!Decrements reference count and destroys the object if there is no - //!more attached allocators. Never throws - void operator()() - { - //If not the last link return - if(mp_node_pool->dec_ref_count() != 0) return; - - //Last link, let's destroy the segment_manager - mp_node_pool->get_segment_manager()->template destroy(boost::interprocess::unique_instance); - } - - //!Constructor. Initializes function - //!object parameters - destroy_if_last_link_func(NodePool *pool) - : mp_node_pool(pool) - {} - - NodePool *mp_node_pool; -}; - -//!Destruction function, initializes and executes destruction function -//!object. Never throws -template -inline void destroy_node_pool_if_last_link(NodePool *pool) -{ - //Get segment manager - typename NodePool::segment_manager *mngr = pool->get_segment_manager(); - //Execute destruction functor atomically - destroy_if_last_link_funcfunc(pool); - mngr->atomic_func(func); -} - -template -class cache_impl -{ - typedef typename NodePool::segment_manager:: - void_pointer void_pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type node_pool_ptr; - typedef typename NodePool::multiallocation_chain multiallocation_chain; - typedef typename NodePool::segment_manager::size_type size_type; - node_pool_ptr mp_node_pool; - multiallocation_chain m_cached_nodes; - size_type m_max_cached_nodes; - - public: - typedef typename NodePool::segment_manager segment_manager; - - cache_impl(segment_manager *segment_mngr, size_type max_cached_nodes) - : mp_node_pool(get_or_create_node_pool(segment_mngr)) - , m_max_cached_nodes(max_cached_nodes) - {} - - cache_impl(const cache_impl &other) - : mp_node_pool(other.get_node_pool()) - , m_max_cached_nodes(other.get_max_cached_nodes()) - { - mp_node_pool->inc_ref_count(); - } - - ~cache_impl() - { - this->deallocate_all_cached_nodes(); - ipcdetail::destroy_node_pool_if_last_link(ipcdetail::to_raw_pointer(mp_node_pool)); - } - - NodePool *get_node_pool() const - { return ipcdetail::to_raw_pointer(mp_node_pool); } - - segment_manager *get_segment_manager() const - { return mp_node_pool->get_segment_manager(); } - - size_type get_max_cached_nodes() const - { return m_max_cached_nodes; } - - void *cached_allocation() - { - //If don't have any cached node, we have to get a new list of free nodes from the pool - if(m_cached_nodes.empty()){ - mp_node_pool->allocate_nodes(m_max_cached_nodes/2, m_cached_nodes); - } - void *ret = ipcdetail::to_raw_pointer(m_cached_nodes.pop_front()); - return ret; - } - - void cached_allocation(size_type n, multiallocation_chain &chain) - { - size_type count = n, allocated(0); - BOOST_TRY{ - //If don't have any cached node, we have to get a new list of free nodes from the pool - while(!m_cached_nodes.empty() && count--){ - void *ret = ipcdetail::to_raw_pointer(m_cached_nodes.pop_front()); - chain.push_back(ret); - ++allocated; - } - - if(allocated != n){ - mp_node_pool->allocate_nodes(n - allocated, chain); - } - } - BOOST_CATCH(...){ - this->cached_deallocation(chain); - BOOST_RETHROW - } - BOOST_CATCH_END - } - - void cached_deallocation(void *ptr) - { - //Check if cache is full - if(m_cached_nodes.size() >= m_max_cached_nodes){ - //This only occurs if this allocator deallocate memory allocated - //with other equal allocator. Since the cache is full, and more - //deallocations are probably coming, we'll make some room in cache - //in a single, efficient multi node deallocation. - this->priv_deallocate_n_nodes(m_cached_nodes.size() - m_max_cached_nodes/2); - } - m_cached_nodes.push_front(ptr); - } - - void cached_deallocation(multiallocation_chain &chain) - { - m_cached_nodes.splice_after(m_cached_nodes.before_begin(), chain); - - //Check if cache is full - if(m_cached_nodes.size() >= m_max_cached_nodes){ - //This only occurs if this allocator deallocate memory allocated - //with other equal allocator. Since the cache is full, and more - //deallocations are probably coming, we'll make some room in cache - //in a single, efficient multi node deallocation. - this->priv_deallocate_n_nodes(m_cached_nodes.size() - m_max_cached_nodes/2); - } - } - - //!Sets the new max cached nodes value. This can provoke deallocations - //!if "newmax" is less than current cached nodes. Never throws - void set_max_cached_nodes(size_type newmax) - { - m_max_cached_nodes = newmax; - this->priv_deallocate_remaining_nodes(); - } - - //!Frees all cached nodes. - //!Never throws - void deallocate_all_cached_nodes() - { - if(m_cached_nodes.empty()) return; - mp_node_pool->deallocate_nodes(m_cached_nodes); - } - - private: - //!Frees all cached nodes at once. - //!Never throws - void priv_deallocate_remaining_nodes() - { - if(m_cached_nodes.size() > m_max_cached_nodes){ - priv_deallocate_n_nodes(m_cached_nodes.size()-m_max_cached_nodes); - } - } - - //!Frees n cached nodes at once. Never throws - void priv_deallocate_n_nodes(size_type n) - { - //This only occurs if this allocator deallocate memory allocated - //with other equal allocator. Since the cache is full, and more - //deallocations are probably coming, we'll make some room in cache - //in a single, efficient multi node deallocation. - size_type count(n); - typename multiallocation_chain::iterator it(m_cached_nodes.before_begin()); - while(count--){ - ++it; - } - multiallocation_chain chain; - chain.splice_after(chain.before_begin(), m_cached_nodes, m_cached_nodes.before_begin(), it, n); - //Deallocate all new linked list at once - mp_node_pool->deallocate_nodes(chain); - } - - public: - void swap(cache_impl &other) - { - ipcdetail::do_swap(mp_node_pool, other.mp_node_pool); - m_cached_nodes.swap(other.m_cached_nodes); - ipcdetail::do_swap(m_max_cached_nodes, other.m_max_cached_nodes); - } -}; - -template -class array_allocation_impl -{ - const Derived *derived() const - { return static_cast(this); } - Derived *derived() - { return static_cast(this); } - - typedef typename SegmentManager::void_pointer void_pointer; - - public: - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type const_pointer; - typedef T value_type; - typedef typename ipcdetail::add_reference - ::type reference; - typedef typename ipcdetail::add_reference - ::type const_reference; - typedef typename SegmentManager::size_type size_type; - typedef typename SegmentManager::difference_type difference_type; - typedef boost::container::container_detail::transform_multiallocation_chain - multiallocation_chain; - - - public: - //!Returns maximum the number of objects the previously allocated memory - //!pointed by p can hold. This size only works for memory allocated with - //!allocate, allocation_command and allocate_many. - size_type size(const pointer &p) const - { - return (size_type)this->derived()->get_segment_manager()->size(ipcdetail::to_raw_pointer(p))/sizeof(T); - } - - std::pair - allocation_command(boost::interprocess::allocation_type command, - size_type limit_size, - size_type preferred_size, - size_type &received_size, const pointer &reuse = 0) - { - return this->derived()->get_segment_manager()->allocation_command - (command, limit_size, preferred_size, received_size, ipcdetail::to_raw_pointer(reuse)); - } - - //!Allocates many elements of size elem_size in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. The elements must be deallocated - //!with deallocate(...) - void allocate_many(size_type elem_size, size_type num_elements, multiallocation_chain &chain) - { - if(size_overflows(elem_size)){ - throw bad_alloc(); - } - this->derived()->get_segment_manager()->allocate_many(elem_size*sizeof(T), num_elements, chain); - } - - //!Allocates n_elements elements, each one of size elem_sizes[i]in a - //!contiguous block - //!of memory. The elements must be deallocated - void allocate_many(const size_type *elem_sizes, size_type n_elements, multiallocation_chain &chain) - { - this->derived()->get_segment_manager()->allocate_many(elem_sizes, n_elements, sizeof(T), chain); - } - - //!Allocates many elements of size elem_size in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. The elements must be deallocated - //!with deallocate(...) - void deallocate_many(multiallocation_chain &chain) - { this->derived()->get_segment_manager()->deallocate_many(chain); } - - //!Returns the number of elements that could be - //!allocated. Never throws - size_type max_size() const - { return this->derived()->get_segment_manager()->get_size()/sizeof(T); } - - //!Returns address of mutable object. - //!Never throws - pointer address(reference value) const - { return pointer(boost::addressof(value)); } - - //!Returns address of non mutable object. - //!Never throws - const_pointer address(const_reference value) const - { return const_pointer(boost::addressof(value)); } - - //!Constructs an object - //!Throws if T's constructor throws - //!For backwards compatibility with libraries using C++03 allocators - template - void construct(const pointer &ptr, BOOST_FWD_REF(P) p) - { ::new((void*)ipcdetail::to_raw_pointer(ptr)) value_type(::boost::forward

(p)); } - - //!Destroys object. Throws if object's - //!destructor throws - void destroy(const pointer &ptr) - { BOOST_ASSERT(ptr != 0); (*ptr).~value_type(); } -}; - - -template -class node_pool_allocation_impl - : public array_allocation_impl - < Derived - , T - , SegmentManager> -{ - const Derived *derived() const - { return static_cast(this); } - Derived *derived() - { return static_cast(this); } - - typedef typename SegmentManager::void_pointer void_pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type cvoid_pointer; - - public: - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type const_pointer; - typedef T value_type; - typedef typename ipcdetail::add_reference - ::type reference; - typedef typename ipcdetail::add_reference - ::type const_reference; - typedef typename SegmentManager::size_type size_type; - typedef typename SegmentManager::difference_type difference_type; - typedef boost::container::container_detail::transform_multiallocation_chain - multiallocation_chain; - - - template - struct node_pool - { - typedef typename Derived::template node_pool<0>::type type; - static type *get(void *p) - { return static_cast(p); } - }; - - public: - //!Allocate memory for an array of count elements. - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate(size_type count, cvoid_pointer hint = 0) - { - (void)hint; - typedef typename node_pool<0>::type node_pool_t; - node_pool_t *pool = node_pool<0>::get(this->derived()->get_node_pool()); - if(size_overflows(count)){ - throw bad_alloc(); - } - else if(Version == 1 && count == 1){ - return pointer(static_cast - (pool->allocate_node())); - } - else{ - return pointer(static_cast - (pool->get_segment_manager()->allocate(count*sizeof(T)))); - } - } - - //!Deallocate allocated memory. Never throws - void deallocate(const pointer &ptr, size_type count) - { - (void)count; - typedef typename node_pool<0>::type node_pool_t; - node_pool_t *pool = node_pool<0>::get(this->derived()->get_node_pool()); - if(Version == 1 && count == 1) - pool->deallocate_node(ipcdetail::to_raw_pointer(ptr)); - else - pool->get_segment_manager()->deallocate((void*)ipcdetail::to_raw_pointer(ptr)); - } - - //!Allocates just one object. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate_one() - { - typedef typename node_pool<0>::type node_pool_t; - node_pool_t *pool = node_pool<0>::get(this->derived()->get_node_pool()); - return pointer(static_cast(pool->allocate_node())); - } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void allocate_individual(size_type num_elements, multiallocation_chain &chain) - { - typedef typename node_pool<0>::type node_pool_t; - node_pool_t *pool = node_pool<0>::get(this->derived()->get_node_pool()); - pool->allocate_nodes(num_elements, chain); - } - - //!Deallocates memory previously allocated with allocate_one(). - //!You should never use deallocate_one to deallocate memory allocated - //!with other functions different from allocate_one(). Never throws - void deallocate_one(const pointer &p) - { - typedef typename node_pool<0>::type node_pool_t; - node_pool_t *pool = node_pool<0>::get(this->derived()->get_node_pool()); - pool->deallocate_node(ipcdetail::to_raw_pointer(p)); - } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void deallocate_individual(multiallocation_chain &chain) - { - node_pool<0>::get(this->derived()->get_node_pool())->deallocate_nodes - (chain); - } - - //!Deallocates all free blocks of the pool - void deallocate_free_blocks() - { node_pool<0>::get(this->derived()->get_node_pool())->deallocate_free_blocks(); } - - //!Deprecated, use deallocate_free_blocks. - //!Deallocates all free chunks of the pool. - void deallocate_free_chunks() - { node_pool<0>::get(this->derived()->get_node_pool())->deallocate_free_blocks(); } -}; - -template -class cached_allocator_impl - : public array_allocation_impl - , T, typename NodePool::segment_manager> -{ - cached_allocator_impl & operator=(const cached_allocator_impl& other); - typedef array_allocation_impl - < cached_allocator_impl - - , T - , typename NodePool::segment_manager> base_t; - - public: - typedef NodePool node_pool_t; - typedef typename NodePool::segment_manager segment_manager; - typedef typename segment_manager::void_pointer void_pointer; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type cvoid_pointer; - typedef typename base_t::pointer pointer; - typedef typename base_t::size_type size_type; - typedef typename base_t::multiallocation_chain multiallocation_chain; - typedef typename base_t::value_type value_type; - - public: - static const std::size_t DEFAULT_MAX_CACHED_NODES = 64; - - cached_allocator_impl(segment_manager *segment_mngr, size_type max_cached_nodes) - : m_cache(segment_mngr, max_cached_nodes) - {} - - cached_allocator_impl(const cached_allocator_impl &other) - : m_cache(other.m_cache) - {} - - //!Copy constructor from related cached_adaptive_pool_base. If not present, constructs - //!a node pool. Increments the reference count of the associated node pool. - //!Can throw boost::interprocess::bad_alloc - template - cached_allocator_impl - (const cached_allocator_impl - &other) - : m_cache(other.get_segment_manager(), other.get_max_cached_nodes()) - {} - - //!Returns a pointer to the node pool. - //!Never throws - node_pool_t* get_node_pool() const - { return m_cache.get_node_pool(); } - - //!Returns the segment manager. - //!Never throws - segment_manager* get_segment_manager()const - { return m_cache.get_segment_manager(); } - - //!Sets the new max cached nodes value. This can provoke deallocations - //!if "newmax" is less than current cached nodes. Never throws - void set_max_cached_nodes(size_type newmax) - { m_cache.set_max_cached_nodes(newmax); } - - //!Returns the max cached nodes parameter. - //!Never throws - size_type get_max_cached_nodes() const - { return m_cache.get_max_cached_nodes(); } - - //!Allocate memory for an array of count elements. - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate(size_type count, cvoid_pointer hint = 0) - { - (void)hint; - void * ret; - if(size_overflows(count)){ - throw bad_alloc(); - } - else if(Version == 1 && count == 1){ - ret = m_cache.cached_allocation(); - } - else{ - ret = this->get_segment_manager()->allocate(count*sizeof(T)); - } - return pointer(static_cast(ret)); - } - - //!Deallocate allocated memory. Never throws - void deallocate(const pointer &ptr, size_type count) - { - (void)count; - if(Version == 1 && count == 1){ - m_cache.cached_deallocation(ipcdetail::to_raw_pointer(ptr)); - } - else{ - this->get_segment_manager()->deallocate((void*)ipcdetail::to_raw_pointer(ptr)); - } - } - - //!Allocates just one object. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - //!Throws boost::interprocess::bad_alloc if there is no enough memory - pointer allocate_one() - { return pointer(static_cast(this->m_cache.cached_allocation())); } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void allocate_individual(size_type num_elements, multiallocation_chain &chain) - { this->m_cache.cached_allocation(num_elements, chain); } - - //!Deallocates memory previously allocated with allocate_one(). - //!You should never use deallocate_one to deallocate memory allocated - //!with other functions different from allocate_one(). Never throws - void deallocate_one(const pointer &p) - { this->m_cache.cached_deallocation(ipcdetail::to_raw_pointer(p)); } - - //!Allocates many elements of size == 1 in a contiguous block - //!of memory. The minimum number to be allocated is min_elements, - //!the preferred and maximum number is - //!preferred_elements. The number of actually allocated elements is - //!will be assigned to received_size. Memory allocated with this function - //!must be deallocated only with deallocate_one(). - void deallocate_individual(multiallocation_chain &chain) - { m_cache.cached_deallocation(chain); } - - //!Deallocates all free blocks of the pool - void deallocate_free_blocks() - { m_cache.get_node_pool()->deallocate_free_blocks(); } - - //!Swaps allocators. Does not throw. If each allocator is placed in a - //!different shared memory segments, the result is undefined. - friend void swap(cached_allocator_impl &alloc1, cached_allocator_impl &alloc2) - { alloc1.m_cache.swap(alloc2.m_cache); } - - void deallocate_cache() - { m_cache.deallocate_all_cached_nodes(); } - - //!Deprecated use deallocate_free_blocks. - void deallocate_free_chunks() - { m_cache.get_node_pool()->deallocate_free_blocks(); } - - /// @cond - private: - cache_impl m_cache; -}; - -//!Equality test for same type of -//!cached_allocator_impl -template inline -bool operator==(const cached_allocator_impl &alloc1, - const cached_allocator_impl &alloc2) - { return alloc1.get_node_pool() == alloc2.get_node_pool(); } - -//!Inequality test for same type of -//!cached_allocator_impl -template inline -bool operator!=(const cached_allocator_impl &alloc1, - const cached_allocator_impl &alloc2) - { return alloc1.get_node_pool() != alloc2.get_node_pool(); } - - -//!Pooled shared memory allocator using adaptive pool. Includes -//!a reference count but the class does not delete itself, this is -//!responsibility of user classes. Node size (NodeSize) and the number of -//!nodes allocated per block (NodesPerBlock) are known at compile time -template -class shared_pool_impl - : public private_node_allocator_t -{ - public: - //!Segment manager typedef - typedef typename private_node_allocator_t:: - segment_manager segment_manager; - typedef typename private_node_allocator_t:: - multiallocation_chain multiallocation_chain; - typedef typename private_node_allocator_t:: - size_type size_type; - - private: - typedef typename segment_manager::mutex_family::mutex_type mutex_type; - - public: - //!Constructor from a segment manager. Never throws - shared_pool_impl(segment_manager *segment_mngr) - : private_node_allocator_t(segment_mngr) - {} - - //!Destructor. Deallocates all allocated blocks. Never throws - ~shared_pool_impl() - {} - - //!Allocates array of count elements. Can throw boost::interprocess::bad_alloc - void *allocate_node() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - return private_node_allocator_t::allocate_node(); - } - - //!Deallocates an array pointed by ptr. Never throws - void deallocate_node(void *ptr) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::deallocate_node(ptr); - } - - //!Allocates n nodes. - //!Can throw boost::interprocess::bad_alloc - void allocate_nodes(const size_type n, multiallocation_chain &chain) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::allocate_nodes(n, chain); - } - - //!Deallocates a linked list of nodes ending in null pointer. Never throws - void deallocate_nodes(multiallocation_chain &nodes, size_type num) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::deallocate_nodes(nodes, num); - } - - //!Deallocates the nodes pointed by the multiallocation iterator. Never throws - void deallocate_nodes(multiallocation_chain &chain) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::deallocate_nodes(chain); - } - - //!Deallocates all the free blocks of memory. Never throws - void deallocate_free_blocks() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::deallocate_free_blocks(); - } - - //!Deallocates all used memory from the common pool. - //!Precondition: all nodes allocated from this pool should - //!already be deallocated. Otherwise, undefined behavior. Never throws - void purge_blocks() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::purge_blocks(); - } - - //!Increments internal reference count and returns new count. Never throws - size_type inc_ref_count() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - return ++m_header.m_usecount; - } - - //!Decrements internal reference count and returns new count. Never throws - size_type dec_ref_count() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - BOOST_ASSERT(m_header.m_usecount > 0); - return --m_header.m_usecount; - } - - //!Deprecated, use deallocate_free_blocks. - void deallocate_free_chunks() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::deallocate_free_blocks(); - } - - //!Deprecated, use purge_blocks. - void purge_chunks() - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - private_node_allocator_t::purge_blocks(); - } - - private: - //!This struct includes needed data and derives from - //!the mutex type to allow EBO when using null_mutex - struct header_t : mutex_type - { - size_type m_usecount; //Number of attached allocators - - header_t() - : m_usecount(0) {} - } m_header; -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_ALLOCATOR_DETAIL_ALLOCATOR_COMMON_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/allocation_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/allocation_type.hpp deleted file mode 100644 index eea431b0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/allocation_type.hpp +++ /dev/null @@ -1,40 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_CONTAINERS_ALLOCATION_TYPE_HPP -#define BOOST_INTERPROCESS_CONTAINERS_ALLOCATION_TYPE_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -namespace boost { -namespace interprocess { - -/// @cond -typedef int allocation_type; -/// @endcond -static const allocation_type allocate_new = boost::container::allocate_new; -static const allocation_type expand_fwd = boost::container::expand_fwd; -static const allocation_type expand_bwd = boost::container::expand_bwd; -static const allocation_type shrink_in_place = boost::container::shrink_in_place; -static const allocation_type try_shrink_in_place= boost::container::try_shrink_in_place; -static const allocation_type nothrow_allocation = boost::container::nothrow_allocation; -static const allocation_type zero_memory = boost::container::zero_memory; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif // #ifndef BOOST_INTERPROCESS_CONTAINERS_VERSION_TYPE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/version_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/version_type.hpp deleted file mode 100644 index 4516e8c9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/containers/version_type.hpp +++ /dev/null @@ -1,33 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_CONTAINERS_VERSION_TYPE_HPP -#define BOOST_INTERPROCESS_CONTAINERS_VERSION_TYPE_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -namespace boost { -namespace interprocess { - -using boost::container::container_detail::version_type; -using boost::container::container_detail::version; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif // #ifndef BOOST_INTERPROCESS_CONTAINERS_VERSION_TYPE_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/creation_tags.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/creation_tags.hpp deleted file mode 100644 index 459eb4df..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/creation_tags.hpp +++ /dev/null @@ -1,77 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_CREATION_TAGS_HPP -#define BOOST_INTERPROCESS_CREATION_TAGS_HPP - -#include -#include - -namespace boost { -namespace interprocess { - -//!Tag to indicate that the resource must -//!be only created -struct create_only_t {}; - -//!Tag to indicate that the resource must -//!be only opened -struct open_only_t {}; - -//!Tag to indicate that the resource must -//!be only opened for reading -struct open_read_only_t {}; - -//!Tag to indicate that the resource must -//!be only opened privately for reading -struct open_read_private_t {}; - -//!Tag to indicate that the resource must -//!be only opened for reading -struct open_copy_on_write_t {}; - -//!Tag to indicate that the resource must -//!be created. If already created, it must be opened. -struct open_or_create_t {}; - -//!Value to indicate that the resource must -//!be only created -static const create_only_t create_only = create_only_t(); - -//!Value to indicate that the resource must -//!be only opened -static const open_only_t open_only = open_only_t(); - -//!Value to indicate that the resource must -//!be only opened for reading -static const open_read_only_t open_read_only = open_read_only_t(); - -//!Value to indicate that the resource must -//!be created. If already created, it must be opened. -static const open_or_create_t open_or_create = open_or_create_t(); - -//!Value to indicate that the resource must -//!be only opened for reading -static const open_copy_on_write_t open_copy_on_write = open_copy_on_write_t(); - -namespace ipcdetail { - -enum create_enum_t -{ DoCreate, DoOpen, DoOpenOrCreate }; - -} //namespace ipcdetail { - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_CREATION_TAGS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/atomic.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/atomic.hpp deleted file mode 100644 index fb56891e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/atomic.hpp +++ /dev/null @@ -1,562 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2006-2012 -// (C) Copyright Markus Schoepflin 2007 -// (C) Copyright Bryce Lelbach 2010 -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_ATOMIC_HPP -#define BOOST_INTERPROCESS_DETAIL_ATOMIC_HPP - -#include -#include -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -//! Atomically increment an boost::uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem); - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem); - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val); - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with": what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp); - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#if (defined BOOST_INTERPROCESS_WINDOWS) - -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return winapi::interlocked_decrement(reinterpret_cast(mem)) + 1; } - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return winapi::interlocked_increment(reinterpret_cast(mem))-1; } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ winapi::interlocked_exchange(reinterpret_cast(mem), val); } - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with": what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ return winapi::interlocked_compare_exchange(reinterpret_cast(mem), with, cmp); } - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ - boost::uint32_t prev = cmp; - // This version by Mans Rullgard of Pathscale - __asm__ __volatile__ ( "lock\n\t" - "cmpxchg %2,%0" - : "+m"(*mem), "+a"(prev) - : "r"(with) - : "cc"); - - return prev; -} - -//! Atomically add 'val' to an boost::uint32_t -//! "mem": pointer to the object -//! "val": amount to add -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_add32 - (volatile boost::uint32_t *mem, boost::uint32_t val) -{ - // int r = *pw; - // *mem += val; - // return r; - int r; - - asm volatile - ( - "lock\n\t" - "xadd %1, %0": - "+m"( *mem ), "=r"( r ): // outputs (%0, %1) - "1"( val ): // inputs (%2 == %1) - "memory", "cc" // clobbers - ); - - return r; -} - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, 1); } - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, (boost::uint32_t)-1); } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ *mem = val; } - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#elif defined(__GNUC__) && (defined(__PPC__) || defined(__ppc__)) - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - -//! Atomically add 'val' to an boost::uint32_t -//! "mem": pointer to the object -//! "val": amount to add -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_add32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ - boost::uint32_t prev, temp; - - asm volatile ("1:\n\t" - "lwarx %0,0,%2\n\t" - "add %1,%0,%3\n\t" - "stwcx. %1,0,%2\n\t" - "bne- 1b" - : "=&r" (prev), "=&r" (temp) - : "b" (mem), "r" (val) - : "cc", "memory"); - return prev; -} - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ - boost::uint32_t prev; - - asm volatile ("1:\n\t" - "lwarx %0,0,%1\n\t" - "cmpw %0,%3\n\t" - "bne- 2f\n\t" - "stwcx. %2,0,%1\n\t" - "bne- 1b\n\t" - "2:" - : "=&r"(prev) - : "b" (mem), "r" (with), "r" (cmp) - : "cc", "memory"); - return prev; -} - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, 1); } - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, boost::uint32_t(-1u)); } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ *mem = val; } - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#elif (defined(sun) || defined(__sun)) - -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -//! Atomically add 'val' to an boost::uint32_t -//! "mem": pointer to the object -//! "val": amount to add -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_add32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ return atomic_add_32_nv(reinterpret_cast(mem), (int32_t)val) - val; } - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ return atomic_cas_32(reinterpret_cast(mem), cmp, with); } - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return atomic_add_32_nv(reinterpret_cast(mem), 1) - 1; } - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return atomic_add_32_nv(reinterpret_cast(mem), (boost::uint32_t)-1) + 1; } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ *mem = val; } - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#elif defined(__osf__) && defined(__DECCXX) - -#include -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -//! Atomically decrement a uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -//! Acquire, memory barrier after decrement. -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ boost::uint32_t old_val = __ATOMIC_DECREMENT_LONG(mem); __MB(); return old_val; } - -//! Atomically increment a uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -//! Release, memory barrier before increment. -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ __MB(); return __ATOMIC_INCREMENT_LONG(mem); } - -// Rational for the implementation of the atomic read and write functions. -// -// 1. The Alpha Architecture Handbook requires that access to a byte, -// an aligned word, an aligned longword, or an aligned quadword is -// atomic. (See 'Alpha Architecture Handbook', version 4, chapter 5.2.2.) -// -// 2. The CXX User's Guide states that volatile quantities are accessed -// with single assembler instructions, and that a compilation error -// occurs when declaring a quantity as volatile which is not properly -// aligned. - -//! Atomically read an boost::uint32_t from memory -//! Acquire, memory barrier after load. -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ boost::uint32_t old_val = *mem; __MB(); return old_val; } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -//! Release, memory barrier before store. -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ __MB(); *mem = val; } - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -//! Memory barrier between load and store. -inline boost::uint32_t atomic_cas32( - volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ - // Note: - // - // Branch prediction prefers backward branches, and the Alpha Architecture - // Handbook explicitely states that the loop should not be implemented like - // it is below. (See chapter 4.2.5.) Therefore the code should probably look - // like this: - // - // return asm( - // "10: ldl_l %v0,(%a0) ;" - // " cmpeq %v0,%a2,%t0 ;" - // " beq %t0,20f ;" - // " mb ;" - // " mov %a1,%t0 ;" - // " stl_c %t0,(%a0) ;" - // " beq %t0,30f ;" - // "20: ret ;" - // "30: br 10b;", - // mem, with, cmp); - // - // But as the compiler always transforms this into the form where a backward - // branch is taken on failure, we can as well implement it in the straight - // forward form, as this is what it will end up in anyway. - - return asm( - "10: ldl_l %v0,(%a0) ;" // load prev value from mem and lock mem - " cmpeq %v0,%a2,%t0 ;" // compare with given value - " beq %t0,20f ;" // if not equal, we're done - " mb ;" // memory barrier - " mov %a1,%t0 ;" // load new value into scratch register - " stl_c %t0,(%a0) ;" // store new value to locked mem (overwriting scratch) - " beq %t0,10b ;" // store failed because lock has been stolen, retry - "20: ", - mem, with, cmp); -} - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#elif defined(__IBMCPP__) && (__IBMCPP__ >= 800) && defined(_AIX) - -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - -//first define boost::uint32_t versions of __lwarx and __stwcx to avoid poluting -//all the functions with casts - -//! From XLC documenation : -//! This function can be used with a subsequent stwcxu call to implement a -//! read-modify-write on a specified memory location. The two functions work -//! together to ensure that if the store is successfully performed, no other -//! processor or mechanism can modify the target doubleword between the time -//! lwarxu function is executed and the time the stwcxu functio ncompletes. -//! "mem" : pointer to the object -//! Returns the value at pointed to by mem -inline boost::uint32_t lwarxu(volatile boost::uint32_t *mem) -{ - return static_cast(__lwarx(reinterpret_cast(mem))); -} - -//! "mem" : pointer to the object -//! "val" : the value to store -//! Returns true if the update of mem is successful and false if it is -//!unsuccessful -inline bool stwcxu(volatile boost::uint32_t* mem, boost::uint32_t val) -{ - return (__stwcx(reinterpret_cast(mem), static_cast(val)) != 0); -} - -//! "mem": pointer to the object -//! "val": amount to add -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_add32 - (volatile boost::uint32_t *mem, boost::uint32_t val) -{ - boost::uint32_t oldValue; - do - { - oldValue = lwarxu(mem); - }while (!stwcxu(mem, oldValue+val)); - return oldValue; -} - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, 1); } - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, (boost::uint32_t)-1); } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ - boost::uint32_t oldValue; - boost::uint32_t valueToStore; - do - { - oldValue = lwarxu(mem); - } while (!stwcxu(mem, (oldValue == with) ? cmp : oldValue)); - - return oldValue; -} - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ *mem = val; } - -} //namespace ipcdetail -} //namespace interprocess -} //namespace boost - -#elif defined(__GNUC__) && ( __GNUC__ * 100 + __GNUC_MINOR__ >= 401 ) - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - -//! Atomically add 'val' to an boost::uint32_t -//! "mem": pointer to the object -//! "val": amount to add -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_add32 - (volatile boost::uint32_t *mem, boost::uint32_t val) -{ return __sync_fetch_and_add(const_cast(mem), val); } - -//! Atomically increment an apr_uint32_t by 1 -//! "mem": pointer to the object -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, 1); } - -//! Atomically decrement an boost::uint32_t by 1 -//! "mem": pointer to the atomic value -//! Returns the old value pointed to by mem -inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) -{ return atomic_add32(mem, (boost::uint32_t)-1); } - -//! Atomically read an boost::uint32_t from memory -inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) -{ return *mem; } - -//! Compare an boost::uint32_t's value with "cmp". -//! If they are the same swap the value with "with" -//! "mem": pointer to the value -//! "with" what to swap it with -//! "cmp": the value to compare it to -//! Returns the old value of *mem -inline boost::uint32_t atomic_cas32 - (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) -{ return __sync_val_compare_and_swap(const_cast(mem), cmp, with); } - -//! Atomically set an boost::uint32_t in memory -//! "mem": pointer to the object -//! "param": val value that the object will assume -inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) -{ *mem = val; } - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#else - -#error No atomic operations implemented for this platform, sorry! - -#endif - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -inline bool atomic_add_unless32 - (volatile boost::uint32_t *mem, boost::uint32_t value, boost::uint32_t unless_this) -{ - boost::uint32_t old, c(atomic_read32(mem)); - while(c != unless_this && (old = atomic_cas32(mem, c + value, c)) != c){ - c = old; - } - return c != unless_this; -} - -} //namespace ipcdetail -} //namespace interprocess -} //namespace boost - - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_ATOMIC_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/cast_tags.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/cast_tags.hpp deleted file mode 100644 index 37dabd1f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/cast_tags.hpp +++ /dev/null @@ -1,29 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_CAST_TAGS_HPP -#define BOOST_INTERPROCESS_CAST_TAGS_HPP - -#include -#include - -namespace boost { namespace interprocess { namespace ipcdetail { - -struct static_cast_tag {}; -struct const_cast_tag {}; -struct dynamic_cast_tag {}; -struct reinterpret_cast_tag {}; - -}}} //namespace boost { namespace interprocess { namespace ipcdetail { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_CAST_TAGS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_begin.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_begin.hpp deleted file mode 100644 index 9224f7dd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_begin.hpp +++ /dev/null @@ -1,48 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#ifndef BOOST_INTERPROCESS_CONFIG_INCLUDED -#define BOOST_INTERPROCESS_CONFIG_INCLUDED -#include -#endif - -#ifdef BOOST_MSVC - #ifndef _CRT_SECURE_NO_DEPRECATE - #define BOOST_INTERPROCESS_CRT_SECURE_NO_DEPRECATE - #define _CRT_SECURE_NO_DEPRECATE - #endif - #pragma warning (push) - #pragma warning (disable : 4702) // unreachable code - #pragma warning (disable : 4706) // assignment within conditional expression - #pragma warning (disable : 4127) // conditional expression is constant - #pragma warning (disable : 4146) // unary minus operator applied to unsigned type, result still unsigned - #pragma warning (disable : 4284) // odd return type for operator-> - #pragma warning (disable : 4244) // possible loss of data - #pragma warning (disable : 4251) // "identifier" : class "type" needs to have dll-interface to be used by clients of class "type2" - #pragma warning (disable : 4267) // conversion from "X" to "Y", possible loss of data - #pragma warning (disable : 4275) // non DLL-interface classkey "identifier" used as base for DLL-interface classkey "identifier" - #pragma warning (disable : 4355) // "this" : used in base member initializer list - #pragma warning (disable : 4503) // "identifier" : decorated name length exceeded, name was truncated - #pragma warning (disable : 4511) // copy constructor could not be generated - #pragma warning (disable : 4512) // assignment operator could not be generated - #pragma warning (disable : 4514) // unreferenced inline removed - #pragma warning (disable : 4521) // Disable "multiple copy constructors specified" - #pragma warning (disable : 4522) // "class" : multiple assignment operators specified - #pragma warning (disable : 4675) // "method" should be declared "static" and have exactly one parameter - #pragma warning (disable : 4710) // function not inlined - #pragma warning (disable : 4711) // function selected for automatic inline expansion - #pragma warning (disable : 4786) // identifier truncated in debug info - #pragma warning (disable : 4996) // "function": was declared deprecated - #pragma warning (disable : 4197) // top-level volatile in cast is ignored - #pragma warning (disable : 4541) // 'typeid' used on polymorphic type 'boost::exception' - // with /GR-; unpredictable behavior may result - #pragma warning (disable : 4673) // throwing '' the following types will not be considered at the catch site - #pragma warning (disable : 4671) // the copy constructor is inaccessible - #pragma warning (disable : 4250) // inherits 'x' via dominance -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_end.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_end.hpp deleted file mode 100644 index f871ce75..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_end.hpp +++ /dev/null @@ -1,17 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#if defined BOOST_MSVC - #pragma warning (pop) - #ifdef BOOST_INTERPROCESS_CRT_SECURE_NO_DEPRECATE - #undef BOOST_INTERPROCESS_CRT_SECURE_NO_DEPRECATE - #undef _CRT_SECURE_NO_DEPRECATE - #endif -#endif - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_begin.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_begin.hpp deleted file mode 100644 index fb578ef0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_begin.hpp +++ /dev/null @@ -1,18 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#ifndef BOOST_INTERPROCESS_EXTERNAL_CONFIG_INCLUDED -#define BOOST_INTERPROCESS_EXTERNAL_CONFIG_INCLUDED -#include -#endif - -#if defined(__GNUC__) && ((__GNUC__*100 + __GNUC_MINOR__) >= 406) -# pragma GCC diagnostic push -# pragma GCC diagnostic ignored "-Wshadow" -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_end.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_end.hpp deleted file mode 100644 index 214558f5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/config_external_end.hpp +++ /dev/null @@ -1,12 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2012-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -#if defined(__GNUC__) && ((__GNUC__*100 + __GNUC_MINOR__) >= 406) -# pragma GCC diagnostic pop -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/in_place_interface.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/in_place_interface.hpp deleted file mode 100644 index 7c0966c1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/in_place_interface.hpp +++ /dev/null @@ -1,73 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_IN_PLACE_INTERFACE_HPP -#define BOOST_INTERPROCESS_IN_PLACE_INTERFACE_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include //typeid - -//!\file -//!Describes an abstract interface for placement construction and destruction. - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -struct in_place_interface -{ - in_place_interface(std::size_t alignm, std::size_t sz, const char *tname) - : alignment(alignm), size(sz), type_name(tname) - {} - - std::size_t alignment; - std::size_t size; - const char *type_name; - - virtual void construct_n(void *mem, std::size_t num, std::size_t &constructed) = 0; - virtual void destroy_n(void *mem, std::size_t num, std::size_t &destroyed) = 0; - virtual ~in_place_interface(){} -}; - -template -struct placement_destroy : public in_place_interface -{ - placement_destroy() - : in_place_interface(::boost::alignment_of::value, sizeof(T), typeid(T).name()) - {} - - virtual void destroy_n(void *mem, std::size_t num, std::size_t &destroyed) - { - T* memory = static_cast(mem); - for(destroyed = 0; destroyed < num; ++destroyed) - (memory++)->~T(); - } - - virtual void construct_n(void *, std::size_t, std::size_t &) {} - - private: - void destroy(void *mem) - { static_cast(mem)->~T(); } -}; - -} -} -} //namespace boost { namespace interprocess { namespace ipcdetail { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_IN_PLACE_INTERFACE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/intermodule_singleton_common.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/intermodule_singleton_common.hpp deleted file mode 100644 index 60ec5939..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/intermodule_singleton_common.hpp +++ /dev/null @@ -1,499 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2009-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_INTERMODULE_SINGLETON_COMMON_HPP -#define BOOST_INTERPROCESS_INTERMODULE_SINGLETON_COMMON_HPP - -#if defined(_MSC_VER)&&(_MSC_VER>=1200) -#pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -namespace intermodule_singleton_helpers { - -inline void get_pid_creation_time_str(std::string &s) -{ - std::stringstream stream; - stream << get_current_process_id() << '_'; - stream.precision(6); - stream << std::fixed << get_current_process_creation_time(); - s = stream.str(); -} - -inline const char *get_map_base_name() -{ return "bip.gmem.map."; } - -inline void get_map_name(std::string &map_name) -{ - get_pid_creation_time_str(map_name); - map_name.insert(0, get_map_base_name()); -} - -inline std::size_t get_map_size() -{ return 65536; } - -template -struct thread_safe_global_map_dependant; - -} //namespace intermodule_singleton_helpers { - -//This class contains common code for all singleton types, so that we instantiate this -//code just once per module. This class also holds a thread soafe global map -//to be used by all instances protected with a reference count -template -class intermodule_singleton_common -{ - public: - typedef void*(singleton_constructor_t)(ThreadSafeGlobalMap &); - typedef void (singleton_destructor_t)(void *, ThreadSafeGlobalMap &); - - static const ::boost::uint32_t Uninitialized = 0u; - static const ::boost::uint32_t Initializing = 1u; - static const ::boost::uint32_t Initialized = 2u; - static const ::boost::uint32_t Broken = 3u; - static const ::boost::uint32_t Destroyed = 4u; - - //Initialize this_module_singleton_ptr, creates the global map if needed and also creates an unique - //opaque type in global map through a singleton_constructor_t function call, - //initializing the passed pointer to that unique instance. - // - //We have two concurrency types here. a)the global map/singleton creation must - //be safe between threads of this process but in different modules/dlls. b) - //the pointer to the singleton is per-module, so we have to protect this - //initization between threads of the same module. - // - //All static variables declared here are shared between inside a module - //so atomic operations will synchronize only threads of the same module. - static void initialize_singleton_logic - (void *&ptr, volatile boost::uint32_t &this_module_singleton_initialized, singleton_constructor_t constructor, bool phoenix) - { - //If current module is not initialized enter to lock free logic - if(atomic_read32(&this_module_singleton_initialized) != Initialized){ - //Now a single thread of the module will succeed in this CAS. - //trying to pass from Uninitialized to Initializing - ::boost::uint32_t previous_module_singleton_initialized = atomic_cas32 - (&this_module_singleton_initialized, Initializing, Uninitialized); - //If the thread succeeded the CAS (winner) it will compete with other - //winner threads from other modules to create the global map - if(previous_module_singleton_initialized == Destroyed){ - //Trying to resurrect a dead Phoenix singleton. Just try to - //mark it as uninitialized and start again - if(phoenix){ - atomic_cas32(&this_module_singleton_initialized, Uninitialized, Destroyed); - previous_module_singleton_initialized = atomic_cas32 - (&this_module_singleton_initialized, Initializing, Uninitialized); - } - //Trying to resurrect a non-Phoenix dead singleton is an error - else{ - throw interprocess_exception("Boost.Interprocess: Dead reference on non-Phoenix singleton of type"); - } - } - if(previous_module_singleton_initialized == Uninitialized){ - try{ - //Now initialize the global map, this function must solve concurrency - //issues between threads of several modules - initialize_global_map_handle(); - //Now try to create the singleton in global map. - //This function solves concurrency issues - //between threads of several modules - void *tmp = constructor(get_map()); - //Increment the module reference count that reflects how many - //singletons this module holds, so that we can safely destroy - //module global map object when no singleton is left - atomic_inc32(&this_module_singleton_count); - //Insert a barrier before assigning the pointer to - //make sure this assignment comes after the initialization - atomic_write32(&this_module_singleton_initialized, Initializing); - //Assign the singleton address to the module-local pointer - ptr = tmp; - //Memory barrier inserted, all previous operations should complete - //before this one. Now marked as initialized - atomic_write32(&this_module_singleton_initialized, Initialized); - } - catch(...){ - //Mark singleton failed to initialize - atomic_write32(&this_module_singleton_initialized, Broken); - throw; - } - } - //If previous state was initializing, this means that another winner thread is - //trying to initialize the singleton. Just wait until completes its work. - else if(previous_module_singleton_initialized == Initializing){ - spin_wait swait; - while(1){ - previous_module_singleton_initialized = atomic_read32(&this_module_singleton_initialized); - if(previous_module_singleton_initialized >= Initialized){ - //Already initialized, or exception thrown by initializer thread - break; - } - else if(previous_module_singleton_initialized == Initializing){ - swait.yield(); - } - else{ - //This can't be happening! - BOOST_ASSERT(0); - } - } - } - else if(previous_module_singleton_initialized == Initialized){ - //Nothing to do here, the singleton is ready - } - //If previous state was greater than initialized, then memory is broken - //trying to initialize the singleton. - else{//(previous_module_singleton_initialized > Initialized) - throw interprocess_exception("boost::interprocess::intermodule_singleton initialization failed"); - } - } - BOOST_ASSERT(ptr != 0); - } - - static void finalize_singleton_logic(void *&ptr, volatile boost::uint32_t &this_module_singleton_initialized, singleton_destructor_t destructor) - { - //Protect destruction against lazy singletons not initialized in this execution - if(ptr){ - //Note: this destructor might provoke a Phoenix singleton - //resurrection. This means that this_module_singleton_count - //might change after this call. - destructor(ptr, get_map()); - ptr = 0; - - //Memory barrier to make sure pointer is nulled. - //Mark this singleton as destroyed. - atomic_write32(&this_module_singleton_initialized, Destroyed); - - //If this is the last singleton of this module - //apply map destruction. - //Note: singletons are destroyed when the module is unloaded - //so no threads should be executing or holding references - //to this module - if(1 == atomic_dec32(&this_module_singleton_count)){ - destroy_global_map_handle(); - } - } - } - - private: - static ThreadSafeGlobalMap &get_map() - { - return *static_cast(static_cast(&mem_holder.map_mem[0])); - } - - static void initialize_global_map_handle() - { - //Obtain unique map name and size - spin_wait swait; - while(1){ - //Try to pass map state to initializing - ::boost::uint32_t tmp = atomic_cas32(&this_module_map_initialized, Initializing, Uninitialized); - if(tmp == Initialized || tmp == Broken){ - break; - } - else if(tmp == Destroyed){ - tmp = atomic_cas32(&this_module_map_initialized, Uninitialized, Destroyed); - continue; - } - //If some other thread is doing the work wait - else if(tmp == Initializing){ - swait.yield(); - } - else{ //(tmp == Uninitialized) - //If not initialized try it again? - try{ - //Remove old global map from the system - intermodule_singleton_helpers::thread_safe_global_map_dependant::remove_old_gmem(); - //in-place construction of the global map class - intermodule_singleton_helpers::thread_safe_global_map_dependant - ::construct_map(static_cast(&get_map())); - //Use global map's internal lock to initialize the lock file - //that will mark this gmem as "in use". - typename intermodule_singleton_helpers::thread_safe_global_map_dependant:: - lock_file_logic f(get_map()); - //If function failed (maybe a competing process has erased the shared - //memory between creation and file locking), retry with a new instance. - if(f.retry()){ - get_map().~ThreadSafeGlobalMap(); - atomic_write32(&this_module_map_initialized, Destroyed); - } - else{ - //Locking succeeded, so this global map module-instance is ready - atomic_write32(&this_module_map_initialized, Initialized); - break; - } - } - catch(...){ - // - throw; - } - } - } - } - - static void destroy_global_map_handle() - { - if(!atomic_read32(&this_module_singleton_count)){ - //This module is being unloaded, so destroy - //the global map object of this module - //and unlink the global map if it's the last - typename intermodule_singleton_helpers::thread_safe_global_map_dependant:: - unlink_map_logic f(get_map()); - (get_map()).~ThreadSafeGlobalMap(); - atomic_write32(&this_module_map_initialized, Destroyed); - //Do some cleanup for other processes old gmem instances - intermodule_singleton_helpers::thread_safe_global_map_dependant::remove_old_gmem(); - } - } - - //Static data, zero-initalized without any dependencies - //this_module_singleton_count is the number of singletons used by this module - static volatile boost::uint32_t this_module_singleton_count; - - //this_module_map_initialized is the state of this module's map class object. - //Values: Uninitialized, Initializing, Initialized, Broken - static volatile boost::uint32_t this_module_map_initialized; - - //Raw memory to construct the global map manager - static struct mem_holder_t - { - ::boost::detail::max_align aligner; - char map_mem [sizeof(ThreadSafeGlobalMap)]; - } mem_holder; -}; - -template -volatile boost::uint32_t intermodule_singleton_common::this_module_singleton_count; - -template -volatile boost::uint32_t intermodule_singleton_common::this_module_map_initialized; - -template -typename intermodule_singleton_common::mem_holder_t - intermodule_singleton_common::mem_holder; - -//A reference count to be stored in global map holding the number -//of singletons (one per module) attached to the instance pointed by -//the internal ptr. -struct ref_count_ptr -{ - ref_count_ptr(void *p, boost::uint32_t count) - : ptr(p), singleton_ref_count(count) - {} - void *ptr; - //This reference count serves to count the number of attached - //modules to this singleton - volatile boost::uint32_t singleton_ref_count; -}; - - -//Now this class is a singleton, initializing the singleton in -//the first get() function call if LazyInit is true. If false -//then the singleton will be initialized when loading the module. -template -class intermodule_singleton_impl -{ - public: - - static C& get() //Let's make inlining easy - { - if(!this_module_singleton_ptr){ - if(lifetime.dummy_function()){ //This forces lifetime instantiation, for reference counted destruction - atentry_work(); - } - } - return *static_cast(this_module_singleton_ptr); - } - - private: - - static void atentry_work() - { - intermodule_singleton_common::initialize_singleton_logic - (this_module_singleton_ptr, this_module_singleton_initialized, singleton_constructor, Phoenix); - } - - static void atexit_work() - { - intermodule_singleton_common::finalize_singleton_logic - (this_module_singleton_ptr, this_module_singleton_initialized, singleton_destructor); - } - - //These statics will be zero-initialized without any constructor call dependency - //this_module_singleton_ptr will be a module-local pointer to the singleton - static void* this_module_singleton_ptr; - - //this_module_singleton_count will be used to synchronize threads of the same module - //for access to a singleton instance, and to flag the state of the - //singleton. - static volatile boost::uint32_t this_module_singleton_initialized; - - //This class destructor will trigger singleton destruction - struct lifetime_type_lazy - { - bool dummy_function() - { return m_dummy == 0; } - - ~lifetime_type_lazy() - { - if(!Phoenix){ - atexit_work(); - } - } - - //Dummy volatile so that the compiler can't resolve its value at compile-time - //and can't avoid lifetime_type instantiation if dummy_function() is called. - static volatile int m_dummy; - }; - - struct lifetime_type_static - : public lifetime_type_lazy - { - lifetime_type_static() - { atentry_work(); } - }; - - typedef typename if_c - ::type lifetime_type; - - static lifetime_type lifetime; - - //A functor to be executed inside global map lock that just - //searches for the singleton in map and if not present creates a new one. - //If singleton constructor throws, the exception is propagated - struct init_atomic_func - { - init_atomic_func(ThreadSafeGlobalMap &m) - : m_map(m) - {} - - void operator()() - { - ref_count_ptr *rcount = intermodule_singleton_helpers::thread_safe_global_map_dependant - ::find(m_map, typeid(C).name()); - if(!rcount){ - C *p = new C; - try{ - ref_count_ptr val(p, 0u); - rcount = intermodule_singleton_helpers::thread_safe_global_map_dependant - ::insert(m_map, typeid(C).name(), val); - } - catch(...){ - intermodule_singleton_helpers::thread_safe_global_map_dependant - ::erase(m_map, typeid(C).name()); - delete p; - throw; - } - } - if(Phoenix){ - std::atexit(&atexit_work); - } - atomic_inc32(&rcount->singleton_ref_count); - ret_ptr = rcount->ptr; - } - void *data() const - { return ret_ptr; } - - private: - ThreadSafeGlobalMap &m_map; - void *ret_ptr; - }; - - //A functor to be executed inside global map lock that just - //deletes the singleton in map if the attached count reaches to zero - struct fini_atomic_func - { - fini_atomic_func(ThreadSafeGlobalMap &m) - : m_map(m) - {} - - void operator()() - { - ref_count_ptr *rcount = intermodule_singleton_helpers::thread_safe_global_map_dependant - ::find(m_map, typeid(C).name()); - //The object must exist - BOOST_ASSERT(rcount); - BOOST_ASSERT(rcount->singleton_ref_count > 0); - //Check if last reference - if(atomic_dec32(&rcount->singleton_ref_count) == 1){ - //If last, destroy the object - BOOST_ASSERT(rcount->ptr != 0); - C *pc = static_cast(rcount->ptr); - //Now destroy map entry - bool destroyed = intermodule_singleton_helpers::thread_safe_global_map_dependant - ::erase(m_map, typeid(C).name()); - (void)destroyed; BOOST_ASSERT(destroyed == true); - delete pc; - } - } - void *data() const - { return ret_ptr; } - - private: - ThreadSafeGlobalMap &m_map; - void *ret_ptr; - }; - - //A wrapper to execute init_atomic_func - static void *singleton_constructor(ThreadSafeGlobalMap &map) - { - init_atomic_func f(map); - intermodule_singleton_helpers::thread_safe_global_map_dependant - ::atomic_func(map, f); - return f.data(); - } - - //A wrapper to execute fini_atomic_func - static void singleton_destructor(void *p, ThreadSafeGlobalMap &map) - { (void)p; - fini_atomic_func f(map); - intermodule_singleton_helpers::thread_safe_global_map_dependant - ::atomic_func(map, f); - } -}; - -template -volatile int intermodule_singleton_impl::lifetime_type_lazy::m_dummy = 0; - -//These will be zero-initialized by the loader -template -void *intermodule_singleton_impl::this_module_singleton_ptr = 0; - -template -volatile boost::uint32_t intermodule_singleton_impl::this_module_singleton_initialized = 0; - -template -typename intermodule_singleton_impl::lifetime_type - intermodule_singleton_impl::lifetime; - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#include - -#endif //#ifndef BOOST_INTERPROCESS_INTERMODULE_SINGLETON_COMMON_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/interprocess_tester.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/interprocess_tester.hpp deleted file mode 100644 index 2fcc07bc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/interprocess_tester.hpp +++ /dev/null @@ -1,31 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_INTERPROCESS_TESTER_HPP -#define BOOST_INTERPROCESS_DETAIL_INTERPROCESS_TESTER_HPP - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -class interprocess_tester -{ - public: - template - static void dont_close_on_destruction(T &t) - { t.dont_close_on_destruction(); } -}; - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_INTERPROCESS_TESTER_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_memory_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_memory_impl.hpp deleted file mode 100644 index 2f97935d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_memory_impl.hpp +++ /dev/null @@ -1,776 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_MANAGED_MEMORY_IMPL_HPP -#define BOOST_INTERPROCESS_DETAIL_MANAGED_MEMORY_IMPL_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -// -#include -// -#include -#include -#include -#include - -//!\file -//!Describes a named shared memory allocation user class. -//! - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -template -class create_open_func; - -template< - class CharType, - class MemoryAlgorithm, - template class IndexType - > -struct segment_manager_type -{ - typedef segment_manager type; -}; - -//!This class is designed to be a base class to classes that manage -//!creation of objects in a fixed size memory buffer. Apart -//!from allocating raw memory, the user can construct named objects. To -//!achieve this, this class uses the reserved space provided by the allocation -//!algorithm to place a named_allocator_algo, who takes care of name mappings. -//!The class can be customized with the char type used for object names -//!and the memory allocation algorithm to be used.*/ -template < class CharType - , class MemoryAlgorithm - , template class IndexType - , std::size_t Offset = 0 - > -class basic_managed_memory_impl -{ - //Non-copyable - basic_managed_memory_impl(const basic_managed_memory_impl &); - basic_managed_memory_impl &operator=(const basic_managed_memory_impl &); - - template - friend class create_open_func; - - public: - typedef typename segment_manager_type - ::type segment_manager; - typedef CharType char_type; - typedef MemoryAlgorithm memory_algorithm; - typedef typename MemoryAlgorithm::mutex_family mutex_family; - typedef CharType char_t; - typedef typename MemoryAlgorithm::size_type size_type; - typedef typename MemoryAlgorithm::difference_type difference_type; - typedef difference_type handle_t; - typedef typename segment_manager:: - const_named_iterator const_named_iterator; - typedef typename segment_manager:: - const_unique_iterator const_unique_iterator; - - /// @cond - - typedef typename - segment_manager::char_ptr_holder_t char_ptr_holder_t; - //Experimental. Don't use. - - typedef typename segment_manager::multiallocation_chain multiallocation_chain; - - /// @endcond - - static const size_type PayloadPerAllocation = segment_manager::PayloadPerAllocation; - - private: - typedef basic_managed_memory_impl - self_t; - protected: - template - static bool grow(const char *filename, size_type extra_bytes) - { - typedef typename ManagedMemory::device_type device_type; - //Increase file size - try{ - offset_t old_size; - { - device_type f(open_or_create, filename, read_write); - if(!f.get_size(old_size)) - return false; - f.truncate(old_size + extra_bytes); - } - ManagedMemory managed_memory(open_only, filename); - //Grow always works - managed_memory.self_t::grow(extra_bytes); - } - catch(...){ - return false; - } - return true; - } - - template - static bool shrink_to_fit(const char *filename) - { - typedef typename ManagedMemory::device_type device_type; - size_type new_size; - try{ - ManagedMemory managed_memory(open_only, filename); - managed_memory.get_size(); - managed_memory.self_t::shrink_to_fit(); - new_size = managed_memory.get_size(); - } - catch(...){ - return false; - } - - //Decrease file size - { - device_type f(open_or_create, filename, read_write); - f.truncate(new_size); - } - return true; - } - - //!Constructor. Allocates basic resources. Never throws. - basic_managed_memory_impl() - : mp_header(0){} - - //!Destructor. Calls close. Never throws. - ~basic_managed_memory_impl() - { this->close_impl(); } - - //!Places segment manager in the reserved space. This can throw. - bool create_impl (void *addr, size_type size) - { - if(mp_header) return false; - - //Check if there is enough space - if(size < segment_manager::get_min_size()) - return false; - - //This function should not throw. The index construction can - //throw if constructor allocates memory. So we must catch it. - BOOST_TRY{ - //Let's construct the allocator in memory - mp_header = new(addr) segment_manager(size); - } - BOOST_CATCH(...){ - return false; - } - BOOST_CATCH_END - return true; - } - - //!Connects to a segment manager in the reserved buffer. Never throws. - bool open_impl (void *addr, size_type) - { - if(mp_header) return false; - mp_header = static_cast(addr); - return true; - } - - //!Frees resources. Never throws. - bool close_impl() - { - bool ret = mp_header != 0; - mp_header = 0; - return ret; - } - - //!Frees resources and destroys common resources. Never throws. - bool destroy_impl() - { - if(mp_header == 0) - return false; - mp_header->~segment_manager(); - this->close_impl(); - return true; - } - - //! - void grow(size_type extra_bytes) - { mp_header->grow(extra_bytes); } - - void shrink_to_fit() - { mp_header->shrink_to_fit(); } - - public: - - //!Returns segment manager. Never throws. - segment_manager *get_segment_manager() const - { return mp_header; } - - //!Returns the base address of the memory in this process. Never throws. - void * get_address () const - { return reinterpret_cast(mp_header) - Offset; } - - //!Returns the size of memory segment. Never throws. - size_type get_size () const - { return mp_header->get_size() + Offset; } - - //!Returns the number of free bytes of the memory - //!segment - size_type get_free_memory() const - { return mp_header->get_free_memory(); } - - //!Returns the result of "all_memory_deallocated()" function - //!of the used memory algorithm - bool all_memory_deallocated() - { return mp_header->all_memory_deallocated(); } - - //!Returns the result of "check_sanity()" function - //!of the used memory algorithm - bool check_sanity() - { return mp_header->check_sanity(); } - - //!Writes to zero free memory (memory not yet allocated) of - //!the memory algorithm - void zero_free_memory() - { mp_header->zero_free_memory(); } - - //!Transforms an absolute address into an offset from base address. - //!The address must belong to the memory segment. Never throws. - handle_t get_handle_from_address (const void *ptr) const - { - return (handle_t)(reinterpret_cast(ptr) - - reinterpret_cast(this->get_address())); - } - - //!Returns true if the address belongs to the managed memory segment - bool belongs_to_segment (const void *ptr) const - { - return ptr >= this->get_address() && - ptr < (reinterpret_cast(this->get_address()) + this->get_size()); - } - - //!Transforms previously obtained offset into an absolute address in the - //!process space of the current process. Never throws.*/ - void * get_address_from_handle (handle_t offset) const - { return reinterpret_cast(this->get_address()) + offset; } - - //!Searches for nbytes of free memory in the segment, marks the - //!memory as used and return the pointer to the memory. If no - //!memory is available throws a boost::interprocess::bad_alloc exception - void* allocate (size_type nbytes) - { return mp_header->allocate(nbytes); } - - //!Searches for nbytes of free memory in the segment, marks the - //!memory as used and return the pointer to the memory. If no memory - //!is available returns 0. Never throws. - void* allocate (size_type nbytes, std::nothrow_t nothrow) - { return mp_header->allocate(nbytes, nothrow); } - - //!Allocates nbytes bytes aligned to "alignment" bytes. "alignment" - //!must be power of two. If no memory - //!is available returns 0. Never throws. - void * allocate_aligned (size_type nbytes, size_type alignment, std::nothrow_t nothrow) - { return mp_header->allocate_aligned(nbytes, alignment, nothrow); } - - template - std::pair - allocation_command (boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - T *reuse_ptr = 0) - { - return mp_header->allocation_command - (command, limit_size, preferred_size, received_size, reuse_ptr); - } - - //!Allocates nbytes bytes aligned to "alignment" bytes. "alignment" - //!must be power of two. If no - //!memory is available throws a boost::interprocess::bad_alloc exception - void * allocate_aligned(size_type nbytes, size_type alignment) - { return mp_header->allocate_aligned(nbytes, alignment); } - - /// @cond - - //Experimental. Don't use. - - //!Allocates n_elements of elem_bytes bytes. - //!Throws bad_alloc on failure. chain.size() is not increased on failure. - void allocate_many(size_type elem_bytes, size_type n_elements, multiallocation_chain &chain) - { mp_header->allocate_many(elem_bytes, n_elements, chain); } - - //!Allocates n_elements, each one of element_lengths[i]*sizeof_element bytes. - //!Throws bad_alloc on failure. chain.size() is not increased on failure. - void allocate_many(const size_type *element_lengths, size_type n_elements, size_type sizeof_element, multiallocation_chain &chain) - { mp_header->allocate_many(element_lengths, n_elements, sizeof_element, chain); } - - //!Allocates n_elements of elem_bytes bytes. - //!Non-throwing version. chain.size() is not increased on failure. - void allocate_many(std::nothrow_t, size_type elem_bytes, size_type n_elements, multiallocation_chain &chain) - { mp_header->allocate_many(std::nothrow_t(), elem_bytes, n_elements, chain); } - - //!Allocates n_elements, each one of - //!element_lengths[i]*sizeof_element bytes. - //!Non-throwing version. chain.size() is not increased on failure. - void allocate_many(std::nothrow_t, const size_type *elem_sizes, size_type n_elements, size_type sizeof_element, multiallocation_chain &chain) - { mp_header->allocate_many(std::nothrow_t(), elem_sizes, n_elements, sizeof_element, chain); } - - //!Deallocates all elements contained in chain. - //!Never throws. - void deallocate_many(multiallocation_chain &chain) - { mp_header->deallocate_many(chain); } - - /// @endcond - - //!Marks previously allocated memory as free. Never throws. - void deallocate (void *addr) - { if (mp_header) mp_header->deallocate(addr); } - - //!Tries to find a previous named allocation address. Returns a memory - //!buffer and the object count. If not found returned pointer is 0. - //!Never throws. - template - std::pair find (char_ptr_holder_t name) - { return mp_header->template find(name); } - - //!Creates a named object or array in memory - //! - //!Allocates and constructs a T object or an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. If an array is being constructed all objects are - //!created using the same parameters given to this function. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> Throws boost::interprocess::bad_alloc if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and if an - //!array was being constructed, destructors of created objects are called - //!before freeing the memory. - template - typename segment_manager::template construct_proxy::type - construct(char_ptr_holder_t name) - { return mp_header->template construct(name); } - - //!Finds or creates a named object or array in memory - //! - //!Tries to find an object with the given name in memory. If - //!found, returns the pointer to this pointer. If the object is not found, - //!allocates and constructs a T object or an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. If an array is being constructed all objects are - //!created using the same parameters given to this function. - //! - //!-> Throws boost::interprocess::bad_alloc if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and if an - //!array was being constructed, destructors of created objects are called - //!before freeing the memory. - template - typename segment_manager::template construct_proxy::type - find_or_construct(char_ptr_holder_t name) - { return mp_header->template find_or_construct(name); } - - //!Creates a named object or array in memory - //! - //!Allocates and constructs a T object or an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. If an array is being constructed all objects are - //!created using the same parameters given to this function. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> Returns 0 if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and if an - //!array was being constructed, destructors of created objects are called - //!before freeing the memory. - template - typename segment_manager::template construct_proxy::type - construct(char_ptr_holder_t name, std::nothrow_t nothrow) - { return mp_header->template construct(name, nothrow); } - - //!Finds or creates a named object or array in memory - //! - //!Tries to find an object with the given name in memory. If - //!found, returns the pointer to this pointer. If the object is not found, - //!allocates and constructs a T object or an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. If an array is being constructed all objects are - //!created using the same parameters given to this function. - //! - //!-> Returns 0 if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and if an - //!array was being constructed, destructors of created objects are called - //!before freeing the memory. - template - typename segment_manager::template construct_proxy::type - find_or_construct(char_ptr_holder_t name, std::nothrow_t nothrow) - { return mp_header->template find_or_construct(name, nothrow); } - - //!Creates a named array from iterators in memory - //! - //!Allocates and constructs an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. Each element in the array is created using the - //!objects returned when dereferencing iterators as parameters - //!and incrementing all iterators for each element. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> Throws boost::interprocess::bad_alloc if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and - //!destructors of created objects are called before freeing the memory. - template - typename segment_manager::template construct_iter_proxy::type - construct_it(char_ptr_holder_t name) - { return mp_header->template construct_it(name); } - - //!Finds or creates a named array from iterators in memory - //! - //!Tries to find an object with the given name in memory. If - //!found, returns the pointer to this pointer. If the object is not found, - //!allocates and constructs an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. Each element in the array is created using the - //!objects returned when dereferencing iterators as parameters - //!and incrementing all iterators for each element. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> Throws boost::interprocess::bad_alloc if there is no available memory - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and - //!destructors of created objects are called before freeing the memory. - template - typename segment_manager::template construct_iter_proxy::type - find_or_construct_it(char_ptr_holder_t name) - { return mp_header->template find_or_construct_it(name); } - - //!Creates a named array from iterators in memory - //! - //!Allocates and constructs an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. Each element in the array is created using the - //!objects returned when dereferencing iterators as parameters - //!and incrementing all iterators for each element. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> If there is no available memory, returns 0. - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and - //!destructors of created objects are called before freeing the memory.*/ - template - typename segment_manager::template construct_iter_proxy::type - construct_it(char_ptr_holder_t name, std::nothrow_t nothrow) - { return mp_header->template construct_it(name, nothrow); } - - //!Finds or creates a named array from iterators in memory - //! - //!Tries to find an object with the given name in memory. If - //!found, returns the pointer to this pointer. If the object is not found, - //!allocates and constructs an array of T in memory, - //!associates this with the given name and returns a pointer to the - //!created object. Each element in the array is created using the - //!objects returned when dereferencing iterators as parameters - //!and incrementing all iterators for each element. - //! - //!-> If the name was previously used, returns 0. - //! - //!-> If there is no available memory, returns 0. - //! - //!-> If T's constructor throws, the function throws that exception. - //! - //!Memory is freed automatically if T's constructor throws and - //!destructors of created objects are called before freeing the memory.*/ - template - typename segment_manager::template construct_iter_proxy::type - find_or_construct_it(char_ptr_holder_t name, std::nothrow_t nothrow) - { return mp_header->template find_or_construct_it(name, nothrow); } - - //!Calls a functor and guarantees that no new construction, search or - //!destruction will be executed by any process while executing the object - //!function call. If the functor throws, this function throws. - template - void atomic_func(Func &f) - { mp_header->atomic_func(f); } - - //!Tries to call a functor guaranteeing that no new construction, search or - //!destruction will be executed by any process while executing the object - //!function call. If the atomic function can't be immediatelly executed - //!because the internal mutex is already locked, returns false. - //!If the functor throws, this function throws. - template - bool try_atomic_func(Func &f) - { return mp_header->try_atomic_func(f); } - - //!Destroys a named memory object or array. - //! - //!Finds the object with the given name, calls its destructors, - //!frees used memory and returns true. - //! - //!-> If the object is not found, it returns false. - //! - //!Exception Handling: - //! - //!When deleting a dynamically object or array, the Standard - //!does not guarantee that dynamically allocated memory, will be released. - //!Also, when deleting arrays, the Standard doesn't require calling - //!destructors for the rest of the objects if for one of them the destructor - //!terminated with an exception. - //! - //!Destroying an object: - //! - //!If the destructor throws, the memory will be freed and that exception - //!will be thrown. - //! - //!Destroying an array: - //! - //!When destroying an array, if a destructor throws, the rest of - //!destructors are called. If any of these throws, the exceptions are - //!ignored. The name association will be erased, memory will be freed and - //!the first exception will be thrown. This guarantees the unlocking of - //!mutexes and other resources. - //! - //!For all theses reasons, classes with throwing destructors are not - //!recommended. - template - bool destroy(const CharType *name) - { return mp_header->template destroy(name); } - - //!Destroys the unique instance of type T - //! - //!Calls the destructor, frees used memory and returns true. - //! - //!Exception Handling: - //! - //!When deleting a dynamically object, the Standard does not - //!guarantee that dynamically allocated memory will be released. - //! - //!Destroying an object: - //! - //!If the destructor throws, the memory will be freed and that exception - //!will be thrown. - //! - //!For all theses reasons, classes with throwing destructors are not - //!recommended for memory. - template - bool destroy(const unique_instance_t *const ) - { return mp_header->template destroy(unique_instance); } - - //!Destroys the object (named, unique, or anonymous) - //! - //!Calls the destructor, frees used memory and returns true. - //! - //!Exception Handling: - //! - //!When deleting a dynamically object, the Standard does not - //!guarantee that dynamically allocated memory will be released. - //! - //!Destroying an object: - //! - //!If the destructor throws, the memory will be freed and that exception - //!will be thrown. - //! - //!For all theses reasons, classes with throwing destructors are not - //!recommended for memory. - template - void destroy_ptr(const T *ptr) - { mp_header->template destroy_ptr(ptr); } - - //!Returns the name of an object created with construct/find_or_construct - //!functions. Does not throw - template - static const char_type *get_instance_name(const T *ptr) - { return segment_manager::get_instance_name(ptr); } - - //!Returns is the type an object created with construct/find_or_construct - //!functions. Does not throw. - template - static instance_type get_instance_type(const T *ptr) - { return segment_manager::get_instance_type(ptr); } - - //!Returns the length of an object created with construct/find_or_construct - //!functions (1 if is a single element, >=1 if it's an array). Does not throw. - template - static size_type get_instance_length(const T *ptr) - { return segment_manager::get_instance_length(ptr); } - - //!Preallocates needed index resources to optimize the - //!creation of "num" named objects in the memory segment. - //!Can throw boost::interprocess::bad_alloc if there is no enough memory. - void reserve_named_objects(size_type num) - { mp_header->reserve_named_objects(num); } - - //!Preallocates needed index resources to optimize the - //!creation of "num" unique objects in the memory segment. - //!Can throw boost::interprocess::bad_alloc if there is no enough memory. - void reserve_unique_objects(size_type num) - { mp_header->reserve_unique_objects(num); } - - //!Calls shrink_to_fit in both named and unique object indexes - //to try to free unused memory from those indexes. - void shrink_to_fit_indexes() - { mp_header->shrink_to_fit_indexes(); } - - //!Returns the number of named objects stored - //!in the managed segment. - size_type get_num_named_objects() - { return mp_header->get_num_named_objects(); } - - //!Returns the number of unique objects stored - //!in the managed segment. - size_type get_num_unique_objects() - { return mp_header->get_num_unique_objects(); } - - //!Returns a constant iterator to the index storing the - //!named allocations. NOT thread-safe. Never throws. - const_named_iterator named_begin() const - { return mp_header->named_begin(); } - - //!Returns a constant iterator to the end of the index - //!storing the named allocations. NOT thread-safe. Never throws. - const_named_iterator named_end() const - { return mp_header->named_end(); } - - //!Returns a constant iterator to the index storing the - //!unique allocations. NOT thread-safe. Never throws. - const_unique_iterator unique_begin() const - { return mp_header->unique_begin(); } - - //!Returns a constant iterator to the end of the index - //!storing the unique allocations. NOT thread-safe. Never throws. - const_unique_iterator unique_end() const - { return mp_header->unique_end(); } - - //!This is the default allocator to allocate types T - //!from this managed segment - template - struct allocator - { - typedef typename segment_manager::template allocator::type type; - }; - - //!Returns an instance of the default allocator for type T - //!initialized that allocates memory from this segment manager. - template - typename allocator::type - get_allocator() - { return mp_header->template get_allocator(); } - - //!This is the default deleter to delete types T - //!from this managed segment. - template - struct deleter - { - typedef typename segment_manager::template deleter::type type; - }; - - //!Returns an instance of the default allocator for type T - //!initialized that allocates memory from this segment manager. - template - typename deleter::type - get_deleter() - { return mp_header->template get_deleter(); } - - /// @cond - //!Tries to find a previous named allocation address. Returns a memory - //!buffer and the object count. If not found returned pointer is 0. - //!Never throws. - template - std::pair find_no_lock (char_ptr_holder_t name) - { return mp_header->template find_no_lock(name); } - /// @endcond - - protected: - //!Swaps the segment manager's managed by this managed memory segment. - //!NOT thread-safe. Never throws. - void swap(basic_managed_memory_impl &other) - { std::swap(mp_header, other.mp_header); } - - private: - segment_manager *mp_header; -}; - -template -class create_open_func -{ - typedef typename BasicManagedMemoryImpl::size_type size_type; - - public: - - create_open_func(BasicManagedMemoryImpl * const frontend, create_enum_t type) - : m_frontend(frontend), m_type(type){} - - bool operator()(void *addr, std::size_t size, bool created) const - { - if( ((m_type == DoOpen) && created) || - ((m_type == DoCreate) && !created) || - //Check for overflow - size_type(-1) < size ){ - return false; - } - else if(created){ - return m_frontend->create_impl(addr, static_cast(size)); - } - else{ - return m_frontend->open_impl (addr, static_cast(size)); - } - } - - std::size_t get_min_size() const - { - const size_type sz = m_frontend->get_segment_manager()->get_min_size(); - if(sz > std::size_t(-1)){ - //The minimum size is not representable by std::size_t - BOOST_ASSERT(false); - return std::size_t(-1); - } - else{ - return static_cast(sz); - } - } - - private: - BasicManagedMemoryImpl *m_frontend; - create_enum_t m_type; -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_MANAGED_MEMORY_IMPL_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_open_or_create_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_open_or_create_impl.hpp deleted file mode 100644 index 948b4f4b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/managed_open_or_create_impl.hpp +++ /dev/null @@ -1,493 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2006-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MANAGED_OPEN_OR_CREATE_IMPL -#define BOOST_INTERPROCESS_MANAGED_OPEN_OR_CREATE_IMPL - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { - -/// @cond -namespace ipcdetail{ class interprocess_tester; } - - -template -struct managed_open_or_create_impl_device_id_t -{ - typedef const char *type; -}; - -#ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - -class xsi_shared_memory_file_wrapper; -class xsi_key; - -template<> -struct managed_open_or_create_impl_device_id_t -{ - typedef xsi_key type; -}; - -#endif //BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - -/// @endcond - -namespace ipcdetail { - - -template -class managed_open_or_create_impl_device_holder -{ - public: - DeviceAbstraction &get_device() - { static DeviceAbstraction dev; return dev; } - - const DeviceAbstraction &get_device() const - { static DeviceAbstraction dev; return dev; } -}; - -template -class managed_open_or_create_impl_device_holder -{ - public: - DeviceAbstraction &get_device() - { return dev; } - - const DeviceAbstraction &get_device() const - { return dev; } - - private: - DeviceAbstraction dev; -}; - -template -class managed_open_or_create_impl - : public managed_open_or_create_impl_device_holder -{ - //Non-copyable - BOOST_MOVABLE_BUT_NOT_COPYABLE(managed_open_or_create_impl) - - typedef typename managed_open_or_create_impl_device_id_t::type device_id_t; - typedef managed_open_or_create_impl_device_holder DevHolder; - enum - { - UninitializedSegment, - InitializingSegment, - InitializedSegment, - CorruptedSegment - }; - - public: - static const std::size_t - ManagedOpenOrCreateUserOffset = - ct_rounded_size - < sizeof(boost::uint32_t) - , MemAlignment ? (MemAlignment) : - (::boost::alignment_of< ::boost::detail::max_align >::value) - >::value; - - managed_open_or_create_impl() - {} - - managed_open_or_create_impl(create_only_t, - const device_id_t & id, - std::size_t size, - mode_t mode, - const void *addr, - const permissions &perm) - { - priv_open_or_create - ( DoCreate - , id - , size - , mode - , addr - , perm - , null_mapped_region_function()); - } - - managed_open_or_create_impl(open_only_t, - const device_id_t & id, - mode_t mode, - const void *addr) - { - priv_open_or_create - ( DoOpen - , id - , 0 - , mode - , addr - , permissions() - , null_mapped_region_function()); - } - - - managed_open_or_create_impl(open_or_create_t, - const device_id_t & id, - std::size_t size, - mode_t mode, - const void *addr, - const permissions &perm) - { - priv_open_or_create - ( DoOpenOrCreate - , id - , size - , mode - , addr - , perm - , null_mapped_region_function()); - } - - template - managed_open_or_create_impl(create_only_t, - const device_id_t & id, - std::size_t size, - mode_t mode, - const void *addr, - const ConstructFunc &construct_func, - const permissions &perm) - { - priv_open_or_create - (DoCreate - , id - , size - , mode - , addr - , perm - , construct_func); - } - - template - managed_open_or_create_impl(open_only_t, - const device_id_t & id, - mode_t mode, - const void *addr, - const ConstructFunc &construct_func) - { - priv_open_or_create - ( DoOpen - , id - , 0 - , mode - , addr - , permissions() - , construct_func); - } - - template - managed_open_or_create_impl(open_or_create_t, - const device_id_t & id, - std::size_t size, - mode_t mode, - const void *addr, - const ConstructFunc &construct_func, - const permissions &perm) - { - priv_open_or_create - ( DoOpenOrCreate - , id - , size - , mode - , addr - , perm - , construct_func); - } - - managed_open_or_create_impl(BOOST_RV_REF(managed_open_or_create_impl) moved) - { this->swap(moved); } - - managed_open_or_create_impl &operator=(BOOST_RV_REF(managed_open_or_create_impl) moved) - { - managed_open_or_create_impl tmp(boost::move(moved)); - this->swap(tmp); - return *this; - } - - ~managed_open_or_create_impl() - {} - - std::size_t get_user_size() const - { return m_mapped_region.get_size() - ManagedOpenOrCreateUserOffset; } - - void *get_user_address() const - { return static_cast(m_mapped_region.get_address()) + ManagedOpenOrCreateUserOffset; } - - std::size_t get_real_size() const - { return m_mapped_region.get_size(); } - - void *get_real_address() const - { return m_mapped_region.get_address(); } - - void swap(managed_open_or_create_impl &other) - { - this->m_mapped_region.swap(other.m_mapped_region); - } - - bool flush() - { return m_mapped_region.flush(); } - - const mapped_region &get_mapped_region() const - { return m_mapped_region; } - - - DeviceAbstraction &get_device() - { return this->DevHolder::get_device(); } - - const DeviceAbstraction &get_device() const - { return this->DevHolder::get_device(); } - - private: - - //These are templatized to allow explicit instantiations - template - static void truncate_device(DeviceAbstraction &, offset_t, false_) - {} //Empty - - template - static void truncate_device(DeviceAbstraction &dev, offset_t size, true_) - { dev.truncate(size); } - - - template - static bool check_offset_t_size(std::size_t , false_) - { return true; } //Empty - - template - static bool check_offset_t_size(std::size_t size, true_) - { return size == std::size_t(offset_t(size)); } - - //These are templatized to allow explicit instantiations - template - static void create_device(DeviceAbstraction &dev, const device_id_t & id, std::size_t size, const permissions &perm, false_ file_like) - { - (void)file_like; - DeviceAbstraction tmp(create_only, id, read_write, size, perm); - tmp.swap(dev); - } - - template - static void create_device(DeviceAbstraction &dev, const device_id_t & id, std::size_t, const permissions &perm, true_ file_like) - { - (void)file_like; - DeviceAbstraction tmp(create_only, id, read_write, perm); - tmp.swap(dev); - } - - template inline - void priv_open_or_create - (create_enum_t type, - const device_id_t & id, - std::size_t size, - mode_t mode, const void *addr, - const permissions &perm, - ConstructFunc construct_func) - { - typedef bool_ file_like_t; - (void)mode; - error_info err; - bool created = false; - bool ronly = false; - bool cow = false; - DeviceAbstraction dev; - - if(type != DoOpen){ - //Check if the requested size is enough to build the managed metadata - const std::size_t func_min_size = construct_func.get_min_size(); - if( (std::size_t(-1) - ManagedOpenOrCreateUserOffset) < func_min_size || - size < (func_min_size + ManagedOpenOrCreateUserOffset) ){ - throw interprocess_exception(error_info(size_error)); - } - } - //Check size can be represented by offset_t (used by truncate) - if(type != DoOpen && !check_offset_t_size(size, file_like_t())){ - throw interprocess_exception(error_info(size_error)); - } - if(type == DoOpen && mode == read_write){ - DeviceAbstraction tmp(open_only, id, read_write); - tmp.swap(dev); - created = false; - } - else if(type == DoOpen && mode == read_only){ - DeviceAbstraction tmp(open_only, id, read_only); - tmp.swap(dev); - created = false; - ronly = true; - } - else if(type == DoOpen && mode == copy_on_write){ - DeviceAbstraction tmp(open_only, id, read_only); - tmp.swap(dev); - created = false; - cow = true; - } - else if(type == DoCreate){ - create_device(dev, id, size, perm, file_like_t()); - created = true; - } - else if(type == DoOpenOrCreate){ - //This loop is very ugly, but brute force is sometimes better - //than diplomacy. If someone knows how to open or create a - //file and know if we have really created it or just open it - //drop me a e-mail! - bool completed = false; - spin_wait swait; - while(!completed){ - try{ - create_device(dev, id, size, perm, file_like_t()); - created = true; - completed = true; - } - catch(interprocess_exception &ex){ - if(ex.get_error_code() != already_exists_error){ - throw; - } - else{ - try{ - DeviceAbstraction tmp(open_only, id, read_write); - dev.swap(tmp); - created = false; - completed = true; - } - catch(interprocess_exception &e){ - if(e.get_error_code() != not_found_error){ - throw; - } - } - catch(...){ - throw; - } - } - } - catch(...){ - throw; - } - swait.yield(); - } - } - - if(created){ - try{ - //If this throws, we are lost - truncate_device(dev, size, file_like_t()); - - //If the following throws, we will truncate the file to 1 - mapped_region region(dev, read_write, 0, 0, addr); - boost::uint32_t *patomic_word = 0; //avoid gcc warning - patomic_word = static_cast(region.get_address()); - boost::uint32_t previous = atomic_cas32(patomic_word, InitializingSegment, UninitializedSegment); - - if(previous == UninitializedSegment){ - try{ - construct_func( static_cast(region.get_address()) + ManagedOpenOrCreateUserOffset - , size - ManagedOpenOrCreateUserOffset, true); - //All ok, just move resources to the external mapped region - m_mapped_region.swap(region); - } - catch(...){ - atomic_write32(patomic_word, CorruptedSegment); - throw; - } - atomic_write32(patomic_word, InitializedSegment); - } - else if(previous == InitializingSegment || previous == InitializedSegment){ - throw interprocess_exception(error_info(already_exists_error)); - } - else{ - throw interprocess_exception(error_info(corrupted_error)); - } - } - catch(...){ - try{ - truncate_device(dev, 1u, file_like_t()); - } - catch(...){ - } - throw; - } - } - else{ - if(FileBased){ - offset_t filesize = 0; - spin_wait swait; - while(filesize == 0){ - if(!get_file_size(file_handle_from_mapping_handle(dev.get_mapping_handle()), filesize)){ - throw interprocess_exception(error_info(system_error_code())); - } - swait.yield(); - } - if(filesize == 1){ - throw interprocess_exception(error_info(corrupted_error)); - } - } - - mapped_region region(dev, ronly ? read_only : (cow ? copy_on_write : read_write), 0, 0, addr); - - boost::uint32_t *patomic_word = static_cast(region.get_address()); - boost::uint32_t value = atomic_read32(patomic_word); - - spin_wait swait; - while(value == InitializingSegment || value == UninitializedSegment){ - swait.yield(); - value = atomic_read32(patomic_word); - } - - if(value != InitializedSegment) - throw interprocess_exception(error_info(corrupted_error)); - - construct_func( static_cast(region.get_address()) + ManagedOpenOrCreateUserOffset - , region.get_size() - ManagedOpenOrCreateUserOffset - , false); - //All ok, just move resources to the external mapped region - m_mapped_region.swap(region); - } - if(StoreDevice){ - this->DevHolder::get_device() = boost::move(dev); - } - } - - friend void swap(managed_open_or_create_impl &left, managed_open_or_create_impl &right) - { - left.swap(right); - } - - private: - friend class interprocess_tester; - void dont_close_on_destruction() - { interprocess_tester::dont_close_on_destruction(m_mapped_region); } - - mapped_region m_mapped_region; -}; - -} //namespace ipcdetail { - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_MANAGED_OPEN_OR_CREATE_IMPL diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/math_functions.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/math_functions.hpp deleted file mode 100644 index 20922b39..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/math_functions.hpp +++ /dev/null @@ -1,110 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Stephen Cleary 2000. -// (C) Copyright Ion Gaztanaga 2007-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -// This file is a slightly modified file from Boost.Pool -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_MATH_FUNCTIONS_HPP -#define BOOST_INTERPROCESS_DETAIL_MATH_FUNCTIONS_HPP - -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -// Greatest common divisor and least common multiple - -// -// gcd is an algorithm that calculates the greatest common divisor of two -// integers, using Euclid's algorithm. -// -// Pre: A > 0 && B > 0 -// Recommended: A > B -template -inline Integer gcd(Integer A, Integer B) -{ - do - { - const Integer tmp(B); - B = A % B; - A = tmp; - } while (B != 0); - - return A; -} - -// -// lcm is an algorithm that calculates the least common multiple of two -// integers. -// -// Pre: A > 0 && B > 0 -// Recommended: A > B -template -inline Integer lcm(const Integer & A, const Integer & B) -{ - Integer ret = A; - ret /= gcd(A, B); - ret *= B; - return ret; -} - -template -inline Integer log2_ceil(const Integer & A) -{ - Integer i = 0; - Integer power_of_2 = 1; - - while(power_of_2 < A){ - power_of_2 <<= 1; - ++i; - } - return i; -} - -template -inline Integer upper_power_of_2(const Integer & A) -{ - Integer power_of_2 = 1; - - while(power_of_2 < A){ - power_of_2 <<= 1; - } - return power_of_2; -} - -//This function uses binary search to discover the -//highest set bit of the integer -inline std::size_t floor_log2 (std::size_t x) -{ - const std::size_t Bits = sizeof(std::size_t)*CHAR_BIT; - const bool Size_t_Bits_Power_2= !(Bits & (Bits-1)); - BOOST_STATIC_ASSERT(((Size_t_Bits_Power_2)== true)); - - std::size_t n = x; - std::size_t log2 = 0; - - for(std::size_t shift = Bits >> 1; shift; shift >>= 1){ - std::size_t tmp = n >> shift; - if (tmp) - log2 += shift, n = tmp; - } - - return log2; -} - -} // namespace ipcdetail -} // namespace interprocess -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/min_max.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/min_max.hpp deleted file mode 100644 index 63ce7efd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/min_max.hpp +++ /dev/null @@ -1,40 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_MIN_MAX_HPP -#define BOOST_INTERPROCESS_DETAIL_MIN_MAX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -namespace boost { -namespace interprocess { - -template -const T &max_value(const T &a, const T &b) -{ return a > b ? a : b; } - -template -const T &min_value(const T &a, const T &b) -{ return a < b ? a : b; } - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_MIN_MAX_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/mpl.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/mpl.hpp deleted file mode 100644 index 4c5e1f1b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/mpl.hpp +++ /dev/null @@ -1,152 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_MPL_HPP -#define BOOST_INTERPROCESS_DETAIL_MPL_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -template -struct integral_constant -{ - static const T value = val; - typedef integral_constant type; -}; - -template< bool C_ > -struct bool_ : integral_constant -{ - static const bool value = C_; -}; - -typedef bool_ true_; -typedef bool_ false_; - -typedef true_ true_type; -typedef false_ false_type; - -typedef char yes_type; -struct no_type -{ - char padding[8]; -}; - -template -struct enable_if_c { - typedef T type; -}; - -template -struct enable_if_c {}; - -template -struct enable_if : public enable_if_c {}; - -template -struct disable_if : public enable_if_c {}; - -template -class is_convertible -{ - typedef char true_t; - class false_t { char dummy[2]; }; - static true_t dispatch(U); - static false_t dispatch(...); - static T trigger(); - public: - static const bool value = sizeof(dispatch(trigger())) == sizeof(true_t); -}; - -template< - bool C - , typename T1 - , typename T2 - > -struct if_c -{ - typedef T1 type; -}; - -template< - typename T1 - , typename T2 - > -struct if_c -{ - typedef T2 type; -}; - -template< - typename T1 - , typename T2 - , typename T3 - > -struct if_ -{ - typedef typename if_c<0 != T1::value, T2, T3>::type type; -}; - - -template -struct select1st -// : public std::unary_function -{ - template - const typename Pair::first_type& operator()(const OtherPair& x) const - { return x.first; } - - const typename Pair::first_type& operator()(const typename Pair::first_type& x) const - { return x; } -}; - -// identity is an extension: it is not part of the standard. -template -struct identity -// : public std::unary_function -{ - typedef T type; - const T& operator()(const T& x) const - { return x; } -}; - -template -struct ls_zeros -{ - static const std::size_t value = (S & std::size_t(1)) ? 0 : (1u + ls_zeros<(S >> 1u)>::value); -}; - -template<> -struct ls_zeros<0> -{ - static const std::size_t value = 0; -}; - -template<> -struct ls_zeros<1> -{ - static const std::size_t value = 0; -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_MPL_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/named_proxy.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/named_proxy.hpp deleted file mode 100644 index 14a9aa0a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/named_proxy.hpp +++ /dev/null @@ -1,349 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_NAMED_PROXY_HPP -#define BOOST_INTERPROCESS_NAMED_PROXY_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include - -#ifndef BOOST_INTERPROCESS_PERFECT_FORWARDING -#include -#else -#include -#include -#endif //#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING - -//!\file -//!Describes a proxy class that implements named allocation syntax. - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING - -template -struct CtorNArg : public placement_destroy -{ - typedef bool_ IsIterator; - typedef CtorNArg self_t; - typedef typename build_number_seq::type index_tuple_t; - - self_t& operator++() - { - this->do_increment(IsIterator(), index_tuple_t()); - return *this; - } - - self_t operator++(int) { return ++*this; *this; } - - CtorNArg(Args && ...args) - : args_(args...) - {} - - virtual void construct_n(void *mem - , std::size_t num - , std::size_t &constructed) - { - T* memory = static_cast(mem); - for(constructed = 0; constructed < num; ++constructed){ - this->construct(memory++, IsIterator(), index_tuple_t()); - this->do_increment(IsIterator(), index_tuple_t()); - } - } - - private: - template - void construct(void *mem, true_, const index_tuple&) - { new((void*)mem)T(*boost::forward(get(args_))...); } - - template - void construct(void *mem, false_, const index_tuple&) - { new((void*)mem)T(boost::forward(get(args_))...); } - - template - void do_increment(true_, const index_tuple&) - { - this->expansion_helper(++get(args_)...); - } - - template - void expansion_helper(ExpansionArgs &&...) - {} - - template - void do_increment(false_, const index_tuple&) - {} - - tuple args_; -}; - -//!Describes a proxy class that implements named -//!allocation syntax. -template - < class SegmentManager //segment manager to construct the object - , class T //type of object to build - , bool is_iterator //passing parameters are normal object or iterators? - > -class named_proxy -{ - typedef typename SegmentManager::char_type char_type; - const char_type * mp_name; - SegmentManager * mp_mngr; - mutable std::size_t m_num; - const bool m_find; - const bool m_dothrow; - - public: - named_proxy(SegmentManager *mngr, const char_type *name, bool find, bool dothrow) - : mp_name(name), mp_mngr(mngr), m_num(1) - , m_find(find), m_dothrow(dothrow) - {} - - template - T *operator()(Args &&...args) const - { - CtorNArg &&ctor_obj = CtorNArg - (boost::forward(args)...); - return mp_mngr->template - generic_construct(mp_name, m_num, m_find, m_dothrow, ctor_obj); - } - - //This operator allows --> named_new("Name")[3]; <-- syntax - const named_proxy &operator[](std::size_t num) const - { m_num *= num; return *this; } -}; - -#else //#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING - -//!Function object that makes placement new -//!without arguments -template -struct Ctor0Arg : public placement_destroy -{ - typedef Ctor0Arg self_t; - - Ctor0Arg(){} - - self_t& operator++() { return *this; } - self_t operator++(int) { return *this; } - - void construct(void *mem) - { new((void*)mem)T; } - - virtual void construct_n(void *mem, std::size_t num, std::size_t &constructed) - { - T* memory = static_cast(mem); - for(constructed = 0; constructed < num; ++constructed) - new((void*)memory++)T; - } -}; - -//////////////////////////////////////////////////////////////// -// What the macro should generate (n == 2): -// -// template -// struct Ctor2Arg -// : public placement_destroy -// { -// typedef bool_ IsIterator; -// typedef Ctor2Arg self_t; -// -// void do_increment(false_) -// { ++m_p1; ++m_p2; } -// -// void do_increment(true_){} -// -// self_t& operator++() -// { -// this->do_increment(IsIterator()); -// return *this; -// } -// -// self_t operator++(int) { return ++*this; *this; } -// -// Ctor2Arg(const P1 &p1, const P2 &p2) -// : p1((P1 &)p_1), p2((P2 &)p_2) {} -// -// void construct(void *mem) -// { new((void*)object)T(m_p1, m_p2); } -// -// virtual void construct_n(void *mem -// , std::size_t num -// , std::size_t &constructed) -// { -// T* memory = static_cast(mem); -// for(constructed = 0; constructed < num; ++constructed){ -// this->construct(memory++, IsIterator()); -// this->do_increment(IsIterator()); -// } -// } -// -// private: -// void construct(void *mem, true_) -// { new((void*)mem)T(*m_p1, *m_p2); } -// -// void construct(void *mem, false_) -// { new((void*)mem)T(m_p1, m_p2); } -// -// P1 &m_p1; P2 &m_p2; -// }; -//////////////////////////////////////////////////////////////// - -//Note: -//We define template parameters as const references to -//be able to bind temporaries. After that we will un-const them. -//This cast is ugly but it is necessary until "perfect forwarding" -//is achieved in C++0x. Meanwhile, if we want to be able to -//bind lvalues with non-const references, we have to be ugly -#define BOOST_PP_LOCAL_MACRO(n) \ - template \ - struct BOOST_PP_CAT(BOOST_PP_CAT(Ctor, n), Arg) \ - : public placement_destroy \ - { \ - typedef bool_ IsIterator; \ - typedef BOOST_PP_CAT(BOOST_PP_CAT(Ctor, n), Arg) self_t; \ - \ - void do_increment(true_) \ - { BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_PARAM_INC, _); } \ - \ - void do_increment(false_){} \ - \ - self_t& operator++() \ - { \ - this->do_increment(IsIterator()); \ - return *this; \ - } \ - \ - self_t operator++(int) { return ++*this; *this; } \ - \ - BOOST_PP_CAT(BOOST_PP_CAT(Ctor, n), Arg) \ - ( BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_PARAM_LIST, _) ) \ - : BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_PARAM_INIT, _) {} \ - \ - virtual void construct_n(void *mem \ - , std::size_t num \ - , std::size_t &constructed) \ - { \ - T* memory = static_cast(mem); \ - for(constructed = 0; constructed < num; ++constructed){ \ - this->construct(memory++, IsIterator()); \ - this->do_increment(IsIterator()); \ - } \ - } \ - \ - private: \ - void construct(void *mem, true_) \ - { \ - new((void*)mem) T \ - (BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_MEMBER_IT_FORWARD, _)); \ - } \ - \ - void construct(void *mem, false_) \ - { \ - new((void*)mem) T \ - (BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_MEMBER_FORWARD, _)); \ - } \ - \ - BOOST_PP_REPEAT(n, BOOST_INTERPROCESS_PP_PARAM_DEFINE, _) \ - }; \ -//! -#define BOOST_PP_LOCAL_LIMITS (1, BOOST_INTERPROCESS_MAX_CONSTRUCTOR_PARAMETERS) -#include BOOST_PP_LOCAL_ITERATE() - -//!Describes a proxy class that implements named -//!allocation syntax. -template - < class SegmentManager //segment manager to construct the object - , class T //type of object to build - , bool is_iterator //passing parameters are normal object or iterators? - > -class named_proxy -{ - typedef typename SegmentManager::char_type char_type; - const char_type * mp_name; - SegmentManager * mp_mngr; - mutable std::size_t m_num; - const bool m_find; - const bool m_dothrow; - - public: - named_proxy(SegmentManager *mngr, const char_type *name, bool find, bool dothrow) - : mp_name(name), mp_mngr(mngr), m_num(1) - , m_find(find), m_dothrow(dothrow) - {} - - //!makes a named allocation and calls the - //!default constructor - T *operator()() const - { - Ctor0Arg ctor_obj; - return mp_mngr->template - generic_construct(mp_name, m_num, m_find, m_dothrow, ctor_obj); - } - //! - - #define BOOST_PP_LOCAL_MACRO(n) \ - template \ - T *operator()(BOOST_PP_ENUM (n, BOOST_INTERPROCESS_PP_PARAM_LIST, _)) const\ - { \ - typedef BOOST_PP_CAT(BOOST_PP_CAT(Ctor, n), Arg) \ - \ - ctor_obj_t; \ - ctor_obj_t ctor_obj \ - (BOOST_PP_ENUM(n, BOOST_INTERPROCESS_PP_PARAM_FORWARD, _)); \ - return mp_mngr->template generic_construct \ - (mp_name, m_num, m_find, m_dothrow, ctor_obj); \ - } \ - //! - - #define BOOST_PP_LOCAL_LIMITS ( 1, BOOST_INTERPROCESS_MAX_CONSTRUCTOR_PARAMETERS ) - #include BOOST_PP_LOCAL_ITERATE() - - //////////////////////////////////////////////////////////////////////// - // What the macro should generate (n == 2) - //////////////////////////////////////////////////////////////////////// - // - // template - // T *operator()(P1 &p1, P2 &p2) const - // { - // typedef Ctor2Arg - // - // ctor_obj_t; - // ctor_obj_t ctor_obj(p1, p2); - // - // return mp_mngr->template generic_construct - // (mp_name, m_num, m_find, m_dothrow, ctor_obj); - // } - // - ////////////////////////////////////////////////////////////////////////// - - //This operator allows --> named_new("Name")[3]; <-- syntax - const named_proxy &operator[](std::size_t num) const - { m_num *= num; return *this; } -}; - -#endif //#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING - -}}} //namespace boost { namespace interprocess { namespace ipcdetail { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_NAMED_PROXY_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_file_functions.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_file_functions.hpp deleted file mode 100644 index 0bc97444..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_file_functions.hpp +++ /dev/null @@ -1,702 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_OS_FILE_FUNCTIONS_HPP -#define BOOST_INTERPROCESS_DETAIL_OS_FILE_FUNCTIONS_HPP - -#include -#include -#include -#include - -#include -#include -#include -#include - -#if (defined BOOST_INTERPROCESS_WINDOWS) -# include -#else -# ifdef BOOST_HAS_UNISTD_H -# include -# include -# include -# include -# include -# include -# include -# if 0 -# include -# endif -# else -# error Unknown platform -# endif -#endif - -#include -#include - -namespace boost { -namespace interprocess { - -#if (defined BOOST_INTERPROCESS_WINDOWS) - -typedef void * file_handle_t; -typedef long long offset_t; -typedef struct mapping_handle_impl_t{ - void * handle; - bool is_shm; -} mapping_handle_t; - -typedef enum { read_only = winapi::generic_read - , read_write = winapi::generic_read | winapi::generic_write - , copy_on_write - , read_private - , invalid_mode = 0xffff - } mode_t; - -typedef enum { file_begin = winapi::file_begin - , file_end = winapi::file_end - , file_current = winapi::file_current - } file_pos_t; - -typedef unsigned long map_options_t; -static const map_options_t default_map_options = map_options_t(-1); - -namespace ipcdetail{ - -inline mapping_handle_t mapping_handle_from_file_handle(file_handle_t hnd) -{ - mapping_handle_t ret; - ret.handle = hnd; - ret.is_shm = false; - return ret; -} - -inline mapping_handle_t mapping_handle_from_shm_handle(file_handle_t hnd) -{ - mapping_handle_t ret; - ret.handle = hnd; - ret.is_shm = true; - return ret; -} - -inline file_handle_t file_handle_from_mapping_handle(mapping_handle_t hnd) -{ return hnd.handle; } - -inline bool create_directory(const char *path) -{ return winapi::create_directory(path); } - -inline const char *get_temporary_path() -{ return std::getenv("TMP"); } - - -inline file_handle_t create_new_file - (const char *name, mode_t mode, const permissions & perm = permissions(), bool temporary = false) -{ - unsigned long attr = temporary ? winapi::file_attribute_temporary : 0; - return winapi::create_file - ( name, (unsigned int)mode, winapi::create_new, attr - , (winapi::interprocess_security_attributes*)perm.get_permissions()); -} - -inline file_handle_t create_or_open_file - (const char *name, mode_t mode, const permissions & perm = permissions(), bool temporary = false) -{ - unsigned long attr = temporary ? winapi::file_attribute_temporary : 0; - return winapi::create_file - ( name, (unsigned int)mode, winapi::open_always, attr - , (winapi::interprocess_security_attributes*)perm.get_permissions()); -} - -inline file_handle_t open_existing_file - (const char *name, mode_t mode, bool temporary = false) -{ - unsigned long attr = temporary ? winapi::file_attribute_temporary : 0; - return winapi::create_file - (name, (unsigned int)mode, winapi::open_existing, attr, 0); -} - -inline bool delete_file(const char *name) -{ return winapi::unlink_file(name); } - -inline bool truncate_file (file_handle_t hnd, std::size_t size) -{ - offset_t filesize; - if(!winapi::get_file_size(hnd, filesize)) - return false; - - typedef boost::make_unsigned::type uoffset_t; - const uoffset_t max_filesize = uoffset_t((std::numeric_limits::max)()); - //Avoid unused variable warnings in 32 bit systems - if(size > max_filesize){ - winapi::set_last_error(winapi::error_file_too_large); - return false; - } - - if(offset_t(size) > filesize){ - if(!winapi::set_file_pointer_ex(hnd, filesize, 0, winapi::file_begin)){ - return false; - } - //We will write zeros in the end of the file - //since set_end_of_file does not guarantee this - for(std::size_t remaining = size - filesize, write_size = 0 - ;remaining > 0 - ;remaining -= write_size){ - const std::size_t DataSize = 512; - static char data [DataSize]; - write_size = DataSize < remaining ? DataSize : remaining; - unsigned long written; - winapi::write_file(hnd, data, (unsigned long)write_size, &written, 0); - if(written != write_size){ - return false; - } - } - } - else{ - if(!winapi::set_file_pointer_ex(hnd, size, 0, winapi::file_begin)){ - return false; - } - if(!winapi::set_end_of_file(hnd)){ - return false; - } - } - return true; -} - -inline bool get_file_size(file_handle_t hnd, offset_t &size) -{ return winapi::get_file_size(hnd, size); } - -inline bool set_file_pointer(file_handle_t hnd, offset_t off, file_pos_t pos) -{ return winapi::set_file_pointer_ex(hnd, off, 0, (unsigned long) pos); } - -inline bool get_file_pointer(file_handle_t hnd, offset_t &off) -{ return winapi::set_file_pointer_ex(hnd, 0, &off, winapi::file_current); } - -inline bool write_file(file_handle_t hnd, const void *data, std::size_t numdata) -{ - unsigned long written; - return 0 != winapi::write_file(hnd, data, (unsigned long)numdata, &written, 0); -} - -inline file_handle_t invalid_file() -{ return winapi::invalid_handle_value; } - -inline bool close_file(file_handle_t hnd) -{ return 0 != winapi::close_handle(hnd); } - -inline bool acquire_file_lock(file_handle_t hnd) -{ - static winapi::interprocess_overlapped overlapped; - const unsigned long len = ((unsigned long)-1); -// winapi::interprocess_overlapped overlapped; -// std::memset(&overlapped, 0, sizeof(overlapped)); - return winapi::lock_file_ex - (hnd, winapi::lockfile_exclusive_lock, 0, len, len, &overlapped); -} - -inline bool try_acquire_file_lock(file_handle_t hnd, bool &acquired) -{ - const unsigned long len = ((unsigned long)-1); - winapi::interprocess_overlapped overlapped; - std::memset(&overlapped, 0, sizeof(overlapped)); - if(!winapi::lock_file_ex - (hnd, winapi::lockfile_exclusive_lock | winapi::lockfile_fail_immediately, - 0, len, len, &overlapped)){ - return winapi::get_last_error() == winapi::error_lock_violation ? - acquired = false, true : false; - - } - return (acquired = true); -} - -inline bool release_file_lock(file_handle_t hnd) -{ - const unsigned long len = ((unsigned long)-1); - winapi::interprocess_overlapped overlapped; - std::memset(&overlapped, 0, sizeof(overlapped)); - return winapi::unlock_file_ex(hnd, 0, len, len, &overlapped); -} - -inline bool acquire_file_lock_sharable(file_handle_t hnd) -{ - const unsigned long len = ((unsigned long)-1); - winapi::interprocess_overlapped overlapped; - std::memset(&overlapped, 0, sizeof(overlapped)); - return winapi::lock_file_ex(hnd, 0, 0, len, len, &overlapped); -} - -inline bool try_acquire_file_lock_sharable(file_handle_t hnd, bool &acquired) -{ - const unsigned long len = ((unsigned long)-1); - winapi::interprocess_overlapped overlapped; - std::memset(&overlapped, 0, sizeof(overlapped)); - if(!winapi::lock_file_ex - (hnd, winapi::lockfile_fail_immediately, 0, len, len, &overlapped)){ - return winapi::get_last_error() == winapi::error_lock_violation ? - acquired = false, true : false; - } - return (acquired = true); -} - -inline bool release_file_lock_sharable(file_handle_t hnd) -{ return release_file_lock(hnd); } - -inline bool delete_subdirectories_recursive - (const std::string &refcstrRootDirectory, const char *dont_delete_this, unsigned int count) -{ - bool bSubdirectory = false; // Flag, indicating whether - // subdirectories have been found - void * hFile; // Handle to directory - std::string strFilePath; // Filepath - std::string strPattern; // Pattern - winapi::win32_find_data_t FileInformation; // File information - - //Find all files and directories - strPattern = refcstrRootDirectory + "\\*.*"; - hFile = winapi::find_first_file(strPattern.c_str(), &FileInformation); - if(hFile != winapi::invalid_handle_value){ - do{ - //If it's not "." or ".." or the pointed root_level dont_delete_this erase it - if(FileInformation.cFileName[0] != '.' && - !(dont_delete_this && count == 0 && std::strcmp(dont_delete_this, FileInformation.cFileName) == 0)){ - strFilePath.erase(); - strFilePath = refcstrRootDirectory + "\\" + FileInformation.cFileName; - - //If it's a directory, go recursive - if(FileInformation.dwFileAttributes & winapi::file_attribute_directory){ - // Delete subdirectory - if(!delete_subdirectories_recursive(strFilePath, dont_delete_this, count+1)) - return false; - } - //If it's a file, just delete it - else{ - // Set file attributes - //if(::SetFileAttributes(strFilePath.c_str(), winapi::file_attribute_normal) == 0) - //return winapi::get_last_error(); - // Delete file - winapi::unlink_file(strFilePath.c_str()); - } - } - //Go to the next file - } while(winapi::find_next_file(hFile, &FileInformation) == 1); - - // Close handle - winapi::find_close(hFile); - - //See if the loop has ended with an error or just because we've traversed all the files - if(winapi::get_last_error() != winapi::error_no_more_files){ - return false; - } - else - { - //Erase empty subdirectories or original refcstrRootDirectory - if(!bSubdirectory && count) - { - // Set directory attributes - //if(::SetFileAttributes(refcstrRootDirectory.c_str(), FILE_ATTRIBUTE_NORMAL) == 0) - //return ::GetLastError(); - // Delete directory - if(winapi::remove_directory(refcstrRootDirectory.c_str()) == 0) - return false; - } - } - } - return true; -} - -//This function erases all the subdirectories of a directory except the one pointed by "dont_delete_this" -inline bool delete_subdirectories(const std::string &refcstrRootDirectory, const char *dont_delete_this) -{ - return delete_subdirectories_recursive(refcstrRootDirectory, dont_delete_this, 0u); -} - - -template -inline bool for_each_file_in_dir(const char *dir, Function f) -{ - void * hFile; // Handle to directory - winapi::win32_find_data_t FileInformation; // File information - - //Get base directory - std::string str(dir); - const std::size_t base_root_dir_len = str.size(); - - //Find all files and directories - str += "\\*.*"; - hFile = winapi::find_first_file(str.c_str(), &FileInformation); - if(hFile != winapi::invalid_handle_value){ - do{ //Now loop every file - str.erase(base_root_dir_len); - //If it's not "." or ".." skip it - if(FileInformation.cFileName[0] != '.'){ - str += "\\"; str += FileInformation.cFileName; - //If it's a file, apply erase logic - if(!(FileInformation.dwFileAttributes & winapi::file_attribute_directory)){ - f(str.c_str(), FileInformation.cFileName); - } - } - //Go to the next file - } while(winapi::find_next_file(hFile, &FileInformation) == 1); - - // Close handle and see if the loop has ended with an error - winapi::find_close(hFile); - if(winapi::get_last_error() != winapi::error_no_more_files){ - return false; - } - } - return true; -} - - -#else //#if (defined BOOST_INTERPROCESS_WINDOWS) - -typedef int file_handle_t; -typedef off_t offset_t; - -typedef struct mapping_handle_impl_t -{ - file_handle_t handle; - bool is_xsi; -} mapping_handle_t; - -typedef enum { read_only = O_RDONLY - , read_write = O_RDWR - , copy_on_write - , read_private - , invalid_mode = 0xffff - } mode_t; - -typedef enum { file_begin = SEEK_SET - , file_end = SEEK_END - , file_current = SEEK_CUR - } file_pos_t; - -typedef int map_options_t; -static const map_options_t default_map_options = map_options_t(-1); - -namespace ipcdetail{ - -inline mapping_handle_t mapping_handle_from_file_handle(file_handle_t hnd) -{ - mapping_handle_t ret; - ret.handle = hnd; - ret.is_xsi = false; - return ret; -} - -inline file_handle_t file_handle_from_mapping_handle(mapping_handle_t hnd) -{ return hnd.handle; } - -inline bool create_directory(const char *path) -{ return ::mkdir(path, 0777) == 0 && ::chmod(path, 0777) == 0; } - -inline const char *get_temporary_path() -{ - const char *names[] = {"/tmp", "TMPDIR", "TMP", "TEMP" }; - const int names_size = sizeof(names)/sizeof(names[0]); - struct stat data; - for(int i = 0; i != names_size; ++i){ - if(::stat(names[i], &data) == 0){ - return names[i]; - } - } - return "/tmp"; -} - -inline file_handle_t create_new_file - (const char *name, mode_t mode, const permissions & perm = permissions(), bool temporary = false) -{ - (void)temporary; - int ret = ::open(name, ((int)mode) | O_EXCL | O_CREAT, perm.get_permissions()); - if(ret >= 0){ - ::fchmod(ret, perm.get_permissions()); - } - return ret; -} - -inline file_handle_t create_or_open_file - (const char *name, mode_t mode, const permissions & perm = permissions(), bool temporary = false) -{ - (void)temporary; - int ret = -1; - //We need a loop to change permissions correctly using fchmod, since - //with "O_CREAT only" ::open we don't know if we've created or opened the file. - while(1){ - ret = ::open(name, ((int)mode) | O_EXCL | O_CREAT, perm.get_permissions()); - if(ret >= 0){ - ::fchmod(ret, perm.get_permissions()); - break; - } - else if(errno == EEXIST){ - if((ret = ::open(name, (int)mode)) >= 0 || errno != ENOENT){ - break; - } - } - } - return ret; -} - -inline file_handle_t open_existing_file - (const char *name, mode_t mode, bool temporary = false) -{ - (void)temporary; - return ::open(name, (int)mode); -} - -inline bool delete_file(const char *name) -{ return ::unlink(name) == 0; } - -inline bool truncate_file (file_handle_t hnd, std::size_t size) -{ - typedef boost::make_unsigned::type uoff_t; - if(uoff_t((std::numeric_limits::max)()) < size){ - errno = EINVAL; - return false; - } - return 0 == ::ftruncate(hnd, off_t(size)); -} - -inline bool get_file_size(file_handle_t hnd, offset_t &size) -{ - struct stat data; - bool ret = 0 == ::fstat(hnd, &data); - if(ret){ - size = data.st_size; - } - return ret; -} - -inline bool set_file_pointer(file_handle_t hnd, offset_t off, file_pos_t pos) -{ return ((off_t)(-1)) != ::lseek(hnd, off, (int)pos); } - -inline bool get_file_pointer(file_handle_t hnd, offset_t &off) -{ - off = ::lseek(hnd, 0, SEEK_CUR); - return off != ((off_t)-1); -} - -inline bool write_file(file_handle_t hnd, const void *data, std::size_t numdata) -{ return (ssize_t(numdata)) == ::write(hnd, data, numdata); } - -inline file_handle_t invalid_file() -{ return -1; } - -inline bool close_file(file_handle_t hnd) -{ return ::close(hnd) == 0; } - -inline bool acquire_file_lock(file_handle_t hnd) -{ - struct ::flock lock; - lock.l_type = F_WRLCK; - lock.l_whence = SEEK_SET; - lock.l_start = 0; - lock.l_len = 0; - return -1 != ::fcntl(hnd, F_SETLKW, &lock); -} - -inline bool try_acquire_file_lock(file_handle_t hnd, bool &acquired) -{ - struct ::flock lock; - lock.l_type = F_WRLCK; - lock.l_whence = SEEK_SET; - lock.l_start = 0; - lock.l_len = 0; - int ret = ::fcntl(hnd, F_SETLK, &lock); - if(ret == -1){ - return (errno == EAGAIN || errno == EACCES) ? - acquired = false, true : false; - } - return (acquired = true); -} - -inline bool release_file_lock(file_handle_t hnd) -{ - struct ::flock lock; - lock.l_type = F_UNLCK; - lock.l_whence = SEEK_SET; - lock.l_start = 0; - lock.l_len = 0; - return -1 != ::fcntl(hnd, F_SETLK, &lock); -} - -inline bool acquire_file_lock_sharable(file_handle_t hnd) -{ - struct ::flock lock; - lock.l_type = F_RDLCK; - lock.l_whence = SEEK_SET; - lock.l_start = 0; - lock.l_len = 0; - return -1 != ::fcntl(hnd, F_SETLKW, &lock); -} - -inline bool try_acquire_file_lock_sharable(file_handle_t hnd, bool &acquired) -{ - struct flock lock; - lock.l_type = F_RDLCK; - lock.l_whence = SEEK_SET; - lock.l_start = 0; - lock.l_len = 0; - int ret = ::fcntl(hnd, F_SETLK, &lock); - if(ret == -1){ - return (errno == EAGAIN || errno == EACCES) ? - acquired = false, true : false; - } - return (acquired = true); -} - -inline bool release_file_lock_sharable(file_handle_t hnd) -{ return release_file_lock(hnd); } - -#if 0 -inline bool acquire_file_lock(file_handle_t hnd) -{ return 0 == ::flock(hnd, LOCK_EX); } - -inline bool try_acquire_file_lock(file_handle_t hnd, bool &acquired) -{ - int ret = ::flock(hnd, LOCK_EX | LOCK_NB); - acquired = ret == 0; - return (acquired || errno == EWOULDBLOCK); -} - -inline bool release_file_lock(file_handle_t hnd) -{ return 0 == ::flock(hnd, LOCK_UN); } - -inline bool acquire_file_lock_sharable(file_handle_t hnd) -{ return 0 == ::flock(hnd, LOCK_SH); } - -inline bool try_acquire_file_lock_sharable(file_handle_t hnd, bool &acquired) -{ - int ret = ::flock(hnd, LOCK_SH | LOCK_NB); - acquired = ret == 0; - return (acquired || errno == EWOULDBLOCK); -} - -inline bool release_file_lock_sharable(file_handle_t hnd) -{ return 0 == ::flock(hnd, LOCK_UN); } -#endif - -inline bool delete_subdirectories_recursive - (const std::string &refcstrRootDirectory, const char *dont_delete_this) -{ - DIR *d = opendir(refcstrRootDirectory.c_str()); - if(!d) { - return false; - } - - struct dir_close - { - DIR *d_; - dir_close(DIR *d) : d_(d) {} - ~dir_close() { ::closedir(d_); } - } dc(d); (void)dc; - - struct ::dirent *de; - struct ::stat st; - std::string fn; - - while((de=::readdir(d))) { - if( de->d_name[0] == '.' && ( de->d_name[1] == '\0' - || (de->d_name[1] == '.' && de->d_name[2] == '\0' )) ){ - continue; - } - if(dont_delete_this && std::strcmp(dont_delete_this, de->d_name) == 0){ - continue; - } - fn = refcstrRootDirectory; - fn += '/'; - fn += de->d_name; - - if(std::remove(fn.c_str())) { - if(::stat(fn.c_str(), & st)) { - return false; - } - if(S_ISDIR(st.st_mode)) { - if(!delete_subdirectories_recursive(fn, 0) ){ - return false; - } - } else { - return false; - } - } - } - return std::remove(refcstrRootDirectory.c_str()) ? false : true; -} - -template -inline bool for_each_file_in_dir(const char *dir, Function f) -{ - std::string refcstrRootDirectory(dir); - - DIR *d = opendir(refcstrRootDirectory.c_str()); - if(!d) { - return false; - } - - struct dir_close - { - DIR *d_; - dir_close(DIR *d) : d_(d) {} - ~dir_close() { ::closedir(d_); } - } dc(d); (void)dc; - - struct ::dirent *de; - struct ::stat st; - std::string fn; - - while((de=::readdir(d))) { - if( de->d_name[0] == '.' && ( de->d_name[1] == '\0' - || (de->d_name[1] == '.' && de->d_name[2] == '\0' )) ){ - continue; - } - fn = refcstrRootDirectory; - fn += '/'; - fn += de->d_name; - - if(::stat(fn.c_str(), & st)) { - return false; - } - //If it's a file, apply erase logic - if(!S_ISDIR(st.st_mode)) { - f(fn.c_str(), de->d_name); - } - } - return true; -} - - -//This function erases all the subdirectories of a directory except the one pointed by "dont_delete_this" -inline bool delete_subdirectories(const std::string &refcstrRootDirectory, const char *dont_delete_this) -{ - return delete_subdirectories_recursive(refcstrRootDirectory, dont_delete_this ); -} - -#endif //#if (defined BOOST_INTERPROCESS_WINDOWS) - -inline bool open_or_create_directory(const char *dir_name) -{ - //If fails, check that it's because it already exists - if(!create_directory(dir_name)){ - error_info info(system_error_code()); - if(info.get_error_code() != already_exists_error){ - return false; - } - } - return true; -} - - -} //namespace ipcdetail{ -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_OS_FILE_FUNCTIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_thread_functions.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_thread_functions.hpp deleted file mode 100644 index eea4957a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/os_thread_functions.hpp +++ /dev/null @@ -1,570 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -//Thread launching functions are adapted from boost/detail/lightweight_thread.hpp -// -// boost/detail/lightweight_thread.hpp -// -// Copyright (c) 2002 Peter Dimov and Multi Media Ltd. -// Copyright (c) 2008 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt - -#ifndef BOOST_INTERPROCESS_DETAIL_OS_THREAD_FUNCTIONS_HPP -#define BOOST_INTERPROCESS_DETAIL_OS_THREAD_FUNCTIONS_HPP - -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_INTERPROCESS_WINDOWS) -# include -# include -#else -# include -# include -# include -# include -# ifdef BOOST_INTERPROCESS_BSD_DERIVATIVE - //Some *BSD systems (OpenBSD & NetBSD) need sys/param.h before sys/sysctl.h, whereas - //others (FreeBSD & Darwin) need sys/types.h -# include -# include -# include -# endif -//According to the article "C/C++ tip: How to measure elapsed real time for benchmarking" -# if defined(CLOCK_MONOTONIC_PRECISE) //BSD -# define BOOST_INTERPROCESS_CLOCK_MONOTONIC CLOCK_MONOTONIC_PRECISE -# elif defined(CLOCK_MONOTONIC_RAW) //Linux -# define BOOST_INTERPROCESS_CLOCK_MONOTONIC CLOCK_MONOTONIC_RAW -# elif defined(CLOCK_HIGHRES) //Solaris -# define BOOST_INTERPROCESS_CLOCK_MONOTONIC CLOCK_HIGHRES -# elif defined(CLOCK_MONOTONIC) //POSIX (AIX, BSD, Linux, Solaris) -# define BOOST_INTERPROCESS_CLOCK_MONOTONIC CLOCK_MONOTONIC -# elif !defined(CLOCK_MONOTONIC) && (defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) -# include // mach_absolute_time, mach_timebase_info_data_t -# define BOOST_INTERPROCESS_MATCH_ABSOLUTE_TIME -# else -# error "No high resolution steady clock in your system, please provide a patch" -# endif -#endif - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - -#if (defined BOOST_INTERPROCESS_WINDOWS) - -typedef unsigned long OS_process_id_t; -typedef unsigned long OS_thread_id_t; -typedef void* OS_thread_t; -typedef OS_thread_id_t OS_systemwide_thread_id_t; - -//process -inline OS_process_id_t get_current_process_id() -{ return winapi::get_current_process_id(); } - -inline OS_process_id_t get_invalid_process_id() -{ return OS_process_id_t(0); } - -//thread -inline OS_thread_id_t get_current_thread_id() -{ return winapi::get_current_thread_id(); } - -inline OS_thread_id_t get_invalid_thread_id() -{ return OS_thread_id_t(0xffffffff); } - -inline bool equal_thread_id(OS_thread_id_t id1, OS_thread_id_t id2) -{ return id1 == id2; } - -//return the system tick in ns -inline unsigned long get_system_tick_ns() -{ - unsigned long curres; - winapi::set_timer_resolution(10000, 0, &curres); - //Windows API returns the value in hundreds of ns - return (curres - 1ul)*100ul; -} - -//return the system tick in us -inline unsigned long get_system_tick_us() -{ - unsigned long curres; - winapi::set_timer_resolution(10000, 0, &curres); - //Windows API returns the value in hundreds of ns - return (curres - 1ul)/10ul + 1ul; -} - -typedef unsigned __int64 OS_highres_count_t; - -inline unsigned long get_system_tick_in_highres_counts() -{ - __int64 freq; - unsigned long curres; - winapi::set_timer_resolution(10000, 0, &curres); - //Frequency in counts per second - if(!winapi::query_performance_frequency(&freq)){ - //Tick resolution in ms - return (curres-1ul)/10000ul + 1ul; - } - else{ - //In femtoseconds - __int64 count_fs = (1000000000000000LL - 1LL)/freq + 1LL; - __int64 tick_counts = (static_cast<__int64>(curres)*100000000LL - 1LL)/count_fs + 1LL; - return static_cast(tick_counts); - } -} - -inline OS_highres_count_t get_current_system_highres_count() -{ - __int64 count; - if(!winapi::query_performance_counter(&count)){ - count = winapi::get_tick_count(); - } - return count; -} - -inline void zero_highres_count(OS_highres_count_t &count) -{ count = 0; } - -inline bool is_highres_count_zero(const OS_highres_count_t &count) -{ return count == 0; } - -template -inline Ostream &ostream_highres_count(Ostream &ostream, const OS_highres_count_t &count) -{ - ostream << count; - return ostream; -} - -inline OS_highres_count_t system_highres_count_subtract(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ return l - r; } - -inline bool system_highres_count_less(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ return l < r; } - -inline bool system_highres_count_less_ul(const OS_highres_count_t &l, unsigned long r) -{ return l < static_cast(r); } - -inline void thread_sleep_tick() -{ winapi::sleep_tick(); } - -inline void thread_yield() -{ winapi::sched_yield(); } - -inline void thread_sleep(unsigned int ms) -{ winapi::Sleep(ms); } - -//systemwide thread -inline OS_systemwide_thread_id_t get_current_systemwide_thread_id() -{ - return get_current_thread_id(); -} - -inline void systemwide_thread_id_copy - (const volatile OS_systemwide_thread_id_t &from, volatile OS_systemwide_thread_id_t &to) -{ - to = from; -} - -inline bool equal_systemwide_thread_id(const OS_systemwide_thread_id_t &id1, const OS_systemwide_thread_id_t &id2) -{ - return equal_thread_id(id1, id2); -} - -inline OS_systemwide_thread_id_t get_invalid_systemwide_thread_id() -{ - return get_invalid_thread_id(); -} - -inline long double get_current_process_creation_time() -{ - winapi::interprocess_filetime CreationTime, ExitTime, KernelTime, UserTime; - - get_process_times - ( winapi::get_current_process(), &CreationTime, &ExitTime, &KernelTime, &UserTime); - - typedef long double ldouble_t; - const ldouble_t resolution = (100.0l/1000000000.0l); - return CreationTime.dwHighDateTime*(ldouble_t(1u<<31u)*2.0l*resolution) + - CreationTime.dwLowDateTime*resolution; -} - -inline unsigned int get_num_cores() -{ - winapi::system_info sysinfo; - winapi::get_system_info( &sysinfo ); - //in Windows dw is long which is equal in bits to int - return static_cast(sysinfo.dwNumberOfProcessors); -} - -#else //#if (defined BOOST_INTERPROCESS_WINDOWS) - -typedef pthread_t OS_thread_t; -typedef pthread_t OS_thread_id_t; -typedef pid_t OS_process_id_t; - -struct OS_systemwide_thread_id_t -{ - OS_systemwide_thread_id_t() - : pid(), tid() - {} - - OS_systemwide_thread_id_t(pid_t p, pthread_t t) - : pid(p), tid(t) - {} - - OS_systemwide_thread_id_t(const OS_systemwide_thread_id_t &x) - : pid(x.pid), tid(x.tid) - {} - - OS_systemwide_thread_id_t(const volatile OS_systemwide_thread_id_t &x) - : pid(x.pid), tid(x.tid) - {} - - OS_systemwide_thread_id_t & operator=(const OS_systemwide_thread_id_t &x) - { pid = x.pid; tid = x.tid; return *this; } - - OS_systemwide_thread_id_t & operator=(const volatile OS_systemwide_thread_id_t &x) - { pid = x.pid; tid = x.tid; return *this; } - - void operator=(const OS_systemwide_thread_id_t &x) volatile - { pid = x.pid; tid = x.tid; } - - pid_t pid; - pthread_t tid; -}; - -inline void systemwide_thread_id_copy - (const volatile OS_systemwide_thread_id_t &from, volatile OS_systemwide_thread_id_t &to) -{ - to.pid = from.pid; - to.tid = from.tid; -} - -//process -inline OS_process_id_t get_current_process_id() -{ return ::getpid(); } - -inline OS_process_id_t get_invalid_process_id() -{ return pid_t(0); } - -//thread -inline OS_thread_id_t get_current_thread_id() -{ return ::pthread_self(); } - -inline OS_thread_id_t get_invalid_thread_id() -{ - static pthread_t invalid_id; - return invalid_id; -} - -inline bool equal_thread_id(OS_thread_id_t id1, OS_thread_id_t id2) -{ return 0 != pthread_equal(id1, id2); } - -inline void thread_yield() -{ ::sched_yield(); } - -#ifndef BOOST_INTERPROCESS_MATCH_ABSOLUTE_TIME -typedef struct timespec OS_highres_count_t; -#else -typedef unsigned long long OS_highres_count_t; -#endif - -inline unsigned long get_system_tick_ns() -{ - #ifdef _SC_CLK_TCK - long hz =::sysconf(_SC_CLK_TCK); // ticks per sec - if(hz <= 0){ //Try a typical value on error - hz = 100; - } - return 999999999ul/static_cast(hz)+1ul; - #else - #error "Can't obtain system tick value for your system, please provide a patch" - #endif -} - -inline unsigned long get_system_tick_in_highres_counts() -{ - #ifndef BOOST_INTERPROCESS_MATCH_ABSOLUTE_TIME - return get_system_tick_ns(); - #else - mach_timebase_info_data_t info; - mach_timebase_info(&info); - //ns - return static_cast - ( - static_cast(get_system_tick_ns()) - / (static_cast(info.numer) / info.denom) - ); - #endif -} - -//return system ticks in us -inline unsigned long get_system_tick_us() -{ - return (get_system_tick_ns()-1)/1000ul + 1ul; -} - -inline OS_highres_count_t get_current_system_highres_count() -{ - #if defined(BOOST_INTERPROCESS_CLOCK_MONOTONIC) - struct timespec count; - ::clock_gettime(BOOST_INTERPROCESS_CLOCK_MONOTONIC, &count); - return count; - #elif defined(BOOST_INTERPROCESS_MATCH_ABSOLUTE_TIME) - return ::mach_absolute_time(); - #endif -} - -#ifndef BOOST_INTERPROCESS_MATCH_ABSOLUTE_TIME - -inline void zero_highres_count(OS_highres_count_t &count) -{ count.tv_sec = 0; count.tv_nsec = 0; } - -inline bool is_highres_count_zero(const OS_highres_count_t &count) -{ return count.tv_sec == 0 && count.tv_nsec == 0; } - -template -inline Ostream &ostream_highres_count(Ostream &ostream, const OS_highres_count_t &count) -{ - ostream << count.tv_sec << "s:" << count.tv_nsec << "ns"; - return ostream; -} - -inline OS_highres_count_t system_highres_count_subtract(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ - OS_highres_count_t res; - - if (l.tv_nsec < r.tv_nsec){ - res.tv_nsec = 1000000000 + l.tv_nsec - r.tv_nsec; - res.tv_sec = l.tv_sec - 1 - r.tv_sec; - } - else{ - res.tv_nsec = l.tv_nsec - r.tv_nsec; - res.tv_sec = l.tv_sec - r.tv_sec; - } - - return res; -} - -inline bool system_highres_count_less(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ return l.tv_sec < r.tv_sec || (l.tv_sec == r.tv_sec && l.tv_nsec < r.tv_nsec); } - -inline bool system_highres_count_less_ul(const OS_highres_count_t &l, unsigned long r) -{ return !l.tv_sec && (static_cast(l.tv_nsec) < r); } - -#else - -inline void zero_highres_count(OS_highres_count_t &count) -{ count = 0; } - -inline bool is_highres_count_zero(const OS_highres_count_t &count) -{ return count == 0; } - -template -inline Ostream &ostream_highres_count(Ostream &ostream, const OS_highres_count_t &count) -{ - ostream << count ; - return ostream; -} - -inline OS_highres_count_t system_highres_count_subtract(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ return l - r; } - -inline bool system_highres_count_less(const OS_highres_count_t &l, const OS_highres_count_t &r) -{ return l < r; } - -inline bool system_highres_count_less_ul(const OS_highres_count_t &l, unsigned long r) -{ return l < static_cast(r); } - -#endif - -inline void thread_sleep_tick() -{ - struct timespec rqt; - //Sleep for the half of the tick time - rqt.tv_sec = 0; - rqt.tv_nsec = get_system_tick_ns()/2; - ::nanosleep(&rqt, 0); -} - -inline void thread_sleep(unsigned int ms) -{ - struct timespec rqt; - rqt.tv_sec = ms/1000u; - rqt.tv_nsec = (ms%1000u)*1000000u; - ::nanosleep(&rqt, 0); -} - -//systemwide thread -inline OS_systemwide_thread_id_t get_current_systemwide_thread_id() -{ - return OS_systemwide_thread_id_t(::getpid(), ::pthread_self()); -} - -inline bool equal_systemwide_thread_id(const OS_systemwide_thread_id_t &id1, const OS_systemwide_thread_id_t &id2) -{ - return (0 != pthread_equal(id1.tid, id2.tid)) && (id1.pid == id2.pid); -} - -inline OS_systemwide_thread_id_t get_invalid_systemwide_thread_id() -{ - return OS_systemwide_thread_id_t(get_invalid_process_id(), get_invalid_thread_id()); -} - -inline long double get_current_process_creation_time() -{ return 0.0L; } - -inline unsigned int get_num_cores() -{ - #ifdef _SC_NPROCESSORS_ONLN - long cores = ::sysconf(_SC_NPROCESSORS_ONLN); - // sysconf returns -1 if the name is invalid, the option does not exist or - // does not have a definite limit. - // if sysconf returns some other negative number, we have no idea - // what is going on. Default to something safe. - if(cores <= 0){ - return 1; - } - //Check for overflow (unlikely) - else if(static_cast(cores) >= - static_cast(static_cast(-1))){ - return static_cast(-1); - } - else{ - return static_cast(cores); - } - #elif defined(BOOST_INTERPROCESS_BSD_DERIVATIVE) && defined(HW_NCPU) - int request[2] = { CTL_HW, HW_NCPU }; - int num_cores; - std::size_t result_len = sizeof(num_cores); - if ( (::sysctl (request, 2, &num_cores, &result_len, 0, 0) < 0) || (num_cores <= 0) ){ - //Return a safe value - return 1; - } - else{ - return static_cast(num_cores); - } - #endif -} - -inline int thread_create(OS_thread_t * thread, void *(*start_routine)(void*), void* arg) -{ return pthread_create(thread, 0, start_routine, arg); } - -inline void thread_join(OS_thread_t thread) -{ (void)pthread_join(thread, 0); } - -#endif //#if (defined BOOST_INTERPROCESS_WINDOWS) - -typedef char pid_str_t[sizeof(OS_process_id_t)*3+1]; - -inline void get_pid_str(pid_str_t &pid_str, OS_process_id_t pid) -{ - bufferstream bstream(pid_str, sizeof(pid_str)); - bstream << pid << std::ends; -} - -inline void get_pid_str(pid_str_t &pid_str) -{ get_pid_str(pid_str, get_current_process_id()); } - -#if defined(BOOST_INTERPROCESS_WINDOWS) - -inline int thread_create( OS_thread_t * thread, unsigned (__stdcall * start_routine) (void*), void* arg ) -{ - void* h = (void*)_beginthreadex( 0, 0, start_routine, arg, 0, 0 ); - - if( h != 0 ){ - *thread = h; - return 0; - } - else{ - return 1; - } -} - -inline void thread_join( OS_thread_t thread) -{ - winapi::wait_for_single_object( thread, winapi::infinite_time ); - winapi::close_handle( thread ); -} - -#endif - -class abstract_thread -{ - public: - virtual ~abstract_thread() {} - virtual void run() = 0; -}; - -#if defined(BOOST_INTERPROCESS_WINDOWS) - -inline unsigned __stdcall launch_thread_routine( void * pv ) -{ - std::auto_ptr pt( static_cast( pv ) ); - pt->run(); - return 0; -} - -#else - -extern "C" void * launch_thread_routine( void * pv ); - -inline void * launch_thread_routine( void * pv ) -{ - std::auto_ptr pt( static_cast( pv ) ); - pt->run(); - return 0; -} - -#endif - -template -class launch_thread_impl - : public abstract_thread -{ - public: - explicit launch_thread_impl( F f ) - : f_( f ) - {} - - void run() - { f_(); } - - private: - F f_; -}; - -template -inline int thread_launch( OS_thread_t & pt, F f ) -{ - std::auto_ptr p( new launch_thread_impl( f ) ); - - int r = thread_create(&pt, launch_thread_routine, p.get()); - if( r == 0 ){ - p.release(); - } - - return r; -} - -} //namespace ipcdetail{ -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_OS_THREAD_FUNCTIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/posix_time_types_wrk.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/posix_time_types_wrk.hpp deleted file mode 100644 index fa167f57..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/posix_time_types_wrk.hpp +++ /dev/null @@ -1,42 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_POSIX_TIMES_WRK_HPP -#define BOOST_INTERPROCESS_POSIX_TIMES_WRK_HPP - -//workaround to avoid winsock redefines when using date-time - -#ifdef _WIN32 -#ifndef WIN32_LEAN_AND_MEAN -#define WIN32_LEAN_AND_MEAN -#define BOOST_INTERPROCESS_WIN32_LEAN_AND_MEAN -#endif //#ifndef WIN32_LEAN_AND_MEAN -#endif //#ifdef _WIN32 - -#include -#include - -namespace boost { -namespace interprocess { - -typedef boost::date_time::microsec_clock microsec_clock; - -} -} - -#ifdef _WIN32 -#ifdef BOOST_INTERPROCESS_WIN32_LEAN_AND_MEAN -#undef WIN32_LEAN_AND_MEAN -#undef BOOST_INTERPROCESS_WIN32_LEAN_AND_MEAN -#endif //#ifdef BOOST_INTERPROCESS_WIN32_LEAN_AND_MEAN -#endif //#ifdef _WIN32 - -#endif //#ifndef BOOST_INTERPROCESS_POSIX_TIMES_WRK_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/preprocessor.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/preprocessor.hpp deleted file mode 100644 index 0eb419d6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/preprocessor.hpp +++ /dev/null @@ -1,203 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_PREPROCESSOR_HPP -#define BOOST_INTERPROCESS_DETAIL_PREPROCESSOR_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include - -#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING -#error "This file is not needed when perfect forwarding is available" -#endif - -#include -#include -#include -#include -#include - -#define BOOST_INTERPROCESS_MAX_CONSTRUCTOR_PARAMETERS 10 - -//Note: -//We define template parameters as const references to -//be able to bind temporaries. After that we will un-const them. -//This cast is ugly but it is necessary until "perfect forwarding" -//is achieved in C++0x. Meanwhile, if we want to be able to -//bind rvalues with non-const references, we have to be ugly -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - #define BOOST_INTERPROCESS_PP_PARAM_LIST(z, n, data) \ - BOOST_PP_CAT(P, n) && BOOST_PP_CAT(p, n) \ - //! -#else - #define BOOST_INTERPROCESS_PP_PARAM_LIST(z, n, data) \ - const BOOST_PP_CAT(P, n) & BOOST_PP_CAT(p, n) \ - //! -#endif - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - #define BOOST_INTERPROCESS_PP_PARAM(U, u) \ - U && u \ - //! -#else - #define BOOST_INTERPROCESS_PP_PARAM(U, u) \ - const U & u \ - //! -#endif - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - - #define BOOST_INTERPROCESS_PP_PARAM_INIT(z, n, data) \ - BOOST_PP_CAT(m_p, n) (::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) )) \ - //! - -#else //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - - #define BOOST_INTERPROCESS_PP_PARAM_INIT(z, n, data) \ - BOOST_PP_CAT(m_p, n) (const_cast(BOOST_PP_CAT(p, n))) \ - //! -#endif - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - - #if defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - - namespace boost { - namespace interprocess { - namespace ipcdetail { - template - struct ref_holder; - - template - struct ref_holder - { - ref_holder(T &t) - : t_(t) - {} - T &t_; - T & get() { return t_; } - T & get_lvalue() { return t_; } - }; - - template - struct ref_holder - { - ref_holder(const T &t) - : t_(t) - {} - const T &t_; - const T & get() { return t_; } - const T & get_lvalue() { return t_; } - }; - - template - struct ref_holder - { - ref_holder(const T &t) - : t_(t) - {} - const T &t_; - const T & get() { return t_; } - const T & get_lvalue() { return t_; } - }; - - template - struct ref_holder - { - ref_holder(T &&t) - : t_(t) - {} - T &t_; - T && get() { return ::boost::move(t_); } - T & get_lvalue() { return t_; } - }; - - template - struct ref_holder - { - ref_holder(T &&t) - : t(t) - {} - T &t; - T && get() { return ::boost::move(t_); } - T & get_lvalue() { return t_; } - }; - - } //namespace ipcdetail { - } //namespace interprocess { - } //namespace boost { - - #define BOOST_INTERPROCESS_PP_PARAM_DEFINE(z, n, data) \ - ::boost::interprocess::ipcdetail::ref_holder BOOST_PP_CAT(m_p, n); \ - //! - - #define BOOST_INTERPROCESS_PP_PARAM_INC(z, n, data) \ - BOOST_PP_CAT(++m_p, n).get_lvalue() \ - //! - - #else //BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG - - #define BOOST_INTERPROCESS_PP_PARAM_DEFINE(z, n, data)\ - BOOST_PP_CAT(P, n) && BOOST_PP_CAT(m_p, n); \ - //! - - #define BOOST_INTERPROCESS_PP_PARAM_INC(z, n, data) \ - BOOST_PP_CAT(++m_p, n) \ - //! - - #endif //defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - -#else - #define BOOST_INTERPROCESS_PP_PARAM_DEFINE(z, n, data) \ - BOOST_PP_CAT(P, n) & BOOST_PP_CAT(m_p, n); \ - //! - - #define BOOST_INTERPROCESS_PP_PARAM_INC(z, n, data) \ - BOOST_PP_CAT(++m_p, n) \ - //! - -#endif - -#define BOOST_INTERPROCESS_PP_PARAM_FORWARD(z, n, data) \ -::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) ) \ -//! - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - - #define BOOST_INTERPROCESS_PP_MEMBER_FORWARD(z, n, data) BOOST_PP_CAT(this->m_p, n).get() \ - //! - - #define BOOST_INTERPROCESS_PP_MEMBER_IT_FORWARD(z, n, data) \ - BOOST_PP_CAT(*m_p, n).get_lvalue() \ - //! - -#else - - #define BOOST_INTERPROCESS_PP_MEMBER_FORWARD(z, n, data) \ - ::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(m_p, n) ) \ - //! - - #define BOOST_INTERPROCESS_PP_MEMBER_IT_FORWARD(z, n, data) \ - BOOST_PP_CAT(*m_p, n) \ - //! - - -#endif //!defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) - -#include - -#else -#ifdef BOOST_INTERPROCESS_PERFECT_FORWARDING -#error "This file is not needed when perfect forwarding is available" -#endif -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_PREPROCESSOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/segment_manager_helper.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/segment_manager_helper.hpp deleted file mode 100644 index 83e5a05e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/segment_manager_helper.hpp +++ /dev/null @@ -1,511 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_SEGMENT_MANAGER_BASE_HPP -#define BOOST_INTERPROCESS_SEGMENT_MANAGER_BASE_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include //std::size_t -#include //char_traits -#include //std::nothrow -#include //std::pair -#include //BOOST_ASSERT -#include //unary_function -#ifndef BOOST_NO_EXCEPTIONS -#include -#endif - -//!\file -//!Describes the object placed in a memory segment that provides -//!named object allocation capabilities. - -namespace boost{ -namespace interprocess{ - -template -class segment_manager_base; - -//!An integer that describes the type of the -//!instance constructed in memory -enum instance_type { anonymous_type, named_type, unique_type, max_allocation_type }; - -namespace ipcdetail{ - -template -class mem_algo_deallocator -{ - void * m_ptr; - MemoryAlgorithm & m_algo; - - public: - mem_algo_deallocator(void *ptr, MemoryAlgorithm &algo) - : m_ptr(ptr), m_algo(algo) - {} - - void release() - { m_ptr = 0; } - - ~mem_algo_deallocator() - { if(m_ptr) m_algo.deallocate(m_ptr); } -}; - -/// @cond -template -struct block_header -{ - size_type m_value_bytes; - unsigned short m_num_char; - unsigned char m_value_alignment; - unsigned char m_alloc_type_sizeof_char; - - block_header(size_type val_bytes - ,size_type val_alignment - ,unsigned char al_type - ,std::size_t szof_char - ,std::size_t num_char - ) - : m_value_bytes(val_bytes) - , m_num_char((unsigned short)num_char) - , m_value_alignment((unsigned char)val_alignment) - , m_alloc_type_sizeof_char( (al_type << 5u) | ((unsigned char)szof_char & 0x1F) ) - {}; - - template - block_header &operator= (const T& ) - { return *this; } - - size_type total_size() const - { - if(alloc_type() != anonymous_type){ - return name_offset() + (m_num_char+1)*sizeof_char(); - } - else{ - return this->value_offset() + m_value_bytes; - } - } - - size_type value_bytes() const - { return m_value_bytes; } - - template - size_type total_size_with_header() const - { - return get_rounded_size - ( size_type(sizeof(Header)) - , size_type(::boost::alignment_of >::value)) - + total_size(); - } - - unsigned char alloc_type() const - { return (m_alloc_type_sizeof_char >> 5u)&(unsigned char)0x7; } - - unsigned char sizeof_char() const - { return m_alloc_type_sizeof_char & (unsigned char)0x1F; } - - template - CharType *name() const - { - return const_cast(reinterpret_cast - (reinterpret_cast(this) + name_offset())); - } - - unsigned short name_length() const - { return m_num_char; } - - size_type name_offset() const - { - return this->value_offset() + get_rounded_size(size_type(m_value_bytes), size_type(sizeof_char())); - } - - void *value() const - { - return const_cast((reinterpret_cast(this) + this->value_offset())); - } - - size_type value_offset() const - { - return get_rounded_size(size_type(sizeof(block_header)), size_type(m_value_alignment)); - } - - template - bool less_comp(const block_header &b) const - { - return m_num_char < b.m_num_char || - (m_num_char < b.m_num_char && - std::char_traits::compare - (name(), b.name(), m_num_char) < 0); - } - - template - bool equal_comp(const block_header &b) const - { - return m_num_char == b.m_num_char && - std::char_traits::compare - (name(), b.name(), m_num_char) == 0; - } - - template - static block_header *block_header_from_value(T *value) - { return block_header_from_value(value, sizeof(T), ::boost::alignment_of::value); } - - static block_header *block_header_from_value(const void *value, std::size_t sz, std::size_t algn) - { - block_header * hdr = - const_cast - (reinterpret_cast(reinterpret_cast(value) - - get_rounded_size(sizeof(block_header), algn))); - (void)sz; - //Some sanity checks - BOOST_ASSERT(hdr->m_value_alignment == algn); - BOOST_ASSERT(hdr->m_value_bytes % sz == 0); - return hdr; - } - - template - static block_header *from_first_header(Header *header) - { - block_header * hdr = - reinterpret_cast*>(reinterpret_cast(header) + - get_rounded_size(size_type(sizeof(Header)), size_type(::boost::alignment_of >::value))); - //Some sanity checks - return hdr; - } - - template - static Header *to_first_header(block_header *bheader) - { - Header * hdr = - reinterpret_cast(reinterpret_cast(bheader) - - get_rounded_size(size_type(sizeof(Header)), size_type(::boost::alignment_of >::value))); - //Some sanity checks - return hdr; - } -}; - -inline void array_construct(void *mem, std::size_t num, in_place_interface &table) -{ - //Try constructors - std::size_t constructed = 0; - BOOST_TRY{ - table.construct_n(mem, num, constructed); - } - //If there is an exception call destructors and erase index node - BOOST_CATCH(...){ - std::size_t destroyed = 0; - table.destroy_n(mem, constructed, destroyed); - BOOST_RETHROW - } - BOOST_CATCH_END -} - -template -struct intrusive_compare_key -{ - typedef CharT char_type; - - intrusive_compare_key(const CharT *str, std::size_t len) - : mp_str(str), m_len(len) - {} - - const CharT * mp_str; - std::size_t m_len; -}; - -//!This struct indicates an anonymous object creation -//!allocation -template -class instance_t -{ - instance_t(){} -}; - -template -struct char_if_void -{ - typedef T type; -}; - -template<> -struct char_if_void -{ - typedef char type; -}; - -typedef instance_t anonymous_instance_t; -typedef instance_t unique_instance_t; - - -template -struct intrusive_value_type_impl - : public Hook -{ - private: - //Non-copyable - intrusive_value_type_impl(const intrusive_value_type_impl &); - intrusive_value_type_impl& operator=(const intrusive_value_type_impl &); - - public: - typedef CharType char_type; - typedef SizeType size_type; - - intrusive_value_type_impl(){} - - enum { BlockHdrAlignment = ::boost::alignment_of >::value }; - - block_header *get_block_header() const - { - return const_cast*> - (reinterpret_cast *>(reinterpret_cast(this) + - get_rounded_size(size_type(sizeof(*this)), size_type(BlockHdrAlignment)))); - } - - bool operator <(const intrusive_value_type_impl & other) const - { return (this->get_block_header())->template less_comp(*other.get_block_header()); } - - bool operator ==(const intrusive_value_type_impl & other) const - { return (this->get_block_header())->template equal_comp(*other.get_block_header()); } - - static intrusive_value_type_impl *get_intrusive_value_type(block_header *hdr) - { - return reinterpret_cast(reinterpret_cast(hdr) - - get_rounded_size(size_type(sizeof(intrusive_value_type_impl)), size_type(BlockHdrAlignment))); - } - - CharType *name() const - { return get_block_header()->template name(); } - - unsigned short name_length() const - { return get_block_header()->name_length(); } - - void *value() const - { return get_block_header()->value(); } -}; - -template -class char_ptr_holder -{ - public: - char_ptr_holder(const CharType *name) - : m_name(name) - {} - - char_ptr_holder(const anonymous_instance_t *) - : m_name(static_cast(0)) - {} - - char_ptr_holder(const unique_instance_t *) - : m_name(reinterpret_cast(-1)) - {} - - operator const CharType *() - { return m_name; } - - private: - const CharType *m_name; -}; - -//!The key of the the named allocation information index. Stores an offset pointer -//!to a null terminated string and the length of the string to speed up sorting -template -struct index_key -{ - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type const_char_ptr_t; - typedef CharT char_type; - typedef typename boost::intrusive::pointer_traits::difference_type difference_type; - typedef typename boost::make_unsigned::type size_type; - - private: - //Offset pointer to the object's name - const_char_ptr_t mp_str; - //Length of the name buffer (null NOT included) - size_type m_len; - public: - - //!Constructor of the key - index_key (const char_type *nm, size_type length) - : mp_str(nm), m_len(length) - {} - - //!Less than function for index ordering - bool operator < (const index_key & right) const - { - return (m_len < right.m_len) || - (m_len == right.m_len && - std::char_traits::compare - (to_raw_pointer(mp_str) - ,to_raw_pointer(right.mp_str), m_len) < 0); - } - - //!Equal to function for index ordering - bool operator == (const index_key & right) const - { - return m_len == right.m_len && - std::char_traits::compare - (to_raw_pointer(mp_str), - to_raw_pointer(right.mp_str), m_len) == 0; - } - - void name(const CharT *nm) - { mp_str = nm; } - - void name_length(size_type len) - { m_len = len; } - - const CharT *name() const - { return to_raw_pointer(mp_str); } - - size_type name_length() const - { return m_len; } -}; - -//!The index_data stores a pointer to a buffer and the element count needed -//!to know how many destructors must be called when calling destroy -template -struct index_data -{ - typedef VoidPointer void_pointer; - void_pointer m_ptr; - index_data(void *ptr) : m_ptr(ptr){} - - void *value() const - { return static_cast(to_raw_pointer(m_ptr)); } -}; - -template -struct segment_manager_base_type -{ typedef segment_manager_base type; }; - -template -struct index_config -{ - typedef typename MemoryAlgorithm::void_pointer void_pointer; - typedef CharT char_type; - typedef index_key key_type; - typedef index_data mapped_type; - typedef typename segment_manager_base_type - ::type segment_manager_base; - - template - struct intrusive_value_type - { typedef intrusive_value_type_impl type; }; - - typedef intrusive_compare_key intrusive_compare_key_type; -}; - -template -class segment_manager_iterator_value_adaptor -{ - typedef typename Iterator::value_type iterator_val_t; - typedef typename iterator_val_t::char_type char_type; - - public: - segment_manager_iterator_value_adaptor(const typename Iterator::value_type &val) - : m_val(&val) - {} - - const char_type *name() const - { return m_val->name(); } - - unsigned short name_length() const - { return m_val->name_length(); } - - const void *value() const - { return m_val->value(); } - - const typename Iterator::value_type *m_val; -}; - - -template -class segment_manager_iterator_value_adaptor -{ - typedef typename Iterator::value_type iterator_val_t; - typedef typename iterator_val_t::first_type first_type; - typedef typename iterator_val_t::second_type second_type; - typedef typename first_type::char_type char_type; - typedef typename first_type::size_type size_type; - - public: - segment_manager_iterator_value_adaptor(const typename Iterator::value_type &val) - : m_val(&val) - {} - - const char_type *name() const - { return m_val->first.name(); } - - size_type name_length() const - { return m_val->first.name_length(); } - - const void *value() const - { - return reinterpret_cast*> - (to_raw_pointer(m_val->second.m_ptr))->value(); - } - - const typename Iterator::value_type *m_val; -}; - -template -struct segment_manager_iterator_transform - : std::unary_function< typename Iterator::value_type - , segment_manager_iterator_value_adaptor > -{ - typedef segment_manager_iterator_value_adaptor result_type; - - result_type operator()(const typename Iterator::value_type &arg) const - { return result_type(arg); } -}; - -} //namespace ipcdetail { - -//These pointers are the ones the user will use to -//indicate previous allocation types -static const ipcdetail::anonymous_instance_t * anonymous_instance = 0; -static const ipcdetail::unique_instance_t * unique_instance = 0; - -namespace ipcdetail_really_deep_namespace { - -//Otherwise, gcc issues a warning of previously defined -//anonymous_instance and unique_instance -struct dummy -{ - dummy() - { - (void)anonymous_instance; - (void)unique_instance; - } -}; - -} //detail_really_deep_namespace - -}} //namespace boost { namespace interprocess - -#include - -#endif //#ifndef BOOST_INTERPROCESS_SEGMENT_MANAGER_BASE_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/tmp_dir_helpers.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/tmp_dir_helpers.hpp deleted file mode 100644 index 2af1a8a7..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/tmp_dir_helpers.hpp +++ /dev/null @@ -1,181 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_TMP_DIR_HELPERS_HPP -#define BOOST_INTERPROCESS_DETAIL_TMP_DIR_HELPERS_HPP - -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME) && defined(BOOST_INTERPROCESS_WINDOWS) - #include -#endif - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -#if defined(BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME) - #if defined(BOOST_INTERPROCESS_WINDOWS) - //This type will initialize the stamp - struct windows_bootstamp - { - windows_bootstamp() - { - winapi::get_last_bootup_time(stamp); - } - //Use std::string. Even if this will be constructed in shared memory, all - //modules/dlls are from this process so internal raw pointers to heap are always valid - std::string stamp; - }; - - inline void get_bootstamp(std::string &s, bool add = false) - { - const windows_bootstamp &bootstamp = windows_intermodule_singleton::get(); - if(add){ - s += bootstamp.stamp; - } - else{ - s = bootstamp.stamp; - } - } - #elif defined(BOOST_INTERPROCESS_HAS_BSD_KERNEL_BOOTTIME) - inline void get_bootstamp(std::string &s, bool add = false) - { - // FreeBSD specific: sysctl "kern.boottime" - int request[2] = { CTL_KERN, KERN_BOOTTIME }; - struct ::timeval result; - std::size_t result_len = sizeof result; - - if (::sysctl (request, 2, &result, &result_len, 0, 0) < 0) - return; - - char bootstamp_str[256]; - - const char Characters [] = - { '0', '1', '2', '3', '4', '5', '6', '7' - , '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; - - std::size_t char_counter = 0; - //32 bit values to allow 32 and 64 bit process IPC - boost::uint32_t fields[2] = { boost::uint32_t(result.tv_sec), boost::uint32_t(result.tv_usec) }; - for(std::size_t field = 0; field != 2; ++field){ - for(std::size_t i = 0; i != sizeof(fields[0]); ++i){ - const char *ptr = (const char *)&fields[field]; - bootstamp_str[char_counter++] = Characters[(ptr[i]&0xF0)>>4]; - bootstamp_str[char_counter++] = Characters[(ptr[i]&0x0F)]; - } - } - bootstamp_str[char_counter] = 0; - if(add){ - s += bootstamp_str; - } - else{ - s = bootstamp_str; - } - } - #else - #error "BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME defined with no known implementation" - #endif -#endif //#if defined(BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME) - -inline void get_tmp_base_dir(std::string &tmp_name) -{ - #if defined (BOOST_INTERPROCESS_WINDOWS) - winapi::get_shared_documents_folder(tmp_name); - if(tmp_name.empty() || !winapi::is_directory(tmp_name.c_str())){ - tmp_name = get_temporary_path(); - } - #else - tmp_name = get_temporary_path(); - #endif - if(tmp_name.empty()){ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - //Remove final null. - tmp_name += "/boost_interprocess"; -} - -inline void tmp_folder(std::string &tmp_name) -{ - get_tmp_base_dir(tmp_name); - #if defined(BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME) - tmp_name += "/"; - get_bootstamp(tmp_name, true); - #endif -} - -inline void tmp_filename(const char *filename, std::string &tmp_name) -{ - tmp_folder(tmp_name); - tmp_name += "/"; - tmp_name += filename; -} - -inline void create_tmp_and_clean_old(std::string &tmp_name) -{ - //First get the temp directory - std::string root_tmp_name; - get_tmp_base_dir(root_tmp_name); - - //If fails, check that it's because already exists - if(!create_directory(root_tmp_name.c_str())){ - error_info info(system_error_code()); - if(info.get_error_code() != already_exists_error){ - throw interprocess_exception(info); - } - } - - #if defined(BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME) - tmp_folder(tmp_name); - - //If fails, check that it's because already exists - if(!create_directory(tmp_name.c_str())){ - error_info info(system_error_code()); - if(info.get_error_code() != already_exists_error){ - throw interprocess_exception(info); - } - } - //Now erase all old directories created in the previous boot sessions - std::string subdir = tmp_name; - subdir.erase(0, root_tmp_name.size()+1); - delete_subdirectories(root_tmp_name, subdir.c_str()); - #else - tmp_name = root_tmp_name; - #endif -} - -inline void create_tmp_and_clean_old_and_get_filename(const char *filename, std::string &tmp_name) -{ - create_tmp_and_clean_old(tmp_name); - tmp_name += "/"; - tmp_name += filename; -} - -inline void add_leading_slash(const char *name, std::string &new_name) -{ - if(name[0] != '/'){ - new_name = '/'; - } - new_name += name; -} - -} //namespace boost{ -} //namespace interprocess { -} //namespace ipcdetail { - -#include - -#endif //ifndef BOOST_INTERPROCESS_DETAIL_TMP_DIR_HELPERS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/transform_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/transform_iterator.hpp deleted file mode 100644 index 56bd0e56..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/transform_iterator.hpp +++ /dev/null @@ -1,195 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// (C) Copyright Gennaro Prota 2003 - 2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_TRANSFORM_ITERATORS_HPP -#define BOOST_INTERPROCESS_DETAIL_TRANSFORM_ITERATORS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include - -#include -#include - -namespace boost { -namespace interprocess { - -template -struct operator_arrow_proxy -{ - operator_arrow_proxy(const PseudoReference &px) - : m_value(px) - {} - - PseudoReference* operator->() const { return &m_value; } - // This function is needed for MWCW and BCC, which won't call operator-> - // again automatically per 13.3.1.2 para 8 -// operator T*() const { return &m_value; } - mutable PseudoReference m_value; -}; - -template -struct operator_arrow_proxy -{ - operator_arrow_proxy(T &px) - : m_value(px) - {} - - T* operator->() const { return const_cast(&m_value); } - // This function is needed for MWCW and BCC, which won't call operator-> - // again automatically per 13.3.1.2 para 8 -// operator T*() const { return &m_value; } - T &m_value; -}; - -template -class transform_iterator - : public UnaryFunction - , public std::iterator - < typename Iterator::iterator_category - , typename ipcdetail::remove_reference::type - , typename Iterator::difference_type - , operator_arrow_proxy - , typename UnaryFunction::result_type> -{ - public: - explicit transform_iterator(const Iterator &it, const UnaryFunction &f = UnaryFunction()) - : UnaryFunction(f), m_it(it) - {} - - explicit transform_iterator() - : UnaryFunction(), m_it() - {} - - //Constructors - transform_iterator& operator++() - { increment(); return *this; } - - transform_iterator operator++(int) - { - transform_iterator result (*this); - increment(); - return result; - } - - transform_iterator& operator--() - { decrement(); return *this; } - - transform_iterator operator--(int) - { - transform_iterator result (*this); - decrement(); - return result; - } - - friend bool operator== (const transform_iterator& i, const transform_iterator& i2) - { return i.equal(i2); } - - friend bool operator!= (const transform_iterator& i, const transform_iterator& i2) - { return !(i == i2); } - - friend bool operator< (const transform_iterator& i, const transform_iterator& i2) - { return i < i2; } - - friend bool operator> (const transform_iterator& i, const transform_iterator& i2) - { return i2 < i; } - - friend bool operator<= (const transform_iterator& i, const transform_iterator& i2) - { return !(i > i2); } - - friend bool operator>= (const transform_iterator& i, const transform_iterator& i2) - { return !(i < i2); } - - friend typename Iterator::difference_type operator- (const transform_iterator& i, const transform_iterator& i2) - { return i2.distance_to(i); } - - //Arithmetic - transform_iterator& operator+=(typename Iterator::difference_type off) - { this->advance(off); return *this; } - - transform_iterator operator+(typename Iterator::difference_type off) const - { - transform_iterator other(*this); - other.advance(off); - return other; - } - - friend transform_iterator operator+(typename Iterator::difference_type off, const transform_iterator& right) - { return right + off; } - - transform_iterator& operator-=(typename Iterator::difference_type off) - { this->advance(-off); return *this; } - - transform_iterator operator-(typename Iterator::difference_type off) const - { return *this + (-off); } - - typename UnaryFunction::result_type operator*() const - { return dereference(); } - - typename UnaryFunction::result_type operator[](typename Iterator::difference_type off) const - { return UnaryFunction::operator()(m_it[off]); } - - operator_arrow_proxy - operator->() const - { return operator_arrow_proxy(dereference()); } - - Iterator & base() - { return m_it; } - - const Iterator & base() const - { return m_it; } - - private: - Iterator m_it; - - void increment() - { ++m_it; } - - void decrement() - { --m_it; } - - bool equal(const transform_iterator &other) const - { return m_it == other.m_it; } - - bool less(const transform_iterator &other) const - { return other.m_it < m_it; } - - typename UnaryFunction::result_type dereference() const - { return UnaryFunction::operator()(*m_it); } - - void advance(typename Iterator::difference_type n) - { std::advance(m_it, n); } - - typename Iterator::difference_type distance_to(const transform_iterator &other)const - { return std::distance(other.m_it, m_it); } -}; - -template -transform_iterator -make_transform_iterator(Iterator it, UnaryFunc fun) -{ - return transform_iterator(it, fun); -} - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_TRANSFORM_ITERATORS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/type_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/type_traits.hpp deleted file mode 100644 index ade623f1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/type_traits.hpp +++ /dev/null @@ -1,158 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// (C) Copyright John Maddock 2000. -// (C) Copyright Ion Gaztanaga 2005-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_TYPE_TRAITS_HPP -#define BOOST_INTERPROCESS_DETAIL_TYPE_TRAITS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -struct nat{}; - -template -struct remove_reference -{ - typedef T type; -}; - -template -struct remove_reference -{ - typedef T type; -}; - -template -struct is_reference -{ - static const bool value = false; -}; - -template -struct is_reference -{ - static const bool value = true; -}; - -template -struct is_pointer -{ - static const bool value = false; -}; - -template -struct is_pointer -{ - static const bool value = true; -}; - -template -struct add_reference -{ - typedef T& type; -}; - -template -struct add_reference -{ - typedef T& type; -}; - -template<> -struct add_reference -{ - typedef nat &type; -}; - -template<> -struct add_reference -{ - typedef const nat &type; -}; - -template -struct add_const_reference -{ typedef const T &type; }; - -template -struct add_const_reference -{ typedef T& type; }; - -template -struct remove_const -{ - typedef T type; -}; - -template -struct remove_const -{ - typedef T type; -}; - -template -struct remove_volatile -{ - typedef T type; -}; - -template -struct remove_volatile -{ - typedef T type; -}; - -template -struct remove_const_volatile -{ - typedef typename remove_const::type>::type type; -}; - -template -struct is_same -{ - typedef char yes_type; - struct no_type - { - char padding[8]; - }; - - template - static yes_type is_same_tester(V*, V*); - static no_type is_same_tester(...); - - static T *t; - static U *u; - - static const bool value = sizeof(yes_type) == sizeof(is_same_tester(t,u)); -}; - -template -struct is_cv_same -{ - static const bool value = is_same< typename remove_const_volatile::type - , typename remove_const_volatile::type >::value; -}; - -} // namespace ipcdetail -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_TYPE_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/utilities.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/utilities.hpp deleted file mode 100644 index 3b486ddc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/utilities.hpp +++ /dev/null @@ -1,218 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. -// (C) Copyright Gennaro Prota 2003 - 2004. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_UTILITIES_HPP -#define BOOST_INTERPROCESS_DETAIL_UTILITIES_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -template -inline T* to_raw_pointer(T* p) -{ return p; } - -template -inline typename boost::intrusive::pointer_traits::element_type* -to_raw_pointer(const Pointer &p) -{ return boost::interprocess::ipcdetail::to_raw_pointer(p.operator->()); } - -//!To avoid ADL problems with swap -template -inline void do_swap(T& x, T& y) -{ - using std::swap; - swap(x, y); -} - -//Rounds "orig_size" by excess to round_to bytes -template -inline SizeType get_rounded_size(SizeType orig_size, SizeType round_to) -{ - return ((orig_size-1)/round_to+1)*round_to; -} - -//Truncates "orig_size" to a multiple of "multiple" bytes. -template -inline SizeType get_truncated_size(SizeType orig_size, SizeType multiple) -{ - return orig_size/multiple*multiple; -} - -//Rounds "orig_size" by excess to round_to bytes. round_to must be power of two -template -inline SizeType get_rounded_size_po2(SizeType orig_size, SizeType round_to) -{ - return ((orig_size-1)&(~(round_to-1))) + round_to; -} - -//Truncates "orig_size" to a multiple of "multiple" bytes. multiple must be power of two -template -inline SizeType get_truncated_size_po2(SizeType orig_size, SizeType multiple) -{ - return (orig_size & (~(multiple-1))); -} - -template -struct ct_rounded_size -{ - BOOST_STATIC_ASSERT((RoundTo != 0)); - static const std::size_t intermediate_value = (OrigSize-1)/RoundTo+1; - BOOST_STATIC_ASSERT(intermediate_value <= std::size_t(-1)/RoundTo); - static const std::size_t value = intermediate_value*RoundTo; -}; - -// Gennaro Prota wrote this. Thanks! -template -struct ct_max_pow2_less -{ - static const std::size_t c = 2*n < p; - - static const std::size_t value = - c ? (ct_max_pow2_less< c*p, 2*c*n>::value) : n; -}; - -template <> -struct ct_max_pow2_less<0, 0> -{ - static const std::size_t value = 0; -}; - -} //namespace ipcdetail { - -//!Trait class to detect if an index is a node -//!index. This allows more efficient operations -//!when deallocating named objects. -template -struct is_node_index -{ - static const bool value = false; -}; - -//!Trait class to detect if an index is an intrusive -//!index. This will embed the derivation hook in each -//!allocation header, to provide memory for the intrusive -//!container. -template -struct is_intrusive_index -{ - static const bool value = false; -}; - -template T* -addressof(T& v) -{ - return reinterpret_cast( - &const_cast(reinterpret_cast(v))); -} - -template -struct sqrt_size_type_max -{ - static const SizeType value = (SizeType(1) << (sizeof(SizeType)*(CHAR_BIT/2)))-1; -}; - -template -inline bool multiplication_overflows(SizeType a, SizeType b) -{ - const SizeType sqrt_size_max = sqrt_size_type_max::value; - return //Fast runtime check - ( (a | b) > sqrt_size_max && - //Slow division check - b && a > SizeType(-1)/b - ); -} - -template -inline bool size_overflows(SizeType count) -{ - //Compile time-check - BOOST_STATIC_ASSERT(SztSizeOfType <= SizeType(-1)); - //Runtime check - return multiplication_overflows(SizeType(SztSizeOfType), count); -} - -template -class pointer_size_t_caster -{ - public: - explicit pointer_size_t_caster(std::size_t sz) - : m_ptr(reinterpret_cast(sz)) - {} - - explicit pointer_size_t_caster(RawPointer p) - : m_ptr(p) - {} - - std::size_t size() const - { return reinterpret_cast(m_ptr); } - - RawPointer pointer() const - { return m_ptr; } - - private: - RawPointer m_ptr; -}; - - -template -inline bool sum_overflows(SizeType a, SizeType b) -{ return SizeType(-1) - a < b; } - -//Anti-exception node eraser -template -class value_eraser -{ - public: - value_eraser(Cont & cont, typename Cont::iterator it) - : m_cont(cont), m_index_it(it), m_erase(true){} - ~value_eraser() - { if(m_erase) m_cont.erase(m_index_it); } - - void release() { m_erase = false; } - - private: - Cont &m_cont; - typename Cont::iterator m_index_it; - bool m_erase; -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_UTILITIES_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/variadic_templates_tools.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/variadic_templates_tools.hpp deleted file mode 100644 index 5f2a94a3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/variadic_templates_tools.hpp +++ /dev/null @@ -1,153 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP -#define BOOST_INTERPROCESS_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include //std::size_t - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -template -class tuple; - -template<> class tuple<> -{}; - -template -class tuple - : private tuple -{ - typedef tuple inherited; - - public: - tuple() { } - - // implicit copy-constructor is okay - // Construct tuple from separate arguments. - tuple(typename add_const_reference::type v, - typename add_const_reference::type... vtail) - : inherited(vtail...), m_head(v) - {} - - // Construct tuple from another tuple. - template - tuple(const tuple& other) - : m_head(other.head()), inherited(other.tail()) - {} - - template - tuple& operator=(const tuple& other) - { - m_head = other.head(); - tail() = other.tail(); - return this; - } - - typename add_reference::type head() { return m_head; } - typename add_reference::type head() const { return m_head; } - - inherited& tail() { return *this; } - const inherited& tail() const { return *this; } - - protected: - Head m_head; -}; - - -template -tuple tie_forward(Values&&... values) -{ return tuple(values...); } - -template -struct tuple_element; - -template -struct tuple_element > -{ - typedef typename tuple_element >::type type; -}; - -template -struct tuple_element<0, tuple > -{ - typedef Head type; -}; - -template -class get_impl; - -template -class get_impl > -{ - typedef typename tuple_element >::type Element; - typedef get_impl > Next; - - public: - typedef typename add_reference::type type; - typedef typename add_const_reference::type const_type; - static type get(tuple& t) { return Next::get(t.tail()); } - static const_type get(const tuple& t) { return Next::get(t.tail()); } -}; - -template -class get_impl<0, tuple > -{ - public: - typedef typename add_reference::type type; - typedef typename add_const_reference::type const_type; - static type get(tuple& t) { return t.head(); } - static const_type get(const tuple& t){ return t.head(); } -}; - -template -typename get_impl >::type get(tuple& t) -{ return get_impl >::get(t); } - -template -typename get_impl >::const_type get(const tuple& t) -{ return get_impl >::get(t); } - -//////////////////////////////////////////////////// -// Builds an index_tuple<0, 1, 2, ..., Num-1>, that will -// be used to "unpack" into comma-separated values -// in a function call. -//////////////////////////////////////////////////// - -template -struct index_tuple{}; - -template > -struct build_number_seq; - -template -struct build_number_seq > - : build_number_seq > -{}; - -template -struct build_number_seq<0, index_tuple > -{ typedef index_tuple type; }; - - -}}} //namespace boost { namespace interprocess { namespace ipcdetail { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/win32_api.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/win32_api.hpp deleted file mode 100644 index 67b5c13e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/win32_api.hpp +++ /dev/null @@ -1,2156 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_WIN32_PRIMITIVES_HPP -#define BOOST_INTERPROCESS_WIN32_PRIMITIVES_HPP - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - - -#if defined (_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -# pragma comment( lib, "Advapi32.lib" ) -# pragma comment( lib, "oleaut32.lib" ) -# pragma comment( lib, "Ole32.lib" ) -# pragma comment( lib, "Psapi.lib" ) -#endif - -#if (defined BOOST_INTERPROCESS_WINDOWS) -# include -# include -#else -# error "This file can only be included in Windows OS" -#endif - - -//The structures used in Interprocess with the -//same binary interface as windows ones -namespace boost { -namespace interprocess { -namespace winapi { - -//Some used constants -static const unsigned long infinite_time = 0xFFFFFFFF; -static const unsigned long error_already_exists = 183L; -static const unsigned long error_invalid_handle = 6L; -static const unsigned long error_sharing_violation = 32L; -static const unsigned long error_file_not_found = 2u; -static const unsigned long error_no_more_files = 18u; -static const unsigned long error_not_locked = 158L; -//Retries in CreateFile, see http://support.microsoft.com/kb/316609 -static const unsigned long error_sharing_violation_tries = 3L; -static const unsigned long error_sharing_violation_sleep_ms = 250L; -static const unsigned long error_file_too_large = 223L; -static const unsigned long error_insufficient_buffer = 122L; -static const unsigned long error_handle_eof = 38L; -static const unsigned long semaphore_all_access = (0x000F0000L)|(0x00100000L)|0x3; -static const unsigned long mutex_all_access = (0x000F0000L)|(0x00100000L)|0x0001; - -static const unsigned long page_readonly = 0x02; -static const unsigned long page_readwrite = 0x04; -static const unsigned long page_writecopy = 0x08; -static const unsigned long page_noaccess = 0x01; - -static const unsigned long standard_rights_required = 0x000F0000L; -static const unsigned long section_query = 0x0001; -static const unsigned long section_map_write = 0x0002; -static const unsigned long section_map_read = 0x0004; -static const unsigned long section_map_execute = 0x0008; -static const unsigned long section_extend_size = 0x0010; -static const unsigned long section_all_access = standard_rights_required | - section_query | - section_map_write | - section_map_read | - section_map_execute | - section_extend_size; - -static const unsigned long file_map_copy = section_query; -static const unsigned long file_map_write = section_map_write; -static const unsigned long file_map_read = section_map_read; -static const unsigned long file_map_all_access = section_all_access; -static const unsigned long delete_access = 0x00010000L; -static const unsigned long file_flag_backup_semantics = 0x02000000; -static const long file_flag_delete_on_close = 0x04000000; - -//Native API constants -static const unsigned long file_open_for_backup_intent = 0x00004000; -static const int file_share_valid_flags = 0x00000007; -static const long file_delete_on_close = 0x00001000L; -static const long obj_case_insensitive = 0x00000040L; -static const long delete_flag = 0x00010000L; - -static const unsigned long movefile_copy_allowed = 0x02; -static const unsigned long movefile_delay_until_reboot = 0x04; -static const unsigned long movefile_replace_existing = 0x01; -static const unsigned long movefile_write_through = 0x08; -static const unsigned long movefile_create_hardlink = 0x10; -static const unsigned long movefile_fail_if_not_trackable = 0x20; - -static const unsigned long file_share_read = 0x00000001; -static const unsigned long file_share_write = 0x00000002; -static const unsigned long file_share_delete = 0x00000004; - -static const unsigned long file_attribute_readonly = 0x00000001; -static const unsigned long file_attribute_hidden = 0x00000002; -static const unsigned long file_attribute_system = 0x00000004; -static const unsigned long file_attribute_directory = 0x00000010; -static const unsigned long file_attribute_archive = 0x00000020; -static const unsigned long file_attribute_device = 0x00000040; -static const unsigned long file_attribute_normal = 0x00000080; -static const unsigned long file_attribute_temporary = 0x00000100; - -static const unsigned long generic_read = 0x80000000L; -static const unsigned long generic_write = 0x40000000L; - -static const unsigned long wait_object_0 = 0; -static const unsigned long wait_abandoned = 0x00000080L; -static const unsigned long wait_timeout = 258L; -static const unsigned long wait_failed = (unsigned long)0xFFFFFFFF; - -static const unsigned long duplicate_close_source = (unsigned long)0x00000001; -static const unsigned long duplicate_same_access = (unsigned long)0x00000002; - -static const unsigned long format_message_allocate_buffer - = (unsigned long)0x00000100; -static const unsigned long format_message_ignore_inserts - = (unsigned long)0x00000200; -static const unsigned long format_message_from_string - = (unsigned long)0x00000400; -static const unsigned long format_message_from_hmodule - = (unsigned long)0x00000800; -static const unsigned long format_message_from_system - = (unsigned long)0x00001000; -static const unsigned long format_message_argument_array - = (unsigned long)0x00002000; -static const unsigned long format_message_max_width_mask - = (unsigned long)0x000000FF; -static const unsigned long lang_neutral = (unsigned long)0x00; -static const unsigned long sublang_default = (unsigned long)0x01; -static const unsigned long invalid_file_size = (unsigned long)0xFFFFFFFF; -static const unsigned long invalid_file_attributes = ((unsigned long)-1); -static void * const invalid_handle_value = ((void*)(long)(-1)); - -static const unsigned long file_type_char = 0x0002L; -static const unsigned long file_type_disk = 0x0001L; -static const unsigned long file_type_pipe = 0x0003L; -static const unsigned long file_type_remote = 0x8000L; -static const unsigned long file_type_unknown = 0x0000L; - -static const unsigned long create_new = 1; -static const unsigned long create_always = 2; -static const unsigned long open_existing = 3; -static const unsigned long open_always = 4; -static const unsigned long truncate_existing = 5; - -static const unsigned long file_begin = 0; -static const unsigned long file_current = 1; -static const unsigned long file_end = 2; - -static const unsigned long lockfile_fail_immediately = 1; -static const unsigned long lockfile_exclusive_lock = 2; -static const unsigned long error_lock_violation = 33; -static const unsigned long security_descriptor_revision = 1; - -const unsigned long max_record_buffer_size = 0x10000L; // 64K - -//Own defines -static const long SystemTimeOfDayInfoLength = 48; -static const long BootAndSystemstampLength = 16; -static const long BootstampLength = 8; -static const unsigned long MaxPath = 260; - -//Keys -static void * const hkey_local_machine = (void*)(unsigned long*)(long)(0x80000002); -static unsigned long key_query_value = 0x0001; - -//COM API -const unsigned long RPC_C_AUTHN_LEVEL_PKT_BIPC = 4; -const unsigned long RPC_C_AUTHN_DEFAULT_BIPC = 0xffffffffL; -const unsigned long RPC_C_AUTHZ_DEFAULT_BIPC = 0xffffffffL; -const unsigned long RPC_C_IMP_LEVEL_IMPERSONATE_BIPC = 3; -const signed long EOAC_NONE_BIPC = 0; -const signed long CLSCTX_INPROC_SERVER_BIPC = 0x1; -const signed long CLSCTX_LOCAL_SERVER_BIPC = 0x4; -const signed long WBEM_FLAG_RETURN_IMMEDIATELY_BIPC = 0x10; -const signed long WBEM_FLAG_RETURN_WHEN_COMPLETE_BIPC = 0x0; -const signed long WBEM_FLAG_FORWARD_ONLY_BIPC = 0x20; -const signed long WBEM_INFINITE_BIPC = 0xffffffffL; -const signed long RPC_E_TOO_LATE_BIPC = 0x80010119L; -const signed long S_OK_BIPC = 0L; -const signed long S_FALSE_BIPC = 1; -const signed long RPC_E_CHANGED_MODE_BIPC = 0x80010106L; -const unsigned long COINIT_APARTMENTTHREADED_BIPC = 0x2; -const unsigned long COINIT_MULTITHREADED_BIPC = 0x0; -const unsigned long COINIT_DISABLE_OLE1DDE_BIPC = 0x4; -const unsigned long COINIT_SPEED_OVER_MEMORY_BIPC = 0x4; - -//If the user needs to change default COM initialization model, -//it can define BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL to one of these: -// -// COINIT_APARTMENTTHREADED_BIPC -// COINIT_MULTITHREADED_BIPC -// COINIT_DISABLE_OLE1DDE_BIPC -// COINIT_SPEED_OVER_MEMORY_BIPC -#if !defined(BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL) - #define BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL COINIT_APARTMENTTHREADED_BIPC -#elif (BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL != COINIT_APARTMENTTHREADED_BIPC) &&\ - (BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL != COINIT_MULTITHREADED_BIPC) &&\ - (BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL != COINIT_DISABLE_OLE1DDE_BIPC) &&\ - (BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL != COINIT_SPEED_OVER_MEMORY_BIPC) - #error "Wrong value for BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL macro" -#endif - -} //namespace winapi { -} //namespace interprocess { -} //namespace boost { - - -namespace boost { -namespace interprocess { -namespace winapi { - -struct GUID_BIPC -{ - unsigned long Data1; - unsigned short Data2; - unsigned short Data3; - unsigned char Data4[8]; -}; - -const GUID_BIPC CLSID_WbemAdministrativeLocator = - { 0xcb8555cc, 0x9128, 0x11d1, {0xad, 0x9b, 0x00, 0xc0, 0x4f, 0xd8, 0xfd, 0xff}}; - -const GUID_BIPC IID_IUnknown = { 0x00000000, 0x0000, 0x0000, {0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46}}; - -struct wchar_variant -{ - unsigned long long dummy; - union value_t{ - wchar_t *pbstrVal; - unsigned long long dummy; - } value; -}; - -struct IUnknown_BIPC -{ - public: - virtual long __stdcall QueryInterface( - const GUID_BIPC &riid, // [in] - void **ppvObject) = 0; // [iid_is][out] - - virtual unsigned long __stdcall AddRef (void) = 0; - virtual unsigned long __stdcall Release(void) = 0; -}; - -struct IWbemClassObject_BIPC : public IUnknown_BIPC -{ - public: - virtual long __stdcall GetQualifierSet( - /* [out] */ void **ppQualSet) = 0; - - virtual long __stdcall Get( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [unique][in][out] */ wchar_variant *pVal, - /* [unique][in][out] */ long *pType, - /* [unique][in][out] */ long *plFlavor) = 0; - - virtual long __stdcall Put( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [in] */ wchar_variant *pVal, - /* [in] */ long Type) = 0; - - virtual long __stdcall Delete( - /* [string][in] */ const wchar_t * wszName) = 0; - - virtual long __stdcall GetNames( - /* [string][in] */ const wchar_t * wszQualifierName, - /* [in] */ long lFlags, - /* [in] */ wchar_variant *pQualifierVal, - /* [out] */ void * *pNames) = 0; - - virtual long __stdcall BeginEnumeration( - /* [in] */ long lEnumFlags) = 0; - - virtual long __stdcall Next( - /* [in] */ long lFlags, - /* [unique][in][out] */ wchar_t * *strName, - /* [unique][in][out] */ wchar_variant *pVal, - /* [unique][in][out] */ long *pType, - /* [unique][in][out] */ long *plFlavor) = 0; - - virtual long __stdcall EndEnumeration( void) = 0; - - virtual long __stdcall GetPropertyQualifierSet( - /* [string][in] */ const wchar_t * wszProperty, - /* [out] */ void **ppQualSet) = 0; - - virtual long __stdcall Clone( - /* [out] */ IWbemClassObject_BIPC **ppCopy) = 0; - - virtual long __stdcall GetObjectText( - /* [in] */ long lFlags, - /* [out] */ wchar_t * *pstrObjectText) = 0; - - virtual long __stdcall SpawnDerivedClass( - /* [in] */ long lFlags, - /* [out] */ IWbemClassObject_BIPC **ppNewClass) = 0; - - virtual long __stdcall SpawnInstance( - /* [in] */ long lFlags, - /* [out] */ IWbemClassObject_BIPC **ppNewInstance) = 0; - - virtual long __stdcall CompareTo( - /* [in] */ long lFlags, - /* [in] */ IWbemClassObject_BIPC *pCompareTo) = 0; - - virtual long __stdcall GetPropertyOrigin( - /* [string][in] */ const wchar_t * wszName, - /* [out] */ wchar_t * *pstrClassName) = 0; - - virtual long __stdcall InheritsFrom( - /* [in] */ const wchar_t * strAncestor) = 0; - - virtual long __stdcall GetMethod( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [out] */ IWbemClassObject_BIPC **ppInSignature, - /* [out] */ IWbemClassObject_BIPC **ppOutSignature) = 0; - - virtual long __stdcall PutMethod( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [in] */ IWbemClassObject_BIPC *pInSignature, - /* [in] */ IWbemClassObject_BIPC *pOutSignature) = 0; - - virtual long __stdcall DeleteMethod( - /* [string][in] */ const wchar_t * wszName) = 0; - - virtual long __stdcall BeginMethodEnumeration( - /* [in] */ long lEnumFlags) = 0; - - virtual long __stdcall NextMethod( - /* [in] */ long lFlags, - /* [unique][in][out] */ wchar_t * *pstrName, - /* [unique][in][out] */ IWbemClassObject_BIPC **ppInSignature, - /* [unique][in][out] */ IWbemClassObject_BIPC **ppOutSignature) = 0; - - virtual long __stdcall EndMethodEnumeration( void) = 0; - - virtual long __stdcall GetMethodQualifierSet( - /* [string][in] */ const wchar_t * wszMethod, - /* [out] */ void **ppQualSet) = 0; - - virtual long __stdcall GetMethodOrigin( - /* [string][in] */ const wchar_t * wszMethodName, - /* [out] */ wchar_t * *pstrClassName) = 0; - -}; - -struct IWbemContext_BIPC : public IUnknown_BIPC -{ -public: - virtual long __stdcall Clone( - /* [out] */ IWbemContext_BIPC **ppNewCopy) = 0; - - virtual long __stdcall GetNames( - /* [in] */ long lFlags, - /* [out] */ void * *pNames) = 0; - - virtual long __stdcall BeginEnumeration( - /* [in] */ long lFlags) = 0; - - virtual long __stdcall Next( - /* [in] */ long lFlags, - /* [out] */ wchar_t * *pstrName, - /* [out] */ wchar_variant *pValue) = 0; - - virtual long __stdcall EndEnumeration( void) = 0; - - virtual long __stdcall SetValue( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [in] */ wchar_variant *pValue) = 0; - - virtual long __stdcall GetValue( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags, - /* [out] */ wchar_variant *pValue) = 0; - - virtual long __stdcall DeleteValue( - /* [string][in] */ const wchar_t * wszName, - /* [in] */ long lFlags) = 0; - - virtual long __stdcall DeleteAll( void) = 0; - -}; - - -struct IEnumWbemClassObject_BIPC : public IUnknown_BIPC -{ -public: - virtual long __stdcall Reset( void) = 0; - - virtual long __stdcall Next( - /* [in] */ long lTimeout, - /* [in] */ unsigned long uCount, - /* [length_is][size_is][out] */ IWbemClassObject_BIPC **apObjects, - /* [out] */ unsigned long *puReturned) = 0; - - virtual long __stdcall NextAsync( - /* [in] */ unsigned long uCount, - /* [in] */ void *pSink) = 0; - - virtual long __stdcall Clone( - /* [out] */ void **ppEnum) = 0; - - virtual long __stdcall Skip( - /* [in] */ long lTimeout, - /* [in] */ unsigned long nCount) = 0; - -}; - -struct IWbemServices_BIPC : public IUnknown_BIPC -{ -public: - virtual long __stdcall OpenNamespace( - /* [in] */ const wchar_t * strNamespace, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppWorkingNamespace, - /* [unique][in][out] */ void **ppResult) = 0; - - virtual long __stdcall CancelAsyncCall( - /* [in] */ void *pSink) = 0; - - virtual long __stdcall QueryObjectSink( - /* [in] */ long lFlags, - /* [out] */ void **ppResponseHandler) = 0; - - virtual long __stdcall GetObject( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppObject, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall GetObjectAsync( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall PutClass( - /* [in] */ IWbemClassObject_BIPC *pObject, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall PutClassAsync( - /* [in] */ IWbemClassObject_BIPC *pObject, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall DeleteClass( - /* [in] */ const wchar_t * strClass, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall DeleteClassAsync( - /* [in] */ const wchar_t * strClass, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall CreateClassEnum( - /* [in] */ const wchar_t * strSuperclass, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [out] */ void **ppEnum) = 0; - - virtual long __stdcall CreateClassEnumAsync( - /* [in] */ const wchar_t * strSuperclass, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall PutInstance( - /* [in] */ void *pInst, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall PutInstanceAsync( - /* [in] */ void *pInst, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall DeleteInstance( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall DeleteInstanceAsync( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall CreateInstanceEnum( - /* [in] */ const wchar_t * strFilter, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [out] */ void **ppEnum) = 0; - - virtual long __stdcall CreateInstanceEnumAsync( - /* [in] */ const wchar_t * strFilter, - /* [in] */ long lFlags, - /* [in] */ void *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall ExecQuery( - /* [in] */ const wchar_t * strQueryLanguage, - /* [in] */ const wchar_t * strQuery, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [out] */ IEnumWbemClassObject_BIPC **ppEnum) = 0; - - virtual long __stdcall ExecQueryAsync( - /* [in] */ const wchar_t * strQueryLanguage, - /* [in] */ const wchar_t * strQuery, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall ExecNotificationQuery( - /* [in] */ const wchar_t * strQueryLanguage, - /* [in] */ const wchar_t * strQuery, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [out] */ void **ppEnum) = 0; - - virtual long __stdcall ExecNotificationQueryAsync( - /* [in] */ const wchar_t * strQueryLanguage, - /* [in] */ const wchar_t * strQuery, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [in] */ void *pResponseHandler) = 0; - - virtual long __stdcall ExecMethod( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ const wchar_t * strMethodName, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [in] */ IWbemClassObject_BIPC *pInParams, - /* [unique][in][out] */ IWbemClassObject_BIPC **ppOutParams, - /* [unique][in][out] */ void **ppCallResult) = 0; - - virtual long __stdcall ExecMethodAsync( - /* [in] */ const wchar_t * strObjectPath, - /* [in] */ const wchar_t * strMethodName, - /* [in] */ long lFlags, - /* [in] */ IWbemContext_BIPC *pCtx, - /* [in] */ IWbemClassObject_BIPC *pInParams, - /* [in] */ void *pResponseHandler) = 0; - -}; - -struct IWbemLocator_BIPC : public IUnknown_BIPC -{ -public: - virtual long __stdcall ConnectServer( - /* [in] */ const wchar_t * strNetworkResource, - /* [in] */ const wchar_t * strUser, - /* [in] */ const wchar_t * strPassword, - /* [in] */ const wchar_t * strLocale, - /* [in] */ long lSecurityFlags, - /* [in] */ const wchar_t * strAuthority, - /* [in] */ void *pCtx, - /* [out] */ IWbemServices_BIPC **ppNamespace) = 0; - -}; - -struct interprocess_overlapped -{ - unsigned long *internal; - unsigned long *internal_high; - union { - struct { - unsigned long offset; - unsigned long offset_high; - }dummy; - void *pointer; - }; - - void *h_event; -}; - -struct interprocess_semaphore_basic_information -{ - unsigned int count; // current semaphore count - unsigned int limit; // max semaphore count -}; - -struct interprocess_section_basic_information -{ - void * base_address; - unsigned long section_attributes; - __int64 section_size; -}; - -struct interprocess_filetime -{ - unsigned long dwLowDateTime; - unsigned long dwHighDateTime; -}; - -struct win32_find_data_t -{ - unsigned long dwFileAttributes; - interprocess_filetime ftCreationTime; - interprocess_filetime ftLastAccessTime; - interprocess_filetime ftLastWriteTime; - unsigned long nFileSizeHigh; - unsigned long nFileSizeLow; - unsigned long dwReserved0; - unsigned long dwReserved1; - char cFileName[MaxPath]; - char cAlternateFileName[14]; -}; - -struct interprocess_security_attributes -{ - unsigned long nLength; - void *lpSecurityDescriptor; - int bInheritHandle; -}; - -struct system_info { - union { - unsigned long dwOemId; // Obsolete field...do not use - struct { - unsigned short wProcessorArchitecture; - unsigned short wReserved; - } dummy; - }; - unsigned long dwPageSize; - void * lpMinimumApplicationAddress; - void * lpMaximumApplicationAddress; - unsigned long * dwActiveProcessorMask; - unsigned long dwNumberOfProcessors; - unsigned long dwProcessorType; - unsigned long dwAllocationGranularity; - unsigned short wProcessorLevel; - unsigned short wProcessorRevision; -}; - -struct interprocess_memory_basic_information -{ - void * BaseAddress; - void * AllocationBase; - unsigned long AllocationProtect; - unsigned long RegionSize; - unsigned long State; - unsigned long Protect; - unsigned long Type; -}; - -struct interprocess_acl -{ - unsigned char AclRevision; - unsigned char Sbz1; - unsigned short AclSize; - unsigned short AceCount; - unsigned short Sbz2; -}; - -typedef struct _interprocess_security_descriptor -{ - unsigned char Revision; - unsigned char Sbz1; - unsigned short Control; - void *Owner; - void *Group; - interprocess_acl *Sacl; - interprocess_acl *Dacl; -} interprocess_security_descriptor; - -enum file_information_class_t { - file_directory_information = 1, - file_full_directory_information, - file_both_directory_information, - file_basic_information, - file_standard_information, - file_internal_information, - file_ea_information, - file_access_information, - file_name_information, - file_rename_information, - file_link_information, - file_names_information, - file_disposition_information, - file_position_information, - file_full_ea_information, - file_mode_information, - file_alignment_information, - file_all_information, - file_allocation_information, - file_end_of_file_information, - file_alternate_name_information, - file_stream_information, - file_pipe_information, - file_pipe_local_information, - file_pipe_remote_information, - file_mailslot_query_information, - file_mailslot_set_information, - file_compression_information, - file_copy_on_write_information, - file_completion_information, - file_move_cluster_information, - file_quota_information, - file_reparse_point_information, - file_network_open_information, - file_object_id_information, - file_tracking_information, - file_ole_directory_information, - file_content_index_information, - file_inherit_content_index_information, - file_ole_information, - file_maximum_information -}; - -enum semaphore_information_class { - semaphore_basic_information = 0 -}; - -struct file_name_information_t { - unsigned long FileNameLength; - wchar_t FileName[1]; -}; - -struct file_rename_information_t { - int Replace; - void *RootDir; - unsigned long FileNameLength; - wchar_t FileName[1]; -}; - -struct unicode_string_t { - unsigned short Length; - unsigned short MaximumLength; - wchar_t *Buffer; -}; - -struct object_attributes_t { - unsigned long Length; - void * RootDirectory; - unicode_string_t *ObjectName; - unsigned long Attributes; - void *SecurityDescriptor; - void *SecurityQualityOfService; -}; - -struct io_status_block_t { - union { - long Status; - void *Pointer; - }; - - unsigned long *Information; -}; - -union system_timeofday_information -{ - struct data_t - { - __int64 liKeBootTime; - __int64 liKeSystemTime; - __int64 liExpTimeZoneBias; - unsigned long uCurrentTimeZoneId; - unsigned long dwReserved; - } data; - unsigned char Reserved1[SystemTimeOfDayInfoLength]; -}; - -struct interprocess_by_handle_file_information -{ - unsigned long dwFileAttributes; - interprocess_filetime ftCreationTime; - interprocess_filetime ftLastAccessTime; - interprocess_filetime ftLastWriteTime; - unsigned long dwVolumeSerialNumber; - unsigned long nFileSizeHigh; - unsigned long nFileSizeLow; - unsigned long nNumberOfLinks; - unsigned long nFileIndexHigh; - unsigned long nFileIndexLow; -}; - -enum system_information_class { - system_basic_information = 0, - system_performance_information = 2, - system_time_of_day_information = 3, - system_process_information = 5, - system_processor_performance_information = 8, - system_interrupt_information = 23, - system_exception_information = 33, - system_registry_quota_information = 37, - system_lookaside_information = 45 -}; - -enum object_information_class -{ - object_basic_information, - object_name_information, - object_type_information, - object_all_information, - object_data_information -}; - -enum section_information_class -{ - section_basic_information, - section_image_information -}; - -struct object_name_information_t -{ - unicode_string_t Name; - wchar_t NameBuffer[1]; -}; - -struct interprocess_eventlogrecord -{ - unsigned long Length; // Length of full record - unsigned long Reserved; // Used by the service - unsigned long RecordNumber; // Absolute record number - unsigned long TimeGenerated; // Seconds since 1-1-1970 - unsigned long TimeWritten; // Seconds since 1-1-1970 - unsigned long EventID; - unsigned short EventType; - unsigned short NumStrings; - unsigned short EventCategory; - unsigned short ReservedFlags; // For use with paired events (auditing) - unsigned long ClosingRecordNumber; // For use with paired events (auditing) - unsigned long StringOffset; // Offset from beginning of record - unsigned long UserSidLength; - unsigned long UserSidOffset; - unsigned long DataLength; - unsigned long DataOffset; // Offset from beginning of record - // - // Then follow: - // - // wchar_t SourceName[] - // wchar_t Computername[] - // SID UserSid - // wchar_t Strings[] - // BYTE Data[] - // CHAR Pad[] - // unsigned long Length; - // -}; - -//Kernel32.dll - -//Some windows API declarations -extern "C" __declspec(dllimport) unsigned long __stdcall GetCurrentProcessId(); -extern "C" __declspec(dllimport) unsigned long __stdcall GetCurrentThreadId(); -extern "C" __declspec(dllimport) int __stdcall GetProcessTimes - ( void *hProcess, interprocess_filetime* lpCreationTime - , interprocess_filetime *lpExitTime,interprocess_filetime *lpKernelTime - , interprocess_filetime *lpUserTime ); -extern "C" __declspec(dllimport) void __stdcall Sleep(unsigned long); -extern "C" __declspec(dllimport) unsigned long __stdcall GetTickCount(void); -extern "C" __declspec(dllimport) int __stdcall SwitchToThread(); -extern "C" __declspec(dllimport) unsigned long __stdcall GetLastError(); -extern "C" __declspec(dllimport) void __stdcall SetLastError(unsigned long); -extern "C" __declspec(dllimport) void * __stdcall GetCurrentProcess(); -extern "C" __declspec(dllimport) int __stdcall CloseHandle(void*); -extern "C" __declspec(dllimport) int __stdcall DuplicateHandle - ( void *hSourceProcessHandle, void *hSourceHandle - , void *hTargetProcessHandle, void **lpTargetHandle - , unsigned long dwDesiredAccess, int bInheritHandle - , unsigned long dwOptions); -extern "C" __declspec(dllimport) long __stdcall GetFileType(void *hFile); -extern "C" __declspec(dllimport) void *__stdcall FindFirstFileA(const char *lpFileName, win32_find_data_t *lpFindFileData); -extern "C" __declspec(dllimport) int __stdcall FindNextFileA(void *hFindFile, win32_find_data_t *lpFindFileData); -extern "C" __declspec(dllimport) int __stdcall FindClose(void *hFindFile); -//extern "C" __declspec(dllimport) void __stdcall GetSystemTimeAsFileTime(interprocess_filetime*); -//extern "C" __declspec(dllimport) int __stdcall FileTimeToLocalFileTime(const interprocess_filetime *in, const interprocess_filetime *out); -extern "C" __declspec(dllimport) void * __stdcall CreateMutexA(interprocess_security_attributes*, int, const char *); -extern "C" __declspec(dllimport) void * __stdcall OpenMutexA(unsigned long, int, const char *); -extern "C" __declspec(dllimport) unsigned long __stdcall WaitForSingleObject(void *, unsigned long); -extern "C" __declspec(dllimport) int __stdcall ReleaseMutex(void *); -extern "C" __declspec(dllimport) int __stdcall UnmapViewOfFile(void *); -extern "C" __declspec(dllimport) void * __stdcall CreateSemaphoreA(interprocess_security_attributes*, long, long, const char *); -extern "C" __declspec(dllimport) int __stdcall ReleaseSemaphore(void *, long, long *); -extern "C" __declspec(dllimport) void * __stdcall OpenSemaphoreA(unsigned long, int, const char *); -extern "C" __declspec(dllimport) void * __stdcall CreateFileMappingA (void *, interprocess_security_attributes*, unsigned long, unsigned long, unsigned long, const char *); -extern "C" __declspec(dllimport) void * __stdcall MapViewOfFileEx (void *, unsigned long, unsigned long, unsigned long, std::size_t, void*); -extern "C" __declspec(dllimport) void * __stdcall OpenFileMappingA (unsigned long, int, const char *); -extern "C" __declspec(dllimport) void * __stdcall CreateFileA (const char *, unsigned long, unsigned long, struct interprocess_security_attributes*, unsigned long, unsigned long, void *); -extern "C" __declspec(dllimport) void __stdcall GetSystemInfo (struct system_info *); -extern "C" __declspec(dllimport) int __stdcall FlushViewOfFile (void *, std::size_t); -extern "C" __declspec(dllimport) int __stdcall VirtualUnlock (void *, std::size_t); -extern "C" __declspec(dllimport) int __stdcall VirtualProtect (void *, std::size_t, unsigned long, unsigned long *); -extern "C" __declspec(dllimport) int __stdcall FlushFileBuffers (void *); -extern "C" __declspec(dllimport) int __stdcall GetFileSizeEx (void *, __int64 *size); -extern "C" __declspec(dllimport) unsigned long __stdcall FormatMessageA - (unsigned long dwFlags, const void *lpSource, unsigned long dwMessageId, - unsigned long dwLanguageId, char *lpBuffer, unsigned long nSize, - std::va_list *Arguments); -extern "C" __declspec(dllimport) void *__stdcall LocalFree (void *); -extern "C" __declspec(dllimport) unsigned long __stdcall GetFileAttributesA(const char *); -extern "C" __declspec(dllimport) int __stdcall CreateDirectoryA(const char *, interprocess_security_attributes*); -extern "C" __declspec(dllimport) int __stdcall RemoveDirectoryA(const char *lpPathName); -extern "C" __declspec(dllimport) int __stdcall GetTempPathA(unsigned long length, char *buffer); -extern "C" __declspec(dllimport) int __stdcall CreateDirectory(const char *, interprocess_security_attributes*); -extern "C" __declspec(dllimport) int __stdcall SetFileValidData(void *, __int64 size); -extern "C" __declspec(dllimport) int __stdcall SetEndOfFile(void *); -extern "C" __declspec(dllimport) int __stdcall SetFilePointerEx(void *, __int64 distance, __int64 *new_file_pointer, unsigned long move_method); -extern "C" __declspec(dllimport) int __stdcall LockFile (void *hnd, unsigned long offset_low, unsigned long offset_high, unsigned long size_low, unsigned long size_high); -extern "C" __declspec(dllimport) int __stdcall UnlockFile(void *hnd, unsigned long offset_low, unsigned long offset_high, unsigned long size_low, unsigned long size_high); -extern "C" __declspec(dllimport) int __stdcall LockFileEx(void *hnd, unsigned long flags, unsigned long reserved, unsigned long size_low, unsigned long size_high, interprocess_overlapped* overlapped); -extern "C" __declspec(dllimport) int __stdcall UnlockFileEx(void *hnd, unsigned long reserved, unsigned long size_low, unsigned long size_high, interprocess_overlapped* overlapped); -extern "C" __declspec(dllimport) int __stdcall WriteFile(void *hnd, const void *buffer, unsigned long bytes_to_write, unsigned long *bytes_written, interprocess_overlapped* overlapped); -extern "C" __declspec(dllimport) int __stdcall ReadFile(void *hnd, void *buffer, unsigned long bytes_to_read, unsigned long *bytes_read, interprocess_overlapped* overlapped); -extern "C" __declspec(dllimport) int __stdcall InitializeSecurityDescriptor(interprocess_security_descriptor *pSecurityDescriptor, unsigned long dwRevision); -extern "C" __declspec(dllimport) int __stdcall SetSecurityDescriptorDacl(interprocess_security_descriptor *pSecurityDescriptor, int bDaclPresent, interprocess_acl *pDacl, int bDaclDefaulted); -extern "C" __declspec(dllimport) void *__stdcall LoadLibraryA(const char *); -extern "C" __declspec(dllimport) int __stdcall FreeLibrary(void *); -extern "C" __declspec(dllimport) void *__stdcall GetProcAddress(void *, const char*); -extern "C" __declspec(dllimport) void *__stdcall GetModuleHandleA(const char*); -extern "C" __declspec(dllimport) void *__stdcall GetFileInformationByHandle(void *, interprocess_by_handle_file_information*); - -//Advapi32.dll -extern "C" __declspec(dllimport) long __stdcall RegOpenKeyExA(void *, const char *, unsigned long, unsigned long, void **); -extern "C" __declspec(dllimport) long __stdcall RegQueryValueExA(void *, const char *, unsigned long*, unsigned long*, unsigned char *, unsigned long*); -extern "C" __declspec(dllimport) long __stdcall RegCloseKey(void *); - -//Ole32.dll -extern "C" __declspec(dllimport) long __stdcall CoInitializeEx(void *pvReserved, unsigned long dwCoInit); -extern "C" __declspec(dllimport) long __stdcall CoInitializeSecurity( - void* pSecDesc, - long cAuthSvc, - void * asAuthSvc, - void *pReserved1, - unsigned long dwAuthnLevel, - unsigned long dwImpLevel, - void *pAuthList, - unsigned long dwCapabilities, - void *pReserved3 ); - - extern "C" __declspec(dllimport) long __stdcall CoSetProxyBlanket( - IUnknown_BIPC *pProxy, - unsigned long dwAuthnSvc, - unsigned long dwAuthzSvc, - wchar_t *pServerPrincName, - unsigned long dwAuthnLevel, - unsigned long dwImpLevel, - void *pAuthInfo, - unsigned long dwCapabilities); -extern "C" __declspec(dllimport) long __stdcall CoCreateInstance(const GUID_BIPC & rclsid, IUnknown_BIPC *pUnkOuter, - unsigned long dwClsContext, const GUID_BIPC & riid, void** ppv); -extern "C" __declspec(dllimport) void __stdcall CoUninitialize(void); - -//OleAut32.dll -extern "C" __declspec(dllimport) long __stdcall VariantClear(wchar_variant * pvarg); - - -//EventLog access functions - -static const unsigned long eventlog_sequential_read = 0x0001; -static const unsigned long eventlog_backwards_read = 0x0008; - -extern "C" __declspec(dllimport) void* __stdcall OpenEventLogA - (const char* lpUNCServerName, const char* lpSourceName); - -extern "C" __declspec(dllimport) int __stdcall CloseEventLog(void *hEventLog); - -extern "C" __declspec(dllimport) int __stdcall ReadEventLogA - (void *hEventLog, - unsigned long dwReadFlags, - unsigned long dwRecordOffset, - void *lpBuffer, - unsigned long nNumberOfBytesToRead, - unsigned long *pnBytesRead, - unsigned long *pnMinNumberOfBytesNeeded - ); - - -//ntdll.dll -typedef long (__stdcall *NtDeleteFile_t)(object_attributes_t *ObjectAttributes); -typedef long (__stdcall *NtSetInformationFile_t)(void *FileHandle, io_status_block_t *IoStatusBlock, void *FileInformation, unsigned long Length, int FileInformationClass ); -typedef long (__stdcall *NtOpenFile)(void **FileHandle, unsigned long DesiredAccess, object_attributes_t *ObjectAttributes - , io_status_block_t *IoStatusBlock, unsigned long ShareAccess, unsigned long Length, unsigned long OpenOptions); -typedef long (__stdcall *NtQuerySystemInformation_t)(int, void*, unsigned long, unsigned long *); -typedef long (__stdcall *NtQueryObject_t)(void*, object_information_class, void *, unsigned long, unsigned long *); -typedef long (__stdcall *NtQuerySemaphore_t)(void*, unsigned int info_class, interprocess_semaphore_basic_information *pinfo, unsigned int info_size, unsigned int *ret_len); -typedef long (__stdcall *NtQuerySection_t)(void*, section_information_class, interprocess_section_basic_information *pinfo, unsigned long info_size, unsigned long *ret_len); -typedef long (__stdcall *NtQueryInformationFile_t)(void *,io_status_block_t *,void *, long, int); -typedef long (__stdcall *NtOpenFile_t)(void*,unsigned long ,object_attributes_t*,io_status_block_t*,unsigned long,unsigned long); -typedef long (__stdcall *NtClose_t) (void*); -typedef long (__stdcall *NtQueryTimerResolution_t) (unsigned long* LowestResolution, unsigned long* HighestResolution, unsigned long* CurrentResolution); -typedef long (__stdcall *NtSetTimerResolution_t) (unsigned long RequestedResolution, int Set, unsigned long* ActualResolution); - -//kernel32.dll -typedef int (__stdcall *QueryPerformanceCounter_t) (__int64 *lpPerformanceCount); -typedef int (__stdcall *QueryPerformanceFrequency_t)(__int64 *lpFrequency); - -} //namespace winapi { -} //namespace interprocess { -} //namespace boost { - -namespace boost { -namespace interprocess { -namespace winapi { - -inline unsigned long get_last_error() -{ return GetLastError(); } - -inline void set_last_error(unsigned long err) -{ return SetLastError(err); } - -inline unsigned long format_message - (unsigned long dwFlags, const void *lpSource, - unsigned long dwMessageId, unsigned long dwLanguageId, - char *lpBuffer, unsigned long nSize, std::va_list *Arguments) -{ - return FormatMessageA - (dwFlags, lpSource, dwMessageId, dwLanguageId, lpBuffer, nSize, Arguments); -} - -//And now, wrapper functions -inline void * local_free(void *hmem) -{ return LocalFree(hmem); } - -inline unsigned long make_lang_id(unsigned long p, unsigned long s) -{ return ((((unsigned short)(s)) << 10) | (unsigned short)(p)); } - -inline void sched_yield() -{ - if(!SwitchToThread()){ - Sleep(0); - } -} - -inline void sleep_tick() -{ Sleep(1); } - -inline void sleep(unsigned long ms) -{ Sleep(ms); } - -inline unsigned long get_current_thread_id() -{ return GetCurrentThreadId(); } - -inline bool get_process_times - ( void *hProcess, interprocess_filetime* lpCreationTime - , interprocess_filetime *lpExitTime, interprocess_filetime *lpKernelTime - , interprocess_filetime *lpUserTime ) -{ return 0 != GetProcessTimes(hProcess, lpCreationTime, lpExitTime, lpKernelTime, lpUserTime); } - -inline unsigned long get_current_process_id() -{ return GetCurrentProcessId(); } - -inline unsigned int close_handle(void* handle) -{ return CloseHandle(handle); } - -inline void * find_first_file(const char *lpFileName, win32_find_data_t *lpFindFileData) -{ return FindFirstFileA(lpFileName, lpFindFileData); } - -inline bool find_next_file(void *hFindFile, win32_find_data_t *lpFindFileData) -{ return FindNextFileA(hFindFile, lpFindFileData) != 0; } - -inline bool find_close(void *handle) -{ return FindClose(handle) != 0; } - -inline bool duplicate_current_process_handle - (void *hSourceHandle, void **lpTargetHandle) -{ - return 0 != DuplicateHandle - ( GetCurrentProcess(), hSourceHandle, GetCurrentProcess() - , lpTargetHandle, 0, 0 - , duplicate_same_access); -} - -inline unsigned long get_file_type(void *hFile) -{ - return GetFileType(hFile); -} - -/* -inline void get_system_time_as_file_time(interprocess_filetime *filetime) -{ GetSystemTimeAsFileTime(filetime); } - -inline bool file_time_to_local_file_time - (const interprocess_filetime *in, const interprocess_filetime *out) -{ return 0 != FileTimeToLocalFileTime(in, out); } -*/ -inline void *open_or_create_mutex(const char *name, bool initial_owner, interprocess_security_attributes *attr) -{ return CreateMutexA(attr, (int)initial_owner, name); } - -inline unsigned long wait_for_single_object(void *handle, unsigned long time) -{ return WaitForSingleObject(handle, time); } - -inline int release_mutex(void *handle) -{ return ReleaseMutex(handle); } - -inline int unmap_view_of_file(void *address) -{ return UnmapViewOfFile(address); } - -inline void *open_or_create_semaphore(const char *name, long initial_count, long maximum_count, interprocess_security_attributes *attr) -{ return CreateSemaphoreA(attr, initial_count, maximum_count, name); } - -inline void *open_semaphore(const char *name) -{ return OpenSemaphoreA(semaphore_all_access, 0, name); } - -inline int release_semaphore(void *handle, long release_count, long *prev_count) -{ return ReleaseSemaphore(handle, release_count, prev_count); } - -class interprocess_all_access_security -{ - interprocess_security_attributes sa; - interprocess_security_descriptor sd; - bool initialized; - - public: - interprocess_all_access_security() - : initialized(false) - { - if(!InitializeSecurityDescriptor(&sd, security_descriptor_revision)) - return; - if(!SetSecurityDescriptorDacl(&sd, true, 0, false)) - return; - sa.lpSecurityDescriptor = &sd; - sa.nLength = sizeof(interprocess_security_attributes); - sa.bInheritHandle = false; - initialized = false; - } - - interprocess_security_attributes *get_attributes() - { return &sa; } -}; - -inline void * create_file_mapping (void * handle, unsigned long access, unsigned __int64 file_offset, const char * name, interprocess_security_attributes *psec) -{ - const unsigned long high_size(file_offset >> 32), low_size((boost::uint32_t)file_offset); - return CreateFileMappingA (handle, psec, access, high_size, low_size, name); -} - -inline void * open_file_mapping (unsigned long access, const char *name) -{ return OpenFileMappingA (access, 0, name); } - -inline void *map_view_of_file_ex(void *handle, unsigned long file_access, unsigned __int64 offset, std::size_t numbytes, void *base_addr) -{ - const unsigned long offset_low = (unsigned long)(offset & ((unsigned __int64)0xFFFFFFFF)); - const unsigned long offset_high = offset >> 32; - return MapViewOfFileEx(handle, file_access, offset_high, offset_low, numbytes, base_addr); -} - -inline void *create_file(const char *name, unsigned long access, unsigned long creation_flags, unsigned long attributes, interprocess_security_attributes *psec) -{ - for (unsigned int attempt(0); attempt < error_sharing_violation_tries; ++attempt){ - void * const handle = CreateFileA(name, access, - file_share_read | file_share_write | file_share_delete, - psec, creation_flags, attributes, 0); - bool const invalid(invalid_handle_value == handle); - if (!invalid){ - return handle; - } - if (error_sharing_violation != get_last_error()){ - return handle; - } - sleep(error_sharing_violation_sleep_ms); - } - return invalid_handle_value; -} - -inline void get_system_info(system_info *info) -{ GetSystemInfo(info); } - -inline bool flush_view_of_file(void *base_addr, std::size_t numbytes) -{ return 0 != FlushViewOfFile(base_addr, numbytes); } - -inline bool virtual_unlock(void *base_addr, std::size_t numbytes) -{ return 0 != VirtualUnlock(base_addr, numbytes); } - -inline bool virtual_protect(void *base_addr, std::size_t numbytes, unsigned long flNewProtect, unsigned long &lpflOldProtect) -{ return 0 != VirtualProtect(base_addr, numbytes, flNewProtect, &lpflOldProtect); } - -inline bool flush_file_buffers(void *handle) -{ return 0 != FlushFileBuffers(handle); } - -inline bool get_file_size(void *handle, __int64 &size) -{ return 0 != GetFileSizeEx(handle, &size); } - -inline bool create_directory(const char *name) -{ - interprocess_all_access_security sec; - return 0 != CreateDirectoryA(name, sec.get_attributes()); -} - -inline bool remove_directory(const char *lpPathName) -{ return 0 != RemoveDirectoryA(lpPathName); } - -inline unsigned long get_temp_path(unsigned long length, char *buffer) -{ return GetTempPathA(length, buffer); } - -inline int set_end_of_file(void *handle) -{ return 0 != SetEndOfFile(handle); } - -inline bool set_file_pointer_ex(void *handle, __int64 distance, __int64 *new_file_pointer, unsigned long move_method) -{ return 0 != SetFilePointerEx(handle, distance, new_file_pointer, move_method); } - -inline bool lock_file_ex(void *hnd, unsigned long flags, unsigned long reserved, unsigned long size_low, unsigned long size_high, interprocess_overlapped *overlapped) -{ return 0 != LockFileEx(hnd, flags, reserved, size_low, size_high, overlapped); } - -inline bool unlock_file_ex(void *hnd, unsigned long reserved, unsigned long size_low, unsigned long size_high, interprocess_overlapped *overlapped) -{ return 0 != UnlockFileEx(hnd, reserved, size_low, size_high, overlapped); } - -inline bool write_file(void *hnd, const void *buffer, unsigned long bytes_to_write, unsigned long *bytes_written, interprocess_overlapped* overlapped) -{ return 0 != WriteFile(hnd, buffer, bytes_to_write, bytes_written, overlapped); } - -inline bool read_file(void *hnd, void *buffer, unsigned long bytes_to_read, unsigned long *bytes_read, interprocess_overlapped* overlapped) -{ return 0 != ReadFile(hnd, buffer, bytes_to_read, bytes_read, overlapped); } - -inline bool get_file_information_by_handle(void *hnd, interprocess_by_handle_file_information *info) -{ return 0 != GetFileInformationByHandle(hnd, info); } - -inline long interlocked_increment(long volatile *addr) -{ return BOOST_INTERLOCKED_INCREMENT(addr); } - -inline long interlocked_decrement(long volatile *addr) -{ return BOOST_INTERLOCKED_DECREMENT(addr); } - -inline long interlocked_compare_exchange(long volatile *addr, long val1, long val2) -{ return BOOST_INTERLOCKED_COMPARE_EXCHANGE(addr, val1, val2); } - -inline long interlocked_exchange_add(long volatile* addend, long value) -{ return BOOST_INTERLOCKED_EXCHANGE_ADD(const_cast(addend), value); } - -inline long interlocked_exchange(long volatile* addend, long value) -{ return BOOST_INTERLOCKED_EXCHANGE(const_cast(addend), value); } - -//Forward functions -inline void *load_library(const char *name) -{ return LoadLibraryA(name); } - -inline bool free_library(void *module) -{ return 0 != FreeLibrary(module); } - -inline void *get_proc_address(void *module, const char *name) -{ return GetProcAddress(module, name); } - -inline void *get_current_process() -{ return GetCurrentProcess(); } - -inline void *get_module_handle(const char *name) -{ return GetModuleHandleA(name); } - -inline long reg_open_key_ex(void *hKey, const char *lpSubKey, unsigned long ulOptions, unsigned long samDesired, void **phkResult) -{ return RegOpenKeyExA(hKey, lpSubKey, ulOptions, samDesired, phkResult); } - -inline long reg_query_value_ex(void *hKey, const char *lpValueName, unsigned long*lpReserved, unsigned long*lpType, unsigned char *lpData, unsigned long*lpcbData) -{ return RegQueryValueExA(hKey, lpValueName, lpReserved, lpType, lpData, lpcbData); } - -inline long reg_close_key(void *hKey) -{ return RegCloseKey(hKey); } - -inline void initialize_object_attributes -( object_attributes_t *pobject_attr, unicode_string_t *name - , unsigned long attr, void *rootdir, void *security_descr) - -{ - pobject_attr->Length = sizeof(object_attributes_t); - pobject_attr->RootDirectory = rootdir; - pobject_attr->Attributes = attr; - pobject_attr->ObjectName = name; - pobject_attr->SecurityDescriptor = security_descr; - pobject_attr->SecurityQualityOfService = 0; -} - -inline void rtl_init_empty_unicode_string(unicode_string_t *ucStr, wchar_t *buf, unsigned short bufSize) -{ - ucStr->Buffer = buf; - ucStr->Length = 0; - ucStr->MaximumLength = bufSize; -} - -//A class that locates and caches loaded DLL function addresses. -template -struct function_address_holder -{ - enum { NtSetInformationFile - , NtQuerySystemInformation - , NtQueryObject - , NtQuerySemaphore - , NtQuerySection - , NtOpenFile - , NtClose - , NtQueryTimerResolution - , NtSetTimerResolution - , QueryPerformanceCounter - , QueryPerformanceFrequency - , NumFunction - }; - enum { NtDll_dll, Kernel32_dll, NumModule }; - - private: - static const char *FunctionNames[NumFunction]; - static const char *ModuleNames[NumModule]; - static void *FunctionAddresses[NumFunction]; - static unsigned int FunctionModules[NumFunction]; - static volatile long FunctionStates[NumFunction]; - static void *ModuleAddresses[NumModule]; - static volatile long ModuleStates[NumModule]; - - static void *get_module_from_id(unsigned int id) - { - BOOST_ASSERT(id < (unsigned int)NumModule); - void *addr = get_module_handle(ModuleNames[id]); - BOOST_ASSERT(addr); - return addr; - } - - static void *get_module(const unsigned int id) - { - BOOST_ASSERT(id < (unsigned int)NumModule); - for(unsigned i = 0; ModuleStates[id] < 2; ++i){ - if(interlocked_compare_exchange(&ModuleStates[id], 1, 0) == 0){ - ModuleAddresses[id] = get_module_from_id(id); - interlocked_increment(&ModuleStates[id]); - break; - } - else if(i & 1){ - sched_yield(); - } - else{ - sleep_tick(); - } - } - return ModuleAddresses[id]; - } - - static void *get_address_from_dll(const unsigned int id) - { - BOOST_ASSERT(id < (unsigned int)NumFunction); - void *addr = get_proc_address(get_module(FunctionModules[id]), FunctionNames[id]); - BOOST_ASSERT(addr); - return addr; - } - - public: - static void *get(const unsigned int id) - { - BOOST_ASSERT(id < (unsigned int)NumFunction); - for(unsigned i = 0; FunctionStates[id] < 2; ++i){ - if(interlocked_compare_exchange(&FunctionStates[id], 1, 0) == 0){ - FunctionAddresses[id] = get_address_from_dll(id); - interlocked_increment(&FunctionStates[id]); - break; - } - else if(i & 1){ - sched_yield(); - } - else{ - sleep_tick(); - } - } - return FunctionAddresses[id]; - } -}; - -template -const char *function_address_holder::FunctionNames[function_address_holder::NumFunction] = -{ - "NtSetInformationFile", - "NtQuerySystemInformation", - "NtQueryObject", - "NtQuerySemaphore", - "NtQuerySection", - "NtOpenFile", - "NtClose", - "NtQueryTimerResolution", - "NtSetTimerResolution", - "QueryPerformanceCounter", - "QueryPerformanceFrequency" -}; - -template -unsigned int function_address_holder::FunctionModules[function_address_holder::NumFunction] = -{ - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - NtDll_dll, - Kernel32_dll, - Kernel32_dll -}; - -template -const char *function_address_holder::ModuleNames[function_address_holder::NumModule] = -{ - "ntdll.dll", - "kernel32.dll" -}; - - -template -void *function_address_holder::FunctionAddresses[function_address_holder::NumFunction]; - -template -volatile long function_address_holder::FunctionStates[function_address_holder::NumFunction]; - -template -void *function_address_holder::ModuleAddresses[function_address_holder::NumModule]; - -template -volatile long function_address_holder::ModuleStates[function_address_holder::NumModule]; - - -struct dll_func - : public function_address_holder<0> -{}; - -//Complex winapi based functions... -struct library_unloader -{ - void *lib_; - library_unloader(void *module) : lib_(module){} - ~library_unloader(){ free_library(lib_); } -}; - - -inline bool get_system_time_of_day_information(system_timeofday_information &info) -{ - NtQuerySystemInformation_t pNtQuerySystemInformation = (NtQuerySystemInformation_t) - dll_func::get(dll_func::NtQuerySystemInformation); - unsigned long res; - long status = pNtQuerySystemInformation(system_time_of_day_information, &info, sizeof(info), &res); - if(status){ - return false; - } - return true; -} - -inline bool get_boot_time(unsigned char (&bootstamp) [BootstampLength]) -{ - system_timeofday_information info; - bool ret = get_system_time_of_day_information(info); - if(!ret){ - return false; - } - std::memcpy(&bootstamp[0], &info.Reserved1, sizeof(bootstamp)); - return true; -} - -inline bool get_boot_and_system_time(unsigned char (&bootsystemstamp) [BootAndSystemstampLength]) -{ - system_timeofday_information info; - bool ret = get_system_time_of_day_information(info); - if(!ret){ - return false; - } - std::memcpy(&bootsystemstamp[0], &info.Reserved1, sizeof(bootsystemstamp)); - return true; -} - -inline bool get_boot_time_str(char *bootstamp_str, std::size_t &s) //will write BootstampLength chars -{ - if(s < (BootstampLength*2)) - return false; - system_timeofday_information info; - bool ret = get_system_time_of_day_information(info); - if(!ret){ - return false; - } - const char Characters [] = - { '0', '1', '2', '3', '4', '5', '6', '7' - , '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; - std::size_t char_counter = 0; - for(std::size_t i = 0; i != static_cast(BootstampLength); ++i){ - bootstamp_str[char_counter++] = Characters[(info.Reserved1[i]&0xF0)>>4]; - bootstamp_str[char_counter++] = Characters[(info.Reserved1[i]&0x0F)]; - } - s = BootstampLength*2; - return true; -} - -//Writes the hexadecimal value of the buffer, in the wide character string. -//str must be twice length -inline void buffer_to_wide_str(const void *buf, std::size_t length, wchar_t *str) -{ - const wchar_t Characters [] = - { L'0', L'1', L'2', L'3', L'4', L'5', L'6', L'7' - , L'8', L'9', L'A', L'B', L'C', L'D', L'E', L'F' }; - std::size_t char_counter = 0; - const char *chbuf = static_cast(buf); - for(std::size_t i = 0; i != length; ++i){ - str[char_counter++] = Characters[(chbuf[i]&0xF0)>>4]; - str[char_counter++] = Characters[(chbuf[i]&0x0F)]; - } -} - -inline bool get_boot_and_system_time_wstr(wchar_t *bootsystemstamp, std::size_t &s) //will write BootAndSystemstampLength chars -{ - if(s < (BootAndSystemstampLength*2)) - return false; - system_timeofday_information info; - bool ret = get_system_time_of_day_information(info); - if(!ret){ - return false; - } - - buffer_to_wide_str(&info.Reserved1[0], BootAndSystemstampLength, bootsystemstamp); - s = BootAndSystemstampLength*2; - return true; -} - -class handle_closer -{ - void *handle_; - handle_closer(const handle_closer &); - handle_closer& operator=(const handle_closer &); - public: - explicit handle_closer(void *handle) : handle_(handle){} - ~handle_closer() - { close_handle(handle_); } -}; - -class eventlog_handle_closer -{ - void *handle_; - eventlog_handle_closer(const handle_closer &); - eventlog_handle_closer& operator=(const eventlog_handle_closer &); - public: - explicit eventlog_handle_closer(void *handle) : handle_(handle){} - ~eventlog_handle_closer() - { CloseEventLog(handle_); } -}; - -union ntquery_mem_t -{ - object_name_information_t name; - struct ren_t - { - file_rename_information_t info; - wchar_t buf[1]; - } ren; -}; - -class nt_query_mem_deleter -{ - static const std::size_t rename_offset = offsetof(ntquery_mem_t, ren.info.FileName) - - offsetof(ntquery_mem_t, name.Name.Buffer); - // Timestamp process id atomic count - static const std::size_t rename_suffix = (SystemTimeOfDayInfoLength + sizeof(unsigned long) + sizeof(boost::uint32_t))*2; - - public: - nt_query_mem_deleter(std::size_t object_name_information_size) - : m_size(object_name_information_size + rename_offset + rename_suffix) - , m_buf(new char [m_size]) - {} - - ~nt_query_mem_deleter() - { - delete[]m_buf; - } - - void realloc_mem(std::size_t num_bytes) - { - num_bytes += rename_suffix + rename_offset; - char *buf = m_buf; - m_buf = new char[num_bytes]; - delete[]buf; - m_size = num_bytes; - } - - ntquery_mem_t *query_mem() const - { return static_cast(static_cast(m_buf)); } - - unsigned long object_name_information_size() const - { return static_cast(m_size - rename_offset - SystemTimeOfDayInfoLength*2); } - - std::size_t file_rename_information_size() const - { return static_cast(m_size); } - - private: - std::size_t m_size; - char *m_buf; -}; - -class c_heap_deleter -{ - public: - c_heap_deleter(std::size_t size) - : m_buf(::malloc(size)) - {} - - ~c_heap_deleter() - { - if(m_buf) ::free(m_buf); - } - - void realloc_mem(std::size_t num_bytes) - { - void *buf = ::realloc(m_buf, num_bytes); - if(!buf){ - free(m_buf); - m_buf = 0; - } - } - - void *get() const - { return m_buf; } - - private: - void *m_buf; -}; - -inline bool unlink_file(const char *filename) -{ - //Don't try to optimize doing a DeleteFile first - //as there are interactions with permissions and - //in-use files. - // - //if(!delete_file(filename)){ - // (...) - // - - //This functions tries to emulate UNIX unlink semantics in windows. - // - //- Open the file and mark the handle as delete-on-close - //- Rename the file to an arbitrary name based on a random number - //- Close the handle. If there are no file users, it will be deleted. - // Otherwise it will be used by already connected handles but the - // file name can't be used to open this file again - try{ - NtSetInformationFile_t pNtSetInformationFile = - (NtSetInformationFile_t)dll_func::get(dll_func::NtSetInformationFile); - - NtQueryObject_t pNtQueryObject = (NtQueryObject_t)dll_func::get(dll_func::NtQueryObject); - - //First step: Obtain a handle to the file using Win32 rules. This resolves relative paths - void *fh = create_file(filename, generic_read | delete_access, open_existing, 0, 0); - if(fh == invalid_handle_value){ - return false; - } - - handle_closer h_closer(fh); - { - //Obtain name length - unsigned long size; - const std::size_t initial_string_mem = 512u; - - nt_query_mem_deleter nt_query_mem(sizeof(ntquery_mem_t)+initial_string_mem); - //Obtain file name with guessed length - if(pNtQueryObject(fh, object_name_information, nt_query_mem.query_mem(), nt_query_mem.object_name_information_size(), &size)){ - //Obtain file name with exact length buffer - nt_query_mem.realloc_mem(size); - if(pNtQueryObject(fh, object_name_information, nt_query_mem.query_mem(), nt_query_mem.object_name_information_size(), &size)){ - return false; - } - } - ntquery_mem_t *pmem = nt_query_mem.query_mem(); - file_rename_information_t *pfri = &pmem->ren.info; - const std::size_t RenMaxNumChars = - (((char*)(pmem) + nt_query_mem.file_rename_information_size()) - (char*)&pmem->ren.info.FileName[0])/sizeof(wchar_t); - - //Copy filename to the rename member - std::memmove(pmem->ren.info.FileName, pmem->name.Name.Buffer, pmem->name.Name.Length); - std::size_t filename_string_length = pmem->name.Name.Length/sizeof(wchar_t); - - //Search '\\' character to replace from it - for(std::size_t i = filename_string_length; i != 0; --filename_string_length){ - if(pmem->ren.info.FileName[--i] == L'\\') - break; - } - - //Add random number - std::size_t s = RenMaxNumChars - filename_string_length; - if(!get_boot_and_system_time_wstr(&pfri->FileName[filename_string_length], s)){ - return false; - } - filename_string_length += s; - - //Sometimes the precission of the timestamp is not enough and we need to add another random number. - //The process id (to exclude concurrent processes) and an atomic count (to exclude concurrent threads). - //should be enough - const unsigned long pid = get_current_process_id(); - buffer_to_wide_str(&pid, sizeof(pid), &pfri->FileName[filename_string_length]); - filename_string_length += sizeof(pid)*2; - - static volatile boost::uint32_t u32_count = 0; - interlocked_decrement(reinterpret_cast(&u32_count)); - buffer_to_wide_str(const_cast(&u32_count), sizeof(boost::uint32_t), &pfri->FileName[filename_string_length]); - filename_string_length += sizeof(boost::uint32_t)*2; - - //Fill rename information (FileNameLength is in bytes) - pfri->FileNameLength = static_cast(sizeof(wchar_t)*(filename_string_length)); - pfri->Replace = 1; - pfri->RootDir = 0; - - //Cange the name of the in-use file... - io_status_block_t io; - if(0 != pNtSetInformationFile(fh, &io, pfri, nt_query_mem.file_rename_information_size(), file_rename_information)){ - return false; - } - } - //...and mark it as delete-on-close - { - //Don't use pNtSetInformationFile with file_disposition_information as it can return STATUS_CANNOT_DELETE - //if the file is still mapped. Reopen it with NtOpenFile and file_delete_on_close - NtOpenFile_t pNtOpenFile = (NtOpenFile_t)dll_func::get(dll_func::NtOpenFile); - NtClose_t pNtClose = (NtClose_t)dll_func::get(dll_func::NtClose); - const wchar_t empty_str [] = L""; - unicode_string_t ustring = { sizeof(empty_str) - sizeof (wchar_t) //length in bytes without null - , sizeof(empty_str) //total size in bytes of memory allocated for Buffer. - , const_cast(empty_str) - }; - object_attributes_t object_attr; - initialize_object_attributes(&object_attr, &ustring, 0, fh, 0); - void* fh2 = 0; - io_status_block_t io; - pNtOpenFile( &fh2, delete_flag, &object_attr, &io - , file_share_read | file_share_write | file_share_delete, file_delete_on_close); - pNtClose(fh2); - //Even if NtOpenFile fails, the file was renamed and the original no longer exists, so return a success status - return true; - } - } - catch(...){ - return false; - } - return true; -} - -struct reg_closer -{ - void *key_; - reg_closer(void *key) : key_(key){} - ~reg_closer(){ reg_close_key(key_); } -}; - -inline void get_shared_documents_folder(std::string &s) -{ - s.clear(); - void *key; - if (reg_open_key_ex( hkey_local_machine - , "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Shell Folders" - , 0 - , key_query_value - , &key) == 0){ - reg_closer key_closer(key); - - //Obtain the value - unsigned long size; - unsigned long type; - const char *const reg_value = "Common AppData"; - //long err = (*pRegQueryValue)( key, reg_value, 0, &type, 0, &size); - long err = reg_query_value_ex( key, reg_value, 0, &type, 0, &size); - if(!err){ - //Size includes terminating NULL - s.resize(size); - //err = (*pRegQueryValue)( key, reg_value, 0, &type, (unsigned char*)(&s[0]), &size); - err = reg_query_value_ex( key, reg_value, 0, &type, (unsigned char*)(&s[0]), &size); - if(!err) - s.erase(s.end()-1); - (void)err; - } - } -} - -inline void get_registry_value(const char *folder, const char *value_key, std::vector &s) -{ - s.clear(); - void *key; - if (reg_open_key_ex( hkey_local_machine - , folder - , 0 - , key_query_value - , &key) == 0){ - reg_closer key_closer(key); - - //Obtain the value - unsigned long size; - unsigned long type; - const char *const reg_value = value_key; - //long err = (*pRegQueryValue)( key, reg_value, 0, &type, 0, &size); - long err = reg_query_value_ex( key, reg_value, 0, &type, 0, &size); - if(!err){ - //Size includes terminating NULL - s.resize(size); - //err = (*pRegQueryValue)( key, reg_value, 0, &type, (unsigned char*)(&s[0]), &size); - err = reg_query_value_ex( key, reg_value, 0, &type, (unsigned char*)(&s[0]), &size); - if(!err) - s.erase(s.end()-1); - (void)err; - } - } -} - -struct co_uninitializer -{ - co_uninitializer(bool b_uninitialize) - : m_b_uninitialize(b_uninitialize) - {} - - ~co_uninitializer() - { - if(m_b_uninitialize){ - CoUninitialize(); - } - } - - private: - const bool m_b_uninitialize; -}; - -template -struct com_releaser -{ - Object *&object_; - com_releaser(Object *&object) : object_(object) {} - ~com_releaser() { object_->Release(); object_ = 0; } -}; - -inline bool get_wmi_class_attribute( std::wstring& strValue, const wchar_t *wmi_class, const wchar_t *wmi_class_var) -{ - //See example http://msdn.microsoft.com/en-us/library/aa390423%28v=VS.85%29.aspx - // - //See BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL definition if you need to change the - //default value of this macro in your application - long co_init_ret = CoInitializeEx(0, BOOST_INTERPROCESS_WINDOWS_COINIT_MODEL); - if(co_init_ret != S_OK_BIPC && co_init_ret != S_FALSE_BIPC && co_init_ret != RPC_E_CHANGED_MODE_BIPC) - return false; - co_uninitializer co_initialize_end(co_init_ret != RPC_E_CHANGED_MODE_BIPC); - (void)co_initialize_end; - - bool bRet = false; - long sec_init_ret = CoInitializeSecurity - ( 0 //pVoid - ,-1 //cAuthSvc - , 0 //asAuthSvc - , 0 //pReserved1 - , RPC_C_AUTHN_LEVEL_PKT_BIPC //dwAuthnLevel - , RPC_C_IMP_LEVEL_IMPERSONATE_BIPC //dwImpLevel - , 0 //pAuthList - , EOAC_NONE_BIPC //dwCapabilities - , 0 //pReserved3 - ); - if( 0 == sec_init_ret || RPC_E_TOO_LATE_BIPC == sec_init_ret) - { - IWbemLocator_BIPC * pIWbemLocator = 0; - const wchar_t * bstrNamespace = L"root\\cimv2"; - - if( 0 != CoCreateInstance( - CLSID_WbemAdministrativeLocator, - 0, - CLSCTX_INPROC_SERVER_BIPC | CLSCTX_LOCAL_SERVER_BIPC, - IID_IUnknown, (void **)&pIWbemLocator)){ - return false; - } - - com_releaser IWbemLocator_releaser(pIWbemLocator); - - IWbemServices_BIPC *pWbemServices = 0; - - if( 0 != pIWbemLocator->ConnectServer( - bstrNamespace, // Namespace - 0, // Userid - 0, // PW - 0, // Locale - 0, // flags - 0, // Authority - 0, // Context - &pWbemServices - ) - ){ - return false; - } - - if( S_OK_BIPC != CoSetProxyBlanket( - pWbemServices, - RPC_C_AUTHN_DEFAULT_BIPC, - RPC_C_AUTHZ_DEFAULT_BIPC, - 0, - RPC_C_AUTHN_LEVEL_PKT_BIPC, - RPC_C_IMP_LEVEL_IMPERSONATE_BIPC, - 0, - EOAC_NONE_BIPC - ) - ){ - return false; - } - - com_releaser IWbemServices_releaser(pWbemServices); - - strValue.clear(); - strValue += L"Select "; - strValue += wmi_class_var; - strValue += L" from "; - strValue += wmi_class; - - IEnumWbemClassObject_BIPC * pEnumObject = 0; - - if ( 0 != pWbemServices->ExecQuery( - L"WQL", - strValue.c_str(), - //WBEM_FLAG_RETURN_IMMEDIATELY_BIPC, - WBEM_FLAG_RETURN_WHEN_COMPLETE_BIPC | WBEM_FLAG_FORWARD_ONLY_BIPC, - 0, - &pEnumObject - ) - ){ - return false; - } - - com_releaser IEnumWbemClassObject_releaser(pEnumObject); - - //WBEM_FLAG_FORWARD_ONLY_BIPC incompatible with Reset - //if ( 0 != pEnumObject->Reset() ){ - //return false; - //} - - wchar_variant vwchar; - unsigned long uCount = 1, uReturned; - IWbemClassObject_BIPC * pClassObject = 0; - while( 0 == pEnumObject->Next( WBEM_INFINITE_BIPC, uCount, &pClassObject, &uReturned ) ) - { - com_releaser IWbemClassObject_releaser(pClassObject); - if ( 0 == pClassObject->Get( L"LastBootUpTime", 0, &vwchar, 0, 0 ) ){ - bRet = true; - strValue = vwchar.value.pbstrVal; - VariantClear(&vwchar ); - break; - } - } - } - return bRet; -} - -#ifdef BOOST_INTERPROCESS_BOOTSTAMP_IS_LASTBOOTUPTIME - -//Obtains the bootup time from WMI LastBootUpTime. -//This time seems to change with hibernation and clock synchronization so avoid it. -inline bool get_last_bootup_time( std::wstring& strValue ) -{ - bool ret = get_wmi_class_attribute(strValue, L"Win32_OperatingSystem", L"LastBootUpTime"); - std::size_t timezone = strValue.find(L'+'); - if(timezone != std::wstring::npos){ - strValue.erase(timezone); - } - timezone = strValue.find(L'-'); - if(timezone != std::wstring::npos){ - strValue.erase(timezone); - } - return ret; -} - -inline bool get_last_bootup_time( std::string& str ) -{ - std::wstring wstr; - bool ret = get_last_bootup_time(wstr); - str.resize(wstr.size()); - for(std::size_t i = 0, max = str.size(); i != max; ++i){ - str[i] = '0' + (wstr[i]-L'0'); - } - return ret; -} - -#else - -// Loop through the buffer and obtain the contents of the -// requested record in the buffer. -inline bool find_record_in_buffer( const void* pBuffer, unsigned long dwBytesRead, const char *provider_name - , unsigned int id_to_find, interprocess_eventlogrecord *&pevent_log_record) -{ - const unsigned char * pRecord = static_cast(pBuffer); - const unsigned char * pEndOfRecords = pRecord + dwBytesRead; - - while (pRecord < pEndOfRecords){ - interprocess_eventlogrecord *pTypedRecord = (interprocess_eventlogrecord*)pRecord; - // Check provider, written at the end of the fixed-part of the record - if (0 == std::strcmp(provider_name, (char*)(pRecord + sizeof(interprocess_eventlogrecord)))) - { - // Check event id - if(id_to_find == (pTypedRecord->EventID & 0xFFFF)){ - pevent_log_record = pTypedRecord; - return true; - } - } - - pRecord += pTypedRecord->Length; - } - pevent_log_record = 0; - return false; -} - -//Obtains the bootup time from the System Event Log, -//event ID == 6005 (event log started). -//Adapted from http://msdn.microsoft.com/en-us/library/windows/desktop/bb427356.aspx -inline bool get_last_bootup_time(std::string &stamp) -{ - const char *source_name = "System"; - const char *provider_name = "EventLog"; - const unsigned short event_id = 6005u; - - unsigned long status = 0; - unsigned long dwBytesToRead = 0; - unsigned long dwBytesRead = 0; - unsigned long dwMinimumBytesToRead = 0; - - // The source name (provider) must exist as a subkey of Application. - void *hEventLog = OpenEventLogA(0, source_name); - if (hEventLog){ - eventlog_handle_closer hnd_closer(hEventLog); (void)hnd_closer; - // Allocate an initial block of memory used to read event records. The number - // of records read into the buffer will vary depending on the size of each event. - // The size of each event will vary based on the size of the user-defined - // data included with each event, the number and length of insertion - // strings, and other data appended to the end of the event record. - dwBytesToRead = max_record_buffer_size; - c_heap_deleter heap_deleter(dwBytesToRead); - - // Read blocks of records until you reach the end of the log or an - // error occurs. The records are read from newest to oldest. If the buffer - // is not big enough to hold a complete event record, reallocate the buffer. - if (heap_deleter.get() != 0){ - while (0 == status){ - if (!ReadEventLogA(hEventLog, - eventlog_sequential_read | eventlog_backwards_read, - 0, - heap_deleter.get(), - dwBytesToRead, - &dwBytesRead, - &dwMinimumBytesToRead)) { - status = get_last_error(); - if (error_insufficient_buffer == status) { - status = 0; - dwBytesToRead = dwMinimumBytesToRead; - heap_deleter.realloc_mem(dwMinimumBytesToRead); - if (!heap_deleter.get()){ - return false; - } - } - else{ //Not found or EOF - return false; - } - } - else - { - interprocess_eventlogrecord *pTypedRecord; - // Print the contents of each record in the buffer. - if(find_record_in_buffer(heap_deleter.get(), dwBytesRead, provider_name, event_id, pTypedRecord)){ - char stamp_str[sizeof(unsigned long)*3+1]; - std::sprintf(&stamp_str[0], "%u", ((unsigned int)pTypedRecord->TimeGenerated)); - stamp = stamp_str; - break; - } - } - } - } - } - return true; -} - -#endif - -inline bool is_directory(const char *path) -{ - unsigned long attrib = GetFileAttributesA(path); - - return (attrib != invalid_file_attributes && - (attrib & file_attribute_directory)); -} - -inline bool get_file_mapping_size(void *file_mapping_hnd, __int64 &size) -{ - NtQuerySection_t pNtQuerySection = - (NtQuerySection_t)dll_func::get(dll_func::NtQuerySection); - //Obtain file name - interprocess_section_basic_information info; - unsigned long ntstatus = - pNtQuerySection(file_mapping_hnd, section_basic_information, &info, sizeof(info), 0); - size = info.section_size; - return !ntstatus; -} - -inline bool get_semaphore_info(void *handle, long &count, long &limit) -{ - winapi::interprocess_semaphore_basic_information info; - winapi::NtQuerySemaphore_t pNtQuerySemaphore = - (winapi::NtQuerySemaphore_t)dll_func::get(winapi::dll_func::NtQuerySemaphore); - unsigned int ret_len; - long status = pNtQuerySemaphore(handle, winapi::semaphore_basic_information, &info, sizeof(info), &ret_len); - count = info.count; - limit = info.limit; - return !status; -} - -inline bool query_timer_resolution(unsigned long *lowres, unsigned long *highres, unsigned long *curres) -{ - winapi::NtQueryTimerResolution_t pNtQueryTimerResolution = - (winapi::NtQueryTimerResolution_t)dll_func::get(winapi::dll_func::NtQueryTimerResolution); - return !pNtQueryTimerResolution(lowres, highres, curres); -} - -inline bool set_timer_resolution(unsigned long RequestedResolution, int Set, unsigned long* ActualResolution) -{ - winapi::NtSetTimerResolution_t pNtSetTimerResolution = - (winapi::NtSetTimerResolution_t)dll_func::get(winapi::dll_func::NtSetTimerResolution); - return !pNtSetTimerResolution(RequestedResolution, Set, ActualResolution); -} - -inline bool query_performance_counter(__int64 *lpPerformanceCount) -{ - QueryPerformanceCounter_t pQueryPerformanceCounter = (QueryPerformanceCounter_t) - dll_func::get(dll_func::QueryPerformanceCounter); - return 0 != pQueryPerformanceCounter(lpPerformanceCount); -} - -inline bool query_performance_frequency(__int64 *lpFrequency) -{ - QueryPerformanceCounter_t pQueryPerformanceFrequency = (QueryPerformanceFrequency_t) - dll_func::get(dll_func::QueryPerformanceFrequency); - return 0 != pQueryPerformanceFrequency(lpFrequency); -} - -inline unsigned long get_tick_count() -{ return GetTickCount(); } - -} //namespace winapi -} //namespace interprocess -} //namespace boost - -#include - -#endif //#ifdef BOOST_INTERPROCESS_WIN32_PRIMITIVES_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/windows_intermodule_singleton.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/windows_intermodule_singleton.hpp deleted file mode 100644 index 946f6a7b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/windows_intermodule_singleton.hpp +++ /dev/null @@ -1,309 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2009-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_WINDOWS_INTERMODULE_SINGLETON_HPP -#define BOOST_INTERPROCESS_WINDOWS_INTERMODULE_SINGLETON_HPP - -#if defined(_MSC_VER)&&(_MSC_VER>=1200) -#pragma once -#endif - -#include -#include - -#if !defined(BOOST_INTERPROCESS_WINDOWS) - #error "This header can't be included from non-windows operating systems" -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost{ -namespace interprocess{ -namespace ipcdetail{ - -namespace intermodule_singleton_helpers { - -//This global map will be implemented using 3 sync primitives: -// -//1) A named mutex that will implement global mutual exclusion between -// threads from different modules/dlls -// -//2) A semaphore that will act as a global counter for modules attached to the global map -// so that the global map can be destroyed when the last module is detached. -// -//3) A semaphore that will be hacked to hold the address of a heap-allocated map in the -// max and current semaphore count. -class windows_semaphore_based_map -{ - typedef std::map map_type; - - public: - windows_semaphore_based_map() - { - map_type *m = new map_type; - boost::uint32_t initial_count = 0; - boost::uint32_t max_count = 0; - - //Windows user address space sizes: - //32 bit windows: [32 bit processes] 2GB or 3GB (31/32 bits) - //64 bit windows: [32 bit processes] 2GB or 4GB (31/32 bits) - // [64 bit processes] 2GB or 8TB (31/43 bits) - // - //Windows semaphores use 'long' parameters (32 bits in LLP64 data model) and - //those values can't be negative, so we have 31 bits to store something - //in max_count and initial count parameters. - //Also, max count must be bigger than 0 and bigger or equal than initial count. - if(sizeof(void*) == sizeof(boost::uint32_t)){ - //This means that for 32 bit processes, a semaphore count (31 usable bits) is - //enough to store 4 byte aligned memory (4GB -> 32 bits - 2 bits = 30 bits). - //The max count will hold the pointer value and current semaphore count - //will be zero. - // - //Relying in UB with a cast through union, but all known windows compilers - //accept this (C11 also accepts this). - union caster_union - { - void *addr; - boost::uint32_t addr_uint32; - } caster; - caster.addr = m; - //memory is at least 4 byte aligned in windows - BOOST_ASSERT((caster.addr_uint32 & boost::uint32_t(3)) == 0); - max_count = caster.addr_uint32 >> 2; - } - else if(sizeof(void*) == sizeof(boost::uint64_t)){ - //Relying in UB with a cast through union, but all known windows compilers - //accept this (C11 accepts this). - union caster_union - { - void *addr; - boost::uint64_t addr_uint64; - } caster; - caster.addr = m; - //We'll encode the address using 30 bits in each 32 bit high and low parts. - //High part will be the sem max count, low part will be the sem initial count. - //(restrictions: max count > 0, initial count >= 0 and max count >= initial count): - // - // - Low part will be shifted two times (4 byte alignment) so that top - // two bits are cleared (the top one for sign, the next one to - // assure low part value is always less than the high part value. - // - The top bit of the high part will be cleared and the next bit will be 1 - // (so high part is always bigger than low part due to the quasi-top bit). - // - // This means that the addresses we can store must be 4 byte aligned - // and less than 1 ExbiBytes ( 2^60 bytes, ~1 ExaByte). User-level address space in Windows 64 - // is much less than this (8TB, 2^43 bytes): "1 EByte (or it was 640K?) ought to be enough for anybody" ;-). - caster.addr = m; - BOOST_ASSERT((caster.addr_uint64 & boost::uint64_t(3)) == 0); - max_count = boost::uint32_t(caster.addr_uint64 >> 32); - initial_count = boost::uint32_t(caster.addr_uint64); - initial_count = initial_count/4; - //Make sure top two bits are zero - BOOST_ASSERT((max_count & boost::uint32_t(0xC0000000)) == 0); - //Set quasi-top bit - max_count |= boost::uint32_t(0x40000000); - } - bool created = false; - const permissions & perm = permissions(); - std::string pid_creation_time, name; - get_pid_creation_time_str(pid_creation_time); - name = "bipc_gmap_sem_lock_"; - name += pid_creation_time; - bool success = m_mtx_lock.open_or_create(name.c_str(), perm); - name = "bipc_gmap_sem_count_"; - name += pid_creation_time; - scoped_lock lck(m_mtx_lock); - { - success = success && m_sem_count.open_or_create - ( name.c_str(), static_cast(0), winapi_semaphore_wrapper::MaxCount, perm, created); - name = "bipc_gmap_sem_map_"; - name += pid_creation_time; - success = success && m_sem_map.open_or_create - (name.c_str(), initial_count, max_count, perm, created); - if(!success){ - delete m; - //winapi_xxx wrappers do the cleanup... - throw int(0); - } - if(!created){ - delete m; - } - else{ - BOOST_ASSERT(&get_map_unlocked() == m); - } - m_sem_count.post(); - } - } - - map_type &get_map_unlocked() - { - if(sizeof(void*) == sizeof(boost::uint32_t)){ - union caster_union - { - void *addr; - boost::uint32_t addr_uint32; - } caster; - caster.addr = 0; - caster.addr_uint32 = m_sem_map.limit(); - caster.addr_uint32 = caster.addr_uint32 << 2; - return *static_cast(caster.addr); - } - else{ - union caster_union - { - void *addr; - boost::uint64_t addr_uint64; - } caster; - boost::uint32_t max_count(m_sem_map.limit()), initial_count(m_sem_map.value()); - //Clear quasi-top bit - max_count &= boost::uint32_t(0xBFFFFFFF); - caster.addr_uint64 = max_count; - caster.addr_uint64 = caster.addr_uint64 << 32; - caster.addr_uint64 |= boost::uint64_t(initial_count) << 2; - return *static_cast(caster.addr); - } - } - - ref_count_ptr *find(const char *name) - { - scoped_lock lck(m_mtx_lock); - map_type &map = this->get_map_unlocked(); - map_type::iterator it = map.find(std::string(name)); - if(it != map.end()){ - return &it->second; - } - else{ - return 0; - } - } - - ref_count_ptr * insert(const char *name, const ref_count_ptr &ref) - { - scoped_lock lck(m_mtx_lock); - map_type &map = this->get_map_unlocked(); - map_type::iterator it = map.insert(map_type::value_type(std::string(name), ref)).first; - return &it->second; - } - - bool erase(const char *name) - { - scoped_lock lck(m_mtx_lock); - map_type &map = this->get_map_unlocked(); - return map.erase(std::string(name)) != 0; - } - - template - void atomic_func(F &f) - { - scoped_lock lck(m_mtx_lock); - f(); - } - - ~windows_semaphore_based_map() - { - scoped_lock lck(m_mtx_lock); - m_sem_count.wait(); - if(0 == m_sem_count.value()){ - map_type &map = this->get_map_unlocked(); - BOOST_ASSERT(map.empty()); - delete ↦ - } - //First close sems to protect this with the external mutex - m_sem_map.close(); - m_sem_count.close(); - //Once scoped_lock unlocks the mutex, the destructor will close the handle... - } - - private: - winapi_mutex_wrapper m_mtx_lock; - winapi_semaphore_wrapper m_sem_map; - winapi_semaphore_wrapper m_sem_count; -}; - -template<> -struct thread_safe_global_map_dependant -{ - static void apply_gmem_erase_logic(const char *, const char *){} - - static bool remove_old_gmem() - { return true; } - - struct lock_file_logic - { - lock_file_logic(windows_semaphore_based_map &) - : retry_with_new_map(false) - {} - - void operator()(void){} - bool retry() const { return retry_with_new_map; } - private: - const bool retry_with_new_map; - }; - - static void construct_map(void *addr) - { - ::new (addr)windows_semaphore_based_map; - } - - struct unlink_map_logic - { - unlink_map_logic(windows_semaphore_based_map &) - {} - void operator()(){} - }; - - static ref_count_ptr *find(windows_semaphore_based_map &map, const char *name) - { - return map.find(name); - } - - static ref_count_ptr * insert(windows_semaphore_based_map &map, const char *name, const ref_count_ptr &ref) - { - return map.insert(name, ref); - } - - static bool erase(windows_semaphore_based_map &map, const char *name) - { - return map.erase(name); - } - - template - static void atomic_func(windows_semaphore_based_map &map, F &f) - { - map.atomic_func(f); - } -}; - -} //namespace intermodule_singleton_helpers { - -template -class windows_intermodule_singleton - : public intermodule_singleton_impl - < C - , LazyInit - , Phoenix - , intermodule_singleton_helpers::windows_semaphore_based_map - > -{}; - -} //namespace ipcdetail{ -} //namespace interprocess{ -} //namespace boost{ - -#include - -#endif //#ifndef BOOST_INTERPROCESS_WINDOWS_INTERMODULE_SINGLETON_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/workaround.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/workaround.hpp deleted file mode 100644 index 6ce2ea1c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/detail/workaround.hpp +++ /dev/null @@ -1,194 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_WORKAROUND_HPP -#define BOOST_INTERPROCESS_DETAIL_WORKAROUND_HPP - -#include - -#if defined(_WIN32) || defined(__WIN32__) || defined(WIN32) - #define BOOST_INTERPROCESS_WINDOWS - #define BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION - #define BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME - //Define this to connect with shared memory created with versions < 1.54 - //#define BOOST_INTERPROCESS_BOOTSTAMP_IS_LASTBOOTUPTIME -#else - #include - - #if defined(_POSIX_THREAD_PROCESS_SHARED) && ((_POSIX_THREAD_PROCESS_SHARED - 0) > 0) - //Cygwin defines _POSIX_THREAD_PROCESS_SHARED but does not implement it. - #if defined(__CYGWIN__) - #define BOOST_INTERPROCESS_BUGGY_POSIX_PROCESS_SHARED - //Mac Os X < Lion (10.7) might define _POSIX_THREAD_PROCESS_SHARED but there is no real support. - #elif defined(__APPLE__) - #include "TargetConditionals.h" - //Check we're on Mac OS target - #if defined(TARGET_OS_MAC) - #include "AvailabilityMacros.h" - //If minimum target for this compilation is older than Mac Os Lion, then we are out of luck - #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 - #define BOOST_INTERPROCESS_BUGGY_POSIX_PROCESS_SHARED - #endif - #endif - #endif - - //If buggy _POSIX_THREAD_PROCESS_SHARED is detected avoid using it - #if defined(BOOST_INTERPROCESS_BUGGY_POSIX_PROCESS_SHARED) - #undef BOOST_INTERPROCESS_BUGGY_POSIX_PROCESS_SHARED - #else - #define BOOST_INTERPROCESS_POSIX_PROCESS_SHARED - #endif - #endif - - #if defined(_POSIX_BARRIERS) && ((_POSIX_BARRIERS - 0) > 0) - #define BOOST_INTERPROCESS_POSIX_BARRIERS - #endif - - #if defined(_POSIX_SEMAPHORES) && ((_POSIX_SEMAPHORES - 0) > 0) - #define BOOST_INTERPROCESS_POSIX_NAMED_SEMAPHORES - #if defined(__CYGWIN__) - #define BOOST_INTERPROCESS_POSIX_SEMAPHORES_NO_UNLINK - #endif - //Some platforms have a limited (name length) named semaphore support - #elif (defined(__FreeBSD__) && (__FreeBSD__ >= 4)) || defined(__APPLE__) - #define BOOST_INTERPROCESS_POSIX_NAMED_SEMAPHORES - #endif - - #if ((defined _V6_ILP32_OFFBIG) &&(_V6_ILP32_OFFBIG - 0 > 0)) ||\ - ((defined _V6_LP64_OFF64) &&(_V6_LP64_OFF64 - 0 > 0)) ||\ - ((defined _V6_LPBIG_OFFBIG) &&(_V6_LPBIG_OFFBIG - 0 > 0)) ||\ - ((defined _XBS5_ILP32_OFFBIG)&&(_XBS5_ILP32_OFFBIG - 0 > 0)) ||\ - ((defined _XBS5_LP64_OFF64) &&(_XBS5_LP64_OFF64 - 0 > 0)) ||\ - ((defined _XBS5_LPBIG_OFFBIG)&&(_XBS5_LPBIG_OFFBIG - 0 > 0)) ||\ - ((defined _FILE_OFFSET_BITS) &&(_FILE_OFFSET_BITS - 0 >= 64))||\ - ((defined _FILE_OFFSET_BITS) &&(_FILE_OFFSET_BITS - 0 >= 64)) - #define BOOST_INTERPROCESS_UNIX_64_BIT_OR_BIGGER_OFF_T - #endif - - //Check for XSI shared memory objects. They are available in nearly all UNIX platforms - #if !defined(__QNXNTO__) - #define BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - #endif - - #if defined(_POSIX_SHARED_MEMORY_OBJECTS) && ((_POSIX_SHARED_MEMORY_OBJECTS - 0) > 0) - #define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS - #else - //VMS and MACOS don't define it but they have shm_open/close interface - #if defined(__vms) - #if __CRTL_VER >= 70200000 - #define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS - #endif - //Mac OS has some non-conformant features like names limited to SHM_NAME_MAX - #elif defined (__APPLE__) - //#define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS - //#define BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS_NO_GROW - #endif - #endif - - //Now check if we have only XSI shared memory - #if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) &&\ - !defined(BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS) - //#define BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS_ONLY - #endif - - #if defined(_POSIX_TIMEOUTS) && ((_POSIX_TIMEOUTS - 0) > 0) - #define BOOST_INTERPROCESS_POSIX_TIMEOUTS - #endif - - #ifdef BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS - //Some systems have filesystem-based resources, so the - //portable "/shmname" format does not work due to permission issues - //For those systems we need to form a path to a temporary directory: - // hp-ux tru64 vms freebsd - #if defined(__hpux) || defined(__osf__) || defined(__vms) || (defined(__FreeBSD__) && (__FreeBSD__ < 7)) - #define BOOST_INTERPROCESS_FILESYSTEM_BASED_POSIX_SHARED_MEMORY - //Some systems have "jailed" environments where shm usage is restricted at runtime - //and temporary file file based shm is possible in those executions. - #elif defined(__FreeBSD__) - #define BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY - #endif - #endif - - #ifdef BOOST_INTERPROCESS_POSIX_NAMED_SEMAPHORES - #if defined(__osf__) || defined(__vms) - #define BOOST_INTERPROCESS_FILESYSTEM_BASED_POSIX_SEMAPHORES - #endif - #endif - - #if defined(_POSIX_VERSION) && defined(_XOPEN_VERSION) && \ - (((_POSIX_VERSION + 0)>= 200112L || (_XOPEN_VERSION + 0)>= 500)) - #define BOOST_INTERPROCESS_POSIX_RECURSIVE_MUTEXES - #endif - - #if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) - #define BOOST_INTERPROCESS_BSD_DERIVATIVE - //Some *BSD systems (OpenBSD & NetBSD) need sys/param.h before sys/sysctl.h, whereas - //others (FreeBSD & Darwin) need sys/types.h - #include - #include - #include - #if defined(CTL_KERN) && defined (KERN_BOOTTIME) - //#define BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME - #endif - #endif -#endif //!defined(BOOST_INTERPROCESS_WINDOWS) - -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - #define BOOST_INTERPROCESS_PERFECT_FORWARDING -#endif - -//Now declare some Boost.Interprocess features depending on the implementation -#if defined(BOOST_INTERPROCESS_POSIX_NAMED_SEMAPHORES) && !defined(BOOST_INTERPROCESS_POSIX_SEMAPHORES_NO_UNLINK) - #define BOOST_INTERPROCESS_NAMED_MUTEX_USES_POSIX_SEMAPHORES - #define BOOST_INTERPROCESS_NAMED_SEMAPHORE_USES_POSIX_SEMAPHORES -#endif - -// Timeout duration use if BOOST_INTERPROCESS_ENABLE_TIMEOUT_WHEN_LOCKING is set -#ifndef BOOST_INTERPROCESS_TIMEOUT_WHEN_LOCKING_DURATION_MS - #define BOOST_INTERPROCESS_TIMEOUT_WHEN_LOCKING_DURATION_MS 10000 -#endif - -//Other switches -//BOOST_INTERPROCESS_MSG_QUEUE_USES_CIRC_INDEX -//message queue uses a circular queue as index instead of an array (better performance) -//Boost version < 1.52 uses an array, so undef this if you want to communicate -//with processes compiled with those versions. -#define BOOST_INTERPROCESS_MSG_QUEUE_CIRCULAR_INDEX - -//Inline attributes -#if defined(_MSC_VER) - #define BOOST_INTERPROCESS_ALWAYS_INLINE __forceinline -#elif defined (__GNUC__) - #define BOOST_INTERPROCESS_ALWAYS_INLINE __attribute__((__always_inline__)) -#else - #define BOOST_INTERPROCESS_ALWAYS_INLINE inline -#endif - -#if defined(_MSC_VER) - #define BOOST_INTERPROCESS_NEVER_INLINE __declspec(noinline) -#elif defined (__GNUC__) - #define BOOST_INTERPROCESS_NEVER_INLINE __attribute__((__noinline__)) -#endif - -#if defined(BOOST_NO_CXX11_NOEXCEPT) - #if defined(BOOST_MSVC) - #define BOOST_INTERPROCESS_NOEXCEPT throw() - #else - #define BOOST_INTERPROCESS_NOEXCEPT - #endif - #define BOOST_INTERPROCESS_NOEXCEPT_IF(x) -#else - #define BOOST_INTERPROCESS_NOEXCEPT noexcept - #define BOOST_INTERPROCESS_NOEXCEPT_IF(x) noexcept(x) -#endif - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_WORKAROUND_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/errors.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/errors.hpp deleted file mode 100644 index 3a3bb533..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/errors.hpp +++ /dev/null @@ -1,236 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -// Parts of this code are taken from boost::filesystem library -// -////////////////////////////////////////////////////////////////////////////// -// -// Copyright (C) 2002 Beman Dawes -// Copyright (C) 2001 Dietmar Kuehl -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy -// at http://www.boost.org/LICENSE_1_0.txt) -// -// See library home page at http://www.boost.org/libs/filesystem -// -////////////////////////////////////////////////////////////////////////////// - - -#ifndef BOOST_INTERPROCESS_ERRORS_HPP -#define BOOST_INTERPROCESS_ERRORS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include - -#if (defined BOOST_INTERPROCESS_WINDOWS) -# include -#else -# ifdef BOOST_HAS_UNISTD_H -# include //Errors -# include //strerror -# else //ifdef BOOST_HAS_UNISTD_H -# error Unknown platform -# endif //ifdef BOOST_HAS_UNISTD_H -#endif //#if (defined BOOST_INTERPROCESS_WINDOWS) - -//!\file -//!Describes the error numbering of interprocess classes - -namespace boost { -namespace interprocess { -/// @cond -inline int system_error_code() // artifact of POSIX and WINDOWS error reporting -{ - #if (defined BOOST_INTERPROCESS_WINDOWS) - return winapi::get_last_error(); - #else - return errno; // GCC 3.1 won't accept ::errno - #endif -} - - -#if (defined BOOST_INTERPROCESS_WINDOWS) -inline void fill_system_message(int sys_err_code, std::string &str) -{ - void *lpMsgBuf; - winapi::format_message( - winapi::format_message_allocate_buffer | - winapi::format_message_from_system | - winapi::format_message_ignore_inserts, - 0, - sys_err_code, - winapi::make_lang_id(winapi::lang_neutral, winapi::sublang_default), // Default language - reinterpret_cast(&lpMsgBuf), - 0, - 0 - ); - str += static_cast(lpMsgBuf); - winapi::local_free( lpMsgBuf ); // free the buffer - while ( str.size() - && (str[str.size()-1] == '\n' || str[str.size()-1] == '\r') ) - str.erase( str.size()-1 ); -} -# else -inline void fill_system_message( int system_error, std::string &str) -{ str = std::strerror(system_error); } -# endif -/// @endcond - -enum error_code_t -{ - no_error = 0, - system_error, // system generated error; if possible, is translated - // to one of the more specific errors below. - other_error, // library generated error - security_error, // includes access rights, permissions failures - read_only_error, - io_error, - path_error, - not_found_error, -// not_directory_error, - busy_error, // implies trying again might succeed - already_exists_error, - not_empty_error, - is_directory_error, - out_of_space_error, - out_of_memory_error, - out_of_resource_error, - lock_error, - sem_error, - mode_error, - size_error, - corrupted_error, - not_such_file_or_directory, - invalid_argument, - timeout_when_locking_error, - timeout_when_waiting_error -}; - -typedef int native_error_t; - -/// @cond -struct ec_xlate -{ - native_error_t sys_ec; - error_code_t ec; -}; - -static const ec_xlate ec_table[] = -{ - #if (defined BOOST_INTERPROCESS_WINDOWS) - { /*ERROR_ACCESS_DENIED*/5L, security_error }, - { /*ERROR_INVALID_ACCESS*/12L, security_error }, - { /*ERROR_SHARING_VIOLATION*/32L, security_error }, - { /*ERROR_LOCK_VIOLATION*/33L, security_error }, - { /*ERROR_LOCKED*/212L, security_error }, - { /*ERROR_NOACCESS*/998L, security_error }, - { /*ERROR_WRITE_PROTECT*/19L, read_only_error }, - { /*ERROR_NOT_READY*/21L, io_error }, - { /*ERROR_SEEK*/25L, io_error }, - { /*ERROR_READ_FAULT*/30L, io_error }, - { /*ERROR_WRITE_FAULT*/29L, io_error }, - { /*ERROR_CANTOPEN*/1011L, io_error }, - { /*ERROR_CANTREAD*/1012L, io_error }, - { /*ERROR_CANTWRITE*/1013L, io_error }, - { /*ERROR_DIRECTORY*/267L, path_error }, - { /*ERROR_INVALID_NAME*/123L, path_error }, - { /*ERROR_FILE_NOT_FOUND*/2L, not_found_error }, - { /*ERROR_PATH_NOT_FOUND*/3L, not_found_error }, - { /*ERROR_DEV_NOT_EXIST*/55L, not_found_error }, - { /*ERROR_DEVICE_IN_USE*/2404L, busy_error }, - { /*ERROR_OPEN_FILES*/2401L, busy_error }, - { /*ERROR_BUSY_DRIVE*/142L, busy_error }, - { /*ERROR_BUSY*/170L, busy_error }, - { /*ERROR_FILE_EXISTS*/80L, already_exists_error }, - { /*ERROR_ALREADY_EXISTS*/183L, already_exists_error }, - { /*ERROR_DIR_NOT_EMPTY*/145L, not_empty_error }, - { /*ERROR_HANDLE_DISK_FULL*/39L, out_of_space_error }, - { /*ERROR_DISK_FULL*/112L, out_of_space_error }, - { /*ERROR_OUTOFMEMORY*/14L, out_of_memory_error }, - { /*ERROR_NOT_ENOUGH_MEMORY*/8L, out_of_memory_error }, - { /*ERROR_TOO_MANY_OPEN_FILES*/4L, out_of_resource_error }, - { /*ERROR_INVALID_ADDRESS*/487L, busy_error } - #else //#if (defined BOOST_INTERPROCESS_WINDOWS) - { EACCES, security_error }, - { EROFS, read_only_error }, - { EIO, io_error }, - { ENAMETOOLONG, path_error }, - { ENOENT, not_found_error }, - // { ENOTDIR, not_directory_error }, - { EAGAIN, busy_error }, - { EBUSY, busy_error }, - { ETXTBSY, busy_error }, - { EEXIST, already_exists_error }, - { ENOTEMPTY, not_empty_error }, - { EISDIR, is_directory_error }, - { ENOSPC, out_of_space_error }, - { ENOMEM, out_of_memory_error }, - { EMFILE, out_of_resource_error }, - { ENOENT, not_such_file_or_directory }, - { EINVAL, invalid_argument } - #endif //#if (defined BOOST_INTERPROCESS_WINDOWS) -}; - -inline error_code_t lookup_error(native_error_t err) -{ - const ec_xlate *cur = &ec_table[0], - *end = cur + sizeof(ec_table)/sizeof(ec_xlate); - for (;cur != end; ++cur ){ - if ( err == cur->sys_ec ) return cur->ec; - } - return system_error; // general system error code -} - -struct error_info -{ - error_info(error_code_t ec = other_error ) - : m_nat(0), m_ec(ec) - {} - - error_info(native_error_t sys_err_code) - : m_nat(sys_err_code), m_ec(lookup_error(sys_err_code)) - {} - - error_info & operator =(error_code_t ec) - { - m_nat = 0; - m_ec = ec; - return *this; - } - - error_info & operator =(native_error_t sys_err_code) - { - m_nat = sys_err_code; - m_ec = lookup_error(sys_err_code); - return *this; - } - - native_error_t get_native_error()const - { return m_nat; } - - error_code_t get_error_code()const - { return m_ec; } - - private: - native_error_t m_nat; - error_code_t m_ec; -}; -/// @endcond - -} // namespace interprocess { -} // namespace boost - -#include - -#endif // BOOST_INTERPROCESS_ERRORS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/exceptions.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/exceptions.hpp deleted file mode 100644 index b9ab45be..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/exceptions.hpp +++ /dev/null @@ -1,150 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_EXCEPTIONS_HPP -#define BOOST_INTERPROCESS_EXCEPTIONS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include - -//!\file -//!Describes exceptions thrown by interprocess classes - -namespace boost { - -namespace interprocess { - -//!This class is the base class of all exceptions -//!thrown by boost::interprocess -class interprocess_exception : public std::exception -{ - public: - interprocess_exception(const char *err/*error_code_t ec = other_error*/) - : m_err(other_error) - { -// try { m_str = "boost::interprocess_exception::library_error"; } - try { m_str = err; } - catch (...) {} - } -/* - interprocess_exception(native_error_t sys_err_code) - : m_err(sys_err_code) - { - try { fill_system_message(m_err.get_native_error(), m_str); } - catch (...) {} - }*/ - - interprocess_exception(const error_info &err_info, const char *str = 0) - : m_err(err_info) - { - try{ - if(m_err.get_native_error() != 0){ - fill_system_message(m_err.get_native_error(), m_str); - } - else if(str){ - m_str = str; - } - else{ - m_str = "boost::interprocess_exception::library_error"; - } - } - catch(...){} - } - - virtual ~interprocess_exception() throw(){} - - virtual const char * what() const throw() - { return m_str.c_str(); } - - native_error_t get_native_error()const { return m_err.get_native_error(); } - - // Note: a value of other_error implies a library (rather than system) error - error_code_t get_error_code() const { return m_err.get_error_code(); } - - /// @cond - private: - error_info m_err; - std::string m_str; - /// @endcond -}; - -//!This is the exception thrown by shared interprocess_mutex family when a deadlock situation -//!is detected or when using a interprocess_condition the interprocess_mutex is not locked -class lock_exception : public interprocess_exception -{ - public: - lock_exception() - : interprocess_exception(lock_error) - {} - - virtual const char* what() const throw() - { return "boost::interprocess::lock_exception"; } -}; - -//!This is the exception thrown by named interprocess_semaphore when a deadlock situation -//!is detected or when an error is detected in the post/wait operation -/* -class sem_exception : public interprocess_exception -{ - public: - sem_exception() - : interprocess_exception(lock_error) - {} - - virtual const char* what() const throw() - { return "boost::interprocess::sem_exception"; } -}; -*/ -//!This is the exception thrown by synchronization objects when there is -//!an error in a wait() function -/* -class wait_exception : public interprocess_exception -{ - public: - virtual const char* what() const throw() - { return "boost::interprocess::wait_exception"; } -}; -*/ - -//!This exception is thrown when a named object is created -//!in "open_only" mode and the resource was not already created -/* -class not_previously_created : public interprocess_exception -{ - public: - virtual const char* what() const throw() - { return "boost::interprocess::not_previously_created"; } -}; -*/ - -//!This exception is thrown when a memory request can't be -//!fulfilled. -class bad_alloc : public interprocess_exception -{ - public: - bad_alloc() : interprocess_exception("::boost::interprocess::bad_alloc"){} - virtual const char* what() const throw() - { return "boost::interprocess::bad_alloc"; } -}; - -} // namespace interprocess { - -} // namespace boost - -#include - -#endif // BOOST_INTERPROCESS_EXCEPTIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/indexes/iset_index.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/indexes/iset_index.hpp deleted file mode 100644 index b1abeded..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/indexes/iset_index.hpp +++ /dev/null @@ -1,150 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_ISET_INDEX_HPP -#define BOOST_INTERPROCESS_ISET_INDEX_HPP - -#include -#include - -#include -#include -#include -#include -#include - - -//!\file -//!Describes index adaptor of boost::intrusive::set container, to use it -//!as name/shared memory index - -namespace boost { -namespace interprocess { - -/// @cond - -//!Helper class to define typedefs from IndexTraits -template -struct iset_index_aux -{ - typedef typename - MapConfig::segment_manager_base segment_manager_base; - - typedef typename - segment_manager_base::void_pointer void_pointer; - typedef typename bi::make_set_base_hook - < bi::void_pointer - , bi::optimize_size - >::type derivation_hook; - - typedef typename MapConfig::template - intrusive_value_type::type value_type; - typedef std::less value_compare; - typedef typename bi::make_set - < value_type - , bi::base_hook - >::type index_t; -}; -/// @endcond - -//!Index type based in boost::intrusive::set. -//!Just derives from boost::intrusive::set -//!and defines the interface needed by managed memory segments*/ -template -class iset_index - //Derive class from map specialization - : public iset_index_aux::index_t -{ - /// @cond - typedef iset_index_aux index_aux; - typedef typename index_aux::index_t index_type; - typedef typename MapConfig:: - intrusive_compare_key_type intrusive_compare_key_type; - typedef typename MapConfig::char_type char_type; - /// @endcond - - public: - typedef typename index_type::iterator iterator; - typedef typename index_type::const_iterator const_iterator; - typedef typename index_type::insert_commit_data insert_commit_data; - typedef typename index_type::value_type value_type; - - /// @cond - private: - - struct intrusive_key_value_less - { - bool operator()(const intrusive_compare_key_type &i, const value_type &b) const - { - std::size_t blen = b.name_length(); - return (i.m_len < blen) || - (i.m_len == blen && - std::char_traits::compare - (i.mp_str, b.name(), i.m_len) < 0); - } - - bool operator()(const value_type &b, const intrusive_compare_key_type &i) const - { - std::size_t blen = b.name_length(); - return (blen < i.m_len) || - (blen == i.m_len && - std::char_traits::compare - (b.name(), i.mp_str, i.m_len) < 0); - } - }; - - /// @endcond - - public: - - //!Constructor. Takes a pointer to the - //!segment manager. Can throw - iset_index(typename MapConfig::segment_manager_base *) - : index_type(/*typename index_aux::value_compare()*/) - {} - - //!This reserves memory to optimize the insertion of n - //!elements in the index - void reserve(typename MapConfig::segment_manager_base::size_type) - { /*Does nothing, map has not reserve or rehash*/ } - - //!This frees all unnecessary memory - void shrink_to_fit() - { /*Does nothing, this intrusive index does not allocate memory;*/ } - - iterator find(const intrusive_compare_key_type &key) - { return index_type::find(key, intrusive_key_value_less()); } - - const_iterator find(const intrusive_compare_key_type &key) const - { return index_type::find(key, intrusive_key_value_less()); } - - std::pairinsert_check - (const intrusive_compare_key_type &key, insert_commit_data &commit_data) - { return index_type::insert_check(key, intrusive_key_value_less(), commit_data); } -}; - -/// @cond - -//!Trait class to detect if an index is an intrusive -//!index. -template -struct is_intrusive_index - > -{ - static const bool value = true; -}; -/// @endcond - -} //namespace interprocess { -} //namespace boost - -#include - -#endif //#ifndef BOOST_INTERPROCESS_ISET_INDEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/interprocess_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/interprocess_fwd.hpp deleted file mode 100644 index 42f170a6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/interprocess_fwd.hpp +++ /dev/null @@ -1,418 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_FWD_HPP -#define BOOST_INTERPROCESS_FWD_HPP - -#if defined (_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include - -////////////////////////////////////////////////////////////////////////////// -// Standard predeclarations -////////////////////////////////////////////////////////////////////////////// - -/// @cond - -namespace boost{ -namespace intrusive{ -}} - -namespace boost{ -namespace interprocess{ -namespace bi = boost::intrusive; -}} - -#include -#include -#include -#include -#include - -/// @endcond - -namespace boost { namespace interprocess { - -////////////////////////////////////////////////////////////////////////////// -// permissions -////////////////////////////////////////////////////////////////////////////// - -class permissions; - -////////////////////////////////////////////////////////////////////////////// -// shared_memory -////////////////////////////////////////////////////////////////////////////// - -class shared_memory_object; - -#if defined (BOOST_INTERPROCESS_WINDOWS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) -class windows_shared_memory; -#endif //#if defined (BOOST_INTERPROCESS_WINDOWS) - -////////////////////////////////////////////////////////////////////////////// -// mapped file/mapped region/mapped_file -////////////////////////////////////////////////////////////////////////////// - -class file_mapping; -class mapped_region; -class mapped_file; - -////////////////////////////////////////////////////////////////////////////// -// Mutexes -////////////////////////////////////////////////////////////////////////////// - -class null_mutex; - -class interprocess_mutex; -class interprocess_recursive_mutex; - -class named_mutex; -class named_recursive_mutex; - -class interprocess_semaphore; -class named_semaphore; - -////////////////////////////////////////////////////////////////////////////// -// Mutex families -////////////////////////////////////////////////////////////////////////////// - -struct mutex_family; -struct null_mutex_family; - -////////////////////////////////////////////////////////////////////////////// -// Other synchronization classes -////////////////////////////////////////////////////////////////////////////// - -class barrier; -class interprocess_sharable_mutex; -class interprocess_condition; - -////////////////////////////////////////////////////////////////////////////// -// Locks -////////////////////////////////////////////////////////////////////////////// - -template -class scoped_lock; - -template -class sharable_lock; - -template -class upgradable_lock; - -////////////////////////////////////////////////////////////////////////////// -// STL compatible allocators -////////////////////////////////////////////////////////////////////////////// - -template -class allocator; - -template -class node_allocator; - -template -class private_node_allocator; - -template -class cached_node_allocator; - -template -class adaptive_pool; - -template -class private_adaptive_pool; - -template -class cached_adaptive_pool; - - -////////////////////////////////////////////////////////////////////////////// -// offset_ptr -////////////////////////////////////////////////////////////////////////////// - -static const std::size_t offset_type_alignment = 0; - -template -class offset_ptr; - -////////////////////////////////////////////////////////////////////////////// -// Memory allocation algorithms -////////////////////////////////////////////////////////////////////////////// - -//Single segment memory allocation algorithms -template > -class simple_seq_fit; - -template, std::size_t MemAlignment = 0> -class rbtree_best_fit; - -////////////////////////////////////////////////////////////////////////////// -// Index Types -////////////////////////////////////////////////////////////////////////////// - -template class flat_map_index; -template class iset_index; -template class iunordered_set_index; -template class map_index; -template class null_index; -template class unordered_map_index; - -////////////////////////////////////////////////////////////////////////////// -// Segment manager -////////////////////////////////////////////////////////////////////////////// - -template class IndexType> -class segment_manager; - -////////////////////////////////////////////////////////////////////////////// -// External buffer managed memory classes -////////////////////////////////////////////////////////////////////////////// - -template class IndexType> -class basic_managed_external_buffer; - -typedef basic_managed_external_buffer - - ,iset_index> -managed_external_buffer; - -typedef basic_managed_external_buffer - - ,iset_index> -wmanaged_external_buffer; - -////////////////////////////////////////////////////////////////////////////// -// managed memory classes -////////////////////////////////////////////////////////////////////////////// - -template class IndexType> -class basic_managed_shared_memory; - -typedef basic_managed_shared_memory - - ,iset_index> -managed_shared_memory; - -typedef basic_managed_shared_memory - - ,iset_index> -wmanaged_shared_memory; - - -////////////////////////////////////////////////////////////////////////////// -// Windows shared memory managed memory classes -////////////////////////////////////////////////////////////////////////////// - -#if defined (BOOST_INTERPROCESS_WINDOWS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - -template class IndexType> -class basic_managed_windows_shared_memory; - -typedef basic_managed_windows_shared_memory - - ,iset_index> -managed_windows_shared_memory; - -typedef basic_managed_windows_shared_memory - - ,iset_index> -wmanaged_windows_shared_memory; - -#endif //#if defined (BOOST_INTERPROCESS_WINDOWS) - -#if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - -template class IndexType> -class basic_managed_xsi_shared_memory; - -typedef basic_managed_xsi_shared_memory - - ,iset_index> -managed_xsi_shared_memory; - -typedef basic_managed_xsi_shared_memory - - ,iset_index> -wmanaged_xsi_shared_memory; - -#endif //#if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) - -////////////////////////////////////////////////////////////////////////////// -// Fixed address shared memory -////////////////////////////////////////////////////////////////////////////// - -typedef basic_managed_shared_memory - - ,iset_index> -fixed_managed_shared_memory; - -typedef basic_managed_shared_memory - - ,iset_index> -wfixed_managed_shared_memory; - -////////////////////////////////////////////////////////////////////////////// -// Heap memory managed memory classes -////////////////////////////////////////////////////////////////////////////// - -template - class IndexType> -class basic_managed_heap_memory; - -typedef basic_managed_heap_memory - - ,iset_index> -managed_heap_memory; - -typedef basic_managed_heap_memory - - ,iset_index> -wmanaged_heap_memory; - -////////////////////////////////////////////////////////////////////////////// -// Mapped file managed memory classes -////////////////////////////////////////////////////////////////////////////// - -template - class IndexType> -class basic_managed_mapped_file; - -typedef basic_managed_mapped_file - - ,iset_index> -managed_mapped_file; - -typedef basic_managed_mapped_file - - ,iset_index> -wmanaged_mapped_file; - -////////////////////////////////////////////////////////////////////////////// -// Exceptions -////////////////////////////////////////////////////////////////////////////// - -class interprocess_exception; -class lock_exception; -class bad_alloc; - -////////////////////////////////////////////////////////////////////////////// -// Bufferstream -////////////////////////////////////////////////////////////////////////////// - -//bufferstream -template > -class basic_bufferbuf; - -template > -class basic_ibufferstream; - -template > -class basic_obufferstream; - -template > -class basic_bufferstream; - -////////////////////////////////////////////////////////////////////////////// -// Vectorstream -////////////////////////////////////////////////////////////////////////////// - -template > -class basic_vectorbuf; - -template > -class basic_ivectorstream; - -template > -class basic_ovectorstream; - -template > -class basic_vectorstream; - -////////////////////////////////////////////////////////////////////////////// -// Smart pointers -////////////////////////////////////////////////////////////////////////////// - -template -class scoped_ptr; - -template -class intrusive_ptr; - -template -class shared_ptr; - -template -class weak_ptr; - -////////////////////////////////////////////////////////////////////////////// -// IPC -////////////////////////////////////////////////////////////////////////////// - -template -class message_queue_t; - -typedef message_queue_t > message_queue; - -}} //namespace boost { namespace interprocess { - -////////////////////////////////////////////////////////////////////////////// -// CONTAINERS -////////////////////////////////////////////////////////////////////////////// - -#include - -#endif //#ifndef BOOST_INTERPROCESS_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/managed_shared_memory.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/managed_shared_memory.hpp deleted file mode 100644 index c20f39ca..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/managed_shared_memory.hpp +++ /dev/null @@ -1,221 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MANAGED_SHARED_MEMORY_HPP -#define BOOST_INTERPROCESS_MANAGED_SHARED_MEMORY_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -//These includes needed to fulfill default template parameters of -//predeclarations in interprocess_fwd.hpp -#include -#include - -namespace boost { -namespace interprocess { - -namespace ipcdetail { - -template -struct shmem_open_or_create -{ - typedef ipcdetail::managed_open_or_create_impl - < shared_memory_object, AllocationAlgorithm::Alignment, true, false> type; -}; - -} //namespace ipcdetail { - -//!A basic shared memory named object creation class. Initializes the -//!shared memory segment. Inherits all basic functionality from -//!basic_managed_memory_impl*/ -template - < - class CharType, - class AllocationAlgorithm, - template class IndexType - > -class basic_managed_shared_memory - : public ipcdetail::basic_managed_memory_impl - ::type::ManagedOpenOrCreateUserOffset> - , private ipcdetail::shmem_open_or_create::type -{ - /// @cond - typedef ipcdetail::basic_managed_memory_impl - ::type::ManagedOpenOrCreateUserOffset> base_t; - typedef typename ipcdetail::shmem_open_or_create::type base2_t; - - typedef ipcdetail::create_open_func create_open_func_t; - - basic_managed_shared_memory *get_this_pointer() - { return this; } - - public: - typedef shared_memory_object device_type; - typedef typename base_t::size_type size_type; - - private: - typedef typename base_t::char_ptr_holder_t char_ptr_holder_t; - BOOST_MOVABLE_BUT_NOT_COPYABLE(basic_managed_shared_memory) - /// @endcond - - public: //functions - - //!Destroys *this and indicates that the calling process is finished using - //!the resource. The destructor function will deallocate - //!any system resources allocated by the system for use by this process for - //!this resource. The resource can still be opened again calling - //!the open constructor overload. To erase the resource from the system - //!use remove(). - ~basic_managed_shared_memory() - {} - - //!Default constructor. Does nothing. - //!Useful in combination with move semantics - basic_managed_shared_memory() - {} - - //!Creates shared memory and creates and places the segment manager. - //!This can throw. - basic_managed_shared_memory(create_only_t, const char *name, - size_type size, const void *addr = 0, const permissions& perm = permissions()) - : base_t() - , base2_t(create_only, name, size, read_write, addr, - create_open_func_t(get_this_pointer(), ipcdetail::DoCreate), perm) - {} - - //!Creates shared memory and creates and places the segment manager if - //!segment was not created. If segment was created it connects to the - //!segment. - //!This can throw. - basic_managed_shared_memory (open_or_create_t, - const char *name, size_type size, - const void *addr = 0, const permissions& perm = permissions()) - : base_t() - , base2_t(open_or_create, name, size, read_write, addr, - create_open_func_t(get_this_pointer(), - ipcdetail::DoOpenOrCreate), perm) - {} - - //!Connects to a created shared memory and its segment manager. - //!in copy_on_write mode. - //!This can throw. - basic_managed_shared_memory (open_copy_on_write_t, const char* name, - const void *addr = 0) - : base_t() - , base2_t(open_only, name, copy_on_write, addr, - create_open_func_t(get_this_pointer(), - ipcdetail::DoOpen)) - {} - - //!Connects to a created shared memory and its segment manager. - //!in read-only mode. - //!This can throw. - basic_managed_shared_memory (open_read_only_t, const char* name, - const void *addr = 0) - : base_t() - , base2_t(open_only, name, read_only, addr, - create_open_func_t(get_this_pointer(), - ipcdetail::DoOpen)) - {} - - //!Connects to a created shared memory and its segment manager. - //!This can throw. - basic_managed_shared_memory (open_only_t, const char* name, - const void *addr = 0) - : base_t() - , base2_t(open_only, name, read_write, addr, - create_open_func_t(get_this_pointer(), - ipcdetail::DoOpen)) - {} - - //!Moves the ownership of "moved"'s managed memory to *this. - //!Does not throw - basic_managed_shared_memory(BOOST_RV_REF(basic_managed_shared_memory) moved) - { - basic_managed_shared_memory tmp; - this->swap(moved); - tmp.swap(moved); - } - - //!Moves the ownership of "moved"'s managed memory to *this. - //!Does not throw - basic_managed_shared_memory &operator=(BOOST_RV_REF(basic_managed_shared_memory) moved) - { - basic_managed_shared_memory tmp(boost::move(moved)); - this->swap(tmp); - return *this; - } - - //!Swaps the ownership of the managed shared memories managed by *this and other. - //!Never throws. - void swap(basic_managed_shared_memory &other) - { - base_t::swap(other); - base2_t::swap(other); - } - - //!Tries to resize the managed shared memory object so that we have - //!room for more objects. - //! - //!This function is not synchronized so no other thread or process should - //!be reading or writing the file - static bool grow(const char *shmname, size_type extra_bytes) - { - return base_t::template grow - (shmname, extra_bytes); - } - - //!Tries to resize the managed shared memory to minimized the size of the file. - //! - //!This function is not synchronized so no other thread or process should - //!be reading or writing the file - static bool shrink_to_fit(const char *shmname) - { - return base_t::template shrink_to_fit - (shmname); - } - /// @cond - - //!Tries to find a previous named allocation address. Returns a memory - //!buffer and the object count. If not found returned pointer is 0. - //!Never throws. - template - std::pair find (char_ptr_holder_t name) - { - if(base2_t::get_mapped_region().get_mode() == read_only){ - return base_t::template find_no_lock(name); - } - else{ - return base_t::template find(name); - } - } - - /// @endcond -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_MANAGED_SHARED_MEMORY_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mapped_region.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/mapped_region.hpp deleted file mode 100644 index f8260d6c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mapped_region.hpp +++ /dev/null @@ -1,907 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MAPPED_REGION_HPP -#define BOOST_INTERPROCESS_MAPPED_REGION_HPP - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -//Some Unixes use caddr_t instead of void * in madvise -// SunOS Tru64 HP-UX AIX -#if defined(sun) || defined(__sun) || defined(__osf__) || defined(__osf) || defined(_hpux) || defined(hpux) || defined(_AIX) -#define BOOST_INTERPROCESS_MADVISE_USES_CADDR_T -#include -#endif - -//A lot of UNIXes have destructive semantics for MADV_DONTNEED, so -//we need to be careful to allow it. -#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__APPLE__) -#define BOOST_INTERPROCESS_MADV_DONTNEED_HAS_NONDESTRUCTIVE_SEMANTICS -#endif - -#if defined (BOOST_INTERPROCESS_WINDOWS) -# include -# include -#else -# ifdef BOOST_HAS_UNISTD_H -# include -# include //mmap -# include -# include -# include -# if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) -# include //System V shared memory... -# endif -# include -# else -# error Unknown platform -# endif - -#endif //#if (defined BOOST_INTERPROCESS_WINDOWS) - -//!\file -//!Describes mapped region class - -namespace boost { -namespace interprocess { - -/// @cond - -//Solaris declares madvise only in some configurations but defines MADV_XXX, a bit confusing. -//Predeclare it here to avoid any compilation error -#if (defined(sun) || defined(__sun)) && defined(MADV_NORMAL) -extern "C" int madvise(caddr_t, size_t, int); -#endif - -namespace ipcdetail{ class interprocess_tester; } -namespace ipcdetail{ class raw_mapped_region_creator; } - -/// @endcond - -//!The mapped_region class represents a portion or region created from a -//!memory_mappable object. -//! -//!The OS can map a region bigger than the requested one, as region must -//!be multiple of the page size, but mapped_region will always refer to -//!the region specified by the user. -class mapped_region -{ - /// @cond - //Non-copyable - BOOST_MOVABLE_BUT_NOT_COPYABLE(mapped_region) - /// @endcond - - public: - - //!Creates a mapping region of the mapped memory "mapping", starting in - //!offset "offset", and the mapping's size will be "size". The mapping - //!can be opened for read only, read-write or copy-on-write. - //! - //!If an address is specified, both the offset and the address must be - //!multiples of the page size. - //! - //!The map is created using "default_map_options". This flag is OS - //!dependant and it should not be changed unless the user needs to - //!specify special options. - //! - //!In Windows systems "map_options" is a DWORD value passed as - //!"dwDesiredAccess" to "MapViewOfFileEx". If "default_map_options" is passed - //!it's initialized to zero. "map_options" is XORed with FILE_MAP_[COPY|READ|WRITE]. - //! - //!In UNIX systems and POSIX mappings "map_options" is an int value passed as "flags" - //!to "mmap". If "default_map_options" is specified it's initialized to MAP_NOSYNC - //!if that option exists and to zero otherwise. "map_options" XORed with MAP_PRIVATE or MAP_SHARED. - //! - //!In UNIX systems and XSI mappings "map_options" is an int value passed as "shmflg" - //!to "shmat". If "default_map_options" is specified it's initialized to zero. - //!"map_options" is XORed with SHM_RDONLY if needed. - //! - //!The OS could allocate more pages than size/page_size(), but get_address() - //!will always return the address passed in this function (if not null) and - //!get_size() will return the specified size. - template - mapped_region(const MemoryMappable& mapping - ,mode_t mode - ,offset_t offset = 0 - ,std::size_t size = 0 - ,const void *address = 0 - ,map_options_t map_options = default_map_options); - - //!Default constructor. Address will be 0 (nullptr). - //!Size will be 0. - //!Does not throw - mapped_region(); - - //!Move constructor. *this will be constructed taking ownership of "other"'s - //!region and "other" will be left in default constructor state. - mapped_region(BOOST_RV_REF(mapped_region) other) - #if defined (BOOST_INTERPROCESS_WINDOWS) - : m_base(0), m_size(0) - , m_page_offset(0) - , m_mode(read_only) - , m_file_or_mapping_hnd(ipcdetail::invalid_file()) - #else - : m_base(0), m_size(0), m_page_offset(0), m_mode(read_only), m_is_xsi(false) - #endif - { this->swap(other); } - - //!Destroys the mapped region. - //!Does not throw - ~mapped_region(); - - //!Move assignment. If *this owns a memory mapped region, it will be - //!destroyed and it will take ownership of "other"'s memory mapped region. - mapped_region &operator=(BOOST_RV_REF(mapped_region) other) - { - mapped_region tmp(boost::move(other)); - this->swap(tmp); - return *this; - } - - //!Swaps the mapped_region with another - //!mapped region - void swap(mapped_region &other); - - //!Returns the size of the mapping. Never throws. - std::size_t get_size() const; - - //!Returns the base address of the mapping. - //!Never throws. - void* get_address() const; - - //!Returns the mode of the mapping used to construct the mapped region. - //!Never throws. - mode_t get_mode() const; - - //!Flushes to the disk a byte range within the mapped memory. - //!If 'async' is true, the function will return before flushing operation is completed - //!If 'async' is false, function will return once data has been written into the underlying - //!device (i.e., in mapped files OS cached information is written to disk). - //!Never throws. Returns false if operation could not be performed. - bool flush(std::size_t mapping_offset = 0, std::size_t numbytes = 0, bool async = true); - - //!Shrinks current mapped region. If after shrinking there is no longer need for a previously - //!mapped memory page, accessing that page can trigger a segmentation fault. - //!Depending on the OS, this operation might fail (XSI shared memory), it can decommit storage - //!and free a portion of the virtual address space (e.g.POSIX) or this - //!function can release some physical memory wihout freeing any virtual address space(Windows). - //!Returns true on success. Never throws. - bool shrink_by(std::size_t bytes, bool from_back = true); - - //!This enum specifies region usage behaviors that an application can specify - //!to the mapped region implementation. - enum advice_types{ - //!Specifies that the application has no advice to give on its behavior with respect to - //!the region. It is the default characteristic if no advice is given for a range of memory. - advice_normal, - //!Specifies that the application expects to access the region sequentially from - //!lower addresses to higher addresses. The implementation can lower the priority of - //!preceding pages within the region once a page have been accessed. - advice_sequential, - //!Specifies that the application expects to access the region in a random order, - //!and prefetching is likely not advantageous. - advice_random, - //!Specifies that the application expects to access the region in the near future. - //!The implementation can prefetch pages of the region. - advice_willneed, - //!Specifies that the application expects that it will not access the region in the near future. - //!The implementation can unload pages within the range to save system resources. - advice_dontneed - }; - - //!Advises the implementation on the expected behavior of the application with respect to the data - //!in the region. The implementation may use this information to optimize handling of the region data. - //!This function has no effect on the semantics of access to memory in the region, although it may affect - //!the performance of access. - //!If the advise type is not known to the implementation, the function returns false. True otherwise. - bool advise(advice_types advise); - - //!Returns the size of the page. This size is the minimum memory that - //!will be used by the system when mapping a memory mappable source and - //!will restrict the address and the offset to map. - static std::size_t get_page_size(); - - /// @cond - private: - //!Closes a previously opened memory mapping. Never throws - void priv_close(); - - void* priv_map_address() const; - std::size_t priv_map_size() const; - bool priv_flush_param_check(std::size_t mapping_offset, void *&addr, std::size_t &numbytes) const; - bool priv_shrink_param_check(std::size_t bytes, bool from_back, void *&shrink_page_start, std::size_t &shrink_page_bytes); - static void priv_size_from_mapping_size - (offset_t mapping_size, offset_t offset, offset_t page_offset, std::size_t &size); - static offset_t priv_page_offset_addr_fixup(offset_t page_offset, const void *&addr); - - template - struct page_size_holder - { - static const std::size_t PageSize; - static std::size_t get_page_size(); - }; - - void* m_base; - std::size_t m_size; - std::size_t m_page_offset; - mode_t m_mode; - #if defined(BOOST_INTERPROCESS_WINDOWS) - file_handle_t m_file_or_mapping_hnd; - #else - bool m_is_xsi; - #endif - - friend class ipcdetail::interprocess_tester; - friend class ipcdetail::raw_mapped_region_creator; - void dont_close_on_destruction(); - #if defined(BOOST_INTERPROCESS_WINDOWS) && !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) - template - static void destroy_syncs_in_range(const void *addr, std::size_t size); - #endif - /// @endcond -}; - -///@cond - -inline void swap(mapped_region &x, mapped_region &y) -{ x.swap(y); } - -inline mapped_region::~mapped_region() -{ this->priv_close(); } - -inline std::size_t mapped_region::get_size() const -{ return m_size; } - -inline mode_t mapped_region::get_mode() const -{ return m_mode; } - -inline void* mapped_region::get_address() const -{ return m_base; } - -inline void* mapped_region::priv_map_address() const -{ return static_cast(m_base) - m_page_offset; } - -inline std::size_t mapped_region::priv_map_size() const -{ return m_size + m_page_offset; } - -inline bool mapped_region::priv_flush_param_check - (std::size_t mapping_offset, void *&addr, std::size_t &numbytes) const -{ - //Check some errors - if(m_base == 0) - return false; - - if(mapping_offset >= m_size || (mapping_offset + numbytes) > m_size){ - return false; - } - - //Update flush size if the user does not provide it - if(numbytes == 0){ - numbytes = m_size - mapping_offset; - } - addr = (char*)this->priv_map_address() + mapping_offset; - numbytes += m_page_offset; - return true; -} - -inline bool mapped_region::priv_shrink_param_check - (std::size_t bytes, bool from_back, void *&shrink_page_start, std::size_t &shrink_page_bytes) -{ - //Check some errors - if(m_base == 0 || bytes > m_size){ - return false; - } - else if(bytes == m_size){ - this->priv_close(); - return true; - } - else{ - const std::size_t page_size = mapped_region::get_page_size(); - if(from_back){ - const std::size_t new_pages = (m_size + m_page_offset - bytes - 1)/page_size + 1; - shrink_page_start = static_cast(this->priv_map_address()) + new_pages*page_size; - shrink_page_bytes = m_page_offset + m_size - new_pages*page_size; - m_size -= bytes; - } - else{ - shrink_page_start = this->priv_map_address(); - m_page_offset += bytes; - shrink_page_bytes = (m_page_offset/page_size)*page_size; - m_page_offset = m_page_offset % page_size; - m_size -= bytes; - m_base = static_cast(m_base) + bytes; - BOOST_ASSERT(shrink_page_bytes%page_size == 0); - } - return true; - } -} - -inline void mapped_region::priv_size_from_mapping_size - (offset_t mapping_size, offset_t offset, offset_t page_offset, std::size_t &size) -{ - //Check if mapping size fits in the user address space - //as offset_t is the maximum file size and its signed. - if(mapping_size < offset || - boost::uintmax_t(mapping_size - (offset - page_offset)) > - boost::uintmax_t(std::size_t(-1))){ - error_info err(size_error); - throw interprocess_exception(err); - } - size = static_cast(mapping_size - (offset - page_offset)); -} - -inline offset_t mapped_region::priv_page_offset_addr_fixup(offset_t offset, const void *&address) -{ - //We can't map any offset so we have to obtain system's - //memory granularity - const std::size_t page_size = mapped_region::get_page_size(); - - //We calculate the difference between demanded and valid offset - //(always less than a page in std::size_t, thus, representable by std::size_t) - const std::size_t page_offset = - static_cast(offset - (offset / page_size) * page_size); - //Update the mapping address - if(address){ - address = static_cast(address) - page_offset; - } - return page_offset; -} - -#if defined (BOOST_INTERPROCESS_WINDOWS) - -inline mapped_region::mapped_region() - : m_base(0), m_size(0), m_page_offset(0), m_mode(read_only) - , m_file_or_mapping_hnd(ipcdetail::invalid_file()) -{} - -template -inline std::size_t mapped_region::page_size_holder::get_page_size() -{ - winapi::system_info info; - get_system_info(&info); - return std::size_t(info.dwAllocationGranularity); -} - -template -inline mapped_region::mapped_region - (const MemoryMappable &mapping - ,mode_t mode - ,offset_t offset - ,std::size_t size - ,const void *address - ,map_options_t map_options) - : m_base(0), m_size(0), m_page_offset(0), m_mode(mode) - , m_file_or_mapping_hnd(ipcdetail::invalid_file()) -{ - mapping_handle_t mhandle = mapping.get_mapping_handle(); - { - file_handle_t native_mapping_handle = 0; - - //Set accesses - //For "create_file_mapping" - unsigned long protection = 0; - //For "mapviewoffile" - unsigned long map_access = map_options == default_map_options ? 0 : map_options; - - switch(mode) - { - case read_only: - case read_private: - protection |= winapi::page_readonly; - map_access |= winapi::file_map_read; - break; - case read_write: - protection |= winapi::page_readwrite; - map_access |= winapi::file_map_write; - break; - case copy_on_write: - protection |= winapi::page_writecopy; - map_access |= winapi::file_map_copy; - break; - default: - { - error_info err(mode_error); - throw interprocess_exception(err); - } - break; - } - - //For file mapping (including emulated shared memory through temporary files), - //the device is a file handle so we need to obtain file's size and call create_file_mapping - //to obtain the mapping handle. - //For files we don't need the file mapping after mapping the memory, as the file is there - //so we'll program the handle close - void * handle_to_close = winapi::invalid_handle_value; - if(!mhandle.is_shm){ - //Create mapping handle - native_mapping_handle = winapi::create_file_mapping - ( ipcdetail::file_handle_from_mapping_handle(mapping.get_mapping_handle()) - , protection, 0, 0, 0); - - //Check if all is correct - if(!native_mapping_handle){ - error_info err = winapi::get_last_error(); - throw interprocess_exception(err); - } - handle_to_close = native_mapping_handle; - } - else{ - //For windows_shared_memory the device handle is already a mapping handle - //and we need to maintain it - native_mapping_handle = mhandle.handle; - } - //RAII handle close on scope exit - const winapi::handle_closer close_handle(handle_to_close); - (void)close_handle; - - const offset_t page_offset = priv_page_offset_addr_fixup(offset, address); - - //Obtain mapping size if user provides 0 size - if(size == 0){ - offset_t mapping_size; - if(!winapi::get_file_mapping_size(native_mapping_handle, mapping_size)){ - error_info err = winapi::get_last_error(); - throw interprocess_exception(err); - } - //This can throw - priv_size_from_mapping_size(mapping_size, offset, page_offset, size); - } - - //Map with new offsets and size - void *base = winapi::map_view_of_file_ex - (native_mapping_handle, - map_access, - offset - page_offset, - static_cast(page_offset + size), - const_cast(address)); - //Check error - if(!base){ - error_info err = winapi::get_last_error(); - throw interprocess_exception(err); - } - - //Calculate new base for the user - m_base = static_cast(base) + page_offset; - m_page_offset = page_offset; - m_size = size; - } - //Windows shared memory needs the duplication of the handle if we want to - //make mapped_region independent from the mappable device - // - //For mapped files, we duplicate the file handle to be able to FlushFileBuffers - if(!winapi::duplicate_current_process_handle(mhandle.handle, &m_file_or_mapping_hnd)){ - error_info err = winapi::get_last_error(); - this->priv_close(); - throw interprocess_exception(err); - } -} - -inline bool mapped_region::flush(std::size_t mapping_offset, std::size_t numbytes, bool async) -{ - void *addr; - if(!this->priv_flush_param_check(mapping_offset, addr, numbytes)){ - return false; - } - //Flush it all - if(!winapi::flush_view_of_file(addr, numbytes)){ - return false; - } - //m_file_or_mapping_hnd can be a file handle or a mapping handle. - //so flushing file buffers has only sense for files... - else if(!async && m_file_or_mapping_hnd != winapi::invalid_handle_value && - winapi::get_file_type(m_file_or_mapping_hnd) == winapi::file_type_disk){ - return winapi::flush_file_buffers(m_file_or_mapping_hnd); - } - return true; -} - -inline bool mapped_region::shrink_by(std::size_t bytes, bool from_back) -{ - void *shrink_page_start; - std::size_t shrink_page_bytes; - if(!this->priv_shrink_param_check(bytes, from_back, shrink_page_start, shrink_page_bytes)){ - return false; - } - else if(shrink_page_bytes){ - //In Windows, we can't decommit the storage or release the virtual address space, - //the best we can do is try to remove some memory from the process working set. - //With a bit of luck we can free some physical memory. - unsigned long old_protect_ignored; - bool b_ret = winapi::virtual_unlock(shrink_page_start, shrink_page_bytes) - || (winapi::get_last_error() == winapi::error_not_locked); - (void)old_protect_ignored; - //Change page protection to forbid any further access - b_ret = b_ret && winapi::virtual_protect - (shrink_page_start, shrink_page_bytes, winapi::page_noaccess, old_protect_ignored); - return b_ret; - } - else{ - return true; - } -} - -inline bool mapped_region::advise(advice_types) -{ - //Windows has no madvise/posix_madvise equivalent - return false; -} - -inline void mapped_region::priv_close() -{ - if(m_base){ - void *addr = this->priv_map_address(); - #if !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) - mapped_region::destroy_syncs_in_range<0>(addr, m_size); - #endif - winapi::unmap_view_of_file(addr); - m_base = 0; - } - if(m_file_or_mapping_hnd != ipcdetail::invalid_file()){ - winapi::close_handle(m_file_or_mapping_hnd); - m_file_or_mapping_hnd = ipcdetail::invalid_file(); - } -} - -inline void mapped_region::dont_close_on_destruction() -{} - -#else //#if (defined BOOST_INTERPROCESS_WINDOWS) - -inline mapped_region::mapped_region() - : m_base(0), m_size(0), m_page_offset(0), m_mode(read_only), m_is_xsi(false) -{} - -template -inline std::size_t mapped_region::page_size_holder::get_page_size() -{ return std::size_t(sysconf(_SC_PAGESIZE)); } - -template -inline mapped_region::mapped_region - ( const MemoryMappable &mapping - , mode_t mode - , offset_t offset - , std::size_t size - , const void *address - , map_options_t map_options) - : m_base(0), m_size(0), m_page_offset(0), m_mode(mode), m_is_xsi(false) -{ - mapping_handle_t map_hnd = mapping.get_mapping_handle(); - - //Some systems dont' support XSI shared memory - #ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - if(map_hnd.is_xsi){ - //Get the size - ::shmid_ds xsi_ds; - int ret = ::shmctl(map_hnd.handle, IPC_STAT, &xsi_ds); - if(ret == -1){ - error_info err(system_error_code()); - throw interprocess_exception(err); - } - //Compare sizess - if(size == 0){ - size = (std::size_t)xsi_ds.shm_segsz; - } - else if(size != (std::size_t)xsi_ds.shm_segsz){ - error_info err(size_error); - throw interprocess_exception(err); - } - //Calculate flag - int flag = map_options == default_map_options ? 0 : map_options; - if(m_mode == read_only){ - flag |= SHM_RDONLY; - } - else if(m_mode != read_write){ - error_info err(mode_error); - throw interprocess_exception(err); - } - //Attach memory - void *base = ::shmat(map_hnd.handle, (void*)address, flag); - if(base == (void*)-1){ - error_info err(system_error_code()); - throw interprocess_exception(err); - } - //Update members - m_base = base; - m_size = size; - m_mode = mode; - m_page_offset = 0; - m_is_xsi = true; - return; - } - #endif //ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - - //We calculate the difference between demanded and valid offset - const offset_t page_offset = priv_page_offset_addr_fixup(offset, address); - - if(size == 0){ - struct ::stat buf; - if(0 != fstat(map_hnd.handle, &buf)){ - error_info err(system_error_code()); - throw interprocess_exception(err); - } - //This can throw - priv_size_from_mapping_size(buf.st_size, offset, page_offset, size); - } - - #ifdef MAP_NOSYNC - #define BOOST_INTERPROCESS_MAP_NOSYNC MAP_NOSYNC - #else - #define BOOST_INTERPROCESS_MAP_NOSYNC 0 - #endif //MAP_NOSYNC - - //Create new mapping - int prot = 0; - int flags = map_options == default_map_options ? BOOST_INTERPROCESS_MAP_NOSYNC : map_options; - - #undef BOOST_INTERPROCESS_MAP_NOSYNC - - switch(mode) - { - case read_only: - prot |= PROT_READ; - flags |= MAP_SHARED; - break; - - case read_private: - prot |= (PROT_READ); - flags |= MAP_PRIVATE; - break; - - case read_write: - prot |= (PROT_WRITE | PROT_READ); - flags |= MAP_SHARED; - break; - - case copy_on_write: - prot |= (PROT_WRITE | PROT_READ); - flags |= MAP_PRIVATE; - break; - - default: - { - error_info err(mode_error); - throw interprocess_exception(err); - } - break; - } - - //Map it to the address space - void* base = mmap ( const_cast(address) - , static_cast(page_offset + size) - , prot - , flags - , mapping.get_mapping_handle().handle - , offset - page_offset); - - //Check if mapping was successful - if(base == MAP_FAILED){ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - - //Calculate new base for the user - m_base = static_cast(base) + page_offset; - m_page_offset = page_offset; - m_size = size; - - //Check for fixed mapping error - if(address && (base != address)){ - error_info err(busy_error); - this->priv_close(); - throw interprocess_exception(err); - } -} - -inline bool mapped_region::shrink_by(std::size_t bytes, bool from_back) -{ - void *shrink_page_start = 0; - std::size_t shrink_page_bytes = 0; - if(m_is_xsi || !this->priv_shrink_param_check(bytes, from_back, shrink_page_start, shrink_page_bytes)){ - return false; - } - else if(shrink_page_bytes){ - //In UNIX we can decommit and free virtual address space. - return 0 == munmap(shrink_page_start, shrink_page_bytes); - } - else{ - return true; - } -} - -inline bool mapped_region::flush(std::size_t mapping_offset, std::size_t numbytes, bool async) -{ - void *addr; - if(m_is_xsi || !this->priv_flush_param_check(mapping_offset, addr, numbytes)){ - return false; - } - //Flush it all - return msync(addr, numbytes, async ? MS_ASYNC : MS_SYNC) == 0; -} - -inline bool mapped_region::advise(advice_types advice) -{ - int unix_advice = 0; - //Modes; 0: none, 2: posix, 1: madvise - const unsigned int mode_none = 0; - const unsigned int mode_padv = 1; - const unsigned int mode_madv = 2; - unsigned int mode = mode_none; - //Choose advice either from POSIX (preferred) or native Unix - switch(advice){ - case advice_normal: - #if defined(POSIX_MADV_NORMAL) - unix_advice = POSIX_MADV_NORMAL; - mode = mode_padv; - #elif defined(MADV_NORMAL) - unix_advice = MADV_NORMAL; - mode = mode_madv; - #endif - break; - case advice_sequential: - #if defined(POSIX_MADV_SEQUENTIAL) - unix_advice = POSIX_MADV_SEQUENTIAL; - mode = mode_padv; - #elif defined(MADV_SEQUENTIAL) - unix_advice = MADV_SEQUENTIAL; - mode = mode_madv; - #endif - break; - case advice_random: - #if defined(POSIX_MADV_RANDOM) - unix_advice = POSIX_MADV_RANDOM; - mode = mode_padv; - #elif defined(MADV_RANDOM) - unix_advice = MADV_RANDOM; - mode = mode_madv; - #endif - break; - case advice_willneed: - #if defined(POSIX_MADV_WILLNEED) - unix_advice = POSIX_MADV_WILLNEED; - mode = mode_padv; - #elif defined(MADV_WILLNEED) - unix_advice = MADV_WILLNEED; - mode = mode_madv; - #endif - break; - case advice_dontneed: - #if defined(POSIX_MADV_DONTNEED) - unix_advice = POSIX_MADV_DONTNEED; - mode = mode_padv; - #elif defined(MADV_DONTNEED) && defined(BOOST_INTERPROCESS_MADV_DONTNEED_HAS_NONDESTRUCTIVE_SEMANTICS) - unix_advice = MADV_DONTNEED; - mode = mode_madv; - #endif - break; - default: - return false; - } - switch(mode){ - #if defined(POSIX_MADV_NORMAL) - case mode_padv: - return 0 == posix_madvise(this->priv_map_address(), this->priv_map_size(), unix_advice); - #endif - #if defined(MADV_NORMAL) - case mode_madv: - return 0 == madvise( - #if defined(BOOST_INTERPROCESS_MADVISE_USES_CADDR_T) - (caddr_t) - #endif - this->priv_map_address(), this->priv_map_size(), unix_advice); - #endif - default: - return false; - - } -} - -inline void mapped_region::priv_close() -{ - if(m_base != 0){ - #ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - if(m_is_xsi){ - int ret = ::shmdt(m_base); - BOOST_ASSERT(ret == 0); - (void)ret; - return; - } - #endif //#ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS - munmap(this->priv_map_address(), this->priv_map_size()); - m_base = 0; - } -} - -inline void mapped_region::dont_close_on_destruction() -{ m_base = 0; } - -#endif //##if (defined BOOST_INTERPROCESS_WINDOWS) - -template -const std::size_t mapped_region::page_size_holder::PageSize - = mapped_region::page_size_holder::get_page_size(); - -inline std::size_t mapped_region::get_page_size() -{ - if(!page_size_holder<0>::PageSize) - return page_size_holder<0>::get_page_size(); - else - return page_size_holder<0>::PageSize; -} - -inline void mapped_region::swap(mapped_region &other) -{ - ipcdetail::do_swap(this->m_base, other.m_base); - ipcdetail::do_swap(this->m_size, other.m_size); - ipcdetail::do_swap(this->m_page_offset, other.m_page_offset); - ipcdetail::do_swap(this->m_mode, other.m_mode); - #if (defined BOOST_INTERPROCESS_WINDOWS) - ipcdetail::do_swap(this->m_file_or_mapping_hnd, other.m_file_or_mapping_hnd); - #else - ipcdetail::do_swap(this->m_is_xsi, other.m_is_xsi); - #endif -} - -//!No-op functor -struct null_mapped_region_function -{ - bool operator()(void *, std::size_t , bool) const - { return true; } - - std::size_t get_min_size() const - { return 0; } -}; - -/// @endcond - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_MAPPED_REGION_HPP - -#if !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - -#ifndef BOOST_INTERPROCESS_MAPPED_REGION_EXT_HPP -#define BOOST_INTERPROCESS_MAPPED_REGION_EXT_HPP - -#if defined(BOOST_INTERPROCESS_WINDOWS) && !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) -# include -# include - -namespace boost { -namespace interprocess { - -template -inline void mapped_region::destroy_syncs_in_range(const void *addr, std::size_t size) -{ - ipcdetail::sync_handles &handles = - ipcdetail::windows_intermodule_singleton::get(); - handles.destroy_syncs_in_range(addr, size); -} - -} //namespace interprocess { -} //namespace boost { - -#endif //defined(BOOST_INTERPROCESS_WINDOWS) && !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) - -#endif //#ifdef BOOST_INTERPROCESS_MAPPED_REGION_EXT_HPP - -#endif //#if !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/detail/mem_algo_common.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/detail/mem_algo_common.hpp deleted file mode 100644 index a6936ec3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/detail/mem_algo_common.hpp +++ /dev/null @@ -1,591 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_MEM_ALGO_COMMON_HPP -#define BOOST_INTERPROCESS_DETAIL_MEM_ALGO_COMMON_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -//!\file -//!Implements common operations for memory algorithms. - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -template -class basic_multiallocation_chain - : public boost::container::container_detail:: - basic_multiallocation_chain -{ - BOOST_MOVABLE_BUT_NOT_COPYABLE(basic_multiallocation_chain) - typedef boost::container::container_detail:: - basic_multiallocation_chain base_t; - public: - - basic_multiallocation_chain() - : base_t() - {} - - basic_multiallocation_chain(BOOST_RV_REF(basic_multiallocation_chain) other) - : base_t(::boost::move(static_cast(other))) - {} - - basic_multiallocation_chain& operator=(BOOST_RV_REF(basic_multiallocation_chain) other) - { - this->base_t::operator=(::boost::move(static_cast(other))); - return *this; - } - - void *pop_front() - { - return boost::interprocess::ipcdetail::to_raw_pointer(this->base_t::pop_front()); - } -}; - - -//!This class implements several allocation functions shared by different algorithms -//!(aligned allocation, multiple allocation...). -template -class memory_algorithm_common -{ - public: - typedef typename MemoryAlgorithm::void_pointer void_pointer; - typedef typename MemoryAlgorithm::block_ctrl block_ctrl; - typedef typename MemoryAlgorithm::multiallocation_chain multiallocation_chain; - typedef memory_algorithm_common this_type; - typedef typename MemoryAlgorithm::size_type size_type; - - static const size_type Alignment = MemoryAlgorithm::Alignment; - static const size_type MinBlockUnits = MemoryAlgorithm::MinBlockUnits; - static const size_type AllocatedCtrlBytes = MemoryAlgorithm::AllocatedCtrlBytes; - static const size_type AllocatedCtrlUnits = MemoryAlgorithm::AllocatedCtrlUnits; - static const size_type BlockCtrlBytes = MemoryAlgorithm::BlockCtrlBytes; - static const size_type BlockCtrlUnits = MemoryAlgorithm::BlockCtrlUnits; - static const size_type UsableByPreviousChunk = MemoryAlgorithm::UsableByPreviousChunk; - - static void assert_alignment(const void *ptr) - { assert_alignment((std::size_t)ptr); } - - static void assert_alignment(size_type uint_ptr) - { - (void)uint_ptr; - BOOST_ASSERT(uint_ptr % Alignment == 0); - } - - static bool check_alignment(const void *ptr) - { return (((std::size_t)ptr) % Alignment == 0); } - - static size_type ceil_units(size_type size) - { return get_rounded_size(size, Alignment)/Alignment; } - - static size_type floor_units(size_type size) - { return size/Alignment; } - - static size_type multiple_of_units(size_type size) - { return get_rounded_size(size, Alignment); } - - static void allocate_many - (MemoryAlgorithm *memory_algo, size_type elem_bytes, size_type n_elements, multiallocation_chain &chain) - { - return this_type::priv_allocate_many(memory_algo, &elem_bytes, n_elements, 0, chain); - } - - static void deallocate_many(MemoryAlgorithm *memory_algo, multiallocation_chain &chain) - { - return this_type::priv_deallocate_many(memory_algo, chain); - } - - static bool calculate_lcm_and_needs_backwards_lcmed - (size_type backwards_multiple, size_type received_size, size_type size_to_achieve, - size_type &lcm_out, size_type &needs_backwards_lcmed_out) - { - // Now calculate lcm_val - size_type max = backwards_multiple; - size_type min = Alignment; - size_type needs_backwards; - size_type needs_backwards_lcmed; - size_type lcm_val; - size_type current_forward; - //Swap if necessary - if(max < min){ - size_type tmp = min; - min = max; - max = tmp; - } - //Check if it's power of two - if((backwards_multiple & (backwards_multiple-1)) == 0){ - if(0 != (size_to_achieve & ((backwards_multiple-1)))){ - return false; - } - - lcm_val = max; - //If we want to use minbytes data to get a buffer between maxbytes - //and minbytes if maxbytes can't be achieved, calculate the - //biggest of all possibilities - current_forward = get_truncated_size_po2(received_size, backwards_multiple); - needs_backwards = size_to_achieve - current_forward; - BOOST_ASSERT((needs_backwards % backwards_multiple) == 0); - needs_backwards_lcmed = get_rounded_size_po2(needs_backwards, lcm_val); - lcm_out = lcm_val; - needs_backwards_lcmed_out = needs_backwards_lcmed; - return true; - } - //Check if it's multiple of alignment - else if((backwards_multiple & (Alignment - 1u)) == 0){ - lcm_val = backwards_multiple; - current_forward = get_truncated_size(received_size, backwards_multiple); - //No need to round needs_backwards because backwards_multiple == lcm_val - needs_backwards_lcmed = needs_backwards = size_to_achieve - current_forward; - BOOST_ASSERT((needs_backwards_lcmed & (Alignment - 1u)) == 0); - lcm_out = lcm_val; - needs_backwards_lcmed_out = needs_backwards_lcmed; - return true; - } - //Check if it's multiple of the half of the alignmment - else if((backwards_multiple & ((Alignment/2u) - 1u)) == 0){ - lcm_val = backwards_multiple*2u; - current_forward = get_truncated_size(received_size, backwards_multiple); - needs_backwards_lcmed = needs_backwards = size_to_achieve - current_forward; - if(0 != (needs_backwards_lcmed & (Alignment-1))) - //while(0 != (needs_backwards_lcmed & (Alignment-1))) - needs_backwards_lcmed += backwards_multiple; - BOOST_ASSERT((needs_backwards_lcmed % lcm_val) == 0); - lcm_out = lcm_val; - needs_backwards_lcmed_out = needs_backwards_lcmed; - return true; - } - //Check if it's multiple of the quarter of the alignmment - else if((backwards_multiple & ((Alignment/4u) - 1u)) == 0){ - size_type remainder; - lcm_val = backwards_multiple*4u; - current_forward = get_truncated_size(received_size, backwards_multiple); - needs_backwards_lcmed = needs_backwards = size_to_achieve - current_forward; - //while(0 != (needs_backwards_lcmed & (Alignment-1))) - //needs_backwards_lcmed += backwards_multiple; - if(0 != (remainder = ((needs_backwards_lcmed & (Alignment-1))>>(Alignment/8u)))){ - if(backwards_multiple & Alignment/2u){ - needs_backwards_lcmed += (remainder)*backwards_multiple; - } - else{ - needs_backwards_lcmed += (4-remainder)*backwards_multiple; - } - } - BOOST_ASSERT((needs_backwards_lcmed % lcm_val) == 0); - lcm_out = lcm_val; - needs_backwards_lcmed_out = needs_backwards_lcmed; - return true; - } - else{ - lcm_val = lcm(max, min); - } - //If we want to use minbytes data to get a buffer between maxbytes - //and minbytes if maxbytes can't be achieved, calculate the - //biggest of all possibilities - current_forward = get_truncated_size(received_size, backwards_multiple); - needs_backwards = size_to_achieve - current_forward; - BOOST_ASSERT((needs_backwards % backwards_multiple) == 0); - needs_backwards_lcmed = get_rounded_size(needs_backwards, lcm_val); - lcm_out = lcm_val; - needs_backwards_lcmed_out = needs_backwards_lcmed; - return true; - } - - static void allocate_many - ( MemoryAlgorithm *memory_algo - , const size_type *elem_sizes - , size_type n_elements - , size_type sizeof_element - , multiallocation_chain &chain) - { - this_type::priv_allocate_many(memory_algo, elem_sizes, n_elements, sizeof_element, chain); - } - - static void* allocate_aligned - (MemoryAlgorithm *memory_algo, size_type nbytes, size_type alignment) - { - - //Ensure power of 2 - if ((alignment & (alignment - size_type(1u))) != 0){ - //Alignment is not power of two - BOOST_ASSERT((alignment & (alignment - size_type(1u))) == 0); - return 0; - } - - size_type real_size; - if(alignment <= Alignment){ - return memory_algo->priv_allocate - (boost::interprocess::allocate_new, nbytes, nbytes, real_size).first; - } - - if(nbytes > UsableByPreviousChunk) - nbytes -= UsableByPreviousChunk; - - //We can find a aligned portion if we allocate a block that has alignment - //nbytes + alignment bytes or more. - size_type minimum_allocation = max_value - (nbytes + alignment, size_type(MinBlockUnits*Alignment)); - //Since we will split that block, we must request a bit more memory - //if the alignment is near the beginning of the buffer, because otherwise, - //there is no space for a new block before the alignment. - // - // ____ Aligned here - // | - // ----------------------------------------------------- - // | MBU | - // ----------------------------------------------------- - size_type request = - minimum_allocation + (2*MinBlockUnits*Alignment - AllocatedCtrlBytes - //prevsize - UsableByPreviousChunk - ); - - //Now allocate the buffer - void *buffer = memory_algo->priv_allocate - (boost::interprocess::allocate_new, request, request, real_size).first; - if(!buffer){ - return 0; - } - else if ((((std::size_t)(buffer)) % alignment) == 0){ - //If we are lucky and the buffer is aligned, just split it and - //return the high part - block_ctrl *first = memory_algo->priv_get_block(buffer); - size_type old_size = first->m_size; - const size_type first_min_units = - max_value(ceil_units(nbytes) + AllocatedCtrlUnits, size_type(MinBlockUnits)); - //We can create a new block in the end of the segment - if(old_size >= (first_min_units + MinBlockUnits)){ - block_ctrl *second = reinterpret_cast - (reinterpret_cast(first) + Alignment*first_min_units); - first->m_size = first_min_units; - second->m_size = old_size - first->m_size; - BOOST_ASSERT(second->m_size >= MinBlockUnits); - memory_algo->priv_mark_new_allocated_block(first); - //memory_algo->priv_tail_size(first, first->m_size); - memory_algo->priv_mark_new_allocated_block(second); - memory_algo->priv_deallocate(memory_algo->priv_get_user_buffer(second)); - } - return buffer; - } - - //Buffer not aligned, find the aligned part. - // - // ____ Aligned here - // | - // ----------------------------------------------------- - // | MBU +more | ACB | - // ----------------------------------------------------- - char *pos = reinterpret_cast - (reinterpret_cast(static_cast(buffer) + - //This is the minimum size of (2) - (MinBlockUnits*Alignment - AllocatedCtrlBytes) + - //This is the next MBU for the aligned memory - AllocatedCtrlBytes + - //This is the alignment trick - alignment - 1) & -alignment); - - //Now obtain the address of the blocks - block_ctrl *first = memory_algo->priv_get_block(buffer); - block_ctrl *second = memory_algo->priv_get_block(pos); - BOOST_ASSERT(pos <= (reinterpret_cast(first) + first->m_size*Alignment)); - BOOST_ASSERT(first->m_size >= 2*MinBlockUnits); - BOOST_ASSERT((pos + MinBlockUnits*Alignment - AllocatedCtrlBytes + nbytes*Alignment/Alignment) <= - (reinterpret_cast(first) + first->m_size*Alignment)); - //Set the new size of the first block - size_type old_size = first->m_size; - first->m_size = (size_type)(reinterpret_cast(second) - reinterpret_cast(first))/Alignment; - memory_algo->priv_mark_new_allocated_block(first); - - //Now check if we can create a new buffer in the end - // - // __"second" block - // | __Aligned here - // | | __"third" block - // -----------|-----|-----|------------------------------ - // | MBU +more | ACB | (3) | BCU | - // ----------------------------------------------------- - //This size will be the minimum size to be able to create a - //new block in the end. - const size_type second_min_units = max_value(size_type(MinBlockUnits), - ceil_units(nbytes) + AllocatedCtrlUnits ); - - //Check if we can create a new block (of size MinBlockUnits) in the end of the segment - if((old_size - first->m_size) >= (second_min_units + MinBlockUnits)){ - //Now obtain the address of the end block - block_ctrl *third = new (reinterpret_cast(second) + Alignment*second_min_units)block_ctrl; - second->m_size = second_min_units; - third->m_size = old_size - first->m_size - second->m_size; - BOOST_ASSERT(third->m_size >= MinBlockUnits); - memory_algo->priv_mark_new_allocated_block(second); - memory_algo->priv_mark_new_allocated_block(third); - memory_algo->priv_deallocate(memory_algo->priv_get_user_buffer(third)); - } - else{ - second->m_size = old_size - first->m_size; - BOOST_ASSERT(second->m_size >= MinBlockUnits); - memory_algo->priv_mark_new_allocated_block(second); - } - - memory_algo->priv_deallocate(memory_algo->priv_get_user_buffer(first)); - return memory_algo->priv_get_user_buffer(second); - } - - static bool try_shrink - (MemoryAlgorithm *memory_algo, void *ptr - ,const size_type max_size, const size_type preferred_size - ,size_type &received_size) - { - (void)memory_algo; - //Obtain the real block - block_ctrl *block = memory_algo->priv_get_block(ptr); - size_type old_block_units = (size_type)block->m_size; - - //The block must be marked as allocated - BOOST_ASSERT(memory_algo->priv_is_allocated_block(block)); - - //Check if alignment and block size are right - assert_alignment(ptr); - - //Put this to a safe value - received_size = (old_block_units - AllocatedCtrlUnits)*Alignment + UsableByPreviousChunk; - - //Now translate it to Alignment units - const size_type max_user_units = floor_units(max_size - UsableByPreviousChunk); - const size_type preferred_user_units = ceil_units(preferred_size - UsableByPreviousChunk); - - //Check if rounded max and preferred are possible correct - if(max_user_units < preferred_user_units) - return false; - - //Check if the block is smaller than the requested minimum - size_type old_user_units = old_block_units - AllocatedCtrlUnits; - - if(old_user_units < preferred_user_units) - return false; - - //If the block is smaller than the requested minimum - if(old_user_units == preferred_user_units) - return true; - - size_type shrunk_user_units = - ((BlockCtrlUnits - AllocatedCtrlUnits) >= preferred_user_units) - ? (BlockCtrlUnits - AllocatedCtrlUnits) - : preferred_user_units; - - //Some parameter checks - if(max_user_units < shrunk_user_units) - return false; - - //We must be able to create at least a new empty block - if((old_user_units - shrunk_user_units) < BlockCtrlUnits ){ - return false; - } - - //Update new size - received_size = shrunk_user_units*Alignment + UsableByPreviousChunk; - return true; - } - - static bool shrink - (MemoryAlgorithm *memory_algo, void *ptr - ,const size_type max_size, const size_type preferred_size - ,size_type &received_size) - { - //Obtain the real block - block_ctrl *block = memory_algo->priv_get_block(ptr); - size_type old_block_units = (size_type)block->m_size; - - if(!try_shrink - (memory_algo, ptr, max_size, preferred_size, received_size)){ - return false; - } - - //Check if the old size was just the shrunk size (no splitting) - if((old_block_units - AllocatedCtrlUnits) == ceil_units(preferred_size - UsableByPreviousChunk)) - return true; - - //Now we can just rewrite the size of the old buffer - block->m_size = (received_size-UsableByPreviousChunk)/Alignment + AllocatedCtrlUnits; - BOOST_ASSERT(block->m_size >= BlockCtrlUnits); - - //We create the new block - block_ctrl *new_block = reinterpret_cast - (reinterpret_cast(block) + block->m_size*Alignment); - //Write control data to simulate this new block was previously allocated - //and deallocate it - new_block->m_size = old_block_units - block->m_size; - BOOST_ASSERT(new_block->m_size >= BlockCtrlUnits); - memory_algo->priv_mark_new_allocated_block(block); - memory_algo->priv_mark_new_allocated_block(new_block); - memory_algo->priv_deallocate(memory_algo->priv_get_user_buffer(new_block)); - return true; - } - - private: - static void priv_allocate_many - ( MemoryAlgorithm *memory_algo - , const size_type *elem_sizes - , size_type n_elements - , size_type sizeof_element - , multiallocation_chain &chain) - { - //Note: sizeof_element == 0 indicates that we want to - //allocate n_elements of the same size "*elem_sizes" - - //Calculate the total size of all requests - size_type total_request_units = 0; - size_type elem_units = 0; - const size_type ptr_size_units = memory_algo->priv_get_total_units(sizeof(void_pointer)); - if(!sizeof_element){ - elem_units = memory_algo->priv_get_total_units(*elem_sizes); - elem_units = ptr_size_units > elem_units ? ptr_size_units : elem_units; - total_request_units = n_elements*elem_units; - } - else{ - for(size_type i = 0; i < n_elements; ++i){ - if(multiplication_overflows(elem_sizes[i], sizeof_element)){ - total_request_units = 0; - break; - } - elem_units = memory_algo->priv_get_total_units(elem_sizes[i]*sizeof_element); - elem_units = ptr_size_units > elem_units ? ptr_size_units : elem_units; - if(sum_overflows(total_request_units, elem_units)){ - total_request_units = 0; - break; - } - total_request_units += elem_units; - } - } - - if(total_request_units && !multiplication_overflows(total_request_units, Alignment)){ - size_type low_idx = 0; - while(low_idx < n_elements){ - size_type total_bytes = total_request_units*Alignment - AllocatedCtrlBytes + UsableByPreviousChunk; - size_type min_allocation = (!sizeof_element) - ? elem_units - : memory_algo->priv_get_total_units(elem_sizes[low_idx]*sizeof_element); - min_allocation = min_allocation*Alignment - AllocatedCtrlBytes + UsableByPreviousChunk; - - size_type received_size; - std::pair ret = memory_algo->priv_allocate - (boost::interprocess::allocate_new, min_allocation, total_bytes, received_size, 0); - if(!ret.first){ - break; - } - - block_ctrl *block = memory_algo->priv_get_block(ret.first); - size_type received_units = (size_type)block->m_size; - char *block_address = reinterpret_cast(block); - - size_type total_used_units = 0; - while(total_used_units < received_units){ - if(sizeof_element){ - elem_units = memory_algo->priv_get_total_units(elem_sizes[low_idx]*sizeof_element); - elem_units = ptr_size_units > elem_units ? ptr_size_units : elem_units; - } - if(total_used_units + elem_units > received_units) - break; - total_request_units -= elem_units; - //This is the position where the new block must be created - block_ctrl *new_block = reinterpret_cast(block_address); - assert_alignment(new_block); - - //The last block should take all the remaining space - if((low_idx + 1) == n_elements || - (total_used_units + elem_units + - ((!sizeof_element) - ? elem_units - : std::max(memory_algo->priv_get_total_units(elem_sizes[low_idx+1]*sizeof_element), ptr_size_units)) - ) > received_units){ - //By default, the new block will use the rest of the buffer - new_block->m_size = received_units - total_used_units; - memory_algo->priv_mark_new_allocated_block(new_block); - - //If the remaining units are bigger than needed and we can - //split it obtaining a new free memory block do it. - if((received_units - total_used_units) >= (elem_units + MemoryAlgorithm::BlockCtrlUnits)){ - size_type shrunk_received; - size_type shrunk_request = elem_units*Alignment - AllocatedCtrlBytes + UsableByPreviousChunk; - bool shrink_ok = shrink - (memory_algo - ,memory_algo->priv_get_user_buffer(new_block) - ,shrunk_request - ,shrunk_request - ,shrunk_received); - (void)shrink_ok; - //Shrink must always succeed with passed parameters - BOOST_ASSERT(shrink_ok); - //Some sanity checks - BOOST_ASSERT(shrunk_request == shrunk_received); - BOOST_ASSERT(elem_units == ((shrunk_request-UsableByPreviousChunk)/Alignment + AllocatedCtrlUnits)); - //"new_block->m_size" must have been reduced to elem_units by "shrink" - BOOST_ASSERT(new_block->m_size == elem_units); - //Now update the total received units with the reduction - received_units = elem_units + total_used_units; - } - } - else{ - new_block->m_size = elem_units; - memory_algo->priv_mark_new_allocated_block(new_block); - } - - block_address += new_block->m_size*Alignment; - total_used_units += (size_type)new_block->m_size; - //Check we have enough room to overwrite the intrusive pointer - BOOST_ASSERT((new_block->m_size*Alignment - AllocatedCtrlUnits) >= sizeof(void_pointer)); - void_pointer p = new(memory_algo->priv_get_user_buffer(new_block))void_pointer(0); - chain.push_back(p); - ++low_idx; - } - //Sanity check - BOOST_ASSERT(total_used_units == received_units); - } - - if(low_idx != n_elements){ - priv_deallocate_many(memory_algo, chain); - } - } - } - - static void priv_deallocate_many(MemoryAlgorithm *memory_algo, multiallocation_chain &chain) - { - while(!chain.empty()){ - memory_algo->priv_deallocate(to_raw_pointer(chain.pop_front())); - } - } -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_MEM_ALGO_COMMON_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/rbtree_best_fit.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/rbtree_best_fit.hpp deleted file mode 100644 index 0f42f7ed..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/mem_algo/rbtree_best_fit.hpp +++ /dev/null @@ -1,1413 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MEM_ALGO_RBTREE_BEST_FIT_HPP -#define BOOST_INTERPROCESS_MEM_ALGO_RBTREE_BEST_FIT_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -#include - -//#define BOOST_INTERPROCESS_RBTREE_BEST_FIT_ABI_V1_HPP -//to maintain ABI compatible with the original version -//ABI had to be updated to fix compatibility issues when -//sharing shared memory between 32 adn 64 bit processes. - -//!\file -//!Describes a best-fit algorithm based in an intrusive red-black tree used to allocate -//!objects in shared memory. This class is intended as a base class for single segment -//!and multi-segment implementations. - -namespace boost { -namespace interprocess { - -//!This class implements an algorithm that stores the free nodes in a red-black tree -//!to have logarithmic search/insert times. -template -class rbtree_best_fit -{ - /// @cond - //Non-copyable - rbtree_best_fit(); - rbtree_best_fit(const rbtree_best_fit &); - rbtree_best_fit &operator=(const rbtree_best_fit &); - - private: - struct block_ctrl; - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type block_ctrl_ptr; - - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type char_ptr; - - /// @endcond - - public: - //!Shared mutex family used for the rest of the Interprocess framework - typedef MutexFamily mutex_family; - //!Pointer type to be used with the rest of the Interprocess framework - typedef VoidPointer void_pointer; - typedef ipcdetail::basic_multiallocation_chain multiallocation_chain; - - typedef typename boost::intrusive::pointer_traits::difference_type difference_type; - typedef typename boost::make_unsigned::type size_type; - - /// @cond - - private: - - typedef typename bi::make_set_base_hook - < bi::void_pointer - , bi::optimize_size - , bi::link_mode >::type TreeHook; - - struct SizeHolder - { - //!This block's memory size (including block_ctrl - //!header) in Alignment units - size_type m_prev_size : sizeof(size_type)*CHAR_BIT; - size_type m_size : sizeof(size_type)*CHAR_BIT - 2; - size_type m_prev_allocated : 1; - size_type m_allocated : 1; - }; - - //!Block control structure - struct block_ctrl - : public SizeHolder, public TreeHook - { - block_ctrl() - { this->m_size = 0; this->m_allocated = 0, this->m_prev_allocated = 0; } - - friend bool operator<(const block_ctrl &a, const block_ctrl &b) - { return a.m_size < b.m_size; } - friend bool operator==(const block_ctrl &a, const block_ctrl &b) - { return a.m_size == b.m_size; } - }; - - struct size_block_ctrl_compare - { - bool operator()(size_type size, const block_ctrl &block) const - { return size < block.m_size; } - - bool operator()(const block_ctrl &block, size_type size) const - { return block.m_size < size; } - }; - - //!Shared mutex to protect memory allocate/deallocate - typedef typename MutexFamily::mutex_type mutex_type; - typedef typename bi::make_multiset - >::type Imultiset; - - typedef typename Imultiset::iterator imultiset_iterator; - - //!This struct includes needed data and derives from - //!mutex_type to allow EBO when using null mutex_type - struct header_t : public mutex_type - { - Imultiset m_imultiset; - - //!The extra size required by the segment - size_type m_extra_hdr_bytes; - //!Allocated bytes for internal checking - size_type m_allocated; - //!The size of the memory segment - size_type m_size; - } m_header; - - friend class ipcdetail::memory_algorithm_common; - - typedef ipcdetail::memory_algorithm_common algo_impl_t; - - public: - /// @endcond - - //!Constructor. "size" is the total size of the managed memory segment, - //!"extra_hdr_bytes" indicates the extra bytes beginning in the sizeof(rbtree_best_fit) - //!offset that the allocator should not use at all. - rbtree_best_fit (size_type size, size_type extra_hdr_bytes); - - //!Destructor. - ~rbtree_best_fit(); - - //!Obtains the minimum size needed by the algorithm - static size_type get_min_size (size_type extra_hdr_bytes); - - //Functions for single segment management - - //!Allocates bytes, returns 0 if there is not more memory - void* allocate (size_type nbytes); - - /// @cond - - //Experimental. Dont' use - - //!Multiple element allocation, same size - void allocate_many(size_type elem_bytes, size_type num_elements, multiallocation_chain &chain) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - algo_impl_t::allocate_many(this, elem_bytes, num_elements, chain); - } - - //!Multiple element allocation, different size - void allocate_many(const size_type *elem_sizes, size_type n_elements, size_type sizeof_element, multiallocation_chain &chain) - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - algo_impl_t::allocate_many(this, elem_sizes, n_elements, sizeof_element, chain); - } - - //!Multiple element allocation, different size - void deallocate_many(multiallocation_chain &chain); - - /// @endcond - - //!Deallocates previously allocated bytes - void deallocate (void *addr); - - //!Returns the size of the memory segment - size_type get_size() const; - - //!Returns the number of free bytes of the segment - size_type get_free_memory() const; - - //!Initializes to zero all the memory that's not in use. - //!This function is normally used for security reasons. - void zero_free_memory(); - - //!Increases managed memory in - //!extra_size bytes more - void grow(size_type extra_size); - - //!Decreases managed memory as much as possible - void shrink_to_fit(); - - //!Returns true if all allocated memory has been deallocated - bool all_memory_deallocated(); - - //!Makes an internal sanity check - //!and returns true if success - bool check_sanity(); - - template - std::pair - allocation_command (boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - T *reuse_ptr = 0); - - std::pair - raw_allocation_command (boost::interprocess::allocation_type command, size_type limit_object, - size_type preferred_object,size_type &received_object, - void *reuse_ptr = 0, size_type sizeof_object = 1); - - //!Returns the size of the buffer previously allocated pointed by ptr - size_type size(const void *ptr) const; - - //!Allocates aligned bytes, returns 0 if there is not more memory. - //!Alignment must be power of 2 - void* allocate_aligned (size_type nbytes, size_type alignment); - - /// @cond - private: - static size_type priv_first_block_offset_from_this(const void *this_ptr, size_type extra_hdr_bytes); - - block_ctrl *priv_first_block(); - - block_ctrl *priv_end_block(); - - std::pair - priv_allocation_command(boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - void *reuse_ptr, size_type sizeof_object); - - - //!Real allocation algorithm with min allocation option - std::pair priv_allocate(boost::interprocess::allocation_type command - ,size_type limit_size - ,size_type preferred_size - ,size_type &received_size - ,void *reuse_ptr = 0 - ,size_type backwards_multiple = 1); - - //!Obtains the block control structure of the user buffer - static block_ctrl *priv_get_block(const void *ptr); - - //!Obtains the pointer returned to the user from the block control - static void *priv_get_user_buffer(const block_ctrl *block); - - //!Returns the number of total units that a user buffer - //!of "userbytes" bytes really occupies (including header) - static size_type priv_get_total_units(size_type userbytes); - - //!Real expand function implementation - bool priv_expand(void *ptr - ,const size_type min_size, const size_type preferred_size - ,size_type &received_size); - - //!Real expand to both sides implementation - void* priv_expand_both_sides(boost::interprocess::allocation_type command - ,size_type min_size - ,size_type preferred_size - ,size_type &received_size - ,void *reuse_ptr - ,bool only_preferred_backwards - ,size_type backwards_multiple); - - //!Returns true if the previous block is allocated - bool priv_is_prev_allocated(block_ctrl *ptr); - - //!Get a pointer of the "end" block from the first block of the segment - static block_ctrl * priv_end_block(block_ctrl *first_segment_block); - - //!Get a pointer of the "first" block from the end block of the segment - static block_ctrl * priv_first_block(block_ctrl *end_segment_block); - - //!Get poitner of the previous block (previous block must be free) - static block_ctrl * priv_prev_block(block_ctrl *ptr); - - //!Get the size in the tail of the previous block - static block_ctrl * priv_next_block(block_ctrl *ptr); - - //!Check if this block is free (not allocated) - bool priv_is_allocated_block(block_ctrl *ptr); - - //!Marks the block as allocated - void priv_mark_as_allocated_block(block_ctrl *ptr); - - //!Marks the block as allocated - void priv_mark_new_allocated_block(block_ctrl *ptr) - { return priv_mark_as_allocated_block(ptr); } - - //!Marks the block as allocated - void priv_mark_as_free_block(block_ctrl *ptr); - - //!Checks if block has enough memory and splits/unlinks the block - //!returning the address to the users - void* priv_check_and_allocate(size_type units - ,block_ctrl* block - ,size_type &received_size); - //!Real deallocation algorithm - void priv_deallocate(void *addr); - - //!Makes a new memory portion available for allocation - void priv_add_segment(void *addr, size_type size); - - public: - - static const size_type Alignment = !MemAlignment - ? size_type(::boost::alignment_of< ::boost::detail::max_align>::value) - : size_type(MemAlignment) - ; - - private: - //Due to embedded bits in size, Alignment must be at least 4 - BOOST_STATIC_ASSERT((Alignment >= 4)); - //Due to rbtree size optimizations, Alignment must have at least pointer alignment - BOOST_STATIC_ASSERT((Alignment >= ::boost::alignment_of::value)); - static const size_type AlignmentMask = (Alignment - 1); - static const size_type BlockCtrlBytes = ipcdetail::ct_rounded_size::value; - static const size_type BlockCtrlUnits = BlockCtrlBytes/Alignment; - static const size_type AllocatedCtrlBytes = ipcdetail::ct_rounded_size::value; - static const size_type AllocatedCtrlUnits = AllocatedCtrlBytes/Alignment; - static const size_type EndCtrlBlockBytes = ipcdetail::ct_rounded_size::value; - static const size_type EndCtrlBlockUnits = EndCtrlBlockBytes/Alignment; - static const size_type MinBlockUnits = BlockCtrlUnits; - static const size_type UsableByPreviousChunk = sizeof(size_type); - - //Make sure the maximum alignment is power of two - BOOST_STATIC_ASSERT((0 == (Alignment & (Alignment - size_type(1u))))); - /// @endcond - public: - static const size_type PayloadPerAllocation = AllocatedCtrlBytes - UsableByPreviousChunk; -}; - -/// @cond - -template -inline typename rbtree_best_fit::size_type - rbtree_best_fit - ::priv_first_block_offset_from_this(const void *this_ptr, size_type extra_hdr_bytes) -{ - size_type uint_this = (std::size_t)this_ptr; - size_type main_hdr_end = uint_this + sizeof(rbtree_best_fit) + extra_hdr_bytes; - size_type aligned_main_hdr_end = ipcdetail::get_rounded_size(main_hdr_end, Alignment); - size_type block1_off = aligned_main_hdr_end - uint_this; - algo_impl_t::assert_alignment(aligned_main_hdr_end); - algo_impl_t::assert_alignment(uint_this + block1_off); - return block1_off; -} - -template -void rbtree_best_fit:: - priv_add_segment(void *addr, size_type segment_size) -{ - //Check alignment - algo_impl_t::check_alignment(addr); - //Check size - BOOST_ASSERT(segment_size >= (BlockCtrlBytes + EndCtrlBlockBytes)); - - //Initialize the first big block and the "end" node - block_ctrl *first_big_block = new(addr)block_ctrl; - first_big_block->m_size = segment_size/Alignment - EndCtrlBlockUnits; - BOOST_ASSERT(first_big_block->m_size >= BlockCtrlUnits); - - //The "end" node is just a node of size 0 with the "end" bit set - block_ctrl *end_block = static_cast - (new (reinterpret_cast(addr) + first_big_block->m_size*Alignment)SizeHolder); - - //This will overwrite the prev part of the "end" node - priv_mark_as_free_block (first_big_block); - #ifdef BOOST_INTERPROCESS_RBTREE_BEST_FIT_ABI_V1_HPP - first_big_block->m_prev_size = end_block->m_size = - (reinterpret_cast(first_big_block) - reinterpret_cast(end_block))/Alignment; - #else - first_big_block->m_prev_size = end_block->m_size = - (reinterpret_cast(end_block) - reinterpret_cast(first_big_block))/Alignment; - #endif - end_block->m_allocated = 1; - first_big_block->m_prev_allocated = 1; - - BOOST_ASSERT(priv_next_block(first_big_block) == end_block); - BOOST_ASSERT(priv_prev_block(end_block) == first_big_block); - BOOST_ASSERT(priv_first_block() == first_big_block); - BOOST_ASSERT(priv_end_block() == end_block); - - //Some check to validate the algorithm, since it makes some assumptions - //to optimize the space wasted in bookkeeping: - - //Check that the sizes of the header are placed before the rbtree - BOOST_ASSERT(static_cast(static_cast(first_big_block)) - < static_cast(static_cast(first_big_block))); - //Insert it in the intrusive containers - m_header.m_imultiset.insert(*first_big_block); -} - -template -inline typename rbtree_best_fit::block_ctrl * - rbtree_best_fit - ::priv_first_block() -{ - size_type block1_off = priv_first_block_offset_from_this(this, m_header.m_extra_hdr_bytes); - return reinterpret_cast(reinterpret_cast(this) + block1_off); -} - -template -inline typename rbtree_best_fit::block_ctrl * - rbtree_best_fit - ::priv_end_block() -{ - size_type block1_off = priv_first_block_offset_from_this(this, m_header.m_extra_hdr_bytes); - const size_type original_first_block_size = m_header.m_size/Alignment*Alignment - block1_off/Alignment*Alignment - EndCtrlBlockBytes; - block_ctrl *end_block = reinterpret_cast - (reinterpret_cast(this) + block1_off + original_first_block_size); - return end_block; -} - -template -inline rbtree_best_fit:: - rbtree_best_fit(size_type segment_size, size_type extra_hdr_bytes) -{ - //Initialize the header - m_header.m_allocated = 0; - m_header.m_size = segment_size; - m_header.m_extra_hdr_bytes = extra_hdr_bytes; - - //Now write calculate the offset of the first big block that will - //cover the whole segment - BOOST_ASSERT(get_min_size(extra_hdr_bytes) <= segment_size); - size_type block1_off = priv_first_block_offset_from_this(this, extra_hdr_bytes); - priv_add_segment(reinterpret_cast(this) + block1_off, segment_size - block1_off); -} - -template -inline rbtree_best_fit::~rbtree_best_fit() -{ - //There is a memory leak! -// BOOST_ASSERT(m_header.m_allocated == 0); -// BOOST_ASSERT(m_header.m_root.m_next->m_next == block_ctrl_ptr(&m_header.m_root)); -} - -template -void rbtree_best_fit::grow(size_type extra_size) -{ - //Get the address of the first block - block_ctrl *first_block = priv_first_block(); - block_ctrl *old_end_block = priv_end_block(); - size_type old_border_offset = (size_type)(reinterpret_cast(old_end_block) - - reinterpret_cast(this)) + EndCtrlBlockBytes; - - //Update managed buffer's size - m_header.m_size += extra_size; - - //We need at least MinBlockUnits blocks to create a new block - if((m_header.m_size - old_border_offset) < MinBlockUnits){ - return; - } - - //Now create a new block between the old end and the new end - size_type align_offset = (m_header.m_size - old_border_offset)/Alignment; - block_ctrl *new_end_block = reinterpret_cast - (reinterpret_cast(old_end_block) + align_offset*Alignment); - - //the last and first block are special: - //new_end_block->m_size & first_block->m_prev_size store the absolute value - //between them - new_end_block->m_allocated = 1; - #ifdef BOOST_INTERPROCESS_RBTREE_BEST_FIT_ABI_V1_HPP - new_end_block->m_size = (reinterpret_cast(first_block) - - reinterpret_cast(new_end_block))/Alignment; - #else - new_end_block->m_size = (reinterpret_cast(new_end_block) - - reinterpret_cast(first_block))/Alignment; - #endif - first_block->m_prev_size = new_end_block->m_size; - first_block->m_prev_allocated = 1; - BOOST_ASSERT(new_end_block == priv_end_block()); - - //The old end block is the new block - block_ctrl *new_block = old_end_block; - new_block->m_size = (reinterpret_cast(new_end_block) - - reinterpret_cast(new_block))/Alignment; - BOOST_ASSERT(new_block->m_size >= BlockCtrlUnits); - priv_mark_as_allocated_block(new_block); - BOOST_ASSERT(priv_next_block(new_block) == new_end_block); - - m_header.m_allocated += (size_type)new_block->m_size*Alignment; - - //Now deallocate the newly created block - this->priv_deallocate(priv_get_user_buffer(new_block)); -} - -template -void rbtree_best_fit::shrink_to_fit() -{ - //Get the address of the first block - block_ctrl *first_block = priv_first_block(); - algo_impl_t::assert_alignment(first_block); - - //block_ctrl *old_end_block = priv_end_block(first_block); - block_ctrl *old_end_block = priv_end_block(); - algo_impl_t::assert_alignment(old_end_block); - size_type old_end_block_size = old_end_block->m_size; - - void *unique_buffer = 0; - block_ctrl *last_block; - //Check if no memory is allocated between the first and last block - if(priv_next_block(first_block) == old_end_block){ - //If so check if we can allocate memory - size_type ignore; - unique_buffer = priv_allocate(boost::interprocess::allocate_new, 0, 0, ignore).first; - //If not, return, we can't shrink - if(!unique_buffer) - return; - //If we can, mark the position just after the new allocation as the new end - algo_impl_t::assert_alignment(unique_buffer); - block_ctrl *unique_block = priv_get_block(unique_buffer); - BOOST_ASSERT(priv_is_allocated_block(unique_block)); - algo_impl_t::assert_alignment(unique_block); - last_block = priv_next_block(unique_block); - BOOST_ASSERT(!priv_is_allocated_block(last_block)); - algo_impl_t::assert_alignment(last_block); - } - else{ - //If memory is allocated, check if the last block is allocated - if(priv_is_prev_allocated(old_end_block)) - return; - //If not, mark last block after the free block - last_block = priv_prev_block(old_end_block); - } - - size_type last_block_size = last_block->m_size; - - //Erase block from the free tree, since we will erase it - m_header.m_imultiset.erase(Imultiset::s_iterator_to(*last_block)); - - size_type shrunk_border_offset = (size_type)(reinterpret_cast(last_block) - - reinterpret_cast(this)) + EndCtrlBlockBytes; - - block_ctrl *new_end_block = last_block; - algo_impl_t::assert_alignment(new_end_block); - - //Write new end block attributes - #ifdef BOOST_INTERPROCESS_RBTREE_BEST_FIT_ABI_V1_HPP - new_end_block->m_size = first_block->m_prev_size = - (reinterpret_cast(first_block) - reinterpret_cast(new_end_block))/Alignment; - #else - new_end_block->m_size = first_block->m_prev_size = - (reinterpret_cast(new_end_block) - reinterpret_cast(first_block))/Alignment; - #endif - - new_end_block->m_allocated = 1; - (void)last_block_size; - (void)old_end_block_size; - BOOST_ASSERT(new_end_block->m_size == (old_end_block_size - last_block_size)); - - //Update managed buffer's size - m_header.m_size = shrunk_border_offset; - BOOST_ASSERT(priv_end_block() == new_end_block); - if(unique_buffer) - priv_deallocate(unique_buffer); -} - -template -inline typename rbtree_best_fit::size_type -rbtree_best_fit::get_size() const -{ return m_header.m_size; } - -template -typename rbtree_best_fit::size_type -rbtree_best_fit::get_free_memory() const -{ - return m_header.m_size - m_header.m_allocated - - priv_first_block_offset_from_this(this, m_header.m_extra_hdr_bytes); -} - -template -typename rbtree_best_fit::size_type -rbtree_best_fit:: - get_min_size (size_type extra_hdr_bytes) -{ - return (algo_impl_t::ceil_units(sizeof(rbtree_best_fit)) + - algo_impl_t::ceil_units(extra_hdr_bytes) + - MinBlockUnits + EndCtrlBlockUnits)*Alignment; -} - -template -inline bool rbtree_best_fit:: - all_memory_deallocated() -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - size_type block1_off = - priv_first_block_offset_from_this(this, m_header.m_extra_hdr_bytes); - - return m_header.m_allocated == 0 && - m_header.m_imultiset.begin() != m_header.m_imultiset.end() && - (++m_header.m_imultiset.begin()) == m_header.m_imultiset.end() - && m_header.m_imultiset.begin()->m_size == - (m_header.m_size - block1_off - EndCtrlBlockBytes)/Alignment; -} - -template -bool rbtree_best_fit:: - check_sanity() -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - imultiset_iterator ib(m_header.m_imultiset.begin()), ie(m_header.m_imultiset.end()); - - size_type free_memory = 0; - - //Iterate through all blocks obtaining their size - for(; ib != ie; ++ib){ - free_memory += (size_type)ib->m_size*Alignment; - algo_impl_t::assert_alignment(&*ib); - if(!algo_impl_t::check_alignment(&*ib)) - return false; - } - - //Check allocated bytes are less than size - if(m_header.m_allocated > m_header.m_size){ - return false; - } - - size_type block1_off = - priv_first_block_offset_from_this(this, m_header.m_extra_hdr_bytes); - - //Check free bytes are less than size - if(free_memory > (m_header.m_size - block1_off)){ - return false; - } - return true; -} - -template -inline void* rbtree_best_fit:: - allocate(size_type nbytes) -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - size_type ignore; - void * ret = priv_allocate(boost::interprocess::allocate_new, nbytes, nbytes, ignore).first; - return ret; -} - -template -inline void* rbtree_best_fit:: - allocate_aligned(size_type nbytes, size_type alignment) -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - return algo_impl_t::allocate_aligned(this, nbytes, alignment); -} - -template -template -inline std::pair rbtree_best_fit:: - allocation_command (boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - T *reuse_ptr) -{ - std::pair ret = priv_allocation_command - (command, limit_size, preferred_size, received_size, static_cast(reuse_ptr), sizeof(T)); - - BOOST_ASSERT(0 == ((std::size_t)ret.first % ::boost::alignment_of::value)); - return std::pair(static_cast(ret.first), ret.second); -} - -template -inline std::pair rbtree_best_fit:: - raw_allocation_command (boost::interprocess::allocation_type command, size_type limit_objects, - size_type preferred_objects,size_type &received_objects, - void *reuse_ptr, size_type sizeof_object) -{ - if(!sizeof_object) - return std::pair(static_cast(0), false); - if(command & boost::interprocess::try_shrink_in_place){ - bool success = algo_impl_t::try_shrink - ( this, reuse_ptr, limit_objects*sizeof_object - , preferred_objects*sizeof_object, received_objects); - received_objects /= sizeof_object; - return std::pair ((success ? reuse_ptr : 0), true); - } - return priv_allocation_command - (command, limit_objects, preferred_objects, received_objects, reuse_ptr, sizeof_object); -} - - -template -inline std::pair rbtree_best_fit:: - priv_allocation_command (boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - void *reuse_ptr, size_type sizeof_object) -{ - std::pair ret; - size_type max_count = m_header.m_size/sizeof_object; - if(limit_size > max_count || preferred_size > max_count){ - ret.first = 0; return ret; - } - size_type l_size = limit_size*sizeof_object; - size_type p_size = preferred_size*sizeof_object; - size_type r_size; - { - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - ret = priv_allocate(command, l_size, p_size, r_size, reuse_ptr, sizeof_object); - } - received_size = r_size/sizeof_object; - return ret; -} - -template -typename rbtree_best_fit::size_type -rbtree_best_fit:: - size(const void *ptr) const -{ - //We need no synchronization since this block's size is not going - //to be modified by anyone else - //Obtain the real size of the block - return ((size_type)priv_get_block(ptr)->m_size - AllocatedCtrlUnits)*Alignment + UsableByPreviousChunk; -} - -template -inline void rbtree_best_fit::zero_free_memory() -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - imultiset_iterator ib(m_header.m_imultiset.begin()), ie(m_header.m_imultiset.end()); - - //Iterate through all blocks obtaining their size - while(ib != ie){ - //Just clear user the memory part reserved for the user - volatile char *ptr = reinterpret_cast(&*ib) + BlockCtrlBytes; - size_type s = (size_type)ib->m_size*Alignment - BlockCtrlBytes; - while(s--){ - *ptr++ = 0; - } - - //This surprisingly is optimized out by Visual C++ 7.1 in release mode! - //std::memset( reinterpret_cast(&*ib) + BlockCtrlBytes - // , 0 - // , ib->m_size*Alignment - BlockCtrlBytes); - ++ib; - } -} - -template -void* rbtree_best_fit:: - priv_expand_both_sides(boost::interprocess::allocation_type command - ,size_type min_size - ,size_type preferred_size - ,size_type &received_size - ,void *reuse_ptr - ,bool only_preferred_backwards - ,size_type backwards_multiple) -{ - algo_impl_t::assert_alignment(reuse_ptr); - if(command & boost::interprocess::expand_fwd){ - if(priv_expand(reuse_ptr, min_size, preferred_size, received_size)) - return reuse_ptr; - } - else{ - received_size = this->size(reuse_ptr); - if(received_size >= preferred_size || received_size >= min_size) - return reuse_ptr; - } - - if(backwards_multiple){ - BOOST_ASSERT(0 == (min_size % backwards_multiple)); - BOOST_ASSERT(0 == (preferred_size % backwards_multiple)); - } - - if(command & boost::interprocess::expand_bwd){ - //Obtain the real size of the block - block_ctrl *reuse = priv_get_block(reuse_ptr); - - //Sanity check - //BOOST_ASSERT(reuse->m_size == priv_tail_size(reuse)); - algo_impl_t::assert_alignment(reuse); - - block_ctrl *prev_block; - - //If the previous block is not free, there is nothing to do - if(priv_is_prev_allocated(reuse)){ - return 0; - } - - prev_block = priv_prev_block(reuse); - BOOST_ASSERT(!priv_is_allocated_block(prev_block)); - - //Some sanity checks - BOOST_ASSERT(prev_block->m_size == reuse->m_prev_size); - algo_impl_t::assert_alignment(prev_block); - - size_type needs_backwards_aligned; - size_type lcm; - if(!algo_impl_t::calculate_lcm_and_needs_backwards_lcmed - ( backwards_multiple - , received_size - , only_preferred_backwards ? preferred_size : min_size - , lcm, needs_backwards_aligned)){ - return 0; - } - - //Check if previous block has enough size - if(size_type(prev_block->m_size*Alignment) >= needs_backwards_aligned){ - //Now take all next space. This will succeed - if(command & boost::interprocess::expand_fwd){ - size_type received_size2; - if(!priv_expand(reuse_ptr, received_size, received_size, received_size2)){ - BOOST_ASSERT(0); - } - BOOST_ASSERT(received_size == received_size2); - } - //We need a minimum size to split the previous one - if(prev_block->m_size >= (needs_backwards_aligned/Alignment + BlockCtrlUnits)){ - block_ctrl *new_block = reinterpret_cast - (reinterpret_cast(reuse) - needs_backwards_aligned); - - //Free old previous buffer - new_block->m_size = - AllocatedCtrlUnits + (needs_backwards_aligned + (received_size - UsableByPreviousChunk))/Alignment; - BOOST_ASSERT(new_block->m_size >= BlockCtrlUnits); - priv_mark_as_allocated_block(new_block); - - prev_block->m_size = (reinterpret_cast(new_block) - - reinterpret_cast(prev_block))/Alignment; - BOOST_ASSERT(prev_block->m_size >= BlockCtrlUnits); - priv_mark_as_free_block(prev_block); - - //Update the old previous block in the free blocks tree - //If the new size fulfills tree invariants do nothing, - //otherwise erase() + insert() - { - imultiset_iterator prev_block_it(Imultiset::s_iterator_to(*prev_block)); - imultiset_iterator was_smaller_it(prev_block_it); - if(prev_block_it != m_header.m_imultiset.begin() && - (--(was_smaller_it = prev_block_it))->m_size > prev_block->m_size){ - m_header.m_imultiset.erase(prev_block_it); - m_header.m_imultiset.insert(m_header.m_imultiset.begin(), *prev_block); - } - } - - received_size = needs_backwards_aligned + received_size; - m_header.m_allocated += needs_backwards_aligned; - - //Check alignment - algo_impl_t::assert_alignment(new_block); - - //If the backwards expansion has remaining bytes in the - //first bytes, fill them with a pattern - void *p = priv_get_user_buffer(new_block); - void *user_ptr = reinterpret_cast(p); - BOOST_ASSERT((static_cast(reuse_ptr) - static_cast(user_ptr)) % backwards_multiple == 0); - algo_impl_t::assert_alignment(user_ptr); - return user_ptr; - } - //Check if there is no place to create a new block and - //the whole new block is multiple of the backwards expansion multiple - else if(prev_block->m_size >= needs_backwards_aligned/Alignment && - 0 == ((prev_block->m_size*Alignment) % lcm)) { - //Erase old previous block, since we will change it - m_header.m_imultiset.erase(Imultiset::s_iterator_to(*prev_block)); - - //Just merge the whole previous block - //prev_block->m_size*Alignment is multiple of lcm (and backwards_multiple) - received_size = received_size + (size_type)prev_block->m_size*Alignment; - - m_header.m_allocated += (size_type)prev_block->m_size*Alignment; - //Now update sizes - prev_block->m_size = prev_block->m_size + reuse->m_size; - BOOST_ASSERT(prev_block->m_size >= BlockCtrlUnits); - priv_mark_as_allocated_block(prev_block); - - //If the backwards expansion has remaining bytes in the - //first bytes, fill them with a pattern - void *user_ptr = priv_get_user_buffer(prev_block); - BOOST_ASSERT((static_cast(reuse_ptr) - static_cast(user_ptr)) % backwards_multiple == 0); - algo_impl_t::assert_alignment(user_ptr); - return user_ptr; - } - else{ - //Alignment issues - } - } - } - return 0; -} - -template -inline void rbtree_best_fit:: - deallocate_many(typename rbtree_best_fit::multiallocation_chain &chain) -{ - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - algo_impl_t::deallocate_many(this, chain); -} - -template -std::pair rbtree_best_fit:: - priv_allocate(boost::interprocess::allocation_type command - ,size_type limit_size - ,size_type preferred_size - ,size_type &received_size - ,void *reuse_ptr - ,size_type backwards_multiple) -{ - //Remove me. Forbid backwards allocation - //command &= (~boost::interprocess::expand_bwd); - - if(command & boost::interprocess::shrink_in_place){ - bool success = - algo_impl_t::shrink(this, reuse_ptr, limit_size, preferred_size, received_size); - return std::pair ((success ? reuse_ptr : 0), true); - } - - typedef std::pair return_type; - received_size = 0; - - if(limit_size > preferred_size) - return return_type(static_cast(0), false); - - //Number of units to request (including block_ctrl header) - size_type preferred_units = priv_get_total_units(preferred_size); - - //Number of units to request (including block_ctrl header) - size_type limit_units = priv_get_total_units(limit_size); - - //Expand in place - if(reuse_ptr && (command & (boost::interprocess::expand_fwd | boost::interprocess::expand_bwd))){ - void *ret = priv_expand_both_sides - (command, limit_size, preferred_size, received_size, reuse_ptr, true, backwards_multiple); - if(ret) - return return_type(ret, true); - } - - if(command & boost::interprocess::allocate_new){ - size_block_ctrl_compare comp; - imultiset_iterator it(m_header.m_imultiset.lower_bound(preferred_units, comp)); - - if(it != m_header.m_imultiset.end()){ - return return_type(this->priv_check_and_allocate - (preferred_units, ipcdetail::to_raw_pointer(&*it), received_size), false); - } - - if(it != m_header.m_imultiset.begin()&& - (--it)->m_size >= limit_units){ - return return_type(this->priv_check_and_allocate - (it->m_size, ipcdetail::to_raw_pointer(&*it), received_size), false); - } - } - - - //Now try to expand both sides with min size - if(reuse_ptr && (command & (boost::interprocess::expand_fwd | boost::interprocess::expand_bwd))){ - return return_type(priv_expand_both_sides - (command, limit_size, preferred_size, received_size, reuse_ptr, false, backwards_multiple), true); - } - - return return_type(static_cast(0), false); -} - -template -inline -typename rbtree_best_fit::block_ctrl * - rbtree_best_fit::priv_get_block(const void *ptr) -{ - return const_cast - (reinterpret_cast - (reinterpret_cast(ptr) - AllocatedCtrlBytes)); -} - -template -inline -void *rbtree_best_fit:: - priv_get_user_buffer(const typename rbtree_best_fit::block_ctrl *block) -{ return const_cast(reinterpret_cast(block) + AllocatedCtrlBytes); } - -template -inline typename rbtree_best_fit::size_type -rbtree_best_fit:: - priv_get_total_units(size_type userbytes) -{ - if(userbytes < UsableByPreviousChunk) - userbytes = UsableByPreviousChunk; - size_type units = ipcdetail::get_rounded_size(userbytes - UsableByPreviousChunk, Alignment)/Alignment + AllocatedCtrlUnits; - if(units < BlockCtrlUnits) units = BlockCtrlUnits; - return units; -} - -template -bool rbtree_best_fit:: - priv_expand (void *ptr - ,const size_type min_size - ,const size_type preferred_size - ,size_type &received_size) -{ - //Obtain the real size of the block - block_ctrl *block = priv_get_block(ptr); - size_type old_block_units = block->m_size; - - //The block must be marked as allocated and the sizes must be equal - BOOST_ASSERT(priv_is_allocated_block(block)); - //BOOST_ASSERT(old_block_units == priv_tail_size(block)); - - //Put this to a safe value - received_size = (old_block_units - AllocatedCtrlUnits)*Alignment + UsableByPreviousChunk; - if(received_size >= preferred_size || received_size >= min_size) - return true; - - //Now translate it to Alignment units - const size_type min_user_units = algo_impl_t::ceil_units(min_size - UsableByPreviousChunk); - const size_type preferred_user_units = algo_impl_t::ceil_units(preferred_size - UsableByPreviousChunk); - - //Some parameter checks - BOOST_ASSERT(min_user_units <= preferred_user_units); - - block_ctrl *next_block; - - if(priv_is_allocated_block(next_block = priv_next_block(block))){ - return received_size >= min_size ? true : false; - } - algo_impl_t::assert_alignment(next_block); - - //Is "block" + "next_block" big enough? - const size_type merged_units = old_block_units + (size_type)next_block->m_size; - - //Now get the expansion size - const size_type merged_user_units = merged_units - AllocatedCtrlUnits; - - if(merged_user_units < min_user_units){ - received_size = merged_units*Alignment - UsableByPreviousChunk; - return false; - } - - //Now get the maximum size the user can allocate - size_type intended_user_units = (merged_user_units < preferred_user_units) ? - merged_user_units : preferred_user_units; - - //These are total units of the merged block (supposing the next block can be split) - const size_type intended_units = AllocatedCtrlUnits + intended_user_units; - - //Check if we can split the next one in two parts - if((merged_units - intended_units) >= BlockCtrlUnits){ - //This block is bigger than needed, split it in - //two blocks, the first one will be merged and - //the second's size will be the remaining space - BOOST_ASSERT(next_block->m_size == priv_next_block(next_block)->m_prev_size); - const size_type rem_units = merged_units - intended_units; - - //Check if we we need to update the old next block in the free blocks tree - //If the new size fulfills tree invariants, we just need to replace the node - //(the block start has been displaced), otherwise erase() + insert(). - // - //This fixup must be done in two parts, because the new next block might - //overwrite the tree hook of the old next block. So we first erase the - //old if needed and we'll insert the new one after creating the new next - imultiset_iterator old_next_block_it(Imultiset::s_iterator_to(*next_block)); - const bool size_invariants_broken = - (next_block->m_size - rem_units ) < BlockCtrlUnits || - (old_next_block_it != m_header.m_imultiset.begin() && - (--imultiset_iterator(old_next_block_it))->m_size > rem_units); - if(size_invariants_broken){ - m_header.m_imultiset.erase(old_next_block_it); - } - //This is the remaining block - block_ctrl *rem_block = new(reinterpret_cast - (reinterpret_cast(block) + intended_units*Alignment))block_ctrl; - rem_block->m_size = rem_units; - algo_impl_t::assert_alignment(rem_block); - BOOST_ASSERT(rem_block->m_size >= BlockCtrlUnits); - priv_mark_as_free_block(rem_block); - - //Now the second part of the fixup - if(size_invariants_broken) - m_header.m_imultiset.insert(m_header.m_imultiset.begin(), *rem_block); - else - m_header.m_imultiset.replace_node(old_next_block_it, *rem_block); - - //Write the new length - block->m_size = intended_user_units + AllocatedCtrlUnits; - BOOST_ASSERT(block->m_size >= BlockCtrlUnits); - m_header.m_allocated += (intended_units - old_block_units)*Alignment; - } - //There is no free space to create a new node: just merge both blocks - else{ - //Now we have to update the data in the tree - m_header.m_imultiset.erase(Imultiset::s_iterator_to(*next_block)); - - //Write the new length - block->m_size = merged_units; - BOOST_ASSERT(block->m_size >= BlockCtrlUnits); - m_header.m_allocated += (merged_units - old_block_units)*Alignment; - } - priv_mark_as_allocated_block(block); - received_size = ((size_type)block->m_size - AllocatedCtrlUnits)*Alignment + UsableByPreviousChunk; - return true; -} - -template inline -typename rbtree_best_fit::block_ctrl * - rbtree_best_fit::priv_prev_block - (typename rbtree_best_fit::block_ctrl *ptr) -{ - BOOST_ASSERT(!ptr->m_prev_allocated); - return reinterpret_cast - (reinterpret_cast(ptr) - ptr->m_prev_size*Alignment); -} - - - -template inline -typename rbtree_best_fit::block_ctrl * - rbtree_best_fit::priv_end_block - (typename rbtree_best_fit::block_ctrl *first_segment_block) -{ - //The first block's logic is different from the rest of blocks: stores in m_prev_size the absolute - //distance with the end block - BOOST_ASSERT(first_segment_block->m_prev_allocated); - block_ctrl *end_block = reinterpret_cast - (reinterpret_cast(first_segment_block) + first_segment_block->m_prev_size*Alignment); - (void)end_block; - BOOST_ASSERT(end_block->m_allocated == 1); - BOOST_ASSERT(end_block->m_size == first_segment_block->m_prev_size); - BOOST_ASSERT(end_block > first_segment_block); - return end_block; -} - -template inline -typename rbtree_best_fit::block_ctrl * - rbtree_best_fit::priv_first_block - (typename rbtree_best_fit::block_ctrl *end_segment_block) -{ - //The first block's logic is different from the rest of blocks: stores in m_prev_size the absolute - //distance with the end block - BOOST_ASSERT(end_segment_block->m_allocated); - block_ctrl *first_block = reinterpret_cast - (reinterpret_cast(end_segment_block) - end_segment_block->m_size*Alignment); - (void)first_block; - BOOST_ASSERT(first_block->m_prev_allocated == 1); - BOOST_ASSERT(first_block->m_prev_size == end_segment_block->m_size); - BOOST_ASSERT(end_segment_block > first_block); - return first_block; -} - - -template inline -typename rbtree_best_fit::block_ctrl * - rbtree_best_fit::priv_next_block - (typename rbtree_best_fit::block_ctrl *ptr) -{ - return reinterpret_cast - (reinterpret_cast(ptr) + ptr->m_size*Alignment); -} - -template inline -bool rbtree_best_fit::priv_is_allocated_block - (typename rbtree_best_fit::block_ctrl *block) -{ - bool allocated = block->m_allocated != 0; - #ifndef NDEBUG - if(block != priv_end_block()){ - block_ctrl *next_block = reinterpret_cast - (reinterpret_cast(block) + block->m_size*Alignment); - bool next_block_prev_allocated = next_block->m_prev_allocated != 0; - (void)next_block_prev_allocated; - BOOST_ASSERT(allocated == next_block_prev_allocated); - } - else{ - block = block; - } - #endif - return allocated; -} - -template inline -bool rbtree_best_fit::priv_is_prev_allocated - (typename rbtree_best_fit::block_ctrl *block) -{ - if(block->m_prev_allocated){ - return true; - } - else{ - #ifndef NDEBUG - if(block != priv_first_block()){ - block_ctrl *prev = priv_prev_block(block); - (void)prev; - BOOST_ASSERT(!prev->m_allocated); - } - else{ - block = block; - } - #endif - return false; - } -} - -template inline -void rbtree_best_fit::priv_mark_as_allocated_block - (typename rbtree_best_fit::block_ctrl *block) -{ - block->m_allocated = 1; - reinterpret_cast - (reinterpret_cast(block)+ block->m_size*Alignment)->m_prev_allocated = 1; -} - -template inline -void rbtree_best_fit::priv_mark_as_free_block - (typename rbtree_best_fit::block_ctrl *block) -{ - block->m_allocated = 0; - block_ctrl *next_block = priv_next_block(block); - next_block->m_prev_allocated = 0; - next_block->m_prev_size = block->m_size; -} - -template inline -void* rbtree_best_fit::priv_check_and_allocate - (size_type nunits - ,typename rbtree_best_fit::block_ctrl* block - ,size_type &received_size) -{ - size_type upper_nunits = nunits + BlockCtrlUnits; - imultiset_iterator it_old = Imultiset::s_iterator_to(*block); - algo_impl_t::assert_alignment(block); - - if (block->m_size >= upper_nunits){ - //This block is bigger than needed, split it in - //two blocks, the first's size will be "units" and - //the second's size "block->m_size-units" - size_type block_old_size = block->m_size; - block->m_size = nunits; - BOOST_ASSERT(block->m_size >= BlockCtrlUnits); - - //This is the remaining block - block_ctrl *rem_block = new(reinterpret_cast - (reinterpret_cast(block) + Alignment*nunits))block_ctrl; - algo_impl_t::assert_alignment(rem_block); - rem_block->m_size = block_old_size - nunits; - BOOST_ASSERT(rem_block->m_size >= BlockCtrlUnits); - priv_mark_as_free_block(rem_block); - - imultiset_iterator it_hint; - if(it_old == m_header.m_imultiset.begin() - || (--imultiset_iterator(it_old))->m_size < rem_block->m_size){ - //option a: slow but secure - //m_header.m_imultiset.insert(m_header.m_imultiset.erase(it_old), *rem_block); - //option b: Construct an empty node and swap - //Imultiset::init_node(*rem_block); - //block->swap_nodes(*rem_block); - //option c: replace the node directly - m_header.m_imultiset.replace_node(Imultiset::s_iterator_to(*it_old), *rem_block); - } - else{ - //Now we have to update the data in the tree - m_header.m_imultiset.erase(it_old); - m_header.m_imultiset.insert(m_header.m_imultiset.begin(), *rem_block); - } - - } - else if (block->m_size >= nunits){ - m_header.m_imultiset.erase(it_old); - } - else{ - BOOST_ASSERT(0); - return 0; - } - //We need block_ctrl for deallocation stuff, so - //return memory user can overwrite - m_header.m_allocated += (size_type)block->m_size*Alignment; - received_size = ((size_type)block->m_size - AllocatedCtrlUnits)*Alignment + UsableByPreviousChunk; - - //Mark the block as allocated - priv_mark_as_allocated_block(block); - - //Clear the memory occupied by the tree hook, since this won't be - //cleared with zero_free_memory - TreeHook *t = static_cast(block); - //Just clear the memory part reserved for the user - std::size_t tree_hook_offset_in_block = (char*)t - (char*)block; - //volatile char *ptr = - char *ptr = reinterpret_cast(block)+tree_hook_offset_in_block; - const std::size_t s = BlockCtrlBytes - tree_hook_offset_in_block; - std::memset(ptr, 0, s); - this->priv_next_block(block)->m_prev_size = 0; - return priv_get_user_buffer(block); -} - -template -void rbtree_best_fit::deallocate(void* addr) -{ - if(!addr) return; - //----------------------- - boost::interprocess::scoped_lock guard(m_header); - //----------------------- - return this->priv_deallocate(addr); -} - -template -void rbtree_best_fit::priv_deallocate(void* addr) -{ - if(!addr) return; - - block_ctrl *block = priv_get_block(addr); - - //The blocks must be marked as allocated and the sizes must be equal - BOOST_ASSERT(priv_is_allocated_block(block)); -// BOOST_ASSERT(block->m_size == priv_tail_size(block)); - - //Check if alignment and block size are right - algo_impl_t::assert_alignment(addr); - - size_type block_old_size = Alignment*(size_type)block->m_size; - BOOST_ASSERT(m_header.m_allocated >= block_old_size); - - //Update used memory count - m_header.m_allocated -= block_old_size; - - //The block to insert in the tree - block_ctrl *block_to_insert = block; - - //Get the next block - block_ctrl *next_block = priv_next_block(block); - bool merge_with_prev = !priv_is_prev_allocated(block); - bool merge_with_next = !priv_is_allocated_block(next_block); - - //Merge logic. First just update block sizes, then fix free blocks tree - if(merge_with_prev || merge_with_next){ - //Merge if the previous is free - if(merge_with_prev){ - //Get the previous block - block_ctrl *prev_block = priv_prev_block(block); - prev_block->m_size += block->m_size; - BOOST_ASSERT(prev_block->m_size >= BlockCtrlUnits); - block_to_insert = prev_block; - } - //Merge if the next is free - if(merge_with_next){ - block_to_insert->m_size += next_block->m_size; - BOOST_ASSERT(block_to_insert->m_size >= BlockCtrlUnits); - if(merge_with_prev) - m_header.m_imultiset.erase(Imultiset::s_iterator_to(*next_block)); - } - - bool only_merge_next = !merge_with_prev && merge_with_next; - imultiset_iterator free_block_to_check_it - (Imultiset::s_iterator_to(only_merge_next ? *next_block : *block_to_insert)); - imultiset_iterator was_bigger_it(free_block_to_check_it); - - //Now try to shortcut erasure + insertion (O(log(N))) with - //a O(1) operation if merging does not alter tree positions - if(++was_bigger_it != m_header.m_imultiset.end() && - block_to_insert->m_size > was_bigger_it->m_size ){ - m_header.m_imultiset.erase(free_block_to_check_it); - m_header.m_imultiset.insert(m_header.m_imultiset.begin(), *block_to_insert); - } - else if(only_merge_next){ - m_header.m_imultiset.replace_node(free_block_to_check_it, *block_to_insert); - } - } - else{ - m_header.m_imultiset.insert(m_header.m_imultiset.begin(), *block_to_insert); - } - priv_mark_as_free_block(block_to_insert); -} - -/// @endcond - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_MEM_ALGO_RBTREE_BEST_FIT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/offset_ptr.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/offset_ptr.hpp deleted file mode 100644 index 508946f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/offset_ptr.hpp +++ /dev/null @@ -1,731 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_OFFSET_PTR_HPP -#define BOOST_INTERPROCESS_OFFSET_PTR_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -//!\file -//!Describes a smart pointer that stores the offset between this pointer and -//!target pointee, called offset_ptr. - -namespace boost { - -//Predeclarations -template -struct has_trivial_constructor; - -template -struct has_trivial_destructor; - -namespace interprocess { - -/// @cond -namespace ipcdetail { - - template - union offset_ptr_internal - { - explicit offset_ptr_internal(OffsetType off) - : m_offset(off) - {} - OffsetType m_offset; //Distance between this object and pointee address - typename ::boost::aligned_storage - < sizeof(OffsetType) - , (OffsetAlignment == offset_type_alignment) ? - ::boost::alignment_of::value : OffsetAlignment - >::type alignment_helper; - }; - - //Note: using the address of a local variable to point to another address - //is not standard conforming and this can be optimized-away by the compiler. - //Non-inlining is a method to remain illegal but correct - - //Undef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_XXX if your compiler can inline - //this code without breaking the library - - //////////////////////////////////////////////////////////////////////// - // - // offset_ptr_to_raw_pointer - // - //////////////////////////////////////////////////////////////////////// - #define BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_PTR - #define BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_PTR - - template - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_PTR - BOOST_INTERPROCESS_NEVER_INLINE - #elif defined(NDEBUG) - inline - #endif - void * offset_ptr_to_raw_pointer(const volatile void *this_ptr, std::size_t offset) - { - typedef pointer_size_t_caster caster_t; - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_PTR - if(offset == 1){ - return 0; - } - else{ - const caster_t caster((void*)this_ptr); - return caster_t(caster.size() + offset).pointer(); - } - #else - const caster_t caster((void*)this_ptr); - return caster_t((caster.size() + offset) & -std::size_t(offset != 1)).pointer(); - #endif - } - - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_PTR - #undef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_PTR - #endif - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_PTR - #undef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_PTR - #endif - - //////////////////////////////////////////////////////////////////////// - // - // offset_ptr_to_offset - // - //////////////////////////////////////////////////////////////////////// - #define BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF - //Branchless seems slower in x86 - #define BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF - - template - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF - BOOST_INTERPROCESS_NEVER_INLINE - #elif defined(NDEBUG) - inline - #endif - std::size_t offset_ptr_to_offset(const volatile void *ptr, const volatile void *this_ptr) - { - typedef pointer_size_t_caster caster_t; - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF - //offset == 1 && ptr != 0 is not legal for this pointer - if(!ptr){ - return 1; - } - else{ - const caster_t this_caster((void*)this_ptr); - const caster_t ptr_caster((void*)ptr); - std::size_t offset = ptr_caster.size() - this_caster.size(); - BOOST_ASSERT(offset != 1); - return offset; - } - #else - const caster_t this_caster((void*)this_ptr); - const caster_t ptr_caster((void*)ptr); - //std::size_t other = -std::size_t(ptr != 0); - //std::size_t offset = (ptr_caster.size() - this_caster.size()) & other; - //return offset + !other; - // - std::size_t offset = (ptr_caster.size() - this_caster.size() - 1) & -std::size_t(ptr != 0); - return ++offset; - #endif - } - - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF - #undef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF - #endif - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF - #undef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF - #endif - - //////////////////////////////////////////////////////////////////////// - // - // offset_ptr_to_offset_from_other - // - //////////////////////////////////////////////////////////////////////// - #define BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF_FROM_OTHER - //Branchless seems slower in x86 - #define BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF_FROM_OTHER - - template - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF_FROM_OTHER - BOOST_INTERPROCESS_NEVER_INLINE - #elif defined(NDEBUG) - inline - #endif - std::size_t offset_ptr_to_offset_from_other - (const volatile void *this_ptr, const volatile void *other_ptr, std::size_t other_offset) - { - typedef pointer_size_t_caster caster_t; - #ifndef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF_FROM_OTHER - if(other_offset == 1){ - return 1; - } - else{ - const caster_t this_caster((void*)this_ptr); - const caster_t other_caster((void*)other_ptr); - std::size_t offset = other_caster.size() - this_caster.size() + other_offset; - BOOST_ASSERT(offset != 1); - return offset; - } - #else - const caster_t this_caster((void*)this_ptr); - const caster_t other_caster((void*)other_ptr); - return ((other_caster.size() - this_caster.size()) & -std::size_t(other_offset != 1)) + other_offset; - #endif - } - - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF_FROM_OTHER - #undef BOOST_INTERPROCESS_OFFSET_PTR_INLINE_TO_OFF_FROM_OTHER - #endif - #ifdef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF_FROM_OTHER - #undef BOOST_INTERPROCESS_OFFSET_PTR_BRANCHLESS_TO_OFF_FROM_OTHER - #endif - - //////////////////////////////////////////////////////////////////////// - // - // Let's assume cast to void and cv cast don't change any target address - // - //////////////////////////////////////////////////////////////////////// - template - struct offset_ptr_maintains_address - { - static const bool value = ipcdetail::is_cv_same::value - || ipcdetail::is_cv_same::value; - }; - -} //namespace ipcdetail { -/// @endcond - -//!A smart pointer that stores the offset between between the pointer and the -//!the object it points. This allows offset allows special properties, since -//!the pointer is independent from the address address of the pointee, if the -//!pointer and the pointee are still separated by the same offset. This feature -//!converts offset_ptr in a smart pointer that can be placed in shared memory and -//!memory mapped files mapped in different addresses in every process. -template -class offset_ptr -{ - /// @cond - typedef offset_ptr self_t; - void unspecified_bool_type_func() const {} - typedef void (self_t::*unspecified_bool_type)() const; - /// @endcond - - public: - typedef PointedType element_type; - typedef PointedType * pointer; - typedef typename ipcdetail:: - add_reference::type reference; - typedef typename ipcdetail:: - remove_volatile::type - >::type value_type; - typedef DifferenceType difference_type; - typedef std::random_access_iterator_tag iterator_category; - typedef OffsetType offset_type; - - public: //Public Functions - - //!Default constructor (null pointer). - //!Never throws. - offset_ptr() - : internal(1) - {} - - //!Constructor from raw pointer (allows "0" pointer conversion). - //!Never throws. - offset_ptr(pointer ptr) - : internal(static_cast(ipcdetail::offset_ptr_to_offset<0>(ptr, this))) - {} - - //!Constructor from other pointer. - //!Never throws. - template - offset_ptr( T *ptr - , typename ipcdetail::enable_if< ipcdetail::is_convertible >::type * = 0) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(static_cast(ptr), this))) - {} - - //!Constructor from other offset_ptr - //!Never throws. - offset_ptr(const offset_ptr& ptr) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset_from_other<0>(this, &ptr, ptr.internal.m_offset))) - {} - - //!Constructor from other offset_ptr. If pointers of pointee types are - //!convertible, offset_ptrs will be convertibles. Never throws. - template - offset_ptr( const offset_ptr &ptr - #ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED - , typename ipcdetail::enable_if_c< ipcdetail::is_convertible::value - && ipcdetail::offset_ptr_maintains_address::value - >::type * = 0 - #endif - ) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset_from_other<0>(this, &ptr, ptr.get_offset()))) - {} - - #ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED - - //!Constructor from other offset_ptr. If pointers of pointee types are - //!convertible, offset_ptrs will be convertibles. Never throws. - template - offset_ptr( const offset_ptr &ptr - , typename ipcdetail::enable_if_c< ipcdetail::is_convertible::value - && !ipcdetail::offset_ptr_maintains_address::value - >::type * = 0) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(static_cast(ptr.get()), this))) - {} - - #endif - - //!Emulates static_cast operator. - //!Never throws. - template - offset_ptr(const offset_ptr & r, ipcdetail::static_cast_tag) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(static_cast(r.get()), this))) - {} - - //!Emulates const_cast operator. - //!Never throws. - template - offset_ptr(const offset_ptr & r, ipcdetail::const_cast_tag) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(const_cast(r.get()), this))) - {} - - //!Emulates dynamic_cast operator. - //!Never throws. - template - offset_ptr(const offset_ptr & r, ipcdetail::dynamic_cast_tag) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(dynamic_cast(r.get()), this))) - {} - - //!Emulates reinterpret_cast operator. - //!Never throws. - template - offset_ptr(const offset_ptr & r, ipcdetail::reinterpret_cast_tag) - : internal(static_cast - (ipcdetail::offset_ptr_to_offset<0>(reinterpret_cast(r.get()), this))) - {} - - //!Obtains raw pointer from offset. - //!Never throws. - pointer get() const - { return (pointer)ipcdetail::offset_ptr_to_raw_pointer<0>(this, this->internal.m_offset); } - - offset_type get_offset() const - { return this->internal.m_offset; } - - //!Pointer-like -> operator. It can return 0 pointer. - //!Never throws. - pointer operator->() const - { return this->get(); } - - //!Dereferencing operator, if it is a null offset_ptr behavior - //! is undefined. Never throws. - reference operator* () const - { - pointer p = this->get(); - reference r = *p; - return r; - } - - //!Indexing operator. - //!Never throws. - reference operator[](difference_type idx) const - { return this->get()[idx]; } - - //!Assignment from pointer (saves extra conversion). - //!Never throws. - offset_ptr& operator= (pointer from) - { - this->internal.m_offset = - static_cast(ipcdetail::offset_ptr_to_offset<0>(from, this)); - return *this; - } - - //!Assignment from other offset_ptr. - //!Never throws. - offset_ptr& operator= (const offset_ptr & ptr) - { - this->internal.m_offset = - static_cast(ipcdetail::offset_ptr_to_offset_from_other<0>(this, &ptr, ptr.internal.m_offset)); - return *this; - } - - //!Assignment from related offset_ptr. If pointers of pointee types - //! are assignable, offset_ptrs will be assignable. Never throws. - template - #ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED - typename ipcdetail::enable_if_c< ipcdetail::is_convertible::value - && ipcdetail::offset_ptr_maintains_address::value - , offset_ptr&>::type - #else - offset_ptr& - #endif - operator= (const offset_ptr &ptr) - { - this->internal.m_offset = - static_cast(ipcdetail::offset_ptr_to_offset_from_other<0>(this, &ptr, ptr.get_offset())); - return *this; - } - - #ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED - template - typename ipcdetail::enable_if_c::value - && !ipcdetail::offset_ptr_maintains_address::value - , offset_ptr&>::type - operator= (const offset_ptr &ptr) - { - this->internal.m_offset = - static_cast(ipcdetail::offset_ptr_to_offset<0>(static_cast(ptr.get()), this)); - return *this; - } - #endif - - //!offset_ptr += difference_type. - //!Never throws. - offset_ptr &operator+= (difference_type offset) - { this->inc_offset(offset * sizeof (PointedType)); return *this; } - - //!offset_ptr -= difference_type. - //!Never throws. - offset_ptr &operator-= (difference_type offset) - { this->dec_offset(offset * sizeof (PointedType)); return *this; } - - //!++offset_ptr. - //!Never throws. - offset_ptr& operator++ (void) - { this->inc_offset(sizeof (PointedType)); return *this; } - - //!offset_ptr++. - //!Never throws. - offset_ptr operator++ (int) - { - offset_ptr tmp(*this); - this->inc_offset(sizeof (PointedType)); - return tmp; - } - - //!--offset_ptr. - //!Never throws. - offset_ptr& operator-- (void) - { this->dec_offset(sizeof (PointedType)); return *this; } - - //!offset_ptr--. - //!Never throws. - offset_ptr operator-- (int) - { - offset_ptr tmp(*this); - this->dec_offset(sizeof (PointedType)); - return tmp; - } - - //!safe bool conversion operator. - //!Never throws. - operator unspecified_bool_type() const - { return this->internal.m_offset != 1? &self_t::unspecified_bool_type_func : 0; } - - //!Not operator. Not needed in theory, but improves portability. - //!Never throws - bool operator! () const - { return this->internal.m_offset == 1; } - - //!Compatibility with pointer_traits - //! - template - struct rebind - { typedef offset_ptr other; }; - - //!Compatibility with pointer_traits - //! - static offset_ptr pointer_to(reference r) - { return offset_ptr(&r); } - - //!difference_type + offset_ptr - //!operation - friend offset_ptr operator+(difference_type diff, offset_ptr right) - { right += diff; return right; } - - //!offset_ptr + difference_type - //!operation - friend offset_ptr operator+(offset_ptr left, difference_type diff) - { left += diff; return left; } - - //!offset_ptr - diff - //!operation - friend offset_ptr operator-(offset_ptr left, difference_type diff) - { left -= diff; return left; } - - //!offset_ptr - diff - //!operation - friend offset_ptr operator-(difference_type diff, offset_ptr right) - { right -= diff; return right; } - - //!offset_ptr - offset_ptr - //!operation - friend difference_type operator-(const offset_ptr &pt, const offset_ptr &pt2) - { return difference_type(pt.get()- pt2.get()); } - - //Comparison - friend bool operator== (const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() == pt2.get(); } - - friend bool operator!= (const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() != pt2.get(); } - - friend bool operator<(const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() < pt2.get(); } - - friend bool operator<=(const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() <= pt2.get(); } - - friend bool operator>(const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() > pt2.get(); } - - friend bool operator>=(const offset_ptr &pt1, const offset_ptr &pt2) - { return pt1.get() >= pt2.get(); } - - //Comparison to raw ptr to support literal 0 - friend bool operator== (pointer pt1, const offset_ptr &pt2) - { return pt1 == pt2.get(); } - - friend bool operator!= (pointer pt1, const offset_ptr &pt2) - { return pt1 != pt2.get(); } - - friend bool operator<(pointer pt1, const offset_ptr &pt2) - { return pt1 < pt2.get(); } - - friend bool operator<=(pointer pt1, const offset_ptr &pt2) - { return pt1 <= pt2.get(); } - - friend bool operator>(pointer pt1, const offset_ptr &pt2) - { return pt1 > pt2.get(); } - - friend bool operator>=(pointer pt1, const offset_ptr &pt2) - { return pt1 >= pt2.get(); } - - //Comparison - friend bool operator== (const offset_ptr &pt1, pointer pt2) - { return pt1.get() == pt2; } - - friend bool operator!= (const offset_ptr &pt1, pointer pt2) - { return pt1.get() != pt2; } - - friend bool operator<(const offset_ptr &pt1, pointer pt2) - { return pt1.get() < pt2; } - - friend bool operator<=(const offset_ptr &pt1, pointer pt2) - { return pt1.get() <= pt2; } - - friend bool operator>(const offset_ptr &pt1, pointer pt2) - { return pt1.get() > pt2; } - - friend bool operator>=(const offset_ptr &pt1, pointer pt2) - { return pt1.get() >= pt2; } - - friend void swap(offset_ptr &left, offset_ptr &right) - { - pointer ptr = right.get(); - right = left; - left = ptr; - } - - private: - /// @cond - void inc_offset(DifferenceType bytes) - { internal.m_offset += bytes; } - - void dec_offset(DifferenceType bytes) - { internal.m_offset -= bytes; } - - ipcdetail::offset_ptr_internal internal; - /// @endcond -}; - -//!operator<< -//!for offset ptr -template -inline std::basic_ostream & operator<< - (std::basic_ostream & os, offset_ptr const & p) -{ return os << p.get_offset(); } - -//!operator>> -//!for offset ptr -template -inline std::basic_istream & operator>> - (std::basic_istream & is, offset_ptr & p) -{ return is >> p.get_offset(); } - -//!Simulation of static_cast between pointers. Never throws. -template -inline boost::interprocess::offset_ptr - static_pointer_cast(const boost::interprocess::offset_ptr & r) -{ - return boost::interprocess::offset_ptr - (r, boost::interprocess::ipcdetail::static_cast_tag()); -} - -//!Simulation of const_cast between pointers. Never throws. -template -inline boost::interprocess::offset_ptr - const_pointer_cast(const boost::interprocess::offset_ptr & r) -{ - return boost::interprocess::offset_ptr - (r, boost::interprocess::ipcdetail::const_cast_tag()); -} - -//!Simulation of dynamic_cast between pointers. Never throws. -template -inline boost::interprocess::offset_ptr - dynamic_pointer_cast(const boost::interprocess::offset_ptr & r) -{ - return boost::interprocess::offset_ptr - (r, boost::interprocess::ipcdetail::dynamic_cast_tag()); -} - -//!Simulation of reinterpret_cast between pointers. Never throws. -template -inline boost::interprocess::offset_ptr - reinterpret_pointer_cast(const boost::interprocess::offset_ptr & r) -{ - return boost::interprocess::offset_ptr - (r, boost::interprocess::ipcdetail::reinterpret_cast_tag()); -} - -} //namespace interprocess { - -/// @cond - -//!has_trivial_constructor<> == true_type specialization for optimizations -template -struct has_trivial_constructor< boost::interprocess::offset_ptr > -{ - static const bool value = true; -}; - -///has_trivial_destructor<> == true_type specialization for optimizations -template -struct has_trivial_destructor< boost::interprocess::offset_ptr > -{ - static const bool value = true; -}; - - -namespace interprocess { - -//!to_raw_pointer() enables boost::mem_fn to recognize offset_ptr. -//!Never throws. -template -inline T * to_raw_pointer(boost::interprocess::offset_ptr const & p) -{ return ipcdetail::to_raw_pointer(p); } - -} //namespace interprocess - - -/// @endcond -} //namespace boost { - -/// @cond - -namespace boost{ - -//This is to support embedding a bit in the pointer -//for intrusive containers, saving space -namespace intrusive { - -//Predeclaration to avoid including header -template -struct max_pointer_plus_bits; - -template -struct max_pointer_plus_bits, OffsetAlignment> -{ - //The offset ptr can embed one bit less than the alignment since it - //uses offset == 1 to store the null pointer. - static const std::size_t value = ::boost::interprocess::ipcdetail::ls_zeros::value - 1; -}; - -//Predeclaration -template -struct pointer_plus_bits; - -template -struct pointer_plus_bits, NumBits> -{ - typedef boost::interprocess::offset_ptr pointer; - typedef ::boost::interprocess::pointer_size_t_caster caster_t; - //Bits are stored in the lower bits of the pointer except the LSB, - //because this bit is used to represent the null pointer. - static const std::size_t Mask = ((std::size_t(1) << NumBits) - 1) << 1u; - - static pointer get_pointer(const pointer &n) - { - caster_t caster(n.get()); - return pointer(caster_t(caster.size() & ~Mask).pointer()); - } - - static void set_pointer(pointer &n, const pointer &p) - { - caster_t n_caster(n.get()); - caster_t p_caster(p.get()); - BOOST_ASSERT(0 == (p_caster.size() & Mask)); - n = caster_t(p_caster.size() | (n_caster.size() & Mask)).pointer(); - } - - static std::size_t get_bits(const pointer &n) - { return (caster_t(n.get()).size() & Mask) >> 1u; } - - static void set_bits(pointer &n, std::size_t b) - { - BOOST_ASSERT(b < (std::size_t(1) << NumBits)); - caster_t n_caster(n.get()); - n = caster_t((n_caster.size() & ~Mask) | (b << 1u)).pointer(); - } -}; - -} //namespace intrusive - -//Predeclaration -template -struct pointer_to_other; - -//Backwards compatibility with pointer_to_other -template -struct pointer_to_other - < ::boost::interprocess::offset_ptr, U > -{ - typedef ::boost::interprocess::offset_ptr type; -}; - -} //namespace boost{ -/// @endcond - -#include - -#endif //#ifndef BOOST_INTERPROCESS_OFFSET_PTR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/permissions.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/permissions.hpp deleted file mode 100644 index 4266b24a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/permissions.hpp +++ /dev/null @@ -1,132 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_PERMISSIONS_HPP -#define BOOST_INTERPROCESS_PERMISSIONS_HPP - -/// @cond - -#if defined (_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include - -#if defined(BOOST_INTERPROCESS_WINDOWS) - -#include - -#endif - -/// @endcond - -//!\file -//!Describes permissions class - -namespace boost { -namespace interprocess { - -/// @cond - -#if defined(BOOST_INTERPROCESS_WINDOWS) - -namespace ipcdetail { - -template -struct unrestricted_permissions_holder -{ - static winapi::interprocess_all_access_security unrestricted; -}; - -template -winapi::interprocess_all_access_security unrestricted_permissions_holder::unrestricted; - -} //namespace ipcdetail { - -#endif //defined BOOST_INTERPROCESS_WINDOWS - -/// @endcond - -//!The permissions class represents permissions to be set to shared memory or -//!files, that can be constructed form usual permission representations: -//!a SECURITY_ATTRIBUTES pointer in windows or ORed rwx chmod integer in UNIX. -class permissions -{ - /// @cond - - #if defined(BOOST_INTERPROCESS_WINDOWS) - typedef void* os_permissions_type; - #else - typedef int os_permissions_type; - #endif - os_permissions_type m_perm; - - /// @endcond - - public: - //!Constructs a permissions object from a user provided os-dependent - //!permissions. - permissions(os_permissions_type type) - : m_perm(type) - {} - - //!Constructs a default permissions object: - //!A null security attributes pointer for windows or 0644 - //!for UNIX. - permissions() - { set_default(); } - - //!Sets permissions to default values: - //!A null security attributes pointer for windows or 0644 - //!for UNIX. - void set_default() - { - /// @cond - #if defined (BOOST_INTERPROCESS_WINDOWS) - m_perm = 0; - #else - m_perm = 0644; - #endif - /// @endcond - } - - //!Sets permissions to unrestricted access: - //!A null DACL for windows or 0666 for UNIX. - void set_unrestricted() - { - /// @cond - #if defined (BOOST_INTERPROCESS_WINDOWS) - m_perm = &ipcdetail::unrestricted_permissions_holder<0>::unrestricted; - #else - m_perm = 0666; - #endif - /// @endcond - } - - //!Sets permissions from a user provided os-dependent - //!permissions. - void set_permissions(os_permissions_type perm) - { m_perm = perm; } - - //!Returns stored os-dependent - //!permissions - os_permissions_type get_permissions() const - { return m_perm; } -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_PERMISSIONS_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/segment_manager.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/segment_manager.hpp deleted file mode 100644 index 9113acba..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/segment_manager.hpp +++ /dev/null @@ -1,1364 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_SEGMENT_MANAGER_HPP -#define BOOST_INTERPROCESS_SEGMENT_MANAGER_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include //std::size_t -#include //char_traits -#include //std::nothrow -#include //std::pair -#include -#ifndef BOOST_NO_EXCEPTIONS -#include -#endif - -//!\file -//!Describes the object placed in a memory segment that provides -//!named object allocation capabilities for single-segment and -//!multi-segment allocations. - -namespace boost{ -namespace interprocess{ - -//!This object is the public base class of segment manager. -//!This class only depends on the memory allocation algorithm -//!and implements all the allocation features not related -//!to named or unique objects. -//! -//!Storing a reference to segment_manager forces -//!the holder class to be dependent on index types and character types. -//!When such dependence is not desirable and only anonymous and raw -//!allocations are needed, segment_manager_base is the correct answer. -template -class segment_manager_base - : private MemoryAlgorithm -{ - public: - typedef segment_manager_base segment_manager_base_type; - typedef typename MemoryAlgorithm::void_pointer void_pointer; - typedef typename MemoryAlgorithm::mutex_family mutex_family; - typedef MemoryAlgorithm memory_algorithm; - - /// @cond - - //Experimental. Don't use - typedef typename MemoryAlgorithm::multiallocation_chain multiallocation_chain; - typedef typename MemoryAlgorithm::difference_type difference_type; - typedef typename MemoryAlgorithm::size_type size_type; - - /// @endcond - - //!This constant indicates the payload size - //!associated with each allocation of the memory algorithm - static const size_type PayloadPerAllocation = MemoryAlgorithm::PayloadPerAllocation; - - //!Constructor of the segment_manager_base - //! - //!"size" is the size of the memory segment where - //!the basic segment manager is being constructed. - //! - //!"reserved_bytes" is the number of bytes - //!after the end of the memory algorithm object itself - //!that the memory algorithm will exclude from - //!dynamic allocation - //! - //!Can throw - segment_manager_base(size_type sz, size_type reserved_bytes) - : MemoryAlgorithm(sz, reserved_bytes) - { - BOOST_ASSERT((sizeof(segment_manager_base) == sizeof(MemoryAlgorithm))); - } - - //!Returns the size of the memory - //!segment - size_type get_size() const - { return MemoryAlgorithm::get_size(); } - - //!Returns the number of free bytes of the memory - //!segment - size_type get_free_memory() const - { return MemoryAlgorithm::get_free_memory(); } - - //!Obtains the minimum size needed by - //!the segment manager - static size_type get_min_size (size_type size) - { return MemoryAlgorithm::get_min_size(size); } - - //!Allocates nbytes bytes. This function is only used in - //!single-segment management. Never throws - void * allocate (size_type nbytes, std::nothrow_t) - { return MemoryAlgorithm::allocate(nbytes); } - - /// @cond - - //Experimental. Dont' use. - //!Allocates n_elements of elem_bytes bytes. - //!Throws bad_alloc on failure. chain.size() is not increased on failure. - void allocate_many(size_type elem_bytes, size_type n_elements, multiallocation_chain &chain) - { - size_type prev_size = chain.size(); - MemoryAlgorithm::allocate_many(elem_bytes, n_elements, chain); - if(!elem_bytes || chain.size() == prev_size){ - throw bad_alloc(); - } - } - - //!Allocates n_elements, each one of element_lengths[i]*sizeof_element bytes. - //!Throws bad_alloc on failure. chain.size() is not increased on failure. - void allocate_many(const size_type *element_lengths, size_type n_elements, size_type sizeof_element, multiallocation_chain &chain) - { - size_type prev_size = chain.size(); - MemoryAlgorithm::allocate_many(element_lengths, n_elements, sizeof_element, chain); - if(!sizeof_element || chain.size() == prev_size){ - throw bad_alloc(); - } - } - - //!Allocates n_elements of elem_bytes bytes. - //!Non-throwing version. chain.size() is not increased on failure. - void allocate_many(std::nothrow_t, size_type elem_bytes, size_type n_elements, multiallocation_chain &chain) - { MemoryAlgorithm::allocate_many(elem_bytes, n_elements, chain); } - - //!Allocates n_elements, each one of - //!element_lengths[i]*sizeof_element bytes. - //!Non-throwing version. chain.size() is not increased on failure. - void allocate_many(std::nothrow_t, const size_type *elem_sizes, size_type n_elements, size_type sizeof_element, multiallocation_chain &chain) - { MemoryAlgorithm::allocate_many(elem_sizes, n_elements, sizeof_element, chain); } - - //!Deallocates all elements contained in chain. - //!Never throws. - void deallocate_many(multiallocation_chain &chain) - { MemoryAlgorithm::deallocate_many(chain); } - - /// @endcond - - //!Allocates nbytes bytes. Throws boost::interprocess::bad_alloc - //!on failure - void * allocate(size_type nbytes) - { - void * ret = MemoryAlgorithm::allocate(nbytes); - if(!ret) - throw bad_alloc(); - return ret; - } - - //!Allocates nbytes bytes. This function is only used in - //!single-segment management. Never throws - void * allocate_aligned (size_type nbytes, size_type alignment, std::nothrow_t) - { return MemoryAlgorithm::allocate_aligned(nbytes, alignment); } - - //!Allocates nbytes bytes. This function is only used in - //!single-segment management. Throws bad_alloc when fails - void * allocate_aligned(size_type nbytes, size_type alignment) - { - void * ret = MemoryAlgorithm::allocate_aligned(nbytes, alignment); - if(!ret) - throw bad_alloc(); - return ret; - } - - template - std::pair - allocation_command (boost::interprocess::allocation_type command, size_type limit_size, - size_type preferred_size,size_type &received_size, - T *reuse_ptr = 0) - { - std::pair ret = MemoryAlgorithm::allocation_command - ( command | boost::interprocess::nothrow_allocation, limit_size, preferred_size, received_size - , reuse_ptr); - if(!(command & boost::interprocess::nothrow_allocation) && !ret.first) - throw bad_alloc(); - return ret; - } - - std::pair - raw_allocation_command (boost::interprocess::allocation_type command, size_type limit_objects, - size_type preferred_objects,size_type &received_objects, - void *reuse_ptr = 0, size_type sizeof_object = 1) - { - std::pair ret = MemoryAlgorithm::raw_allocation_command - ( command | boost::interprocess::nothrow_allocation, limit_objects, preferred_objects, received_objects - , reuse_ptr, sizeof_object); - if(!(command & boost::interprocess::nothrow_allocation) && !ret.first) - throw bad_alloc(); - return ret; - } - - //!Deallocates the bytes allocated with allocate/allocate_many() - //!pointed by addr - void deallocate (void *addr) - { MemoryAlgorithm::deallocate(addr); } - - //!Increases managed memory in extra_size bytes more. This only works - //!with single-segment management. - void grow(size_type extra_size) - { MemoryAlgorithm::grow(extra_size); } - - //!Decreases managed memory to the minimum. This only works - //!with single-segment management. - void shrink_to_fit() - { MemoryAlgorithm::shrink_to_fit(); } - - //!Returns the result of "all_memory_deallocated()" function - //!of the used memory algorithm - bool all_memory_deallocated() - { return MemoryAlgorithm::all_memory_deallocated(); } - - //!Returns the result of "check_sanity()" function - //!of the used memory algorithm - bool check_sanity() - { return MemoryAlgorithm::check_sanity(); } - - //!Writes to zero free memory (memory not yet allocated) - //!of the memory algorithm - void zero_free_memory() - { MemoryAlgorithm::zero_free_memory(); } - - //!Returns the size of the buffer previously allocated pointed by ptr - size_type size(const void *ptr) const - { return MemoryAlgorithm::size(ptr); } - - /// @cond - protected: - void * prot_anonymous_construct - (size_type num, bool dothrow, ipcdetail::in_place_interface &table) - { - typedef ipcdetail::block_header block_header_t; - block_header_t block_info ( size_type(table.size*num) - , size_type(table.alignment) - , anonymous_type - , 1 - , 0); - - //Allocate memory - void *ptr_struct = this->allocate(block_info.total_size(), std::nothrow_t()); - - //Check if there is enough memory - if(!ptr_struct){ - if(dothrow){ - throw bad_alloc(); - } - else{ - return 0; - } - } - - //Build scoped ptr to avoid leaks with constructor exception - ipcdetail::mem_algo_deallocator mem(ptr_struct, *this); - - //Now construct the header - block_header_t * hdr = new(ptr_struct) block_header_t(block_info); - void *ptr = 0; //avoid gcc warning - ptr = hdr->value(); - - //Now call constructors - ipcdetail::array_construct(ptr, num, table); - - //All constructors successful, we don't want erase memory - mem.release(); - return ptr; - } - - //!Calls the destructor and makes an anonymous deallocate - void prot_anonymous_destroy(const void *object, ipcdetail::in_place_interface &table) - { - - //Get control data from associated with this object - typedef ipcdetail::block_header block_header_t; - block_header_t *ctrl_data = block_header_t::block_header_from_value(object, table.size, table.alignment); - - //------------------------------- - //scoped_lock guard(m_header); - //------------------------------- - - if(ctrl_data->alloc_type() != anonymous_type){ - //This is not an anonymous object, the pointer is wrong! - BOOST_ASSERT(0); - } - - //Call destructors and free memory - //Build scoped ptr to avoid leaks with destructor exception - std::size_t destroyed = 0; - table.destroy_n(const_cast(object), ctrl_data->m_value_bytes/table.size, destroyed); - this->deallocate(ctrl_data); - } - /// @endcond -}; - -//!This object is placed in the beginning of memory segment and -//!implements the allocation (named or anonymous) of portions -//!of the segment. This object contains two indexes that -//!maintain an association between a name and a portion of the segment. -//! -//!The first index contains the mappings for normal named objects using the -//!char type specified in the template parameter. -//! -//!The second index contains the association for unique instances. The key will -//!be the const char * returned from type_info.name() function for the unique -//!type to be constructed. -//! -//!segment_manager inherits publicly -//!from segment_manager_base and inherits from it -//!many public functions related to anonymous object and raw memory allocation. -//!See segment_manager_base reference to know about those functions. -template class IndexType> -class segment_manager - : public segment_manager_base -{ - /// @cond - //Non-copyable - segment_manager(); - segment_manager(const segment_manager &); - segment_manager &operator=(const segment_manager &); - typedef segment_manager_base Base; - /// @endcond - - public: - typedef MemoryAlgorithm memory_algorithm; - typedef typename Base::void_pointer void_pointer; - typedef typename Base::size_type size_type; - typedef typename Base::difference_type difference_type; - typedef CharType char_type; - - typedef segment_manager_base segment_manager_base_type; - - static const size_type PayloadPerAllocation = Base::PayloadPerAllocation; - - /// @cond - private: - typedef ipcdetail::block_header block_header_t; - typedef ipcdetail::index_config index_config_named; - typedef ipcdetail::index_config index_config_unique; - typedef IndexType index_type; - typedef ipcdetail::bool_::value > is_intrusive_t; - typedef ipcdetail::bool_::value> is_node_index_t; - - public: - typedef IndexType named_index_t; - typedef IndexType unique_index_t; - typedef ipcdetail::char_ptr_holder char_ptr_holder_t; - typedef ipcdetail::segment_manager_iterator_transform - ::value> named_transform; - - typedef ipcdetail::segment_manager_iterator_transform - ::value> unique_transform; - /// @endcond - - typedef typename Base::mutex_family mutex_family; - - typedef transform_iterator - const_named_iterator; - typedef transform_iterator - const_unique_iterator; - - /// @cond - - //!Constructor proxy object definition helper class - template - struct construct_proxy - { - typedef ipcdetail::named_proxy type; - }; - - //!Constructor proxy object definition helper class - template - struct construct_iter_proxy - { - typedef ipcdetail::named_proxy type; - }; - - /// @endcond - - //!Constructor of the segment manager - //!"size" is the size of the memory segment where - //!the segment manager is being constructed. - //!Can throw - explicit segment_manager(size_type segment_size) - : Base(segment_size, priv_get_reserved_bytes()) - , m_header(static_cast(get_this_pointer())) - { - (void) anonymous_instance; (void) unique_instance; - BOOST_ASSERT(static_cast(this) == static_cast(static_cast(this))); - } - - //!Tries to find a previous named allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. - template - std::pair find (const CharType* name) - { return this->priv_find_impl(name, true); } - - //!Tries to find a previous unique allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. - template - std::pair find (const ipcdetail::unique_instance_t* name) - { return this->priv_find_impl(name, true); } - - //!Tries to find a previous named allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. This search is not mutex-protected! - template - std::pair find_no_lock (const CharType* name) - { return this->priv_find_impl(name, false); } - - //!Tries to find a previous unique allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. This search is not mutex-protected! - template - std::pair find_no_lock (const ipcdetail::unique_instance_t* name) - { return this->priv_find_impl(name, false); } - - //!Returns throwing "construct" proxy - //!object - template - typename construct_proxy::type - construct(char_ptr_holder_t name) - { return typename construct_proxy::type (this, name, false, true); } - - //!Returns throwing "search or construct" proxy - //!object - template - typename construct_proxy::type find_or_construct(char_ptr_holder_t name) - { return typename construct_proxy::type (this, name, true, true); } - - //!Returns no throwing "construct" proxy - //!object - template - typename construct_proxy::type - construct(char_ptr_holder_t name, std::nothrow_t) - { return typename construct_proxy::type (this, name, false, false); } - - //!Returns no throwing "search or construct" - //!proxy object - template - typename construct_proxy::type - find_or_construct(char_ptr_holder_t name, std::nothrow_t) - { return typename construct_proxy::type (this, name, true, false); } - - //!Returns throwing "construct from iterators" proxy object - template - typename construct_iter_proxy::type - construct_it(char_ptr_holder_t name) - { return typename construct_iter_proxy::type (this, name, false, true); } - - //!Returns throwing "search or construct from iterators" - //!proxy object - template - typename construct_iter_proxy::type - find_or_construct_it(char_ptr_holder_t name) - { return typename construct_iter_proxy::type (this, name, true, true); } - - //!Returns no throwing "construct from iterators" - //!proxy object - template - typename construct_iter_proxy::type - construct_it(char_ptr_holder_t name, std::nothrow_t) - { return typename construct_iter_proxy::type (this, name, false, false); } - - //!Returns no throwing "search or construct from iterators" - //!proxy object - template - typename construct_iter_proxy::type - find_or_construct_it(char_ptr_holder_t name, std::nothrow_t) - { return typename construct_iter_proxy::type (this, name, true, false); } - - //!Calls object function blocking recursive interprocess_mutex and guarantees that - //!no new named_alloc or destroy will be executed by any process while - //!executing the object function call*/ - template - void atomic_func(Func &f) - { scoped_lock guard(m_header); f(); } - - //!Tries to calls a functor guaranteeing that no new construction, search or - //!destruction will be executed by any process while executing the object - //!function call. If the atomic function can't be immediatelly executed - //!because the internal mutex is already locked, returns false. - //!If the functor throws, this function throws. - template - bool try_atomic_func(Func &f) - { - scoped_lock guard(m_header, try_to_lock); - if(guard){ - f(); - return true; - } - else{ - return false; - } - } - - //!Destroys a previously created unique instance. - //!Returns false if the object was not present. - template - bool destroy(const ipcdetail::unique_instance_t *) - { - ipcdetail::placement_destroy dtor; - return this->priv_generic_named_destroy - (typeid(T).name(), m_header.m_unique_index, dtor, is_intrusive_t()); - } - - //!Destroys the named object with - //!the given name. Returns false if that object can't be found. - template - bool destroy(const CharType *name) - { - ipcdetail::placement_destroy dtor; - return this->priv_generic_named_destroy - (name, m_header.m_named_index, dtor, is_intrusive_t()); - } - - //!Destroys an anonymous, unique or named object - //!using it's address - template - void destroy_ptr(const T *p) - { - //If T is void transform it to char - typedef typename ipcdetail::char_if_void::type data_t; - ipcdetail::placement_destroy dtor; - priv_destroy_ptr(p, dtor); - } - - //!Returns the name of an object created with construct/find_or_construct - //!functions. Does not throw - template - static const CharType *get_instance_name(const T *ptr) - { return priv_get_instance_name(block_header_t::block_header_from_value(ptr)); } - - //!Returns the length of an object created with construct/find_or_construct - //!functions. Does not throw. - template - static size_type get_instance_length(const T *ptr) - { return priv_get_instance_length(block_header_t::block_header_from_value(ptr), sizeof(T)); } - - //!Returns is the the name of an object created with construct/find_or_construct - //!functions. Does not throw - template - static instance_type get_instance_type(const T *ptr) - { return priv_get_instance_type(block_header_t::block_header_from_value(ptr)); } - - //!Preallocates needed index resources to optimize the - //!creation of "num" named objects in the managed memory segment. - //!Can throw boost::interprocess::bad_alloc if there is no enough memory. - void reserve_named_objects(size_type num) - { - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - m_header.m_named_index.reserve(num); - } - - //!Preallocates needed index resources to optimize the - //!creation of "num" unique objects in the managed memory segment. - //!Can throw boost::interprocess::bad_alloc if there is no enough memory. - void reserve_unique_objects(size_type num) - { - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - m_header.m_unique_index.reserve(num); - } - - //!Calls shrink_to_fit in both named and unique object indexes - //!to try to free unused memory from those indexes. - void shrink_to_fit_indexes() - { - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - m_header.m_named_index.shrink_to_fit(); - m_header.m_unique_index.shrink_to_fit(); - } - - //!Returns the number of named objects stored in - //!the segment. - size_type get_num_named_objects() - { - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - return m_header.m_named_index.size(); - } - - //!Returns the number of unique objects stored in - //!the segment. - size_type get_num_unique_objects() - { - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - return m_header.m_unique_index.size(); - } - - //!Obtains the minimum size needed by the - //!segment manager - static size_type get_min_size() - { return Base::get_min_size(priv_get_reserved_bytes()); } - - //!Returns a constant iterator to the beginning of the information about - //!the named allocations performed in this segment manager - const_named_iterator named_begin() const - { - return make_transform_iterator - (m_header.m_named_index.begin(), named_transform()); - } - - //!Returns a constant iterator to the end of the information about - //!the named allocations performed in this segment manager - const_named_iterator named_end() const - { - return make_transform_iterator - (m_header.m_named_index.end(), named_transform()); - } - - //!Returns a constant iterator to the beginning of the information about - //!the unique allocations performed in this segment manager - const_unique_iterator unique_begin() const - { - return make_transform_iterator - (m_header.m_unique_index.begin(), unique_transform()); - } - - //!Returns a constant iterator to the end of the information about - //!the unique allocations performed in this segment manager - const_unique_iterator unique_end() const - { - return make_transform_iterator - (m_header.m_unique_index.end(), unique_transform()); - } - - //!This is the default allocator to allocate types T - //!from this managed segment - template - struct allocator - { - typedef boost::interprocess::allocator type; - }; - - //!Returns an instance of the default allocator for type T - //!initialized that allocates memory from this segment manager. - template - typename allocator::type - get_allocator() - { return typename allocator::type(this); } - - //!This is the default deleter to delete types T - //!from this managed segment. - template - struct deleter - { - typedef boost::interprocess::deleter type; - }; - - //!Returns an instance of the default allocator for type T - //!initialized that allocates memory from this segment manager. - template - typename deleter::type - get_deleter() - { return typename deleter::type(this); } - - /// @cond - - //!Generic named/anonymous new function. Offers all the possibilities, - //!such as throwing, search before creating, and the constructor is - //!encapsulated in an object function. - template - T *generic_construct(const CharType *name, - size_type num, - bool try2find, - bool dothrow, - ipcdetail::in_place_interface &table) - { - return static_cast - (priv_generic_construct(name, num, try2find, dothrow, table)); - } - - private: - //!Tries to find a previous named allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. - template - std::pair priv_find_impl (const CharType* name, bool lock) - { - //The name can't be null, no anonymous object can be found by name - BOOST_ASSERT(name != 0); - ipcdetail::placement_destroy table; - size_type sz; - void *ret; - - if(name == reinterpret_cast(-1)){ - ret = priv_generic_find (typeid(T).name(), m_header.m_unique_index, table, sz, is_intrusive_t(), lock); - } - else{ - ret = priv_generic_find (name, m_header.m_named_index, table, sz, is_intrusive_t(), lock); - } - return std::pair(static_cast(ret), sz); - } - - //!Tries to find a previous unique allocation. Returns the address - //!and the object count. On failure the first member of the - //!returned pair is 0. - template - std::pair priv_find__impl (const ipcdetail::unique_instance_t* name, bool lock) - { - ipcdetail::placement_destroy table; - size_type size; - void *ret = priv_generic_find(name, m_header.m_unique_index, table, size, is_intrusive_t(), lock); - return std::pair(static_cast(ret), size); - } - - void *priv_generic_construct(const CharType *name, - size_type num, - bool try2find, - bool dothrow, - ipcdetail::in_place_interface &table) - { - void *ret; - //Security overflow check - if(num > ((std::size_t)-1)/table.size){ - if(dothrow) - throw bad_alloc(); - else - return 0; - } - if(name == 0){ - ret = this->prot_anonymous_construct(num, dothrow, table); - } - else if(name == reinterpret_cast(-1)){ - ret = this->priv_generic_named_construct - (unique_type, table.type_name, num, try2find, dothrow, table, m_header.m_unique_index, is_intrusive_t()); - } - else{ - ret = this->priv_generic_named_construct - (named_type, name, num, try2find, dothrow, table, m_header.m_named_index, is_intrusive_t()); - } - return ret; - } - - void priv_destroy_ptr(const void *ptr, ipcdetail::in_place_interface &dtor) - { - block_header_t *ctrl_data = block_header_t::block_header_from_value(ptr, dtor.size, dtor.alignment); - switch(ctrl_data->alloc_type()){ - case anonymous_type: - this->prot_anonymous_destroy(ptr, dtor); - break; - - case named_type: - this->priv_generic_named_destroy - (ctrl_data, m_header.m_named_index, dtor, is_node_index_t()); - break; - - case unique_type: - this->priv_generic_named_destroy - (ctrl_data, m_header.m_unique_index, dtor, is_node_index_t()); - break; - - default: - //This type is unknown, bad pointer passed to this function! - BOOST_ASSERT(0); - break; - } - } - - //!Returns the name of an object created with construct/find_or_construct - //!functions. Does not throw - static const CharType *priv_get_instance_name(block_header_t *ctrl_data) - { - boost::interprocess::allocation_type type = ctrl_data->alloc_type(); - if(type != named_type){ - BOOST_ASSERT((type == anonymous_type && ctrl_data->m_num_char == 0) || - (type == unique_type && ctrl_data->m_num_char != 0) ); - return 0; - } - CharType *name = static_cast(ctrl_data->template name()); - - //Sanity checks - BOOST_ASSERT(ctrl_data->sizeof_char() == sizeof(CharType)); - BOOST_ASSERT(ctrl_data->m_num_char == std::char_traits::length(name)); - return name; - } - - static size_type priv_get_instance_length(block_header_t *ctrl_data, size_type sizeofvalue) - { - //Get header - BOOST_ASSERT((ctrl_data->value_bytes() %sizeofvalue) == 0); - return ctrl_data->value_bytes()/sizeofvalue; - } - - //!Returns is the the name of an object created with construct/find_or_construct - //!functions. Does not throw - static instance_type priv_get_instance_type(block_header_t *ctrl_data) - { - //Get header - BOOST_ASSERT((instance_type)ctrl_data->alloc_type() < max_allocation_type); - return (instance_type)ctrl_data->alloc_type(); - } - - static size_type priv_get_reserved_bytes() - { - //Get the number of bytes until the end of (*this) - //beginning in the end of the Base base. - return sizeof(segment_manager) - sizeof(Base); - } - - template - void *priv_generic_find - (const CharT* name, - IndexType > &index, - ipcdetail::in_place_interface &table, - size_type &length, - ipcdetail::true_ is_intrusive, - bool use_lock) - { - (void)is_intrusive; - typedef IndexType > index_type; - typedef typename index_type::iterator index_it; - - //------------------------------- - scoped_lock guard(priv_get_lock(use_lock)); - //------------------------------- - //Find name in index - ipcdetail::intrusive_compare_key key - (name, std::char_traits::length(name)); - index_it it = index.find(key); - - //Initialize return values - void *ret_ptr = 0; - length = 0; - - //If found, assign values - if(it != index.end()){ - //Get header - block_header_t *ctrl_data = it->get_block_header(); - - //Sanity check - BOOST_ASSERT((ctrl_data->m_value_bytes % table.size) == 0); - BOOST_ASSERT(ctrl_data->sizeof_char() == sizeof(CharT)); - ret_ptr = ctrl_data->value(); - length = ctrl_data->m_value_bytes/table.size; - } - return ret_ptr; - } - - template - void *priv_generic_find - (const CharT* name, - IndexType > &index, - ipcdetail::in_place_interface &table, - size_type &length, - ipcdetail::false_ is_intrusive, - bool use_lock) - { - (void)is_intrusive; - typedef IndexType > index_type; - typedef typename index_type::key_type key_type; - typedef typename index_type::iterator index_it; - - //------------------------------- - scoped_lock guard(priv_get_lock(use_lock)); - //------------------------------- - //Find name in index - index_it it = index.find(key_type(name, std::char_traits::length(name))); - - //Initialize return values - void *ret_ptr = 0; - length = 0; - - //If found, assign values - if(it != index.end()){ - //Get header - block_header_t *ctrl_data = reinterpret_cast - (ipcdetail::to_raw_pointer(it->second.m_ptr)); - - //Sanity check - BOOST_ASSERT((ctrl_data->m_value_bytes % table.size) == 0); - BOOST_ASSERT(ctrl_data->sizeof_char() == sizeof(CharT)); - ret_ptr = ctrl_data->value(); - length = ctrl_data->m_value_bytes/table.size; - } - return ret_ptr; - } - - template - bool priv_generic_named_destroy - (block_header_t *block_header, - IndexType > &index, - ipcdetail::in_place_interface &table, - ipcdetail::true_ is_node_index) - { - (void)is_node_index; - typedef typename IndexType >::iterator index_it; - - index_it *ihdr = block_header_t::template to_first_header(block_header); - return this->priv_generic_named_destroy_impl(*ihdr, index, table); - } - - template - bool priv_generic_named_destroy - (block_header_t *block_header, - IndexType > &index, - ipcdetail::in_place_interface &table, - ipcdetail::false_ is_node_index) - { - (void)is_node_index; - CharT *name = static_cast(block_header->template name()); - return this->priv_generic_named_destroy(name, index, table, is_intrusive_t()); - } - - template - bool priv_generic_named_destroy(const CharT *name, - IndexType > &index, - ipcdetail::in_place_interface &table, - ipcdetail::true_ is_intrusive_index) - { - (void)is_intrusive_index; - typedef IndexType > index_type; - typedef typename index_type::iterator index_it; - typedef typename index_type::value_type intrusive_value_type; - - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - //Find name in index - ipcdetail::intrusive_compare_key key - (name, std::char_traits::length(name)); - index_it it = index.find(key); - - //If not found, return false - if(it == index.end()){ - //This name is not present in the index, wrong pointer or name! - //BOOST_ASSERT(0); - return false; - } - - block_header_t *ctrl_data = it->get_block_header(); - intrusive_value_type *iv = intrusive_value_type::get_intrusive_value_type(ctrl_data); - void *memory = iv; - void *values = ctrl_data->value(); - std::size_t num = ctrl_data->m_value_bytes/table.size; - - //Sanity check - BOOST_ASSERT((ctrl_data->m_value_bytes % table.size) == 0); - BOOST_ASSERT(sizeof(CharT) == ctrl_data->sizeof_char()); - - //Erase node from index - index.erase(it); - - //Destroy the headers - ctrl_data->~block_header_t(); - iv->~intrusive_value_type(); - - //Call destructors and free memory - std::size_t destroyed; - table.destroy_n(values, num, destroyed); - this->deallocate(memory); - return true; - } - - template - bool priv_generic_named_destroy(const CharT *name, - IndexType > &index, - ipcdetail::in_place_interface &table, - ipcdetail::false_ is_intrusive_index) - { - (void)is_intrusive_index; - typedef IndexType > index_type; - typedef typename index_type::iterator index_it; - typedef typename index_type::key_type key_type; - - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - //Try to find the name in the index - index_it it = index.find(key_type (name, - std::char_traits::length(name))); - - //If not found, return false - if(it == index.end()){ - //This name is not present in the index, wrong pointer or name! - //BOOST_ASSERT(0); - return false; - } - return this->priv_generic_named_destroy_impl(it, index, table); - } - - template - bool priv_generic_named_destroy_impl - (const typename IndexType >::iterator &it, - IndexType > &index, - ipcdetail::in_place_interface &table) - { - typedef IndexType > index_type; - typedef typename index_type::iterator index_it; - - //Get allocation parameters - block_header_t *ctrl_data = reinterpret_cast - (ipcdetail::to_raw_pointer(it->second.m_ptr)); - char *stored_name = static_cast(static_cast(const_cast(it->first.name()))); - (void)stored_name; - - //Check if the distance between the name pointer and the memory pointer - //is correct (this can detect incorrect type in destruction) - std::size_t num = ctrl_data->m_value_bytes/table.size; - void *values = ctrl_data->value(); - - //Sanity check - BOOST_ASSERT((ctrl_data->m_value_bytes % table.size) == 0); - BOOST_ASSERT(static_cast(stored_name) == static_cast(ctrl_data->template name())); - BOOST_ASSERT(sizeof(CharT) == ctrl_data->sizeof_char()); - - //Erase node from index - index.erase(it); - - //Destroy the header - ctrl_data->~block_header_t(); - - void *memory; - if(is_node_index_t::value){ - index_it *ihdr = block_header_t::template - to_first_header(ctrl_data); - ihdr->~index_it(); - memory = ihdr; - } - else{ - memory = ctrl_data; - } - - //Call destructors and free memory - std::size_t destroyed; - table.destroy_n(values, num, destroyed); - this->deallocate(memory); - return true; - } - - template - void * priv_generic_named_construct(unsigned char type, - const CharT *name, - size_type num, - bool try2find, - bool dothrow, - ipcdetail::in_place_interface &table, - IndexType > &index, - ipcdetail::true_ is_intrusive) - { - (void)is_intrusive; - std::size_t namelen = std::char_traits::length(name); - - block_header_t block_info ( size_type(table.size*num) - , size_type(table.alignment) - , type - , sizeof(CharT) - , namelen); - - typedef IndexType > index_type; - typedef typename index_type::iterator index_it; - typedef std::pair index_ib; - - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - //Insert the node. This can throw. - //First, we want to know if the key is already present before - //we allocate any memory, and if the key is not present, we - //want to allocate all memory in a single buffer that will - //contain the name and the user buffer. - // - //Since equal_range(key) + insert(hint, value) approach is - //quite inefficient in container implementations - //(they re-test if the position is correct), I've chosen - //to insert the node, do an ugly un-const cast and modify - //the key (which is a smart pointer) to an equivalent one - index_ib insert_ret; - - typename index_type::insert_commit_data commit_data; - typedef typename index_type::value_type intrusive_value_type; - - BOOST_TRY{ - ipcdetail::intrusive_compare_key key(name, namelen); - insert_ret = index.insert_check(key, commit_data); - } - //Ignore exceptions - BOOST_CATCH(...){ - if(dothrow) - BOOST_RETHROW - return 0; - } - BOOST_CATCH_END - - index_it it = insert_ret.first; - - //If found and this is find or construct, return data - //else return null - if(!insert_ret.second){ - if(try2find){ - return it->get_block_header()->value(); - } - if(dothrow){ - throw interprocess_exception(already_exists_error); - } - else{ - return 0; - } - } - - //Allocates buffer for name + data, this can throw (it hurts) - void *buffer_ptr; - - //Check if there is enough memory - if(dothrow){ - buffer_ptr = this->allocate - (block_info.template total_size_with_header()); - } - else{ - buffer_ptr = this->allocate - (block_info.template total_size_with_header(), std::nothrow_t()); - if(!buffer_ptr) - return 0; - } - - //Now construct the intrusive hook plus the header - intrusive_value_type * intrusive_hdr = new(buffer_ptr) intrusive_value_type(); - block_header_t * hdr = new(intrusive_hdr->get_block_header())block_header_t(block_info); - void *ptr = 0; //avoid gcc warning - ptr = hdr->value(); - - //Copy name to memory segment and insert data - CharT *name_ptr = static_cast(hdr->template name()); - std::char_traits::copy(name_ptr, name, namelen+1); - - BOOST_TRY{ - //Now commit the insertion using previous context data - it = index.insert_commit(*intrusive_hdr, commit_data); - } - //Ignore exceptions - BOOST_CATCH(...){ - if(dothrow) - BOOST_RETHROW - return 0; - } - BOOST_CATCH_END - - //Avoid constructions if constructor is trivial - //Build scoped ptr to avoid leaks with constructor exception - ipcdetail::mem_algo_deallocator mem - (buffer_ptr, *static_cast(this)); - - //Initialize the node value_eraser to erase inserted node - //if something goes wrong. This will be executed *before* - //the memory allocation as the intrusive value is built in that - //memory - value_eraser v_eraser(index, it); - - //Construct array, this can throw - ipcdetail::array_construct(ptr, num, table); - - //Release rollbacks since construction was successful - v_eraser.release(); - mem.release(); - return ptr; - } - - //!Generic named new function for - //!named functions - template - void * priv_generic_named_construct(unsigned char type, - const CharT *name, - size_type num, - bool try2find, - bool dothrow, - ipcdetail::in_place_interface &table, - IndexType > &index, - ipcdetail::false_ is_intrusive) - { - (void)is_intrusive; - std::size_t namelen = std::char_traits::length(name); - - block_header_t block_info ( size_type(table.size*num) - , size_type(table.alignment) - , type - , sizeof(CharT) - , namelen); - - typedef IndexType > index_type; - typedef typename index_type::key_type key_type; - typedef typename index_type::mapped_type mapped_type; - typedef typename index_type::value_type value_type; - typedef typename index_type::iterator index_it; - typedef std::pair index_ib; - - //------------------------------- - scoped_lock guard(m_header); - //------------------------------- - //Insert the node. This can throw. - //First, we want to know if the key is already present before - //we allocate any memory, and if the key is not present, we - //want to allocate all memory in a single buffer that will - //contain the name and the user buffer. - // - //Since equal_range(key) + insert(hint, value) approach is - //quite inefficient in container implementations - //(they re-test if the position is correct), I've chosen - //to insert the node, do an ugly un-const cast and modify - //the key (which is a smart pointer) to an equivalent one - index_ib insert_ret; - BOOST_TRY{ - insert_ret = index.insert(value_type(key_type (name, namelen), mapped_type(0))); - } - //Ignore exceptions - BOOST_CATCH(...){ - if(dothrow) - BOOST_RETHROW; - return 0; - } - BOOST_CATCH_END - - index_it it = insert_ret.first; - - //If found and this is find or construct, return data - //else return null - if(!insert_ret.second){ - if(try2find){ - block_header_t *hdr = static_cast - (ipcdetail::to_raw_pointer(it->second.m_ptr)); - return hdr->value(); - } - return 0; - } - //Initialize the node value_eraser to erase inserted node - //if something goes wrong - value_eraser v_eraser(index, it); - - //Allocates buffer for name + data, this can throw (it hurts) - void *buffer_ptr; - block_header_t * hdr; - - //Allocate and construct the headers - if(is_node_index_t::value){ - size_type total_size = block_info.template total_size_with_header(); - if(dothrow){ - buffer_ptr = this->allocate(total_size); - } - else{ - buffer_ptr = this->allocate(total_size, std::nothrow_t()); - if(!buffer_ptr) - return 0; - } - index_it *idr = new(buffer_ptr) index_it(it); - hdr = block_header_t::template from_first_header(idr); - } - else{ - if(dothrow){ - buffer_ptr = this->allocate(block_info.total_size()); - } - else{ - buffer_ptr = this->allocate(block_info.total_size(), std::nothrow_t()); - if(!buffer_ptr) - return 0; - } - hdr = static_cast(buffer_ptr); - } - - hdr = new(hdr)block_header_t(block_info); - void *ptr = 0; //avoid gcc warning - ptr = hdr->value(); - - //Copy name to memory segment and insert data - CharT *name_ptr = static_cast(hdr->template name()); - std::char_traits::copy(name_ptr, name, namelen+1); - - //Do the ugly cast, please mama, forgive me! - //This new key points to an identical string, so it must have the - //same position than the overwritten key according to the predicate - const_cast(it->first).name(name_ptr); - it->second.m_ptr = hdr; - - //Build scoped ptr to avoid leaks with constructor exception - ipcdetail::mem_algo_deallocator mem - (buffer_ptr, *static_cast(this)); - - //Construct array, this can throw - ipcdetail::array_construct(ptr, num, table); - - //All constructors successful, we don't want to release memory - mem.release(); - - //Release node v_eraser since construction was successful - v_eraser.release(); - return ptr; - } - - private: - //!Returns the this pointer - segment_manager *get_this_pointer() - { return this; } - - typedef typename MemoryAlgorithm::mutex_family::recursive_mutex_type rmutex; - - scoped_lock priv_get_lock(bool use_lock) - { - scoped_lock local(m_header, defer_lock); - if(use_lock){ - local.lock(); - } - return scoped_lock(boost::move(local)); - } - - //!This struct includes needed data and derives from - //!rmutex to allow EBO when using null interprocess_mutex - struct header_t - : public rmutex - { - named_index_t m_named_index; - unique_index_t m_unique_index; - - header_t(Base *restricted_segment_mngr) - : m_named_index (restricted_segment_mngr) - , m_unique_index(restricted_segment_mngr) - {} - } m_header; - - /// @endcond -}; - - -}} //namespace boost { namespace interprocess - -#include - -#endif //#ifndef BOOST_INTERPROCESS_SEGMENT_MANAGER_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/shared_memory_object.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/shared_memory_object.hpp deleted file mode 100644 index 54563f5c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/shared_memory_object.hpp +++ /dev/null @@ -1,430 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_SHARED_MEMORY_OBJECT_HPP -#define BOOST_INTERPROCESS_SHARED_MEMORY_OBJECT_HPP - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS_ONLY) -# include //System V shared memory... -#elif defined(BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS) -# include //O_CREAT, O_*... -# include //shm_xxx -# include //ftruncate, close -# include //mode_t, S_IRWXG, S_IRWXO, S_IRWXU, -# if defined(BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY) -# if defined(__FreeBSD__) -# include -# endif -# endif -#else -// -#endif - -//!\file -//!Describes a shared memory object management class. - -namespace boost { -namespace interprocess { - -//!A class that wraps a shared memory mapping that can be used to -//!create mapped regions from the mapped files -class shared_memory_object -{ - /// @cond - //Non-copyable and non-assignable - BOOST_MOVABLE_BUT_NOT_COPYABLE(shared_memory_object) - /// @endcond - - public: - //!Default constructor. Represents an empty shared_memory_object. - shared_memory_object(); - - //!Creates a shared memory object with name "name" and mode "mode", with the access mode "mode" - //!If the file previously exists, throws an error.*/ - shared_memory_object(create_only_t, const char *name, mode_t mode, const permissions &perm = permissions()) - { this->priv_open_or_create(ipcdetail::DoCreate, name, mode, perm); } - - //!Tries to create a shared memory object with name "name" and mode "mode", with the - //!access mode "mode". If the file previously exists, it tries to open it with mode "mode". - //!Otherwise throws an error. - shared_memory_object(open_or_create_t, const char *name, mode_t mode, const permissions &perm = permissions()) - { this->priv_open_or_create(ipcdetail::DoOpenOrCreate, name, mode, perm); } - - //!Tries to open a shared memory object with name "name", with the access mode "mode". - //!If the file does not previously exist, it throws an error. - shared_memory_object(open_only_t, const char *name, mode_t mode) - { this->priv_open_or_create(ipcdetail::DoOpen, name, mode, permissions()); } - - //!Moves the ownership of "moved"'s shared memory object to *this. - //!After the call, "moved" does not represent any shared memory object. - //!Does not throw - shared_memory_object(BOOST_RV_REF(shared_memory_object) moved) - : m_handle(file_handle_t(ipcdetail::invalid_file())) - , m_mode(read_only) - { this->swap(moved); } - - //!Moves the ownership of "moved"'s shared memory to *this. - //!After the call, "moved" does not represent any shared memory. - //!Does not throw - shared_memory_object &operator=(BOOST_RV_REF(shared_memory_object) moved) - { - shared_memory_object tmp(boost::move(moved)); - this->swap(tmp); - return *this; - } - - //!Swaps the shared_memory_objects. Does not throw - void swap(shared_memory_object &moved); - - //!Erases a shared memory object from the system. - //!Returns false on error. Never throws - static bool remove(const char *name); - - //!Sets the size of the shared memory mapping - void truncate(offset_t length); - - //!Destroys *this and indicates that the calling process is finished using - //!the resource. All mapped regions are still - //!valid after destruction. The destructor function will deallocate - //!any system resources allocated by the system for use by this process for - //!this resource. The resource can still be opened again calling - //!the open constructor overload. To erase the resource from the system - //!use remove(). - ~shared_memory_object(); - - //!Returns the name of the shared memory object. - const char *get_name() const; - - //!Returns true if the size of the shared memory object - //!can be obtained and writes the size in the passed reference - bool get_size(offset_t &size) const; - - //!Returns access mode - mode_t get_mode() const; - - //!Returns mapping handle. Never throws. - mapping_handle_t get_mapping_handle() const; - - /// @cond - private: - - //!Closes a previously opened file mapping. Never throws. - void priv_close(); - - //!Closes a previously opened file mapping. Never throws. - bool priv_open_or_create(ipcdetail::create_enum_t type, const char *filename, mode_t mode, const permissions &perm); - - file_handle_t m_handle; - mode_t m_mode; - std::string m_filename; - /// @endcond -}; - -/// @cond - -inline shared_memory_object::shared_memory_object() - : m_handle(file_handle_t(ipcdetail::invalid_file())) - , m_mode(read_only) -{} - -inline shared_memory_object::~shared_memory_object() -{ this->priv_close(); } - - -inline const char *shared_memory_object::get_name() const -{ return m_filename.c_str(); } - -inline bool shared_memory_object::get_size(offset_t &size) const -{ return ipcdetail::get_file_size((file_handle_t)m_handle, size); } - -inline void shared_memory_object::swap(shared_memory_object &other) -{ - std::swap(m_handle, other.m_handle); - std::swap(m_mode, other.m_mode); - m_filename.swap(other.m_filename); -} - -inline mapping_handle_t shared_memory_object::get_mapping_handle() const -{ - return ipcdetail::mapping_handle_from_file_handle(m_handle); -} - -inline mode_t shared_memory_object::get_mode() const -{ return m_mode; } - -#if !defined(BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS) - -inline bool shared_memory_object::priv_open_or_create - (ipcdetail::create_enum_t type, const char *filename, mode_t mode, const permissions &perm) -{ - m_filename = filename; - std::string shmfile; - ipcdetail::create_tmp_and_clean_old_and_get_filename(filename, shmfile); - - //Set accesses - if (mode != read_write && mode != read_only){ - error_info err = other_error; - throw interprocess_exception(err); - } - - switch(type){ - case ipcdetail::DoOpen: - m_handle = ipcdetail::open_existing_file(shmfile.c_str(), mode, true); - break; - case ipcdetail::DoCreate: - m_handle = ipcdetail::create_new_file(shmfile.c_str(), mode, perm, true); - break; - case ipcdetail::DoOpenOrCreate: - m_handle = ipcdetail::create_or_open_file(shmfile.c_str(), mode, perm, true); - break; - default: - { - error_info err = other_error; - throw interprocess_exception(err); - } - } - - //Check for error - if(m_handle == ipcdetail::invalid_file()){ - error_info err = system_error_code(); - this->priv_close(); - throw interprocess_exception(err); - } - - m_mode = mode; - return true; -} - -inline bool shared_memory_object::remove(const char *filename) -{ - try{ - //Make sure a temporary path is created for shared memory - std::string shmfile; - ipcdetail::tmp_filename(filename, shmfile); - return ipcdetail::delete_file(shmfile.c_str()); - } - catch(...){ - return false; - } -} - -inline void shared_memory_object::truncate(offset_t length) -{ - if(!ipcdetail::truncate_file(m_handle, length)){ - error_info err = system_error_code(); - throw interprocess_exception(err); - } -} - -inline void shared_memory_object::priv_close() -{ - if(m_handle != ipcdetail::invalid_file()){ - ipcdetail::close_file(m_handle); - m_handle = ipcdetail::invalid_file(); - } -} - -#else //!defined(BOOST_INTERPROCESS_POSIX_SHARED_MEMORY_OBJECTS) - -namespace shared_memory_object_detail { - -#ifdef BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY - -#if defined(__FreeBSD__) - -inline bool use_filesystem_based_posix() -{ - int jailed = 0; - std::size_t len = sizeof(jailed); - ::sysctlbyname("security.jail.jailed", &jailed, &len, NULL, 0); - return jailed != 0; -} - -#else -#error "Not supported platform for BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY" -#endif - -#endif - -} //shared_memory_object_detail - -inline bool shared_memory_object::priv_open_or_create - (ipcdetail::create_enum_t type, - const char *filename, - mode_t mode, const permissions &perm) -{ - #if defined(BOOST_INTERPROCESS_FILESYSTEM_BASED_POSIX_SHARED_MEMORY) - const bool add_leading_slash = false; - #elif defined(BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY) - const bool add_leading_slash = !shared_memory_object_detail::use_filesystem_based_posix(); - #else - const bool add_leading_slash = true; - #endif - if(add_leading_slash){ - ipcdetail::add_leading_slash(filename, m_filename); - } - else{ - ipcdetail::create_tmp_and_clean_old_and_get_filename(filename, m_filename); - } - - //Create new mapping - int oflag = 0; - if(mode == read_only){ - oflag |= O_RDONLY; - } - else if(mode == read_write){ - oflag |= O_RDWR; - } - else{ - error_info err(mode_error); - throw interprocess_exception(err); - } - int unix_perm = perm.get_permissions(); - - switch(type){ - case ipcdetail::DoOpen: - { - //No oflag addition - m_handle = shm_open(m_filename.c_str(), oflag, unix_perm); - } - break; - case ipcdetail::DoCreate: - { - oflag |= (O_CREAT | O_EXCL); - m_handle = shm_open(m_filename.c_str(), oflag, unix_perm); - if(m_handle >= 0){ - ::fchmod(m_handle, unix_perm); - } - } - break; - case ipcdetail::DoOpenOrCreate: - { - //We need a create/open loop to change permissions correctly using fchmod, since - //with "O_CREAT" only we don't know if we've created or opened the shm. - while(1){ - //Try to create shared memory - m_handle = shm_open(m_filename.c_str(), oflag | (O_CREAT | O_EXCL), unix_perm); - //If successful change real permissions - if(m_handle >= 0){ - ::fchmod(m_handle, unix_perm); - } - //If already exists, try to open - else if(errno == EEXIST){ - m_handle = shm_open(m_filename.c_str(), oflag, unix_perm); - //If open fails and errno tells the file does not exist - //(shm was removed between creation and opening tries), just retry - if(m_handle < 0 && errno == ENOENT){ - continue; - } - } - //Exit retries - break; - } - } - break; - default: - { - error_info err = other_error; - throw interprocess_exception(err); - } - } - - //Check for error - if(m_handle < 0){ - error_info err = errno; - this->priv_close(); - throw interprocess_exception(err); - } - - m_filename = filename; - m_mode = mode; - return true; -} - -inline bool shared_memory_object::remove(const char *filename) -{ - try{ - std::string file_str; - #if defined(BOOST_INTERPROCESS_FILESYSTEM_BASED_POSIX_SHARED_MEMORY) - const bool add_leading_slash = false; - #elif defined(BOOST_INTERPROCESS_RUNTIME_FILESYSTEM_BASED_POSIX_SHARED_MEMORY) - const bool add_leading_slash = !shared_memory_object_detail::use_filesystem_based_posix(); - #else - const bool add_leading_slash = true; - #endif - if(add_leading_slash){ - ipcdetail::add_leading_slash(filename, file_str); - } - else{ - ipcdetail::tmp_filename(filename, file_str); - } - return 0 == shm_unlink(file_str.c_str()); - } - catch(...){ - return false; - } -} - -inline void shared_memory_object::truncate(offset_t length) -{ - if(0 != ftruncate(m_handle, length)){ - error_info err(system_error_code()); - throw interprocess_exception(err); - } -} - -inline void shared_memory_object::priv_close() -{ - if(m_handle != -1){ - ::close(m_handle); - m_handle = -1; - } -} - -#endif - -///@endcond - -//!A class that stores the name of a shared memory -//!and calls shared_memory_object::remove(name) in its destructor -//!Useful to remove temporary shared memory objects in the presence -//!of exceptions -class remove_shared_memory_on_destroy -{ - const char * m_name; - public: - remove_shared_memory_on_destroy(const char *name) - : m_name(name) - {} - - ~remove_shared_memory_on_destroy() - { shared_memory_object::remove(m_name); } -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_SHARED_MEMORY_OBJECT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/smart_ptr/deleter.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/smart_ptr/deleter.hpp deleted file mode 100644 index 8447bf1b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/smart_ptr/deleter.hpp +++ /dev/null @@ -1,64 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2012. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DELETER_HPP -#define BOOST_INTERPROCESS_DELETER_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include - -//!\file -//!Describes the functor to delete objects from the segment. - -namespace boost { -namespace interprocess { - -//!A deleter that uses the segment manager's destroy_ptr -//!function to destroy the passed pointer resource. -//! -//!This deleter is used -template -class deleter -{ - public: - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type pointer; - - private: - typedef typename boost::intrusive:: - pointer_traits::template - rebind_pointer::type segment_manager_pointer; - - segment_manager_pointer mp_mngr; - - public: - deleter(segment_manager_pointer pmngr) - : mp_mngr(pmngr) - {} - - void operator()(const pointer &p) - { mp_mngr->destroy_ptr(ipcdetail::to_raw_pointer(p)); } -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DELETER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/streams/bufferstream.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/streams/bufferstream.hpp deleted file mode 100644 index 404880d2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/streams/bufferstream.hpp +++ /dev/null @@ -1,483 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// This file comes from SGI's sstream file. Modified by Ion Gaztanaga 2005-2012. -// Changed internal SGI string to a buffer. Added efficient -// internal buffer get/set/swap functions, so that we can obtain/establish the -// internal buffer without any reallocation or copy. Kill those temporaries! -/////////////////////////////////////////////////////////////////////////////// -/* - * Copyright (c) 1998 - * Silicon Graphics Computer Systems, Inc. - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Silicon Graphics makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - */ - -//!\file -//!This file defines basic_bufferbuf, basic_ibufferstream, -//!basic_obufferstream, and basic_bufferstream classes. These classes -//!represent streamsbufs and streams whose sources or destinations -//!are fixed size character buffers. - -#ifndef BOOST_INTERPROCESS_BUFFERSTREAM_HPP -#define BOOST_INTERPROCESS_BUFFERSTREAM_HPP - -#include -#include - -#include -#include -#include -#include -#include // char traits -#include // ptrdiff_t -#include -#include - -namespace boost { namespace interprocess { - -//!A streambuf class that controls the transmission of elements to and from -//!a basic_xbufferstream. The elements are transmitted from a to a fixed -//!size buffer -template -class basic_bufferbuf - : public std::basic_streambuf -{ - public: - typedef CharT char_type; - typedef typename CharTraits::int_type int_type; - typedef typename CharTraits::pos_type pos_type; - typedef typename CharTraits::off_type off_type; - typedef CharTraits traits_type; - typedef std::basic_streambuf base_t; - - public: - //!Constructor. - //!Does not throw. - explicit basic_bufferbuf(std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - : base_t(), m_mode(mode), m_buffer(0), m_length(0) - {} - - //!Constructor. Assigns formatting buffer. - //!Does not throw. - explicit basic_bufferbuf(CharT *buf, std::size_t length, - std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - : base_t(), m_mode(mode), m_buffer(buf), m_length(length) - { this->set_pointers(); } - - virtual ~basic_bufferbuf(){} - - public: - //!Returns the pointer and size of the internal buffer. - //!Does not throw. - std::pair buffer() const - { return std::pair(m_buffer, m_length); } - - //!Sets the underlying buffer to a new value - //!Does not throw. - void buffer(CharT *buf, std::size_t length) - { m_buffer = buf; m_length = length; this->set_pointers(); } - - /// @cond - private: - void set_pointers() - { - // The initial read position is the beginning of the buffer. - if(m_mode & std::ios_base::in) - this->setg(m_buffer, m_buffer, m_buffer + m_length); - - // The initial write position is the beginning of the buffer. - if(m_mode & std::ios_base::out) - this->setp(m_buffer, m_buffer + m_length); - } - - protected: - virtual int_type underflow() - { - // Precondition: gptr() >= egptr(). Returns a character, if available. - return this->gptr() != this->egptr() ? - CharTraits::to_int_type(*this->gptr()) : CharTraits::eof(); - } - - virtual int_type pbackfail(int_type c = CharTraits::eof()) - { - if(this->gptr() != this->eback()) { - if(!CharTraits::eq_int_type(c, CharTraits::eof())) { - if(CharTraits::eq(CharTraits::to_char_type(c), this->gptr()[-1])) { - this->gbump(-1); - return c; - } - else if(m_mode & std::ios_base::out) { - this->gbump(-1); - *this->gptr() = c; - return c; - } - else - return CharTraits::eof(); - } - else { - this->gbump(-1); - return CharTraits::not_eof(c); - } - } - else - return CharTraits::eof(); - } - - virtual int_type overflow(int_type c = CharTraits::eof()) - { - if(m_mode & std::ios_base::out) { - if(!CharTraits::eq_int_type(c, CharTraits::eof())) { -// if(!(m_mode & std::ios_base::in)) { -// if(this->pptr() != this->epptr()) { -// *this->pptr() = CharTraits::to_char_type(c); -// this->pbump(1); -// return c; -// } -// else -// return CharTraits::eof(); -// } -// else { - if(this->pptr() == this->epptr()) { - //We can't append to a static buffer - return CharTraits::eof(); - } - else { - *this->pptr() = CharTraits::to_char_type(c); - this->pbump(1); - return c; - } -// } - } - else // c is EOF, so we don't have to do anything - return CharTraits::not_eof(c); - } - else // Overflow always fails if it's read-only. - return CharTraits::eof(); - } - - virtual pos_type seekoff(off_type off, std::ios_base::seekdir dir, - std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - { - bool in = false; - bool out = false; - - const std::ios_base::openmode inout = - std::ios_base::in | std::ios_base::out; - - if((mode & inout) == inout) { - if(dir == std::ios_base::beg || dir == std::ios_base::end) - in = out = true; - } - else if(mode & std::ios_base::in) - in = true; - else if(mode & std::ios_base::out) - out = true; - - if(!in && !out) - return pos_type(off_type(-1)); - else if((in && (!(m_mode & std::ios_base::in) || this->gptr() == 0)) || - (out && (!(m_mode & std::ios_base::out) || this->pptr() == 0))) - return pos_type(off_type(-1)); - - std::streamoff newoff; - switch(dir) { - case std::ios_base::beg: - newoff = 0; - break; - case std::ios_base::end: - newoff = static_cast(m_length); - break; - case std::ios_base::cur: - newoff = in ? static_cast(this->gptr() - this->eback()) - : static_cast(this->pptr() - this->pbase()); - break; - default: - return pos_type(off_type(-1)); - } - - off += newoff; - - if(in) { - std::ptrdiff_t n = this->egptr() - this->eback(); - - if(off < 0 || off > n) - return pos_type(off_type(-1)); - else - this->setg(this->eback(), this->eback() + off, this->eback() + n); - } - - if(out) { - std::ptrdiff_t n = this->epptr() - this->pbase(); - - if(off < 0 || off > n) - return pos_type(off_type(-1)); - else { - this->setp(this->pbase(), this->pbase() + n); - this->pbump(off); - } - } - - return pos_type(off); - } - - virtual pos_type seekpos(pos_type pos, std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - { return seekoff(pos - pos_type(off_type(0)), std::ios_base::beg, mode); } - - private: - std::ios_base::openmode m_mode; - CharT * m_buffer; - std::size_t m_length; - /// @endcond -}; - -//!A basic_istream class that uses a fixed size character buffer -//!as its formatting buffer. -template -class basic_ibufferstream : - /// @cond - private basic_bufferbuf, - /// @endcond - public std::basic_istream -{ - public: // Typedefs - typedef typename std::basic_ios - ::char_type char_type; - typedef typename std::basic_ios::int_type int_type; - typedef typename std::basic_ios::pos_type pos_type; - typedef typename std::basic_ios::off_type off_type; - typedef typename std::basic_ios::traits_type traits_type; - - /// @cond - private: - typedef basic_bufferbuf bufferbuf_t; - typedef std::basic_ios basic_ios_t; - typedef std::basic_istream base_t; - bufferbuf_t & get_buf() { return *this; } - const bufferbuf_t & get_buf() const{ return *this; } - /// @endcond - - public: - //!Constructor. - //!Does not throw. - basic_ibufferstream(std::ios_base::openmode mode = std::ios_base::in) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(mode | std::ios_base::in) - , base_t(&get_buf()) - {} - - //!Constructor. Assigns formatting buffer. - //!Does not throw. - basic_ibufferstream(const CharT *buf, std::size_t length, - std::ios_base::openmode mode = std::ios_base::in) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(const_cast(buf), length, mode | std::ios_base::in) - , base_t(&get_buf()) - {} - - ~basic_ibufferstream(){}; - - public: - //!Returns the address of the stored - //!stream buffer. - basic_bufferbuf* rdbuf() const - { return const_cast*>(&get_buf()); } - - //!Returns the pointer and size of the internal buffer. - //!Does not throw. - std::pair buffer() const - { return get_buf().buffer(); } - - //!Sets the underlying buffer to a new value. Resets - //!stream position. Does not throw. - void buffer(const CharT *buf, std::size_t length) - { get_buf().buffer(const_cast(buf), length); } -}; - -//!A basic_ostream class that uses a fixed size character buffer -//!as its formatting buffer. -template -class basic_obufferstream : - /// @cond - private basic_bufferbuf, - /// @endcond - public std::basic_ostream -{ - public: - typedef typename std::basic_ios - ::char_type char_type; - typedef typename std::basic_ios::int_type int_type; - typedef typename std::basic_ios::pos_type pos_type; - typedef typename std::basic_ios::off_type off_type; - typedef typename std::basic_ios::traits_type traits_type; - - /// @cond - private: - typedef basic_bufferbuf bufferbuf_t; - typedef std::basic_ios basic_ios_t; - typedef std::basic_ostream base_t; - bufferbuf_t & get_buf() { return *this; } - const bufferbuf_t & get_buf() const{ return *this; } - /// @endcond - - public: - //!Constructor. - //!Does not throw. - basic_obufferstream(std::ios_base::openmode mode = std::ios_base::out) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(mode | std::ios_base::out) - , base_t(&get_buf()) - {} - - //!Constructor. Assigns formatting buffer. - //!Does not throw. - basic_obufferstream(CharT *buf, std::size_t length, - std::ios_base::openmode mode = std::ios_base::out) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(buf, length, mode | std::ios_base::out) - , base_t(&get_buf()) - {} - - ~basic_obufferstream(){} - - public: - //!Returns the address of the stored - //!stream buffer. - basic_bufferbuf* rdbuf() const - { return const_cast*>(&get_buf()); } - - //!Returns the pointer and size of the internal buffer. - //!Does not throw. - std::pair buffer() const - { return get_buf().buffer(); } - - //!Sets the underlying buffer to a new value. Resets - //!stream position. Does not throw. - void buffer(CharT *buf, std::size_t length) - { get_buf().buffer(buf, length); } -}; - - -//!A basic_iostream class that uses a fixed size character buffer -//!as its formatting buffer. -template -class basic_bufferstream : - /// @cond - private basic_bufferbuf, - /// @endcond - public std::basic_iostream -{ - public: // Typedefs - typedef typename std::basic_ios - ::char_type char_type; - typedef typename std::basic_ios::int_type int_type; - typedef typename std::basic_ios::pos_type pos_type; - typedef typename std::basic_ios::off_type off_type; - typedef typename std::basic_ios::traits_type traits_type; - - /// @cond - private: - typedef basic_bufferbuf bufferbuf_t; - typedef std::basic_ios basic_ios_t; - typedef std::basic_iostream base_t; - bufferbuf_t & get_buf() { return *this; } - const bufferbuf_t & get_buf() const{ return *this; } - /// @endcond - - public: - //!Constructor. - //!Does not throw. - basic_bufferstream(std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(mode) - , base_t(&get_buf()) - {} - - //!Constructor. Assigns formatting buffer. - //!Does not throw. - basic_bufferstream(CharT *buf, std::size_t length, - std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - : //basic_ios_t() is called first (lefting it uninitialized) as it's a - //virtual base of basic_istream. The class will be initialized when - //basic_istream is constructed calling basic_ios_t::init(). - //As bufferbuf_t's constructor does not throw there is no risk of - //calling the basic_ios_t's destructor without calling basic_ios_t::init() - bufferbuf_t(buf, length, mode) - , base_t(&get_buf()) - {} - - ~basic_bufferstream(){} - - public: - //!Returns the address of the stored - //!stream buffer. - basic_bufferbuf* rdbuf() const - { return const_cast*>(&get_buf()); } - - //!Returns the pointer and size of the internal buffer. - //!Does not throw. - std::pair buffer() const - { return get_buf().buffer(); } - - //!Sets the underlying buffer to a new value. Resets - //!stream position. Does not throw. - void buffer(CharT *buf, std::size_t length) - { get_buf().buffer(buf, length); } -}; - -//Some typedefs to simplify usage -typedef basic_bufferbuf bufferbuf; -typedef basic_bufferstream bufferstream; -typedef basic_ibufferstream ibufferstream; -typedef basic_obufferstream obufferstream; - -typedef basic_bufferbuf wbufferbuf; -typedef basic_bufferstream wbufferstream; -typedef basic_ibufferstream wibufferstream; -typedef basic_obufferstream wobufferstream; - - -}} //namespace boost { namespace interprocess { - -#include - -#endif /* BOOST_INTERPROCESS_BUFFERSTREAM_HPP */ diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_mutex.hpp deleted file mode 100644 index 5615e8b9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_mutex.hpp +++ /dev/null @@ -1,184 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// Parts of the pthread code come from Boost Threads code. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MUTEX_HPP -#define BOOST_INTERPROCESS_MUTEX_HPP - -/// @cond - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include - -#if !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) && defined (BOOST_INTERPROCESS_POSIX_PROCESS_SHARED) - #include - #define BOOST_INTERPROCESS_USE_POSIX -//Experimental... -#elif !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) && defined (BOOST_INTERPROCESS_WINDOWS) - #include - #define BOOST_INTERPROCESS_USE_WINDOWS -#elif !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - #include - #define BOOST_INTERPROCESS_USE_GENERIC_EMULATION - -namespace boost { -namespace interprocess { -namespace ipcdetail{ -namespace robust_emulation_helpers { - -template -class mutex_traits; - -}}}} - -#endif - -/// @endcond - -//!\file -//!Describes a mutex class that can be placed in memory shared by -//!several processes. - -namespace boost { -namespace interprocess { - -class interprocess_condition; - -//!Wraps a interprocess_mutex that can be placed in shared memory and can be -//!shared between processes. Allows timed lock tries -class interprocess_mutex -{ - /// @cond - //Non-copyable - interprocess_mutex(const interprocess_mutex &); - interprocess_mutex &operator=(const interprocess_mutex &); - friend class interprocess_condition; - - public: - #if defined(BOOST_INTERPROCESS_USE_GENERIC_EMULATION) - #undef BOOST_INTERPROCESS_USE_GENERIC_EMULATION - typedef ipcdetail::spin_mutex internal_mutex_type; - private: - friend class ipcdetail::robust_emulation_helpers::mutex_traits; - void take_ownership(){ m_mutex.take_ownership(); } - public: - #elif defined(BOOST_INTERPROCESS_USE_POSIX) - #undef BOOST_INTERPROCESS_USE_POSIX - typedef ipcdetail::posix_mutex internal_mutex_type; - #elif defined(BOOST_INTERPROCESS_USE_WINDOWS) - #undef BOOST_INTERPROCESS_USE_WINDOWS - typedef ipcdetail::windows_mutex internal_mutex_type; - #else - #error "Unknown platform for interprocess_mutex" - #endif - - /// @endcond - public: - - //!Constructor. - //!Throws interprocess_exception on error. - interprocess_mutex(); - - //!Destructor. If any process uses the mutex after the destructor is called - //!the result is undefined. Does not throw. - ~interprocess_mutex(); - - //!Effects: The calling thread tries to obtain ownership of the mutex, and - //! if another thread has ownership of the mutex, it waits until it can - //! obtain the ownership. If a thread takes ownership of the mutex the - //! mutex must be unlocked by the same mutex. - //!Throws: interprocess_exception on error. - void lock(); - - //!Effects: The calling thread tries to obtain ownership of the mutex, and - //! if another thread has ownership of the mutex returns immediately. - //!Returns: If the thread acquires ownership of the mutex, returns true, if - //! the another thread has ownership of the mutex, returns false. - //!Throws: interprocess_exception on error. - bool try_lock(); - - //!Effects: The calling thread will try to obtain exclusive ownership of the - //! mutex if it can do so in until the specified time is reached. If the - //! mutex supports recursive locking, the mutex must be unlocked the same - //! number of times it is locked. - //!Returns: If the thread acquires ownership of the mutex, returns true, if - //! the timeout expires returns false. - //!Throws: interprocess_exception on error. - bool timed_lock(const boost::posix_time::ptime &abs_time); - - //!Effects: The calling thread releases the exclusive ownership of the mutex. - //!Throws: interprocess_exception on error. - void unlock(); - - /// @cond - internal_mutex_type &internal_mutex() - { return m_mutex; } - - const internal_mutex_type &internal_mutex() const - { return m_mutex; } - - private: - internal_mutex_type m_mutex; - /// @endcond -}; - -} //namespace interprocess { -} //namespace boost { - - -namespace boost { -namespace interprocess { - -inline interprocess_mutex::interprocess_mutex(){} - -inline interprocess_mutex::~interprocess_mutex(){} - -inline void interprocess_mutex::lock() -{ - #ifdef BOOST_INTERPROCESS_ENABLE_TIMEOUT_WHEN_LOCKING - boost::posix_time::ptime wait_time - = boost::posix_time::microsec_clock::universal_time() - + boost::posix_time::milliseconds(BOOST_INTERPROCESS_TIMEOUT_WHEN_LOCKING_DURATION_MS); - if (!m_mutex.timed_lock(wait_time)) - { - throw interprocess_exception(timeout_when_locking_error - , "Interprocess mutex timeout when locking. Possible deadlock: " - "owner died without unlocking?"); - } - #else - m_mutex.lock(); - #endif -} - -inline bool interprocess_mutex::try_lock() -{ return m_mutex.try_lock(); } - -inline bool interprocess_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ return m_mutex.timed_lock(abs_time); } - -inline void interprocess_mutex::unlock() -{ m_mutex.unlock(); } - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_recursive_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_recursive_mutex.hpp deleted file mode 100644 index 1c5dad37..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/interprocess_recursive_mutex.hpp +++ /dev/null @@ -1,177 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// Parts of the pthread code come from Boost Threads code: -// -////////////////////////////////////////////////////////////////////////////// -// -// Copyright (C) 2001-2003 -// William E. Kempf -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. William E. Kempf makes no representations -// about the suitability of this software for any purpose. -// It is provided "as is" without express or implied warranty. -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_RECURSIVE_MUTEX_HPP -#define BOOST_INTERPROCESS_RECURSIVE_MUTEX_HPP - -/// @cond - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include - -#if !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) && \ - (defined(BOOST_INTERPROCESS_POSIX_PROCESS_SHARED) && defined (BOOST_INTERPROCESS_POSIX_RECURSIVE_MUTEXES)) - #include - #define BOOST_INTERPROCESS_USE_POSIX -//Experimental... -#elif !defined(BOOST_INTERPROCESS_FORCE_GENERIC_EMULATION) && defined (BOOST_INTERPROCESS_WINDOWS) - #include - #define BOOST_INTERPROCESS_USE_WINDOWS -#elif !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) - #include - #define BOOST_INTERPROCESS_USE_GENERIC_EMULATION -#endif - -#if defined (BOOST_INTERPROCESS_USE_GENERIC_EMULATION) -namespace boost { -namespace interprocess { -namespace ipcdetail{ -namespace robust_emulation_helpers { - -template -class mutex_traits; - -}}}} - -#endif - -/// @endcond - -//!\file -//!Describes interprocess_recursive_mutex and shared_recursive_try_mutex classes - -namespace boost { -namespace interprocess { - -//!Wraps a interprocess_mutex that can be placed in shared memory and can be -//!shared between processes. Allows several locking calls by the same -//!process. Allows timed lock tries -class interprocess_recursive_mutex -{ - /// @cond - //Non-copyable - interprocess_recursive_mutex(const interprocess_recursive_mutex &); - interprocess_recursive_mutex &operator=(const interprocess_recursive_mutex &); - /// @endcond - public: - //!Constructor. - //!Throws interprocess_exception on error. - interprocess_recursive_mutex(); - - //!Destructor. If any process uses the mutex after the destructor is called - //!the result is undefined. Does not throw. - ~interprocess_recursive_mutex(); - - //!Effects: The calling thread tries to obtain ownership of the mutex, and - //! if another thread has ownership of the mutex, it waits until it can - //! obtain the ownership. If a thread takes ownership of the mutex the - //! mutex must be unlocked by the same mutex. The mutex must be unlocked - //! the same number of times it is locked. - //!Throws: interprocess_exception on error. - void lock(); - - //!Tries to lock the interprocess_mutex, returns false when interprocess_mutex - //!is already locked, returns true when success. The mutex must be unlocked - //!the same number of times it is locked. - //!Throws: interprocess_exception if a severe error is found - bool try_lock(); - - //!Tries to lock the interprocess_mutex, if interprocess_mutex can't be locked before - //!abs_time time, returns false. The mutex must be unlocked - //! the same number of times it is locked. - //!Throws: interprocess_exception if a severe error is found - bool timed_lock(const boost::posix_time::ptime &abs_time); - - //!Effects: The calling thread releases the exclusive ownership of the mutex. - //! If the mutex supports recursive locking, the mutex must be unlocked the - //! same number of times it is locked. - //!Throws: interprocess_exception on error. - void unlock(); - /// @cond - private: - - #if defined (BOOST_INTERPROCESS_USE_GENERIC_EMULATION) - #undef BOOST_INTERPROCESS_USE_GENERIC_EMULATION - void take_ownership(){ mutex.take_ownership(); } - friend class ipcdetail::robust_emulation_helpers::mutex_traits; - ipcdetail::spin_recursive_mutex mutex; - #elif defined(BOOST_INTERPROCESS_USE_POSIX) - #undef BOOST_INTERPROCESS_USE_POSIX - ipcdetail::posix_recursive_mutex mutex; - #elif defined(BOOST_INTERPROCESS_USE_WINDOWS) - #undef BOOST_INTERPROCESS_USE_WINDOWS - ipcdetail::windows_recursive_mutex mutex; - #else - #error "Unknown platform for interprocess_mutex" - #endif - /// @endcond -}; - -} //namespace interprocess { -} //namespace boost { - -namespace boost { -namespace interprocess { - -inline interprocess_recursive_mutex::interprocess_recursive_mutex(){} - -inline interprocess_recursive_mutex::~interprocess_recursive_mutex(){} - -inline void interprocess_recursive_mutex::lock() -{ - #ifdef BOOST_INTERPROCESS_ENABLE_TIMEOUT_WHEN_LOCKING - boost::posix_time::ptime wait_time - = boost::posix_time::microsec_clock::universal_time() - + boost::posix_time::milliseconds(BOOST_INTERPROCESS_TIMEOUT_WHEN_LOCKING_DURATION_MS); - if (!mutex.timed_lock(wait_time)){ - throw interprocess_exception(timeout_when_locking_error, "Interprocess mutex timeout when locking. Possible deadlock: owner died without unlocking?"); - } - #else - mutex.lock(); - #endif -} - -inline bool interprocess_recursive_mutex::try_lock() -{ return mutex.try_lock(); } - -inline bool interprocess_recursive_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ return mutex.timed_lock(abs_time); } - -inline void interprocess_recursive_mutex::unlock() -{ mutex.unlock(); } - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_RECURSIVE_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/lock_options.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/lock_options.hpp deleted file mode 100644 index 1139d83a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/lock_options.hpp +++ /dev/null @@ -1,55 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_LOCK_OPTIONS_HPP -#define BOOST_INTERPROCESS_LOCK_OPTIONS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -//!\file -//!Describes the lock options with associated with interprocess_mutex lock constructors. - -namespace boost { - -namespace posix_time -{ class ptime; } - -namespace interprocess { - -//!Type to indicate to a mutex lock constructor that must not lock the mutex. -struct defer_lock_type{}; -//!Type to indicate to a mutex lock constructor that must try to lock the mutex. -struct try_to_lock_type {}; -//!Type to indicate to a mutex lock constructor that the mutex is already locked. -struct accept_ownership_type{}; - -//!An object indicating that the locking -//!must be deferred. -static const defer_lock_type defer_lock = defer_lock_type(); - -//!An object indicating that a try_lock() -//!operation must be executed. -static const try_to_lock_type try_to_lock = try_to_lock_type(); - -//!An object indicating that the ownership of lockable -//!object must be accepted by the new owner. -static const accept_ownership_type accept_ownership = accept_ownership_type(); - -} // namespace interprocess { -} // namespace boost{ - -#include - -#endif // BOOST_INTERPROCESS_LOCK_OPTIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/mutex_family.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/mutex_family.hpp deleted file mode 100644 index 0636de0d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/mutex_family.hpp +++ /dev/null @@ -1,56 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_MUTEX_FAMILY_HPP -#define BOOST_INTERPROCESS_MUTEX_FAMILY_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include - -//!\file -//!Describes a shared interprocess_mutex family fit algorithm used to allocate objects in shared memory. - -namespace boost { - -namespace interprocess { - -//!Describes interprocess_mutex family to use with Interprocess framework -//!based on boost::interprocess synchronization objects. -struct mutex_family -{ - typedef boost::interprocess::interprocess_mutex mutex_type; - typedef boost::interprocess::interprocess_recursive_mutex recursive_mutex_type; -}; - -//!Describes interprocess_mutex family to use with Interprocess frameworks -//!based on null operation synchronization objects. -struct null_mutex_family -{ - typedef boost::interprocess::null_mutex mutex_type; - typedef boost::interprocess::null_mutex recursive_mutex_type; -}; - -} //namespace interprocess { - -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_MUTEX_FAMILY_HPP - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/null_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/null_mutex.hpp deleted file mode 100644 index d9f69a69..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/null_mutex.hpp +++ /dev/null @@ -1,147 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_NULL_MUTEX_HPP -#define BOOST_INTERPROCESS_NULL_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - - -//!\file -//!Describes null_mutex classes - -namespace boost { - -namespace posix_time -{ class ptime; } - -namespace interprocess { - -//!Implements a mutex that simulates a mutex without doing any operation and -//!simulates a successful operation. -class null_mutex -{ - /// @cond - null_mutex(const null_mutex&); - null_mutex &operator= (const null_mutex&); - /// @endcond - public: - - //!Constructor. - //!Empty. - null_mutex(){} - - //!Destructor. - //!Empty. - ~null_mutex(){} - - //!Simulates a mutex lock() operation. Empty function. - void lock(){} - - //!Simulates a mutex try_lock() operation. - //!Equivalent to "return true;" - bool try_lock() - { return true; } - - //!Simulates a mutex timed_lock() operation. - //!Equivalent to "return true;" - bool timed_lock(const boost::posix_time::ptime &) - { return true; } - - //!Simulates a mutex unlock() operation. - //!Empty function. - void unlock(){} - - //!Simulates a mutex lock_sharable() operation. - //!Empty function. - void lock_sharable(){} - - //!Simulates a mutex try_lock_sharable() operation. - //!Equivalent to "return true;" - bool try_lock_sharable() - { return true; } - - //!Simulates a mutex timed_lock_sharable() operation. - //!Equivalent to "return true;" - bool timed_lock_sharable(const boost::posix_time::ptime &) - { return true; } - - //!Simulates a mutex unlock_sharable() operation. - //!Empty function. - void unlock_sharable(){} - - //!Simulates a mutex lock_upgradable() operation. - //!Empty function. - void lock_upgradable(){} - - //!Simulates a mutex try_lock_upgradable() operation. - //!Equivalent to "return true;" - bool try_lock_upgradable() - { return true; } - - //!Simulates a mutex timed_lock_upgradable() operation. - //!Equivalent to "return true;" - bool timed_lock_upgradable(const boost::posix_time::ptime &) - { return true; } - - //!Simulates a mutex unlock_upgradable() operation. - //!Empty function. - void unlock_upgradable(){} - - //!Simulates unlock_and_lock_upgradable(). - //!Empty function. - void unlock_and_lock_upgradable(){} - - //!Simulates unlock_and_lock_sharable(). - //!Empty function. - void unlock_and_lock_sharable(){} - - //!Simulates unlock_upgradable_and_lock_sharable(). - //!Empty function. - void unlock_upgradable_and_lock_sharable(){} - - //Promotions - - //!Simulates unlock_upgradable_and_lock(). - //!Empty function. - void unlock_upgradable_and_lock(){} - - //!Simulates try_unlock_upgradable_and_lock(). - //!Equivalent to "return true;" - bool try_unlock_upgradable_and_lock() - { return true; } - - //!Simulates timed_unlock_upgradable_and_lock(). - //!Equivalent to "return true;" - bool timed_unlock_upgradable_and_lock(const boost::posix_time::ptime &) - { return true; } - - //!Simulates try_unlock_sharable_and_lock(). - //!Equivalent to "return true;" - bool try_unlock_sharable_and_lock() - { return true; } - - //!Simulates try_unlock_sharable_and_lock_upgradable(). - //!Equivalent to "return true;" - bool try_unlock_sharable_and_lock_upgradable() - { return true; } -}; - -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_NULL_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/mutex.hpp deleted file mode 100644 index 6bc45ca4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/mutex.hpp +++ /dev/null @@ -1,155 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// Parts of the pthread code come from Boost Threads code: -// -////////////////////////////////////////////////////////////////////////////// -// -// Copyright (C) 2001-2003 -// William E. Kempf -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. William E. Kempf makes no representations -// about the suitability of this software for any purpose. -// It is provided "as is" without express or implied warranty. -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_POSIX_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_POSIX_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -#ifndef BOOST_INTERPROCESS_POSIX_TIMEOUTS -# include -# include -#endif -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class posix_condition; - -class posix_mutex -{ - posix_mutex(const posix_mutex &); - posix_mutex &operator=(const posix_mutex &); - public: - - posix_mutex(); - ~posix_mutex(); - - void lock(); - bool try_lock(); - bool timed_lock(const boost::posix_time::ptime &abs_time); - void unlock(); - - friend class posix_condition; - - private: - pthread_mutex_t m_mut; -}; - -inline posix_mutex::posix_mutex() -{ - mutexattr_wrapper mut_attr; - mutex_initializer mut(m_mut, mut_attr); - mut.release(); -} - -inline posix_mutex::~posix_mutex() -{ - int res = pthread_mutex_destroy(&m_mut); - BOOST_ASSERT(res == 0);(void)res; -} - -inline void posix_mutex::lock() -{ - if (pthread_mutex_lock(&m_mut) != 0) - throw lock_exception(); -} - -inline bool posix_mutex::try_lock() -{ - int res = pthread_mutex_trylock(&m_mut); - if (!(res == 0 || res == EBUSY)) - throw lock_exception(); - return res == 0; -} - -inline bool posix_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ - if(abs_time == boost::posix_time::pos_infin){ - this->lock(); - return true; - } - #ifdef BOOST_INTERPROCESS_POSIX_TIMEOUTS - - timespec ts = ptime_to_timespec(abs_time); - int res = pthread_mutex_timedlock(&m_mut, &ts); - if (res != 0 && res != ETIMEDOUT) - throw lock_exception(); - return res == 0; - - #else //BOOST_INTERPROCESS_POSIX_TIMEOUTS - - //Obtain current count and target time - boost::posix_time::ptime now = microsec_clock::universal_time(); - - spin_wait swait; - do{ - if(this->try_lock()){ - break; - } - now = microsec_clock::universal_time(); - - if(now >= abs_time){ - return false; - } - // relinquish current time slice - swait.yield(); - }while (true); - return true; - - #endif //BOOST_INTERPROCESS_POSIX_TIMEOUTS -} - -inline void posix_mutex::unlock() -{ - int res = 0; - res = pthread_mutex_unlock(&m_mut); - (void)res; - BOOST_ASSERT(res == 0); -} - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_POSIX_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/pthread_helpers.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/pthread_helpers.hpp deleted file mode 100644 index 9e989d58..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/pthread_helpers.hpp +++ /dev/null @@ -1,168 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_PTHREAD_HELPERS_HPP -#define BOOST_INTERPROCESS_PTHREAD_HELPERS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail{ - - #if defined BOOST_INTERPROCESS_POSIX_PROCESS_SHARED - - //!Makes pthread_mutexattr_t cleanup easy when using exceptions - struct mutexattr_wrapper - { - //!Constructor - mutexattr_wrapper(bool recursive = false) - { - if(pthread_mutexattr_init(&m_attr)!=0 || - pthread_mutexattr_setpshared(&m_attr, PTHREAD_PROCESS_SHARED)!= 0 || - (recursive && - pthread_mutexattr_settype(&m_attr, PTHREAD_MUTEX_RECURSIVE)!= 0 )) - throw interprocess_exception("pthread_mutexattr_xxxx failed"); - } - - //!Destructor - ~mutexattr_wrapper() { pthread_mutexattr_destroy(&m_attr); } - - //!This allows using mutexattr_wrapper as pthread_mutexattr_t - operator pthread_mutexattr_t&() { return m_attr; } - - pthread_mutexattr_t m_attr; - }; - - //!Makes pthread_condattr_t cleanup easy when using exceptions - struct condattr_wrapper - { - //!Constructor - condattr_wrapper() - { - if(pthread_condattr_init(&m_attr)!=0 || - pthread_condattr_setpshared(&m_attr, PTHREAD_PROCESS_SHARED)!= 0) - throw interprocess_exception("pthread_condattr_xxxx failed"); - } - - //!Destructor - ~condattr_wrapper() { pthread_condattr_destroy(&m_attr); } - - //!This allows using condattr_wrapper as pthread_condattr_t - operator pthread_condattr_t&(){ return m_attr; } - - pthread_condattr_t m_attr; - }; - - //!Makes initialized pthread_mutex_t cleanup easy when using exceptions - class mutex_initializer - { - public: - //!Constructor. Takes interprocess_mutex attributes to initialize the interprocess_mutex - mutex_initializer(pthread_mutex_t &mut, pthread_mutexattr_t &mut_attr) - : mp_mut(&mut) - { - if(pthread_mutex_init(mp_mut, &mut_attr) != 0) - throw interprocess_exception("pthread_mutex_init failed"); - } - - ~mutex_initializer() { if(mp_mut) pthread_mutex_destroy(mp_mut); } - - void release() {mp_mut = 0; } - - private: - pthread_mutex_t *mp_mut; - }; - - //!Makes initialized pthread_cond_t cleanup easy when using exceptions - class condition_initializer - { - public: - condition_initializer(pthread_cond_t &cond, pthread_condattr_t &cond_attr) - : mp_cond(&cond) - { - if(pthread_cond_init(mp_cond, &cond_attr)!= 0) - throw interprocess_exception("pthread_cond_init failed"); - } - - ~condition_initializer() { if(mp_cond) pthread_cond_destroy(mp_cond); } - - void release() { mp_cond = 0; } - - private: - pthread_cond_t *mp_cond; - }; - - #endif // #if defined BOOST_INTERPROCESS_POSIX_PROCESS_SHARED - - #if defined(BOOST_INTERPROCESS_POSIX_BARRIERS) && defined(BOOST_INTERPROCESS_POSIX_PROCESS_SHARED) - - //!Makes pthread_barrierattr_t cleanup easy when using exceptions - struct barrierattr_wrapper - { - //!Constructor - barrierattr_wrapper() - { - if(pthread_barrierattr_init(&m_attr)!=0 || - pthread_barrierattr_setpshared(&m_attr, PTHREAD_PROCESS_SHARED)!= 0) - throw interprocess_exception("pthread_barrierattr_xxx failed"); - } - - //!Destructor - ~barrierattr_wrapper() { pthread_barrierattr_destroy(&m_attr); } - - //!This allows using mutexattr_wrapper as pthread_barrierattr_t - operator pthread_barrierattr_t&() { return m_attr; } - - pthread_barrierattr_t m_attr; - }; - - //!Makes initialized pthread_barrier_t cleanup easy when using exceptions - class barrier_initializer - { - public: - //!Constructor. Takes barrier attributes to initialize the barrier - barrier_initializer(pthread_barrier_t &mut, - pthread_barrierattr_t &mut_attr, - int count) - : mp_barrier(&mut) - { - if(pthread_barrier_init(mp_barrier, &mut_attr, count) != 0) - throw interprocess_exception("pthread_barrier_init failed"); - } - - ~barrier_initializer() { if(mp_barrier) pthread_barrier_destroy(mp_barrier); } - - void release() {mp_barrier = 0; } - - private: - pthread_barrier_t *mp_barrier; - }; - - #endif //#if defined(BOOST_INTERPROCESS_POSIX_BARRIERS) && defined(BOOST_INTERPROCESS_POSIX_PROCESS_SHARED) - -}//namespace ipcdetail - -}//namespace interprocess - -}//namespace boost - -#include - -#endif //ifdef BOOST_INTERPROCESS_PTHREAD_HELPERS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/ptime_to_timespec.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/ptime_to_timespec.hpp deleted file mode 100644 index 3e20dc70..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/ptime_to_timespec.hpp +++ /dev/null @@ -1,38 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_PTIME_TO_TIMESPEC_HPP -#define BOOST_INTERPROCESS_DETAIL_PTIME_TO_TIMESPEC_HPP - -#include - -namespace boost { - -namespace interprocess { - -namespace ipcdetail { - -inline timespec ptime_to_timespec (const boost::posix_time::ptime &tm) -{ - const boost::posix_time::ptime epoch(boost::gregorian::date(1970,1,1)); - boost::posix_time::time_duration duration (tm - epoch); - timespec ts; - ts.tv_sec = duration.total_seconds(); - ts.tv_nsec = duration.total_nanoseconds() % 1000000000; - return ts; -} - -} //namespace ipcdetail { - -} //namespace interprocess { - -} //namespace boost { - -#endif //ifndef BOOST_INTERPROCESS_DETAIL_PTIME_TO_TIMESPEC_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/recursive_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/recursive_mutex.hpp deleted file mode 100644 index ce2ad689..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/posix/recursive_mutex.hpp +++ /dev/null @@ -1,143 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// Parts of the pthread code come from Boost Threads code: -// -////////////////////////////////////////////////////////////////////////////// -// -// Copyright (C) 2001-2003 -// William E. Kempf -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. William E. Kempf makes no representations -// about the suitability of this software for any purpose. -// It is provided "as is" without express or implied warranty. -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_POSIX_RECURSIVE_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_POSIX_RECURSIVE_MUTEX_HPP - -#include -#include - -#include -#include -#include -#include -#include -#include -#ifndef BOOST_INTERPROCESS_POSIX_TIMEOUTS -# include -# include -#endif -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class posix_recursive_mutex -{ - posix_recursive_mutex(const posix_recursive_mutex &); - posix_recursive_mutex &operator=(const posix_recursive_mutex &); - public: - - posix_recursive_mutex(); - ~posix_recursive_mutex(); - - void lock(); - bool try_lock(); - bool timed_lock(const boost::posix_time::ptime &abs_time); - void unlock(); - - private: - pthread_mutex_t m_mut; -}; - -inline posix_recursive_mutex::posix_recursive_mutex() -{ - mutexattr_wrapper mut_attr(true); - mutex_initializer mut(m_mut, mut_attr); - mut.release(); -} - -inline posix_recursive_mutex::~posix_recursive_mutex() -{ - int res = pthread_mutex_destroy(&m_mut); - BOOST_ASSERT(res == 0);(void)res; -} - -inline void posix_recursive_mutex::lock() -{ - if (pthread_mutex_lock(&m_mut) != 0) - throw lock_exception(); -} - -inline bool posix_recursive_mutex::try_lock() -{ - int res = pthread_mutex_trylock(&m_mut); - if (!(res == 0 || res == EBUSY)) - throw lock_exception(); - return res == 0; -} - -inline bool posix_recursive_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ - if(abs_time == boost::posix_time::pos_infin){ - this->lock(); - return true; - } - #ifdef BOOST_INTERPROCESS_POSIX_TIMEOUTS - - timespec ts = ptime_to_timespec(abs_time); - int res = pthread_mutex_timedlock(&m_mut, &ts); - if (res != 0 && res != ETIMEDOUT) - throw lock_exception(); - return res == 0; - - #else //BOOST_INTERPROCESS_POSIX_TIMEOUTS - - //Obtain current count and target time - boost::posix_time::ptime now = microsec_clock::universal_time(); - spin_wait swait; - do{ - if(this->try_lock()){ - break; - } - now = microsec_clock::universal_time(); - - if(now >= abs_time){ - return false; - } - // relinquish current time slice - swait.yield(); - }while (true); - return true; - - #endif //BOOST_INTERPROCESS_POSIX_TIMEOUTS -} - -inline void posix_recursive_mutex::unlock() -{ - int res = 0; - res = pthread_mutex_unlock(&m_mut); - BOOST_ASSERT(res == 0); (void)res; -} - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTERPROCESS_DETAIL_POSIX_RECURSIVE_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/scoped_lock.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/scoped_lock.hpp deleted file mode 100644 index 5709f6ff..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/scoped_lock.hpp +++ /dev/null @@ -1,372 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// This interface is inspired by Howard Hinnant's lock proposal. -// http://home.twcny.rr.com/hinnant/cpp_extensions/threads_move.html -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_SCOPED_LOCK_HPP -#define BOOST_INTERPROCESS_SCOPED_LOCK_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -//!\file -//!Describes the scoped_lock class. - -namespace boost { -namespace interprocess { - - -//!scoped_lock is meant to carry out the tasks for locking, unlocking, try-locking -//!and timed-locking (recursive or not) for the Mutex. The Mutex need not supply all -//!of this functionality. If the client of scoped_lock does not use -//!functionality which the Mutex does not supply, no harm is done. Mutex ownership -//!transfer is supported through the syntax of move semantics. Ownership transfer -//!is allowed both by construction and assignment. The scoped_lock does not support -//!copy semantics. A compile time error results if copy construction or copy -//!assignment is attempted. Mutex ownership can also be moved from an -//!upgradable_lock and sharable_lock via constructor. In this role, scoped_lock -//!shares the same functionality as a write_lock. -template -class scoped_lock -{ - /// @cond - private: - typedef scoped_lock this_type; - BOOST_MOVABLE_BUT_NOT_COPYABLE(scoped_lock) - typedef bool this_type::*unspecified_bool_type; - /// @endcond - public: - - typedef Mutex mutex_type; - - //!Effects: Default constructs a scoped_lock. - //!Postconditions: owns() == false and mutex() == 0. - scoped_lock() - : mp_mutex(0), m_locked(false) - {} - - //!Effects: m.lock(). - //!Postconditions: owns() == true and mutex() == &m. - //!Notes: The constructor will take ownership of the mutex. If another thread - //! already owns the mutex, this thread will block until the mutex is released. - //! Whether or not this constructor handles recursive locking depends upon the mutex. - explicit scoped_lock(mutex_type& m) - : mp_mutex(&m), m_locked(false) - { mp_mutex->lock(); m_locked = true; } - - //!Postconditions: owns() == false, and mutex() == &m. - //!Notes: The constructor will not take ownership of the mutex. There is no effect - //! required on the referenced mutex. - scoped_lock(mutex_type& m, defer_lock_type) - : mp_mutex(&m), m_locked(false) - {} - - //!Postconditions: owns() == true, and mutex() == &m. - //!Notes: The constructor will suppose that the mutex is already locked. There - //! is no effect required on the referenced mutex. - scoped_lock(mutex_type& m, accept_ownership_type) - : mp_mutex(&m), m_locked(true) - {} - - //!Effects: m.try_lock(). - //!Postconditions: mutex() == &m. owns() == the return value of the - //! m.try_lock() executed within the constructor. - //!Notes: The constructor will take ownership of the mutex if it can do - //! so without waiting. Whether or not this constructor handles recursive - //! locking depends upon the mutex. If the mutex_type does not support try_lock, - //! this constructor will fail at compile time if instantiated, but otherwise - //! have no effect. - scoped_lock(mutex_type& m, try_to_lock_type) - : mp_mutex(&m), m_locked(mp_mutex->try_lock()) - {} - - //!Effects: m.timed_lock(abs_time). - //!Postconditions: mutex() == &m. owns() == the return value of the - //! m.timed_lock(abs_time) executed within the constructor. - //!Notes: The constructor will take ownership of the mutex if it can do - //! it until abs_time is reached. Whether or not this constructor - //! handles recursive locking depends upon the mutex. If the mutex_type - //! does not support try_lock, this constructor will fail at compile - //! time if instantiated, but otherwise have no effect. - scoped_lock(mutex_type& m, const boost::posix_time::ptime& abs_time) - : mp_mutex(&m), m_locked(mp_mutex->timed_lock(abs_time)) - {} - - //!Postconditions: mutex() == the value scop.mutex() had before the - //! constructor executes. s1.mutex() == 0. owns() == the value of - //! scop.owns() before the constructor executes. scop.owns(). - //!Notes: If the scop scoped_lock owns the mutex, ownership is moved - //! to thisscoped_lock with no blocking. If the scop scoped_lock does not - //! own the mutex, then neither will this scoped_lock. Only a moved - //! scoped_lock's will match this signature. An non-moved scoped_lock - //! can be moved with the expression: "boost::move(lock);". This - //! constructor does not alter the state of the mutex, only potentially - //! who owns it. - scoped_lock(BOOST_RV_REF(scoped_lock) scop) - : mp_mutex(0), m_locked(scop.owns()) - { mp_mutex = scop.release(); } - - //!Effects: If upgr.owns() then calls unlock_upgradable_and_lock() on the - //! referenced mutex. upgr.release() is called. - //!Postconditions: mutex() == the value upgr.mutex() had before the construction. - //! upgr.mutex() == 0. owns() == upgr.owns() before the construction. - //! upgr.owns() == false after the construction. - //!Notes: If upgr is locked, this constructor will lock this scoped_lock while - //! unlocking upgr. If upgr is unlocked, then this scoped_lock will be - //! unlocked as well. Only a moved upgradable_lock's will match this - //! signature. An non-moved upgradable_lock can be moved with - //! the expression: "boost::move(lock);" This constructor may block if - //! other threads hold a sharable_lock on this mutex (sharable_lock's can - //! share ownership with an upgradable_lock). - template - explicit scoped_lock(BOOST_RV_REF(upgradable_lock) upgr - , typename ipcdetail::enable_if< ipcdetail::is_same >::type * = 0) - : mp_mutex(0), m_locked(false) - { - upgradable_lock &u_lock = upgr; - if(u_lock.owns()){ - u_lock.mutex()->unlock_upgradable_and_lock(); - m_locked = true; - } - mp_mutex = u_lock.release(); - } - - //!Effects: If upgr.owns() then calls try_unlock_upgradable_and_lock() on the - //!referenced mutex: - //! a)if try_unlock_upgradable_and_lock() returns true then mutex() obtains - //! the value from upgr.release() and owns() is set to true. - //! b)if try_unlock_upgradable_and_lock() returns false then upgr is - //! unaffected and this scoped_lock construction as the same effects as - //! a default construction. - //! c)Else upgr.owns() is false. mutex() obtains the value from upgr.release() - //! and owns() is set to false - //!Notes: This construction will not block. It will try to obtain mutex - //! ownership from upgr immediately, while changing the lock type from a - //! "read lock" to a "write lock". If the "read lock" isn't held in the - //! first place, the mutex merely changes type to an unlocked "write lock". - //! If the "read lock" is held, then mutex transfer occurs only if it can - //! do so in a non-blocking manner. - template - scoped_lock(BOOST_RV_REF(upgradable_lock) upgr, try_to_lock_type - , typename ipcdetail::enable_if< ipcdetail::is_same >::type * = 0) - : mp_mutex(0), m_locked(false) - { - upgradable_lock &u_lock = upgr; - if(u_lock.owns()){ - if((m_locked = u_lock.mutex()->try_unlock_upgradable_and_lock()) == true){ - mp_mutex = u_lock.release(); - } - } - else{ - u_lock.release(); - } - } - - //!Effects: If upgr.owns() then calls timed_unlock_upgradable_and_lock(abs_time) - //! on the referenced mutex: - //! a)if timed_unlock_upgradable_and_lock(abs_time) returns true then mutex() - //! obtains the value from upgr.release() and owns() is set to true. - //! b)if timed_unlock_upgradable_and_lock(abs_time) returns false then upgr - //! is unaffected and this scoped_lock construction as the same effects - //! as a default construction. - //! c)Else upgr.owns() is false. mutex() obtains the value from upgr.release() - //! and owns() is set to false - //!Notes: This construction will not block. It will try to obtain mutex ownership - //! from upgr immediately, while changing the lock type from a "read lock" to a - //! "write lock". If the "read lock" isn't held in the first place, the mutex - //! merely changes type to an unlocked "write lock". If the "read lock" is held, - //! then mutex transfer occurs only if it can do so in a non-blocking manner. - template - scoped_lock(BOOST_RV_REF(upgradable_lock) upgr, boost::posix_time::ptime &abs_time - , typename ipcdetail::enable_if< ipcdetail::is_same >::type * = 0) - : mp_mutex(0), m_locked(false) - { - upgradable_lock &u_lock = upgr; - if(u_lock.owns()){ - if((m_locked = u_lock.mutex()->timed_unlock_upgradable_and_lock(abs_time)) == true){ - mp_mutex = u_lock.release(); - } - } - else{ - u_lock.release(); - } - } - - //!Effects: If shar.owns() then calls try_unlock_sharable_and_lock() on the - //!referenced mutex. - //! a)if try_unlock_sharable_and_lock() returns true then mutex() obtains - //! the value from shar.release() and owns() is set to true. - //! b)if try_unlock_sharable_and_lock() returns false then shar is - //! unaffected and this scoped_lock construction has the same - //! effects as a default construction. - //! c)Else shar.owns() is false. mutex() obtains the value from - //! shar.release() and owns() is set to false - //!Notes: This construction will not block. It will try to obtain mutex - //! ownership from shar immediately, while changing the lock type from a - //! "read lock" to a "write lock". If the "read lock" isn't held in the - //! first place, the mutex merely changes type to an unlocked "write lock". - //! If the "read lock" is held, then mutex transfer occurs only if it can - //! do so in a non-blocking manner. - template - scoped_lock(BOOST_RV_REF(sharable_lock) shar, try_to_lock_type - , typename ipcdetail::enable_if< ipcdetail::is_same >::type * = 0) - : mp_mutex(0), m_locked(false) - { - sharable_lock &s_lock = shar; - if(s_lock.owns()){ - if((m_locked = s_lock.mutex()->try_unlock_sharable_and_lock()) == true){ - mp_mutex = s_lock.release(); - } - } - else{ - s_lock.release(); - } - } - - //!Effects: if (owns()) mp_mutex->unlock(). - //!Notes: The destructor behavior ensures that the mutex lock is not leaked.*/ - ~scoped_lock() - { - try{ if(m_locked && mp_mutex) mp_mutex->unlock(); } - catch(...){} - } - - //!Effects: If owns() before the call, then unlock() is called on mutex(). - //! *this gets the state of scop and scop gets set to a default constructed state. - //!Notes: With a recursive mutex it is possible that both this and scop own - //! the same mutex before the assignment. In this case, this will own the - //! mutex after the assignment (and scop will not), but the mutex's lock - //! count will be decremented by one. - scoped_lock &operator=(BOOST_RV_REF(scoped_lock) scop) - { - if(this->owns()) - this->unlock(); - m_locked = scop.owns(); - mp_mutex = scop.release(); - return *this; - } - - //!Effects: If mutex() == 0 or if already locked, throws a lock_exception() - //! exception. Calls lock() on the referenced mutex. - //!Postconditions: owns() == true. - //!Notes: The scoped_lock changes from a state of not owning the mutex, to - //! owning the mutex, blocking if necessary. - void lock() - { - if(!mp_mutex || m_locked) - throw lock_exception(); - mp_mutex->lock(); - m_locked = true; - } - - //!Effects: If mutex() == 0 or if already locked, throws a lock_exception() - //! exception. Calls try_lock() on the referenced mutex. - //!Postconditions: owns() == the value returned from mutex()->try_lock(). - //!Notes: The scoped_lock changes from a state of not owning the mutex, to - //! owning the mutex, but only if blocking was not required. If the - //! mutex_type does not support try_lock(), this function will fail at - //! compile time if instantiated, but otherwise have no effect.*/ - bool try_lock() - { - if(!mp_mutex || m_locked) - throw lock_exception(); - m_locked = mp_mutex->try_lock(); - return m_locked; - } - - //!Effects: If mutex() == 0 or if already locked, throws a lock_exception() - //! exception. Calls timed_lock(abs_time) on the referenced mutex. - //!Postconditions: owns() == the value returned from mutex()-> timed_lock(abs_time). - //!Notes: The scoped_lock changes from a state of not owning the mutex, to - //! owning the mutex, but only if it can obtain ownership by the specified - //! time. If the mutex_type does not support timed_lock (), this function - //! will fail at compile time if instantiated, but otherwise have no effect.*/ - bool timed_lock(const boost::posix_time::ptime& abs_time) - { - if(!mp_mutex || m_locked) - throw lock_exception(); - m_locked = mp_mutex->timed_lock(abs_time); - return m_locked; - } - - //!Effects: If mutex() == 0 or if not locked, throws a lock_exception() - //! exception. Calls unlock() on the referenced mutex. - //!Postconditions: owns() == false. - //!Notes: The scoped_lock changes from a state of owning the mutex, to not - //! owning the mutex.*/ - void unlock() - { - if(!mp_mutex || !m_locked) - throw lock_exception(); - mp_mutex->unlock(); - m_locked = false; - } - - //!Effects: Returns true if this scoped_lock has acquired - //!the referenced mutex. - bool owns() const - { return m_locked && mp_mutex; } - - //!Conversion to bool. - //!Returns owns(). - operator unspecified_bool_type() const - { return m_locked? &this_type::m_locked : 0; } - - //!Effects: Returns a pointer to the referenced mutex, or 0 if - //!there is no mutex to reference. - mutex_type* mutex() const - { return mp_mutex; } - - //!Effects: Returns a pointer to the referenced mutex, or 0 if there is no - //! mutex to reference. - //!Postconditions: mutex() == 0 and owns() == false. - mutex_type* release() - { - mutex_type *mut = mp_mutex; - mp_mutex = 0; - m_locked = false; - return mut; - } - - //!Effects: Swaps state with moved lock. - //!Throws: Nothing. - void swap( scoped_lock &other) - { - std::swap(mp_mutex, other.mp_mutex); - std::swap(m_locked, other.m_locked); - } - - /// @cond - private: - mutex_type *mp_mutex; - bool m_locked; - /// @endcond -}; - -} // namespace interprocess -} // namespace boost - -#include - -#endif // BOOST_INTERPROCESS_SCOPED_LOCK_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/mutex.hpp deleted file mode 100644 index 7a77549e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/mutex.hpp +++ /dev/null @@ -1,117 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_SPIN_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_SPIN_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class spin_mutex -{ - spin_mutex(const spin_mutex &); - spin_mutex &operator=(const spin_mutex &); - public: - - spin_mutex(); - ~spin_mutex(); - - void lock(); - bool try_lock(); - bool timed_lock(const boost::posix_time::ptime &abs_time); - void unlock(); - void take_ownership(){}; - private: - volatile boost::uint32_t m_s; -}; - -inline spin_mutex::spin_mutex() - : m_s(0) -{ - //Note that this class is initialized to zero. - //So zeroed memory can be interpreted as an - //initialized mutex -} - -inline spin_mutex::~spin_mutex() -{ - //Trivial destructor -} - -inline void spin_mutex::lock(void) -{ - spin_wait swait; - do{ - boost::uint32_t prev_s = ipcdetail::atomic_cas32(const_cast(&m_s), 1, 0); - - if (m_s == 1 && prev_s == 0){ - break; - } - // relinquish current timeslice - swait.yield(); - }while (true); -} - -inline bool spin_mutex::try_lock(void) -{ - boost::uint32_t prev_s = ipcdetail::atomic_cas32(const_cast(&m_s), 1, 0); - return m_s == 1 && prev_s == 0; -} - -inline bool spin_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ - if(abs_time == boost::posix_time::pos_infin){ - this->lock(); - return true; - } - //Obtain current count and target time - boost::posix_time::ptime now = microsec_clock::universal_time(); - - spin_wait swait; - do{ - if(this->try_lock()){ - break; - } - now = microsec_clock::universal_time(); - - if(now >= abs_time){ - return false; - } - // relinquish current time slice - swait.yield(); - }while (true); - - return true; -} - -inline void spin_mutex::unlock(void) -{ ipcdetail::atomic_cas32(const_cast(&m_s), 0, 1); } - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_SPIN_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/recursive_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/recursive_mutex.hpp deleted file mode 100644 index 38e9dcaa..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/recursive_mutex.hpp +++ /dev/null @@ -1,175 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// -// -// Parts of the pthread code come from Boost Threads code: -// -////////////////////////////////////////////////////////////////////////////// -// -// Copyright (C) 2001-2003 -// William E. Kempf -// -// Permission to use, copy, modify, distribute and sell this software -// and its documentation for any purpose is hereby granted without fee, -// provided that the above copyright notice appear in all copies and -// that both that copyright notice and this permission notice appear -// in supporting documentation. William E. Kempf makes no representations -// about the suitability of this software for any purpose. -// It is provided "as is" without express or implied warranty. -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_SPIN_RECURSIVE_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_SPIN_RECURSIVE_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class spin_recursive_mutex -{ - spin_recursive_mutex(const spin_recursive_mutex &); - spin_recursive_mutex &operator=(const spin_recursive_mutex &); - public: - - spin_recursive_mutex(); - ~spin_recursive_mutex(); - - void lock(); - bool try_lock(); - bool timed_lock(const boost::posix_time::ptime &abs_time); - void unlock(); - void take_ownership(); - private: - spin_mutex m_mutex; - unsigned int m_nLockCount; - volatile ipcdetail::OS_systemwide_thread_id_t m_nOwner; - volatile boost::uint32_t m_s; -}; - -inline spin_recursive_mutex::spin_recursive_mutex() - : m_nLockCount(0), m_nOwner(ipcdetail::get_invalid_systemwide_thread_id()){} - -inline spin_recursive_mutex::~spin_recursive_mutex(){} - -inline void spin_recursive_mutex::lock() -{ - typedef ipcdetail::OS_systemwide_thread_id_t handle_t; - const handle_t thr_id(ipcdetail::get_current_systemwide_thread_id()); - handle_t old_id; - ipcdetail::systemwide_thread_id_copy(m_nOwner, old_id); - if(ipcdetail::equal_systemwide_thread_id(thr_id , old_id)){ - if((unsigned int)(m_nLockCount+1) == 0){ - //Overflow, throw an exception - throw interprocess_exception("boost::interprocess::spin_recursive_mutex recursive lock overflow"); - } - ++m_nLockCount; - } - else{ - m_mutex.lock(); - ipcdetail::systemwide_thread_id_copy(thr_id, m_nOwner); - m_nLockCount = 1; - } -} - -inline bool spin_recursive_mutex::try_lock() -{ - typedef ipcdetail::OS_systemwide_thread_id_t handle_t; - handle_t thr_id(ipcdetail::get_current_systemwide_thread_id()); - handle_t old_id; - ipcdetail::systemwide_thread_id_copy(m_nOwner, old_id); - if(ipcdetail::equal_systemwide_thread_id(thr_id , old_id)) { // we own it - if((unsigned int)(m_nLockCount+1) == 0){ - //Overflow, throw an exception - throw interprocess_exception("boost::interprocess::spin_recursive_mutex recursive lock overflow"); - } - ++m_nLockCount; - return true; - } - if(m_mutex.try_lock()){ - ipcdetail::systemwide_thread_id_copy(thr_id, m_nOwner); - m_nLockCount = 1; - return true; - } - return false; -} - -inline bool spin_recursive_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ - typedef ipcdetail::OS_systemwide_thread_id_t handle_t; - if(abs_time == boost::posix_time::pos_infin){ - this->lock(); - return true; - } - const handle_t thr_id(ipcdetail::get_current_systemwide_thread_id()); - handle_t old_id; - ipcdetail::systemwide_thread_id_copy(m_nOwner, old_id); - if(ipcdetail::equal_systemwide_thread_id(thr_id , old_id)) { // we own it - if((unsigned int)(m_nLockCount+1) == 0){ - //Overflow, throw an exception - throw interprocess_exception("boost::interprocess::spin_recursive_mutex recursive lock overflow"); - } - ++m_nLockCount; - return true; - } - if(m_mutex.timed_lock(abs_time)){ - ipcdetail::systemwide_thread_id_copy(thr_id, m_nOwner); - m_nLockCount = 1; - return true; - } - return false; -} - -inline void spin_recursive_mutex::unlock() -{ - typedef ipcdetail::OS_systemwide_thread_id_t handle_t; - handle_t old_id; - ipcdetail::systemwide_thread_id_copy(m_nOwner, old_id); - const handle_t thr_id(ipcdetail::get_current_systemwide_thread_id()); - (void)old_id; - (void)thr_id; - BOOST_ASSERT(ipcdetail::equal_systemwide_thread_id(thr_id, old_id)); - --m_nLockCount; - if(!m_nLockCount){ - const handle_t new_id(ipcdetail::get_invalid_systemwide_thread_id()); - ipcdetail::systemwide_thread_id_copy(new_id, m_nOwner); - m_mutex.unlock(); - } -} - -inline void spin_recursive_mutex::take_ownership() -{ - typedef ipcdetail::OS_systemwide_thread_id_t handle_t; - this->m_nLockCount = 1; - const handle_t thr_id(ipcdetail::get_current_systemwide_thread_id()); - ipcdetail::systemwide_thread_id_copy(thr_id, m_nOwner); -} - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_SPIN_RECURSIVE_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/wait.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/wait.hpp deleted file mode 100644 index 0707bd8d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/spin/wait.hpp +++ /dev/null @@ -1,181 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Peter Dimov 2008. -// (C) Copyright Ion Gaztanaga 2013-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -//Parts of this file come from boost/smart_ptr/detail/yield_k.hpp -//Many thanks to Peter Dimov. - -#ifndef BOOST_INTERPROCESS_SYNC_WAIT_HPP_INCLUDED -#define BOOST_INTERPROCESS_SYNC_WAIT_HPP_INCLUDED - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -//#define BOOST_INTERPROCESS_SPIN_WAIT_DEBUG -#ifdef BOOST_INTERPROCESS_SPIN_WAIT_DEBUG -#include -#endif - -// BOOST_INTERPROCESS_SMT_PAUSE - -#if defined(_MSC_VER) && _MSC_VER >= 1310 && ( defined(_M_IX86) || defined(_M_X64) ) - -extern "C" void _mm_pause(); -#pragma intrinsic( _mm_pause ) - -#define BOOST_INTERPROCESS_SMT_PAUSE _mm_pause(); - -#elif defined(__GNUC__) && ( defined(__i386__) || defined(__x86_64__) ) - -#define BOOST_INTERPROCESS_SMT_PAUSE __asm__ __volatile__( "rep; nop" : : : "memory" ); - -#endif - -namespace boost{ -namespace interprocess{ -namespace ipcdetail { - -template -class num_core_holder -{ - public: - static unsigned int get() - { - if(!num_cores){ - return ipcdetail::get_num_cores(); - } - else{ - return num_cores; - } - } - - private: - static unsigned int num_cores; -}; - -template -unsigned int num_core_holder::num_cores = ipcdetail::get_num_cores(); - -} //namespace ipcdetail { - -class spin_wait -{ - public: - - static const unsigned int nop_pause_limit = 32u; - spin_wait() - : m_count_start(), m_ul_yield_only_counts(), m_k() - {} - - #ifdef BOOST_INTERPROCESS_SPIN_WAIT_DEBUG - ~spin_wait() - { - if(m_k){ - std::cout << "final m_k: " << m_k - << " system tick(us): " << ipcdetail::get_system_tick_us() << std::endl; - } - } - #endif - - unsigned int count() const - { return m_k; } - - void yield() - { - //Lazy initialization of limits - if( !m_k){ - this->init_limits(); - } - //Nop tries - if( m_k < (nop_pause_limit >> 2) ){ - - } - //Pause tries if the processor supports it - #if defined(BOOST_INTERPROCESS_SMT_PAUSE) - else if( m_k < nop_pause_limit ){ - BOOST_INTERPROCESS_SMT_PAUSE - } - #endif - //Yield/Sleep strategy - else{ - //Lazy initialization of tick information - if(m_k == nop_pause_limit){ - this->init_tick_info(); - } - else if( this->yield_or_sleep() ){ - ipcdetail::thread_yield(); - } - else{ - ipcdetail::thread_sleep_tick(); - } - } - ++m_k; - } - - void reset() - { - m_k = 0u; - } - - private: - - void init_limits() - { - unsigned int num_cores = ipcdetail::num_core_holder<0>::get(); - m_k = num_cores > 1u ? 0u : nop_pause_limit; - } - - void init_tick_info() - { - m_ul_yield_only_counts = ipcdetail::get_system_tick_in_highres_counts(); - m_count_start = ipcdetail::get_current_system_highres_count(); - } - - //Returns true if yield must be called, false is sleep must be called - bool yield_or_sleep() - { - if(!m_ul_yield_only_counts){ //If yield-only limit was reached then yield one in every two tries - return (m_k & 1u) != 0; - } - else{ //Try to see if we've reched yield-only time limit - const ipcdetail::OS_highres_count_t now = ipcdetail::get_current_system_highres_count(); - const ipcdetail::OS_highres_count_t elapsed = ipcdetail::system_highres_count_subtract(now, m_count_start); - if(!ipcdetail::system_highres_count_less_ul(elapsed, m_ul_yield_only_counts)){ - #ifdef BOOST_INTERPROCESS_SPIN_WAIT_DEBUG - std::cout << "elapsed!\n" - << " m_ul_yield_only_counts: " << m_ul_yield_only_counts - << " system tick(us): " << ipcdetail::get_system_tick_us() << '\n' - << " m_k: " << m_k << " elapsed counts: "; - ipcdetail::ostream_highres_count(std::cout, elapsed) << std::endl; - #endif - //Yield-only time reached, now it's time to sleep - m_ul_yield_only_counts = 0ul; - return false; - } - } - return true; //Otherwise yield - } - - ipcdetail::OS_highres_count_t m_count_start; - unsigned long m_ul_yield_only_counts; - unsigned int m_k; -}; - -} // namespace interprocess -} // namespace boost - -#include - -#endif // #ifndef BOOST_INTERPROCESS_SYNC_WAIT_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/mutex.hpp deleted file mode 100644 index c8a64b3b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/mutex.hpp +++ /dev/null @@ -1,114 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_WINDOWS_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_WINDOWS_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class windows_mutex -{ - windows_mutex(const windows_mutex &); - windows_mutex &operator=(const windows_mutex &); - public: - - windows_mutex(); - ~windows_mutex(); - - void lock(); - bool try_lock(); - bool timed_lock(const boost::posix_time::ptime &abs_time); - void unlock(); - void take_ownership(){}; - - private: - const sync_id id_; -}; - -inline windows_mutex::windows_mutex() - : id_(this) -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - //Create mutex with the initial count - bool open_or_created; - (void)handles.obtain_mutex(this->id_, &open_or_created); - //The mutex must be created, never opened - BOOST_ASSERT(open_or_created); - BOOST_ASSERT(open_or_created && winapi::get_last_error() != winapi::error_already_exists); - (void)open_or_created; -} - -inline windows_mutex::~windows_mutex() -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - handles.destroy_handle(this->id_); -} - -inline void windows_mutex::lock(void) -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - //This can throw - winapi_mutex_functions mut(handles.obtain_mutex(this->id_)); - mut.lock(); -} - -inline bool windows_mutex::try_lock(void) -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - //This can throw - winapi_mutex_functions mut(handles.obtain_mutex(this->id_)); - return mut.try_lock(); -} - -inline bool windows_mutex::timed_lock(const boost::posix_time::ptime &abs_time) -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - //This can throw - winapi_mutex_functions mut(handles.obtain_mutex(this->id_)); - return mut.timed_lock(abs_time); -} - -inline void windows_mutex::unlock(void) -{ - sync_handles &handles = - windows_intermodule_singleton::get(); - //This can throw - winapi_mutex_functions mut(handles.obtain_mutex(this->id_)); - return mut.unlock(); -} - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_WINDOWS_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/recursive_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/recursive_mutex.hpp deleted file mode 100644 index 2b4797e1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/recursive_mutex.hpp +++ /dev/null @@ -1,43 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_WINDOWS_RECURSIVE_MUTEX_HPP -#define BOOST_INTERPROCESS_DETAIL_WINDOWS_RECURSIVE_MUTEX_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -//Windows mutex is already recursive -class windows_recursive_mutex - : public windows_mutex -{ - windows_recursive_mutex(const windows_recursive_mutex &); - windows_recursive_mutex &operator=(const windows_recursive_mutex &); - public: - windows_recursive_mutex() : windows_mutex() {} -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_WINDOWS_RECURSIVE_MUTEX_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/sync_utils.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/sync_utils.hpp deleted file mode 100644 index 92d8e55a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/sync_utils.hpp +++ /dev/null @@ -1,236 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_SYNC_UTILS_HPP -#define BOOST_INTERPROCESS_DETAIL_SYNC_UTILS_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - -//Shield against external warnings -#include - #include -#include - - -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -inline bool bytes_to_str(const void *mem, const std::size_t mem_length, char *out_str, std::size_t &out_length) -{ - const std::size_t need_mem = mem_length*2+1; - if(out_length < need_mem){ - out_length = need_mem; - return false; - } - - const char Characters [] = - { '0', '1', '2', '3', '4', '5', '6', '7' - , '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; - - std::size_t char_counter = 0; - const char *buf = (const char *)mem; - for(std::size_t i = 0; i != mem_length; ++i){ - out_str[char_counter++] = Characters[(buf[i]&0xF0)>>4]; - out_str[char_counter++] = Characters[(buf[i]&0x0F)]; - } - out_str[char_counter] = 0; - return true; -} - -class sync_id -{ - public: - typedef __int64 internal_type; - sync_id(const void *map_addr) - : map_addr_(map_addr) - { winapi::query_performance_counter(&rand_); } - - explicit sync_id(internal_type val, const void *map_addr) - : map_addr_(map_addr) - { rand_ = val; } - - const internal_type &internal_pod() const - { return rand_; } - - internal_type &internal_pod() - { return rand_; } - - const void *map_address() const - { return map_addr_; } - - friend std::size_t hash_value(const sync_id &m) - { return boost::hash_value(m.rand_); } - - friend bool operator==(const sync_id &l, const sync_id &r) - { return l.rand_ == r.rand_ && l.map_addr_ == r.map_addr_; } - - private: - internal_type rand_; - const void * const map_addr_; -}; - -class sync_handles -{ - public: - enum type { MUTEX, SEMAPHORE }; - - private: - struct address_less - { - bool operator()(sync_id const * const l, sync_id const * const r) const - { return l->map_address() < r->map_address(); } - }; - - typedef boost::unordered_map umap_type; - typedef boost::container::map map_type; - static const std::size_t LengthOfGlobal = sizeof("Global\\boost.ipc")-1; - static const std::size_t StrSize = LengthOfGlobal + (sizeof(sync_id)*2+1); - typedef char NameBuf[StrSize]; - - - void fill_name(NameBuf &name, const sync_id &id) - { - const char *n = "Global\\boost.ipc"; - std::size_t i = 0; - do{ - name[i] = n[i]; - ++i; - } while(n[i]); - std::size_t len = sizeof(NameBuf) - LengthOfGlobal; - bytes_to_str(&id.internal_pod(), sizeof(id.internal_pod()), &name[LengthOfGlobal], len); - } - - void throw_if_error(void *hnd_val) - { - if(!hnd_val){ - error_info err(winapi::get_last_error()); - throw interprocess_exception(err); - } - } - - void* open_or_create_semaphore(const sync_id &id, unsigned int initial_count) - { - NameBuf name; - fill_name(name, id); - permissions unrestricted_security; - unrestricted_security.set_unrestricted(); - winapi_semaphore_wrapper sem_wrapper; - bool created; - sem_wrapper.open_or_create - (name, (long)initial_count, winapi_semaphore_wrapper::MaxCount, unrestricted_security, created); - throw_if_error(sem_wrapper.handle()); - return sem_wrapper.release(); - } - - void* open_or_create_mutex(const sync_id &id) - { - NameBuf name; - fill_name(name, id); - permissions unrestricted_security; - unrestricted_security.set_unrestricted(); - winapi_mutex_wrapper mtx_wrapper; - mtx_wrapper.open_or_create(name, unrestricted_security); - throw_if_error(mtx_wrapper.handle()); - return mtx_wrapper.release(); - } - - public: - void *obtain_mutex(const sync_id &id, bool *popen_created = 0) - { - umap_type::value_type v(id, (void*)0); - scoped_lock lock(mtx_); - umap_type::iterator it = umap_.insert(v).first; - void *&hnd_val = it->second; - if(!hnd_val){ - map_[&it->first] = it; - hnd_val = open_or_create_mutex(id); - if(popen_created) *popen_created = true; - } - else if(popen_created){ - *popen_created = false; - } - return hnd_val; - } - - void *obtain_semaphore(const sync_id &id, unsigned int initial_count, bool *popen_created = 0) - { - umap_type::value_type v(id, (void*)0); - scoped_lock lock(mtx_); - umap_type::iterator it = umap_.insert(v).first; - void *&hnd_val = it->second; - if(!hnd_val){ - map_[&it->first] = it; - hnd_val = open_or_create_semaphore(id, initial_count); - if(popen_created) *popen_created = true; - } - else if(popen_created){ - *popen_created = false; - } - return hnd_val; - } - - void destroy_handle(const sync_id &id) - { - scoped_lock lock(mtx_); - umap_type::iterator it = umap_.find(id); - umap_type::iterator itend = umap_.end(); - - if(it != itend){ - winapi::close_handle(it->second); - const map_type::key_type &k = &it->first; - map_.erase(k); - umap_.erase(it); - } - } - - void destroy_syncs_in_range(const void *addr, std::size_t size) - { - const sync_id low_id(addr); - const sync_id hig_id(static_cast(addr)+size); - scoped_lock lock(mtx_); - map_type::iterator itlow(map_.lower_bound(&low_id)), - ithig(map_.lower_bound(&hig_id)); - while(itlow != ithig){ - void * const hnd = umap_[*itlow->first]; - winapi::close_handle(hnd); - umap_.erase(*itlow->first); - itlow = map_.erase(itlow); - } - } - - private: - spin_mutex mtx_; - umap_type umap_; - map_type map_; -}; - - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_SYNC_UTILS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_mutex_wrapper.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_mutex_wrapper.hpp deleted file mode 100644 index 0be96011..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_mutex_wrapper.hpp +++ /dev/null @@ -1,163 +0,0 @@ - ////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_WINAPI_MUTEX_WRAPPER_HPP -#define BOOST_INTERPROCESS_DETAIL_WINAPI_MUTEX_WRAPPER_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class winapi_mutex_functions -{ - /// @cond - - //Non-copyable - winapi_mutex_functions(const winapi_mutex_functions &); - winapi_mutex_functions &operator=(const winapi_mutex_functions &); - /// @endcond - - public: - winapi_mutex_functions(void *mtx_hnd) - : m_mtx_hnd(mtx_hnd) - {} - - void unlock() - { - winapi::release_mutex(m_mtx_hnd); - } - - void lock() - { - if(winapi::wait_for_single_object(m_mtx_hnd, winapi::infinite_time) != winapi::wait_object_0){ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - bool try_lock() - { - unsigned long ret = winapi::wait_for_single_object(m_mtx_hnd, 0); - if(ret == winapi::wait_object_0){ - return true; - } - else if(ret == winapi::wait_timeout){ - return false; - } - else{ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - bool timed_lock(const boost::posix_time::ptime &abs_time) - { - if(abs_time == boost::posix_time::pos_infin){ - this->lock(); - return true; - } - - unsigned long ret = winapi::wait_for_single_object - (m_mtx_hnd, (abs_time - microsec_clock::universal_time()).total_milliseconds()); - if(ret == winapi::wait_object_0){ - return true; - } - else if(ret == winapi::wait_timeout){ - return false; - } - else{ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - /// @cond - protected: - void *m_mtx_hnd; - /// @endcond -}; - -//Swappable mutex wrapper -class winapi_mutex_wrapper - : public winapi_mutex_functions -{ - /// @cond - - //Non-copyable - winapi_mutex_wrapper(const winapi_mutex_wrapper &); - winapi_mutex_wrapper &operator=(const winapi_mutex_wrapper &); - /// @endcond - - public: - winapi_mutex_wrapper(void *mtx_hnd = winapi::invalid_handle_value) - : winapi_mutex_functions(mtx_hnd) - {} - - ~winapi_mutex_wrapper() - { this->close(); } - - void *release() - { - void *hnd = m_mtx_hnd; - m_mtx_hnd = winapi::invalid_handle_value; - return hnd; - } - - void *handle() const - { return m_mtx_hnd; } - - bool open_or_create(const char *name, const permissions &perm) - { - if(m_mtx_hnd == winapi::invalid_handle_value){ - m_mtx_hnd = winapi::open_or_create_mutex - ( name - , false - , (winapi::interprocess_security_attributes*)perm.get_permissions() - ); - return m_mtx_hnd != winapi::invalid_handle_value; - } - else{ - return false; - } - } - - void close() - { - if(m_mtx_hnd != winapi::invalid_handle_value){ - winapi::close_handle(m_mtx_hnd); - m_mtx_hnd = winapi::invalid_handle_value; - } - } - - void swap(winapi_mutex_wrapper &other) - { void *tmp = m_mtx_hnd; m_mtx_hnd = other.m_mtx_hnd; other.m_mtx_hnd = tmp; } -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_WINAPI_MUTEX_WRAPPER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_semaphore_wrapper.hpp b/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_semaphore_wrapper.hpp deleted file mode 100644 index de5185ac..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/interprocess/sync/windows/winapi_semaphore_wrapper.hpp +++ /dev/null @@ -1,198 +0,0 @@ - ////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2012. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/interprocess for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTERPROCESS_DETAIL_WINAPI_SEMAPHORE_WRAPPER_HPP -#define BOOST_INTERPROCESS_DETAIL_WINAPI_SEMAPHORE_WRAPPER_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace interprocess { -namespace ipcdetail { - -class winapi_semaphore_functions -{ - /// @cond - - //Non-copyable - winapi_semaphore_functions(const winapi_semaphore_functions &); - winapi_semaphore_functions &operator=(const winapi_semaphore_functions &); - /// @endcond - - public: - winapi_semaphore_functions(void *hnd) - : m_sem_hnd(hnd) - {} - - void post(long count = 1) - { - long prev_count; - winapi::release_semaphore(m_sem_hnd, count, &prev_count); - } - - void wait() - { - if(winapi::wait_for_single_object(m_sem_hnd, winapi::infinite_time) != winapi::wait_object_0){ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - bool try_wait() - { - unsigned long ret = winapi::wait_for_single_object(m_sem_hnd, 0); - if(ret == winapi::wait_object_0){ - return true; - } - else if(ret == winapi::wait_timeout){ - return false; - } - else{ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - bool timed_wait(const boost::posix_time::ptime &abs_time) - { - if(abs_time == boost::posix_time::pos_infin){ - this->wait(); - return true; - } - - unsigned long ret = winapi::wait_for_single_object - (m_sem_hnd, (abs_time - microsec_clock::universal_time()).total_milliseconds()); - if(ret == winapi::wait_object_0){ - return true; - } - else if(ret == winapi::wait_timeout){ - return false; - } - else{ - error_info err = system_error_code(); - throw interprocess_exception(err); - } - } - - long value() const - { - long l_count, l_limit; - if(!winapi::get_semaphore_info(m_sem_hnd, l_count, l_limit)) - return 0; - return l_count; - } - - long limit() const - { - long l_count, l_limit; - if(!winapi::get_semaphore_info(m_sem_hnd, l_count, l_limit)) - return 0; - return l_limit; - } - - /// @cond - protected: - void *m_sem_hnd; - /// @endcond -}; - - -//Swappable semaphore wrapper -class winapi_semaphore_wrapper - : public winapi_semaphore_functions -{ - winapi_semaphore_wrapper(const winapi_semaphore_wrapper &); - winapi_semaphore_wrapper &operator=(const winapi_semaphore_wrapper &); - - public: - - //Long is 32 bits in windows - static const long MaxCount = long(0x7FFFFFFF); - - winapi_semaphore_wrapper(void *hnd = winapi::invalid_handle_value) - : winapi_semaphore_functions(hnd) - {} - - ~winapi_semaphore_wrapper() - { this->close(); } - - void *release() - { - void *hnd = m_sem_hnd; - m_sem_hnd = winapi::invalid_handle_value; - return hnd; - } - - void *handle() const - { return m_sem_hnd; } - - bool open_or_create( const char *name - , long sem_count - , long max_count - , const permissions &perm - , bool &created) - { - if(m_sem_hnd == winapi::invalid_handle_value){ - m_sem_hnd = winapi::open_or_create_semaphore - ( name - , sem_count - , max_count - , (winapi::interprocess_security_attributes*)perm.get_permissions() - ); - created = winapi::get_last_error() != winapi::error_already_exists; - return m_sem_hnd != winapi::invalid_handle_value; - } - else{ - return false; - } - } - - bool open_semaphore(const char *name) - { - if(m_sem_hnd == winapi::invalid_handle_value){ - m_sem_hnd = winapi::open_semaphore(name); - return m_sem_hnd != winapi::invalid_handle_value; - } - else{ - return false; - } - } - - void close() - { - if(m_sem_hnd != winapi::invalid_handle_value){ - winapi::close_handle(m_sem_hnd); - m_sem_hnd = winapi::invalid_handle_value; - } - } - - void swap(winapi_semaphore_wrapper &other) - { void *tmp = m_sem_hnd; m_sem_hnd = other.m_sem_hnd; other.m_sem_hnd = tmp; } -}; - -} //namespace ipcdetail { -} //namespace interprocess { -} //namespace boost { - -#include - -#endif //BOOST_INTERPROCESS_DETAIL_WINAPI_SEMAPHORE_WRAPPER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree.hpp deleted file mode 100644 index 32554fb5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree.hpp +++ /dev/null @@ -1,2014 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2013-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// -#ifndef BOOST_INTRUSIVE_BSTREE_HPP -#define BOOST_INTRUSIVE_BSTREE_HPP - -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace intrusive { - -/// @cond - -struct bstree_defaults -{ - typedef detail::default_bstree_hook proto_value_traits; - static const bool constant_time_size = true; - typedef std::size_t size_type; - typedef void compare; - static const bool floating_point = true; //For sgtree - typedef void priority; //For treap -}; - -template -struct bstbase3 - : public detail::get_real_value_traits::type::node_traits::node - , public ValueTraits -{ - typedef ValueTraits value_traits; - typedef typename detail::get_real_value_traits::type real_value_traits; - typedef typename real_value_traits::node_traits node_traits; - typedef typename node_traits::node node_type; - typedef typename get_algo::type node_algorithms; - typedef typename node_traits::node_ptr node_ptr; - typedef typename node_traits::const_node_ptr const_node_ptr; - - bstbase3(const ValueTraits &vtraits) - : ValueTraits(vtraits) - {} - - static const bool external_value_traits = - detail::external_value_traits_bool_is_true::value; - - node_ptr header_ptr() - { return pointer_traits::pointer_to(static_cast(*this)); } - - const_node_ptr header_ptr() const - { return pointer_traits::pointer_to(static_cast(*this)); } - - const value_traits &val_traits() const - { return *this; } - - value_traits &val_traits() - { return *this; } - - const real_value_traits &get_real_value_traits(detail::bool_) const - { return *this; } - - const real_value_traits &get_real_value_traits(detail::bool_) const - { return this->val_traits().get_value_traits(*this); } - - real_value_traits &get_real_value_traits(detail::bool_) - { return *this; } - - real_value_traits &get_real_value_traits(detail::bool_) - { return this->val_traits().get_value_traits(*this); } - - const real_value_traits &get_real_value_traits() const - { return this->get_real_value_traits(detail::bool_()); } - - real_value_traits &get_real_value_traits() - { return this->get_real_value_traits(detail::bool_()); } - - typedef typename pointer_traits::template rebind_pointer::type const_real_value_traits_ptr; - - const_real_value_traits_ptr real_value_traits_ptr() const - { return pointer_traits::pointer_to(this->get_real_value_traits()); } - - - typedef tree_iterator iterator; - typedef tree_iterator const_iterator; - typedef boost::intrusive::detail::reverse_iterator reverse_iterator; - typedef boost::intrusive::detail::reverse_iterator const_reverse_iterator; - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::pointer) pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::const_pointer) const_pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::element_type) value_type; - typedef BOOST_INTRUSIVE_IMPDEF(value_type) key_type; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) const_reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::difference_type) difference_type; - static const bool safemode_or_autounlink = is_safe_autounlink::value; - static const bool stateful_value_traits = detail::is_stateful_value_traits::value; - - iterator begin() - { return iterator (node_traits::get_left(this->header_ptr()), this->real_value_traits_ptr()); } - - const_iterator begin() const - { return cbegin(); } - - const_iterator cbegin() const - { return const_iterator (node_traits::get_left(this->header_ptr()), this->real_value_traits_ptr()); } - - iterator end() - { return iterator (this->header_ptr(), this->real_value_traits_ptr()); } - - const_iterator end() const - { return cend(); } - - const_iterator cend() const - { return const_iterator (detail::uncast(this->header_ptr()), this->real_value_traits_ptr()); } - - reverse_iterator rbegin() - { return reverse_iterator(end()); } - - const_reverse_iterator rbegin() const - { return const_reverse_iterator(end()); } - - const_reverse_iterator crbegin() const - { return const_reverse_iterator(end()); } - - reverse_iterator rend() - { return reverse_iterator(begin()); } - - const_reverse_iterator rend() const - { return const_reverse_iterator(begin()); } - - const_reverse_iterator crend() const - { return const_reverse_iterator(begin()); } - - void replace_node(iterator replace_this, reference with_this) - { - node_algorithms::replace_node( get_real_value_traits().to_node_ptr(*replace_this) - , this->header_ptr() - , get_real_value_traits().to_node_ptr(with_this)); - if(safemode_or_autounlink) - node_algorithms::init(replace_this.pointed_node()); - } - - void rebalance() - { node_algorithms::rebalance(this->header_ptr()); } - - iterator rebalance_subtree(iterator root) - { return iterator(node_algorithms::rebalance_subtree(root.pointed_node()), this->real_value_traits_ptr()); } - - static iterator s_iterator_to(reference value) - { - BOOST_STATIC_ASSERT((!stateful_value_traits)); - return iterator (value_traits::to_node_ptr(value), const_real_value_traits_ptr()); - } - - static const_iterator s_iterator_to(const_reference value) - { - BOOST_STATIC_ASSERT((!stateful_value_traits)); - return const_iterator (value_traits::to_node_ptr(const_cast (value)), const_real_value_traits_ptr()); - } - - iterator iterator_to(reference value) - { return iterator (value_traits::to_node_ptr(value), this->real_value_traits_ptr()); } - - const_iterator iterator_to(const_reference value) const - { return const_iterator (value_traits::to_node_ptr(const_cast (value)), this->real_value_traits_ptr()); } - - static void init_node(reference value) - { node_algorithms::init(value_traits::to_node_ptr(value)); } - -}; - -template -struct bstbase2 - : public bstbase3 - , public detail::ebo_functor_holder::type::value_type - >::type> -{ - typedef bstbase3 treeheader_t; - typedef typename treeheader_t::real_value_traits real_value_traits; - typedef typename treeheader_t::node_algorithms node_algorithms; - typedef typename get_less - < VoidOrKeyComp, typename real_value_traits::value_type>::type value_compare; - typedef BOOST_INTRUSIVE_IMPDEF(value_compare) key_compare; - typedef typename treeheader_t::iterator iterator; - typedef typename treeheader_t::const_iterator const_iterator; - typedef typename treeheader_t::node_ptr node_ptr; - typedef typename treeheader_t::const_node_ptr const_node_ptr; - - bstbase2(const value_compare &comp, const ValueTraits &vtraits) - : treeheader_t(vtraits), detail::ebo_functor_holder(comp) - {} - - const value_compare &comp() const - { return this->get(); } - - value_compare &comp() - { return this->get(); } - - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::pointer) pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::const_pointer) const_pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::element_type) value_type; - typedef BOOST_INTRUSIVE_IMPDEF(value_type) key_type; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) const_reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::difference_type) difference_type; - typedef typename node_algorithms::insert_commit_data insert_commit_data; - - value_compare value_comp() const - { return this->comp(); } - - key_compare key_comp() const - { return this->comp(); } - - iterator lower_bound(const_reference value) - { return this->lower_bound(value, this->comp()); } - - const_iterator lower_bound(const_reference value) const - { return this->lower_bound(value, this->comp()); } - - template - iterator lower_bound(const KeyType &key, KeyValueCompare comp) - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return iterator(node_algorithms::lower_bound - (this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - template - const_iterator lower_bound(const KeyType &key, KeyValueCompare comp) const - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return const_iterator(node_algorithms::lower_bound - (this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - iterator upper_bound(const_reference value) - { return this->upper_bound(value, this->comp()); } - - template - iterator upper_bound(const KeyType &key, KeyValueCompare comp) - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return iterator(node_algorithms::upper_bound - (this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - const_iterator upper_bound(const_reference value) const - { return this->upper_bound(value, this->comp()); } - - template - const_iterator upper_bound(const KeyType &key, KeyValueCompare comp) const - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return const_iterator(node_algorithms::upper_bound - (this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - iterator find(const_reference value) - { return this->find(value, this->comp()); } - - template - iterator find(const KeyType &key, KeyValueCompare comp) - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return iterator - (node_algorithms::find(this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - const_iterator find(const_reference value) const - { return this->find(value, this->comp()); } - - template - const_iterator find(const KeyType &key, KeyValueCompare comp) const - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - return const_iterator - (node_algorithms::find(this->header_ptr(), key, key_node_comp), this->real_value_traits_ptr()); - } - - std::pair equal_range(const_reference value) - { return this->equal_range(value, this->comp()); } - - template - std::pair equal_range(const KeyType &key, KeyValueCompare comp) - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - std::pair ret - (node_algorithms::equal_range(this->header_ptr(), key, key_node_comp)); - return std::pair( iterator(ret.first, this->real_value_traits_ptr()) - , iterator(ret.second, this->real_value_traits_ptr())); - } - - std::pair - equal_range(const_reference value) const - { return this->equal_range(value, this->comp()); } - - template - std::pair - equal_range(const KeyType &key, KeyValueCompare comp) const - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - std::pair ret - (node_algorithms::equal_range(this->header_ptr(), key, key_node_comp)); - return std::pair( const_iterator(ret.first, this->real_value_traits_ptr()) - , const_iterator(ret.second, this->real_value_traits_ptr())); - } - - std::pair bounded_range - (const_reference lower_value, const_reference upper_value, bool left_closed, bool right_closed) - { return this->bounded_range(lower_value, upper_value, this->comp(), left_closed, right_closed); } - - template - std::pair bounded_range - (const KeyType &lower_key, const KeyType &upper_key, KeyValueCompare comp, bool left_closed, bool right_closed) - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - std::pair ret - (node_algorithms::bounded_range - (this->header_ptr(), lower_key, upper_key, key_node_comp, left_closed, right_closed)); - return std::pair( iterator(ret.first, this->real_value_traits_ptr()) - , iterator(ret.second, this->real_value_traits_ptr())); - } - - std::pair bounded_range - (const_reference lower_value, const_reference upper_value, bool left_closed, bool right_closed) const - { return this->bounded_range(lower_value, upper_value, this->comp(), left_closed, right_closed); } - - template - std::pair bounded_range - (const KeyType &lower_key, const KeyType &upper_key, KeyValueCompare comp, bool left_closed, bool right_closed) const - { - detail::key_nodeptr_comp - key_node_comp(comp, &this->get_real_value_traits()); - std::pair ret - (node_algorithms::bounded_range - (this->header_ptr(), lower_key, upper_key, key_node_comp, left_closed, right_closed)); - return std::pair( const_iterator(ret.first, this->real_value_traits_ptr()) - , const_iterator(ret.second, this->real_value_traits_ptr())); - } - - template - std::pair insert_unique_check - (const KeyType &key, KeyValueCompare key_value_comp, insert_commit_data &commit_data) - { - detail::key_nodeptr_comp - ocomp(key_value_comp, &this->get_real_value_traits()); - std::pair ret = - (node_algorithms::insert_unique_check - (this->header_ptr(), key, ocomp, commit_data)); - return std::pair(iterator(ret.first, this->real_value_traits_ptr()), ret.second); - } - - template - std::pair insert_unique_check - (const_iterator hint, const KeyType &key - ,KeyValueCompare key_value_comp, insert_commit_data &commit_data) - { - detail::key_nodeptr_comp - ocomp(key_value_comp, &this->get_real_value_traits()); - std::pair ret = - (node_algorithms::insert_unique_check - (this->header_ptr(), hint.pointed_node(), key, ocomp, commit_data)); - return std::pair(iterator(ret.first, this->real_value_traits_ptr()), ret.second); - } -}; - -template -struct bstbase - : public detail::size_holder - , public bstbase2 < ValueTraits, VoidOrKeyComp, AlgoType> -{ - typedef typename detail::get_real_value_traits::type real_value_traits; - typedef bstbase2< ValueTraits, VoidOrKeyComp, AlgoType> base_type; - typedef typename base_type::value_compare value_compare; - typedef BOOST_INTRUSIVE_IMPDEF(value_compare) key_compare; - typedef typename base_type::const_reference const_reference; - typedef typename base_type::reference reference; - typedef typename base_type::iterator iterator; - typedef typename base_type::const_iterator const_iterator; - typedef typename base_type::node_traits node_traits; - typedef typename get_algo - ::type algo_type; - typedef SizeType size_type; - - bstbase(const value_compare & comp, const ValueTraits &vtraits) - : base_type(comp, vtraits) - {} - - public: - typedef detail::size_holder size_traits; - - size_traits &sz_traits() - { return *this; } - - const size_traits &sz_traits() const - { return *this; } - - size_type count(const_reference value) const - { return size_type(this->count(value, this->comp())); } - - template - size_type count(const KeyType &key, KeyValueCompare comp) const - { - std::pair ret = this->equal_range(key, comp); - return size_type(std::distance(ret.first, ret.second)); - } - - bool empty() const - { - if(ConstantTimeSize){ - return !this->sz_traits().get_size(); - } - else{ - return algo_type::unique(this->header_ptr()); - } - } -}; - - -/// @endcond - -//! The class template bstree is an unbalanced intrusive binary search tree -//! container. The no-throw guarantee holds only, if the value_compare object -//! doesn't throw. -//! -//! The complexity guarantees only hold if the tree is balanced, logarithmic -//! complexity would increase to linear if the tree is totally unbalanced. -//! -//! The template parameter \c T is the type to be managed by the container. -//! The user can specify additional options and if no options are provided -//! default options are used. -//! -//! The container supports the following options: -//! \c base_hook<>/member_hook<>/value_traits<>, -//! \c constant_time_size<>, \c size_type<> and -//! \c compare<>. -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -class bstree_impl - : public bstbase - , private detail::clear_on_destructor_base - < bstree_impl - , is_safe_autounlink::type::link_mode>::value - > -{ - template friend class detail::clear_on_destructor_base; - public: - typedef ValueTraits value_traits; - /// @cond - static const bool external_value_traits = - detail::external_value_traits_bool_is_true::value; - typedef typename detail::get_real_value_traits::type real_value_traits; - typedef bstbase data_type; - typedef tree_iterator iterator_type; - typedef tree_iterator const_iterator_type; - /// @endcond - - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::pointer) pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::const_pointer) const_pointer; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::element_type) value_type; - typedef BOOST_INTRUSIVE_IMPDEF(value_type) key_type; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::reference) const_reference; - typedef BOOST_INTRUSIVE_IMPDEF(typename pointer_traits::difference_type) difference_type; - typedef BOOST_INTRUSIVE_IMPDEF(SizeType) size_type; - typedef BOOST_INTRUSIVE_IMPDEF(typename data_type::value_compare) value_compare; - typedef BOOST_INTRUSIVE_IMPDEF(value_compare) key_compare; - typedef BOOST_INTRUSIVE_IMPDEF(iterator_type) iterator; - typedef BOOST_INTRUSIVE_IMPDEF(const_iterator_type) const_iterator; - typedef BOOST_INTRUSIVE_IMPDEF(boost::intrusive::detail::reverse_iterator) reverse_iterator; - typedef BOOST_INTRUSIVE_IMPDEF(boost::intrusive::detail::reverse_iterator) const_reverse_iterator; - typedef BOOST_INTRUSIVE_IMPDEF(typename real_value_traits::node_traits) node_traits; - typedef BOOST_INTRUSIVE_IMPDEF(typename node_traits::node) node; - typedef BOOST_INTRUSIVE_IMPDEF(typename node_traits::node_ptr) node_ptr; - typedef BOOST_INTRUSIVE_IMPDEF(typename node_traits::const_node_ptr) const_node_ptr; - /// @cond - typedef typename get_algo::type algo_type; - /// @endcond - typedef BOOST_INTRUSIVE_IMPDEF(algo_type) node_algorithms; - - static const bool constant_time_size = ConstantTimeSize; - static const bool stateful_value_traits = detail::is_stateful_value_traits::value; - /// @cond - private: - - //noncopyable - BOOST_MOVABLE_BUT_NOT_COPYABLE(bstree_impl) - - static const bool safemode_or_autounlink = is_safe_autounlink::value; - - //Constant-time size is incompatible with auto-unlink hooks! - BOOST_STATIC_ASSERT(!(constant_time_size && ((int)real_value_traits::link_mode == (int)auto_unlink))); - - - protected: - - - /// @endcond - - public: - - typedef typename node_algorithms::insert_commit_data insert_commit_data; - - //! Effects: Constructs an empty container. - //! - //! Complexity: Constant. - //! - //! Throws: If value_traits::node_traits::node - //! constructor throws (this does not happen with predefined Boost.Intrusive hooks) - //! or the copy constructorof the value_compare object throws. Basic guarantee. - explicit bstree_impl( const value_compare &cmp = value_compare() - , const value_traits &v_traits = value_traits()) - : data_type(cmp, v_traits) - { - node_algorithms::init_header(this->header_ptr()); - this->sz_traits().set_size(size_type(0)); - } - - //! Requires: Dereferencing iterator must yield an lvalue of type value_type. - //! cmp must be a comparison function that induces a strict weak ordering. - //! - //! Effects: Constructs an empty container and inserts elements from - //! [b, e). - //! - //! Complexity: Linear in N if [b, e) is already sorted using - //! comp and otherwise N * log N, where N is the distance between first and last. - //! - //! Throws: If value_traits::node_traits::node - //! constructor throws (this does not happen with predefined Boost.Intrusive hooks) - //! or the copy constructor/operator() of the value_compare object throws. Basic guarantee. - template - bstree_impl( bool unique, Iterator b, Iterator e - , const value_compare &cmp = value_compare() - , const value_traits &v_traits = value_traits()) - : data_type(cmp, v_traits) - { - node_algorithms::init_header(this->header_ptr()); - this->sz_traits().set_size(size_type(0)); - if(unique) - this->insert_unique(b, e); - else - this->insert_equal(b, e); - } - - //! Effects: to-do - //! - bstree_impl(BOOST_RV_REF(bstree_impl) x) - : data_type(::boost::move(x.comp()), ::boost::move(x.val_traits())) - { - node_algorithms::init_header(this->header_ptr()); - this->sz_traits().set_size(size_type(0)); - this->swap(x); - } - - //! Effects: to-do - //! - bstree_impl& operator=(BOOST_RV_REF(bstree_impl) x) - { this->swap(x); return *this; } - - #ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - //! Effects: Detaches all elements from this. The objects in the set - //! are not deleted (i.e. no destructors are called), but the nodes according to - //! the value_traits template parameter are reinitialized and thus can be reused. - //! - //! Complexity: Linear to elements contained in *this. - //! - //! Throws: Nothing. - ~bstree_impl() - {} - - //! Effects: Returns an iterator pointing to the beginning of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - iterator begin(); - - //! Effects: Returns a const_iterator pointing to the beginning of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_iterator begin() const; - - //! Effects: Returns a const_iterator pointing to the beginning of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_iterator cbegin() const; - - //! Effects: Returns an iterator pointing to the end of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - iterator end(); - - //! Effects: Returns a const_iterator pointing to the end of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_iterator end() const; - - //! Effects: Returns a const_iterator pointing to the end of the container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_iterator cend() const; - - //! Effects: Returns a reverse_iterator pointing to the beginning of the - //! reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - reverse_iterator rbegin(); - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_reverse_iterator rbegin() const; - - //! Effects: Returns a const_reverse_iterator pointing to the beginning - //! of the reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_reverse_iterator crbegin() const; - - //! Effects: Returns a reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - reverse_iterator rend(); - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_reverse_iterator rend() const; - - //! Effects: Returns a const_reverse_iterator pointing to the end - //! of the reversed container. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_reverse_iterator crend() const; - - #endif //#ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - //! Precondition: end_iterator must be a valid end iterator - //! of the container. - //! - //! Effects: Returns a const reference to the container associated to the end iterator - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - static bstree_impl &container_from_end_iterator(iterator end_iterator) - { - return *static_cast - (boost::intrusive::detail::to_raw_pointer(end_iterator.pointed_node())); - } - - //! Precondition: end_iterator must be a valid end const_iterator - //! of the container. - //! - //! Effects: Returns a const reference to the container associated to the iterator - //! - //! Throws: Nothing. - //! - //! Complexity: Constant. - static const bstree_impl &container_from_end_iterator(const_iterator end_iterator) - { - return *static_cast - (boost::intrusive::detail::to_raw_pointer(end_iterator.pointed_node())); - } - - //! Precondition: it must be a valid iterator - //! of the container. - //! - //! Effects: Returns a const reference to the container associated to the iterator - //! - //! Throws: Nothing. - //! - //! Complexity: Logarithmic. - static bstree_impl &container_from_iterator(iterator it) - { return container_from_end_iterator(it.end_iterator_from_it()); } - - //! Precondition: it must be a valid end const_iterator - //! of container. - //! - //! Effects: Returns a const reference to the container associated to the end iterator - //! - //! Throws: Nothing. - //! - //! Complexity: Logarithmic. - static const bstree_impl &container_from_iterator(const_iterator it) - { return container_from_end_iterator(it.end_iterator_from_it()); } - - #ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - //! Effects: Returns the key_compare object used by the container. - //! - //! Complexity: Constant. - //! - //! Throws: If value_compare copy-constructor throws. - key_compare key_comp() const; - - //! Effects: Returns the value_compare object used by the container. - //! - //! Complexity: Constant. - //! - //! Throws: If value_compare copy-constructor throws. - value_compare value_comp() const; - - //! Effects: Returns true if the container is empty. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - bool empty() const; - - #endif //#ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - //! Effects: Returns the number of elements stored in the container. - //! - //! Complexity: Linear to elements contained in *this - //! if constant-time size option is disabled. Constant time otherwise. - //! - //! Throws: Nothing. - size_type size() const - { - if(constant_time_size) - return this->sz_traits().get_size(); - else{ - return (size_type)node_algorithms::size(this->header_ptr()); - } - } - - //! Effects: Swaps the contents of two containers. - //! - //! Complexity: Constant. - //! - //! Throws: If the comparison functor's swap call throws. - void swap(bstree_impl& other) - { - //This can throw - using std::swap; - swap(this->comp(), this->comp()); - //These can't throw - node_algorithms::swap_tree(this->header_ptr(), node_ptr(other.header_ptr())); - if(constant_time_size){ - size_type backup = this->sz_traits().get_size(); - this->sz_traits().set_size(other.sz_traits().get_size()); - other.sz_traits().set_size(backup); - } - } - - //! Requires: Disposer::operator()(pointer) shouldn't throw. - //! Cloner should yield to nodes equivalent to the original nodes. - //! - //! Effects: Erases all the elements from *this - //! calling Disposer::operator()(pointer), clones all the - //! elements from src calling Cloner::operator()(const_reference ) - //! and inserts them on *this. Copies the predicate from the source container. - //! - //! If cloner throws, all cloned elements are unlinked and disposed - //! calling Disposer::operator()(pointer). - //! - //! Complexity: Linear to erased plus inserted elements. - //! - //! Throws: If cloner throws or predicate copy assignment throws. Basic guarantee. - template - void clone_from(const bstree_impl &src, Cloner cloner, Disposer disposer) - { - this->clear_and_dispose(disposer); - if(!src.empty()){ - detail::exception_disposer - rollback(*this, disposer); - node_algorithms::clone - (const_node_ptr(src.header_ptr()) - ,node_ptr(this->header_ptr()) - ,detail::node_cloner (cloner, &this->get_real_value_traits()) - ,detail::node_disposer(disposer, &this->get_real_value_traits())); - this->sz_traits().set_size(src.sz_traits().get_size()); - this->comp() = src.comp(); - rollback.release(); - } - } - - //! Requires: value must be an lvalue - //! - //! Effects: Inserts value into the container before the upper bound. - //! - //! Complexity: Average complexity for insert element is at - //! most logarithmic. - //! - //! Throws: If the internal value_compare ordering function throws. Strong guarantee. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - iterator insert_equal(reference value) - { - detail::key_nodeptr_comp - key_node_comp(this->comp(), &this->get_real_value_traits()); - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - iterator ret(node_algorithms::insert_equal_upper_bound - (this->header_ptr(), to_insert, key_node_comp), this->real_value_traits_ptr()); - this->sz_traits().increment(); - return ret; - } - - //! Requires: value must be an lvalue, and "hint" must be - //! a valid iterator. - //! - //! Effects: Inserts x into the container, using "hint" as a hint to - //! where it will be inserted. If "hint" is the upper_bound - //! the insertion takes constant time (two comparisons in the worst case) - //! - //! Complexity: Logarithmic in general, but it is amortized - //! constant time if t is inserted immediately before hint. - //! - //! Throws: If the internal value_compare ordering function throws. Strong guarantee. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - iterator insert_equal(const_iterator hint, reference value) - { - detail::key_nodeptr_comp - key_node_comp(this->comp(), &this->get_real_value_traits()); - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - iterator ret(node_algorithms::insert_equal - (this->header_ptr(), hint.pointed_node(), to_insert, key_node_comp), this->real_value_traits_ptr()); - this->sz_traits().increment(); - return ret; - } - - //! Requires: Dereferencing iterator must yield an lvalue - //! of type value_type. - //! - //! Effects: Inserts a each element of a range into the container - //! before the upper bound of the key of each element. - //! - //! Complexity: Insert range is in general O(N * log(N)), where N is the - //! size of the range. However, it is linear in N if the range is already sorted - //! by value_comp(). - //! - //! Throws: Nothing. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - template - void insert_equal(Iterator b, Iterator e) - { - iterator iend(this->end()); - for (; b != e; ++b) - this->insert_equal(iend, *b); - } - - //! Requires: value must be an lvalue - //! - //! Effects: Inserts value into the container if the value - //! is not already present. - //! - //! Complexity: Average complexity for insert element is at - //! most logarithmic. - //! - //! Throws: Nothing. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - std::pair insert_unique(reference value) - { - insert_commit_data commit_data; - std::pair ret = this->insert_unique_check(value, this->comp(), commit_data); - if(!ret.second) - return ret; - return std::pair (this->insert_unique_commit(value, commit_data), true); - } - - //! Requires: value must be an lvalue, and "hint" must be - //! a valid iterator - //! - //! Effects: Tries to insert x into the container, using "hint" as a hint - //! to where it will be inserted. - //! - //! Complexity: Logarithmic in general, but it is amortized - //! constant time (two comparisons in the worst case) - //! if t is inserted immediately before hint. - //! - //! Throws: Nothing. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - iterator insert_unique(const_iterator hint, reference value) - { - insert_commit_data commit_data; - std::pair ret = this->insert_unique_check(hint, value, this->comp(), commit_data); - if(!ret.second) - return ret.first; - return this->insert_unique_commit(value, commit_data); - } - - //! Requires: Dereferencing iterator must yield an lvalue - //! of type value_type. - //! - //! Effects: Tries to insert each element of a range into the container. - //! - //! Complexity: Insert range is in general O(N * log(N)), where N is the - //! size of the range. However, it is linear in N if the range is already sorted - //! by value_comp(). - //! - //! Throws: Nothing. - //! - //! Note: Does not affect the validity of iterators and references. - //! No copy-constructors are called. - template - void insert_unique(Iterator b, Iterator e) - { - if(this->empty()){ - iterator iend(this->end()); - for (; b != e; ++b) - this->insert_unique(iend, *b); - } - else{ - for (; b != e; ++b) - this->insert_unique(*b); - } - } - - #ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - //! Requires: key_value_comp must be a comparison function that induces - //! the same strict weak ordering as value_compare. The difference is that - //! key_value_comp compares an arbitrary key with the contained values. - //! - //! Effects: Checks if a value can be inserted in the container, using - //! a user provided key instead of the value itself. - //! - //! Returns: If there is an equivalent value - //! returns a pair containing an iterator to the already present value - //! and false. If the value can be inserted returns true in the returned - //! pair boolean and fills "commit_data" that is meant to be used with - //! the "insert_commit" function. - //! - //! Complexity: Average complexity is at most logarithmic. - //! - //! Throws: If the key_value_comp ordering function throws. Strong guarantee. - //! - //! Notes: This function is used to improve performance when constructing - //! a value_type is expensive: if there is an equivalent value - //! the constructed object must be discarded. Many times, the part of the - //! node that is used to impose the order is much cheaper to construct - //! than the value_type and this function offers the possibility to use that - //! part to check if the insertion will be successful. - //! - //! If the check is successful, the user can construct the value_type and use - //! "insert_commit" to insert the object in constant-time. This gives a total - //! logarithmic complexity to the insertion: check(O(log(N)) + commit(O(1)). - //! - //! "commit_data" remains valid for a subsequent "insert_commit" only if no more - //! objects are inserted or erased from the container. - template - std::pair insert_unique_check - (const KeyType &key, KeyValueCompare key_value_comp, insert_commit_data &commit_data); - - //! Requires: key_value_comp must be a comparison function that induces - //! the same strict weak ordering as value_compare. The difference is that - //! key_value_comp compares an arbitrary key with the contained values. - //! - //! Effects: Checks if a value can be inserted in the container, using - //! a user provided key instead of the value itself, using "hint" - //! as a hint to where it will be inserted. - //! - //! Returns: If there is an equivalent value - //! returns a pair containing an iterator to the already present value - //! and false. If the value can be inserted returns true in the returned - //! pair boolean and fills "commit_data" that is meant to be used with - //! the "insert_commit" function. - //! - //! Complexity: Logarithmic in general, but it's amortized - //! constant time if t is inserted immediately before hint. - //! - //! Throws: If the key_value_comp ordering function throws. Strong guarantee. - //! - //! Notes: This function is used to improve performance when constructing - //! a value_type is expensive: if there is an equivalent value - //! the constructed object must be discarded. Many times, the part of the - //! constructing that is used to impose the order is much cheaper to construct - //! than the value_type and this function offers the possibility to use that key - //! to check if the insertion will be successful. - //! - //! If the check is successful, the user can construct the value_type and use - //! "insert_commit" to insert the object in constant-time. This can give a total - //! constant-time complexity to the insertion: check(O(1)) + commit(O(1)). - //! - //! "commit_data" remains valid for a subsequent "insert_commit" only if no more - //! objects are inserted or erased from the container. - template - std::pair insert_unique_check - (const_iterator hint, const KeyType &key - ,KeyValueCompare key_value_comp, insert_commit_data &commit_data); - - #endif //#ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED - - //! Requires: value must be an lvalue of type value_type. commit_data - //! must have been obtained from a previous call to "insert_check". - //! No objects should have been inserted or erased from the container between - //! the "insert_check" that filled "commit_data" and the call to "insert_commit". - //! - //! Effects: Inserts the value in the container using the information obtained - //! from the "commit_data" that a previous "insert_check" filled. - //! - //! Returns: An iterator to the newly inserted object. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - //! - //! Notes: This function has only sense if a "insert_check" has been - //! previously executed to fill "commit_data". No value should be inserted or - //! erased between the "insert_check" and "insert_commit" calls. - iterator insert_unique_commit(reference value, const insert_commit_data &commit_data) - { - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - node_algorithms::insert_unique_commit - (this->header_ptr(), to_insert, commit_data); - this->sz_traits().increment(); - return iterator(to_insert, this->real_value_traits_ptr()); - } - - //! Requires: value must be an lvalue, "pos" must be - //! a valid iterator (or end) and must be the succesor of value - //! once inserted according to the predicate - //! - //! Effects: Inserts x into the container before "pos". - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - //! - //! Note: This function does not check preconditions so if "pos" is not - //! the successor of "value" container ordering invariant will be broken. - //! This is a low-level function to be used only for performance reasons - //! by advanced users. - iterator insert_before(const_iterator pos, reference value) - { - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - this->sz_traits().increment(); - return iterator(node_algorithms::insert_before - (this->header_ptr(), pos.pointed_node(), to_insert), this->real_value_traits_ptr()); - } - - //! Requires: value must be an lvalue, and it must be no less - //! than the greatest inserted key - //! - //! Effects: Inserts x into the container in the last position. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - //! - //! Note: This function does not check preconditions so if value is - //! less than the greatest inserted key container ordering invariant will be broken. - //! This function is slightly more efficient than using "insert_before". - //! This is a low-level function to be used only for performance reasons - //! by advanced users. - void push_back(reference value) - { - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - this->sz_traits().increment(); - node_algorithms::push_back(this->header_ptr(), to_insert); - } - - //! Requires: value must be an lvalue, and it must be no greater - //! than the minimum inserted key - //! - //! Effects: Inserts x into the container in the first position. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - //! - //! Note: This function does not check preconditions so if value is - //! greater than the minimum inserted key container ordering invariant will be broken. - //! This function is slightly more efficient than using "insert_before". - //! This is a low-level function to be used only for performance reasons - //! by advanced users. - void push_front(reference value) - { - node_ptr to_insert(this->get_real_value_traits().to_node_ptr(value)); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(node_algorithms::unique(to_insert)); - this->sz_traits().increment(); - node_algorithms::push_front(this->header_ptr(), to_insert); - } - - //! Effects: Erases the element pointed to by pos. - //! - //! Complexity: Average complexity for erase element is constant time. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - iterator erase(const_iterator i) - { - const_iterator ret(i); - ++ret; - node_ptr to_erase(i.pointed_node()); - if(safemode_or_autounlink) - BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT(!node_algorithms::unique(to_erase)); - node_algorithms::erase(this->header_ptr(), to_erase); - this->sz_traits().decrement(); - if(safemode_or_autounlink) - node_algorithms::init(to_erase); - return ret.unconst(); - } - - //! Effects: Erases the range pointed to by b end e. - //! - //! Complexity: Average complexity for erase range is at most - //! O(log(size() + N)), where N is the number of elements in the range. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - iterator erase(const_iterator b, const_iterator e) - { size_type n; return this->private_erase(b, e, n); } - - //! Effects: Erases all the elements with the given value. - //! - //! Returns: The number of erased elements. - //! - //! Complexity: O(log(size() + N). - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - size_type erase(const_reference value) - { return this->erase(value, this->comp()); } - - //! Effects: Erases all the elements with the given key. - //! according to the comparison functor "comp". - //! - //! Returns: The number of erased elements. - //! - //! Complexity: O(log(size() + N). - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - template - size_type erase(const KeyType& key, KeyValueCompare comp - /// @cond - , typename detail::enable_if_c::value >::type * = 0 - /// @endcond - ) - { - std::pair p = this->equal_range(key, comp); - size_type n; - this->private_erase(p.first, p.second, n); - return n; - } - - //! Requires: Disposer::operator()(pointer) shouldn't throw. - //! - //! Effects: Erases the element pointed to by pos. - //! Disposer::operator()(pointer) is called for the removed element. - //! - //! Complexity: Average complexity for erase element is constant time. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators - //! to the erased elements. - template - iterator erase_and_dispose(const_iterator i, Disposer disposer) - { - node_ptr to_erase(i.pointed_node()); - iterator ret(this->erase(i)); - disposer(this->get_real_value_traits().to_value_ptr(to_erase)); - return ret; - } - - #if !defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - template - iterator erase_and_dispose(iterator i, Disposer disposer) - { return this->erase_and_dispose(const_iterator(i), disposer); } - #endif - - //! Requires: Disposer::operator()(pointer) shouldn't throw. - //! - //! Effects: Erases all the elements with the given value. - //! Disposer::operator()(pointer) is called for the removed elements. - //! - //! Returns: The number of erased elements. - //! - //! Complexity: O(log(size() + N). - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - template - size_type erase_and_dispose(const_reference value, Disposer disposer) - { - std::pair p = this->equal_range(value); - size_type n; - this->private_erase(p.first, p.second, n, disposer); - return n; - } - - //! Requires: Disposer::operator()(pointer) shouldn't throw. - //! - //! Effects: Erases the range pointed to by b end e. - //! Disposer::operator()(pointer) is called for the removed elements. - //! - //! Complexity: Average complexity for erase range is at most - //! O(log(size() + N)), where N is the number of elements in the range. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators - //! to the erased elements. - template - iterator erase_and_dispose(const_iterator b, const_iterator e, Disposer disposer) - { size_type n; return this->private_erase(b, e, n, disposer); } - - //! Requires: Disposer::operator()(pointer) shouldn't throw. - //! - //! Effects: Erases all the elements with the given key. - //! according to the comparison functor "comp". - //! Disposer::operator()(pointer) is called for the removed elements. - //! - //! Returns: The number of erased elements. - //! - //! Complexity: O(log(size() + N). - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators - //! to the erased elements. - template - size_type erase_and_dispose(const KeyType& key, KeyValueCompare comp, Disposer disposer - /// @cond - , typename detail::enable_if_c::value >::type * = 0 - /// @endcond - ) - { - std::pair p = this->equal_range(key, comp); - size_type n; - this->private_erase(p.first, p.second, n, disposer); - return n; - } - - //! Effects: Erases all of the elements. - //! - //! Complexity: Linear to the number of elements on the container. - //! if it's a safe-mode or auto-unlink value_type. Constant time otherwise. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. No destructors are called. - void clear() - { - if(safemode_or_autounlink){ - this->clear_and_dispose(detail::null_disposer()); - } - else{ - node_algorithms::init_header(this->header_ptr()); - this->sz_traits().set_size(0); - } - } - - //! Effects: Erases all of the elements calling disposer(p) for - //! each node to be erased. - //! Complexity: Average complexity for is at most O(log(size() + N)), - //! where N is the number of elements in the container. - //! - //! Throws: Nothing. - //! - //! Note: Invalidates the iterators (but not the references) - //! to the erased elements. Calls N times to disposer functor. - template - void clear_and_dispose(Disposer disposer) - { - node_algorithms::clear_and_dispose(this->header_ptr() - , detail::node_disposer(disposer, &this->get_real_value_traits())); - node_algorithms::init_header(this->header_ptr()); - this->sz_traits().set_size(0); - } - - #if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Effects: Returns the number of contained elements with the given value - //! - //! Complexity: Logarithmic to the number of elements contained plus lineal - //! to number of objects with the given value. - //! - //! Throws: Nothing. - size_type count(const_reference value) const; - - //! Effects: Returns the number of contained elements with the given key - //! - //! Complexity: Logarithmic to the number of elements contained plus lineal - //! to number of objects with the given key. - //! - //! Throws: Nothing. - template - size_type count(const KeyType &key, KeyValueCompare comp) const; - - //! Effects: Returns an iterator to the first element whose - //! key is not less than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - iterator lower_bound(const_reference value); - - //! Effects: Returns an iterator to the first element whose - //! key is not less than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - const_iterator lower_bound(const_reference value) const; - - //! Effects: Returns an iterator to the first element whose - //! key is not less than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - iterator lower_bound(const KeyType &key, KeyValueCompare comp); - - //! Effects: Returns a const iterator to the first element whose - //! key is not less than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - const_iterator lower_bound(const KeyType &key, KeyValueCompare comp) const; - - //! Effects: Returns an iterator to the first element whose - //! key is greater than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - iterator upper_bound(const_reference value); - - //! Effects: Returns an iterator to the first element whose - //! key is greater than k according to comp or end() if that element - //! does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - iterator upper_bound(const KeyType &key, KeyValueCompare comp); - - //! Effects: Returns an iterator to the first element whose - //! key is greater than k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - const_iterator upper_bound(const_reference value) const; - - //! Effects: Returns an iterator to the first element whose - //! key is greater than k according to comp or end() if that element - //! does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - const_iterator upper_bound(const KeyType &key, KeyValueCompare comp) const; - - //! Effects: Finds an iterator to the first element whose key is - //! k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - iterator find(const_reference value); - - //! Effects: Finds an iterator to the first element whose key is - //! k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - iterator find(const KeyType &key, KeyValueCompare comp); - - //! Effects: Finds a const_iterator to the first element whose key is - //! k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - const_iterator find(const_reference value) const; - - //! Effects: Finds a const_iterator to the first element whose key is - //! k or end() if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - const_iterator find(const KeyType &key, KeyValueCompare comp) const; - - //! Effects: Finds a range containing all elements whose key is k or - //! an empty range that indicates the position where those elements would be - //! if they there is no elements with key k. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - std::pair equal_range(const_reference value); - - //! Effects: Finds a range containing all elements whose key is k or - //! an empty range that indicates the position where those elements would be - //! if they there is no elements with key k. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - std::pair equal_range(const KeyType &key, KeyValueCompare comp); - - //! Effects: Finds a range containing all elements whose key is k or - //! an empty range that indicates the position where those elements would be - //! if they there is no elements with key k. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - std::pair - equal_range(const_reference value) const; - - //! Effects: Finds a range containing all elements whose key is k or - //! an empty range that indicates the position where those elements would be - //! if they there is no elements with key k. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - template - std::pair - equal_range(const KeyType &key, KeyValueCompare comp) const; - - //! Requires: 'lower_value' must not be greater than 'upper_value'. If - //! 'lower_value' == 'upper_value', ('left_closed' || 'right_closed') must be false. - //! - //! Effects: Returns an a pair with the following criteria: - //! - //! first = lower_bound(lower_key) if left_closed, upper_bound(lower_key) otherwise - //! - //! second = upper_bound(upper_key) if right_closed, lower_bound(upper_key) otherwise - //! - //! Complexity: Logarithmic. - //! - //! Throws: If the predicate throws. - //! - //! Note: This function can be more efficient than calling upper_bound - //! and lower_bound for lower_value and upper_value. - //! - //! Note: Experimental function, the interface might change in future releases. - std::pair bounded_range - (const_reference lower_value, const_reference upper_value, bool left_closed, bool right_closed); - - //! Requires: KeyValueCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the container. - //! 'lower_key' must not be greater than 'upper_key' according to 'comp'. If - //! 'lower_key' == 'upper_key', ('left_closed' || 'right_closed') must be false. - //! - //! Effects: Returns an a pair with the following criteria: - //! - //! first = lower_bound(lower_key, comp) if left_closed, upper_bound(lower_key, comp) otherwise - //! - //! second = upper_bound(upper_key, comp) if right_closed, lower_bound(upper_key, comp) otherwise - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - //! - //! Note: This function can be more efficient than calling upper_bound - //! and lower_bound for lower_key and upper_key. - //! - //! Note: Experimental function, the interface might change in future releases. - template - std::pair bounded_range - (const KeyType &lower_key, const KeyType &upper_key, KeyValueCompare comp, bool left_closed, bool right_closed); - - //! Requires: 'lower_value' must not be greater than 'upper_value'. If - //! 'lower_value' == 'upper_value', ('left_closed' || 'right_closed') must be false. - //! - //! Effects: Returns an a pair with the following criteria: - //! - //! first = lower_bound(lower_key) if left_closed, upper_bound(lower_key) otherwise - //! - //! second = upper_bound(upper_key) if right_closed, lower_bound(upper_key) otherwise - //! - //! Complexity: Logarithmic. - //! - //! Throws: If the predicate throws. - //! - //! Note: This function can be more efficient than calling upper_bound - //! and lower_bound for lower_value and upper_value. - //! - //! Note: Experimental function, the interface might change in future releases. - std::pair bounded_range - (const_reference lower_value, const_reference upper_value, bool left_closed, bool right_closed) const; - - //! Requires: KeyValueCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the container. - //! 'lower_key' must not be greater than 'upper_key' according to 'comp'. If - //! 'lower_key' == 'upper_key', ('left_closed' || 'right_closed') must be false. - //! - //! Effects: Returns an a pair with the following criteria: - //! - //! first = lower_bound(lower_key, comp) if left_closed, upper_bound(lower_key, comp) otherwise - //! - //! second = upper_bound(upper_key, comp) if right_closed, lower_bound(upper_key, comp) otherwise - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - //! - //! Note: This function can be more efficient than calling upper_bound - //! and lower_bound for lower_key and upper_key. - //! - //! Note: Experimental function, the interface might change in future releases. - template - std::pair bounded_range - (const KeyType &lower_key, const KeyType &upper_key, KeyValueCompare comp, bool left_closed, bool right_closed) const; - - //! Requires: value must be an lvalue and shall be in a set of - //! appropriate type. Otherwise the behavior is undefined. - //! - //! Effects: Returns: a valid iterator i belonging to the set - //! that points to the value - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Note: This static function is available only if the value traits - //! is stateless. - static iterator s_iterator_to(reference value); - - //! Requires: value must be an lvalue and shall be in a set of - //! appropriate type. Otherwise the behavior is undefined. - //! - //! Effects: Returns: a valid const_iterator i belonging to the - //! set that points to the value - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Note: This static function is available only if the value traits - //! is stateless. - static const_iterator s_iterator_to(const_reference value); - - //! Requires: value must be an lvalue and shall be in a set of - //! appropriate type. Otherwise the behavior is undefined. - //! - //! Effects: Returns: a valid iterator i belonging to the set - //! that points to the value - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - iterator iterator_to(reference value); - - //! Requires: value must be an lvalue and shall be in a set of - //! appropriate type. Otherwise the behavior is undefined. - //! - //! Effects: Returns: a valid const_iterator i belonging to the - //! set that points to the value - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - const_iterator iterator_to(const_reference value) const; - - //! Requires: value shall not be in a container. - //! - //! Effects: init_node puts the hook of a value in a well-known default - //! state. - //! - //! Throws: Nothing. - //! - //! Complexity: Constant time. - //! - //! Note: This function puts the hook in the well-known default state - //! used by auto_unlink and safe hooks. - static void init_node(reference value); - - #endif //#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Effects: Unlinks the leftmost node from the container. - //! - //! Complexity: Average complexity is constant time. - //! - //! Throws: Nothing. - //! - //! Notes: This function breaks the container and the container can - //! only be used for more unlink_leftmost_without_rebalance calls. - //! This function is normally used to achieve a step by step - //! controlled destruction of the container. - pointer unlink_leftmost_without_rebalance() - { - node_ptr to_be_disposed(node_algorithms::unlink_leftmost_without_rebalance - (this->header_ptr())); - if(!to_be_disposed) - return 0; - this->sz_traits().decrement(); - if(safemode_or_autounlink)//If this is commented does not work with normal_link - node_algorithms::init(to_be_disposed); - return this->get_real_value_traits().to_value_ptr(to_be_disposed); - } - - #if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Requires: replace_this must be a valid iterator of *this - //! and with_this must not be inserted in any container. - //! - //! Effects: Replaces replace_this in its position in the - //! container with with_this. The container does not need to be rebalanced. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Note: This function will break container ordering invariants if - //! with_this is not equivalent to *replace_this according to the - //! ordering rules. This function is faster than erasing and inserting - //! the node, since no rebalancing or comparison is needed. - void replace_node(iterator replace_this, reference with_this); - - //! Effects: Rebalances the tree. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear. - void rebalance(); - - //! Requires: old_root is a node of a tree. - //! - //! Effects: Rebalances the subtree rooted at old_root. - //! - //! Returns: The new root of the subtree. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear to the elements in the subtree. - iterator rebalance_subtree(iterator root); - - #endif //#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Effects: removes "value" from the container. - //! - //! Throws: Nothing. - //! - //! Complexity: Logarithmic time. - //! - //! Note: This static function is only usable with non-constant - //! time size containers that have stateless comparison functors. - //! - //! If the user calls - //! this function with a constant time size container or stateful comparison - //! functor a compilation error will be issued. - static void remove_node(reference value) - { - BOOST_STATIC_ASSERT((!constant_time_size)); - node_ptr to_remove(value_traits::to_node_ptr(value)); - node_algorithms::unlink(to_remove); - if(safemode_or_autounlink) - node_algorithms::init(to_remove); - } - - /// @cond - private: - template - iterator private_erase(const_iterator b, const_iterator e, size_type &n, Disposer disposer) - { - for(n = 0; b != e; ++n) - this->erase_and_dispose(b++, disposer); - return b.unconst(); - } - - iterator private_erase(const_iterator b, const_iterator e, size_type &n) - { - for(n = 0; b != e; ++n) - this->erase(b++); - return b.unconst(); - } - /// @endcond - - private: - static bstree_impl &priv_container_from_end_iterator(const const_iterator &end_iterator) - { - return *static_cast - (boost::intrusive::detail::to_raw_pointer(end_iterator.pointed_node())); - } -}; - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline bool operator< -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ return std::lexicographical_compare(x.begin(), x.end(), y.begin(), y.end()); } - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -bool operator== -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ - typedef bstree_impl tree_type; - typedef typename tree_type::const_iterator const_iterator; - - if(tree_type::constant_time_size && x.size() != y.size()){ - return false; - } - const_iterator end1 = x.end(); - const_iterator i1 = x.begin(); - const_iterator i2 = y.begin(); - if(tree_type::constant_time_size){ - while (i1 != end1 && *i1 == *i2) { - ++i1; - ++i2; - } - return i1 == end1; - } - else{ - const_iterator end2 = y.end(); - while (i1 != end1 && i2 != end2 && *i1 == *i2) { - ++i1; - ++i2; - } - return i1 == end1 && i2 == end2; - } -} - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline bool operator!= -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ return !(x == y); } - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline bool operator> -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ return y < x; } - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline bool operator<= -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ return !(y < x); } - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline bool operator>= -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(const bstree_impl &x, const bstree_impl &y) -#else -( const bstree_impl &x -, const bstree_impl &y) -#endif -{ return !(x < y); } - -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -template -#else -template -#endif -inline void swap -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) -(bstree_impl &x, bstree_impl &y) -#else -( bstree_impl &x -, bstree_impl &y) -#endif -{ x.swap(y); } - -//! Helper metafunction to define a \c bstree that yields to the same type when the -//! same options (either explicitly or implicitly) are used. -#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) || defined(BOOST_INTRUSIVE_VARIADIC_TEMPLATES) -template -#else -template -#endif -struct make_bstree -{ - /// @cond - typedef typename pack_options - < bstree_defaults, - #if !defined(BOOST_INTRUSIVE_VARIADIC_TEMPLATES) - O1, O2, O3, O4 - #else - Options... - #endif - >::type packed_options; - - typedef typename detail::get_value_traits - ::type value_traits; - - typedef bstree_impl - < value_traits - , typename packed_options::compare - , typename packed_options::size_type - , packed_options::constant_time_size - , BsTreeAlgorithms - > implementation_defined; - /// @endcond - typedef implementation_defined type; -}; - - -#ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - -#if !defined(BOOST_INTRUSIVE_VARIADIC_TEMPLATES) -template -#else -template -#endif -class bstree - : public make_bstree::type -{ - typedef typename make_bstree - ::type Base; - BOOST_MOVABLE_BUT_NOT_COPYABLE(bstree) - - public: - typedef typename Base::value_compare value_compare; - typedef typename Base::value_traits value_traits; - typedef typename Base::real_value_traits real_value_traits; - typedef typename Base::iterator iterator; - typedef typename Base::const_iterator const_iterator; - - //Assert if passed value traits are compatible with the type - BOOST_STATIC_ASSERT((detail::is_same::value)); - - bstree( const value_compare &cmp = value_compare() - , const value_traits &v_traits = value_traits()) - : Base(cmp, v_traits) - {} - - template - bstree( bool unique, Iterator b, Iterator e - , const value_compare &cmp = value_compare() - , const value_traits &v_traits = value_traits()) - : Base(unique, b, e, cmp, v_traits) - {} - - bstree(BOOST_RV_REF(bstree) x) - : Base(::boost::move(static_cast(x))) - {} - - bstree& operator=(BOOST_RV_REF(bstree) x) - { return static_cast(this->Base::operator=(::boost::move(static_cast(x)))); } - - static bstree &container_from_end_iterator(iterator end_iterator) - { return static_cast(Base::container_from_end_iterator(end_iterator)); } - - static const bstree &container_from_end_iterator(const_iterator end_iterator) - { return static_cast(Base::container_from_end_iterator(end_iterator)); } - - static bstree &container_from_iterator(iterator it) - { return static_cast(Base::container_from_iterator(it)); } - - static const bstree &container_from_iterator(const_iterator it) - { return static_cast(Base::container_from_iterator(it)); } -}; - -#endif -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_BSTREE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree_algorithms.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree_algorithms.hpp deleted file mode 100644 index 62973292..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/bstree_algorithms.hpp +++ /dev/null @@ -1,1988 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_BSTREE_ALGORITHMS_HPP -#define BOOST_INTRUSIVE_BSTREE_ALGORITHMS_HPP - -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace intrusive { - -/// @cond - -//! This type is the information that will be filled by insert_unique_check -template -struct insert_commit_data_t -{ - insert_commit_data_t() - : link_left(false) - , node() - {} - bool link_left; - NodePtr node; -}; - -template -struct data_for_rebalance_t -{ - NodePtr x; - NodePtr x_parent; - NodePtr y; -}; - -/// @endcond - - - -//! This is an implementation of a binary search tree. -//! A node in the search tree has references to its children and its parent. This -//! is to allow traversal of the whole tree from a given node making the -//! implementation of iterator a pointer to a node. -//! At the top of the tree a node is used specially. This node's parent pointer -//! is pointing to the root of the tree. Its left pointer points to the -//! leftmost node in the tree and the right pointer to the rightmost one. -//! This node is used to represent the end-iterator. -//! -//! +---------+ -//! header------------------------------>| | -//! | | -//! +----------(left)--------| |--------(right)---------+ -//! | +---------+ | -//! | | | -//! | | (parent) | -//! | | | -//! | | | -//! | +---------+ | -//! root of tree ..|......................> | | | -//! | | D | | -//! | | | | -//! | +-------+---------+-------+ | -//! | | | | -//! | | | | -//! | | | | -//! | | | | -//! | | | | -//! | +---------+ +---------+ | -//! | | | | | | -//! | | B | | F | | -//! | | | | | | -//! | +--+---------+--+ +--+---------+--+ | -//! | | | | | | -//! | | | | | | -//! | | | | | | -//! | +---+-----+ +-----+---+ +---+-----+ +-----+---+ | -//! +-->| | | | | | | |<--+ -//! | A | | C | | E | | G | -//! | | | | | | | | -//! +---------+ +---------+ +---------+ +---------+ -//! -//! bstree_algorithms is configured with a NodeTraits class, which encapsulates the -//! information about the node to be manipulated. NodeTraits must support the -//! following interface: -//! -//! Typedefs: -//! -//! node: The type of the node that forms the binary search tree -//! -//! node_ptr: A pointer to a node -//! -//! const_node_ptr: A pointer to a const node -//! -//! Static functions: -//! -//! static node_ptr get_parent(const_node_ptr n); -//! -//! static void set_parent(node_ptr n, node_ptr parent); -//! -//! static node_ptr get_left(const_node_ptr n); -//! -//! static void set_left(node_ptr n, node_ptr left); -//! -//! static node_ptr get_right(const_node_ptr n); -//! -//! static void set_right(node_ptr n, node_ptr right); -template -class bstree_algorithms -{ - public: - typedef typename NodeTraits::node node; - typedef NodeTraits node_traits; - typedef typename NodeTraits::node_ptr node_ptr; - typedef typename NodeTraits::const_node_ptr const_node_ptr; - typedef insert_commit_data_t insert_commit_data; - typedef data_for_rebalance_t data_for_rebalance; - - /// @cond - - private: - template - struct dispose_subtree_disposer - { - dispose_subtree_disposer(Disposer &disp, const node_ptr & subtree) - : disposer_(&disp), subtree_(subtree) - {} - - void release() - { disposer_ = 0; } - - ~dispose_subtree_disposer() - { - if(disposer_){ - dispose_subtree(subtree_, *disposer_); - } - } - Disposer *disposer_; - const node_ptr subtree_; - }; - - /// @endcond - - public: - //! Requires: 'header' is the header node of a tree. - //! - //! Effects: Returns the first node of the tree, the header if the tree is empty. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - static node_ptr begin_node(const const_node_ptr & header) - { return node_traits::get_left(header); } - - //! Requires: 'header' is the header node of a tree. - //! - //! Effects: Returns the header of the tree. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - static node_ptr end_node(const const_node_ptr & header) - { return detail::uncast(header); } - - //! Requires: 'node' is a node of the tree or an node initialized - //! by init(...) or init_node. - //! - //! Effects: Returns true if the node is initialized by init() or init_node(). - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - static bool unique(const const_node_ptr & node) - { return !NodeTraits::get_parent(node); } - - //! Requires: 'node' is a node of the tree or a header node. - //! - //! Effects: Returns the header of the tree. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - static node_ptr get_header(const const_node_ptr & node) - { - node_ptr n(detail::uncast(node)); - node_ptr p(NodeTraits::get_parent(node)); - //If p is null, then n is the header of an empty tree - if(p){ - //Non-empty tree, check if n is neither root nor header - node_ptr pp(NodeTraits::get_parent(p)); - //If granparent is not equal to n, then n is neither root nor header, - //the try the fast path - if(n != pp){ - do{ - n = p; - p = pp; - pp = NodeTraits::get_parent(pp); - }while(n != pp); - n = p; - } - //Check if n is root or header when size() > 0 - else if(!is_header(n)){ - n = p; - } - } - return n; - /* - node_ptr h = detail::uncast(node); - node_ptr p = NodeTraits::get_parent(node); - if(p){ - while(!is_header(p)) - p = NodeTraits::get_parent(p); - return p; - } - else{ - return h; - }*/ - } - - //! Requires: node1 and node2 can't be header nodes - //! of two trees. - //! - //! Effects: Swaps two nodes. After the function node1 will be inserted - //! in the position node2 before the function. node2 will be inserted in the - //! position node1 had before the function. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - //! - //! Note: This function will break container ordering invariants if - //! node1 and node2 are not equivalent according to the ordering rules. - //! - //!Experimental function - static void swap_nodes(const node_ptr & node1, const node_ptr & node2) - { - if(node1 == node2) - return; - - node_ptr header1(get_header(node1)), header2(get_header(node2)); - swap_nodes(node1, header1, node2, header2); - } - - //! Requires: node1 and node2 can't be header nodes - //! of two trees with header header1 and header2. - //! - //! Effects: Swaps two nodes. After the function node1 will be inserted - //! in the position node2 before the function. node2 will be inserted in the - //! position node1 had before the function. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Note: This function will break container ordering invariants if - //! node1 and node2 are not equivalent according to the ordering rules. - //! - //!Experimental function - static void swap_nodes(const node_ptr & node1, const node_ptr & header1, const node_ptr & node2, const node_ptr & header2) - { - if(node1 == node2) - return; - - //node1 and node2 must not be header nodes - //BOOST_INTRUSIVE_INVARIANT_ASSERT((header1 != node1 && header2 != node2)); - if(header1 != header2){ - //Update header1 if necessary - if(node1 == NodeTraits::get_left(header1)){ - NodeTraits::set_left(header1, node2); - } - - if(node1 == NodeTraits::get_right(header1)){ - NodeTraits::set_right(header1, node2); - } - - if(node1 == NodeTraits::get_parent(header1)){ - NodeTraits::set_parent(header1, node2); - } - - //Update header2 if necessary - if(node2 == NodeTraits::get_left(header2)){ - NodeTraits::set_left(header2, node1); - } - - if(node2 == NodeTraits::get_right(header2)){ - NodeTraits::set_right(header2, node1); - } - - if(node2 == NodeTraits::get_parent(header2)){ - NodeTraits::set_parent(header2, node1); - } - } - else{ - //If both nodes are from the same tree - //Update header if necessary - if(node1 == NodeTraits::get_left(header1)){ - NodeTraits::set_left(header1, node2); - } - else if(node2 == NodeTraits::get_left(header2)){ - NodeTraits::set_left(header2, node1); - } - - if(node1 == NodeTraits::get_right(header1)){ - NodeTraits::set_right(header1, node2); - } - else if(node2 == NodeTraits::get_right(header2)){ - NodeTraits::set_right(header2, node1); - } - - if(node1 == NodeTraits::get_parent(header1)){ - NodeTraits::set_parent(header1, node2); - } - else if(node2 == NodeTraits::get_parent(header2)){ - NodeTraits::set_parent(header2, node1); - } - - //Adjust data in nodes to be swapped - //so that final link swap works as expected - if(node1 == NodeTraits::get_parent(node2)){ - NodeTraits::set_parent(node2, node2); - - if(node2 == NodeTraits::get_right(node1)){ - NodeTraits::set_right(node1, node1); - } - else{ - NodeTraits::set_left(node1, node1); - } - } - else if(node2 == NodeTraits::get_parent(node1)){ - NodeTraits::set_parent(node1, node1); - - if(node1 == NodeTraits::get_right(node2)){ - NodeTraits::set_right(node2, node2); - } - else{ - NodeTraits::set_left(node2, node2); - } - } - } - - //Now swap all the links - node_ptr temp; - //swap left link - temp = NodeTraits::get_left(node1); - NodeTraits::set_left(node1, NodeTraits::get_left(node2)); - NodeTraits::set_left(node2, temp); - //swap right link - temp = NodeTraits::get_right(node1); - NodeTraits::set_right(node1, NodeTraits::get_right(node2)); - NodeTraits::set_right(node2, temp); - //swap parent link - temp = NodeTraits::get_parent(node1); - NodeTraits::set_parent(node1, NodeTraits::get_parent(node2)); - NodeTraits::set_parent(node2, temp); - - //Now adjust adjacent nodes for newly inserted node 1 - if((temp = NodeTraits::get_left(node1))){ - NodeTraits::set_parent(temp, node1); - } - if((temp = NodeTraits::get_right(node1))){ - NodeTraits::set_parent(temp, node1); - } - if((temp = NodeTraits::get_parent(node1)) && - //The header has been already updated so avoid it - temp != header2){ - if(NodeTraits::get_left(temp) == node2){ - NodeTraits::set_left(temp, node1); - } - if(NodeTraits::get_right(temp) == node2){ - NodeTraits::set_right(temp, node1); - } - } - //Now adjust adjacent nodes for newly inserted node 2 - if((temp = NodeTraits::get_left(node2))){ - NodeTraits::set_parent(temp, node2); - } - if((temp = NodeTraits::get_right(node2))){ - NodeTraits::set_parent(temp, node2); - } - if((temp = NodeTraits::get_parent(node2)) && - //The header has been already updated so avoid it - temp != header1){ - if(NodeTraits::get_left(temp) == node1){ - NodeTraits::set_left(temp, node2); - } - if(NodeTraits::get_right(temp) == node1){ - NodeTraits::set_right(temp, node2); - } - } - } - - //! Requires: node_to_be_replaced must be inserted in a tree - //! and new_node must not be inserted in a tree. - //! - //! Effects: Replaces node_to_be_replaced in its position in the - //! tree with new_node. The tree does not need to be rebalanced - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - //! - //! Note: This function will break container ordering invariants if - //! new_node is not equivalent to node_to_be_replaced according to the - //! ordering rules. This function is faster than erasing and inserting - //! the node, since no rebalancing and comparison is needed. Experimental function - static void replace_node(const node_ptr & node_to_be_replaced, const node_ptr & new_node) - { - if(node_to_be_replaced == new_node) - return; - replace_node(node_to_be_replaced, get_header(node_to_be_replaced), new_node); - } - - //! Requires: node_to_be_replaced must be inserted in a tree - //! with header "header" and new_node must not be inserted in a tree. - //! - //! Effects: Replaces node_to_be_replaced in its position in the - //! tree with new_node. The tree does not need to be rebalanced - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Note: This function will break container ordering invariants if - //! new_node is not equivalent to node_to_be_replaced according to the - //! ordering rules. This function is faster than erasing and inserting - //! the node, since no rebalancing or comparison is needed. Experimental function - static void replace_node(const node_ptr & node_to_be_replaced, const node_ptr & header, const node_ptr & new_node) - { - if(node_to_be_replaced == new_node) - return; - - //Update header if necessary - if(node_to_be_replaced == NodeTraits::get_left(header)){ - NodeTraits::set_left(header, new_node); - } - - if(node_to_be_replaced == NodeTraits::get_right(header)){ - NodeTraits::set_right(header, new_node); - } - - if(node_to_be_replaced == NodeTraits::get_parent(header)){ - NodeTraits::set_parent(header, new_node); - } - - //Now set data from the original node - node_ptr temp; - NodeTraits::set_left(new_node, NodeTraits::get_left(node_to_be_replaced)); - NodeTraits::set_right(new_node, NodeTraits::get_right(node_to_be_replaced)); - NodeTraits::set_parent(new_node, NodeTraits::get_parent(node_to_be_replaced)); - - //Now adjust adjacent nodes for newly inserted node - if((temp = NodeTraits::get_left(new_node))){ - NodeTraits::set_parent(temp, new_node); - } - if((temp = NodeTraits::get_right(new_node))){ - NodeTraits::set_parent(temp, new_node); - } - if((temp = NodeTraits::get_parent(new_node)) && - //The header has been already updated so avoid it - temp != header){ - if(NodeTraits::get_left(temp) == node_to_be_replaced){ - NodeTraits::set_left(temp, new_node); - } - if(NodeTraits::get_right(temp) == node_to_be_replaced){ - NodeTraits::set_right(temp, new_node); - } - } - } - - //! Requires: 'node' is a node from the tree except the header. - //! - //! Effects: Returns the next node of the tree. - //! - //! Complexity: Average constant time. - //! - //! Throws: Nothing. - static node_ptr next_node(const node_ptr & node) - { - node_ptr p_right(NodeTraits::get_right(node)); - if(p_right){ - return minimum(p_right); - } - else { - node_ptr p(node); - node_ptr x = NodeTraits::get_parent(p); - while(p == NodeTraits::get_right(x)){ - p = x; - x = NodeTraits::get_parent(x); - } - return NodeTraits::get_right(p) != x ? x : detail::uncast(p); - } - } - - //! Requires: 'node' is a node from the tree except the leftmost node. - //! - //! Effects: Returns the previous node of the tree. - //! - //! Complexity: Average constant time. - //! - //! Throws: Nothing. - static node_ptr prev_node(const node_ptr & node) - { - if(is_header(node)){ - return NodeTraits::get_right(node); - //return maximum(NodeTraits::get_parent(node)); - } - else if(NodeTraits::get_left(node)){ - return maximum(NodeTraits::get_left(node)); - } - else { - node_ptr p(node); - node_ptr x = NodeTraits::get_parent(p); - while(p == NodeTraits::get_left(x)){ - p = x; - x = NodeTraits::get_parent(x); - } - return x; - } - } - - //! Requires: 'node' is a node of a tree but not the header. - //! - //! Effects: Returns the minimum node of the subtree starting at p. - //! - //! Complexity: Logarithmic to the size of the subtree. - //! - //! Throws: Nothing. - static node_ptr minimum (node_ptr node) - { - for(node_ptr p_left = NodeTraits::get_left(node) - ;p_left - ;p_left = NodeTraits::get_left(node)){ - node = p_left; - } - return node; - } - - //! Requires: 'node' is a node of a tree but not the header. - //! - //! Effects: Returns the maximum node of the subtree starting at p. - //! - //! Complexity: Logarithmic to the size of the subtree. - //! - //! Throws: Nothing. - static node_ptr maximum(node_ptr node) - { - for(node_ptr p_right = NodeTraits::get_right(node) - ;p_right - ;p_right = NodeTraits::get_right(node)){ - node = p_right; - } - return node; - } - - //! Requires: 'node' must not be part of any tree. - //! - //! Effects: After the function unique(node) == true. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Nodes: If node is inserted in a tree, this function corrupts the tree. - static void init(const node_ptr & node) - { - NodeTraits::set_parent(node, node_ptr()); - NodeTraits::set_left(node, node_ptr()); - NodeTraits::set_right(node, node_ptr()); - }; - - //! Effects: Returns true if node is in the same state as if called init(node) - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - static bool inited(const const_node_ptr & node) - { - return !NodeTraits::get_parent(node) && - !NodeTraits::get_left(node) && - !NodeTraits::get_right(node) ; - }; - - //! Requires: node must not be part of any tree. - //! - //! Effects: Initializes the header to represent an empty tree. - //! unique(header) == true. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - //! - //! Nodes: If node is inserted in a tree, this function corrupts the tree. - static void init_header(const node_ptr & header) - { - NodeTraits::set_parent(header, node_ptr()); - NodeTraits::set_left(header, header); - NodeTraits::set_right(header, header); - } - - //! Requires: "disposer" must be an object function - //! taking a node_ptr parameter and shouldn't throw. - //! - //! Effects: Empties the target tree calling - //! void disposer::operator()(const node_ptr &) for every node of the tree - //! except the header. - //! - //! Complexity: Linear to the number of element of the source tree plus the. - //! number of elements of tree target tree when calling this function. - //! - //! Throws: If cloner functor throws. If this happens target nodes are disposed. - template - static void clear_and_dispose(const node_ptr & header, Disposer disposer) - { - node_ptr source_root = NodeTraits::get_parent(header); - if(!source_root) - return; - dispose_subtree(source_root, disposer); - init_header(header); - } - - //! Requires: header is the header of a tree. - //! - //! Effects: Unlinks the leftmost node from the tree, and - //! updates the header link to the new leftmost node. - //! - //! Complexity: Average complexity is constant time. - //! - //! Throws: Nothing. - //! - //! Notes: This function breaks the tree and the tree can - //! only be used for more unlink_leftmost_without_rebalance calls. - //! This function is normally used to achieve a step by step - //! controlled destruction of the tree. - static node_ptr unlink_leftmost_without_rebalance(const node_ptr & header) - { - node_ptr leftmost = NodeTraits::get_left(header); - if (leftmost == header) - return node_ptr(); - node_ptr leftmost_parent(NodeTraits::get_parent(leftmost)); - node_ptr leftmost_right (NodeTraits::get_right(leftmost)); - bool is_root = leftmost_parent == header; - - if (leftmost_right){ - NodeTraits::set_parent(leftmost_right, leftmost_parent); - NodeTraits::set_left(header, bstree_algorithms::minimum(leftmost_right)); - - if (is_root) - NodeTraits::set_parent(header, leftmost_right); - else - NodeTraits::set_left(NodeTraits::get_parent(header), leftmost_right); - } - else if (is_root){ - NodeTraits::set_parent(header, node_ptr()); - NodeTraits::set_left(header, header); - NodeTraits::set_right(header, header); - } - else{ - NodeTraits::set_left(leftmost_parent, node_ptr()); - NodeTraits::set_left(header, leftmost_parent); - } - return leftmost; - } - - //! Requires: node is a node of the tree but it's not the header. - //! - //! Effects: Returns the number of nodes of the subtree. - //! - //! Complexity: Linear time. - //! - //! Throws: Nothing. - static std::size_t size(const const_node_ptr & header) - { - node_ptr beg(begin_node(header)); - node_ptr end(end_node(header)); - std::size_t i = 0; - for(;beg != end; beg = next_node(beg)) ++i; - return i; - } - - //! Requires: header1 and header2 must be the header nodes - //! of two trees. - //! - //! Effects: Swaps two trees. After the function header1 will contain - //! links to the second tree and header2 will have links to the first tree. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - static void swap_tree(const node_ptr & header1, const node_ptr & header2) - { - if(header1 == header2) - return; - - node_ptr tmp; - - //Parent swap - tmp = NodeTraits::get_parent(header1); - NodeTraits::set_parent(header1, NodeTraits::get_parent(header2)); - NodeTraits::set_parent(header2, tmp); - //Left swap - tmp = NodeTraits::get_left(header1); - NodeTraits::set_left(header1, NodeTraits::get_left(header2)); - NodeTraits::set_left(header2, tmp); - //Right swap - tmp = NodeTraits::get_right(header1); - NodeTraits::set_right(header1, NodeTraits::get_right(header2)); - NodeTraits::set_right(header2, tmp); - - //Now test parent - node_ptr h1_parent(NodeTraits::get_parent(header1)); - if(h1_parent){ - NodeTraits::set_parent(h1_parent, header1); - } - else{ - NodeTraits::set_left(header1, header1); - NodeTraits::set_right(header1, header1); - } - - node_ptr h2_parent(NodeTraits::get_parent(header2)); - if(h2_parent){ - NodeTraits::set_parent(h2_parent, header2); - } - else{ - NodeTraits::set_left(header2, header2); - NodeTraits::set_right(header2, header2); - } - } - - //! Requires: p is a node of a tree. - //! - //! Effects: Returns true if p is the header of the tree. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - static bool is_header(const const_node_ptr & p) - { - node_ptr p_left (NodeTraits::get_left(p)); - node_ptr p_right(NodeTraits::get_right(p)); - if(!NodeTraits::get_parent(p) || //Header condition when empty tree - (p_left && p_right && //Header always has leftmost and rightmost - (p_left == p_right || //Header condition when only node - (NodeTraits::get_parent(p_left) != p || - NodeTraits::get_parent(p_right) != p )) - //When tree size > 1 headers can't be leftmost's - //and rightmost's parent - )){ - return true; - } - return false; - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! - //! Effects: Returns an node_ptr to the element that is equivalent to - //! "key" according to "comp" or "header" if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - template - static node_ptr find - (const const_node_ptr & header, const KeyType &key, KeyNodePtrCompare comp) - { - node_ptr end = detail::uncast(header); - node_ptr y = lower_bound(header, key, comp); - return (y == end || comp(key, y)) ? end : y; - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! 'lower_key' must not be greater than 'upper_key' according to 'comp'. If - //! 'lower_key' == 'upper_key', ('left_closed' || 'right_closed') must be false. - //! - //! Effects: Returns an a pair with the following criteria: - //! - //! first = lower_bound(lower_key) if left_closed, upper_bound(lower_key) otherwise - //! - //! second = upper_bound(upper_key) if right_closed, lower_bound(upper_key) otherwise - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - //! - //! Note: This function can be more efficient than calling upper_bound - //! and lower_bound for lower_key and upper_key. - //! - //! Note: Experimental function, the interface might change. - template< class KeyType, class KeyNodePtrCompare> - static std::pair bounded_range - ( const const_node_ptr & header - , const KeyType &lower_key - , const KeyType &upper_key - , KeyNodePtrCompare comp - , bool left_closed - , bool right_closed) - { - node_ptr y = detail::uncast(header); - node_ptr x = NodeTraits::get_parent(header); - - while(x){ - //If x is less than lower_key the target - //range is on the right part - if(comp(x, lower_key)){ - //Check for invalid input range - BOOST_INTRUSIVE_INVARIANT_ASSERT(comp(x, upper_key)); - x = NodeTraits::get_right(x); - } - //If the upper_key is less than x, the target - //range is on the left part - else if(comp(upper_key, x)){ - //y > upper_key - y = x; - x = NodeTraits::get_left(x); - } - else{ - //x is inside the bounded range( x >= lower_key && x <= upper_key), - //so we must split lower and upper searches - // - //Sanity check: if lower_key and upper_key are equal, then both left_closed and right_closed can't be false - BOOST_INTRUSIVE_INVARIANT_ASSERT(left_closed || right_closed || comp(lower_key, x) || comp(x, upper_key)); - return std::pair( - left_closed - //If left_closed, then comp(x, lower_key) is already the lower_bound - //condition so we save one comparison and go to the next level - //following traditional lower_bound algo - ? lower_bound_loop(NodeTraits::get_left(x), x, lower_key, comp) - //If left-open, comp(x, lower_key) is not the upper_bound algo - //condition so we must recheck current 'x' node with upper_bound algo - : upper_bound_loop(x, y, lower_key, comp) - , - right_closed - //If right_closed, then comp(upper_key, x) is already the upper_bound - //condition so we can save one comparison and go to the next level - //following lower_bound algo - ? upper_bound_loop(NodeTraits::get_right(x), y, upper_key, comp) - //If right-open, comp(upper_key, x) is not the lower_bound algo - //condition so we must recheck current 'x' node with lower_bound algo - : lower_bound_loop(x, y, upper_key, comp) - ); - } - } - return std::pair (y, y); - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! - //! Effects: Returns the number of elements with a key equivalent to "key"pair of node_ptr delimiting a range containing - //! according to "comp". - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - template - static std::size_t count - (const const_node_ptr & header, const KeyType &key, KeyNodePtrCompare comp) - { - std::pair ret = equal_range(header, key, comp); - std::size_t n = 0; - while(ret.first != ret.second){ - ++n; - ret.first = next_node(ret.first); - } - return n; - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! - //! Effects: Returns an a pair of node_ptr delimiting a range containing - //! all elements that are equivalent to "key" according to "comp" or an - //! empty range that indicates the position where those elements would be - //! if there are no equivalent elements. - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - template - static std::pair equal_range - (const const_node_ptr & header, const KeyType &key, KeyNodePtrCompare comp) - { - return bounded_range(header, key, key, comp, true, true); - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! - //! Effects: Returns an node_ptr to the first element that is - //! not less than "key" according to "comp" or "header" if that element does - //! not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - template - static node_ptr lower_bound - (const const_node_ptr & header, const KeyType &key, KeyNodePtrCompare comp) - { - return lower_bound_loop(NodeTraits::get_parent(header), detail::uncast(header), key, comp); - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. KeyNodePtrCompare can compare KeyType with tree's node_ptrs. - //! - //! Effects: Returns an node_ptr to the first element that is greater - //! than "key" according to "comp" or "header" if that element does not exist. - //! - //! Complexity: Logarithmic. - //! - //! Throws: If "comp" throws. - template - static node_ptr upper_bound - (const const_node_ptr & header, const KeyType &key, KeyNodePtrCompare comp) - { - return upper_bound_loop(NodeTraits::get_parent(header), detail::uncast(header), key, comp); - } - - //! Requires: "header" must be the header node of a tree. - //! "commit_data" must have been obtained from a previous call to - //! "insert_unique_check". No objects should have been inserted or erased - //! from the set between the "insert_unique_check" that filled "commit_data" - //! and the call to "insert_commit". - //! - //! - //! Effects: Inserts new_node in the set using the information obtained - //! from the "commit_data" that a previous "insert_check" filled. - //! - //! Complexity: Constant time. - //! - //! Throws: Nothing. - //! - //! Notes: This function has only sense if a "insert_unique_check" has been - //! previously executed to fill "commit_data". No value should be inserted or - //! erased between the "insert_check" and "insert_commit" calls. - static void insert_unique_commit - (const node_ptr & header, const node_ptr & new_value, const insert_commit_data &commit_data) - { return insert_commit(header, new_value, commit_data); } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. NodePtrCompare compares KeyType with a node_ptr. - //! - //! Effects: Checks if there is an equivalent node to "key" in the - //! tree according to "comp" and obtains the needed information to realize - //! a constant-time node insertion if there is no equivalent node. - //! - //! Returns: If there is an equivalent value - //! returns a pair containing a node_ptr to the already present node - //! and false. If there is not equivalent key can be inserted returns true - //! in the returned pair's boolean and fills "commit_data" that is meant to - //! be used with the "insert_commit" function to achieve a constant-time - //! insertion function. - //! - //! Complexity: Average complexity is at most logarithmic. - //! - //! Throws: If "comp" throws. - //! - //! Notes: This function is used to improve performance when constructing - //! a node is expensive and the user does not want to have two equivalent nodes - //! in the tree: if there is an equivalent value - //! the constructed object must be discarded. Many times, the part of the - //! node that is used to impose the order is much cheaper to construct - //! than the node and this function offers the possibility to use that part - //! to check if the insertion will be successful. - //! - //! If the check is successful, the user can construct the node and use - //! "insert_commit" to insert the node in constant-time. This gives a total - //! logarithmic complexity to the insertion: check(O(log(N)) + commit(O(1)). - //! - //! "commit_data" remains valid for a subsequent "insert_unique_commit" only - //! if no more objects are inserted or erased from the set. - template - static std::pair insert_unique_check - (const const_node_ptr & header, const KeyType &key - ,KeyNodePtrCompare comp, insert_commit_data &commit_data - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - std::size_t depth = 0; - node_ptr h(detail::uncast(header)); - node_ptr y(h); - node_ptr x(NodeTraits::get_parent(y)); - node_ptr prev = node_ptr(); - - //Find the upper bound, cache the previous value and if we should - //store it in the left or right node - bool left_child = true; - while(x){ - ++depth; - y = x; - x = (left_child = comp(key, x)) ? - NodeTraits::get_left(x) : (prev = y, NodeTraits::get_right(x)); - } - - if(pdepth) *pdepth = depth; - - //Since we've found the upper bound there is no other value with the same key if: - // - There is no previous node - // - The previous node is less than the key - if(!prev || comp(prev, key)){ - commit_data.link_left = left_child; - commit_data.node = y; - return std::pair(node_ptr(), true); - } - //If the previous value was not less than key, it means that it's equal - //(because we've checked the upper bound) - else{ - return std::pair(prev, false); - } - } - - //! Requires: "header" must be the header node of a tree. - //! KeyNodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. NodePtrCompare compares KeyType with a node_ptr. - //! "hint" is node from the "header"'s tree. - //! - //! Effects: Checks if there is an equivalent node to "key" in the - //! tree according to "comp" using "hint" as a hint to where it should be - //! inserted and obtains the needed information to realize - //! a constant-time node insertion if there is no equivalent node. - //! If "hint" is the upper_bound the function has constant time - //! complexity (two comparisons in the worst case). - //! - //! Returns: If there is an equivalent value - //! returns a pair containing a node_ptr to the already present node - //! and false. If there is not equivalent key can be inserted returns true - //! in the returned pair's boolean and fills "commit_data" that is meant to - //! be used with the "insert_commit" function to achieve a constant-time - //! insertion function. - //! - //! Complexity: Average complexity is at most logarithmic, but it is - //! amortized constant time if new_node should be inserted immediately before "hint". - //! - //! Throws: If "comp" throws. - //! - //! Notes: This function is used to improve performance when constructing - //! a node is expensive and the user does not want to have two equivalent nodes - //! in the tree: if there is an equivalent value - //! the constructed object must be discarded. Many times, the part of the - //! node that is used to impose the order is much cheaper to construct - //! than the node and this function offers the possibility to use that part - //! to check if the insertion will be successful. - //! - //! If the check is successful, the user can construct the node and use - //! "insert_commit" to insert the node in constant-time. This gives a total - //! logarithmic complexity to the insertion: check(O(log(N)) + commit(O(1)). - //! - //! "commit_data" remains valid for a subsequent "insert_unique_commit" only - //! if no more objects are inserted or erased from the set. - template - static std::pair insert_unique_check - (const const_node_ptr & header, const node_ptr &hint, const KeyType &key - ,KeyNodePtrCompare comp, insert_commit_data &commit_data - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - //hint must be bigger than the key - if(hint == header || comp(key, hint)){ - node_ptr prev(hint); - //Previous value should be less than the key - if(hint == begin_node(header) || comp((prev = prev_node(hint)), key)){ - commit_data.link_left = unique(header) || !NodeTraits::get_left(hint); - commit_data.node = commit_data.link_left ? hint : prev; - if(pdepth){ - *pdepth = commit_data.node == header ? 0 : depth(commit_data.node) + 1; - } - return std::pair(node_ptr(), true); - } - } - //Hint was wrong, use hintless insertion - return insert_unique_check(header, key, comp, commit_data, pdepth); - } - - //! Requires: "header" must be the header node of a tree. - //! NodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. NodePtrCompare compares two node_ptrs. "hint" is node from - //! the "header"'s tree. - //! - //! Effects: Inserts new_node into the tree, using "hint" as a hint to - //! where it will be inserted. If "hint" is the upper_bound - //! the insertion takes constant time (two comparisons in the worst case). - //! - //! Complexity: Logarithmic in general, but it is amortized - //! constant time if new_node is inserted immediately before "hint". - //! - //! Throws: If "comp" throws. - template - static node_ptr insert_equal - (const node_ptr & h, const node_ptr & hint, const node_ptr & new_node, NodePtrCompare comp - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - insert_equal_check(h, hint, new_node, comp, commit_data, pdepth); - insert_commit(h, new_node, commit_data); - return new_node; - } - - //! Requires: "h" must be the header node of a tree. - //! NodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. NodePtrCompare compares two node_ptrs. - //! - //! Effects: Inserts new_node into the tree before the upper bound - //! according to "comp". - //! - //! Complexity: Average complexity for insert element is at - //! most logarithmic. - //! - //! Throws: If "comp" throws. - template - static node_ptr insert_equal_upper_bound - (const node_ptr & h, const node_ptr & new_node, NodePtrCompare comp - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - insert_equal_upper_bound_check(h, new_node, comp, commit_data, pdepth); - insert_commit(h, new_node, commit_data); - return new_node; - } - - //! Requires: "h" must be the header node of a tree. - //! NodePtrCompare is a function object that induces a strict weak - //! ordering compatible with the strict weak ordering used to create the - //! the tree. NodePtrCompare compares two node_ptrs. - //! - //! Effects: Inserts new_node into the tree before the lower bound - //! according to "comp". - //! - //! Complexity: Average complexity for insert element is at - //! most logarithmic. - //! - //! Throws: If "comp" throws. - template - static node_ptr insert_equal_lower_bound - (const node_ptr & h, const node_ptr & new_node, NodePtrCompare comp - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - insert_equal_lower_bound_check(h, new_node, comp, commit_data, pdepth); - insert_commit(h, new_node, commit_data); - return new_node; - } - - //! Requires: "header" must be the header node of a tree. - //! "pos" must be a valid iterator or header (end) node. - //! "pos" must be an iterator pointing to the successor to "new_node" - //! once inserted according to the order of already inserted nodes. This function does not - //! check "pos" and this precondition must be guaranteed by the caller. - //! - //! Effects: Inserts new_node into the tree before "pos". - //! - //! Complexity: Constant-time. - //! - //! Throws: Nothing. - //! - //! Note: If "pos" is not the successor of the newly inserted "new_node" - //! tree invariants might be broken. - static node_ptr insert_before - (const node_ptr & header, const node_ptr & pos, const node_ptr & new_node - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - insert_before_check(header, pos, commit_data, pdepth); - insert_commit(header, new_node, commit_data); - return new_node; - } - - //! Requires: "header" must be the header node of a tree. - //! "new_node" must be, according to the used ordering no less than the - //! greatest inserted key. - //! - //! Effects: Inserts new_node into the tree before "pos". - //! - //! Complexity: Constant-time. - //! - //! Throws: Nothing. - //! - //! Note: If "new_node" is less than the greatest inserted key - //! tree invariants are broken. This function is slightly faster than - //! using "insert_before". - static void push_back - (const node_ptr & header, const node_ptr & new_node - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - push_back_check(header, commit_data, pdepth); - insert_commit(header, new_node, commit_data); - } - - //! Requires: "header" must be the header node of a tree. - //! "new_node" must be, according to the used ordering, no greater than the - //! lowest inserted key. - //! - //! Effects: Inserts new_node into the tree before "pos". - //! - //! Complexity: Constant-time. - //! - //! Throws: Nothing. - //! - //! Note: If "new_node" is greater than the lowest inserted key - //! tree invariants are broken. This function is slightly faster than - //! using "insert_before". - static void push_front - (const node_ptr & header, const node_ptr & new_node - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - insert_commit_data commit_data; - push_front_check(header, commit_data, pdepth); - insert_commit(header, new_node, commit_data); - } - - //! Requires: 'node' can't be a header node. - //! - //! Effects: Calculates the depth of a node: the depth of a - //! node is the length (number of edges) of the path from the root - //! to that node. (The root node is at depth 0.) - //! - //! Complexity: Logarithmic to the number of nodes in the tree. - //! - //! Throws: Nothing. - static std::size_t depth(const_node_ptr node) - { - std::size_t depth = 0; - node_ptr p_parent; - while(node != NodeTraits::get_parent(p_parent = NodeTraits::get_parent(node))){ - ++depth; - node = p_parent; - } - return depth; - } - - //! Requires: "cloner" must be a function - //! object taking a node_ptr and returning a new cloned node of it. "disposer" must - //! take a node_ptr and shouldn't throw. - //! - //! Effects: First empties target tree calling - //! void disposer::operator()(const node_ptr &) for every node of the tree - //! except the header. - //! - //! Then, duplicates the entire tree pointed by "source_header" cloning each - //! source node with node_ptr Cloner::operator()(const node_ptr &) to obtain - //! the nodes of the target tree. If "cloner" throws, the cloned target nodes - //! are disposed using void disposer(const node_ptr &). - //! - //! Complexity: Linear to the number of element of the source tree plus the. - //! number of elements of tree target tree when calling this function. - //! - //! Throws: If cloner functor throws. If this happens target nodes are disposed. - template - static void clone - (const const_node_ptr & source_header, const node_ptr & target_header, Cloner cloner, Disposer disposer) - { - if(!unique(target_header)){ - clear_and_dispose(target_header, disposer); - } - - node_ptr leftmost, rightmost; - node_ptr new_root = clone_subtree - (source_header, target_header, cloner, disposer, leftmost, rightmost); - - //Now update header node - NodeTraits::set_parent(target_header, new_root); - NodeTraits::set_left (target_header, leftmost); - NodeTraits::set_right (target_header, rightmost); - } - - //! Requires: header must be the header of a tree, z a node - //! of that tree and z != header. - //! - //! Effects: Erases node "z" from the tree with header "header". - //! - //! Complexity: Amortized constant time. - //! - //! Throws: Nothing. - static void erase(const node_ptr & header, const node_ptr & z) - { - data_for_rebalance ignored; - erase_impl(header, z, ignored); - } - - //! Requires: node is a tree node but not the header. - //! - //! Effects: Unlinks the node and rebalances the tree. - //! - //! Complexity: Average complexity is constant time. - //! - //! Throws: Nothing. - static void unlink(const node_ptr & node) - { - node_ptr x = NodeTraits::get_parent(node); - if(x){ - while(!is_header(x)) - x = NodeTraits::get_parent(x); - erase(x, node); - } - } - - //! Requires: header must be the header of a tree. - //! - //! Effects: Rebalances the tree. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear. - static void rebalance(const node_ptr & header) - { - node_ptr root = NodeTraits::get_parent(header); - if(root){ - rebalance_subtree(root); - } - } - - //! Requires: old_root is a node of a tree. It shall not be null. - //! - //! Effects: Rebalances the subtree rooted at old_root. - //! - //! Returns: The new root of the subtree. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear. - static node_ptr rebalance_subtree(const node_ptr & old_root) - { - //Taken from: - //"Tree rebalancing in optimal time and space" - //Quentin F. Stout and Bette L. Warren - - //To avoid irregularities in the algorithm (old_root can be a - //left or right child or even the root of the tree) just put the - //root as the right child of its parent. Before doing this backup - //information to restore the original relationship after - //the algorithm is applied. - node_ptr super_root = NodeTraits::get_parent(old_root); - BOOST_INTRUSIVE_INVARIANT_ASSERT(super_root); - - //Get root info - node_ptr super_root_right_backup = NodeTraits::get_right(super_root); - bool super_root_is_header = NodeTraits::get_parent(super_root) == old_root; - bool old_root_is_right = is_right_child(old_root); - NodeTraits::set_right(super_root, old_root); - - std::size_t size; - subtree_to_vine(super_root, size); - vine_to_subtree(super_root, size); - node_ptr new_root = NodeTraits::get_right(super_root); - - //Recover root - if(super_root_is_header){ - NodeTraits::set_right(super_root, super_root_right_backup); - NodeTraits::set_parent(super_root, new_root); - } - else if(old_root_is_right){ - NodeTraits::set_right(super_root, new_root); - } - else{ - NodeTraits::set_right(super_root, super_root_right_backup); - NodeTraits::set_left(super_root, new_root); - } - return new_root; - } - - protected: - //! Requires: node is a node of the tree but it's not the header. - //! - //! Effects: Returns the number of nodes of the subtree. - //! - //! Complexity: Linear time. - //! - //! Throws: Nothing. - static std::size_t subtree_size(const const_node_ptr & subtree) - { - std::size_t count = 0; - if (subtree){ - node_ptr n = detail::uncast(subtree); - node_ptr m = NodeTraits::get_left(n); - while(m){ - n = m; - m = NodeTraits::get_left(n); - } - - while(1){ - ++count; - node_ptr n_right(NodeTraits::get_right(n)); - if(n_right){ - n = n_right; - m = NodeTraits::get_left(n); - while(m){ - n = m; - m = NodeTraits::get_left(n); - } - } - else { - do{ - if (n == subtree){ - return count; - } - m = n; - n = NodeTraits::get_parent(n); - }while(NodeTraits::get_left(n) != m); - } - } - } - return count; - } - - //! Requires: p is a node of a tree. - //! - //! Effects: Returns true if p is a left child. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - static bool is_left_child(const node_ptr & p) - { return NodeTraits::get_left(NodeTraits::get_parent(p)) == p; } - - //! Requires: p is a node of a tree. - //! - //! Effects: Returns true if p is a right child. - //! - //! Complexity: Constant. - //! - //! Throws: Nothing. - static bool is_right_child(const node_ptr & p) - { return NodeTraits::get_right(NodeTraits::get_parent(p)) == p; } - - template - static void erase(const node_ptr & header, const node_ptr & z, F z_and_successor_fixup, data_for_rebalance &info) - { - erase_impl(header, z, info); - if(info.y != z){ - z_and_successor_fixup(z, info.y); - } - } - - //Fix header and own's parent data when replacing x with own, providing own's old data with parent - static void replace_own_impl(const node_ptr & own, const node_ptr & x, const node_ptr & header, const node_ptr & own_parent, bool own_was_left) - { - if(NodeTraits::get_parent(header) == own) - NodeTraits::set_parent(header, x); - else if(own_was_left) - NodeTraits::set_left(own_parent, x); - else - NodeTraits::set_right(own_parent, x); - } - - //Fix header and own's parent data when replacing x with own, supposing own - //links with its parent are still ok - static void replace_own(const node_ptr & own, const node_ptr & x, const node_ptr & header) - { - node_ptr own_parent(NodeTraits::get_parent(own)); - bool own_is_left(NodeTraits::get_left(own_parent) == own); - replace_own_impl(own, x, header, own_parent, own_is_left); - } - - // rotate parent p to left (no header and p's parent fixup) - static node_ptr rotate_left(const node_ptr & p) - { - node_ptr x(NodeTraits::get_right(p)); - node_ptr x_left(NodeTraits::get_left(x)); - NodeTraits::set_right(p, x_left); - if(x_left){ - NodeTraits::set_parent(x_left, p); - } - NodeTraits::set_left(x, p); - NodeTraits::set_parent(p, x); - return x; - } - - // rotate parent p to left (with header and p's parent fixup) - static void rotate_left(const node_ptr & p, const node_ptr & header) - { - bool p_was_left(is_left_child(p)); - node_ptr p_old_parent(NodeTraits::get_parent(p)); - node_ptr x(rotate_left(p)); - NodeTraits::set_parent(x, p_old_parent); - replace_own_impl(p, x, header, p_old_parent, p_was_left); - } - - // rotate parent p to right (no header and p's parent fixup) - static node_ptr rotate_right(const node_ptr & p) - { - node_ptr x(NodeTraits::get_left(p)); - node_ptr x_right(NodeTraits::get_right(x)); - NodeTraits::set_left(p, x_right); - if(x_right){ - NodeTraits::set_parent(x_right, p); - } - NodeTraits::set_right(x, p); - NodeTraits::set_parent(p, x); - return x; - } - - // rotate parent p to right (with header and p's parent fixup) - static void rotate_right(const node_ptr & p, const node_ptr & header) - { - bool p_was_left(is_left_child(p)); - node_ptr p_old_parent(NodeTraits::get_parent(p)); - node_ptr x(rotate_right(p)); - NodeTraits::set_parent(x, p_old_parent); - replace_own_impl(p, x, header, p_old_parent, p_was_left); - } - - static void insert_before_check - (const node_ptr &header, const node_ptr & pos - , insert_commit_data &commit_data - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - node_ptr prev(pos); - if(pos != NodeTraits::get_left(header)) - prev = prev_node(pos); - bool link_left = unique(header) || !NodeTraits::get_left(pos); - commit_data.link_left = link_left; - commit_data.node = link_left ? pos : prev; - if(pdepth){ - *pdepth = commit_data.node == header ? 0 : depth(commit_data.node) + 1; - } - } - - static void push_back_check - (const node_ptr & header, insert_commit_data &commit_data - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - node_ptr prev(NodeTraits::get_right(header)); - if(pdepth){ - *pdepth = prev == header ? 0 : depth(prev) + 1; - } - commit_data.link_left = false; - commit_data.node = prev; - } - - static void push_front_check - (const node_ptr & header, insert_commit_data &commit_data - #ifndef BOOST_INTRUSIVE_DOXYGEN_INVOKED - , std::size_t *pdepth = 0 - #endif - ) - { - node_ptr pos(NodeTraits::get_left(header)); - if(pdepth){ - *pdepth = pos == header ? 0 : depth(pos) + 1; - } - commit_data.link_left = true; - commit_data.node = pos; - } - - template - static void insert_equal_check - (const node_ptr &header, const node_ptr & hint, const node_ptr & new_node, NodePtrCompare comp - , insert_commit_data &commit_data - /// @cond - , std::size_t *pdepth = 0 - /// @endcond - ) - { - if(hint == header || !comp(hint, new_node)){ - node_ptr prev(hint); - if(hint == NodeTraits::get_left(header) || - !comp(new_node, (prev = prev_node(hint)))){ - bool link_left = unique(header) || !NodeTraits::get_left(hint); - commit_data.link_left = link_left; - commit_data.node = link_left ? hint : prev; - if(pdepth){ - *pdepth = commit_data.node == header ? 0 : depth(commit_data.node) + 1; - } - } - else{ - insert_equal_upper_bound_check(header, new_node, comp, commit_data, pdepth); - } - } - else{ - insert_equal_lower_bound_check(header, new_node, comp, commit_data, pdepth); - } - } - - template - static void insert_equal_upper_bound_check - (const node_ptr & h, const node_ptr & new_node, NodePtrCompare comp, insert_commit_data & commit_data, std::size_t *pdepth = 0) - { insert_equal_check_impl(true, h, new_node, comp, commit_data, pdepth); } - - template - static void insert_equal_lower_bound_check - (const node_ptr & h, const node_ptr & new_node, NodePtrCompare comp, insert_commit_data & commit_data, std::size_t *pdepth = 0) - { insert_equal_check_impl(false, h, new_node, comp, commit_data, pdepth); } - - static void insert_commit - (const node_ptr & header, const node_ptr & new_node, const insert_commit_data &commit_data) - { - //Check if commit_data has not been initialized by a insert_unique_check call. - BOOST_INTRUSIVE_INVARIANT_ASSERT(commit_data.node != node_ptr()); - node_ptr parent_node(commit_data.node); - if(parent_node == header){ - NodeTraits::set_parent(header, new_node); - NodeTraits::set_right(header, new_node); - NodeTraits::set_left(header, new_node); - } - else if(commit_data.link_left){ - NodeTraits::set_left(parent_node, new_node); - if(parent_node == NodeTraits::get_left(header)) - NodeTraits::set_left(header, new_node); - } - else{ - NodeTraits::set_right(parent_node, new_node); - if(parent_node == NodeTraits::get_right(header)) - NodeTraits::set_right(header, new_node); - } - NodeTraits::set_parent(new_node, parent_node); - NodeTraits::set_right(new_node, node_ptr()); - NodeTraits::set_left(new_node, node_ptr()); - } - - private: - static void subtree_to_vine(node_ptr vine_tail, std::size_t &size) - { - //Inspired by LibAVL: - //It uses a clever optimization for trees with parent pointers. - //No parent pointer is updated when transforming a tree to a vine as - //most of them will be overriten during compression rotations. - //A final pass must be made after the rebalancing to updated those - //pointers not updated by tree_to_vine + compression calls - std::size_t len = 0; - node_ptr remainder = NodeTraits::get_right(vine_tail); - while(remainder){ - node_ptr tempptr = NodeTraits::get_left(remainder); - if(!tempptr){ //move vine-tail down one - vine_tail = remainder; - remainder = NodeTraits::get_right(remainder); - ++len; - } - else{ //rotate - NodeTraits::set_left(remainder, NodeTraits::get_right(tempptr)); - NodeTraits::set_right(tempptr, remainder); - remainder = tempptr; - NodeTraits::set_right(vine_tail, tempptr); - } - } - size = len; - } - - static void compress_subtree(node_ptr scanner, std::size_t count) - { - while(count--){ //compress "count" spine nodes in the tree with pseudo-root scanner - node_ptr child = NodeTraits::get_right(scanner); - node_ptr child_right = NodeTraits::get_right(child); - NodeTraits::set_right(scanner, child_right); - //Avoid setting the parent of child_right - scanner = child_right; - node_ptr scanner_left = NodeTraits::get_left(scanner); - NodeTraits::set_right(child, scanner_left); - if(scanner_left) - NodeTraits::set_parent(scanner_left, child); - NodeTraits::set_left(scanner, child); - NodeTraits::set_parent(child, scanner); - } - } - - static void vine_to_subtree(const node_ptr & super_root, std::size_t count) - { - std::size_t leaf_nodes = count + 1 - ((std::size_t) 1 << detail::floor_log2(count + 1)); - compress_subtree(super_root, leaf_nodes); //create deepest leaves - std::size_t vine_nodes = count - leaf_nodes; - while(vine_nodes > 1){ - vine_nodes /= 2; - compress_subtree(super_root, vine_nodes); - } - - //Update parents of nodes still in the in the original vine line - //as those have not been updated by subtree_to_vine or compress_subtree - for ( node_ptr q = super_root, p = NodeTraits::get_right(super_root) - ; p - ; q = p, p = NodeTraits::get_right(p)){ - NodeTraits::set_parent(p, q); - } - } - - //! Requires: "n" must be a node inserted in a tree. - //! - //! Effects: Returns a pointer to the header node of the tree. - //! - //! Complexity: Logarithmic. - //! - //! Throws: Nothing. - static node_ptr get_root(const node_ptr & node) - { - BOOST_INTRUSIVE_INVARIANT_ASSERT((!inited(node))); - node_ptr x = NodeTraits::get_parent(node); - if(x){ - while(!is_header(x)){ - x = NodeTraits::get_parent(x); - } - return x; - } - else{ - return node; - } - } - - template - static node_ptr clone_subtree - (const const_node_ptr &source_parent, const node_ptr &target_parent - , Cloner cloner, Disposer disposer - , node_ptr &leftmost_out, node_ptr &rightmost_out - ) - { - node_ptr target_sub_root = target_parent; - node_ptr source_root = NodeTraits::get_parent(source_parent); - if(!source_root){ - leftmost_out = rightmost_out = source_root; - } - else{ - //We'll calculate leftmost and rightmost nodes while iterating - node_ptr current = source_root; - node_ptr insertion_point = target_sub_root = cloner(current); - - //We'll calculate leftmost and rightmost nodes while iterating - node_ptr leftmost = target_sub_root; - node_ptr rightmost = target_sub_root; - - //First set the subroot - NodeTraits::set_left(target_sub_root, node_ptr()); - NodeTraits::set_right(target_sub_root, node_ptr()); - NodeTraits::set_parent(target_sub_root, target_parent); - - dispose_subtree_disposer rollback(disposer, target_sub_root); - while(true) { - //First clone left nodes - if( NodeTraits::get_left(current) && - !NodeTraits::get_left(insertion_point)) { - current = NodeTraits::get_left(current); - node_ptr temp = insertion_point; - //Clone and mark as leaf - insertion_point = cloner(current); - NodeTraits::set_left (insertion_point, node_ptr()); - NodeTraits::set_right (insertion_point, node_ptr()); - //Insert left - NodeTraits::set_parent(insertion_point, temp); - NodeTraits::set_left (temp, insertion_point); - //Update leftmost - if(rightmost == target_sub_root) - leftmost = insertion_point; - } - //Then clone right nodes - else if( NodeTraits::get_right(current) && - !NodeTraits::get_right(insertion_point)){ - current = NodeTraits::get_right(current); - node_ptr temp = insertion_point; - //Clone and mark as leaf - insertion_point = cloner(current); - NodeTraits::set_left (insertion_point, node_ptr()); - NodeTraits::set_right (insertion_point, node_ptr()); - //Insert right - NodeTraits::set_parent(insertion_point, temp); - NodeTraits::set_right (temp, insertion_point); - //Update rightmost - rightmost = insertion_point; - } - //If not, go up - else if(current == source_root){ - break; - } - else{ - //Branch completed, go up searching more nodes to clone - current = NodeTraits::get_parent(current); - insertion_point = NodeTraits::get_parent(insertion_point); - } - } - rollback.release(); - leftmost_out = leftmost; - rightmost_out = rightmost; - } - return target_sub_root; - } - - template - static void dispose_subtree(node_ptr x, Disposer disposer) - { - while (x){ - node_ptr save(NodeTraits::get_left(x)); - if (save) { - // Right rotation - NodeTraits::set_left(x, NodeTraits::get_right(save)); - NodeTraits::set_right(save, x); - } - else { - save = NodeTraits::get_right(x); - init(x); - disposer(x); - } - x = save; - } - } - - template - static node_ptr lower_bound_loop - (node_ptr x, node_ptr y, const KeyType &key, KeyNodePtrCompare comp) - { - while(x){ - if(comp(x, key)){ - x = NodeTraits::get_right(x); - } - else{ - y = x; - x = NodeTraits::get_left(x); - } - } - return y; - } - - template - static node_ptr upper_bound_loop - (node_ptr x, node_ptr y, const KeyType &key, KeyNodePtrCompare comp) - { - while(x){ - if(comp(key, x)){ - y = x; - x = NodeTraits::get_left(x); - } - else{ - x = NodeTraits::get_right(x); - } - } - return y; - } - - - template - static void insert_equal_check_impl - (bool upper, const node_ptr & h, const node_ptr & new_node, NodePtrCompare comp, insert_commit_data & commit_data, std::size_t *pdepth = 0) - { - std::size_t depth = 0; - node_ptr y(h); - node_ptr x(NodeTraits::get_parent(y)); - bool link_left; - - if(upper){ - while(x){ - ++depth; - y = x; - x = comp(new_node, x) ? - NodeTraits::get_left(x) : NodeTraits::get_right(x); - } - link_left = (y == h) || comp(new_node, y); - } - else{ - while(x){ - ++depth; - y = x; - x = !comp(x, new_node) ? - NodeTraits::get_left(x) : NodeTraits::get_right(x); - } - link_left = (y == h) || !comp(y, new_node); - } - - commit_data.link_left = link_left; - commit_data.node = y; - if(pdepth) *pdepth = depth; - } - - static void erase_impl(const node_ptr & header, const node_ptr & z, data_for_rebalance &info) - { - node_ptr y(z); - node_ptr x; - node_ptr x_parent = node_ptr(); - node_ptr z_left(NodeTraits::get_left(z)); - node_ptr z_right(NodeTraits::get_right(z)); - if(!z_left){ - x = z_right; // x might be null. - } - else if(!z_right){ // z has exactly one non-null child. y == z. - x = z_left; // x is not null. - } - else{ - // find z's successor - y = bstree_algorithms::minimum (z_right); - x = NodeTraits::get_right(y); // x might be null. - } - - if(y != z){ - // relink y in place of z. y is z's successor - NodeTraits::set_parent(NodeTraits::get_left(z), y); - NodeTraits::set_left(y, NodeTraits::get_left(z)); - if(y != NodeTraits::get_right(z)){ - x_parent = NodeTraits::get_parent(y); - if(x) - NodeTraits::set_parent(x, x_parent); - NodeTraits::set_left(x_parent, x); // y must be a child of left_ - NodeTraits::set_right(y, NodeTraits::get_right(z)); - NodeTraits::set_parent(NodeTraits::get_right(z), y); - } - else - x_parent = y; - bstree_algorithms::replace_own (z, y, header); - NodeTraits::set_parent(y, NodeTraits::get_parent(z)); - } - else { // y == z --> z has only one child, or void - x_parent = NodeTraits::get_parent(z); - if(x) - NodeTraits::set_parent(x, x_parent); - bstree_algorithms::replace_own (z, x, header); - if(NodeTraits::get_left(header) == z){ - NodeTraits::set_left(header, !NodeTraits::get_right(z) ? // z->get_left() must be null also - NodeTraits::get_parent(z) : // makes leftmost == header if z == root - bstree_algorithms::minimum (x)); - } - if(NodeTraits::get_right(header) == z){ - NodeTraits::set_right(header, !NodeTraits::get_left(z) ? // z->get_right() must be null also - NodeTraits::get_parent(z) : // makes rightmost == header if z == root - bstree_algorithms::maximum(x)); - } - } - - info.x = x; - info.x_parent = x_parent; - info.y = y; - } -}; - -/// @cond - -template -struct get_algo -{ - typedef bstree_algorithms type; -}; - -/// @endcond - -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_BSTREE_ALGORITHMS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/circular_slist_algorithms.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/circular_slist_algorithms.hpp deleted file mode 100644 index fb5f75ab..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/circular_slist_algorithms.hpp +++ /dev/null @@ -1,415 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Olaf Krzikalla 2004-2006. -// (C) Copyright Ion Gaztanaga 2006-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_CIRCULAR_SLIST_ALGORITHMS_HPP -#define BOOST_INTRUSIVE_CIRCULAR_SLIST_ALGORITHMS_HPP - -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace intrusive { - -//! circular_slist_algorithms provides basic algorithms to manipulate nodes -//! forming a circular singly linked list. An empty circular list is formed by a node -//! whose pointer to the next node points to itself. -//! -//! circular_slist_algorithms is configured with a NodeTraits class, which encapsulates the -//! information about the node to be manipulated. NodeTraits must support the -//! following interface: -//! -//! Typedefs: -//! -//! node: The type of the node that forms the circular list -//! -//! node_ptr: A pointer to a node -//! -//! const_node_ptr: A pointer to a const node -//! -//! Static functions: -//! -//! static node_ptr get_next(const_node_ptr n); -//! -//! static void set_next(node_ptr n, node_ptr next); -template -class circular_slist_algorithms - /// @cond - : public detail::common_slist_algorithms - /// @endcond -{ - /// @cond - typedef detail::common_slist_algorithms base_t; - /// @endcond - public: - typedef typename NodeTraits::node node; - typedef typename NodeTraits::node_ptr node_ptr; - typedef typename NodeTraits::const_node_ptr const_node_ptr; - typedef NodeTraits node_traits; - - #if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Effects: Constructs an non-used list element, putting the next - //! pointer to null: - //! NodeTraits::get_next(this_node) == node_ptr() - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void init(node_ptr this_node); - - //! Requires: this_node must be in a circular list or be an empty circular list. - //! - //! Effects: Returns true is "this_node" is the only node of a circular list: - //! or it's a not inserted node: - //! return node_ptr() == NodeTraits::get_next(this_node) || NodeTraits::get_next(this_node) == this_node - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static bool unique(const_node_ptr this_node); - - //! Effects: Returns true is "this_node" has the same state as - //! if it was inited using "init(node_ptr)" - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static bool inited(const_node_ptr this_node); - - //! Requires: prev_node must be in a circular list or be an empty circular list. - //! - //! Effects: Unlinks the next node of prev_node from the circular list. - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void unlink_after(node_ptr prev_node); - - //! Requires: prev_node and last_node must be in a circular list - //! or be an empty circular list. - //! - //! Effects: Unlinks the range (prev_node, last_node) from the circular list. - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void unlink_after(node_ptr prev_node, node_ptr last_node); - - //! Requires: prev_node must be a node of a circular list. - //! - //! Effects: Links this_node after prev_node in the circular list. - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void link_after(node_ptr prev_node, node_ptr this_node); - - //! Requires: b and e must be nodes of the same circular list or an empty range. - //! and p must be a node of a different circular list. - //! - //! Effects: Removes the nodes from (b, e] range from their circular list and inserts - //! them after p in p's circular list. - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void transfer_after(node_ptr p, node_ptr b, node_ptr e); - - #endif //#if defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED) - - //! Effects: Constructs an empty list, making this_node the only - //! node of the circular list: - //! NodeTraits::get_next(this_node) == this_node. - //! - //! Complexity: Constant - //! - //! Throws: Nothing. - static void init_header(const node_ptr &this_node) - { NodeTraits::set_next(this_node, this_node); } - - //! Requires: this_node and prev_init_node must be in the same circular list. - //! - //! Effects: Returns the previous node of this_node in the circular list starting. - //! the search from prev_init_node. The first node checked for equality - //! is NodeTraits::get_next(prev_init_node). - //! - //! Complexity: Linear to the number of elements between prev_init_node and this_node. - //! - //! Throws: Nothing. - static node_ptr get_previous_node(const node_ptr &prev_init_node, const node_ptr &this_node) - { return base_t::get_previous_node(prev_init_node, this_node); } - - //! Requires: this_node must be in a circular list or be an empty circular list. - //! - //! Effects: Returns the previous node of this_node in the circular list. - //! - //! Complexity: Linear to the number of elements in the circular list. - //! - //! Throws: Nothing. - static node_ptr get_previous_node(const node_ptr & this_node) - { return base_t::get_previous_node(this_node, this_node); } - - //! Requires: this_node must be in a circular list or be an empty circular list. - //! - //! Effects: Returns the previous node of the previous node of this_node in the circular list. - //! - //! Complexity: Linear to the number of elements in the circular list. - //! - //! Throws: Nothing. - static node_ptr get_previous_previous_node(const node_ptr & this_node) - { return get_previous_previous_node(this_node, this_node); } - - //! Requires: this_node and p must be in the same circular list. - //! - //! Effects: Returns the previous node of the previous node of this_node in the - //! circular list starting. the search from p. The first node checked - //! for equality is NodeTraits::get_next((NodeTraits::get_next(p)). - //! - //! Complexity: Linear to the number of elements in the circular list. - //! - //! Throws: Nothing. - static node_ptr get_previous_previous_node(node_ptr p, const node_ptr & this_node) - { - node_ptr p_next = NodeTraits::get_next(p); - node_ptr p_next_next = NodeTraits::get_next(p_next); - while (this_node != p_next_next){ - p = p_next; - p_next = p_next_next; - p_next_next = NodeTraits::get_next(p_next); - } - return p; - } - - //! Requires: this_node must be in a circular list or be an empty circular list. - //! - //! Effects: Returns the number of nodes in a circular list. If the circular list - //! is empty, returns 1. - //! - //! Complexity: Linear - //! - //! Throws: Nothing. - static std::size_t count(const const_node_ptr & this_node) - { - std::size_t result = 0; - const_node_ptr p = this_node; - do{ - p = NodeTraits::get_next(p); - ++result; - } while (p != this_node); - return result; - } - - //! Requires: this_node must be in a circular list, be an empty circular list or be inited. - //! - //! Effects: Unlinks the node from the circular list. - //! - //! Complexity: Linear to the number of elements in the circular list - //! - //! Throws: Nothing. - static void unlink(const node_ptr & this_node) - { - if(NodeTraits::get_next(this_node)) - base_t::unlink_after(get_previous_node(this_node)); - } - - //! Requires: nxt_node must be a node of a circular list. - //! - //! Effects: Links this_node before nxt_node in the circular list. - //! - //! Complexity: Linear to the number of elements in the circular list. - //! - //! Throws: Nothing. - static void link_before (const node_ptr & nxt_node, const node_ptr & this_node) - { base_t::link_after(get_previous_node(nxt_node), this_node); } - - //! Requires: this_node and other_node must be nodes inserted - //! in circular lists or be empty circular lists. - //! - //! Effects: Swaps the position of the nodes: this_node is inserted in - //! other_nodes position in the second circular list and the other_node is inserted - //! in this_node's position in the first circular list. - //! - //! Complexity: Linear to number of elements of both lists - //! - //! Throws: Nothing. - static void swap_nodes(const node_ptr & this_node, const node_ptr & other_node) - { - if (other_node == this_node) - return; - bool this_inited = base_t::inited(this_node); - bool other_inited = base_t::inited(other_node); - if(this_inited){ - base_t::init_header(this_node); - } - if(other_inited){ - base_t::init_header(other_node); - } - - bool empty1 = base_t::unique(this_node); - bool empty2 = base_t::unique(other_node); - node_ptr prev_this (get_previous_node(this_node)); - node_ptr prev_other(get_previous_node(other_node)); - - node_ptr this_next (NodeTraits::get_next(this_node)); - node_ptr other_next(NodeTraits::get_next(other_node)); - NodeTraits::set_next(this_node, other_next); - NodeTraits::set_next(other_node, this_next); - NodeTraits::set_next(empty1 ? other_node : prev_this, other_node); - NodeTraits::set_next(empty2 ? this_node : prev_other, this_node); - - if(this_inited){ - base_t::init(other_node); - } - if(other_inited){ - base_t::init(this_node); - } - } - - //! Effects: Reverses the order of elements in the list. - //! - //! Throws: Nothing. - //! - //! Complexity: This function is linear to the contained elements. - static void reverse(const node_ptr & p) - { - node_ptr i = NodeTraits::get_next(p), e(p); - for (;;) { - node_ptr nxt(NodeTraits::get_next(i)); - if (nxt == e) - break; - base_t::transfer_after(e, i, nxt); - } - } - - //! Effects: Moves the node p n positions towards the end of the list. - //! - //! Returns: The previous node of p after the function if there has been any movement, - //! Null if n leads to no movement. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear to the number of elements plus the number moved positions. - static node_ptr move_backwards(const node_ptr & p, std::size_t n) - { - //Null shift, nothing to do - if(!n) return node_ptr(); - node_ptr first = NodeTraits::get_next(p); - - //count() == 1 or 2, nothing to do - if(NodeTraits::get_next(first) == p) - return node_ptr(); - - bool end_found = false; - node_ptr new_last = node_ptr(); - - //Now find the new last node according to the shift count. - //If we find p before finding the new last node - //unlink p, shortcut the search now that we know the size of the list - //and continue. - for(std::size_t i = 1; i <= n; ++i){ - new_last = first; - first = NodeTraits::get_next(first); - if(first == p){ - //Shortcut the shift with the modulo of the size of the list - n %= i; - if(!n) - return node_ptr(); - i = 0; - //Unlink p and continue the new first node search - first = NodeTraits::get_next(p); - base_t::unlink_after(new_last); - end_found = true; - } - } - - //If the p has not been found in the previous loop, find it - //starting in the new first node and unlink it - if(!end_found){ - base_t::unlink_after(base_t::get_previous_node(first, p)); - } - - //Now link p after the new last node - base_t::link_after(new_last, p); - return new_last; - } - - //! Effects: Moves the node p n positions towards the beginning of the list. - //! - //! Returns: The previous node of p after the function if there has been any movement, - //! Null if n leads equals to no movement. - //! - //! Throws: Nothing. - //! - //! Complexity: Linear to the number of elements plus the number moved positions. - static node_ptr move_forward(const node_ptr & p, std::size_t n) - { - //Null shift, nothing to do - if(!n) return node_ptr(); - node_ptr first = node_traits::get_next(p); - - //count() == 1 or 2, nothing to do - if(node_traits::get_next(first) == p) return node_ptr(); - - //Iterate until p is found to know where the current last node is. - //If the shift count is less than the size of the list, we can also obtain - //the position of the new last node after the shift. - node_ptr old_last(first), next_to_it, new_last(p); - std::size_t distance = 1; - while(p != (next_to_it = node_traits::get_next(old_last))){ - if(++distance > n) - new_last = node_traits::get_next(new_last); - old_last = next_to_it; - } - //If the shift was bigger or equal than the size, obtain the equivalent - //forward shifts and find the new last node. - if(distance <= n){ - //Now find the equivalent forward shifts. - //Shortcut the shift with the modulo of the size of the list - std::size_t new_before_last_pos = (distance - (n % distance))% distance; - //If the shift is a multiple of the size there is nothing to do - if(!new_before_last_pos) return node_ptr(); - - for( new_last = p - ; new_before_last_pos-- - ; new_last = node_traits::get_next(new_last)){ - //empty - } - } - - //Now unlink p and link it after the new last node - base_t::unlink_after(old_last); - base_t::link_after(new_last, p); - return new_last; - } -}; - -/// @cond - -template -struct get_algo -{ - typedef circular_slist_algorithms type; -}; - -/// @endcond - -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_CIRCULAR_SLIST_ALGORITHMS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/assert.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/assert.hpp deleted file mode 100644 index 3dacbcc3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/assert.hpp +++ /dev/null @@ -1,41 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2006-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_ASSERT_HPP -#define BOOST_INTRUSIVE_DETAIL_ASSERT_HPP - -#if defined(_MSC_VER)&&(_MSC_VER>=1200) -#pragma once -#endif - -#if !defined(BOOST_INTRUSIVE_INVARIANT_ASSERT) - #include - #define BOOST_INTRUSIVE_INVARIANT_ASSERT BOOST_ASSERT -#elif defined(BOOST_INTRUSIVE_INVARIANT_ASSERT_INCLUDE) - #include BOOST_INTRUSIVE_INVARIANT_ASSERT_INCLUDE -#endif - -#if !defined(BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT) - #include - #define BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT BOOST_ASSERT -#elif defined(BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT_INCLUDE) - #include BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT_INCLUDE -#endif - -#if !defined(BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT) - #include - #define BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT BOOST_ASSERT -#elif defined(BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT_INCLUDE) - #include BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT_INCLUDE -#endif - -#endif //BOOST_INTRUSIVE_DETAIL_ASSERT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/clear_on_destructor_base.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/clear_on_destructor_base.hpp deleted file mode 100644 index 164fe409..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/clear_on_destructor_base.hpp +++ /dev/null @@ -1,40 +0,0 @@ -//////} // /////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2008-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_CLEAR_ON_DESTRUCTOR_HPP -#define BOOST_INTRUSIVE_DETAIL_CLEAR_ON_DESTRUCTOR_HPP - -#include - -namespace boost { -namespace intrusive { -namespace detail { - -template -class clear_on_destructor_base -{ - protected: - ~clear_on_destructor_base() - { - static_cast(this)->clear(); - } -}; - -template -class clear_on_destructor_base -{}; - -} // namespace detail { -} // namespace intrusive { -} // namespace boost { - -#include - -#endif //#ifndef BOOST_INTRUSIVE_DETAIL_CLEAR_ON_DESTRUCTOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/common_slist_algorithms.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/common_slist_algorithms.hpp deleted file mode 100644 index a5433bb1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/common_slist_algorithms.hpp +++ /dev/null @@ -1,102 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_COMMON_SLIST_ALGORITHMS_HPP -#define BOOST_INTRUSIVE_COMMON_SLIST_ALGORITHMS_HPP - -#include -#include -#include -#include - -namespace boost { -namespace intrusive { -namespace detail { - -template -class common_slist_algorithms -{ - public: - typedef typename NodeTraits::node node; - typedef typename NodeTraits::node_ptr node_ptr; - typedef typename NodeTraits::const_node_ptr const_node_ptr; - typedef NodeTraits node_traits; - - static node_ptr get_previous_node(node_ptr p, const node_ptr & this_node) - { - for( node_ptr p_next - ; this_node != (p_next = NodeTraits::get_next(p)) - ; p = p_next){ - //Logic error: possible use of linear lists with - //operations only permitted with lists - BOOST_INTRUSIVE_INVARIANT_ASSERT(p); - } - return p; - } - - static void init_header(const node_ptr & this_node) - { NodeTraits::set_next(this_node, this_node); } - - static void init(const node_ptr & this_node) - { NodeTraits::set_next(this_node, node_ptr()); } - - static bool unique(const const_node_ptr & this_node) - { - node_ptr next = NodeTraits::get_next(this_node); - return !next || next == this_node; - } - - static bool inited(const const_node_ptr & this_node) - { return !NodeTraits::get_next(this_node); } - - static void unlink_after(const node_ptr & prev_node) - { - const_node_ptr this_node(NodeTraits::get_next(prev_node)); - NodeTraits::set_next(prev_node, NodeTraits::get_next(this_node)); - } - - static void unlink_after(const node_ptr & prev_node, const node_ptr & last_node) - { NodeTraits::set_next(prev_node, last_node); } - - static void link_after(const node_ptr & prev_node, const node_ptr & this_node) - { - NodeTraits::set_next(this_node, NodeTraits::get_next(prev_node)); - NodeTraits::set_next(prev_node, this_node); - } - - static void incorporate_after(const node_ptr & bp, const node_ptr & b, const node_ptr & be) - { - node_ptr p(NodeTraits::get_next(bp)); - NodeTraits::set_next(bp, b); - NodeTraits::set_next(be, p); - } - - static void transfer_after(const node_ptr & bp, const node_ptr & bb, const node_ptr & be) - { - if (bp != bb && bp != be && bb != be) { - node_ptr next_b = NodeTraits::get_next(bb); - node_ptr next_e = NodeTraits::get_next(be); - node_ptr next_p = NodeTraits::get_next(bp); - NodeTraits::set_next(bb, next_e); - NodeTraits::set_next(be, next_p); - NodeTraits::set_next(bp, next_b); - } - } -}; - -} //namespace detail -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_COMMON_SLIST_ALGORITHMS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_begin.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_begin.hpp deleted file mode 100644 index 109a5908..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_begin.hpp +++ /dev/null @@ -1,52 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2006-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_CONFIG_INCLUDED -#define BOOST_INTRUSIVE_CONFIG_INCLUDED -#include -#endif - -#ifdef BOOST_MSVC - - #pragma warning (push) - // - //'function' : resolved overload was found by argument-dependent lookup - //A function found by argument-dependent lookup (Koenig lookup) was eventually - //chosen by overload resolution. - // - //In Visual C++ .NET and earlier compilers, a different function would have - //been called. To pick the original function, use an explicitly qualified name. - // - - //warning C4275: non dll-interface class 'x' used as base for - //dll-interface class 'Y' - #pragma warning (disable : 4275) - //warning C4251: 'x' : class 'y' needs to have dll-interface to - //be used by clients of class 'z' - #pragma warning (disable : 4251) - #pragma warning (disable : 4675) - #pragma warning (disable : 4996) - #pragma warning (disable : 4503) - #pragma warning (disable : 4284) // odd return type for operator-> - #pragma warning (disable : 4244) // possible loss of data - #pragma warning (disable : 4521) ////Disable "multiple copy constructors specified" - #pragma warning (disable : 4522) - #pragma warning (disable : 4146) - #pragma warning (disable : 4267) //conversion from 'X' to 'Y', possible loss of data - #pragma warning (disable : 4127) //conditional expression is constant - #pragma warning (disable : 4706) //assignment within conditional expression - #pragma warning (disable : 4541) //'typeid' used on polymorphic type 'boost::exception' with /GR- - #pragma warning (disable : 4512) //'typeid' used on polymorphic type 'boost::exception' with /GR- -#endif - -//#define BOOST_INTRUSIVE_USE_ITERATOR_FACADE -//#define BOOST_INTRUSIVE_USE_ITERATOR_ENABLE_IF_CONVERTIBLE diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_end.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_end.hpp deleted file mode 100644 index a081443e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/config_end.hpp +++ /dev/null @@ -1,15 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2006-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#if defined BOOST_MSVC - #pragma warning (pop) -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/ebo_functor_holder.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/ebo_functor_holder.hpp deleted file mode 100644 index 3c2959b9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/ebo_functor_holder.hpp +++ /dev/null @@ -1,95 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Joaquin M Lopez Munoz 2006-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_EBO_HOLDER_HPP -#define BOOST_INTRUSIVE_DETAIL_EBO_HOLDER_HPP - -#include -#include - -namespace boost { -namespace intrusive { -namespace detail { - -template -class ebo_functor_holder_impl -{ - public: - ebo_functor_holder_impl() - {} - ebo_functor_holder_impl(const T& t) - : t_(t) - {} - template - ebo_functor_holder_impl(const Arg1& arg1, const Arg2& arg2) - : t_(arg1, arg2) - {} - - T& get(){return t_;} - const T& get()const{return t_;} - - private: - T t_; -}; - -template -class ebo_functor_holder_impl - : public T -{ - public: - ebo_functor_holder_impl() - {} - ebo_functor_holder_impl(const T& t) - : T(t) - {} - template - ebo_functor_holder_impl(const Arg1& arg1, const Arg2& arg2) - : T(arg1, arg2) - {} - - T& get(){return *this;} - const T& get()const{return *this;} -}; - -template -class ebo_functor_holder - : public ebo_functor_holder_impl::value> -{ - private: - typedef ebo_functor_holder_impl::value> super; - - public: - ebo_functor_holder(){} - ebo_functor_holder(const T& t) - : super(t) - {} - - template - ebo_functor_holder(const Arg1& arg1, const Arg2& arg2) - : super(arg1, arg2) - {} - - ebo_functor_holder& operator=(const ebo_functor_holder& x) - { - this->get()=x.get(); - return *this; - } -}; - - -} //namespace detail { -} //namespace intrusive { -} //namespace boost { - -#include - -#endif //#ifndef BOOST_INTRUSIVE_DETAIL_EBO_HOLDER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/function_detector.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/function_detector.hpp deleted file mode 100644 index f8eccf9e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/function_detector.hpp +++ /dev/null @@ -1,88 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2009-2013. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// -// This code was modified from the code posted by Alexandre Courpron in his -// article "Interface Detection" in The Code Project: -// http://www.codeproject.com/KB/architecture/Detector.aspx -/////////////////////////////////////////////////////////////////////////////// -// Copyright 2007 Alexandre Courpron -// -// Permission to use, copy, modify, redistribute and sell this software, -// provided that this copyright notice appears on all copies of the software. -/////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_FUNCTION_DETECTOR_HPP -#define BOOST_INTRUSIVE_DETAIL_FUNCTION_DETECTOR_HPP - -#include - -namespace boost { -namespace intrusive { -namespace function_detector { - - typedef char NotFoundType; - struct StaticFunctionType { NotFoundType x [2]; }; - struct NonStaticFunctionType { NotFoundType x [3]; }; - - enum - { NotFound = 0, - StaticFunction = sizeof( StaticFunctionType ) - sizeof( NotFoundType ), - NonStaticFunction = sizeof( NonStaticFunctionType ) - sizeof( NotFoundType ) - }; - -} //namespace boost { -} //namespace intrusive { -} //namespace function_detector { - -#define BOOST_INTRUSIVE_CREATE_FUNCTION_DETECTOR(Identifier, InstantiationKey) \ - namespace boost { \ - namespace intrusive { \ - namespace function_detector { \ - template < class T, \ - class NonStaticType, \ - class NonStaticConstType, \ - class StaticType > \ - class DetectMember_##InstantiationKey_##Identifier { \ - template < NonStaticType > \ - struct TestNonStaticNonConst ; \ - \ - template < NonStaticConstType > \ - struct TestNonStaticConst ; \ - \ - template < StaticType > \ - struct TestStatic ; \ - \ - template \ - static NonStaticFunctionType Test( TestNonStaticNonConst<&U::Identifier>*, int ); \ - \ - template \ - static NonStaticFunctionType Test( TestNonStaticConst<&U::Identifier>*, int ); \ - \ - template \ - static StaticFunctionType Test( TestStatic<&U::Identifier>*, int ); \ - \ - template \ - static NotFoundType Test( ... ); \ - public : \ - static const int check = NotFound + (sizeof(Test(0, 0)) - sizeof(NotFoundType));\ - };\ -}}} //namespace boost::intrusive::function_detector { - -#define BOOST_INTRUSIVE_DETECT_FUNCTION(Class, InstantiationKey, ReturnType, Identifier, Params) \ - ::boost::intrusive::function_detector::DetectMember_##InstantiationKey_##Identifier< Class,\ - ReturnType (Class::*)Params,\ - ReturnType (Class::*)Params const,\ - ReturnType (*)Params \ - >::check - -#include - -#endif //@ifndef BOOST_INTRUSIVE_DETAIL_FUNCTION_DETECTOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/generic_hook.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/generic_hook.hpp deleted file mode 100644 index 8848aff9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/generic_hook.hpp +++ /dev/null @@ -1,194 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2007-2013 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_GENERIC_HOOK_HPP -#define BOOST_INTRUSIVE_GENERIC_HOOK_HPP - -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { -namespace intrusive { - -/// @cond - -enum base_hook_type -{ NoBaseHookId -, ListBaseHookId -, SlistBaseHookId -, RbTreeBaseHookId -, HashBaseHookId -, SplayTreeBaseHookId -, AvlTreeBaseHookId -, BsTreeBaseHookId -, AnyBaseHookId -}; - - -template -struct hook_tags_definer{}; - -template -struct hook_tags_definer -{ typedef HookTags default_list_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_slist_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_rbtree_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_hashtable_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_splaytree_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_avltree_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_bstree_hook; }; - -template -struct hook_tags_definer -{ typedef HookTags default_any_hook; }; - -template - < class NodeTraits - , class Tag - , link_mode_type LinkMode - , base_hook_type BaseHookType - > -struct hooktags_impl -{ - static const link_mode_type link_mode = LinkMode; - typedef Tag tag; - typedef NodeTraits node_traits; - static const bool is_base_hook = !detail::is_same::value; - static const bool safemode_or_autounlink = is_safe_autounlink::value; - static const unsigned int type = BaseHookType; -}; - -/// @endcond - -template - < class GetNodeAlgorithms - , class Tag - , link_mode_type LinkMode - , base_hook_type BaseHookType - > -class generic_hook - /// @cond - //If the hook is a base hook, derive generic hook from node_holder - //so that a unique base class is created to convert from the node - //to the type. This mechanism will be used by bhtraits. - // - //If the hook is a member hook, generic hook will directly derive - //from the hook. - : public detail::if_c - < detail::is_same::value - , typename GetNodeAlgorithms::type::node - , node_holder - >::type - //If this is the a default-tagged base hook derive from a class that - //will define an special internal typedef. Containers will be able to detect this - //special typedef and obtain generic_hook's internal types in order to deduce - //value_traits for this hook. - , public hook_tags_definer - < generic_hook - , detail::is_same::value*BaseHookType> - /// @endcond -{ - /// @cond - typedef typename GetNodeAlgorithms::type node_algorithms; - typedef typename node_algorithms::node node; - typedef typename node_algorithms::node_ptr node_ptr; - typedef typename node_algorithms::const_node_ptr const_node_ptr; - - public: - - typedef hooktags_impl - < typename GetNodeAlgorithms::type::node_traits - , Tag, LinkMode, BaseHookType> hooktags; - - node_ptr this_ptr() - { return pointer_traits::pointer_to(static_cast(*this)); } - - const_node_ptr this_ptr() const - { return pointer_traits::pointer_to(static_cast(*this)); } - - public: - /// @endcond - - generic_hook() - { - if(hooktags::safemode_or_autounlink){ - node_algorithms::init(this->this_ptr()); - } - } - - generic_hook(const generic_hook& ) - { - if(hooktags::safemode_or_autounlink){ - node_algorithms::init(this->this_ptr()); - } - } - - generic_hook& operator=(const generic_hook& ) - { return *this; } - - ~generic_hook() - { - destructor_impl - (*this, detail::link_dispatch()); - } - - void swap_nodes(generic_hook &other) - { - node_algorithms::swap_nodes - (this->this_ptr(), other.this_ptr()); - } - - bool is_linked() const - { - //is_linked() can be only used in safe-mode or auto-unlink - BOOST_STATIC_ASSERT(( hooktags::safemode_or_autounlink )); - return !node_algorithms::unique(this->this_ptr()); - } - - void unlink() - { - BOOST_STATIC_ASSERT(( (int)hooktags::link_mode == (int)auto_unlink )); - node_algorithms::unlink(this->this_ptr()); - node_algorithms::init(this->this_ptr()); - } -}; - -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_GENERIC_HOOK_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/has_member_function_callable_with.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/has_member_function_callable_with.hpp deleted file mode 100644 index be4a0153..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/has_member_function_callable_with.hpp +++ /dev/null @@ -1,357 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -// sample.h - -#if !defined(BOOST_PP_IS_ITERATING) - - #ifndef BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_DETAILS_INCLUDED - #define BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_DETAILS_INCLUDED - - #include - #include - #include - #include - #include - #include - - //Mark that we don't support 0 arg calls due to compiler ICE in GCC 3.4/4.0/4.1 and - //wrong SFINAE for GCC 4.2/4.3 - #if defined(__GNUC__) && !defined(__clang__) && ((__GNUC__*100 + __GNUC_MINOR__*10) >= 340) && ((__GNUC__*100 + __GNUC_MINOR__*10) <= 430) - #define BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_0_ARGS_UNSUPPORTED - #elif defined(BOOST_INTEL) && (BOOST_INTEL < 1200 ) - #define BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_0_ARGS_UNSUPPORTED - #endif - - namespace boost_intrusive_has_member_function_callable_with { - - struct dont_care - { - dont_care(...); - }; - - struct private_type - { - static private_type p; - private_type const &operator,(int) const; - }; - - typedef char yes_type; // sizeof(yes_type) == 1 - struct no_type{ char dummy[2]; }; // sizeof(no_type) == 2 - - template - no_type is_private_type(T const &); - yes_type is_private_type(private_type const &); - - } //boost_intrusive_has_member_function_callable_with - - #include - - #endif //BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_DETAILS_INCLUDED - -#else //!BOOST_PP_IS_ITERATING - - #ifndef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - #error "BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME not defined!" - #endif - - #ifndef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN - #error "BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN not defined!" - #endif - - #ifndef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END - #error "BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END not defined!" - #endif - - #if BOOST_PP_ITERATION_START() != 0 - #error "BOOST_PP_ITERATION_START() must be zero (0)" - #endif - - #if BOOST_PP_ITERATION() == 0 - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN - - template - class BOOST_PP_CAT(has_member_function_named_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - { - struct BaseMixin - { - void BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME(); - }; - - struct Base : public ::boost::intrusive::detail::remove_cv::type, public BaseMixin { Base(); }; - template class Helper{}; - - template - static boost_intrusive_has_member_function_callable_with::no_type deduce - (U*, Helper* = 0); - static boost_intrusive_has_member_function_callable_with::yes_type deduce(...); - - public: - static const bool value = - sizeof(boost_intrusive_has_member_function_callable_with::yes_type) == sizeof(deduce((Base*)(0))); - }; - - #if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME), _impl); - //! - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME), _impl) - - { - static const bool value = false; - }; - //! - - #if !defined(_MSC_VER) || (_MSC_VER < 1600) - - #if defined(BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_0_ARGS_UNSUPPORTED) - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - //Mark that we don't support 0 arg calls due to compiler ICE in GCC 3.4/4.0/4.1 and - //wrong SFINAE for GCC 4.2/4.3 - static const bool value = true; - }; - - #else //defined(BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_0_ARGS_UNSUPPORTED) - - //Special case for 0 args - template< class F - , std::size_t N = - sizeof((boost::move_detail::declval(). - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME (), 0))> - struct BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - { - boost_intrusive_has_member_function_callable_with::yes_type dummy; - BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)(int); - }; - - //For buggy compilers like MSVC 7.1+ ((F*)0)->func() does not - //SFINAE-out the zeroarg_checker_ instantiation but sizeof yields to 0. - template - struct BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - { - boost_intrusive_has_member_function_callable_with::no_type dummy; - BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)(int); - }; - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - template - static BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - Test(BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)*); - - template - static boost_intrusive_has_member_function_callable_with::no_type Test(...); - - static const bool value = sizeof(Test< Fun >(0)) - == sizeof(boost_intrusive_has_member_function_callable_with::yes_type); - }; - #endif //defined(BOOST_INTRUSIVE_DETAIL_HAS_MEMBER_FUNCTION_CALLABLE_WITH_0_ARGS_UNSUPPORTED) - - #else //#if !defined(_MSC_VER) || (_MSC_VER < 1600) - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - template - static decltype( boost::move_detail::declval().BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME() - , boost_intrusive_has_member_function_callable_with::yes_type()) - Test(Fun*); - - template - static boost_intrusive_has_member_function_callable_with::no_type Test(...); - - static const bool value = sizeof(Test(0)) - == sizeof(boost_intrusive_has_member_function_callable_with::yes_type); - }; - #endif //#if !defined(_MSC_VER) || (_MSC_VER < 1600) - - #else //#if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl); - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - static const bool value = false; - }; - - //Special case for 0 args - template< class F - , std::size_t N = - sizeof((boost::move_detail::declval(). - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME (), 0))> - struct BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - { - boost_intrusive_has_member_function_callable_with::yes_type dummy; - BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)(int); - }; - - //For buggy compilers like MSVC 7.1+ ((F*)0)->func() does not - //SFINAE-out the zeroarg_checker_ instantiation but sizeof yields to 0. - template - struct BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - { - boost_intrusive_has_member_function_callable_with::no_type dummy; - BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)(int); - }; - - template - struct BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - template - static BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - Test(BOOST_PP_CAT(zeroarg_checker_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)*); - - template - static boost_intrusive_has_member_function_callable_with::no_type Test(...); - - static const bool value = sizeof(Test< Fun >(0)) - == sizeof(boost_intrusive_has_member_function_callable_with::yes_type); - }; - - template - struct BOOST_PP_CAT( funwrap_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME ) - : Fun - { - BOOST_PP_CAT( funwrap_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME )(); - using Fun::BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME; - - boost_intrusive_has_member_function_callable_with::private_type - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - ( DontCares...) const; - }; - - template - struct BOOST_PP_CAT( BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME), _impl) - - { - template - struct make_dontcare - { - typedef boost_intrusive_has_member_function_callable_with::dont_care type; - }; - - typedef BOOST_PP_CAT( funwrap_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME ) - ::type...> FunWrap; - - static bool const value = (sizeof(boost_intrusive_has_member_function_callable_with::no_type) == - sizeof(boost_intrusive_has_member_function_callable_with::is_private_type - ( (::boost::move_detail::declval< FunWrap >(). - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - ( ::boost::move_detail::declval()... ), 0) ) - ) - ); - }; - - template - struct BOOST_PP_CAT( has_member_function_callable_with_ - , BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - : public BOOST_PP_CAT( BOOST_PP_CAT(has_member_function_callable_with_ - , BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - < Fun - , BOOST_PP_CAT( has_member_function_named_ - , BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME )::value - , Args... > - {}; - - #endif //#if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END - - #else //BOOST_PP_ITERATION() == 0 - - #if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN - - template - struct BOOST_PP_CAT( BOOST_PP_CAT(funwrap, BOOST_PP_ITERATION()) - , BOOST_PP_CAT(_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)) - : Fun - { - BOOST_PP_CAT( BOOST_PP_CAT(funwrap, BOOST_PP_ITERATION()) - , BOOST_PP_CAT(_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME))(); - - using Fun::BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME; - boost_intrusive_has_member_function_callable_with::private_type - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - ( BOOST_PP_ENUM(BOOST_PP_ITERATION() - , BOOST_INTRUSIVE_PP_IDENTITY - , boost_intrusive_has_member_function_callable_with::dont_care)) const; - }; - - template - struct BOOST_PP_CAT( BOOST_PP_CAT(has_member_function_callable_with_ - , BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME),_impl) - - { - typedef BOOST_PP_CAT( BOOST_PP_CAT(funwrap, BOOST_PP_ITERATION()) - , BOOST_PP_CAT(_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME)) - FunWrap; - static bool const value = - (sizeof(boost_intrusive_has_member_function_callable_with::no_type) == - sizeof(boost_intrusive_has_member_function_callable_with::is_private_type - ( (boost::move_detail::declval(). - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - ( BOOST_PP_ENUM( BOOST_PP_ITERATION(), BOOST_INTRUSIVE_PP_DECLVAL, _) ), 0 - ) - ) - ) - ); - }; - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END - #endif //#if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - #endif //BOOST_PP_ITERATION() == 0 - - #if BOOST_PP_ITERATION() == BOOST_PP_ITERATION_FINISH() - - #if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN - - template - struct BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME) - : public BOOST_PP_CAT(BOOST_PP_CAT(has_member_function_callable_with_, BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME), _impl) - ::value - BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_PP_ITERATION_FINISH(), P) > - {}; - - BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END - - #endif //#if !defined(BOOST_INTRUSIVE_PERFECT_FORWARDING) - - #undef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME - #undef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN - #undef BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END - - #endif //#if BOOST_PP_ITERATION() == BOOST_PP_ITERATION_FINISH() - -#endif //!BOOST_PP_IS_ITERATING diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/is_stateful_value_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/is_stateful_value_traits.hpp deleted file mode 100644 index c98f6c6b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/is_stateful_value_traits.hpp +++ /dev/null @@ -1,77 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2009-2013. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_IS_STATEFUL_VALUE_TRAITS_HPP -#define BOOST_INTRUSIVE_DETAIL_IS_STATEFUL_VALUE_TRAITS_HPP - -#include - -#if defined(_MSC_VER) && (_MSC_VER <= 1310) - -#include - -namespace boost { -namespace intrusive { -namespace detail { - -template -struct is_stateful_value_traits -{ - static const bool value = !detail::is_empty_class::value; -}; - -}}} - -#else - -#include - -BOOST_INTRUSIVE_CREATE_FUNCTION_DETECTOR(to_node_ptr, boost_intrusive) -BOOST_INTRUSIVE_CREATE_FUNCTION_DETECTOR(to_value_ptr, boost_intrusive) - -namespace boost { -namespace intrusive { -namespace detail { - -template -struct is_stateful_value_traits -{ - typedef typename ValueTraits::node_ptr node_ptr; - typedef typename ValueTraits::pointer pointer; - typedef typename ValueTraits::value_type value_type; - typedef typename ValueTraits::const_node_ptr const_node_ptr; - typedef typename ValueTraits::const_pointer const_pointer; - - typedef ValueTraits value_traits; - - static const bool value = - (boost::intrusive::function_detector::NonStaticFunction == - (BOOST_INTRUSIVE_DETECT_FUNCTION(ValueTraits, boost_intrusive, node_ptr, to_node_ptr, (value_type&) ))) - || - (boost::intrusive::function_detector::NonStaticFunction == - (BOOST_INTRUSIVE_DETECT_FUNCTION(ValueTraits, boost_intrusive, pointer, to_value_ptr, (node_ptr) ))) - || - (boost::intrusive::function_detector::NonStaticFunction == - (BOOST_INTRUSIVE_DETECT_FUNCTION(ValueTraits, boost_intrusive, const_node_ptr, to_node_ptr, (const value_type&) ))) - || - (boost::intrusive::function_detector::NonStaticFunction == - (BOOST_INTRUSIVE_DETECT_FUNCTION(ValueTraits, boost_intrusive, const_pointer, to_value_ptr, (const_node_ptr) ))) - ; -}; - -}}} - -#endif - -#include - -#endif //@ifndef BOOST_INTRUSIVE_DETAIL_IS_STATEFUL_VALUE_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/memory_util.hpp b/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/memory_util.hpp deleted file mode 100644 index bfc9b149..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/intrusive/detail/memory_util.hpp +++ /dev/null @@ -1,292 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Pablo Halpern 2009. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2011-2013. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_ALLOCATOR_MEMORY_UTIL_HPP -#define BOOST_INTRUSIVE_ALLOCATOR_MEMORY_UTIL_HPP - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -#include -#include -#include -#include - -namespace boost { -namespace intrusive { -namespace detail { - -template -inline T* addressof(T& obj) -{ - return static_cast - (static_cast - (const_cast - (&reinterpret_cast(obj)) - ) - ); -} - -template struct unvoid { typedef T type; }; -template <> struct unvoid { struct type { }; }; -template <> struct unvoid { struct type { }; }; - -template struct unvoid_ref { typedef T &type; }; -template <> struct unvoid_ref { struct type_impl { }; typedef type_impl & type; }; -template <> struct unvoid_ref { struct type_impl { }; typedef type_impl & type; }; - -template -struct LowPriorityConversion -{ - // Convertible from T with user-defined-conversion rank. - LowPriorityConversion(const T&) { } -}; - -// Infrastructure for providing a default type for T::TNAME if absent. -#define BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(TNAME) \ - template \ - struct boost_intrusive_default_type_ ## TNAME \ - { \ - template \ - static char test(int, typename X::TNAME*); \ - \ - template \ - static int test(boost::intrusive::detail:: \ - LowPriorityConversion, void*); \ - \ - struct DefaultWrap { typedef DefaultType TNAME; }; \ - \ - static const bool value = (1 == sizeof(test(0, 0))); \ - \ - typedef typename \ - ::boost::intrusive::detail::if_c \ - ::type::TNAME type; \ - }; \ - \ - template \ - struct boost_intrusive_eval_default_type_ ## TNAME \ - { \ - template \ - static char test(int, typename X::TNAME*); \ - \ - template \ - static int test(boost::intrusive::detail:: \ - LowPriorityConversion, void*); \ - \ - struct DefaultWrap \ - { typedef typename DefaultType::type TNAME; }; \ - \ - static const bool value = (1 == sizeof(test(0, 0))); \ - \ - typedef typename \ - ::boost::intrusive::detail::eval_if_c \ - < value \ - , ::boost::intrusive::detail::identity \ - , ::boost::intrusive::detail::identity \ - >::type::TNAME type; \ - }; \ -// - -#define BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT(INSTANTIATION_NS_PREFIX, T, TNAME, TIMPL) \ - typename INSTANTIATION_NS_PREFIX \ - boost_intrusive_default_type_ ## TNAME< T, TIMPL >::type \ -// - -#define BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT(INSTANTIATION_NS_PREFIX, T, TNAME, TIMPL) \ - typename INSTANTIATION_NS_PREFIX \ - boost_intrusive_eval_default_type_ ## TNAME< T, TIMPL >::type \ -// - -}}} //namespace boost::intrusive::detail - -#include - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME pointer_to -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace intrusive { namespace detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 1, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME static_cast_from -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace intrusive { namespace detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 1, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME const_cast_from -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace intrusive { namespace detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 1, )) -#include BOOST_PP_ITERATE() - -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_FUNCNAME dynamic_cast_from -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_BEGIN namespace boost { namespace intrusive { namespace detail { -#define BOOST_INTRUSIVE_HAS_MEMBER_FUNCTION_CALLABLE_WITH_NS_END }}} -#define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 1, )) -#include BOOST_PP_ITERATE() - -namespace boost { -namespace intrusive { -namespace detail { - -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(element_type) -BOOST_INTRUSIVE_INSTANTIATE_DEFAULT_TYPE_TMPLT(difference_type) - -////////////////////// -//struct first_param -////////////////////// - -template struct first_param -{ typedef void type; }; - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - - template

::type& - > -{ -}; - -template -struct pointer_iterator_traits -{ - typedef T pointer; - typedef std::random_access_iterator_tag iterator_category; - typedef std::ptrdiff_t difference_type; - - typedef typename pointer_value_type::type value_type; - typedef typename pointer_reference::type reference; -}; - -# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -// We'll sort iterator types into one of these classifications, from which we -// can determine the difference_type, pointer, reference, and value_type -template -struct standard_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 msvc_stdlib_mutable_traits - : std::iterator_traits -{ - typedef typename std::iterator_traits::distance_type difference_type; - typedef typename std::iterator_traits::value_type* pointer; - typedef typename std::iterator_traits::value_type& reference; -}; - -template -struct msvc_stdlib_const_traits - : std::iterator_traits -{ - typedef typename std::iterator_traits::distance_type difference_type; - typedef const typename std::iterator_traits::value_type* pointer; - typedef const typename std::iterator_traits::value_type& reference; -}; - -# ifdef BOOST_BAD_OUTPUT_ITERATOR_SPECIALIZATION -template -struct is_bad_output_iterator - : is_base_and_derived< - std::iterator - , Iterator> -{ -}; - -struct bad_output_iterator_traits -{ - typedef void value_type; - typedef void difference_type; - typedef std::output_iterator_tag iterator_category; - typedef void pointer; - typedef void reference; -}; -# endif - -// If we're looking at an MSVC6 (old Dinkumware) ``standard'' -// iterator, this will generate an appropriate traits class. -template -struct msvc_stdlib_iterator_traits - : mpl::if_< - is_mutable_iterator - , msvc_stdlib_mutable_traits - , msvc_stdlib_const_traits - >::type -{}; - -template -struct non_pointer_iterator_traits - : mpl::if_< - // if the iterator contains all the right nested types... - is_full_iterator_traits - // Use a standard iterator_traits implementation - , standard_iterator_traits -# ifdef BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF - // Check for STLPort 4.0 broken _Iterator_category type - , mpl::if_< - is_stlport_40_debug_iterator - , stlport_40_debug_iterator_traits -# endif - // Otherwise, assume it's a Dinkum iterator - , msvc_stdlib_iterator_traits -# ifdef BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF - >::type -# endif - >::type -{ -}; - -template -struct iterator_traits_aux - : mpl::if_< - is_pointer - , pointer_iterator_traits - , non_pointer_iterator_traits - >::type -{ -}; - -template -struct iterator_traits -{ - // Explicit forwarding from base class needed to keep MSVC6 happy - // under some circumstances. - private: -# ifdef BOOST_BAD_OUTPUT_ITERATOR_SPECIALIZATION - typedef - typename mpl::if_< - is_bad_output_iterator - , bad_output_iterator_traits - , iterator_traits_aux - >::type base; -# else - typedef iterator_traits_aux base; -# endif - public: - typedef typename base::value_type value_type; - typedef typename base::pointer pointer; - typedef typename base::reference reference; - typedef typename base::difference_type difference_type; - typedef typename base::iterator_category iterator_category; -}; - -// This specialization cuts off ETI (Early Template Instantiation) for MSVC. -template <> struct iterator_traits -{ - typedef int value_type; - typedef int pointer; - typedef int reference; - typedef int difference_type; - typedef int iterator_category; -}; - -}} // namespace boost::detail - -# endif // workarounds - -namespace boost { namespace detail { - -namespace iterator_traits_ -{ - template - struct distance_select - { - static Difference execute(Iterator i1, const Iterator i2, ...) - { - Difference result = 0; - while (i1 != i2) - { - ++i1; - ++result; - } - return result; - } - - static Difference execute(Iterator i1, const Iterator i2, std::random_access_iterator_tag*) - { - return i2 - i1; - } - }; -} // namespace boost::detail::iterator_traits_ - -template -inline typename iterator_traits::difference_type -distance(Iterator first, Iterator last) -{ - typedef typename iterator_traits::difference_type diff_t; - typedef typename ::boost::detail::iterator_traits::iterator_category iterator_category; - - return iterator_traits_::distance_select::execute( - first, last, (iterator_category*)0); -} - -}} - -# endif - - -# undef BOOST_BAD_CONTAINER_ITERATOR_CATEGORY_TYPEDEF -# undef BOOST_BAD_OUTPUT_ITERATOR_SPECIALIZATION - -#endif // ITERATOR_DWA122600_HPP_ diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/lcast_precision.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/lcast_precision.hpp deleted file mode 100644 index 93abce18..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/lcast_precision.hpp +++ /dev/null @@ -1,184 +0,0 @@ -// Copyright Alexander Nasonov & Paul A. Bristow 2006. - -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt -// or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_DETAIL_LCAST_PRECISION_HPP_INCLUDED -#define BOOST_DETAIL_LCAST_PRECISION_HPP_INCLUDED - -#include -#include -#include - -#include -#include - -#ifndef BOOST_NO_IS_ABSTRACT -// Fix for SF:1358600 - lexical_cast & pure virtual functions & VC 8 STL -#include -#include -#endif - -#if defined(BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS) || \ - (defined(BOOST_MSVC) && (BOOST_MSVC<1310)) - -#define BOOST_LCAST_NO_COMPILE_TIME_PRECISION -#endif - -#ifdef BOOST_LCAST_NO_COMPILE_TIME_PRECISION -#include -#else -#include -#endif - -namespace boost { namespace detail { - -class lcast_abstract_stub {}; - -#ifndef BOOST_LCAST_NO_COMPILE_TIME_PRECISION -// Calculate an argument to pass to std::ios_base::precision from -// lexical_cast. See alternative implementation for broken standard -// libraries in lcast_get_precision below. Keep them in sync, please. -template -struct lcast_precision -{ -#ifdef BOOST_NO_IS_ABSTRACT - typedef std::numeric_limits limits; // No fix for SF:1358600. -#else - typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_< - boost::is_abstract - , std::numeric_limits - , std::numeric_limits - >::type limits; -#endif - - BOOST_STATIC_CONSTANT(bool, use_default_precision = - !limits::is_specialized || limits::is_exact - ); - - BOOST_STATIC_CONSTANT(bool, is_specialized_bin = - !use_default_precision && - limits::radix == 2 && limits::digits > 0 - ); - - BOOST_STATIC_CONSTANT(bool, is_specialized_dec = - !use_default_precision && - limits::radix == 10 && limits::digits10 > 0 - ); - - BOOST_STATIC_CONSTANT(std::streamsize, streamsize_max = - boost::integer_traits::const_max - ); - - BOOST_STATIC_CONSTANT(unsigned int, precision_dec = limits::digits10 + 1U); - - BOOST_STATIC_ASSERT(!is_specialized_dec || - precision_dec <= streamsize_max + 0UL - ); - - BOOST_STATIC_CONSTANT(unsigned long, precision_bin = - 2UL + limits::digits * 30103UL / 100000UL - ); - - BOOST_STATIC_ASSERT(!is_specialized_bin || - (limits::digits + 0UL < ULONG_MAX / 30103UL && - precision_bin > limits::digits10 + 0UL && - precision_bin <= streamsize_max + 0UL) - ); - - BOOST_STATIC_CONSTANT(std::streamsize, value = - is_specialized_bin ? precision_bin - : is_specialized_dec ? precision_dec : 6 - ); -}; -#endif - -template -inline std::streamsize lcast_get_precision(T* = 0) -{ -#ifndef BOOST_LCAST_NO_COMPILE_TIME_PRECISION - return lcast_precision::value; -#else // Follow lcast_precision algorithm at run-time: - -#ifdef BOOST_NO_IS_ABSTRACT - typedef std::numeric_limits limits; // No fix for SF:1358600. -#else - typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_< - boost::is_abstract - , std::numeric_limits - , std::numeric_limits - >::type limits; -#endif - - bool const use_default_precision = - !limits::is_specialized || limits::is_exact; - - if(!use_default_precision) - { // Includes all built-in floating-point types, float, double ... - // and UDT types for which digits (significand bits) is defined (not zero) - - bool const is_specialized_bin = - limits::radix == 2 && limits::digits > 0; - bool const is_specialized_dec = - limits::radix == 10 && limits::digits10 > 0; - std::streamsize const streamsize_max = - (boost::integer_traits::max)(); - - if(is_specialized_bin) - { // Floating-point types with - // limits::digits defined by the specialization. - - unsigned long const digits = limits::digits; - unsigned long const precision = 2UL + digits * 30103UL / 100000UL; - // unsigned long is selected because it is at least 32-bits - // and thus ULONG_MAX / 30103UL is big enough for all types. - BOOST_ASSERT( - digits < ULONG_MAX / 30103UL && - precision > limits::digits10 + 0UL && - precision <= streamsize_max + 0UL - ); - return precision; - } - else if(is_specialized_dec) - { // Decimal Floating-point type, most likely a User Defined Type - // rather than a real floating-point hardware type. - unsigned int const precision = limits::digits10 + 1U; - BOOST_ASSERT(precision <= streamsize_max + 0UL); - return precision; - } - } - - // Integral type (for which precision has no effect) - // or type T for which limits is NOT specialized, - // so assume stream precision remains the default 6 decimal digits. - // Warning: if your User-defined Floating-point type T is NOT specialized, - // then you may lose accuracy by only using 6 decimal digits. - // To avoid this, you need to specialize T with either - // radix == 2 and digits == the number of significand bits, - // OR - // radix = 10 and digits10 == the number of decimal digits. - - return 6; -#endif -} - -template -inline void lcast_set_precision(std::ios_base& stream, T*) -{ - stream.precision(lcast_get_precision()); -} - -template -inline void lcast_set_precision(std::ios_base& stream, Source*, Target*) -{ - std::streamsize const s = lcast_get_precision(static_cast(0)); - std::streamsize const t = lcast_get_precision(static_cast(0)); - stream.precision(s > t ? s : t); -} - -}} - -#endif // BOOST_DETAIL_LCAST_PRECISION_HPP_INCLUDED - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/lightweight_mutex.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/lightweight_mutex.hpp deleted file mode 100644 index b7a7f6dd..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/lightweight_mutex.hpp +++ /dev/null @@ -1,22 +0,0 @@ -#ifndef BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED -#define BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// boost/detail/lightweight_mutex.hpp - lightweight mutex -// -// Copyright (c) 2002, 2003 Peter Dimov and Multi Media Ltd. -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// - -#include - -#endif // #ifndef BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/no_exceptions_support.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/no_exceptions_support.hpp deleted file mode 100644 index d94e3583..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/no_exceptions_support.hpp +++ /dev/null @@ -1,87 +0,0 @@ -#ifndef BOOST_DETAIL_NO_EXCEPTIONS_SUPPORT_HPP_ -#define BOOST_DETAIL_NO_EXCEPTIONS_SUPPORT_HPP_ - -#if (defined _MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif - -//---------------------------------------------------------------------- -// (C) Copyright 2004 Pavel Vozenilek. -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt -// or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// -// This file contains helper macros used when exception support may be -// disabled (as indicated by macro BOOST_NO_EXCEPTIONS). -// -// Before picking up these macros you may consider using RAII techniques -// to deal with exceptions - their syntax can be always the same with -// or without exception support enabled. -// - -/* Example of use: - -void foo() { - BOOST_TRY { - ... - } BOOST_CATCH(const std::bad_alloc&) { - ... - BOOST_RETHROW - } BOOST_CATCH(const std::exception& e) { - ... - } - BOOST_CATCH_END -} - -With exception support enabled it will expand into: - -void foo() { - { try { - ... - } catch (const std::bad_alloc&) { - ... - throw; - } catch (const std::exception& e) { - ... - } - } -} - -With exception support disabled it will expand into: - -void foo() { - { if(true) { - ... - } else if (false) { - ... - } else if (false) { - ... - } - } -} -*/ -//---------------------------------------------------------------------- - -#include -#include - -#if !(defined BOOST_NO_EXCEPTIONS) -# define BOOST_TRY { try -# define BOOST_CATCH(x) catch(x) -# define BOOST_RETHROW throw; -# define BOOST_CATCH_END } -#else -# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -# define BOOST_TRY { if ("") -# define BOOST_CATCH(x) else if (!"") -# else -# define BOOST_TRY { if (true) -# define BOOST_CATCH(x) else if (false) -# endif -# define BOOST_RETHROW -# define BOOST_CATCH_END } -#endif - - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/numeric_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/numeric_traits.hpp deleted file mode 100644 index 6325d70c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/numeric_traits.hpp +++ /dev/null @@ -1,191 +0,0 @@ -// (C) Copyright David Abrahams 2001, Howard Hinnant 2001. -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// Template class numeric_traits -- -// -// Supplies: -// -// typedef difference_type -- a type used to represent the difference -// between any two values of Number. -// -// Support: -// 1. Not all specializations are supplied -// -// 2. Use of specializations that are not supplied will cause a -// compile-time error -// -// 3. Users are free to specialize numeric_traits for any type. -// -// 4. Right now, specializations are only supplied for integer types. -// -// 5. On implementations which do not supply compile-time constants in -// std::numeric_limits<>, only specializations for built-in integer types -// are supplied. -// -// 6. Handling of numbers whose range of representation is at least as -// great as boost::intmax_t can cause some differences to be -// unrepresentable in difference_type: -// -// Number difference_type -// ------ --------------- -// signed Number -// unsigned intmax_t -// -// template typename numeric_traits::difference_type -// numeric_distance(Number x, Number y) -// computes (y - x), attempting to avoid overflows. -// - -// See http://www.boost.org for most recent version including documentation. - -// Revision History -// 11 Feb 2001 - Use BOOST_STATIC_CONSTANT (David Abrahams) -// 11 Feb 2001 - Rolled back ineffective Borland-specific code -// (David Abrahams) -// 10 Feb 2001 - Rolled in supposed Borland fixes from John Maddock, but -// not seeing any improvement yet (David Abrahams) -// 06 Feb 2001 - Factored if_true out into boost/detail/select_type.hpp -// (David Abrahams) -// 23 Jan 2001 - Fixed logic of difference_type selection, which was -// completely wack. In the process, added digit_traits<> -// to compute the number of digits in intmax_t even when -// not supplied by numeric_limits<>. (David Abrahams) -// 21 Jan 2001 - Created (David Abrahams) - -#ifndef BOOST_NUMERIC_TRAITS_HPP_DWA20001901 -# define BOOST_NUMERIC_TRAITS_HPP_DWA20001901 - -# include -# include -# include -# include -# include -# include - -namespace boost { namespace detail { - - // Template class is_signed -- determine whether a numeric type is signed - // Requires that T is constructable from the literals -1 and 0. Compile-time - // error results if that requirement is not met (and thus signedness is not - // likely to have meaning for that type). - template - struct is_signed - { -#if defined(BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS) || defined(BOOST_MSVC) && BOOST_MSVC <= 1300 - BOOST_STATIC_CONSTANT(bool, value = (Number(-1) < Number(0))); -#else - BOOST_STATIC_CONSTANT(bool, value = std::numeric_limits::is_signed); -#endif - }; - -# ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - // digit_traits - compute the number of digits in a built-in integer - // type. Needed for implementations on which numeric_limits is not specialized - // for intmax_t (e.g. VC6). - template struct digit_traits_select; - - // numeric_limits is specialized; just select that version of digits - template <> struct digit_traits_select - { - template struct traits - { - BOOST_STATIC_CONSTANT(int, digits = std::numeric_limits::digits); - }; - }; - - // numeric_limits is not specialized; compute digits from sizeof(T) - template <> struct digit_traits_select - { - template struct traits - { - BOOST_STATIC_CONSTANT(int, digits = ( - sizeof(T) * std::numeric_limits::digits - - (is_signed::value ? 1 : 0)) - ); - }; - }; - - // here's the "usable" template - template struct digit_traits - { - typedef digit_traits_select< - ::std::numeric_limits::is_specialized> selector; - typedef typename selector::template traits traits; - BOOST_STATIC_CONSTANT(int, digits = traits::digits); - }; -#endif - - // Template class integer_traits -- traits of various integer types - // This should probably be rolled into boost::integer_traits one day, but I - // need it to work without - template - struct integer_traits - { -# ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS - private: - typedef Integer integer_type; - typedef std::numeric_limits x; -# if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 - // for some reason, MSVC asserts when it shouldn't unless we make these - // local definitions - BOOST_STATIC_CONSTANT(bool, is_integer = x::is_integer); - BOOST_STATIC_CONSTANT(bool, is_specialized = x::is_specialized); - - BOOST_STATIC_ASSERT(is_integer); - BOOST_STATIC_ASSERT(is_specialized); -# endif - public: - typedef typename - if_true<(int(x::is_signed) - && (!int(x::is_bounded) - // digits is the number of no-sign bits - || (int(x::digits) + 1 >= digit_traits::digits)))>::template then< - Integer, - - typename if_true<(int(x::digits) + 1 < digit_traits::digits)>::template then< - signed int, - - typename if_true<(int(x::digits) + 1 < digit_traits::digits)>::template then< - signed long, - - // else - intmax_t - >::type>::type>::type difference_type; -#else - BOOST_STATIC_ASSERT(boost::is_integral::value); - - typedef typename - if_true<(sizeof(Integer) >= sizeof(intmax_t))>::template then< - - typename if_true<(is_signed::value)>::template then< - Integer, - intmax_t - >::type, - - typename if_true<(sizeof(Integer) < sizeof(std::ptrdiff_t))>::template then< - std::ptrdiff_t, - intmax_t - >::type - >::type difference_type; -# endif - }; - - // Right now, only supports integers, but should be expanded. - template - struct numeric_traits - { - typedef typename integer_traits::difference_type difference_type; - }; - - template - typename numeric_traits::difference_type numeric_distance(Number x, Number y) - { - typedef typename numeric_traits::difference_type difference_type; - return difference_type(y) - difference_type(x); - } -}} - -#endif // BOOST_NUMERIC_TRAITS_HPP_DWA20001901 diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/ob_call_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/ob_call_traits.hpp deleted file mode 100644 index eb4df7a3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/ob_call_traits.hpp +++ /dev/null @@ -1,168 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. -// -// Crippled version for crippled compilers: -// see libs/utility/call_traits.htm -// - -/* Release notes: - 01st October 2000: - Fixed call_traits on VC6, using "poor man's partial specialisation", - using ideas taken from "Generative programming" by Krzysztof Czarnecki - & Ulrich Eisenecker. -*/ - -#ifndef BOOST_OB_CALL_TRAITS_HPP -#define BOOST_OB_CALL_TRAITS_HPP - -#ifndef BOOST_CONFIG_HPP -#include -#endif - -#ifndef BOOST_ARITHMETIC_TYPE_TRAITS_HPP -#include -#endif -#ifndef BOOST_COMPOSITE_TYPE_TRAITS_HPP -#include -#endif - -namespace boost{ - -#ifdef BOOST_MSVC6_MEMBER_TEMPLATES -// -// use member templates to emulate -// partial specialisation: -// -namespace detail{ - -template -struct standard_call_traits -{ - typedef T value_type; - typedef T& reference; - typedef const T& const_reference; - typedef const T& param_type; -}; -template -struct simple_call_traits -{ - typedef T value_type; - typedef T& reference; - typedef const T& const_reference; - typedef const T param_type; -}; -template -struct reference_call_traits -{ - typedef T value_type; - typedef T reference; - typedef T const_reference; - typedef T param_type; -}; - -template -struct call_traits_chooser -{ - template - struct rebind - { - typedef standard_call_traits type; - }; -}; - -template <> -struct call_traits_chooser -{ - template - struct rebind - { - typedef simple_call_traits type; - }; -}; - -template <> -struct call_traits_chooser -{ - template - struct rebind - { - typedef reference_call_traits type; - }; -}; - -template -struct call_traits_sizeof_chooser2 -{ - template - struct small_rebind - { - typedef simple_call_traits small_type; - }; -}; - -template<> -struct call_traits_sizeof_chooser2 -{ - template - struct small_rebind - { - typedef standard_call_traits small_type; - }; -}; - -template <> -struct call_traits_chooser -{ - template - struct rebind - { - enum { sizeof_choice = (sizeof(T) <= sizeof(void*)) }; - typedef call_traits_sizeof_chooser2<(sizeof(T) <= sizeof(void*))> chooser; - typedef typename chooser::template small_rebind bound_type; - typedef typename bound_type::small_type type; - }; -}; - -} // namespace detail -template -struct call_traits -{ -private: - typedef detail::call_traits_chooser< - ::boost::is_pointer::value, - ::boost::is_arithmetic::value, - ::boost::is_reference::value - > chooser; - typedef typename chooser::template rebind bound_type; - typedef typename bound_type::type call_traits_type; -public: - typedef typename call_traits_type::value_type value_type; - typedef typename call_traits_type::reference reference; - typedef typename call_traits_type::const_reference const_reference; - typedef typename call_traits_type::param_type param_type; -}; - -#else -// -// sorry call_traits is completely non-functional -// blame your broken compiler: -// - -template -struct call_traits -{ - typedef T value_type; - typedef T& reference; - typedef const T& const_reference; - typedef const T& param_type; -}; - -#endif // member templates - -} - -#endif // BOOST_OB_CALL_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/ob_compressed_pair.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/ob_compressed_pair.hpp deleted file mode 100644 index 727acab6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/ob_compressed_pair.hpp +++ /dev/null @@ -1,510 +0,0 @@ -// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. -// Use, modification and distribution are subject to the Boost Software License, -// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt). -// -// See http://www.boost.org/libs/utility for most recent version including documentation. -// see libs/utility/compressed_pair.hpp -// -/* Release notes: - 20 Jan 2001: - Fixed obvious bugs (David Abrahams) - 07 Oct 2000: - Added better single argument constructor support. - 03 Oct 2000: - Added VC6 support (JM). - 23rd July 2000: - Additional comments added. (JM) - Jan 2000: - Original version: this version crippled for use with crippled compilers - - John Maddock Jan 2000. -*/ - - -#ifndef BOOST_OB_COMPRESSED_PAIR_HPP -#define BOOST_OB_COMPRESSED_PAIR_HPP - -#include -#ifndef BOOST_OBJECT_TYPE_TRAITS_HPP -#include -#endif -#ifndef BOOST_SAME_TRAITS_HPP -#include -#endif -#ifndef BOOST_CALL_TRAITS_HPP -#include -#endif - -namespace boost -{ -#ifdef BOOST_MSVC6_MEMBER_TEMPLATES -// -// use member templates to emulate -// partial specialisation. Note that due to -// problems with overload resolution with VC6 -// each of the compressed_pair versions that follow -// have one template single-argument constructor -// in place of two specific constructors: -// - -template -class compressed_pair; - -namespace detail{ - -template -struct best_conversion_traits -{ - typedef char one; - typedef char (&two)[2]; - static A a; - static one test(T1); - static two test(T2); - - enum { value = sizeof(test(a)) }; -}; - -template -struct init_one; - -template <> -struct init_one<1> -{ - template - static void init(const A& a, T1* p1, T2*) - { - *p1 = a; - } -}; - -template <> -struct init_one<2> -{ - template - static void init(const A& a, T1*, T2* p2) - { - *p2 = a; - } -}; - - -// T1 != T2, both non-empty -template -class compressed_pair_0 -{ -private: - T1 _first; - T2 _second; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_0() : _first(), _second() {} - compressed_pair_0(first_param_type x, second_param_type y) : _first(x), _second(y) {} - template - explicit compressed_pair_0(const A& val) - { - init_one::value>::init(val, &_first, &_second); - } - compressed_pair_0(const ::boost::compressed_pair& x) - : _first(x.first()), _second(x.second()) {} - -#if 0 - compressed_pair_0& operator=(const compressed_pair_0& x) { - cout << "assigning compressed pair 0" << endl; - _first = x._first; - _second = x._second; - cout << "finished assigning compressed pair 0" << endl; - return *this; - } -#endif - - first_reference first() { return _first; } - first_const_reference first() const { return _first; } - - second_reference second() { return _second; } - second_const_reference second() const { return _second; } - - void swap(compressed_pair_0& y) - { - using std::swap; - swap(_first, y._first); - swap(_second, y._second); - } -}; - -// T1 != T2, T2 empty -template -class compressed_pair_1 : T2 -{ -private: - T1 _first; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_1() : T2(), _first() {} - compressed_pair_1(first_param_type x, second_param_type y) : T2(y), _first(x) {} - - template - explicit compressed_pair_1(const A& val) - { - init_one::value>::init(val, &_first, static_cast(this)); - } - - compressed_pair_1(const ::boost::compressed_pair& x) - : T2(x.second()), _first(x.first()) {} - -#if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 - // Total weirdness. If the assignment to _first is moved after - // the call to the inherited operator=, then this breaks graph/test/graph.cpp - // by way of iterator_adaptor. - compressed_pair_1& operator=(const compressed_pair_1& x) { - _first = x._first; - T2::operator=(x); - return *this; - } -#endif - - first_reference first() { return _first; } - first_const_reference first() const { return _first; } - - second_reference second() { return *this; } - second_const_reference second() const { return *this; } - - void swap(compressed_pair_1& y) - { - // no need to swap empty base class: - using std::swap; - swap(_first, y._first); - } -}; - -// T1 != T2, T1 empty -template -class compressed_pair_2 : T1 -{ -private: - T2 _second; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_2() : T1(), _second() {} - compressed_pair_2(first_param_type x, second_param_type y) : T1(x), _second(y) {} - template - explicit compressed_pair_2(const A& val) - { - init_one::value>::init(val, static_cast(this), &_second); - } - compressed_pair_2(const ::boost::compressed_pair& x) - : T1(x.first()), _second(x.second()) {} - -#if 0 - compressed_pair_2& operator=(const compressed_pair_2& x) { - cout << "assigning compressed pair 2" << endl; - T1::operator=(x); - _second = x._second; - cout << "finished assigning compressed pair 2" << endl; - return *this; - } -#endif - first_reference first() { return *this; } - first_const_reference first() const { return *this; } - - second_reference second() { return _second; } - second_const_reference second() const { return _second; } - - void swap(compressed_pair_2& y) - { - // no need to swap empty base class: - using std::swap; - swap(_second, y._second); - } -}; - -// T1 != T2, both empty -template -class compressed_pair_3 : T1, T2 -{ -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_3() : T1(), T2() {} - compressed_pair_3(first_param_type x, second_param_type y) : T1(x), T2(y) {} - template - explicit compressed_pair_3(const A& val) - { - init_one::value>::init(val, static_cast(this), static_cast(this)); - } - compressed_pair_3(const ::boost::compressed_pair& x) - : T1(x.first()), T2(x.second()) {} - - first_reference first() { return *this; } - first_const_reference first() const { return *this; } - - second_reference second() { return *this; } - second_const_reference second() const { return *this; } - - void swap(compressed_pair_3& y) - { - // no need to swap empty base classes: - } -}; - -// T1 == T2, and empty -template -class compressed_pair_4 : T1 -{ -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_4() : T1() {} - compressed_pair_4(first_param_type x, second_param_type y) : T1(x), m_second(y) {} - // only one single argument constructor since T1 == T2 - explicit compressed_pair_4(first_param_type x) : T1(x), m_second(x) {} - compressed_pair_4(const ::boost::compressed_pair& x) - : T1(x.first()), m_second(x.second()) {} - - first_reference first() { return *this; } - first_const_reference first() const { return *this; } - - second_reference second() { return m_second; } - second_const_reference second() const { return m_second; } - - void swap(compressed_pair_4& y) - { - // no need to swap empty base classes: - } -private: - T2 m_second; -}; - -// T1 == T2, not empty -template -class compressed_pair_5 -{ -private: - T1 _first; - T2 _second; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair_5() : _first(), _second() {} - compressed_pair_5(first_param_type x, second_param_type y) : _first(x), _second(y) {} - // only one single argument constructor since T1 == T2 - explicit compressed_pair_5(first_param_type x) : _first(x), _second(x) {} - compressed_pair_5(const ::boost::compressed_pair& c) - : _first(c.first()), _second(c.second()) {} - - first_reference first() { return _first; } - first_const_reference first() const { return _first; } - - second_reference second() { return _second; } - second_const_reference second() const { return _second; } - - void swap(compressed_pair_5& y) - { - using std::swap; - swap(_first, y._first); - swap(_second, y._second); - } -}; - -template -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_0 type; - }; -}; - -template <> -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_1 type; - }; -}; - -template <> -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_2 type; - }; -}; - -template <> -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_3 type; - }; -}; - -template <> -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_4 type; - }; -}; - -template <> -struct compressed_pair_chooser -{ - template - struct rebind - { - typedef compressed_pair_5 type; - }; -}; - -template -struct compressed_pair_traits -{ -private: - typedef compressed_pair_chooser::value, is_empty::value, is_same::value> chooser; - typedef typename chooser::template rebind bound_type; -public: - typedef typename bound_type::type type; -}; - -} // namespace detail - -template -class compressed_pair : public detail::compressed_pair_traits::type -{ -private: - typedef typename detail::compressed_pair_traits::type base_type; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair() : base_type() {} - compressed_pair(first_param_type x, second_param_type y) : base_type(x, y) {} - template - explicit compressed_pair(const A& x) : base_type(x){} - - first_reference first() { return base_type::first(); } - first_const_reference first() const { return base_type::first(); } - - second_reference second() { return base_type::second(); } - second_const_reference second() const { return base_type::second(); } -}; - -template -inline void swap(compressed_pair& x, compressed_pair& y) -{ - x.swap(y); -} - -#else -// no partial specialisation, no member templates: - -template -class compressed_pair -{ -private: - T1 _first; - T2 _second; -public: - typedef T1 first_type; - typedef T2 second_type; - typedef typename call_traits::param_type first_param_type; - typedef typename call_traits::param_type second_param_type; - typedef typename call_traits::reference first_reference; - typedef typename call_traits::reference second_reference; - typedef typename call_traits::const_reference first_const_reference; - typedef typename call_traits::const_reference second_const_reference; - - compressed_pair() : _first(), _second() {} - compressed_pair(first_param_type x, second_param_type y) : _first(x), _second(y) {} - explicit compressed_pair(first_param_type x) : _first(x), _second() {} - // can't define this in case T1 == T2: - // explicit compressed_pair(second_param_type y) : _first(), _second(y) {} - - first_reference first() { return _first; } - first_const_reference first() const { return _first; } - - second_reference second() { return _second; } - second_const_reference second() const { return _second; } - - void swap(compressed_pair& y) - { - using std::swap; - swap(_first, y._first); - swap(_second, y._second); - } -}; - -template -inline void swap(compressed_pair& x, compressed_pair& y) -{ - x.swap(y); -} - -#endif - -} // boost - -#endif // BOOST_OB_COMPRESSED_PAIR_HPP - - - diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/quick_allocator.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/quick_allocator.hpp deleted file mode 100644 index d54b3a79..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/quick_allocator.hpp +++ /dev/null @@ -1,23 +0,0 @@ -#ifndef BOOST_DETAIL_QUICK_ALLOCATOR_HPP_INCLUDED -#define BOOST_DETAIL_QUICK_ALLOCATOR_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// -// detail/quick_allocator.hpp -// -// Copyright (c) 2003 David Abrahams -// Copyright (c) 2003 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// - -#include - -#endif // #ifndef BOOST_DETAIL_QUICK_ALLOCATOR_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/reference_content.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/reference_content.hpp deleted file mode 100644 index daf56a8b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/reference_content.hpp +++ /dev/null @@ -1,141 +0,0 @@ -//----------------------------------------------------------------------------- -// boost detail/reference_content.hpp header file -// See http://www.boost.org for updates, documentation, and revision history. -//----------------------------------------------------------------------------- -// -// Copyright (c) 2003 -// Eric Friedman -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_DETAIL_REFERENCE_CONTENT_HPP -#define BOOST_DETAIL_REFERENCE_CONTENT_HPP - -#include "boost/config.hpp" - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -# include "boost/mpl/bool.hpp" -# include "boost/type_traits/has_nothrow_copy.hpp" -#else -# include "boost/mpl/if.hpp" -# include "boost/type_traits/is_reference.hpp" -#endif - -#include "boost/mpl/void.hpp" - -namespace boost { - -namespace detail { - -/////////////////////////////////////////////////////////////////////////////// -// (detail) class template reference_content -// -// Non-Assignable wrapper for references. -// -template -class reference_content -{ -private: // representation - - RefT content_; - -public: // structors - - ~reference_content() - { - } - - reference_content(RefT r) - : content_( r ) - { - } - - reference_content(const reference_content& operand) - : content_( operand.content_ ) - { - } - -private: // non-Assignable - - reference_content& operator=(const reference_content&); - -public: // queries - - RefT get() const - { - return content_; - } - -}; - -/////////////////////////////////////////////////////////////////////////////// -// (detail) metafunction make_reference_content -// -// Wraps with reference_content if specified type is reference. -// - -template struct make_reference_content; - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - -template -struct make_reference_content -{ - typedef T type; -}; - -template -struct make_reference_content< T& > -{ - typedef reference_content type; -}; - -#else // defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - -template -struct make_reference_content - : mpl::if_< - is_reference - , reference_content - , T - > -{ -}; - -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION workaround - -template <> -struct make_reference_content< mpl::void_ > -{ - template - struct apply - : make_reference_content - { - }; - - typedef mpl::void_ type; -}; - -} // namespace detail - -/////////////////////////////////////////////////////////////////////////////// -// reference_content type traits specializations -// - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - -template -struct has_nothrow_copy< - ::boost::detail::reference_content< T& > - > - : mpl::true_ -{ -}; - -#endif // !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - -} // namespace boost - -#endif // BOOST_DETAIL_REFERENCE_CONTENT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/scoped_enum_emulation.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/scoped_enum_emulation.hpp deleted file mode 100644 index d266e0e3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/scoped_enum_emulation.hpp +++ /dev/null @@ -1,337 +0,0 @@ -// scoped_enum_emulation.hpp ---------------------------------------------------------// - -// Copyright Beman Dawes, 2009 -// Copyright (C) 2011-2012 Vicente J. Botet Escriba -// Copyright (C) 2012 Anthony Williams - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -/* -[section:scoped_enums Scoped Enums] - -Generates C++0x scoped enums if the feature is present, otherwise emulates C++0x -scoped enums with C++03 namespaces and enums. The Boost.Config BOOST_NO_CXX11_SCOPED_ENUMS -macro is used to detect feature support. - -See http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2347.pdf for a -description of the scoped enum feature. Note that the committee changed the name -from strongly typed enum to scoped enum. - -Some of the enumerations defined in the standard library are scoped enums. - - enum class future_errc - { - broken_promise, - future_already_retrieved, - promise_already_satisfied, - no_state - }; - -On compilers that don't support them, the library provides two emulations: - -[heading Strict] - -* Able to specify the underlying type. -* explicit conversion to/from underlying type. -* The wrapper is not a C++03 enum type. - -The user can declare declare these types as - - BOOST_SCOPED_ENUM_DECLARE_BEGIN(future_errc) - { - broken_promise, - future_already_retrieved, - promise_already_satisfied, - no_state - } - BOOST_SCOPED_ENUM_DECLARE_END(future_errc) - -These macros allows to use 'future_errc' in almost all the cases as an scoped enum. - - future_errc err = future_errc::no_state; - -There are however some limitations: - -* The type is not a C++ enum, so 'is_enum' will be false_type. -* The emulated scoped enum can not be used in switch nor in template arguments. For these cases the user needs to use some macros. - -Instead of - - switch (ev) - { - case future_errc::broken_promise: - // ... - -use - - switch (boost::native_value(ev)) - { - case future_errc::broken_promise: - -And instead of - - #ifdef BOOST_NO_CXX11_SCOPED_ENUMS - template <> - struct BOOST_SYMBOL_VISIBLE is_error_code_enum : public true_type { }; - #endif - -use - - #ifdef BOOST_NO_CXX11_SCOPED_ENUMS - template <> - struct BOOST_SYMBOL_VISIBLE is_error_code_enum : public true_type { }; - #endif - - -Sample usage: - - BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(algae, char) { green, red, cyan }; BOOST_SCOPED_ENUM_DECLARE_END(algae) - ... - algae sample( algae::red ); - void foo( algae color ); - ... - sample = algae::green; - foo( algae::cyan ); - - Light - Caution: only the syntax is emulated; the semantics are not emulated and - the syntax emulation doesn't include being able to specify the underlying - representation type. - - The literal scoped emulation is via struct rather than namespace to allow use within classes. - Thanks to Andrey Semashev for pointing that out. - However the type is an real C++03 enum and so convertible implicitly to an int. - - Sample usage: - - BOOST_SCOPED_ENUM_START(algae) { green, red, cyan }; BOOST_SCOPED_ENUM_END - ... - BOOST_SCOPED_ENUM(algae) sample( algae::red ); - void foo( BOOST_SCOPED_ENUM(algae) color ); - ... - sample = algae::green; - foo( algae::cyan ); - - Helpful comments and suggestions were also made by Kjell Elster, Phil Endecott, - Joel Falcou, Mathias Gaunard, Felipe Magno de Almeida, Matt Calabrese, Vicente - Botet, and Daniel James. - -[endsect] -*/ - - -#ifndef BOOST_SCOPED_ENUM_EMULATION_HPP -#define BOOST_SCOPED_ENUM_EMULATION_HPP - -#include -#include - -namespace boost -{ - -#ifdef BOOST_NO_CXX11_SCOPED_ENUMS - /** - * Meta-function to get the underlying type of a scoped enum. - * - * Requires EnumType must be an enum type or the emulation of a scoped enum - */ - template - struct underlying_type - { - /** - * The member typedef type names the underlying type of EnumType. It is EnumType::underlying_type when the EnumType is an emulated scoped enum, - * std::underlying_type::type when the standard library std::underlying_type is provided. - * - * The user will need to specialize it when the compiler supports scoped enums but don't provides std::underlying_type. - */ - typedef typename EnumType::underlying_type type; - }; - - /** - * Meta-function to get the native enum type associated to an enum class or its emulation. - */ - template - struct native_type - { - /** - * The member typedef type names the native enum type associated to the scoped enum, - * which is it self if the compiler supports scoped enums or EnumType::enum_type if it is an emulated scoped enum. - */ - typedef typename EnumType::enum_type type; - }; - - /** - * Casts a scoped enum to its underlying type. - * - * This function is useful when working with scoped enum classes, which doens't implicitly convert to the underlying type. - * @param v A scoped enum. - * @returns The underlying type. - * @throws No-throws. - */ - template - UnderlyingType underlying_cast(EnumType v) - { - return v.get_underlying_value_(); - } - - /** - * Casts a scoped enum to its native enum type. - * - * This function is useful to make programs portable when the scoped enum emulation can not be use where native enums can. - * - * EnumType the scoped enum type - * - * @param v A scoped enum. - * @returns The native enum value. - * @throws No-throws. - */ - template - inline - typename EnumType::enum_type native_value(EnumType e) - { - return e.native_value_(); - } - -#else // BOOST_NO_CXX11_SCOPED_ENUMS - - template - struct underlying_type - { - //typedef typename std::underlying_type::type type; - }; - - template - struct native_type - { - typedef EnumType type; - }; - - template - UnderlyingType underlying_cast(EnumType v) - { - return static_cast(v); - } - - template - inline - EnumType native_value(EnumType e) - { - return e; - } - -#endif -} - - -#ifdef BOOST_NO_CXX11_SCOPED_ENUMS - -#ifndef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS - -#define BOOST_SCOPED_ENUM_UT_DECLARE_CONVERSION_OPERATOR \ - explicit operator underlying_type() const { return get_underlying_value_(); } - -#else - -#define BOOST_SCOPED_ENUM_UT_DECLARE_CONVERSION_OPERATOR - -#endif - -/** - * Start a declaration of a scoped enum. - * - * @param EnumType The new scoped enum. - * @param UnderlyingType The underlying type. - */ -#define BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(EnumType, UnderlyingType) \ - struct EnumType { \ - typedef UnderlyingType underlying_type; \ - EnumType() BOOST_NOEXCEPT {} \ - explicit EnumType(underlying_type v) : v_(v) {} \ - underlying_type get_underlying_value_() const { return v_; } \ - BOOST_SCOPED_ENUM_UT_DECLARE_CONVERSION_OPERATOR \ - private: \ - underlying_type v_; \ - typedef EnumType self_type; \ - public: \ - enum enum_type - -#define BOOST_SCOPED_ENUM_DECLARE_END2() \ - enum_type get_native_value_() const BOOST_NOEXCEPT { return enum_type(v_); } \ - operator enum_type() const BOOST_NOEXCEPT { return get_native_value_(); } \ - friend bool operator ==(self_type lhs, self_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)==enum_type(rhs.v_); } \ - friend bool operator ==(self_type lhs, enum_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)==rhs; } \ - friend bool operator ==(enum_type lhs, self_type rhs) BOOST_NOEXCEPT { return lhs==enum_type(rhs.v_); } \ - friend bool operator !=(self_type lhs, self_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)!=enum_type(rhs.v_); } \ - friend bool operator !=(self_type lhs, enum_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)!=rhs; } \ - friend bool operator !=(enum_type lhs, self_type rhs) BOOST_NOEXCEPT { return lhs!=enum_type(rhs.v_); } \ - friend bool operator <(self_type lhs, self_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)(self_type lhs, self_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)>enum_type(rhs.v_); } \ - friend bool operator >(self_type lhs, enum_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)>rhs; } \ - friend bool operator >(enum_type lhs, self_type rhs) BOOST_NOEXCEPT { return lhs>enum_type(rhs.v_); } \ - friend bool operator >=(self_type lhs, self_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)>=enum_type(rhs.v_); } \ - friend bool operator >=(self_type lhs, enum_type rhs) BOOST_NOEXCEPT { return enum_type(lhs.v_)>=rhs; } \ - friend bool operator >=(enum_type lhs, self_type rhs) BOOST_NOEXCEPT { return lhs>=enum_type(rhs.v_); } \ - }; - -#define BOOST_SCOPED_ENUM_DECLARE_END(EnumType) \ - ; \ - EnumType(enum_type v) BOOST_NOEXCEPT : v_(v) {} \ - BOOST_SCOPED_ENUM_DECLARE_END2() - -/** - * Starts a declaration of a scoped enum with the default int underlying type. - * - * @param EnumType The new scoped enum. - */ -#define BOOST_SCOPED_ENUM_DECLARE_BEGIN(EnumType) \ - BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(EnumType,int) - -/** - * Name of the native enum type. - * - * @param NT The new scoped enum. - */ -#define BOOST_SCOPED_ENUM_NATIVE(EnumType) EnumType::enum_type -/** - * Forward declares an scoped enum. - * - * @param NT The scoped enum. - */ -#define BOOST_SCOPED_ENUM_FORWARD_DECLARE(EnumType) struct EnumType - -#else // BOOST_NO_CXX11_SCOPED_ENUMS - -#define BOOST_SCOPED_ENUM_UT_DECLARE_BEGIN(EnumType,UnderlyingType) enum class EnumType:UnderlyingType -#define BOOST_SCOPED_ENUM_DECLARE_BEGIN(EnumType) enum class EnumType -#define BOOST_SCOPED_ENUM_DECLARE_END2() -#define BOOST_SCOPED_ENUM_DECLARE_END(EnumType) ; - -#define BOOST_SCOPED_ENUM_NATIVE(EnumType) EnumType -#define BOOST_SCOPED_ENUM_FORWARD_DECLARE(EnumType) enum class EnumType - -#endif // BOOST_NO_CXX11_SCOPED_ENUMS - -#define BOOST_SCOPED_ENUM_START(name) BOOST_SCOPED_ENUM_DECLARE_BEGIN(name) -#define BOOST_SCOPED_ENUM_END BOOST_SCOPED_ENUM_DECLARE_END2() -#define BOOST_SCOPED_ENUM(name) BOOST_SCOPED_ENUM_NATIVE(name) - -//#ifdef BOOST_NO_CXX11_SCOPED_ENUMS -// -//# define BOOST_SCOPED_ENUM_START(name) struct name { enum enum_type -//# define BOOST_SCOPED_ENUM_END }; -//# define BOOST_SCOPED_ENUM(name) name::enum_type -// -//#else -// -//# define BOOST_SCOPED_ENUM_START(name) enum class name -//# define BOOST_SCOPED_ENUM_END -//# define BOOST_SCOPED_ENUM(name) name -// -//#endif -#endif // BOOST_SCOPED_ENUM_EMULATION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/select_type.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/select_type.hpp deleted file mode 100644 index c13946f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/select_type.hpp +++ /dev/null @@ -1,36 +0,0 @@ -// (C) Copyright David Abrahams 2001. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org for most recent version including documentation. - -// Revision History -// 09 Feb 01 Applied John Maddock's Borland patch Moving -// specialization to unspecialized template (David Abrahams) -// 06 Feb 01 Created (David Abrahams) - -#ifndef SELECT_TYPE_DWA20010206_HPP -# define SELECT_TYPE_DWA20010206_HPP - -namespace boost { namespace detail { - - // Template class if_true -- select among 2 types based on a bool constant expression - // Usage: - // typename if_true<(bool_const_expression)>::template then::type - - // HP aCC cannot deal with missing names for template value parameters - template struct if_true - { - template - struct then { typedef T type; }; - }; - - template <> - struct if_true - { - template - struct then { typedef F type; }; - }; -}} -#endif // SELECT_TYPE_DWA20010206_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/sp_typeinfo.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/sp_typeinfo.hpp deleted file mode 100644 index 43fae78e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/sp_typeinfo.hpp +++ /dev/null @@ -1,135 +0,0 @@ -#ifndef BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED -#define BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED - -// MS compatible compilers support #pragma once - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// detail/sp_typeinfo.hpp -// -// Copyright 2007 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#include - -#if defined( BOOST_NO_TYPEID ) - -#include -#include - -namespace boost -{ - -namespace detail -{ - -class sp_typeinfo -{ -private: - - sp_typeinfo( sp_typeinfo const& ); - sp_typeinfo& operator=( sp_typeinfo const& ); - - char const * name_; - -public: - - explicit sp_typeinfo( char const * name ): name_( name ) - { - } - - bool operator==( sp_typeinfo const& rhs ) const - { - return this == &rhs; - } - - bool operator!=( sp_typeinfo const& rhs ) const - { - return this != &rhs; - } - - bool before( sp_typeinfo const& rhs ) const - { - return std::less< sp_typeinfo const* >()( this, &rhs ); - } - - char const* name() const - { - return name_; - } -}; - -template struct sp_typeid_ -{ - static sp_typeinfo ti_; - - static char const * name() - { - return BOOST_CURRENT_FUNCTION; - } -}; - -#if defined(__SUNPRO_CC) -// see #4199, the Sun Studio compiler gets confused about static initialization -// constructor arguments. But an assignment works just fine. -template sp_typeinfo sp_typeid_< T >::ti_ = sp_typeid_< T >::name(); -#else -template sp_typeinfo sp_typeid_< T >::ti_(sp_typeid_< T >::name()); -#endif - -template struct sp_typeid_< T & >: sp_typeid_< T > -{ -}; - -template struct sp_typeid_< T const >: sp_typeid_< T > -{ -}; - -template struct sp_typeid_< T volatile >: sp_typeid_< T > -{ -}; - -template struct sp_typeid_< T const volatile >: sp_typeid_< T > -{ -}; - -} // namespace detail - -} // namespace boost - -#define BOOST_SP_TYPEID(T) (boost::detail::sp_typeid_::ti_) - -#else - -#include - -namespace boost -{ - -namespace detail -{ - -#if defined( BOOST_NO_STD_TYPEINFO ) - -typedef ::type_info sp_typeinfo; - -#else - -typedef std::type_info sp_typeinfo; - -#endif - -} // namespace detail - -} // namespace boost - -#define BOOST_SP_TYPEID(T) typeid(T) - -#endif - -#endif // #ifndef BOOST_DETAIL_SP_TYPEINFO_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.hpp deleted file mode 100644 index b777ff93..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.hpp +++ /dev/null @@ -1,190 +0,0 @@ -// Copyright (c) 2001 Ronald Garcia, Indiana University (garcia@osl.iu.edu) -// Andrew Lumsdaine, Indiana University (lums@osl.iu.edu). -// Distributed under the Boost Software License, Version 1.0. (See accompany- -// ing file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_UTF8_CODECVT_FACET_HPP -#define BOOST_UTF8_CODECVT_FACET_HPP - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// utf8_codecvt_facet.hpp - -// This header defines class utf8_codecvt_facet, derived fro -// std::codecvt, which can be used to convert utf8 data in -// files into wchar_t strings in the application. -// -// The header is NOT STANDALONE, and is not to be included by the USER. -// There are at least two libraries which want to use this functionality, and -// we want to avoid code duplication. It would be possible to create utf8 -// library, but: -// - this requires review process first -// - in the case, when linking the a library which uses utf8 -// (say 'program_options'), user should also link to the utf8 library. -// This seems inconvenient, and asking a user to link to an unrevieved -// library is strange. -// Until the above points are fixed, a library which wants to use utf8 must: -// - include this header from one of it's headers or sources -// - include the corresponding .cpp file from one of the sources -// - before including either file, the library must define -// - BOOST_UTF8_BEGIN_NAMESPACE to the namespace declaration that must be used -// - BOOST_UTF8_END_NAMESPACE to the code to close the previous namespace -// - declaration. -// - BOOST_UTF8_DECL -- to the code which must be used for all 'exportable' -// symbols. -// -// For example, program_options library might contain: -// #define BOOST_UTF8_BEGIN_NAMESPACE -// namespace boost { namespace program_options { -// #define BOOST_UTF8_END_NAMESPACE }} -// #define BOOST_UTF8_DECL BOOST_PROGRAM_OPTIONS_DECL -// #include "../../detail/utf8/utf8_codecvt.cpp" -// -// Essentially, each library will have its own copy of utf8 code, in -// different namespaces. - -// Note:(Robert Ramey). I have made the following alterations in the original -// code. -// a) Rendered utf8_codecvt with using templates -// b) Move longer functions outside class definition to prevent inlining -// and make code smaller -// c) added on a derived class to permit translation to/from current -// locale to utf8 - -// See http://www.boost.org for updates, documentation, and revision history. - -// archives stored as text - note these ar templated on the basic -// stream templates to accommodate wide (and other?) kind of characters -// -// note the fact that on libraries without wide characters, ostream is -// is not a specialization of basic_ostream which in fact is not defined -// in such cases. So we can't use basic_ostream but rather -// use two template parameters -// -// utf8_codecvt_facet -// This is an implementation of a std::codecvt facet for translating -// from UTF-8 externally to UCS-4. Note that this is not tied to -// any specific types in order to allow customization on platforms -// where wchar_t is not big enough. -// -// NOTES: The current implementation jumps through some unpleasant hoops in -// order to deal with signed character types. As a std::codecvt_base::result, -// it is necessary for the ExternType to be convertible to unsigned char. -// I chose not to tie the extern_type explicitly to char. But if any combination -// of types other than is used, then std::codecvt must be -// specialized on those types for this to work. - -#include -#include // for mbstate_t -#include // for std::size_t - -#include -#include - -#if defined(BOOST_NO_STDC_NAMESPACE) -namespace std { - using ::mbstate_t; - using ::size_t; -} -#endif - -#if !defined(__MSL_CPP__) && !defined(__LIBCOMO__) - #define BOOST_CODECVT_DO_LENGTH_CONST const -#else - #define BOOST_CODECVT_DO_LENGTH_CONST -#endif - -// maximum lenght of a multibyte string -#define MB_LENGTH_MAX 8 - -BOOST_UTF8_BEGIN_NAMESPACE - -struct BOOST_UTF8_DECL utf8_codecvt_facet : - public std::codecvt -{ -public: - explicit utf8_codecvt_facet(std::size_t no_locale_manage=0) - : std::codecvt(no_locale_manage) - {} -protected: - virtual std::codecvt_base::result do_in( - std::mbstate_t& state, - const char * from, - const char * from_end, - const char * & from_next, - wchar_t * to, - wchar_t * to_end, - wchar_t*& to_next - ) const; - - virtual std::codecvt_base::result do_out( - std::mbstate_t & state, const wchar_t * from, - const wchar_t * from_end, const wchar_t* & from_next, - char * to, char * to_end, char * & to_next - ) const; - - bool invalid_continuing_octet(unsigned char octet_1) const { - return (octet_1 < 0x80|| 0xbf< octet_1); - } - - bool invalid_leading_octet(unsigned char octet_1) const { - return (0x7f < octet_1 && octet_1 < 0xc0) || - (octet_1 > 0xfd); - } - - // continuing octets = octets except for the leading octet - static unsigned int get_cont_octet_count(unsigned char lead_octet) { - return get_octet_count(lead_octet) - 1; - } - - static unsigned int get_octet_count(unsigned char lead_octet); - - // How many "continuing octets" will be needed for this word - // == total octets - 1. - int get_cont_octet_out_count(wchar_t word) const ; - - virtual bool do_always_noconv() const throw() { return false; } - - // UTF-8 isn't really stateful since we rewind on partial conversions - virtual std::codecvt_base::result do_unshift( - std::mbstate_t&, - char * from, - char * /*to*/, - char * & next - ) const - { - next = from; - return ok; - } - - virtual int do_encoding() const throw() { - const int variable_byte_external_encoding=0; - return variable_byte_external_encoding; - } - - // How many char objects can I process to get <= max_limit - // wchar_t objects? - virtual int do_length( - BOOST_CODECVT_DO_LENGTH_CONST std::mbstate_t &, - const char * from, - const char * from_end, - std::size_t max_limit -#if BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) - ) const throw(); -#else - ) const; -#endif - - // Largest possible value do_length(state,from,from_end,1) could return. - virtual int do_max_length() const throw () { - return 6; // largest UTF-8 encoding of a UCS-4 character - } -}; - -BOOST_UTF8_END_NAMESPACE - -#endif // BOOST_UTF8_CODECVT_FACET_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.ipp b/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.ipp deleted file mode 100644 index 064fdaf5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/utf8_codecvt_facet.ipp +++ /dev/null @@ -1,285 +0,0 @@ -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// utf8_codecvt_facet.ipp - -// Copyright (c) 2001 Ronald Garcia, Indiana University (garcia@osl.iu.edu) -// Andrew Lumsdaine, Indiana University (lums@osl.iu.edu). -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Please see the comments in to -// learn how this file should be used. - -#include - -#include // for multi-byte converson routines -#include - -#include -#include - -// If we don't have wstring, then Unicode support -// is not available anyway, so we don't need to even -// compiler this file. This also fixes the problem -// with mingw, which can compile this file, but will -// generate link error when building DLL. -#ifndef BOOST_NO_STD_WSTRING - -BOOST_UTF8_BEGIN_NAMESPACE - -/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 -// implementation for wchar_t - -// Translate incoming UTF-8 into UCS-4 -std::codecvt_base::result utf8_codecvt_facet::do_in( - std::mbstate_t& /*state*/, - const char * from, - const char * from_end, - const char * & from_next, - wchar_t * to, - wchar_t * to_end, - wchar_t * & to_next -) const { - // Basic algorithm: The first octet determines how many - // octets total make up the UCS-4 character. The remaining - // "continuing octets" all begin with "10". To convert, subtract - // the amount that specifies the number of octets from the first - // octet. Subtract 0x80 (1000 0000) from each continuing octet, - // then mash the whole lot together. Note that each continuing - // octet only uses 6 bits as unique values, so only shift by - // multiples of 6 to combine. - while (from != from_end && to != to_end) { - - // Error checking on the first octet - if (invalid_leading_octet(*from)){ - from_next = from; - to_next = to; - return std::codecvt_base::error; - } - - // The first octet is adjusted by a value dependent upon - // the number of "continuing octets" encoding the character - const int cont_octet_count = get_cont_octet_count(*from); - const wchar_t octet1_modifier_table[] = { - 0x00, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc - }; - - // The unsigned char conversion is necessary in case char is - // signed (I learned this the hard way) - wchar_t ucs_result = - (unsigned char)(*from++) - octet1_modifier_table[cont_octet_count]; - - // Invariants : - // 1) At the start of the loop, 'i' continuing characters have been - // processed - // 2) *from points to the next continuing character to be processed. - int i = 0; - while(i != cont_octet_count && from != from_end) { - - // Error checking on continuing characters - if (invalid_continuing_octet(*from)) { - from_next = from; - to_next = to; - return std::codecvt_base::error; - } - - ucs_result *= (1 << 6); - - // each continuing character has an extra (10xxxxxx)b attached to - // it that must be removed. - ucs_result += (unsigned char)(*from++) - 0x80; - ++i; - } - - // If the buffer ends with an incomplete unicode character... - if (from == from_end && i != cont_octet_count) { - // rewind "from" to before the current character translation - from_next = from - (i+1); - to_next = to; - return std::codecvt_base::partial; - } - *to++ = ucs_result; - } - from_next = from; - to_next = to; - - // Were we done converting or did we run out of destination space? - if(from == from_end) return std::codecvt_base::ok; - else return std::codecvt_base::partial; -} - -std::codecvt_base::result utf8_codecvt_facet::do_out( - std::mbstate_t& /*state*/, - const wchar_t * from, - const wchar_t * from_end, - const wchar_t * & from_next, - char * to, - char * to_end, - char * & to_next -) const -{ - // RG - consider merging this table with the other one - const wchar_t octet1_modifier_table[] = { - 0x00, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc - }; - - wchar_t max_wchar = (std::numeric_limits::max)(); - while (from != from_end && to != to_end) { - - // Check for invalid UCS-4 character - if (*from > max_wchar) { - from_next = from; - to_next = to; - return std::codecvt_base::error; - } - - int cont_octet_count = get_cont_octet_out_count(*from); - - // RG - comment this formula better - int shift_exponent = (cont_octet_count) * 6; - - // Process the first character - *to++ = static_cast(octet1_modifier_table[cont_octet_count] + - (unsigned char)(*from / (1 << shift_exponent))); - - // Process the continuation characters - // Invariants: At the start of the loop: - // 1) 'i' continuing octets have been generated - // 2) '*to' points to the next location to place an octet - // 3) shift_exponent is 6 more than needed for the next octet - int i = 0; - while (i != cont_octet_count && to != to_end) { - shift_exponent -= 6; - *to++ = static_cast(0x80 + ((*from / (1 << shift_exponent)) % (1 << 6))); - ++i; - } - // If we filled up the out buffer before encoding the character - if(to == to_end && i != cont_octet_count) { - from_next = from; - to_next = to - (i+1); - return std::codecvt_base::partial; - } - ++from; - } - from_next = from; - to_next = to; - // Were we done or did we run out of destination space - if(from == from_end) return std::codecvt_base::ok; - else return std::codecvt_base::partial; -} - -// How many char objects can I process to get <= max_limit -// wchar_t objects? -int utf8_codecvt_facet::do_length( - BOOST_CODECVT_DO_LENGTH_CONST std::mbstate_t &, - const char * from, - const char * from_end, - std::size_t max_limit -#if BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) -) const throw() -#else -) const -#endif -{ - // RG - this code is confusing! I need a better way to express it. - // and test cases. - - // Invariants: - // 1) last_octet_count has the size of the last measured character - // 2) char_count holds the number of characters shown to fit - // within the bounds so far (no greater than max_limit) - // 3) from_next points to the octet 'last_octet_count' before the - // last measured character. - int last_octet_count=0; - std::size_t char_count = 0; - const char* from_next = from; - // Use "<" because the buffer may represent incomplete characters - while (from_next+last_octet_count <= from_end && char_count <= max_limit) { - from_next += last_octet_count; - last_octet_count = (get_octet_count(*from_next)); - ++char_count; - } - return static_cast(from_next-from_end); -} - -unsigned int utf8_codecvt_facet::get_octet_count( - unsigned char lead_octet -){ - // if the 0-bit (MSB) is 0, then 1 character - if (lead_octet <= 0x7f) return 1; - - // Otherwise the count number of consecutive 1 bits starting at MSB -// assert(0xc0 <= lead_octet && lead_octet <= 0xfd); - - if (0xc0 <= lead_octet && lead_octet <= 0xdf) return 2; - else if (0xe0 <= lead_octet && lead_octet <= 0xef) return 3; - else if (0xf0 <= lead_octet && lead_octet <= 0xf7) return 4; - else if (0xf8 <= lead_octet && lead_octet <= 0xfb) return 5; - else return 6; -} -BOOST_UTF8_END_NAMESPACE - -namespace { -template -int get_cont_octet_out_count_impl(wchar_t word){ - if (word < 0x80) { - return 0; - } - if (word < 0x800) { - return 1; - } - return 2; -} - -template<> -int get_cont_octet_out_count_impl<4>(wchar_t word){ - if (word < 0x80) { - return 0; - } - if (word < 0x800) { - return 1; - } - - // Note that the following code will generate warnings on some platforms - // where wchar_t is defined as UCS2. The warnings are superfluous as the - // specialization is never instantitiated with such compilers, but this - // can cause problems if warnings are being treated as errors, so we guard - // against that. Including as we do - // should be enough to get WCHAR_MAX defined. -#if !defined(WCHAR_MAX) -# error WCHAR_MAX not defined! -#endif - // cope with VC++ 7.1 or earlier having invalid WCHAR_MAX -#if defined(_MSC_VER) && _MSC_VER <= 1310 // 7.1 or earlier - return 2; -#elif WCHAR_MAX > 0x10000 - - if (word < 0x10000) { - return 2; - } - if (word < 0x200000) { - return 3; - } - if (word < 0x4000000) { - return 4; - } - return 5; - -#else - return 2; -#endif -} - -} // namespace anonymous - -BOOST_UTF8_BEGIN_NAMESPACE -// How many "continuing octets" will be needed for this word -// == total octets - 1. -int utf8_codecvt_facet::get_cont_octet_out_count( - wchar_t word -) const { - return get_cont_octet_out_count_impl(word); -} -BOOST_UTF8_END_NAMESPACE - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/GetLastError.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/GetLastError.hpp deleted file mode 100644 index 6e9e2d99..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/GetLastError.hpp +++ /dev/null @@ -1,31 +0,0 @@ -// GetLastError.hpp --------------------------------------------------------------// - -// Copyright 2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -#ifndef BOOST_DETAIL_WINAPI_GETLASTERROR_HPP -#define BOOST_DETAIL_WINAPI_GETLASTERROR_HPP - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace detail { -namespace winapi { -#if defined( BOOST_USE_WINDOWS_H ) - using ::GetLastError; -#else - extern "C" __declspec(dllimport) DWORD_ WINAPI - GetLastError(); -#endif -} -} -} - -#endif // BOOST_DETAIL_WINAPI_GETLASTERROR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/basic_types.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/basic_types.hpp deleted file mode 100644 index e9ca3700..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/basic_types.hpp +++ /dev/null @@ -1,116 +0,0 @@ -// basic_types.hpp --------------------------------------------------------------// - -// Copyright 2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -#ifndef BOOST_DETAIL_WINAPI_BASIC_TYPES_HPP -#define BOOST_DETAIL_WINAPI_BASIC_TYPES_HPP - -#include -#include -#include - -#if defined( BOOST_USE_WINDOWS_H ) -# include -#elif defined( WIN32 ) || defined( _WIN32 ) || defined( __WIN32__ ) || defined(__CYGWIN__) -# include -// @FIXME Which condition must be tested -# ifdef UNDER_CE -# ifndef WINAPI -# ifndef _WIN32_WCE_EMULATION -# define WINAPI __cdecl // Note this doesn't match the desktop definition -# else -# define WINAPI __stdcall -# endif -# endif -# else -# ifndef WINAPI -# define WINAPI __stdcall -# endif -# endif -#else -# error "Win32 functions not available" -#endif - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace detail { -namespace winapi { -#if defined( BOOST_USE_WINDOWS_H ) - typedef ::BOOL BOOL_; - typedef ::WORD WORD_; - typedef ::DWORD DWORD_; - typedef ::HANDLE HANDLE_; - typedef ::LONG LONG_; - typedef ::LONGLONG LONGLONG_; - typedef ::ULONG_PTR ULONG_PTR_; - typedef ::LARGE_INTEGER LARGE_INTEGER_; - typedef ::PLARGE_INTEGER PLARGE_INTEGER_; - typedef ::PVOID PVOID_; - typedef ::LPVOID LPVOID_; - typedef ::CHAR CHAR_; - typedef ::LPSTR LPSTR_; - typedef ::LPCSTR LPCSTR_; - typedef ::WCHAR WCHAR_; - typedef ::LPWSTR LPWSTR_; - typedef ::LPCWSTR LPCWSTR_; -#else -extern "C" { - typedef int BOOL_; - typedef unsigned short WORD_; - typedef unsigned long DWORD_; - typedef void* HANDLE_; - - typedef long LONG_; - -// @FIXME Which condition must be tested -//~ #if !defined(_M_IX86) -//~ #if defined(BOOST_NO_INT64_T) - //~ typedef double LONGLONG_; -//~ #else - //~ typedef __int64 LONGLONG_; -//~ #endif -//~ #else - //~ typedef double LONGLONG_; -//~ #endif - typedef boost::int64_t LONGLONG_; - -// @FIXME Which condition must be tested -# ifdef _WIN64 -#if defined(__CYGWIN__) - typedef unsigned long ULONG_PTR_; -#else - typedef unsigned __int64 ULONG_PTR_; -#endif -# else - typedef unsigned long ULONG_PTR_; -# endif - - typedef struct _LARGE_INTEGER { - LONGLONG_ QuadPart; - } LARGE_INTEGER_; - typedef LARGE_INTEGER_ *PLARGE_INTEGER_; - - typedef void *PVOID_; - typedef void *LPVOID_; - typedef const void *LPCVOID_; - - typedef char CHAR_; - typedef CHAR_ *LPSTR_; - typedef const CHAR_ *LPCSTR_; - - typedef wchar_t WCHAR_; - typedef WCHAR_ *LPWSTR_; - typedef const WCHAR_ *LPCWSTR_; -} -#endif -} -} -} -#endif // BOOST_DETAIL_WINAPI_TIME_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/time.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/time.hpp deleted file mode 100644 index b3e4c441..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/time.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// time.hpp --------------------------------------------------------------// - -// Copyright 2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -#ifndef BOOST_DETAIL_WINAPI_TIME_HPP -#define BOOST_DETAIL_WINAPI_TIME_HPP - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost { -namespace detail { -namespace winapi { -#if defined( BOOST_USE_WINDOWS_H ) - typedef FILETIME FILETIME_; - typedef PFILETIME PFILETIME_; - typedef LPFILETIME LPFILETIME_; - - typedef SYSTEMTIME SYSTEMTIME_; - typedef SYSTEMTIME* PSYSTEMTIME_; - - #ifdef BOOST_HAS_GETSYSTEMTIMEASFILETIME // Windows CE does not define GetSystemTimeAsFileTime - using ::GetSystemTimeAsFileTime; - #endif - using ::FileTimeToLocalFileTime; - using ::GetSystemTime; - using ::SystemTimeToFileTime; - using ::GetTickCount; - -#else -extern "C" { - typedef struct _FILETIME { - DWORD_ dwLowDateTime; - DWORD_ dwHighDateTime; - } FILETIME_, *PFILETIME_, *LPFILETIME_; - - typedef struct _SYSTEMTIME { - WORD_ wYear; - WORD_ wMonth; - WORD_ wDayOfWeek; - WORD_ wDay; - WORD_ wHour; - WORD_ wMinute; - WORD_ wSecond; - WORD_ wMilliseconds; - } SYSTEMTIME_, *PSYSTEMTIME_; - - #ifdef BOOST_HAS_GETSYSTEMTIMEASFILETIME // Windows CE does not define GetSystemTimeAsFileTime - __declspec(dllimport) void WINAPI - GetSystemTimeAsFileTime(FILETIME_* lpFileTime); - #endif - __declspec(dllimport) int WINAPI - FileTimeToLocalFileTime(const FILETIME_* lpFileTime, - FILETIME_* lpLocalFileTime); - __declspec(dllimport) void WINAPI - GetSystemTime(SYSTEMTIME_* lpSystemTime); - __declspec(dllimport) int WINAPI - SystemTimeToFileTime(const SYSTEMTIME_* lpSystemTime, - FILETIME_* lpFileTime); - __declspec(dllimport) DWORD_ WINAPI - GetTickCount(); -} -#endif - -#ifndef BOOST_HAS_GETSYSTEMTIMEASFILETIME -inline void WINAPI GetSystemTimeAsFileTime(FILETIME_* lpFileTime) -{ - SYSTEMTIME_ st; - GetSystemTime(&st); - SystemTimeToFileTime(&st, lpFileTime); -} -#endif - -} -} -} - -#endif // BOOST_DETAIL_WINAPI_TIME_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/timers.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/timers.hpp deleted file mode 100644 index 04c6dfbc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/winapi/timers.hpp +++ /dev/null @@ -1,44 +0,0 @@ -// timers.hpp --------------------------------------------------------------// - -// Copyright 2010 Vicente J. Botet Escriba - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - - -#ifndef BOOST_DETAIL_WINAPI_TIMERS_HPP -#define BOOST_DETAIL_WINAPI_TIMERS_HPP - -#include - -#ifdef BOOST_HAS_PRAGMA_ONCE -#pragma once -#endif - -namespace boost -{ -namespace detail -{ -namespace winapi -{ -#if defined( BOOST_USE_WINDOWS_H ) - using ::QueryPerformanceCounter; - using ::QueryPerformanceFrequency; -#else -extern "C" { - __declspec(dllimport) BOOL_ WINAPI - QueryPerformanceCounter( - LARGE_INTEGER_ *lpPerformanceCount - ); - - __declspec(dllimport) BOOL_ WINAPI - QueryPerformanceFrequency( - LARGE_INTEGER_ *lpFrequency - ); -} -#endif -} -} -} - -#endif // BOOST_DETAIL_WINAPI_TIMERS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/detail/workaround.hpp b/third_party/ycmd/cpp/BoostParts/boost/detail/workaround.hpp deleted file mode 100644 index 40b3423b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/detail/workaround.hpp +++ /dev/null @@ -1,267 +0,0 @@ -// Copyright David Abrahams 2002. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -#ifndef WORKAROUND_DWA2002126_HPP -# define WORKAROUND_DWA2002126_HPP - -// Compiler/library version workaround macro -// -// Usage: -// -// #if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -// // workaround for eVC4 and VC6 -// ... // workaround code here -// #endif -// -// When BOOST_STRICT_CONFIG is defined, expands to 0. Otherwise, the -// first argument must be undefined or expand to a numeric -// value. The above expands to: -// -// (BOOST_MSVC) != 0 && (BOOST_MSVC) < 1300 -// -// When used for workarounds that apply to the latest known version -// and all earlier versions of a compiler, the following convention -// should be observed: -// -// #if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1301)) -// -// The version number in this case corresponds to the last version in -// which the workaround was known to have been required. When -// BOOST_DETECT_OUTDATED_WORKAROUNDS is not the defined, the macro -// BOOST_TESTED_AT(x) expands to "!= 0", which effectively activates -// the workaround for any version of the compiler. When -// BOOST_DETECT_OUTDATED_WORKAROUNDS is defined, a compiler warning or -// error will be issued if the compiler version exceeds the argument -// to BOOST_TESTED_AT(). This can be used to locate workarounds which -// may be obsoleted by newer versions. - -# ifndef BOOST_STRICT_CONFIG - -#include - -#ifndef __BORLANDC__ -#define __BORLANDC___WORKAROUND_GUARD 1 -#else -#define __BORLANDC___WORKAROUND_GUARD 0 -#endif -#ifndef __CODEGEARC__ -#define __CODEGEARC___WORKAROUND_GUARD 1 -#else -#define __CODEGEARC___WORKAROUND_GUARD 0 -#endif -#ifndef _MSC_VER -#define _MSC_VER_WORKAROUND_GUARD 1 -#else -#define _MSC_VER_WORKAROUND_GUARD 0 -#endif -#ifndef _MSC_FULL_VER -#define _MSC_FULL_VER_WORKAROUND_GUARD 1 -#else -#define _MSC_FULL_VER_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_MSVC -#define BOOST_MSVC_WORKAROUND_GUARD 1 -#else -#define BOOST_MSVC_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_MSVC_FULL_VER -#define BOOST_MSVC_FULL_VER_WORKAROUND_GUARD 1 -#else -#define BOOST_MSVC_FULL_VER_WORKAROUND_GUARD 0 -#endif -#ifndef __GNUC__ -#define __GNUC___WORKAROUND_GUARD 1 -#else -#define __GNUC___WORKAROUND_GUARD 0 -#endif -#ifndef __GNUC_MINOR__ -#define __GNUC_MINOR___WORKAROUND_GUARD 1 -#else -#define __GNUC_MINOR___WORKAROUND_GUARD 0 -#endif -#ifndef __GNUC_PATCHLEVEL__ -#define __GNUC_PATCHLEVEL___WORKAROUND_GUARD 1 -#else -#define __GNUC_PATCHLEVEL___WORKAROUND_GUARD 0 -#endif -#ifndef __IBMCPP__ -#define __IBMCPP___WORKAROUND_GUARD 1 -#else -#define __IBMCPP___WORKAROUND_GUARD 0 -#endif -#ifndef __SUNPRO_CC -#define __SUNPRO_CC_WORKAROUND_GUARD 1 -#else -#define __SUNPRO_CC_WORKAROUND_GUARD 0 -#endif -#ifndef __DECCXX_VER -#define __DECCXX_VER_WORKAROUND_GUARD 1 -#else -#define __DECCXX_VER_WORKAROUND_GUARD 0 -#endif -#ifndef __MWERKS__ -#define __MWERKS___WORKAROUND_GUARD 1 -#else -#define __MWERKS___WORKAROUND_GUARD 0 -#endif -#ifndef __EDG__ -#define __EDG___WORKAROUND_GUARD 1 -#else -#define __EDG___WORKAROUND_GUARD 0 -#endif -#ifndef __EDG_VERSION__ -#define __EDG_VERSION___WORKAROUND_GUARD 1 -#else -#define __EDG_VERSION___WORKAROUND_GUARD 0 -#endif -#ifndef __HP_aCC -#define __HP_aCC_WORKAROUND_GUARD 1 -#else -#define __HP_aCC_WORKAROUND_GUARD 0 -#endif -#ifndef __hpxstd98 -#define __hpxstd98_WORKAROUND_GUARD 1 -#else -#define __hpxstd98_WORKAROUND_GUARD 0 -#endif -#ifndef _CRAYC -#define _CRAYC_WORKAROUND_GUARD 1 -#else -#define _CRAYC_WORKAROUND_GUARD 0 -#endif -#ifndef __DMC__ -#define __DMC___WORKAROUND_GUARD 1 -#else -#define __DMC___WORKAROUND_GUARD 0 -#endif -#ifndef MPW_CPLUS -#define MPW_CPLUS_WORKAROUND_GUARD 1 -#else -#define MPW_CPLUS_WORKAROUND_GUARD 0 -#endif -#ifndef __COMO__ -#define __COMO___WORKAROUND_GUARD 1 -#else -#define __COMO___WORKAROUND_GUARD 0 -#endif -#ifndef __COMO_VERSION__ -#define __COMO_VERSION___WORKAROUND_GUARD 1 -#else -#define __COMO_VERSION___WORKAROUND_GUARD 0 -#endif -#ifndef __INTEL_COMPILER -#define __INTEL_COMPILER_WORKAROUND_GUARD 1 -#else -#define __INTEL_COMPILER_WORKAROUND_GUARD 0 -#endif -#ifndef __ICL -#define __ICL_WORKAROUND_GUARD 1 -#else -#define __ICL_WORKAROUND_GUARD 0 -#endif -#ifndef _COMPILER_VERSION -#define _COMPILER_VERSION_WORKAROUND_GUARD 1 -#else -#define _COMPILER_VERSION_WORKAROUND_GUARD 0 -#endif - -#ifndef _RWSTD_VER -#define _RWSTD_VER_WORKAROUND_GUARD 1 -#else -#define _RWSTD_VER_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_RWSTD_VER -#define BOOST_RWSTD_VER_WORKAROUND_GUARD 1 -#else -#define BOOST_RWSTD_VER_WORKAROUND_GUARD 0 -#endif -#ifndef __GLIBCPP__ -#define __GLIBCPP___WORKAROUND_GUARD 1 -#else -#define __GLIBCPP___WORKAROUND_GUARD 0 -#endif -#ifndef _GLIBCXX_USE_C99_FP_MACROS_DYNAMIC -#define _GLIBCXX_USE_C99_FP_MACROS_DYNAMIC_WORKAROUND_GUARD 1 -#else -#define _GLIBCXX_USE_C99_FP_MACROS_DYNAMIC_WORKAROUND_GUARD 0 -#endif -#ifndef __SGI_STL_PORT -#define __SGI_STL_PORT_WORKAROUND_GUARD 1 -#else -#define __SGI_STL_PORT_WORKAROUND_GUARD 0 -#endif -#ifndef _STLPORT_VERSION -#define _STLPORT_VERSION_WORKAROUND_GUARD 1 -#else -#define _STLPORT_VERSION_WORKAROUND_GUARD 0 -#endif -#ifndef __LIBCOMO_VERSION__ -#define __LIBCOMO_VERSION___WORKAROUND_GUARD 1 -#else -#define __LIBCOMO_VERSION___WORKAROUND_GUARD 0 -#endif -#ifndef _CPPLIB_VER -#define _CPPLIB_VER_WORKAROUND_GUARD 1 -#else -#define _CPPLIB_VER_WORKAROUND_GUARD 0 -#endif - -#ifndef BOOST_INTEL_CXX_VERSION -#define BOOST_INTEL_CXX_VERSION_WORKAROUND_GUARD 1 -#else -#define BOOST_INTEL_CXX_VERSION_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_INTEL_WIN -#define BOOST_INTEL_WIN_WORKAROUND_GUARD 1 -#else -#define BOOST_INTEL_WIN_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_DINKUMWARE_STDLIB -#define BOOST_DINKUMWARE_STDLIB_WORKAROUND_GUARD 1 -#else -#define BOOST_DINKUMWARE_STDLIB_WORKAROUND_GUARD 0 -#endif -#ifndef BOOST_INTEL -#define BOOST_INTEL_WORKAROUND_GUARD 1 -#else -#define BOOST_INTEL_WORKAROUND_GUARD 0 -#endif -// Always define to zero, if it's used it'll be defined my MPL: -#define BOOST_MPL_CFG_GCC_WORKAROUND_GUARD 0 - -# define BOOST_WORKAROUND(symbol, test) \ - ((symbol ## _WORKAROUND_GUARD + 0 == 0) && \ - (symbol != 0) && (1 % (( (symbol test) ) + 1))) -// ^ ^ ^ ^ -// The extra level of parenthesis nesting above, along with the -// BOOST_OPEN_PAREN indirection below, is required to satisfy the -// broken preprocessor in MWCW 8.3 and earlier. -// -// The basic mechanism works as follows: -// (symbol test) + 1 => if (symbol test) then 2 else 1 -// 1 % ((symbol test) + 1) => if (symbol test) then 1 else 0 -// -// The complication with % is for cooperation with BOOST_TESTED_AT(). -// When "test" is BOOST_TESTED_AT(x) and -// BOOST_DETECT_OUTDATED_WORKAROUNDS is #defined, -// -// symbol test => if (symbol <= x) then 1 else -1 -// (symbol test) + 1 => if (symbol <= x) then 2 else 0 -// 1 % ((symbol test) + 1) => if (symbol <= x) then 1 else divide-by-zero -// - -# ifdef BOOST_DETECT_OUTDATED_WORKAROUNDS -# define BOOST_OPEN_PAREN ( -# define BOOST_TESTED_AT(value) > value) ?(-1): BOOST_OPEN_PAREN 1 -# else -# define BOOST_TESTED_AT(value) != ((value)-(value)) -# endif - -# else - -# define BOOST_WORKAROUND(symbol, test) 0 - -# endif - -#endif // WORKAROUND_DWA2002126_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset.hpp b/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset.hpp deleted file mode 100644 index 29e10386..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset.hpp +++ /dev/null @@ -1,17 +0,0 @@ -// ----------------------------------------------------------- -// -// Copyright (c) 2001-2002 Chuck Allison and Jeremy Siek -// Copyright (c) 2003-2004, 2008 Gennaro Prota -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// ----------------------------------------------------------- - -#ifndef BOOST_DYNAMIC_BITSET_HPP -#define BOOST_DYNAMIC_BITSET_HPP - -#include "boost/dynamic_bitset/dynamic_bitset.hpp" - -#endif // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/config.hpp deleted file mode 100644 index 1e6d9f7e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/config.hpp +++ /dev/null @@ -1,72 +0,0 @@ -// ----------------------------------------------------------- -// -// Copyright (c) 2001-2002 Chuck Allison and Jeremy Siek -// Copyright (c) 2003-2006, 2008 Gennaro Prota -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// ----------------------------------------------------------- - -#ifndef BOOST_DYNAMIC_BITSET_CONFIG_HPP_GP_20040424 -#define BOOST_DYNAMIC_BITSET_CONFIG_HPP_GP_20040424 - -#include "boost/config.hpp" -#include "boost/detail/workaround.hpp" - -// support for pre 3.0 libstdc++ - thanks Phil Edwards! -#if defined (__STL_CONFIG_H) && !defined (__STL_USE_NEW_IOSTREAMS) -# define BOOST_OLD_IOSTREAMS -#endif - -// no-op function to workaround gcc bug c++/8419 -// -namespace boost { namespace detail { - template T make_non_const(T t) { return t; } -}} - -#if defined(__GNUC__) -# define BOOST_DYNAMIC_BITSET_WRAP_CONSTANT(expr) \ - (boost::detail::make_non_const(expr)) -#else -# define BOOST_DYNAMIC_BITSET_WRAP_CONSTANT(expr) (expr) -#endif - -// -#if (defined __BORLANDC__ && BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))) \ - || (defined BOOST_NO_MEMBER_TEMPLATE_FRIENDS) -#define BOOST_DYNAMIC_BITSET_DONT_USE_FRIENDS -#endif - -// if we can't use friends then we simply expose private members -// -#if defined(BOOST_DYNAMIC_BITSET_DONT_USE_FRIENDS) -#define BOOST_DYNAMIC_BITSET_PRIVATE public -#else -#define BOOST_DYNAMIC_BITSET_PRIVATE private -#endif - -// A couple of macros to cope with libraries without locale -// support. The first macro must be used to declare a reference -// to a ctype facet. The second one to widen a char by using -// that ctype object. If facets and locales aren't available -// the first macro is a no-op and the second one just expands -// to its parameter c. -// -#if defined (BOOST_USE_FACET) - -#define BOOST_DYNAMIC_BITSET_CTYPE_FACET(ch, name, loc) \ - const std::ctype & name = \ - BOOST_USE_FACET(std::ctype, loc) /**/ - -#define BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, c) \ - (fac.widen(c)) -#else - -#define BOOST_DYNAMIC_BITSET_CTYPE_FACET(ch, name, loc) /**/ -#define BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, c) c - -#endif - -#endif // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/dynamic_bitset.hpp b/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/dynamic_bitset.hpp deleted file mode 100644 index 930e4b2d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset/dynamic_bitset.hpp +++ /dev/null @@ -1,1761 +0,0 @@ -// ----------------------------------------------------------- -// -// Copyright (c) 2001-2002 Chuck Allison and Jeremy Siek -// Copyright (c) 2003-2006, 2008 Gennaro Prota -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// ----------------------------------------------------------- - -#ifndef BOOST_DYNAMIC_BITSET_DYNAMIC_BITSET_HPP -#define BOOST_DYNAMIC_BITSET_DYNAMIC_BITSET_HPP - -#include -#include -#include -#include -#include -#include // for CHAR_BIT - -#include "boost/dynamic_bitset/config.hpp" - -#ifndef BOOST_NO_STD_LOCALE -# include -#endif - -#if defined(BOOST_OLD_IOSTREAMS) -# include -# include // for isspace -#else -# include -# include -#endif - -#include "boost/dynamic_bitset_fwd.hpp" -#include "boost/detail/dynamic_bitset.hpp" -#include "boost/detail/iterator.hpp" // used to implement append(Iter, Iter) -#include "boost/static_assert.hpp" -#include "boost/limits.hpp" -#include "boost/pending/lowest_bit.hpp" - - -namespace boost { - -template -class dynamic_bitset -{ - // Portability note: member function templates are defined inside - // this class definition to avoid problems with VC++. Similarly, - // with the member functions of nested classes. - // - // [October 2008: the note above is mostly historical; new versions - // of VC++ are likely able to digest a more drinking form of the - // code; but changing it now is probably not worth the risks...] - - BOOST_STATIC_ASSERT((bool)detail::dynamic_bitset_impl::allowed_block_type::value); - -public: - typedef Block block_type; - typedef Allocator allocator_type; - typedef std::size_t size_type; - typedef block_type block_width_type; - - BOOST_STATIC_CONSTANT(block_width_type, bits_per_block = (std::numeric_limits::digits)); - BOOST_STATIC_CONSTANT(size_type, npos = static_cast(-1)); - - -public: - - // A proxy class to simulate lvalues of bit type. - // - class reference - { - friend class dynamic_bitset; - - - // the one and only non-copy ctor - reference(block_type & b, block_type pos) - :m_block(b), - m_mask( (assert(pos < bits_per_block), - block_type(1) << pos ) - ) - { } - - void operator&(); // left undefined - - public: - - // copy constructor: compiler generated - - operator bool() const { return (m_block & m_mask) != 0; } - bool operator~() const { return (m_block & m_mask) == 0; } - - reference& flip() { do_flip(); return *this; } - - reference& operator=(bool x) { do_assign(x); return *this; } // for b[i] = x - reference& operator=(const reference& rhs) { do_assign(rhs); return *this; } // for b[i] = b[j] - - reference& operator|=(bool x) { if (x) do_set(); return *this; } - reference& operator&=(bool x) { if (!x) do_reset(); return *this; } - reference& operator^=(bool x) { if (x) do_flip(); return *this; } - reference& operator-=(bool x) { if (x) do_reset(); return *this; } - - private: - block_type & m_block; - const block_type m_mask; - - void do_set() { m_block |= m_mask; } - void do_reset() { m_block &= ~m_mask; } - void do_flip() { m_block ^= m_mask; } - void do_assign(bool x) { x? do_set() : do_reset(); } - }; - - typedef bool const_reference; - - // constructors, etc. - explicit - dynamic_bitset(const Allocator& alloc = Allocator()); - - explicit - dynamic_bitset(size_type num_bits, unsigned long value = 0, - const Allocator& alloc = Allocator()); - - - // WARNING: you should avoid using this constructor. - // - // A conversion from string is, in most cases, formatting, - // and should be performed by using operator>>. - // - // NOTE: - // Leave the parentheses around std::basic_string::npos. - // g++ 3.2 requires them and probably the standard will - see core issue 325 - // NOTE 2: - // split into two constructors because of bugs in MSVC 6.0sp5 with STLport - - template - dynamic_bitset(const std::basic_string& s, - typename std::basic_string::size_type pos, - typename std::basic_string::size_type n, - size_type num_bits = npos, - const Allocator& alloc = Allocator()) - - :m_bits(alloc), - m_num_bits(0) - { - init_from_string(s, pos, n, num_bits); - } - - template - explicit - dynamic_bitset(const std::basic_string& s, - typename std::basic_string::size_type pos = 0) - - :m_bits(Allocator()), - m_num_bits(0) - { - init_from_string(s, pos, (std::basic_string::npos), - npos); - } - - // The first bit in *first is the least significant bit, and the - // last bit in the block just before *last is the most significant bit. - template - dynamic_bitset(BlockInputIterator first, BlockInputIterator last, - const Allocator& alloc = Allocator()) - - :m_bits(alloc), - m_num_bits(0) - { - using boost::detail::dynamic_bitset_impl::value_to_type; - using boost::detail::dynamic_bitset_impl::is_numeric; - - const value_to_type< - is_numeric::value> selector; - - dispatch_init(first, last, selector); - } - - template - void dispatch_init(T num_bits, unsigned long value, - detail::dynamic_bitset_impl::value_to_type) - { - init_from_unsigned_long(static_cast(num_bits), value); - } - - template - void dispatch_init(T first, T last, - detail::dynamic_bitset_impl::value_to_type) - { - init_from_block_range(first, last); - } - - template - void init_from_block_range(BlockIter first, BlockIter last) - { - assert(m_bits.size() == 0); - m_bits.insert(m_bits.end(), first, last); - m_num_bits = m_bits.size() * bits_per_block; - } - - // copy constructor - dynamic_bitset(const dynamic_bitset& b); - - ~dynamic_bitset(); - - void swap(dynamic_bitset& b); - dynamic_bitset& operator=(const dynamic_bitset& b); - - allocator_type get_allocator() const; - - // size changing operations - void resize(size_type num_bits, bool value = false); - void clear(); - void push_back(bool bit); - void append(Block block); - - template - void m_append(BlockInputIterator first, BlockInputIterator last, std::input_iterator_tag) - { - std::vector v(first, last); - m_append(v.begin(), v.end(), std::random_access_iterator_tag()); - } - template - void m_append(BlockInputIterator first, BlockInputIterator last, std::forward_iterator_tag) - { - assert(first != last); - block_width_type r = count_extra_bits(); - std::size_t d = boost::detail::distance(first, last); - m_bits.reserve(num_blocks() + d); - if (r == 0) { - for( ; first != last; ++first) - m_bits.push_back(*first); // could use vector<>::insert() - } - else { - m_highest_block() |= (*first << r); - do { - Block b = *first >> (bits_per_block - r); - ++first; - m_bits.push_back(b | (first==last? 0 : *first << r)); - } while (first != last); - } - m_num_bits += bits_per_block * d; - } - template - void append(BlockInputIterator first, BlockInputIterator last) // strong guarantee - { - if (first != last) { - typename detail::iterator_traits::iterator_category cat; - m_append(first, last, cat); - } - } - - - // bitset operations - dynamic_bitset& operator&=(const dynamic_bitset& b); - dynamic_bitset& operator|=(const dynamic_bitset& b); - dynamic_bitset& operator^=(const dynamic_bitset& b); - dynamic_bitset& operator-=(const dynamic_bitset& b); - dynamic_bitset& operator<<=(size_type n); - dynamic_bitset& operator>>=(size_type n); - dynamic_bitset operator<<(size_type n) const; - dynamic_bitset operator>>(size_type n) const; - - // basic bit operations - dynamic_bitset& set(size_type n, bool val = true); - dynamic_bitset& set(); - dynamic_bitset& reset(size_type n); - dynamic_bitset& reset(); - dynamic_bitset& flip(size_type n); - dynamic_bitset& flip(); - bool test(size_type n) const; - bool any() const; - bool none() const; - dynamic_bitset operator~() const; - size_type count() const; - - // subscript - reference operator[](size_type pos) { - return reference(m_bits[block_index(pos)], bit_index(pos)); - } - bool operator[](size_type pos) const { return test(pos); } - - unsigned long to_ulong() const; - - size_type size() const; - size_type num_blocks() const; - size_type max_size() const; - bool empty() const; - - bool is_subset_of(const dynamic_bitset& a) const; - bool is_proper_subset_of(const dynamic_bitset& a) const; - bool intersects(const dynamic_bitset & a) const; - - // lookup - size_type find_first() const; - size_type find_next(size_type pos) const; - - -#if !defined BOOST_DYNAMIC_BITSET_DONT_USE_FRIENDS - // lexicographical comparison - template - friend bool operator==(const dynamic_bitset& a, - const dynamic_bitset& b); - - template - friend bool operator<(const dynamic_bitset& a, - const dynamic_bitset& b); - - - template - friend void to_block_range(const dynamic_bitset& b, - BlockOutputIterator result); - - template - friend void from_block_range(BlockIterator first, BlockIterator last, - dynamic_bitset& result); - - - template - friend std::basic_istream& operator>>(std::basic_istream& is, - dynamic_bitset& b); - - template - friend void to_string_helper(const dynamic_bitset & b, stringT & s, bool dump_all); - - -#endif - - -private: - BOOST_STATIC_CONSTANT(block_width_type, ulong_width = std::numeric_limits::digits); - typedef std::vector buffer_type; - - void m_zero_unused_bits(); - bool m_check_invariants() const; - - size_type m_do_find_from(size_type first_block) const; - - block_width_type count_extra_bits() const { return bit_index(size()); } - static size_type block_index(size_type pos) { return pos / bits_per_block; } - static block_width_type bit_index(size_type pos) { return static_cast(pos % bits_per_block); } - static Block bit_mask(size_type pos) { return Block(1) << bit_index(pos); } - - template - void init_from_string(const std::basic_string& s, - typename std::basic_string::size_type pos, - typename std::basic_string::size_type n, - size_type num_bits) - { - assert(pos <= s.size()); - - typedef typename std::basic_string StrT; - typedef typename StrT::traits_type Tr; - - const typename StrT::size_type rlen = (std::min)(n, s.size() - pos); - const size_type sz = ( num_bits != npos? num_bits : rlen); - m_bits.resize(calc_num_blocks(sz)); - m_num_bits = sz; - - - BOOST_DYNAMIC_BITSET_CTYPE_FACET(CharT, fac, std::locale()); - const CharT one = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '1'); - - const size_type m = num_bits < rlen ? num_bits : rlen; - typename StrT::size_type i = 0; - for( ; i < m; ++i) { - - const CharT c = s[(pos + m - 1) - i]; - - assert( Tr::eq(c, one) - || Tr::eq(c, BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '0')) ); - - if (Tr::eq(c, one)) - set(i); - - } - - } - - void init_from_unsigned_long(size_type num_bits, - unsigned long value/*, - const Allocator& alloc*/) - { - - assert(m_bits.size() == 0); - - m_bits.resize(calc_num_blocks(num_bits)); - m_num_bits = num_bits; - - typedef unsigned long num_type; - typedef boost::detail::dynamic_bitset_impl - ::shifter shifter; - - //if (num_bits == 0) - // return; - - // zero out all bits at pos >= num_bits, if any; - // note that: num_bits == 0 implies value == 0 - if (num_bits < static_cast(ulong_width)) { - const num_type mask = (num_type(1) << num_bits) - 1; - value &= mask; - } - - typename buffer_type::iterator it = m_bits.begin(); - for( ; value; shifter::left_shift(value), ++it) { - *it = static_cast(value); - } - - } - - - -BOOST_DYNAMIC_BITSET_PRIVATE: - - bool m_unchecked_test(size_type pos) const; - static size_type calc_num_blocks(size_type num_bits); - - Block& m_highest_block(); - const Block& m_highest_block() const; - - buffer_type m_bits; - size_type m_num_bits; - - - class bit_appender; - friend class bit_appender; - class bit_appender { - // helper for stream >> - // Supplies to the lack of an efficient append at the less - // significant end: bits are actually appended "at left" but - // rearranged in the destructor. From the perspective of - // client code everything works *as if* dynamic_bitset<> had - // an append_at_right() function (eventually throwing the same - // exceptions as push_back) except that the function is in fact - // called bit_appender::do_append(). - // - dynamic_bitset & bs; - size_type n; - Block mask; - Block * current; - - // not implemented - bit_appender(const bit_appender &); - bit_appender & operator=(const bit_appender &); - - public: - bit_appender(dynamic_bitset & r) : bs(r), n(0), mask(0), current(0) {} - ~bit_appender() { - // reverse the order of blocks, shift - // if needed, and then resize - // - std::reverse(bs.m_bits.begin(), bs.m_bits.end()); - const block_width_type offs = bit_index(n); - if (offs) - bs >>= (bits_per_block - offs); - bs.resize(n); // doesn't enlarge, so can't throw - assert(bs.m_check_invariants()); - } - inline void do_append(bool value) { - - if (mask == 0) { - bs.append(Block(0)); - current = &bs.m_highest_block(); - mask = Block(1) << (bits_per_block - 1); - } - - if(value) - *current |= mask; - - mask /= 2; - ++n; - } - size_type get_count() const { return n; } - }; - -}; - -#if !defined BOOST_NO_INCLASS_MEMBER_INITIALIZATION - -template -const typename dynamic_bitset::block_width_type -dynamic_bitset::bits_per_block; - -template -const typename dynamic_bitset::size_type -dynamic_bitset::npos; - -template -const typename dynamic_bitset::block_width_type -dynamic_bitset::ulong_width; - -#endif - -// Global Functions: - -// comparison -template -bool operator!=(const dynamic_bitset& a, - const dynamic_bitset& b); - -template -bool operator<=(const dynamic_bitset& a, - const dynamic_bitset& b); - -template -bool operator>(const dynamic_bitset& a, - const dynamic_bitset& b); - -template -bool operator>=(const dynamic_bitset& a, - const dynamic_bitset& b); - -// stream operators -#ifdef BOOST_OLD_IOSTREAMS -template -std::ostream& operator<<(std::ostream& os, - const dynamic_bitset& b); - -template -std::istream& operator>>(std::istream& is, dynamic_bitset& b); -#else -template -std::basic_ostream& -operator<<(std::basic_ostream& os, - const dynamic_bitset& b); - -template -std::basic_istream& -operator>>(std::basic_istream& is, - dynamic_bitset& b); -#endif - -// bitset operations -template -dynamic_bitset -operator&(const dynamic_bitset& b1, - const dynamic_bitset& b2); - -template -dynamic_bitset -operator|(const dynamic_bitset& b1, - const dynamic_bitset& b2); - -template -dynamic_bitset -operator^(const dynamic_bitset& b1, - const dynamic_bitset& b2); - -template -dynamic_bitset -operator-(const dynamic_bitset& b1, - const dynamic_bitset& b2); - -// namespace scope swap -template -void swap(dynamic_bitset& b1, - dynamic_bitset& b2); - - -template -void -to_string(const dynamic_bitset& b, stringT & s); - -template -void -to_block_range(const dynamic_bitset& b, - BlockOutputIterator result); - - -template -inline void -from_block_range(BlockIterator first, BlockIterator last, - dynamic_bitset& result) -{ - // PRE: distance(first, last) <= numblocks() - std::copy (first, last, result.m_bits.begin()); -} - -//============================================================================= -// dynamic_bitset implementation - - -//----------------------------------------------------------------------------- -// constructors, etc. - -template -dynamic_bitset::dynamic_bitset(const Allocator& alloc) - : m_bits(alloc), m_num_bits(0) -{ - -} - -template -dynamic_bitset:: -dynamic_bitset(size_type num_bits, unsigned long value, const Allocator& alloc) - : m_bits(alloc), - m_num_bits(0) -{ - init_from_unsigned_long(num_bits, value); -} - -// copy constructor -template -inline dynamic_bitset:: -dynamic_bitset(const dynamic_bitset& b) - : m_bits(b.m_bits), m_num_bits(b.m_num_bits) -{ - -} - -template -inline dynamic_bitset:: -~dynamic_bitset() -{ - assert(m_check_invariants()); -} - -template -inline void dynamic_bitset:: -swap(dynamic_bitset& b) // no throw -{ - std::swap(m_bits, b.m_bits); - std::swap(m_num_bits, b.m_num_bits); -} - -template -dynamic_bitset& dynamic_bitset:: -operator=(const dynamic_bitset& b) -{ - m_bits = b.m_bits; - m_num_bits = b.m_num_bits; - return *this; -} - -template -inline typename dynamic_bitset::allocator_type -dynamic_bitset::get_allocator() const -{ - return m_bits.get_allocator(); -} - -//----------------------------------------------------------------------------- -// size changing operations - -template -void dynamic_bitset:: -resize(size_type num_bits, bool value) // strong guarantee -{ - - const size_type old_num_blocks = num_blocks(); - const size_type required_blocks = calc_num_blocks(num_bits); - - const block_type v = value? ~Block(0) : Block(0); - - if (required_blocks != old_num_blocks) { - m_bits.resize(required_blocks, v); // s.g. (copy) - } - - - // At this point: - // - // - if the buffer was shrunk, we have nothing more to do, - // except a call to m_zero_unused_bits() - // - // - if it was enlarged, all the (used) bits in the new blocks have - // the correct value, but we have not yet touched those bits, if - // any, that were 'unused bits' before enlarging: if value == true, - // they must be set. - - if (value && (num_bits > m_num_bits)) { - - const block_width_type extra_bits = count_extra_bits(); - if (extra_bits) { - assert(old_num_blocks >= 1 && old_num_blocks <= m_bits.size()); - - // Set them. - m_bits[old_num_blocks - 1] |= (v << extra_bits); - } - - } - - m_num_bits = num_bits; - m_zero_unused_bits(); - -} - -template -void dynamic_bitset:: -clear() // no throw -{ - m_bits.clear(); - m_num_bits = 0; -} - - -template -void dynamic_bitset:: -push_back(bool bit) -{ - const size_type sz = size(); - resize(sz + 1); - set(sz, bit); -} - -template -void dynamic_bitset:: -append(Block value) // strong guarantee -{ - const block_width_type r = count_extra_bits(); - - if (r == 0) { - // the buffer is empty, or all blocks are filled - m_bits.push_back(value); - } - else { - m_bits.push_back(value >> (bits_per_block - r)); - m_bits[m_bits.size() - 2] |= (value << r); // m_bits.size() >= 2 - } - - m_num_bits += bits_per_block; - assert(m_check_invariants()); - -} - - -//----------------------------------------------------------------------------- -// bitset operations -template -dynamic_bitset& -dynamic_bitset::operator&=(const dynamic_bitset& rhs) -{ - assert(size() == rhs.size()); - for (size_type i = 0; i < num_blocks(); ++i) - m_bits[i] &= rhs.m_bits[i]; - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::operator|=(const dynamic_bitset& rhs) -{ - assert(size() == rhs.size()); - for (size_type i = 0; i < num_blocks(); ++i) - m_bits[i] |= rhs.m_bits[i]; - //m_zero_unused_bits(); - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::operator^=(const dynamic_bitset& rhs) -{ - assert(size() == rhs.size()); - for (size_type i = 0; i < this->num_blocks(); ++i) - m_bits[i] ^= rhs.m_bits[i]; - //m_zero_unused_bits(); - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::operator-=(const dynamic_bitset& rhs) -{ - assert(size() == rhs.size()); - for (size_type i = 0; i < num_blocks(); ++i) - m_bits[i] &= ~rhs.m_bits[i]; - //m_zero_unused_bits(); - return *this; -} - -// -// NOTE: -// Note that the 'if (r != 0)' is crucial to avoid undefined -// behavior when the left hand operand of >> isn't promoted to a -// wider type (because rs would be too large). -// -template -dynamic_bitset& -dynamic_bitset::operator<<=(size_type n) -{ - if (n >= m_num_bits) - return reset(); - //else - if (n > 0) { - - size_type const last = num_blocks() - 1; // num_blocks() is >= 1 - size_type const div = n / bits_per_block; // div is <= last - block_width_type const r = bit_index(n); - block_type * const b = &m_bits[0]; - - if (r != 0) { - - block_width_type const rs = bits_per_block - r; - - for (size_type i = last-div; i>0; --i) { - b[i+div] = (b[i] << r) | (b[i-1] >> rs); - } - b[div] = b[0] << r; - - } - else { - for (size_type i = last-div; i>0; --i) { - b[i+div] = b[i]; - } - b[div] = b[0]; - } - - // zero out div blocks at the less significant end - std::fill_n(b, div, static_cast(0)); - - // zero out any 1 bit that flowed into the unused part - m_zero_unused_bits(); // thanks to Lester Gong - - } - - return *this; - - -} - - -// -// NOTE: -// see the comments to operator <<= -// -template -dynamic_bitset & dynamic_bitset::operator>>=(size_type n) { - if (n >= m_num_bits) { - return reset(); - } - //else - if (n>0) { - - size_type const last = num_blocks() - 1; // num_blocks() is >= 1 - size_type const div = n / bits_per_block; // div is <= last - block_width_type const r = bit_index(n); - block_type * const b = &m_bits[0]; - - - if (r != 0) { - - block_width_type const ls = bits_per_block - r; - - for (size_type i = div; i < last; ++i) { - b[i-div] = (b[i] >> r) | (b[i+1] << ls); - } - // r bits go to zero - b[last-div] = b[last] >> r; - } - - else { - for (size_type i = div; i <= last; ++i) { - b[i-div] = b[i]; - } - // note the '<=': the last iteration 'absorbs' - // b[last-div] = b[last] >> 0; - } - - - - // div blocks are zero filled at the most significant end - std::fill_n(b + (num_blocks()-div), div, static_cast(0)); - } - - return *this; -} - - -template -dynamic_bitset -dynamic_bitset::operator<<(size_type n) const -{ - dynamic_bitset r(*this); - return r <<= n; -} - -template -dynamic_bitset -dynamic_bitset::operator>>(size_type n) const -{ - dynamic_bitset r(*this); - return r >>= n; -} - - -//----------------------------------------------------------------------------- -// basic bit operations - -template -dynamic_bitset& -dynamic_bitset::set(size_type pos, bool val) -{ - assert(pos < m_num_bits); - - if (val) - m_bits[block_index(pos)] |= bit_mask(pos); - else - reset(pos); - - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::set() -{ - std::fill(m_bits.begin(), m_bits.end(), ~Block(0)); - m_zero_unused_bits(); - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::reset(size_type pos) -{ - assert(pos < m_num_bits); -#if defined __MWERKS__ && BOOST_WORKAROUND(__MWERKS__, <= 0x3003) // 8.x - // CodeWarrior 8 generates incorrect code when the &=~ is compiled, - // use the |^ variation instead.. - m_bits[block_index(pos)] |= bit_mask(pos); - m_bits[block_index(pos)] ^= bit_mask(pos); -#else - m_bits[block_index(pos)] &= ~bit_mask(pos); -#endif - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::reset() -{ - std::fill(m_bits.begin(), m_bits.end(), Block(0)); - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::flip(size_type pos) -{ - assert(pos < m_num_bits); - m_bits[block_index(pos)] ^= bit_mask(pos); - return *this; -} - -template -dynamic_bitset& -dynamic_bitset::flip() -{ - for (size_type i = 0; i < num_blocks(); ++i) - m_bits[i] = ~m_bits[i]; - m_zero_unused_bits(); - return *this; -} - -template -bool dynamic_bitset::m_unchecked_test(size_type pos) const -{ - return (m_bits[block_index(pos)] & bit_mask(pos)) != 0; -} - -template -bool dynamic_bitset::test(size_type pos) const -{ - assert(pos < m_num_bits); - return m_unchecked_test(pos); -} - -template -bool dynamic_bitset::any() const -{ - for (size_type i = 0; i < num_blocks(); ++i) - if (m_bits[i]) - return true; - return false; -} - -template -inline bool dynamic_bitset::none() const -{ - return !any(); -} - -template -dynamic_bitset -dynamic_bitset::operator~() const -{ - dynamic_bitset b(*this); - b.flip(); - return b; -} - -template -typename dynamic_bitset::size_type -dynamic_bitset::count() const -{ - using detail::dynamic_bitset_impl::table_width; - using detail::dynamic_bitset_impl::access_by_bytes; - using detail::dynamic_bitset_impl::access_by_blocks; - using detail::dynamic_bitset_impl::value_to_type; - -#if BOOST_WORKAROUND(__GNUC__, == 4) && (__GNUC_MINOR__ == 3) && (__GNUC_PATCHLEVEL__ == 3) - // NOTE: Explicit qualification of "bits_per_block" - // breaks compilation on gcc 4.3.3 - enum { no_padding = bits_per_block == CHAR_BIT * sizeof(Block) }; -#else - // NOTE: Explicitly qualifying "bits_per_block" to workaround - // regressions of gcc 3.4.x - enum { no_padding = - dynamic_bitset::bits_per_block - == CHAR_BIT * sizeof(Block) }; -#endif - - enum { enough_table_width = table_width >= CHAR_BIT }; - - enum { mode = (no_padding && enough_table_width) - ? access_by_bytes - : access_by_blocks }; - - return do_count(m_bits.begin(), num_blocks(), Block(0), - static_cast *>(0)); -} - - -//----------------------------------------------------------------------------- -// conversions - - -template -void to_string_helper(const dynamic_bitset & b, stringT & s, - bool dump_all) -{ - typedef typename stringT::traits_type Tr; - typedef typename stringT::value_type Ch; - - BOOST_DYNAMIC_BITSET_CTYPE_FACET(Ch, fac, std::locale()); - const Ch zero = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '0'); - const Ch one = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '1'); - - // Note that this function may access (when - // dump_all == true) bits beyond position size() - 1 - - typedef typename dynamic_bitset::size_type size_type; - - const size_type len = dump_all? - dynamic_bitset::bits_per_block * b.num_blocks(): - b.size(); - s.assign (len, zero); - - for (size_type i = 0; i < len; ++i) { - if (b.m_unchecked_test(i)) - Tr::assign(s[len - 1 - i], one); - - } - -} - - -// A comment similar to the one about the constructor from -// basic_string can be done here. Thanks to James Kanze for -// making me (Gennaro) realize this important separation of -// concerns issue, as well as many things about i18n. -// -template -inline void -to_string(const dynamic_bitset& b, stringT& s) -{ - to_string_helper(b, s, false); -} - - -// Differently from to_string this function dumps out -// every bit of the internal representation (may be -// useful for debugging purposes) -// -template -inline void -dump_to_string(const dynamic_bitset& b, stringT& s) -{ - to_string_helper(b, s, true /* =dump_all*/); -} - -template -inline void -to_block_range(const dynamic_bitset& b, - BlockOutputIterator result) -{ - // note how this copies *all* bits, including the - // unused ones in the last block (which are zero) - std::copy(b.m_bits.begin(), b.m_bits.end(), result); -} - -template -unsigned long dynamic_bitset:: -to_ulong() const -{ - - if (m_num_bits == 0) - return 0; // convention - - // Check for overflows. This may be a performance burden on very - // large bitsets but is required by the specification, sorry - if (find_next(ulong_width - 1) != npos) - throw std::overflow_error("boost::dynamic_bitset::to_ulong overflow"); - - - // Ok, from now on we can be sure there's no "on" bit - // beyond the "allowed" positions - typedef unsigned long result_type; - - const size_type maximum_size = - (std::min)(m_num_bits, static_cast(ulong_width)); - - const size_type last_block = block_index( maximum_size - 1 ); - - assert((last_block * bits_per_block) < static_cast(ulong_width)); - - result_type result = 0; - for (size_type i = 0; i <= last_block; ++i) { - const size_type offset = i * bits_per_block; - result |= (static_cast(m_bits[i]) << offset); - } - - return result; -} - -template -inline typename dynamic_bitset::size_type -dynamic_bitset::size() const -{ - return m_num_bits; -} - -template -inline typename dynamic_bitset::size_type -dynamic_bitset::num_blocks() const -{ - return m_bits.size(); -} - -template -inline typename dynamic_bitset::size_type -dynamic_bitset::max_size() const -{ - // Semantics of vector<>::max_size() aren't very clear - // (see lib issue 197) and many library implementations - // simply return dummy values, _unrelated_ to the underlying - // allocator. - // - // Given these problems, I was tempted to not provide this - // function at all but the user could need it if he provides - // his own allocator. - // - - const size_type m = detail::dynamic_bitset_impl:: - vector_max_size_workaround(m_bits); - - return m <= (size_type(-1)/bits_per_block) ? - m * bits_per_block : - size_type(-1); -} - -template -inline bool dynamic_bitset::empty() const -{ - return size() == 0; -} - -template -bool dynamic_bitset:: -is_subset_of(const dynamic_bitset& a) const -{ - assert(size() == a.size()); - for (size_type i = 0; i < num_blocks(); ++i) - if (m_bits[i] & ~a.m_bits[i]) - return false; - return true; -} - -template -bool dynamic_bitset:: -is_proper_subset_of(const dynamic_bitset& a) const -{ - assert(size() == a.size()); - assert(num_blocks() == a.num_blocks()); - - bool proper = false; - for (size_type i = 0; i < num_blocks(); ++i) { - const Block & bt = m_bits[i]; - const Block & ba = a.m_bits[i]; - - if (bt & ~ba) - return false; // not a subset at all - if (ba & ~bt) - proper = true; - } - return proper; -} - -template -bool dynamic_bitset::intersects(const dynamic_bitset & b) const -{ - size_type common_blocks = num_blocks() < b.num_blocks() - ? num_blocks() : b.num_blocks(); - - for(size_type i = 0; i < common_blocks; ++i) { - if(m_bits[i] & b.m_bits[i]) - return true; - } - return false; -} - -// -------------------------------- -// lookup - - -// look for the first bit "on", starting -// from the block with index first_block -// -template -typename dynamic_bitset::size_type -dynamic_bitset::m_do_find_from(size_type first_block) const -{ - size_type i = first_block; - - // skip null blocks - while (i < num_blocks() && m_bits[i] == 0) - ++i; - - if (i >= num_blocks()) - return npos; // not found - - return i * bits_per_block + boost::lowest_bit(m_bits[i]); - -} - - -template -typename dynamic_bitset::size_type -dynamic_bitset::find_first() const -{ - return m_do_find_from(0); -} - - -template -typename dynamic_bitset::size_type -dynamic_bitset::find_next(size_type pos) const -{ - - const size_type sz = size(); - if (pos >= (sz-1) || sz == 0) - return npos; - - ++pos; - - const size_type blk = block_index(pos); - const block_width_type ind = bit_index(pos); - - // mask out bits before pos - const Block fore = m_bits[blk] & ( ~Block(0) << ind ); - - return fore? - blk * bits_per_block + lowest_bit(fore) - : - m_do_find_from(blk + 1); - -} - - - -//----------------------------------------------------------------------------- -// comparison - -template -bool operator==(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - return (a.m_num_bits == b.m_num_bits) - && (a.m_bits == b.m_bits); -} - -template -inline bool operator!=(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - return !(a == b); -} - -template -bool operator<(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - assert(a.size() == b.size()); - typedef typename dynamic_bitset::size_type size_type; - - //if (a.size() == 0) - // return false; - - // Since we are storing the most significant bit - // at pos == size() - 1, we need to do the comparisons in reverse. - // - for (size_type ii = a.num_blocks(); ii > 0; --ii) { - size_type i = ii-1; - if (a.m_bits[i] < b.m_bits[i]) - return true; - else if (a.m_bits[i] > b.m_bits[i]) - return false; - } - return false; -} - -template -inline bool operator<=(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - return !(a > b); -} - -template -inline bool operator>(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - return b < a; -} - -template -inline bool operator>=(const dynamic_bitset& a, - const dynamic_bitset& b) -{ - return !(a < b); -} - -//----------------------------------------------------------------------------- -// stream operations - -#ifdef BOOST_OLD_IOSTREAMS -template < typename Block, typename Alloc> -std::ostream& -operator<<(std::ostream& os, const dynamic_bitset& b) -{ - // NOTE: since this is aimed at "classic" iostreams, exception - // masks on the stream are not supported. The library that - // ships with gcc 2.95 has an exceptions() member function but - // nothing is actually implemented; not even the class ios::failure. - - using namespace std; - - const ios::iostate ok = ios::goodbit; - ios::iostate err = ok; - - if (os.opfx()) { - - //try - typedef typename dynamic_bitset::size_type bitsetsize_type; - - const bitsetsize_type sz = b.size(); - std::streambuf * buf = os.rdbuf(); - size_t npad = os.width() <= 0 // careful: os.width() is signed (and can be < 0) - || (bitsetsize_type) os.width() <= sz? 0 : os.width() - sz; - - const char fill_char = os.fill(); - const ios::fmtflags adjustfield = os.flags() & ios::adjustfield; - - // if needed fill at left; pad is decresed along the way - if (adjustfield != ios::left) { - for (; 0 < npad; --npad) - if (fill_char != buf->sputc(fill_char)) { - err |= ios::failbit; - break; - } - } - - if (err == ok) { - // output the bitset - for (bitsetsize_type i = b.size(); 0 < i; --i) { - const char dig = b.test(i-1)? '1' : '0'; - if (EOF == buf->sputc(dig)) { - err |= ios::failbit; - break; - } - } - } - - if (err == ok) { - // if needed fill at right - for (; 0 < npad; --npad) { - if (fill_char != buf->sputc(fill_char)) { - err |= ios::failbit; - break; - } - } - } - - os.osfx(); - os.width(0); - - } // if opfx - - if(err != ok) - os.setstate(err); // assume this does NOT throw - return os; - -} -#else - -template -std::basic_ostream& -operator<<(std::basic_ostream& os, - const dynamic_bitset& b) -{ - - using namespace std; - - const ios_base::iostate ok = ios_base::goodbit; - ios_base::iostate err = ok; - - typename basic_ostream::sentry cerberos(os); - if (cerberos) { - - BOOST_DYNAMIC_BITSET_CTYPE_FACET(Ch, fac, os.getloc()); - const Ch zero = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '0'); - const Ch one = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '1'); - - try { - - typedef typename dynamic_bitset::size_type bitsetsize_type; - typedef basic_streambuf buffer_type; - - buffer_type * buf = os.rdbuf(); - size_t npad = os.width() <= 0 // careful: os.width() is signed (and can be < 0) - || (bitsetsize_type) os.width() <= b.size()? 0 : os.width() - b.size(); - - const Ch fill_char = os.fill(); - const ios_base::fmtflags adjustfield = os.flags() & ios_base::adjustfield; - - // if needed fill at left; pad is decresed along the way - if (adjustfield != ios_base::left) { - for (; 0 < npad; --npad) - if (Tr::eq_int_type(Tr::eof(), buf->sputc(fill_char))) { - err |= ios_base::failbit; - break; - } - } - - if (err == ok) { - // output the bitset - for (bitsetsize_type i = b.size(); 0 < i; --i) { - typename buffer_type::int_type - ret = buf->sputc(b.test(i-1)? one : zero); - if (Tr::eq_int_type(Tr::eof(), ret)) { - err |= ios_base::failbit; - break; - } - } - } - - if (err == ok) { - // if needed fill at right - for (; 0 < npad; --npad) { - if (Tr::eq_int_type(Tr::eof(), buf->sputc(fill_char))) { - err |= ios_base::failbit; - break; - } - } - } - - - os.width(0); - - } catch (...) { // see std 27.6.1.1/4 - bool rethrow = false; - try { os.setstate(ios_base::failbit); } catch (...) { rethrow = true; } - - if (rethrow) - throw; - } - } - - if(err != ok) - os.setstate(err); // may throw exception - return os; - -} -#endif - - -#ifdef BOOST_OLD_IOSTREAMS - - // A sentry-like class that calls isfx in its destructor. - // "Necessary" because bit_appender::do_append may throw. - class pseudo_sentry { - std::istream & m_r; - const bool m_ok; - public: - explicit pseudo_sentry(std::istream & r) : m_r(r), m_ok(r.ipfx(0)) { } - ~pseudo_sentry() { m_r.isfx(); } - operator bool() const { return m_ok; } - }; - -template -std::istream& -operator>>(std::istream& is, dynamic_bitset& b) -{ - -// Extractor for classic IO streams (libstdc++ < 3.0) -// ----------------------------------------------------// -// It's assumed that the stream buffer functions, and -// the stream's setstate() _cannot_ throw. - - - typedef dynamic_bitset bitset_type; - typedef typename bitset_type::size_type size_type; - - std::ios::iostate err = std::ios::goodbit; - pseudo_sentry cerberos(is); // skips whitespaces - if(cerberos) { - - b.clear(); - - const std::streamsize w = is.width(); - const size_type limit = w > 0 && static_cast(w) < b.max_size() - ? w : b.max_size(); - typename bitset_type::bit_appender appender(b); - std::streambuf * buf = is.rdbuf(); - for(int c = buf->sgetc(); appender.get_count() < limit; c = buf->snextc() ) { - - if (c == EOF) { - err |= std::ios::eofbit; - break; - } - else if (char(c) != '0' && char(c) != '1') - break; // non digit character - - else { - try { - appender.do_append(char(c) == '1'); - } - catch(...) { - is.setstate(std::ios::failbit); // assume this can't throw - throw; - } - } - - } // for - } - - is.width(0); - if (b.size() == 0) - err |= std::ios::failbit; - if (err != std::ios::goodbit) - is.setstate (err); // may throw - - return is; -} - -#else // BOOST_OLD_IOSTREAMS - -template -std::basic_istream& -operator>>(std::basic_istream& is, dynamic_bitset& b) -{ - - using namespace std; - - typedef dynamic_bitset bitset_type; - typedef typename bitset_type::size_type size_type; - - const streamsize w = is.width(); - const size_type limit = 0 < w && static_cast(w) < b.max_size()? - w : b.max_size(); - - ios_base::iostate err = ios_base::goodbit; - typename basic_istream::sentry cerberos(is); // skips whitespaces - if(cerberos) { - - // in accordance with prop. resol. of lib DR 303 [last checked 4 Feb 2004] - BOOST_DYNAMIC_BITSET_CTYPE_FACET(Ch, fac, is.getloc()); - const Ch zero = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '0'); - const Ch one = BOOST_DYNAMIC_BITSET_WIDEN_CHAR(fac, '1'); - - b.clear(); - try { - typename bitset_type::bit_appender appender(b); - basic_streambuf * buf = is.rdbuf(); - typename Tr::int_type c = buf->sgetc(); - for( ; appender.get_count() < limit; c = buf->snextc() ) { - - if (Tr::eq_int_type(Tr::eof(), c)) { - err |= ios_base::eofbit; - break; - } - else { - const Ch to_c = Tr::to_char_type(c); - const bool is_one = Tr::eq(to_c, one); - - if (!is_one && !Tr::eq(to_c, zero)) - break; // non digit character - - appender.do_append(is_one); - - } - - } // for - } - catch (...) { - // catches from stream buf, or from vector: - // - // bits_stored bits have been extracted and stored, and - // either no further character is extractable or we can't - // append to the underlying vector (out of memory) - - bool rethrow = false; // see std 27.6.1.1/4 - try { is.setstate(ios_base::badbit); } - catch(...) { rethrow = true; } - - if (rethrow) - throw; - - } - } - - is.width(0); - if (b.size() == 0 /*|| !cerberos*/) - err |= ios_base::failbit; - if (err != ios_base::goodbit) - is.setstate (err); // may throw - - return is; - -} - - -#endif - - -//----------------------------------------------------------------------------- -// bitset operations - -template -dynamic_bitset -operator&(const dynamic_bitset& x, - const dynamic_bitset& y) -{ - dynamic_bitset b(x); - return b &= y; -} - -template -dynamic_bitset -operator|(const dynamic_bitset& x, - const dynamic_bitset& y) -{ - dynamic_bitset b(x); - return b |= y; -} - -template -dynamic_bitset -operator^(const dynamic_bitset& x, - const dynamic_bitset& y) -{ - dynamic_bitset b(x); - return b ^= y; -} - -template -dynamic_bitset -operator-(const dynamic_bitset& x, - const dynamic_bitset& y) -{ - dynamic_bitset b(x); - return b -= y; -} - -//----------------------------------------------------------------------------- -// namespace scope swap - -template -inline void -swap(dynamic_bitset& left, - dynamic_bitset& right) // no throw -{ - left.swap(right); -} - - -//----------------------------------------------------------------------------- -// private (on conforming compilers) member functions - - -template -inline typename dynamic_bitset::size_type -dynamic_bitset::calc_num_blocks(size_type num_bits) -{ - return num_bits / bits_per_block - + static_cast( num_bits % bits_per_block != 0 ); -} - -// gives a reference to the highest block -// -template -inline Block& dynamic_bitset::m_highest_block() -{ - return const_cast - (static_cast(this)->m_highest_block()); -} - -// gives a const-reference to the highest block -// -template -inline const Block& dynamic_bitset::m_highest_block() const -{ - assert(size() > 0 && num_blocks() > 0); - return m_bits.back(); -} - - -// If size() is not a multiple of bits_per_block -// then not all the bits in the last block are used. -// This function resets the unused bits (convenient -// for the implementation of many member functions) -// -template -inline void dynamic_bitset::m_zero_unused_bits() -{ - assert (num_blocks() == calc_num_blocks(m_num_bits)); - - // if != 0 this is the number of bits used in the last block - const block_width_type extra_bits = count_extra_bits(); - - if (extra_bits != 0) - m_highest_block() &= ~(~static_cast(0) << extra_bits); - -} - -// check class invariants -template -bool dynamic_bitset::m_check_invariants() const -{ - const block_width_type extra_bits = count_extra_bits(); - if (extra_bits > 0) { - block_type const mask = (~static_cast(0) << extra_bits); - if ((m_highest_block() & mask) != 0) - return false; - } - if (m_bits.size() > m_bits.capacity() || num_blocks() != calc_num_blocks(size())) - return false; - - return true; - -} - - -} // namespace boost - - -#undef BOOST_BITSET_CHAR - -#endif // include guard - diff --git a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset_fwd.hpp deleted file mode 100644 index 7bb6e897..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/dynamic_bitset_fwd.hpp +++ /dev/null @@ -1,25 +0,0 @@ -// ----------------------------------------------------------- -// -// Copyright (c) 2001-2002 Chuck Allison and Jeremy Siek -// Copyright (c) 2003-2004 Gennaro Prota -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// ----------------------------------------------------------- - -#ifndef BOOST_DYNAMIC_BITSET_FWD_HPP -#define BOOST_DYNAMIC_BITSET_FWD_HPP - -#include - -namespace boost { - -template > -class dynamic_bitset; - -} - -#endif // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/enable_shared_from_this.hpp b/third_party/ycmd/cpp/BoostParts/boost/enable_shared_from_this.hpp deleted file mode 100644 index b1bb63d9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/enable_shared_from_this.hpp +++ /dev/null @@ -1,18 +0,0 @@ -#ifndef BOOST_ENABLE_SHARED_FROM_THIS_HPP_INCLUDED -#define BOOST_ENABLE_SHARED_FROM_THIS_HPP_INCLUDED - -// -// enable_shared_from_this.hpp -// -// Copyright (c) 2002 Peter Dimov -// -// Distributed under the Boost Software License, Version 1.0. -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt -// -// http://www.boost.org/libs/smart_ptr/enable_shared_from_this.html -// - -#include - -#endif // #ifndef BOOST_ENABLE_SHARED_FROM_THIS_HPP_INCLUDED diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/all.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/all.hpp deleted file mode 100644 index 32eb1505..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/all.hpp +++ /dev/null @@ -1,36 +0,0 @@ -//Copyright (c) 2006-2008 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_316FDA946C0D11DEA9CBAE5255D89593 -#define UUID_316FDA946C0D11DEA9CBAE5255D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef BOOST_NO_EXCEPTIONS -#include -#include -#endif - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/current_exception_cast.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/current_exception_cast.hpp deleted file mode 100644 index 5d81f00b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/current_exception_cast.hpp +++ /dev/null @@ -1,43 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_7E83C166200811DE885E826156D89593 -#define UUID_7E83C166200811DE885E826156D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -namespace -boost - { - template - inline - E * - current_exception_cast() - { - try - { - throw; - } - catch( - E & e ) - { - return &e; - } - catch( - ...) - { - return 0; - } - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/attribute_noreturn.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/attribute_noreturn.hpp deleted file mode 100644 index ae9f031e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/attribute_noreturn.hpp +++ /dev/null @@ -1,17 +0,0 @@ -//Copyright (c) 2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_61531AB0680611DEADD5846855D89593 -#define UUID_61531AB0680611DEADD5846855D89593 - -#if defined(_MSC_VER) -#define BOOST_ATTRIBUTE_NORETURN __declspec(noreturn) -#elif defined(__GNUC__) -#define BOOST_ATTRIBUTE_NORETURN __attribute__((__noreturn__)) -#else -#define BOOST_ATTRIBUTE_NORETURN -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/clone_current_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/clone_current_exception.hpp deleted file mode 100644 index 6fc13747..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/clone_current_exception.hpp +++ /dev/null @@ -1,56 +0,0 @@ -//Copyright (c) 2006-2013 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_81522C0EB56511DFAB613DB0DFD72085 -#define UUID_81522C0EB56511DFAB613DB0DFD72085 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#ifdef BOOST_NO_EXCEPTIONS -# error This header requires exception handling to be enabled. -#endif - -namespace -boost - { - namespace - exception_detail - { - class clone_base; - -#ifdef BOOST_ENABLE_NON_INTRUSIVE_EXCEPTION_PTR - int clone_current_exception_non_intrusive( clone_base const * & cloned ); -#endif - - namespace - clone_current_exception_result - { - int const success=0; - int const bad_alloc=1; - int const bad_exception=2; - int const not_supported=3; - } - - inline - int - clone_current_exception( clone_base const * & cloned ) - { -#ifdef BOOST_ENABLE_NON_INTRUSIVE_EXCEPTION_PTR - return clone_current_exception_non_intrusive(cloned); -#else - return clone_current_exception_result::not_supported; -#endif - } - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/error_info_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/error_info_impl.hpp deleted file mode 100644 index 12e601b5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/error_info_impl.hpp +++ /dev/null @@ -1,74 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_CE6983AC753411DDA764247956D89593 -#define UUID_CE6983AC753411DDA764247956D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include - -namespace -boost - { - namespace - exception_detail - { - class - error_info_base - { - public: - - virtual std::string name_value_string() const = 0; - - protected: - - virtual - ~error_info_base() throw() - { - } - }; - } - - template - class - error_info: - public exception_detail::error_info_base - { - public: - - typedef T value_type; - - error_info( value_type const & value ); - ~error_info() throw(); - - value_type const & - value() const - { - return value_; - } - - value_type & - value() - { - return value_; - } - - private: - - std::string name_value_string() const; - - value_type value_; - }; - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/exception_ptr.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/exception_ptr.hpp deleted file mode 100644 index 36298fa4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/exception_ptr.hpp +++ /dev/null @@ -1,513 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_618474C2DE1511DEB74A388C56D89593 -#define UUID_618474C2DE1511DEB74A388C56D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#ifdef BOOST_NO_EXCEPTIONS -#error This header requires exception handling to be enabled. -#endif -#include -#include -#include -#include -#include -//#ifndef BOOST_NO_RTTI -//#include -//#endif -#include -#include -#include -#include -#include - -namespace -boost - { - class exception_ptr; - BOOST_ATTRIBUTE_NORETURN void rethrow_exception( exception_ptr const & ); - exception_ptr current_exception(); - - class - exception_ptr - { - typedef boost::shared_ptr impl; - impl ptr_; - friend void rethrow_exception( exception_ptr const & ); - typedef exception_detail::clone_base const * (impl::*unspecified_bool_type)() const; - public: - exception_ptr() - { - } - explicit - exception_ptr( impl const & ptr ): - ptr_(ptr) - { - } - bool - operator==( exception_ptr const & other ) const - { - return ptr_==other.ptr_; - } - bool - operator!=( exception_ptr const & other ) const - { - return ptr_!=other.ptr_; - } - operator unspecified_bool_type() const - { - return ptr_?&impl::get:0; - } - }; - - template - inline - exception_ptr - copy_exception( T const & e ) - { - try - { - throw enable_current_exception(e); - } - catch( - ... ) - { - return current_exception(); - } - } - -#ifndef BOOST_NO_RTTI - typedef error_info original_exception_type; - - inline - std::string - to_string( original_exception_type const & x ) - { - return /*units::detail::demangle*/(x.value()->name()); - } -#endif - - namespace - exception_detail - { - struct - bad_alloc_: - boost::exception, - std::bad_alloc - { - ~bad_alloc_() throw() { } - }; - - struct - bad_exception_: - boost::exception, - std::bad_exception - { - ~bad_exception_() throw() { } - }; - - template - exception_ptr - get_static_exception_object() - { - Exception ba; - exception_detail::clone_impl c(ba); -#ifndef BOOST_EXCEPTION_DISABLE - c << - throw_function(BOOST_CURRENT_FUNCTION) << - throw_file(__FILE__) << - throw_line(__LINE__); -#endif - static exception_ptr ep(shared_ptr(new exception_detail::clone_impl(c))); - return ep; - } - - template - struct - exception_ptr_static_exception_object - { - static exception_ptr const e; - }; - - template - exception_ptr const - exception_ptr_static_exception_object:: - e = get_static_exception_object(); - } - -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility push (default) -# endif -#endif - class - unknown_exception: - public boost::exception, - public std::exception - { - public: - - unknown_exception() - { - } - - explicit - unknown_exception( std::exception const & e ) - { - add_original_type(e); - } - - explicit - unknown_exception( boost::exception const & e ): - boost::exception(e) - { - add_original_type(e); - } - - ~unknown_exception() throw() - { - } - - private: - - template - void - add_original_type( E const & e ) - { -#ifndef BOOST_NO_RTTI - (*this) << original_exception_type(&typeid(e)); -#endif - } - }; -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility pop -# endif -#endif - - namespace - exception_detail - { - template - class - current_exception_std_exception_wrapper: - public T, - public boost::exception - { - public: - - explicit - current_exception_std_exception_wrapper( T const & e1 ): - T(e1) - { - add_original_type(e1); - } - - current_exception_std_exception_wrapper( T const & e1, boost::exception const & e2 ): - T(e1), - boost::exception(e2) - { - add_original_type(e1); - } - - ~current_exception_std_exception_wrapper() throw() - { - } - - private: - - template - void - add_original_type( E const & e ) - { -#ifndef BOOST_NO_RTTI - (*this) << original_exception_type(&typeid(e)); -#endif - } - }; - -#ifdef BOOST_NO_RTTI - template - boost::exception const * - get_boost_exception( T const * ) - { - try - { - throw; - } - catch( - boost::exception & x ) - { - return &x; - } - catch(...) - { - return 0; - } - } -#else - template - boost::exception const * - get_boost_exception( T const * x ) - { - return dynamic_cast(x); - } -#endif - - template - inline - exception_ptr - current_exception_std_exception( T const & e1 ) - { - if( boost::exception const * e2 = get_boost_exception(&e1) ) - return boost::copy_exception(current_exception_std_exception_wrapper(e1,*e2)); - else - return boost::copy_exception(current_exception_std_exception_wrapper(e1)); - } - - inline - exception_ptr - current_exception_unknown_exception() - { - return boost::copy_exception(unknown_exception()); - } - - inline - exception_ptr - current_exception_unknown_boost_exception( boost::exception const & e ) - { - return boost::copy_exception(unknown_exception(e)); - } - - inline - exception_ptr - current_exception_unknown_std_exception( std::exception const & e ) - { - if( boost::exception const * be = get_boost_exception(&e) ) - return current_exception_unknown_boost_exception(*be); - else - return boost::copy_exception(unknown_exception(e)); - } - - inline - exception_ptr - current_exception_impl() - { - exception_detail::clone_base const * e=0; - switch( - exception_detail::clone_current_exception(e) ) - { - case exception_detail::clone_current_exception_result:: - success: - { - BOOST_ASSERT(e!=0); - return exception_ptr(shared_ptr(e)); - } - case exception_detail::clone_current_exception_result:: - bad_alloc: - { - BOOST_ASSERT(!e); - return exception_detail::exception_ptr_static_exception_object::e; - } - case exception_detail::clone_current_exception_result:: - bad_exception: - { - BOOST_ASSERT(!e); - return exception_detail::exception_ptr_static_exception_object::e; - } - default: - BOOST_ASSERT(0); - case exception_detail::clone_current_exception_result:: - not_supported: - { - BOOST_ASSERT(!e); - try - { - throw; - } - catch( - exception_detail::clone_base & e ) - { - return exception_ptr(shared_ptr(e.clone())); - } - catch( - std::domain_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::invalid_argument & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::length_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::out_of_range & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::logic_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::range_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::overflow_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::underflow_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::ios_base::failure & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::runtime_error & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::bad_alloc & e ) - { - return exception_detail::current_exception_std_exception(e); - } -#ifndef BOOST_NO_TYPEID - catch( - std::bad_cast & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::bad_typeid & e ) - { - return exception_detail::current_exception_std_exception(e); - } -#endif - catch( - std::bad_exception & e ) - { - return exception_detail::current_exception_std_exception(e); - } - catch( - std::exception & e ) - { - return exception_detail::current_exception_unknown_std_exception(e); - } - catch( - boost::exception & e ) - { - return exception_detail::current_exception_unknown_boost_exception(e); - } - catch( - ... ) - { - return exception_detail::current_exception_unknown_exception(); - } - } - } - } - } - - inline - exception_ptr - current_exception() - { - exception_ptr ret; - try - { - ret=exception_detail::current_exception_impl(); - } - catch( - std::bad_alloc & ) - { - ret=exception_detail::exception_ptr_static_exception_object::e; - } - catch( - ... ) - { - ret=exception_detail::exception_ptr_static_exception_object::e; - } - BOOST_ASSERT(ret); - return ret; - } - - BOOST_ATTRIBUTE_NORETURN - inline - void - rethrow_exception( exception_ptr const & p ) - { - BOOST_ASSERT(p); - p.ptr_->rethrow(); - BOOST_ASSERT(0); - #if defined(UNDER_CE) - // some CE platforms don't define ::abort() - exit(-1); - #else - abort(); - #endif - } - - inline - std::string - diagnostic_information( exception_ptr const & p, bool verbose=true ) - { - if( p ) - try - { - rethrow_exception(p); - } - catch( - ... ) - { - return current_exception_diagnostic_information(verbose); - } - return ""; - } - - inline - std::string - to_string( exception_ptr const & p ) - { - std::string s='\n'+diagnostic_information(p); - std::string padding(" "); - std::string r; - bool f=false; - for( std::string::const_iterator i=s.begin(),e=s.end(); i!=e; ++i ) - { - if( f ) - r+=padding; - char c=*i; - r+=c; - f=(c=='\n'); - } - return r; - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/is_output_streamable.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/is_output_streamable.hpp deleted file mode 100644 index 847f3484..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/is_output_streamable.hpp +++ /dev/null @@ -1,60 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_898984B4076411DD973EDFA055D89593 -#define UUID_898984B4076411DD973EDFA055D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include - -namespace -boost - { - namespace - to_string_detail - { - struct - partial_ordering_helper1 - { - template - partial_ordering_helper1( std::basic_ostream & ); - }; - - struct - partial_ordering_helper2 - { - template - partial_ordering_helper2( T const & ); - }; - - char operator<<( partial_ordering_helper1, partial_ordering_helper2 ); - - template - struct - is_output_streamable_impl - { - static std::basic_ostream & f(); - static T const & g(); - enum e { value=1!=(sizeof(f()< > - struct - is_output_streamable - { - enum e { value=to_string_detail::is_output_streamable_impl::value }; - }; - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/object_hex_dump.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/object_hex_dump.hpp deleted file mode 100644 index 53c8bf6f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/object_hex_dump.hpp +++ /dev/null @@ -1,50 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_6F463AC838DF11DDA3E6909F56D89593 -#define UUID_6F463AC838DF11DDA3E6909F56D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -#include -#include -#include - -namespace -boost - { - namespace - exception_detail - { - template - inline - std::string - object_hex_dump( T const & x, std::size_t max_size=16 ) - { - std::ostringstream s; - s << "type: " << type_name() << ", size: " << sizeof(T) << ", dump: "; - std::size_t n=sizeof(T)>max_size?max_size:sizeof(T); - s.fill('0'); - s.width(2); - unsigned char const * b=reinterpret_cast(&x); - s << std::setw(2) << std::hex << (unsigned int)*b; - for( unsigned char const * e=b+n; ++b!=e; ) - s << " " << std::setw(2) << std::hex << (unsigned int)*b; - return s.str(); - } - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/type_info.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/detail/type_info.hpp deleted file mode 100644 index 0af8ef52..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/detail/type_info.hpp +++ /dev/null @@ -1,83 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_C3E1741C754311DDB2834CCA55D89593 -#define UUID_C3E1741C754311DDB2834CCA55D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -//#ifndef BOOST_NO_TYPEID -//#include -//#endif -#include - -namespace -boost - { - template - inline - std::string - tag_type_name() - { -#ifdef BOOST_NO_TYPEID - return BOOST_CURRENT_FUNCTION; -#else - return /*units::detail::demangle*/(typeid(T*).name()); -#endif - } - - template - inline - std::string - type_name() - { -#ifdef BOOST_NO_TYPEID - return BOOST_CURRENT_FUNCTION; -#else - return /*units::detail::demangle*/(typeid(T).name()); -#endif - } - - namespace - exception_detail - { - struct - type_info_ - { - detail::sp_typeinfo const * type_; - - explicit - type_info_( detail::sp_typeinfo const & type ): - type_(&type) - { - } - - friend - bool - operator<( type_info_ const & a, type_info_ const & b ) - { - return 0!=(a.type_->before(*b.type_)); - } - }; - } - } - -#define BOOST_EXCEPTION_STATIC_TYPEID(T) ::boost::exception_detail::type_info_(BOOST_SP_TYPEID(T)) - -#ifndef BOOST_NO_RTTI -#define BOOST_EXCEPTION_DYNAMIC_TYPEID(x) ::boost::exception_detail::type_info_(typeid(x)) -#endif - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/diagnostic_information.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/diagnostic_information.hpp deleted file mode 100644 index 7889c8f9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/diagnostic_information.hpp +++ /dev/null @@ -1,201 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_0552D49838DD11DD90146B8956D89593 -#define UUID_0552D49838DD11DD90146B8956D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -#include -//#ifndef BOOST_NO_RTTI -//#include -//#endif -#include -#include -#include - -#ifndef BOOST_NO_EXCEPTIONS -#include -namespace -boost - { - namespace - exception_detail - { - std::string diagnostic_information_impl( boost::exception const *, std::exception const *, bool, bool ); - } - - inline - std::string - current_exception_diagnostic_information( bool verbose=true) - { - boost::exception const * be=current_exception_cast(); - std::exception const * se=current_exception_cast(); - if( be || se ) - return exception_detail::diagnostic_information_impl(be,se,true,verbose); - else - return "No diagnostic information available."; - } - } -#endif - -namespace -boost - { - namespace - exception_detail - { - inline - exception const * - get_boost_exception( exception const * e ) - { - return e; - } - - inline - exception const * - get_boost_exception( ... ) - { - return 0; - } - - inline - std::exception const * - get_std_exception( std::exception const * e ) - { - return e; - } - - inline - std::exception const * - get_std_exception( ... ) - { - return 0; - } - - inline - char const * - get_diagnostic_information( exception const & x, char const * header ) - { -#ifndef BOOST_NO_EXCEPTIONS - try - { -#endif - error_info_container * c=x.data_.get(); - if( !c ) - x.data_.adopt(c=new exception_detail::error_info_container_impl); - char const * di=c->diagnostic_information(header); - BOOST_ASSERT(di!=0); - return di; -#ifndef BOOST_NO_EXCEPTIONS - } - catch(...) - { - return 0; - } -#endif - } - - inline - std::string - diagnostic_information_impl( boost::exception const * be, std::exception const * se, bool with_what, bool verbose ) - { - if( !be && !se ) - return "Unknown exception."; -#ifndef BOOST_NO_RTTI - if( !be ) - be=dynamic_cast(se); - if( !se ) - se=dynamic_cast(be); -#endif - char const * wh=0; - if( with_what && se ) - { - wh=se->what(); - if( be && exception_detail::get_diagnostic_information(*be,0)==wh ) - return wh; - } - std::ostringstream tmp; - if( be && verbose ) - { - char const * const * f=get_error_info(*be); - int const * l=get_error_info(*be); - char const * const * fn=get_error_info(*be); - if( !f && !l && !fn ) - tmp << "Throw location unknown (consider using BOOST_THROW_EXCEPTION)\n"; - else - { - if( f ) - { - tmp << *f; - if( int const * l=get_error_info(*be) ) - tmp << '(' << *l << "): "; - } - tmp << "Throw in function "; - if( char const * const * fn=get_error_info(*be) ) - tmp << *fn; - else - tmp << "(unknown)"; - tmp << '\n'; - } - } -#ifndef BOOST_NO_RTTI - if ( verbose ) - tmp << std::string("Dynamic exception type: ") << - /*units::detail::demangle*/((be?(BOOST_EXCEPTION_DYNAMIC_TYPEID(*be)):(BOOST_EXCEPTION_DYNAMIC_TYPEID(*se))).type_->name()) << '\n'; -#endif - if( with_what && se && verbose ) - tmp << "std::exception::what: " << wh << '\n'; - if( be ) - if( char const * s=exception_detail::get_diagnostic_information(*be,tmp.str().c_str()) ) - if( *s ) - return std::string(s); - return tmp.str(); - } - } - - template - std::string - diagnostic_information( T const & e, bool verbose=true ) - { - return exception_detail::diagnostic_information_impl(exception_detail::get_boost_exception(&e),exception_detail::get_std_exception(&e),true,verbose); - } - - inline - char const * - diagnostic_information_what( exception const & e, bool verbose=true ) throw() - { - char const * w=0; -#ifndef BOOST_NO_EXCEPTIONS - try - { -#endif - (void) exception_detail::diagnostic_information_impl(&e,0,false,verbose); - if( char const * di=exception_detail::get_diagnostic_information(e,0) ) - return di; - else - return "Failed to produce boost::diagnostic_information_what()"; -#ifndef BOOST_NO_EXCEPTIONS - } - catch( - ... ) - { - } -#endif - return w; - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_api_function.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_api_function.hpp deleted file mode 100644 index 481c6131..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_api_function.hpp +++ /dev/null @@ -1,22 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_DDFBB4546C1211DEA4659E9055D89593 -#define UUID_DDFBB4546C1211DEA4659E9055D89593 - -#include "boost/exception/error_info.hpp" - -namespace -boost - { - //Usage hint: - //if( api_function(....)!=0 ) - // BOOST_THROW_EXCEPTION( - // failure() << - // errinfo_api_function("api_function") ); - typedef error_info errinfo_api_function; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_at_line.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_at_line.hpp deleted file mode 100644 index cbd5ccef..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_at_line.hpp +++ /dev/null @@ -1,18 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_E7255CE26C1211DE85800C9155D89593 -#define UUID_E7255CE26C1211DE85800C9155D89593 - -namespace -boost - { - template class error_info; - - //Use with parsing errors exceptions, for example in a XML file parser. - typedef error_info errinfo_at_line; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_errno.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_errno.hpp deleted file mode 100644 index 2cf7cabe..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_errno.hpp +++ /dev/null @@ -1,44 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_F0EE17BE6C1211DE87FF459155D89593 -#define UUID_F0EE17BE6C1211DE87FF459155D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include "boost/exception/info.hpp" -#include -#include - -namespace -boost - { - typedef error_info errinfo_errno; - - //Usage hint: - //if( c_function(....)!=0 ) - // BOOST_THROW_EXCEPTION( - // failure() << - // errinfo_errno(errno) << - // errinfo_api_function("c_function") ); - inline - std::string - to_string( errinfo_errno const & e ) - { - std::ostringstream tmp; - int v=e.value(); - tmp << v << ", \"" << strerror(v) << "\""; - return tmp.str(); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_handle.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_handle.hpp deleted file mode 100644 index 8e6cff8f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_handle.hpp +++ /dev/null @@ -1,20 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_F79E6EE26C1211DEB26E929155D89593 -#define UUID_F79E6EE26C1211DEB26E929155D89593 - -#include - -namespace -boost - { - template class weak_ptr; - template class error_info; - - typedef error_info > errinfo_file_handle; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_name.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_name.hpp deleted file mode 100644 index d3cce4d3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_name.hpp +++ /dev/null @@ -1,26 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_FEE5120A6C1211DE94E8BC9155D89593 -#define UUID_FEE5120A6C1211DE94E8BC9155D89593 - -#include - -namespace -boost - { - template class error_info; - - //Usage hint: - //FILE * f=fopen(name,mode); - //if( !f ) - // BOOST_THROW_EXCEPTION( - // file_open_error() << - // errinfo_file_name(name) << - // errinfo_file_open_mode(mode) ); - typedef error_info errinfo_file_name; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_open_mode.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_open_mode.hpp deleted file mode 100644 index f4fba0d5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_file_open_mode.hpp +++ /dev/null @@ -1,26 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_056F1F266C1311DE8E74299255D89593 -#define UUID_056F1F266C1311DE8E74299255D89593 - -#include - -namespace -boost - { - template class error_info; - - //Usage hint: - //FILE * f=fopen(name,mode); - //if( !f ) - // BOOST_THROW_EXCEPTION( - // file_open_error() << - // errinfo_file_name(name) << - // errinfo_file_open_mode(mode) ); - typedef error_info errinfo_file_open_mode; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_nested_exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_nested_exception.hpp deleted file mode 100644 index c3299d14..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_nested_exception.hpp +++ /dev/null @@ -1,18 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_45CC9A82B77511DEB330FC4956D89593 -#define UUID_45CC9A82B77511DEB330FC4956D89593 - -namespace -boost - { - namespace exception_detail { class clone_base; } - template class error_info; - class exception_ptr; - typedef error_info errinfo_nested_exception; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_type_info_name.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_type_info_name.hpp deleted file mode 100644 index 0b060e2e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/errinfo_type_info_name.hpp +++ /dev/null @@ -1,23 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_0E11109E6C1311DEB7EA649255D89593 -#define UUID_0E11109E6C1311DEB7EA649255D89593 - -#include - -namespace -boost - { - template class error_info; - - //Usage hint: - //BOOST_THROW_EXCEPTION( - // bad_type() << - // errinfo_type_info_name(typeid(x).name()) ); - typedef error_info errinfo_type_info_name; - } - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/error_info.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/error_info.hpp deleted file mode 100644 index 03b3da8e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/error_info.hpp +++ /dev/null @@ -1,9 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_EE7ECCA0433B11E1923E37064924019B -#define UUID_EE7ECCA0433B11E1923E37064924019B -namespace boost { template class error_info; } -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/exception.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/exception.hpp deleted file mode 100644 index 31d43178..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/exception.hpp +++ /dev/null @@ -1,483 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_274DA366004E11DCB1DDFE2E56D89593 -#define UUID_274DA366004E11DCB1DDFE2E56D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -namespace -boost - { - namespace - exception_detail - { - template - class - refcount_ptr - { - public: - - refcount_ptr(): - px_(0) - { - } - - ~refcount_ptr() - { - release(); - } - - refcount_ptr( refcount_ptr const & x ): - px_(x.px_) - { - add_ref(); - } - - refcount_ptr & - operator=( refcount_ptr const & x ) - { - adopt(x.px_); - return *this; - } - - void - adopt( T * px ) - { - release(); - px_=px; - add_ref(); - } - - T * - get() const - { - return px_; - } - - private: - - T * px_; - - void - add_ref() - { - if( px_ ) - px_->add_ref(); - } - - void - release() - { - if( px_ && px_->release() ) - px_=0; - } - }; - } - - //////////////////////////////////////////////////////////////////////// - - template - class error_info; - - typedef error_info throw_function; - typedef error_info throw_file; - typedef error_info throw_line; - - template <> - class - error_info - { - public: - typedef char const * value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - - template <> - class - error_info - { - public: - typedef char const * value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - - template <> - class - error_info - { - public: - typedef int value_type; - value_type v_; - explicit - error_info( value_type v ): - v_(v) - { - } - }; - -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility push (default) -# endif -#endif - class exception; -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility pop -# endif -#endif - - template - class shared_ptr; - - namespace - exception_detail - { - class error_info_base; - struct type_info_; - - struct - error_info_container - { - virtual char const * diagnostic_information( char const * ) const = 0; - virtual shared_ptr get( type_info_ const & ) const = 0; - virtual void set( shared_ptr const &, type_info_ const & ) = 0; - virtual void add_ref() const = 0; - virtual bool release() const = 0; - virtual refcount_ptr clone() const = 0; - - protected: - - ~error_info_container() throw() - { - } - }; - - template - struct get_info; - - template <> - struct get_info; - - template <> - struct get_info; - - template <> - struct get_info; - - char const * get_diagnostic_information( exception const &, char const * ); - - void copy_boost_exception( exception *, exception const * ); - - template - E const & set_info( E const &, error_info const & ); - - template - E const & set_info( E const &, throw_function const & ); - - template - E const & set_info( E const &, throw_file const & ); - - template - E const & set_info( E const &, throw_line const & ); - } - -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility push (default) -# endif -#endif - class - exception - { - protected: - - exception(): - throw_function_(0), - throw_file_(0), - throw_line_(-1) - { - } - -#ifdef __HP_aCC - //On HP aCC, this protected copy constructor prevents throwing boost::exception. - //On all other platforms, the same effect is achieved by the pure virtual destructor. - exception( exception const & x ) throw(): - data_(x.data_), - throw_function_(x.throw_function_), - throw_file_(x.throw_file_), - throw_line_(x.throw_line_) - { - } -#endif - - virtual ~exception() throw() -#ifndef __HP_aCC - = 0 //Workaround for HP aCC, =0 incorrectly leads to link errors. -#endif - ; - -#if (defined(__MWERKS__) && __MWERKS__<=0x3207) || (defined(_MSC_VER) && _MSC_VER<=1310) - public: -#else - private: - - template - friend E const & exception_detail::set_info( E const &, throw_function const & ); - - template - friend E const & exception_detail::set_info( E const &, throw_file const & ); - - template - friend E const & exception_detail::set_info( E const &, throw_line const & ); - - template - friend E const & exception_detail::set_info( E const &, error_info const & ); - - friend char const * exception_detail::get_diagnostic_information( exception const &, char const * ); - - template - friend struct exception_detail::get_info; - friend struct exception_detail::get_info; - friend struct exception_detail::get_info; - friend struct exception_detail::get_info; - friend void exception_detail::copy_boost_exception( exception *, exception const * ); -#endif - mutable exception_detail::refcount_ptr data_; - mutable char const * throw_function_; - mutable char const * throw_file_; - mutable int throw_line_; - }; -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility pop -# endif -#endif - - inline - exception:: - ~exception() throw() - { - } - - namespace - exception_detail - { - template - E const & - set_info( E const & x, throw_function const & y ) - { - x.throw_function_=y.v_; - return x; - } - - template - E const & - set_info( E const & x, throw_file const & y ) - { - x.throw_file_=y.v_; - return x; - } - - template - E const & - set_info( E const & x, throw_line const & y ) - { - x.throw_line_=y.v_; - return x; - } - } - - //////////////////////////////////////////////////////////////////////// - - namespace - exception_detail - { -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility push (default) -# endif -#endif - template - struct - error_info_injector: - public T, - public exception - { - explicit - error_info_injector( T const & x ): - T(x) - { - } - - ~error_info_injector() throw() - { - } - }; -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility pop -# endif -#endif - - struct large_size { char c[256]; }; - large_size dispatch_boost_exception( exception const * ); - - struct small_size { }; - small_size dispatch_boost_exception( void const * ); - - template - struct enable_error_info_helper; - - template - struct - enable_error_info_helper - { - typedef T type; - }; - - template - struct - enable_error_info_helper - { - typedef error_info_injector type; - }; - - template - struct - enable_error_info_return_type - { - typedef typename enable_error_info_helper(0)))>::type type; - }; - } - - template - inline - typename - exception_detail::enable_error_info_return_type::type - enable_error_info( T const & x ) - { - typedef typename exception_detail::enable_error_info_return_type::type rt; - return rt(x); - } - - //////////////////////////////////////////////////////////////////////// - - namespace - exception_detail - { -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility push (default) -# endif -#endif - class - clone_base - { - public: - - virtual clone_base const * clone() const = 0; - virtual void rethrow() const = 0; - - virtual - ~clone_base() throw() - { - } - }; -#if defined(__GNUC__) -# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4) -# pragma GCC visibility pop -# endif -#endif - - inline - void - copy_boost_exception( exception * a, exception const * b ) - { - refcount_ptr data; - if( error_info_container * d=b->data_.get() ) - data = d->clone(); - a->throw_file_ = b->throw_file_; - a->throw_line_ = b->throw_line_; - a->throw_function_ = b->throw_function_; - a->data_ = data; - } - - inline - void - copy_boost_exception( void *, void const * ) - { - } - - template - class - clone_impl: - public T, - public virtual clone_base - { - struct clone_tag { }; - clone_impl( clone_impl const & x, clone_tag ): - T(x) - { - copy_boost_exception(this,&x); - } - - public: - - explicit - clone_impl( T const & x ): - T(x) - { - copy_boost_exception(this,&x); - } - - ~clone_impl() throw() - { - } - - private: - - clone_base const * - clone() const - { - return new clone_impl(*this,clone_tag()); - } - - void - rethrow() const - { - throw*this; - } - }; - } - - template - inline - exception_detail::clone_impl - enable_current_exception( T const & x ) - { - return exception_detail::clone_impl(x); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/get_error_info.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/get_error_info.hpp deleted file mode 100644 index 96be7632..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/get_error_info.hpp +++ /dev/null @@ -1,130 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_1A590226753311DD9E4CCF6156D89593 -#define UUID_1A590226753311DD9E4CCF6156D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -#include - -namespace -boost - { - namespace - exception_detail - { - template - struct - get_info - { - static - typename ErrorInfo::value_type * - get( exception const & x ) - { - if( exception_detail::error_info_container * c=x.data_.get() ) - if( shared_ptr eib = c->get(BOOST_EXCEPTION_STATIC_TYPEID(ErrorInfo)) ) - { -#ifndef BOOST_NO_RTTI - BOOST_ASSERT( 0!=dynamic_cast(eib.get()) ); -#endif - ErrorInfo * w = static_cast(eib.get()); - return &w->value(); - } - return 0; - } - }; - - template <> - struct - get_info - { - static - char const * * - get( exception const & x ) - { - return x.throw_function_ ? &x.throw_function_ : 0; - } - }; - - template <> - struct - get_info - { - static - char const * * - get( exception const & x ) - { - return x.throw_file_ ? &x.throw_file_ : 0; - } - }; - - template <> - struct - get_info - { - static - int * - get( exception const & x ) - { - return x.throw_line_!=-1 ? &x.throw_line_ : 0; - } - }; - - template - struct - get_error_info_return_type - { - typedef R * type; - }; - - template - struct - get_error_info_return_type - { - typedef R const * type; - }; - } - -#ifdef BOOST_NO_RTTI - template - inline - typename ErrorInfo::value_type const * - get_error_info( boost::exception const & x ) - { - return exception_detail::get_info::get(x); - } - template - inline - typename ErrorInfo::value_type * - get_error_info( boost::exception & x ) - { - return exception_detail::get_info::get(x); - } -#else - template - inline - typename exception_detail::get_error_info_return_type::type - get_error_info( E & some_exception ) - { - if( exception const * x = dynamic_cast(&some_exception) ) - return exception_detail::get_info::get(*x); - else - return 0; - } -#endif - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/info.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/info.hpp deleted file mode 100644 index 762a950f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/info.hpp +++ /dev/null @@ -1,198 +0,0 @@ -//Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_8D22C4CA9CC811DCAA9133D256D89593 -#define UUID_8D22C4CA9CC811DCAA9133D256D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include -#include -#include -#include - -namespace -boost - { - template - inline - std::string - error_info_name( error_info const & x ) - { - return tag_type_name(); - } - - template - inline - std::string - to_string( error_info const & x ) - { - return '[' + error_info_name(x) + "] = " + to_string_stub(x.value()) + '\n'; - } - - template - inline - error_info:: - error_info( value_type const & value ): - value_(value) - { - } - - template - inline - error_info:: - ~error_info() throw() - { - } - - template - inline - std::string - error_info:: - name_value_string() const - { - return to_string_stub(*this); - } - - namespace - exception_detail - { - class - error_info_container_impl: - public error_info_container - { - public: - - error_info_container_impl(): - count_(0) - { - } - - ~error_info_container_impl() throw() - { - } - - void - set( shared_ptr const & x, type_info_ const & typeid_ ) - { - BOOST_ASSERT(x); - info_[typeid_] = x; - diagnostic_info_str_.clear(); - } - - shared_ptr - get( type_info_ const & ti ) const - { - error_info_map::const_iterator i=info_.find(ti); - if( info_.end()!=i ) - { - shared_ptr const & p = i->second; -#ifndef BOOST_NO_RTTI - BOOST_ASSERT( *BOOST_EXCEPTION_DYNAMIC_TYPEID(*p).type_==*ti.type_ ); -#endif - return p; - } - return shared_ptr(); - } - - char const * - diagnostic_information( char const * header ) const - { - if( header ) - { - std::ostringstream tmp; - tmp << header; - for( error_info_map::const_iterator i=info_.begin(),end=info_.end(); i!=end; ++i ) - { - error_info_base const & x = *i->second; - tmp << x.name_value_string(); - } - tmp.str().swap(diagnostic_info_str_); - } - return diagnostic_info_str_.c_str(); - } - - private: - - friend class boost::exception; - - typedef std::map< type_info_, shared_ptr > error_info_map; - error_info_map info_; - mutable std::string diagnostic_info_str_; - mutable int count_; - - error_info_container_impl( error_info_container_impl const & ); - error_info_container_impl & operator=( error_info_container const & ); - - void - add_ref() const - { - ++count_; - } - - bool - release() const - { - if( --count_ ) - return false; - else - { - delete this; - return true; - } - } - - refcount_ptr - clone() const - { - refcount_ptr p; - error_info_container_impl * c=new error_info_container_impl; - p.adopt(c); - c->info_ = info_; - return p; - } - }; - - template - inline - E const & - set_info( E const & x, error_info const & v ) - { - typedef error_info error_info_tag_t; - shared_ptr p( new error_info_tag_t(v) ); - exception_detail::error_info_container * c=x.data_.get(); - if( !c ) - x.data_.adopt(c=new exception_detail::error_info_container_impl); - c->set(p,BOOST_EXCEPTION_STATIC_TYPEID(error_info_tag_t)); - return x; - } - - template - struct - derives_boost_exception - { - enum e { value = (sizeof(dispatch_boost_exception((T*)0))==sizeof(large_size)) }; - }; - } - - template - inline - typename enable_if,E const &>::type - operator<<( E const & x, error_info const & v ) - { - return exception_detail::set_info(x,v); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/info_tuple.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/info_tuple.hpp deleted file mode 100644 index 70154fd2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/info_tuple.hpp +++ /dev/null @@ -1,100 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_63EE924290FB11DC87BB856555D89593 -#define UUID_63EE924290FB11DC87BB856555D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include - -namespace -boost - { - template < - class E > - inline - E const & - operator<<( - E const & x, - tuple< > const & v ) - { - return x; - } - - template < - class E, - class Tag1,class T1 > - inline - E const & - operator<<( - E const & x, - tuple< - error_info > const & v ) - { - return x << v.template get<0>(); - } - - template < - class E, - class Tag1,class T1, - class Tag2,class T2 > - inline - E const & - operator<<( - E const & x, - tuple< - error_info, - error_info > const & v ) - { - return x << v.template get<0>() << v.template get<1>(); - } - - template < - class E, - class Tag1,class T1, - class Tag2,class T2, - class Tag3,class T3 > - inline - E const & - operator<<( - E const & x, - tuple< - error_info, - error_info, - error_info > const & v ) - { - return x << v.template get<0>() << v.template get<1>() << v.template get<2>(); - } - - template < - class E, - class Tag1,class T1, - class Tag2,class T2, - class Tag3,class T3, - class Tag4,class T4 > - inline - E const & - operator<<( - E const & x, - tuple< - error_info, - error_info, - error_info, - error_info > const & v ) - { - return x << v.template get<0>() << v.template get<1>() << v.template get<2>() << v.template get<3>(); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/to_string.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/to_string.hpp deleted file mode 100644 index 68541d2b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/to_string.hpp +++ /dev/null @@ -1,88 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_7E48761AD92811DC9011477D56D89593 -#define UUID_7E48761AD92811DC9011477D56D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include - -namespace -boost - { - template - std::string to_string( std::pair const & ); - std::string to_string( std::exception const & ); - - namespace - to_string_detail - { - template - typename disable_if,char>::type to_string( T const & ); - using boost::to_string; - - template - struct has_to_string_impl; - - template - struct - has_to_string_impl - { - enum e { value=1 }; - }; - - template - struct - has_to_string_impl - { - static T const & f(); - enum e { value=1!=sizeof(to_string(f())) }; - }; - } - - template - inline - typename enable_if,std::string>::type - to_string( T const & x ) - { - std::ostringstream out; - out << x; - return out.str(); - } - - template - struct - has_to_string - { - enum e { value=to_string_detail::has_to_string_impl::value>::value }; - }; - - template - inline - std::string - to_string( std::pair const & x ) - { - return std::string("(") + to_string(x.first) + ',' + to_string(x.second) + ')'; - } - - inline - std::string - to_string( std::exception const & x ) - { - return x.what(); - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception/to_string_stub.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception/to_string_stub.hpp deleted file mode 100644 index b6ab31cf..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception/to_string_stub.hpp +++ /dev/null @@ -1,117 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_E788439ED9F011DCB181F25B55D89593 -#define UUID_E788439ED9F011DCB181F25B55D89593 -#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma GCC system_header -#endif -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(push,1) -#endif - -#include -#include -#include - -namespace -boost - { - namespace - exception_detail - { - template - struct - to_string_dispatcher - { - template - static - std::string - convert( T const & x, Stub ) - { - return to_string(x); - } - }; - - template <> - struct - to_string_dispatcher - { - template - static - std::string - convert( T const & x, Stub s ) - { - return s(x); - } - - template - static - std::string - convert( T const & x, std::string s ) - { - return s; - } - - template - static - std::string - convert( T const & x, char const * s ) - { - BOOST_ASSERT(s!=0); - return s; - } - }; - - namespace - to_string_dispatch - { - template - inline - std::string - dispatch( T const & x, Stub s ) - { - return to_string_dispatcher::value>::convert(x,s); - } - } - - template - inline - std::string - string_stub_dump( T const & x ) - { - return "[ " + exception_detail::object_hex_dump(x) + " ]"; - } - } - - template - inline - std::string - to_string_stub( T const & x ) - { - return exception_detail::to_string_dispatch::dispatch(x,&exception_detail::string_stub_dump); - } - - template - inline - std::string - to_string_stub( T const & x, Stub s ) - { - return exception_detail::to_string_dispatch::dispatch(x,s); - } - - template - inline - std::string - to_string_stub( std::pair const & x, Stub s ) - { - return std::string("(") + to_string_stub(x.first,s) + ',' + to_string_stub(x.second,s) + ')'; - } - } - -#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) -#pragma warning(pop) -#endif -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/exception_ptr.hpp b/third_party/ycmd/cpp/BoostParts/boost/exception_ptr.hpp deleted file mode 100644 index d48cce9d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/exception_ptr.hpp +++ /dev/null @@ -1,11 +0,0 @@ -//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc. - -//Distributed under the Boost Software License, Version 1.0. (See accompanying -//file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#ifndef UUID_FA5836A2CADA11DC8CD47C8555D89593 -#define UUID_FA5836A2CADA11DC8CD47C8555D89593 - -#include - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem.hpp deleted file mode 100644 index 1a753026..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem.hpp +++ /dev/null @@ -1,20 +0,0 @@ -// boost/filesystem.hpp --------------------------------------------------------------// - -// Copyright Beman Dawes 2010 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM_FILESYSTEM_HPP -#define BOOST_FILESYSTEM_FILESYSTEM_HPP - -# include -# include -# include -# include - -#endif // BOOST_FILESYSTEM_FILESYSTEM_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/config.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/config.hpp deleted file mode 100644 index ca695f41..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/config.hpp +++ /dev/null @@ -1,109 +0,0 @@ -// boost/filesystem/v3/config.hpp ----------------------------------------------------// - -// Copyright Beman Dawes 2003 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_CONFIG_HPP -#define BOOST_FILESYSTEM3_CONFIG_HPP - -# if defined(BOOST_FILESYSTEM_VERSION) && BOOST_FILESYSTEM_VERSION != 3 -# error Compiling Filesystem version 3 file with BOOST_FILESYSTEM_VERSION defined != 3 -# endif - -# if !defined(BOOST_FILESYSTEM_VERSION) -# define BOOST_FILESYSTEM_VERSION 3 -# endif - -#define BOOST_FILESYSTEM_I18N // aid users wishing to compile several versions - -// This header implements separate compilation features as described in -// http://www.boost.org/more/separate_compilation.html - -#include -#include // for BOOST_POSIX_API or BOOST_WINDOWS_API -#include - -// BOOST_FILESYSTEM_DEPRECATED needed for source compiles -----------------------------// - -# ifdef BOOST_FILESYSTEM_SOURCE -# define BOOST_FILESYSTEM_DEPRECATED -# endif - -// throw an exception ----------------------------------------------------------------// -// -// Exceptions were originally thrown via boost::throw_exception(). -// As throw_exception() became more complex, it caused user error reporting -// to be harder to interpret, since the exception reported became much more complex. -// The immediate fix was to throw directly, wrapped in a macro to make any later change -// easier. - -#define BOOST_FILESYSTEM_THROW(EX) throw EX - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -// This header implements separate compilation features as described in -// http://www.boost.org/more/separate_compilation.html - -// normalize macros ------------------------------------------------------------------// - -#if !defined(BOOST_FILESYSTEM_DYN_LINK) && !defined(BOOST_FILESYSTEM_STATIC_LINK) \ - && !defined(BOOST_ALL_DYN_LINK) && !defined(BOOST_ALL_STATIC_LINK) -# define BOOST_FILESYSTEM_STATIC_LINK -#endif - -#if defined(BOOST_ALL_DYN_LINK) && !defined(BOOST_FILESYSTEM_DYN_LINK) -# define BOOST_FILESYSTEM_DYN_LINK -#elif defined(BOOST_ALL_STATIC_LINK) && !defined(BOOST_FILESYSTEM_STATIC_LINK) -# define BOOST_FILESYSTEM_STATIC_LINK -#endif - -#if defined(BOOST_FILESYSTEM_DYN_LINK) && defined(BOOST_FILESYSTEM_STATIC_LINK) -# error Must not define both BOOST_FILESYSTEM_DYN_LINK and BOOST_FILESYSTEM_STATIC_LINK -#endif - -#if defined(BOOST_ALL_NO_LIB) && !defined(BOOST_FILESYSTEM_NO_LIB) -# define BOOST_FILESYSTEM_NO_LIB -#endif - -// enable dynamic linking ------------------------------------------------------------// - -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_FILESYSTEM_DYN_LINK) -# if defined(BOOST_FILESYSTEM_SOURCE) -# define BOOST_FILESYSTEM_DECL BOOST_SYMBOL_EXPORT -# else -# define BOOST_FILESYSTEM_DECL BOOST_SYMBOL_IMPORT -# endif -#else -# define BOOST_FILESYSTEM_DECL -#endif - -// enable automatic library variant selection ----------------------------------------// - -#if !defined(BOOST_FILESYSTEM_SOURCE) && !defined(BOOST_ALL_NO_LIB) \ - && !defined(BOOST_FILESYSTEM_NO_LIB) -// -// Set the name of our library, this will get undef'ed by auto_link.hpp -// once it's done with it: -// -#define BOOST_LIB_NAME boost_filesystem -// -// If we're importing code from a dll, then tell auto_link.hpp about it: -// -#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_FILESYSTEM_DYN_LINK) -# define BOOST_DYN_LINK -#endif -// -// And include the header that does the work: -// -#include -#endif // auto-linking disabled - -#endif // BOOST_FILESYSTEM3_CONFIG_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/convenience.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/convenience.hpp deleted file mode 100644 index f0bd9869..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/convenience.hpp +++ /dev/null @@ -1,58 +0,0 @@ -// boost/filesystem/convenience.hpp ----------------------------------------// - -// Copyright Beman Dawes, 2002-2005 -// Copyright Vladimir Prus, 2002 -// Use, modification, and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// See library home page at http://www.boost.org/libs/filesystem - -//----------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_CONVENIENCE_HPP -#define BOOST_FILESYSTEM3_CONVENIENCE_HPP - -#include - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include -#include - -#include // must be the last #include - -namespace boost -{ - namespace filesystem - { - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - - inline std::string extension(const path & p) - { - return p.extension().string(); - } - - inline std::string basename(const path & p) - { - return p.stem().string(); - } - - inline path change_extension( const path & p, const path & new_extension ) - { - path new_p( p ); - new_p.replace_extension( new_extension ); - return new_p; - } - -# endif - - - } // namespace filesystem -} // namespace boost - -#include // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_CONVENIENCE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/detail/utf8_codecvt_facet.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/detail/utf8_codecvt_facet.hpp deleted file mode 100644 index 3b78fb1b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/detail/utf8_codecvt_facet.hpp +++ /dev/null @@ -1,24 +0,0 @@ -// Copyright (c) 2001 Ronald Garcia, Indiana University (garcia@osl.iu.edu) -// Andrew Lumsdaine, Indiana University (lums@osl.iu.edu). - -// Distributed under the Boost Software License, Version 1.0. -// (See http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_FILESYSTEM_UTF8_CODECVT_FACET_HPP -#define BOOST_FILESYSTEM_UTF8_CODECVT_FACET_HPP - -#include - -#define BOOST_UTF8_BEGIN_NAMESPACE \ - namespace boost { namespace filesystem { namespace detail { - -#define BOOST_UTF8_END_NAMESPACE }}} -#define BOOST_UTF8_DECL BOOST_FILESYSTEM_DECL - -#include - -#undef BOOST_UTF8_BEGIN_NAMESPACE -#undef BOOST_UTF8_END_NAMESPACE -#undef BOOST_UTF8_DECL - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/fstream.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/fstream.hpp deleted file mode 100644 index 07272388..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/fstream.hpp +++ /dev/null @@ -1,182 +0,0 @@ -// boost/filesystem/fstream.hpp ------------------------------------------------------// - -// Copyright Beman Dawes 2002 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_FSTREAM_HPP -#define BOOST_FILESYSTEM3_FSTREAM_HPP - -#include - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include -#include -#include - -#include // must be the last #include - -// on Windows, except for standard libaries known to have wchar_t overloads for -// file stream I/O, use path::string() to get a narrow character c_str() -#if defined(BOOST_WINDOWS_API) \ - && (!defined(_CPPLIB_VER) || _CPPLIB_VER < 405 || defined(_STLPORT_VERSION)) - // !Dinkumware || early Dinkumware || STLPort masquerading as Dinkumware -# define BOOST_FILESYSTEM_C_STR string().c_str() // use narrow, since wide not available -#else // use the native c_str, which will be narrow on POSIX, wide on Windows -# define BOOST_FILESYSTEM_C_STR c_str() -#endif - -namespace boost -{ -namespace filesystem -{ - -//--------------------------------------------------------------------------------------// -// basic_filebuf // -//--------------------------------------------------------------------------------------// - - template < class charT, class traits = std::char_traits > - class basic_filebuf : public std::basic_filebuf - { - private: // disallow copying - basic_filebuf(const basic_filebuf&); - const basic_filebuf& operator=(const basic_filebuf&); - - public: - basic_filebuf() {} - virtual ~basic_filebuf() {} - - basic_filebuf* - open(const path& p, std::ios_base::openmode mode) - { - return std::basic_filebuf::open(p.BOOST_FILESYSTEM_C_STR, mode) - ? this : 0; - } - }; - -//--------------------------------------------------------------------------------------// -// basic_ifstream // -//--------------------------------------------------------------------------------------// - - template < class charT, class traits = std::char_traits > - class basic_ifstream : public std::basic_ifstream - { - private: // disallow copying - basic_ifstream(const basic_ifstream&); - const basic_ifstream& operator=(const basic_ifstream&); - - public: - basic_ifstream() {} - - // use two signatures, rather than one signature with default second - // argument, to workaround VC++ 7.1 bug (ID VSWhidbey 38416) - - explicit basic_ifstream(const path& p) - : std::basic_ifstream(p.BOOST_FILESYSTEM_C_STR, std::ios_base::in) {} - - basic_ifstream(const path& p, std::ios_base::openmode mode) - : std::basic_ifstream(p.BOOST_FILESYSTEM_C_STR, mode) {} - - void open(const path& p) - { std::basic_ifstream::open(p.BOOST_FILESYSTEM_C_STR, std::ios_base::in); } - - void open(const path& p, std::ios_base::openmode mode) - { std::basic_ifstream::open(p.BOOST_FILESYSTEM_C_STR, mode); } - - virtual ~basic_ifstream() {} - }; - -//--------------------------------------------------------------------------------------// -// basic_ofstream // -//--------------------------------------------------------------------------------------// - - template < class charT, class traits = std::char_traits > - class basic_ofstream : public std::basic_ofstream - { - private: // disallow copying - basic_ofstream(const basic_ofstream&); - const basic_ofstream& operator=(const basic_ofstream&); - - public: - basic_ofstream() {} - - // use two signatures, rather than one signature with default second - // argument, to workaround VC++ 7.1 bug (ID VSWhidbey 38416) - - explicit basic_ofstream(const path& p) - : std::basic_ofstream(p.BOOST_FILESYSTEM_C_STR, std::ios_base::out) {} - - basic_ofstream(const path& p, std::ios_base::openmode mode) - : std::basic_ofstream(p.BOOST_FILESYSTEM_C_STR, mode) {} - - void open(const path& p) - { std::basic_ofstream::open(p.BOOST_FILESYSTEM_C_STR, std::ios_base::out); } - - void open(const path& p, std::ios_base::openmode mode) - { std::basic_ofstream::open(p.BOOST_FILESYSTEM_C_STR, mode); } - - virtual ~basic_ofstream() {} - }; - -//--------------------------------------------------------------------------------------// -// basic_fstream // -//--------------------------------------------------------------------------------------// - - template < class charT, class traits = std::char_traits > - class basic_fstream : public std::basic_fstream - { - private: // disallow copying - basic_fstream(const basic_fstream&); - const basic_fstream & operator=(const basic_fstream&); - - public: - basic_fstream() {} - - // use two signatures, rather than one signature with default second - // argument, to workaround VC++ 7.1 bug (ID VSWhidbey 38416) - - explicit basic_fstream(const path& p) - : std::basic_fstream(p.BOOST_FILESYSTEM_C_STR, - std::ios_base::in | std::ios_base::out) {} - - basic_fstream(const path& p, std::ios_base::openmode mode) - : std::basic_fstream(p.BOOST_FILESYSTEM_C_STR, mode) {} - - void open(const path& p) - { std::basic_fstream::open(p.BOOST_FILESYSTEM_C_STR, - std::ios_base::in | std::ios_base::out); } - - void open(const path& p, std::ios_base::openmode mode) - { std::basic_fstream::open(p.BOOST_FILESYSTEM_C_STR, mode); } - - virtual ~basic_fstream() {} - - }; - -//--------------------------------------------------------------------------------------// -// typedefs // -//--------------------------------------------------------------------------------------// - - typedef basic_filebuf filebuf; - typedef basic_ifstream ifstream; - typedef basic_ofstream ofstream; - typedef basic_fstream fstream; - - typedef basic_filebuf wfilebuf; - typedef basic_ifstream wifstream; - typedef basic_ofstream wofstream; - typedef basic_fstream wfstream; - -} // namespace filesystem -} // namespace boost - -#include // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_FSTREAM_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/operations.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/operations.hpp deleted file mode 100644 index dc01b7d8..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/operations.hpp +++ /dev/null @@ -1,1096 +0,0 @@ -// boost/filesystem/operations.hpp ---------------------------------------------------// - -// Copyright Beman Dawes 2002-2009 -// Copyright Jan Langer 2002 -// Copyright Dietmar Kuehl 2001 -// Copyright Vladimir Prus 2002 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -//--------------------------------------------------------------------------------------// - -#ifndef BOOST_FILESYSTEM3_OPERATIONS_HPP -#define BOOST_FILESYSTEM3_OPERATIONS_HPP - -#include - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include // for pair -#include -#include -#include - -#ifdef BOOST_WINDOWS_API -# include -#endif - -#include // must be the last #include - -//--------------------------------------------------------------------------------------// - -namespace boost -{ - namespace filesystem - { - -//--------------------------------------------------------------------------------------// -// file_type // -//--------------------------------------------------------------------------------------// - - enum file_type - { - status_error, -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - status_unknown = status_error, -# endif - file_not_found, - regular_file, - directory_file, - // the following may not apply to some operating systems or file systems - symlink_file, - block_file, - character_file, - fifo_file, - socket_file, - reparse_file, // Windows: FILE_ATTRIBUTE_REPARSE_POINT that is not a symlink - type_unknown, // file does exist, but isn't one of the above types or - // we don't have strong enough permission to find its type - - _detail_directory_symlink // internal use only; never exposed to users - }; - -//--------------------------------------------------------------------------------------// -// perms // -//--------------------------------------------------------------------------------------// - - enum perms - { - no_perms = 0, // file_not_found is no_perms rather than perms_not_known - - // POSIX equivalent macros given in comments. - // Values are from POSIX and are given in octal per the POSIX standard. - - // permission bits - - owner_read = 0400, // S_IRUSR, Read permission, owner - owner_write = 0200, // S_IWUSR, Write permission, owner - owner_exe = 0100, // S_IXUSR, Execute/search permission, owner - owner_all = 0700, // S_IRWXU, Read, write, execute/search by owner - - group_read = 040, // S_IRGRP, Read permission, group - group_write = 020, // S_IWGRP, Write permission, group - group_exe = 010, // S_IXGRP, Execute/search permission, group - group_all = 070, // S_IRWXG, Read, write, execute/search by group - - others_read = 04, // S_IROTH, Read permission, others - others_write = 02, // S_IWOTH, Write permission, others - others_exe = 01, // S_IXOTH, Execute/search permission, others - others_all = 07, // S_IRWXO, Read, write, execute/search by others - - all_all = owner_all|group_all|others_all, // 0777 - - // other POSIX bits - - set_uid_on_exe = 04000, // S_ISUID, Set-user-ID on execution - set_gid_on_exe = 02000, // S_ISGID, Set-group-ID on execution - sticky_bit = 01000, // S_ISVTX, - // (POSIX XSI) On directories, restricted deletion flag - // (V7) 'sticky bit': save swapped text even after use - // (SunOS) On non-directories: don't cache this file - // (SVID-v4.2) On directories: restricted deletion flag - // Also see http://en.wikipedia.org/wiki/Sticky_bit - - perms_mask = all_all|set_uid_on_exe|set_gid_on_exe|sticky_bit, // 07777 - - perms_not_known = 0xFFFF, // present when directory_entry cache not loaded - - // options for permissions() function - - add_perms = 0x1000, // adds the given permission bits to the current bits - remove_perms = 0x2000, // removes the given permission bits from the current bits; - // choose add_perms or remove_perms, not both; if neither add_perms - // nor remove_perms is given, replace the current bits with - // the given bits. - - symlink_perms = 0x4000 // on POSIX, don't resolve symlinks; implied on Windows - }; - - BOOST_BITMASK(perms) - -//--------------------------------------------------------------------------------------// -// file_status // -//--------------------------------------------------------------------------------------// - - class BOOST_FILESYSTEM_DECL file_status - { - public: - file_status() : m_value(status_error), m_perms(perms_not_known) {} - explicit file_status(file_type v, perms prms = perms_not_known) - : m_value(v), m_perms(prms) {} - - // observers - file_type type() const { return m_value; } - perms permissions() const { return m_perms; } - - // modifiers - void type(file_type v) { m_value = v; } - void permissions(perms prms) { m_perms = prms; } - - bool operator==(const file_status& rhs) const { return type() == rhs.type() && - permissions() == rhs.permissions(); } - bool operator!=(const file_status& rhs) const { return !(*this == rhs); } - - private: - file_type m_value; - enum perms m_perms; - }; - - inline bool type_present(file_status f) { return f.type() != status_error; } - inline bool permissions_present(file_status f) - {return f.permissions() != perms_not_known;} - inline bool status_known(file_status f) { return type_present(f) && permissions_present(f); } - inline bool exists(file_status f) { return f.type() != status_error - && f.type() != file_not_found; } - inline bool is_regular_file(file_status f){ return f.type() == regular_file; } - inline bool is_directory(file_status f) { return f.type() == directory_file; } - inline bool is_symlink(file_status f) { return f.type() == symlink_file; } - inline bool is_other(file_status f) { return exists(f) && !is_regular_file(f) - && !is_directory(f) && !is_symlink(f); } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - inline bool is_regular(file_status f) { return f.type() == regular_file; } -# endif - - struct space_info - { - // all values are byte counts - boost::uintmax_t capacity; - boost::uintmax_t free; // <= capacity - boost::uintmax_t available; // <= free - }; - - BOOST_SCOPED_ENUM_START(copy_option) - {none, fail_if_exists = none, overwrite_if_exists}; - BOOST_SCOPED_ENUM_END - -//--------------------------------------------------------------------------------------// -// implementation details // -//--------------------------------------------------------------------------------------// - - namespace detail - { - BOOST_FILESYSTEM_DECL - file_status status(const path&p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - file_status symlink_status(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - bool is_empty(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path initial_path(system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path canonical(const path& p, const path& base, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void copy(const path& from, const path& to, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void copy_directory(const path& from, const path& to, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void copy_file(const path& from, const path& to, - BOOST_SCOPED_ENUM(copy_option) option, // See ticket #2925 - system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void copy_symlink(const path& existing_symlink, const path& new_symlink, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - bool create_directories(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - bool create_directory(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void create_directory_symlink(const path& to, const path& from, - system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void create_hard_link(const path& to, const path& from, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void create_symlink(const path& to, const path& from, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path current_path(system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void current_path(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - bool equivalent(const path& p1, const path& p2, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - boost::uintmax_t file_size(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - boost::uintmax_t hard_link_count(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - std::time_t last_write_time(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void last_write_time(const path& p, const std::time_t new_time, - system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void permissions(const path& p, perms prms, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path read_symlink(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - // For standardization, if the committee doesn't like "remove", consider "eliminate" - bool remove(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - boost::uintmax_t remove_all(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void rename(const path& old_p, const path& new_p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - void resize_file(const path& p, uintmax_t size, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - space_info space(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path system_complete(const path& p, system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path temp_directory_path(system::error_code* ec=0); - BOOST_FILESYSTEM_DECL - path unique_path(const path& p, system::error_code* ec=0); - } // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// status query functions // -// // -//--------------------------------------------------------------------------------------// - - inline - file_status status(const path& p) {return detail::status(p);} - inline - file_status status(const path& p, system::error_code& ec) - {return detail::status(p, &ec);} - inline - file_status symlink_status(const path& p) {return detail::symlink_status(p);} - inline - file_status symlink_status(const path& p, system::error_code& ec) - {return detail::symlink_status(p, &ec);} - inline - bool exists(const path& p) {return exists(detail::status(p));} - inline - bool exists(const path& p, system::error_code& ec) - {return exists(detail::status(p, &ec));} - inline - bool is_directory(const path& p) {return is_directory(detail::status(p));} - inline - bool is_directory(const path& p, system::error_code& ec) - {return is_directory(detail::status(p, &ec));} - inline - bool is_regular_file(const path& p) {return is_regular_file(detail::status(p));} - inline - bool is_regular_file(const path& p, system::error_code& ec) - {return is_regular_file(detail::status(p, &ec));} - inline - bool is_other(const path& p) {return is_other(detail::status(p));} - inline - bool is_other(const path& p, system::error_code& ec) - {return is_other(detail::status(p, &ec));} - inline - bool is_symlink(const path& p) {return is_symlink(detail::symlink_status(p));} - inline - bool is_symlink(const path& p, system::error_code& ec) - {return is_symlink(detail::symlink_status(p, &ec));} -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - inline - bool is_regular(const path& p) {return is_regular(detail::status(p));} - inline - bool is_regular(const path& p, system::error_code& ec) - {return is_regular(detail::status(p, &ec));} -# endif - - inline - bool is_empty(const path& p) {return detail::is_empty(p);} - inline - bool is_empty(const path& p, system::error_code& ec) - {return detail::is_empty(p, &ec);} - -//--------------------------------------------------------------------------------------// -// // -// operational functions // -// in alphabetical order, unless otherwise noted // -// // -//--------------------------------------------------------------------------------------// - - // forward declarations - path current_path(); // fwd declaration - path initial_path(); - - BOOST_FILESYSTEM_DECL - path absolute(const path& p, const path& base=current_path()); - // If base.is_absolute(), throws nothing. Thus no need for ec argument - - inline - path canonical(const path& p, const path& base=current_path()) - {return detail::canonical(p, base);} - inline - path canonical(const path& p, system::error_code& ec) - {return detail::canonical(p, current_path(), &ec);} - inline - path canonical(const path& p, const path& base, system::error_code& ec) - {return detail::canonical(p, base, &ec);} - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - inline - path complete(const path& p) - { - return absolute(p, initial_path()); - } - - inline - path complete(const path& p, const path& base) - { - return absolute(p, base); - } -# endif - - inline - void copy(const path& from, const path& to) {detail::copy(from, to);} - - inline - void copy(const path& from, const path& to, system::error_code& ec) - {detail::copy(from, to, &ec);} - inline - void copy_directory(const path& from, const path& to) - {detail::copy_directory(from, to);} - inline - void copy_directory(const path& from, const path& to, system::error_code& ec) - {detail::copy_directory(from, to, &ec);} - inline - void copy_file(const path& from, const path& to, // See ticket #2925 - BOOST_SCOPED_ENUM(copy_option) option) - {detail::copy_file(from, to, option);} - inline - void copy_file(const path& from, const path& to) - {detail::copy_file(from, to, copy_option::fail_if_exists);} - inline - void copy_file(const path& from, const path& to, // See ticket #2925 - BOOST_SCOPED_ENUM(copy_option) option, system::error_code& ec) - {detail::copy_file(from, to, option, &ec);} - inline - void copy_file(const path& from, const path& to, system::error_code& ec) - {detail::copy_file(from, to, copy_option::fail_if_exists, &ec);} - inline - void copy_symlink(const path& existing_symlink, const path& new_symlink) {detail::copy_symlink(existing_symlink, new_symlink);} - - inline - void copy_symlink(const path& existing_symlink, const path& new_symlink, system::error_code& ec) - {detail::copy_symlink(existing_symlink, new_symlink, &ec);} - inline - bool create_directories(const path& p) {return detail::create_directories(p);} - - inline - bool create_directories(const path& p, system::error_code& ec) - {return detail::create_directories(p, &ec);} - inline - bool create_directory(const path& p) {return detail::create_directory(p);} - - inline - bool create_directory(const path& p, system::error_code& ec) - {return detail::create_directory(p, &ec);} - inline - void create_directory_symlink(const path& to, const path& from) - {detail::create_directory_symlink(to, from);} - inline - void create_directory_symlink(const path& to, const path& from, system::error_code& ec) - {detail::create_directory_symlink(to, from, &ec);} - inline - void create_hard_link(const path& to, const path& new_hard_link) {detail::create_hard_link(to, new_hard_link);} - - inline - void create_hard_link(const path& to, const path& new_hard_link, system::error_code& ec) - {detail::create_hard_link(to, new_hard_link, &ec);} - inline - void create_symlink(const path& to, const path& new_symlink) {detail::create_symlink(to, new_symlink);} - - inline - void create_symlink(const path& to, const path& new_symlink, system::error_code& ec) - {detail::create_symlink(to, new_symlink, &ec);} - inline - path current_path() {return detail::current_path();} - - inline - path current_path(system::error_code& ec) {return detail::current_path(&ec);} - - inline - void current_path(const path& p) {detail::current_path(p);} - - inline - void current_path(const path& p, system::error_code& ec) {detail::current_path(p, &ec);} - - inline - bool equivalent(const path& p1, const path& p2) {return detail::equivalent(p1, p2);} - - inline - bool equivalent(const path& p1, const path& p2, system::error_code& ec) - {return detail::equivalent(p1, p2, &ec);} - inline - boost::uintmax_t file_size(const path& p) {return detail::file_size(p);} - - inline - boost::uintmax_t file_size(const path& p, system::error_code& ec) - {return detail::file_size(p, &ec);} - inline - boost::uintmax_t hard_link_count(const path& p) {return detail::hard_link_count(p);} - - inline - boost::uintmax_t hard_link_count(const path& p, system::error_code& ec) - {return detail::hard_link_count(p, &ec);} - inline - path initial_path() {return detail::initial_path();} - - inline - path initial_path(system::error_code& ec) {return detail::initial_path(&ec);} - - template - path initial_path() {return initial_path();} - template - path initial_path(system::error_code& ec) {return detail::initial_path(&ec);} - - inline - std::time_t last_write_time(const path& p) {return detail::last_write_time(p);} - - inline - std::time_t last_write_time(const path& p, system::error_code& ec) - {return detail::last_write_time(p, &ec);} - inline - void last_write_time(const path& p, const std::time_t new_time) - {detail::last_write_time(p, new_time);} - inline - void last_write_time(const path& p, const std::time_t new_time, system::error_code& ec) - {detail::last_write_time(p, new_time, &ec);} - inline - void permissions(const path& p, perms prms) - {detail::permissions(p, prms);} - inline - void permissions(const path& p, perms prms, system::error_code& ec) - {detail::permissions(p, prms, &ec);} - - inline - path read_symlink(const path& p) {return detail::read_symlink(p);} - - inline - path read_symlink(const path& p, system::error_code& ec) - {return detail::read_symlink(p, &ec);} - inline - // For standardization, if the committee doesn't like "remove", consider "eliminate" - bool remove(const path& p) {return detail::remove(p);} - - inline - bool remove(const path& p, system::error_code& ec) {return detail::remove(p, &ec);} - - inline - boost::uintmax_t remove_all(const path& p) {return detail::remove_all(p);} - - inline - boost::uintmax_t remove_all(const path& p, system::error_code& ec) - {return detail::remove_all(p, &ec);} - inline - void rename(const path& old_p, const path& new_p) {detail::rename(old_p, new_p);} - - inline - void rename(const path& old_p, const path& new_p, system::error_code& ec) - {detail::rename(old_p, new_p, &ec);} - inline // name suggested by Scott McMurray - void resize_file(const path& p, uintmax_t size) {detail::resize_file(p, size);} - - inline - void resize_file(const path& p, uintmax_t size, system::error_code& ec) - {detail::resize_file(p, size, &ec);} - inline - space_info space(const path& p) {return detail::space(p);} - - inline - space_info space(const path& p, system::error_code& ec) {return detail::space(p, &ec);} - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - inline bool symbolic_link_exists(const path& p) - { return is_symlink(symlink_status(p)); } -# endif - - inline - path system_complete(const path& p) {return detail::system_complete(p);} - - inline - path system_complete(const path& p, system::error_code& ec) - {return detail::system_complete(p, &ec);} - inline - path temp_directory_path() {return detail::temp_directory_path();} - - inline - path temp_directory_path(system::error_code& ec) - {return detail::temp_directory_path(&ec);} - inline - path unique_path(const path& p="%%%%-%%%%-%%%%-%%%%") - { return detail::unique_path(p); } - inline - path unique_path(const path& p, system::error_code& ec) - { return detail::unique_path(p, &ec); } - -//--------------------------------------------------------------------------------------// -// // -// directory_entry // -// // -//--------------------------------------------------------------------------------------// - -// GCC has a problem with a member function named path within a namespace or -// sub-namespace that also has a class named path. The workaround is to always -// fully qualify the name path when it refers to the class name. - -class BOOST_FILESYSTEM_DECL directory_entry -{ -public: - - // compiler generated copy constructor, copy assignment, and destructor apply - - directory_entry() {} - explicit directory_entry(const boost::filesystem::path& p, - file_status st = file_status(), file_status symlink_st=file_status()) - : m_path(p), m_status(st), m_symlink_status(symlink_st) - {} - - void assign(const boost::filesystem::path& p, - file_status st = file_status(), file_status symlink_st = file_status()) - { m_path = p; m_status = st; m_symlink_status = symlink_st; } - - void replace_filename(const boost::filesystem::path& p, - file_status st = file_status(), file_status symlink_st = file_status()) - { - m_path.remove_filename(); - m_path /= p; - m_status = st; - m_symlink_status = symlink_st; - } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - void replace_leaf(const boost::filesystem::path& p, - file_status st, file_status symlink_st) - { replace_filename(p, st, symlink_st); } -# endif - - const boost::filesystem::path& path() const {return m_path;} - file_status status() const {return m_get_status();} - file_status status(system::error_code& ec) const {return m_get_status(&ec);} - file_status symlink_status() const {return m_get_symlink_status();} - file_status symlink_status(system::error_code& ec) const {return m_get_symlink_status(&ec);} - - bool operator==(const directory_entry& rhs) {return m_path == rhs.m_path;} - bool operator!=(const directory_entry& rhs) {return m_path != rhs.m_path;} - bool operator< (const directory_entry& rhs) {return m_path < rhs.m_path;} - bool operator<=(const directory_entry& rhs) {return m_path <= rhs.m_path;} - bool operator> (const directory_entry& rhs) {return m_path > rhs.m_path;} - bool operator>=(const directory_entry& rhs) {return m_path >= rhs.m_path;} - -private: - boost::filesystem::path m_path; - mutable file_status m_status; // stat()-like - mutable file_status m_symlink_status; // lstat()-like - - file_status m_get_status(system::error_code* ec=0) const; - file_status m_get_symlink_status(system::error_code* ec=0) const; -}; // directory_entry - -//--------------------------------------------------------------------------------------// -// // -// directory_iterator helpers // -// // -//--------------------------------------------------------------------------------------// - -class directory_iterator; - -namespace detail -{ - BOOST_FILESYSTEM_DECL - system::error_code dir_itr_close(// never throws() - void *& handle -# if defined(BOOST_POSIX_API) - , void *& buffer -# endif - ); - - struct dir_itr_imp - { - directory_entry dir_entry; - void* handle; - -# ifdef BOOST_POSIX_API - void* buffer; // see dir_itr_increment implementation -# endif - - dir_itr_imp() : handle(0) -# ifdef BOOST_POSIX_API - , buffer(0) -# endif - {} - - ~dir_itr_imp() // never throws - { - dir_itr_close(handle -# if defined(BOOST_POSIX_API) - , buffer -# endif - ); - } - }; - - // see path::iterator: comment below - BOOST_FILESYSTEM_DECL void directory_iterator_construct(directory_iterator& it, - const path& p, system::error_code* ec); - BOOST_FILESYSTEM_DECL void directory_iterator_increment(directory_iterator& it, - system::error_code* ec); - -} // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// directory_iterator // -// // -//--------------------------------------------------------------------------------------// - - class directory_iterator - : public boost::iterator_facade< directory_iterator, - directory_entry, - boost::single_pass_traversal_tag > - { - public: - - directory_iterator(){} // creates the "end" iterator - - // iterator_facade derived classes don't seem to like implementations in - // separate translation unit dll's, so forward to detail functions - explicit directory_iterator(const path& p) - : m_imp(new detail::dir_itr_imp) - { detail::directory_iterator_construct(*this, p, 0); } - - directory_iterator(const path& p, system::error_code& ec) - : m_imp(new detail::dir_itr_imp) - { detail::directory_iterator_construct(*this, p, &ec); } - - ~directory_iterator() {} // never throws - - directory_iterator& increment(system::error_code& ec) - { - detail::directory_iterator_increment(*this, &ec); - return *this; - } - - private: - friend struct detail::dir_itr_imp; - friend BOOST_FILESYSTEM_DECL void detail::directory_iterator_construct(directory_iterator& it, - const path& p, system::error_code* ec); - friend BOOST_FILESYSTEM_DECL void detail::directory_iterator_increment(directory_iterator& it, - system::error_code* ec); - - // shared_ptr provides shallow-copy semantics required for InputIterators. - // m_imp.get()==0 indicates the end iterator. - boost::shared_ptr< detail::dir_itr_imp > m_imp; - - friend class boost::iterator_core_access; - - boost::iterator_facade< - directory_iterator, - directory_entry, - boost::single_pass_traversal_tag >::reference dereference() const - { - BOOST_ASSERT_MSG(m_imp.get(), "attempt to dereference end iterator"); - return m_imp->dir_entry; - } - - void increment() { detail::directory_iterator_increment(*this, 0); } - - bool equal(const directory_iterator& rhs) const - { return m_imp == rhs.m_imp; } - }; - -//--------------------------------------------------------------------------------------// -// // -// recursive_directory_iterator helpers // -// // -//--------------------------------------------------------------------------------------// - - BOOST_SCOPED_ENUM_START(symlink_option) - { - none, - no_recurse = none, // don't follow directory symlinks (default behavior) - recurse, // follow directory symlinks - _detail_no_push = recurse << 1 // internal use only - }; - BOOST_SCOPED_ENUM_END - - BOOST_BITMASK(BOOST_SCOPED_ENUM(symlink_option)) - - namespace detail - { - struct recur_dir_itr_imp - { - typedef directory_iterator element_type; - std::stack< element_type, std::vector< element_type > > m_stack; - int m_level; - BOOST_SCOPED_ENUM(symlink_option) m_options; - - recur_dir_itr_imp() : m_level(0), m_options(symlink_option::none) {} - - void increment(system::error_code* ec); // ec == 0 means throw on error - - void pop(); - - }; - - // Implementation is inline to avoid dynamic linking difficulties with m_stack: - // Microsoft warning C4251, m_stack needs to have dll-interface to be used by - // clients of struct 'boost::filesystem::detail::recur_dir_itr_imp' - - inline - void recur_dir_itr_imp::increment(system::error_code* ec) - // ec == 0 means throw on error - { - if ((m_options & symlink_option::_detail_no_push) == symlink_option::_detail_no_push) - m_options &= ~symlink_option::_detail_no_push; - - else - { - // Logic for following predicate was contributed by Daniel Aarno to handle cyclic - // symlinks correctly and efficiently, fixing ticket #5652. - // if (((m_options & symlink_option::recurse) == symlink_option::recurse - // || !is_symlink(m_stack.top()->symlink_status())) - // && is_directory(m_stack.top()->status())) ... - // The predicate code has since been rewritten to pass error_code arguments, - // per ticket #5653. - bool or_pred = (m_options & symlink_option::recurse) == symlink_option::recurse - || (ec == 0 ? !is_symlink(m_stack.top()->symlink_status()) - : !is_symlink(m_stack.top()->symlink_status(*ec))); - if (ec != 0 && *ec) - return; - bool and_pred = or_pred && (ec == 0 ? is_directory(m_stack.top()->status()) - : is_directory(m_stack.top()->status(*ec))); - if (ec != 0 && *ec) - return; - - if (and_pred) - { - if (ec == 0) - m_stack.push(directory_iterator(m_stack.top()->path())); - else - { - m_stack.push(directory_iterator(m_stack.top()->path(), *ec)); - if (*ec) - return; - } - if (m_stack.top() != directory_iterator()) - { - ++m_level; - return; - } - m_stack.pop(); - } - } - - while (!m_stack.empty() && ++m_stack.top() == directory_iterator()) - { - m_stack.pop(); - --m_level; - } - } - - inline - void recur_dir_itr_imp::pop() - { - BOOST_ASSERT_MSG(m_level > 0, - "pop() on recursive_directory_iterator with level < 1"); - - do - { - m_stack.pop(); - --m_level; - } - while (!m_stack.empty() && ++m_stack.top() == directory_iterator()); - } - } // namespace detail - -//--------------------------------------------------------------------------------------// -// // -// recursive_directory_iterator // -// // -//--------------------------------------------------------------------------------------// - - class recursive_directory_iterator - : public boost::iterator_facade< - recursive_directory_iterator, - directory_entry, - boost::single_pass_traversal_tag > - { - public: - - recursive_directory_iterator(){} // creates the "end" iterator - - explicit recursive_directory_iterator(const path& dir_path, - BOOST_SCOPED_ENUM(symlink_option) opt = symlink_option::none) - : m_imp(new detail::recur_dir_itr_imp) - { - m_imp->m_options = opt; - m_imp->m_stack.push(directory_iterator(dir_path)); - if (m_imp->m_stack.top() == directory_iterator()) - { m_imp.reset (); } - } - - recursive_directory_iterator(const path& dir_path, - BOOST_SCOPED_ENUM(symlink_option) opt, - system::error_code & ec) - : m_imp(new detail::recur_dir_itr_imp) - { - m_imp->m_options = opt; - m_imp->m_stack.push(directory_iterator(dir_path, ec)); - if (m_imp->m_stack.top() == directory_iterator()) - { m_imp.reset (); } - } - - recursive_directory_iterator(const path& dir_path, - system::error_code & ec) - : m_imp(new detail::recur_dir_itr_imp) - { - m_imp->m_options = symlink_option::none; - m_imp->m_stack.push(directory_iterator(dir_path, ec)); - if (m_imp->m_stack.top() == directory_iterator()) - { m_imp.reset (); } - } - - recursive_directory_iterator& increment(system::error_code& ec) - { - BOOST_ASSERT_MSG(m_imp.get(), - "increment() on end recursive_directory_iterator"); - m_imp->increment(&ec); - if (m_imp->m_stack.empty()) - m_imp.reset(); // done, so make end iterator - return *this; - } - - int level() const - { - BOOST_ASSERT_MSG(m_imp.get(), - "level() on end recursive_directory_iterator"); - return m_imp->m_level; - } - - bool no_push_pending() const - { - BOOST_ASSERT_MSG(m_imp.get(), - "is_no_push_requested() on end recursive_directory_iterator"); - return (m_imp->m_options & symlink_option::_detail_no_push) - == symlink_option::_detail_no_push; - } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - bool no_push_request() const { return no_push_pending(); } -# endif - - void pop() - { - BOOST_ASSERT_MSG(m_imp.get(), - "pop() on end recursive_directory_iterator"); - m_imp->pop(); - if (m_imp->m_stack.empty()) m_imp.reset(); // done, so make end iterator - } - - void no_push(bool value=true) - { - BOOST_ASSERT_MSG(m_imp.get(), - "no_push() on end recursive_directory_iterator"); - if (value) - m_imp->m_options |= symlink_option::_detail_no_push; - else - m_imp->m_options &= ~symlink_option::_detail_no_push; - } - - file_status status() const - { - BOOST_ASSERT_MSG(m_imp.get(), - "status() on end recursive_directory_iterator"); - return m_imp->m_stack.top()->status(); - } - - file_status symlink_status() const - { - BOOST_ASSERT_MSG(m_imp.get(), - "symlink_status() on end recursive_directory_iterator"); - return m_imp->m_stack.top()->symlink_status(); - } - - private: - - // shared_ptr provides shallow-copy semantics required for InputIterators. - // m_imp.get()==0 indicates the end iterator. - boost::shared_ptr< detail::recur_dir_itr_imp > m_imp; - - friend class boost::iterator_core_access; - - boost::iterator_facade< - recursive_directory_iterator, - directory_entry, - boost::single_pass_traversal_tag >::reference - dereference() const - { - BOOST_ASSERT_MSG(m_imp.get(), - "dereference of end recursive_directory_iterator"); - return *m_imp->m_stack.top(); - } - - void increment() - { - BOOST_ASSERT_MSG(m_imp.get(), - "increment of end recursive_directory_iterator"); - m_imp->increment(0); - if (m_imp->m_stack.empty()) - m_imp.reset(); // done, so make end iterator - } - - bool equal(const recursive_directory_iterator& rhs) const - { return m_imp == rhs.m_imp; } - - }; - -# if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) - typedef recursive_directory_iterator wrecursive_directory_iterator; -# endif - -//--------------------------------------------------------------------------------------// -// // -// class filesystem_error // -// // -//--------------------------------------------------------------------------------------// - - class BOOST_SYMBOL_VISIBLE filesystem_error : public system::system_error - { - // see http://www.boost.org/more/error_handling.html for design rationale - - // all functions are inline to avoid issues with crossing dll boundaries - - public: - // compiler generates copy constructor and copy assignment - - filesystem_error( - const std::string & what_arg, system::error_code ec) - : system::system_error(ec, what_arg) - { - try - { - m_imp_ptr.reset(new m_imp); - } - catch (...) { m_imp_ptr.reset(); } - } - - filesystem_error( - const std::string & what_arg, const path& path1_arg, - system::error_code ec) - : system::system_error(ec, what_arg) - { - try - { - m_imp_ptr.reset(new m_imp); - m_imp_ptr->m_path1 = path1_arg; - } - catch (...) { m_imp_ptr.reset(); } - } - - filesystem_error( - const std::string & what_arg, const path& path1_arg, - const path& path2_arg, system::error_code ec) - : system::system_error(ec, what_arg) - { - try - { - m_imp_ptr.reset(new m_imp); - m_imp_ptr->m_path1 = path1_arg; - m_imp_ptr->m_path2 = path2_arg; - } - catch (...) { m_imp_ptr.reset(); } - } - - ~filesystem_error() throw() {} - - const path& path1() const - { - static const path empty_path; - return m_imp_ptr.get() ? m_imp_ptr->m_path1 : empty_path ; - } - const path& path2() const - { - static const path empty_path; - return m_imp_ptr.get() ? m_imp_ptr->m_path2 : empty_path ; - } - - const char* what() const throw() - { - if (!m_imp_ptr.get()) - return system::system_error::what(); - - try - { - if (m_imp_ptr->m_what.empty()) - { - m_imp_ptr->m_what = system::system_error::what(); - if (!m_imp_ptr->m_path1.empty()) - { - m_imp_ptr->m_what += ": \""; - m_imp_ptr->m_what += m_imp_ptr->m_path1.string(); - m_imp_ptr->m_what += "\""; - } - if (!m_imp_ptr->m_path2.empty()) - { - m_imp_ptr->m_what += ", \""; - m_imp_ptr->m_what += m_imp_ptr->m_path2.string(); - m_imp_ptr->m_what += "\""; - } - } - return m_imp_ptr->m_what.c_str(); - } - catch (...) - { - return system::system_error::what(); - } - } - - private: - struct m_imp - { - path m_path1; // may be empty() - path m_path2; // may be empty() - std::string m_what; // not built until needed - }; - boost::shared_ptr m_imp_ptr; - }; - -// test helper -----------------------------------------------------------------------// - -// Not part of the documented interface since false positives are possible; -// there is no law that says that an OS that has large stat.st_size -// actually supports large file sizes. - - namespace detail - { - BOOST_FILESYSTEM_DECL bool possible_large_file_size_support(); - } - - } // namespace filesystem -} // namespace boost - -#include // pops abi_prefix.hpp pragmas -#endif // BOOST_FILESYSTEM3_OPERATIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/path.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/path.hpp deleted file mode 100644 index 2dd1b00e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/path.hpp +++ /dev/null @@ -1,758 +0,0 @@ -// filesystem path.hpp ---------------------------------------------------------------// - -// Copyright Beman Dawes 2002-2005, 2009 -// Copyright Vladimir Prus 2002 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -// path::stem(), extension(), and replace_extension() are based on -// basename(), extension(), and change_extension() from the original -// filesystem/convenience.hpp header by Vladimir Prus. - -#ifndef BOOST_FILESYSTEM_PATH_HPP -#define BOOST_FILESYSTEM_PATH_HPP - -#include - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include -#include // includes -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include // must be the last #include - -namespace boost -{ -namespace filesystem -{ - //------------------------------------------------------------------------------------// - // // - // class path // - // // - //------------------------------------------------------------------------------------// - - class BOOST_FILESYSTEM_DECL path - { - public: - - // value_type is the character type used by the operating system API to - // represent paths. - -# ifdef BOOST_WINDOWS_API - typedef wchar_t value_type; - BOOST_STATIC_CONSTEXPR value_type preferred_separator = L'\\'; -# else - typedef char value_type; - BOOST_STATIC_CONSTEXPR value_type preferred_separator = '/'; -# endif - typedef std::basic_string string_type; - typedef std::codecvt codecvt_type; - - - // ----- character encoding conversions ----- - - // Following the principle of least astonishment, path input arguments - // passed to or obtained from the operating system via objects of - // class path behave as if they were directly passed to or - // obtained from the O/S API, unless conversion is explicitly requested. - // - // POSIX specfies that path strings are passed unchanged to and from the - // API. Note that this is different from the POSIX command line utilities, - // which convert according to a locale. - // - // Thus for POSIX, char strings do not undergo conversion. wchar_t strings - // are converted to/from char using the path locale or, if a conversion - // argument is given, using a conversion object modeled on - // std::wstring_convert. - // - // The path locale, which is global to the thread, can be changed by the - // imbue() function. It is initialized to an implementation defined locale. - // - // For Windows, wchar_t strings do not undergo conversion. char strings - // are converted using the "ANSI" or "OEM" code pages, as determined by - // the AreFileApisANSI() function, or, if a conversion argument is given, - // using a conversion object modeled on std::wstring_convert. - // - // See m_pathname comments for further important rationale. - - // TODO: rules needed for operating systems that use / or . - // differently, or format directory paths differently from file paths. - // - // ********************************************************************************** - // - // More work needed: How to handle an operating system that may have - // slash characters or dot characters in valid filenames, either because - // it doesn't follow the POSIX standard, or because it allows MBCS - // filename encodings that may contain slash or dot characters. For - // example, ISO/IEC 2022 (JIS) encoding which allows switching to - // JIS x0208-1983 encoding. A valid filename in this set of encodings is - // 0x1B 0x24 0x42 [switch to X0208-1983] 0x24 0x2F [U+304F Kiragana letter KU] - // ^^^^ - // Note that 0x2F is the ASCII slash character - // - // ********************************************************************************** - - // Supported source arguments: half-open iterator range, container, c-array, - // and single pointer to null terminated string. - - // All source arguments except pointers to null terminated byte strings support - // multi-byte character strings which may have embedded nulls. Embedded null - // support is required for some Asian languages on Windows. - - // [defaults] "const codecvt_type& cvt=codecvt()" default arguments are not used - // because some compilers, such as Microsoft prior to VC++ 10, do not handle defaults - // correctly in templates. - - // ----- constructors ----- - - path(){} - - path(const path& p) : m_pathname(p.m_pathname) {} - - template - path(Source const& source, - typename boost::enable_if::type> >::type* =0) - { - path_traits::dispatch(source, m_pathname, codecvt()); - } - - // Overloads for the operating system API's native character type. Rationale: - // - Avoids use of codecvt() for native value_type strings. This limits the - // impact of locale("") initialization failures on POSIX systems to programs - // that actually depend on locale(""). It further ensures that exceptions thrown - // as a result of such failues occur after main() has started, so can be caught. - // This is a partial resolution of tickets 4688, 5100, and 5289. - // - A slight optimization for a common use case, particularly on POSIX since - // value_type is char and that is the most common useage. - path(const value_type* s) : m_pathname(s) {} - path(const std::basic_string& s) : m_pathname(s) {} - - template - path(Source const& source, const codecvt_type& cvt) - // see [defaults] note above explaining why codecvt() default arguments are not used - { - path_traits::dispatch(source, m_pathname, cvt); - } - - template - path(InputIterator begin, InputIterator end) - { - if (begin != end) - { - std::basic_string::value_type> - s(begin, end); - path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, codecvt()); - } - } - - template - path(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin != end) - { - std::basic_string::value_type> - s(begin, end); - path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); - } - } - - // ----- assignments ----- - - path& operator=(const path& p) - { - m_pathname = p.m_pathname; - return *this; - } - - path& operator=(const value_type* ptr) // required in case ptr overlaps *this - { - m_pathname = ptr; - return *this; - } - - template - typename boost::enable_if::type>, path&>::type - operator=(Source const& source) - { - m_pathname.clear(); - path_traits::dispatch(source, m_pathname, codecvt()); - return *this; - } - - path& assign(const value_type* ptr, const codecvt_type&) // required in case ptr overlaps *this - { - m_pathname = ptr; - return *this; - } - - template - path& assign(Source const& source, const codecvt_type& cvt) - { - m_pathname.clear(); - path_traits::dispatch(source, m_pathname, cvt); - return *this; - } - - template - path& assign(InputIterator begin, InputIterator end) - { - return assign(begin, end, codecvt()); - } - - template - path& assign(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - m_pathname.clear(); - if (begin != end) - { - std::basic_string::value_type> - s(begin, end); - path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); - } - return *this; - } - - // ----- concatenation ----- - - path& operator+=(const path& p) {m_pathname += p.m_pathname; return *this;} - path& operator+=(const string_type& s) {m_pathname += s; return *this;} - path& operator+=(const value_type* ptr) {m_pathname += ptr; return *this;} - path& operator+=(value_type c) {m_pathname += c; return *this;} - - template - typename boost::enable_if::type>, path&>::type - operator+=(Source const& source) - { - return concat(source, codecvt()); - } - - template - typename boost::enable_if, path&>::type - operator+=(CharT c) - { - CharT tmp[2]; - tmp[0] = c; - tmp[1] = 0; - return concat(tmp, codecvt()); - } - - template - path& concat(Source const& source, const codecvt_type& cvt) - { - path_traits::dispatch(source, m_pathname, cvt); - return *this; - } - - template - path& concat(InputIterator begin, InputIterator end) - { - return concat(begin, end, codecvt()); - } - - template - path& concat(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin == end) - return *this; - std::basic_string::value_type> - s(begin, end); - path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); - return *this; - } - - // ----- appends ----- - - // if a separator is added, it is the preferred separator for the platform; - // slash for POSIX, backslash for Windows - - path& operator/=(const path& p); - - path& operator/=(const value_type* ptr); - - template - typename boost::enable_if::type>, path&>::type - operator/=(Source const& source) - { - return append(source, codecvt()); - } - - path& append(const value_type* ptr, const codecvt_type&) // required in case ptr overlaps *this - { - this->operator/=(ptr); - return *this; - } - - template - path& append(Source const& source, const codecvt_type& cvt); - - template - path& append(InputIterator begin, InputIterator end) - { - return append(begin, end, codecvt()); - } - - template - path& append(InputIterator begin, InputIterator end, const codecvt_type& cvt); - - // ----- modifiers ----- - - void clear() { m_pathname.clear(); } - path& make_preferred() -# ifdef BOOST_POSIX_API - { return *this; } // POSIX no effect -# else // BOOST_WINDOWS_API - ; // change slashes to backslashes -# endif - path& remove_filename(); - path& replace_extension(const path& new_extension = path()); - void swap(path& rhs) { m_pathname.swap(rhs.m_pathname); } - - // ----- observers ----- - - // For operating systems that format file paths differently than directory - // paths, return values from observers are formatted as file names unless there - // is a trailing separator, in which case returns are formatted as directory - // paths. POSIX and Windows make no such distinction. - - // Implementations are permitted to return const values or const references. - - // The string or path returned by an observer are specified as being formatted - // as "native" or "generic". - // - // For POSIX, these are all the same format; slashes and backslashes are as input and - // are not modified. - // - // For Windows, native: as input; slashes and backslashes are not modified; - // this is the format of the internally stored string. - // generic: backslashes are converted to slashes - - // ----- native format observers ----- - - const string_type& native() const { return m_pathname; } // Throws: nothing - const value_type* c_str() const { return m_pathname.c_str(); } // Throws: nothing - - template - String string() const; - - template - String string(const codecvt_type& cvt) const; - -# ifdef BOOST_WINDOWS_API - const std::string string() const { return string(codecvt()); } - const std::string string(const codecvt_type& cvt) const - { - std::string tmp; - if (!m_pathname.empty()) - path_traits::convert(&*m_pathname.begin(), &*m_pathname.begin()+m_pathname.size(), - tmp, cvt); - return tmp; - } - - // string_type is std::wstring, so there is no conversion - const std::wstring& wstring() const { return m_pathname; } - const std::wstring& wstring(const codecvt_type&) const { return m_pathname; } - -# else // BOOST_POSIX_API - // string_type is std::string, so there is no conversion - const std::string& string() const { return m_pathname; } - const std::string& string(const codecvt_type&) const { return m_pathname; } - - const std::wstring wstring() const { return wstring(codecvt()); } - const std::wstring wstring(const codecvt_type& cvt) const - { - std::wstring tmp; - if (!m_pathname.empty()) - path_traits::convert(&*m_pathname.begin(), &*m_pathname.begin()+m_pathname.size(), - tmp, cvt); - return tmp; - } - -# endif - - // ----- generic format observers ----- - - template - String generic_string() const; - - template - String generic_string(const codecvt_type& cvt) const; - -# ifdef BOOST_WINDOWS_API - const std::string generic_string() const { return generic_string(codecvt()); } - const std::string generic_string(const codecvt_type& cvt) const; - const std::wstring generic_wstring() const; - const std::wstring generic_wstring(const codecvt_type&) const { return generic_wstring(); }; - -# else // BOOST_POSIX_API - // On POSIX-like systems, the generic format is the same as the native format - const std::string& generic_string() const { return m_pathname; } - const std::string& generic_string(const codecvt_type&) const { return m_pathname; } - const std::wstring generic_wstring() const { return wstring(codecvt()); } - const std::wstring generic_wstring(const codecvt_type& cvt) const { return wstring(cvt); } - -# endif - - // ----- compare ----- - - int compare(const path& p) const BOOST_NOEXCEPT; // generic, lexicographical - int compare(const std::string& s) const { return compare(path(s)); } - int compare(const value_type* s) const { return compare(path(s)); } - - // ----- decomposition ----- - - path root_path() const; - path root_name() const; // returns 0 or 1 element path - // even on POSIX, root_name() is non-empty() for network paths - path root_directory() const; // returns 0 or 1 element path - path relative_path() const; - path parent_path() const; - path filename() const; // returns 0 or 1 element path - path stem() const; // returns 0 or 1 element path - path extension() const; // returns 0 or 1 element path - - // ----- query ----- - - bool empty() const { return m_pathname.empty(); } // name consistent with std containers - bool has_root_path() const { return has_root_directory() || has_root_name(); } - bool has_root_name() const { return !root_name().empty(); } - bool has_root_directory() const { return !root_directory().empty(); } - bool has_relative_path() const { return !relative_path().empty(); } - bool has_parent_path() const { return !parent_path().empty(); } - bool has_filename() const { return !m_pathname.empty(); } - bool has_stem() const { return !stem().empty(); } - bool has_extension() const { return !extension().empty(); } - bool is_absolute() const - { -# ifdef BOOST_WINDOWS_API - return has_root_name() && has_root_directory(); -# else - return has_root_directory(); -# endif - } - bool is_relative() const { return !is_absolute(); } - - // ----- iterators ----- - - class iterator; - typedef iterator const_iterator; - - iterator begin() const; - iterator end() const; - - // ----- static member functions ----- - - static std::locale imbue(const std::locale& loc); - static const codecvt_type& codecvt(); - - // ----- deprecated functions ----- - -# if defined(BOOST_FILESYSTEM_DEPRECATED) && defined(BOOST_FILESYSTEM_NO_DEPRECATED) -# error both BOOST_FILESYSTEM_DEPRECATED and BOOST_FILESYSTEM_NO_DEPRECATED are defined -# endif - -# if !defined(BOOST_FILESYSTEM_NO_DEPRECATED) - // recently deprecated functions supplied by default - path& normalize() { return m_normalize(); } - path& remove_leaf() { return remove_filename(); } - path leaf() const { return filename(); } - path branch_path() const { return parent_path(); } - bool has_leaf() const { return !m_pathname.empty(); } - bool has_branch_path() const { return !parent_path().empty(); } - bool is_complete() const { return is_absolute(); } -# endif - -# if defined(BOOST_FILESYSTEM_DEPRECATED) - // deprecated functions with enough signature or semantic changes that they are - // not supplied by default - const std::string file_string() const { return string(); } - const std::string directory_string() const { return string(); } - const std::string native_file_string() const { return string(); } - const std::string native_directory_string() const { return string(); } - const string_type external_file_string() const { return native(); } - const string_type external_directory_string() const { return native(); } - - // older functions no longer supported - //typedef bool (*name_check)(const std::string & name); - //basic_path(const string_type& str, name_check) { operator/=(str); } - //basic_path(const typename string_type::value_type* s, name_check) - // { operator/=(s);} - //static bool default_name_check_writable() { return false; } - //static void default_name_check(name_check) {} - //static name_check default_name_check() { return 0; } - //basic_path& canonize(); -# endif - -//--------------------------------------------------------------------------------------// -// class path private members // -//--------------------------------------------------------------------------------------// - - private: -# if defined(_MSC_VER) -# pragma warning(push) // Save warning settings -# pragma warning(disable : 4251) // disable warning: class 'std::basic_string<_Elem,_Traits,_Ax>' -# endif // needs to have dll-interface... -/* - m_pathname has the type, encoding, and format required by the native - operating system. Thus for POSIX and Windows there is no conversion for - passing m_pathname.c_str() to the O/S API or when obtaining a path from the - O/S API. POSIX encoding is unspecified other than for dot and slash - characters; POSIX just treats paths as a sequence of bytes. Windows - encoding is UCS-2 or UTF-16 depending on the version. -*/ - string_type m_pathname; // Windows: as input; backslashes NOT converted to slashes, - // slashes NOT converted to backslashes -# if defined(_MSC_VER) -# pragma warning(pop) // restore warning settings. -# endif - - string_type::size_type m_append_separator_if_needed(); - // Returns: If separator is to be appended, m_pathname.size() before append. Otherwise 0. - // Note: An append is never performed if size()==0, so a returned 0 is unambiguous. - - void m_erase_redundant_separator(string_type::size_type sep_pos); - string_type::size_type m_parent_path_end() const; - - path& m_normalize(); - - // Was qualified; como433beta8 reports: - // warning #427-D: qualified name is not allowed in member declaration - friend class iterator; - friend bool operator<(const path& lhs, const path& rhs); - - // see path::iterator::increment/decrement comment below - static void m_path_iterator_increment(path::iterator & it); - static void m_path_iterator_decrement(path::iterator & it); - - }; // class path - - namespace detail - { - BOOST_FILESYSTEM_DECL - int lex_compare(path::iterator first1, path::iterator last1, - path::iterator first2, path::iterator last2); - } - -# ifndef BOOST_FILESYSTEM_NO_DEPRECATED - typedef path wpath; -# endif - - //------------------------------------------------------------------------------------// - // class path::iterator // - //------------------------------------------------------------------------------------// - - class path::iterator - : public boost::iterator_facade< - path::iterator, - path const, - boost::bidirectional_traversal_tag > - { - private: - friend class boost::iterator_core_access; - friend class boost::filesystem::path; - friend void m_path_iterator_increment(path::iterator & it); - friend void m_path_iterator_decrement(path::iterator & it); - - const path& dereference() const { return m_element; } - - bool equal(const iterator & rhs) const - { - return m_path_ptr == rhs.m_path_ptr && m_pos == rhs.m_pos; - } - - // iterator_facade derived classes don't seem to like implementations in - // separate translation unit dll's, so forward to class path static members - void increment() { m_path_iterator_increment(*this); } - void decrement() { m_path_iterator_decrement(*this); } - - path m_element; // current element - const path* m_path_ptr; // path being iterated over - string_type::size_type m_pos; // position of m_element in - // m_path_ptr->m_pathname. - // if m_element is implicit dot, m_pos is the - // position of the last separator in the path. - // end() iterator is indicated by - // m_pos == m_path_ptr->m_pathname.size() - }; // path::iterator - - //------------------------------------------------------------------------------------// - // // - // non-member functions // - // // - //------------------------------------------------------------------------------------// - - // std::lexicographical_compare would infinately recurse because path iterators - // yield paths, so provide a path aware version - inline bool lexicographical_compare(path::iterator first1, path::iterator last1, - path::iterator first2, path::iterator last2) - { return detail::lex_compare(first1, last1, first2, last2) < 0; } - - inline bool operator==(const path& lhs, const path& rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path& lhs, const path::string_type& rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path::string_type& lhs, const path& rhs) {return rhs.compare(lhs) == 0;} - inline bool operator==(const path& lhs, const path::value_type* rhs) {return lhs.compare(rhs) == 0;} - inline bool operator==(const path::value_type* lhs, const path& rhs) {return rhs.compare(lhs) == 0;} - - inline bool operator!=(const path& lhs, const path& rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path& lhs, const path::string_type& rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path::string_type& lhs, const path& rhs) {return rhs.compare(lhs) != 0;} - inline bool operator!=(const path& lhs, const path::value_type* rhs) {return lhs.compare(rhs) != 0;} - inline bool operator!=(const path::value_type* lhs, const path& rhs) {return rhs.compare(lhs) != 0;} - - // TODO: why do == and != have additional overloads, but the others don't? - - inline bool operator<(const path& lhs, const path& rhs) {return lhs.compare(rhs) < 0;} - inline bool operator<=(const path& lhs, const path& rhs) {return !(rhs < lhs);} - inline bool operator> (const path& lhs, const path& rhs) {return rhs < lhs;} - inline bool operator>=(const path& lhs, const path& rhs) {return !(lhs < rhs);} - - inline std::size_t hash_value(const path& x) - { -# ifdef BOOST_WINDOWS_API - std::size_t seed = 0; - for(const path::value_type* it = x.c_str(); *it; ++it) - hash_combine(seed, *it == '/' ? L'\\' : *it); - return seed; -# else // BOOST_POSIX_API - return hash_range(x.native().begin(), x.native().end()); -# endif - } - - inline void swap(path& lhs, path& rhs) { lhs.swap(rhs); } - - inline path operator/(const path& lhs, const path& rhs) { return path(lhs) /= rhs; } - - // inserters and extractors - // use boost::io::quoted() to handle spaces in paths - // use '&' as escape character to ease use for Windows paths - - template - inline std::basic_ostream& - operator<<(std::basic_ostream& os, const path& p) - { - return os - << boost::io::quoted(p.template string >(), static_cast('&')); - } - - template - inline std::basic_istream& - operator>>(std::basic_istream& is, path& p) - { - std::basic_string str; - is >> boost::io::quoted(str, static_cast('&')); - p = str; - return is; - } - - // name_checks - - // These functions are holdovers from version 1. It isn't clear they have much - // usefulness, or how to generalize them for later versions. - - BOOST_FILESYSTEM_DECL bool portable_posix_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool windows_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_directory_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool portable_file_name(const std::string & name); - BOOST_FILESYSTEM_DECL bool native(const std::string & name); - -//--------------------------------------------------------------------------------------// -// class path member template implementation // -//--------------------------------------------------------------------------------------// - - template - path& path::append(InputIterator begin, InputIterator end, const codecvt_type& cvt) - { - if (begin == end) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - std::basic_string::value_type> - s(begin, end); - path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - - template - path& path::append(Source const& source, const codecvt_type& cvt) - { - if (path_traits::empty(source)) - return *this; - string_type::size_type sep_pos(m_append_separator_if_needed()); - path_traits::dispatch(source, m_pathname, cvt); - if (sep_pos) - m_erase_redundant_separator(sep_pos); - return *this; - } - -//--------------------------------------------------------------------------------------// -// class path member template specializations // -//--------------------------------------------------------------------------------------// - - template <> inline - std::string path::string() const - { return string(); } - - template <> inline - std::wstring path::string() const - { return wstring(); } - - template <> inline - std::string path::string(const codecvt_type& cvt) const - { return string(cvt); } - - template <> inline - std::wstring path::string(const codecvt_type& cvt) const - { return wstring(cvt); } - - template <> inline - std::string path::generic_string() const - { return generic_string(); } - - template <> inline - std::wstring path::generic_string() const - { return generic_wstring(); } - - template <> inline - std::string path::generic_string(const codecvt_type& cvt) const - { return generic_string(cvt); } - - template <> inline - std::wstring path::generic_string(const codecvt_type& cvt) const - { return generic_wstring(cvt); } - - -} // namespace filesystem -} // namespace boost - -//----------------------------------------------------------------------------// - -#include // pops abi_prefix.hpp pragmas - -#endif // BOOST_FILESYSTEM_PATH_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/filesystem/path_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/filesystem/path_traits.hpp deleted file mode 100644 index a6a25055..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/filesystem/path_traits.hpp +++ /dev/null @@ -1,235 +0,0 @@ -// filesystem path_traits.hpp --------------------------------------------------------// - -// Copyright Beman Dawes 2009 - -// Distributed under the Boost Software License, Version 1.0. -// See http://www.boost.org/LICENSE_1_0.txt - -// Library home page: http://www.boost.org/libs/filesystem - -#ifndef BOOST_FILESYSTEM_PATH_TRAITS_HPP -#define BOOST_FILESYSTEM_PATH_TRAITS_HPP - -#include - -# if defined( BOOST_NO_STD_WSTRING ) -# error Configuration not supported: Boost.Filesystem V3 and later requires std::wstring support -# endif - -#include -#include -#include -#include -#include -#include // for mbstate_t -#include -#include -#include -#include -#include -#include -// #include //**** comment me out **** - -#include // must be the last #include - -namespace boost { namespace filesystem { - - BOOST_FILESYSTEM_DECL const system::error_category& codecvt_error_category(); - // uses std::codecvt_base::result used for error codes: - // - // ok: Conversion successful. - // partial: Not all source characters converted; one or more additional source - // characters are needed to produce the final target character, or the - // size of the target intermediate buffer was too small to hold the result. - // error: A character in the source could not be converted to the target encoding. - // noconv: The source and target characters have the same type and encoding, so no - // conversion was necessary. - - class directory_entry; - -namespace path_traits { - - typedef std::codecvt codecvt_type; - - // is_pathable type trait; allows disabling over-agressive class path member templates - - template - struct is_pathable { static const bool value = false; }; - - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - template<> struct is_pathable > { static const bool value = true; }; - template<> struct is_pathable > { static const bool value = true; }; - template<> struct is_pathable > { static const bool value = true; }; - template<> struct is_pathable > { static const bool value = true; }; - template<> struct is_pathable { static const bool value = true; }; - - // Pathable empty - - template inline - // disable_if aids broken compilers (IBM, old GCC, etc.) and is harmless for - // conforming compilers. Replace by plain "bool" at some future date (2012?) - typename boost::disable_if, bool>::type - empty(const Container & c) - { return c.begin() == c.end(); } - - template inline - bool empty(T * const & c_str) - { - BOOST_ASSERT(c_str); - return !*c_str; - } - - template inline - bool empty(T (&x)[N]) - { return !x[0]; } - - // value types differ ---------------------------------------------------------------// - // - // A from_end argument of 0 is less efficient than a known end, so use only if needed - - BOOST_FILESYSTEM_DECL - void convert(const char* from, - const char* from_end, // 0 for null terminated MBCS - std::wstring & to, - const codecvt_type& cvt); - - BOOST_FILESYSTEM_DECL - void convert(const wchar_t* from, - const wchar_t* from_end, // 0 for null terminated MBCS - std::string & to, - const codecvt_type& cvt); - - inline - void convert(const char* from, - std::wstring & to, - const codecvt_type& cvt) - { - BOOST_ASSERT(from); - convert(from, 0, to, cvt); - } - - inline - void convert(const wchar_t* from, - std::string & to, - const codecvt_type& cvt) - { - BOOST_ASSERT(from); - convert(from, 0, to, cvt); - } - - // value types same -----------------------------------------------------------------// - - // char - - inline - void convert(const char* from, const char* from_end, std::string & to, - const codecvt_type&) - { - BOOST_ASSERT(from); - BOOST_ASSERT(from_end); - to.append(from, from_end); - } - - inline - void convert(const char* from, - std::string & to, - const codecvt_type&) - { - BOOST_ASSERT(from); - to += from; - } - - // wchar_t - - inline - void convert(const wchar_t* from, const wchar_t* from_end, std::wstring & to, - const codecvt_type&) - { - BOOST_ASSERT(from); - BOOST_ASSERT(from_end); - to.append(from, from_end); - } - - inline - void convert(const wchar_t* from, - std::wstring & to, - const codecvt_type&) - { - BOOST_ASSERT(from); - to += from; - } - - // Source dispatch -----------------------------------------------------------------// - - // contiguous containers - template inline - void dispatch(const std::string& c, U& to, const codecvt_type& cvt) - { - if (c.size()) - convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); - } - template inline - void dispatch(const std::wstring& c, U& to, const codecvt_type& cvt) - { - if (c.size()) - convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); - } - template inline - void dispatch(const std::vector& c, U& to, const codecvt_type& cvt) - { - if (c.size()) - convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); - } - template inline - void dispatch(const std::vector& c, U& to, const codecvt_type& cvt) - { - if (c.size()) - convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); - } - - // non-contiguous containers - template inline - // disable_if aids broken compilers (IBM, old GCC, etc.) and is harmless for - // conforming compilers. Replace by plain "void" at some future date (2012?) - typename boost::disable_if, void>::type - dispatch(const Container & c, U& to, const codecvt_type& cvt) - { - if (c.size()) - { - std::basic_string s(c.begin(), c.end()); - convert(s.c_str(), s.c_str()+s.size(), to, cvt); - } - } - - // c_str - template inline - void dispatch(T * const & c_str, U& to, const codecvt_type& cvt) - { -// std::cout << "dispatch() const T *\n"; - BOOST_ASSERT(c_str); - convert(c_str, to, cvt); - } - - // Note: there is no dispatch on C-style arrays because the array may - // contain a string smaller than the array size. - - BOOST_FILESYSTEM_DECL - void dispatch(const directory_entry & de, -# ifdef BOOST_WINDOWS_API - std::wstring & to, -# else - std::string & to, -# endif - const codecvt_type&); - - -}}} // namespace boost::filesystem::path_traits - -#include // pops abi_prefix.hpp pragmas - -#endif // BOOST_FILESYSTEM_PATH_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/foreach.hpp b/third_party/ycmd/cpp/BoostParts/boost/foreach.hpp deleted file mode 100644 index 33b59202..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/foreach.hpp +++ /dev/null @@ -1,1128 +0,0 @@ -/////////////////////////////////////////////////////////////////////////////// -// foreach.hpp header file -// -// Copyright 2004 Eric Niebler. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// See http://www.boost.org/libs/foreach for documentation -// -// Credits: -// Anson Tsao - for the initial inspiration and several good suggestions. -// Thorsten Ottosen - for Boost.Range, and for suggesting a way to detect -// const-qualified rvalues at compile time on VC7.1+ -// Russell Hind - For help porting to Borland -// Alisdair Meredith - For help porting to Borland -// Stefan Slapeta - For help porting to Intel -// David Jenkins - For help finding a Microsoft Code Analysis bug -// mimomorin@... - For a patch to use rvalue refs on supporting compilers - -#ifndef BOOST_FOREACH - -// MS compatible compilers support #pragma once -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include // for std::pair - -#include -#include - -// Some compilers let us detect even const-qualified rvalues at compile-time -#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) \ - || BOOST_WORKAROUND(BOOST_MSVC, >= 1310) && !defined(_PREFAST_) \ - || (BOOST_WORKAROUND(__GNUC__, == 4) && (__GNUC_MINOR__ <= 5) && !defined(BOOST_INTEL) && \ - !defined(BOOST_CLANG)) \ - || (BOOST_WORKAROUND(__GNUC__, == 3) && (__GNUC_MINOR__ >= 4) && !defined(BOOST_INTEL) && \ - !defined(BOOST_CLANG)) -# define BOOST_FOREACH_COMPILE_TIME_CONST_RVALUE_DETECTION -#else -// Some compilers allow temporaries to be bound to non-const references. -// These compilers make it impossible to for BOOST_FOREACH to detect -// temporaries and avoid reevaluation of the collection expression. -# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \ - || BOOST_WORKAROUND(__BORLANDC__, < 0x593) \ - || (BOOST_WORKAROUND(BOOST_INTEL_CXX_VERSION, <= 700) && defined(_MSC_VER)) \ - || BOOST_WORKAROUND(__SUNPRO_CC, < 0x5100) \ - || BOOST_WORKAROUND(__DECCXX_VER, <= 60590042) -# define BOOST_FOREACH_NO_RVALUE_DETECTION -# endif -// Some compilers do not correctly implement the lvalue/rvalue conversion -// rules of the ternary conditional operator. -# if defined(BOOST_FOREACH_NO_RVALUE_DETECTION) \ - || defined(BOOST_NO_SFINAE) \ - || BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1400)) \ - || BOOST_WORKAROUND(BOOST_INTEL_WIN, BOOST_TESTED_AT(1400)) \ - || BOOST_WORKAROUND(__GNUC__, < 3) \ - || (BOOST_WORKAROUND(__GNUC__, == 3) && (__GNUC_MINOR__ <= 2)) \ - || (BOOST_WORKAROUND(__GNUC__, == 3) && (__GNUC_MINOR__ <= 3) && defined(__APPLE_CC__)) \ - || BOOST_WORKAROUND(__IBMCPP__, BOOST_TESTED_AT(600)) \ - || BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3206)) \ - || BOOST_WORKAROUND(__SUNPRO_CC, >= 0x5100) \ - || BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x590)) -# define BOOST_FOREACH_NO_CONST_RVALUE_DETECTION -# else -# define BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -# endif -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -# include -# include -# include -# include -#endif - -namespace boost -{ - -// forward declarations for iterator_range -template -class iterator_range; - -// forward declarations for sub_range -template -class sub_range; - -namespace foreach -{ - /////////////////////////////////////////////////////////////////////////////// - // in_range - // - template - inline std::pair in_range(T begin, T end) - { - return std::make_pair(begin, end); - } - - /////////////////////////////////////////////////////////////////////////////// - // boost::foreach::is_lightweight_proxy - // Specialize this for user-defined collection types if they are inexpensive to copy. - // This tells BOOST_FOREACH it can avoid the rvalue/lvalue detection stuff. - template - struct is_lightweight_proxy - : boost::mpl::false_ - { - }; - - /////////////////////////////////////////////////////////////////////////////// - // boost::foreach::is_noncopyable - // Specialize this for user-defined collection types if they cannot be copied. - // This also tells BOOST_FOREACH to avoid the rvalue/lvalue detection stuff. - template - struct is_noncopyable - #if !defined(BOOST_BROKEN_IS_BASE_AND_DERIVED) && !defined(BOOST_NO_IS_ABSTRACT) - : boost::mpl::or_< - boost::is_abstract - , boost::is_base_and_derived - > - #elif !defined(BOOST_BROKEN_IS_BASE_AND_DERIVED) - : boost::is_base_and_derived - #elif !defined(BOOST_NO_IS_ABSTRACT) - : boost::is_abstract - #else - : boost::mpl::false_ - #endif - { - }; - -} // namespace foreach - -} // namespace boost - -// vc6/7 needs help ordering the following overloads -#ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -# define BOOST_FOREACH_TAG_DEFAULT ... -#else -# define BOOST_FOREACH_TAG_DEFAULT boost::foreach::tag -#endif - -/////////////////////////////////////////////////////////////////////////////// -// boost_foreach_is_lightweight_proxy -// Another customization point for the is_lightweight_proxy optimization, -// this one works on legacy compilers. Overload boost_foreach_is_lightweight_proxy -// at the global namespace for your type. -template -inline boost::foreach::is_lightweight_proxy * -boost_foreach_is_lightweight_proxy(T *&, BOOST_FOREACH_TAG_DEFAULT) { return 0; } - -template -inline boost::mpl::true_ * -boost_foreach_is_lightweight_proxy(std::pair *&, boost::foreach::tag) { return 0; } - -template -inline boost::mpl::true_ * -boost_foreach_is_lightweight_proxy(boost::iterator_range *&, boost::foreach::tag) { return 0; } - -template -inline boost::mpl::true_ * -boost_foreach_is_lightweight_proxy(boost::sub_range *&, boost::foreach::tag) { return 0; } - -template -inline boost::mpl::true_ * -boost_foreach_is_lightweight_proxy(T **&, boost::foreach::tag) { return 0; } - -/////////////////////////////////////////////////////////////////////////////// -// boost_foreach_is_noncopyable -// Another customization point for the is_noncopyable trait, -// this one works on legacy compilers. Overload boost_foreach_is_noncopyable -// at the global namespace for your type. -template -inline boost::foreach::is_noncopyable * -boost_foreach_is_noncopyable(T *&, BOOST_FOREACH_TAG_DEFAULT) { return 0; } - -namespace boost -{ - -namespace foreach_detail_ -{ - -/////////////////////////////////////////////////////////////////////////////// -// Define some utilities for assessing the properties of expressions -// -template -inline boost::mpl::and_ *and_(Bool1 *, Bool2 *) { return 0; } - -template -inline boost::mpl::and_ *and_(Bool1 *, Bool2 *, Bool3 *) { return 0; } - -template -inline boost::mpl::or_ *or_(Bool1 *, Bool2 *) { return 0; } - -template -inline boost::mpl::or_ *or_(Bool1 *, Bool2 *, Bool3 *) { return 0; } - -template -inline boost::mpl::not_ *not_(Bool1 *) { return 0; } - -template -inline boost::is_array *is_array_(T const &) { return 0; } - -template -inline boost::is_const *is_const_(T &) { return 0; } - -#ifndef BOOST_FOREACH_NO_RVALUE_DETECTION -template -inline boost::mpl::true_ *is_const_(T const &) { return 0; } -#endif - -#ifdef BOOST_NO_CXX11_RVALUE_REFERENCES -template -inline boost::mpl::false_ *is_rvalue_(T &, int) { return 0; } - -template -inline boost::mpl::true_ *is_rvalue_(T const &, ...) { return 0; } -#else -template -inline boost::is_rvalue_reference *is_rvalue_(T &&, int) { return 0; } -#endif - -/////////////////////////////////////////////////////////////////////////////// -// auto_any_t/auto_any -// General utility for putting an object of any type into automatic storage -struct auto_any_base -{ - // auto_any_base must evaluate to false in boolean context so that - // they can be declared in if() statements. - operator bool() const - { - return false; - } -}; - -template -struct auto_any : auto_any_base -{ - explicit auto_any(T const &t) - : item(t) - { - } - - // temporaries of type auto_any will be bound to const auto_any_base - // references, but we still want to be able to mutate the stored - // data, so declare it as mutable. - mutable T item; -}; - -typedef auto_any_base const &auto_any_t; - -template -inline BOOST_DEDUCED_TYPENAME boost::mpl::if_::type &auto_any_cast(auto_any_t a) -{ - return static_cast const &>(a).item; -} - -typedef boost::mpl::true_ const_; - -/////////////////////////////////////////////////////////////////////////////// -// type2type -// -template -struct type2type - : boost::mpl::if_ -{ -}; - -template -struct wrap_cstr -{ - typedef T type; -}; - -template<> -struct wrap_cstr -{ - typedef wrap_cstr type; - typedef char *iterator; - typedef char *const_iterator; -}; - -template<> -struct wrap_cstr -{ - typedef wrap_cstr type; - typedef char const *iterator; - typedef char const *const_iterator; -}; - -template<> -struct wrap_cstr -{ - typedef wrap_cstr type; - typedef wchar_t *iterator; - typedef wchar_t *const_iterator; -}; - -template<> -struct wrap_cstr -{ - typedef wrap_cstr type; - typedef wchar_t const *iterator; - typedef wchar_t const *const_iterator; -}; - -template -struct is_char_array - : mpl::and_< - is_array - , mpl::or_< - is_convertible - , is_convertible - > - > -{}; - -template -struct foreach_iterator -{ - // **** READ THIS IF YOUR COMPILE BREAKS HERE **** - // - // There is an ambiguity about how to iterate over arrays of char and wchar_t. - // Should the last array element be treated as a null terminator to be skipped, or - // is it just like any other element in the array? To fix the problem, you must - // say which behavior you want. - // - // To treat the container as a null-terminated string, merely cast it to a - // char const *, as in BOOST_FOREACH( char ch, (char const *)"hello" ) ... - // - // To treat the container as an array, use boost::as_array() in , - // as in BOOST_FOREACH( char ch, boost::as_array("hello") ) ... - #if !defined(BOOST_MSVC) || BOOST_MSVC > 1300 - BOOST_MPL_ASSERT_MSG( (!is_char_array::value), IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING, (T&) ); - #endif - - // If the type is a pointer to a null terminated string (as opposed - // to an array type), there is no ambiguity. - typedef BOOST_DEDUCED_TYPENAME wrap_cstr::type container; - - typedef BOOST_DEDUCED_TYPENAME boost::mpl::eval_if< - C - , range_const_iterator - , range_mutable_iterator - >::type type; -}; - - -template -struct foreach_reverse_iterator -{ - // **** READ THIS IF YOUR COMPILE BREAKS HERE **** - // - // There is an ambiguity about how to iterate over arrays of char and wchar_t. - // Should the last array element be treated as a null terminator to be skipped, or - // is it just like any other element in the array? To fix the problem, you must - // say which behavior you want. - // - // To treat the container as a null-terminated string, merely cast it to a - // char const *, as in BOOST_FOREACH( char ch, (char const *)"hello" ) ... - // - // To treat the container as an array, use boost::as_array() in , - // as in BOOST_FOREACH( char ch, boost::as_array("hello") ) ... - #if !defined(BOOST_MSVC) || BOOST_MSVC > 1300 - BOOST_MPL_ASSERT_MSG( (!is_char_array::value), IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING, (T&) ); - #endif - - // If the type is a pointer to a null terminated string (as opposed - // to an array type), there is no ambiguity. - typedef BOOST_DEDUCED_TYPENAME wrap_cstr::type container; - - typedef BOOST_DEDUCED_TYPENAME boost::mpl::eval_if< - C - , range_reverse_iterator - , range_reverse_iterator - >::type type; -}; - -template -struct foreach_reference - : iterator_reference::type> -{ -}; - -/////////////////////////////////////////////////////////////////////////////// -// encode_type -// -template -inline type2type *encode_type(T &, boost::mpl::false_ *) { return 0; } - -template -inline type2type *encode_type(T const &, boost::mpl::true_ *) { return 0; } - -/////////////////////////////////////////////////////////////////////////////// -// set_false -// -inline bool set_false(bool &b) -{ - b = false; - return false; -} - -/////////////////////////////////////////////////////////////////////////////// -// to_ptr -// -template -inline T *&to_ptr(T const &) -{ - static T *t = 0; - return t; -} - -// Borland needs a little extra help with arrays -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -template -inline T (*&to_ptr(T (&)[N]))[N] -{ - static T (*t)[N] = 0; - return t; -} - -/////////////////////////////////////////////////////////////////////////////// -// derefof -// -template -inline T &derefof(T *t) -{ - // This is a work-around for a compiler bug in Borland. If T* is a pointer to array type U(*)[N], - // then dereferencing it results in a U* instead of U(&)[N]. The cast forces the issue. - return reinterpret_cast( - *const_cast( - reinterpret_cast(t) - ) - ); -} - -# define BOOST_FOREACH_DEREFOF(T) boost::foreach_detail_::derefof(*T) -#else -# define BOOST_FOREACH_DEREFOF(T) (*T) -#endif - -#if defined(BOOST_FOREACH_COMPILE_TIME_CONST_RVALUE_DETECTION) \ - && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -/////////////////////////////////////////////////////////////////////////////// -// Rvalue references makes it drop-dead simple to detect at compile time -// whether an expression is an rvalue. -/////////////////////////////////////////////////////////////////////////////// - -# define BOOST_FOREACH_IS_RVALUE(COL) \ - boost::foreach_detail_::is_rvalue_((COL), 0) - -#elif defined(BOOST_FOREACH_COMPILE_TIME_CONST_RVALUE_DETECTION) \ - && defined(BOOST_NO_CXX11_RVALUE_REFERENCES) -/////////////////////////////////////////////////////////////////////////////// -// Detect at compile-time whether an expression yields an rvalue or -// an lvalue. This is rather non-standard, but some popular compilers -// accept it. -/////////////////////////////////////////////////////////////////////////////// - -/////////////////////////////////////////////////////////////////////////////// -// rvalue_probe -// -template -struct rvalue_probe -{ - struct private_type_ {}; - // can't ever return an array by value - typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_< - boost::mpl::or_, boost::is_array >, private_type_, T - >::type value_type; - operator value_type() { return *reinterpret_cast(this); } // never called - operator T &() const { return *reinterpret_cast(const_cast(this)); } // never called -}; - -template -rvalue_probe const make_probe(T const &) -{ - return rvalue_probe(); -} - -# define BOOST_FOREACH_IS_RVALUE(COL) \ - boost::foreach_detail_::and_( \ - boost::foreach_detail_::not_(boost::foreach_detail_::is_array_(COL)) \ - , (true ? 0 : boost::foreach_detail_::is_rvalue_( \ - (true ? boost::foreach_detail_::make_probe(COL) : (COL)), 0))) - -#elif defined(BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION) -/////////////////////////////////////////////////////////////////////////////// -// Detect at run-time whether an expression yields an rvalue -// or an lvalue. This is 100% standard C++, but not all compilers -// accept it. Also, it causes FOREACH to break when used with non- -// copyable collection types. -/////////////////////////////////////////////////////////////////////////////// - -/////////////////////////////////////////////////////////////////////////////// -// rvalue_probe -// -template -struct rvalue_probe -{ - rvalue_probe(T &t, bool &b) - : value(t) - , is_rvalue(b) - { - } - - struct private_type_ {}; - // can't ever return an array or an abstract type by value - #ifdef BOOST_NO_IS_ABSTRACT - typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_< - boost::is_array, private_type_, T - >::type value_type; - #else - typedef BOOST_DEDUCED_TYPENAME boost::mpl::if_< - boost::mpl::or_, boost::is_array >, private_type_, T - >::type value_type; - #endif - - operator value_type() - { - this->is_rvalue = true; - return this->value; - } - - operator T &() const - { - return this->value; - } - -private: - T &value; - bool &is_rvalue; -}; - -template -rvalue_probe make_probe(T &t, bool &b) { return rvalue_probe(t, b); } - -template -rvalue_probe make_probe(T const &t, bool &b) { return rvalue_probe(t, b); } - -/////////////////////////////////////////////////////////////////////////////// -// simple_variant -// holds either a T or a T const* -template -struct simple_variant -{ - simple_variant(T const *t) - : is_rvalue(false) - { - *static_cast(this->data.address()) = t; - } - - simple_variant(T const &t) - : is_rvalue(true) - { - ::new(this->data.address()) T(t); - } - - simple_variant(simple_variant const &that) - : is_rvalue(that.is_rvalue) - { - if(this->is_rvalue) - ::new(this->data.address()) T(*that.get()); - else - *static_cast(this->data.address()) = that.get(); - } - - ~simple_variant() - { - if(this->is_rvalue) - this->get()->~T(); - } - - T const *get() const - { - if(this->is_rvalue) - return static_cast(this->data.address()); - else - return *static_cast(this->data.address()); - } - -private: - enum size_type { size = sizeof(T) > sizeof(T*) ? sizeof(T) : sizeof(T*) }; - simple_variant &operator =(simple_variant const &); - bool const is_rvalue; - aligned_storage data; -}; - -// If the collection is an array or is noncopyable, it must be an lvalue. -// If the collection is a lightweight proxy, treat it as an rvalue -// BUGBUG what about a noncopyable proxy? -template -inline BOOST_DEDUCED_TYPENAME boost::enable_if, IsProxy>::type * -should_copy_impl(LValue *, IsProxy *, bool *) -{ - return 0; -} - -// Otherwise, we must determine at runtime whether it's an lvalue or rvalue -inline bool * -should_copy_impl(boost::mpl::false_ *, boost::mpl::false_ *, bool *is_rvalue) -{ - return is_rvalue; -} - -#endif - -/////////////////////////////////////////////////////////////////////////////// -// contain -// -template -inline auto_any contain(T const &t, boost::mpl::true_ *) // rvalue -{ - return auto_any(t); -} - -template -inline auto_any contain(T &t, boost::mpl::false_ *) // lvalue -{ - // Cannot seem to get sunpro to handle addressof() with array types. - #if BOOST_WORKAROUND(__SUNPRO_CC, BOOST_TESTED_AT(0x570)) - return auto_any(&t); - #else - return auto_any(boost::addressof(t)); - #endif -} - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -template -inline auto_any > -contain(T const &t, bool *rvalue) -{ - return auto_any >(*rvalue ? simple_variant(t) : simple_variant(&t)); -} -#endif - -///////////////////////////////////////////////////////////////////////////// -// begin -// -template -inline auto_any::type> -begin(auto_any_t col, type2type *, boost::mpl::true_ *) // rvalue -{ - return auto_any::type>( - boost::begin(auto_any_cast(col))); -} - -template -inline auto_any::type> -begin(auto_any_t col, type2type *, boost::mpl::false_ *) // lvalue -{ - typedef BOOST_DEDUCED_TYPENAME type2type::type type; - typedef BOOST_DEDUCED_TYPENAME foreach_iterator::type iterator; - return auto_any::type>( - iterator(boost::begin(BOOST_FOREACH_DEREFOF((auto_any_cast(col)))))); -} - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -template -inline auto_any::type> -begin(auto_any_t col, type2type *, bool *) -{ - return auto_any::type>( - boost::begin(*auto_any_cast, boost::mpl::false_>(col).get())); -} -#endif - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline auto_any -begin(auto_any_t col, type2type *, boost::mpl::true_ *) // null-terminated C-style strings -{ - return auto_any(auto_any_cast(col)); -} -#endif - -/////////////////////////////////////////////////////////////////////////////// -// end -// -template -inline auto_any::type> -end(auto_any_t col, type2type *, boost::mpl::true_ *) // rvalue -{ - return auto_any::type>( - boost::end(auto_any_cast(col))); -} - -template -inline auto_any::type> -end(auto_any_t col, type2type *, boost::mpl::false_ *) // lvalue -{ - typedef BOOST_DEDUCED_TYPENAME type2type::type type; - typedef BOOST_DEDUCED_TYPENAME foreach_iterator::type iterator; - return auto_any::type>( - iterator(boost::end(BOOST_FOREACH_DEREFOF((auto_any_cast(col)))))); -} - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -template -inline auto_any::type> -end(auto_any_t col, type2type *, bool *) -{ - return auto_any::type>( - boost::end(*auto_any_cast, boost::mpl::false_>(col).get())); -} -#endif - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline auto_any -end(auto_any_t, type2type *, boost::mpl::true_ *) // null-terminated C-style strings -{ - return auto_any(0); // not used -} -#endif - -/////////////////////////////////////////////////////////////////////////////// -// done -// -template -inline bool done(auto_any_t cur, auto_any_t end, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_iterator::type iter_t; - return auto_any_cast(cur) == auto_any_cast(end); -} - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline bool done(auto_any_t cur, auto_any_t, type2type *) // null-terminated C-style strings -{ - return ! *auto_any_cast(cur); -} -#endif - -/////////////////////////////////////////////////////////////////////////////// -// next -// -template -inline void next(auto_any_t cur, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_iterator::type iter_t; - ++auto_any_cast(cur); -} - -/////////////////////////////////////////////////////////////////////////////// -// deref -// -template -inline BOOST_DEDUCED_TYPENAME foreach_reference::type -deref(auto_any_t cur, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_iterator::type iter_t; - return *auto_any_cast(cur); -} - -///////////////////////////////////////////////////////////////////////////// -// rbegin -// -template -inline auto_any::type> -rbegin(auto_any_t col, type2type *, boost::mpl::true_ *) // rvalue -{ - return auto_any::type>( - boost::rbegin(auto_any_cast(col))); -} - -template -inline auto_any::type> -rbegin(auto_any_t col, type2type *, boost::mpl::false_ *) // lvalue -{ - typedef BOOST_DEDUCED_TYPENAME type2type::type type; - typedef BOOST_DEDUCED_TYPENAME foreach_reverse_iterator::type iterator; - return auto_any::type>( - iterator(boost::rbegin(BOOST_FOREACH_DEREFOF((auto_any_cast(col)))))); -} - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -template -inline auto_any::type> -rbegin(auto_any_t col, type2type *, bool *) -{ - return auto_any::type>( - boost::rbegin(*auto_any_cast, boost::mpl::false_>(col).get())); -} -#endif - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline auto_any > -rbegin(auto_any_t col, type2type *, boost::mpl::true_ *) // null-terminated C-style strings -{ - T *p = auto_any_cast(col); - while(0 != *p) - ++p; - return auto_any >(reverse_iterator(p)); -} -#endif - -/////////////////////////////////////////////////////////////////////////////// -// rend -// -template -inline auto_any::type> -rend(auto_any_t col, type2type *, boost::mpl::true_ *) // rvalue -{ - return auto_any::type>( - boost::rend(auto_any_cast(col))); -} - -template -inline auto_any::type> -rend(auto_any_t col, type2type *, boost::mpl::false_ *) // lvalue -{ - typedef BOOST_DEDUCED_TYPENAME type2type::type type; - typedef BOOST_DEDUCED_TYPENAME foreach_reverse_iterator::type iterator; - return auto_any::type>( - iterator(boost::rend(BOOST_FOREACH_DEREFOF((auto_any_cast(col)))))); -} - -#ifdef BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION -template -inline auto_any::type> -rend(auto_any_t col, type2type *, bool *) -{ - return auto_any::type>( - boost::rend(*auto_any_cast, boost::mpl::false_>(col).get())); -} -#endif - -#ifndef BOOST_NO_FUNCTION_TEMPLATE_ORDERING -template -inline auto_any > -rend(auto_any_t col, type2type *, boost::mpl::true_ *) // null-terminated C-style strings -{ - return auto_any >( - reverse_iterator(auto_any_cast(col))); -} -#endif - -/////////////////////////////////////////////////////////////////////////////// -// rdone -// -template -inline bool rdone(auto_any_t cur, auto_any_t end, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_reverse_iterator::type iter_t; - return auto_any_cast(cur) == auto_any_cast(end); -} - -/////////////////////////////////////////////////////////////////////////////// -// rnext -// -template -inline void rnext(auto_any_t cur, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_reverse_iterator::type iter_t; - ++auto_any_cast(cur); -} - -/////////////////////////////////////////////////////////////////////////////// -// rderef -// -template -inline BOOST_DEDUCED_TYPENAME foreach_reference::type -rderef(auto_any_t cur, type2type *) -{ - typedef BOOST_DEDUCED_TYPENAME foreach_reverse_iterator::type iter_t; - return *auto_any_cast(cur); -} - -} // namespace foreach_detail_ -} // namespace boost - -// Suppress a bogus code analysis warning on vc8+ -#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) -# define BOOST_FOREACH_SUPPRESS_WARNINGS() __pragma(warning(suppress:6001)) -#else -# define BOOST_FOREACH_SUPPRESS_WARNINGS() -#endif - -/////////////////////////////////////////////////////////////////////////////// -// Define a macro for giving hidden variables a unique name. Not strictly -// needed, but eliminates some warnings on some compilers. -#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1500)) -// With some versions of MSVC, use of __LINE__ to create unique identifiers -// can fail when the Edit-and-Continue debug flag is used. -# define BOOST_FOREACH_ID(x) x -#else -# define BOOST_FOREACH_ID(x) BOOST_PP_CAT(x, __LINE__) -#endif - -// A sneaky way to get the type of the collection without evaluating the expression -#define BOOST_FOREACH_TYPEOF(COL) \ - (true ? 0 : boost::foreach_detail_::encode_type(COL, boost::foreach_detail_::is_const_(COL))) - -// returns true_* if the type is noncopyable -#define BOOST_FOREACH_IS_NONCOPYABLE(COL) \ - boost_foreach_is_noncopyable( \ - boost::foreach_detail_::to_ptr(COL) \ - , boost_foreach_argument_dependent_lookup_hack_value) - -// returns true_* if the type is a lightweight proxy (and is not noncopyable) -#define BOOST_FOREACH_IS_LIGHTWEIGHT_PROXY(COL) \ - boost::foreach_detail_::and_( \ - boost::foreach_detail_::not_(BOOST_FOREACH_IS_NONCOPYABLE(COL)) \ - , boost_foreach_is_lightweight_proxy( \ - boost::foreach_detail_::to_ptr(COL) \ - , boost_foreach_argument_dependent_lookup_hack_value)) - -#if defined(BOOST_FOREACH_COMPILE_TIME_CONST_RVALUE_DETECTION) -/////////////////////////////////////////////////////////////////////////////// -// R-values and const R-values supported here with zero runtime overhead -/////////////////////////////////////////////////////////////////////////////// - -// No variable is needed to track the rvalue-ness of the collection expression -# define BOOST_FOREACH_PREAMBLE() \ - BOOST_FOREACH_SUPPRESS_WARNINGS() - -// Evaluate the collection expression -# define BOOST_FOREACH_EVALUATE(COL) \ - (COL) - -# define BOOST_FOREACH_SHOULD_COPY(COL) \ - (true ? 0 : boost::foreach_detail_::or_( \ - BOOST_FOREACH_IS_RVALUE(COL) \ - , BOOST_FOREACH_IS_LIGHTWEIGHT_PROXY(COL))) - -#elif defined(BOOST_FOREACH_RUN_TIME_CONST_RVALUE_DETECTION) -/////////////////////////////////////////////////////////////////////////////// -// R-values and const R-values supported here -/////////////////////////////////////////////////////////////////////////////// - -// Declare a variable to track the rvalue-ness of the collection expression -# define BOOST_FOREACH_PREAMBLE() \ - BOOST_FOREACH_SUPPRESS_WARNINGS() \ - if (bool BOOST_FOREACH_ID(_foreach_is_rvalue) = false) {} else - -// Evaluate the collection expression, and detect if it is an lvalue or and rvalue -# define BOOST_FOREACH_EVALUATE(COL) \ - (true ? boost::foreach_detail_::make_probe((COL), BOOST_FOREACH_ID(_foreach_is_rvalue)) : (COL)) - -// The rvalue/lvalue-ness of the collection expression is determined dynamically, unless -// the type is an array or is noncopyable or is non-const, in which case we know it's an lvalue. -// If the type happens to be a lightweight proxy, always make a copy. -# define BOOST_FOREACH_SHOULD_COPY(COL) \ - (boost::foreach_detail_::should_copy_impl( \ - true ? 0 : boost::foreach_detail_::or_( \ - boost::foreach_detail_::is_array_(COL) \ - , BOOST_FOREACH_IS_NONCOPYABLE(COL) \ - , boost::foreach_detail_::not_(boost::foreach_detail_::is_const_(COL))) \ - , true ? 0 : BOOST_FOREACH_IS_LIGHTWEIGHT_PROXY(COL) \ - , &BOOST_FOREACH_ID(_foreach_is_rvalue))) - -#elif !defined(BOOST_FOREACH_NO_RVALUE_DETECTION) -/////////////////////////////////////////////////////////////////////////////// -// R-values supported here, const R-values NOT supported here -/////////////////////////////////////////////////////////////////////////////// - -// No variable is needed to track the rvalue-ness of the collection expression -# define BOOST_FOREACH_PREAMBLE() \ - BOOST_FOREACH_SUPPRESS_WARNINGS() - -// Evaluate the collection expression -# define BOOST_FOREACH_EVALUATE(COL) \ - (COL) - -// Determine whether the collection expression is an lvalue or an rvalue. -// NOTE: this gets the answer wrong for const rvalues. -# define BOOST_FOREACH_SHOULD_COPY(COL) \ - (true ? 0 : boost::foreach_detail_::or_( \ - boost::foreach_detail_::is_rvalue_((COL), 0) \ - , BOOST_FOREACH_IS_LIGHTWEIGHT_PROXY(COL))) - -#else -/////////////////////////////////////////////////////////////////////////////// -// R-values NOT supported here -/////////////////////////////////////////////////////////////////////////////// - -// No variable is needed to track the rvalue-ness of the collection expression -# define BOOST_FOREACH_PREAMBLE() \ - BOOST_FOREACH_SUPPRESS_WARNINGS() - -// Evaluate the collection expression -# define BOOST_FOREACH_EVALUATE(COL) \ - (COL) - -// Can't use rvalues with BOOST_FOREACH (unless they are lightweight proxies) -# define BOOST_FOREACH_SHOULD_COPY(COL) \ - (true ? 0 : BOOST_FOREACH_IS_LIGHTWEIGHT_PROXY(COL)) - -#endif - -#define BOOST_FOREACH_CONTAIN(COL) \ - boost::foreach_detail_::contain( \ - BOOST_FOREACH_EVALUATE(COL) \ - , BOOST_FOREACH_SHOULD_COPY(COL)) - -#define BOOST_FOREACH_BEGIN(COL) \ - boost::foreach_detail_::begin( \ - BOOST_FOREACH_ID(_foreach_col) \ - , BOOST_FOREACH_TYPEOF(COL) \ - , BOOST_FOREACH_SHOULD_COPY(COL)) - -#define BOOST_FOREACH_END(COL) \ - boost::foreach_detail_::end( \ - BOOST_FOREACH_ID(_foreach_col) \ - , BOOST_FOREACH_TYPEOF(COL) \ - , BOOST_FOREACH_SHOULD_COPY(COL)) - -#define BOOST_FOREACH_DONE(COL) \ - boost::foreach_detail_::done( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_ID(_foreach_end) \ - , BOOST_FOREACH_TYPEOF(COL)) - -#define BOOST_FOREACH_NEXT(COL) \ - boost::foreach_detail_::next( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_TYPEOF(COL)) - -#define BOOST_FOREACH_DEREF(COL) \ - boost::foreach_detail_::deref( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_TYPEOF(COL)) - -#define BOOST_FOREACH_RBEGIN(COL) \ - boost::foreach_detail_::rbegin( \ - BOOST_FOREACH_ID(_foreach_col) \ - , BOOST_FOREACH_TYPEOF(COL) \ - , BOOST_FOREACH_SHOULD_COPY(COL)) - -#define BOOST_FOREACH_REND(COL) \ - boost::foreach_detail_::rend( \ - BOOST_FOREACH_ID(_foreach_col) \ - , BOOST_FOREACH_TYPEOF(COL) \ - , BOOST_FOREACH_SHOULD_COPY(COL)) - -#define BOOST_FOREACH_RDONE(COL) \ - boost::foreach_detail_::rdone( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_ID(_foreach_end) \ - , BOOST_FOREACH_TYPEOF(COL)) - -#define BOOST_FOREACH_RNEXT(COL) \ - boost::foreach_detail_::rnext( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_TYPEOF(COL)) - -#define BOOST_FOREACH_RDEREF(COL) \ - boost::foreach_detail_::rderef( \ - BOOST_FOREACH_ID(_foreach_cur) \ - , BOOST_FOREACH_TYPEOF(COL)) - -/////////////////////////////////////////////////////////////////////////////// -// BOOST_FOREACH -// -// For iterating over collections. Collections can be -// arrays, null-terminated strings, or STL containers. -// The loop variable can be a value or reference. For -// example: -// -// std::list int_list(/*stuff*/); -// BOOST_FOREACH(int &i, int_list) -// { -// /* -// * loop body goes here. -// * i is a reference to the int in int_list. -// */ -// } -// -// Alternately, you can declare the loop variable first, -// so you can access it after the loop finishes. Obviously, -// if you do it this way, then the loop variable cannot be -// a reference. -// -// int i; -// BOOST_FOREACH(i, int_list) -// { ... } -// -#define BOOST_FOREACH(VAR, COL) \ - BOOST_FOREACH_PREAMBLE() \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_col) = BOOST_FOREACH_CONTAIN(COL)) {} else \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_cur) = BOOST_FOREACH_BEGIN(COL)) {} else \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_end) = BOOST_FOREACH_END(COL)) {} else \ - for (bool BOOST_FOREACH_ID(_foreach_continue) = true; \ - BOOST_FOREACH_ID(_foreach_continue) && !BOOST_FOREACH_DONE(COL); \ - BOOST_FOREACH_ID(_foreach_continue) ? BOOST_FOREACH_NEXT(COL) : (void)0) \ - if (boost::foreach_detail_::set_false(BOOST_FOREACH_ID(_foreach_continue))) {} else \ - for (VAR = BOOST_FOREACH_DEREF(COL); !BOOST_FOREACH_ID(_foreach_continue); BOOST_FOREACH_ID(_foreach_continue) = true) - -/////////////////////////////////////////////////////////////////////////////// -// BOOST_REVERSE_FOREACH -// -// For iterating over collections in reverse order. In -// all other respects, BOOST_REVERSE_FOREACH is like -// BOOST_FOREACH. -// -#define BOOST_REVERSE_FOREACH(VAR, COL) \ - BOOST_FOREACH_PREAMBLE() \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_col) = BOOST_FOREACH_CONTAIN(COL)) {} else \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_cur) = BOOST_FOREACH_RBEGIN(COL)) {} else \ - if (boost::foreach_detail_::auto_any_t BOOST_FOREACH_ID(_foreach_end) = BOOST_FOREACH_REND(COL)) {} else \ - for (bool BOOST_FOREACH_ID(_foreach_continue) = true; \ - BOOST_FOREACH_ID(_foreach_continue) && !BOOST_FOREACH_RDONE(COL); \ - BOOST_FOREACH_ID(_foreach_continue) ? BOOST_FOREACH_RNEXT(COL) : (void)0) \ - if (boost::foreach_detail_::set_false(BOOST_FOREACH_ID(_foreach_continue))) {} else \ - for (VAR = BOOST_FOREACH_RDEREF(COL); !BOOST_FOREACH_ID(_foreach_continue); BOOST_FOREACH_ID(_foreach_continue) = true) - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/foreach_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/foreach_fwd.hpp deleted file mode 100644 index 4e0bb370..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/foreach_fwd.hpp +++ /dev/null @@ -1,51 +0,0 @@ -/////////////////////////////////////////////////////////////////////////////// -// foreach.hpp header file -// -// Copyright 2010 Eric Niebler. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// See http://www.boost.org/libs/foreach for documentation -// -// Credits: -// Kazutoshi Satoda: for suggesting the need for a _fwd header for foreach's -// customization points. - -#ifndef BOOST_FOREACH_FWD_HPP -#define BOOST_FOREACH_FWD_HPP - -// This must be at global scope, hence the uglified name -enum boost_foreach_argument_dependent_lookup_hack -{ - boost_foreach_argument_dependent_lookup_hack_value -}; - -namespace boost -{ - -namespace foreach -{ - /////////////////////////////////////////////////////////////////////////////// - // boost::foreach::tag - // - typedef boost_foreach_argument_dependent_lookup_hack tag; - - /////////////////////////////////////////////////////////////////////////////// - // boost::foreach::is_lightweight_proxy - // Specialize this for user-defined collection types if they are inexpensive to copy. - // This tells BOOST_FOREACH it can avoid the rvalue/lvalue detection stuff. - template - struct is_lightweight_proxy; - - /////////////////////////////////////////////////////////////////////////////// - // boost::foreach::is_noncopyable - // Specialize this for user-defined collection types if they cannot be copied. - // This also tells BOOST_FOREACH to avoid the rvalue/lvalue detection stuff. - template - struct is_noncopyable; - -} // namespace foreach - -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/format.hpp b/third_party/ycmd/cpp/BoostParts/boost/format.hpp deleted file mode 100644 index 73464a81..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format.hpp +++ /dev/null @@ -1,59 +0,0 @@ -// ---------------------------------------------------------------------------- -// format.hpp : primary header -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_HPP -#define BOOST_FORMAT_HPP - -#include -#include -#include -#include - -#ifndef BOOST_NO_STD_LOCALE -#include -#endif - -// *** Compatibility framework -#include - -#ifdef BOOST_NO_LOCALE_ISIDIGIT -#include // we'll use the non-locale 's std::isdigit(int) -#endif - -// **** Forward declarations ---------------------------------- -#include // basic_format, and other frontends -#include // misc forward declarations for internal use - -// **** Auxiliary structs (stream_format_state , and format_item ) -#include - -// **** Format class interface -------------------------------- -#include - -// **** Exceptions ----------------------------------------------- -#include - -// **** Implementation ------------------------------------------- -#include // member functions -#include // class for grouping arguments -#include // argument-feeding functions -#include // format-string parsing (member-)functions - -// **** Implementation of the free functions ---------------------- -#include - - -// *** Undefine 'local' macros : -#include - -#endif // BOOST_FORMAT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream.hpp deleted file mode 100644 index e236be35..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream.hpp +++ /dev/null @@ -1,176 +0,0 @@ -// ---------------------------------------------------------------------------- -// alt_sstream.hpp : alternative stringstream -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - - - -#ifndef BOOST_SK_ALT_SSTREAM_HPP -#define BOOST_SK_ALT_SSTREAM_HPP - -#include -#include -#include -#include -#include - -namespace boost { - namespace io { - - template, - class Alloc=::std::allocator > - class basic_altstringbuf; - - template, - class Alloc=::std::allocator > - class basic_oaltstringstream; - - - template - class basic_altstringbuf - : public ::std::basic_streambuf - { - typedef ::std::basic_streambuf streambuf_t; - typedef typename CompatAlloc::compatible_type compat_allocator_type; - typedef typename CompatTraits::compatible_type compat_traits_type; - public: - typedef Ch char_type; - typedef Tr traits_type; - typedef typename compat_traits_type::int_type int_type; - typedef typename compat_traits_type::pos_type pos_type; - typedef typename compat_traits_type::off_type off_type; - typedef Alloc allocator_type; - typedef ::std::basic_string string_type; - typedef typename string_type::size_type size_type; - - typedef ::std::streamsize streamsize; - - - explicit basic_altstringbuf(std::ios_base::openmode mode - = std::ios_base::in | std::ios_base::out) - : putend_(NULL), is_allocated_(false), mode_(mode) - {} - explicit basic_altstringbuf(const string_type& s, - ::std::ios_base::openmode mode - = ::std::ios_base::in | ::std::ios_base::out) - : putend_(NULL), is_allocated_(false), mode_(mode) - { dealloc(); str(s); } - virtual ~basic_altstringbuf() - { dealloc(); } - using streambuf_t::pbase; - using streambuf_t::pptr; - using streambuf_t::epptr; - using streambuf_t::eback; - using streambuf_t::gptr; - using streambuf_t::egptr; - - void clear_buffer(); - void str(const string_type& s); - - // 0-copy access : - Ch * begin() const; - size_type size() const; - size_type cur_size() const; // stop at current pointer - Ch * pend() const // the highest position reached by pptr() since creation - { return ((putend_ < pptr()) ? pptr() : putend_); } - size_type pcount() const - { return static_cast( pptr() - pbase()) ;} - - // copy buffer to string : - string_type str() const - { return string_type(begin(), size()); } - string_type cur_str() const - { return string_type(begin(), cur_size()); } - protected: - explicit basic_altstringbuf (basic_altstringbuf * s, - ::std::ios_base::openmode mode - = ::std::ios_base::in | ::std::ios_base::out) - : putend_(NULL), is_allocated_(false), mode_(mode) - { dealloc(); str(s); } - - virtual pos_type seekoff(off_type off, ::std::ios_base::seekdir way, - ::std::ios_base::openmode which - = ::std::ios_base::in | ::std::ios_base::out); - virtual pos_type seekpos (pos_type pos, - ::std::ios_base::openmode which - = ::std::ios_base::in | ::std::ios_base::out); - virtual int_type underflow(); - virtual int_type pbackfail(int_type meta = compat_traits_type::eof()); - virtual int_type overflow(int_type meta = compat_traits_type::eof()); - void dealloc(); - private: - enum { alloc_min = 256}; // minimum size of allocations - - Ch *putend_; // remembers (over seeks) the highest value of pptr() - bool is_allocated_; - ::std::ios_base::openmode mode_; - compat_allocator_type alloc_; // the allocator object - }; - - -// --- class basic_oaltstringstream ---------------------------------------- - template - class basic_oaltstringstream - : private base_from_member< shared_ptr< basic_altstringbuf< Ch, Tr, Alloc> > >, - public ::std::basic_ostream - { - class No_Op { - // used as no-op deleter for (not-owner) shared_pointers - public: - template - const T & operator()(const T & arg) { return arg; } - }; - typedef ::std::basic_ostream stream_t; - typedef boost::base_from_member > > - pbase_type; - typedef ::std::basic_string string_type; - typedef typename string_type::size_type size_type; - typedef basic_altstringbuf stringbuf_t; - public: - typedef Alloc allocator_type; - basic_oaltstringstream() - : pbase_type(new stringbuf_t), stream_t(rdbuf()) - { } - basic_oaltstringstream(::boost::shared_ptr buf) - : pbase_type(buf), stream_t(rdbuf()) - { } - basic_oaltstringstream(stringbuf_t * buf) - : pbase_type(buf, No_Op() ), stream_t(rdbuf()) - { } - stringbuf_t * rdbuf() const - { return pbase_type::member.get(); } - void clear_buffer() - { rdbuf()->clear_buffer(); } - - // 0-copy access : - Ch * begin() const - { return rdbuf()->begin(); } - size_type size() const - { return rdbuf()->size(); } - size_type cur_size() const // stops at current position - { return rdbuf()->cur_size(); } - - // copy buffer to string : - string_type str() const // [pbase, epptr[ - { return rdbuf()->str(); } - string_type cur_str() const // [pbase, pptr[ - { return rdbuf()->cur_str(); } - void str(const string_type& s) - { rdbuf()->str(s); } - }; - - } // N.S. io -} // N.S. boost - -#include - -#endif // include guard - diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream_impl.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream_impl.hpp deleted file mode 100644 index 9975e4f9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/alt_sstream_impl.hpp +++ /dev/null @@ -1,313 +0,0 @@ -// ---------------------------------------------------------------------------- -// alt_sstream_impl.hpp : alternative stringstream, templates implementation -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_SK_ALT_SSTREAM_IMPL_HPP -#define BOOST_SK_ALT_SSTREAM_IMPL_HPP - -namespace boost { - namespace io { -// --- Implementation ------------------------------------------------------// - - template - void basic_altstringbuf:: - clear_buffer () { - const Ch * p = pptr(); - const Ch * b = pbase(); - if(p != NULL && p != b) { - seekpos(0, ::std::ios_base::out); - } - p = gptr(); - b = eback(); - if(p != NULL && p != b) { - seekpos(0, ::std::ios_base::in); - } - } - - template - void basic_altstringbuf:: - str (const string_type& s) { - size_type sz=s.size(); - if(sz != 0 && mode_ & (::std::ios_base::in | ::std::ios_base::out) ) { -#ifdef _RWSTD_NO_CLASS_PARTIAL_SPEC - void *vd_ptr = alloc_.allocate(sz, is_allocated_? eback() : 0); - Ch *new_ptr = static_cast(vd_ptr); -#else - Ch *new_ptr = alloc_.allocate(sz, is_allocated_? eback() : 0); -#endif - // if this didnt throw, we're safe, update the buffer - dealloc(); - sz = s.copy(new_ptr, sz); - putend_ = new_ptr + sz; - if(mode_ & ::std::ios_base::in) - streambuf_t::setg(new_ptr, new_ptr, new_ptr + sz); - if(mode_ & ::std::ios_base::out) { - streambuf_t::setp(new_ptr, new_ptr + sz); - if(mode_ & (::std::ios_base::app | ::std::ios_base::ate)) - streambuf_t::pbump(static_cast(sz)); - if(gptr() == NULL) - streambuf_t::setg(new_ptr, NULL, new_ptr); - } - is_allocated_ = true; - } - else - dealloc(); - } - template - Ch* basic_altstringbuf:: - begin () const { - if(mode_ & ::std::ios_base::out && pptr() != NULL) - return pbase(); - else if(mode_ & ::std::ios_base::in && gptr() != NULL) - return eback(); - return NULL; - } - - template - typename std::basic_string::size_type - basic_altstringbuf:: - size () const { - if(mode_ & ::std::ios_base::out && pptr()) - return static_cast(pend() - pbase()); - else if(mode_ & ::std::ios_base::in && gptr()) - return static_cast(egptr() - eback()); - else - return 0; - } - - template - typename std::basic_string::size_type - basic_altstringbuf:: - cur_size () const { - if(mode_ & ::std::ios_base::out && pptr()) - return static_cast( pptr() - pbase()); - else if(mode_ & ::std::ios_base::in && gptr()) - return static_cast( gptr() - eback()); - else - return 0; - } - - template - typename basic_altstringbuf::pos_type - basic_altstringbuf:: - seekoff (off_type off, ::std::ios_base::seekdir way, ::std::ios_base::openmode which) { - if(pptr() != NULL && putend_ < pptr()) - putend_ = pptr(); - if(which & ::std::ios_base::in && gptr() != NULL) { - // get area - if(way == ::std::ios_base::end) - off += static_cast(putend_ - gptr()); - else if(way == ::std::ios_base::beg) - off += static_cast(eback() - gptr()); - else if(way != ::std::ios_base::cur || (which & ::std::ios_base::out) ) - // (altering in&out is only supported if way is beg or end, not cur) - return pos_type(off_type(-1)); - if(eback() <= off+gptr() && off+gptr() <= putend_ ) { - // set gptr - streambuf_t::gbump(static_cast(off)); - if(which & ::std::ios_base::out && pptr() != NULL) - // update pptr to match gptr - streambuf_t::pbump(static_cast(gptr()-pptr())); - } - else - off = off_type(-1); - } - else if(which & ::std::ios_base::out && pptr() != NULL) { - // put area - if(way == ::std::ios_base::end) - off += static_cast(putend_ - pptr()); - else if(way == ::std::ios_base::beg) - off += static_cast(pbase() - pptr()); - else if(way != ::std::ios_base::beg) - return pos_type(off_type(-1)); - if(pbase() <= off+pptr() && off+pptr() <= putend_) - // set pptr - streambuf_t::pbump(static_cast(off)); - else - off = off_type(-1); - } - else // neither in nor out - off = off_type(-1); - return (pos_type(off)); - } - //- end seekoff(..) - - - template - typename basic_altstringbuf::pos_type - basic_altstringbuf:: - seekpos (pos_type pos, ::std::ios_base::openmode which) { - off_type off = off_type(pos); // operation guaranteed by 27.4.3.2 table 88 - if(pptr() != NULL && putend_ < pptr()) - putend_ = pptr(); - if(off != off_type(-1)) { - if(which & ::std::ios_base::in && gptr() != NULL) { - // get area - if(0 <= off && off <= putend_ - eback()) { - streambuf_t::gbump(static_cast(eback() - gptr() + off)); - if(which & ::std::ios_base::out && pptr() != NULL) { - // update pptr to match gptr - streambuf_t::pbump(static_cast(gptr()-pptr())); - } - } - else - off = off_type(-1); - } - else if(which & ::std::ios_base::out && pptr() != NULL) { - // put area - if(0 <= off && off <= putend_ - eback()) - streambuf_t::pbump(static_cast(eback() - pptr() + off)); - else - off = off_type(-1); - } - else // neither in nor out - off = off_type(-1); - return (pos_type(off)); - } - else { - BOOST_ASSERT(0); // 27.4.3.2 allows undefined-behaviour here - return pos_type(off_type(-1)); - } - } - // -end seekpos(..) - - - template - typename basic_altstringbuf::int_type - basic_altstringbuf:: - underflow () { - if(gptr() == NULL) // no get area -> nothing to get. - return (compat_traits_type::eof()); - else if(gptr() < egptr()) // ok, in buffer - return (compat_traits_type::to_int_type(*gptr())); - else if(mode_ & ::std::ios_base::in && pptr() != NULL - && (gptr() < pptr() || gptr() < putend_) ) - { // expand get area - if(putend_ < pptr()) - putend_ = pptr(); // remember pptr reached this far - streambuf_t::setg(eback(), gptr(), putend_); - return (compat_traits_type::to_int_type(*gptr())); - } - else // couldnt get anything. EOF. - return (compat_traits_type::eof()); - } - // -end underflow(..) - - - template - typename basic_altstringbuf::int_type - basic_altstringbuf:: - pbackfail (int_type meta) { - if(gptr() != NULL && (eback() < gptr()) - && (mode_ & (::std::ios_base::out) - || compat_traits_type::eq_int_type(compat_traits_type::eof(), meta) - || compat_traits_type::eq(compat_traits_type::to_char_type(meta), gptr()[-1]) ) ) { - streambuf_t::gbump(-1); // back one character - if(!compat_traits_type::eq_int_type(compat_traits_type::eof(), meta)) - // put-back meta into get area - *gptr() = compat_traits_type::to_char_type(meta); - return (compat_traits_type::not_eof(meta)); - } - else - return (compat_traits_type::eof()); // failed putback - } - // -end pbackfail(..) - - - template - typename basic_altstringbuf::int_type - basic_altstringbuf:: - overflow (int_type meta) { -#ifdef BOOST_MSVC -#pragma warning(push) -#pragma warning(disable:4996) -#endif - if(compat_traits_type::eq_int_type(compat_traits_type::eof(), meta)) - return compat_traits_type::not_eof(meta); // nothing to do - else if(pptr() != NULL && pptr() < epptr()) { - streambuf_t::sputc(compat_traits_type::to_char_type(meta)); - return meta; - } - else if(! (mode_ & ::std::ios_base::out)) - // no write position, and cant make one - return compat_traits_type::eof(); - else { // make a write position available - std::size_t prev_size = pptr() == NULL ? 0 : epptr() - eback(); - std::size_t new_size = prev_size; - // exponential growth : size *= 1.5 - std::size_t add_size = new_size / 2; - if(add_size < alloc_min) - add_size = alloc_min; - Ch * newptr = NULL, *oldptr = eback(); - - // make sure adding add_size wont overflow size_t - while (0 < add_size && ((std::numeric_limits::max)() - - add_size < new_size) ) - add_size /= 2; - if(0 < add_size) { - new_size += add_size; -#ifdef _RWSTD_NO_CLASS_PARTIAL_SPEC - void *vdptr = alloc_.allocate(new_size, is_allocated_? oldptr : 0); - newptr = static_cast(vdptr); -#else - newptr = alloc_.allocate(new_size, is_allocated_? oldptr : 0); -#endif - } - - if(0 < prev_size) - compat_traits_type::copy(newptr, oldptr, prev_size); - if(is_allocated_) - alloc_.deallocate(oldptr, prev_size); - is_allocated_=true; - - if(prev_size == 0) { // first allocation - putend_ = newptr; - streambuf_t::setp(newptr, newptr + new_size); - if(mode_ & ::std::ios_base::in) - streambuf_t::setg(newptr, newptr, newptr + 1); - else - streambuf_t::setg(newptr, 0, newptr); - } - else { // update pointers - putend_ = putend_ - oldptr + newptr; - int pptr_count = static_cast(pptr()-pbase()); - int gptr_count = static_cast(gptr()-eback()); - streambuf_t::setp(pbase() - oldptr + newptr, newptr + new_size); - streambuf_t::pbump(pptr_count); - if(mode_ & ::std::ios_base::in) - streambuf_t::setg(newptr, newptr + gptr_count, pptr() + 1); - else - streambuf_t::setg(newptr, 0, newptr); - } - streambuf_t::sputc(compat_traits_type::to_char_type(meta)); - return meta; - } -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - } - // -end overflow(..) - - template - void basic_altstringbuf:: dealloc() { - if(is_allocated_) - alloc_.deallocate(eback(), (pptr() != NULL ? epptr() : egptr()) - eback()); - is_allocated_ = false; - streambuf_t::setg(0, 0, 0); - streambuf_t::setp(0, 0); - putend_ = NULL; - } - - }// N.S. io -} // N.S. boost - -#endif // include guard - diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/compat_workarounds.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/compat_workarounds.hpp deleted file mode 100644 index 8e51514f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/compat_workarounds.hpp +++ /dev/null @@ -1,86 +0,0 @@ -// ---------------------------------------------------------------------------- -// compat_workarounds : general framework for non-conformance workarounds -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// see http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - - -// this file defines wrapper classes to hide non-conforming -// std::char_traits<> and std::allocator<> traits -// and Includes : config_macros.hpp (defines config macros -// and compiler-specific switches) - -// Non-conformant Std-libs fail to supply conformant traits (std::char_traits, -// std::allocator) and/or the std::string doesnt support them. -// We don't want to have hundreds of #ifdef workarounds, so we define -// replacement traits. -// But both char_traits and allocator traits are visible in the interface, -// (inside the final string type), thus we need to keep both -// the replacement type (typedefed to 'compatible_type') for real use, -// and the original stdlib type (typedef to 'type_for_string') for interface -// visibility. This is what Compat* classes do (as well as be transparent -// when good allocator and char traits are present) - -#ifndef BOOST_FORMAT_COMPAT_WORKAROUNDS_HPP -#define BOOST_FORMAT_COMPAT_WORKAROUNDS_HPP - -namespace boost { - namespace io { - - // gcc-2.95 char traits (non-conformantly named string_char_traits) - // lack several functions so we extend them in a replacement class. - template - class CompatTraits; - - // std::allocator in gcc-2.95 is ok, but basic_string only works - // with plain 'std::alloc' still, alt_stringbuf requires a functionnal - // alloc template argument, so we need a replacement allocator - template - class CompatAlloc; - } // N.S. io -}// N.S. boost - - -#include - // sets-up macros and load compiler-specific workarounds headers. - -#if !defined(BOOST_FORMAT_STREAMBUF_DEFINED) -// workarounds-gcc-2.95 might have defined own streambuf -#include -#endif - -#if !defined(BOOST_FORMAT_OSTREAM_DEFINED) -// workarounds-gcc-2.95 might already have included -#include -#endif - - - -namespace boost { - namespace io { - - // **** CompatTraits general definitions : ---------------------------- - template - class CompatTraits - { // general case : be transparent - public: - typedef Tr compatible_type; - }; - - // **** CompatAlloc general definitions : ----------------------------- - template - class CompatAlloc - { // general case : be transparent - public: - typedef Alloc compatible_type; - }; - - } //N.S. io -} // N.S. boost -#endif // include guard diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/config_macros.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/config_macros.hpp deleted file mode 100644 index 1f01b178..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/config_macros.hpp +++ /dev/null @@ -1,97 +0,0 @@ -// -*- C++ -*- -// ---------------------------------------------------------------------------- -// config_macros.hpp : configuration macros for the format library -// only BOOST_IO_STD is absolutely needed (it should be 'std::' in general) -// others are compiler-specific workaround macros used in #ifdef switches -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// see http://www.boost.org/libs/format for library home page - - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_CONFIG_MACROS_HPP -#define BOOST_FORMAT_CONFIG_MACROS_HPP - -#include -#include - -// make sure our local macros wont override something : -#if defined(BOOST_NO_LOCALE_ISDIGIT) || defined(BOOST_OVERLOAD_FOR_NON_CONST) \ - || defined(BOOST_IO_STD) || defined( BOOST_IO_NEEDS_USING_DECLARATION ) \ - || defined(BOOST_NO_TEMPLATE_STD_STREAM) \ - || defined(BOOST_FORMAT_STREAMBUF_DEFINED) || defined(BOOST_FORMAT_OSTREAM_DEFINED) -#error "boost::format uses a local macro that is already defined." -#endif - -// specific workarounds. each header can define BOOS_IO_STD if it -// needs. (e.g. because of IO_NEEDS_USING_DECLARATION) -#include -#include - -#ifndef BOOST_IO_STD -# define BOOST_IO_STD ::std:: -#endif - -#if defined(BOOST_NO_STD_LOCALE) || \ - ( BOOST_WORKAROUND(__BORLANDC__, <= 0x564) \ - || BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT( 0x570 ) ) ) -// some future __BORLANDC__ >0x564 versions might not need this -// 0x570 is Borland's kylix branch -#define BOOST_NO_LOCALE_ISDIGIT -#endif - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x570) ) || BOOST_WORKAROUND( BOOST_MSVC, BOOST_TESTED_AT(1300)) -#define BOOST_NO_OVERLOAD_FOR_NON_CONST -#endif - -// gcc-2.95's native stringstream is not usable -#if BOOST_WORKAROUND(__GNUC__, < 3) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -#define BOOST_FORMAT_IGNORE_STRINGSTREAM -#endif - - -// **** Workaround for io streams, stlport and msvc. -#ifdef BOOST_IO_NEEDS_USING_DECLARATION -namespace boost { - using std::char_traits; - using std::basic_ostream; - namespace io { - using std::basic_ostream; - namespace detail { - using std::basic_ios; - using std::basic_ostream; - } - } -#if ! defined(BOOST_NO_STD_LOCALE) - using std::locale; - namespace io { - using std::locale; - namespace detail { - using std::locale; - } - } -#endif // locale -} - // -end N.S. boost -#endif // needs_using_declaration - - -// *** hide std::locale if it doesnt exist. -// this typedef is either std::locale or int, avoids placing ifdefs everywhere -namespace boost { namespace io { namespace detail { -#if ! defined(BOOST_NO_STD_LOCALE) - typedef BOOST_IO_STD locale locale_t; -#else - typedef int locale_t; -#endif -} } } - - -// ---------------------------------------------------------------------------- - -#endif // BOOST_FORMAT_MACROS_DEFAULT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/msvc_disambiguater.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/msvc_disambiguater.hpp deleted file mode 100644 index f12e5e97..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/msvc_disambiguater.hpp +++ /dev/null @@ -1,56 +0,0 @@ -// ---------------------------------------------------------------------------- -// msvc_disambiguater.hpp : msvc workarounds. (for put_{head|last} overloads) -// the trick was described in boost's list by Aleksey Gurtovoy -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// see http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_MSVC_DISAMBIGUATER_HPP -#define BOOST_MSVC_DISAMBIGUATER_HPP - -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1300) || \ - BOOST_WORKAROUND(__DECCXX_VER, BOOST_TESTED_AT(60590042)) - // this whole header is specifically for msvc up to 7.0 - -#include -#include - -namespace boost { -namespace io { -namespace detail { - -template< class Ch, class Tr, class T > -struct disambiguater -{ - template< typename U > - static void put_head(BOOST_IO_STD basic_ostream& os, group1 const& x, long) - { - os << group_head(x.a1_); - } - static void put_head(BOOST_IO_STD basic_ostream& os, T const& x, int) - { - } - template< typename U > - static void put_last(BOOST_IO_STD basic_ostream& os, group1 const& x, long) - { - os << group_last(x.a1_); - } - static void put_last(BOOST_IO_STD basic_ostream& os, T const& x, int) - { - os << x; - } -}; - -} // namespace detail -} // namespace io -} // namespace boost - -#endif // -BOOST_MSVC - -#endif // -BOOST_MSVC_DISAMBIGUATER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/unset_macros.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/unset_macros.hpp deleted file mode 100644 index b3ac47b4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/unset_macros.hpp +++ /dev/null @@ -1,34 +0,0 @@ -// ---------------------------------------------------------------------------- -// unset_macros.hpp -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -// *** Undefine 'local' macros : -#ifdef BOOST_NO_OVERLOAD_FOR_NON_CONST -#undef BOOST_NO_OVERLOAD_FOR_NON_CONST -#endif -#ifdef BOOST_NO_LOCALE_ISDIGIT -#undef BOOST_NO_LOCALE_ISDIGIT -#endif -#ifdef BOOST_IO_STD -#undef BOOST_IO_STD -#endif -#ifdef BOOST_IO_NEEDS_USING_DECLARATION -#undef BOOST_IO_NEEDS_USING_DECLARATION -#endif -#ifdef BOOST_NO_TEMPLATE_STD_STREAM -#undef BOOST_NO_TEMPLATE_STD_STREAM -#endif -#ifdef BOOST_FORMAT_STREAMBUF_DEFINED -#undef BOOST_FORMAT_STREAMBUF_DEFINED -#endif -#ifdef BOOST_FORMAT_OSTREAM_DEFINED -#undef BOOST_FORMAT_OSTREAM_DEFINED -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_gcc-2_95.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_gcc-2_95.hpp deleted file mode 100644 index 8c49d42d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_gcc-2_95.hpp +++ /dev/null @@ -1,162 +0,0 @@ -// ---------------------------------------------------------------------------- -// workarounds for gcc < 3.0. -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - - -// ---------------------------------------------------------------------------- - -// There's a lot to do, the stdlib shipped with gcc prior to 3.x -// was terribly non-conforming. -// . defines macros switches -// . supplies template classes basic_foo where gcc only supplies foo. -// i.e : -// - basic_ios from ios -// - basic_ostream from ostream -// - basic_srteambuf from streambuf -// these can be used transparently. (it obviously does not work for wchar_t) -// . specialise CompatAlloc and CompatTraits to wrap gcc-2.95's -// string_char_traits and std::alloc - -#if BOOST_WORKAROUND(__GNUC__, < 3) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) - // only for gcc-2.95's native stdlib - -#ifndef BOOST_FORMAT_WORKAROUNDS_GCC295_H -#define BOOST_FORMAT_WORKAROUNDS_GCC295_H - -// SGI STL doesnt have and others, so we need iostream. -#include -#define BOOST_FORMAT_OSTREAM_DEFINED - -#include -#define BOOST_FORMAT_STREAMBUF_DEFINED - -#define BOOST_NO_TEMPLATE_STD_STREAM - -#ifndef BOOST_IO_STD -# define BOOST_IO_STD std:: -#endif - - - -// *** -// gcc's simple classes turned into standard-like template classes : - -namespace std { - - - // gcc has string_char_traits, it's incomplete. - // we declare a std::char_traits, and specialize CompatTraits<..> on it - // to do what is required - template - class char_traits; // no definition here, we will just use it as a tag. - - template - class basic_streambuf; - - template - class basic_streambuf : public streambuf { - }; - - template > - class basic_ios; - - template - class basic_ios : public ostream { - public: - basic_ios(streambuf * p) : ostream(p) {}; - char fill() const { return ios::fill(); } // gcc returns wchar.. - char fill(char c) { return ios::fill(c); } // gcc takes wchar.. - char widen(char c) { return c; } - char narrow(char c, char def) { return c; } - basic_ios& copyfmt(const ios& right) { - fill(right.fill()); - flags(right.flags() ); - exceptions(right.exceptions()); - width(right.width()); - precision(right.precision()); - return *this; - } - }; - - - typedef ios ios_base; - - template - class basic_ostream; - - template - class basic_ostream : public basic_ios - { - public: - basic_ostream(streambuf * p) : basic_ios (p) {} - }; - -} // namespace std - - -namespace boost { - namespace io { - - - // ** CompatTraits gcc2.95 specialisations ---------------------------- - template - class CompatTraits< ::std::string_char_traits > - : public ::std::string_char_traits - { - public: - typedef CompatTraits compatible_type; - - typedef Ch char_type; - typedef int int_type; - typedef ::std::streampos pos_type; - typedef ::std::streamoff off_type; - - static char_type - to_char_type(const int_type& meta) { - return static_cast(meta); } - static int_type - to_int_type(const char_type& ch) { - return static_cast(static_cast(ch) );} - static bool - eq_int_type(const int_type& left, const int_type& right) { - return left == right; } - static int_type - eof() { - return static_cast(EOF); - } - static int_type - not_eof(const int_type& meta) { - return (meta == eof()) ? 0 : meta; - } - }; - - template - class CompatTraits< ::std::char_traits > { - public: - typedef CompatTraits< ::std::string_char_traits > compatible_type; - }; - - // ** CompatAlloc gcc-2.95 specialisations --------------------------- - template<> - class CompatAlloc< ::std::alloc> - { - public: - typedef ::std::allocator compatible_type; - }; - - } // N.S. io -} // N.S. boost - - - - - -#endif // include guard - -#endif // if workaround diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_stlport.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_stlport.hpp deleted file mode 100644 index eb35dc17..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/detail/workarounds_stlport.hpp +++ /dev/null @@ -1,42 +0,0 @@ -// ---------------------------------------------------------------------------- -// workarounds_stlport.hpp : workaround STLport issues -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// see http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_MACROS_STLPORT_HPP -#define BOOST_MACROS_STLPORT_HPP - -#if defined(_STLPORT_VERSION) && BOOST_WORKAROUND( BOOST_MSVC, <= 1300) -// msvc-6-stlport fails to find basic_string::append( iterator, iterator) when linking -// might affect other MSwindows compilers -#define BOOST_NO_STRING_APPEND -#endif - -// *** This should go to "boost/config/stdlib/stlport.hpp". - -// If the streams are not native and there are problems with using templates -// accross namespaces, we define some macros to enable a workaround for this. - -// STLport 4.5 -#if !defined(_STLP_OWN_IOSTREAMS) && defined(_STLP_USE_NAMESPACES) && defined(BOOST_NO_USING_TEMPLATE) -# define BOOST_IO_STD -# define BOOST_IO_NEEDS_USING_DECLARATION -#endif - -// STLport 4.0 -#if !defined(__SGI_STL_OWN_IOSTREAMS) && defined(__STL_USE_OWN_NAMESPACE) && defined(BOOST_NO_USING_TEMPLATE) -# define BOOST_IO_STD -# define BOOST_IO_NEEDS_USING_DECLARATION -#endif - - -// ---------------------------------------------------------------------------- - -#endif // BOOST_MACROS_STLPORT_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/exceptions.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/exceptions.hpp deleted file mode 100644 index 9b2de834..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/exceptions.hpp +++ /dev/null @@ -1,103 +0,0 @@ -// ---------------------------------------------------------------------------- -// boost/format/exceptions.hpp -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// -// See http://www.boost.org/libs/format/ for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_EXCEPTIONS_HPP -#define BOOST_FORMAT_EXCEPTIONS_HPP - - -#include - - -namespace boost { - - namespace io { - -// **** exceptions ----------------------------------------------- - - class format_error : public std::exception - { - public: - format_error() {} - virtual const char *what() const throw() { - return "boost::format_error: " - "format generic failure"; - } - }; - - class bad_format_string : public format_error - { - std::size_t pos_, next_; - public: - bad_format_string(std::size_t pos, std::size_t size) - : pos_(pos), next_(size) {} - std::size_t get_pos() const { return pos_; } - std::size_t get_next() const { return next_; } - virtual const char *what() const throw() { - return "boost::bad_format_string: format-string is ill-formed"; - } - }; - - class too_few_args : public format_error - { - std::size_t cur_, expected_; - public: - too_few_args(std::size_t cur, std::size_t expected) - : cur_(cur), expected_(expected) {} - std::size_t get_cur() const { return cur_; } - std::size_t get_expected() const { return expected_; } - virtual const char *what() const throw() { - return "boost::too_few_args: " - "format-string referred to more arguments than were passed"; - } - }; - - class too_many_args : public format_error - { - std::size_t cur_, expected_; - public: - too_many_args(std::size_t cur, std::size_t expected) - : cur_(cur), expected_(expected) {} - std::size_t get_cur() const { return cur_; } - std::size_t get_expected() const { return expected_; } - virtual const char *what() const throw() { - return "boost::too_many_args: " - "format-string referred to less arguments than were passed"; - } - }; - - - class out_of_range : public format_error - { - int index_, beg_, end_; // range is [ beg, end [ - public: - out_of_range(int index, int beg, int end) - : index_(index), beg_(beg), end_(end) {} - int get_index() const { return index_; } - int get_beg() const { return beg_; } - int get_end() const { return end_; } - virtual const char *what() const throw() { - return "boost::out_of_range: " - "tried to refer to an argument (or item) number which" - " is out of range, according to the format string"; - } - }; - - - } // namespace io - -} // namespace boost - - -#endif // BOOST_FORMAT_EXCEPTIONS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/feed_args.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/feed_args.hpp deleted file mode 100644 index 53243dcc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/feed_args.hpp +++ /dev/null @@ -1,277 +0,0 @@ -// ---------------------------------------------------------------------------- -// feed_args.hpp : functions for processing each argument -// (feed, feed_manip, and distribute) -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_FEED_ARGS_HPP -#define BOOST_FORMAT_FEED_ARGS_HPP - -#include -#include -#include - -#include -#include -#include - -namespace boost { -namespace io { -namespace detail { - - template - void mk_str( std::basic_string & res, - const Ch * beg, - typename std::basic_string::size_type size, - std::streamsize w, - const Ch fill_char, - std::ios_base::fmtflags f, - const Ch prefix_space, // 0 if no space-padding - bool center) - // applies centered/left/right padding to the string [beg, beg+size[ - // Effects : the result is placed in res. - { - typedef typename std::basic_string::size_type size_type; - res.resize(0); - if(w<=0 || static_cast(w) <=size) { - // no need to pad. - res.reserve(size + !!prefix_space); - if(prefix_space) - res.append(1, prefix_space); - if (size) - res.append(beg, size); - } - else { - std::streamsize n=static_cast(w-size-!!prefix_space); - std::streamsize n_after = 0, n_before = 0; - res.reserve(static_cast(w)); // allocate once for the 2 inserts - if(center) - n_after = n/2, n_before = n - n_after; - else - if(f & std::ios_base::left) - n_after = n; - else - n_before = n; - // now make the res string : - if(n_before) res.append(static_cast(n_before), fill_char); - if(prefix_space) - res.append(1, prefix_space); - if (size) - res.append(beg, size); - if(n_after) res.append(static_cast(n_after), fill_char); - } - } // -mk_str(..) - - -#if BOOST_WORKAROUND( BOOST_MSVC, <= 1300) || \ - BOOST_WORKAROUND(__DECCXX_VER, BOOST_TESTED_AT(60590042)) -// MSVC needs to be tricked to disambiguate this simple overload.. -// the trick is in "boost/format/msvc_disambiguater.hpp" - - template< class Ch, class Tr, class T> inline - void put_head (BOOST_IO_STD basic_ostream & os, const T& x ) { - disambiguater::put_head(os, x, 1L); - } - template< class Ch, class Tr, class T> inline - void put_last (BOOST_IO_STD basic_ostream & os, const T& x ) { - disambiguater::put_last(os, x, 1L); - } - -#else - - template< class Ch, class Tr, class T> inline - void put_head (BOOST_IO_STD basic_ostream &, const T& ) { - } - - template< class Ch, class Tr, class T> inline - void put_head( BOOST_IO_STD basic_ostream & os, const group1& x ) { - os << group_head(x.a1_); // send the first N-1 items, not the last - } - - template< class Ch, class Tr, class T> inline - void put_last( BOOST_IO_STD basic_ostream & os, const T& x ) { - os << x ; - } - - template< class Ch, class Tr, class T> inline - void put_last( BOOST_IO_STD basic_ostream & os, const group1& x ) { - os << group_last(x.a1_); // this selects the last element - } - -#ifndef BOOST_NO_OVERLOAD_FOR_NON_CONST - template< class Ch, class Tr, class T> inline - void put_head( BOOST_IO_STD basic_ostream &, T& ) { - } - - template< class Ch, class Tr, class T> inline - void put_last( BOOST_IO_STD basic_ostream & os, T& x) { - os << x ; - } -#endif -#endif // -msvc workaround - - - template< class Ch, class Tr, class Alloc, class T> - void put( T x, - const format_item& specs, - typename basic_format::string_type& res, - typename basic_format::internal_streambuf_t & buf, - io::detail::locale_t *loc_p = NULL) - { -#ifdef BOOST_MSVC - // If std::min or std::max are already instantiated - // at this point then we get a blizzard of warning messages when we call - // those templates with std::size_t as arguments. Weird and very annoyning... -#pragma warning(push) -#pragma warning(disable:4267) -#endif - // does the actual conversion of x, with given params, into a string - // using the supplied stringbuf. - - typedef typename basic_format::string_type string_type; - typedef typename basic_format::format_item_t format_item_t; - typedef typename string_type::size_type size_type; - - basic_oaltstringstream oss( &buf); - specs.fmtstate_.apply_on(oss, loc_p); - - // the stream format state can be modified by manipulators in the argument : - put_head( oss, x ); - // in case x is a group, apply the manip part of it, - // in order to find width - - const std::ios_base::fmtflags fl=oss.flags(); - const bool internal = (fl & std::ios_base::internal) != 0; - const std::streamsize w = oss.width(); - const bool two_stepped_padding= internal && (w!=0); - - res.resize(0); - if(! two_stepped_padding) { - if(w>0) // handle padding via mk_str, not natively in stream - oss.width(0); - put_last( oss, x); - const Ch * res_beg = buf.pbase(); - Ch prefix_space = 0; - if(specs.pad_scheme_ & format_item_t::spacepad) - if(buf.pcount()== 0 || - (res_beg[0] !=oss.widen('+') && res_beg[0] !=oss.widen('-') )) - prefix_space = oss.widen(' '); - size_type res_size = (std::min)( - static_cast(specs.truncate_ - !!prefix_space), - buf.pcount() ); - mk_str(res, res_beg, res_size, w, oss.fill(), fl, - prefix_space, (specs.pad_scheme_ & format_item_t::centered) !=0 ); - } - else { // 2-stepped padding - // internal can be implied by zeropad, or user-set. - // left, right, and centered alignment overrule internal, - // but spacepad or truncate might be mixed with internal (using manipulator) - put_last( oss, x); // may pad - const Ch * res_beg = buf.pbase(); - size_type res_size = buf.pcount(); - bool prefix_space=false; - if(specs.pad_scheme_ & format_item_t::spacepad) - if(buf.pcount()== 0 || - (res_beg[0] !=oss.widen('+') && res_beg[0] !=oss.widen('-') )) - prefix_space = true; - if(res_size == static_cast(w) && w<=specs.truncate_ && !prefix_space) { - // okay, only one thing was printed and padded, so res is fine - res.assign(res_beg, res_size); - } - else { // length w exceeded - // either it was multi-output with first output padding up all width.. - // either it was one big arg and we are fine. - // Note that res_size oss2( &buf); - specs.fmtstate_.apply_on(oss2, loc_p); - put_head( oss2, x ); - - oss2.width(0); - if(prefix_space) - oss2 << ' '; - put_last(oss2, x ); - if(buf.pcount()==0 && specs.pad_scheme_ & format_item_t::spacepad) { - prefix_space =true; - oss2 << ' '; - } - // we now have the minimal-length output - const Ch * tmp_beg = buf.pbase(); - size_type tmp_size = (std::min)(static_cast(specs.truncate_), - buf.pcount() ); - - - if(static_cast(w) <= tmp_size) { - // minimal length is already >= w, so no padding (cool!) - res.assign(tmp_beg, tmp_size); - } - else { // hum.. we need to pad (multi_output, or spacepad present) - //find where we should pad - size_type sz = (std::min)(res_size + (prefix_space ? 1 : 0), tmp_size); - size_type i = prefix_space; - for(; i=tmp_size) i=prefix_space; - res.assign(tmp_beg, i); - std::streamsize d = w - static_cast(tmp_size); - BOOST_ASSERT(d>0); - res.append(static_cast( d ), oss2.fill()); - res.append(tmp_beg+i, tmp_size-i); - BOOST_ASSERT(i+(tmp_size-i)+(std::max)(d,(std::streamsize)0) - == static_cast(w)); - BOOST_ASSERT(res.size() == static_cast(w)); - } - } - } - buf.clear_buffer(); -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - } // end- put(..) - - - template< class Ch, class Tr, class Alloc, class T> - void distribute (basic_format& self, T x) { - // call put(x, ..) on every occurence of the current argument : - if(self.cur_arg_ >= self.num_args_) { - if( self.exceptions() & too_many_args_bit ) - boost::throw_exception(too_many_args(self.cur_arg_, self.num_args_)); - else return; - } - for(unsigned long i=0; i < self.items_.size(); ++i) { - if(self.items_[i].argN_ == self.cur_arg_) { - put (x, self.items_[i], self.items_[i].res_, - self.buf_, boost::get_pointer(self.loc_) ); - } - } - } - - template - basic_format& - feed (basic_format& self, T x) { - if(self.dumped_) self.clear(); - distribute (self, x); - ++self.cur_arg_; - if(self.bound_.size() != 0) { - while( self.cur_arg_ < self.num_args_ && self.bound_[self.cur_arg_] ) - ++self.cur_arg_; - } - return self; - } - -} // namespace detail -} // namespace io -} // namespace boost - - -#endif // BOOST_FORMAT_FEED_ARGS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/format_class.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/format_class.hpp deleted file mode 100644 index 4555e56e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/format_class.hpp +++ /dev/null @@ -1,168 +0,0 @@ -// ---------------------------------------------------------------------------- -// format_class.hpp : class interface -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_CLASS_HPP -#define BOOST_FORMAT_CLASS_HPP - - -#include -#include - -#include // to store locale when needed - -#include -#include -#include -#include - -namespace boost { - - template - class basic_format - { - typedef typename io::CompatTraits::compatible_type compat_traits; - public: - typedef Ch CharT; // borland fails in operator% if we use Ch and Tr directly - typedef std::basic_string string_type; - typedef typename string_type::size_type size_type; - typedef io::detail::format_item format_item_t; - typedef io::basic_altstringbuf internal_streambuf_t; - - - explicit basic_format(const Ch* str=NULL); - explicit basic_format(const string_type& s); - basic_format(const basic_format& x); - basic_format& operator= (const basic_format& x); - void swap(basic_format& x); - -#if !defined(BOOST_NO_STD_LOCALE) - explicit basic_format(const Ch* str, const std::locale & loc); - explicit basic_format(const string_type& s, const std::locale & loc); -#endif - io::detail::locale_t getloc() const; - - basic_format& clear(); // empty all converted string buffers (except bound items) - basic_format& clear_binds(); // unbind all bound items, and call clear() - basic_format& parse(const string_type&); // resets buffers and parse a new format string - - // ** formatted result ** // - size_type size() const; // sum of the current string pieces sizes - string_type str() const; // final string - - // ** arguments passing ** // - template - basic_format& operator%(const T& x) - { return io::detail::feed(*this,x); } - -#ifndef BOOST_NO_OVERLOAD_FOR_NON_CONST - template basic_format& operator%(T& x) - { return io::detail::feed(*this,x); } -#endif - -#if defined(__GNUC__) - // GCC can't handle anonymous enums without some help - // ** arguments passing ** // - basic_format& operator%(const int& x) - { return io::detail::feed(*this,x); } - -#ifndef BOOST_NO_OVERLOAD_FOR_NON_CONST - basic_format& operator%(int& x) - { return io::detail::feed(*this,x); } -#endif -#endif - - // The total number of arguments expected to be passed to the format objectt - int expected_args() const - { return num_args_; } - // The number of arguments currently bound (see bind_arg(..) ) - int bound_args() const; - // The number of arguments currently fed to the format object - int fed_args() const; - // The index (1-based) of the current argument (i.e. next to be formatted) - int cur_arg() const; - // The number of arguments still required to be fed - int remaining_args() const; // same as expected_args() - bound_args() - fed_args() - - - // ** object modifying **// - template - basic_format& bind_arg(int argN, const T& val) - { return io::detail::bind_arg_body(*this, argN, val); } - basic_format& clear_bind(int argN); - template - basic_format& modify_item(int itemN, T manipulator) - { return io::detail::modify_item_body (*this, itemN, manipulator);} - - // Choosing which errors will throw exceptions : - unsigned char exceptions() const; - unsigned char exceptions(unsigned char newexcept); - -#if !defined( BOOST_NO_MEMBER_TEMPLATE_FRIENDS ) \ - && !BOOST_WORKAROUND(__BORLANDC__, <= 0x570) \ - && !BOOST_WORKAROUND( _CRAYC, != 0) \ - && !BOOST_WORKAROUND(__DECCXX_VER, BOOST_TESTED_AT(60590042)) - // use friend templates and private members only if supported - -#ifndef BOOST_NO_TEMPLATE_STD_STREAM - template - friend std::basic_ostream & - operator<<( std::basic_ostream & , - const basic_format& ); -#else - template - friend std::ostream & - operator<<( std::ostream & , - const basic_format& ); -#endif - - template - friend basic_format& - io::detail::feed (basic_format&, T); - - template friend - void io::detail::distribute (basic_format&, T); - - template friend - basic_format& - io::detail::modify_item_body (basic_format&, int, T); - - template friend - basic_format& - io::detail::bind_arg_body (basic_format&, int, const T&); - - private: -#endif - typedef io::detail::stream_format_state stream_format_state; - // flag bits, used for style_ - enum style_values { ordered = 1, // set only if all directives are positional - special_needs = 4 }; - - void make_or_reuse_data(std::size_t nbitems);// used for (re-)initialisation - - // member data --------------------------------------------// - std::vector items_; // each '%..' directive leads to a format_item - std::vector bound_; // stores which arguments were bound. size() == 0 || num_args - - int style_; // style of format-string : positional or not, etc - int cur_arg_; // keep track of wich argument is current - int num_args_; // number of expected arguments - mutable bool dumped_; // true only after call to str() or << - string_type prefix_; // piece of string to insert before first item - unsigned char exceptions_; - internal_streambuf_t buf_; // the internal stream buffer. - boost::optional loc_; - }; // class basic_format - -} // namespace boost - - -#endif // BOOST_FORMAT_CLASS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/format_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/format_fwd.hpp deleted file mode 100644 index be3228af..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/format_fwd.hpp +++ /dev/null @@ -1,49 +0,0 @@ -// ---------------------------------------------------------------------------- -// format_fwd.hpp : forward declarations -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_FWD_HPP -#define BOOST_FORMAT_FWD_HPP - -#include -#include - -#include - -namespace boost { - - template , class Alloc = std::allocator > -#else - class Tr = std::string_char_traits, class Alloc = std::alloc > -#endif - class basic_format; - - typedef basic_format format; - -#if !defined(BOOST_NO_STD_WSTRING) && !defined(BOOST_NO_STD_WSTREAMBUF) \ - && !defined(BOOST_FORMAT_IGNORE_STRINGSTREAM) - typedef basic_format wformat; -#endif - - namespace io { - enum format_error_bits { bad_format_string_bit = 1, - too_few_args_bit = 2, too_many_args_bit = 4, - out_of_range_bit = 8, - all_error_bits = 255, no_error_bits=0 }; - - } // namespace io - -} // namespace boost - -#endif // BOOST_FORMAT_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/format_implementation.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/format_implementation.hpp deleted file mode 100644 index 2abb5c4b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/format_implementation.hpp +++ /dev/null @@ -1,329 +0,0 @@ -// ---------------------------------------------------------------------------- -// format_implementation.hpp Implementation of the basic_format class -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_IMPLEMENTATION_HPP -#define BOOST_FORMAT_IMPLEMENTATION_HPP - -#include -#include -#include -#include -#include // std::swap - -namespace boost { - -// --- basic_format implementation -----------------------------------------// - - template< class Ch, class Tr, class Alloc> - basic_format:: basic_format(const Ch* s) - : style_(0), cur_arg_(0), num_args_(0), dumped_(false), - exceptions_(io::all_error_bits) - { - if( s) - parse( s ); - } - -#if !defined(BOOST_NO_STD_LOCALE) - template< class Ch, class Tr, class Alloc> - basic_format:: basic_format(const Ch* s, const std::locale & loc) - : style_(0), cur_arg_(0), num_args_(0), dumped_(false), - exceptions_(io::all_error_bits), loc_(loc) - { - if(s) parse( s ); - } - - template< class Ch, class Tr, class Alloc> - basic_format:: basic_format(const string_type& s, const std::locale & loc) - : style_(0), cur_arg_(0), num_args_(0), dumped_(false), - exceptions_(io::all_error_bits), loc_(loc) - { - parse(s); - } -#endif // ! BOOST_NO_STD_LOCALE - template< class Ch, class Tr, class Alloc> - io::detail::locale_t basic_format:: - getloc() const { - return loc_ ? loc_.get() : io::detail::locale_t(); - } - - template< class Ch, class Tr, class Alloc> - basic_format:: basic_format(const string_type& s) - : style_(0), cur_arg_(0), num_args_(0), dumped_(false), - exceptions_(io::all_error_bits) - { - parse(s); - } - - template< class Ch, class Tr, class Alloc> // just don't copy the buf_ member - basic_format:: basic_format(const basic_format& x) - : items_(x.items_), bound_(x.bound_), style_(x.style_), - cur_arg_(x.cur_arg_), num_args_(x.num_args_), dumped_(x.dumped_), - prefix_(x.prefix_), exceptions_(x.exceptions_), loc_(x.loc_) - { - } - - template< class Ch, class Tr, class Alloc> // just don't copy the buf_ member - basic_format& basic_format:: - operator= (const basic_format& x) { - if(this == &x) - return *this; - (basic_format(x)).swap(*this); - return *this; - } - template< class Ch, class Tr, class Alloc> - void basic_format:: - swap (basic_format & x) { - std::swap(exceptions_, x.exceptions_); - std::swap(style_, x.style_); - std::swap(cur_arg_, x.cur_arg_); - std::swap(num_args_, x.num_args_); - std::swap(dumped_, x.dumped_); - - items_.swap(x.items_); - prefix_.swap(x.prefix_); - bound_.swap(x.bound_); - } - - template< class Ch, class Tr, class Alloc> - unsigned char basic_format:: exceptions() const { - return exceptions_; - } - - template< class Ch, class Tr, class Alloc> - unsigned char basic_format:: exceptions(unsigned char newexcept) { - unsigned char swp = exceptions_; - exceptions_ = newexcept; - return swp; - } - - template - void basic_format:: - make_or_reuse_data (std::size_t nbitems) { -#if !defined(BOOST_NO_STD_LOCALE) - Ch fill = ( BOOST_USE_FACET(std::ctype, getloc()) ). widen(' '); -#else - Ch fill = ' '; -#endif - if(items_.size() == 0) - items_.assign( nbitems, format_item_t(fill) ); - else { - if(nbitems>items_.size()) - items_.resize(nbitems, format_item_t(fill)); - bound_.resize(0); - for(std::size_t i=0; i < nbitems; ++i) - items_[i].reset(fill); // strings are resized, instead of reallocated - } - prefix_.resize(0); - } - - template< class Ch, class Tr, class Alloc> - basic_format& basic_format:: - clear () { - // empty the string buffers (except bound arguments) - // and make the format object ready for formatting a new set of arguments - - BOOST_ASSERT( bound_.size()==0 || num_args_ == static_cast(bound_.size()) ); - - for(unsigned long i=0; i - basic_format& basic_format:: - clear_binds () { - // remove all binds, then clear() - bound_.resize(0); - clear(); - return *this; - } - - template< class Ch, class Tr, class Alloc> - basic_format& basic_format:: - clear_bind (int argN) { - // remove the bind of ONE argument then clear() - if(argN<1 || argN > num_args_ || bound_.size()==0 || !bound_[argN-1] ) { - if( exceptions() & io::out_of_range_bit) - boost::throw_exception(io::out_of_range(argN, 1, num_args_+1 ) ); - else return *this; - } - bound_[argN-1]=false; - clear(); - return *this; - } - - template< class Ch, class Tr, class Alloc> - int basic_format:: - bound_args() const { - if(bound_.size()==0) - return 0; - int n=0; - for(int i=0; i - int basic_format:: - fed_args() const { - if(bound_.size()==0) - return cur_arg_; - int n=0; - for(int i=0; i - int basic_format:: - cur_arg() const { - return cur_arg_+1; } - - template< class Ch, class Tr, class Alloc> - int basic_format:: - remaining_args() const { - if(bound_.size()==0) - return num_args_-cur_arg_; - int n=0; - for(int i=cur_arg_; i - typename basic_format::string_type - basic_format:: - str () const { - if(items_.size()==0) - return prefix_; - if( cur_arg_ < num_args_) - if( exceptions() & io::too_few_args_bit ) - // not enough variables supplied - boost::throw_exception(io::too_few_args(cur_arg_, num_args_)); - - unsigned long i; - string_type res; - res.reserve(size()); - res += prefix_; - for(i=0; i < items_.size(); ++i) { - const format_item_t& item = items_[i]; - res += item.res_; - if( item.argN_ == format_item_t::argN_tabulation) { - BOOST_ASSERT( item.pad_scheme_ & format_item_t::tabulation); - if( static_cast(item.fmtstate_.width_) > res.size() ) - res.append( static_cast(item.fmtstate_.width_) - res.size(), - item.fmtstate_.fill_ ); - } - res += item.appendix_; - } - dumped_=true; - return res; - } - template< class Ch, class Tr, class Alloc> - typename std::basic_string::size_type basic_format:: - size () const { -#ifdef BOOST_MSVC - // If std::min or std::max are already instantiated - // at this point then we get a blizzard of warning messages when we call - // those templates with std::size_t as arguments. Weird and very annoyning... -#pragma warning(push) -#pragma warning(disable:4267) -#endif - BOOST_USING_STD_MAX(); - size_type sz = prefix_.size(); - unsigned long i; - for(i=0; i < items_.size(); ++i) { - const format_item_t& item = items_[i]; - sz += item.res_.size(); - if( item.argN_ == format_item_t::argN_tabulation) - sz = max BOOST_PREVENT_MACRO_SUBSTITUTION (sz, - static_cast(item.fmtstate_.width_) ); - sz += item.appendix_.size(); - } - return sz; -#ifdef BOOST_MSVC -#pragma warning(pop) -#endif - } - -namespace io { -namespace detail { - - template - basic_format& - bind_arg_body (basic_format& self, int argN, const T& val) { - // bind one argument to a fixed value - // this is persistent over clear() calls, thus also over str() and << - if(self.dumped_) - self.clear(); // needed because we will modify cur_arg_ - if(argN<1 || argN > self.num_args_) { - if( self.exceptions() & io::out_of_range_bit ) - boost::throw_exception(io::out_of_range(argN, 1, self.num_args_+1 ) ); - else return self; - } - if(self.bound_.size()==0) - self.bound_.assign(self.num_args_,false); - else - BOOST_ASSERT( self.num_args_ == static_cast(self.bound_.size()) ); - int o_cur_arg = self.cur_arg_; - self.cur_arg_ = argN-1; // arrays begin at 0 - - self.bound_[self.cur_arg_]=false; // if already set, we unset and re-sets.. - self.operator%(val); // put val at the right place, because cur_arg is set - - - // Now re-position cur_arg before leaving : - self.cur_arg_ = o_cur_arg; - self.bound_[argN-1]=true; - if(self.cur_arg_ == argN-1 ) { - // hum, now this arg is bound, so move to next free arg - while(self.cur_arg_ < self.num_args_ && self.bound_[self.cur_arg_]) - ++self.cur_arg_; - } - // In any case, we either have all args, or are on an unbound arg : - BOOST_ASSERT( self.cur_arg_ >= self.num_args_ || ! self.bound_[self.cur_arg_]); - return self; - } - - template basic_format& - modify_item_body (basic_format& self, int itemN, T manipulator) { - // applies a manipulator to the format_item describing a given directive. - // this is a permanent change, clear or reset won't cancel that. - if(itemN<1 || itemN > static_cast(self.items_.size() )) { - if( self.exceptions() & io::out_of_range_bit ) - boost::throw_exception(io::out_of_range(itemN, 1, static_cast(self.items_.size()) )); - else return self; - } - self.items_[itemN-1].fmtstate_. template apply_manip ( manipulator ); - return self; - } - -} // namespace detail -} // namespace io -} // namespace boost - - - -#endif // BOOST_FORMAT_IMPLEMENTATION_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/free_funcs.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/free_funcs.hpp deleted file mode 100644 index 3a515455..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/free_funcs.hpp +++ /dev/null @@ -1,70 +0,0 @@ -// ---------------------------------------------------------------------------- -// free_funcs.hpp : implementation of the free functions of boost::format -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_FUNCS_HPP -#define BOOST_FORMAT_FUNCS_HPP - -#include -#include - -namespace boost { - - template inline - std::basic_string str(const basic_format& f) { - // adds up all pieces of strings and converted items, and return the formatted string - return f.str(); - } - namespace io { - using ::boost::str; // keep compatibility with when it was defined in this N.S. - } // - namespace io - -#ifndef BOOST_NO_TEMPLATE_STD_STREAM - template - std::basic_ostream & - operator<<( std::basic_ostream & os, - const basic_format& f) -#else - template - std::ostream & - operator<<( std::ostream & os, - const basic_format& f) -#endif - // effect: "return os << str(f);" but we can do it faster - { - typedef boost::basic_format format_t; - if(f.items_.size()==0) - os << f.prefix_; - else { - if(f.cur_arg_ < f.num_args_) - if( f.exceptions() & io::too_few_args_bit ) - // not enough variables supplied - boost::throw_exception(io::too_few_args(f.cur_arg_, f.num_args_)); - if(f.style_ & format_t::special_needs) - os << f.str(); - else { - // else we dont have to count chars output, so we dump directly to os : - os << f.prefix_; - for(unsigned long i=0; i - - -namespace boost { -namespace io { - - -namespace detail { - - -// empty group, but useful even though. -struct group0 -{ - group0() {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << ( BOOST_IO_STD basic_ostream& os, - const group0& ) -{ - return os; -} - -template -struct group1 -{ - T1 a1_; - group1(T1 a1) - : a1_(a1) - {} -private: - group1& operator=(const group1&); -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group1& x) -{ - os << x.a1_; - return os; -} - - - - -template -struct group2 -{ - T1 a1_; - T2 a2_; - group2(T1 a1,T2 a2) - : a1_(a1),a2_(a2) - {} -private: - group2& operator=(const group2&); -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group2& x) -{ - os << x.a1_<< x.a2_; - return os; -} - -template -struct group3 -{ - T1 a1_; - T2 a2_; - T3 a3_; - group3(T1 a1,T2 a2,T3 a3) - : a1_(a1),a2_(a2),a3_(a3) - {} -private: - group3& operator=(const group3&); -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group3& x) -{ - os << x.a1_<< x.a2_<< x.a3_; - return os; -} - -template -struct group4 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - group4(T1 a1,T2 a2,T3 a3,T4 a4) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4) - {} -private: - group4& operator=(const group4&); -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group4& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_; - return os; -} - -template -struct group5 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - group5(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group5& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_; - return os; -} - -template -struct group6 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - T6 a6_; - group6(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5),a6_(a6) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group6& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_<< x.a6_; - return os; -} - -template -struct group7 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - T6 a6_; - T7 a7_; - group7(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5),a6_(a6),a7_(a7) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group7& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_<< x.a6_<< x.a7_; - return os; -} - -template -struct group8 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - T6 a6_; - T7 a7_; - T8 a8_; - group8(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5),a6_(a6),a7_(a7),a8_(a8) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group8& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_<< x.a6_<< x.a7_<< x.a8_; - return os; -} - -template -struct group9 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - T6 a6_; - T7 a7_; - T8 a8_; - T9 a9_; - group9(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8,T9 a9) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5),a6_(a6),a7_(a7),a8_(a8),a9_(a9) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group9& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_<< x.a6_<< x.a7_<< x.a8_<< x.a9_; - return os; -} - -template -struct group10 -{ - T1 a1_; - T2 a2_; - T3 a3_; - T4 a4_; - T5 a5_; - T6 a6_; - T7 a7_; - T8 a8_; - T9 a9_; - T10 a10_; - group10(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8,T9 a9,T10 a10) - : a1_(a1),a2_(a2),a3_(a3),a4_(a4),a5_(a5),a6_(a6),a7_(a7),a8_(a8),a9_(a9),a10_(a10) - {} -}; - -template -inline -BOOST_IO_STD basic_ostream& -operator << (BOOST_IO_STD basic_ostream& os, - const group10& x) -{ - os << x.a1_<< x.a2_<< x.a3_<< x.a4_<< x.a5_<< x.a6_<< x.a7_<< x.a8_<< x.a9_<< x.a10_; - return os; -} - - - - -template -inline -group1 -group_head( group2 const& x) -{ - return group1 (x.a1_); -} - -template -inline -group1 -group_last( group2 const& x) -{ - return group1 (x.a2_); -} - - - -template -inline -group2 -group_head( group3 const& x) -{ - return group2 (x.a1_,x.a2_); -} - -template -inline -group1 -group_last( group3 const& x) -{ - return group1 (x.a3_); -} - - - -template -inline -group3 -group_head( group4 const& x) -{ - return group3 (x.a1_,x.a2_,x.a3_); -} - -template -inline -group1 -group_last( group4 const& x) -{ - return group1 (x.a4_); -} - - - -template -inline -group4 -group_head( group5 const& x) -{ - return group4 (x.a1_,x.a2_,x.a3_,x.a4_); -} - -template -inline -group1 -group_last( group5 const& x) -{ - return group1 (x.a5_); -} - - - -template -inline -group5 -group_head( group6 const& x) -{ - return group5 (x.a1_,x.a2_,x.a3_,x.a4_,x.a5_); -} - -template -inline -group1 -group_last( group6 const& x) -{ - return group1 (x.a6_); -} - - - -template -inline -group6 -group_head( group7 const& x) -{ - return group6 (x.a1_,x.a2_,x.a3_,x.a4_,x.a5_,x.a6_); -} - -template -inline -group1 -group_last( group7 const& x) -{ - return group1 (x.a7_); -} - - - -template -inline -group7 -group_head( group8 const& x) -{ - return group7 (x.a1_,x.a2_,x.a3_,x.a4_,x.a5_,x.a6_,x.a7_); -} - -template -inline -group1 -group_last( group8 const& x) -{ - return group1 (x.a8_); -} - - - -template -inline -group8 -group_head( group9 const& x) -{ - return group8 (x.a1_,x.a2_,x.a3_,x.a4_,x.a5_,x.a6_,x.a7_,x.a8_); -} - -template -inline -group1 -group_last( group9 const& x) -{ - return group1 (x.a9_); -} - - - -template -inline -group9 -group_head( group10 const& x) -{ - return group9 (x.a1_,x.a2_,x.a3_,x.a4_,x.a5_,x.a6_,x.a7_,x.a8_,x.a9_); -} - -template -inline -group1 -group_last( group10 const& x) -{ - return group1 (x.a10_); -} - - - - - -} // namespace detail - - - -// helper functions - - -inline detail::group1< detail::group0 > -group() { return detail::group1< detail::group0 > ( detail::group0() ); } - -template -inline -detail::group1< detail::group2 > - group(T1 a1, Var const& var) -{ - return detail::group1< detail::group2 > - ( detail::group2 - (a1, var) - ); -} - -template -inline -detail::group1< detail::group3 > - group(T1 a1,T2 a2, Var const& var) -{ - return detail::group1< detail::group3 > - ( detail::group3 - (a1,a2, var) - ); -} - -template -inline -detail::group1< detail::group4 > - group(T1 a1,T2 a2,T3 a3, Var const& var) -{ - return detail::group1< detail::group4 > - ( detail::group4 - (a1,a2,a3, var) - ); -} - -template -inline -detail::group1< detail::group5 > - group(T1 a1,T2 a2,T3 a3,T4 a4, Var const& var) -{ - return detail::group1< detail::group5 > - ( detail::group5 - (a1,a2,a3,a4, var) - ); -} - -template -inline -detail::group1< detail::group6 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5, Var const& var) -{ - return detail::group1< detail::group6 > - ( detail::group6 - (a1,a2,a3,a4,a5, var) - ); -} - -template -inline -detail::group1< detail::group7 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6, Var const& var) -{ - return detail::group1< detail::group7 > - ( detail::group7 - (a1,a2,a3,a4,a5,a6, var) - ); -} - -template -inline -detail::group1< detail::group8 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7, Var const& var) -{ - return detail::group1< detail::group8 > - ( detail::group8 - (a1,a2,a3,a4,a5,a6,a7, var) - ); -} - -template -inline -detail::group1< detail::group9 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8, Var const& var) -{ - return detail::group1< detail::group9 > - ( detail::group9 - (a1,a2,a3,a4,a5,a6,a7,a8, var) - ); -} - -template -inline -detail::group1< detail::group10 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8,T9 a9, Var const& var) -{ - return detail::group1< detail::group10 > - ( detail::group10 - (a1,a2,a3,a4,a5,a6,a7,a8,a9, var) - ); -} - - -#ifndef BOOST_NO_OVERLOAD_FOR_NON_CONST - -template -inline -detail::group1< detail::group2 > - group(T1 a1, Var& var) -{ - return detail::group1< detail::group2 > - ( detail::group2 - (a1, var) - ); -} - -template -inline -detail::group1< detail::group3 > - group(T1 a1,T2 a2, Var& var) -{ - return detail::group1< detail::group3 > - ( detail::group3 - (a1,a2, var) - ); -} - -template -inline -detail::group1< detail::group4 > - group(T1 a1,T2 a2,T3 a3, Var& var) -{ - return detail::group1< detail::group4 > - ( detail::group4 - (a1,a2,a3, var) - ); -} - -template -inline -detail::group1< detail::group5 > - group(T1 a1,T2 a2,T3 a3,T4 a4, Var& var) -{ - return detail::group1< detail::group5 > - ( detail::group5 - (a1,a2,a3,a4, var) - ); -} - -template -inline -detail::group1< detail::group6 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5, Var& var) -{ - return detail::group1< detail::group6 > - ( detail::group6 - (a1,a2,a3,a4,a5, var) - ); -} - -template -inline -detail::group1< detail::group7 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6, Var& var) -{ - return detail::group1< detail::group7 > - ( detail::group7 - (a1,a2,a3,a4,a5,a6, var) - ); -} - -template -inline -detail::group1< detail::group8 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7, Var& var) -{ - return detail::group1< detail::group8 > - ( detail::group8 - (a1,a2,a3,a4,a5,a6,a7, var) - ); -} - -template -inline -detail::group1< detail::group9 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8, Var& var) -{ - return detail::group1< detail::group9 > - ( detail::group9 - (a1,a2,a3,a4,a5,a6,a7,a8, var) - ); -} - -template -inline -detail::group1< detail::group10 > - group(T1 a1,T2 a2,T3 a3,T4 a4,T5 a5,T6 a6,T7 a7,T8 a8,T9 a9, Var& var) -{ - return detail::group1< detail::group10 > - ( detail::group10 - (a1,a2,a3,a4,a5,a6,a7,a8,a9, var) - ); -} - - -#endif // - BOOST_NO_OVERLOAD_FOR_NON_CONST - - -} // namespace io - -} // namespace boost - - -#endif // BOOST_FORMAT_GROUP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/internals.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/internals.hpp deleted file mode 100644 index b0d874a1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/internals.hpp +++ /dev/null @@ -1,201 +0,0 @@ -// ---------------------------------------------------------------------------- -// internals.hpp : internal structs : stream_format_state, format_item. -// included by format.hpp -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_INTERNALS_HPP -#define BOOST_FORMAT_INTERNALS_HPP - - -#include -#include -#include -#include -#include -#include // used as a dummy stream - -namespace boost { -namespace io { -namespace detail { - - -//---- stream_format_state --------------------------------------------------// - -// set of params that define the format state of a stream - template - struct stream_format_state - { - typedef BOOST_IO_STD basic_ios basic_ios; - - stream_format_state(Ch fill) { reset(fill); } -// stream_format_state(const basic_ios& os) { set_by_stream(os); } - - void reset(Ch fill); //- sets to default state. - void set_by_stream(const basic_ios& os); //- sets to os's state. - void apply_on(basic_ios & os, //- applies format_state to the stream - boost::io::detail::locale_t * loc_default = 0) const; - template - void apply_manip(T manipulator) //- modifies state by applying manipulator - { apply_manip_body( *this, manipulator) ; } - - // --- data --- - std::streamsize width_; - std::streamsize precision_; - Ch fill_; - std::ios_base::fmtflags flags_; - std::ios_base::iostate rdstate_; - std::ios_base::iostate exceptions_; - boost::optional loc_; - }; - - -//---- format_item ---------------------------------------------------------// - -// stores all parameters that can be specified in format strings - template - struct format_item - { - enum pad_values { zeropad = 1, spacepad =2, centered=4, tabulation = 8 }; - // 1. if zeropad is set, all other bits are not, - // 2. if tabulation is set, all others are not. - // centered and spacepad can be mixed freely. - enum arg_values { argN_no_posit = -1, // non-positional directive. will set argN later - argN_tabulation = -2, // tabulation directive. (no argument read) - argN_ignored = -3 // ignored directive. (no argument read) - }; - typedef BOOST_IO_STD basic_ios basic_ios; - typedef detail::stream_format_state stream_format_state; - typedef ::std::basic_string string_type; - - format_item(Ch fill) :argN_(argN_no_posit), fmtstate_(fill), - truncate_(max_streamsize()), pad_scheme_(0) {} - void reset(Ch fill); - void compute_states(); // sets states according to truncate and pad_scheme. - - static std::streamsize max_streamsize() { - return (std::numeric_limits::max)(); - } - - // --- data --- - int argN_; //- argument number (starts at 0, eg : %1 => argN=0) - // negative values for items that don't process an argument - string_type res_; //- result of the formatting of this item - string_type appendix_; //- piece of string between this item and the next - - stream_format_state fmtstate_;// set by parsing, is only affected by modify_item - - std::streamsize truncate_;//- is set for directives like %.5s that ask truncation - unsigned int pad_scheme_;//- several possible padding schemes can mix. see pad_values - }; - - - -//--- Definitions ------------------------------------------------------------ - -// - stream_format_state:: ------------------------------------------------- - template - void stream_format_state:: apply_on (basic_ios & os, - boost::io::detail::locale_t * loc_default) const { - // set the state of this stream according to our params - if(width_ != -1) - os.width(width_); - if(precision_ != -1) - os.precision(precision_); - if(fill_ != 0) - os.fill(fill_); - os.flags(flags_); - os.clear(rdstate_); - os.exceptions(exceptions_); -#if !defined(BOOST_NO_STD_LOCALE) - if(loc_) - os.imbue(loc_.get()); - else if(loc_default) - os.imbue(*loc_default); -#else - (void) loc_default; // keep compiler quiet if we don't support locales -#endif - } - - template - void stream_format_state:: set_by_stream(const basic_ios& os) { - // set our params according to the state of this stream - flags_ = os.flags(); - width_ = os.width(); - precision_ = os.precision(); - fill_ = os.fill(); - rdstate_ = os.rdstate(); - exceptions_ = os.exceptions(); - } - - - template - void apply_manip_body( stream_format_state& self, - T manipulator) { - // modify our params according to the manipulator - basic_oaltstringstream ss; - self.apply_on( ss ); - ss << manipulator; - self.set_by_stream( ss ); - } - - template inline - void stream_format_state:: reset(Ch fill) { - // set our params to standard's default state. cf 27.4.4.1 of the C++ norm - width_=0; precision_=6; - fill_=fill; // default is widen(' '), but we cant compute it without the locale - flags_ = std::ios_base::dec | std::ios_base::skipws; - // the adjust_field part is left equal to 0, which means right. - exceptions_ = std::ios_base::goodbit; - rdstate_ = std::ios_base::goodbit; - } - - -// --- format_item:: -------------------------------------------------------- - - template - void format_item:: - reset (Ch fill) { - argN_=argN_no_posit; truncate_ = max_streamsize(); pad_scheme_ =0; - res_.resize(0); appendix_.resize(0); - fmtstate_.reset(fill); - } - - template - void format_item:: - compute_states() { - // reflect pad_scheme_ on fmt_state_ - // because some pad_schemes has complex consequences on several state params. - if(pad_scheme_ & zeropad) { - // ignore zeropad in left alignment : - if(fmtstate_.flags_ & std::ios_base::left) { - BOOST_ASSERT(!(fmtstate_.flags_ &(std::ios_base::adjustfield ^std::ios_base::left))); - // only left bit might be set. (not right, nor internal) - pad_scheme_ = pad_scheme_ & (~zeropad); - } - else { - pad_scheme_ &= ~spacepad; // printf ignores spacepad when zeropadding - fmtstate_.fill_='0'; - fmtstate_.flags_ = (fmtstate_.flags_ & ~std::ios_base::adjustfield) - | std::ios_base::internal; - // removes all adjustfield bits, and adds internal. - } - } - if(pad_scheme_ & spacepad) { - if(fmtstate_.flags_ & std::ios_base::showpos) - pad_scheme_ &= ~spacepad; - } - } - - -} } } // namespaces boost :: io :: detail - - -#endif // BOOST_FORMAT_INTERNALS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/internals_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/internals_fwd.hpp deleted file mode 100644 index e44eb3c1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/internals_fwd.hpp +++ /dev/null @@ -1,60 +0,0 @@ -// ---------------------------------------------------------------------------- -// internals_fwd.hpp : forward declarations, for internal headers -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// See http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_INTERNAL_FWD_HPP -#define BOOST_FORMAT_INTERNAL_FWD_HPP - -#include -#include - - -namespace boost { -namespace io { - -namespace detail { - template struct stream_format_state; - template struct format_item; - - - // these functions were intended as methods, - // but MSVC have problems with template member functions : - // defined in format_implementation.hpp : - template - basic_format& - modify_item_body (basic_format& self, - int itemN, T manipulator); - - template - basic_format& - bind_arg_body (basic_format& self, - int argN, const T& val); - - // in internals.hpp : - template - void apply_manip_body (stream_format_state& self, - T manipulator); - - // argument feeding (defined in feed_args.hpp ) : - template - void distribute (basic_format& self, T x); - - template - basic_format& - feed (basic_format& self, T x); - -} // namespace detail - -} // namespace io -} // namespace boost - - -#endif // BOOST_FORMAT_INTERNAL_FWD_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/format/parsing.hpp b/third_party/ycmd/cpp/BoostParts/boost/format/parsing.hpp deleted file mode 100644 index b14ca82c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/format/parsing.hpp +++ /dev/null @@ -1,504 +0,0 @@ -// ---------------------------------------------------------------------------- -// parsing.hpp : implementation of the parsing member functions -// ( parse, parse_printf_directive) -// ---------------------------------------------------------------------------- - -// Copyright Samuel Krempp 2003. Use, modification, and distribution are -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// see http://www.boost.org/libs/format for library home page - -// ---------------------------------------------------------------------------- - -#ifndef BOOST_FORMAT_PARSING_HPP -#define BOOST_FORMAT_PARSING_HPP - - -#include -#include -#include -#include - - -namespace boost { -namespace io { -namespace detail { - -#if defined(BOOST_NO_STD_LOCALE) - // streams will be used for narrow / widen. but these methods are not const - template - T& const_or_not(const T& x) { - return const_cast (x); - } -#else - template - const T& const_or_not(const T& x) { - return x; - } -#endif - - template inline - char wrap_narrow(const Facet& fac, Ch c, char deflt) { - return const_or_not(fac).narrow(c, deflt); - } - - template inline - bool wrap_isdigit(const Facet& fac, Ch c) { -#if ! defined( BOOST_NO_LOCALE_ISDIGIT ) - return fac.is(std::ctype::digit, c); -# else - (void) fac; // remove "unused parameter" warning - using namespace std; - return isdigit(c); -#endif - } - - template - Iter wrap_scan_notdigit(const Facet & fac, Iter beg, Iter end) { - using namespace std; - for( ; beg!=end && wrap_isdigit(fac, *beg); ++beg) ; - return beg; - } - - - // Input : [start, last) iterators range and a - // a Facet to use its widen/narrow member function - // Effects : read sequence and convert digits into integral n, of type Res - // Returns : n - template - Iter str2int (const Iter & start, const Iter & last, Res & res, - const Facet& fac) - { - using namespace std; - Iter it; - res=0; - for(it=start; it != last && wrap_isdigit(fac, *it); ++it ) { - char cur_ch = wrap_narrow(fac, *it, 0); // cant fail. - res *= 10; - res += cur_ch - '0'; // 22.2.1.1.2.13 of the C++ standard - } - return it; - } - - // skip printf's "asterisk-fields" directives in the format-string buf - // Input : char string, with starting index *pos_p - // a Facet merely to use its widen/narrow member function - // Effects : advance *pos_p by skipping printf's asterisk fields. - // Returns : nothing - template - Iter skip_asterisk(Iter start, Iter last, const Facet& fac) - { - using namespace std; - ++ start; - start = wrap_scan_notdigit(fac, start, last); - if(start!=last && *start== const_or_not(fac).widen( '$') ) - ++start; - return start; - } - - - // auxiliary func called by parse_printf_directive - // for centralising error handling - // it either throws if user sets the corresponding flag, or does nothing. - inline void maybe_throw_exception(unsigned char exceptions, - std::size_t pos, std::size_t size) - { - if(exceptions & io::bad_format_string_bit) - boost::throw_exception(io::bad_format_string(pos, size) ); - } - - - // Input: the position of a printf-directive in the format-string - // a basic_ios& merely to use its widen/narrow member function - // a bitset'exceptions' telling whether to throw exceptions on errors. - // Returns: - // true if parse succeeded (ignore some errors if exceptions disabled) - // false if it failed so bad that the directive should be printed verbatim - // Effects: - // start is incremented so that *start is the first char after - // this directive - // *fpar is set with the parameters read in the directive - template - bool parse_printf_directive(Iter & start, const Iter& last, - detail::format_item * fpar, - const Facet& fac, - std::size_t offset, unsigned char exceptions) - { - typedef typename basic_format::format_item_t format_item_t; - - fpar->argN_ = format_item_t::argN_no_posit; // if no positional-directive - bool precision_set = false; - bool in_brackets=false; - Iter start0 = start; - std::size_t fstring_size = last-start0+offset; - - if(start>= last) { // empty directive : this is a trailing % - maybe_throw_exception(exceptions, start-start0 + offset, fstring_size); - return false; - } - - if(*start== const_or_not(fac).widen( '|')) { - in_brackets=true; - if( ++start >= last ) { - maybe_throw_exception(exceptions, start-start0 + offset, fstring_size); - return false; - } - } - - // the flag '0' would be picked as a digit for argument order, but here it's a flag : - if(*start== const_or_not(fac).widen( '0')) - goto parse_flags; - - // handle argument order (%2$d) or possibly width specification: %2d - if(wrap_isdigit(fac, *start)) { - int n; - start = str2int(start, last, n, fac); - if( start >= last ) { - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - return false; - } - - // %N% case : this is already the end of the directive - if( *start == const_or_not(fac).widen( '%') ) { - fpar->argN_ = n-1; - ++start; - if( in_brackets) - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - // but don't return. maybe "%" was used in lieu of '$', so we go on. - else - return true; - } - - if ( *start== const_or_not(fac).widen( '$') ) { - fpar->argN_ = n-1; - ++start; - } - else { - // non-positionnal directive - fpar->fmtstate_.width_ = n; - fpar->argN_ = format_item_t::argN_no_posit; - goto parse_precision; - } - } - - parse_flags: - // handle flags - while ( start != last) { // as long as char is one of + - = _ # 0 l h or ' ' - // misc switches - switch ( wrap_narrow(fac, *start, 0)) { - case '\'' : break; // no effect yet. (painful to implement) - case 'l': - case 'h': // short/long modifier : for printf-comaptibility (no action needed) - break; - case '-': - fpar->fmtstate_.flags_ |= std::ios_base::left; - break; - case '=': - fpar->pad_scheme_ |= format_item_t::centered; - break; - case '_': - fpar->fmtstate_.flags_ |= std::ios_base::internal; - break; - case ' ': - fpar->pad_scheme_ |= format_item_t::spacepad; - break; - case '+': - fpar->fmtstate_.flags_ |= std::ios_base::showpos; - break; - case '0': - fpar->pad_scheme_ |= format_item_t::zeropad; - // need to know alignment before really setting flags, - // so just add 'zeropad' flag for now, it will be processed later. - break; - case '#': - fpar->fmtstate_.flags_ |= std::ios_base::showpoint | std::ios_base::showbase; - break; - default: - goto parse_width; - } - ++start; - } // loop on flag. - - if( start>=last) { - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - return true; - } - parse_width: - // handle width spec - // first skip 'asterisk fields' : *, or *N$ - if(*start == const_or_not(fac).widen( '*') ) - start = skip_asterisk(start, last, fac); - if(start!=last && wrap_isdigit(fac, *start)) - start = str2int(start, last, fpar->fmtstate_.width_, fac); - - parse_precision: - if( start>= last) { - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - return true; - } - // handle precision spec - if (*start== const_or_not(fac).widen( '.')) { - ++start; - if(start != last && *start == const_or_not(fac).widen( '*') ) - start = skip_asterisk(start, last, fac); - if(start != last && wrap_isdigit(fac, *start)) { - start = str2int(start, last, fpar->fmtstate_.precision_, fac); - precision_set = true; - } - else - fpar->fmtstate_.precision_ =0; - } - - // handle formatting-type flags : - while( start != last && ( *start== const_or_not(fac).widen( 'l') - || *start== const_or_not(fac).widen( 'L') - || *start== const_or_not(fac).widen( 'h')) ) - ++start; - if( start>=last) { - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - return true; - } - - if( in_brackets && *start== const_or_not(fac).widen( '|') ) { - ++start; - return true; - } - switch ( wrap_narrow(fac, *start, 0) ) { - case 'X': - fpar->fmtstate_.flags_ |= std::ios_base::uppercase; - case 'p': // pointer => set hex. - case 'x': - fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; - fpar->fmtstate_.flags_ |= std::ios_base::hex; - break; - - case 'o': - fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; - fpar->fmtstate_.flags_ |= std::ios_base::oct; - break; - - case 'E': - fpar->fmtstate_.flags_ |= std::ios_base::uppercase; - case 'e': - fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield; - fpar->fmtstate_.flags_ |= std::ios_base::scientific; - - fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; - fpar->fmtstate_.flags_ |= std::ios_base::dec; - break; - - case 'f': - fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield; - fpar->fmtstate_.flags_ |= std::ios_base::fixed; - case 'u': - case 'd': - case 'i': - fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; - fpar->fmtstate_.flags_ |= std::ios_base::dec; - break; - - case 'T': - ++start; - if( start >= last) - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - else - fpar->fmtstate_.fill_ = *start; - fpar->pad_scheme_ |= format_item_t::tabulation; - fpar->argN_ = format_item_t::argN_tabulation; - break; - case 't': - fpar->fmtstate_.fill_ = const_or_not(fac).widen( ' '); - fpar->pad_scheme_ |= format_item_t::tabulation; - fpar->argN_ = format_item_t::argN_tabulation; - break; - - case 'G': - fpar->fmtstate_.flags_ |= std::ios_base::uppercase; - break; - case 'g': // 'g' conversion is default for floats. - fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; - fpar->fmtstate_.flags_ |= std::ios_base::dec; - - // CLEAR all floatield flags, so stream will CHOOSE - fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield; - break; - - case 'C': - case 'c': - fpar->truncate_ = 1; - break; - case 'S': - case 's': - if(precision_set) // handle truncation manually, with own parameter. - fpar->truncate_ = fpar->fmtstate_.precision_; - fpar->fmtstate_.precision_ = 6; // default stream precision. - break; - case 'n' : - fpar->argN_ = format_item_t::argN_ignored; - break; - default: - maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - } - ++start; - - if( in_brackets ) { - if( start != last && *start== const_or_not(fac).widen( '|') ) { - ++start; - return true; - } - else maybe_throw_exception(exceptions, start-start0+offset, fstring_size); - } - return true; - } - // -end parse_printf_directive() - - template - int upper_bound_from_fstring(const String& buf, - const typename String::value_type arg_mark, - const Facet& fac, - unsigned char exceptions) - { - // quick-parsing of the format-string to count arguments mark (arg_mark, '%') - // returns : upper bound on the number of format items in the format strings - using namespace boost::io; - typename String::size_type i1=0; - int num_items=0; - while( (i1=buf.find(arg_mark,i1)) != String::npos ) { - if( i1+1 >= buf.size() ) { - if(exceptions & bad_format_string_bit) - boost::throw_exception(bad_format_string(i1, buf.size() )); // must not end in ".. %" - else { - ++num_items; - break; - } - } - if(buf[i1+1] == buf[i1] ) {// escaped "%%" - i1+=2; continue; - } - - ++i1; - // in case of %N% directives, dont count it double (wastes allocations..) : - i1 = detail::wrap_scan_notdigit(fac, buf.begin()+i1, buf.end()) - buf.begin(); - if( i1 < buf.size() && buf[i1] == arg_mark ) - ++i1; - ++num_items; - } - return num_items; - } - template inline - void append_string(String& dst, const String& src, - const typename String::size_type beg, - const typename String::size_type end) { -#if !defined(BOOST_NO_STRING_APPEND) - dst.append(src.begin()+beg, src.begin()+end); -#else - dst += src.substr(beg, end-beg); -#endif - } - -} // detail namespace -} // io namespace - - - -// ----------------------------------------------- -// format :: parse(..) - - template - basic_format& basic_format:: - parse (const string_type& buf) { - // parse the format-string - using namespace std; -#if !defined(BOOST_NO_STD_LOCALE) - const std::ctype & fac = BOOST_USE_FACET( std::ctype, getloc()); -#else - io::basic_oaltstringstream fac; - //has widen and narrow even on compilers without locale -#endif - - const Ch arg_mark = io::detail::const_or_not(fac).widen( '%'); - bool ordered_args=true; - int max_argN=-1; - - // A: find upper_bound on num_items and allocates arrays - int num_items = io::detail::upper_bound_from_fstring(buf, arg_mark, fac, exceptions()); - make_or_reuse_data(num_items); - - // B: Now the real parsing of the format string : - num_items=0; - typename string_type::size_type i0=0, i1=0; - typename string_type::const_iterator it; - bool special_things=false; - int cur_item=0; - while( (i1=buf.find(arg_mark,i1)) != string_type::npos ) { - string_type & piece = (cur_item==0) ? prefix_ : items_[cur_item-1].appendix_; - if( buf[i1+1] == buf[i1] ) { // escaped mark, '%%' - io::detail::append_string(piece, buf, i0, i1+1); - i1+=2; i0=i1; - continue; - } - BOOST_ASSERT( static_cast(cur_item) < items_.size() || cur_item==0); - - if(i1!=i0) { - io::detail::append_string(piece, buf, i0, i1); - i0=i1; - } - ++i1; - it = buf.begin()+i1; - bool parse_ok = io::detail::parse_printf_directive( - it, buf.end(), &items_[cur_item], fac, i1, exceptions()); - i1 = it - buf.begin(); - if( ! parse_ok ) // the directive will be printed verbatim - continue; - i0=i1; - items_[cur_item].compute_states(); // process complex options, like zeropad, into params - - int argN=items_[cur_item].argN_; - if(argN == format_item_t::argN_ignored) - continue; - if(argN ==format_item_t::argN_no_posit) - ordered_args=false; - else if(argN == format_item_t::argN_tabulation) special_things=true; - else if(argN > max_argN) max_argN = argN; - ++num_items; - ++cur_item; - } // loop on %'s - BOOST_ASSERT(cur_item == num_items); - - // store the final piece of string - { - string_type & piece = (cur_item==0) ? prefix_ : items_[cur_item-1].appendix_; - io::detail::append_string(piece, buf, i0, buf.size()); - } - - if( !ordered_args) { - if(max_argN >= 0 ) { // dont mix positional with non-positionnal directives - if(exceptions() & io::bad_format_string_bit) - boost::throw_exception(io::bad_format_string(max_argN, 0)); - // else do nothing. => positionnal arguments are processed as non-positionnal - } - // set things like it would have been with positional directives : - int non_ordered_items = 0; - for(int i=0; i< num_items; ++i) - if(items_[i].argN_ == format_item_t::argN_no_posit) { - items_[i].argN_ = non_ordered_items; - ++non_ordered_items; - } - max_argN = non_ordered_items-1; - } - - // C: set some member data : - items_.resize(num_items, format_item_t(io::detail::const_or_not(fac).widen( ' ')) ); - - if(special_things) style_ |= special_needs; - num_args_ = max_argN + 1; - if(ordered_args) style_ |= ordered; - else style_ &= ~ordered; - return *this; - } - -} // namespace boost - - -#endif // BOOST_FORMAT_PARSING_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/function.hpp b/third_party/ycmd/cpp/BoostParts/boost/function.hpp deleted file mode 100644 index b72842bb..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function.hpp +++ /dev/null @@ -1,66 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2001-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org/libs/function - -// William Kempf, Jesse Jones and Karl Nelson were all very helpful in the -// design of this library. - -#include // unary_function, binary_function - -#include -#include - -#ifndef BOOST_FUNCTION_MAX_ARGS -# define BOOST_FUNCTION_MAX_ARGS 10 -#endif // BOOST_FUNCTION_MAX_ARGS - -// Include the prologue here so that the use of file-level iteration -// in anything that may be included by function_template.hpp doesn't break -#include - -// Older Visual Age C++ version do not handle the file iteration well -#if BOOST_WORKAROUND(__IBMCPP__, >= 500) && BOOST_WORKAROUND(__IBMCPP__, < 800) -# if BOOST_FUNCTION_MAX_ARGS >= 0 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 1 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 2 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 3 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 4 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 5 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 6 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 7 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 8 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 9 -# include -# endif -# if BOOST_FUNCTION_MAX_ARGS >= 10 -# include -# endif -#else -// What is the '3' for? -# define BOOST_PP_ITERATION_PARAMS_1 (3,(0,BOOST_FUNCTION_MAX_ARGS,)) -# include BOOST_PP_ITERATE() -# undef BOOST_PP_ITERATION_PARAMS_1 -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/detail/function_iterate.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/detail/function_iterate.hpp deleted file mode 100644 index 5370b36a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/detail/function_iterate.hpp +++ /dev/null @@ -1,16 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org -#if !defined(BOOST_PP_IS_ITERATING) -# error Boost.Function - do not include this file! -#endif - -#define BOOST_FUNCTION_NUM_ARGS BOOST_PP_ITERATION() -#include -#undef BOOST_FUNCTION_NUM_ARGS - diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/detail/gen_maybe_include.pl b/third_party/ycmd/cpp/BoostParts/boost/function/detail/gen_maybe_include.pl deleted file mode 100644 index d0629205..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/detail/gen_maybe_include.pl +++ /dev/null @@ -1,37 +0,0 @@ -#!/usr/bin/perl -w -# -# Boost.Function library -# -# Copyright (C) 2001-2003 Douglas Gregor (gregod@cs.rpi.edu) -# -# Permission to copy, use, sell and distribute this software is granted -# provided this copyright notice appears in all copies. -# Permission to modify the code and to distribute modified code is granted -# provided this copyright notice appears in all copies, and a notice -# that the code was modified is included with the copyright notice. -# -# This software is provided "as is" without express or implied warranty, -# and with no claim as to its suitability for any purpose. -# -# For more information, see http://www.boost.org -use English; - -$max_args = $ARGV[0]; - -open (OUT, ">maybe_include.hpp") or die("Cannot write to maybe_include.hpp"); -for($on_arg = 0; $on_arg <= $max_args; ++$on_arg) { - if ($on_arg == 0) { - print OUT "#if"; - } - else { - print OUT "#elif"; - } - print OUT " BOOST_FUNCTION_NUM_ARGS == $on_arg\n"; - print OUT "# ifndef BOOST_FUNCTION_$on_arg\n"; - print OUT "# define BOOST_FUNCTION_$on_arg\n"; - print OUT "# include \n"; - print OUT "# endif\n"; -} -print OUT "#else\n"; -print OUT "# error Cannot handle Boost.Function objects that accept more than $max_args arguments!\n"; -print OUT "#endif\n"; diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/detail/maybe_include.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/detail/maybe_include.hpp deleted file mode 100644 index 92f71bb2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/detail/maybe_include.hpp +++ /dev/null @@ -1,267 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#if BOOST_FUNCTION_NUM_ARGS == 0 -# ifndef BOOST_FUNCTION_0 -# define BOOST_FUNCTION_0 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 1 -# ifndef BOOST_FUNCTION_1 -# define BOOST_FUNCTION_1 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 2 -# ifndef BOOST_FUNCTION_2 -# define BOOST_FUNCTION_2 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 3 -# ifndef BOOST_FUNCTION_3 -# define BOOST_FUNCTION_3 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 4 -# ifndef BOOST_FUNCTION_4 -# define BOOST_FUNCTION_4 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 5 -# ifndef BOOST_FUNCTION_5 -# define BOOST_FUNCTION_5 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 6 -# ifndef BOOST_FUNCTION_6 -# define BOOST_FUNCTION_6 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 7 -# ifndef BOOST_FUNCTION_7 -# define BOOST_FUNCTION_7 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 8 -# ifndef BOOST_FUNCTION_8 -# define BOOST_FUNCTION_8 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 9 -# ifndef BOOST_FUNCTION_9 -# define BOOST_FUNCTION_9 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 10 -# ifndef BOOST_FUNCTION_10 -# define BOOST_FUNCTION_10 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 11 -# ifndef BOOST_FUNCTION_11 -# define BOOST_FUNCTION_11 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 12 -# ifndef BOOST_FUNCTION_12 -# define BOOST_FUNCTION_12 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 13 -# ifndef BOOST_FUNCTION_13 -# define BOOST_FUNCTION_13 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 14 -# ifndef BOOST_FUNCTION_14 -# define BOOST_FUNCTION_14 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 15 -# ifndef BOOST_FUNCTION_15 -# define BOOST_FUNCTION_15 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 16 -# ifndef BOOST_FUNCTION_16 -# define BOOST_FUNCTION_16 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 17 -# ifndef BOOST_FUNCTION_17 -# define BOOST_FUNCTION_17 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 18 -# ifndef BOOST_FUNCTION_18 -# define BOOST_FUNCTION_18 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 19 -# ifndef BOOST_FUNCTION_19 -# define BOOST_FUNCTION_19 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 20 -# ifndef BOOST_FUNCTION_20 -# define BOOST_FUNCTION_20 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 21 -# ifndef BOOST_FUNCTION_21 -# define BOOST_FUNCTION_21 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 22 -# ifndef BOOST_FUNCTION_22 -# define BOOST_FUNCTION_22 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 23 -# ifndef BOOST_FUNCTION_23 -# define BOOST_FUNCTION_23 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 24 -# ifndef BOOST_FUNCTION_24 -# define BOOST_FUNCTION_24 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 25 -# ifndef BOOST_FUNCTION_25 -# define BOOST_FUNCTION_25 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 26 -# ifndef BOOST_FUNCTION_26 -# define BOOST_FUNCTION_26 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 27 -# ifndef BOOST_FUNCTION_27 -# define BOOST_FUNCTION_27 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 28 -# ifndef BOOST_FUNCTION_28 -# define BOOST_FUNCTION_28 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 29 -# ifndef BOOST_FUNCTION_29 -# define BOOST_FUNCTION_29 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 30 -# ifndef BOOST_FUNCTION_30 -# define BOOST_FUNCTION_30 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 31 -# ifndef BOOST_FUNCTION_31 -# define BOOST_FUNCTION_31 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 32 -# ifndef BOOST_FUNCTION_32 -# define BOOST_FUNCTION_32 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 33 -# ifndef BOOST_FUNCTION_33 -# define BOOST_FUNCTION_33 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 34 -# ifndef BOOST_FUNCTION_34 -# define BOOST_FUNCTION_34 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 35 -# ifndef BOOST_FUNCTION_35 -# define BOOST_FUNCTION_35 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 36 -# ifndef BOOST_FUNCTION_36 -# define BOOST_FUNCTION_36 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 37 -# ifndef BOOST_FUNCTION_37 -# define BOOST_FUNCTION_37 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 38 -# ifndef BOOST_FUNCTION_38 -# define BOOST_FUNCTION_38 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 39 -# ifndef BOOST_FUNCTION_39 -# define BOOST_FUNCTION_39 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 40 -# ifndef BOOST_FUNCTION_40 -# define BOOST_FUNCTION_40 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 41 -# ifndef BOOST_FUNCTION_41 -# define BOOST_FUNCTION_41 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 42 -# ifndef BOOST_FUNCTION_42 -# define BOOST_FUNCTION_42 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 43 -# ifndef BOOST_FUNCTION_43 -# define BOOST_FUNCTION_43 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 44 -# ifndef BOOST_FUNCTION_44 -# define BOOST_FUNCTION_44 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 45 -# ifndef BOOST_FUNCTION_45 -# define BOOST_FUNCTION_45 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 46 -# ifndef BOOST_FUNCTION_46 -# define BOOST_FUNCTION_46 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 47 -# ifndef BOOST_FUNCTION_47 -# define BOOST_FUNCTION_47 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 48 -# ifndef BOOST_FUNCTION_48 -# define BOOST_FUNCTION_48 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 49 -# ifndef BOOST_FUNCTION_49 -# define BOOST_FUNCTION_49 -# include -# endif -#elif BOOST_FUNCTION_NUM_ARGS == 50 -# ifndef BOOST_FUNCTION_50 -# define BOOST_FUNCTION_50 -# include -# endif -#else -# error Cannot handle Boost.Function objects that accept more than 50 arguments! -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/detail/prologue.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/detail/prologue.hpp deleted file mode 100644 index 53d0f05c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/detail/prologue.hpp +++ /dev/null @@ -1,26 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#ifndef BOOST_FUNCTION_PROLOGUE_HPP -#define BOOST_FUNCTION_PROLOGUE_HPP -# include -# include -# include // unary_function, binary_function -# include -# include -# include -# include -# include -# include -# include -# include -# include -# include -# include -#endif // BOOST_FUNCTION_PROLOGUE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function0.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function0.hpp deleted file mode 100644 index 65a02e5f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function0.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 0 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function1.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function1.hpp deleted file mode 100644 index 90897151..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function1.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 1 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function10.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function10.hpp deleted file mode 100644 index 65627248..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function10.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 10 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function2.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function2.hpp deleted file mode 100644 index dc8bf975..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function2.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 2 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function3.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function3.hpp deleted file mode 100644 index 19d1a49d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function3.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 3 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function4.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function4.hpp deleted file mode 100644 index f3349e2d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function4.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 4 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function5.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function5.hpp deleted file mode 100644 index a1305eb5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function5.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 5 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function6.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function6.hpp deleted file mode 100644 index 1f609149..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function6.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 6 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function7.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function7.hpp deleted file mode 100644 index 68542ed4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function7.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 7 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function8.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function8.hpp deleted file mode 100644 index cf2c3766..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function8.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 8 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function9.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function9.hpp deleted file mode 100644 index 590e0883..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function9.hpp +++ /dev/null @@ -1,12 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2002-2003. Use, modification and -// distribution is subject to the Boost Software License, Version -// 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#define BOOST_FUNCTION_NUM_ARGS 9 -#include -#undef BOOST_FUNCTION_NUM_ARGS diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function_base.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function_base.hpp deleted file mode 100644 index 78b7dd1e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function_base.hpp +++ /dev/null @@ -1,910 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2001-2006 -// Copyright Emil Dotchevski 2007 -// Use, modification and distribution is subject to the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -#ifndef BOOST_FUNCTION_BASE_HEADER -#define BOOST_FUNCTION_BASE_HEADER - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#ifndef BOOST_NO_SFINAE -# include "boost/utility/enable_if.hpp" -#else -# include "boost/mpl/bool.hpp" -#endif -#include -#include - -#if defined(BOOST_MSVC) -# pragma warning( push ) -# pragma warning( disable : 4793 ) // complaint about native code generation -# pragma warning( disable : 4127 ) // "conditional expression is constant" -#endif - -// Define BOOST_FUNCTION_STD_NS to the namespace that contains type_info. -#ifdef BOOST_NO_STD_TYPEINFO -// Embedded VC++ does not have type_info in namespace std -# define BOOST_FUNCTION_STD_NS -#else -# define BOOST_FUNCTION_STD_NS std -#endif - -// Borrowed from Boost.Python library: determines the cases where we -// need to use std::type_info::name to compare instead of operator==. -#if defined( BOOST_NO_TYPEID ) -# define BOOST_FUNCTION_COMPARE_TYPE_ID(X,Y) ((X)==(Y)) -#elif (defined(__GNUC__) && __GNUC__ >= 3) \ - || defined(_AIX) \ - || ( defined(__sgi) && defined(__host_mips)) -# include -# define BOOST_FUNCTION_COMPARE_TYPE_ID(X,Y) \ - (std::strcmp((X).name(),(Y).name()) == 0) -# else -# define BOOST_FUNCTION_COMPARE_TYPE_ID(X,Y) ((X)==(Y)) -#endif - -#if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 || defined(__ICL) && __ICL <= 600 || defined(__MWERKS__) && __MWERKS__ < 0x2406 && !defined(BOOST_STRICT_CONFIG) -# define BOOST_FUNCTION_TARGET_FIX(x) x -#else -# define BOOST_FUNCTION_TARGET_FIX(x) -#endif // not MSVC - -#if !BOOST_WORKAROUND(__BORLANDC__, < 0x5A0) -# define BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor,Type) \ - typename ::boost::enable_if_c<(::boost::type_traits::ice_not< \ - (::boost::is_integral::value)>::value), \ - Type>::type -#else -// BCC doesn't recognize this depends on a template argument and complains -// about the use of 'typename' -# define BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor,Type) \ - ::boost::enable_if_c<(::boost::type_traits::ice_not< \ - (::boost::is_integral::value)>::value), \ - Type>::type -#endif - -namespace boost { - namespace detail { - namespace function { - class X; - - /** - * A buffer used to store small function objects in - * boost::function. It is a union containing function pointers, - * object pointers, and a structure that resembles a bound - * member function pointer. - */ - union function_buffer - { - // For pointers to function objects - mutable void* obj_ptr; - - // For pointers to std::type_info objects - struct type_t { - // (get_functor_type_tag, check_functor_type_tag). - const detail::sp_typeinfo* type; - - // Whether the type is const-qualified. - bool const_qualified; - // Whether the type is volatile-qualified. - bool volatile_qualified; - } type; - - // For function pointers of all kinds - mutable void (*func_ptr)(); - - // For bound member pointers - struct bound_memfunc_ptr_t { - void (X::*memfunc_ptr)(int); - void* obj_ptr; - } bound_memfunc_ptr; - - // For references to function objects. We explicitly keep - // track of the cv-qualifiers on the object referenced. - struct obj_ref_t { - mutable void* obj_ptr; - bool is_const_qualified; - bool is_volatile_qualified; - } obj_ref; - - // To relax aliasing constraints - mutable char data; - }; - - /** - * The unusable class is a placeholder for unused function arguments - * It is also completely unusable except that it constructable from - * anything. This helps compilers without partial specialization to - * handle Boost.Function objects returning void. - */ - struct unusable - { - unusable() {} - template unusable(const T&) {} - }; - - /* Determine the return type. This supports compilers that do not support - * void returns or partial specialization by silently changing the return - * type to "unusable". - */ - template struct function_return_type { typedef T type; }; - - template<> - struct function_return_type - { - typedef unusable type; - }; - - // The operation type to perform on the given functor/function pointer - enum functor_manager_operation_type { - clone_functor_tag, - move_functor_tag, - destroy_functor_tag, - check_functor_type_tag, - get_functor_type_tag - }; - - // Tags used to decide between different types of functions - struct function_ptr_tag {}; - struct function_obj_tag {}; - struct member_ptr_tag {}; - struct function_obj_ref_tag {}; - - template - class get_function_tag - { - typedef typename mpl::if_c<(is_pointer::value), - function_ptr_tag, - function_obj_tag>::type ptr_or_obj_tag; - - typedef typename mpl::if_c<(is_member_pointer::value), - member_ptr_tag, - ptr_or_obj_tag>::type ptr_or_obj_or_mem_tag; - - typedef typename mpl::if_c<(is_reference_wrapper::value), - function_obj_ref_tag, - ptr_or_obj_or_mem_tag>::type or_ref_tag; - - public: - typedef or_ref_tag type; - }; - - // The trivial manager does nothing but return the same pointer (if we - // are cloning) or return the null pointer (if we are deleting). - template - struct reference_manager - { - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - switch (op) { - case clone_functor_tag: - out_buffer.obj_ref = in_buffer.obj_ref; - return; - - case move_functor_tag: - out_buffer.obj_ref = in_buffer.obj_ref; - in_buffer.obj_ref.obj_ptr = 0; - return; - - case destroy_functor_tag: - out_buffer.obj_ref.obj_ptr = 0; - return; - - case check_functor_type_tag: - { - const detail::sp_typeinfo& check_type - = *out_buffer.type.type; - - // Check whether we have the same type. We can add - // cv-qualifiers, but we can't take them away. - if (BOOST_FUNCTION_COMPARE_TYPE_ID(check_type, BOOST_SP_TYPEID(F)) - && (!in_buffer.obj_ref.is_const_qualified - || out_buffer.type.const_qualified) - && (!in_buffer.obj_ref.is_volatile_qualified - || out_buffer.type.volatile_qualified)) - out_buffer.obj_ptr = in_buffer.obj_ref.obj_ptr; - else - out_buffer.obj_ptr = 0; - } - return; - - case get_functor_type_tag: - out_buffer.type.type = &BOOST_SP_TYPEID(F); - out_buffer.type.const_qualified = in_buffer.obj_ref.is_const_qualified; - out_buffer.type.volatile_qualified = in_buffer.obj_ref.is_volatile_qualified; - return; - } - } - }; - - /** - * Determine if boost::function can use the small-object - * optimization with the function object type F. - */ - template - struct function_allows_small_object_optimization - { - BOOST_STATIC_CONSTANT - (bool, - value = ((sizeof(F) <= sizeof(function_buffer) && - (alignment_of::value - % alignment_of::value == 0)))); - }; - - template - struct functor_wrapper: public F, public A - { - functor_wrapper( F f, A a ): - F(f), - A(a) - { - } - - functor_wrapper(const functor_wrapper& f) : - F(static_cast(f)), - A(static_cast(f)) - { - } - }; - - /** - * The functor_manager class contains a static function "manage" which - * can clone or destroy the given function/function object pointer. - */ - template - struct functor_manager_common - { - typedef Functor functor_type; - - // Function pointers - static inline void - manage_ptr(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - if (op == clone_functor_tag) - out_buffer.func_ptr = in_buffer.func_ptr; - else if (op == move_functor_tag) { - out_buffer.func_ptr = in_buffer.func_ptr; - in_buffer.func_ptr = 0; - } else if (op == destroy_functor_tag) - out_buffer.func_ptr = 0; - else if (op == check_functor_type_tag) { - const detail::sp_typeinfo& check_type - = *out_buffer.type.type; - if (BOOST_FUNCTION_COMPARE_TYPE_ID(check_type, BOOST_SP_TYPEID(Functor))) - out_buffer.obj_ptr = &in_buffer.func_ptr; - else - out_buffer.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.type.type = &BOOST_SP_TYPEID(Functor); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - } - } - - // Function objects that fit in the small-object buffer. - static inline void - manage_small(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - if (op == clone_functor_tag || op == move_functor_tag) { - const functor_type* in_functor = - reinterpret_cast(&in_buffer.data); - new (reinterpret_cast(&out_buffer.data)) functor_type(*in_functor); - - if (op == move_functor_tag) { - functor_type* f = reinterpret_cast(&in_buffer.data); - (void)f; // suppress warning about the value of f not being used (MSVC) - f->~Functor(); - } - } else if (op == destroy_functor_tag) { - // Some compilers (Borland, vc6, ...) are unhappy with ~functor_type. - functor_type* f = reinterpret_cast(&out_buffer.data); - (void)f; // suppress warning about the value of f not being used (MSVC) - f->~Functor(); - } else if (op == check_functor_type_tag) { - const detail::sp_typeinfo& check_type - = *out_buffer.type.type; - if (BOOST_FUNCTION_COMPARE_TYPE_ID(check_type, BOOST_SP_TYPEID(Functor))) - out_buffer.obj_ptr = &in_buffer.data; - else - out_buffer.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.type.type = &BOOST_SP_TYPEID(Functor); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - } - } - }; - - template - struct functor_manager - { - private: - typedef Functor functor_type; - - // Function pointers - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_ptr_tag) - { - functor_manager_common::manage_ptr(in_buffer,out_buffer,op); - } - - // Function objects that fit in the small-object buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, mpl::true_) - { - functor_manager_common::manage_small(in_buffer,out_buffer,op); - } - - // Function objects that require heap allocation - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, mpl::false_) - { - if (op == clone_functor_tag) { - // Clone the functor - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - // jewillco: Changing this to static_cast because GCC 2.95.3 is - // obsolete. - const functor_type* f = - static_cast(in_buffer.obj_ptr); - functor_type* new_f = new functor_type(*f); - out_buffer.obj_ptr = new_f; - } else if (op == move_functor_tag) { - out_buffer.obj_ptr = in_buffer.obj_ptr; - in_buffer.obj_ptr = 0; - } else if (op == destroy_functor_tag) { - /* Cast from the void pointer to the functor pointer type */ - functor_type* f = - static_cast(out_buffer.obj_ptr); - delete f; - out_buffer.obj_ptr = 0; - } else if (op == check_functor_type_tag) { - const detail::sp_typeinfo& check_type - = *out_buffer.type.type; - if (BOOST_FUNCTION_COMPARE_TYPE_ID(check_type, BOOST_SP_TYPEID(Functor))) - out_buffer.obj_ptr = in_buffer.obj_ptr; - else - out_buffer.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.type.type = &BOOST_SP_TYPEID(Functor); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - } - } - - // For function objects, we determine whether the function - // object can use the small-object optimization buffer or - // whether we need to allocate it on the heap. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_obj_tag) - { - manager(in_buffer, out_buffer, op, - mpl::bool_<(function_allows_small_object_optimization::value)>()); - } - - // For member pointers, we use the small-object optimization buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, member_ptr_tag) - { - manager(in_buffer, out_buffer, op, mpl::true_()); - } - - public: - /* Dispatch to an appropriate manager based on whether we have a - function pointer or a function object pointer. */ - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - typedef typename get_function_tag::type tag_type; - switch (op) { - case get_functor_type_tag: - out_buffer.type.type = &BOOST_SP_TYPEID(functor_type); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - return; - - default: - manager(in_buffer, out_buffer, op, tag_type()); - return; - } - } - }; - - template - struct functor_manager_a - { - private: - typedef Functor functor_type; - - // Function pointers - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_ptr_tag) - { - functor_manager_common::manage_ptr(in_buffer,out_buffer,op); - } - - // Function objects that fit in the small-object buffer. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, mpl::true_) - { - functor_manager_common::manage_small(in_buffer,out_buffer,op); - } - - // Function objects that require heap allocation - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, mpl::false_) - { - typedef functor_wrapper functor_wrapper_type; - typedef typename Allocator::template rebind::other - wrapper_allocator_type; - typedef typename wrapper_allocator_type::pointer wrapper_allocator_pointer_type; - - if (op == clone_functor_tag) { - // Clone the functor - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - const functor_wrapper_type* f = - static_cast(in_buffer.obj_ptr); - wrapper_allocator_type wrapper_allocator(static_cast(*f)); - wrapper_allocator_pointer_type copy = wrapper_allocator.allocate(1); - wrapper_allocator.construct(copy, *f); - - // Get back to the original pointer type - functor_wrapper_type* new_f = static_cast(copy); - out_buffer.obj_ptr = new_f; - } else if (op == move_functor_tag) { - out_buffer.obj_ptr = in_buffer.obj_ptr; - in_buffer.obj_ptr = 0; - } else if (op == destroy_functor_tag) { - /* Cast from the void pointer to the functor_wrapper_type */ - functor_wrapper_type* victim = - static_cast(in_buffer.obj_ptr); - wrapper_allocator_type wrapper_allocator(static_cast(*victim)); - wrapper_allocator.destroy(victim); - wrapper_allocator.deallocate(victim,1); - out_buffer.obj_ptr = 0; - } else if (op == check_functor_type_tag) { - const detail::sp_typeinfo& check_type - = *out_buffer.type.type; - if (BOOST_FUNCTION_COMPARE_TYPE_ID(check_type, BOOST_SP_TYPEID(Functor))) - out_buffer.obj_ptr = in_buffer.obj_ptr; - else - out_buffer.obj_ptr = 0; - } else /* op == get_functor_type_tag */ { - out_buffer.type.type = &BOOST_SP_TYPEID(Functor); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - } - } - - // For function objects, we determine whether the function - // object can use the small-object optimization buffer or - // whether we need to allocate it on the heap. - static inline void - manager(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op, function_obj_tag) - { - manager(in_buffer, out_buffer, op, - mpl::bool_<(function_allows_small_object_optimization::value)>()); - } - - public: - /* Dispatch to an appropriate manager based on whether we have a - function pointer or a function object pointer. */ - static inline void - manage(const function_buffer& in_buffer, function_buffer& out_buffer, - functor_manager_operation_type op) - { - typedef typename get_function_tag::type tag_type; - switch (op) { - case get_functor_type_tag: - out_buffer.type.type = &BOOST_SP_TYPEID(functor_type); - out_buffer.type.const_qualified = false; - out_buffer.type.volatile_qualified = false; - return; - - default: - manager(in_buffer, out_buffer, op, tag_type()); - return; - } - } - }; - - // A type that is only used for comparisons against zero - struct useless_clear_type {}; - -#ifdef BOOST_NO_SFINAE - // These routines perform comparisons between a Boost.Function - // object and an arbitrary function object (when the last - // parameter is mpl::bool_) or against zero (when the - // last parameter is mpl::bool_). They are only necessary - // for compilers that don't support SFINAE. - template - bool - compare_equal(const Function& f, const Functor&, int, mpl::bool_) - { return f.empty(); } - - template - bool - compare_not_equal(const Function& f, const Functor&, int, - mpl::bool_) - { return !f.empty(); } - - template - bool - compare_equal(const Function& f, const Functor& g, long, - mpl::bool_) - { - if (const Functor* fp = f.template target()) - return function_equal(*fp, g); - else return false; - } - - template - bool - compare_equal(const Function& f, const reference_wrapper& g, - int, mpl::bool_) - { - if (const Functor* fp = f.template target()) - return fp == g.get_pointer(); - else return false; - } - - template - bool - compare_not_equal(const Function& f, const Functor& g, long, - mpl::bool_) - { - if (const Functor* fp = f.template target()) - return !function_equal(*fp, g); - else return true; - } - - template - bool - compare_not_equal(const Function& f, - const reference_wrapper& g, int, - mpl::bool_) - { - if (const Functor* fp = f.template target()) - return fp != g.get_pointer(); - else return true; - } -#endif // BOOST_NO_SFINAE - - /** - * Stores the "manager" portion of the vtable for a - * boost::function object. - */ - struct vtable_base - { - void (*manager)(const function_buffer& in_buffer, - function_buffer& out_buffer, - functor_manager_operation_type op); - }; - } // end namespace function - } // end namespace detail - -/** - * The function_base class contains the basic elements needed for the - * function1, function2, function3, etc. classes. It is common to all - * functions (and as such can be used to tell if we have one of the - * functionN objects). - */ -class function_base -{ -public: - function_base() : vtable(0) { } - - /** Determine if the function is empty (i.e., has no target). */ - bool empty() const { return !vtable; } - - /** Retrieve the type of the stored function object, or BOOST_SP_TYPEID(void) - if this is empty. */ - const detail::sp_typeinfo& target_type() const - { - if (!vtable) return BOOST_SP_TYPEID(void); - - detail::function::function_buffer type; - get_vtable()->manager(functor, type, detail::function::get_functor_type_tag); - return *type.type.type; - } - - template - Functor* target() - { - if (!vtable) return 0; - - detail::function::function_buffer type_result; - type_result.type.type = &BOOST_SP_TYPEID(Functor); - type_result.type.const_qualified = is_const::value; - type_result.type.volatile_qualified = is_volatile::value; - get_vtable()->manager(functor, type_result, - detail::function::check_functor_type_tag); - return static_cast(type_result.obj_ptr); - } - - template -#if defined(BOOST_MSVC) && BOOST_WORKAROUND(BOOST_MSVC, < 1300) - const Functor* target( Functor * = 0 ) const -#else - const Functor* target() const -#endif - { - if (!vtable) return 0; - - detail::function::function_buffer type_result; - type_result.type.type = &BOOST_SP_TYPEID(Functor); - type_result.type.const_qualified = true; - type_result.type.volatile_qualified = is_volatile::value; - get_vtable()->manager(functor, type_result, - detail::function::check_functor_type_tag); - // GCC 2.95.3 gets the CV qualifiers wrong here, so we - // can't do the static_cast that we should do. - return static_cast(type_result.obj_ptr); - } - - template - bool contains(const F& f) const - { -#if defined(BOOST_MSVC) && BOOST_WORKAROUND(BOOST_MSVC, < 1300) - if (const F* fp = this->target( (F*)0 )) -#else - if (const F* fp = this->template target()) -#endif - { - return function_equal(*fp, f); - } else { - return false; - } - } - -#if defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3 - // GCC 3.3 and newer cannot copy with the global operator==, due to - // problems with instantiation of function return types before it - // has been verified that the argument types match up. - template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(Functor g) const - { - if (const Functor* fp = target()) - return function_equal(*fp, g); - else return false; - } - - template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(Functor g) const - { - if (const Functor* fp = target()) - return !function_equal(*fp, g); - else return true; - } -#endif - -public: // should be protected, but GCC 2.95.3 will fail to allow access - detail::function::vtable_base* get_vtable() const { - return reinterpret_cast( - reinterpret_cast(vtable) & ~static_cast(0x01)); - } - - bool has_trivial_copy_and_destroy() const { - return reinterpret_cast(vtable) & 0x01; - } - - detail::function::vtable_base* vtable; - mutable detail::function::function_buffer functor; -}; - -/** - * The bad_function_call exception class is thrown when a boost::function - * object is invoked - */ -class bad_function_call : public std::runtime_error -{ -public: - bad_function_call() : std::runtime_error("call to empty boost::function") {} -}; - -#ifndef BOOST_NO_SFINAE -inline bool operator==(const function_base& f, - detail::function::useless_clear_type*) -{ - return f.empty(); -} - -inline bool operator!=(const function_base& f, - detail::function::useless_clear_type*) -{ - return !f.empty(); -} - -inline bool operator==(detail::function::useless_clear_type*, - const function_base& f) -{ - return f.empty(); -} - -inline bool operator!=(detail::function::useless_clear_type*, - const function_base& f) -{ - return !f.empty(); -} -#endif - -#ifdef BOOST_NO_SFINAE -// Comparisons between boost::function objects and arbitrary function objects -template - inline bool operator==(const function_base& f, Functor g) - { - typedef mpl::bool_<(is_integral::value)> integral; - return detail::function::compare_equal(f, g, 0, integral()); - } - -template - inline bool operator==(Functor g, const function_base& f) - { - typedef mpl::bool_<(is_integral::value)> integral; - return detail::function::compare_equal(f, g, 0, integral()); - } - -template - inline bool operator!=(const function_base& f, Functor g) - { - typedef mpl::bool_<(is_integral::value)> integral; - return detail::function::compare_not_equal(f, g, 0, integral()); - } - -template - inline bool operator!=(Functor g, const function_base& f) - { - typedef mpl::bool_<(is_integral::value)> integral; - return detail::function::compare_not_equal(f, g, 0, integral()); - } -#else - -# if !(defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ <= 3) -// Comparisons between boost::function objects and arbitrary function -// objects. GCC 3.3 and before has an obnoxious bug that prevents this -// from working. -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(const function_base& f, Functor g) - { - if (const Functor* fp = f.template target()) - return function_equal(*fp, g); - else return false; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(Functor g, const function_base& f) - { - if (const Functor* fp = f.template target()) - return function_equal(g, *fp); - else return false; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(const function_base& f, Functor g) - { - if (const Functor* fp = f.template target()) - return !function_equal(*fp, g); - else return true; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(Functor g, const function_base& f) - { - if (const Functor* fp = f.template target()) - return !function_equal(g, *fp); - else return true; - } -# endif - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(const function_base& f, reference_wrapper g) - { - if (const Functor* fp = f.template target()) - return fp == g.get_pointer(); - else return false; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator==(reference_wrapper g, const function_base& f) - { - if (const Functor* fp = f.template target()) - return g.get_pointer() == fp; - else return false; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(const function_base& f, reference_wrapper g) - { - if (const Functor* fp = f.template target()) - return fp != g.get_pointer(); - else return true; - } - -template - BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL(Functor, bool) - operator!=(reference_wrapper g, const function_base& f) - { - if (const Functor* fp = f.template target()) - return g.get_pointer() != fp; - else return true; - } - -#endif // Compiler supporting SFINAE - -namespace detail { - namespace function { - inline bool has_empty_target(const function_base* f) - { - return f->empty(); - } - -#if BOOST_WORKAROUND(BOOST_MSVC, <= 1310) - inline bool has_empty_target(const void*) - { - return false; - } -#else - inline bool has_empty_target(...) - { - return false; - } -#endif - } // end namespace function -} // end namespace detail -} // end namespace boost - -#undef BOOST_FUNCTION_ENABLE_IF_NOT_INTEGRAL -#undef BOOST_FUNCTION_COMPARE_TYPE_ID - -#if defined(BOOST_MSVC) -# pragma warning( pop ) -#endif - -#endif // BOOST_FUNCTION_BASE_HEADER diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function_fwd.hpp deleted file mode 100644 index fb318c99..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function_fwd.hpp +++ /dev/null @@ -1,70 +0,0 @@ -// Boost.Function library -// Copyright (C) Douglas Gregor 2008 -// -// Use, modification and distribution is subject to the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// For more information, see http://www.boost.org -#ifndef BOOST_FUNCTION_FWD_HPP -#define BOOST_FUNCTION_FWD_HPP -#include - -#if defined(__sgi) && defined(_COMPILER_VERSION) && _COMPILER_VERSION <= 730 && !defined(BOOST_STRICT_CONFIG) -// Work around a compiler bug. -// boost::python::objects::function has to be seen by the compiler before the -// boost::function class template. -namespace boost { namespace python { namespace objects { - class function; -}}} -#endif - -#if defined (BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \ - || defined(BOOST_BCB_PARTIAL_SPECIALIZATION_BUG) \ - || !(defined(BOOST_STRICT_CONFIG) || !defined(__SUNPRO_CC) || __SUNPRO_CC > 0x540) -# define BOOST_FUNCTION_NO_FUNCTION_TYPE_SYNTAX -#endif - -namespace boost { - class bad_function_call; - -#if !defined(BOOST_FUNCTION_NO_FUNCTION_TYPE_SYNTAX) - // Preferred syntax - template class function; - - template - inline void swap(function& f1, function& f2) - { - f1.swap(f2); - } -#endif // have partial specialization - - // Portable syntax - template class function0; - template class function1; - template class function2; - template class function3; - template - class function4; - template - class function5; - template - class function6; - template - class function7; - template - class function8; - template - class function9; - template - class function10; -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/function/function_template.hpp b/third_party/ycmd/cpp/BoostParts/boost/function/function_template.hpp deleted file mode 100644 index 73ed72ef..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function/function_template.hpp +++ /dev/null @@ -1,1185 +0,0 @@ -// Boost.Function library - -// Copyright Douglas Gregor 2001-2006 -// Copyright Emil Dotchevski 2007 -// Use, modification and distribution is subject to the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org - -// Note: this header is a header template and must NOT have multiple-inclusion -// protection. -#include -#include - -#if defined(BOOST_MSVC) -# pragma warning( push ) -# pragma warning( disable : 4127 ) // "conditional expression is constant" -#endif - -#define BOOST_FUNCTION_TEMPLATE_PARMS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, typename T) - -#define BOOST_FUNCTION_TEMPLATE_ARGS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, T) - -#define BOOST_FUNCTION_PARM(J,I,D) BOOST_PP_CAT(T,I) BOOST_PP_CAT(a,I) - -#define BOOST_FUNCTION_PARMS BOOST_PP_ENUM(BOOST_FUNCTION_NUM_ARGS,BOOST_FUNCTION_PARM,BOOST_PP_EMPTY) - -#define BOOST_FUNCTION_ARGS BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS, a) - -#define BOOST_FUNCTION_ARG_TYPE(J,I,D) \ - typedef BOOST_PP_CAT(T,I) BOOST_PP_CAT(BOOST_PP_CAT(arg, BOOST_PP_INC(I)),_type); - -#define BOOST_FUNCTION_ARG_TYPES BOOST_PP_REPEAT(BOOST_FUNCTION_NUM_ARGS,BOOST_FUNCTION_ARG_TYPE,BOOST_PP_EMPTY) - -// Comma if nonzero number of arguments -#if BOOST_FUNCTION_NUM_ARGS == 0 -# define BOOST_FUNCTION_COMMA -#else -# define BOOST_FUNCTION_COMMA , -#endif // BOOST_FUNCTION_NUM_ARGS > 0 - -// Class names used in this version of the code -#define BOOST_FUNCTION_FUNCTION BOOST_JOIN(function,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_INVOKER \ - BOOST_JOIN(function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_INVOKER \ - BOOST_JOIN(void_function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(void_function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_FUNCTION_REF_INVOKER \ - BOOST_JOIN(function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER \ - BOOST_JOIN(void_function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_MEMBER_INVOKER \ - BOOST_JOIN(function_mem_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VOID_MEMBER_INVOKER \ - BOOST_JOIN(function_void_mem_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_INVOKER \ - BOOST_JOIN(get_function_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER \ - BOOST_JOIN(get_function_obj_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER \ - BOOST_JOIN(get_function_ref_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_MEMBER_INVOKER \ - BOOST_JOIN(get_member_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_GET_INVOKER \ - BOOST_JOIN(get_invoker,BOOST_FUNCTION_NUM_ARGS) -#define BOOST_FUNCTION_VTABLE BOOST_JOIN(basic_vtable,BOOST_FUNCTION_NUM_ARGS) - -#ifndef BOOST_NO_VOID_RETURNS -# define BOOST_FUNCTION_VOID_RETURN_TYPE void -# define BOOST_FUNCTION_RETURN(X) X -#else -# define BOOST_FUNCTION_VOID_RETURN_TYPE boost::detail::function::unusable -# define BOOST_FUNCTION_RETURN(X) X; return BOOST_FUNCTION_VOID_RETURN_TYPE () -#endif - -namespace boost { - namespace detail { - namespace function { - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_INVOKER - { - static R invoke(function_buffer& function_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - { - FunctionPtr f = reinterpret_cast(function_ptr.func_ptr); - return f(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionPtr f = reinterpret_cast(function_ptr.func_ptr); - BOOST_FUNCTION_RETURN(f(BOOST_FUNCTION_ARGS)); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_OBJ_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f; - if (function_allows_small_object_optimization::value) - f = reinterpret_cast(&function_obj_ptr.data); - else - f = reinterpret_cast(function_obj_ptr.obj_ptr); - return (*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f; - if (function_allows_small_object_optimization::value) - f = reinterpret_cast(&function_obj_ptr.data); - else - f = reinterpret_cast(function_obj_ptr.obj_ptr); - BOOST_FUNCTION_RETURN((*f)(BOOST_FUNCTION_ARGS)); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_FUNCTION_REF_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f = - reinterpret_cast(function_obj_ptr.obj_ptr); - return (*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - FunctionObj* f = - reinterpret_cast(function_obj_ptr.obj_ptr); - BOOST_FUNCTION_RETURN((*f)(BOOST_FUNCTION_ARGS)); - } - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Handle invocation of member pointers. */ - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_MEMBER_INVOKER - { - static R invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - MemberPtr* f = - reinterpret_cast(&function_obj_ptr.data); - return boost::mem_fn(*f)(BOOST_FUNCTION_ARGS); - } - }; - - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_VOID_MEMBER_INVOKER - { - static BOOST_FUNCTION_VOID_RETURN_TYPE - invoke(function_buffer& function_obj_ptr BOOST_FUNCTION_COMMA - BOOST_FUNCTION_PARMS) - - { - MemberPtr* f = - reinterpret_cast(&function_obj_ptr.data); - BOOST_FUNCTION_RETURN(boost::mem_fn(*f)(BOOST_FUNCTION_ARGS)); - } - }; -#endif - - template< - typename FunctionPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_INVOKER - { - typedef typename mpl::if_c<(is_void::value), - BOOST_FUNCTION_VOID_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER - { - typedef typename mpl::if_c<(is_void::value), - BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - - template< - typename FunctionObj, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER - { - typedef typename mpl::if_c<(is_void::value), - BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_FUNCTION_REF_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Retrieve the appropriate invoker for a member pointer. */ - template< - typename MemberPtr, - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - struct BOOST_FUNCTION_GET_MEMBER_INVOKER - { - typedef typename mpl::if_c<(is_void::value), - BOOST_FUNCTION_VOID_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >, - BOOST_FUNCTION_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - > - >::type type; - }; -#endif - - /* Given the tag returned by get_function_tag, retrieve the - actual invoker that will be used for the given function - object. - - Each specialization contains an "apply" nested class template - that accepts the function object, return type, function - argument types, and allocator. The resulting "apply" class - contains two typedefs, "invoker_type" and "manager_type", - which correspond to the invoker and manager types. */ - template - struct BOOST_FUNCTION_GET_INVOKER { }; - - /* Retrieve the invoker for a function pointer. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER - { - template - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager manager_type; - }; - - template - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_INVOKER< - FunctionPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager manager_type; - }; - }; - -#if BOOST_FUNCTION_NUM_ARGS > 0 - /* Retrieve the invoker for a member pointer. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER - { - template - struct apply - { - typedef typename BOOST_FUNCTION_GET_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager manager_type; - }; - - template - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_MEMBER_INVOKER< - MemberPtr, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager manager_type; - }; - }; -#endif - - /* Retrieve the invoker for a function object. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER - { - template - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager manager_type; - }; - - template - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER< - FunctionObj, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef functor_manager_a manager_type; - }; - }; - - /* Retrieve the invoker for a reference to a function object. */ - template<> - struct BOOST_FUNCTION_GET_INVOKER - { - template - struct apply - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER< - typename RefWrapper::type, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef reference_manager manager_type; - }; - - template - struct apply_a - { - typedef typename BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER< - typename RefWrapper::type, - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >::type - invoker_type; - - typedef reference_manager manager_type; - }; - }; - - - /** - * vtable for a specific boost::function instance. This - * structure must be an aggregate so that we can use static - * initialization in boost::function's assign_to and assign_to_a - * members. It therefore cannot have any constructors, - * destructors, base classes, etc. - */ - template - struct BOOST_FUNCTION_VTABLE - { -#ifndef BOOST_NO_VOID_RETURNS - typedef R result_type; -#else - typedef typename function_return_type::type result_type; -#endif // BOOST_NO_VOID_RETURNS - - typedef result_type (*invoker_type)(function_buffer& - BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS); - - template - bool assign_to(F f, function_buffer& functor) const - { - typedef typename get_function_tag::type tag; - return assign_to(f, functor, tag()); - } - template - bool assign_to_a(F f, function_buffer& functor, Allocator a) const - { - typedef typename get_function_tag::type tag; - return assign_to_a(f, functor, a, tag()); - } - - void clear(function_buffer& functor) const - { - if (base.manager) - base.manager(functor, functor, destroy_functor_tag); - } - - private: - // Function pointers - template - bool - assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const - { - this->clear(functor); - if (f) { - // should be a reinterpret cast, but some compilers insist - // on giving cv-qualifiers to free functions - functor.func_ptr = reinterpret_cast(f); - return true; - } else { - return false; - } - } - template - bool - assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const - { - return assign_to(f,functor,function_ptr_tag()); - } - - // Member pointers -#if BOOST_FUNCTION_NUM_ARGS > 0 - template - bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const - { - // DPG TBD: Add explicit support for member function - // objects, so we invoke through mem_fn() but we retain the - // right target_type() values. - if (f) { - this->assign_to(boost::mem_fn(f), functor); - return true; - } else { - return false; - } - } - template - bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const - { - // DPG TBD: Add explicit support for member function - // objects, so we invoke through mem_fn() but we retain the - // right target_type() values. - if (f) { - this->assign_to_a(boost::mem_fn(f), functor, a); - return true; - } else { - return false; - } - } -#endif // BOOST_FUNCTION_NUM_ARGS > 0 - - // Function objects - // Assign to a function object using the small object optimization - template - void - assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const - { - new (reinterpret_cast(&functor.data)) FunctionObj(f); - } - template - void - assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const - { - assign_functor(f,functor,mpl::true_()); - } - - // Assign to a function object allocated on the heap. - template - void - assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const - { - functor.obj_ptr = new FunctionObj(f); - } - template - void - assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const - { - typedef functor_wrapper functor_wrapper_type; - typedef typename Allocator::template rebind::other - wrapper_allocator_type; - typedef typename wrapper_allocator_type::pointer wrapper_allocator_pointer_type; - wrapper_allocator_type wrapper_allocator(a); - wrapper_allocator_pointer_type copy = wrapper_allocator.allocate(1); - wrapper_allocator.construct(copy, functor_wrapper_type(f,a)); - functor_wrapper_type* new_f = static_cast(copy); - functor.obj_ptr = new_f; - } - - template - bool - assign_to(FunctionObj f, function_buffer& functor, function_obj_tag) const - { - if (!boost::detail::function::has_empty_target(boost::addressof(f))) { - assign_functor(f, functor, - mpl::bool_<(function_allows_small_object_optimization::value)>()); - return true; - } else { - return false; - } - } - template - bool - assign_to_a(FunctionObj f, function_buffer& functor, Allocator a, function_obj_tag) const - { - if (!boost::detail::function::has_empty_target(boost::addressof(f))) { - assign_functor_a(f, functor, a, - mpl::bool_<(function_allows_small_object_optimization::value)>()); - return true; - } else { - return false; - } - } - - // Reference to a function object - template - bool - assign_to(const reference_wrapper& f, - function_buffer& functor, function_obj_ref_tag) const - { - functor.obj_ref.obj_ptr = (void *)(f.get_pointer()); - functor.obj_ref.is_const_qualified = is_const::value; - functor.obj_ref.is_volatile_qualified = is_volatile::value; - return true; - } - template - bool - assign_to_a(const reference_wrapper& f, - function_buffer& functor, Allocator, function_obj_ref_tag) const - { - return assign_to(f,functor,function_obj_ref_tag()); - } - - public: - vtable_base base; - invoker_type invoker; - }; - } // end namespace function - } // end namespace detail - - template< - typename R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_PARMS - > - class BOOST_FUNCTION_FUNCTION : public function_base - -#if BOOST_FUNCTION_NUM_ARGS == 1 - - , public std::unary_function - -#elif BOOST_FUNCTION_NUM_ARGS == 2 - - , public std::binary_function - -#endif - - { - public: -#ifndef BOOST_NO_VOID_RETURNS - typedef R result_type; -#else - typedef typename boost::detail::function::function_return_type::type - result_type; -#endif // BOOST_NO_VOID_RETURNS - - private: - typedef boost::detail::function::BOOST_FUNCTION_VTABLE< - R BOOST_FUNCTION_COMMA BOOST_FUNCTION_TEMPLATE_ARGS> - vtable_type; - - vtable_type* get_vtable() const { - return reinterpret_cast( - reinterpret_cast(vtable) & ~static_cast(0x01)); - } - - struct clear_type {}; - - public: - BOOST_STATIC_CONSTANT(int, args = BOOST_FUNCTION_NUM_ARGS); - - // add signature for boost::lambda - template - struct sig - { - typedef result_type type; - }; - -#if BOOST_FUNCTION_NUM_ARGS == 1 - typedef T0 argument_type; -#elif BOOST_FUNCTION_NUM_ARGS == 2 - typedef T0 first_argument_type; - typedef T1 second_argument_type; -#endif - - BOOST_STATIC_CONSTANT(int, arity = BOOST_FUNCTION_NUM_ARGS); - BOOST_FUNCTION_ARG_TYPES - - typedef BOOST_FUNCTION_FUNCTION self_type; - - BOOST_FUNCTION_FUNCTION() : function_base() { } - - // MSVC chokes if the following two constructors are collapsed into - // one with a default parameter. - template - BOOST_FUNCTION_FUNCTION(Functor BOOST_FUNCTION_TARGET_FIX(const &) f -#ifndef BOOST_NO_SFINAE - ,typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - int>::type = 0 -#endif // BOOST_NO_SFINAE - ) : - function_base() - { - this->assign_to(f); - } - template - BOOST_FUNCTION_FUNCTION(Functor BOOST_FUNCTION_TARGET_FIX(const &) f, Allocator a -#ifndef BOOST_NO_SFINAE - ,typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - int>::type = 0 -#endif // BOOST_NO_SFINAE - ) : - function_base() - { - this->assign_to_a(f,a); - } - -#ifndef BOOST_NO_SFINAE - BOOST_FUNCTION_FUNCTION(clear_type*) : function_base() { } -#else - BOOST_FUNCTION_FUNCTION(int zero) : function_base() - { - BOOST_ASSERT(zero == 0); - } -#endif - - BOOST_FUNCTION_FUNCTION(const BOOST_FUNCTION_FUNCTION& f) : function_base() - { - this->assign_to_own(f); - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - BOOST_FUNCTION_FUNCTION(BOOST_FUNCTION_FUNCTION&& f) : function_base() - { - this->move_assign(f); - } -#endif - - ~BOOST_FUNCTION_FUNCTION() { clear(); } - - result_type operator()(BOOST_FUNCTION_PARMS) const - { - if (this->empty()) - boost::throw_exception(bad_function_call()); - - return get_vtable()->invoker - (this->functor BOOST_FUNCTION_COMMA BOOST_FUNCTION_ARGS); - } - - // The distinction between when to use BOOST_FUNCTION_FUNCTION and - // when to use self_type is obnoxious. MSVC cannot handle self_type as - // the return type of these assignment operators, but Borland C++ cannot - // handle BOOST_FUNCTION_FUNCTION as the type of the temporary to - // construct. - template -#ifndef BOOST_NO_SFINAE - typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - BOOST_FUNCTION_FUNCTION&>::type -#else - BOOST_FUNCTION_FUNCTION& -#endif - operator=(Functor BOOST_FUNCTION_TARGET_FIX(const &) f) - { - this->clear(); - BOOST_TRY { - this->assign_to(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } - template - void assign(Functor BOOST_FUNCTION_TARGET_FIX(const &) f, Allocator a) - { - this->clear(); - BOOST_TRY{ - this->assign_to_a(f,a); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - } - -#ifndef BOOST_NO_SFINAE - BOOST_FUNCTION_FUNCTION& operator=(clear_type*) - { - this->clear(); - return *this; - } -#else - BOOST_FUNCTION_FUNCTION& operator=(int zero) - { - BOOST_ASSERT(zero == 0); - this->clear(); - return *this; - } -#endif - - // Assignment from another BOOST_FUNCTION_FUNCTION - BOOST_FUNCTION_FUNCTION& operator=(const BOOST_FUNCTION_FUNCTION& f) - { - if (&f == this) - return *this; - - this->clear(); - BOOST_TRY { - this->assign_to_own(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - // Move assignment from another BOOST_FUNCTION_FUNCTION - BOOST_FUNCTION_FUNCTION& operator=(BOOST_FUNCTION_FUNCTION&& f) - { - - if (&f == this) - return *this; - - this->clear(); - BOOST_TRY { - this->move_assign(f); - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - return *this; - } -#endif - - void swap(BOOST_FUNCTION_FUNCTION& other) - { - if (&other == this) - return; - - BOOST_FUNCTION_FUNCTION tmp; - tmp.move_assign(*this); - this->move_assign(other); - other.move_assign(tmp); - } - - // Clear out a target, if there is one - void clear() - { - if (vtable) { - if (!this->has_trivial_copy_and_destroy()) - get_vtable()->clear(this->functor); - vtable = 0; - } - } - -#if (defined __SUNPRO_CC) && (__SUNPRO_CC <= 0x530) && !(defined BOOST_NO_COMPILER_CONFIG) - // Sun C++ 5.3 can't handle the safe_bool idiom, so don't use it - operator bool () const { return !this->empty(); } -#else - private: - struct dummy { - void nonnull() {} - }; - - typedef void (dummy::*safe_bool)(); - - public: - operator safe_bool () const - { return (this->empty())? 0 : &dummy::nonnull; } - - bool operator!() const - { return this->empty(); } -#endif - - private: - void assign_to_own(const BOOST_FUNCTION_FUNCTION& f) - { - if (!f.empty()) { - this->vtable = f.vtable; - if (this->has_trivial_copy_and_destroy()) - this->functor = f.functor; - else - get_vtable()->base.manager(f.functor, this->functor, - boost::detail::function::clone_functor_tag); - } - } - - template - void assign_to(Functor f) - { - using detail::function::vtable_base; - - typedef typename detail::function::get_function_tag::type tag; - typedef detail::function::BOOST_FUNCTION_GET_INVOKER get_invoker; - typedef typename get_invoker:: - template apply - handler_type; - - typedef typename handler_type::invoker_type invoker_type; - typedef typename handler_type::manager_type manager_type; - - // Note: it is extremely important that this initialization use - // static initialization. Otherwise, we will have a race - // condition here in multi-threaded code. See - // http://thread.gmane.org/gmane.comp.lib.boost.devel/164902/. - static const vtable_type stored_vtable = - { { &manager_type::manage }, &invoker_type::invoke }; - - if (stored_vtable.assign_to(f, functor)) { - std::size_t value = reinterpret_cast(&stored_vtable.base); - if (boost::has_trivial_copy_constructor::value && - boost::has_trivial_destructor::value && - detail::function::function_allows_small_object_optimization::value) - value |= static_cast(0x01); - vtable = reinterpret_cast(value); - } else - vtable = 0; - } - - template - void assign_to_a(Functor f,Allocator a) - { - using detail::function::vtable_base; - - typedef typename detail::function::get_function_tag::type tag; - typedef detail::function::BOOST_FUNCTION_GET_INVOKER get_invoker; - typedef typename get_invoker:: - template apply_a - handler_type; - - typedef typename handler_type::invoker_type invoker_type; - typedef typename handler_type::manager_type manager_type; - - // Note: it is extremely important that this initialization use - // static initialization. Otherwise, we will have a race - // condition here in multi-threaded code. See - // http://thread.gmane.org/gmane.comp.lib.boost.devel/164902/. - static const vtable_type stored_vtable = - { { &manager_type::manage }, &invoker_type::invoke }; - - if (stored_vtable.assign_to_a(f, functor, a)) { - std::size_t value = reinterpret_cast(&stored_vtable.base); - if (boost::has_trivial_copy_constructor::value && - boost::has_trivial_destructor::value && - detail::function::function_allows_small_object_optimization::value) - value |= static_cast(0x01); - vtable = reinterpret_cast(value); - } else - vtable = 0; - } - - // Moves the value from the specified argument to *this. If the argument - // has its function object allocated on the heap, move_assign will pass - // its buffer to *this, and set the argument's buffer pointer to NULL. - void move_assign(BOOST_FUNCTION_FUNCTION& f) - { - if (&f == this) - return; - - BOOST_TRY { - if (!f.empty()) { - this->vtable = f.vtable; - if (this->has_trivial_copy_and_destroy()) - this->functor = f.functor; - else - get_vtable()->base.manager(f.functor, this->functor, - boost::detail::function::move_functor_tag); - f.vtable = 0; - } else { - clear(); - } - } BOOST_CATCH (...) { - vtable = 0; - BOOST_RETHROW; - } - BOOST_CATCH_END - } - }; - - template - inline void swap(BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >& f1, - BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS - >& f2) - { - f1.swap(f2); - } - -// Poison comparisons between boost::function objects of the same type. -template - void operator==(const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&, - const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&); -template - void operator!=(const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>&, - const BOOST_FUNCTION_FUNCTION< - R BOOST_FUNCTION_COMMA - BOOST_FUNCTION_TEMPLATE_ARGS>& ); - -#if !defined(BOOST_FUNCTION_NO_FUNCTION_TYPE_SYNTAX) - -#if BOOST_FUNCTION_NUM_ARGS == 0 -#define BOOST_FUNCTION_PARTIAL_SPEC R (void) -#else -#define BOOST_FUNCTION_PARTIAL_SPEC R (BOOST_PP_ENUM_PARAMS(BOOST_FUNCTION_NUM_ARGS,T)) -#endif - -template -class function - : public BOOST_FUNCTION_FUNCTION -{ - typedef BOOST_FUNCTION_FUNCTION base_type; - typedef function self_type; - - struct clear_type {}; - -public: - - function() : base_type() {} - - template - function(Functor f -#ifndef BOOST_NO_SFINAE - ,typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - int>::type = 0 -#endif - ) : - base_type(f) - { - } - template - function(Functor f, Allocator a -#ifndef BOOST_NO_SFINAE - ,typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - int>::type = 0 -#endif - ) : - base_type(f,a) - { - } - -#ifndef BOOST_NO_SFINAE - function(clear_type*) : base_type() {} -#endif - - function(const self_type& f) : base_type(static_cast(f)){} - - function(const base_type& f) : base_type(static_cast(f)){} - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - // Move constructors - function(self_type&& f): base_type(static_cast(f)){} - function(base_type&& f): base_type(static_cast(f)){} -#endif - - self_type& operator=(const self_type& f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - self_type& operator=(self_type&& f) - { - self_type(static_cast(f)).swap(*this); - return *this; - } -#endif - - template -#ifndef BOOST_NO_SFINAE - typename enable_if_c< - (boost::type_traits::ice_not< - (is_integral::value)>::value), - self_type&>::type -#else - self_type& -#endif - operator=(Functor f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_SFINAE - self_type& operator=(clear_type*) - { - this->clear(); - return *this; - } -#endif - - self_type& operator=(const base_type& f) - { - self_type(f).swap(*this); - return *this; - } - -#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES - self_type& operator=(base_type&& f) - { - self_type(static_cast(f)).swap(*this); - return *this; - } -#endif -}; - -#undef BOOST_FUNCTION_PARTIAL_SPEC -#endif // have partial specialization - -} // end namespace boost - -// Cleanup after ourselves... -#undef BOOST_FUNCTION_VTABLE -#undef BOOST_FUNCTION_COMMA -#undef BOOST_FUNCTION_FUNCTION -#undef BOOST_FUNCTION_FUNCTION_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_INVOKER -#undef BOOST_FUNCTION_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_VOID_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_MEMBER_INVOKER -#undef BOOST_FUNCTION_VOID_MEMBER_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_OBJ_INVOKER -#undef BOOST_FUNCTION_GET_FUNCTION_REF_INVOKER -#undef BOOST_FUNCTION_GET_MEM_FUNCTION_INVOKER -#undef BOOST_FUNCTION_GET_INVOKER -#undef BOOST_FUNCTION_TEMPLATE_PARMS -#undef BOOST_FUNCTION_TEMPLATE_ARGS -#undef BOOST_FUNCTION_PARMS -#undef BOOST_FUNCTION_PARM -#undef BOOST_FUNCTION_ARGS -#undef BOOST_FUNCTION_ARG_TYPE -#undef BOOST_FUNCTION_ARG_TYPES -#undef BOOST_FUNCTION_VOID_RETURN_TYPE -#undef BOOST_FUNCTION_RETURN - -#if defined(BOOST_MSVC) -# pragma warning( pop ) -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/function_equal.hpp b/third_party/ycmd/cpp/BoostParts/boost/function_equal.hpp deleted file mode 100644 index 2d76c75b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/function_equal.hpp +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright Douglas Gregor 2004. -// Copyright 2005 Peter Dimov - -// Use, modification and distribution is subject to -// the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// For more information, see http://www.boost.org -#ifndef BOOST_FUNCTION_EQUAL_HPP -#define BOOST_FUNCTION_EQUAL_HPP - -namespace boost { - -template - bool function_equal_impl(const F& f, const G& g, long) - { return f == g; } - -// function_equal_impl needs to be unqualified to pick -// user overloads on two-phase compilers - -template - bool function_equal(const F& f, const G& g) - { return function_equal_impl(f, g, 0); } - -} // end namespace boost - -#endif // BOOST_FUNCTION_EQUAL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional.hpp deleted file mode 100644 index 3e0588e0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional.hpp +++ /dev/null @@ -1,548 +0,0 @@ -// ------------------------------------------------------------------------------ -// Copyright (c) 2000 Cadenza New Zealand Ltd -// Distributed under the Boost Software License, Version 1.0. (See accompany- -// ing file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// ------------------------------------------------------------------------------ -// Boost functional.hpp header file -// See http://www.boost.org/libs/functional for documentation. -// ------------------------------------------------------------------------------ -// $Id: functional.hpp 36246 2006-12-02 14:17:26Z andreas_huber69 $ -// ------------------------------------------------------------------------------ - -#ifndef BOOST_FUNCTIONAL_HPP -#define BOOST_FUNCTIONAL_HPP - -#include -#include -#include - -namespace boost -{ -#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - // -------------------------------------------------------------------------- - // The following traits classes allow us to avoid the need for ptr_fun - // because the types of arguments and the result of a function can be - // deduced. - // - // In addition to the standard types defined in unary_function and - // binary_function, we add - // - // - function_type, the type of the function or function object itself. - // - // - param_type, the type that should be used for passing the function or - // function object as an argument. - // -------------------------------------------------------------------------- - namespace detail - { - template - struct unary_traits_imp; - - template - struct unary_traits_imp - { - typedef Operation function_type; - typedef const function_type & param_type; - typedef typename Operation::result_type result_type; - typedef typename Operation::argument_type argument_type; - }; - - template - struct unary_traits_imp - { - typedef R (*function_type)(A); - typedef R (*param_type)(A); - typedef R result_type; - typedef A argument_type; - }; - - template - struct binary_traits_imp; - - template - struct binary_traits_imp - { - typedef Operation function_type; - typedef const function_type & param_type; - typedef typename Operation::result_type result_type; - typedef typename Operation::first_argument_type first_argument_type; - typedef typename Operation::second_argument_type second_argument_type; - }; - - template - struct binary_traits_imp - { - typedef R (*function_type)(A1,A2); - typedef R (*param_type)(A1,A2); - typedef R result_type; - typedef A1 first_argument_type; - typedef A2 second_argument_type; - }; - } // namespace detail - - template - struct unary_traits - { - typedef typename detail::unary_traits_imp::function_type function_type; - typedef typename detail::unary_traits_imp::param_type param_type; - typedef typename detail::unary_traits_imp::result_type result_type; - typedef typename detail::unary_traits_imp::argument_type argument_type; - }; - - template - struct unary_traits - { - typedef R (*function_type)(A); - typedef R (*param_type)(A); - typedef R result_type; - typedef A argument_type; - }; - - template - struct binary_traits - { - typedef typename detail::binary_traits_imp::function_type function_type; - typedef typename detail::binary_traits_imp::param_type param_type; - typedef typename detail::binary_traits_imp::result_type result_type; - typedef typename detail::binary_traits_imp::first_argument_type first_argument_type; - typedef typename detail::binary_traits_imp::second_argument_type second_argument_type; - }; - - template - struct binary_traits - { - typedef R (*function_type)(A1,A2); - typedef R (*param_type)(A1,A2); - typedef R result_type; - typedef A1 first_argument_type; - typedef A2 second_argument_type; - }; -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - // -------------------------------------------------------------------------- - // If we have no partial specialisation available, decay to a situation - // that is no worse than in the Standard, i.e., ptr_fun will be required. - // -------------------------------------------------------------------------- - - template - struct unary_traits - { - typedef Operation function_type; - typedef const Operation& param_type; - typedef typename Operation::result_type result_type; - typedef typename Operation::argument_type argument_type; - }; - - template - struct binary_traits - { - typedef Operation function_type; - typedef const Operation & param_type; - typedef typename Operation::result_type result_type; - typedef typename Operation::first_argument_type first_argument_type; - typedef typename Operation::second_argument_type second_argument_type; - }; -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // -------------------------------------------------------------------------- - // unary_negate, not1 - // -------------------------------------------------------------------------- - template - class unary_negate - : public std::unary_function::argument_type,bool> - { - public: - explicit unary_negate(typename unary_traits::param_type x) - : - pred(x) - {} - bool operator()(typename call_traits::argument_type>::param_type x) const - { - return !pred(x); - } - private: - typename unary_traits::function_type pred; - }; - - template - unary_negate not1(const Predicate &pred) - { - // The cast is to placate Borland C++Builder in certain circumstances. - // I don't think it should be necessary. - return unary_negate((typename unary_traits::param_type)pred); - } - - template - unary_negate not1(Predicate &pred) - { - return unary_negate(pred); - } - - // -------------------------------------------------------------------------- - // binary_negate, not2 - // -------------------------------------------------------------------------- - template - class binary_negate - : public std::binary_function::first_argument_type, - typename binary_traits::second_argument_type, - bool> - { - public: - explicit binary_negate(typename binary_traits::param_type x) - : - pred(x) - {} - bool operator()(typename call_traits::first_argument_type>::param_type x, - typename call_traits::second_argument_type>::param_type y) const - { - return !pred(x,y); - } - private: - typename binary_traits::function_type pred; - }; - - template - binary_negate not2(const Predicate &pred) - { - // The cast is to placate Borland C++Builder in certain circumstances. - // I don't think it should be necessary. - return binary_negate((typename binary_traits::param_type)pred); - } - - template - binary_negate not2(Predicate &pred) - { - return binary_negate(pred); - } - - // -------------------------------------------------------------------------- - // binder1st, bind1st - // -------------------------------------------------------------------------- - template - class binder1st - : public std::unary_function::second_argument_type, - typename binary_traits::result_type> - { - public: - binder1st(typename binary_traits::param_type x, - typename call_traits::first_argument_type>::param_type y) - : - op(x), value(y) - {} - - typename binary_traits::result_type - operator()(typename call_traits::second_argument_type>::param_type x) const - { - return op(value, x); - } - - protected: - typename binary_traits::function_type op; - typename binary_traits::first_argument_type value; - }; - - template - inline binder1st bind1st(const Operation &op, - typename call_traits< - typename binary_traits::first_argument_type - >::param_type x) - { - // The cast is to placate Borland C++Builder in certain circumstances. - // I don't think it should be necessary. - return binder1st((typename binary_traits::param_type)op, x); - } - - template - inline binder1st bind1st(Operation &op, - typename call_traits< - typename binary_traits::first_argument_type - >::param_type x) - { - return binder1st(op, x); - } - - // -------------------------------------------------------------------------- - // binder2nd, bind2nd - // -------------------------------------------------------------------------- - template - class binder2nd - : public std::unary_function::first_argument_type, - typename binary_traits::result_type> - { - public: - binder2nd(typename binary_traits::param_type x, - typename call_traits::second_argument_type>::param_type y) - : - op(x), value(y) - {} - - typename binary_traits::result_type - operator()(typename call_traits::first_argument_type>::param_type x) const - { - return op(x, value); - } - - protected: - typename binary_traits::function_type op; - typename binary_traits::second_argument_type value; - }; - - template - inline binder2nd bind2nd(const Operation &op, - typename call_traits< - typename binary_traits::second_argument_type - >::param_type x) - { - // The cast is to placate Borland C++Builder in certain circumstances. - // I don't think it should be necessary. - return binder2nd((typename binary_traits::param_type)op, x); - } - - template - inline binder2nd bind2nd(Operation &op, - typename call_traits< - typename binary_traits::second_argument_type - >::param_type x) - { - return binder2nd(op, x); - } - - // -------------------------------------------------------------------------- - // mem_fun, etc - // -------------------------------------------------------------------------- - template - class mem_fun_t : public std::unary_function - { - public: - explicit mem_fun_t(S (T::*p)()) - : - ptr(p) - {} - S operator()(T* p) const - { - return (p->*ptr)(); - } - private: - S (T::*ptr)(); - }; - - template - class mem_fun1_t : public std::binary_function - { - public: - explicit mem_fun1_t(S (T::*p)(A)) - : - ptr(p) - {} - S operator()(T* p, typename call_traits::param_type x) const - { - return (p->*ptr)(x); - } - private: - S (T::*ptr)(A); - }; - - template - class const_mem_fun_t : public std::unary_function - { - public: - explicit const_mem_fun_t(S (T::*p)() const) - : - ptr(p) - {} - S operator()(const T* p) const - { - return (p->*ptr)(); - } - private: - S (T::*ptr)() const; - }; - - template - class const_mem_fun1_t : public std::binary_function - { - public: - explicit const_mem_fun1_t(S (T::*p)(A) const) - : - ptr(p) - {} - S operator()(const T* p, typename call_traits::param_type x) const - { - return (p->*ptr)(x); - } - private: - S (T::*ptr)(A) const; - }; - - template - inline mem_fun_t mem_fun(S (T::*f)()) - { - return mem_fun_t(f); - } - - template - inline mem_fun1_t mem_fun(S (T::*f)(A)) - { - return mem_fun1_t(f); - } - -#ifndef BOOST_NO_POINTER_TO_MEMBER_CONST - template - inline const_mem_fun_t mem_fun(S (T::*f)() const) - { - return const_mem_fun_t(f); - } - - template - inline const_mem_fun1_t mem_fun(S (T::*f)(A) const) - { - return const_mem_fun1_t(f); - } -#endif // BOOST_NO_POINTER_TO_MEMBER_CONST - - // -------------------------------------------------------------------------- - // mem_fun_ref, etc - // -------------------------------------------------------------------------- - template - class mem_fun_ref_t : public std::unary_function - { - public: - explicit mem_fun_ref_t(S (T::*p)()) - : - ptr(p) - {} - S operator()(T& p) const - { - return (p.*ptr)(); - } - private: - S (T::*ptr)(); - }; - - template - class mem_fun1_ref_t : public std::binary_function - { - public: - explicit mem_fun1_ref_t(S (T::*p)(A)) - : - ptr(p) - {} - S operator()(T& p, typename call_traits::param_type x) const - { - return (p.*ptr)(x); - } - private: - S (T::*ptr)(A); - }; - - template - class const_mem_fun_ref_t : public std::unary_function - { - public: - explicit const_mem_fun_ref_t(S (T::*p)() const) - : - ptr(p) - {} - - S operator()(const T &p) const - { - return (p.*ptr)(); - } - private: - S (T::*ptr)() const; - }; - - template - class const_mem_fun1_ref_t : public std::binary_function - { - public: - explicit const_mem_fun1_ref_t(S (T::*p)(A) const) - : - ptr(p) - {} - - S operator()(const T& p, typename call_traits::param_type x) const - { - return (p.*ptr)(x); - } - private: - S (T::*ptr)(A) const; - }; - - template - inline mem_fun_ref_t mem_fun_ref(S (T::*f)()) - { - return mem_fun_ref_t(f); - } - - template - inline mem_fun1_ref_t mem_fun_ref(S (T::*f)(A)) - { - return mem_fun1_ref_t(f); - } - -#ifndef BOOST_NO_POINTER_TO_MEMBER_CONST - template - inline const_mem_fun_ref_t mem_fun_ref(S (T::*f)() const) - { - return const_mem_fun_ref_t(f); - } - - template - inline const_mem_fun1_ref_t mem_fun_ref(S (T::*f)(A) const) - { - return const_mem_fun1_ref_t(f); - } -#endif // BOOST_NO_POINTER_TO_MEMBER_CONST - - // -------------------------------------------------------------------------- - // ptr_fun - // -------------------------------------------------------------------------- - template - class pointer_to_unary_function : public std::unary_function - { - public: - explicit pointer_to_unary_function(Result (*f)(Arg)) - : - func(f) - {} - - Result operator()(typename call_traits::param_type x) const - { - return func(x); - } - - private: - Result (*func)(Arg); - }; - - template - inline pointer_to_unary_function ptr_fun(Result (*f)(Arg)) - { - return pointer_to_unary_function(f); - } - - template - class pointer_to_binary_function : public std::binary_function - { - public: - explicit pointer_to_binary_function(Result (*f)(Arg1, Arg2)) - : - func(f) - {} - - Result operator()(typename call_traits::param_type x, typename call_traits::param_type y) const - { - return func(x,y); - } - - private: - Result (*func)(Arg1, Arg2); - }; - - template - inline pointer_to_binary_function ptr_fun(Result (*f)(Arg1, Arg2)) - { - return pointer_to_binary_function(f); - } -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash.hpp deleted file mode 100644 index 44983f19..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash.hpp +++ /dev/null @@ -1,7 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#include - diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/float_functions.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/float_functions.hpp deleted file mode 100644 index 4b8374d4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/float_functions.hpp +++ /dev/null @@ -1,336 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_FUNCTIONAL_HASH_DETAIL_FLOAT_FUNCTIONS_HPP) -#define BOOST_FUNCTIONAL_HASH_DETAIL_FLOAT_FUNCTIONS_HPP - -#include -#include - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -// Set BOOST_HASH_CONFORMANT_FLOATS to 1 for libraries known to have -// sufficiently good floating point support to not require any -// workarounds. -// -// When set to 0, the library tries to automatically -// use the best available implementation. This normally works well, but -// breaks when ambiguities are created by odd namespacing of the functions. -// -// Note that if this is set to 0, the library should still take full -// advantage of the platform's floating point support. - -#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif defined(__LIBCOMO__) -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER) -// Rogue Wave library: -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif defined(_LIBCPP_VERSION) -// libc++ -# define BOOST_HASH_CONFORMANT_FLOATS 1 -#elif defined(__GLIBCPP__) || defined(__GLIBCXX__) -// GNU libstdc++ 3 -# if defined(__GNUC__) && __GNUC__ >= 4 -# define BOOST_HASH_CONFORMANT_FLOATS 1 -# else -# define BOOST_HASH_CONFORMANT_FLOATS 0 -# endif -#elif defined(__STL_CONFIG_H) -// generic SGI STL -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif defined(__MSL_CPP__) -// MSL standard lib: -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif defined(__IBMCPP__) -// VACPP std lib (probably conformant for much earlier version). -# if __IBMCPP__ >= 1210 -# define BOOST_HASH_CONFORMANT_FLOATS 1 -# else -# define BOOST_HASH_CONFORMANT_FLOATS 0 -# endif -#elif defined(MSIPL_COMPILE_H) -// Modena C++ standard library -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER) -// Dinkumware Library (this has to appear after any possible replacement libraries): -# if _CPPLIB_VER >= 405 -# define BOOST_HASH_CONFORMANT_FLOATS 1 -# else -# define BOOST_HASH_CONFORMANT_FLOATS 0 -# endif -#else -# define BOOST_HASH_CONFORMANT_FLOATS 0 -#endif - -#if BOOST_HASH_CONFORMANT_FLOATS - -// The standard library is known to be compliant, so don't use the -// configuration mechanism. - -namespace boost { - namespace hash_detail { - template - struct call_ldexp { - typedef Float float_type; - inline Float operator()(Float x, int y) const { - return std::ldexp(x, y); - } - }; - - template - struct call_frexp { - typedef Float float_type; - inline Float operator()(Float x, int* y) const { - return std::frexp(x, y); - } - }; - - template - struct select_hash_type - { - typedef Float type; - }; - } -} - -#else // BOOST_HASH_CONFORMANT_FLOATS == 0 - -// The C++ standard requires that the C float functions are overloarded -// for float, double and long double in the std namespace, but some of the older -// library implementations don't support this. On some that don't, the C99 -// float functions (frexpf, frexpl, etc.) are available. -// -// The following tries to automatically detect which are available. - -namespace boost { - namespace hash_detail { - - // Returned by dummy versions of the float functions. - - struct not_found { - // Implicitly convertible to float and long double in order to avoid - // a compile error when the dummy float functions are used. - - inline operator float() const { return 0; } - inline operator long double() const { return 0; } - }; - - // A type for detecting the return type of functions. - - template struct is; - template <> struct is { char x[10]; }; - template <> struct is { char x[20]; }; - template <> struct is { char x[30]; }; - template <> struct is { char x[40]; }; - - // Used to convert the return type of a function to a type for sizeof. - - template is float_type(T); - - // call_ldexp - // - // This will get specialized for float and long double - - template struct call_ldexp - { - typedef double float_type; - - inline double operator()(double a, int b) const - { - using namespace std; - return ldexp(a, b); - } - }; - - // call_frexp - // - // This will get specialized for float and long double - - template struct call_frexp - { - typedef double float_type; - - inline double operator()(double a, int* b) const - { - using namespace std; - return frexp(a, b); - } - }; - } -} - -// A namespace for dummy functions to detect when the actual function we want -// isn't available. ldexpl, ldexpf etc. might be added tby the macros below. -// -// AFAICT these have to be outside of the boost namespace, as if they're in -// the boost namespace they'll always be preferable to any other function -// (since the arguments are built in types, ADL can't be used). - -namespace boost_hash_detect_float_functions { - template boost::hash_detail::not_found ldexp(Float, int); - template boost::hash_detail::not_found frexp(Float, int*); -} - -// Macros for generating specializations of call_ldexp and call_frexp. -// -// check_cpp and check_c99 check if the C++ or C99 functions are available. -// -// Then the call_* functions select an appropriate implementation. -// -// I used c99_func in a few places just to get a unique name. -// -// Important: when using 'using namespace' at namespace level, include as -// little as possible in that namespace, as Visual C++ has an odd bug which -// can cause the namespace to be imported at the global level. This seems to -// happen mainly when there's a template in the same namesapce. - -#define BOOST_HASH_CALL_FLOAT_FUNC(cpp_func, c99_func, type1, type2) \ -namespace boost_hash_detect_float_functions { \ - template \ - boost::hash_detail::not_found c99_func(Float, type2); \ -} \ - \ -namespace boost { \ - namespace hash_detail { \ - namespace c99_func##_detect { \ - using namespace std; \ - using namespace boost_hash_detect_float_functions; \ - \ - struct check { \ - static type1 x; \ - static type2 y; \ - BOOST_STATIC_CONSTANT(bool, cpp = \ - sizeof(float_type(cpp_func(x,y))) \ - == sizeof(is)); \ - BOOST_STATIC_CONSTANT(bool, c99 = \ - sizeof(float_type(c99_func(x,y))) \ - == sizeof(is)); \ - }; \ - } \ - \ - template \ - struct call_c99_##c99_func : \ - boost::hash_detail::call_##cpp_func {}; \ - \ - template <> \ - struct call_c99_##c99_func { \ - typedef type1 float_type; \ - \ - template \ - inline type1 operator()(type1 a, T b) const \ - { \ - using namespace std; \ - return c99_func(a, b); \ - } \ - }; \ - \ - template \ - struct call_cpp_##c99_func : \ - call_c99_##c99_func< \ - ::boost::hash_detail::c99_func##_detect::check::c99 \ - > {}; \ - \ - template <> \ - struct call_cpp_##c99_func { \ - typedef type1 float_type; \ - \ - template \ - inline type1 operator()(type1 a, T b) const \ - { \ - using namespace std; \ - return cpp_func(a, b); \ - } \ - }; \ - \ - template <> \ - struct call_##cpp_func : \ - call_cpp_##c99_func< \ - ::boost::hash_detail::c99_func##_detect::check::cpp \ - > {}; \ - } \ -} - -#define BOOST_HASH_CALL_FLOAT_MACRO(cpp_func, c99_func, type1, type2) \ -namespace boost { \ - namespace hash_detail { \ - \ - template <> \ - struct call_##cpp_func { \ - typedef type1 float_type; \ - inline type1 operator()(type1 x, type2 y) const { \ - return c99_func(x, y); \ - } \ - }; \ - } \ -} - -#if defined(ldexpf) -BOOST_HASH_CALL_FLOAT_MACRO(ldexp, ldexpf, float, int) -#else -BOOST_HASH_CALL_FLOAT_FUNC(ldexp, ldexpf, float, int) -#endif - -#if defined(ldexpl) -BOOST_HASH_CALL_FLOAT_MACRO(ldexp, ldexpl, long double, int) -#else -BOOST_HASH_CALL_FLOAT_FUNC(ldexp, ldexpl, long double, int) -#endif - -#if defined(frexpf) -BOOST_HASH_CALL_FLOAT_MACRO(frexp, frexpf, float, int*) -#else -BOOST_HASH_CALL_FLOAT_FUNC(frexp, frexpf, float, int*) -#endif - -#if defined(frexpl) -BOOST_HASH_CALL_FLOAT_MACRO(frexp, frexpl, long double, int*) -#else -BOOST_HASH_CALL_FLOAT_FUNC(frexp, frexpl, long double, int*) -#endif - -#undef BOOST_HASH_CALL_FLOAT_MACRO -#undef BOOST_HASH_CALL_FLOAT_FUNC - - -namespace boost -{ - namespace hash_detail - { - template - struct select_hash_type_impl { - typedef double type; - }; - - template <> - struct select_hash_type_impl { - typedef float type; - }; - - template <> - struct select_hash_type_impl { - typedef long double type; - }; - - - // select_hash_type - // - // If there is support for a particular floating point type, use that - // otherwise use double (there's always support for double). - - template - struct select_hash_type : select_hash_type_impl< - BOOST_DEDUCED_TYPENAME call_ldexp::float_type, - BOOST_DEDUCED_TYPENAME call_frexp::float_type - > {}; - } -} - -#endif // BOOST_HASH_CONFORMANT_FLOATS - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/hash_float.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/hash_float.hpp deleted file mode 100644 index 7c3de31a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/hash_float.hpp +++ /dev/null @@ -1,271 +0,0 @@ - -// Copyright 2005-2012 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#if !defined(BOOST_FUNCTIONAL_HASH_DETAIL_HASH_FLOAT_HEADER) -#define BOOST_FUNCTIONAL_HASH_DETAIL_HASH_FLOAT_HEADER - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_MSVC) -#pragma warning(push) -#if BOOST_MSVC >= 1400 -#pragma warning(disable:6294) // Ill-defined for-loop: initial condition does - // not satisfy test. Loop body not executed -#endif -#endif - -// Can we use fpclassify? - -// STLport -#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -#define BOOST_HASH_USE_FPCLASSIFY 0 - -// GNU libstdc++ 3 -#elif defined(__GLIBCPP__) || defined(__GLIBCXX__) -# if (defined(__USE_ISOC99) || defined(_GLIBCXX_USE_C99_MATH)) && \ - !(defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) -# define BOOST_HASH_USE_FPCLASSIFY 1 -# else -# define BOOST_HASH_USE_FPCLASSIFY 0 -# endif - -// Everything else -#else -# define BOOST_HASH_USE_FPCLASSIFY 0 -#endif - -namespace boost -{ - namespace hash_detail - { - inline void hash_float_combine(std::size_t& seed, std::size_t value) - { - seed ^= value + (seed<<6) + (seed>>2); - } - - //////////////////////////////////////////////////////////////////////// - // Binary hash function - // - // Only used for floats with known iec559 floats, and certain values in - // numeric_limits - - inline std::size_t hash_binary(char* ptr, std::size_t length) - { - std::size_t seed = 0; - - if (length >= sizeof(std::size_t)) { - seed = *(std::size_t*) ptr; - length -= sizeof(std::size_t); - ptr += sizeof(std::size_t); - - while(length >= sizeof(std::size_t)) { - std::size_t buffer = 0; - std::memcpy(&buffer, ptr, sizeof(std::size_t)); - hash_float_combine(seed, buffer); - length -= sizeof(std::size_t); - ptr += sizeof(std::size_t); - } - } - - if (length > 0) { - std::size_t buffer = 0; - std::memcpy(&buffer, ptr, length); - hash_float_combine(seed, buffer); - } - - return seed; - } - - template - struct enable_binary_hash - { - BOOST_STATIC_CONSTANT(bool, value = - std::numeric_limits::is_iec559 && - std::numeric_limits::digits == digits && - std::numeric_limits::radix == 2 && - std::numeric_limits::max_exponent == max_exponent); - }; - - template - inline std::size_t float_hash_impl(Float v, - BOOST_DEDUCED_TYPENAME boost::enable_if_c< - enable_binary_hash::value, - std::size_t>::type) - { - return hash_binary((char*) &v, 4); - } - - - template - inline std::size_t float_hash_impl(Float v, - BOOST_DEDUCED_TYPENAME boost::enable_if_c< - enable_binary_hash::value, - std::size_t>::type) - { - return hash_binary((char*) &v, 8); - } - - template - inline std::size_t float_hash_impl(Float v, - BOOST_DEDUCED_TYPENAME boost::enable_if_c< - enable_binary_hash::value, - std::size_t>::type) - { - return hash_binary((char*) &v, 10); - } - - template - inline std::size_t float_hash_impl(Float v, - BOOST_DEDUCED_TYPENAME boost::enable_if_c< - enable_binary_hash::value, - std::size_t>::type) - { - return hash_binary((char*) &v, 16); - } - - //////////////////////////////////////////////////////////////////////// - // Portable hash function - // - // Used as a fallback when the binary hash function isn't supported. - - template - inline std::size_t float_hash_impl2(T v) - { - boost::hash_detail::call_frexp frexp; - boost::hash_detail::call_ldexp ldexp; - - int exp = 0; - - v = frexp(v, &exp); - - // A postive value is easier to hash, so combine the - // sign with the exponent and use the absolute value. - if(v < 0) { - v = -v; - exp += limits::max_exponent - - limits::min_exponent; - } - - v = ldexp(v, limits::digits); - std::size_t seed = static_cast(v); - v -= static_cast(seed); - - // ceiling(digits(T) * log2(radix(T))/ digits(size_t)) - 1; - std::size_t const length - = (limits::digits * - boost::static_log2::radix>::value - + limits::digits - 1) - / limits::digits; - - for(std::size_t i = 0; i != length; ++i) - { - v = ldexp(v, limits::digits); - std::size_t part = static_cast(v); - v -= static_cast(part); - hash_float_combine(seed, part); - } - - hash_float_combine(seed, exp); - - return seed; - } - -#if !defined(BOOST_HASH_DETAIL_TEST_WITHOUT_GENERIC) - template - inline std::size_t float_hash_impl(T v, ...) - { - typedef BOOST_DEDUCED_TYPENAME select_hash_type::type type; - return float_hash_impl2(static_cast(v)); - } -#endif - } -} - -#if BOOST_HASH_USE_FPCLASSIFY - -#include - -namespace boost -{ - namespace hash_detail - { - template - inline std::size_t float_hash_value(T v) - { -#if defined(fpclassify) - switch (fpclassify(v)) -#elif BOOST_HASH_CONFORMANT_FLOATS - switch (std::fpclassify(v)) -#else - using namespace std; - switch (fpclassify(v)) -#endif - { - case FP_ZERO: - return 0; - case FP_INFINITE: - return (std::size_t)(v > 0 ? -1 : -2); - case FP_NAN: - return (std::size_t)(-3); - case FP_NORMAL: - case FP_SUBNORMAL: - return float_hash_impl(v, 0); - default: - BOOST_ASSERT(0); - return 0; - } - } - } -} - -#else // !BOOST_HASH_USE_FPCLASSIFY - -namespace boost -{ - namespace hash_detail - { - template - inline bool is_zero(T v) - { -#if !defined(__GNUC__) - return v == 0; -#else - // GCC's '-Wfloat-equal' will complain about comparing - // v to 0, but because it disables warnings for system - // headers it won't complain if you use std::equal_to to - // compare with 0. Resulting in this silliness: - return std::equal_to()(v, 0); -#endif - } - - template - inline std::size_t float_hash_value(T v) - { - return boost::hash_detail::is_zero(v) ? 0 : float_hash_impl(v, 0); - } - } -} - -#endif // BOOST_HASH_USE_FPCLASSIFY - -#undef BOOST_HASH_USE_FPCLASSIFY - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/limits.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/limits.hpp deleted file mode 100644 index f5b520ea..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/detail/limits.hpp +++ /dev/null @@ -1,61 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// On some platforms std::limits gives incorrect values for long double. -// This tries to work around them. - -#if !defined(BOOST_FUNCTIONAL_HASH_DETAIL_LIMITS_HEADER) -#define BOOST_FUNCTIONAL_HASH_DETAIL_LIMITS_HEADER - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include - -// On OpenBSD, numeric_limits is not reliable for long doubles, but -// the macros defined in are and support long double when STLport -// doesn't. - -#if defined(__OpenBSD__) || defined(_STLP_NO_LONG_DOUBLE) -#include -#endif - -namespace boost -{ - namespace hash_detail - { - template - struct limits : std::numeric_limits {}; - -#if defined(__OpenBSD__) || defined(_STLP_NO_LONG_DOUBLE) - template <> - struct limits - : std::numeric_limits - { - static long double epsilon() { - return LDBL_EPSILON; - } - - static long double (max)() { - return LDBL_MAX; - } - - static long double (min)() { - return LDBL_MIN; - } - - BOOST_STATIC_CONSTANT(int, digits = LDBL_MANT_DIG); - BOOST_STATIC_CONSTANT(int, max_exponent = LDBL_MAX_EXP); - BOOST_STATIC_CONSTANT(int, min_exponent = LDBL_MIN_EXP); -#if defined(_STLP_NO_LONG_DOUBLE) - BOOST_STATIC_CONSTANT(int, radix = FLT_RADIX); -#endif - }; -#endif // __OpenBSD__ - } -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/extensions.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/extensions.hpp deleted file mode 100644 index 998c08e4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/extensions.hpp +++ /dev/null @@ -1,379 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Based on Peter Dimov's proposal -// http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf -// issue 6.18. - -// This implements the extensions to the standard. -// It's undocumented, so you shouldn't use it.... - -#if !defined(BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP) -#define BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP - -#include -#include -#include -#include -#include -#include - -#if !defined(BOOST_NO_CXX11_HDR_ARRAY) -# include -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) -# include -#endif - -#if !defined(BOOST_NO_CXX11_HDR_MEMORY) -# include -#endif - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#if defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) -#include -#endif - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -#include -#endif - -namespace boost -{ - template - std::size_t hash_value(std::pair const&); - template - std::size_t hash_value(std::vector const&); - template - std::size_t hash_value(std::list const& v); - template - std::size_t hash_value(std::deque const& v); - template - std::size_t hash_value(std::set const& v); - template - std::size_t hash_value(std::multiset const& v); - template - std::size_t hash_value(std::map const& v); - template - std::size_t hash_value(std::multimap const& v); - - template - std::size_t hash_value(std::complex const&); - - template - std::size_t hash_value(std::pair const& v) - { - std::size_t seed = 0; - boost::hash_combine(seed, v.first); - boost::hash_combine(seed, v.second); - return seed; - } - - template - std::size_t hash_value(std::vector const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::list const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::deque const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::set const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::multiset const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::map const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::multimap const& v) - { - return boost::hash_range(v.begin(), v.end()); - } - - template - std::size_t hash_value(std::complex const& v) - { - boost::hash hasher; - std::size_t seed = hasher(v.imag()); - seed ^= hasher(v.real()) + (seed<<6) + (seed>>2); - return seed; - } - -#if !defined(BOOST_NO_CXX11_HDR_ARRAY) - template - std::size_t hash_value(std::array const& v) - { - return boost::hash_range(v.begin(), v.end()); - } -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TUPLE) - namespace hash_detail { - template - inline typename boost::enable_if_c<(I == std::tuple_size::value), - void>::type - hash_combine_tuple(std::size_t&, T const&) - { - } - - template - inline typename boost::enable_if_c<(I < std::tuple_size::value), - void>::type - hash_combine_tuple(std::size_t& seed, T const& v) - { - boost::hash_combine(seed, std::get(v)); - boost::hash_detail::hash_combine_tuple(seed, v); - } - - template - inline std::size_t hash_tuple(T const& v) - { - std::size_t seed = 0; - boost::hash_detail::hash_combine_tuple<0>(seed, v); - return seed; - } - } - -#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) - template - inline std::size_t hash_value(std::tuple const& v) - { - return boost::hash_detail::hash_tuple(v); - } -#else - - inline std::size_t hash_value(std::tuple<> const& v) - { - return boost::hash_detail::hash_tuple(v); - } - -# define BOOST_HASH_TUPLE_F(z, n, _) \ - template< \ - BOOST_PP_ENUM_PARAMS_Z(z, n, typename A) \ - > \ - inline std::size_t hash_value(std::tuple< \ - BOOST_PP_ENUM_PARAMS_Z(z, n, A) \ - > const& v) \ - { \ - return boost::hash_detail::hash_tuple(v); \ - } - - BOOST_PP_REPEAT_FROM_TO(1, 11, BOOST_HASH_TUPLE_F, _) -# undef BOOST_HASH_TUPLE_F -#endif - -#endif - -#if !defined(BOOST_NO_CXX11_SMART_PTR) - template - inline std::size_t hash_value(std::shared_ptr const& x) { - return boost::hash_value(x.get()); - } - - template - inline std::size_t hash_value(std::unique_ptr const& x) { - return boost::hash_value(x.get()); - } -#endif - - // - // call_hash_impl - // - - // On compilers without function template ordering, this deals with arrays. - -#if defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - namespace hash_detail - { - template - struct call_hash_impl - { - template - struct inner - { - static std::size_t call(T const& v) - { - using namespace boost; - return hash_value(v); - } - }; - }; - - template <> - struct call_hash_impl - { - template - struct inner - { -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) - static std::size_t call(Array const& v) -#else - static std::size_t call(Array& v) -#endif - { - const int size = sizeof(v) / sizeof(*v); - return boost::hash_range(v, v + size); - } - }; - }; - - template - struct call_hash - : public call_hash_impl::value> - ::BOOST_NESTED_TEMPLATE inner - { - }; - } -#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING - - // - // boost::hash - // - - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - - template struct hash - : std::unary_function - { -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - std::size_t operator()(T const& val) const - { - return hash_value(val); - } -#else - std::size_t operator()(T const& val) const - { - return hash_detail::call_hash::call(val); - } -#endif - }; - -#if BOOST_WORKAROUND(__DMC__, <= 0x848) - template struct hash - : std::unary_function - { - std::size_t operator()(const T* val) const - { - return boost::hash_range(val, val+n); - } - }; -#endif - -#else // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - - // On compilers without partial specialization, boost::hash - // has already been declared to deal with pointers, so just - // need to supply the non-pointer version of hash_impl. - - namespace hash_detail - { - template - struct hash_impl; - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) - - template <> - struct hash_impl - { - template - struct inner - : std::unary_function - { -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - std::size_t operator()(T const& val) const - { - return hash_value(val); - } -#else - std::size_t operator()(T const& val) const - { - return hash_detail::call_hash::call(val); - } -#endif - }; - }; - -#else // Visual C++ 6.5 - - // Visual C++ 6.5 has problems with nested member functions and - // applying const to const types in templates. So we get this: - - template - struct hash_impl_msvc - { - template - struct inner - : public std::unary_function - { - std::size_t operator()(T const& val) const - { - return hash_detail::call_hash::call(val); - } - - std::size_t operator()(T& val) const - { - return hash_detail::call_hash::call(val); - } - }; - }; - - template <> - struct hash_impl_msvc - { - template - struct inner - : public std::unary_function - { - std::size_t operator()(T& val) const - { - return hash_detail::call_hash::call(val); - } - }; - }; - - template - struct hash_impl_msvc2 - : public hash_impl_msvc::value> - ::BOOST_NESTED_TEMPLATE inner {}; - - template <> - struct hash_impl - { - template - struct inner : public hash_impl_msvc2 {}; - }; - -#endif // Visual C++ 6.5 - } -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash.hpp deleted file mode 100644 index 0adf9c90..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash.hpp +++ /dev/null @@ -1,541 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Based on Peter Dimov's proposal -// http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf -// issue 6.18. - -#if !defined(BOOST_FUNCTIONAL_HASH_HASH_HPP) -#define BOOST_FUNCTIONAL_HASH_HASH_HPP - -#include -#include -#include -#include -#include -#include -#include -#include - -#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -#include -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) -#include -#endif - -#if defined(BOOST_MSVC) -#pragma warning(push) -#pragma warning(disable:6295) // Ill-defined for-loop : 'unsigned int' values - // are always of range '0' to '4294967295'. - // Loop executes infinitely. -#endif - -#if BOOST_WORKAROUND(__GNUC__, < 3) \ - && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) -#define BOOST_HASH_CHAR_TRAITS string_char_traits -#else -#define BOOST_HASH_CHAR_TRAITS char_traits -#endif - -namespace boost -{ - namespace hash_detail - { - struct enable_hash_value { typedef std::size_t type; }; - - template struct basic_numbers {}; - template struct long_numbers; - template struct ulong_numbers; - template struct float_numbers {}; - - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; - -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) - template <> struct basic_numbers : - boost::hash_detail::enable_hash_value {}; -#endif - - // long_numbers is defined like this to allow for separate - // specialization for long_long and int128_type, in case - // they conflict. - template struct long_numbers2 {}; - template struct ulong_numbers2 {}; - template struct long_numbers : long_numbers2 {}; - template struct ulong_numbers : ulong_numbers2 {}; - -#if !defined(BOOST_NO_LONG_LONG) - template <> struct long_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct ulong_numbers : - boost::hash_detail::enable_hash_value {}; -#endif - -#if defined(BOOST_HAS_INT128) - template <> struct long_numbers2 : - boost::hash_detail::enable_hash_value {}; - template <> struct ulong_numbers2 : - boost::hash_detail::enable_hash_value {}; -#endif - - template <> struct float_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct float_numbers : - boost::hash_detail::enable_hash_value {}; - template <> struct float_numbers : - boost::hash_detail::enable_hash_value {}; - } - - template - typename boost::hash_detail::basic_numbers::type hash_value(T); - template - typename boost::hash_detail::long_numbers::type hash_value(T); - template - typename boost::hash_detail::ulong_numbers::type hash_value(T); - - template - typename boost::enable_if, std::size_t>::type - hash_value(T); - -#if !BOOST_WORKAROUND(__DMC__, <= 0x848) - template std::size_t hash_value(T* const&); -#else - template std::size_t hash_value(T*); -#endif - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - template< class T, unsigned N > - std::size_t hash_value(const T (&x)[N]); - - template< class T, unsigned N > - std::size_t hash_value(T (&x)[N]); -#endif - - template - std::size_t hash_value( - std::basic_string, A> const&); - - template - typename boost::hash_detail::float_numbers::type hash_value(T); - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - std::size_t hash_value(std::type_index); -#endif - - // Implementation - - namespace hash_detail - { - template - inline std::size_t hash_value_signed(T val) - { - const int size_t_bits = std::numeric_limits::digits; - // ceiling(std::numeric_limits::digits / size_t_bits) - 1 - const int length = (std::numeric_limits::digits - 1) - / size_t_bits; - - std::size_t seed = 0; - T positive = val < 0 ? -1 - val : val; - - // Hopefully, this loop can be unrolled. - for(unsigned int i = length * size_t_bits; i > 0; i -= size_t_bits) - { - seed ^= (std::size_t) (positive >> i) + (seed<<6) + (seed>>2); - } - seed ^= (std::size_t) val + (seed<<6) + (seed>>2); - - return seed; - } - - template - inline std::size_t hash_value_unsigned(T val) - { - const int size_t_bits = std::numeric_limits::digits; - // ceiling(std::numeric_limits::digits / size_t_bits) - 1 - const int length = (std::numeric_limits::digits - 1) - / size_t_bits; - - std::size_t seed = 0; - - // Hopefully, this loop can be unrolled. - for(unsigned int i = length * size_t_bits; i > 0; i -= size_t_bits) - { - seed ^= (std::size_t) (val >> i) + (seed<<6) + (seed>>2); - } - seed ^= (std::size_t) val + (seed<<6) + (seed>>2); - - return seed; - } - } - - template - typename boost::hash_detail::basic_numbers::type hash_value(T v) - { - return static_cast(v); - } - - template - typename boost::hash_detail::long_numbers::type hash_value(T v) - { - return hash_detail::hash_value_signed(v); - } - - template - typename boost::hash_detail::ulong_numbers::type hash_value(T v) - { - return hash_detail::hash_value_unsigned(v); - } - - template - typename boost::enable_if, std::size_t>::type - hash_value(T v) - { - return static_cast(v); - } - - // Implementation by Alberto Barbati and Dave Harris. -#if !BOOST_WORKAROUND(__DMC__, <= 0x848) - template std::size_t hash_value(T* const& v) -#else - template std::size_t hash_value(T* v) -#endif - { -#if defined(__VMS) && __INITIAL_POINTER_SIZE == 64 - // for some reason ptrdiff_t on OpenVMS compiler with - // 64 bit is not 64 bit !!! - std::size_t x = static_cast( - reinterpret_cast(v)); -#else - std::size_t x = static_cast( - reinterpret_cast(v)); -#endif - return x + (x >> 3); - } - -#if defined(BOOST_MSVC) -#pragma warning(push) -#if BOOST_MSVC <= 1400 -#pragma warning(disable:4267) // 'argument' : conversion from 'size_t' to - // 'unsigned int', possible loss of data - // A misguided attempt to detect 64-bit - // incompatability. -#endif -#endif - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - template - inline void hash_combine(std::size_t& seed, T& v) -#else - template - inline void hash_combine(std::size_t& seed, T const& v) -#endif - { - boost::hash hasher; - seed ^= hasher(v) + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - - template - inline std::size_t hash_range(It first, It last) - { - std::size_t seed = 0; - - for(; first != last; ++first) - { - hash_combine(seed, *first); - } - - return seed; - } - - template - inline void hash_range(std::size_t& seed, It first, It last) - { - for(; first != last; ++first) - { - hash_combine(seed, *first); - } - } - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x551)) - template - inline std::size_t hash_range(T* first, T* last) - { - std::size_t seed = 0; - - for(; first != last; ++first) - { - boost::hash hasher; - seed ^= hasher(*first) + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - - return seed; - } - - template - inline void hash_range(std::size_t& seed, T* first, T* last) - { - for(; first != last; ++first) - { - boost::hash hasher; - seed ^= hasher(*first) + 0x9e3779b9 + (seed<<6) + (seed>>2); - } - } -#endif - -#if !defined(BOOST_NO_FUNCTION_TEMPLATE_ORDERING) - template< class T, unsigned N > - inline std::size_t hash_value(const T (&x)[N]) - { - return hash_range(x, x + N); - } - - template< class T, unsigned N > - inline std::size_t hash_value(T (&x)[N]) - { - return hash_range(x, x + N); - } -#endif - - template - inline std::size_t hash_value( - std::basic_string, A> const& v) - { - return hash_range(v.begin(), v.end()); - } - - template - typename boost::hash_detail::float_numbers::type hash_value(T v) - { - return boost::hash_detail::float_hash_value(v); - } - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - inline std::size_t hash_value(std::type_index v) - { - return v.hash_code(); - } -#endif - - // - // boost::hash - // - - // Define the specializations required by the standard. The general purpose - // boost::hash is defined later in extensions.hpp if - // BOOST_HASH_NO_EXTENSIONS is not defined. - - // BOOST_HASH_SPECIALIZE - define a specialization for a type which is - // passed by copy. - // - // BOOST_HASH_SPECIALIZE_REF - define a specialization for a type which is - // passed by copy. - // - // These are undefined later. - -#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) -#define BOOST_HASH_SPECIALIZE(type) \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(type v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; - -#define BOOST_HASH_SPECIALIZE_REF(type) \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(type const& v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; -#else -#define BOOST_HASH_SPECIALIZE(type) \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(type v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; \ - \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(const type v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; - -#define BOOST_HASH_SPECIALIZE_REF(type) \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(type const& v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; \ - \ - template <> struct hash \ - : public std::unary_function \ - { \ - std::size_t operator()(type const& v) const \ - { \ - return boost::hash_value(v); \ - } \ - }; -#endif - - BOOST_HASH_SPECIALIZE(bool) - BOOST_HASH_SPECIALIZE(char) - BOOST_HASH_SPECIALIZE(signed char) - BOOST_HASH_SPECIALIZE(unsigned char) -#if !defined(BOOST_NO_INTRINSIC_WCHAR_T) - BOOST_HASH_SPECIALIZE(wchar_t) -#endif - BOOST_HASH_SPECIALIZE(short) - BOOST_HASH_SPECIALIZE(unsigned short) - BOOST_HASH_SPECIALIZE(int) - BOOST_HASH_SPECIALIZE(unsigned int) - BOOST_HASH_SPECIALIZE(long) - BOOST_HASH_SPECIALIZE(unsigned long) - - BOOST_HASH_SPECIALIZE(float) - BOOST_HASH_SPECIALIZE(double) - BOOST_HASH_SPECIALIZE(long double) - - BOOST_HASH_SPECIALIZE_REF(std::string) -#if !defined(BOOST_NO_STD_WSTRING) - BOOST_HASH_SPECIALIZE_REF(std::wstring) -#endif - -#if !defined(BOOST_NO_LONG_LONG) - BOOST_HASH_SPECIALIZE(boost::long_long_type) - BOOST_HASH_SPECIALIZE(boost::ulong_long_type) -#endif - -#if defined(BOOST_HAS_INT128) - BOOST_HASH_SPECIALIZE(boost::int128_type) - BOOST_HASH_SPECIALIZE(boost::uint128_type) -#endif - -#if !defined(BOOST_NO_CXX11_HDR_TYPEINDEX) - BOOST_HASH_SPECIALIZE(std::type_index) -#endif - -#undef BOOST_HASH_SPECIALIZE -#undef BOOST_HASH_SPECIALIZE_REF - -// Specializing boost::hash for pointers. - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) - - template - struct hash - : public std::unary_function - { - std::size_t operator()(T* v) const - { -#if !BOOST_WORKAROUND(__SUNPRO_CC, <= 0x590) - return boost::hash_value(v); -#else - std::size_t x = static_cast( - reinterpret_cast(v)); - - return x + (x >> 3); -#endif - } - }; - -#else - - // For compilers without partial specialization, we define a - // boost::hash for all remaining types. But hash_impl is only defined - // for pointers in 'extensions.hpp' - so when BOOST_HASH_NO_EXTENSIONS - // is defined there will still be a compile error for types not supported - // in the standard. - - namespace hash_detail - { - template - struct hash_impl; - - template <> - struct hash_impl - { - template - struct inner - : public std::unary_function - { - std::size_t operator()(T val) const - { -#if !BOOST_WORKAROUND(__SUNPRO_CC, <= 590) - return boost::hash_value(val); -#else - std::size_t x = static_cast( - reinterpret_cast(val)); - - return x + (x >> 3); -#endif - } - }; - }; - } - - template struct hash - : public boost::hash_detail::hash_impl::value> - ::BOOST_NESTED_TEMPLATE inner - { - }; - -#endif -} - -#undef BOOST_HASH_CHAR_TRAITS - -#if defined(BOOST_MSVC) -#pragma warning(pop) -#endif - -#endif // BOOST_FUNCTIONAL_HASH_HASH_HPP - -// Include this outside of the include guards in case the file is included -// twice - once with BOOST_HASH_NO_EXTENSIONS defined, and then with it -// undefined. - -#if !defined(BOOST_HASH_NO_EXTENSIONS) \ - && !defined(BOOST_FUNCTIONAL_HASH_EXTENSIONS_HPP) -#include -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash_fwd.hpp deleted file mode 100644 index 1d51b07f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash/hash_fwd.hpp +++ /dev/null @@ -1,40 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -// Based on Peter Dimov's proposal -// http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf -// issue 6.18. - -#if !defined(BOOST_FUNCTIONAL_HASH_FWD_HPP) -#define BOOST_FUNCTIONAL_HASH_FWD_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1020) -# pragma once -#endif - -#include -#include -#include - -namespace boost -{ - template struct hash; - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) - template void hash_combine(std::size_t& seed, T& v); -#else - template void hash_combine(std::size_t& seed, T const& v); -#endif - - template std::size_t hash_range(It, It); - template void hash_range(std::size_t&, It, It); - -#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x551)) - template inline std::size_t hash_range(T*, T*); - template inline void hash_range(std::size_t&, T*, T*); -#endif -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/functional/hash_fwd.hpp b/third_party/ycmd/cpp/BoostParts/boost/functional/hash_fwd.hpp deleted file mode 100644 index b6409886..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/functional/hash_fwd.hpp +++ /dev/null @@ -1,7 +0,0 @@ - -// Copyright 2005-2009 Daniel James. -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) - -#include - diff --git a/third_party/ycmd/cpp/BoostParts/boost/get_pointer.hpp b/third_party/ycmd/cpp/BoostParts/boost/get_pointer.hpp deleted file mode 100644 index b27b98a6..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/get_pointer.hpp +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright Peter Dimov and David Abrahams 2002. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -#ifndef GET_POINTER_DWA20021219_HPP -#define GET_POINTER_DWA20021219_HPP - -#include - -// In order to avoid circular dependencies with Boost.TR1 -// we make sure that our include of doesn't try to -// pull in the TR1 headers: that's why we use this header -// rather than including directly: -#include // std::auto_ptr - -namespace boost { - -// get_pointer(p) extracts a ->* capable pointer from p - -template T * get_pointer(T * p) -{ - return p; -} - -// get_pointer(shared_ptr const & p) has been moved to shared_ptr.hpp - -template T * get_pointer(std::auto_ptr const& p) -{ - return p.get(); -} - -#if !defined( BOOST_NO_CXX11_SMART_PTR ) - -template T * get_pointer( std::unique_ptr const& p ) -{ - return p.get(); -} - -template T * get_pointer( std::shared_ptr const& p ) -{ - return p.get(); -} - -#endif - -} // namespace boost - -#endif // GET_POINTER_DWA20021219_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_iterator.hpp deleted file mode 100644 index d5006064..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_iterator.hpp +++ /dev/null @@ -1,102 +0,0 @@ -//======================================================================= -// Copyright 2002 Indiana University. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_ADJACENCY_ITERATOR_HPP -#define BOOST_ADJACENCY_ITERATOR_HPP - -#include -#include - -namespace boost -{ - - template - struct adjacency_iterator - : iterator_adaptor< - adjacency_iterator - , OutEdgeIter - , Vertex - , use_default - , Vertex - , Difference - > - { - typedef iterator_adaptor< - adjacency_iterator - , OutEdgeIter - , Vertex - , use_default - , Vertex - , Difference - > super_t; - - inline adjacency_iterator() {} - inline adjacency_iterator(OutEdgeIter const& i, const Graph* g) : super_t(i), m_g(g) { } - - inline Vertex - dereference() const - { return target(*this->base(), *m_g); } - - const Graph* m_g; - }; - - template ::vertex_descriptor, - class OutEdgeIter=typename graph_traits::out_edge_iterator> - class adjacency_iterator_generator - { - typedef typename boost::detail::iterator_traits - ::difference_type difference_type; - public: - typedef adjacency_iterator type; - }; - - template - struct inv_adjacency_iterator - : iterator_adaptor< - inv_adjacency_iterator - , InEdgeIter - , Vertex - , use_default - , Vertex - , Difference - > - { - typedef iterator_adaptor< - inv_adjacency_iterator - , InEdgeIter - , Vertex - , use_default - , Vertex - , Difference - > super_t; - - inline inv_adjacency_iterator() { } - inline inv_adjacency_iterator(InEdgeIter const& i, const Graph* g) : super_t(i), m_g(g) { } - - inline Vertex - dereference() const - { return source(*this->base(), *m_g); } - - const Graph* m_g; - }; - - template ::vertex_descriptor, - class InEdgeIter = typename graph_traits::in_edge_iterator> - class inv_adjacency_iterator_generator { - typedef typename boost::detail::iterator_traits - ::difference_type difference_type; - public: - typedef inv_adjacency_iterator type; - }; - -} // namespace boost - -#endif // BOOST_DETAIL_ADJACENCY_ITERATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_list.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_list.hpp deleted file mode 100644 index 6738fa22..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/adjacency_list.hpp +++ /dev/null @@ -1,458 +0,0 @@ -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Copyright 2010 Thomas Claveirole -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek, Thomas Claveirole -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_ADJACENCY_LIST_HPP -#define BOOST_GRAPH_ADJACENCY_LIST_HPP - - -#include - -#include -#include -#include - -#include - -#if !defined BOOST_NO_SLIST -# ifdef BOOST_SLIST_HEADER -# include BOOST_SLIST_HEADER -# else -# include -# endif -#endif - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - - //=========================================================================== - // Selectors for the VertexList and EdgeList template parameters of - // adjacency_list, and the container_gen traits class which is used - // to map the selectors to the container type used to implement the - // graph. - -#if !defined BOOST_NO_SLIST - struct slistS {}; -#endif - - struct vecS { }; - struct listS { }; - struct setS { }; - struct mapS { }; - struct multisetS { }; - struct multimapS { }; - struct hash_setS { }; - struct hash_mapS { }; - struct hash_multisetS { }; - struct hash_multimapS { }; - - template - struct container_gen { }; - - template - struct container_gen { - typedef std::list type; - }; -#if !defined BOOST_NO_SLIST - template - struct container_gen { - typedef BOOST_STD_EXTENSION_NAMESPACE::slist type; - }; -#endif - template - struct container_gen { - typedef std::vector type; - }; - - template - struct container_gen { - typedef std::set type; - }; - - template - struct container_gen { - typedef std::set type; - }; - - template - struct container_gen { - typedef std::multiset type; - }; - - template - struct container_gen { - typedef std::multiset type; - }; - - template - struct container_gen { - typedef boost::unordered_set type; - }; - - template - struct container_gen { - typedef boost::unordered_set type; - }; - - template - struct container_gen { - typedef boost::unordered_multiset type; - }; - - template - struct container_gen { - typedef boost::unordered_multiset type; - }; - - template - struct parallel_edge_traits { }; - - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; }; - - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; }; - -#if !defined BOOST_NO_SLIST - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; }; -#endif - - template <> - struct parallel_edge_traits { - typedef disallow_parallel_edge_tag type; }; - - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; }; - - template <> - struct parallel_edge_traits { - typedef disallow_parallel_edge_tag type; - }; - - // mapS is obsolete, replaced with setS - template <> - struct parallel_edge_traits { - typedef disallow_parallel_edge_tag type; }; - - template <> - struct parallel_edge_traits { - typedef disallow_parallel_edge_tag type; - }; - - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; - }; - - template <> - struct parallel_edge_traits { - typedef allow_parallel_edge_tag type; - }; - - namespace detail { - template struct is_random_access { - enum { value = false}; - typedef mpl::false_ type; - }; - template <> - struct is_random_access { - enum { value = true }; - typedef mpl::true_ type; - }; - - } // namespace detail - - template struct is_distributed_selector: mpl::false_ {}; - - - //=========================================================================== - // The adjacency_list_traits class, which provides a way to access - // some of the associated types of an adjacency_list type without - // having to first create the adjacency_list type. This is useful - // when trying to create interior vertex or edge properties who's - // value type is a vertex or edge descriptor. - - template - struct adjacency_list_traits - { - typedef typename detail::is_random_access::type - is_rand_access; - typedef typename DirectedS::is_bidir_t is_bidir; - typedef typename DirectedS::is_directed_t is_directed; - - typedef typename mpl::if_::type - >::type directed_category; - - typedef typename parallel_edge_traits::type - edge_parallel_category; - - typedef std::size_t vertices_size_type; - typedef void* vertex_ptr; - typedef typename mpl::if_::type vertex_descriptor; - typedef detail::edge_desc_impl - edge_descriptor; - - private: - // Logic to figure out the edges_size_type - struct dummy {}; - typedef typename container_gen::type EdgeContainer; - typedef typename DirectedS::is_bidir_t BidirectionalT; - typedef typename DirectedS::is_directed_t DirectedT; - typedef typename mpl::and_::type >::type on_edge_storage; - public: - typedef typename mpl::if_::type edges_size_type; - - }; - -} // namespace boost - -#include - -namespace boost { - - //=========================================================================== - // The adjacency_list class. - // - - template - class adjacency_list - : public detail::adj_list_gen< - adjacency_list, - VertexListS, OutEdgeListS, DirectedS, - VertexProperty, EdgeProperty, - GraphProperty, EdgeListS>::type, - // Support for named vertices - public graph::maybe_named_graph< - adjacency_list, - typename adjacency_list_traits::vertex_descriptor, - VertexProperty> - { - public: - typedef GraphProperty graph_property_type; - typedef typename lookup_one_property::type graph_bundled; - - typedef VertexProperty vertex_property_type; - typedef typename lookup_one_property::type vertex_bundled; - - typedef EdgeProperty edge_property_type; - typedef typename lookup_one_property::type edge_bundled; - - private: - typedef adjacency_list self; - typedef typename detail::adj_list_gen< - self, VertexListS, OutEdgeListS, DirectedS, - vertex_property_type, edge_property_type, GraphProperty, EdgeListS - >::type Base; - - public: - typedef typename Base::stored_vertex stored_vertex; - typedef typename Base::vertices_size_type vertices_size_type; - typedef typename Base::edges_size_type edges_size_type; - typedef typename Base::degree_size_type degree_size_type; - typedef typename Base::vertex_descriptor vertex_descriptor; - typedef typename Base::edge_descriptor edge_descriptor; - typedef OutEdgeListS out_edge_list_selector; - typedef VertexListS vertex_list_selector; - typedef DirectedS directed_selector; - typedef EdgeListS edge_list_selector; - - - adjacency_list(const GraphProperty& p = GraphProperty()) - : m_property(new graph_property_type(p)) - { } - - adjacency_list(const adjacency_list& x) - : Base(x), m_property(new graph_property_type(*x.m_property)) - { } - - adjacency_list& operator=(const adjacency_list& x) { - // TBD: probably should give the strong guarantee - if (&x != this) { - Base::operator=(x); - - // Copy/swap the ptr since we can't just assign it... - property_ptr p(new graph_property_type(*x.m_property)); - m_property.swap(p); - } - return *this; - } - - // Required by Mutable Graph - adjacency_list(vertices_size_type num_vertices, - const GraphProperty& p = GraphProperty()) - : Base(num_vertices), m_property(new graph_property_type(p)) - { } - -#if !defined(BOOST_MSVC) || BOOST_MSVC >= 1300 - // Required by Iterator Constructible Graph - template - adjacency_list(EdgeIterator first, EdgeIterator last, - vertices_size_type n, - edges_size_type = 0, - const GraphProperty& p = GraphProperty()) - : Base(n, first, last), m_property(new graph_property_type(p)) - { } - - template - adjacency_list(EdgeIterator first, EdgeIterator last, - EdgePropertyIterator ep_iter, - vertices_size_type n, - edges_size_type = 0, - const GraphProperty& p = GraphProperty()) - : Base(n, first, last, ep_iter), m_property(new graph_property_type(p)) - { } -#endif - - void swap(adjacency_list& x) { - // Is there a more efficient way to do this? - adjacency_list tmp(x); - x = *this; - *this = tmp; - } - - void clear() - { - this->clearing_graph(); - Base::clear(); - } - -#ifndef BOOST_GRAPH_NO_BUNDLED_PROPERTIES - // Directly access a vertex or edge bundle - vertex_bundled& operator[](vertex_descriptor v) - { return get(vertex_bundle, *this)[v]; } - - const vertex_bundled& operator[](vertex_descriptor v) const - { return get(vertex_bundle, *this)[v]; } - - edge_bundled& operator[](edge_descriptor e) - { return get(edge_bundle, *this)[e]; } - - const edge_bundled& operator[](edge_descriptor e) const - { return get(edge_bundle, *this)[e]; } - - graph_bundled& operator[](graph_bundle_t) - { return get_property(*this); } - - graph_bundled const& operator[](graph_bundle_t) const - { return get_property(*this); } -#endif - - // protected: (would be protected if friends were more portable) - typedef scoped_ptr property_ptr; - property_ptr m_property; - }; - -#define ADJLIST_PARAMS \ - typename OEL, typename VL, typename D, typename VP, typename EP, \ - typename GP, typename EL -#define ADJLIST adjacency_list - - template - inline void set_property(ADJLIST& g, Tag tag, Value const& value) { - get_property_value(*g.m_property, tag) = value; - } - - template - inline typename graph_property::type& - get_property(ADJLIST& g, Tag tag) { - return get_property_value(*g.m_property, tag); - } - - template - inline typename graph_property::type const& - get_property(ADJLIST const& g, Tag tag) { - return get_property_value(*g.m_property, tag); - } - - // dwa 09/25/00 - needed to be more explicit so reverse_graph would work. - template - inline Vertex - source(const detail::edge_base& e, - const adjacency_list&) - { - return e.m_source; - } - - template - inline Vertex - target(const detail::edge_base& e, - const adjacency_list&) - { - return e.m_target; - } - -// Mutability Traits -template -struct graph_mutability_traits { - typedef mutable_property_graph_tag category; -}; - -// Can't remove vertices from adjacency lists with VL==vecS -template -struct graph_mutability_traits< adjacency_list > { - typedef add_only_property_graph_tag category; -}; -#undef ADJLIST_PARAMS -#undef ADJLIST - - -} // namespace boost - - -#endif // BOOST_GRAPH_ADJACENCY_LIST_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/breadth_first_search.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/breadth_first_search.hpp deleted file mode 100644 index b0d10ad5..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/breadth_first_search.hpp +++ /dev/null @@ -1,413 +0,0 @@ -// -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= -// -#ifndef BOOST_GRAPH_BREADTH_FIRST_SEARCH_HPP -#define BOOST_GRAPH_BREADTH_FIRST_SEARCH_HPP - -/* - Breadth First Search Algorithm (Cormen, Leiserson, and Rivest p. 470) -*/ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#ifdef BOOST_GRAPH_USE_MPI -#include -#endif // BOOST_GRAPH_USE_MPI - -namespace boost { - - template - struct BFSVisitorConcept { - void constraints() { - BOOST_CONCEPT_ASSERT(( CopyConstructibleConcept )); - vis.initialize_vertex(u, g); - vis.discover_vertex(u, g); - vis.examine_vertex(u, g); - vis.examine_edge(e, g); - vis.tree_edge(e, g); - vis.non_tree_edge(e, g); - vis.gray_target(e, g); - vis.black_target(e, g); - vis.finish_vertex(u, g); - } - Visitor vis; - Graph g; - typename graph_traits::vertex_descriptor u; - typename graph_traits::edge_descriptor e; - }; - - - // Multiple-source version - template - void breadth_first_visit - (const IncidenceGraph& g, - SourceIterator sources_begin, SourceIterator sources_end, - Buffer& Q, BFSVisitor vis, ColorMap color) - { - BOOST_CONCEPT_ASSERT(( IncidenceGraphConcept )); - typedef graph_traits GTraits; - typedef typename GTraits::vertex_descriptor Vertex; - BOOST_CONCEPT_ASSERT(( BFSVisitorConcept )); - BOOST_CONCEPT_ASSERT(( ReadWritePropertyMapConcept )); - typedef typename property_traits::value_type ColorValue; - typedef color_traits Color; - typename GTraits::out_edge_iterator ei, ei_end; - - for (; sources_begin != sources_end; ++sources_begin) { - Vertex s = *sources_begin; - put(color, s, Color::gray()); vis.discover_vertex(s, g); - Q.push(s); - } - while (! Q.empty()) { - Vertex u = Q.top(); Q.pop(); vis.examine_vertex(u, g); - for (boost::tie(ei, ei_end) = out_edges(u, g); ei != ei_end; ++ei) { - Vertex v = target(*ei, g); vis.examine_edge(*ei, g); - ColorValue v_color = get(color, v); - if (v_color == Color::white()) { vis.tree_edge(*ei, g); - put(color, v, Color::gray()); vis.discover_vertex(v, g); - Q.push(v); - } else { vis.non_tree_edge(*ei, g); - if (v_color == Color::gray()) vis.gray_target(*ei, g); - else vis.black_target(*ei, g); - } - } // end for - put(color, u, Color::black()); vis.finish_vertex(u, g); - } // end while - } // breadth_first_visit - - // Single-source version - template - void breadth_first_visit - (const IncidenceGraph& g, - typename graph_traits::vertex_descriptor s, - Buffer& Q, BFSVisitor vis, ColorMap color) - { - typename graph_traits::vertex_descriptor sources[1] = {s}; - breadth_first_visit(g, sources, sources + 1, Q, vis, color); - } - - - template - void breadth_first_search - (const VertexListGraph& g, - SourceIterator sources_begin, SourceIterator sources_end, - Buffer& Q, BFSVisitor vis, ColorMap color) - { - // Initialization - typedef typename property_traits::value_type ColorValue; - typedef color_traits Color; - typename boost::graph_traits::vertex_iterator i, i_end; - for (boost::tie(i, i_end) = vertices(g); i != i_end; ++i) { - vis.initialize_vertex(*i, g); - put(color, *i, Color::white()); - } - breadth_first_visit(g, sources_begin, sources_end, Q, vis, color); - } - - template - void breadth_first_search - (const VertexListGraph& g, - typename graph_traits::vertex_descriptor s, - Buffer& Q, BFSVisitor vis, ColorMap color) - { - typename graph_traits::vertex_descriptor sources[1] = {s}; - breadth_first_search(g, sources, sources + 1, Q, vis, color); - } - - namespace graph { struct bfs_visitor_event_not_overridden {}; } - - - template - class bfs_visitor { - public: - bfs_visitor() { } - bfs_visitor(Visitors vis) : m_vis(vis) { } - - template - graph::bfs_visitor_event_not_overridden - initialize_vertex(Vertex u, Graph& g) - { - invoke_visitors(m_vis, u, g, ::boost::on_initialize_vertex()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - discover_vertex(Vertex u, Graph& g) - { - invoke_visitors(m_vis, u, g, ::boost::on_discover_vertex()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - examine_vertex(Vertex u, Graph& g) - { - invoke_visitors(m_vis, u, g, ::boost::on_examine_vertex()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - examine_edge(Edge e, Graph& g) - { - invoke_visitors(m_vis, e, g, ::boost::on_examine_edge()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - tree_edge(Edge e, Graph& g) - { - invoke_visitors(m_vis, e, g, ::boost::on_tree_edge()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - non_tree_edge(Edge e, Graph& g) - { - invoke_visitors(m_vis, e, g, ::boost::on_non_tree_edge()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - gray_target(Edge e, Graph& g) - { - invoke_visitors(m_vis, e, g, ::boost::on_gray_target()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - black_target(Edge e, Graph& g) - { - invoke_visitors(m_vis, e, g, ::boost::on_black_target()); - return graph::bfs_visitor_event_not_overridden(); - } - - template - graph::bfs_visitor_event_not_overridden - finish_vertex(Vertex u, Graph& g) - { - invoke_visitors(m_vis, u, g, ::boost::on_finish_vertex()); - return graph::bfs_visitor_event_not_overridden(); - } - - BOOST_GRAPH_EVENT_STUB(on_initialize_vertex,bfs) - BOOST_GRAPH_EVENT_STUB(on_discover_vertex,bfs) - BOOST_GRAPH_EVENT_STUB(on_examine_vertex,bfs) - BOOST_GRAPH_EVENT_STUB(on_examine_edge,bfs) - BOOST_GRAPH_EVENT_STUB(on_tree_edge,bfs) - BOOST_GRAPH_EVENT_STUB(on_non_tree_edge,bfs) - BOOST_GRAPH_EVENT_STUB(on_gray_target,bfs) - BOOST_GRAPH_EVENT_STUB(on_black_target,bfs) - BOOST_GRAPH_EVENT_STUB(on_finish_vertex,bfs) - - protected: - Visitors m_vis; - }; - template - bfs_visitor - make_bfs_visitor(Visitors vis) { - return bfs_visitor(vis); - } - typedef bfs_visitor<> default_bfs_visitor; - - - namespace detail { - - template - void bfs_helper - (VertexListGraph& g, - typename graph_traits::vertex_descriptor s, - ColorMap color, - BFSVisitor vis, - const bgl_named_params& params, - boost::mpl::false_) - { - typedef graph_traits Traits; - // Buffer default - typedef typename Traits::vertex_descriptor Vertex; - typedef boost::queue queue_t; - queue_t Q; - breadth_first_search - (g, s, - choose_param(get_param(params, buffer_param_t()), boost::ref(Q)).get(), - vis, color); - } - -#ifdef BOOST_GRAPH_USE_MPI - template - void bfs_helper - (DistributedGraph& g, - typename graph_traits::vertex_descriptor s, - ColorMap color, - BFSVisitor vis, - const bgl_named_params& params, - boost::mpl::true_); -#endif // BOOST_GRAPH_USE_MPI - - //------------------------------------------------------------------------- - // Choose between default color and color parameters. Using - // function dispatching so that we don't require vertex index if - // the color default is not being used. - - template - struct bfs_dispatch { - template - static void apply - (VertexListGraph& g, - typename graph_traits::vertex_descriptor s, - const bgl_named_params& params, - ColorMap color) - { - bfs_helper - (g, s, color, - choose_param(get_param(params, graph_visitor), - make_bfs_visitor(null_visitor())), - params, - boost::mpl::bool_< - boost::is_base_and_derived< - distributed_graph_tag, - typename graph_traits::traversal_category>::value>()); - } - }; - - template <> - struct bfs_dispatch { - template - static void apply - (VertexListGraph& g, - typename graph_traits::vertex_descriptor s, - const bgl_named_params& params, - param_not_found) - { - null_visitor null_vis; - - bfs_helper - (g, s, - make_two_bit_color_map - (num_vertices(g), - choose_const_pmap(get_param(params, vertex_index), - g, vertex_index)), - choose_param(get_param(params, graph_visitor), - make_bfs_visitor(null_vis)), - params, - boost::mpl::bool_< - boost::is_base_and_derived< - distributed_graph_tag, - typename graph_traits::traversal_category>::value>()); - } - }; - - } // namespace detail - -#if 1 - // Named Parameter Variant - template - void breadth_first_search - (const VertexListGraph& g, - typename graph_traits::vertex_descriptor s, - const bgl_named_params& params) - { - // The graph is passed by *const* reference so that graph adaptors - // (temporaries) can be passed into this function. However, the - // graph is not really const since we may write to property maps - // of the graph. - VertexListGraph& ng = const_cast(g); - typedef typename get_param_type< vertex_color_t, bgl_named_params >::type C; - detail::bfs_dispatch::apply(ng, s, params, - get_param(params, vertex_color)); - } -#endif - - - // This version does not initialize colors, user has to. - - template - void breadth_first_visit - (const IncidenceGraph& g, - typename graph_traits::vertex_descriptor s, - const bgl_named_params& params) - { - // The graph is passed by *const* reference so that graph adaptors - // (temporaries) can be passed into this function. However, the - // graph is not really const since we may write to property maps - // of the graph. - IncidenceGraph& ng = const_cast(g); - - typedef graph_traits Traits; - // Buffer default - typedef typename Traits::vertex_descriptor vertex_descriptor; - typedef boost::queue queue_t; - queue_t Q; - - breadth_first_visit - (ng, s, - choose_param(get_param(params, buffer_param_t()), boost::ref(Q)).get(), - choose_param(get_param(params, graph_visitor), - make_bfs_visitor(null_visitor())), - choose_pmap(get_param(params, vertex_color), ng, vertex_color) - ); - } - - namespace graph { - namespace detail { - template - struct breadth_first_search_impl { - typedef void result_type; - template - void operator()(const Graph& g, const Source& source, const ArgPack& arg_pack) { - using namespace boost::graph::keywords; - typename boost::graph_traits::vertex_descriptor sources[1] = {source}; - boost::queue::vertex_descriptor> Q; - boost::breadth_first_search(g, - &sources[0], - &sources[1], - boost::unwrap_ref(arg_pack[_buffer | boost::ref(Q)]), - arg_pack[_visitor | make_bfs_visitor(null_visitor())], - boost::detail::make_color_map_from_arg_pack(g, arg_pack)); - } - }; - } - BOOST_GRAPH_MAKE_FORWARDING_FUNCTION(breadth_first_search, 2, 4) - } - -#if 0 - // Named Parameter Variant - BOOST_GRAPH_MAKE_OLD_STYLE_PARAMETER_FUNCTION(breadth_first_search, 2) -#endif - -} // namespace boost - -#ifdef BOOST_GRAPH_USE_MPI -# include -#endif - -#endif // BOOST_GRAPH_BREADTH_FIRST_SEARCH_HPP - diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/buffer_concepts.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/buffer_concepts.hpp deleted file mode 100644 index 2bad8af3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/buffer_concepts.hpp +++ /dev/null @@ -1,91 +0,0 @@ -// Copyright Daniel Trebbien 2010. -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or the copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_GRAPH_BUFFER_CONCEPTS_HPP -#define BOOST_GRAPH_BUFFER_CONCEPTS_HPP 1 -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - - BOOST_concept(Buffer, (B)) - { - typedef typename B::value_type value_type; - typedef typename B::size_type size_type; - - BOOST_CONCEPT_USAGE(Buffer) { - typedef typename boost::add_reference::type reference; - - BOOST_CONCEPT_ASSERT((Assignable)); - - buf.push(g_ct); - buf.pop(); - reference t = buf.top(); - boost::ignore_unused_variable_warning(t); - } - - void const_constraints(const B& cbuf) { - typedef typename boost::add_const::type>::type& const_reference; - - const_reference ct = cbuf.top(); - s = cbuf.size(); - if (cbuf.empty()) - dummy = __LINE__; - } - - int dummy; - - static const value_type g_ct; - size_type s; - B buf; - }; - - BOOST_concept(UpdatableQueue, (Q)) - : Buffer - { - BOOST_CONCEPT_USAGE(UpdatableQueue) { - q.update(g_ct); - } - - void const_constraints(const Q& cq) { - if (cq.contains(g_ct)) - dummy = __LINE__; - } - - int dummy; - - static const typename Buffer::value_type g_ct; - Q q; - }; - - BOOST_concept(KeyedUpdatableQueue, (Q)) - : UpdatableQueue - { - typedef typename Q::key_type key_type; - typedef typename Q::key_map key_map; - - BOOST_CONCEPT_USAGE(KeyedUpdatableQueue) { - BOOST_CONCEPT_ASSERT((boost::ReadWritePropertyMapConcept::value_type>)); - } - - void const_constraints(const Q& cq) { - km = cq.keys(); - k = get(km, g_ct); - } - - static const typename Buffer::value_type g_ct; - key_type k; - key_map km; - Q q; - }; - -} // end `namespace boost` - -#endif // !BOOST_GRAPH_BUFFER_CONCEPTS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adj_list_edge_iterator.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adj_list_edge_iterator.hpp deleted file mode 100644 index 12cb6ee9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adj_list_edge_iterator.hpp +++ /dev/null @@ -1,117 +0,0 @@ -// -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= -// -#ifndef BOOST_GRAPH_DETAIL_ADJ_LIST_EDGE_ITERATOR_HPP -#define BOOST_GRAPH_DETAIL_ADJ_LIST_EDGE_ITERATOR_HPP - -#include -#include -#include - -#if BOOST_WORKAROUND( __IBMCPP__, <= 600 ) -# define BOOST_GRAPH_NO_OPTIONAL -#endif - -#ifdef BOOST_GRAPH_NO_OPTIONAL -# define BOOST_GRAPH_MEMBER . -#else -# define BOOST_GRAPH_MEMBER -> -# include -#endif // ndef BOOST_GRAPH_NO_OPTIONAL - -namespace boost { - - namespace detail { - - template - class adj_list_edge_iterator { - typedef adj_list_edge_iterator self; - public: - typedef std::forward_iterator_tag iterator_category; - typedef typename OutEdgeIterator::value_type value_type; - typedef typename OutEdgeIterator::reference reference; - typedef typename OutEdgeIterator::pointer pointer; - typedef typename OutEdgeIterator::difference_type difference_type; - typedef difference_type distance_type; - - inline adj_list_edge_iterator() {} - - inline adj_list_edge_iterator(const self& x) - : vBegin(x.vBegin), vCurr(x.vCurr), vEnd(x.vEnd), - edges(x.edges), m_g(x.m_g) { } - - template - inline adj_list_edge_iterator(VertexIterator b, - VertexIterator c, - VertexIterator e, - const G& g) - : vBegin(b), vCurr(c), vEnd(e), m_g(&g) { - if ( vCurr != vEnd ) { - while ( vCurr != vEnd && out_degree(*vCurr, *m_g) == 0 ) - ++vCurr; - if ( vCurr != vEnd ) - edges = out_edges(*vCurr, *m_g); - } - } - - /*Note: - In the directed graph cases, it is fine. - For undirected graphs, one edge go through twice. - */ - inline self& operator++() { - ++edges BOOST_GRAPH_MEMBER first; - if (edges BOOST_GRAPH_MEMBER first == edges BOOST_GRAPH_MEMBER second) - { - ++vCurr; - while ( vCurr != vEnd && out_degree(*vCurr, *m_g) == 0 ) - ++vCurr; - if ( vCurr != vEnd ) - edges = out_edges(*vCurr, *m_g); - } - return *this; - } - inline self operator++(int) { - self tmp = *this; - ++(*this); - return tmp; - } - inline value_type operator*() const - { return *edges BOOST_GRAPH_MEMBER first; } - inline bool operator==(const self& x) const { - return vCurr == x.vCurr - && (vCurr == vEnd - || edges BOOST_GRAPH_MEMBER first == x.edges BOOST_GRAPH_MEMBER first); - } - inline bool operator!=(const self& x) const { - return vCurr != x.vCurr - || (vCurr != vEnd - && edges BOOST_GRAPH_MEMBER first != x.edges BOOST_GRAPH_MEMBER first); - } - protected: - VertexIterator vBegin; - VertexIterator vCurr; - VertexIterator vEnd; - -#ifdef BOOST_GRAPH_NO_OPTIONAL - std::pair edges; -#else - boost::optional > - edges; -#endif // ndef BOOST_GRAPH_NO_OPTIONAL - const Graph* m_g; - }; - - } // namespace detail - -} - -#undef BOOST_GRAPH_MEMBER - -#endif // BOOST_GRAPH_DETAIL_ADJ_LIST_EDGE_ITERATOR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adjacency_list.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adjacency_list.hpp deleted file mode 100644 index a99ec265..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/adjacency_list.hpp +++ /dev/null @@ -1,2784 +0,0 @@ -// -*- c++ -*- -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Copyright 2010 Thomas Claveirole -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek, Thomas Claveirole -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_DETAIL_ADJACENCY_LIST_HPP -#define BOOST_GRAPH_DETAIL_ADJACENCY_LIST_HPP - -#include // for vertex_map in copy_impl -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* - Outline for this file: - - out_edge_iterator and in_edge_iterator implementation - edge_iterator for undirected graph - stored edge types (these object live in the out-edge/in-edge lists) - directed edges helper class - directed graph helper class - undirected graph helper class - bidirectional graph helper class - bidirectional graph helper class (without edge properties) - bidirectional graph helper class (with edge properties) - adjacency_list helper class - adj_list_impl class - vec_adj_list_impl class - adj_list_gen class - vertex property map - edge property map - - - Note: it would be nice to merge some of the undirected and - bidirectional code... it is awful similar. - */ - - -namespace boost { - - namespace detail { - - template - struct directed_category_traits { - typedef directed_tag directed_category; - }; - - template <> - struct directed_category_traits { - typedef directed_tag directed_category; - }; - template <> - struct directed_category_traits { - typedef undirected_tag directed_category; - }; - template <> - struct directed_category_traits { - typedef bidirectional_tag directed_category; - }; - - template - struct target_is { - target_is(const Vertex& v) : m_target(v) { } - template - bool operator()(const StoredEdge& e) const { - return e.get_target() == m_target; - } - Vertex m_target; - }; - - // O(E/V) - template - void erase_from_incidence_list(EdgeList& el, vertex_descriptor v, - allow_parallel_edge_tag) - { - boost::graph_detail::erase_if(el, detail::target_is(v)); - } - // O(log(E/V)) - template - void erase_from_incidence_list(EdgeList& el, vertex_descriptor v, - disallow_parallel_edge_tag) - { - typedef typename EdgeList::value_type StoredEdge; - el.erase(StoredEdge(v)); - } - - //========================================================================= - // Out-Edge and In-Edge Iterator Implementation - - template - struct out_edge_iter - : iterator_adaptor< - out_edge_iter - , BaseIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > - { - typedef iterator_adaptor< - out_edge_iter - , BaseIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > super_t; - - inline out_edge_iter() { } - inline out_edge_iter(const BaseIter& i, const VertexDescriptor& src) - : super_t(i), m_src(src) { } - - inline EdgeDescriptor - dereference() const - { - return EdgeDescriptor(m_src, (*this->base()).get_target(), - &(*this->base()).get_property()); - } - VertexDescriptor m_src; - }; - - template - struct in_edge_iter - : iterator_adaptor< - in_edge_iter - , BaseIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > - { - typedef iterator_adaptor< - in_edge_iter - , BaseIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > super_t; - - inline in_edge_iter() { } - inline in_edge_iter(const BaseIter& i, const VertexDescriptor& src) - : super_t(i), m_src(src) { } - - inline EdgeDescriptor - dereference() const - { - return EdgeDescriptor((*this->base()).get_target(), m_src, - &this->base()->get_property()); - } - VertexDescriptor m_src; - }; - - //========================================================================= - // Undirected Edge Iterator Implementation - - template - struct undirected_edge_iter - : iterator_adaptor< - undirected_edge_iter - , EdgeIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > - { - typedef iterator_adaptor< - undirected_edge_iter - , EdgeIter - , EdgeDescriptor - , use_default - , EdgeDescriptor - , Difference - > super_t; - - undirected_edge_iter() {} - - explicit undirected_edge_iter(EdgeIter i) - : super_t(i) {} - - inline EdgeDescriptor - dereference() const { - return EdgeDescriptor( - (*this->base()).m_source - , (*this->base()).m_target - , &this->base()->get_property()); - } - }; - - //========================================================================= - // Edge Storage Types (stored in the out-edge/in-edge lists) - - template - class stored_edge - : public boost::equality_comparable1< stored_edge, - boost::less_than_comparable1< stored_edge > > - { - public: - typedef no_property property_type; - inline stored_edge() { } - inline stored_edge(Vertex target, const no_property& = no_property()) - : m_target(target) { } - // Need to write this explicitly so stored_edge_property can - // invoke Base::operator= (at least, for SGI MIPSPro compiler) - inline stored_edge& operator=(const stored_edge& x) { - m_target = x.m_target; - return *this; - } - inline Vertex& get_target() const { return m_target; } - inline const no_property& get_property() const { return s_prop; } - inline bool operator==(const stored_edge& x) const - { return m_target == x.get_target(); } - inline bool operator<(const stored_edge& x) const - { return m_target < x.get_target(); } - //protected: need to add hash<> as a friend - static no_property s_prop; - // Sometimes target not used as key in the set, and in that case - // it is ok to change the target. - mutable Vertex m_target; - }; - template - no_property stored_edge::s_prop; - - template - class stored_edge_property : public stored_edge { - typedef stored_edge_property self; - typedef stored_edge Base; - public: - typedef Property property_type; - inline stored_edge_property() { } - inline stored_edge_property(Vertex target, - const Property& p = Property()) - : stored_edge(target), m_property(new Property(p)) { } - stored_edge_property(const self& x) - : Base(x), m_property(const_cast(x).m_property) { } - self& operator=(const self& x) { - Base::operator=(x); - m_property = const_cast(x).m_property; - return *this; - } - inline Property& get_property() { return *m_property; } - inline const Property& get_property() const { return *m_property; } - protected: - // Holding the property by-value causes edge-descriptor - // invalidation for add_edge() with EdgeList=vecS. Instead we - // hold a pointer to the property. std::auto_ptr is not - // a perfect fit for the job, but it is darn close. - std::auto_ptr m_property; - }; - - - template - class stored_edge_iter - : public stored_edge - { - public: - typedef Property property_type; - inline stored_edge_iter() { } - inline stored_edge_iter(Vertex v) - : stored_edge(v) { } - inline stored_edge_iter(Vertex v, Iter i, void* = 0) - : stored_edge(v), m_iter(i) { } - inline Property& get_property() { return m_iter->get_property(); } - inline const Property& get_property() const { - return m_iter->get_property(); - } - inline Iter get_iter() const { return m_iter; } - protected: - Iter m_iter; - }; - - // For when the EdgeList is a std::vector. - // Want to make the iterator stable, so use an offset - // instead of an iterator into a std::vector - template - class stored_ra_edge_iter - : public stored_edge - { - typedef typename EdgeVec::iterator Iter; - public: - typedef Property property_type; - inline stored_ra_edge_iter() { } - inline explicit stored_ra_edge_iter(Vertex v) // Only used for comparisons - : stored_edge(v), m_i(0), m_vec(0){ } - inline stored_ra_edge_iter(Vertex v, Iter i, EdgeVec* edge_vec) - : stored_edge(v), m_i(i - edge_vec->begin()), m_vec(edge_vec){ } - inline Property& get_property() { BOOST_ASSERT ((m_vec != 0)); return (*m_vec)[m_i].get_property(); } - inline const Property& get_property() const { - BOOST_ASSERT ((m_vec != 0)); - return (*m_vec)[m_i].get_property(); - } - inline Iter get_iter() const { BOOST_ASSERT ((m_vec != 0)); return m_vec->begin() + m_i; } - protected: - std::size_t m_i; - EdgeVec* m_vec; - }; - - } // namespace detail - - template - const typename property_value::type& - get(Tag property_tag, - const detail::stored_edge_property& e) - { - return get_property_value(e.get_property(), property_tag); - } - - template - const typename property_value::type& - get(Tag property_tag, - const detail::stored_edge_iter& e) - { - return get_property_value(e.get_property(), property_tag); - } - - template - const typename property_value::type& - get(Tag property_tag, - const detail::stored_ra_edge_iter& e) - { - return get_property_value(e.get_property(), property_tag); - } - - //========================================================================= - // Directed Edges Helper Class - - namespace detail { - - // O(E/V) - template - inline void - remove_directed_edge_dispatch(edge_descriptor, EdgeList& el, - StoredProperty& p) - { - for (typename EdgeList::iterator i = el.begin(); - i != el.end(); ++i) - if (&(*i).get_property() == &p) { - el.erase(i); - return; - } - } - - template - inline void - remove_directed_edge_if_dispatch(incidence_iterator first, - incidence_iterator last, - EdgeList& el, Predicate pred, - boost::allow_parallel_edge_tag) - { - // remove_if - while (first != last && !pred(*first)) - ++first; - incidence_iterator i = first; - if (first != last) - for (++i; i != last; ++i) - if (!pred(*i)) { - *first.base() = *i.base(); - ++first; - } - el.erase(first.base(), el.end()); - } - template - inline void - remove_directed_edge_if_dispatch(incidence_iterator first, - incidence_iterator last, - EdgeList& el, - Predicate pred, - boost::disallow_parallel_edge_tag) - { - for (incidence_iterator next = first; - first != last; first = next) { - ++next; - if (pred(*first)) - el.erase( first.base() ); - } - } - - template - inline void - undirected_remove_out_edge_if_dispatch(Graph& g, - incidence_iterator first, - incidence_iterator last, - EdgeList& el, Predicate pred, - boost::allow_parallel_edge_tag) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - // remove_if - while (first != last && !pred(*first)) - ++first; - incidence_iterator i = first; - bool self_loop_removed = false; - if (first != last) - for (; i != last; ++i) { - if (self_loop_removed) { - /* With self loops, the descriptor will show up - * twice. The first time it will be removed, and now it - * will be skipped. - */ - self_loop_removed = false; - } - else if (!pred(*i)) { - *first.base() = *i.base(); - ++first; - } else { - if (source(*i, g) == target(*i, g)) self_loop_removed = true; - else { - // Remove the edge from the target - detail::remove_directed_edge_dispatch - (*i, - g.out_edge_list(target(*i, g)), - *(PropT*)(*i).get_property()); - } - - // Erase the edge property - g.m_edges.erase( (*i.base()).get_iter() ); - } - } - el.erase(first.base(), el.end()); - } - template - inline void - undirected_remove_out_edge_if_dispatch(Graph& g, - incidence_iterator first, - incidence_iterator last, - EdgeList& el, - Predicate pred, - boost::disallow_parallel_edge_tag) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - for (incidence_iterator next = first; - first != last; first = next) { - ++next; - if (pred(*first)) { - if (source(*first, g) != target(*first, g)) { - // Remove the edge from the target - detail::remove_directed_edge_dispatch - (*first, - g.out_edge_list(target(*first, g)), - *(PropT*)(*first).get_property()); - } - - // Erase the edge property - g.m_edges.erase( (*first.base()).get_iter() ); - - // Erase the edge in the source - el.erase( first.base() ); - } - } - } - - // O(E/V) - template - inline void - remove_directed_edge_dispatch(edge_descriptor e, EdgeList& el, - no_property&) - { - for (typename EdgeList::iterator i = el.begin(); - i != el.end(); ++i) - if ((*i).get_target() == e.m_target) { - el.erase(i); - return; - } - } - - } // namespace detail - - template - struct directed_edges_helper { - - // Placement of these overloaded remove_edge() functions - // inside the class avoids a VC++ bug. - - // O(E/V) - inline void - remove_edge(typename Config::edge_descriptor e) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(*this); - typename Config::OutEdgeList& el = g.out_edge_list(source(e, g)); - typedef typename Config::OutEdgeList::value_type::property_type PType; - detail::remove_directed_edge_dispatch(e, el, - *(PType*)e.get_property()); - } - - // O(1) - inline void - remove_edge(typename Config::out_edge_iterator iter) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(*this); - typename Config::edge_descriptor e = *iter; - typename Config::OutEdgeList& el = g.out_edge_list(source(e, g)); - el.erase(iter.base()); - } - - }; - - // O(1) - template - inline std::pair - edges(const directed_edges_helper& g_) - { - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_iterator edge_iterator; - const graph_type& cg = static_cast(g_); - graph_type& g = const_cast(cg); - return std::make_pair( edge_iterator(g.vertex_set().begin(), - g.vertex_set().begin(), - g.vertex_set().end(), g), - edge_iterator(g.vertex_set().begin(), - g.vertex_set().end(), - g.vertex_set().end(), g) ); - } - - //========================================================================= - // Directed Graph Helper Class - - struct adj_list_dir_traversal_tag : - public virtual vertex_list_graph_tag, - public virtual incidence_graph_tag, - public virtual adjacency_graph_tag, - public virtual edge_list_graph_tag { }; - - template - struct directed_graph_helper - : public directed_edges_helper { - typedef typename Config::edge_descriptor edge_descriptor; - typedef adj_list_dir_traversal_tag traversal_category; - }; - - // O(E/V) - template - inline void - remove_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_parallel_category Cat; - graph_type& g = static_cast(g_); - detail::erase_from_incidence_list(g.out_edge_list(u), v, Cat()); - } - - template - inline void - remove_out_edge_if(typename Config::vertex_descriptor u, Predicate pred, - directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typename Config::out_edge_iterator first, last; - boost::tie(first, last) = out_edges(u, g); - typedef typename Config::edge_parallel_category edge_parallel_category; - detail::remove_directed_edge_if_dispatch - (first, last, g.out_edge_list(u), pred, edge_parallel_category()); - } - - template - inline void - remove_edge_if(Predicate pred, directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - - typename Config::vertex_iterator vi, vi_end; - for (boost::tie(vi, vi_end) = vertices(g); vi != vi_end; ++vi) - remove_out_edge_if(*vi, pred, g); - } - - template - inline void - remove_edge(EdgeOrIter e_or_iter, directed_graph_helper& g_) - { - g_.remove_edge(e_or_iter); - } - - // O(V + E) for allow_parallel_edges - // O(V * log(E/V)) for disallow_parallel_edges - template - inline void - clear_vertex(typename Config::vertex_descriptor u, - directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_parallel_category Cat; - graph_type& g = static_cast(g_); - typename Config::vertex_iterator vi, viend; - for (boost::tie(vi, viend) = vertices(g); vi != viend; ++vi) - detail::erase_from_incidence_list(g.out_edge_list(*vi), u, Cat()); - g.out_edge_list(u).clear(); - // clear() should be a req of Sequence and AssociativeContainer, - // or maybe just Container - } - - template - inline void - clear_out_edges(typename Config::vertex_descriptor u, - directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - g.out_edge_list(u).clear(); - // clear() should be a req of Sequence and AssociativeContainer, - // or maybe just Container - } - - // O(V), could do better... - template - inline typename Config::edges_size_type - num_edges(const directed_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - const graph_type& g = static_cast(g_); - typename Config::edges_size_type num_e = 0; - typename Config::vertex_iterator vi, vi_end; - for (boost::tie(vi, vi_end) = vertices(g); vi != vi_end; ++vi) - num_e += out_degree(*vi, g); - return num_e; - } - // O(1) for allow_parallel_edge_tag - // O(log(E/V)) for disallow_parallel_edge_tag - template - inline std::pair::edge_descriptor, bool> - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const typename Config::edge_property_type& p, - directed_graph_helper& g_) - { - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::graph_type graph_type; - typedef typename Config::StoredEdge StoredEdge; - graph_type& g = static_cast(g_); - typename Config::OutEdgeList::iterator i; - bool inserted; - boost::tie(i, inserted) = boost::graph_detail::push(g.out_edge_list(u), - StoredEdge(v, p)); - return std::make_pair(edge_descriptor(u, v, &(*i).get_property()), - inserted); - } - // Did not use default argument here because that - // causes Visual C++ to get confused. - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - directed_graph_helper& g_) - { - typename Config::edge_property_type p; - return add_edge(u, v, p, g_); - } - //========================================================================= - // Undirected Graph Helper Class - - template - struct undirected_graph_helper; - - struct undir_adj_list_traversal_tag : - public virtual vertex_list_graph_tag, - public virtual incidence_graph_tag, - public virtual adjacency_graph_tag, - public virtual edge_list_graph_tag, - public virtual bidirectional_graph_tag { }; - - namespace detail { - - // using class with specialization for dispatch is a VC++ workaround. - template - struct remove_undirected_edge_dispatch { - - // O(E/V) - template - static void - apply(edge_descriptor e, - undirected_graph_helper& g_, - StoredProperty& p) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - - typename Config::OutEdgeList& out_el = g.out_edge_list(source(e, g)); - typename Config::OutEdgeList::iterator out_i = out_el.begin(); - typename Config::EdgeIter edge_iter_to_erase; - for (; out_i != out_el.end(); ++out_i) - if (&(*out_i).get_property() == &p) { - edge_iter_to_erase = (*out_i).get_iter(); - out_el.erase(out_i); - break; - } - typename Config::OutEdgeList& in_el = g.out_edge_list(target(e, g)); - typename Config::OutEdgeList::iterator in_i = in_el.begin(); - for (; in_i != in_el.end(); ++in_i) - if (&(*in_i).get_property() == &p) { - in_el.erase(in_i); - break; - } - g.m_edges.erase(edge_iter_to_erase); - } - }; - - template <> - struct remove_undirected_edge_dispatch { - // O(E/V) - template - static void - apply(edge_descriptor e, - undirected_graph_helper& g_, - no_property&) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - no_property* p = (no_property*)e.get_property(); - typename Config::OutEdgeList& out_el = g.out_edge_list(source(e, g)); - typename Config::OutEdgeList::iterator out_i = out_el.begin(); - typename Config::EdgeIter edge_iter_to_erase; - for (; out_i != out_el.end(); ++out_i) - if (&(*out_i).get_property() == p) { - edge_iter_to_erase = (*out_i).get_iter(); - out_el.erase(out_i); - break; - } - typename Config::OutEdgeList& in_el = g.out_edge_list(target(e, g)); - typename Config::OutEdgeList::iterator in_i = in_el.begin(); - for (; in_i != in_el.end(); ++in_i) - if (&(*in_i).get_property() == p) { - in_el.erase(in_i); - break; - } - g.m_edges.erase(edge_iter_to_erase); - } - }; - - // O(E/V) - template - inline void - remove_edge_and_property(Graph& g, EdgeList& el, Vertex v, - boost::allow_parallel_edge_tag cat) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typename EdgeList::iterator i = el.begin(), end = el.end(); - for (; i != end; ++i) { - if ((*i).get_target() == v) { - // NOTE: Wihtout this skip, this loop will double-delete properties - // of loop edges. This solution is based on the observation that - // the incidence edges of a vertex with a loop are adjacent in the - // out edge list. This *may* actually hold for multisets also. - bool skip = (boost::next(i) != end && i->get_iter() == boost::next(i)->get_iter()); - g.m_edges.erase((*i).get_iter()); - if (skip) ++i; - } - } - detail::erase_from_incidence_list(el, v, cat); - } - // O(log(E/V)) - template - inline void - remove_edge_and_property(Graph& g, EdgeList& el, Vertex v, - boost::disallow_parallel_edge_tag) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename EdgeList::value_type StoredEdge; - typename EdgeList::iterator i = el.find(StoredEdge(v)), end = el.end(); - if (i != end) { - g.m_edges.erase((*i).get_iter()); - el.erase(i); - } - } - - } // namespace detail - - template - struct list_edge // short name due to VC++ truncation and linker problems - : public boost::detail::edge_base - { - typedef EdgeProperty property_type; - typedef boost::detail::edge_base Base; - list_edge(Vertex u, Vertex v, const EdgeProperty& p = EdgeProperty()) - : Base(u, v), m_property(p) { } - EdgeProperty& get_property() { return m_property; } - const EdgeProperty& get_property() const { return m_property; } - // the following methods should never be used, but are needed - // to make SGI MIPSpro C++ happy - list_edge() { } - bool operator==(const list_edge&) const { return false; } - bool operator<(const list_edge&) const { return false; } - EdgeProperty m_property; - }; - - template - struct undirected_graph_helper { - - typedef undir_adj_list_traversal_tag traversal_category; - - // Placement of these overloaded remove_edge() functions - // inside the class avoids a VC++ bug. - - // O(E/V) - inline void - remove_edge(typename Config::edge_descriptor e) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::OutEdgeList::value_type::property_type PType; - detail::remove_undirected_edge_dispatch::apply - (e, *this, *(PType*)e.get_property()); - } - // O(E/V) - inline void - remove_edge(typename Config::out_edge_iterator iter) - { - this->remove_edge(*iter); - } - }; - - // Had to make these non-members to avoid accidental instantiation - // on SGI MIPSpro C++ - template - inline typename C::InEdgeList& - in_edge_list(undirected_graph_helper&, - typename C::vertex_descriptor v) - { - typename C::stored_vertex* sv = (typename C::stored_vertex*)v; - return sv->m_out_edges; - } - template - inline const typename C::InEdgeList& - in_edge_list(const undirected_graph_helper&, - typename C::vertex_descriptor v) { - typename C::stored_vertex* sv = (typename C::stored_vertex*)v; - return sv->m_out_edges; - } - - // O(E/V) - template - inline void - remove_edge(EdgeOrIter e, undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - g_.remove_edge(e); - } - - // O(E/V) or O(log(E/V)) - template - void - remove_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typedef typename Config::edge_parallel_category Cat; - detail::remove_edge_and_property(g, g.out_edge_list(u), v, Cat()); - detail::erase_from_incidence_list(g.out_edge_list(v), u, Cat()); - } - - template - void - remove_out_edge_if(typename Config::vertex_descriptor u, Predicate pred, - undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::OutEdgeList::value_type::property_type PropT; - graph_type& g = static_cast(g_); - typename Config::out_edge_iterator first, last; - boost::tie(first, last) = out_edges(u, g); - typedef typename Config::edge_parallel_category Cat; - detail::undirected_remove_out_edge_if_dispatch - (g, first, last, g.out_edge_list(u), pred, Cat()); - } - template - void - remove_in_edge_if(typename Config::vertex_descriptor u, Predicate pred, - undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - remove_out_edge_if(u, pred, g_); - } - - // O(E/V * E) or O(log(E/V) * E) - template - void - remove_edge_if(Predicate pred, undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typename Config::edge_iterator ei, ei_end, next; - boost::tie(ei, ei_end) = edges(g); - for (next = ei; ei != ei_end; ei = next) { - ++next; - if (pred(*ei)) - remove_edge(*ei, g); - } - } - - // O(1) - template - inline std::pair - edges(const undirected_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_iterator edge_iterator; - const graph_type& cg = static_cast(g_); - graph_type& g = const_cast(cg); - return std::make_pair( edge_iterator(g.m_edges.begin()), - edge_iterator(g.m_edges.end()) ); - } - // O(1) - template - inline typename Config::edges_size_type - num_edges(const undirected_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - const graph_type& g = static_cast(g_); - return g.m_edges.size(); - } - // O(E/V * E/V) - template - inline void - clear_vertex(typename Config::vertex_descriptor u, - undirected_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - while (true) { - typename Config::out_edge_iterator ei, ei_end; - boost::tie(ei, ei_end) = out_edges(u, g); - if (ei == ei_end) break; - remove_edge(*ei, g); - } - } - // O(1) for allow_parallel_edge_tag - // O(log(E/V)) for disallow_parallel_edge_tag - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const typename Config::edge_property_type& p, - undirected_graph_helper& g_) - { - typedef typename Config::StoredEdge StoredEdge; - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - - bool inserted; - typename Config::EdgeContainer::value_type e(u, v, p); - typename Config::EdgeContainer::iterator p_iter - = graph_detail::push(g.m_edges, e).first; - - typename Config::OutEdgeList::iterator i; - boost::tie(i, inserted) = boost::graph_detail::push(g.out_edge_list(u), - StoredEdge(v, p_iter, &g.m_edges)); - if (inserted) { - boost::graph_detail::push(g.out_edge_list(v), StoredEdge(u, p_iter, &g.m_edges)); - return std::make_pair(edge_descriptor(u, v, &p_iter->get_property()), - true); - } else { - g.m_edges.erase(p_iter); - return std::make_pair - (edge_descriptor(u, v, &i->get_iter()->get_property()), false); - } - } - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - undirected_graph_helper& g_) - { - typename Config::edge_property_type p; - return add_edge(u, v, p, g_); - } - - // O(1) - template - inline typename Config::degree_size_type - degree(typename Config::vertex_descriptor u, - const undirected_graph_helper& g_) - { - typedef typename Config::graph_type Graph; - const Graph& g = static_cast(g_); - return out_degree(u, g); - } - - template - inline std::pair - in_edges(typename Config::vertex_descriptor u, - const undirected_graph_helper& g_) - { - typedef typename Config::graph_type Graph; - const Graph& cg = static_cast(g_); - Graph& g = const_cast(cg); - typedef typename Config::in_edge_iterator in_edge_iterator; - return - std::make_pair(in_edge_iterator(g.out_edge_list(u).begin(), u), - in_edge_iterator(g.out_edge_list(u).end(), u)); - } - - template - inline typename Config::degree_size_type - in_degree(typename Config::vertex_descriptor u, - const undirected_graph_helper& g_) - { return degree(u, g_); } - - //========================================================================= - // Bidirectional Graph Helper Class - - struct bidir_adj_list_traversal_tag : - public virtual vertex_list_graph_tag, - public virtual incidence_graph_tag, - public virtual adjacency_graph_tag, - public virtual edge_list_graph_tag, - public virtual bidirectional_graph_tag { }; - - template - struct bidirectional_graph_helper - : public directed_edges_helper { - typedef bidir_adj_list_traversal_tag traversal_category; - }; - - // Had to make these non-members to avoid accidental instantiation - // on SGI MIPSpro C++ - template - inline typename C::InEdgeList& - in_edge_list(bidirectional_graph_helper&, - typename C::vertex_descriptor v) - { - typename C::stored_vertex* sv = (typename C::stored_vertex*)v; - return sv->m_in_edges; - } - template - inline const typename C::InEdgeList& - in_edge_list(const bidirectional_graph_helper&, - typename C::vertex_descriptor v) { - typename C::stored_vertex* sv = (typename C::stored_vertex*)v; - return sv->m_in_edges; - } - - template - inline void - remove_edge_if(Predicate pred, bidirectional_graph_helper& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typename Config::edge_iterator ei, ei_end, next; - boost::tie(ei, ei_end) = edges(g); - for (next = ei; ei != ei_end; ei = next) { - ++next; - if (pred(*ei)) - remove_edge(*ei, g); - } - } - - template - inline std::pair - in_edges(typename Config::vertex_descriptor u, - const bidirectional_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - const graph_type& cg = static_cast(g_); - graph_type& g = const_cast(cg); - typedef typename Config::in_edge_iterator in_edge_iterator; - return - std::make_pair(in_edge_iterator(in_edge_list(g, u).begin(), u), - in_edge_iterator(in_edge_list(g, u).end(), u)); - } - - // O(1) - template - inline std::pair - edges(const bidirectional_graph_helper& g_) - { - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_iterator edge_iterator; - const graph_type& cg = static_cast(g_); - graph_type& g = const_cast(cg); - return std::make_pair( edge_iterator(g.m_edges.begin()), - edge_iterator(g.m_edges.end()) ); - } - - //========================================================================= - // Bidirectional Graph Helper Class (with edge properties) - - - template - struct bidirectional_graph_helper_with_property - : public bidirectional_graph_helper - { - typedef typename Config::graph_type graph_type; - typedef typename Config::out_edge_iterator out_edge_iterator; - - std::pair - get_parallel_edge_sublist(typename Config::edge_descriptor e, - const graph_type& g, - void*) - { return out_edges(source(e, g), g); } - - std::pair - get_parallel_edge_sublist(typename Config::edge_descriptor e, - const graph_type& g, - setS*) - { return edge_range(source(e, g), target(e, g), g); } - - std::pair - get_parallel_edge_sublist(typename Config::edge_descriptor e, - const graph_type& g, - multisetS*) - { return edge_range(source(e, g), target(e, g), g); } - - std::pair - get_parallel_edge_sublist(typename Config::edge_descriptor e, - const graph_type& g, - hash_setS*) - { return edge_range(source(e, g), target(e, g), g); } - - // Placement of these overloaded remove_edge() functions - // inside the class avoids a VC++ bug. - - // O(E/V) or O(log(E/V)) - void - remove_edge(typename Config::edge_descriptor e) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - graph_type& g = static_cast(*this); - - typedef typename Config::edgelist_selector OutEdgeListS; - - std::pair rng = - get_parallel_edge_sublist(e, g, (OutEdgeListS*)(0)); - rng.first = std::find(rng.first, rng.second, e); - BOOST_ASSERT(rng.first != rng.second); - remove_edge(rng.first); - } - - inline void - remove_edge(typename Config::out_edge_iterator iter) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(*this); - typename Config::edge_descriptor e = *iter; - typename Config::OutEdgeList& oel = g.out_edge_list(source(e, g)); - typename Config::InEdgeList& iel = in_edge_list(g, target(e, g)); - typedef typename Config::OutEdgeList::value_type::property_type PType; - PType& p = *(PType*)e.get_property(); - detail::remove_directed_edge_dispatch(*iter, iel, p); - g.m_edges.erase(iter.base()->get_iter()); - oel.erase(iter.base()); - } - }; - - // O(E/V) for allow_parallel_edge_tag - // O(log(E/V)) for disallow_parallel_edge_tag - template - inline void - remove_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typedef typename Config::edge_parallel_category Cat; - detail::remove_edge_and_property(g, g.out_edge_list(u), v, Cat()); - detail::erase_from_incidence_list(in_edge_list(g, v), u, Cat()); - } - - // O(E/V) or O(log(E/V)) - template - inline void - remove_edge(EdgeOrIter e, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - g_.remove_edge(e); - } - - template - inline void - remove_out_edge_if(typename Config::vertex_descriptor u, Predicate pred, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::OutEdgeList::value_type::property_type PropT; - graph_type& g = static_cast(g_); - - typedef typename Config::EdgeIter EdgeIter; - typedef std::vector Garbage; - Garbage garbage; - - // First remove the edges from the targets' in-edge lists and - // from the graph's edge set list. - typename Config::out_edge_iterator out_i, out_end; - for (boost::tie(out_i, out_end) = out_edges(u, g); out_i != out_end; ++out_i) - if (pred(*out_i)) { - detail::remove_directed_edge_dispatch - (*out_i, in_edge_list(g, target(*out_i, g)), - *(PropT*)(*out_i).get_property()); - // Put in garbage to delete later. Will need the properties - // for the remove_if of the out-edges. - garbage.push_back((*out_i.base()).get_iter()); - } - - // Now remove the edges from this out-edge list. - typename Config::out_edge_iterator first, last; - boost::tie(first, last) = out_edges(u, g); - typedef typename Config::edge_parallel_category Cat; - detail::remove_directed_edge_if_dispatch - (first, last, g.out_edge_list(u), pred, Cat()); - - // Now delete the edge properties from the g.m_edges list - for (typename Garbage::iterator i = garbage.begin(); - i != garbage.end(); ++i) - g.m_edges.erase(*i); - } - template - inline void - remove_in_edge_if(typename Config::vertex_descriptor v, Predicate pred, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::OutEdgeList::value_type::property_type PropT; - graph_type& g = static_cast(g_); - - typedef typename Config::EdgeIter EdgeIter; - typedef std::vector Garbage; - Garbage garbage; - - // First remove the edges from the sources' out-edge lists and - // from the graph's edge set list. - typename Config::in_edge_iterator in_i, in_end; - for (boost::tie(in_i, in_end) = in_edges(v, g); in_i != in_end; ++in_i) - if (pred(*in_i)) { - typename Config::vertex_descriptor u = source(*in_i, g); - detail::remove_directed_edge_dispatch - (*in_i, g.out_edge_list(u), *(PropT*)(*in_i).get_property()); - // Put in garbage to delete later. Will need the properties - // for the remove_if of the out-edges. - garbage.push_back((*in_i.base()).get_iter()); - } - // Now remove the edges from this in-edge list. - typename Config::in_edge_iterator first, last; - boost::tie(first, last) = in_edges(v, g); - typedef typename Config::edge_parallel_category Cat; - detail::remove_directed_edge_if_dispatch - (first, last, in_edge_list(g, v), pred, Cat()); - - // Now delete the edge properties from the g.m_edges list - for (typename Garbage::iterator i = garbage.begin(); - i != garbage.end(); ++i) - g.m_edges.erase(*i); - } - - // O(1) - template - inline typename Config::edges_size_type - num_edges(const bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::graph_type graph_type; - const graph_type& g = static_cast(g_); - return g.m_edges.size(); - } - // O(E/V * E/V) for allow_parallel_edge_tag - // O(E/V * log(E/V)) for disallow_parallel_edge_tag - template - inline void - clear_vertex(typename Config::vertex_descriptor u, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_parallel_category Cat; - graph_type& g = static_cast(g_); - typename Config::OutEdgeList& el = g.out_edge_list(u); - typename Config::OutEdgeList::iterator - ei = el.begin(), ei_end = el.end(); - for (; ei != ei_end; ++ei) { - detail::erase_from_incidence_list - (in_edge_list(g, (*ei).get_target()), u, Cat()); - g.m_edges.erase((*ei).get_iter()); - } - typename Config::InEdgeList& in_el = in_edge_list(g, u); - typename Config::InEdgeList::iterator - in_ei = in_el.begin(), in_ei_end = in_el.end(); - for (; in_ei != in_ei_end; ++in_ei) { - detail::erase_from_incidence_list - (g.out_edge_list((*in_ei).get_target()), u, Cat()); - g.m_edges.erase((*in_ei).get_iter()); - } - g.out_edge_list(u).clear(); - in_edge_list(g, u).clear(); - } - - template - inline void - clear_out_edges(typename Config::vertex_descriptor u, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_parallel_category Cat; - graph_type& g = static_cast(g_); - typename Config::OutEdgeList& el = g.out_edge_list(u); - typename Config::OutEdgeList::iterator - ei = el.begin(), ei_end = el.end(); - for (; ei != ei_end; ++ei) { - detail::erase_from_incidence_list - (in_edge_list(g, (*ei).get_target()), u, Cat()); - g.m_edges.erase((*ei).get_iter()); - } - g.out_edge_list(u).clear(); - } - - template - inline void - clear_in_edges(typename Config::vertex_descriptor u, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Config::graph_type graph_type; - typedef typename Config::edge_parallel_category Cat; - graph_type& g = static_cast(g_); - typename Config::InEdgeList& in_el = in_edge_list(g, u); - typename Config::InEdgeList::iterator - in_ei = in_el.begin(), in_ei_end = in_el.end(); - for (; in_ei != in_ei_end; ++in_ei) { - detail::erase_from_incidence_list - (g.out_edge_list((*in_ei).get_target()), u, Cat()); - g.m_edges.erase((*in_ei).get_iter()); - } - in_edge_list(g, u).clear(); - } - - // O(1) for allow_parallel_edge_tag - // O(log(E/V)) for disallow_parallel_edge_tag - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const typename Config::edge_property_type& p, - bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::graph_type graph_type; - graph_type& g = static_cast(g_); - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::StoredEdge StoredEdge; - bool inserted; - typename Config::EdgeContainer::value_type e(u, v, p); - typename Config::EdgeContainer::iterator p_iter - = graph_detail::push(g.m_edges, e).first; - typename Config::OutEdgeList::iterator i; - boost::tie(i, inserted) = boost::graph_detail::push(g.out_edge_list(u), - StoredEdge(v, p_iter, &g.m_edges)); - if (inserted) { - boost::graph_detail::push(in_edge_list(g, v), StoredEdge(u, p_iter, &g.m_edges)); - return std::make_pair(edge_descriptor(u, v, &p_iter->m_property), - true); - } else { - g.m_edges.erase(p_iter); - return std::make_pair(edge_descriptor(u, v, - &i->get_iter()->get_property()), - false); - } - } - - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - bidirectional_graph_helper_with_property& g_) - { - typename Config::edge_property_type p; - return add_edge(u, v, p, g_); - } - // O(1) - template - inline typename Config::degree_size_type - degree(typename Config::vertex_descriptor u, - const bidirectional_graph_helper_with_property& g_) - { - typedef typename Config::graph_type graph_type; - const graph_type& g = static_cast(g_); - return in_degree(u, g) + out_degree(u, g); - } - - //========================================================================= - // Adjacency List Helper Class - - template - struct adj_list_helper : public Base - { - typedef typename Config::graph_type AdjList; - typedef typename Config::vertex_descriptor vertex_descriptor; - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::out_edge_iterator out_edge_iterator; - typedef typename Config::in_edge_iterator in_edge_iterator; - typedef typename Config::adjacency_iterator adjacency_iterator; - typedef typename Config::inv_adjacency_iterator inv_adjacency_iterator; - typedef typename Config::vertex_iterator vertex_iterator; - typedef typename Config::edge_iterator edge_iterator; - typedef typename Config::directed_category directed_category; - typedef typename Config::edge_parallel_category edge_parallel_category; - typedef typename Config::vertices_size_type vertices_size_type; - typedef typename Config::edges_size_type edges_size_type; - typedef typename Config::degree_size_type degree_size_type; - typedef typename Config::StoredEdge StoredEdge; - typedef typename Config::vertex_property_type vertex_property_type; - typedef typename Config::edge_property_type edge_property_type; - typedef typename Config::graph_property_type graph_property_type; - - typedef typename Config::global_edgelist_selector - global_edgelist_selector; - - typedef typename lookup_one_property::type vertex_bundled; - typedef typename lookup_one_property::type edge_bundled; - typedef typename lookup_one_property::type graph_bundled; - }; - - template - inline std::pair - adjacent_vertices(typename Config::vertex_descriptor u, - const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - const AdjList& cg = static_cast(g_); - AdjList& g = const_cast(cg); - typedef typename Config::adjacency_iterator adjacency_iterator; - typename Config::out_edge_iterator first, last; - boost::tie(first, last) = out_edges(u, g); - return std::make_pair(adjacency_iterator(first, &g), - adjacency_iterator(last, &g)); - } - template - inline std::pair - inv_adjacent_vertices(typename Config::vertex_descriptor u, - const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - const AdjList& cg = static_cast(g_); - AdjList& g = const_cast(cg); - typedef typename Config::inv_adjacency_iterator inv_adjacency_iterator; - typename Config::in_edge_iterator first, last; - boost::tie(first, last) = in_edges(u, g); - return std::make_pair(inv_adjacency_iterator(first, &g), - inv_adjacency_iterator(last, &g)); - } - template - inline std::pair - out_edges(typename Config::vertex_descriptor u, - const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - typedef typename Config::out_edge_iterator out_edge_iterator; - const AdjList& cg = static_cast(g_); - AdjList& g = const_cast(cg); - return - std::make_pair(out_edge_iterator(g.out_edge_list(u).begin(), u), - out_edge_iterator(g.out_edge_list(u).end(), u)); - } - template - inline std::pair - vertices(const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - const AdjList& cg = static_cast(g_); - AdjList& g = const_cast(cg); - return std::make_pair( g.vertex_set().begin(), g.vertex_set().end() ); - } - template - inline typename Config::vertices_size_type - num_vertices(const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - const AdjList& g = static_cast(g_); - return g.vertex_set().size(); - } - template - inline typename Config::degree_size_type - out_degree(typename Config::vertex_descriptor u, - const adj_list_helper& g_) - { - typedef typename Config::graph_type AdjList; - const AdjList& g = static_cast(g_); - return g.out_edge_list(u).size(); - } - template - inline std::pair - edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const adj_list_helper& g_) - { - typedef typename Config::graph_type Graph; - typedef typename Config::StoredEdge StoredEdge; - const Graph& cg = static_cast(g_); - const typename Config::OutEdgeList& el = cg.out_edge_list(u); - typename Config::OutEdgeList::const_iterator it = graph_detail:: - find(el, StoredEdge(v)); - return std::make_pair( - typename Config::edge_descriptor - (u, v, (it == el.end() ? 0 : &(*it).get_property())), - (it != el.end())); - } - - template - inline std::pair - edge_range(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const adj_list_helper& g_) - { - typedef typename Config::graph_type Graph; - typedef typename Config::StoredEdge StoredEdge; - const Graph& cg = static_cast(g_); - Graph& g = const_cast(cg); - typedef typename Config::out_edge_iterator out_edge_iterator; - typename Config::OutEdgeList& el = g.out_edge_list(u); - typename Config::OutEdgeList::iterator first, last; - typename Config::EdgeContainer fake_edge_container; - boost::tie(first, last) = graph_detail:: - equal_range(el, StoredEdge(v, fake_edge_container.end(), - &fake_edge_container)); - return std::make_pair(out_edge_iterator(first, u), - out_edge_iterator(last, u)); - } - - template - inline typename Config::degree_size_type - in_degree(typename Config::vertex_descriptor u, - const directed_edges_helper& g_) - { - typedef typename Config::graph_type Graph; - const Graph& cg = static_cast(g_); - Graph& g = const_cast(cg); - return in_edge_list(g, u).size(); - } - - namespace detail { - template - inline - typename boost::property_map::type - get_dispatch(adj_list_helper&, Property p, - boost::edge_property_tag) { - typedef typename Config::graph_type Graph; - typedef typename boost::property_map::type PA; - return PA(p); - } - template - inline - typename boost::property_map::const_type - get_dispatch(const adj_list_helper&, Property p, - boost::edge_property_tag) { - typedef typename Config::graph_type Graph; - typedef typename boost::property_map::const_type PA; - return PA(p); - } - - template - inline - typename boost::property_map::type - get_dispatch(adj_list_helper& g, Property p, - boost::vertex_property_tag) { - typedef typename Config::graph_type Graph; - typedef typename boost::property_map::type PA; - return PA(&static_cast(g), p); - } - template - inline - typename boost::property_map::const_type - get_dispatch(const adj_list_helper& g, Property p, - boost::vertex_property_tag) { - typedef typename Config::graph_type Graph; - typedef typename boost::property_map::const_type PA; - const Graph& cg = static_cast(g); - return PA(&cg, p); - } - - } // namespace detail - - // Implementation of the PropertyGraph interface - template - inline - typename boost::property_map::type - get(Property p, adj_list_helper& g) { - typedef typename detail::property_kind_from_graph, Property>::type Kind; - return detail::get_dispatch(g, p, Kind()); - } - template - inline - typename boost::property_map::const_type - get(Property p, const adj_list_helper& g) { - typedef typename detail::property_kind_from_graph, Property>::type Kind; - return detail::get_dispatch(g, p, Kind()); - } - - template - inline - typename boost::property_traits< - typename boost::property_map::type - >::reference - get(Property p, adj_list_helper& g, const Key& key) { - return get(get(p, g), key); - } - - template - inline - typename boost::property_traits< - typename boost::property_map::const_type - >::reference - get(Property p, const adj_list_helper& g, const Key& key) { - return get(get(p, g), key); - } - - template - inline void - put(Property p, adj_list_helper& g, - const Key& key, const Value& value) - { - typedef typename Config::graph_type Graph; - typedef typename boost::property_map::type Map; - Map pmap = get(p, static_cast(g)); - put(pmap, key, value); - } - - - //========================================================================= - // Generalize Adjacency List Implementation - - struct adj_list_tag { }; - - template - class adj_list_impl - : public adj_list_helper - { - typedef typename Config::OutEdgeList OutEdgeList; - typedef typename Config::InEdgeList InEdgeList; - typedef typename Config::StoredVertexList StoredVertexList; - public: - typedef typename Config::stored_vertex stored_vertex; - typedef typename Config::EdgeContainer EdgeContainer; - typedef typename Config::vertex_descriptor vertex_descriptor; - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::vertex_iterator vertex_iterator; - typedef typename Config::edge_iterator edge_iterator; - typedef typename Config::edge_parallel_category edge_parallel_category; - typedef typename Config::vertices_size_type vertices_size_type; - typedef typename Config::edges_size_type edges_size_type; - typedef typename Config::degree_size_type degree_size_type; - typedef typename Config::edge_property_type edge_property_type; - typedef adj_list_tag graph_tag; - - static vertex_descriptor null_vertex() - { - return 0; - } - - inline adj_list_impl() { } - - inline adj_list_impl(const adj_list_impl& x) { - copy_impl(x); - } - inline adj_list_impl& operator=(const adj_list_impl& x) { - this->clear(); - copy_impl(x); - return *this; - } - inline void clear() { - for (typename StoredVertexList::iterator i = m_vertices.begin(); - i != m_vertices.end(); ++i) - delete (stored_vertex*)*i; - m_vertices.clear(); - m_edges.clear(); - } - inline adj_list_impl(vertices_size_type num_vertices) { - for (vertices_size_type i = 0; i < num_vertices; ++i) - add_vertex(static_cast(*this)); - } - template - inline adj_list_impl(vertices_size_type num_vertices, - EdgeIterator first, EdgeIterator last) - { - vertex_descriptor* v = new vertex_descriptor[num_vertices]; - for (vertices_size_type i = 0; i < num_vertices; ++i) - v[i] = add_vertex(static_cast(*this)); - - while (first != last) { - add_edge(v[(*first).first], v[(*first).second], *this); - ++first; - } - delete [] v; - } - template - inline adj_list_impl(vertices_size_type num_vertices, - EdgeIterator first, EdgeIterator last, - EdgePropertyIterator ep_iter) - { - vertex_descriptor* v = new vertex_descriptor[num_vertices]; - for (vertices_size_type i = 0; i < num_vertices; ++i) - v[i] = add_vertex(static_cast(*this)); - - while (first != last) { - add_edge(v[(*first).first], v[(*first).second], *ep_iter, *this); - ++first; - ++ep_iter; - } - delete [] v; - } - ~adj_list_impl() { - for (typename StoredVertexList::iterator i = m_vertices.begin(); - i != m_vertices.end(); ++i) - delete (stored_vertex*)*i; - } - // protected: - inline OutEdgeList& out_edge_list(vertex_descriptor v) { - stored_vertex* sv = (stored_vertex*)v; - return sv->m_out_edges; - } - inline const OutEdgeList& out_edge_list(vertex_descriptor v) const { - stored_vertex* sv = (stored_vertex*)v; - return sv->m_out_edges; - } - inline StoredVertexList& vertex_set() { return m_vertices; } - inline const StoredVertexList& vertex_set() const { return m_vertices; } - - inline void copy_impl(const adj_list_impl& x_) - { - const Derived& x = static_cast(x_); - - // Would be better to have a constant time way to get from - // vertices in x to the corresponding vertices in *this. - std::map vertex_map; - - // Copy the stored vertex objects by adding each vertex - // and copying its property object. - vertex_iterator vi, vi_end; - for (boost::tie(vi, vi_end) = vertices(x); vi != vi_end; ++vi) { - stored_vertex* v = (stored_vertex*)add_vertex(*this); - v->m_property = ((stored_vertex*)*vi)->m_property; - vertex_map[(stored_vertex*)*vi] = v; - } - // Copy the edges by adding each edge and copying its - // property object. - edge_iterator ei, ei_end; - for (boost::tie(ei, ei_end) = edges(x); ei != ei_end; ++ei) { - edge_descriptor e; - bool inserted; - vertex_descriptor s = source(*ei,x), t = target(*ei,x); - boost::tie(e, inserted) = add_edge(vertex_map[(stored_vertex*)s], - vertex_map[(stored_vertex*)t], *this); - *((edge_property_type*)e.m_eproperty) - = *((edge_property_type*)(*ei).m_eproperty); - } - } - - - typename Config::EdgeContainer m_edges; - StoredVertexList m_vertices; - }; - - // O(1) - template - inline typename Config::vertex_descriptor - add_vertex(adj_list_impl& g_) - { - Derived& g = static_cast(g_); - typedef typename Config::stored_vertex stored_vertex; - stored_vertex* v = new stored_vertex; - typename Config::StoredVertexList::iterator pos; - bool inserted; - boost::tie(pos,inserted) = boost::graph_detail::push(g.m_vertices, v); - v->m_position = pos; - g.added_vertex(v); - return v; - } - // O(1) - template - inline typename Config::vertex_descriptor - add_vertex(const typename Config::vertex_property_type& p, - adj_list_impl& g_) - { - typedef typename Config::vertex_descriptor vertex_descriptor; - Derived& g = static_cast(g_); - if (optional v - = g.vertex_by_property(get_property_value(p, vertex_bundle))) - return *v; - - typedef typename Config::stored_vertex stored_vertex; - stored_vertex* v = new stored_vertex(p); - typename Config::StoredVertexList::iterator pos; - bool inserted; - boost::tie(pos,inserted) = boost::graph_detail::push(g.m_vertices, v); - v->m_position = pos; - g.added_vertex(v); - return v; - } - // O(1) - template - inline void remove_vertex(typename Config::vertex_descriptor u, - adj_list_impl& g_) - { - typedef typename Config::stored_vertex stored_vertex; - Derived& g = static_cast(g_); - g.removing_vertex(u, boost::graph_detail::iterator_stability(g_.m_vertices)); - stored_vertex* su = (stored_vertex*)u; - g.m_vertices.erase(su->m_position); - delete su; - } - // O(V) - template - inline typename Config::vertex_descriptor - vertex(typename Config::vertices_size_type n, - const adj_list_impl& g_) - { - const Derived& g = static_cast(g_); - typename Config::vertex_iterator i = vertices(g).first; - while (n--) ++i; // std::advance(i, n); (not VC++ portable) - return *i; - } - - //========================================================================= - // Vector-Backbone Adjacency List Implementation - - namespace detail { - - template - inline void - remove_vertex_dispatch(Graph& g, vertex_descriptor u, - boost::directed_tag) - { - typedef typename Graph::edge_parallel_category edge_parallel_category; - g.m_vertices.erase(g.m_vertices.begin() + u); - vertex_descriptor V = num_vertices(g); - if (u != V) { - for (vertex_descriptor v = 0; v < V; ++v) - reindex_edge_list(g.out_edge_list(v), u, edge_parallel_category()); - } - } - - template - inline void - remove_vertex_dispatch(Graph& g, vertex_descriptor u, - boost::undirected_tag) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Graph::edge_parallel_category edge_parallel_category; - g.m_vertices.erase(g.m_vertices.begin() + u); - vertex_descriptor V = num_vertices(g); - for (vertex_descriptor v = 0; v < V; ++v) - reindex_edge_list(g.out_edge_list(v), u, - edge_parallel_category()); - typedef typename Graph::EdgeContainer Container; - typedef typename Container::iterator Iter; - Iter ei = g.m_edges.begin(), ei_end = g.m_edges.end(); - for (; ei != ei_end; ++ei) { - if (ei->m_source > u) - --ei->m_source; - if (ei->m_target > u) - --ei->m_target; - } - } - template - inline void - remove_vertex_dispatch(Graph& g, vertex_descriptor u, - boost::bidirectional_tag) - { - typedef typename Graph::global_edgelist_selector EdgeListS; - BOOST_STATIC_ASSERT((!is_same::value)); - - typedef typename Graph::edge_parallel_category edge_parallel_category; - g.m_vertices.erase(g.m_vertices.begin() + u); - vertex_descriptor V = num_vertices(g); - vertex_descriptor v; - if (u != V) { - for (v = 0; v < V; ++v) - reindex_edge_list(g.out_edge_list(v), u, - edge_parallel_category()); - for (v = 0; v < V; ++v) - reindex_edge_list(in_edge_list(g, v), u, - edge_parallel_category()); - - typedef typename Graph::EdgeContainer Container; - typedef typename Container::iterator Iter; - Iter ei = g.m_edges.begin(), ei_end = g.m_edges.end(); - for (; ei != ei_end; ++ei) { - if (ei->m_source > u) - --ei->m_source; - if (ei->m_target > u) - --ei->m_target; - } - } - } - - template - inline void - reindex_edge_list(EdgeList& el, vertex_descriptor u, - boost::allow_parallel_edge_tag) - { - typename EdgeList::iterator ei = el.begin(), e_end = el.end(); - for (; ei != e_end; ++ei) - if ((*ei).get_target() > u) - --(*ei).get_target(); - } - template - inline void - reindex_edge_list(EdgeList& el, vertex_descriptor u, - boost::disallow_parallel_edge_tag) - { - typename EdgeList::iterator ei = el.begin(), e_end = el.end(); - while (ei != e_end) { - typename EdgeList::value_type ce = *ei; - ++ei; - if (ce.get_target() > u) { - el.erase(ce); - --ce.get_target(); - el.insert(ce); - } - } - } - } // namespace detail - - struct vec_adj_list_tag { }; - - template - class vec_adj_list_impl - : public adj_list_helper - { - typedef typename Config::OutEdgeList OutEdgeList; - typedef typename Config::InEdgeList InEdgeList; - typedef typename Config::StoredVertexList StoredVertexList; - public: - typedef typename Config::vertex_descriptor vertex_descriptor; - typedef typename Config::edge_descriptor edge_descriptor; - typedef typename Config::out_edge_iterator out_edge_iterator; - typedef typename Config::edge_iterator edge_iterator; - typedef typename Config::directed_category directed_category; - typedef typename Config::vertices_size_type vertices_size_type; - typedef typename Config::edges_size_type edges_size_type; - typedef typename Config::degree_size_type degree_size_type; - typedef typename Config::StoredEdge StoredEdge; - typedef typename Config::stored_vertex stored_vertex; - typedef typename Config::EdgeContainer EdgeContainer; - typedef typename Config::edge_property_type edge_property_type; - typedef vec_adj_list_tag graph_tag; - - static vertex_descriptor null_vertex() - { - return (std::numeric_limits::max)(); - } - - inline vec_adj_list_impl() { } - - inline vec_adj_list_impl(const vec_adj_list_impl& x) { - copy_impl(x); - } - inline vec_adj_list_impl& operator=(const vec_adj_list_impl& x) { - this->clear(); - copy_impl(x); - return *this; - } - inline void clear() { - m_vertices.clear(); - m_edges.clear(); - } - - inline vec_adj_list_impl(vertices_size_type _num_vertices) - : m_vertices(_num_vertices) { } - - template - inline vec_adj_list_impl(vertices_size_type num_vertices, - EdgeIterator first, EdgeIterator last) - : m_vertices(num_vertices) - { - while (first != last) { - add_edge((*first).first, (*first).second, - static_cast(*this)); - ++first; - } - } - template - inline vec_adj_list_impl(vertices_size_type num_vertices, - EdgeIterator first, EdgeIterator last, - EdgePropertyIterator ep_iter) - : m_vertices(num_vertices) - { - while (first != last) { - add_edge((*first).first, (*first).second, *ep_iter, - static_cast(*this)); - ++first; - ++ep_iter; - } - } - - // protected: - inline boost::integer_range vertex_set() const { - return boost::integer_range(0, m_vertices.size()); - } - inline OutEdgeList& out_edge_list(vertex_descriptor v) { - return m_vertices[v].m_out_edges; - } - inline const OutEdgeList& out_edge_list(vertex_descriptor v) const { - return m_vertices[v].m_out_edges; - } - inline void copy_impl(const vec_adj_list_impl& x_) - { - const Graph& x = static_cast(x_); - // Copy the stored vertex objects by adding each vertex - // and copying its property object. - for (vertices_size_type i = 0; i < num_vertices(x); ++i) { - vertex_descriptor v = add_vertex(*this); - m_vertices[v].m_property = x.m_vertices[i].m_property; - } - // Copy the edges by adding each edge and copying its - // property object. - edge_iterator ei, ei_end; - for (boost::tie(ei, ei_end) = edges(x); ei != ei_end; ++ei) { - edge_descriptor e; - bool inserted; - boost::tie(e, inserted) = add_edge(source(*ei,x), target(*ei,x) , *this); - *((edge_property_type*)e.m_eproperty) - = *((edge_property_type*)(*ei).m_eproperty); - } - } - typename Config::EdgeContainer m_edges; - StoredVertexList m_vertices; - }; - // Had to make these non-members to avoid accidental instantiation - // on SGI MIPSpro C++ - template - inline typename C::InEdgeList& - in_edge_list(vec_adj_list_impl& g, - typename C::vertex_descriptor v) { - return g.m_vertices[v].m_in_edges; - } - template - inline const typename C::InEdgeList& - in_edge_list(const vec_adj_list_impl& g, - typename C::vertex_descriptor v) { - return g.m_vertices[v].m_in_edges; - } - - // O(1) - template - inline typename Config::vertex_descriptor - add_vertex(vec_adj_list_impl& g_) { - Graph& g = static_cast(g_); - g.m_vertices.resize(g.m_vertices.size() + 1); - g.added_vertex(g.m_vertices.size() - 1); - return g.m_vertices.size() - 1; - } - - template - inline typename Config::vertex_descriptor - add_vertex(const typename Config::vertex_property_type& p, - vec_adj_list_impl& g_) { - typedef typename Config::vertex_descriptor vertex_descriptor; - Graph& g = static_cast(g_); - if (optional v - = g.vertex_by_property(get_property_value(p, vertex_bundle))) - return *v; - typedef typename Config::stored_vertex stored_vertex; - g.m_vertices.push_back(stored_vertex(p)); - g.added_vertex(g.m_vertices.size() - 1); - return g.m_vertices.size() - 1; - } - - // Here we override the directed_graph_helper add_edge() function - // so that the number of vertices is automatically changed if - // either u or v is greater than the number of vertices. - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - const typename Config::edge_property_type& p, - vec_adj_list_impl& g_) - { - BOOST_USING_STD_MAX(); - typename Config::vertex_descriptor x = max BOOST_PREVENT_MACRO_SUBSTITUTION(u, v); - if (x >= num_vertices(g_)) - g_.m_vertices.resize(x + 1); - adj_list_helper& g = g_; - return add_edge(u, v, p, g); - } - template - inline std::pair - add_edge(typename Config::vertex_descriptor u, - typename Config::vertex_descriptor v, - vec_adj_list_impl& g_) - { - typename Config::edge_property_type p; - return add_edge(u, v, p, g_); - } - - - // O(V + E) - template - inline void remove_vertex(typename Config::vertex_descriptor v, - vec_adj_list_impl& g_) - { - typedef typename Config::directed_category Cat; - Graph& g = static_cast(g_); - g.removing_vertex(v, boost::graph_detail::iterator_stability(g_.m_vertices)); - detail::remove_vertex_dispatch(g, v, Cat()); - } - // O(1) - template - inline typename Config::vertex_descriptor - vertex(typename Config::vertices_size_type n, - const vec_adj_list_impl&) - { - return n; - } - - - namespace detail { - - //========================================================================= - // Adjacency List Generator - - template - struct adj_list_gen - { - typedef typename detail::is_random_access::type - is_rand_access; - typedef typename has_property::type has_edge_property; - typedef typename DirectedS::is_directed_t DirectedT; - typedef typename DirectedS::is_bidir_t BidirectionalT; - - struct config - { - typedef OutEdgeListS edgelist_selector; - typedef EdgeListS global_edgelist_selector; - - typedef Graph graph_type; - typedef EdgeProperty edge_property_type; - typedef VertexProperty vertex_property_type; - typedef GraphProperty graph_property_type; - typedef std::size_t vertices_size_type; - - typedef adjacency_list_traits - Traits; - - typedef typename Traits::directed_category directed_category; - typedef typename Traits::edge_parallel_category edge_parallel_category; - typedef typename Traits::vertex_descriptor vertex_descriptor; - typedef typename Traits::edge_descriptor edge_descriptor; - - typedef void* vertex_ptr; - - // need to reorganize this to avoid instantiating stuff - // that doesn't get used -JGS - - // VertexList and vertex_iterator - typedef typename container_gen::type SeqVertexList; - typedef boost::integer_range RandVertexList; - typedef typename mpl::if_::type VertexList; - - typedef typename VertexList::iterator vertex_iterator; - - // EdgeContainer and StoredEdge - - typedef typename container_gen >::type EdgeContainer; - - typedef typename mpl::and_::type >::type on_edge_storage; - - typedef typename mpl::if_::type edges_size_type; - - typedef typename EdgeContainer::iterator EdgeIter; - - typedef typename detail::is_random_access::type is_edge_ra; - - typedef typename mpl::if_, - typename mpl::if_, - stored_edge_iter - >::type - >::type StoredEdge; - - // Adjacency Types - - typedef typename container_gen::type - OutEdgeList; - typedef typename OutEdgeList::size_type degree_size_type; - typedef typename OutEdgeList::iterator OutEdgeIter; - - typedef boost::detail::iterator_traits OutEdgeIterTraits; - typedef typename OutEdgeIterTraits::iterator_category OutEdgeIterCat; - typedef typename OutEdgeIterTraits::difference_type OutEdgeIterDiff; - - typedef out_edge_iter< - OutEdgeIter, vertex_descriptor, edge_descriptor, OutEdgeIterDiff - > out_edge_iterator; - - typedef typename adjacency_iterator_generator::type adjacency_iterator; - - typedef OutEdgeList InEdgeList; - typedef OutEdgeIter InEdgeIter; - typedef OutEdgeIterCat InEdgeIterCat; - typedef OutEdgeIterDiff InEdgeIterDiff; - - typedef in_edge_iter< - InEdgeIter, vertex_descriptor, edge_descriptor, InEdgeIterDiff - > in_edge_iterator; - - typedef typename inv_adjacency_iterator_generator::type inv_adjacency_iterator; - - // Edge Iterator - - typedef boost::detail::iterator_traits EdgeIterTraits; - typedef typename EdgeIterTraits::iterator_category EdgeIterCat; - typedef typename EdgeIterTraits::difference_type EdgeIterDiff; - - typedef undirected_edge_iter< - EdgeIter - , edge_descriptor - , EdgeIterDiff - > UndirectedEdgeIter; // also used for bidirectional - - typedef adj_list_edge_iterator DirectedEdgeIter; - - typedef typename mpl::if_::type edge_iterator; - - // stored_vertex and StoredVertexList - typedef typename container_gen::type - SeqStoredVertexList; - struct seq_stored_vertex { - seq_stored_vertex() { } - seq_stored_vertex(const VertexProperty& p) : m_property(p) { } - OutEdgeList m_out_edges; - VertexProperty m_property; - typename SeqStoredVertexList::iterator m_position; - }; - struct bidir_seq_stored_vertex { - bidir_seq_stored_vertex() { } - bidir_seq_stored_vertex(const VertexProperty& p) : m_property(p) { } - OutEdgeList m_out_edges; - InEdgeList m_in_edges; - VertexProperty m_property; - typename SeqStoredVertexList::iterator m_position; - }; - struct rand_stored_vertex { - rand_stored_vertex() { } - rand_stored_vertex(const VertexProperty& p) : m_property(p) { } - OutEdgeList m_out_edges; - VertexProperty m_property; - }; - struct bidir_rand_stored_vertex { - bidir_rand_stored_vertex() { } - bidir_rand_stored_vertex(const VertexProperty& p) : m_property(p) { } - OutEdgeList m_out_edges; - InEdgeList m_in_edges; - VertexProperty m_property; - }; - typedef typename mpl::if_::type, - typename mpl::if_::type - >::type StoredVertex; - struct stored_vertex : public StoredVertex { - stored_vertex() { } - stored_vertex(const VertexProperty& p) : StoredVertex(p) { } - }; - - typedef typename container_gen::type - RandStoredVertexList; - typedef typename mpl::if_< is_rand_access, - RandStoredVertexList, SeqStoredVertexList>::type StoredVertexList; - }; // end of config - - - typedef typename mpl::if_, - typename mpl::if_, - undirected_graph_helper - >::type - >::type DirectedHelper; - - typedef typename mpl::if_, - adj_list_impl - >::type type; - - }; - - } // namespace detail - - //========================================================================= - // Vertex Property Maps - - template - struct adj_list_vertex_property_map - : public boost::put_get_helper< - Reference, - adj_list_vertex_property_map - > - { - typedef typename Graph::stored_vertex StoredVertex; - typedef ValueType value_type; - typedef Reference reference; - typedef typename Graph::vertex_descriptor key_type; - typedef boost::lvalue_property_map_tag category; - inline adj_list_vertex_property_map(const Graph* = 0, Tag tag = Tag()): m_tag(tag) { } - inline Reference operator[](key_type v) const { - StoredVertex* sv = (StoredVertex*)v; - return get_property_value(sv->m_property, m_tag); - } - inline Reference operator()(key_type v) const { - return this->operator[](v); - } - Tag m_tag; - }; - - template - struct adj_list_vertex_all_properties_map - : public boost::put_get_helper - > - { - typedef typename Graph::stored_vertex StoredVertex; - typedef Property value_type; - typedef PropRef reference; - typedef typename Graph::vertex_descriptor key_type; - typedef boost::lvalue_property_map_tag category; - inline adj_list_vertex_all_properties_map(const Graph* = 0, vertex_all_t = vertex_all_t()) { } - inline PropRef operator[](key_type v) const { - StoredVertex* sv = (StoredVertex*)v; - return sv->m_property; - } - inline PropRef operator()(key_type v) const { - return this->operator[](v); - } - }; - - template - struct vec_adj_list_vertex_property_map - : public boost::put_get_helper< - Reference, - vec_adj_list_vertex_property_map - > - { - typedef ValueType value_type; - typedef Reference reference; - typedef typename boost::graph_traits::vertex_descriptor key_type; - typedef boost::lvalue_property_map_tag category; - vec_adj_list_vertex_property_map(GraphPtr g = 0, Tag tag = Tag()) : m_g(g), m_tag(tag) { } - inline Reference operator[](key_type v) const { - return get_property_value(m_g->m_vertices[v].m_property, m_tag); - } - inline Reference operator()(key_type v) const { - return this->operator[](v); - } - GraphPtr m_g; - Tag m_tag; - }; - - template - struct vec_adj_list_vertex_all_properties_map - : public boost::put_get_helper - > - { - typedef Property value_type; - typedef PropertyRef reference; - typedef typename boost::graph_traits::vertex_descriptor key_type; - typedef boost::lvalue_property_map_tag category; - vec_adj_list_vertex_all_properties_map(GraphPtr g = 0, vertex_all_t = vertex_all_t()) : m_g(g) { } - inline PropertyRef operator[](key_type v) const { - return m_g->m_vertices[v].m_property; - } - inline PropertyRef operator()(key_type v) const { - return this->operator[](v); - } - GraphPtr m_g; - }; - - struct adj_list_any_vertex_pa { - template - struct bind_ { - typedef typename property_value::type value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - - typedef adj_list_vertex_property_map - type; - typedef adj_list_vertex_property_map - const_type; - }; - }; - struct adj_list_all_vertex_pa { - template - struct bind_ { - typedef typename Graph::vertex_descriptor Vertex; - typedef adj_list_vertex_all_properties_map type; - typedef adj_list_vertex_all_properties_map const_type; - }; - }; - - template - struct vec_adj_list_vertex_id_map - : public boost::put_get_helper< - Vertex, vec_adj_list_vertex_id_map - > - { - typedef Vertex value_type; - typedef Vertex key_type; - typedef Vertex reference; - typedef boost::readable_property_map_tag category; - inline vec_adj_list_vertex_id_map() { } - template - inline vec_adj_list_vertex_id_map(const Graph&, vertex_index_t) { } - inline value_type operator[](key_type v) const { return v; } - inline value_type operator()(key_type v) const { return v; } - }; - - struct vec_adj_list_any_vertex_pa { - template - struct bind_ { - typedef typename property_value::type value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - - typedef vec_adj_list_vertex_property_map - type; - typedef vec_adj_list_vertex_property_map - const_type; - }; - }; - struct vec_adj_list_id_vertex_pa { - template - struct bind_ { - typedef typename Graph::vertex_descriptor Vertex; - typedef vec_adj_list_vertex_id_map type; - typedef vec_adj_list_vertex_id_map const_type; - }; - }; - struct vec_adj_list_all_vertex_pa { - template - struct bind_ { - typedef typename Graph::vertex_descriptor Vertex; - typedef vec_adj_list_vertex_all_properties_map - type; - typedef vec_adj_list_vertex_all_properties_map - const_type; - }; - }; - namespace detail { - template - struct adj_list_choose_vertex_pa - : boost::mpl::if_< - boost::is_same, - adj_list_all_vertex_pa, - adj_list_any_vertex_pa>::type - ::template bind_ - {}; - - - template - struct vec_adj_list_choose_vertex_pa_helper { - typedef vec_adj_list_any_vertex_pa type; - }; - template <> - struct vec_adj_list_choose_vertex_pa_helper { - typedef vec_adj_list_id_vertex_pa type; - }; - template <> - struct vec_adj_list_choose_vertex_pa_helper { - typedef vec_adj_list_all_vertex_pa type; - }; - template - struct vec_adj_list_choose_vertex_pa - : vec_adj_list_choose_vertex_pa_helper::type::template bind_ - {}; - } // namespace detail - - //========================================================================= - // Edge Property Map - - template - struct adj_list_edge_property_map - : public put_get_helper< - Ref, - adj_list_edge_property_map - > - { - Tag tag; - explicit adj_list_edge_property_map(Tag tag = Tag()): tag(tag) {} - - typedef Value value_type; - typedef Ref reference; - typedef detail::edge_desc_impl key_type; - typedef boost::lvalue_property_map_tag category; - inline Ref operator[](key_type e) const { - Property& p = *(Property*)e.get_property(); - return get_property_value(p, tag); - } - inline Ref operator()(key_type e) const { - return this->operator[](e); - } - }; - - template - struct adj_list_edge_all_properties_map - : public put_get_helper - > - { - explicit adj_list_edge_all_properties_map(edge_all_t = edge_all_t()) {} - typedef Property value_type; - typedef PropRef reference; - typedef detail::edge_desc_impl key_type; - typedef boost::lvalue_property_map_tag category; - inline PropRef operator[](key_type e) const { - return *(PropPtr)e.get_property(); - } - inline PropRef operator()(key_type e) const { - return this->operator[](e); - } - }; - - // Edge Property Maps - - namespace detail { - struct adj_list_any_edge_pmap { - template - struct bind_ { - typedef typename property_value::type value_type; - typedef value_type& reference; - typedef const value_type& const_reference; - - typedef adj_list_edge_property_map - type; - typedef adj_list_edge_property_map - const_type; - }; - }; - struct adj_list_all_edge_pmap { - template - struct bind_ { - typedef adj_list_edge_all_properties_map - type; - typedef adj_list_edge_all_properties_map - const_type; - }; - }; - - template - struct adj_list_choose_edge_pmap_helper { - typedef adj_list_any_edge_pmap type; - }; - template <> - struct adj_list_choose_edge_pmap_helper { - typedef adj_list_all_edge_pmap type; - }; - template - struct adj_list_choose_edge_pmap - : adj_list_choose_edge_pmap_helper::type::template bind_ - {}; - struct adj_list_edge_property_selector { - template - struct bind_: adj_list_choose_edge_pmap {}; - }; - } // namespace detail - - template <> - struct edge_property_selector { - typedef detail::adj_list_edge_property_selector type; - }; - template <> - struct edge_property_selector { - typedef detail::adj_list_edge_property_selector type; - }; - - // Vertex Property Maps - - struct adj_list_vertex_property_selector { - template - struct bind_ - : detail::adj_list_choose_vertex_pa - {}; - }; - template <> - struct vertex_property_selector { - typedef adj_list_vertex_property_selector type; - }; - - struct vec_adj_list_vertex_property_selector { - template - struct bind_: detail::vec_adj_list_choose_vertex_pa {}; - }; - template <> - struct vertex_property_selector { - typedef vec_adj_list_vertex_property_selector type; - }; - -} // namespace boost - -#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -namespace boost { - - template - struct hash< boost::detail::stored_edge > - { - std::size_t - operator()(const boost::detail::stored_edge& e) const - { - return hash()(e.m_target); - } - }; - - template - struct hash< boost::detail::stored_edge_property > - { - std::size_t - operator()(const boost::detail::stored_edge_property& e) const - { - return hash()(e.m_target); - } - }; - - template - struct hash< boost::detail::stored_edge_iter > - { - std::size_t - operator()(const boost::detail::stored_edge_iter& e) const - { - return hash()(e.m_target); - } - }; - -} -#endif - - -#endif // BOOST_GRAPH_DETAIL_DETAIL_ADJACENCY_LIST_CCT - -/* - Implementation Notes: - - Many of the public interface functions in this file would have been - more conveniently implemented as inline friend functions. - However there are a few compiler bugs that make that approach - non-portable. - - 1. g++ inline friend in namespace bug - 2. g++ using clause doesn't work with inline friends - 3. VC++ doesn't have Koenig lookup - - For these reasons, the functions were all written as non-inline free - functions, and static cast was used to convert from the helper - class to the adjacency_list derived class. - - Looking back, it might have been better to write out all functions - in terms of the adjacency_list, and then use a tag to dispatch - to the various helpers instead of using inheritance. - - */ diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/d_ary_heap.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/detail/d_ary_heap.hpp deleted file mode 100644 index cf930fc1..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/d_ary_heap.hpp +++ /dev/null @@ -1,319 +0,0 @@ -// -//======================================================================= -// Copyright 2009 Trustees of Indiana University -// Authors: Jeremiah J. Willcock, Andrew Lumsdaine -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= -// -#ifndef BOOST_D_ARY_HEAP_HPP -#define BOOST_D_ARY_HEAP_HPP - -#include -#include -#include -#include -#include -#include -#include -#include - -// WARNING: it is not safe to copy a d_ary_heap_indirect and then modify one of -// the copies. The class is required to be copyable so it can be passed around -// (without move support from C++11), but it deep-copies the heap contents yet -// shallow-copies the index_in_heap_map. - -namespace boost { - - // Swap two elements in a property map without assuming they model - // LvaluePropertyMap -- currently not used - template - inline void property_map_swap( - PropMap prop_map, - const typename boost::property_traits::key_type& ka, - const typename boost::property_traits::key_type& kb) { - typename boost::property_traits::value_type va = get(prop_map, ka); - put(prop_map, ka, get(prop_map, kb)); - put(prop_map, kb, va); - } - - namespace detail { - template - class fixed_max_size_vector { - boost::shared_array m_data; - std::size_t m_size; - - public: - typedef std::size_t size_type; - fixed_max_size_vector(std::size_t max_size) - : m_data(new Value[max_size]), m_size(0) {} - std::size_t size() const {return m_size;} - bool empty() const {return m_size == 0;} - Value& operator[](std::size_t i) {return m_data[i];} - const Value& operator[](std::size_t i) const {return m_data[i];} - void push_back(Value v) {m_data[m_size++] = v;} - void pop_back() {--m_size;} - Value& back() {return m_data[m_size - 1];} - const Value& back() const {return m_data[m_size - 1];} - }; - } - - // D-ary heap using an indirect compare operator (use identity_property_map - // as DistanceMap to get a direct compare operator). This heap appears to be - // commonly used for Dijkstra's algorithm for its good practical performance - // on some platforms; asymptotically, it has an O(lg N) decrease-key - // operation while that can be done in constant time on a relaxed heap. The - // implementation is mostly based on the binary heap page on Wikipedia and - // online sources that state that the operations are the same for d-ary - // heaps. This code is not based on the old Boost d-ary heap code. - // - // - d_ary_heap_indirect is a model of UpdatableQueue as is needed for - // dijkstra_shortest_paths. - // - // - Value must model Assignable. - // - Arity must be at least 2 (optimal value appears to be 4, both in my and - // third-party experiments). - // - IndexInHeapMap must be a ReadWritePropertyMap from Value to - // Container::size_type (to store the index of each stored value within the - // heap for decrease-key aka update). - // - DistanceMap must be a ReadablePropertyMap from Value to something - // (typedef'ed as distance_type). - // - Compare must be a BinaryPredicate used as a less-than operator on - // distance_type. - // - Container must be a random-access, contiguous container (in practice, - // the operations used probably require that it is std::vector). - // - template , - typename Container = std::vector > - class d_ary_heap_indirect { - BOOST_STATIC_ASSERT (Arity >= 2); - - public: - typedef typename Container::size_type size_type; - typedef Value value_type; - typedef typename boost::property_traits::value_type key_type; - typedef DistanceMap key_map; - - d_ary_heap_indirect(DistanceMap distance, - IndexInHeapPropertyMap index_in_heap, - const Compare& compare = Compare(), - const Container& data = Container()) - : compare(compare), data(data), distance(distance), - index_in_heap(index_in_heap) {} - /* Implicit copy constructor */ - /* Implicit assignment operator */ - - size_type size() const { - return data.size(); - } - - bool empty() const { - return data.empty(); - } - - void push(const Value& v) { - size_type index = data.size(); - data.push_back(v); - put(index_in_heap, v, index); - preserve_heap_property_up(index); - verify_heap(); - } - - Value& top() { - BOOST_ASSERT (!this->empty()); - return data[0]; - } - - const Value& top() const { - BOOST_ASSERT (!this->empty()); - return data[0]; - } - - void pop() { - BOOST_ASSERT (!this->empty()); - put(index_in_heap, data[0], (size_type)(-1)); - if (data.size() != 1) { - data[0] = data.back(); - put(index_in_heap, data[0], (size_type)(0)); - data.pop_back(); - preserve_heap_property_down(); - verify_heap(); - } else { - data.pop_back(); - } - } - - // This function assumes the key has been updated (using an external write - // to the distance map or such) - // See http://coding.derkeiler.com/Archive/General/comp.theory/2007-05/msg00043.html - void update(const Value& v) { /* decrease-key */ - size_type index = get(index_in_heap, v); - preserve_heap_property_up(index); - verify_heap(); - } - - bool contains(const Value& v) const { - size_type index = get(index_in_heap, v); - return (index != (size_type)(-1)); - } - - void push_or_update(const Value& v) { /* insert if not present, else update */ - size_type index = get(index_in_heap, v); - if (index == (size_type)(-1)) { - index = data.size(); - data.push_back(v); - put(index_in_heap, v, index); - } - preserve_heap_property_up(index); - verify_heap(); - } - - DistanceMap keys() const { - return distance; - } - - private: - Compare compare; - Container data; - DistanceMap distance; - IndexInHeapPropertyMap index_in_heap; - - // The distances being compared using compare and that are stored in the - // distance map - typedef typename boost::property_traits::value_type distance_type; - - // Get the parent of a given node in the heap - static size_type parent(size_type index) { - return (index - 1) / Arity; - } - - // Get the child_idx'th child of a given node; 0 <= child_idx < Arity - static size_type child(size_type index, std::size_t child_idx) { - return index * Arity + child_idx + 1; - } - - // Swap two elements in the heap by index, updating index_in_heap - void swap_heap_elements(size_type index_a, size_type index_b) { - using std::swap; - Value value_a = data[index_a]; - Value value_b = data[index_b]; - data[index_a] = value_b; - data[index_b] = value_a; - put(index_in_heap, value_a, index_b); - put(index_in_heap, value_b, index_a); - } - - // Emulate the indirect_cmp that is now folded into this heap class - bool compare_indirect(const Value& a, const Value& b) const { - return compare(get(distance, a), get(distance, b)); - } - - // Verify that the array forms a heap; commented out by default - void verify_heap() const { - // This is a very expensive test so it should be disabled even when - // NDEBUG is not defined -#if 0 - for (size_t i = 1; i < data.size(); ++i) { - if (compare_indirect(data[i], data[parent(i)])) { - BOOST_ASSERT (!"Element is smaller than its parent"); - } - } -#endif - } - - // Starting at a node, move up the tree swapping elements to preserve the - // heap property - void preserve_heap_property_up(size_type index) { - size_type orig_index = index; - size_type num_levels_moved = 0; - // The first loop just saves swaps that need to be done in order to avoid - // aliasing issues in its search; there is a second loop that does the - // necessary swap operations - if (index == 0) return; // Do nothing on root - Value currently_being_moved = data[index]; - distance_type currently_being_moved_dist = - get(distance, currently_being_moved); - for (;;) { - if (index == 0) break; // Stop at root - size_type parent_index = parent(index); - Value parent_value = data[parent_index]; - if (compare(currently_being_moved_dist, get(distance, parent_value))) { - ++num_levels_moved; - index = parent_index; - continue; - } else { - break; // Heap property satisfied - } - } - // Actually do the moves -- move num_levels_moved elements down in the - // tree, then put currently_being_moved at the top - index = orig_index; - for (size_type i = 0; i < num_levels_moved; ++i) { - size_type parent_index = parent(index); - Value parent_value = data[parent_index]; - put(index_in_heap, parent_value, index); - data[index] = parent_value; - index = parent_index; - } - data[index] = currently_being_moved; - put(index_in_heap, currently_being_moved, index); - verify_heap(); - } - - // From the root, swap elements (each one with its smallest child) if there - // are any parent-child pairs that violate the heap property - void preserve_heap_property_down() { - if (data.empty()) return; - size_type index = 0; - Value currently_being_moved = data[0]; - distance_type currently_being_moved_dist = - get(distance, currently_being_moved); - size_type heap_size = data.size(); - Value* data_ptr = &data[0]; - for (;;) { - size_type first_child_index = child(index, 0); - if (first_child_index >= heap_size) break; /* No children */ - Value* child_base_ptr = data_ptr + first_child_index; - size_type smallest_child_index = 0; - distance_type smallest_child_dist = get(distance, child_base_ptr[smallest_child_index]); - if (first_child_index + Arity <= heap_size) { - // Special case for a statically known loop count (common case) - for (size_t i = 1; i < Arity; ++i) { - Value i_value = child_base_ptr[i]; - distance_type i_dist = get(distance, i_value); - if (compare(i_dist, smallest_child_dist)) { - smallest_child_index = i; - smallest_child_dist = i_dist; - } - } - } else { - for (size_t i = 1; i < heap_size - first_child_index; ++i) { - distance_type i_dist = get(distance, child_base_ptr[i]); - if (compare(i_dist, smallest_child_dist)) { - smallest_child_index = i; - smallest_child_dist = i_dist; - } - } - } - if (compare(smallest_child_dist, currently_being_moved_dist)) { - swap_heap_elements(smallest_child_index + first_child_index, index); - index = smallest_child_index + first_child_index; - continue; - } else { - break; // Heap property satisfied - } - } - verify_heap(); - } - - }; - -} // namespace boost - -#endif // BOOST_D_ARY_HEAP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/edge.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/detail/edge.hpp deleted file mode 100644 index da085973..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/detail/edge.hpp +++ /dev/null @@ -1,124 +0,0 @@ -// -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_DETAIL_EDGE_HPP -#define BOOST_GRAPH_DETAIL_EDGE_HPP - -#if __GNUC__ < 3 -#include -#else -#include -#endif - -namespace boost { - - namespace detail { - - template - struct edge_base - { - inline edge_base() {} - inline edge_base(Vertex s, Vertex d) - : m_source(s), m_target(d) { } - Vertex m_source; - Vertex m_target; - }; - - template - class edge_desc_impl : public edge_base { - typedef edge_desc_impl self; - typedef edge_base Base; - public: - typedef void property_type; - - inline edge_desc_impl() : m_eproperty(0) {} - - inline edge_desc_impl(Vertex s, Vertex d, const property_type* eplug) - : Base(s,d), m_eproperty(const_cast(eplug)) { } - - property_type* get_property() { return m_eproperty; } - const property_type* get_property() const { return m_eproperty; } - - // protected: - property_type* m_eproperty; - }; - - template - inline bool - operator==(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return a.get_property() == b.get_property(); - } - template - inline bool - operator!=(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return ! (a.get_property() == b.get_property()); - } - - // Order edges according to the address of their property object - template - inline bool - operator<(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return a.get_property() < b.get_property(); - } - template - inline bool - operator<=(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return a.get_property() <= b.get_property(); - } - template - inline bool - operator>(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return a.get_property() > b.get_property(); - } - template - inline bool - operator>=(const detail::edge_desc_impl& a, - const detail::edge_desc_impl& b) - { - return a.get_property() >= b.get_property(); - } - - } //namespace detail - -} // namespace boost - -namespace std { - -#if __GNUC__ < 3 - template - std::ostream& - operator<<(std::ostream& os, const boost::detail::edge_desc_impl& e) - { - return os << "(" << e.m_source << "," << e.m_target << ")"; - } -#else - template - std::basic_ostream& - operator<<(std::basic_ostream& os, - const boost::detail::edge_desc_impl& e) - { - return os << "(" << e.m_source << "," << e.m_target << ")"; - } -#endif - -} - - -#endif // BOOST_GRAPH_DETAIL_DETAIL_EDGE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/breadth_first_search.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/breadth_first_search.hpp deleted file mode 100644 index 5bb99c6c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/breadth_first_search.hpp +++ /dev/null @@ -1,163 +0,0 @@ -// Copyright 2004 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#ifndef BOOST_GRAPH_PARALLEL_BFS_HPP -#define BOOST_GRAPH_PARALLEL_BFS_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - namespace detail { - /** @brief A unary predicate that decides when to push into a - * breadth-first search queue. - * - * This predicate stores a color map that is used to determine - * when to push. If it is provided with a key for which the color - * is white, it darkens the color to gray and returns true (so - * that the value will be pushed appropriately); if the color is - * not white, it returns false so that the vertex will be - * ignored. - */ - template - struct darken_and_push - { - typedef typename property_traits::key_type argument_type; - typedef bool result_type; - - explicit darken_and_push(const ColorMap& color) : color(color) { } - - bool operator()(const argument_type& value) const - { - typedef color_traits::value_type> - Color; - if (get(color, value) == Color::white()) { - put(color, value, Color::gray()); - return true; - } else { - return false; - } - } - - ColorMap color; - }; - - template - struct has_not_been_seen - { - typedef bool result_type; - - has_not_been_seen() { } - - has_not_been_seen(std::size_t n, IndexMap index_map) - : seen(n), index_map(index_map) {} - - template - result_type operator()(Key key) - { - bool result = seen[get(index_map, key)]; - seen[get(index_map, key)] = true; - return !result; - } - - void swap(has_not_been_seen& other) - { - using std::swap; - swap(seen, other.seen); - swap(index_map, other.index_map); - } - - private: - dynamic_bitset<> seen; - IndexMap index_map; - }; - - template - inline void - swap(has_not_been_seen& x, has_not_been_seen& y) - { - x.swap(y); - } - - template - inline void - parallel_bfs_helper - (DistributedGraph& g, - typename graph_traits::vertex_descriptor s, - ColorMap color, - BFSVisitor vis, - BufferRef Q, - VertexIndexMap) - { - set_property_map_role(vertex_color, color); - color.set_consistency_model(0); - breadth_first_search(g, s, Q.ref, vis, color); - } - - template - void parallel_bfs_helper - (DistributedGraph& g, - typename graph_traits::vertex_descriptor s, - ColorMap color, - BFSVisitor vis, - boost::param_not_found, - VertexIndexMap vertex_index) - { - using boost::graph::parallel::process_group; - - typedef graph_traits Traits; - typedef typename Traits::vertex_descriptor Vertex; - typedef typename boost::graph::parallel::process_group_type::type - process_group_type; - - set_property_map_role(vertex_color, color); - color.set_consistency_model(0); - - // Buffer default - typedef typename property_map - ::const_type vertex_owner_map; - typedef boost::graph::distributed::distributed_queue< - process_group_type, vertex_owner_map, queue, - detail::darken_and_push > queue_t; - queue_t Q(process_group(g), - get(vertex_owner, g), - detail::darken_and_push(color)); - breadth_first_search(g, s, Q, vis, color); - } - - template - void bfs_helper - (DistributedGraph& g, - typename graph_traits::vertex_descriptor s, - ColorMap color, - BFSVisitor vis, - const bgl_named_params& params, - boost::mpl::true_) - { - parallel_bfs_helper - (g, s, color, vis, get_param(params, buffer_param_t()), - choose_const_pmap(get_param(params, vertex_index), g, vertex_index)); - } - } -} - -#endif // BOOST_GRAPH_PARALLEL_BFS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/concepts.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/concepts.hpp deleted file mode 100644 index 9d6e2672..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/concepts.hpp +++ /dev/null @@ -1,213 +0,0 @@ -// Copyright (C) 2004-2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -// -// Distributed graph concepts and helpers -// - -#ifndef BOOST_GRAPH_DISTRIBUTED_CONCEPTS_HPP -#define BOOST_GRAPH_DISTRIBUTED_CONCEPTS_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include -#include -#include - -#if BOOST_VERSION >= 103500 -# include -#endif - -namespace boost { - -#if BOOST_VERSION >= 103500 - namespace concepts { -#endif - -#if BOOST_VERSION < 103500 - -template -struct DistributedVertexListGraphConcept -{ - typedef typename graph_traits::vertex_iterator vertex_iterator; - typedef typename graph_traits::vertices_size_type vertices_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - void constraints() { - BOOST_CONCEPT_ASSERT(( GraphConcept )); - BOOST_CONCEPT_ASSERT(( MultiPassInputIteratorConcept )); - BOOST_CONCEPT_ASSERT(( ConvertibleConcept )); - -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - p = vertices(g); - v = *p.first; - const_constraints(g); - } - void const_constraints(const G& cg) { -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - - p = vertices(cg); - v = *p.first; - V = num_vertices(cg); - } - std::pair p; - typename graph_traits::vertex_descriptor v; - G g; - vertices_size_type V; -}; - -template -struct DistributedEdgeListGraphConcept -{ - typedef typename graph_traits::edge_descriptor edge_descriptor; - typedef typename graph_traits::edge_iterator edge_iterator; - typedef typename graph_traits::edges_size_type edges_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - void constraints() { - BOOST_CONCEPT_ASSERT(( GraphConcept )); - BOOST_CONCEPT_ASSERT(( MultiPassInputIteratorConcept )); - BOOST_CONCEPT_ASSERT(( DefaultConstructibleConcept )); - BOOST_CONCEPT_ASSERT(( EqualityComparableConcept )); - BOOST_CONCEPT_ASSERT(( AssignableConcept )); - BOOST_CONCEPT_ASSERT(( ConvertibleConcept )); - - p = edges(g); - e = *p.first; - u = source(e, g); - v = target(e, g); - const_constraints(g); - } - void const_constraints(const G& cg) { - p = edges(cg); - E = num_edges(cg); - e = *p.first; - u = source(e, cg); - v = target(e, cg); - } - std::pair p; - typename graph_traits::vertex_descriptor u, v; - typename graph_traits::edge_descriptor e; - edges_size_type E; - G g; -}; -#else - BOOST_concept(DistributedVertexListGraph,(G)) - : Graph - { - typedef typename graph_traits::vertex_iterator vertex_iterator; - typedef typename graph_traits::vertices_size_type vertices_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - ~DistributedVertexListGraph() { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((Convertible)); - -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - p = vertices(g); - v = *p.first; - const_constraints(g); - } - void const_constraints(const G& cg) { -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - - p = vertices(cg); - v = *p.first; - V = num_vertices(cg); - } - std::pair p; - typename graph_traits::vertex_descriptor v; - G g; - vertices_size_type V; - }; - - BOOST_concept(DistributedEdgeListGraph,(G)) - : Graph - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - typedef typename graph_traits::edge_iterator edge_iterator; - typedef typename graph_traits::edges_size_type edges_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - ~DistributedEdgeListGraph() { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((DefaultConstructible)); - BOOST_CONCEPT_ASSERT((EqualityComparable)); - BOOST_CONCEPT_ASSERT((Assignable)); - BOOST_CONCEPT_ASSERT((Convertible)); - - p = edges(g); - e = *p.first; - u = source(e, g); - v = target(e, g); - const_constraints(g); - } - void const_constraints(const G& cg) { - p = edges(cg); - E = num_edges(cg); - e = *p.first; - u = source(e, cg); - v = target(e, cg); - } - std::pair p; - typename graph_traits::vertex_descriptor u, v; - typename graph_traits::edge_descriptor e; - edges_size_type E; - G g; - }; -#endif - -#if BOOST_VERSION >= 103500 - } // end namespace concepts - - using concepts::DistributedVertexListGraphConcept; - using concepts::DistributedEdgeListGraphConcept; -#endif -} // end namespace boost - -#if BOOST_VERSION >= 103500 -# include -#endif - -#endif // BOOST_GRAPH_DISTRIBUTED_CONCEPTS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/filtered_queue.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/filtered_queue.hpp deleted file mode 100644 index 9871b70d..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/filtered_queue.hpp +++ /dev/null @@ -1,108 +0,0 @@ -// Copyright (C) 2004-2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#ifndef BOOST_FILTERED_QUEUE_HPP -#define BOOST_FILTERED_QUEUE_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include - -namespace boost { - -/** Queue adaptor that filters elements pushed into the queue - * according to some predicate. - */ -template -class filtered_queue -{ - public: - typedef Buffer buffer_type; - typedef Predicate predicate_type; - typedef typename Buffer::value_type value_type; - typedef typename Buffer::size_type size_type; - - /** - * Constructs a new filtered queue with an initial buffer and a - * predicate. - * - * @param buffer the initial buffer - * @param pred the predicate - */ - explicit - filtered_queue(const buffer_type& buffer = buffer_type(), - const predicate_type& pred = predicate_type()) - : buffer(buffer), pred(pred) {} - - /** Push a value into the queue. - * - * If the predicate returns @c true for @p x, pushes @p x into the - * buffer. - */ - void push(const value_type& x) { if (pred(x)) buffer.push(x); } - - /** Pop the front element off the buffer. - * - * @pre @c !empty() - */ - void pop() { buffer.pop(); } - - /** Retrieve the front (top) element in the buffer. - * - * @pre @c !empty() - */ - value_type& top() { return buffer.top(); } - - /** - * \overload - */ - const value_type& top() const { return buffer.top(); } - - /** Determine the number of elements in the buffer. */ - size_type size() const { return buffer.size(); } - - /** Determine if the buffer is empty. */ - bool empty() const { return buffer.empty(); } - - /** Get a reference to the underlying buffer. */ - buffer_type& base() { return buffer; } - const buffer_type& base() const { return buffer; } - - /** Swap the contents of this with @p other. */ - void swap(filtered_queue& other) - { - using std::swap; - swap(buffer, other.buffer); - swap(pred, other.pred); - } - - private: - buffer_type buffer; - predicate_type pred; -}; - -/** Create a filtered queue. */ -template -inline filtered_queue -make_filtered_queue(const Buffer& buffer, const Predicate& pred) -{ return filtered_queue(buffer, pred); } - -/** Swap a filtered_queue. */ -template -inline void -swap(filtered_queue& x, - filtered_queue& y) -{ - x.swap(y); -} - -} // end namespace boost - -#endif // BOOST_FILTERED_QUEUE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/queue.ipp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/queue.ipp deleted file mode 100644 index f37ff25f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/detail/queue.ipp +++ /dev/null @@ -1,177 +0,0 @@ -// Copyright (C) 2004-2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#include -#include -#include -#include -#include -#include -#include - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -namespace boost { namespace graph { namespace distributed { - -template -BOOST_DISTRIBUTED_QUEUE_TYPE:: -distributed_queue(const ProcessGroup& process_group, const OwnerMap& owner, - const Buffer& buffer, bool polling) - : process_group(process_group, attach_distributed_object()), - owner(owner), - buffer(buffer), - polling(polling) -{ - if (!polling) - outgoing_buffers.reset( - new outgoing_buffers_t(num_processes(process_group))); - - setup_triggers(); -} - -template -BOOST_DISTRIBUTED_QUEUE_TYPE:: -distributed_queue(const ProcessGroup& process_group, const OwnerMap& owner, - const Buffer& buffer, const UnaryPredicate& pred, - bool polling) - : process_group(process_group, attach_distributed_object()), - owner(owner), - buffer(buffer), - pred(pred), - polling(polling) -{ - if (!polling) - outgoing_buffers.reset( - new outgoing_buffers_t(num_processes(process_group))); - - setup_triggers(); -} - -template -BOOST_DISTRIBUTED_QUEUE_TYPE:: -distributed_queue(const ProcessGroup& process_group, const OwnerMap& owner, - const UnaryPredicate& pred, bool polling) - : process_group(process_group, attach_distributed_object()), - owner(owner), - pred(pred), - polling(polling) -{ - if (!polling) - outgoing_buffers.reset( - new outgoing_buffers_t(num_processes(process_group))); - - setup_triggers(); -} - -template -void -BOOST_DISTRIBUTED_QUEUE_TYPE::push(const value_type& x) -{ - typename ProcessGroup::process_id_type dest = get(owner, x); - if (outgoing_buffers) - outgoing_buffers->at(dest).push_back(x); - else if (dest == process_id(process_group)) - buffer.push(x); - else - send(process_group, get(owner, x), msg_push, x); -} - -template -bool -BOOST_DISTRIBUTED_QUEUE_TYPE::empty() const -{ - /* Processes will stay here until the buffer is nonempty or - synchronization with the other processes indicates that all local - buffers are empty (and no messages are in transit). - */ - while (buffer.empty() && !do_synchronize()) ; - - return buffer.empty(); -} - -template -typename BOOST_DISTRIBUTED_QUEUE_TYPE::size_type -BOOST_DISTRIBUTED_QUEUE_TYPE::size() const -{ - empty(); - return buffer.size(); -} - -template -void BOOST_DISTRIBUTED_QUEUE_TYPE::setup_triggers() -{ - using boost::graph::parallel::simple_trigger; - - simple_trigger(process_group, msg_push, this, - &distributed_queue::handle_push); - simple_trigger(process_group, msg_multipush, this, - &distributed_queue::handle_multipush); -} - -template -void -BOOST_DISTRIBUTED_QUEUE_TYPE:: -handle_push(int /*source*/, int /*tag*/, const value_type& value, - trigger_receive_context) -{ - if (pred(value)) buffer.push(value); -} - -template -void -BOOST_DISTRIBUTED_QUEUE_TYPE:: -handle_multipush(int /*source*/, int /*tag*/, - const std::vector& values, - trigger_receive_context) -{ - for (std::size_t i = 0; i < values.size(); ++i) - if (pred(values[i])) buffer.push(values[i]); -} - -template -bool -BOOST_DISTRIBUTED_QUEUE_TYPE::do_synchronize() const -{ -#ifdef PBGL_ACCOUNTING - ++num_synchronizations; -#endif - - using boost::parallel::all_reduce; - using std::swap; - - typedef typename ProcessGroup::process_id_type process_id_type; - - if (outgoing_buffers) { - // Transfer all of the push requests - process_id_type id = process_id(process_group); - process_id_type np = num_processes(process_group); - for (process_id_type dest = 0; dest < np; ++dest) { - outgoing_buffer_t& outgoing = outgoing_buffers->at(dest); - std::size_t size = outgoing.size(); - if (size != 0) { - if (dest != id) { - send(process_group, dest, msg_multipush, outgoing); - } else { - for (std::size_t i = 0; i < size; ++i) - buffer.push(outgoing[i]); - } - outgoing.clear(); - } - } - } - synchronize(process_group); - - unsigned local_size = buffer.size(); - unsigned global_size = - all_reduce(process_group, local_size, std::plus()); - return global_size == 0; -} - -} } } // end namespace boost::graph::distributed diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/queue.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/queue.hpp deleted file mode 100644 index 7e84272a..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/queue.hpp +++ /dev/null @@ -1,278 +0,0 @@ -// Copyright (C) 2004-2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#ifndef BOOST_GRAPH_DISTRIBUTED_QUEUE_HPP -#define BOOST_GRAPH_DISTRIBUTED_QUEUE_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include -#include -#include - -namespace boost { namespace graph { namespace distributed { - -/// A unary predicate that always returns "true". -struct always_push -{ - template bool operator()(const T&) const { return true; } -}; - - - -/** A distributed queue adaptor. - * - * Class template @c distributed_queue implements a distributed queue - * across a process group. The distributed queue is an adaptor over an - * existing (local) queue, which must model the @ref Buffer - * concept. Each process stores a distinct copy of the local queue, - * from which it draws or removes elements via the @ref pop and @ref - * top members. - * - * The value type of the local queue must be a model of the @ref - * GlobalDescriptor concept. The @ref push operation of the - * distributed queue passes (via a message) the value to its owning - * processor. Thus, the elements within a particular local queue are - * guaranteed to have the process owning that local queue as an owner. - * - * Synchronization of distributed queues occurs in the @ref empty and - * @ref size functions, which will only return "empty" values (true or - * 0, respectively) when the entire distributed queue is empty. If the - * local queue is empty but the distributed queue is not, the - * operation will block until either condition changes. When the @ref - * size function of a nonempty queue returns, it returns the size of - * the local queue. These semantics were selected so that sequential - * code that processes elements in the queue via the following idiom - * can be parallelized via introduction of a distributed queue: - * - * distributed_queue<...> Q; - * Q.push(x); - * while (!Q.empty()) { - * // do something, that may push a value onto Q - * } - * - * In the parallel version, the initial @ref push operation will place - * the value @c x onto its owner's queue. All processes will - * synchronize at the call to empty, and only the process owning @c x - * will be allowed to execute the loop (@ref Q.empty() returns - * false). This iteration may in turn push values onto other remote - * queues, so when that process finishes execution of the loop body - * and all processes synchronize again in @ref empty, more processes - * may have nonempty local queues to execute. Once all local queues - * are empty, @ref Q.empty() returns @c false for all processes. - * - * The distributed queue can receive messages at two different times: - * during synchronization and when polling @ref empty. Messages are - * always received during synchronization, to ensure that accurate - * local queue sizes can be determines. However, whether @ref empty - * should poll for messages is specified as an option to the - * constructor. Polling may be desired when the order in which - * elements in the queue are processed is not important, because it - * permits fewer synchronization steps and less communication - * overhead. However, when more strict ordering guarantees are - * required, polling may be semantically incorrect. By disabling - * polling, one ensures that parallel execution using the idiom above - * will not process an element at a later "level" before an earlier - * "level". - * - * The distributed queue nearly models the @ref Buffer - * concept. However, the @ref push routine does not necessarily - * increase the result of @c size() by one (although the size of the - * global queue does increase by one). - */ -template -class distributed_queue -{ - typedef distributed_queue self_type; - - enum { - /** Message indicating a remote push. The message contains a - * single value x of type value_type that is to be pushed on the - * receiver's queue. - */ - msg_push, - /** Push many elements at once. */ - msg_multipush - }; - - public: - typedef ProcessGroup process_group_type; - typedef Buffer buffer_type; - typedef typename buffer_type::value_type value_type; - typedef typename buffer_type::size_type size_type; - - /** Construct a new distributed queue. - * - * Build a new distributed queue that communicates over the given @p - * process_group, whose local queue is initialized via @p buffer and - * which may or may not poll for messages. - */ - explicit - distributed_queue(const ProcessGroup& process_group, - const OwnerMap& owner, - const Buffer& buffer, - bool polling = false); - - /** Construct a new distributed queue. - * - * Build a new distributed queue that communicates over the given @p - * process_group, whose local queue is initialized via @p buffer and - * which may or may not poll for messages. - */ - explicit - distributed_queue(const ProcessGroup& process_group = ProcessGroup(), - const OwnerMap& owner = OwnerMap(), - const Buffer& buffer = Buffer(), - const UnaryPredicate& pred = UnaryPredicate(), - bool polling = false); - - /** Construct a new distributed queue. - * - * Build a new distributed queue that communicates over the given @p - * process_group, whose local queue is default-initalized and which - * may or may not poll for messages. - */ - distributed_queue(const ProcessGroup& process_group, const OwnerMap& owner, - const UnaryPredicate& pred, bool polling = false); - - /** Virtual destructor required with virtual functions. - * - */ - virtual ~distributed_queue() {} - - /** Push an element onto the distributed queue. - * - * The element will be sent to its owner process to be added to that - * process's local queue. If polling is enabled for this queue and - * the owner process is the current process, the value will be - * immediately pushed onto the local queue. - * - * Complexity: O(1) messages of size O(sizeof(value_type)) will be - * transmitted. - */ - void push(const value_type& x); - - /** Pop an element off the local queue. - * - * @p @c !empty() - */ - void pop() { buffer.pop(); } - - /** - * Return the element at the top of the local queue. - * - * @p @c !empty() - */ - value_type& top() { return buffer.top(); } - - /** - * \overload - */ - const value_type& top() const { return buffer.top(); } - - /** Determine if the queue is empty. - * - * When the local queue is nonempty, returns @c true. If the local - * queue is empty, synchronizes with all other processes in the - * process group until either (1) the local queue is nonempty - * (returns @c true) (2) the entire distributed queue is empty - * (returns @c false). - */ - bool empty() const; - - /** Determine the size of the local queue. - * - * The behavior of this routine is equivalent to the behavior of - * @ref empty, except that when @ref empty returns true this - * function returns the size of the local queue and when @ref empty - * returns false this function returns zero. - */ - size_type size() const; - - // private: - /** Synchronize the distributed queue and determine if all queues - * are empty. - * - * \returns \c true when all local queues are empty, or false if at least - * one of the local queues is nonempty. - * Defined as virtual for derived classes like depth_limited_distributed_queue. - */ - virtual bool do_synchronize() const; - - private: - // Setup triggers - void setup_triggers(); - - // Message handlers - void - handle_push(int source, int tag, const value_type& value, - trigger_receive_context); - - void - handle_multipush(int source, int tag, const std::vector& values, - trigger_receive_context); - - mutable ProcessGroup process_group; - OwnerMap owner; - mutable Buffer buffer; - UnaryPredicate pred; - bool polling; - - typedef std::vector outgoing_buffer_t; - typedef std::vector outgoing_buffers_t; - shared_ptr outgoing_buffers; -}; - -/// Helper macro containing the normal names for the template -/// parameters to distributed_queue. -#define BOOST_DISTRIBUTED_QUEUE_PARMS \ - typename ProcessGroup, typename OwnerMap, typename Buffer, \ - typename UnaryPredicate - -/// Helper macro containing the normal template-id for -/// distributed_queue. -#define BOOST_DISTRIBUTED_QUEUE_TYPE \ - distributed_queue - -/** Synchronize all processes involved with the given distributed queue. - * - * This function will synchronize all of the local queues for a given - * distributed queue, by ensuring that no additional messages are in - * transit. It is rarely required by the user, because most - * synchronization of distributed queues occurs via the @c empty or @c - * size methods. - */ -template -inline void -synchronize(const BOOST_DISTRIBUTED_QUEUE_TYPE& Q) -{ Q.do_synchronize(); } - -/// Construct a new distributed queue. -template -inline distributed_queue -make_distributed_queue(const ProcessGroup& process_group, - const OwnerMap& owner, - const Buffer& buffer, - bool polling = false) -{ - typedef distributed_queue result_type; - return result_type(process_group, owner, buffer, polling); -} - -} } } // end namespace boost::graph::distributed - -#include - -#undef BOOST_DISTRIBUTED_QUEUE_TYPE -#undef BOOST_DISTRIBUTED_QUEUE_PARMS - -#endif // BOOST_GRAPH_DISTRIBUTED_QUEUE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/two_bit_color_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/two_bit_color_map.hpp deleted file mode 100644 index d7ec6bdf..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/two_bit_color_map.hpp +++ /dev/null @@ -1,116 +0,0 @@ -// Copyright (C) 2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Jeremiah Willcock -// Andrew Lumsdaine - -// Distributed version of the two-bit color map -#ifndef BOOST_DISTRIBUTED_TWO_BIT_COLOR_MAP_HPP -#define BOOST_DISTRIBUTED_TWO_BIT_COLOR_MAP_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include -#include - -namespace boost { - -template -class two_bit_color_map > - : public parallel::distributed_property_map > -{ - typedef two_bit_color_map local_map; - - typedef parallel::distributed_property_map - inherited; - - typedef local_property_map - index_map_type; - -public: - two_bit_color_map(std::size_t inital_size, - const index_map_type& index = index_map_type()) - : inherited(index.process_group(), index.global(), - local_map(inital_size, index.base())) { } - - inherited& base() { return *this; } - const inherited& base() const { return *this; } -}; - -template -inline two_bit_color_type -get(two_bit_color_map > - const& pm, - typename property_traits::key_type key) -{ - return get(pm.base(), key); -} - -template -inline void -put(two_bit_color_map > - const& pm, - typename property_traits::key_type key, - two_bit_color_type value) -{ - put(pm.base(), key, value); -} - -template -class two_bit_color_map > - : public parallel::distributed_property_map< - ProcessGroup, GlobalMap, two_bit_color_map > -{ - typedef two_bit_color_map local_map; - - typedef parallel::distributed_property_map - inherited; - - typedef parallel::distributed_property_map - index_map_type; - -public: - two_bit_color_map(std::size_t inital_size, - const index_map_type& index = index_map_type()) - : inherited(index.process_group(), index.global(), - local_map(inital_size, index.base())) { } - - inherited& base() { return *this; } - const inherited& base() const { return *this; } -}; - -template -inline two_bit_color_type -get(two_bit_color_map< - parallel::distributed_property_map< - ProcessGroup, GlobalMap, two_bit_color_map > > const& pm, - typename property_traits::key_type key) -{ - return get(pm.base(), key); -} - -template -inline void -put(two_bit_color_map< - parallel::distributed_property_map< - ProcessGroup, GlobalMap, two_bit_color_map > > const& pm, - typename property_traits::key_type key, - two_bit_color_type value) -{ - put(pm.base(), key, value); -} - -} // end namespace boost - -#endif // BOOST_DISTRIBUTED_TWO_BIT_COLOR_MAP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/unsafe_serialize.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/unsafe_serialize.hpp deleted file mode 100644 index 38ad8a67..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/distributed/unsafe_serialize.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright (C) 2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -// This file contains the "unsafe_serialize" routine, which transforms -// types they may not be serializable (such as void*) into -// serializable equivalents. -#ifndef PBGL_UNSAFE_SERIALIZE_HPP -#define PBGL_UNSAFE_SERIALIZE_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include -#include -#include -#include -#include -#include -#include - -BOOST_IS_BITWISE_SERIALIZABLE(void*) -namespace boost { namespace mpi { - template<> struct is_mpi_datatype : mpl::true_ { }; -} } // end namespace boost::mpi - -namespace boost { - typedef mpl::if_c<(sizeof(int) == sizeof(void*)), - int, - mpl::if_c<(sizeof(long) == sizeof(void*)), - long, - mpl::if_c<(sizeof(void*) <= sizeof(boost::intmax_t)), - boost::intmax_t, - void>::type - >::type - >::type ptr_serialize_type; - - BOOST_STATIC_ASSERT ((!boost::is_void::value)); - - template inline T& unsafe_serialize(T& x) { return x; } - - inline ptr_serialize_type& unsafe_serialize(void*& x) - { return reinterpret_cast(x); } - - // Force Boost.MPI to serialize a void* like a ptr_serialize_type - namespace mpi { - template<> inline MPI_Datatype get_mpi_datatype(void* const& x) - { - return get_mpi_datatype(); - } - } - - template - struct unsafe_pair - { - unsafe_pair() { } - unsafe_pair(const T& t, const U& u) : first(t), second(u) { } - unsafe_pair(const std::pair& p) : first(p.first), second(p.second) { } - T first; - U second; - - template - void serialize(Archiver& ar, const unsigned /*version*/) - { - ar & unsafe_serialize(first) & unsafe_serialize(second); - } - }; - - template - bool operator<(unsafe_pair const& x, unsafe_pair const& y) - { - return std::make_pair(x.first, x.second) < - std::make_pair(y.first, y.second); - } - -} // end namespace boost - -#endif // PBGL_UNSAFE_SERIALIZE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_concepts.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/graph_concepts.hpp deleted file mode 100644 index f03afeea..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_concepts.hpp +++ /dev/null @@ -1,619 +0,0 @@ -// -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Copyright 2009, Andrew Sutton -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= -// -#ifndef BOOST_GRAPH_CONCEPTS_HPP -#define BOOST_GRAPH_CONCEPTS_HPP - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -namespace boost -{ -// dwa 2003/7/11 -- This clearly shouldn't be necessary, but if -// you want to use vector_as_graph, it is! I'm sure the graph -// library leaves these out all over the place. Probably a -// redesign involving specializing a template with a static -// member function is in order :( -// -// It is needed in order to allow us to write using boost::vertices as -// needed for ADL when using vector_as_graph below. -#if !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP) \ - && !BOOST_WORKAROUND(__GNUC__, <= 2) \ - && !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) -# define BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK -#endif - -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK -template -typename T::ThereReallyIsNoMemberByThisNameInT vertices(T const&); -#endif - - namespace concepts { - BOOST_concept(MultiPassInputIterator,(T)) { - BOOST_CONCEPT_USAGE(MultiPassInputIterator) { - BOOST_CONCEPT_ASSERT((InputIterator)); - } - }; - - BOOST_concept(Graph,(G)) - { - typedef typename graph_traits::vertex_descriptor vertex_descriptor; - typedef typename graph_traits::edge_descriptor edge_descriptor; - typedef typename graph_traits::directed_category directed_category; - typedef typename graph_traits::edge_parallel_category edge_parallel_category; - typedef typename graph_traits::traversal_category traversal_category; - - BOOST_CONCEPT_USAGE(Graph) - { - BOOST_CONCEPT_ASSERT((DefaultConstructible)); - BOOST_CONCEPT_ASSERT((EqualityComparable)); - BOOST_CONCEPT_ASSERT((Assignable)); - } - G g; - }; - - BOOST_concept(IncidenceGraph,(G)) - : Graph - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - typedef typename graph_traits::out_edge_iterator out_edge_iterator; - typedef typename graph_traits::degree_size_type degree_size_type; - typedef typename graph_traits::traversal_category traversal_category; - - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - - BOOST_CONCEPT_USAGE(IncidenceGraph) { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((DefaultConstructible)); - BOOST_CONCEPT_ASSERT((EqualityComparable)); - BOOST_CONCEPT_ASSERT((Assignable)); - BOOST_CONCEPT_ASSERT((Convertible)); - - p = out_edges(u, g); - n = out_degree(u, g); - e = *p.first; - u = source(e, g); - v = target(e, g); - const_constraints(g); - } - void const_constraints(const G& cg) { - p = out_edges(u, cg); - n = out_degree(u, cg); - e = *p.first; - u = source(e, cg); - v = target(e, cg); - } - std::pair p; - typename graph_traits::vertex_descriptor u, v; - typename graph_traits::edge_descriptor e; - typename graph_traits::degree_size_type n; - G g; - }; - - BOOST_concept(BidirectionalGraph,(G)) - : IncidenceGraph - { - typedef typename graph_traits::in_edge_iterator - in_edge_iterator; - typedef typename graph_traits::traversal_category - traversal_category; - - BOOST_CONCEPT_USAGE(BidirectionalGraph) { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((Convertible)); - - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - - p = in_edges(v, g); - n = in_degree(v, g); - e = *p.first; - const_constraints(g); - } - void const_constraints(const G& cg) { - p = in_edges(v, cg); - n = in_degree(v, cg); - e = *p.first; - } - std::pair p; - typename graph_traits::vertex_descriptor v; - typename graph_traits::edge_descriptor e; - typename graph_traits::degree_size_type n; - G g; - }; - - BOOST_concept(AdjacencyGraph,(G)) - : Graph - { - typedef typename graph_traits::adjacency_iterator - adjacency_iterator; - typedef typename graph_traits::traversal_category - traversal_category; - - BOOST_CONCEPT_USAGE(AdjacencyGraph) { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((Convertible)); - - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - - p = adjacent_vertices(v, g); - v = *p.first; - const_constraints(g); - } - void const_constraints(const G& cg) { - p = adjacent_vertices(v, cg); - } - std::pair p; - typename graph_traits::vertex_descriptor v; - G g; - }; - - BOOST_concept(VertexListGraph,(G)) - : Graph - { - typedef typename graph_traits::vertex_iterator vertex_iterator; - typedef typename graph_traits::vertices_size_type vertices_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - - BOOST_CONCEPT_USAGE(VertexListGraph) { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((Convertible)); - - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - p = vertices(g); - v = *p.first; - const_constraints(g); - } - void const_constraints(const G& cg) { -#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK - // dwa 2003/7/11 -- This clearly shouldn't be necessary, but if - // you want to use vector_as_graph, it is! I'm sure the graph - // library leaves these out all over the place. Probably a - // redesign involving specializing a template with a static - // member function is in order :( - using boost::vertices; -#endif - - p = vertices(cg); - v = *p.first; - V = num_vertices(cg); - } - std::pair p; - typename graph_traits::vertex_descriptor v; - G g; - vertices_size_type V; - }; - - BOOST_concept(EdgeListGraph,(G)) - : Graph - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - typedef typename graph_traits::edge_iterator edge_iterator; - typedef typename graph_traits::edges_size_type edges_size_type; - typedef typename graph_traits::traversal_category - traversal_category; - - BOOST_CONCEPT_USAGE(EdgeListGraph) { - BOOST_CONCEPT_ASSERT((MultiPassInputIterator)); - BOOST_CONCEPT_ASSERT((DefaultConstructible)); - BOOST_CONCEPT_ASSERT((EqualityComparable)); - BOOST_CONCEPT_ASSERT((Assignable)); - BOOST_CONCEPT_ASSERT((Convertible)); - - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - BOOST_STATIC_ASSERT((boost::mpl::not_ >::value)); - - p = edges(g); - e = *p.first; - u = source(e, g); - v = target(e, g); - const_constraints(g); - } - void const_constraints(const G& cg) { - p = edges(cg); - E = num_edges(cg); - e = *p.first; - u = source(e, cg); - v = target(e, cg); - } - std::pair p; - typename graph_traits::vertex_descriptor u, v; - typename graph_traits::edge_descriptor e; - edges_size_type E; - G g; - }; - - BOOST_concept(VertexAndEdgeListGraph,(G)) - : VertexListGraph - , EdgeListGraph - { - }; - - // Where to put the requirement for this constructor? - // G g(n_vertices); - // Not in mutable graph, then LEDA graph's can't be models of - // MutableGraph. - BOOST_concept(EdgeMutableGraph,(G)) - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - - BOOST_CONCEPT_USAGE(EdgeMutableGraph) { - p = add_edge(u, v, g); - remove_edge(u, v, g); - remove_edge(e, g); - clear_vertex(v, g); - } - G g; - edge_descriptor e; - std::pair p; - typename graph_traits::vertex_descriptor u, v; - }; - - BOOST_concept(VertexMutableGraph,(G)) - { - - BOOST_CONCEPT_USAGE(VertexMutableGraph) { - v = add_vertex(g); - remove_vertex(v, g); - } - G g; - typename graph_traits::vertex_descriptor u, v; - }; - - BOOST_concept(MutableGraph,(G)) - : EdgeMutableGraph - , VertexMutableGraph - { - }; - - template - struct dummy_edge_predicate { - bool operator()(const edge_descriptor&) const { - return false; - } - }; - - BOOST_concept(MutableIncidenceGraph,(G)) - : MutableGraph - { - BOOST_CONCEPT_USAGE(MutableIncidenceGraph) { - remove_edge(iter, g); - remove_out_edge_if(u, p, g); - } - G g; - typedef typename graph_traits::edge_descriptor edge_descriptor; - dummy_edge_predicate p; - typename boost::graph_traits::vertex_descriptor u; - typename boost::graph_traits::out_edge_iterator iter; - }; - - BOOST_concept(MutableBidirectionalGraph,(G)) - : MutableIncidenceGraph - { - BOOST_CONCEPT_USAGE(MutableBidirectionalGraph) - { - remove_in_edge_if(u, p, g); - } - G g; - typedef typename graph_traits::edge_descriptor edge_descriptor; - dummy_edge_predicate p; - typename boost::graph_traits::vertex_descriptor u; - }; - - BOOST_concept(MutableEdgeListGraph,(G)) - : EdgeMutableGraph - { - BOOST_CONCEPT_USAGE(MutableEdgeListGraph) { - remove_edge_if(p, g); - } - G g; - typedef typename graph_traits::edge_descriptor edge_descriptor; - dummy_edge_predicate p; - }; - - BOOST_concept(VertexMutablePropertyGraph,(G)) - : VertexMutableGraph - { - BOOST_CONCEPT_USAGE(VertexMutablePropertyGraph) { - v = add_vertex(vp, g); - } - G g; - typename graph_traits::vertex_descriptor v; - typename vertex_property_type::type vp; - }; - - BOOST_concept(EdgeMutablePropertyGraph,(G)) - : EdgeMutableGraph - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - - BOOST_CONCEPT_USAGE(EdgeMutablePropertyGraph) { - p = add_edge(u, v, ep, g); - } - G g; - std::pair p; - typename graph_traits::vertex_descriptor u, v; - typename edge_property_type::type ep; - }; - - BOOST_concept(AdjacencyMatrix,(G)) - : Graph - { - typedef typename graph_traits::edge_descriptor edge_descriptor; - - BOOST_CONCEPT_USAGE(AdjacencyMatrix) { - p = edge(u, v, g); - const_constraints(g); - } - void const_constraints(const G& cg) { - p = edge(u, v, cg); - } - typename graph_traits::vertex_descriptor u, v; - std::pair p; - G g; - }; - - BOOST_concept(ReadablePropertyGraph,(G)(X)(Property)) - : Graph - { - typedef typename property_map::const_type const_Map; - - BOOST_CONCEPT_USAGE(ReadablePropertyGraph) - { - BOOST_CONCEPT_ASSERT((ReadablePropertyMapConcept)); - - const_constraints(g); - } - void const_constraints(const G& cg) { - const_Map pmap = get(Property(), cg); - pval = get(Property(), cg, x); - ignore_unused_variable_warning(pmap); - } - G g; - X x; - typename property_traits::value_type pval; - }; - - BOOST_concept(PropertyGraph,(G)(X)(Property)) - : ReadablePropertyGraph - { - typedef typename property_map::type Map; - BOOST_CONCEPT_USAGE(PropertyGraph) { - BOOST_CONCEPT_ASSERT((ReadWritePropertyMapConcept)); - - Map pmap = get(Property(), g); - pval = get(Property(), g, x); - put(Property(), g, x, pval); - ignore_unused_variable_warning(pmap); - } - G g; - X x; - typename property_traits::value_type pval; - }; - - BOOST_concept(LvaluePropertyGraph,(G)(X)(Property)) - : ReadablePropertyGraph - { - typedef typename property_map::type Map; - typedef typename property_map::const_type const_Map; - - BOOST_CONCEPT_USAGE(LvaluePropertyGraph) { - BOOST_CONCEPT_ASSERT((LvaluePropertyMapConcept)); - - pval = get(Property(), g, x); - put(Property(), g, x, pval); - } - G g; - X x; - typename property_traits::value_type pval; - }; - - // The *IndexGraph concepts are "semantic" graph concpepts. These can be - // applied to describe any graph that has an index map that can be accessed - // using the get(*_index, g) method. For example, adjacency lists with - // VertexSet == vecS are implicitly models of this concept. - // - // NOTE: We could require an associated type vertex_index_type, but that - // would mean propagating that type name into graph_traits and all of the - // other graph implementations. Much easier to simply call it unsigned. - - BOOST_concept(VertexIndexGraph,(Graph)) - { - BOOST_CONCEPT_USAGE(VertexIndexGraph) - { - typedef typename graph_traits::vertex_descriptor Vertex; - typedef typename property_map::type Map; - typedef unsigned Index; // This could be Graph::vertex_index_type - Map m = get(vertex_index, g); - Index x = get(vertex_index, g, Vertex()); - ignore_unused_variable_warning(m); - ignore_unused_variable_warning(x); - - // This is relaxed - renumber_vertex_indices(g); - - const_constraints(g); - } - void const_constraints(const Graph& g) - { - typedef typename property_map::const_type Map; - Map m = get(vertex_index, g); - ignore_unused_variable_warning(m); - } - private: - Graph g; - }; - - BOOST_concept(EdgeIndexGraph,(Graph)) - { - BOOST_CONCEPT_USAGE(EdgeIndexGraph) - { - typedef typename graph_traits::edge_descriptor Edge; - typedef typename property_map::type Map; - typedef unsigned Index; // This could be Graph::vertex_index_type - Map m = get(edge_index, g); - Index x = get(edge_index, g, Edge()); - ignore_unused_variable_warning(m); - ignore_unused_variable_warning(x); - - // This is relaxed - renumber_edge_indices(g); - - const_constraints(g); - } - void const_constraints(const Graph& g) - { - typedef typename property_map::const_type Map; - Map m = get(edge_index, g); - ignore_unused_variable_warning(m); - } - private: - Graph g; - }; - - BOOST_concept(ColorValue,(C)) - : EqualityComparable - , DefaultConstructible - { - BOOST_CONCEPT_USAGE(ColorValue) { - c = color_traits::white(); - c = color_traits::gray(); - c = color_traits::black(); - } - C c; - }; - - BOOST_concept(BasicMatrix,(M)(I)(V)) - { - BOOST_CONCEPT_USAGE(BasicMatrix) { - V& elt = A[i][j]; - const_constraints(A); - ignore_unused_variable_warning(elt); - } - void const_constraints(const M& cA) { - const V& elt = cA[i][j]; - ignore_unused_variable_warning(elt); - } - M A; - I i, j; - }; - - // The following concepts describe aspects of numberic values and measure - // functions. We're extending the notion of numeric values to include - // emulation for zero and infinity. - - BOOST_concept(NumericValue,(Numeric)) - { - BOOST_CONCEPT_USAGE(NumericValue) - { - BOOST_CONCEPT_ASSERT(( DefaultConstructible )); - BOOST_CONCEPT_ASSERT(( CopyConstructible )); - numeric_values::zero(); - numeric_values::infinity(); - } - }; - - BOOST_concept(DegreeMeasure,(Measure)(Graph)) - { - BOOST_CONCEPT_USAGE(DegreeMeasure) - { - typedef typename Measure::degree_type Degree; - typedef typename Measure::vertex_type Vertex; - - Degree d = m(Vertex(), g); - ignore_unused_variable_warning(d); - } - private: - Measure m; - Graph g; - }; - - BOOST_concept(DistanceMeasure,(Measure)(Graph)) - { - BOOST_CONCEPT_USAGE(DistanceMeasure) - { - typedef typename Measure::distance_type Distance; - typedef typename Measure::result_type Result; - Result r = m(Distance(), g); - ignore_unused_variable_warning(r); - } - private: - Measure m; - Graph g; - }; - -} /* namespace concepts */ - -using boost::concepts::MultiPassInputIteratorConcept; - -// Graph concepts -using boost::concepts::GraphConcept; -using boost::concepts::IncidenceGraphConcept; -using boost::concepts::BidirectionalGraphConcept; -using boost::concepts::AdjacencyGraphConcept; -using boost::concepts::VertexListGraphConcept; -using boost::concepts::EdgeListGraphConcept; -using boost::concepts::VertexAndEdgeListGraphConcept; -using boost::concepts::EdgeMutableGraphConcept; -using boost::concepts::VertexMutableGraphConcept; -using boost::concepts::MutableGraphConcept; -using boost::concepts::MutableIncidenceGraphConcept; -using boost::concepts::MutableBidirectionalGraphConcept; -using boost::concepts::MutableEdgeListGraphConcept; -using boost::concepts::VertexMutablePropertyGraphConcept; -using boost::concepts::EdgeMutablePropertyGraphConcept; -using boost::concepts::AdjacencyMatrixConcept; -using boost::concepts::ReadablePropertyGraphConcept; -using boost::concepts::PropertyGraphConcept; -using boost::concepts::LvaluePropertyGraphConcept; -using boost::concepts::VertexIndexGraphConcept; -using boost::concepts::EdgeIndexGraphConcept; - -// Utility concepts -using boost::concepts::ColorValueConcept; -using boost::concepts::BasicMatrixConcept; -using boost::concepts::NumericValueConcept; -using boost::concepts::DistanceMeasureConcept; -using boost::concepts::DegreeMeasureConcept; - - -} /* namespace boost */ -#include - -#endif /* BOOST_GRAPH_CONCEPTS_H */ diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_mutability_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/graph_mutability_traits.hpp deleted file mode 100644 index 726d8d14..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_mutability_traits.hpp +++ /dev/null @@ -1,204 +0,0 @@ -// Copyright (C) 2009 Andrew Sutton -// -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_GRAPH_MUTABILITY_TRAITS_HPP -#define BOOST_GRAPH_MUTABILITY_TRAITS_HPP - -#include -#include -#include -#include -#include - -namespace boost { - -// The mutabiltiy categories classify graphs by their mutating operations -// on the edge and vertex sets. This is a substantially more refined -// categorization than the MutableGraph and MutablePropertyGraph denote. -// Currently, this framework is only used in the graph tests to help -// dispatch test to the correct places. However, there are probably some -// constructive or destructive algorithms (i.e., graph generators) that -// may use these to describe requirements on graph inputs. - -struct add_vertex_tag { }; -struct add_vertex_property_tag : virtual add_vertex_tag { }; -struct add_edge_tag { }; -struct add_edge_property_tag : virtual add_edge_tag { }; -struct remove_vertex_tag { }; -struct remove_edge_tag { }; - -struct mutable_vertex_graph_tag - : virtual add_vertex_tag, virtual remove_vertex_tag -{ }; -struct mutable_vertex_property_graph_tag - : virtual add_vertex_property_tag, virtual remove_vertex_tag -{ }; - -struct mutable_edge_graph_tag - : virtual add_edge_tag, virtual remove_edge_tag -{ }; -struct mutable_edge_property_graph_tag - : virtual add_edge_property_tag, virtual remove_edge_tag -{ }; - -struct mutable_graph_tag - : virtual mutable_vertex_graph_tag - , virtual mutable_edge_graph_tag -{ }; -struct mutable_property_graph_tag - : virtual mutable_vertex_property_graph_tag - , virtual mutable_edge_property_graph_tag -{ }; - -// Some graphs just don't like to be torn down. Note this only restricts -// teardown to the set of vertices, not the vertex set. -// TODO: Find a better name for this tag. -struct add_only_property_graph_tag - : virtual add_vertex_property_tag - , virtual mutable_edge_property_graph_tag -{ }; - -/** - * The graph_mutability_traits provide methods for determining the - * interfaces supported by graph classes for adding and removing vertices - * and edges. - */ -template -struct graph_mutability_traits { - typedef typename Graph::mutability_category category; -}; - -template -struct graph_has_add_vertex - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - add_vertex_tag - >::value - > -{ }; - -template -struct graph_has_add_vertex_with_property - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - add_vertex_property_tag - >::value - > -{ }; - - -template -struct graph_has_remove_vertex - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - remove_vertex_tag - >::value - > -{ }; - -template -struct graph_has_add_edge - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - add_edge_tag - >::value - > -{ }; - -template -struct graph_has_add_edge_with_property - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - add_edge_property_tag - >::value - > -{ }; - - -template -struct graph_has_remove_edge - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - remove_edge_tag - >::value - > -{ }; - - -template -struct is_mutable_vertex_graph - : mpl::and_< - graph_has_add_vertex, - graph_has_remove_vertex - > -{ }; - -template -struct is_mutable_vertex_property_graph - : mpl::and_< - graph_has_add_vertex_with_property, - graph_has_remove_vertex - > -{ }; - - -template -struct is_mutable_edge_graph - : mpl::and_< - graph_has_add_edge, - graph_has_remove_edge - > -{ }; - -template -struct is_mutable_edge_property_graph - : mpl::and_< - graph_has_add_edge_with_property, - graph_has_remove_edge - > -{ }; - - -template -struct is_mutable_graph - : mpl::and_< - is_mutable_vertex_graph, - is_mutable_edge_graph - > -{ }; - -template -struct is_mutable_property_graph - : mpl::and_< - is_mutable_vertex_property_graph, - is_mutable_edge_property_graph - > -{ }; - -template -struct is_add_only_property_graph - : mpl::bool_< - is_convertible< - typename graph_mutability_traits::category, - add_only_property_graph_tag - >::value - > -{ }; - -/** @name Mutability Traits Specializations */ -//@{ - -//@} - -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_selectors.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/graph_selectors.hpp deleted file mode 100644 index 777ebefc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_selectors.hpp +++ /dev/null @@ -1,38 +0,0 @@ -//======================================================================= -// Copyright 2002 Indiana University. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_SELECTORS_HPP -#define BOOST_GRAPH_SELECTORS_HPP - -#include - -namespace boost { - - //=========================================================================== - // Selectors for the Directed template parameter of adjacency_list - // and adjacency_matrix. - - struct directedS { enum { is_directed = true, is_bidir = false }; - typedef mpl::true_ is_directed_t; - typedef mpl::false_ is_bidir_t; - }; - struct undirectedS { - enum { is_directed = false, is_bidir = false }; - typedef mpl::false_ is_directed_t; - typedef mpl::false_ is_bidir_t; - }; - struct bidirectionalS { - enum { is_directed = true, is_bidir = true }; - typedef mpl::true_ is_directed_t; - typedef mpl::true_ is_bidir_t; - }; - -} // namespace boost - -#endif // BOOST_GRAPH_SELECTORS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/graph_traits.hpp deleted file mode 100644 index a1c27483..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/graph_traits.hpp +++ /dev/null @@ -1,404 +0,0 @@ -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_TRAITS_HPP -#define BOOST_GRAPH_TRAITS_HPP - -#include -#include -#include /* Primarily for std::pair */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - - namespace detail { -#define BOOST_GRAPH_MEMBER_OR_VOID(name) \ - BOOST_MPL_HAS_XXX_TRAIT_DEF(name) \ - template struct BOOST_JOIN(get_member_, name) {typedef typename T::name type;}; \ - template struct BOOST_JOIN(get_opt_member_, name): \ - boost::mpl::eval_if_c< \ - BOOST_JOIN(has_, name)::value, \ - BOOST_JOIN(get_member_, name), \ - boost::mpl::identity > \ - {}; - BOOST_GRAPH_MEMBER_OR_VOID(adjacency_iterator) - BOOST_GRAPH_MEMBER_OR_VOID(out_edge_iterator) - BOOST_GRAPH_MEMBER_OR_VOID(in_edge_iterator) - BOOST_GRAPH_MEMBER_OR_VOID(vertex_iterator) - BOOST_GRAPH_MEMBER_OR_VOID(edge_iterator) - BOOST_GRAPH_MEMBER_OR_VOID(vertices_size_type) - BOOST_GRAPH_MEMBER_OR_VOID(edges_size_type) - BOOST_GRAPH_MEMBER_OR_VOID(degree_size_type) - } - - template - struct graph_traits { -#define BOOST_GRAPH_PULL_OPT_MEMBER(name) \ - typedef typename detail::BOOST_JOIN(get_opt_member_, name)::type name; - - typedef typename G::vertex_descriptor vertex_descriptor; - typedef typename G::edge_descriptor edge_descriptor; - BOOST_GRAPH_PULL_OPT_MEMBER(adjacency_iterator) - BOOST_GRAPH_PULL_OPT_MEMBER(out_edge_iterator) - BOOST_GRAPH_PULL_OPT_MEMBER(in_edge_iterator) - BOOST_GRAPH_PULL_OPT_MEMBER(vertex_iterator) - BOOST_GRAPH_PULL_OPT_MEMBER(edge_iterator) - - typedef typename G::directed_category directed_category; - typedef typename G::edge_parallel_category edge_parallel_category; - typedef typename G::traversal_category traversal_category; - - BOOST_GRAPH_PULL_OPT_MEMBER(vertices_size_type) - BOOST_GRAPH_PULL_OPT_MEMBER(edges_size_type) - BOOST_GRAPH_PULL_OPT_MEMBER(degree_size_type) -#undef BOOST_GRAPH_PULL_OPT_MEMBER - - static inline vertex_descriptor null_vertex(); - }; - - template - inline typename graph_traits::vertex_descriptor - graph_traits::null_vertex() - { return G::null_vertex(); } - - // directed_category tags - struct directed_tag { }; - struct undirected_tag { }; - struct bidirectional_tag : public directed_tag { }; - - namespace detail { - inline bool is_directed(directed_tag) { return true; } - inline bool is_directed(undirected_tag) { return false; } - } - - /** Return true if the given graph is directed. */ - template - bool is_directed(const Graph&) { - typedef typename graph_traits::directed_category Cat; - return detail::is_directed(Cat()); - } - - /** Return true if the given graph is undirected. */ - template - bool is_undirected(const Graph& g) { - return !is_directed(g); - } - - /** @name Directed/Undirected Graph Traits */ - //@{ - namespace graph_detail { - template - struct is_directed_tag - : mpl::bool_::value> - { }; - } // namespace graph_detail - - template - struct is_directed_graph - : graph_detail::is_directed_tag< - typename graph_traits::directed_category - > - { }; - - template - struct is_undirected_graph - : mpl::not_< is_directed_graph > - { }; - //@} - - // edge_parallel_category tags - struct allow_parallel_edge_tag { }; - struct disallow_parallel_edge_tag { }; - - namespace detail { - inline bool allows_parallel(allow_parallel_edge_tag) { return true; } - inline bool allows_parallel(disallow_parallel_edge_tag) { return false; } - } - - template - bool allows_parallel_edges(const Graph&) { - typedef typename graph_traits::edge_parallel_category Cat; - return detail::allows_parallel(Cat()); - } - - /** @name Parallel Edges Traits */ - //@{ - /** - * The is_multigraph metafunction returns true if the graph allows - * parallel edges. Technically, a multigraph is a simple graph that - * allows parallel edges, but since there are no traits for the allowance - * or disallowance of loops, this is a moot point. - */ - template - struct is_multigraph - : mpl::bool_< - is_same< - typename graph_traits::edge_parallel_category, - allow_parallel_edge_tag - >::value - > - { }; - //@} - - // traversal_category tags - struct incidence_graph_tag { }; - struct adjacency_graph_tag { }; - struct bidirectional_graph_tag : virtual incidence_graph_tag { }; - struct vertex_list_graph_tag { }; - struct edge_list_graph_tag { }; - struct adjacency_matrix_tag { }; - - // Parallel traversal_category tags - struct distributed_graph_tag { }; - struct distributed_vertex_list_graph_tag { }; - struct distributed_edge_list_graph_tag { }; -#define BOOST_GRAPH_SEQUENTIAL_TRAITS_DEFINES_DISTRIBUTED_TAGS // Disable these from external versions of PBGL - - /** @name Traversal Category Traits - * These traits classify graph types by their supported methods of - * vertex and edge traversal. - */ - //@{ - template - struct is_incidence_graph - : mpl::bool_< - is_convertible< - typename graph_traits::traversal_category, - incidence_graph_tag - >::value - > - { }; - - template - struct is_bidirectional_graph - : mpl::bool_< - is_convertible< - typename graph_traits::traversal_category, - bidirectional_graph_tag - >::value - > - { }; - - template - struct is_vertex_list_graph - : mpl::bool_< - is_convertible< - typename graph_traits::traversal_category, - vertex_list_graph_tag - >::value - > - { }; - - template - struct is_edge_list_graph - : mpl::bool_< - is_convertible< - typename graph_traits::traversal_category, - edge_list_graph_tag - >::value - > - { }; - - template - struct is_adjacency_matrix - : mpl::bool_< - is_convertible< - typename graph_traits::traversal_category, - adjacency_matrix_tag - >::value - > - { }; - //@} - - /** @name Directed Graph Traits - * These metafunctions are used to fully classify directed vs. undirected - * graphs. Recall that an undirected graph is also bidirectional, but it - * cannot be both undirected and directed at the same time. - */ - //@{ - template - struct is_directed_unidirectional_graph - : mpl::and_< - is_directed_graph, mpl::not_< is_bidirectional_graph > - > - { }; - - template - struct is_directed_bidirectional_graph - : mpl::and_< - is_directed_graph, is_bidirectional_graph - > - { }; - //@} - - //?? not the right place ?? Lee - typedef boost::forward_traversal_tag multi_pass_input_iterator_tag; - - namespace detail { - BOOST_MPL_HAS_XXX_TRAIT_DEF(graph_property_type) - BOOST_MPL_HAS_XXX_TRAIT_DEF(edge_property_type) - BOOST_MPL_HAS_XXX_TRAIT_DEF(vertex_property_type) - - template struct get_graph_property_type {typedef typename G::graph_property_type type;}; - template struct get_edge_property_type {typedef typename G::edge_property_type type;}; - template struct get_vertex_property_type {typedef typename G::vertex_property_type type;}; - } - - template - struct graph_property_type - : boost::mpl::eval_if, - detail::get_graph_property_type, - no_property> {}; - template - struct edge_property_type - : boost::mpl::eval_if, - detail::get_edge_property_type, - no_property> {}; - template - struct vertex_property_type - : boost::mpl::eval_if, - detail::get_vertex_property_type, - no_property> {}; - - template - struct graph_bundle_type { - typedef typename G::graph_bundled type; - }; - - template - struct vertex_bundle_type { - typedef typename G::vertex_bundled type; - }; - - template - struct edge_bundle_type { - typedef typename G::edge_bundled type; - }; - - namespace graph { namespace detail { - template - class bundled_result { - typedef typename graph_traits::vertex_descriptor Vertex; - typedef typename mpl::if_c<(is_same::value), - vertex_bundle_type, - edge_bundle_type >::type bundler; - public: - typedef typename bundler::type type; - }; - - template - class bundled_result { - typedef typename graph_traits::vertex_descriptor Vertex; - typedef graph_bundle_type bundler; - public: - typedef typename bundler::type type; - }; - - } } // namespace graph::detail - - namespace graph_detail { - // A helper metafunction for determining whether or not a type is - // bundled. - template - struct is_no_bundle : mpl::bool_::value> - { }; - } // namespace graph_detail - - /** @name Graph Property Traits - * These metafunctions (along with those above), can be used to access the - * vertex and edge properties (bundled or otherwise) of vertices and - * edges. - */ - //@{ - template - struct has_graph_property - : mpl::not_< - typename detail::is_no_property< - typename graph_property_type::type - >::type - >::type - { }; - - template - struct has_bundled_graph_property - : mpl::not_< - graph_detail::is_no_bundle::type> - > - { }; - - template - struct has_vertex_property - : mpl::not_< - typename detail::is_no_property::type> - >::type - { }; - - template - struct has_bundled_vertex_property - : mpl::not_< - graph_detail::is_no_bundle::type> - > - { }; - - template - struct has_edge_property - : mpl::not_< - typename detail::is_no_property::type> - >::type - { }; - - template - struct has_bundled_edge_property - : mpl::not_< - graph_detail::is_no_bundle::type> - > - { }; - //@} - -} // namespace boost - -// Since pair is in namespace std, Koenig lookup will find source and -// target if they are also defined in namespace std. This is illegal, -// but the alternative is to put source and target in the global -// namespace which causes name conflicts with other libraries (like -// SUIF). -namespace std { - - /* Some helper functions for dealing with pairs as edges */ - template - T source(pair p, const G&) { return p.first; } - - template - T target(pair p, const G&) { return p.second; } - -} - -#if defined(__GNUC__) && defined(__SGI_STL_PORT) -// For some reason g++ with STLport does not see the above definition -// of source() and target() unless we bring them into the boost -// namespace. -namespace boost { - using std::source; - using std::target; -} -#endif - -#endif // BOOST_GRAPH_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/iteration_macros.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/iteration_macros.hpp deleted file mode 100644 index 2bf40f95..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/iteration_macros.hpp +++ /dev/null @@ -1,140 +0,0 @@ -//======================================================================= -// Copyright 2001 Indiana University -// Author: Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_ITERATION_MACROS_HPP -#define BOOST_GRAPH_ITERATION_MACROS_HPP - -#include - -#define BGL_CAT(x,y) x ## y -#define BGL_RANGE(linenum) BGL_CAT(bgl_range_,linenum) -#define BGL_FIRST(linenum) (BGL_RANGE(linenum).first) -#define BGL_LAST(linenum) (BGL_RANGE(linenum).second) - -/* - BGL_FORALL_VERTICES_T(v, g, graph_t) // This is on line 9 - expands to the following, but all on the same line - - for (typename boost::graph_traits::vertex_iterator - bgl_first_9 = vertices(g).first, bgl_last_9 = vertices(g).second; - bgl_first_9 != bgl_last_9; bgl_first_9 = bgl_last_9) - for (typename boost::graph_traits::vertex_descriptor v; - bgl_first_9 != bgl_last_9 ? (v = *bgl_first_9, true) : false; - ++bgl_first_9) - - The purpose of having two for-loops is just to provide a place to - declare both the iterator and value variables. There is really only - one loop. The stopping condition gets executed two more times than it - usually would be, oh well. The reason for the bgl_first_9 = bgl_last_9 - in the outer for-loop is in case the user puts a break statement - in the inner for-loop. - - The other macros work in a similar fashion. - - Use the _T versions when the graph type is a template parameter or - dependent on a template parameter. Otherwise use the non _T versions. - - ----------------------- - 6/9/09 THK - - The above contains two calls to the vertices function. I modified these - macros to expand to - - for (std::pair::vertex_iterator, - typename boost::graph_traits::vertex_iterator> bgl_range_9 = vertices(g); - bgl_range_9.first != bgl_range_9.second; - bgl_range_9.first = bgl_range_9.second) - for (typename boost::graph_traits::vertex_descriptor v; - bgl_range_9.first != bgl_range_9.second ? (v = *bgl_range_9.first, true) : false; - ++bgl_range_9.first) - - */ - - -#define BGL_FORALL_VERTICES_T(VNAME, GNAME, GraphType) \ -for (std::pair::vertex_iterator, \ - typename boost::graph_traits::vertex_iterator> BGL_RANGE(__LINE__) = vertices(GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ - for (typename boost::graph_traits::vertex_descriptor VNAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (VNAME = *BGL_FIRST(__LINE__), true):false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_VERTICES(VNAME, GNAME, GraphType) \ -for (std::pair::vertex_iterator, \ - boost::graph_traits::vertex_iterator> BGL_RANGE(__LINE__) = vertices(GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ - for (boost::graph_traits::vertex_descriptor VNAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (VNAME = *BGL_FIRST(__LINE__), true):false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_EDGES_T(ENAME, GNAME, GraphType) \ -for (std::pair::edge_iterator, \ - typename boost::graph_traits::edge_iterator> BGL_RANGE(__LINE__) = edges(GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ - for (typename boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true):false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_EDGES(ENAME, GNAME, GraphType) \ -for (std::pair::edge_iterator, \ - boost::graph_traits::edge_iterator> BGL_RANGE(__LINE__) = edges(GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ - for (boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true):false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_ADJ_T(UNAME, VNAME, GNAME, GraphType) \ -for (std::pair::adjacency_iterator, \ - typename boost::graph_traits::adjacency_iterator> BGL_RANGE(__LINE__) = adjacent_vertices(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (typename boost::graph_traits::vertex_descriptor VNAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (VNAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_ADJ(UNAME, VNAME, GNAME, GraphType) \ -for (std::pair::adjacency_iterator, \ - boost::graph_traits::adjacency_iterator> BGL_RANGE(__LINE__) = adjacent_vertices(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (boost::graph_traits::vertex_descriptor VNAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (VNAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_OUTEDGES_T(UNAME, ENAME, GNAME, GraphType) \ -for (std::pair::out_edge_iterator, \ - typename boost::graph_traits::out_edge_iterator> BGL_RANGE(__LINE__) = out_edges(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (typename boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_OUTEDGES(UNAME, ENAME, GNAME, GraphType) \ -for (std::pair::out_edge_iterator, \ - boost::graph_traits::out_edge_iterator> BGL_RANGE(__LINE__) = out_edges(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_INEDGES_T(UNAME, ENAME, GNAME, GraphType) \ -for (std::pair::in_edge_iterator, \ - typename boost::graph_traits::in_edge_iterator> BGL_RANGE(__LINE__) = in_edges(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (typename boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#define BGL_FORALL_INEDGES(UNAME, ENAME, GNAME, GraphType) \ -for (std::pair::in_edge_iterator, \ - boost::graph_traits::in_edge_iterator> BGL_RANGE(__LINE__) = in_edges(UNAME, GNAME); \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \ -for (boost::graph_traits::edge_descriptor ENAME; \ - BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (ENAME = *BGL_FIRST(__LINE__), true) : false; \ - ++BGL_FIRST(__LINE__)) - -#endif // BOOST_GRAPH_ITERATION_MACROS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/named_function_params.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/named_function_params.hpp deleted file mode 100644 index 26d3d5e4..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/named_function_params.hpp +++ /dev/null @@ -1,738 +0,0 @@ -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_NAMED_FUNCTION_PARAMS_HPP -#define BOOST_GRAPH_NAMED_FUNCTION_PARAMS_HPP - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - - struct parity_map_t { }; - struct vertex_assignment_map_t { }; - struct distance_compare_t { }; - struct distance_combine_t { }; - struct distance_inf_t { }; - struct distance_zero_t { }; - struct buffer_param_t { }; - struct edge_copy_t { }; - struct vertex_copy_t { }; - struct vertex_isomorphism_t { }; - struct vertex_invariant_t { }; - struct vertex_invariant1_t { }; - struct vertex_invariant2_t { }; - struct edge_compare_t { }; - struct vertex_max_invariant_t { }; - struct orig_to_copy_t { }; - struct root_vertex_t { }; - struct polling_t { }; - struct lookahead_t { }; - struct in_parallel_t { }; - struct attractive_force_t { }; - struct repulsive_force_t { }; - struct force_pairs_t { }; - struct cooling_t { }; - struct vertex_displacement_t { }; - struct iterations_t { }; - struct diameter_range_t { }; - struct learning_constant_range_t { }; - struct vertices_equivalent_t { }; - struct edges_equivalent_t { }; - struct index_in_heap_map_t { }; - struct max_priority_queue_t { }; - -#define BOOST_BGL_DECLARE_NAMED_PARAMS \ - BOOST_BGL_ONE_PARAM_CREF(weight_map, edge_weight) \ - BOOST_BGL_ONE_PARAM_CREF(weight_map2, edge_weight2) \ - BOOST_BGL_ONE_PARAM_CREF(distance_map, vertex_distance) \ - BOOST_BGL_ONE_PARAM_CREF(distance_map2, vertex_distance2) \ - BOOST_BGL_ONE_PARAM_CREF(predecessor_map, vertex_predecessor) \ - BOOST_BGL_ONE_PARAM_CREF(rank_map, vertex_rank) \ - BOOST_BGL_ONE_PARAM_CREF(root_map, vertex_root) \ - BOOST_BGL_ONE_PARAM_CREF(root_vertex, root_vertex) \ - BOOST_BGL_ONE_PARAM_CREF(edge_centrality_map, edge_centrality) \ - BOOST_BGL_ONE_PARAM_CREF(centrality_map, vertex_centrality) \ - BOOST_BGL_ONE_PARAM_CREF(parity_map, parity_map) \ - BOOST_BGL_ONE_PARAM_CREF(color_map, vertex_color) \ - BOOST_BGL_ONE_PARAM_CREF(edge_color_map, edge_color) \ - BOOST_BGL_ONE_PARAM_CREF(capacity_map, edge_capacity) \ - BOOST_BGL_ONE_PARAM_CREF(residual_capacity_map, edge_residual_capacity) \ - BOOST_BGL_ONE_PARAM_CREF(reverse_edge_map, edge_reverse) \ - BOOST_BGL_ONE_PARAM_CREF(discover_time_map, vertex_discover_time) \ - BOOST_BGL_ONE_PARAM_CREF(lowpoint_map, vertex_lowpoint) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_index_map, vertex_index) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_index1_map, vertex_index1) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_index2_map, vertex_index2) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_assignment_map, vertex_assignment_map) \ - BOOST_BGL_ONE_PARAM_CREF(visitor, graph_visitor) \ - BOOST_BGL_ONE_PARAM_CREF(distance_compare, distance_compare) \ - BOOST_BGL_ONE_PARAM_CREF(distance_combine, distance_combine) \ - BOOST_BGL_ONE_PARAM_CREF(distance_inf, distance_inf) \ - BOOST_BGL_ONE_PARAM_CREF(distance_zero, distance_zero) \ - BOOST_BGL_ONE_PARAM_CREF(edge_copy, edge_copy) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_copy, vertex_copy) \ - BOOST_BGL_ONE_PARAM_REF(buffer, buffer_param) \ - BOOST_BGL_ONE_PARAM_CREF(orig_to_copy, orig_to_copy) \ - BOOST_BGL_ONE_PARAM_CREF(isomorphism_map, vertex_isomorphism) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_invariant, vertex_invariant) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_invariant1, vertex_invariant1) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_invariant2, vertex_invariant2) \ - BOOST_BGL_ONE_PARAM_CREF(vertex_max_invariant, vertex_max_invariant) \ - BOOST_BGL_ONE_PARAM_CREF(polling, polling) \ - BOOST_BGL_ONE_PARAM_CREF(lookahead, lookahead) \ - BOOST_BGL_ONE_PARAM_CREF(in_parallel, in_parallel) \ - BOOST_BGL_ONE_PARAM_CREF(displacement_map, vertex_displacement) \ - BOOST_BGL_ONE_PARAM_CREF(attractive_force, attractive_force) \ - BOOST_BGL_ONE_PARAM_CREF(repulsive_force, repulsive_force) \ - BOOST_BGL_ONE_PARAM_CREF(force_pairs, force_pairs) \ - BOOST_BGL_ONE_PARAM_CREF(cooling, cooling) \ - BOOST_BGL_ONE_PARAM_CREF(iterations, iterations) \ - BOOST_BGL_ONE_PARAM_CREF(diameter_range, diameter_range) \ - BOOST_BGL_ONE_PARAM_CREF(learning_constant_range, learning_constant_range) \ - BOOST_BGL_ONE_PARAM_CREF(vertices_equivalent, vertices_equivalent) \ - BOOST_BGL_ONE_PARAM_CREF(edges_equivalent, edges_equivalent) \ - BOOST_BGL_ONE_PARAM_CREF(index_in_heap_map, index_in_heap_map) \ - BOOST_BGL_ONE_PARAM_REF(max_priority_queue, max_priority_queue) - - template - struct bgl_named_params - { - typedef bgl_named_params self; - typedef Base next_type; - typedef Tag tag_type; - typedef T value_type; - bgl_named_params(T v = T()) : m_value(v) { } - bgl_named_params(T v, const Base& b) : m_value(v), m_base(b) { } - T m_value; - Base m_base; - -#define BOOST_BGL_ONE_PARAM_REF(name, key) \ - template \ - bgl_named_params, BOOST_PP_CAT(key, _t), self> \ - name(PType& p) const { \ - typedef bgl_named_params, BOOST_PP_CAT(key, _t), self> Params; \ - return Params(boost::ref(p), *this); \ - } \ - -#define BOOST_BGL_ONE_PARAM_CREF(name, key) \ - template \ - bgl_named_params \ - name(const PType& p) const { \ - typedef bgl_named_params Params; \ - return Params(p, *this); \ - } \ - -BOOST_BGL_DECLARE_NAMED_PARAMS - -#undef BOOST_BGL_ONE_PARAM_REF -#undef BOOST_BGL_ONE_PARAM_CREF - - // Duplicate - template - bgl_named_params - vertex_color_map(const PType& p) const {return this->color_map(p);} - }; - -#define BOOST_BGL_ONE_PARAM_REF(name, key) \ - template \ - bgl_named_params, BOOST_PP_CAT(key, _t)> \ - name(PType& p) { \ - typedef bgl_named_params, BOOST_PP_CAT(key, _t)> Params; \ - return Params(boost::ref(p)); \ - } \ - -#define BOOST_BGL_ONE_PARAM_CREF(name, key) \ - template \ - bgl_named_params \ - name(const PType& p) { \ - typedef bgl_named_params Params; \ - return Params(p); \ - } \ - -BOOST_BGL_DECLARE_NAMED_PARAMS - -#undef BOOST_BGL_ONE_PARAM_REF -#undef BOOST_BGL_ONE_PARAM_CREF - - // Duplicate - template - bgl_named_params - vertex_color_map(const PType& p) {return color_map(p);} - - namespace detail { - struct unused_tag_type {}; - } - typedef bgl_named_params no_named_parameters; - - //=========================================================================== - // Functions for extracting parameters from bgl_named_params - - template - struct lookup_named_param {}; - - template - struct lookup_named_param > { - typedef T type; - static const T& get(const bgl_named_params& p) { - return p.m_value; - } - }; - - template - struct lookup_named_param > { - typedef typename lookup_named_param::type type; - static const type& get(const bgl_named_params& p) { - return lookup_named_param::get(p.m_base); - } - }; - - template - struct lookup_named_param_def { - typedef Def type; - static const Def& get(const Args&, const Def& def) {return def;} - }; - - template - struct lookup_named_param_def, Def> { - typedef T type; - static const type& get(const bgl_named_params& p, const Def&) { - return p.m_value; - } - }; - - template - struct lookup_named_param_def, Def> { - typedef typename lookup_named_param_def::type type; - static const type& get(const bgl_named_params& p, const Def& def) { - return lookup_named_param_def::get(p.m_base, def); - } - }; - - struct param_not_found {}; - - template - struct get_param_type: - lookup_named_param_def {}; - - template - inline - const typename lookup_named_param_def::type& - get_param(const Args& p, Tag) { - return lookup_named_param_def::get(p, param_not_found()); - } - - template - const P& choose_param(const P& param, const Default&) { - return param; - } - - template - Default choose_param(const param_not_found&, const Default& d) { - return d; - } - - template - inline bool is_default_param(const T&) { return false; } - - inline bool is_default_param(const param_not_found&) - { return true; } - - namespace detail { - template - struct const_type_as_type {typedef typename T::const_type type;}; - } // namespace detail - - - // Use this function instead of choose_param() when you want - // to avoid requiring get(tag, g) when it is not used. - namespace detail { - template - struct choose_impl_result: - boost::mpl::eval_if< - boost::is_same, - boost::mpl::eval_if< - GraphIsConst, - detail::const_type_as_type >, - property_map >, - boost::mpl::identity > {}; - - // Parameters of f are (GraphIsConst, Graph, Param, Tag) - template struct choose_impl_helper; - - template <> struct choose_impl_helper { - template - static typename property_map::type, PropertyTag>::const_type - f(boost::mpl::true_, const Graph& g, const Param&, PropertyTag tag) { - return get(tag, g); - } - - template - static typename property_map::type, PropertyTag>::type - f(boost::mpl::false_, Graph& g, const Param&, PropertyTag tag) { - return get(tag, g); - } - }; - - template <> struct choose_impl_helper { - template - static Param f(GraphIsConst, const Graph&, const Param& p, PropertyTag) { - return p; - } - }; - } - - template - typename detail::choose_impl_result::type - choose_const_pmap(const Param& p, const Graph& g, PropertyTag tag) - { - return detail::choose_impl_helper::value> - ::f(boost::mpl::true_(), g, p, tag); - } - - template - typename detail::choose_impl_result::type - choose_pmap(const Param& p, Graph& g, PropertyTag tag) - { - return detail::choose_impl_helper::value> - ::f(boost::mpl::false_(), g, p, tag); - } - - namespace detail { - - // used in the max-flow algorithms - template - struct edge_capacity_value - { - typedef bgl_named_params Params; - typedef typename detail::choose_impl_result::type, edge_capacity_t>::type CapacityEdgeMap; - typedef typename property_traits::value_type type; - }; - - } - - // Declare all new tags - namespace graph { - namespace keywords { -#define BOOST_BGL_ONE_PARAM_REF(name, key) BOOST_PARAMETER_NAME(name) -#define BOOST_BGL_ONE_PARAM_CREF(name, key) BOOST_PARAMETER_NAME(name) - BOOST_BGL_DECLARE_NAMED_PARAMS -#undef BOOST_BGL_ONE_PARAM_REF -#undef BOOST_BGL_ONE_PARAM_CREF - } - } - - namespace detail { - template struct convert_one_keyword {}; -#define BOOST_BGL_ONE_PARAM_REF(name, key) \ - template <> \ - struct convert_one_keyword { \ - typedef boost::graph::keywords::tag::name type; \ - }; -#define BOOST_BGL_ONE_PARAM_CREF(name, key) BOOST_BGL_ONE_PARAM_REF(name, key) - BOOST_BGL_DECLARE_NAMED_PARAMS -#undef BOOST_BGL_ONE_PARAM_REF -#undef BOOST_BGL_ONE_PARAM_CREF - - template - struct convert_bgl_params_to_boost_parameter { - typedef typename convert_one_keyword::type new_kw; - typedef boost::parameter::aux::tagged_argument tagged_arg_type; - typedef convert_bgl_params_to_boost_parameter rest_conv; - typedef boost::parameter::aux::arg_list type; - static type conv(const T& x) { - return type(tagged_arg_type(x.m_value), rest_conv::conv(x.m_base)); - } - }; - - template - struct convert_bgl_params_to_boost_parameter > { - typedef convert_bgl_params_to_boost_parameter rest_conv; - typedef typename rest_conv::type type; - static type conv(const bgl_named_params& x) { - return rest_conv::conv(x.m_base); - } - }; - - template <> - struct convert_bgl_params_to_boost_parameter { - typedef boost::parameter::aux::empty_arg_list type; - static type conv(const boost::no_property&) {return type();} - }; - - template <> - struct convert_bgl_params_to_boost_parameter { - typedef boost::parameter::aux::empty_arg_list type; - static type conv(const boost::no_named_parameters&) {return type();} - }; - - struct bgl_parameter_not_found_type {}; - - template - struct parameter_exists : boost::mpl::not_::type, bgl_parameter_not_found_type> > {}; - } - -#define BOOST_GRAPH_DECLARE_CONVERTED_PARAMETERS(old_type, old_var) \ - typedef typename boost::detail::convert_bgl_params_to_boost_parameter::type arg_pack_type; \ - arg_pack_type arg_pack = boost::detail::convert_bgl_params_to_boost_parameter::conv(old_var); - - namespace detail { - - template - struct override_const_property_t { - typedef typename boost::remove_const::type result_type; - result_type operator()(const Graph&, const ArgType& a) const {return a;} - }; - - template - struct override_const_property_t { - typedef typename boost::property_map::const_type result_type; - result_type operator()(const Graph& g, const ArgType&) const {return get(Prop(), g);} - }; - - template - struct override_const_property_result { - typedef - typename override_const_property_t< - typename boost::parameter::value_type::type, - Prop, - Graph, - boost::detail::parameter_exists::value - >::result_type - type; - }; - - template - typename override_const_property_result::type - override_const_property(const ArgPack& ap, const boost::parameter::keyword& t, const Graph& g, Prop) { - return override_const_property_t< - typename boost::parameter::value_type::type, - Prop, - Graph, - boost::detail::parameter_exists::value - >()(g, ap[t | 0]); - } - - template - struct override_property_t { - typedef ArgType result_type; - result_type operator()(const Graph&, const typename boost::add_reference::type a) const {return a;} - }; - - template - struct override_property_t { - typedef typename boost::property_map::type result_type; - result_type operator()(const Graph& g, const ArgType&) const {return get(Prop(), g);} - }; - - template - struct override_property_result { - typedef - typename override_property_t< - typename boost::parameter::value_type::type, - Prop, - Graph, - boost::detail::parameter_exists::value - >::result_type - type; - }; - - template - typename override_property_result::type - override_property(const ArgPack& ap, const boost::parameter::keyword& t, const Graph& g, Prop) { - return override_property_t< - typename boost::parameter::value_type::type, - Prop, - Graph, - boost::detail::parameter_exists::value - >()(g, ap[t | 0]); - } - - template struct make_arg_pack_type; - template <> struct make_arg_pack_type {typedef boost::parameter::aux::empty_arg_list type;}; - template - struct make_arg_pack_type { - typedef boost::parameter::aux::tagged_argument type; - }; - -#define BOOST_GRAPH_OPENING_PART_OF_PAIR(z, i, n) boost::parameter::aux::arg_list, -#define BOOST_GRAPH_MAKE_PAIR_PARAM(z, i, _) const boost::parameter::aux::tagged_argument& BOOST_PP_CAT(kw, i) - -#define BOOST_GRAPH_MAKE_AP_TYPE_SPECIALIZATION(z, i, _) \ - template \ - struct make_arg_pack_type { \ - typedef \ - BOOST_PP_REPEAT(i, BOOST_GRAPH_OPENING_PART_OF_PAIR, BOOST_PP_DEC(i)) boost::parameter::aux::empty_arg_list BOOST_PP_REPEAT(i, > BOOST_PP_TUPLE_EAT(3), ~) \ - type; \ - }; - BOOST_PP_REPEAT_FROM_TO(2, 11, BOOST_GRAPH_MAKE_AP_TYPE_SPECIALIZATION, ~) -#undef BOOST_GRAPH_MAKE_AP_TYPE_SPECIALIZATION - -#define BOOST_GRAPH_MAKE_FORWARDING_FUNCTION(name, nfixed, nnamed_max) \ - /* Entry point for conversion from BGL-style named parameters */ \ - template \ - typename boost::result_of< \ - detail::BOOST_PP_CAT(name, _impl)(BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_COMMA_IF(nfixed) const ArgPack&) \ - >::type \ - BOOST_PP_CAT(name, _with_named_params)(BOOST_PP_ENUM_BINARY_PARAMS(nfixed, const Param, & param) BOOST_PP_COMMA_IF(nfixed) const ArgPack& arg_pack) { \ - return detail::BOOST_PP_CAT(name, _impl)()(BOOST_PP_ENUM_PARAMS(nfixed, param) BOOST_PP_COMMA_IF(nfixed) arg_pack); \ - } \ - /* Individual functions taking Boost.Parameter-style keyword arguments */ \ - BOOST_PP_REPEAT(BOOST_PP_INC(nnamed_max), BOOST_GRAPH_MAKE_FORWARDING_FUNCTION_ONE, (name)(nfixed)) - -#define BOOST_GRAPH_MAKE_FORWARDING_FUNCTION_ONE(z, nnamed, seq) \ - BOOST_GRAPH_MAKE_FORWARDING_FUNCTION_ONEX(z, nnamed, BOOST_PP_SEQ_ELEM(0, seq), BOOST_PP_SEQ_ELEM(1, seq)) - -#define BOOST_GRAPH_MAKE_FORWARDING_FUNCTION_ONEX(z, nnamed, name, nfixed) \ - template \ - typename boost::result_of< \ - detail::BOOST_PP_CAT(name, _impl) \ - (BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_COMMA_IF(nfixed) \ - const typename boost::detail::make_arg_pack_type::type&) \ - >::type \ - name(BOOST_PP_ENUM_BINARY_PARAMS(nfixed, const Param, & param) \ - BOOST_PP_ENUM_TRAILING(nnamed, BOOST_GRAPH_MAKE_PAIR_PARAM, ~)) { \ - return detail::BOOST_PP_CAT(name, _impl)() \ - (BOOST_PP_ENUM_PARAMS(nfixed, param), \ - (boost::parameter::aux::empty_arg_list() BOOST_PP_ENUM_TRAILING_PARAMS(nnamed, kw))); \ - } - -#define BOOST_GRAPH_MAKE_OLD_STYLE_PARAMETER_FUNCTION(name, nfixed) \ - template \ - typename boost::result_of< \ - ::boost::graph::detail::BOOST_PP_CAT(name, _impl) BOOST_PP_EXPR_IF(nfixed, <) BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_EXPR_IF(nfixed, >) \ - (BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_COMMA_IF(nfixed) \ - const typename boost::detail::convert_bgl_params_to_boost_parameter >::type &) \ - >::type \ - name(BOOST_PP_ENUM_BINARY_PARAMS(nfixed, const Param, & param) BOOST_PP_COMMA_IF(nfixed) const boost::bgl_named_params& old_style_params) { \ - typedef boost::bgl_named_params old_style_params_type; \ - BOOST_GRAPH_DECLARE_CONVERTED_PARAMETERS(old_style_params_type, old_style_params) \ - return ::boost::graph::BOOST_PP_CAT(name, _with_named_params)(BOOST_PP_ENUM_PARAMS(nfixed, param) BOOST_PP_COMMA_IF(nfixed) arg_pack); \ - } \ - \ - BOOST_PP_EXPR_IF(nfixed, template <) BOOST_PP_ENUM_PARAMS(nfixed, typename Param) BOOST_PP_EXPR_IF(nfixed, >) \ - BOOST_PP_EXPR_IF(nfixed, typename) boost::result_of< \ - ::boost::graph::detail::BOOST_PP_CAT(name, _impl) BOOST_PP_EXPR_IF(nfixed, <) BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_EXPR_IF(nfixed, >) \ - (BOOST_PP_ENUM_PARAMS(nfixed, Param) BOOST_PP_COMMA_IF(nfixed) const boost::parameter::aux::empty_arg_list &) \ - >::type \ - name(BOOST_PP_ENUM_BINARY_PARAMS(nfixed, const Param, & param)) { \ - BOOST_GRAPH_DECLARE_CONVERTED_PARAMETERS(boost::no_named_parameters, boost::no_named_parameters()) \ - return ::boost::graph::BOOST_PP_CAT(name, _with_named_params)(BOOST_PP_ENUM_PARAMS(nfixed, param) BOOST_PP_COMMA_IF(nfixed) arg_pack); \ - } - - } - - namespace detail { - - template - struct map_maker_helper { - typedef PM map_type; - static PM make_map(const Graph&, Value, const PM& pm, const ArgPack&) { - return pm; - } - }; - - template - struct map_maker_helper { - typedef typename boost::remove_const< - typename override_const_property_t< - typename boost::parameter::value_type< - ArgPack, boost::graph::keywords::tag::vertex_index_map, int>::type, - boost::vertex_index_t, - Graph, - boost::detail::parameter_exists< - ArgPack, boost::graph::keywords::tag::vertex_index_map>::value - >::result_type>::type vi_map_type; - typedef - boost::shared_array_property_map - map_type; - static map_type make_map(const Graph& g, - Value v, - const PM&, - const ArgPack& ap) { - return make_shared_array_property_map( - num_vertices(g), - v, - override_const_property( - ap, - boost::graph::keywords::_vertex_index_map, - g, vertex_index)); - } - }; - - template - struct map_maker { - BOOST_STATIC_CONSTANT( - bool, - has_map = - (parameter_exists - ::value)); - typedef map_maker_helper::type - >::type> helper; - typedef typename helper::map_type map_type; - static map_type make_map(const Graph& g, const ArgPack& ap, ValueType default_value) { - return helper::make_map(g, default_value, ap[::boost::parameter::keyword::instance | 0], ap); - } - }; - - template - class make_property_map_from_arg_pack_gen { - ValueType default_value; - - public: - make_property_map_from_arg_pack_gen(ValueType default_value) - : default_value(default_value) {} - - template - typename map_maker::map_type - operator()(const Graph& g, const ArgPack& ap) const { - return map_maker::make_map(g, ap, default_value); - } - }; - - template - class make_property_map_from_arg_pack_gen { - public: - template - typename map_maker::map_type - operator()(const Graph& g, const ArgPack& ap, ValueType default_value) const { - return map_maker::make_map(g, ap, default_value); - } - }; - - static const - make_property_map_from_arg_pack_gen< - boost::graph::keywords::tag::color_map, - default_color_type> - make_color_map_from_arg_pack(white_color); - - template - struct priority_queue_maker_helper { - typedef Q priority_queue_type; - - static priority_queue_type - make_queue(const Graph&, const ArgPack&, KeyT, const Q& q) { - return q; - } - }; - - template - struct priority_queue_maker_helper { - typedef typename std::vector::size_type default_index_in_heap_type; - typedef typename map_maker::helper::map_type index_in_heap_map; - typedef boost::d_ary_heap_indirect::helper::map_type, Compare> priority_queue_type; - - static priority_queue_type - make_queue(const Graph& g, const ArgPack& ap, KeyT defaultKey, const Q&) { - return priority_queue_type( - map_maker::make_map(g, ap, defaultKey), - map_maker::make_map(g, ap, typename boost::property_traits::value_type(-1)) - ); - } - }; - - template - struct priority_queue_maker { - BOOST_STATIC_CONSTANT( - bool, - g_hasQ = - (parameter_exists - ::value)); - typedef boost::reference_wrapper int_refw; - typedef typename boost::parameter::value_type< - ArgPack, - PriorityQueueTag, - int_refw - >::type - param_value_type_wrapper; - typedef typename param_value_type_wrapper::type - param_value_type; - typedef typename boost::remove_const::type param_value_type_no_const; - typedef priority_queue_maker_helper helper; - typedef typename helper::priority_queue_type priority_queue_type; - - static priority_queue_type make_queue(const Graph& g, const ArgPack& ap, KeyT defaultKey) { - return helper::make_queue(g, ap, defaultKey, ap[::boost::parameter::keyword::instance | 0]); - } - }; - - template , class KeyMapTag = boost::graph::keywords::tag::distance_map, class IndexInHeapMapTag = boost::graph::keywords::tag::index_in_heap_map> - struct make_priority_queue_from_arg_pack_gen { - KeyT defaultKey; - - make_priority_queue_from_arg_pack_gen(KeyT defaultKey_) : defaultKey(defaultKey_) { } - - template - struct result { - typedef typename remove_const::arg1_type>::type>::type graph_type; - typedef typename remove_const::arg2_type>::type>::type arg_pack_type; - typedef typename priority_queue_maker::priority_queue_type type; - }; - - template - typename priority_queue_maker::priority_queue_type - operator()(const Graph& g, const ArgPack& ap) const { - return priority_queue_maker::make_queue(g, ap, defaultKey); - } - }; - - template - typename boost::graph_traits::vertex_descriptor - get_null_vertex(const G&) {return boost::graph_traits::null_vertex();} - - template - typename boost::graph_traits::vertex_descriptor - get_default_starting_vertex(const G& g) { - std::pair::vertex_iterator, typename boost::graph_traits::vertex_iterator> iters = vertices(g); - return (iters.first == iters.second) ? boost::graph_traits::null_vertex() : *iters.first; - } - - template - struct get_default_starting_vertex_t { - typedef typename boost::graph_traits::vertex_descriptor result_type; - const G& g; - get_default_starting_vertex_t(const G& g): g(g) {} - result_type operator()() const {return get_default_starting_vertex(g);} - }; - - // Wrapper to avoid instantiating numeric_limits when users provide distance_inf value manually - template - struct get_max { - T operator()() const { - return (std::numeric_limits::max)(); - } - typedef T result_type; - }; - - } // namespace detail - -} // namespace boost - -#undef BOOST_BGL_DECLARE_NAMED_PARAMS - -#endif // BOOST_GRAPH_NAMED_FUNCTION_PARAMS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/named_graph.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/named_graph.hpp deleted file mode 100644 index d82807f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/named_graph.hpp +++ /dev/null @@ -1,547 +0,0 @@ -// Copyright (C) 2007 Douglas Gregor - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Provides support for named vertices in graphs, allowing one to more -// easily associate unique external names (URLs, city names, employee -// ID numbers, etc.) with the vertices of a graph. -#ifndef BOOST_GRAPH_NAMED_GRAPH_HPP -#define BOOST_GRAPH_NAMED_GRAPH_HPP - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include // for boost::lookup_one_property -#include -#include -#include // for boost::make_tuple -#include -#include -#include -#include -#include -#include // for std::equal_to -#include // for std::runtime_error -#include // for std::pair - -namespace boost { namespace graph { - -/******************************************************************* - * User-customized traits * - *******************************************************************/ - -/** - * @brief Trait used to extract the internal vertex name from a vertex - * property. - * - * To enable the use of internal vertex names in a graph type, - * specialize the @c internal_vertex_name trait for your graph - * property (e.g., @c a City class, which stores information about the - * vertices in a road map). - */ -template -struct internal_vertex_name -{ - /** - * The @c type field provides a function object that extracts a key - * from the @c VertexProperty. The function object type must have a - * nested @c result_type that provides the type of the key. For - * more information, see the @c KeyExtractor concept in the - * Boost.MultiIndex documentation: @c type must either be @c void - * (if @c VertexProperty does not have an internal vertex name) or - * a model of @c KeyExtractor. - */ - typedef void type; -}; - -#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -/** - * Extract the internal vertex name from a @c property structure by - * looking at its base. - */ -template -struct internal_vertex_name > - : internal_vertex_name { }; -#endif - -/** - * Construct an instance of @c VertexProperty directly from its - * name. This function object should be used within the @c - * internal_vertex_constructor trait. - */ -template -struct vertex_from_name -{ -private: - typedef typename internal_vertex_name::type extract_name_type; - - typedef typename remove_cv< - typename remove_reference< - typename extract_name_type::result_type>::type>::type - vertex_name_type; - -public: - typedef vertex_name_type argument_type; - typedef VertexProperty result_type; - - VertexProperty operator()(const vertex_name_type& name) - { - return VertexProperty(name); - } -}; - -/** - * Throw an exception whenever one tries to construct a @c - * VertexProperty instance from its name. - */ -template -struct cannot_add_vertex -{ -private: - typedef typename internal_vertex_name::type extract_name_type; - - typedef typename remove_cv< - typename remove_reference< - typename extract_name_type::result_type>::type>::type - vertex_name_type; - -public: - typedef vertex_name_type argument_type; - typedef VertexProperty result_type; - - VertexProperty operator()(const vertex_name_type&) - { - boost::throw_exception(std::runtime_error("add_vertex: " - "unable to create a vertex from its name")); - } -}; - -/** - * @brief Trait used to construct an instance of a @c VertexProperty, - * which is a class type that stores the properties associated with a - * vertex in a graph, from just the name of that vertex property. This - * operation is used when an operation is required to map from a - * vertex name to a vertex descriptor (e.g., to add an edge outgoing - * from that vertex), but no vertex by the name exists. The function - * object provided by this trait will be used to add new vertices - * based only on their names. Since this cannot be done for arbitrary - * types, the default behavior is to throw an exception when this - * routine is called, which requires that all named vertices be added - * before adding any edges by name. - */ -template -struct internal_vertex_constructor -{ - /** - * The @c type field provides a function object that constructs a - * new instance of @c VertexProperty from the name of the vertex (as - * determined by @c internal_vertex_name). The function object shall - * accept a vertex name and return a @c VertexProperty. Predefined - * options include: - * - * @c vertex_from_name: construct an instance of - * @c VertexProperty directly from the name. - * - * @c cannot_add_vertex: the default value, which - * throws an @c std::runtime_error if one attempts to add a vertex - * given just the name. - */ - typedef cannot_add_vertex type; -}; - -#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -/** - * Extract the internal vertex constructor from a @c property structure by - * looking at its base. - */ -template -struct internal_vertex_constructor > - : internal_vertex_constructor { }; -#endif - -/******************************************************************* - * Named graph mixin * - *******************************************************************/ - -/** - * named_graph is a mixin that provides names for the vertices of a - * graph, including a mapping from names to vertices. Graph types that - * may or may not be have vertex names (depending on the properties - * supplied by the user) should use maybe_named_graph. - * - * Template parameters: - * - * Graph: the graph type that derives from named_graph - * - * Vertex: the type of a vertex descriptor in Graph. Note: we cannot - * use graph_traits here, because the Graph is not yet defined. - * - * VertexProperty: the type stored with each vertex in the Graph. - */ -template -class named_graph -{ -public: - /// The type of the function object that extracts names from vertex - /// properties. - typedef typename internal_vertex_name::type extract_name_type; - /// The type of the "bundled" property, from which the name can be - /// extracted. - typedef typename lookup_one_property::type - bundled_vertex_property_type; - - /// The type of the function object that generates vertex properties - /// from names, for the implicit addition of vertices. - typedef typename internal_vertex_constructor::type - vertex_constructor_type; - - /// The type used to name vertices in the graph - typedef typename remove_cv< - typename remove_reference< - typename extract_name_type::result_type>::type>::type - vertex_name_type; - - /// The type of vertex descriptors in the graph - typedef Vertex vertex_descriptor; - -private: - /// Key extractor for use with the multi_index_container - struct extract_name_from_vertex - { - typedef vertex_name_type result_type; - - extract_name_from_vertex(Graph& graph, const extract_name_type& extract) - : graph(graph), extract(extract) { } - - const result_type& operator()(Vertex vertex) const - { - return extract(graph[vertex]); - } - - Graph& graph; - extract_name_type extract; - }; - -public: - /// The type that maps names to vertices - typedef multi_index::multi_index_container< - Vertex, - multi_index::indexed_by< - multi_index::hashed_unique, - extract_name_from_vertex> > - > named_vertices_type; - - /// The set of vertices, indexed by name - typedef typename named_vertices_type::template index::type - vertices_by_name_type; - - /// Construct an instance of the named graph mixin, using the given - /// function object to extract a name from the bundled property - /// associated with a vertex. - named_graph(const extract_name_type& extract = extract_name_type(), - const vertex_constructor_type& vertex_constructor - = vertex_constructor_type()); - - /// Notify the named_graph that we have added the given vertex. The - /// name of the vertex will be added to the mapping. - void added_vertex(Vertex vertex); - - /// Notify the named_graph that we are removing the given - /// vertex. The name of the vertex will be removed from the mapping. - template - void removing_vertex(Vertex vertex, VertexIterStability); - - /// Notify the named_graph that we are clearing the graph. - /// This will clear out all of the name->vertex mappings - void clearing_graph(); - - /// Retrieve the derived instance - Graph& derived() { return static_cast(*this); } - const Graph& derived() const { return static_cast(*this); } - - /// Extract the name from a vertex property instance - typename extract_name_type::result_type - extract_name(const bundled_vertex_property_type& property); - - /// Search for a vertex that has the given property (based on its - /// name) - optional - vertex_by_property(const bundled_vertex_property_type& property); - - /// Mapping from names to vertices - named_vertices_type named_vertices; - - /// Constructs a vertex from the name of that vertex - vertex_constructor_type vertex_constructor; -}; - -/// Helper macro containing the template parameters of named_graph -#define BGL_NAMED_GRAPH_PARAMS \ - typename Graph, typename Vertex, typename VertexProperty -/// Helper macro containing the named_graph<...> instantiation -#define BGL_NAMED_GRAPH \ - named_graph - -template -BGL_NAMED_GRAPH::named_graph(const extract_name_type& extract, - const vertex_constructor_type& vertex_constructor) - : named_vertices( - typename named_vertices_type::ctor_args_list( - boost::make_tuple( - boost::make_tuple( - 0, // initial number of buckets - extract_name_from_vertex(derived(), extract), - boost::hash(), - std::equal_to())))), - vertex_constructor(vertex_constructor) -{ -} - -template -inline void BGL_NAMED_GRAPH::added_vertex(Vertex vertex) -{ - named_vertices.insert(vertex); -} - -template -template -inline void BGL_NAMED_GRAPH::removing_vertex(Vertex vertex, VertexIterStability) -{ - BOOST_STATIC_ASSERT_MSG ((boost::is_base_of::value), "Named graphs cannot use vecS as vertex container and remove vertices; the lack of vertex descriptor stability (which iterator stability is a proxy for) means that the name -> vertex mapping would need to be completely rebuilt after each deletion. See https://svn.boost.org/trac/boost/ticket/7863 for more information and a test case."); - typedef typename BGL_NAMED_GRAPH::vertex_name_type vertex_name_type; - const vertex_name_type& vertex_name = extract_name(derived()[vertex]); - named_vertices.erase(vertex_name); -} - -template -inline void BGL_NAMED_GRAPH::clearing_graph() -{ - named_vertices.clear(); -} - -template -typename BGL_NAMED_GRAPH::extract_name_type::result_type -BGL_NAMED_GRAPH::extract_name(const bundled_vertex_property_type& property) -{ - return named_vertices.key_extractor().extract(property); -} - -template -optional -BGL_NAMED_GRAPH:: -vertex_by_property(const bundled_vertex_property_type& property) -{ - return find_vertex(extract_name(property), *this); -} - -/// Retrieve the vertex associated with the given name -template -optional -find_vertex(typename BGL_NAMED_GRAPH::vertex_name_type const& name, - const BGL_NAMED_GRAPH& g) -{ - typedef typename BGL_NAMED_GRAPH::vertices_by_name_type - vertices_by_name_type; - - // Retrieve the set of vertices indexed by name - vertices_by_name_type const& vertices_by_name - = g.named_vertices.template get(); - - /// Look for a vertex with the given name - typename vertices_by_name_type::const_iterator iter - = vertices_by_name.find(name); - - if (iter == vertices_by_name.end()) - return optional(); // vertex not found - else - return *iter; -} - -/// Retrieve the vertex associated with the given name, or add a new -/// vertex with that name if no such vertex is available. -/// Note: This is enabled only when the vertex property type is different -/// from the vertex name to avoid ambiguous overload problems with -/// the add_vertex() function that takes a vertex property. -template - typename disable_if, -Vertex>::type -add_vertex(typename BGL_NAMED_GRAPH::vertex_name_type const& name, - BGL_NAMED_GRAPH& g) -{ - if (optional vertex = find_vertex(name, g)) - /// We found the vertex, so return it - return *vertex; - else - /// There is no vertex with the given name, so create one - return add_vertex(g.vertex_constructor(name), g.derived()); -} - -/// Add an edge using vertex names to refer to the vertices -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_name_type const& u_name, - typename BGL_NAMED_GRAPH::vertex_name_type const& v_name, - BGL_NAMED_GRAPH& g) -{ - return add_edge(add_vertex(u_name, g.derived()), - add_vertex(v_name, g.derived()), - g.derived()); -} - -/// Add an edge using vertex descriptors or names to refer to the vertices -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_descriptor const& u, - typename BGL_NAMED_GRAPH::vertex_name_type const& v_name, - BGL_NAMED_GRAPH& g) -{ - return add_edge(u, - add_vertex(v_name, g.derived()), - g.derived()); -} - -/// Add an edge using vertex descriptors or names to refer to the vertices -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_name_type const& u_name, - typename BGL_NAMED_GRAPH::vertex_descriptor const& v, - BGL_NAMED_GRAPH& g) -{ - return add_edge(add_vertex(u_name, g.derived()), - v, - g.derived()); -} - -// Overloads to support EdgeMutablePropertyGraph graphs -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_descriptor const& u, - typename BGL_NAMED_GRAPH::vertex_name_type const& v_name, - typename edge_property_type::type const& p, - BGL_NAMED_GRAPH& g) { - return add_edge(u, add_vertex(v_name, g.derived()), p, g.derived()); -} - -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_name_type const& u_name, - typename BGL_NAMED_GRAPH::vertex_descriptor const& v, - typename edge_property_type::type const& p, - BGL_NAMED_GRAPH& g) { - return add_edge(add_vertex(u_name, g.derived()), v, p, g.derived()); -} - -template -std::pair::edge_descriptor, bool> -add_edge(typename BGL_NAMED_GRAPH::vertex_name_type const& u_name, - typename BGL_NAMED_GRAPH::vertex_name_type const& v_name, - typename edge_property_type::type const& p, - BGL_NAMED_GRAPH& g) { - return add_edge(add_vertex(u_name, g.derived()), - add_vertex(v_name, g.derived()), p, g.derived()); -} - -#undef BGL_NAMED_GRAPH -#undef BGL_NAMED_GRAPH_PARAMS - -/******************************************************************* - * Maybe named graph mixin * - *******************************************************************/ - -#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION -/** - * A graph mixin that can provide a mapping from names to vertices, - * and use that mapping to simplify creation and manipulation of - * graphs. - */ -template::type> -struct maybe_named_graph : public named_graph -{ -}; - -/** - * A graph mixin that can provide a mapping from names to vertices, - * and use that mapping to simplify creation and manipulation of - * graphs. This partial specialization turns off this functionality - * when the @c VertexProperty does not have an internal vertex name. - */ -template -struct maybe_named_graph -{ - /// The type of the "bundled" property, from which the name can be - /// extracted. - typedef typename lookup_one_property::type - bundled_vertex_property_type; - - /// Notify the named_graph that we have added the given vertex. This - /// is a no-op. - void added_vertex(Vertex) { } - - /// Notify the named_graph that we are removing the given - /// vertex. This is a no-op. - template - void removing_vertex(Vertex, VertexIterStability) { } - - /// Notify the named_graph that we are clearing the graph. This is a - /// no-op. - void clearing_graph() { } - - /// Search for a vertex that has the given property (based on its - /// name). This always returns an empty optional<> - optional - vertex_by_property(const bundled_vertex_property_type&) - { - return optional(); - } -}; -#else -template::type> -struct maybe_named_graph -{ - /// The type of the "bundled" property, from which the name can be - /// extracted. - typedef typename detail::extract_bundled_vertex::type - bundled_vertex_property_type; - - /// Notify the named_graph that we have added the given vertex. This - /// is a no-op. - void added_vertex(Vertex) { } - - /// Notify the named_graph that we are removing the given - /// vertex. This is a no-op. - template - void removing_vertex(Vertex, VertexIterStability) { } - - /// Notify the named_graph that we are clearing the graph. This is a - /// no-op. - void clearing_graph() { } - - /// Search for a vertex that has the given property (based on its - /// name). This always returns an empty optional<> - template - optional - vertex_by_property(const bundled_vertex_property_type&) - { - return optional(); - } -}; -#endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - -} } // end namespace boost::graph - -#endif // BOOST_GRAPH_NAMED_GRAPH_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/numeric_values.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/numeric_values.hpp deleted file mode 100644 index ad018372..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/numeric_values.hpp +++ /dev/null @@ -1,52 +0,0 @@ -// (C) Copyright 2007-2009 Andrew Sutton -// -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0 (See accompanying file -// LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_GRAPH_NUMERIC_VALUES_HPP -#define BOOST_GRAPH_NUMERIC_VALUES_HPP - -#include - -namespace boost -{ - -#define BOOST_GRAPH_SPECIALIZE_NUMERIC_FLOAT(type) \ - template <> struct numeric_values { \ - typedef type value_type; \ - static type zero() { return 0.0; } \ - static type infinity() { return std::numeric_limits::infinity(); } \ - }; - - /** - * This generic type reports various numeric values for some type. In the - * general case, numeric values simply treat their maximum value as infinity - * and the default-constructed value as 0. - * - * Specializations of this template can redefine the notions of zero and - * infinity for various types. For example, the class is specialized for - * floating point types to use the built in notion of infinity. - */ - template - struct numeric_values - { - typedef T value_type; - - static T zero() - { return T(); } - - static T infinity() - { return (std::numeric_limits::max)(); } - }; - - // Specializations for floating point types refer to 0.0 and their infinity - // value defined by numeric_limits. - BOOST_GRAPH_SPECIALIZE_NUMERIC_FLOAT(float) - BOOST_GRAPH_SPECIALIZE_NUMERIC_FLOAT(double) - BOOST_GRAPH_SPECIALIZE_NUMERIC_FLOAT(long double) - -#undef BOOST_GRAPH_SPECIALIZE_NUMERIC_VALUE -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/overloading.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/overloading.hpp deleted file mode 100644 index a952e22f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/overloading.hpp +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright 2004 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -// -// This file contains helps that enable concept-based overloading -// within the Boost Graph Library. -// -#ifndef BOOST_GRAPH_OVERLOADING_HPP -#define BOOST_GRAPH_OVERLOADING_HPP - -#include -#include - -namespace boost { namespace graph { namespace detail { - -struct no_parameter {}; - -} } } // end namespace boost::graph::detail - -#ifndef BOOST_NO_SFINAE - -#define BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, Type) \ - typename enable_if_c<(is_base_and_derived< \ - Tag, \ - typename graph_traits::traversal_category>::value), \ - Type>::type - -#define BOOST_GRAPH_ENABLE_IF_MODELS_PARM(Graph, Tag) \ - , BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, \ - ::boost::graph::detail::no_parameter) \ - = ::boost::graph::detail::no_parameter() - -#else - -#define BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, Type) Type -#define BOOST_GRAPH_ENABLE_IF_MODELS_PARM(Graph, Tag) - -#endif // no SFINAE support - -#endif // BOOST_GRAPH_OVERLOADING_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/algorithm.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/algorithm.hpp deleted file mode 100644 index eed9bf87..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/algorithm.hpp +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright 2004 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#ifndef BOOST_PARALLEL_ALGORITHM_HPP -#define BOOST_PARALLEL_ALGORITHM_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include // for BOOST_STATIC_CONSTANT -#include -#include - -namespace boost { namespace parallel { - template - struct is_commutative - { - BOOST_STATIC_CONSTANT(bool, value = false); - }; - - template - struct minimum : std::binary_function - { - const T& operator()(const T& x, const T& y) const { return x < y? x : y; } - }; - - template - struct maximum : std::binary_function - { - const T& operator()(const T& x, const T& y) const { return x < y? y : x; } - }; - - template - struct sum : std::binary_function - { - const T operator()(const T& x, const T& y) const { return x + y; } - }; - - template - OutputIterator - reduce(ProcessGroup pg, typename ProcessGroup::process_id_type root, - InputIterator first, InputIterator last, OutputIterator out, - BinaryOperation bin_op); - - template - inline T - all_reduce(ProcessGroup pg, const T& value, BinaryOperation bin_op) - { - T result; - all_reduce(pg, - const_cast(&value), const_cast(&value+1), - &result, bin_op); - return result; - } - - template - inline T - scan(ProcessGroup pg, const T& value, BinaryOperation bin_op) - { - T result; - scan(pg, - const_cast(&value), const_cast(&value+1), - &result, bin_op); - return result; - } - - - template - void - all_gather(ProcessGroup pg, InputIterator first, InputIterator last, - std::vector& out); -} } // end namespace boost::parallel - -#include - -#endif // BOOST_PARALLEL_ALGORITHM_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/basic_reduce.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/basic_reduce.hpp deleted file mode 100644 index ee23b3a9..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/basic_reduce.hpp +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright 2005 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -#ifndef BOOST_PARALLEL_BASIC_REDUCE_HPP -#define BOOST_PARALLEL_BASIC_REDUCE_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -namespace boost { namespace parallel { - -/** Reduction operation used to reconcile differences between local - * and remote values for a particular key in a property map. The - * type @c T is typically the @c value_type of the property - * map. This basic reduction returns a default-constructed @c T as - * the default value and always resolves to the remote value. - */ -template -struct basic_reduce -{ - BOOST_STATIC_CONSTANT(bool, non_default_resolver = false); - - /// Returns a default-constructed T object - template - T operator()(const Key&) const { return T(); } - - /// Returns the remote value - template - const T& operator()(const Key&, const T&, const T& remote) const - { return remote; } -}; - -} } // end namespace boost::parallel - -#endif // BOOST_PARALLEL_BASIC_REDUCE_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/container_traits.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/container_traits.hpp deleted file mode 100644 index f4dd0e9f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/container_traits.hpp +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright (C) 2004-2006 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -// -// This file contains traits that describe -// -#ifndef BOOST_GRAPH_PARALLEL_CONTAINER_TRAITS_HPP -#define BOOST_GRAPH_PARALLEL_CONTAINER_TRAITS_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -namespace boost { namespace graph { namespace parallel { - -template -struct process_group_type -{ - typedef typename T::process_group_type type; -}; - -template -inline typename process_group_type::type -process_group(const T& x) -{ return x.process_group(); } - -// Helper function that algorithms should use to get the process group -// out of a container. -template -inline typename process_group_type::type -process_group_adl(const Container& container) -{ - return process_group(container); -} - - -} } } // end namespace boost::graph::parallel - -#endif // BOOST_GRAPH_PARALLEL_CONTAINER_TRAITS_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/inplace_all_to_all.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/inplace_all_to_all.hpp deleted file mode 100644 index a403ad77..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/inplace_all_to_all.hpp +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright 2005 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -#ifndef BOOST_GRAPH_PARALLEL_INPLACE_ALL_TO_ALL_HPP -#define BOOST_GRAPH_PARALLEL_INPLACE_ALL_TO_ALL_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -// -// Implements the inplace all-to-all communication algorithm. -// -#include -#include - -namespace boost { namespace parallel { - -template -// where {LinearProcessGroup, MessagingProcessGroup} -void -inplace_all_to_all(ProcessGroup pg, - const std::vector >& outgoing, - std::vector >& incoming) -{ - typedef typename std::vector::size_type size_type; - - typedef typename ProcessGroup::process_size_type process_size_type; - typedef typename ProcessGroup::process_id_type process_id_type; - - process_size_type p = num_processes(pg); - - // Make sure there are no straggling messages - synchronize(pg); - - // Send along the count (always) and the data (if count > 0) - for (process_id_type dest = 0; dest < p; ++dest) { - if (dest != process_id(pg)) { - send(pg, dest, 0, outgoing[dest].size()); - if (!outgoing[dest].empty()) - send(pg, dest, 1, &outgoing[dest].front(), outgoing[dest].size()); - } - } - - // Make sure all of the data gets transferred - synchronize(pg); - - // Receive the sizes and data - for (process_id_type source = 0; source < p; ++source) { - if (source != process_id(pg)) { - size_type size; - receive(pg, source, 0, size); - incoming[source].resize(size); - if (size > 0) - receive(pg, source, 1, &incoming[source].front(), size); - } else if (&incoming != &outgoing) { - incoming[source] = outgoing[source]; - } - } -} - -template -// where {LinearProcessGroup, MessagingProcessGroup} -void -inplace_all_to_all(ProcessGroup pg, std::vector >& data) -{ - inplace_all_to_all(pg, data, data); -} - -} } // end namespace boost::parallel - -#endif // BOOST_GRAPH_PARALLEL_INPLACE_ALL_TO_ALL_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/untracked_pair.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/untracked_pair.hpp deleted file mode 100644 index 3554910f..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/detail/untracked_pair.hpp +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright (C) 2007 Matthias Troyer -// -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// -// This file contains helper data structures for use in transmitting -// properties. The basic idea is to optimize away any storage for the -// properties when no properties are specified. -#ifndef BOOST_PARALLEL_DETAIL_UNTRACKED_PAIR_HPP -#define BOOST_PARALLEL_DETAIL_UNTRACKED_PAIR_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include // for std::pair -#include - -namespace boost { namespace parallel { namespace detail { - -/** - * This structure is like std::pair, with the only difference - * that tracking in the serialization library is turned off. - */ - -template -struct untracked_pair : public std::pair -{ - untracked_pair() {} - - untracked_pair(const T& t, const U& u) - : std::pair(t,u) {} - - template - untracked_pair(std::pair const& p) - : std::pair(p) {} -}; - -template -inline untracked_pair -make_untracked_pair(const T& t, const U& u) -{ - return untracked_pair(t,u); -} - -} } } // end namespace boost::parallel::detail - -namespace boost { namespace mpi { - -template -struct is_mpi_datatype > - : is_mpi_datatype > {}; - -} } // end namespace boost::mpi - -namespace boost { namespace serialization { - -// pair -template -inline void serialize( - Archive & ar, - boost::parallel::detail::untracked_pair & p, - const unsigned int /* file_version */ -){ - ar & boost::serialization::make_nvp("first", p.first); - ar & boost::serialization::make_nvp("second", p.second); -} - -template -struct is_bitwise_serializable< - boost::parallel::detail::untracked_pair > - : is_bitwise_serializable > {}; - -template -struct implementation_level > - : mpl::int_ {} ; - -template -struct tracking_level > - : mpl::int_ {} ; - -} } // end namespace boost::serialization - -#endif // BOOST_PARALLEL_DETAIL_UNTRACKED_PAIR_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/process_group.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/process_group.hpp deleted file mode 100644 index 280ee4db..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/process_group.hpp +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2004 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine -#ifndef BOOST_GRAPH_PARALLEL_PROCESS_GROUP_HPP -#define BOOST_GRAPH_PARALLEL_PROCESS_GROUP_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include - -namespace boost { namespace graph { namespace parallel { - -/** - * A special type used as a flag to a process group constructor that - * indicates that the copy of a process group will represent a new - * distributed data structure. - */ -struct attach_distributed_object { }; - -/** - * Describes the context in which a trigger is being invoked to - * receive a message. - */ -enum trigger_receive_context { - /// No trigger is active at this time. - trc_none, - /// The trigger is being invoked during synchronization, at the end - /// of a superstep. - trc_in_synchronization, - /// The trigger is being invoked as an "early" receive of a message - /// that was sent through the normal "send" operations to be - /// received by the end of the superstep, but the process group sent - /// the message earlier to clear its buffers. - trc_early_receive, - /// The trigger is being invoked for an out-of-band message, which - /// must be handled immediately. - trc_out_of_band, - /// The trigger is being invoked for an out-of-band message, which - /// must be handled immediately and has alredy been received by - /// an MPI_IRecv call. - trc_irecv_out_of_band -}; - -// Process group tags -struct process_group_tag {}; -struct linear_process_group_tag : virtual process_group_tag {}; -struct messaging_process_group_tag : virtual process_group_tag {}; -struct immediate_process_group_tag : virtual messaging_process_group_tag {}; -struct bsp_process_group_tag : virtual messaging_process_group_tag {}; -struct batch_process_group_tag : virtual messaging_process_group_tag {}; -struct locking_process_group_tag : virtual process_group_tag {}; -struct spawning_process_group_tag : virtual process_group_tag {}; - -struct process_group_archetype -{ - typedef int process_id_type; -}; - -void wait(process_group_archetype&); -void synchronize(process_group_archetype&); -int process_id(const process_group_archetype&); -int num_processes(const process_group_archetype&); - -template void send(process_group_archetype&, int, int, const T&); - -template -process_group_archetype::process_id_type -receive(const process_group_archetype& pg, - process_group_archetype::process_id_type source, int tag, T& value); - -template -std::pair -receive(const process_group_archetype& pg, int tag, T values[], std::size_t n); - -template -std::pair -receive(const process_group_archetype& pg, - process_group_archetype::process_id_type source, int tag, T values[], - std::size_t n); - -} } } // end namespace boost::graph::parallel - -namespace boost { namespace graph { namespace distributed { - using parallel::trigger_receive_context; - using parallel::trc_early_receive; - using parallel::trc_out_of_band; - using parallel::trc_irecv_out_of_band; - using parallel::trc_in_synchronization; - using parallel::trc_none; - using parallel::attach_distributed_object; -} } } // end namespace boost::graph::distributed - -#endif // BOOST_GRAPH_PARALLEL_PROCESS_GROUP_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/properties.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/properties.hpp deleted file mode 100644 index c6bb0bb0..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/properties.hpp +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright 2004 The Trustees of Indiana University. - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Douglas Gregor -// Andrew Lumsdaine - -#ifndef BOOST_GRAPH_PARALLEL_PROPERTIES_HPP -#define BOOST_GRAPH_PARALLEL_PROPERTIES_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include -#include - -namespace boost { - /*************************************************************************** - * Property map reduction operations - ***************************************************************************/ - /** - * Metafunction that produces a reduction operation for the given - * property. The default behavior merely forwards to @ref - * basic_reduce, but it is expected that this class template will be - * specified for important properties. - */ - template - struct property_reduce - { - template - class apply : public parallel::basic_reduce {}; - }; - - /** - * Reduction of vertex colors can only darken, not lighten, the - * color. Black cannot turn black, grey can only turn black, and - * white can be changed to either color. The default color is white. - */ - template<> - struct property_reduce - { - template - class apply - { - typedef color_traits traits; - - public: - BOOST_STATIC_CONSTANT(bool, non_default_resolver = true); - - template - Color operator()(const Key&) const { return traits::white(); } - - template - Color operator()(const Key&, Color local, Color remote) const { - if (local == traits::white()) return remote; - else if (remote == traits::black()) return remote; - else return local; - } - }; - }; - - /** - * Reduction of a distance always takes the shorter distance. The - * default distance value is the maximum value for the data type. - */ - template<> - struct property_reduce - { - template - class apply - { - public: - BOOST_STATIC_CONSTANT(bool, non_default_resolver = true); - - template - T operator()(const Key&) const { return (std::numeric_limits::max)(); } - - template - T operator()(const Key&, T x, T y) const { return x < y? x : y; } - }; - }; - - template<> - struct property_reduce - { - template - class apply - { - public: - BOOST_STATIC_CONSTANT(bool, non_default_resolver = true); - - T operator()(T key) const { return key; } - T operator()(T key, T, T y) const { return y; } - }; - }; - - template - inline void set_property_map_role(Property p, PropertyMap pm) - { - typedef typename property_traits::value_type value_type; - typedef property_reduce property_red; - typedef typename property_red::template apply reduce; - - pm.set_reduce(reduce()); - } - -} // end namespace boost -#endif // BOOST_GRAPH_PARALLEL_PROPERTIES_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/simple_trigger.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/simple_trigger.hpp deleted file mode 100644 index b1639bf2..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/parallel/simple_trigger.hpp +++ /dev/null @@ -1,108 +0,0 @@ -// Copyright (C) 2007 Douglas Gregor - -// Use, modification and distribution is subject to the Boost Software -// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// This file contains a simplification of the "trigger" method for -// process groups. The simple trigger handles the common case where -// the handler associated with a trigger is a member function bound to -// a particular pointer. - -#ifndef BOOST_GRAPH_PARALLEL_SIMPLE_TRIGGER_HPP -#define BOOST_GRAPH_PARALLEL_SIMPLE_TRIGGER_HPP - -#ifndef BOOST_GRAPH_USE_MPI -#error "Parallel BGL files should not be included unless has been included" -#endif - -#include - -namespace boost { namespace graph { namespace parallel { - -namespace detail { - -/** - * INTERNAL ONLY - * - * The actual function object that bridges from the normal trigger - * interface to the simplified interface. This is the equivalent of - * bind(pmf, self, _1, _2, _3, _4), but without the compile-time - * overhead of bind. - */ -template -class simple_trigger_t -{ -public: - simple_trigger_t(Class* self, - Result (Class::*pmf)(int, int, const T&, - trigger_receive_context)) - : self(self), pmf(pmf) { } - - Result - operator()(int source, int tag, const T& data, - trigger_receive_context context) const - { - return (self->*pmf)(source, tag, data, context); - } - -private: - Class* self; - Result (Class::*pmf)(int, int, const T&, trigger_receive_context); -}; - -} // end namespace detail - -/** - * Simplified trigger interface that reduces the amount of code - * required to connect a process group trigger to a handler that is - * just a bound member function. - * - * INTERNAL ONLY - */ -template -inline void -simple_trigger(ProcessGroup& pg, int tag, Class* self, - void (Class::*pmf)(int source, int tag, const T& data, - trigger_receive_context context), int) -{ - pg.template trigger(tag, - detail::simple_trigger_t(self, pmf)); -} - -/** - * Simplified trigger interface that reduces the amount of code - * required to connect a process group trigger with a reply to a - * handler that is just a bound member function. - * - * INTERNAL ONLY - */ -template -inline void -simple_trigger(ProcessGroup& pg, int tag, Class* self, - Result (Class::*pmf)(int source, int tag, const T& data, - trigger_receive_context context), long) -{ - pg.template trigger_with_reply - (tag, detail::simple_trigger_t(self, pmf)); -} - -/** - * Simplified trigger interface that reduces the amount of code - * required to connect a process group trigger to a handler that is - * just a bound member function. - */ -template -inline void -simple_trigger(ProcessGroup& pg, int tag, Class* self, - Result (Class::*pmf)(int source, int tag, const T& data, - trigger_receive_context context)) -{ - // We pass 0 (an int) to help VC++ disambiguate calls to simple_trigger - // with Result=void. - simple_trigger(pg, tag, self, pmf, 0); -} - -} } } // end namespace boost::graph::parallel - -#endif // BOOST_GRAPH_PARALLEL_SIMPLE_TRIGGER_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/properties.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/properties.hpp deleted file mode 100644 index d540439e..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/properties.hpp +++ /dev/null @@ -1,382 +0,0 @@ -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= - -#ifndef BOOST_GRAPH_PROPERTIES_HPP -#define BOOST_GRAPH_PROPERTIES_HPP - -#include -#include -#include -#include - -// Include the property map library and extensions in the BGL. -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -// Stay out of the way of the concept checking class -# define Graph Graph_ -# define RandomAccessContainer RandomAccessContainer_ -#endif - -namespace boost { - - enum default_color_type { white_color, gray_color, green_color, red_color, black_color }; - - template - struct color_traits { - static default_color_type white() { return white_color; } - static default_color_type gray() { return gray_color; } - static default_color_type green() { return green_color; } - static default_color_type red() { return red_color; } - static default_color_type black() { return black_color; } - }; - - // These functions are now obsolete, replaced by color_traits. - inline default_color_type white(default_color_type) { return white_color; } - inline default_color_type gray(default_color_type) { return gray_color; } - inline default_color_type green(default_color_type) { return green_color; } - inline default_color_type red(default_color_type) { return red_color; } - inline default_color_type black(default_color_type) { return black_color; } - -#ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION - template <> - struct property_traits { - typedef default_color_type value_type; - typedef std::ptrdiff_t key_type; - typedef default_color_type& reference; - typedef lvalue_property_map_tag category; - }; - // get/put already defined for T* -#endif - - struct graph_property_tag { }; - struct vertex_property_tag { }; - struct edge_property_tag { }; - - // See examples/edge_property.cpp for how to use this. -#define BOOST_INSTALL_PROPERTY(KIND, NAME) \ - template <> struct property_kind { \ - typedef KIND##_property_tag type; \ - } - -#define BOOST_DEF_PROPERTY(KIND, NAME) \ - enum KIND##_##NAME##_t { KIND##_##NAME }; \ - BOOST_INSTALL_PROPERTY(KIND, NAME) - - // These three are defined in boost/pending/property.hpp - BOOST_INSTALL_PROPERTY(vertex, all); - BOOST_INSTALL_PROPERTY(edge, all); - BOOST_INSTALL_PROPERTY(graph, all); - BOOST_DEF_PROPERTY(vertex, index); - BOOST_DEF_PROPERTY(vertex, index1); - BOOST_DEF_PROPERTY(vertex, index2); - BOOST_DEF_PROPERTY(vertex, root); - BOOST_DEF_PROPERTY(edge, index); - BOOST_DEF_PROPERTY(edge, name); - BOOST_DEF_PROPERTY(edge, weight); - BOOST_DEF_PROPERTY(edge, weight2); - BOOST_DEF_PROPERTY(edge, color); - BOOST_DEF_PROPERTY(vertex, name); - BOOST_DEF_PROPERTY(graph, name); - BOOST_DEF_PROPERTY(vertex, distance); - BOOST_DEF_PROPERTY(vertex, distance2); - BOOST_DEF_PROPERTY(vertex, color); - BOOST_DEF_PROPERTY(vertex, degree); - BOOST_DEF_PROPERTY(vertex, in_degree); - BOOST_DEF_PROPERTY(vertex, out_degree); - BOOST_DEF_PROPERTY(vertex, current_degree); - BOOST_DEF_PROPERTY(vertex, priority); - BOOST_DEF_PROPERTY(vertex, discover_time); - BOOST_DEF_PROPERTY(vertex, finish_time); - BOOST_DEF_PROPERTY(vertex, predecessor); - BOOST_DEF_PROPERTY(vertex, rank); - BOOST_DEF_PROPERTY(vertex, centrality); - BOOST_DEF_PROPERTY(vertex, lowpoint); - BOOST_DEF_PROPERTY(vertex, potential); - BOOST_DEF_PROPERTY(vertex, update); - BOOST_DEF_PROPERTY(vertex, underlying); - BOOST_DEF_PROPERTY(edge, reverse); - BOOST_DEF_PROPERTY(edge, capacity); - BOOST_DEF_PROPERTY(edge, flow); - BOOST_DEF_PROPERTY(edge, residual_capacity); - BOOST_DEF_PROPERTY(edge, centrality); - BOOST_DEF_PROPERTY(edge, discover_time); - BOOST_DEF_PROPERTY(edge, update); - BOOST_DEF_PROPERTY(edge, finished); - BOOST_DEF_PROPERTY(edge, underlying); - BOOST_DEF_PROPERTY(graph, visitor); - - // These tags are used for property bundles - // These three are defined in boost/pending/property.hpp - BOOST_INSTALL_PROPERTY(graph, bundle); - BOOST_INSTALL_PROPERTY(vertex, bundle); - BOOST_INSTALL_PROPERTY(edge, bundle); - - // These tags are used to denote the owners and local descriptors - // for the vertices and edges of a distributed graph. - BOOST_DEF_PROPERTY(vertex, global); - BOOST_DEF_PROPERTY(vertex, owner); - BOOST_DEF_PROPERTY(vertex, local); - BOOST_DEF_PROPERTY(edge, global); - BOOST_DEF_PROPERTY(edge, owner); - BOOST_DEF_PROPERTY(edge, local); - BOOST_DEF_PROPERTY(vertex, local_index); - BOOST_DEF_PROPERTY(edge, local_index); - -#undef BOOST_DEF_PROPERTY - - namespace detail { - - template - struct property_kind_from_graph: property_kind {}; - -#ifndef BOOST_GRAPH_NO_BUNDLED_PROPERTIES - template - struct property_kind_from_graph { - typedef typename boost::mpl::if_< - boost::is_base_of::type>, - vertex_property_tag, - typename boost::mpl::if_< - boost::is_base_of::type>, - edge_property_tag, - typename boost::mpl::if_< - boost::is_base_of::type>, - graph_property_tag, - void>::type>::type>::type type; - }; -#endif - - struct dummy_edge_property_selector { - template - struct bind_ { - typedef identity_property_map type; - typedef identity_property_map const_type; - }; - }; - struct dummy_vertex_property_selector { - template - struct bind_ { - typedef identity_property_map type; - typedef identity_property_map const_type; - }; - }; - - } // namespace detail - - // Graph classes can either partially specialize property_map - // or they can specialize these two selector classes. - template - struct edge_property_selector { - typedef detail::dummy_edge_property_selector type; - }; - - template - struct vertex_property_selector { - typedef detail::dummy_vertex_property_selector type; - }; - - namespace detail { - - template struct return_void {typedef void type;}; - - template - struct graph_tag_or_void { - typedef void type; - }; - - template - struct graph_tag_or_void::type> { - typedef typename Graph::graph_tag type; - }; - - template - struct edge_property_map - : edge_property_selector< - typename graph_tag_or_void::type - >::type::template bind_< - Graph, - typename edge_property_type::type, - PropertyTag> - {}; - template - struct vertex_property_map - : vertex_property_selector< - typename graph_tag_or_void::type - >::type::template bind_< - Graph, - typename vertex_property_type::type, - PropertyTag> - {}; - } // namespace detail - - template - struct property_map: - mpl::if_< - is_same::type, edge_property_tag>, - detail::edge_property_map, - detail::vertex_property_map >::type - {}; - - // shortcut for accessing the value type of the property map - template - class property_map_value { - typedef typename property_map::const_type PMap; - public: - typedef typename property_traits::value_type type; - }; - - template - class graph_property { - public: - typedef typename property_value< - typename boost::graph_property_type::type, Property - >::type type; - }; - - template struct vertex_property: vertex_property_type {}; - template struct edge_property: edge_property_type {}; - - template - class degree_property_map - : public put_get_helper::degree_size_type, - degree_property_map > - { - public: - typedef typename graph_traits::vertex_descriptor key_type; - typedef typename graph_traits::degree_size_type value_type; - typedef value_type reference; - typedef readable_property_map_tag category; - degree_property_map(const Graph& g) : m_g(g) { } - value_type operator[](const key_type& v) const { - return degree(v, m_g); - } - private: - const Graph& m_g; - }; - template - inline degree_property_map - make_degree_map(const Graph& g) { - return degree_property_map(g); - } - - //======================================================================== - // Iterator Property Map Generating Functions contributed by - // Kevin Vanhorn. (see also the property map generating functions - // in boost/property_map/property_map.hpp) - -#if !defined(BOOST_NO_STD_ITERATOR_TRAITS) - // A helper function for creating a vertex property map out of a - // random access iterator and the internal vertex index map from a - // graph. - template - inline - iterator_property_map< - RandomAccessIterator, - typename property_map::type, - typename std::iterator_traits::value_type, - typename std::iterator_traits::reference - > - make_iterator_vertex_map(RandomAccessIterator iter, const PropertyGraph& g) - { - return make_iterator_property_map(iter, get(vertex_index, g)); - } - - // Use this next function when vertex_descriptor is known to be an - // integer type, with values ranging from 0 to num_vertices(g). - // - template - inline - iterator_property_map< - RandomAccessIterator, - identity_property_map, - typename std::iterator_traits::value_type, - typename std::iterator_traits::reference - > - make_iterator_vertex_map(RandomAccessIterator iter) - { - return make_iterator_property_map(iter, identity_property_map()); - } -#endif - - template - inline - iterator_property_map< - typename RandomAccessContainer::iterator, - typename property_map::type, - typename RandomAccessContainer::value_type, - typename RandomAccessContainer::reference - > - make_container_vertex_map(RandomAccessContainer& c, const PropertyGraph& g) - { - BOOST_ASSERT(c.size() >= num_vertices(g)); - return make_iterator_vertex_map(c.begin(), g); - } - - template inline - iterator_property_map< - typename RandomAccessContainer::iterator, - identity_property_map, - typename RandomAccessContainer::value_type, - typename RandomAccessContainer::reference - > - make_container_vertex_map(RandomAccessContainer& c) - { - return make_iterator_vertex_map(c.begin()); - } - -#if defined (BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) -# define BOOST_GRAPH_NO_BUNDLED_PROPERTIES -#endif - -#if BOOST_WORKAROUND(__SUNPRO_CC, BOOST_TESTED_AT(0x590)) && !defined (BOOST_GRAPH_NO_BUNDLED_PROPERTIES) -// This compiler cannot define a partial specialization based on a -// pointer-to-member type, as seen in boost/graph/subgraph.hpp line 985 (as of -// trunk r53912) -# define BOOST_GRAPH_NO_BUNDLED_PROPERTIES -#endif - -// NOTE: These functions are declared, but never defined since they need to -// be overloaded by graph implementations. However, we need them to be -// declared for the functions below. -template -typename graph_property::type& -get_property(Graph& g, Tag); - -template -typename graph_property::type const& -get_property(Graph const& g, Tag); - -#ifndef BOOST_GRAPH_NO_BUNDLED_PROPERTIES -// NOTE: This operation is a simple adaptor over the overloaded get_property -// operations. -template -inline typename graph_property::type& -get_property(Graph& g) { - return get_property(g, graph_bundle); -} - -template -inline typename graph_property::type const& -get_property(const Graph& g) { - return get_property(g, graph_bundle); -} -#endif - -} // namespace boost - -#endif /* BOOST_GRAPH_PROPERTIES_HPP */ diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/constant_property_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/constant_property_map.hpp deleted file mode 100644 index 9d83ea18..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/constant_property_map.hpp +++ /dev/null @@ -1,92 +0,0 @@ -// (C) Copyright 2007-2009 Andrew Sutton -// -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0 (See accompanying file -// LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_GRAPH_CONSTANT_PROPERTY_HPP -#define BOOST_GRAPH_CONSTANT_PROPERTY_HPP - -#include - - -// TODO: This should really be part of the property maps library rather than -// the Boost.Graph library. - -namespace boost { - -/** - * A constant property is one, that regardless of the edge or vertex given, - * will always return a constant value. - */ -template -struct constant_property_map - : public boost::put_get_helper< - const Value&, - constant_property_map - > -{ - typedef Key key_type; - typedef Value value_type; - typedef const Value& reference; - typedef boost::readable_property_map_tag category; - - constant_property_map() - : m_value() - { } - - constant_property_map(const value_type &value) - : m_value(value) - { } - - constant_property_map(const constant_property_map& copy) - : m_value(copy.m_value) - { } - - inline reference operator [](const key_type&) const - { return m_value; } - - value_type m_value; -}; - -template -inline constant_property_map -make_constant_property(const Value& value) -{ return constant_property_map(value); } - -/** - * Same as above, but pretends to be writable as well. - */ -template -struct constant_writable_property_map { - typedef Key key_type; - typedef Value value_type; - typedef Value& reference; - typedef boost::read_write_property_map_tag category; - - constant_writable_property_map() - : m_value() - { } - - constant_writable_property_map(const value_type &value) - : m_value(value) - { } - - constant_writable_property_map(const constant_writable_property_map& copy) - : m_value(copy.m_value) - { } - - friend Value get(const constant_writable_property_map& me, Key) {return me.m_value;} - friend void put(const constant_writable_property_map&, Key, Value) {} - - value_type m_value; -}; - -template -inline constant_writable_property_map -make_constant_writable_property(const Value& value) -{ return constant_writable_property_map(value); } - -} /* namespace boost */ - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/null_property_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/null_property_map.hpp deleted file mode 100644 index 09ff55e3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/property_maps/null_property_map.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// (C) Copyright Andrew Sutton 2007 -// -// Use, modification and distribution are subject to the -// Boost Software License, Version 1.0 (See accompanying file -// LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) - -#ifndef BOOST_GRAPH_NULL_PROPERTY_HPP -#define BOOST_GRAPH_NULL_PROPERTY_HPP - -#include - -// TODO: This should really be part of the property maps library rather than -// the Boost.Graph library. - -namespace boost -{ - // A null property is somewhat like the inverse of the constant - // property map except that instead of returning a single value, - // this eats any writes and cannot be read from. - - template - struct null_property_map - { - typedef Key key_type; - typedef Value value_type; - typedef void reference; - typedef boost::writable_property_map_tag category; - }; - - // The null_property_map only has a put() function. - template - void put(null_property_map& /*pm*/, const K& /*key*/, const V& /*value*/) - { } - - // A helper function for intantiating null property maps. - template - inline null_property_map make_null_property() - { return null_property_map(); } -} - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/reverse_graph.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/reverse_graph.hpp deleted file mode 100644 index e9027e3c..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/reverse_graph.hpp +++ /dev/null @@ -1,525 +0,0 @@ -// (C) Copyright David Abrahams 2000. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef REVERSE_GRAPH_DWA092300_H_ -# define REVERSE_GRAPH_DWA092300_H_ - -#include -#include -#include -#include -#include -#include - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -// Stay out of the way of the concept checking class -# define BidirectionalGraph BidirectionalGraph_ -#endif - -namespace boost { - -struct reverse_graph_tag { }; - - namespace detail { - - template - class reverse_graph_edge_descriptor { - public: - EdgeDesc underlying_descx; // Odd name is because this needs to be public but shouldn't be exposed to users anymore - - private: - typedef EdgeDesc base_descriptor_type; - - public: - explicit reverse_graph_edge_descriptor(const EdgeDesc& underlying_descx = EdgeDesc()) - : underlying_descx(underlying_descx) {} - - friend bool operator==(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx == b.underlying_descx; - } - friend bool operator!=(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx != b.underlying_descx; - } - friend bool operator<(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx < b.underlying_descx; - } - friend bool operator>(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx > b.underlying_descx; - } - friend bool operator<=(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx <= b.underlying_descx; - } - friend bool operator>=(const reverse_graph_edge_descriptor& a, const reverse_graph_edge_descriptor& b) { - return a.underlying_descx >= b.underlying_descx; - } - }; - - template - struct reverse_graph_edge_descriptor_maker { - typedef reverse_graph_edge_descriptor result_type; - - reverse_graph_edge_descriptor operator()(const EdgeDesc& ed) const { - return reverse_graph_edge_descriptor(ed); - } - }; - - template - std::pair, Iter>, - transform_iterator, Iter> > - reverse_edge_iter_pair(const std::pair& ip) { - return std::make_pair(make_transform_iterator(ip.first, reverse_graph_edge_descriptor_maker()), - make_transform_iterator(ip.second, reverse_graph_edge_descriptor_maker())); - } - - // Get the underlying descriptor from a vertex or edge descriptor - template - struct get_underlying_descriptor_from_reverse_descriptor { - typedef Desc type; - static Desc convert(const Desc& d) {return d;} - }; - template - struct get_underlying_descriptor_from_reverse_descriptor > { - typedef Desc type; - static Desc convert(const reverse_graph_edge_descriptor& d) {return d.underlying_descx;} - }; - - template struct choose_rev_edge_iter { }; - template <> struct choose_rev_edge_iter { - template struct bind_ { - typedef transform_iterator::edge_descriptor>, typename graph_traits::edge_iterator> type; - }; - }; - template <> struct choose_rev_edge_iter { - template struct bind_ { - typedef void type; - }; - }; - - } // namespace detail - -template -class reverse_graph { - typedef reverse_graph Self; - typedef graph_traits Traits; - public: - typedef BidirectionalGraph base_type; - typedef GraphRef base_ref_type; - - // Constructor - reverse_graph(GraphRef g) : m_g(g) {} - // Conversion from reverse_graph on non-const reference to one on const reference - reverse_graph(const reverse_graph& o): m_g(o.m_g) {} - - // Graph requirements - typedef typename Traits::vertex_descriptor vertex_descriptor; - typedef detail::reverse_graph_edge_descriptor edge_descriptor; - typedef typename Traits::directed_category directed_category; - typedef typename Traits::edge_parallel_category edge_parallel_category; - typedef typename Traits::traversal_category traversal_category; - - // IncidenceGraph requirements - typedef transform_iterator, typename Traits::in_edge_iterator> out_edge_iterator; - typedef typename Traits::degree_size_type degree_size_type; - - // BidirectionalGraph requirements - typedef transform_iterator, typename Traits::out_edge_iterator> in_edge_iterator; - - // AdjacencyGraph requirements - typedef typename adjacency_iterator_generator::type adjacency_iterator; - - // VertexListGraph requirements - typedef typename Traits::vertex_iterator vertex_iterator; - - // EdgeListGraph requirements - enum { is_edge_list = is_convertible::value }; - typedef detail::choose_rev_edge_iter ChooseEdgeIter; - typedef typename ChooseEdgeIter:: - template bind_::type edge_iterator; - typedef typename Traits::vertices_size_type vertices_size_type; - typedef typename Traits::edges_size_type edges_size_type; - - typedef reverse_graph_tag graph_tag; - -#ifndef BOOST_GRAPH_NO_BUNDLED_PROPERTIES - // Bundled properties support - template - typename graph::detail::bundled_result< - BidirectionalGraph, - typename detail::get_underlying_descriptor_from_reverse_descriptor::type - >::type& - operator[](Descriptor x) - { return m_g[detail::get_underlying_descriptor_from_reverse_descriptor::convert(x)]; } - - template - typename graph::detail::bundled_result< - BidirectionalGraph, - typename detail::get_underlying_descriptor_from_reverse_descriptor::type - >::type const& - operator[](Descriptor x) const - { return m_g[detail::get_underlying_descriptor_from_reverse_descriptor::convert(x)]; } -#endif // BOOST_GRAPH_NO_BUNDLED_PROPERTIES - - static vertex_descriptor null_vertex() - { return Traits::null_vertex(); } - - // would be private, but template friends aren't portable enough. - // private: - GraphRef m_g; -}; - - -// These are separate so they are not instantiated unless used (see bug 1021) -template -struct vertex_property_type > { - typedef typename boost::vertex_property_type::type type; -}; - -template -struct edge_property_type > { - typedef typename boost::edge_property_type::type type; -}; - -template -struct graph_property_type > { - typedef typename boost::graph_property_type::type type; -}; - -#ifndef BOOST_GRAPH_NO_BUNDLED_PROPERTIES - template - struct vertex_bundle_type > - : vertex_bundle_type { }; - - template - struct edge_bundle_type > - : edge_bundle_type { }; - - template - struct graph_bundle_type > - : graph_bundle_type { }; -#endif // BOOST_GRAPH_NO_BUNDLED_PROPERTIES - -template -inline reverse_graph -make_reverse_graph(const BidirectionalGraph& g) -{ - return reverse_graph(g); -} - -template -inline reverse_graph -make_reverse_graph(BidirectionalGraph& g) -{ - return reverse_graph(g); -} - -template -std::pair::vertex_iterator, - typename reverse_graph::vertex_iterator> -vertices(const reverse_graph& g) -{ - return vertices(g.m_g); -} - -template -std::pair::edge_iterator, - typename reverse_graph::edge_iterator> -edges(const reverse_graph& g) -{ - return detail::reverse_edge_iter_pair::edge_descriptor>(edges(g.m_g)); -} - -template -inline std::pair::out_edge_iterator, - typename reverse_graph::out_edge_iterator> -out_edges(const typename graph_traits::vertex_descriptor u, - const reverse_graph& g) -{ - return detail::reverse_edge_iter_pair::edge_descriptor>(in_edges(u, g.m_g)); -} - -template -inline typename graph_traits::vertices_size_type -num_vertices(const reverse_graph& g) -{ - return num_vertices(g.m_g); -} - -template -inline typename reverse_graph::edges_size_type -num_edges(const reverse_graph& g) -{ - return num_edges(g.m_g); -} - -template -inline typename graph_traits::degree_size_type -out_degree(const typename graph_traits::vertex_descriptor u, - const reverse_graph& g) -{ - return in_degree(u, g.m_g); -} - -template -inline typename graph_traits::vertex_descriptor -vertex(const typename graph_traits::vertices_size_type v, - const reverse_graph& g) -{ - return vertex(v, g.m_g); -} - -template -inline std::pair< typename graph_traits >::edge_descriptor, - bool> -edge(const typename graph_traits::vertex_descriptor u, - const typename graph_traits::vertex_descriptor v, - const reverse_graph& g) -{ - typedef typename graph_traits::edge_descriptor underlying_edge_descriptor; - std::pair e = edge(v, u, g.m_g); - return std::make_pair(detail::reverse_graph_edge_descriptor(e.first), e.second); -} - -template -inline std::pair::in_edge_iterator, - typename reverse_graph::in_edge_iterator> -in_edges(const typename graph_traits::vertex_descriptor u, - const reverse_graph& g) -{ - return detail::reverse_edge_iter_pair::edge_descriptor>(out_edges(u, g.m_g)); -} - -template -inline std::pair::adjacency_iterator, - typename reverse_graph::adjacency_iterator> -adjacent_vertices(typename graph_traits::vertex_descriptor u, - const reverse_graph& g) -{ - typedef reverse_graph Graph; - typename graph_traits::out_edge_iterator first, last; - boost::tie(first, last) = out_edges(u, g); - typedef typename graph_traits::adjacency_iterator adjacency_iterator; - return std::make_pair(adjacency_iterator(first, const_cast(&g)), - adjacency_iterator(last, const_cast(&g))); -} - -template -inline typename graph_traits::degree_size_type -in_degree(const typename graph_traits::vertex_descriptor u, - const reverse_graph& g) -{ - return out_degree(u, g.m_g); -} - -template -inline typename graph_traits::vertex_descriptor -source(const detail::reverse_graph_edge_descriptor& e, const reverse_graph& g) -{ - return target(e.underlying_descx, g.m_g); -} - -template -inline typename graph_traits::vertex_descriptor -target(const detail::reverse_graph_edge_descriptor& e, const reverse_graph& g) -{ - return source(e.underlying_descx, g.m_g); -} - - -namespace detail { - - template - struct reverse_graph_edge_property_map { - private: - PM underlying_pm; - - public: - typedef reverse_graph_edge_descriptor::key_type> key_type; - typedef typename property_traits::value_type value_type; - typedef typename property_traits::reference reference; - typedef typename property_traits::category category; - - explicit reverse_graph_edge_property_map(const PM& pm): underlying_pm(pm) {} - - friend reference - get(const reverse_graph_edge_property_map& m, - const key_type& e) { - return get(m.underlying_pm, e.underlying_descx); - } - - friend void - put(const reverse_graph_edge_property_map& m, - const key_type& e, - const value_type& v) { - put(m.underlying_pm, e.underlying_descx, v); - } - - reference operator[](const key_type& k) const { - return (this->underlying_pm)[k.underlying_descx]; - } - }; - -} // namespace detail - -template -struct property_map, Property> { - typedef boost::is_same::type, edge_property_tag> is_edge_prop; - typedef boost::is_const::type> is_ref_const; - typedef typename boost::mpl::if_< - is_ref_const, - typename property_map::const_type, - typename property_map::type>::type - orig_type; - typedef typename property_map::const_type orig_const_type; - typedef typename boost::mpl::if_, orig_type>::type type; - typedef typename boost::mpl::if_, orig_const_type>::type const_type; -}; - -template -struct property_map, Property> { - typedef boost::is_same::type, edge_property_tag> is_edge_prop; - typedef typename property_map::const_type orig_const_type; - typedef typename boost::mpl::if_, orig_const_type>::type const_type; - typedef const_type type; -}; - -template -typename disable_if< - is_same, - typename property_map, Property>::type>::type -get(Property p, reverse_graph& g) -{ - return typename property_map, Property>::type(get(p, g.m_g)); -} - -template -typename disable_if< - is_same, - typename property_map, Property>::const_type>::type -get(Property p, const reverse_graph& g) -{ - const BidirGraph& gref = g.m_g; // in case GRef is non-const - return typename property_map, Property>::const_type(get(p, gref)); -} - -template -typename disable_if< - is_same, - typename property_traits< - typename property_map, Property>::const_type - >::value_type>::type -get(Property p, const reverse_graph& g, const Key& k) -{ - return get(get(p, g), k); -} - -template -void -put(Property p, reverse_graph& g, const Key& k, - const Value& val) -{ - put(get(p, g), k, val); -} - -// Get the underlying descriptor from a reverse_graph's wrapped edge descriptor - -namespace detail { - template - struct underlying_edge_desc_map_type { - E operator[](const reverse_graph_edge_descriptor& k) const { - return k.underlying_descx; - } - }; - - template - E - get(underlying_edge_desc_map_type m, - const reverse_graph_edge_descriptor& k) - { - return m[k]; - } -} - -template -struct property_traits > { - typedef detail::reverse_graph_edge_descriptor key_type; - typedef E value_type; - typedef const E& reference; - typedef readable_property_map_tag category; -}; - -template -struct property_map, edge_underlying_t> { - private: - typedef typename graph_traits::edge_descriptor ed; - - public: - typedef detail::underlying_edge_desc_map_type type; - typedef detail::underlying_edge_desc_map_type const_type; -}; - -template struct is_reverse_graph: boost::mpl::false_ {}; -template struct is_reverse_graph >: boost::mpl::true_ {}; - -template -typename enable_if, - detail::underlying_edge_desc_map_type::edge_descriptor> >::type -get(edge_underlying_t, - G&) -{ - return detail::underlying_edge_desc_map_type::edge_descriptor>(); -} - -template -typename enable_if, typename graph_traits::edge_descriptor>::type -get(edge_underlying_t, - G&, - const typename graph_traits::edge_descriptor& k) -{ - return k.underlying_descx; -} - -template -typename enable_if, detail::underlying_edge_desc_map_type::edge_descriptor> >::type -get(edge_underlying_t, - const G&) -{ - return detail::underlying_edge_desc_map_type::edge_descriptor>(); -} - -template -typename enable_if, typename graph_traits::edge_descriptor>::type -get(edge_underlying_t, - const G&, - const typename graph_traits::edge_descriptor& k) -{ - return k.underlying_descx; -} - -// Access to wrapped graph's graph properties - -template -inline void -set_property(const reverse_graph& g, Tag tag, - const Value& value) -{ - set_property(g.m_g, tag, value); -} - -template -inline -typename boost::mpl::if_< - boost::is_const::type>, - const typename graph_property::type&, - typename graph_property::type& >::type -get_property(const reverse_graph& g, Tag tag) -{ - return get_property(g.m_g, tag); -} - -} // namespace boost - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/two_bit_color_map.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/two_bit_color_map.hpp deleted file mode 100644 index 3d55eabc..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/two_bit_color_map.hpp +++ /dev/null @@ -1,109 +0,0 @@ -// Copyright (C) 2005-2006 The Trustees of Indiana University. - -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -// Authors: Jeremiah Willcock -// Douglas Gregor -// Andrew Lumsdaine - -// Two bit per color property map - -#ifndef BOOST_TWO_BIT_COLOR_MAP_HPP -#define BOOST_TWO_BIT_COLOR_MAP_HPP - -#include -#include -#include -#include -#include -#include -#include - -namespace boost { - -enum two_bit_color_type { - two_bit_white = 0, - two_bit_gray = 1, - two_bit_green = 2, - two_bit_black = 3 -}; - -template <> -struct color_traits -{ - static two_bit_color_type white() { return two_bit_white; } - static two_bit_color_type gray() { return two_bit_gray; } - static two_bit_color_type green() { return two_bit_green; } - static two_bit_color_type black() { return two_bit_black; } -}; - - -template -struct two_bit_color_map -{ - std::size_t n; - IndexMap index; - shared_array data; - - BOOST_STATIC_CONSTANT(int, bits_per_char = std::numeric_limits::digits); - BOOST_STATIC_CONSTANT(int, elements_per_char = bits_per_char / 2); - typedef typename property_traits::key_type key_type; - typedef two_bit_color_type value_type; - typedef void reference; - typedef read_write_property_map_tag category; - - explicit two_bit_color_map(std::size_t n, const IndexMap& index = IndexMap()) - : n(n), index(index), data(new unsigned char[(n + elements_per_char - 1) / elements_per_char]) - { - // Fill to white - std::fill(data.get(), data.get() + (n + elements_per_char - 1) / elements_per_char, 0); - } -}; - -template -inline two_bit_color_type -get(const two_bit_color_map& pm, - typename property_traits::key_type key) -{ - BOOST_STATIC_CONSTANT(int, elements_per_char = two_bit_color_map::elements_per_char); - typename property_traits::value_type i = get(pm.index, key); - BOOST_ASSERT ((std::size_t)i < pm.n); - std::size_t byte_num = i / elements_per_char; - std::size_t bit_position = ((i % elements_per_char) * 2); - return two_bit_color_type((pm.data.get()[byte_num] >> bit_position) & 3); -} - -template -inline void -put(const two_bit_color_map& pm, - typename property_traits::key_type key, - two_bit_color_type value) -{ - BOOST_STATIC_CONSTANT(int, elements_per_char = two_bit_color_map::elements_per_char); - typename property_traits::value_type i = get(pm.index, key); - BOOST_ASSERT ((std::size_t)i < pm.n); - BOOST_ASSERT (value >= 0 && value < 4); - std::size_t byte_num = i / elements_per_char; - std::size_t bit_position = ((i % elements_per_char) * 2); - pm.data.get()[byte_num] = - (unsigned char) - ((pm.data.get()[byte_num] & ~(3 << bit_position)) - | (value << bit_position)); -} - -template -inline two_bit_color_map -make_two_bit_color_map(std::size_t n, const IndexMap& index_map) -{ - return two_bit_color_map(n, index_map); -} - -} // end namespace boost - -#endif // BOOST_TWO_BIT_COLOR_MAP_HPP - -#ifdef BOOST_GRAPH_USE_MPI -# include -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/graph/visitors.hpp b/third_party/ycmd/cpp/BoostParts/boost/graph/visitors.hpp deleted file mode 100644 index e4a614f3..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/graph/visitors.hpp +++ /dev/null @@ -1,321 +0,0 @@ -//======================================================================= -// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. -// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek -// -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -//======================================================================= -// -// Revision History: -// 01 April 2001: Modified to use new header. (JMaddock) -// -#ifndef BOOST_GRAPH_GRAPH_SEARCH_VISITORS_HPP -#define BOOST_GRAPH_GRAPH_SEARCH_VISITORS_HPP - -#include -#include -#include -#include -#include -#include -#include - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -// Stay out of the way of the concept checking class -# define Graph Graph_ -#endif - -namespace boost { - - // This is a bit more convenient than std::numeric_limits because - // you don't have to explicitly provide type T. - template - inline T numeric_limits_max(T) { return (std::numeric_limits::max)(); } - - //======================================================================== - // Event Tags - - namespace detail { - // For partial specialization workaround - enum event_visitor_enum - { on_no_event_num, - on_initialize_vertex_num, on_start_vertex_num, - on_discover_vertex_num, on_finish_vertex_num, on_examine_vertex_num, - on_examine_edge_num, on_tree_edge_num, on_non_tree_edge_num, - on_gray_target_num, on_black_target_num, - on_forward_or_cross_edge_num, on_back_edge_num, on_finish_edge_num, - on_edge_relaxed_num, on_edge_not_relaxed_num, - on_edge_minimized_num, on_edge_not_minimized_num - }; - - template - struct functor_to_visitor : Visitor - { - typedef Event event_filter; - functor_to_visitor(const Visitor& visitor) : Visitor(visitor) {} - }; - - } // namespace detail - - struct on_no_event { enum { num = detail::on_no_event_num }; }; - - struct on_initialize_vertex { - enum { num = detail::on_initialize_vertex_num }; }; - struct on_start_vertex { enum { num = detail::on_start_vertex_num }; }; - struct on_discover_vertex { enum { num = detail::on_discover_vertex_num }; }; - struct on_examine_vertex { enum { num = detail::on_examine_vertex_num }; }; - struct on_finish_vertex { enum { num = detail::on_finish_vertex_num }; }; - - struct on_examine_edge { enum { num = detail::on_examine_edge_num }; }; - struct on_tree_edge { enum { num = detail::on_tree_edge_num }; }; - struct on_non_tree_edge { enum { num = detail::on_non_tree_edge_num }; }; - struct on_gray_target { enum { num = detail::on_gray_target_num }; }; - struct on_black_target { enum { num = detail::on_black_target_num }; }; - struct on_forward_or_cross_edge { - enum { num = detail::on_forward_or_cross_edge_num }; }; - struct on_back_edge { enum { num = detail::on_back_edge_num }; }; - struct on_finish_edge { enum { num = detail::on_finish_edge_num }; }; - - struct on_edge_relaxed { enum { num = detail::on_edge_relaxed_num }; }; - struct on_edge_not_relaxed { - enum { num = detail::on_edge_not_relaxed_num }; }; - struct on_edge_minimized { enum { num = detail::on_edge_minimized_num }; }; - struct on_edge_not_minimized { - enum { num = detail::on_edge_not_minimized_num }; }; - - //======================================================================== - // base_visitor and null_visitor - - // needed for MSVC workaround - template - struct base_visitor { - typedef on_no_event event_filter; - template - void operator()(T, Graph&) { } - }; - - struct null_visitor : public base_visitor { - typedef on_no_event event_filter; - template - void operator()(T, Graph&) { } - }; - - //======================================================================== - // The invoke_visitors() function - - namespace detail { - template - inline void invoke_dispatch(Visitor& v, T x, Graph& g, mpl::true_) { - v(x, g); - } - - template - inline void invoke_dispatch(Visitor&, T, Graph&, mpl::false_) - { } - } // namespace detail - - template - inline void - invoke_visitors(std::pair& vlist, T x, Graph& g, Tag tag) { - typedef typename Visitor::event_filter Category; - typedef typename is_same::type IsSameTag; - detail::invoke_dispatch(vlist.first, x, g, IsSameTag()); - invoke_visitors(vlist.second, x, g, tag); - } -#if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 - template - inline void - invoke_visitors(base_visitor& vis, T x, Graph& g, Tag) { - typedef typename Visitor::event_filter Category; - typedef typename is_same::type IsSameTag; - Visitor& v = static_cast(vis); - detail::invoke_dispatch(v, x, g, IsSameTag()); - } -#else - template - inline void - invoke_visitors(Visitor& v, T x, Graph& g, Tag) { - typedef typename Visitor::event_filter Category; - typedef typename is_same::type IsSameTag; - detail::invoke_dispatch(v, x, g, IsSameTag()); - } -#endif - - //======================================================================== - // predecessor_recorder - - template - struct predecessor_recorder - : public base_visitor > - { - typedef Tag event_filter; - predecessor_recorder(PredecessorMap pa) : m_predecessor(pa) { } - template - void operator()(Edge e, const Graph& g) { - put(m_predecessor, target(e, g), source(e, g)); - } - PredecessorMap m_predecessor; - }; - template - predecessor_recorder - record_predecessors(PredecessorMap pa, Tag) { - return predecessor_recorder (pa); - } - - //======================================================================== - // edge_predecessor_recorder - - template - struct edge_predecessor_recorder - : public base_visitor > - { - typedef Tag event_filter; - edge_predecessor_recorder(PredEdgeMap pa) : m_predecessor(pa) { } - template - void operator()(Edge e, const Graph& g) { - put(m_predecessor, target(e, g), e); - } - PredEdgeMap m_predecessor; - }; - template - edge_predecessor_recorder - record_edge_predecessors(PredEdgeMap pa, Tag) { - return edge_predecessor_recorder (pa); - } - - //======================================================================== - // distance_recorder - - template - struct distance_recorder - : public base_visitor > - { - typedef Tag event_filter; - distance_recorder(DistanceMap pa) : m_distance(pa) { } - template - void operator()(Edge e, const Graph& g) { - typename graph_traits::vertex_descriptor - u = source(e, g), v = target(e, g); - put(m_distance, v, get(m_distance, u) + 1); - } - DistanceMap m_distance; - }; - template - distance_recorder - record_distances(DistanceMap pa, Tag) { - return distance_recorder (pa); - } - - //======================================================================== - // time_stamper - - - template - struct time_stamper - : public base_visitor > - { - typedef Tag event_filter; - time_stamper(TimeMap pa, TimeT& t) : m_time_pa(pa), m_time(t) { } - template - void operator()(Vertex u, const Graph&) { - put(m_time_pa, u, ++m_time); - } - TimeMap m_time_pa; - TimeT& m_time; - }; - template - time_stamper - stamp_times(TimeMap pa, TimeT& time_counter, Tag) { - return time_stamper(pa, time_counter); - } - - //======================================================================== - // property_writer - - template - struct property_writer - : public base_visitor > - { - typedef Tag event_filter; - - property_writer(PA pa, OutputIterator out) : m_pa(pa), m_out(out) { } - - template - void operator()(T x, Graph&) { *m_out++ = get(m_pa, x); } - PA m_pa; - OutputIterator m_out; - }; - template - property_writer - write_property(PA pa, OutputIterator out, Tag) { - return property_writer(pa, out); - } - - //======================================================================== - // property_put - - /** - * Functor which just sets a given value to a vertex or edge in a property map. - */ - - template - struct property_put - { - typedef EventTag event_filter; - - property_put (PropertyMap property_map, - typename property_traits ::value_type value) : - property_map_ (property_map), value_ (value) - {} - - template - void operator() (VertexOrEdge v, const Graph&) - { - put (property_map_, v, value_); - } - - private: - PropertyMap property_map_; - typename property_traits ::value_type value_; - }; - - /** - * Creates a property_put functor which just sets a given value to a vertex or edge. - * - * @param property_map Given writeable property map - * @param value Fixed value of the map - * @param tag Event Filter - * @return The functor. - */ - - template - inline property_put - put_property (PropertyMap property_map, - typename property_traits ::value_type value, - EventTag) - { - return property_put (property_map, value); - } - -#define BOOST_GRAPH_EVENT_STUB(Event,Kind) \ - typedef ::boost::Event Event##_type; \ - template \ - Kind##_visitor, Visitors> > \ - do_##Event(Visitor visitor) \ - { \ - typedef std::pair, \ - Visitors> visitor_list; \ - typedef Kind##_visitor result_type; \ - return result_type(visitor_list(visitor, m_vis)); \ - } - -} /* namespace boost */ - -#if BOOST_WORKAROUND(BOOST_MSVC, < 1300) -// Stay out of the way of the concept checking class -# undef Graph -#endif - -#endif diff --git a/third_party/ycmd/cpp/BoostParts/boost/implicit_cast.hpp b/third_party/ycmd/cpp/BoostParts/boost/implicit_cast.hpp deleted file mode 100644 index 5b1cd92b..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/implicit_cast.hpp +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright David Abrahams 2003. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -#ifndef IMPLICIT_CAST_DWA200356_HPP -# define IMPLICIT_CAST_DWA200356_HPP - -# include - -namespace boost { - -// implementation originally suggested by C. Green in -// http://lists.boost.org/MailArchives/boost/msg00886.php - -// The use of identity creates a non-deduced form, so that the -// explicit template argument must be supplied -template -inline T implicit_cast (typename mpl::identity::type x) { - return x; -} - -// incomplete return type now is here -//template -//void implicit_cast (...); - -} // namespace boost - - -#endif // IMPLICIT_CAST_DWA200356_HPP diff --git a/third_party/ycmd/cpp/BoostParts/boost/indirect_reference.hpp b/third_party/ycmd/cpp/BoostParts/boost/indirect_reference.hpp deleted file mode 100644 index 5fbb3423..00000000 --- a/third_party/ycmd/cpp/BoostParts/boost/indirect_reference.hpp +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef INDIRECT_REFERENCE_DWA200415_HPP -# define INDIRECT_REFERENCE_DWA200415_HPP - -// -// Copyright David Abrahams 2004. Use, modification and distribution is -// subject to the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// typename indirect_reference