passenger 6.0.2 → 6.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (419) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +60 -19
  3. data/CONTRIBUTORS +2 -0
  4. data/build/support/vendor/cxxcodebuilder/lib/cxxcodebuilder/builder.rb +56 -3
  5. data/dev/copy_boost_headers +1 -0
  6. data/package.json +1 -1
  7. data/resources/templates/standalone/http.erb +1 -0
  8. data/src/agent/Core/Config.h +13 -1
  9. data/src/agent/Core/Controller/Config.h +1 -1
  10. data/src/agent/Core/CoreMain.cpp +1 -0
  11. data/src/agent/Core/SpawningKit/Context.h +1 -0
  12. data/src/agent/Core/SpawningKit/Handshake/Prepare.h +1 -1
  13. data/src/agent/Core/SpawningKit/Handshake/WorkDir.h +5 -2
  14. data/src/agent/Watchdog/Config.h +14 -1
  15. data/src/agent/Watchdog/WatchdogMain.cpp +7 -0
  16. data/src/apache2_module/ConfigGeneral/AutoGeneratedDefinitions.cpp +5 -0
  17. data/src/apache2_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.cpp +5 -0
  18. data/src/apache2_module/ConfigGeneral/AutoGeneratedSetterFuncs.cpp +15 -0
  19. data/src/apache2_module/Hooks.cpp +1 -0
  20. data/src/apache2_module/ServerConfig/AutoGeneratedManifestGeneration.cpp +11 -0
  21. data/src/apache2_module/ServerConfig/AutoGeneratedStruct.h +13 -0
  22. data/src/cxx_supportlib/Constants.h +1 -1
  23. data/src/cxx_supportlib/LoggingKit/Config.h +1 -0
  24. data/src/cxx_supportlib/ServerKit/HttpChunkedBodyParser.h +1 -1
  25. data/src/cxx_supportlib/SystemTools/ContainerHelpers.h +2 -2
  26. data/src/cxx_supportlib/WebSocketCommandReverseServer.h +11 -7
  27. data/src/cxx_supportlib/vendor-modified/boost/algorithm/string/finder.hpp +0 -4
  28. data/src/cxx_supportlib/vendor-modified/boost/asio/buffer.hpp +46 -37
  29. data/src/cxx_supportlib/vendor-modified/boost/asio/connect.hpp +16 -15
  30. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/config.hpp +45 -26
  31. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/future.hpp +33 -0
  32. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/socket_ops.ipp +1 -1
  33. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/is_buffer_sequence.hpp +38 -14
  34. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/timer_queue.hpp +2 -0
  35. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/io_context.hpp +1 -1
  36. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read_until.hpp +3 -1
  37. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/use_future.hpp +0 -1
  38. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/bad_address_cast.hpp +6 -1
  39. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver.hpp +6 -4
  40. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/basic_resolver_results.hpp +4 -4
  41. data/src/cxx_supportlib/vendor-modified/boost/asio/packaged_task.hpp +3 -3
  42. data/src/cxx_supportlib/vendor-modified/boost/asio/read.hpp +4 -4
  43. data/src/cxx_supportlib/vendor-modified/boost/asio/read_at.hpp +4 -4
  44. data/src/cxx_supportlib/vendor-modified/boost/asio/read_until.hpp +8 -6
  45. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/context_base.hpp +17 -0
  46. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/impl/context.ipp +50 -5
  47. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/stream.hpp +2 -1
  48. data/src/cxx_supportlib/vendor-modified/boost/asio/thread_pool.hpp +1 -1
  49. data/src/cxx_supportlib/vendor-modified/boost/asio/use_future.hpp +3 -2
  50. data/src/cxx_supportlib/vendor-modified/boost/asio/version.hpp +1 -1
  51. data/src/cxx_supportlib/vendor-modified/boost/asio/write.hpp +4 -3
  52. data/src/cxx_supportlib/vendor-modified/boost/asio/write_at.hpp +5 -3
  53. data/src/cxx_supportlib/vendor-modified/boost/atomic/detail/ops_gcc_x86_dcas.hpp +13 -12
  54. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/mac/chrono.hpp +10 -10
  55. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/mac/process_cpu_clocks.hpp +34 -34
  56. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/mac/thread_clock.hpp +4 -4
  57. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/posix/chrono.hpp +8 -8
  58. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/posix/process_cpu_clocks.hpp +27 -27
  59. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/posix/thread_clock.hpp +4 -4
  60. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/system.hpp +5 -4
  61. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/time_point_io.hpp +1 -1
  62. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer.hpp +3 -3
  63. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer/allocators.hpp +89 -0
  64. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer/base.hpp +83 -74
  65. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer/details.hpp +21 -33
  66. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer/space_optimized.hpp +5 -5
  67. data/src/cxx_supportlib/vendor-modified/boost/concept/assert.hpp +1 -1
  68. data/src/cxx_supportlib/vendor-modified/boost/concept/detail/general.hpp +3 -3
  69. data/src/cxx_supportlib/vendor-modified/boost/concept/detail/has_constraints.hpp +3 -3
  70. data/src/cxx_supportlib/vendor-modified/boost/concept/usage.hpp +1 -1
  71. data/src/cxx_supportlib/vendor-modified/boost/concept_check.hpp +19 -19
  72. data/src/cxx_supportlib/vendor-modified/boost/config/auto_link.hpp +8 -0
  73. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/borland.hpp +5 -2
  74. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/clang.hpp +5 -1
  75. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/codegear.hpp +6 -2
  76. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/comeau.hpp +1 -1
  77. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/common_edg.hpp +4 -0
  78. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/cray.hpp +368 -52
  79. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/digitalmars.hpp +4 -1
  80. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/gcc.hpp +6 -3
  81. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/gcc_xml.hpp +3 -0
  82. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/greenhills.hpp +1 -1
  83. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/hp_acc.hpp +1 -1
  84. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/intel.hpp +6 -1
  85. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/kai.hpp +1 -1
  86. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/metrowerks.hpp +4 -1
  87. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/mpw.hpp +4 -1
  88. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/nvcc.hpp +3 -3
  89. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/pathscale.hpp +3 -0
  90. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/sunpro_cc.hpp +3 -0
  91. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/vacpp.hpp +4 -1
  92. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/visualc.hpp +9 -4
  93. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/xlcpp.hpp +4 -0
  94. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/xlcpp_zos.hpp +1 -0
  95. data/src/cxx_supportlib/vendor-modified/boost/config/detail/select_compiler_config.hpp +1 -2
  96. data/src/cxx_supportlib/vendor-modified/boost/config/detail/suffix.hpp +13 -0
  97. data/src/cxx_supportlib/vendor-modified/boost/config/stdlib/dinkumware.hpp +2 -2
  98. data/src/cxx_supportlib/vendor-modified/boost/config/stdlib/libcpp.hpp +14 -4
  99. data/src/cxx_supportlib/vendor-modified/boost/config/stdlib/libstdcpp3.hpp +4 -4
  100. data/src/cxx_supportlib/vendor-modified/boost/container/adaptive_pool.hpp +262 -2
  101. data/src/cxx_supportlib/vendor-modified/boost/container/allocator.hpp +4 -3
  102. data/src/cxx_supportlib/vendor-modified/boost/container/allocator_traits.hpp +1 -1
  103. data/src/cxx_supportlib/vendor-modified/boost/container/deque.hpp +7 -0
  104. data/src/cxx_supportlib/vendor-modified/boost/container/detail/adaptive_node_pool.hpp +22 -19
  105. data/src/cxx_supportlib/vendor-modified/boost/container/detail/adaptive_node_pool_impl.hpp +833 -459
  106. data/src/cxx_supportlib/vendor-modified/boost/container/detail/advanced_insert_int.hpp +24 -6
  107. data/src/cxx_supportlib/vendor-modified/boost/container/detail/allocator_version_traits.hpp +2 -1
  108. data/src/cxx_supportlib/vendor-modified/boost/container/detail/compare_functors.hpp +61 -5
  109. data/src/cxx_supportlib/vendor-modified/boost/container/detail/copy_move_algo.hpp +33 -8
  110. data/src/cxx_supportlib/vendor-modified/boost/container/detail/flat_tree.hpp +132 -41
  111. data/src/cxx_supportlib/vendor-modified/boost/container/detail/iterator.hpp +16 -0
  112. data/src/cxx_supportlib/vendor-modified/boost/container/detail/math_functions.hpp +54 -0
  113. data/src/cxx_supportlib/vendor-modified/boost/container/detail/mpl.hpp +58 -0
  114. data/src/cxx_supportlib/vendor-modified/boost/container/detail/multiallocation_chain.hpp +28 -23
  115. data/src/cxx_supportlib/vendor-modified/boost/container/detail/node_alloc_holder.hpp +167 -115
  116. data/src/cxx_supportlib/vendor-modified/boost/container/detail/pair.hpp +55 -0
  117. data/src/cxx_supportlib/vendor-modified/boost/container/detail/std_fwd.hpp +3 -0
  118. data/src/cxx_supportlib/vendor-modified/boost/container/detail/thread_mutex.hpp +181 -0
  119. data/src/cxx_supportlib/vendor-modified/boost/container/detail/tree.hpp +167 -29
  120. data/src/cxx_supportlib/vendor-modified/boost/container/detail/type_traits.hpp +2 -0
  121. data/src/cxx_supportlib/vendor-modified/boost/container/detail/variadic_templates_tools.hpp +1 -1
  122. data/src/cxx_supportlib/vendor-modified/boost/container/detail/workaround.hpp +18 -0
  123. data/src/cxx_supportlib/vendor-modified/boost/container/flat_map.hpp +389 -3
  124. data/src/cxx_supportlib/vendor-modified/boost/container/flat_set.hpp +262 -0
  125. data/src/cxx_supportlib/vendor-modified/boost/container/list.hpp +52 -8
  126. data/src/cxx_supportlib/vendor-modified/boost/container/map.hpp +364 -0
  127. data/src/cxx_supportlib/vendor-modified/boost/container/pmr/monotonic_buffer_resource.hpp +4 -2
  128. data/src/cxx_supportlib/vendor-modified/boost/container/pmr/resource_adaptor.hpp +1 -1
  129. data/src/cxx_supportlib/vendor-modified/boost/container/pmr/synchronized_pool_resource.hpp +3 -2
  130. data/src/cxx_supportlib/vendor-modified/boost/container/set.hpp +286 -6
  131. data/src/cxx_supportlib/vendor-modified/boost/container/slist.hpp +56 -8
  132. data/src/cxx_supportlib/vendor-modified/boost/container/small_vector.hpp +43 -6
  133. data/src/cxx_supportlib/vendor-modified/boost/container/stable_vector.hpp +100 -31
  134. data/src/cxx_supportlib/vendor-modified/boost/container/static_vector.hpp +2 -1
  135. data/src/cxx_supportlib/vendor-modified/boost/container/string.hpp +126 -69
  136. data/src/cxx_supportlib/vendor-modified/boost/container/vector.hpp +75 -51
  137. data/src/cxx_supportlib/vendor-modified/boost/core/empty_value.hpp +136 -0
  138. data/src/cxx_supportlib/vendor-modified/boost/core/exchange.hpp +49 -0
  139. data/src/cxx_supportlib/vendor-modified/boost/core/explicit_operator_bool.hpp +9 -0
  140. data/src/cxx_supportlib/vendor-modified/boost/core/lightweight_test.hpp +101 -130
  141. data/src/cxx_supportlib/vendor-modified/boost/core/lightweight_test_trait.hpp +2 -2
  142. data/src/cxx_supportlib/vendor-modified/boost/core/noncopyable.hpp +16 -1
  143. data/src/cxx_supportlib/vendor-modified/boost/core/quick_exit.hpp +59 -0
  144. data/src/cxx_supportlib/vendor-modified/boost/core/ref.hpp +2 -1
  145. data/src/cxx_supportlib/vendor-modified/boost/core/swap.hpp +9 -2
  146. data/src/cxx_supportlib/vendor-modified/boost/core/typeinfo.hpp +26 -10
  147. data/src/cxx_supportlib/vendor-modified/boost/date_time/compiler_config.hpp +5 -0
  148. data/src/cxx_supportlib/vendor-modified/boost/date_time/posix_time/posix_time_duration.hpp +3 -3
  149. data/src/cxx_supportlib/vendor-modified/boost/date_time/time_duration.hpp +1 -1
  150. data/src/cxx_supportlib/vendor-modified/boost/detail/basic_pointerbuf.hpp +1 -1
  151. data/src/cxx_supportlib/vendor-modified/boost/detail/indirect_traits.hpp +38 -47
  152. data/src/cxx_supportlib/vendor-modified/boost/detail/lcast_precision.hpp +5 -5
  153. data/src/cxx_supportlib/vendor-modified/boost/detail/reference_content.hpp +7 -7
  154. data/src/cxx_supportlib/vendor-modified/boost/exception/exception.hpp +62 -58
  155. data/src/cxx_supportlib/vendor-modified/boost/function.hpp +1 -1
  156. data/src/cxx_supportlib/vendor-modified/boost/function/function_base.hpp +29 -29
  157. data/src/cxx_supportlib/vendor-modified/boost/function/function_template.hpp +38 -40
  158. data/src/cxx_supportlib/vendor-modified/boost/integer/common_factor_rt.hpp +4 -4
  159. data/src/cxx_supportlib/vendor-modified/boost/intrusive/avltree_algorithms.hpp +44 -44
  160. data/src/cxx_supportlib/vendor-modified/boost/intrusive/bstree_algorithms.hpp +39 -39
  161. data/src/cxx_supportlib/vendor-modified/boost/intrusive/circular_list_algorithms.hpp +15 -15
  162. data/src/cxx_supportlib/vendor-modified/boost/intrusive/circular_slist_algorithms.hpp +7 -7
  163. data/src/cxx_supportlib/vendor-modified/boost/intrusive/derivation_value_traits.hpp +1 -1
  164. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/any_node_and_algorithms.hpp +14 -14
  165. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/avltree_node.hpp +9 -9
  166. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/common_slist_algorithms.hpp +7 -7
  167. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/list_iterator.hpp +1 -1
  168. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/list_node.hpp +2 -2
  169. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/node_cloner_disposer.hpp +2 -2
  170. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/rbtree_node.hpp +6 -6
  171. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/simple_disposers.hpp +1 -1
  172. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/slist_iterator.hpp +1 -1
  173. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/slist_node.hpp +1 -1
  174. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/tree_iterator.hpp +1 -1
  175. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/tree_node.hpp +3 -3
  176. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/tree_value_compare.hpp +33 -14
  177. data/src/cxx_supportlib/vendor-modified/boost/intrusive/hashtable.hpp +12 -12
  178. data/src/cxx_supportlib/vendor-modified/boost/intrusive/linear_slist_algorithms.hpp +4 -4
  179. data/src/cxx_supportlib/vendor-modified/boost/intrusive/pointer_plus_bits.hpp +3 -0
  180. data/src/cxx_supportlib/vendor-modified/boost/intrusive/rbtree_algorithms.hpp +39 -39
  181. data/src/cxx_supportlib/vendor-modified/boost/intrusive/sgtree_algorithms.hpp +61 -61
  182. data/src/cxx_supportlib/vendor-modified/boost/intrusive/slist.hpp +4 -4
  183. data/src/cxx_supportlib/vendor-modified/boost/intrusive/splaytree_algorithms.hpp +66 -66
  184. data/src/cxx_supportlib/vendor-modified/boost/intrusive/treap_algorithms.hpp +54 -54
  185. data/src/cxx_supportlib/vendor-modified/boost/intrusive/unordered_set.hpp +6 -2
  186. data/src/cxx_supportlib/vendor-modified/boost/intrusive/unordered_set_hook.hpp +3 -3
  187. data/src/cxx_supportlib/vendor-modified/boost/iterator/advance.hpp +1 -1
  188. data/src/cxx_supportlib/vendor-modified/boost/iterator/distance.hpp +65 -0
  189. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast.hpp +1 -1
  190. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/bad_lexical_cast.hpp +1 -1
  191. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_lexical.hpp +23 -23
  192. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_lexical_streams.hpp +4 -4
  193. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_numeric.hpp +13 -13
  194. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/inf_nan.hpp +1 -1
  195. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/is_character.hpp +5 -4
  196. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/lcast_char_constants.hpp +1 -1
  197. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/lcast_unsigned_converters.hpp +5 -5
  198. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/widest_char.hpp +5 -2
  199. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/try_lexical_convert.hpp +18 -13
  200. data/src/cxx_supportlib/vendor-modified/boost/libs/regex/src/cregex.cpp +4 -4
  201. data/src/cxx_supportlib/vendor-modified/boost/libs/system/src/error_code.cpp +16 -5
  202. data/src/cxx_supportlib/vendor-modified/boost/libs/thread/src/future.cpp +1 -1
  203. data/src/cxx_supportlib/vendor-modified/boost/libs/thread/src/pthread/thread.cpp +14 -8
  204. data/src/cxx_supportlib/vendor-modified/boost/libs/thread/src/tss_null.cpp +2 -2
  205. data/src/cxx_supportlib/vendor-modified/boost/math/special_functions/detail/fp_traits.hpp +13 -13
  206. data/src/cxx_supportlib/vendor-modified/boost/math/special_functions/math_fwd.hpp +27 -0
  207. data/src/cxx_supportlib/vendor-modified/boost/math/tools/config.hpp +1 -1
  208. data/src/cxx_supportlib/vendor-modified/boost/move/algo/adaptive_merge.hpp +29 -6
  209. data/src/cxx_supportlib/vendor-modified/boost/move/algo/adaptive_sort.hpp +12 -3
  210. data/src/cxx_supportlib/vendor-modified/boost/move/algo/detail/adaptive_sort_merge.hpp +1 -1
  211. data/src/cxx_supportlib/vendor-modified/boost/move/algo/move.hpp +1 -1
  212. data/src/cxx_supportlib/vendor-modified/boost/move/algorithm.hpp +1 -1
  213. data/src/cxx_supportlib/vendor-modified/boost/move/core.hpp +8 -8
  214. data/src/cxx_supportlib/vendor-modified/boost/move/detail/meta_utils.hpp +2 -0
  215. data/src/cxx_supportlib/vendor-modified/boost/move/detail/type_traits.hpp +3 -3
  216. data/src/cxx_supportlib/vendor-modified/boost/mpl/assert.hpp +23 -3
  217. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/experimental_traits.hpp +9 -3
  218. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/old_optional_implementation.hpp +10 -11
  219. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_reference_spec.hpp +20 -1
  220. data/src/cxx_supportlib/vendor-modified/boost/optional/detail/optional_trivially_copyable_base.hpp +3 -3
  221. data/src/cxx_supportlib/vendor-modified/boost/optional/optional.hpp +211 -101
  222. data/src/cxx_supportlib/vendor-modified/boost/parameter/python.hpp +5 -6
  223. data/src/cxx_supportlib/vendor-modified/boost/pool/detail/mutex.hpp +119 -25
  224. data/src/cxx_supportlib/vendor-modified/boost/predef/architecture.h +1 -0
  225. data/src/cxx_supportlib/vendor-modified/boost/predef/architecture/arm.h +5 -0
  226. data/src/cxx_supportlib/vendor-modified/boost/predef/architecture/ptx.h +44 -0
  227. data/src/cxx_supportlib/vendor-modified/boost/predef/compiler.h +1 -0
  228. data/src/cxx_supportlib/vendor-modified/boost/predef/compiler/compaq.h +1 -1
  229. data/src/cxx_supportlib/vendor-modified/boost/predef/compiler/nvcc.h +73 -0
  230. data/src/cxx_supportlib/vendor-modified/boost/predef/detail/endian_compat.h +3 -1
  231. data/src/cxx_supportlib/vendor-modified/boost/predef/language.h +1 -0
  232. data/src/cxx_supportlib/vendor-modified/boost/predef/language/cuda.h +52 -0
  233. data/src/cxx_supportlib/vendor-modified/boost/predef/make.h +4 -0
  234. data/src/cxx_supportlib/vendor-modified/boost/predef/os/cygwin.h +6 -1
  235. data/src/cxx_supportlib/vendor-modified/boost/predef/other/endian.h +1 -2
  236. data/src/cxx_supportlib/vendor-modified/boost/predef/version.h +1 -1
  237. data/src/cxx_supportlib/vendor-modified/boost/preprocessor/config/config.hpp +17 -8
  238. data/src/cxx_supportlib/vendor-modified/boost/preprocessor/stringize.hpp +4 -0
  239. data/src/cxx_supportlib/vendor-modified/boost/preprocessor/wstringize.hpp +4 -0
  240. data/src/cxx_supportlib/vendor-modified/boost/random/detail/gray_coded_qrng.hpp +166 -0
  241. data/src/cxx_supportlib/vendor-modified/boost/random/detail/niederreiter_base2_table.hpp +513 -0
  242. data/src/cxx_supportlib/vendor-modified/boost/random/detail/qrng_base.hpp +291 -0
  243. data/src/cxx_supportlib/vendor-modified/boost/random/detail/sobol_table.hpp +4106 -0
  244. data/src/cxx_supportlib/vendor-modified/boost/random/faure.hpp +367 -0
  245. data/src/cxx_supportlib/vendor-modified/boost/random/niederreiter_base2.hpp +360 -0
  246. data/src/cxx_supportlib/vendor-modified/boost/random/sobol.hpp +237 -0
  247. data/src/cxx_supportlib/vendor-modified/boost/range/as_literal.hpp +43 -0
  248. data/src/cxx_supportlib/vendor-modified/boost/range/begin.hpp +13 -5
  249. data/src/cxx_supportlib/vendor-modified/boost/range/concepts.hpp +1 -1
  250. data/src/cxx_supportlib/vendor-modified/boost/range/detail/common.hpp +1 -3
  251. data/src/cxx_supportlib/vendor-modified/boost/range/detail/implementation_help.hpp +2 -2
  252. data/src/cxx_supportlib/vendor-modified/boost/range/distance.hpp +11 -5
  253. data/src/cxx_supportlib/vendor-modified/boost/range/end.hpp +14 -6
  254. data/src/cxx_supportlib/vendor-modified/boost/range/has_range_iterator.hpp +3 -3
  255. data/src/cxx_supportlib/vendor-modified/boost/ratio/config.hpp +6 -2
  256. data/src/cxx_supportlib/vendor-modified/boost/rational.hpp +55 -37
  257. data/src/cxx_supportlib/vendor-modified/boost/regex/concepts.hpp +3 -2
  258. data/src/cxx_supportlib/vendor-modified/boost/regex/config.hpp +11 -1
  259. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/basic_regex.hpp +7 -1
  260. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/basic_regex_creator.hpp +3 -1
  261. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/basic_regex_parser.hpp +5 -2
  262. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/fileiter.hpp +0 -3
  263. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp +15 -4
  264. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/match_flags.hpp +1 -2
  265. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/match_results.hpp +12 -3
  266. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/perl_matcher.hpp +7 -2
  267. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/perl_matcher_common.hpp +7 -3
  268. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/perl_matcher_non_recursive.hpp +6 -2
  269. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_format.hpp +0 -5
  270. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_iterator.hpp +0 -8
  271. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_raw_buffer.hpp +3 -3
  272. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_split.hpp +3 -1
  273. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_token_iterator.hpp +0 -8
  274. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_traits_defaults.hpp +12 -11
  275. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/regex_workaround.hpp +7 -4
  276. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/u32regex_iterator.hpp +1 -9
  277. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/u32regex_token_iterator.hpp +2 -10
  278. data/src/cxx_supportlib/vendor-modified/boost/regex/v4/w32_regex_traits.hpp +2 -0
  279. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/allocate_shared_array.hpp +60 -115
  280. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/local_counted_base.hpp +3 -3
  281. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_acc_ia64.hpp +2 -1
  282. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_aix.hpp +2 -1
  283. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_clang.hpp +2 -1
  284. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_cw_ppc.hpp +2 -1
  285. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_cw_x86.hpp +2 -1
  286. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_gcc_ia64.hpp +2 -1
  287. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_gcc_mips.hpp +2 -1
  288. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_gcc_ppc.hpp +2 -1
  289. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp +2 -1
  290. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp +2 -1
  291. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_nt.hpp +2 -1
  292. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_pt.hpp +2 -1
  293. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_snc_ps3.hpp +2 -1
  294. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_solaris.hpp +2 -1
  295. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_spin.hpp +2 -1
  296. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_std_atomic.hpp +2 -1
  297. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_sync.hpp +2 -1
  298. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_base_vacpp_ppc.hpp +2 -1
  299. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/sp_counted_impl.hpp +3 -3
  300. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/yield_k.hpp +14 -8
  301. data/src/cxx_supportlib/vendor-modified/boost/system/config.hpp +4 -24
  302. data/src/cxx_supportlib/vendor-modified/boost/system/detail/config.hpp +57 -0
  303. data/src/cxx_supportlib/vendor-modified/boost/system/detail/generic_category.hpp +101 -0
  304. data/src/cxx_supportlib/vendor-modified/boost/system/detail/std_interoperability.hpp +141 -0
  305. data/src/cxx_supportlib/vendor-modified/boost/system/detail/system_category_posix.hpp +132 -0
  306. data/src/cxx_supportlib/vendor-modified/boost/system/error_code.hpp +775 -588
  307. data/src/cxx_supportlib/vendor-modified/boost/system/system_error.hpp +4 -4
  308. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/config.hpp +6 -0
  309. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/move.hpp +13 -6
  310. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/nullary_function.hpp +8 -3
  311. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp +3 -1
  312. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread_safety.hpp +160 -0
  313. data/src/cxx_supportlib/vendor-modified/boost/thread/detail/tss_hooks.hpp +2 -2
  314. data/src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp +3 -3
  315. data/src/cxx_supportlib/vendor-modified/boost/thread/executors/basic_thread_pool.hpp +24 -1
  316. data/src/cxx_supportlib/vendor-modified/boost/thread/future.hpp +10 -1
  317. data/src/cxx_supportlib/vendor-modified/boost/thread/lock_guard.hpp +4 -4
  318. data/src/cxx_supportlib/vendor-modified/boost/thread/lockable_traits.hpp +31 -0
  319. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp +2 -2
  320. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable_fwd.hpp +2 -2
  321. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/mutex.hpp +8 -53
  322. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/pthread_mutex_scoped_lock.hpp +73 -4
  323. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/recursive_mutex.hpp +6 -6
  324. data/src/cxx_supportlib/vendor-modified/boost/thread/pthread/thread_data.hpp +14 -9
  325. data/src/cxx_supportlib/vendor-modified/boost/thread/xtime.hpp +6 -6
  326. data/src/cxx_supportlib/vendor-modified/boost/throw_exception.hpp +9 -8
  327. data/src/cxx_supportlib/vendor-modified/boost/token_functions.hpp +1 -0
  328. data/src/cxx_supportlib/vendor-modified/boost/type_index/stl_type_index.hpp +21 -19
  329. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/common_arithmetic_type.hpp +3 -1
  330. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/config.hpp +9 -0
  331. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/detector.hpp +1 -1
  332. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/has_postfix_operator.hpp +55 -0
  333. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/has_prefix_operator.hpp +72 -0
  334. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_function_cxx_03.hpp +108 -0
  335. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_function_cxx_11.hpp +501 -0
  336. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_function_msvc10_fix.hpp +30 -0
  337. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_likely_lambda.hpp +2 -2
  338. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_member_function_pointer_cxx_03.hpp +117 -0
  339. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_member_function_pointer_cxx_11.hpp +557 -0
  340. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_rvalue_reference_msvc10_fix.hpp +43 -0
  341. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detected.hpp +1 -1
  342. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detected_or.hpp +1 -1
  343. data/src/cxx_supportlib/vendor-modified/boost/type_traits/enable_if.hpp +37 -0
  344. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_dereference.hpp +344 -0
  345. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_minus.hpp +5 -0
  346. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_minus_assign.hpp +5 -0
  347. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_plus_assign.hpp +5 -0
  348. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_post_decrement.hpp +21 -0
  349. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_post_increment.hpp +21 -0
  350. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_pre_decrement.hpp +21 -0
  351. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_pre_increment.hpp +22 -0
  352. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_trivial_move_assign.hpp +1 -1
  353. data/src/cxx_supportlib/vendor-modified/boost/type_traits/has_trivial_move_constructor.hpp +2 -1
  354. data/src/cxx_supportlib/vendor-modified/boost/type_traits/integral_constant.hpp +5 -15
  355. data/src/cxx_supportlib/vendor-modified/boost/type_traits/intrinsics.hpp +16 -6
  356. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_complete.hpp +3 -1
  357. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_copy_assignable.hpp +3 -4
  358. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_copy_constructible.hpp +4 -6
  359. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_detected.hpp +1 -1
  360. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_detected_convertible.hpp +1 -1
  361. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_detected_exact.hpp +1 -1
  362. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_final.hpp +1 -1
  363. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_function.hpp +4 -79
  364. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_member_function_pointer.hpp +3 -97
  365. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_noncopyable.hpp +39 -0
  366. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_nothrow_move_assignable.hpp +2 -2
  367. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_nothrow_move_constructible.hpp +2 -2
  368. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_rvalue_reference.hpp +4 -0
  369. data/src/cxx_supportlib/vendor-modified/boost/type_traits/is_virtual_base_of.hpp +104 -63
  370. data/src/cxx_supportlib/vendor-modified/boost/type_traits/make_void.hpp +1 -1
  371. data/src/cxx_supportlib/vendor-modified/boost/type_traits/nonesuch.hpp +1 -1
  372. data/src/cxx_supportlib/vendor-modified/boost/typeof/constant.hpp +26 -0
  373. data/src/cxx_supportlib/vendor-modified/boost/typeof/dmc/typeof_impl.hpp +4 -4
  374. data/src/cxx_supportlib/vendor-modified/boost/typeof/encode_decode.hpp +0 -3
  375. data/src/cxx_supportlib/vendor-modified/boost/typeof/encode_decode_params.hpp +1 -1
  376. data/src/cxx_supportlib/vendor-modified/boost/typeof/int_encoding.hpp +4 -5
  377. data/src/cxx_supportlib/vendor-modified/boost/typeof/modifiers.hpp +5 -5
  378. data/src/cxx_supportlib/vendor-modified/boost/typeof/msvc/typeof_impl.hpp +9 -9
  379. data/src/cxx_supportlib/vendor-modified/boost/typeof/native.hpp +3 -3
  380. data/src/cxx_supportlib/vendor-modified/boost/typeof/pointers_data_members.hpp +2 -2
  381. data/src/cxx_supportlib/vendor-modified/boost/typeof/register_functions_iterate.hpp +6 -6
  382. data/src/cxx_supportlib/vendor-modified/boost/typeof/register_mem_functions.hpp +1 -1
  383. data/src/cxx_supportlib/vendor-modified/boost/typeof/template_encoding.hpp +4 -4
  384. data/src/cxx_supportlib/vendor-modified/boost/typeof/template_template_param.hpp +2 -2
  385. data/src/cxx_supportlib/vendor-modified/boost/typeof/type_encoding.hpp +2 -2
  386. data/src/cxx_supportlib/vendor-modified/boost/typeof/typeof_impl.hpp +16 -16
  387. data/src/cxx_supportlib/vendor-modified/boost/typeof/vector.hpp +5 -5
  388. data/src/cxx_supportlib/vendor-modified/boost/typeof/vector100.hpp +201 -201
  389. data/src/cxx_supportlib/vendor-modified/boost/typeof/vector150.hpp +301 -301
  390. data/src/cxx_supportlib/vendor-modified/boost/typeof/vector200.hpp +401 -401
  391. data/src/cxx_supportlib/vendor-modified/boost/typeof/vector50.hpp +101 -101
  392. data/src/cxx_supportlib/vendor-modified/boost/utility/detail/minstd_rand.hpp +3 -0
  393. data/src/cxx_supportlib/vendor-modified/boost/utility/string_ref.hpp +2 -0
  394. data/src/cxx_supportlib/vendor-modified/boost/utility/string_view.hpp +26 -6
  395. data/src/cxx_supportlib/vendor-modified/boost/version.hpp +2 -2
  396. data/src/nginx_module/ConfigGeneral/AutoGeneratedDefinitions.c +16 -0
  397. data/src/nginx_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.c +13 -0
  398. data/src/nginx_module/ConfigGeneral/AutoGeneratedSetterFuncs.c +24 -0
  399. data/src/nginx_module/Configuration.c +9 -0
  400. data/src/nginx_module/ContentHandler.c +7 -1
  401. data/src/nginx_module/LocationConfig/AutoGeneratedCreateFunction.c +5 -0
  402. data/src/nginx_module/LocationConfig/AutoGeneratedManifestGeneration.c +13 -0
  403. data/src/nginx_module/LocationConfig/AutoGeneratedMergeFunction.c +3 -0
  404. data/src/nginx_module/LocationConfig/AutoGeneratedStruct.h +4 -0
  405. data/src/nginx_module/MainConfig/AutoGeneratedCreateFunction.c +6 -0
  406. data/src/nginx_module/MainConfig/AutoGeneratedManifestGeneration.c +12 -0
  407. data/src/nginx_module/MainConfig/AutoGeneratedStruct.h +4 -0
  408. data/src/nginx_module/ngx_http_passenger_module.c +1 -0
  409. data/src/ruby_supportlib/phusion_passenger.rb +7 -7
  410. data/src/ruby_supportlib/phusion_passenger/apache2/config_options.rb +7 -0
  411. data/src/ruby_supportlib/phusion_passenger/nginx/config_options.rb +15 -0
  412. data/src/ruby_supportlib/phusion_passenger/request_handler.rb +2 -2
  413. data/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb +5 -0
  414. data/src/ruby_supportlib/phusion_passenger/standalone/start_command/builtin_engine.rb +1 -0
  415. metadata +33 -6
  416. data/src/cxx_supportlib/vendor-modified/boost/call_traits.hpp +0 -20
  417. data/src/cxx_supportlib/vendor-modified/boost/detail/call_traits.hpp +0 -172
  418. data/src/cxx_supportlib/vendor-modified/boost/detail/no_exceptions_support.hpp +0 -17
  419. data/src/cxx_supportlib/vendor-modified/boost/system/detail/error_code.ipp +0 -496
@@ -58,21 +58,21 @@ namespace boost { namespace chrono {
58
58
  mach_msg_type_number_t count = THREAD_BASIC_INFO_COUNT;
59
59
  if ( thread_info(port, THREAD_BASIC_INFO, (thread_info_t)&info, &count) != KERN_SUCCESS )
60
60
  {
61
- if (BOOST_CHRONO_IS_THROWS(ec))
61
+ if (::boost::chrono::is_throws(ec))
62
62
  {
63
63
  boost::throw_exception(
64
64
  system::system_error(
65
65
  EINVAL,
66
- BOOST_CHRONO_SYSTEM_CATEGORY,
66
+ ::boost::system::system_category(),
67
67
  "chrono::thread_clock" ));
68
68
  }
69
69
  else
70
70
  {
71
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
71
+ ec.assign( errno, ::boost::system::system_category() );
72
72
  return time_point();
73
73
  }
74
74
  }
75
- if (!BOOST_CHRONO_IS_THROWS(ec))
75
+ if (!::boost::chrono::is_throws(ec))
76
76
  {
77
77
  ec.clear();
78
78
  }
@@ -36,22 +36,22 @@ namespace chrono
36
36
  timespec ts;
37
37
  if ( ::clock_gettime( CLOCK_REALTIME, &ts ) )
38
38
  {
39
- if (BOOST_CHRONO_IS_THROWS(ec))
39
+ if (::boost::chrono::is_throws(ec))
40
40
  {
41
41
  boost::throw_exception(
42
42
  system::system_error(
43
43
  errno,
44
- BOOST_CHRONO_SYSTEM_CATEGORY,
44
+ ::boost::system::system_category(),
45
45
  "chrono::system_clock" ));
46
46
  }
47
47
  else
48
48
  {
49
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
49
+ ec.assign( errno, ::boost::system::system_category() );
50
50
  return time_point();
51
51
  }
52
52
  }
53
53
 
54
- if (!BOOST_CHRONO_IS_THROWS(ec))
54
+ if (!::boost::chrono::is_throws(ec))
55
55
  {
56
56
  ec.clear();
57
57
  }
@@ -90,22 +90,22 @@ namespace chrono
90
90
  timespec ts;
91
91
  if ( ::clock_gettime( CLOCK_MONOTONIC, &ts ) )
92
92
  {
93
- if (BOOST_CHRONO_IS_THROWS(ec))
93
+ if (::boost::chrono::is_throws(ec))
94
94
  {
95
95
  boost::throw_exception(
96
96
  system::system_error(
97
97
  errno,
98
- BOOST_CHRONO_SYSTEM_CATEGORY,
98
+ ::boost::system::system_category(),
99
99
  "chrono::steady_clock" ));
100
100
  }
101
101
  else
102
102
  {
103
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
103
+ ec.assign( errno, ::boost::system::system_category() );
104
104
  return time_point();
105
105
  }
106
106
  }
107
107
 
108
- if (!BOOST_CHRONO_IS_THROWS(ec))
108
+ if (!::boost::chrono::is_throws(ec))
109
109
  {
110
110
  ec.clear();
111
111
  }
@@ -73,17 +73,17 @@ process_real_cpu_clock::time_point process_real_cpu_clock::now(
73
73
  clock_t c = ::times( &tm );
74
74
  if ( c == clock_t(-1) ) // error
75
75
  {
76
- if (BOOST_CHRONO_IS_THROWS(ec))
76
+ if (::boost::chrono::is_throws(ec))
77
77
  {
78
78
  boost::throw_exception(
79
79
  system::system_error(
80
80
  errno,
81
- BOOST_CHRONO_SYSTEM_CATEGORY,
81
+ ::boost::system::system_category(),
82
82
  "chrono::process_real_cpu_clock" ));
83
83
  }
84
84
  else
85
85
  {
86
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
86
+ ec.assign( errno, ::boost::system::system_category() );
87
87
  return time_point();
88
88
  }
89
89
  }
@@ -91,7 +91,7 @@ process_real_cpu_clock::time_point process_real_cpu_clock::now(
91
91
  {
92
92
  if ( chrono_detail::tick_factor() != -1 )
93
93
  {
94
- if (!BOOST_CHRONO_IS_THROWS(ec))
94
+ if (!::boost::chrono::is_throws(ec))
95
95
  {
96
96
  ec.clear();
97
97
  }
@@ -100,17 +100,17 @@ process_real_cpu_clock::time_point process_real_cpu_clock::now(
100
100
  }
101
101
  else
102
102
  {
103
- if (BOOST_CHRONO_IS_THROWS(ec))
103
+ if (::boost::chrono::is_throws(ec))
104
104
  {
105
105
  boost::throw_exception(
106
106
  system::system_error(
107
107
  errno,
108
- BOOST_CHRONO_SYSTEM_CATEGORY,
108
+ ::boost::system::system_category(),
109
109
  "chrono::process_real_cpu_clock" ));
110
110
  }
111
111
  else
112
112
  {
113
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
113
+ ec.assign( errno, ::boost::system::system_category() );
114
114
  return time_point();
115
115
  }
116
116
  }
@@ -149,17 +149,17 @@ process_user_cpu_clock::time_point process_user_cpu_clock::now(
149
149
  clock_t c = ::times( &tm );
150
150
  if ( c == clock_t(-1) ) // error
151
151
  {
152
- if (BOOST_CHRONO_IS_THROWS(ec))
152
+ if (::boost::chrono::is_throws(ec))
153
153
  {
154
154
  boost::throw_exception(
155
155
  system::system_error(
156
156
  errno,
157
- BOOST_CHRONO_SYSTEM_CATEGORY,
157
+ ::boost::system::system_category(),
158
158
  "chrono::process_user_cpu_clock" ));
159
159
  }
160
160
  else
161
161
  {
162
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
162
+ ec.assign( errno, ::boost::system::system_category() );
163
163
  return time_point();
164
164
  }
165
165
  }
@@ -167,7 +167,7 @@ process_user_cpu_clock::time_point process_user_cpu_clock::now(
167
167
  {
168
168
  if ( chrono_detail::tick_factor() != -1 )
169
169
  {
170
- if (!BOOST_CHRONO_IS_THROWS(ec))
170
+ if (!::boost::chrono::is_throws(ec))
171
171
  {
172
172
  ec.clear();
173
173
  }
@@ -176,17 +176,17 @@ process_user_cpu_clock::time_point process_user_cpu_clock::now(
176
176
  }
177
177
  else
178
178
  {
179
- if (BOOST_CHRONO_IS_THROWS(ec))
179
+ if (::boost::chrono::is_throws(ec))
180
180
  {
181
181
  boost::throw_exception(
182
182
  system::system_error(
183
183
  errno,
184
- BOOST_CHRONO_SYSTEM_CATEGORY,
184
+ ::boost::system::system_category(),
185
185
  "chrono::process_user_cpu_clock" ));
186
186
  }
187
187
  else
188
188
  {
189
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
189
+ ec.assign( errno, ::boost::system::system_category() );
190
190
  return time_point();
191
191
  }
192
192
  }
@@ -226,17 +226,17 @@ process_system_cpu_clock::time_point process_system_cpu_clock::now(
226
226
  clock_t c = ::times( &tm );
227
227
  if ( c == clock_t(-1) ) // error
228
228
  {
229
- if (BOOST_CHRONO_IS_THROWS(ec))
229
+ if (::boost::chrono::is_throws(ec))
230
230
  {
231
231
  boost::throw_exception(
232
232
  system::system_error(
233
233
  errno,
234
- BOOST_CHRONO_SYSTEM_CATEGORY,
234
+ ::boost::system::system_category(),
235
235
  "chrono::process_system_cpu_clock" ));
236
236
  }
237
237
  else
238
238
  {
239
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
239
+ ec.assign( errno, ::boost::system::system_category() );
240
240
  return time_point();
241
241
  }
242
242
  }
@@ -244,7 +244,7 @@ process_system_cpu_clock::time_point process_system_cpu_clock::now(
244
244
  {
245
245
  if ( chrono_detail::tick_factor() != -1 )
246
246
  {
247
- if (!BOOST_CHRONO_IS_THROWS(ec))
247
+ if (!::boost::chrono::is_throws(ec))
248
248
  {
249
249
  ec.clear();
250
250
  }
@@ -253,17 +253,17 @@ process_system_cpu_clock::time_point process_system_cpu_clock::now(
253
253
  }
254
254
  else
255
255
  {
256
- if (BOOST_CHRONO_IS_THROWS(ec))
256
+ if (::boost::chrono::is_throws(ec))
257
257
  {
258
258
  boost::throw_exception(
259
259
  system::system_error(
260
260
  errno,
261
- BOOST_CHRONO_SYSTEM_CATEGORY,
261
+ ::boost::system::system_category(),
262
262
  "chrono::process_system_cpu_clock" ));
263
263
  }
264
264
  else
265
265
  {
266
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
266
+ ec.assign( errno, ::boost::system::system_category() );
267
267
  return time_point();
268
268
  }
269
269
  }
@@ -306,17 +306,17 @@ process_cpu_clock::time_point process_cpu_clock::now(
306
306
  clock_t c = ::times( &tm );
307
307
  if ( c == clock_t(-1) ) // error
308
308
  {
309
- if (BOOST_CHRONO_IS_THROWS(ec))
309
+ if (::boost::chrono::is_throws(ec))
310
310
  {
311
311
  boost::throw_exception(
312
312
  system::system_error(
313
313
  errno,
314
- BOOST_CHRONO_SYSTEM_CATEGORY,
314
+ ::boost::system::system_category(),
315
315
  "chrono::process_clock" ));
316
316
  }
317
317
  else
318
318
  {
319
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
319
+ ec.assign( errno, ::boost::system::system_category() );
320
320
  return time_point();
321
321
  }
322
322
  }
@@ -332,17 +332,17 @@ process_cpu_clock::time_point process_cpu_clock::now(
332
332
  }
333
333
  else
334
334
  {
335
- if (BOOST_CHRONO_IS_THROWS(ec))
335
+ if (::boost::chrono::is_throws(ec))
336
336
  {
337
337
  boost::throw_exception(
338
338
  system::system_error(
339
339
  errno,
340
- BOOST_CHRONO_SYSTEM_CATEGORY,
340
+ ::boost::system::system_category(),
341
341
  "chrono::process_clock" ));
342
342
  }
343
343
  else
344
344
  {
345
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
345
+ ec.assign( errno, ::boost::system::system_category() );
346
346
  return time_point();
347
347
  }
348
348
  }
@@ -65,21 +65,21 @@ namespace boost { namespace chrono {
65
65
  if ( ::clock_gettime( clock_id, &ts ) )
66
66
  #endif
67
67
  {
68
- if (BOOST_CHRONO_IS_THROWS(ec))
68
+ if (::boost::chrono::is_throws(ec))
69
69
  {
70
70
  boost::throw_exception(
71
71
  system::system_error(
72
72
  errno,
73
- BOOST_CHRONO_SYSTEM_CATEGORY,
73
+ ::boost::system::system_category(),
74
74
  "chrono::thread_clock" ));
75
75
  }
76
76
  else
77
77
  {
78
- ec.assign( errno, BOOST_CHRONO_SYSTEM_CATEGORY );
78
+ ec.assign( errno, ::boost::system::system_category() );
79
79
  return time_point();
80
80
  }
81
81
  }
82
- if (!BOOST_CHRONO_IS_THROWS(ec))
82
+ if (!::boost::chrono::is_throws(ec))
83
83
  {
84
84
  ec.clear();
85
85
  }
@@ -10,10 +10,11 @@
10
10
 
11
11
  #include <boost/system/error_code.hpp>
12
12
 
13
- #define BOOST_CHRONO_SYSTEM_CATEGORY boost::system::system_category()
14
-
15
- #define BOOST_CHRONO_THROWS boost::throws()
16
- #define BOOST_CHRONO_IS_THROWS(EC) (&EC==&boost::throws())
13
+ namespace boost {
14
+ namespace chrono {
15
+ inline bool is_throws(system::error_code & ec) { return (&ec==&boost::throws()); }
16
+ }
17
+ }
17
18
 
18
19
  #endif
19
20
  #endif
@@ -767,7 +767,7 @@ namespace boost
767
767
  }
768
768
  inline int32_t days_from_1970(int32_t year)
769
769
  {
770
- static const int days_from_0_to_1970 = days_from_0(1970);
770
+ static const int32_t days_from_0_to_1970 = days_from_0(1970);
771
771
  return days_from_0(year) - days_from_0_to_1970;
772
772
  }
773
773
  inline int32_t days_from_1jan(int32_t year,int32_t month,int32_t day)
@@ -16,7 +16,7 @@
16
16
  #endif
17
17
 
18
18
  #include <boost/circular_buffer_fwd.hpp>
19
- #include <boost/detail/workaround.hpp>
19
+ #include <boost/config/workaround.hpp>
20
20
  #include <boost/static_assert.hpp>
21
21
 
22
22
  // BOOST_CB_ENABLE_DEBUG: Debug support control.
@@ -36,10 +36,10 @@
36
36
  #if BOOST_WORKAROUND(__BORLANDC__, <= 0x0550) || BOOST_WORKAROUND(__MWERKS__, <= 0x2407)
37
37
  #define BOOST_CB_IS_CONVERTIBLE(Iterator, Type) ((void)0)
38
38
  #else
39
- #include <boost/detail/iterator.hpp>
39
+ #include <iterator>
40
40
  #include <boost/type_traits/is_convertible.hpp>
41
41
  #define BOOST_CB_IS_CONVERTIBLE(Iterator, Type) \
42
- BOOST_STATIC_ASSERT((is_convertible<typename detail::iterator_traits<Iterator>::value_type, Type>::value))
42
+ BOOST_STATIC_ASSERT((is_convertible<typename std::iterator_traits<Iterator>::value_type, Type>::value))
43
43
  #endif
44
44
 
45
45
  // BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS:
@@ -0,0 +1,89 @@
1
+ // Copyright 2018 Glen Joseph Fernandes
2
+ // (glenjofe@gmail.com)
3
+ //
4
+ // Distributed under the Boost Software License, Version 1.0.
5
+ // (See accompanying file LICENSE_1_0.txt or copy at
6
+ // http://www.boost.org/LICENSE_1_0.txt)
7
+
8
+ #ifndef BOOST_CIRCULAR_BUFFER_ALLOCATORS_HPP
9
+ #define BOOST_CIRCULAR_BUFFER_ALLOCATORS_HPP
10
+
11
+ #include <boost/config.hpp>
12
+ #if defined(BOOST_NO_CXX11_ALLOCATOR)
13
+ #define BOOST_CB_NO_CXX11_ALLOCATOR
14
+ #elif defined(BOOST_LIBSTDCXX_VERSION) && (BOOST_LIBSTDCXX_VERSION < 40800)
15
+ #define BOOST_CB_NO_CXX11_ALLOCATOR
16
+ #endif
17
+ #include <limits>
18
+ #if !defined(BOOST_CB_NO_CXX11_ALLOCATOR)
19
+ #include <memory>
20
+ #else
21
+ #include <new>
22
+ #endif
23
+ #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
24
+ #include <utility>
25
+ #endif
26
+
27
+ namespace boost {
28
+ namespace cb_details {
29
+
30
+ #if !defined(BOOST_CB_NO_CXX11_ALLOCATOR)
31
+ template<class A>
32
+ struct allocator_traits
33
+ : std::allocator_traits<A> {
34
+ using typename std::allocator_traits<A>::value_type;
35
+ using typename std::allocator_traits<A>::size_type;
36
+
37
+ static size_type max_size(const A&) BOOST_NOEXCEPT {
38
+ return (std::numeric_limits<size_type>::max)() / sizeof(value_type);
39
+ }
40
+ };
41
+ #else
42
+ template<class A>
43
+ struct allocator_traits {
44
+ typedef typename A::value_type value_type;
45
+ typedef typename A::pointer pointer;
46
+ typedef typename A::const_pointer const_pointer;
47
+ typedef typename A::difference_type difference_type;
48
+ typedef typename A::size_type size_type;
49
+
50
+ static size_type max_size(const A&) BOOST_NOEXCEPT {
51
+ return (std::numeric_limits<size_type>::max)() / sizeof(value_type);
52
+ }
53
+
54
+ #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
55
+ #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
56
+ template<class U, class... Args>
57
+ static void construct(const A&, U* ptr, Args&&... args) {
58
+ ::new((void*)ptr) U(std::forward<Args>(args)...);
59
+ }
60
+ #else
61
+ template<class U, class V>
62
+ static void construct(const A&, U* ptr, V&& value) {
63
+ ::new((void*)ptr) U(std::forward<V>(value));
64
+ }
65
+ #endif
66
+ #else
67
+ template<class U, class V>
68
+ static void construct(const A&, U* ptr, const V& value) {
69
+ ::new((void*)ptr) U(value);
70
+ }
71
+
72
+ template<class U, class V>
73
+ static void construct(const A&, U* ptr, V& value) {
74
+ ::new((void*)ptr) U(value);
75
+ }
76
+ #endif
77
+
78
+ template<class U>
79
+ static void destroy(const A&, U* ptr) {
80
+ (void)ptr;
81
+ ptr->~U();
82
+ }
83
+ };
84
+ #endif
85
+
86
+ } // cb_details
87
+ } // boost
88
+
89
+ #endif
@@ -3,7 +3,9 @@
3
3
  // Copyright (c) 2003-2008 Jan Gaspar
4
4
  // Copyright (c) 2013 Paul A. Bristow // Doxygen comments changed.
5
5
  // Copyright (c) 2013 Antony Polukhin // Move semantics implementation.
6
- // Copyright (c) 2014 Glen Fernandes // C++11 allocator model support.
6
+
7
+ // Copyright 2014,2018 Glen Joseph Fernandes
8
+ // (glenjofe@gmail.com)
7
9
 
8
10
  // Use, modification, and distribution is subject to the Boost Software
9
11
  // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
@@ -17,12 +19,10 @@
17
19
  #endif
18
20
 
19
21
  #include <boost/config.hpp>
20
- #include <boost/call_traits.hpp>
21
22
  #include <boost/concept_check.hpp>
22
23
  #include <boost/limits.hpp>
23
- #include <boost/container/allocator_traits.hpp>
24
- #include <boost/iterator/reverse_iterator.hpp>
25
- #include <boost/iterator/iterator_traits.hpp>
24
+ #include <boost/circular_buffer/allocators.hpp>
25
+ #include <boost/core/empty_value.hpp>
26
26
  #include <boost/type_traits/is_stateless.hpp>
27
27
  #include <boost/type_traits/is_integral.hpp>
28
28
  #include <boost/type_traits/is_scalar.hpp>
@@ -32,8 +32,8 @@
32
32
  #include <boost/type_traits/conditional.hpp>
33
33
  #include <boost/move/adl_move_swap.hpp>
34
34
  #include <boost/move/move.hpp>
35
- #include <boost/utility/addressof.hpp>
36
35
  #include <algorithm>
36
+ #include <iterator>
37
37
  #include <utility>
38
38
  #include <deque>
39
39
  #include <stdexcept>
@@ -70,12 +70,15 @@ namespace boost {
70
70
  */
71
71
  template <class T, class Alloc>
72
72
  class circular_buffer
73
+ :
73
74
  /*! \cond */
74
75
  #if BOOST_CB_ENABLE_DEBUG
75
- : public cb_details::debug_iterator_registry
76
+ public cb_details::debug_iterator_registry,
76
77
  #endif
77
78
  /*! \endcond */
79
+ private empty_value<Alloc>
78
80
  {
81
+ typedef empty_value<Alloc> base;
79
82
 
80
83
  // Requirements
81
84
  //BOOST_CLASS_REQUIRE(T, boost, SGIAssignableConcept);
@@ -96,31 +99,31 @@ public:
96
99
  typedef circular_buffer<T, Alloc> this_type;
97
100
 
98
101
  //! The type of elements stored in the <code>circular_buffer</code>.
99
- typedef typename boost::container::allocator_traits<Alloc>::value_type value_type;
102
+ typedef typename cb_details::allocator_traits<Alloc>::value_type value_type;
100
103
 
101
104
  //! A pointer to an element.
102
- typedef typename boost::container::allocator_traits<Alloc>::pointer pointer;
105
+ typedef typename cb_details::allocator_traits<Alloc>::pointer pointer;
103
106
 
104
107
  //! A const pointer to the element.
105
- typedef typename boost::container::allocator_traits<Alloc>::const_pointer const_pointer;
108
+ typedef typename cb_details::allocator_traits<Alloc>::const_pointer const_pointer;
106
109
 
107
110
  //! A reference to an element.
108
- typedef typename boost::container::allocator_traits<Alloc>::reference reference;
111
+ typedef value_type& reference;
109
112
 
110
113
  //! A const reference to an element.
111
- typedef typename boost::container::allocator_traits<Alloc>::const_reference const_reference;
114
+ typedef const value_type& const_reference;
112
115
 
113
116
  //! The distance type.
114
117
  /*!
115
118
  (A signed integral type used to represent the distance between two iterators.)
116
119
  */
117
- typedef typename boost::container::allocator_traits<Alloc>::difference_type difference_type;
120
+ typedef typename cb_details::allocator_traits<Alloc>::difference_type difference_type;
118
121
 
119
122
  //! The size type.
120
123
  /*!
121
124
  (An unsigned integral type that can represent any non-negative value of the container's distance type.)
122
125
  */
123
- typedef typename boost::container::allocator_traits<Alloc>::size_type size_type;
126
+ typedef typename cb_details::allocator_traits<Alloc>::size_type size_type;
124
127
 
125
128
  //! The type of an allocator used in the <code>circular_buffer</code>.
126
129
  typedef Alloc allocator_type;
@@ -128,16 +131,16 @@ public:
128
131
  // Iterators
129
132
 
130
133
  //! A const (random access) iterator used to iterate through the <code>circular_buffer</code>.
131
- typedef cb_details::iterator< circular_buffer<T, Alloc>, cb_details::const_traits<boost::container::allocator_traits<Alloc> > > const_iterator;
134
+ typedef cb_details::iterator< circular_buffer<T, Alloc>, cb_details::const_traits<cb_details::allocator_traits<Alloc> > > const_iterator;
132
135
 
133
136
  //! A (random access) iterator used to iterate through the <code>circular_buffer</code>.
134
- typedef cb_details::iterator< circular_buffer<T, Alloc>, cb_details::nonconst_traits<boost::container::allocator_traits<Alloc> > > iterator;
137
+ typedef cb_details::iterator< circular_buffer<T, Alloc>, cb_details::nonconst_traits<cb_details::allocator_traits<Alloc> > > iterator;
135
138
 
136
139
  //! A const iterator used to iterate backwards through a <code>circular_buffer</code>.
137
- typedef boost::reverse_iterator<const_iterator> const_reverse_iterator;
140
+ typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
138
141
 
139
142
  //! An iterator used to iterate backwards through a <code>circular_buffer</code>.
140
- typedef boost::reverse_iterator<iterator> reverse_iterator;
143
+ typedef std::reverse_iterator<iterator> reverse_iterator;
141
144
 
142
145
  // Container specific types
143
146
 
@@ -193,9 +196,6 @@ private:
193
196
  //! The number of items currently stored in the circular buffer.
194
197
  size_type m_size;
195
198
 
196
- //! The allocator.
197
- allocator_type m_alloc;
198
-
199
199
  // Friends
200
200
  #if defined(BOOST_NO_MEMBER_TEMPLATE_FRIENDS)
201
201
  friend iterator;
@@ -219,7 +219,7 @@ public:
219
219
  Constant (in the size of the <code>circular_buffer</code>).
220
220
  \sa <code>get_allocator()</code> for obtaining an allocator %reference.
221
221
  */
222
- allocator_type get_allocator() const BOOST_NOEXCEPT { return m_alloc; }
222
+ allocator_type get_allocator() const BOOST_NOEXCEPT { return alloc(); }
223
223
 
224
224
  //! Get the allocator reference.
225
225
  /*!
@@ -235,7 +235,7 @@ public:
235
235
  although use of stateful allocators in STL is discouraged.
236
236
  \sa <code>get_allocator() const</code>
237
237
  */
238
- allocator_type& get_allocator() BOOST_NOEXCEPT { return m_alloc; }
238
+ allocator_type& get_allocator() BOOST_NOEXCEPT { return alloc(); }
239
239
 
240
240
  // Element access
241
241
 
@@ -666,7 +666,7 @@ public:
666
666
  break;
667
667
  }
668
668
  if (is_uninitialized(dest)) {
669
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(dest), boost::move_if_noexcept(*src));
669
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(dest), boost::move_if_noexcept(*src));
670
670
  ++constructed;
671
671
  } else {
672
672
  value_type tmp = boost::move_if_noexcept(*src);
@@ -787,7 +787,7 @@ public:
787
787
  \sa <code>size()</code>, <code>capacity()</code>, <code>reserve()</code>
788
788
  */
789
789
  size_type max_size() const BOOST_NOEXCEPT {
790
- return (std::min<size_type>)(boost::container::allocator_traits<Alloc>::max_size(m_alloc), (std::numeric_limits<difference_type>::max)());
790
+ return (std::min<size_type>)(cb_details::allocator_traits<Alloc>::max_size(alloc()), (std::numeric_limits<difference_type>::max)());
791
791
  }
792
792
 
793
793
  //! Is the <code>circular_buffer</code> empty?
@@ -878,7 +878,7 @@ public:
878
878
  iterator b = begin();
879
879
  BOOST_TRY {
880
880
  reset(buff,
881
- cb_details::uninitialized_move_if_noexcept(b, b + (std::min)(new_capacity, size()), buff, m_alloc),
881
+ cb_details::uninitialized_move_if_noexcept(b, b + (std::min)(new_capacity, size()), buff, alloc()),
882
882
  new_capacity);
883
883
  } BOOST_CATCH(...) {
884
884
  deallocate(buff, new_capacity);
@@ -954,7 +954,7 @@ public:
954
954
  iterator e = end();
955
955
  BOOST_TRY {
956
956
  reset(buff, cb_details::uninitialized_move_if_noexcept(e - (std::min)(new_capacity, size()),
957
- e, buff, m_alloc), new_capacity);
957
+ e, buff, alloc()), new_capacity);
958
958
  } BOOST_CATCH(...) {
959
959
  deallocate(buff, new_capacity);
960
960
  BOOST_RETHROW
@@ -1020,7 +1020,7 @@ public:
1020
1020
  <code>set_capacity(capacity_type)</code>
1021
1021
  */
1022
1022
  explicit circular_buffer(const allocator_type& alloc = allocator_type()) BOOST_NOEXCEPT
1023
- : m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0), m_alloc(alloc) {}
1023
+ : base(boost::empty_init_t(), alloc), m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0) {}
1024
1024
 
1025
1025
  //! Create an empty <code>circular_buffer</code> with the specified capacity.
1026
1026
  /*!
@@ -1033,7 +1033,7 @@ public:
1033
1033
  Constant.
1034
1034
  */
1035
1035
  explicit circular_buffer(capacity_type buffer_capacity, const allocator_type& alloc = allocator_type())
1036
- : m_size(0), m_alloc(alloc) {
1036
+ : base(boost::empty_init_t(), alloc), m_size(0) {
1037
1037
  initialize_buffer(buffer_capacity);
1038
1038
  m_first = m_last = m_buff;
1039
1039
  }
@@ -1052,7 +1052,7 @@ public:
1052
1052
  Linear (in the <code>n</code>).
1053
1053
  */
1054
1054
  circular_buffer(size_type n, param_value_type item, const allocator_type& alloc = allocator_type())
1055
- : m_size(n), m_alloc(alloc) {
1055
+ : base(boost::empty_init_t(), alloc), m_size(n) {
1056
1056
  initialize_buffer(n, item);
1057
1057
  m_first = m_last = m_buff;
1058
1058
  }
@@ -1074,7 +1074,7 @@ public:
1074
1074
  */
1075
1075
  circular_buffer(capacity_type buffer_capacity, size_type n, param_value_type item,
1076
1076
  const allocator_type& alloc = allocator_type())
1077
- : m_size(n), m_alloc(alloc) {
1077
+ : base(boost::empty_init_t(), alloc), m_size(n) {
1078
1078
  BOOST_CB_ASSERT(buffer_capacity >= size()); // check for capacity lower than size
1079
1079
  initialize_buffer(buffer_capacity, item);
1080
1080
  m_first = m_buff;
@@ -1097,11 +1097,12 @@ public:
1097
1097
  #if BOOST_CB_ENABLE_DEBUG
1098
1098
  debug_iterator_registry(),
1099
1099
  #endif
1100
- m_size(cb.size()), m_alloc(cb.get_allocator()) {
1100
+ base(boost::empty_init_t(), cb.get_allocator()),
1101
+ m_size(cb.size()) {
1101
1102
  initialize_buffer(cb.capacity());
1102
1103
  m_first = m_buff;
1103
1104
  BOOST_TRY {
1104
- m_last = cb_details::uninitialized_copy(cb.begin(), cb.end(), m_buff, m_alloc);
1105
+ m_last = cb_details::uninitialized_copy(cb.begin(), cb.end(), m_buff, alloc());
1105
1106
  } BOOST_CATCH(...) {
1106
1107
  deallocate(m_buff, cb.capacity());
1107
1108
  BOOST_RETHROW
@@ -1121,7 +1122,7 @@ public:
1121
1122
  \par Constant.
1122
1123
  */
1123
1124
  circular_buffer(circular_buffer<T, Alloc>&& cb) BOOST_NOEXCEPT
1124
- : m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0), m_alloc(cb.get_allocator()) {
1125
+ : base(boost::empty_init_t(), cb.get_allocator()), m_buff(0), m_end(0), m_first(0), m_last(0), m_size(0) {
1125
1126
  cb.swap(*this);
1126
1127
  }
1127
1128
  #endif // BOOST_NO_CXX11_RVALUE_REFERENCES
@@ -1144,7 +1145,7 @@ public:
1144
1145
  */
1145
1146
  template <class InputIterator>
1146
1147
  circular_buffer(InputIterator first, InputIterator last, const allocator_type& alloc = allocator_type())
1147
- : m_alloc(alloc) {
1148
+ : base(boost::empty_init_t(), alloc) {
1148
1149
  initialize(first, last, is_integral<InputIterator>());
1149
1150
  }
1150
1151
 
@@ -1174,7 +1175,7 @@ public:
1174
1175
  template <class InputIterator>
1175
1176
  circular_buffer(capacity_type buffer_capacity, InputIterator first, InputIterator last,
1176
1177
  const allocator_type& alloc = allocator_type())
1177
- : m_alloc(alloc) {
1178
+ : base(boost::empty_init_t(), alloc) {
1178
1179
  initialize(buffer_capacity, first, last, is_integral<InputIterator>());
1179
1180
  }
1180
1181
 
@@ -1225,7 +1226,7 @@ public:
1225
1226
  return *this;
1226
1227
  pointer buff = allocate(cb.capacity());
1227
1228
  BOOST_TRY {
1228
- reset(buff, cb_details::uninitialized_copy(cb.begin(), cb.end(), buff, m_alloc), cb.capacity());
1229
+ reset(buff, cb_details::uninitialized_copy(cb.begin(), cb.end(), buff, alloc()), cb.capacity());
1229
1230
  } BOOST_CATCH(...) {
1230
1231
  deallocate(buff, cb.capacity());
1231
1232
  BOOST_RETHROW
@@ -1245,7 +1246,7 @@ public:
1245
1246
  */
1246
1247
  circular_buffer<T, Alloc>& operator = (circular_buffer<T, Alloc>&& cb) BOOST_NOEXCEPT {
1247
1248
  cb.swap(*this); // now `this` holds `cb`
1248
- circular_buffer<T, Alloc>(get_allocator()) // temprary that holds initial `cb` allocator
1249
+ circular_buffer<T, Alloc>(get_allocator()) // temporary that holds initial `cb` allocator
1249
1250
  .swap(cb); // makes `cb` empty
1250
1251
  return *this;
1251
1252
  }
@@ -1276,7 +1277,7 @@ public:
1276
1277
  <code>assign(capacity_type, InputIterator, InputIterator)</code>
1277
1278
  */
1278
1279
  void assign(size_type n, param_value_type item) {
1279
- assign_n(n, n, cb_details::assign_n<param_value_type, allocator_type>(n, item, m_alloc));
1280
+ assign_n(n, n, cb_details::assign_n<param_value_type, allocator_type>(n, item, alloc()));
1280
1281
  }
1281
1282
 
1282
1283
  //! Assign <code>n</code> items into the <code>circular_buffer</code> specifying the capacity.
@@ -1306,7 +1307,7 @@ public:
1306
1307
  */
1307
1308
  void assign(capacity_type buffer_capacity, size_type n, param_value_type item) {
1308
1309
  BOOST_CB_ASSERT(buffer_capacity >= n); // check for new capacity lower than n
1309
- assign_n(buffer_capacity, n, cb_details::assign_n<param_value_type, allocator_type>(n, item, m_alloc));
1310
+ assign_n(buffer_capacity, n, cb_details::assign_n<param_value_type, allocator_type>(n, item, alloc()));
1310
1311
  }
1311
1312
 
1312
1313
  //! Assign a copy of the range into the <code>circular_buffer</code>.
@@ -1422,7 +1423,7 @@ private:
1422
1423
  increment(m_last);
1423
1424
  m_first = m_last;
1424
1425
  } else {
1425
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(m_last), static_cast<ValT>(item));
1426
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(m_last), static_cast<ValT>(item));
1426
1427
  increment(m_last);
1427
1428
  ++m_size;
1428
1429
  }
@@ -1439,7 +1440,7 @@ private:
1439
1440
  m_last = m_first;
1440
1441
  } else {
1441
1442
  decrement(m_first);
1442
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(m_first), static_cast<ValT>(item));
1443
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(m_first), static_cast<ValT>(item));
1443
1444
  ++m_size;
1444
1445
  }
1445
1446
  } BOOST_CATCH(...) {
@@ -2173,7 +2174,7 @@ public:
2173
2174
  the erased element (towards the beginning).
2174
2175
  \par Complexity
2175
2176
  Linear (in <code>std::distance(begin(), pos)</code>).
2176
- \note This method is symetric to the <code>erase(iterator)</code> method and is more effective than
2177
+ \note This method is symmetric to the <code>erase(iterator)</code> method and is more effective than
2177
2178
  <code>erase(iterator)</code> if the iterator <code>pos</code> is close to the beginning of the
2178
2179
  <code>circular_buffer</code>. (See the <i>Complexity</i>.)
2179
2180
  \sa <code>erase(iterator)</code>, <code>erase(iterator, iterator)</code>,
@@ -2214,7 +2215,7 @@ public:
2214
2215
  the erased range (towards the beginning).
2215
2216
  \par Complexity
2216
2217
  Linear (in <code>std::distance(begin(), last)</code>).
2217
- \note This method is symetric to the <code>erase(iterator, iterator)</code> method and is more effective than
2218
+ \note This method is symmetric to the <code>erase(iterator, iterator)</code> method and is more effective than
2218
2219
  <code>erase(iterator, iterator)</code> if <code>std::distance(begin(), first)</code> is lower that
2219
2220
  <code>std::distance(last, end())</code>.
2220
2221
  \sa <code>erase(iterator)</code>, <code>erase(iterator, iterator)</code>, <code>rerase(iterator)</code>,
@@ -2367,23 +2368,31 @@ private:
2367
2368
  //! Map the null pointer to virtual end of circular buffer.
2368
2369
  pointer map_pointer(pointer p) const { return p == 0 ? m_last : p; }
2369
2370
 
2371
+ const Alloc& alloc() const {
2372
+ return base::get();
2373
+ }
2374
+
2375
+ Alloc& alloc() {
2376
+ return base::get();
2377
+ }
2378
+
2370
2379
  //! Allocate memory.
2371
2380
  pointer allocate(size_type n) {
2372
2381
  if (n > max_size())
2373
2382
  throw_exception(std::length_error("circular_buffer"));
2374
2383
  #if BOOST_CB_ENABLE_DEBUG
2375
- pointer p = (n == 0) ? 0 : m_alloc.allocate(n);
2384
+ pointer p = (n == 0) ? 0 : alloc().allocate(n);
2376
2385
  cb_details::do_fill_uninitialized_memory(p, sizeof(value_type) * n);
2377
2386
  return p;
2378
2387
  #else
2379
- return (n == 0) ? 0 : m_alloc.allocate(n);
2388
+ return (n == 0) ? 0 : alloc().allocate(n);
2380
2389
  #endif
2381
2390
  }
2382
2391
 
2383
2392
  //! Deallocate memory.
2384
2393
  void deallocate(pointer p, size_type n) {
2385
2394
  if (p != 0)
2386
- m_alloc.deallocate(p, n);
2395
+ alloc().deallocate(p, n);
2387
2396
  }
2388
2397
 
2389
2398
  //! Does the pointer point to the uninitialized memory?
@@ -2414,7 +2423,7 @@ private:
2414
2423
  */
2415
2424
  void construct_or_replace(bool construct, pointer pos, param_value_type item) {
2416
2425
  if (construct)
2417
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(pos), item);
2426
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(pos), item);
2418
2427
  else
2419
2428
  replace(pos, item);
2420
2429
  }
@@ -2426,14 +2435,14 @@ private:
2426
2435
  */
2427
2436
  void construct_or_replace(bool construct, pointer pos, rvalue_type item) {
2428
2437
  if (construct)
2429
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(pos), boost::move(item));
2438
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(pos), boost::move(item));
2430
2439
  else
2431
2440
  replace(pos, boost::move(item));
2432
2441
  }
2433
2442
 
2434
2443
  //! Destroy an item.
2435
2444
  void destroy_item(pointer p) {
2436
- boost::container::allocator_traits<Alloc>::destroy(m_alloc, boost::to_address(p));
2445
+ cb_details::allocator_traits<Alloc>::destroy(alloc(), boost::to_address(p));
2437
2446
  #if BOOST_CB_ENABLE_DEBUG
2438
2447
  invalidate_iterators(iterator(this, p));
2439
2448
  cb_details::do_fill_uninitialized_memory(p, sizeof(value_type));
@@ -2488,7 +2497,7 @@ private:
2488
2497
  void initialize_buffer(capacity_type buffer_capacity, param_value_type item) {
2489
2498
  initialize_buffer(buffer_capacity);
2490
2499
  BOOST_TRY {
2491
- cb_details::uninitialized_fill_n_with_alloc(m_buff, size(), item, m_alloc);
2500
+ cb_details::uninitialized_fill_n_with_alloc(m_buff, size(), item, alloc());
2492
2501
  } BOOST_CATCH(...) {
2493
2502
  deallocate(m_buff, size());
2494
2503
  BOOST_RETHROW
@@ -2509,9 +2518,9 @@ private:
2509
2518
  void initialize(Iterator first, Iterator last, const false_type&) {
2510
2519
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2511
2520
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2512
- initialize(first, last, iterator_category<Iterator>::type());
2521
+ initialize(first, last, std::iterator_traits<Iterator>::iterator_category());
2513
2522
  #else
2514
- initialize(first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2523
+ initialize(first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2515
2524
  #endif
2516
2525
  }
2517
2526
 
@@ -2520,7 +2529,7 @@ private:
2520
2529
  void initialize(InputIterator first, InputIterator last, const std::input_iterator_tag&) {
2521
2530
  BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS // check if the STL provides templated iterator constructors
2522
2531
  // for containers
2523
- std::deque<value_type, allocator_type> tmp(first, last, m_alloc);
2532
+ std::deque<value_type, allocator_type> tmp(first, last, alloc());
2524
2533
  size_type distance = tmp.size();
2525
2534
  initialize(distance, boost::make_move_iterator(tmp.begin()), boost::make_move_iterator(tmp.end()), distance);
2526
2535
  }
@@ -2548,9 +2557,9 @@ private:
2548
2557
  void initialize(capacity_type buffer_capacity, Iterator first, Iterator last, const false_type&) {
2549
2558
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2550
2559
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2551
- initialize(buffer_capacity, first, last, iterator_category<Iterator>::type());
2560
+ initialize(buffer_capacity, first, last, std::iterator_traits<Iterator>::iterator_category());
2552
2561
  #else
2553
- initialize(buffer_capacity, first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2562
+ initialize(buffer_capacity, first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2554
2563
  #endif
2555
2564
  }
2556
2565
 
@@ -2566,7 +2575,7 @@ private:
2566
2575
  if (buffer_capacity == 0)
2567
2576
  return;
2568
2577
  while (first != last && !full()) {
2569
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(m_last), *first++);
2578
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(m_last), *first++);
2570
2579
  increment(m_last);
2571
2580
  ++m_size;
2572
2581
  }
@@ -2602,7 +2611,7 @@ private:
2602
2611
  m_size = distance;
2603
2612
  }
2604
2613
  BOOST_TRY {
2605
- m_last = cb_details::uninitialized_copy(first, last, m_buff, m_alloc);
2614
+ m_last = cb_details::uninitialized_copy(first, last, m_buff, alloc());
2606
2615
  } BOOST_CATCH(...) {
2607
2616
  deallocate(m_buff, buffer_capacity);
2608
2617
  BOOST_RETHROW
@@ -2628,7 +2637,7 @@ private:
2628
2637
 
2629
2638
  //! Specialized method for swapping the allocator.
2630
2639
  void swap_allocator(circular_buffer<T, Alloc>& cb, const false_type&) {
2631
- adl_move_swap(m_alloc, cb.m_alloc);
2640
+ adl_move_swap(alloc(), cb.alloc());
2632
2641
  }
2633
2642
 
2634
2643
  //! Specialized assign method.
@@ -2642,9 +2651,9 @@ private:
2642
2651
  void assign(Iterator first, Iterator last, const false_type&) {
2643
2652
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2644
2653
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2645
- assign(first, last, iterator_category<Iterator>::type());
2654
+ assign(first, last, std::iterator_traits<Iterator>::iterator_category());
2646
2655
  #else
2647
- assign(first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2656
+ assign(first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2648
2657
  #endif
2649
2658
  }
2650
2659
 
@@ -2653,11 +2662,11 @@ private:
2653
2662
  void assign(InputIterator first, InputIterator last, const std::input_iterator_tag&) {
2654
2663
  BOOST_CB_ASSERT_TEMPLATED_ITERATOR_CONSTRUCTORS // check if the STL provides templated iterator constructors
2655
2664
  // for containers
2656
- std::deque<value_type, allocator_type> tmp(first, last, m_alloc);
2665
+ std::deque<value_type, allocator_type> tmp(first, last, alloc());
2657
2666
  size_type distance = tmp.size();
2658
2667
  assign_n(distance, distance,
2659
2668
  cb_details::make_assign_range
2660
- (boost::make_move_iterator(tmp.begin()), boost::make_move_iterator(tmp.end()), m_alloc));
2669
+ (boost::make_move_iterator(tmp.begin()), boost::make_move_iterator(tmp.end()), alloc()));
2661
2670
  }
2662
2671
 
2663
2672
  //! Specialized assign method.
@@ -2665,7 +2674,7 @@ private:
2665
2674
  void assign(ForwardIterator first, ForwardIterator last, const std::forward_iterator_tag&) {
2666
2675
  BOOST_CB_ASSERT(std::distance(first, last) >= 0); // check for wrong range
2667
2676
  size_type distance = std::distance(first, last);
2668
- assign_n(distance, distance, cb_details::make_assign_range(first, last, m_alloc));
2677
+ assign_n(distance, distance, cb_details::make_assign_range(first, last, alloc()));
2669
2678
  }
2670
2679
 
2671
2680
  //! Specialized assign method.
@@ -2679,9 +2688,9 @@ private:
2679
2688
  void assign(capacity_type new_capacity, Iterator first, Iterator last, const false_type&) {
2680
2689
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2681
2690
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2682
- assign(new_capacity, first, last, iterator_category<Iterator>::type());
2691
+ assign(new_capacity, first, last, std::iterator_traits<Iterator>::iterator_category());
2683
2692
  #else
2684
- assign(new_capacity, first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2693
+ assign(new_capacity, first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2685
2694
  #endif
2686
2695
  }
2687
2696
 
@@ -2692,7 +2701,7 @@ private:
2692
2701
  clear();
2693
2702
  insert(begin(), first, last);
2694
2703
  } else {
2695
- circular_buffer<value_type, allocator_type> tmp(new_capacity, first, last, m_alloc);
2704
+ circular_buffer<value_type, allocator_type> tmp(new_capacity, first, last, alloc());
2696
2705
  tmp.swap(*this);
2697
2706
  }
2698
2707
  }
@@ -2708,7 +2717,7 @@ private:
2708
2717
  distance = new_capacity;
2709
2718
  }
2710
2719
  assign_n(new_capacity, distance,
2711
- cb_details::make_assign_range(first, last, m_alloc));
2720
+ cb_details::make_assign_range(first, last, alloc()));
2712
2721
  }
2713
2722
 
2714
2723
  //! Helper assign method.
@@ -2788,9 +2797,9 @@ private:
2788
2797
  void insert(const iterator& pos, Iterator first, Iterator last, const false_type&) {
2789
2798
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2790
2799
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2791
- insert(pos, first, last, iterator_category<Iterator>::type());
2800
+ insert(pos, first, last, std::iterator_traits<Iterator>::iterator_category());
2792
2801
  #else
2793
- insert(pos, first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2802
+ insert(pos, first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2794
2803
  #endif
2795
2804
  }
2796
2805
 
@@ -2831,7 +2840,7 @@ private:
2831
2840
  pointer p = m_last;
2832
2841
  BOOST_TRY {
2833
2842
  for (; ii < construct; ++ii, increment(p))
2834
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(p), *wrapper());
2843
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(p), *wrapper());
2835
2844
  for (;ii < n; ++ii, increment(p))
2836
2845
  replace(p, *wrapper());
2837
2846
  } BOOST_CATCH(...) {
@@ -2879,9 +2888,9 @@ private:
2879
2888
  void rinsert(const iterator& pos, Iterator first, Iterator last, const false_type&) {
2880
2889
  BOOST_CB_IS_CONVERTIBLE(Iterator, value_type); // check for invalid iterator type
2881
2890
  #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x581))
2882
- rinsert(pos, first, last, iterator_category<Iterator>::type());
2891
+ rinsert(pos, first, last, std::iterator_traits<Iterator>::iterator_category());
2883
2892
  #else
2884
- rinsert(pos, first, last, BOOST_DEDUCED_TYPENAME iterator_category<Iterator>::type());
2893
+ rinsert(pos, first, last, BOOST_DEDUCED_TYPENAME std::iterator_traits<Iterator>::iterator_category());
2885
2894
  #endif
2886
2895
  }
2887
2896
 
@@ -2925,7 +2934,7 @@ private:
2925
2934
  for (;ii > construct; --ii, increment(p))
2926
2935
  replace(p, *wrapper());
2927
2936
  for (; ii > 0; --ii, increment(p))
2928
- boost::container::allocator_traits<Alloc>::construct(m_alloc, boost::to_address(p), *wrapper());
2937
+ cb_details::allocator_traits<Alloc>::construct(alloc(), boost::to_address(p), *wrapper());
2929
2938
  } BOOST_CATCH(...) {
2930
2939
  size_type constructed = ii < construct ? construct - ii : 0;
2931
2940
  m_last = add(m_last, constructed);